Pārlūkot izejas kodu

feat: add XS and XL font sizes and change default font size to L

George Cushen 5 gadi atpakaļ
vecāks
revīzija
e9a7925152

+ 9 - 5
exampleSite/config/_default/params.toml

@@ -2,7 +2,7 @@
 # Documentation: https://sourcethemes.com/academic/
 
 # Choose a theme.
-#   Latest themes (may require updating Academic): https://sourcethemes.com/academic/themes/
+#   Latest themes (may require updating): https://sourcethemes.com/academic/themes/
 #   Browse built-in themes in `themes/academic/data/themes/`
 #   Browse user installed themes in `data/themes/`
 theme = "minimal"
@@ -10,15 +10,15 @@ theme = "minimal"
 # Enable users to switch between day and night mode?
 day_night = true
 
-# Overrride the theme's font set (optional).
-#   Latest font sets (may require updating Academic): https://sourcethemes.com/academic/themes/
+# Override the theme's font set (optional).
+#   Latest font sets (may require updating): https://sourcethemes.com/academic/themes/
 #   Browse built-in font sets in `themes/academic/data/fonts/`
 #   Browse user installed font sets in `data/fonts/`
 font = ""
 
 # Choose a font size.
-# Sizes: s (small), m (medium), l (large)
-font_size = "m"
+# Sizes: XS (extra small), S (small), M (medium), L (large - DEFAULT), XL (extra large)
+font_size = "L"
 
 # Description for social sharing and search engines. If undefined, superuser role is used in place.
 description = ""
@@ -109,6 +109,10 @@ latitude = "37.4275"
 longitude = "-122.1697"
 zoom = 15
 
+# Address line delimiter
+# Popular separators are ", " (comma), "<br>" (new line), " " (space)
+address_delimiter = ", "
+
 ############################
 ## Plugins                ##
 ############################

+ 3 - 3
layouts/partials/functions/parse_theme.html

@@ -9,9 +9,9 @@
 
 {{/* Get Font Size. */}}
 
-{{- $font_size := site.Params.font_size | default "m" -}}
-{{- $font_sizes := dict "s" 16 "m" 21 "l" 25 -}}
-{{- $font_size_numeric := (index $font_sizes $font_size) | default (index $font_sizes "m") -}}
+{{- $font_size := lower site.Params.font_size | default "l" -}}
+{{- $font_sizes := dict "xs" 14 "s" 16 "m" 18 "l" 21 "xl" 23 -}}
+{{- $font_size_numeric := (index $font_sizes $font_size) | default (index $font_sizes "l") -}}
 {{- $scr.Set "font_size" $font_size_numeric -}}
 {{- $scr.Set "font_size_small" (mul 0.77 $font_size_numeric) -}}