From e7eb592764681e76d6c53c0059f79a54292d2538 Mon Sep 17 00:00:00 2001 From: Jieiku Date: Thu, 23 Jun 2022 06:42:15 -0700 Subject: Update Abridge.woff2 and Readme --- README.md | 15 +++++++++++++++ config.toml | 5 +++-- sass/_variables.scss | 2 +- sass/fonts/_Abridge.scss | 13 +++++++------ sass/include/_nav.scss | 2 +- static/font/Abridge.woff2 | Bin 788 -> 768 bytes 6 files changed, 27 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index a51b73d..a178dc0 100644 --- a/README.md +++ b/README.md @@ -352,6 +352,21 @@ All pages extend to `base.html`, and you can customize them as need. ## Optional Performance Optimizations: +### Abridge.woff2 Icon Font + +The Abridge.woff2 Icon Font is a subset of Font Awesome. + +This file can be overridden just like any other Zola theme file, by placing your own Abridge.woff2 in your sites root eg: `mysite/static/font/Abridge.woff2` + +To create your own Icon Font with other/more icons you can use the repository here: https://github.com/Jieiku/fontsubset + +You will also need to add the additional icon entries to `abridge/sass/fonts/_Abridge.scss` + +If you are running Abridge as a submodule, what you can do instead is copy `_Abridge.scss` as your own `mysite/sass/myfont.scss`, and then adjust your config.toml: + +instead of this: `stylesheets = [ "abridge-switcher.css" ]` do this: `stylesheets = [ "abridge-switcher.css", "myfont.css" ]` + + ### Theme-Switcher The theme switcher relies on javascript to work, it applies the .light class to the root documentElement. The file that handles this (theme.js) is tiny and optimized and it is the first file loaded in the head, so the performance hit is minimal, but it does still exist. Without the Theme switcher you can still use The automatic Theme, it works by using Browser/OS preference, you can even install a [Firefox plugin](https://addons.mozilla.org/en-US/firefox/addon/theme-switcher-for-firefox/) to quickly switch between the two. By default the demo has the theme switcher enabled so that it can be evaluated. diff --git a/config.toml b/config.toml index cbeb1ea..6b0503c 100644 --- a/config.toml +++ b/config.toml @@ -107,6 +107,7 @@ js_bundle = "abridge-switcher.min.js"# Bundle JS File, comment out to disable (i stylesheets = [ "abridge-switcher.css" ] # Orange Automatic Dark/Light Theme based on browser/system preference with switcher #stylesheets = [ "abridge-blue-switcher.css" ] # Blue Automatic Night/Light Theme based on browser/system preference with switcher #stylesheets = [ "abridge-blueshade-switcher.css" ] # BlueShade Automatic Night/Light Theme based on browser/system preference with switcher +#stylesheets = [ "abridge-switcher.css", "myfont.css" ] # include your own font icons! ########## No Switcher ########## #js_bundle = "search.min.js"# Bundle JS File, comment out to disable (search only: no switcher/prestyle) @@ -143,8 +144,8 @@ favicon180 = "apple-touch-icon.png" # apple-touch-icon.png favicon32 = "favicon-32x32.png" # favicon-32x32.png favicon16 = "favicon-16x16.png" # favicon-16x16.png -icon_search = "svgs search" # Search button in search box. -icon_adjust = "svgs svgh i-adjust" # Theme Switcher button in top menu. +icon_search = "svgs i-search" # Search button in search box. +icon_adjust = "svgs i-adjust" # Theme Switcher button in top menu. (add class svgh to change colors on hover) icon_top = "svgs i-up" # Back to Top Button. icon_first = "svgs i-first" # Pagination First Page. icon_prev = "svgs i-prev" # Pagination Previous Page. diff --git a/sass/_variables.scss b/sass/_variables.scss index 51b3d8c..af41e32 100644 --- a/sass/_variables.scss +++ b/sass/_variables.scss @@ -87,8 +87,8 @@ $icon-twitch: true !default; $icon-youtube: true !default; $icon-researchgate: true !default; -$icon-search: true !default; $icon-x: true !default;// x symbol +$icon-search: false !default; $icon-contrast: false !default; $icon-ffolder: false !default; $icon-folder: false !default;// categories folder diff --git a/sass/fonts/_Abridge.scss b/sass/fonts/_Abridge.scss index 09f4637..3085236 100644 --- a/sass/fonts/_Abridge.scss +++ b/sass/fonts/_Abridge.scss @@ -17,9 +17,10 @@ //text-decoration: inherit; } -.i-up:before { content: '\e801'; } /* '' */ -.i-adjust:before { content: '\e803'; } /* '' */ -.i-first:before { content: '\f100'; } /* '' */ -.i-last:before { content: '\f101'; } /* '' */ -.i-prev:before { content: '\f104'; } /* '' */ -.i-next:before { content: '\f105'; } /* '' */ +.i-search:before { content: '\f002'; } // search box button +.i-adjust:before { content: '\f042'; } // theme switcher button +.i-first:before { content: '\f100'; } // pagination first page +.i-last:before { content: '\f101'; } // pagination last page +.i-prev:before { content: '\f104'; } // pagination previous page +.i-next:before { content: '\f105'; } // pagination next page +.i-up:before { content: '\f106'; } // back to top button \ No newline at end of file diff --git a/sass/include/_nav.scss b/sass/include/_nav.scss index 38f15d6..a86ec54 100644 --- a/sass/include/_nav.scss +++ b/sass/include/_nav.scss @@ -77,7 +77,7 @@ main nav { border-radius: var(--br); } .mode:hover, .cnav { - color: var(--a3);//pagination color current page + color: var(--a1);//pagination color current page } footer nav { ul { diff --git a/static/font/Abridge.woff2 b/static/font/Abridge.woff2 index e87c1bc..2ce0193 100644 Binary files a/static/font/Abridge.woff2 and b/static/font/Abridge.woff2 differ -- cgit v1.3.1