diff options
| author | a73x <[email protected]> | 2024-08-31 18:51:42 +0100 |
|---|---|---|
| committer | a73x <[email protected]> | 2024-08-31 18:51:46 +0100 |
| commit | 68cc8a115d79c97e3c557c70d81d59d0de29ae46 (patch) | |
| tree | d027f0eb3cb8d1cf0692238dfbb582326661a17e /templates/layouts | |
| parent | 975df0362b6ccfe958e550db246f465b2753baf7 (diff) | |
feat(html): add syntax highlighting
using a js library until I work out how to use https://github.com/alecthomas/chroma
Diffstat (limited to 'templates/layouts')
| -rw-r--r-- | templates/layouts/_default.html | 28 |
1 files changed, 7 insertions, 21 deletions
diff --git a/templates/layouts/_default.html b/templates/layouts/_default.html index 27cd916..33ae3fd 100644 --- a/templates/layouts/_default.html +++ b/templates/layouts/_default.html @@ -9,6 +9,10 @@ <meta name="viewport" content="user-scalable=no, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, width=device-width" /> <title>a73x</title> + <link rel="stylesheet" href="/static/styles.css"> + <script src="/static/highlight.js"></script> + <script src="/static/highlight.go.js"></script> + <script>hljs.highlightAll();</script> <style> @font-face { font-family: 'Mono'; @@ -16,6 +20,9 @@ font-weight: normal; font-style: normal; } + code { + font-family: "Mono"; + } h1 { margin-bottom: 0; } @@ -23,27 +30,6 @@ max-width: 70ch; font-family: "Mono"; } - - pre { - overflow: scroll; - font-family: "Mono"; - color: crimson; - background-color: #f1f1f1; - padding: 2px; - - } - - pre code { - background: none; - } - - code { - font-family: "Mono"; - color: crimson; - background-color: #f1f1f1; - padding: 2px; - } - nav ul { display: flex; list-style: none; |
