mirror of
https://github.com/fruworg/themu.git
synced 2025-06-13 18:20:25 +03:00
Option to use local font files instead of Google fonts, combined option for CDN use (#16)
* option to use local font files instead of GoogleFonts, combined config for CDN use * set new combined config in exampleSite config * fix path to fonts when hugo is serving in a subdirectory * update README for new option * switch to Fira Sans
This commit is contained in:
@ -33,13 +33,18 @@
|
||||
|
||||
{{- template "_internal/opengraph.html" . -}}
|
||||
{{- template "_internal/twitter_cards.html" . -}}
|
||||
{{ if and (isset .Site.Params "social") (isset .Site.Params "feathericonscdn") (eq .Site.Params.featherIconsCDN true) -}}
|
||||
{{ if and (isset .Site.Params "social") (.Site.Params.useCDN | default false) -}}
|
||||
<script src="https://cdn.jsdelivr.net/npm/feather-icons/dist/feather.min.js"></script>
|
||||
{{- else if (isset .Site.Params "social") -}}
|
||||
<script src="{{ .Site.BaseURL }}js/feather.min.js"></script>
|
||||
{{ end }}
|
||||
<link href="https://fonts.googleapis.com/css2?family=Fira+Sans&display=swap" rel="stylesheet">
|
||||
<link href="https://fonts.googleapis.com/css?family=Roboto+Mono" rel="stylesheet">
|
||||
{{ if .Site.Params.useCDN | default false -}}
|
||||
<link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:ital,wght@1,500&display=swap" rel="stylesheet">
|
||||
<link href="https://fonts.googleapis.com/css2?family=Fira+Sans&display=swap" rel="stylesheet">
|
||||
<link href="https://fonts.googleapis.com/css?family=Roboto+Mono" rel="stylesheet">
|
||||
{{- else -}}
|
||||
<link href="{{ .Site.BaseURL }}css/fonts.css" rel="stylesheet">
|
||||
{{ end }}
|
||||
<link rel="stylesheet" type="text/css" media="screen" href="{{ .Site.BaseURL }}css/main.css" />
|
||||
{{- if or (eq .Site.Params.mode "auto") (eq .Site.Params.mode "dark") -}}
|
||||
<link rel="stylesheet" type="text/css" href="{{ .Site.BaseURL }}css/dark.css" {{ if eq .Site.Params.mode "auto" }}media="(prefers-color-scheme: dark)"{{ end }} />
|
||||
|
Reference in New Issue
Block a user