diff --git a/assets/js/mathjax-assistant.js b/assets/js/mathjax-assistant.js new file mode 100644 index 0000000..dab8c9e --- /dev/null +++ b/assets/js/mathjax-assistant.js @@ -0,0 +1,12 @@ +MathJax = { + tex: { + displayMath: [['\\[', '\\]'], ['$$', '$$']], // block + inlineMath: [['\\(', '\\)']] // inline + // processEscapes: true, + // processEnvironments: true, + } + // options: { + // skipHtmlTags: ['script', 'noscript', 'style', 'textarea', 'pre'], + // enableMenu: false + // } +}; \ No newline at end of file diff --git a/assets/scss/_predefined.scss b/assets/scss/_predefined.scss index b513b92..2defe61 100644 --- a/assets/scss/_predefined.scss +++ b/assets/scss/_predefined.scss @@ -1,6 +1,6 @@ // Colors -$theme: #018574; -$text: #e8eef2; +$theme: hsl(172, 99%, 26%); +$text: hsl(204, 28%, 93%); $light-grey: #494f5c; $dark-grey: #3B3E48; $highlight-grey: #7d828a; diff --git a/assets/scss/style.scss b/assets/scss/style.scss index 3ae8afa..96d533e 100644 --- a/assets/scss/style.scss +++ b/assets/scss/style.scss @@ -4,12 +4,20 @@ @import "animate.scss"; @import "_scroll.scss"; @import "_admonition.scss"; -@import "_mathjax.scss"; @import "_socialshare.scss"; {{ if (fileExists "assets/scss/userstyles.scss") }} @import "userstyles.scss"; {{ end }} +/* text selection */ +::-moz-selection { + background: $highlight-grey; +} + +::selection { + background: $highlight-grey; +} + /* Webkit Scrollbar Customize */ ::-webkit-scrollbar { width: 8px; @@ -60,13 +68,14 @@ pre { code { padding: 0; margin: 0; - background: $midnightblue; + color: #eee; + background: transparent; } } code { - color: #eee; - background: $highlight-grey; + color: hsl(0, 1%, 67%); + background: $dark-grey; border-radius: 3px; padding: 0 3px; margin: 0 4px; @@ -463,7 +472,6 @@ p.img-404 { @include dimmed; &:hover { - text-decoration: underline; cursor: pointer; } } @@ -491,6 +499,36 @@ p.img-404 { margin-left: 1em; @include dimmed; } + .post-description { + font-size:x-small; + flex-shrink: 0; + @include dimmed; + } +} + +.pinned-posts-group { + display: flex; + margin-bottom: 1.9em; + line-height: normal; + border-bottom: 2px $highlight-grey solid; + + .pinned-posts-list { + flex-grow: 1; + margin: 0; + padding: 0; + list-style: none; + } + + .pinned-post-item { + display: flex; + justify-content: start; + align-items: baseline; + padding: 12px 0; + + a { + padding-left: 12px; + } + } } // single.html diff --git a/hugo.toml.example b/hugo.toml.example index a56ed87..21d705c 100644 --- a/hugo.toml.example +++ b/hugo.toml.example @@ -43,6 +43,13 @@ enableEmoji = true # googleAnalytics = "UA-123-45" # disqusShortname = "CHANGE ME" +[frontmatter] +date = ["date", "publishDate", "lastmod"] +lastmod = ["lastmod", ":git", "date", "publishDate"] +publishDate = ["publishDate", "date"] +expiryDate = ["expiryDate"] + + [params.author] name = "CHANGE SITE AUTHOR" about = "CHANGE SITE AUTHOR ABOUT" @@ -57,6 +64,17 @@ enableEmoji = true # Categories are disabled by default. # category = "categories" +# Enable to get proper Mathjax support +#[markup] +# [markup.goldmark] +# [markup.goldmark.extensions] +# [markup.goldmark.extensions.passthrough] +# enable = true +# [markup.goldmark.extensions.passthrough.delimiters] +# block = [['\[', '\]'], ['$$', '$$']] +# inline = [['\(', '\)']] + + [params] dateform = "Jan 2, 2006" dateformShort = "Jan 2" @@ -87,6 +105,10 @@ enableEmoji = true # googleTagManager = "GTM-XXXXXXXX" # tagSymbol = "#" # categorySymbol = "⊲" + # pinned = "Pinned Posts" + # pinnedSVGname = "pin" + # descriptionInPosts= true + # initialPublish = "Initally Posted on: " [[params.socialLinks]] name = "mastodon" diff --git a/layouts/_default/list.html b/layouts/_default/list.html index dc525d6..c7b2e30 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -10,20 +10,42 @@ {{ .Content }} {{- end }} + + {{- if and (ge (len (where .Site.Pages ".Params.pin" true)) 1) (.Site.Params.pinned) -}} +