summaryrefslogtreecommitdiff
path: root/layouts/_partials/head/css.html
blob: 853b05fe9238bb9f5ee14d368324aca51d28dd31 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
<!-- Google Fonts -->
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
{{ if eq .Site.Language.Lang "zh" }}
<link href="https://fonts.googleapis.com/css2?family=Noto+Serif+SC:wght@200..900&family=Noto+Serif:ital,wght@0,100..900;1,100..900&display=swap" rel="stylesheet">
{{ else }}
<link href="https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400..900;1,400..900&display=swap" rel="stylesheet">
{{ end }}

<!-- Aplayer -->
{{ if .Params.aplayer }}
{{ with resources.Get "css/aplayer.css" }}
<style>{{ .Content | safeCSS }}</style>
{{ end }}
{{ end }}

<!-- Extra -->
{{ range .Site.Params.extraCSSFiles -}}
<link
    rel="stylesheet"
    href="{{ $.Site.Params.staticPrefix }}{{ . | relURL }}"
/>
{{- end }}

<!-- theme css -->
{{ with resources.Get "css/uno.css" | minify }}
<style>{{ .Content | safeCSS }}</style>
{{ end }}

{{ with resources.Get "css/main.scss" | css.Sass | minify }}
<style>{{ .Content | safeCSS }}</style>
{{ end }}