Commit Graph

24 Commits

Author SHA1 Message Date
Nathan Harkenrider
dde6a10cab
feat: implement cache busting for CSS (#444) 2021-12-28 23:28:33 +01:00
k
dda55f87e2
feat: change the page vertical scrollbar styles (#227)
* fix: take out [data-scheme="dark"] from :root

Taking out the [data-scheme="dark"] from :root allows us to fix the
precedence of CSS when the [data-scheme="dark"] is placed in the <html>
tag. This is needed in order to make the dark styles accesible from the
<html> elment, this will allow us to change the vertical scrollbar
styles following the dark and light schemes.

* change document.body.dataset.scheme to document.documentElement.dataset.scheme

When the dark mode is on or when the light mode is on, the
[data-scheme="light"] or [data-scheme="dark"], respectively, will be
placed in the <html> tag. Allowing us to access the dark and light color
schemes from the <html> to change the vertical scrollbar styles
according to the current color scheme.

* feat: change the page vertical scrollbar styles

This change will make the vertical scrollbar styles to follow the dark
and light color scheme modes. Also, this change will make the vertical
scrollbar to look consistent in both, Chromium and Firefox.

* make the scrollbar-track background-color transparent

The body has this transition: 'transition: background-color 0.3s ease
0s'. Making the scrollbar-track background-color transparent allow us to
appreciate that transition in the scrollbar-track when switching the
background-color.

* Move [data-scheme=dark] back to :root block

* fix(comment/waline): detect dark mode from html tag

* feat: apply custom scrollbar style to all elements

Co-authored-by: Jimmy Cai <jimmehcai@gmail.com>
2021-06-20 15:49:35 +02:00
zhixuan
2c0bf8c940
feat: Add support for Google Analytics v4 (#214) 2021-06-12 09:51:31 +02:00
zhixuan
7dab67b358
refactor(opengraph/twitter): add @ before username (#186)
https://github.com/gohugoio/hugo/blob/master/tpl/tplimpl/embedded/templates/twitter_cards.html
2021-04-07 10:31:25 +02:00
Julian Alarcon
83e3a4e8e1
feat: Google Analytics support (#135)
* Added Google Analytics feature

* style: load GA script before head/custom

* style(config): googleAnalytics field empty by default

Co-authored-by: Jimmy Cai <github@jimmycai.com>
2021-02-11 18:56:39 +01:00
Jimmy Cai
358e63e799
feat(darkmode): dark mode toggle (#82)
* feat(darkmode): initial support for dark mode toggle

* fix(darkmode): add svg icons

* feat(darkmode): dispatch onColorSchemeChange event

* add head/darkmode

* feat(darkmode); add colorScheme config

* style: remove empty line

* refactor(darkmode): simplify code

* style: add comment for darkmode config

* i18n support for dark mode toggle

* Some renaming
2020-12-23 19:03:40 +01:00
Jimmy Cai
ddd6aa2d20
feat(head): add favicon setting in config.yaml (#73)
closes https://github.com/CaiJimmy/hugo-theme-stack/issues/42
2020-12-20 11:38:49 +01:00
Jimmy Cai
25a72940b8
refactor(opengraph): add default value for twitter:card (#72) 2020-12-20 11:05:34 +01:00
Jimmy Cai
c19780280e
feat: add "head" block 2020-09-26 23:00:48 +02:00
Jimmy Cai
0bcfb160f1
fix: use .RelPermalink to include CSS 2020-09-20 11:33:32 +02:00
Jimmy Cai
93146c9dc3
fix: add .Type as second cache key for helper/image
closes https://github.com/CaiJimmy/hugo-theme-stack/issues/12
2020-09-18 00:12:26 +02:00
Jimmy Cai
8f0d420d24
feat: add partialCached for data/title data/description 2020-09-17 21:59:57 +02:00
Jimmy Cai
cf6502c311
feat: add partialCached to helper/image invocation
Using .RelPermalink as key for cache
2020-09-17 21:52:06 +02:00
Jimmy Cai
5265af0b3b
reafctor(head): rewrite description.html function 2020-09-11 23:00:19 +02:00
Jimmy Cai
6f5ee1bbdb
refactor(head): rewrite title function 2020-09-11 22:50:30 +02:00
Jimmy Cai
b064b5ef85
refactor: move partial/head.html and partial/footer.html 2020-09-11 22:41:40 +02:00
Jimmy Cai
5f7e818b92
refactor(head/opengraph): split code into modules 2020-09-11 21:55:15 +02:00
Jimmy Cai
a2662603df
feat(helper/image): new way to set default image 2020-09-11 16:27:23 +02:00
Jimmy Cai
cfd4cdb731
feat(helper/image): new return format 2020-09-11 16:01:01 +02:00
Jimmy Cai
28c06ef8ae
feat(helper/image): new image helper (WIP) 2020-09-10 18:53:36 +02:00
Jimmy Cai
a6870541dd feat: add head/custom and footer/custom for inserting custom code 2020-08-24 20:48:31 +02:00
Jimmy Cai
901d1f63fc refactor(opengraph): move OpenGraph related settings to .Params.opengraph 2020-08-23 11:30:10 +02:00
Jimmy Cai
18148dbc4f Place webfont at the bottom of the page 2020-08-22 16:14:12 +02:00
Jimmy Cai
c698d944e6 🎉 Initial commit 2020-08-22 13:20:08 +02:00