aboutsummaryrefslogtreecommitdiff
path: root/layouts/partials/head.html
diff options
context:
space:
mode:
authorolOwOlo <26087907+olOwOlo@users.noreply.github.com>2017-09-12 23:59:08 +0800
committerolOwOlo <26087907+olOwOlo@users.noreply.github.com>2017-09-12 23:59:08 +0800
commit5fb5a658e8ec8f26c4cb67bc306d1827b781962c (patch)
tree3169aaebffb47ab817966a2b07da890855d268fc /layouts/partials/head.html
parent8e36a302cec6df297c00be4555ea0a6d8bd20114 (diff)
feat: config public cdn
deprecated bootcdn param
Diffstat (limited to 'layouts/partials/head.html')
-rw-r--r--layouts/partials/head.html10
1 files changed, 6 insertions, 4 deletions
diff --git a/layouts/partials/head.html b/layouts/partials/head.html
index 66d34eb..5a9ed21 100644
--- a/layouts/partials/head.html
+++ b/layouts/partials/head.html
@@ -53,8 +53,10 @@
<!-- Styles -->
<link href="{{ "dist/even.min.css?v=2.5.0" | relURL }}" rel="stylesheet">
{{ if .Site.Params.bootcdn -}}
- {{ if .Site.Params.fancybox }}<link href="https://cdn.bootcss.com/fancybox/3.1.20/jquery.fancybox.min.css" rel="stylesheet">{{ end }}
-{{ else -}}
+ {{ if .Site.Params.fancybox }}<link href="https://cdn.bootcss.com/fancybox/3.1.20/jquery.fancybox.min.css" rel="stylesheet" crossorigin="anonymous">{{ end }}
+{{- else if .Site.Params.publicCDN.enable -}}
+ {{ if .Site.Params.fancybox }}{{ .Site.Params.publicCDN.fancyboxCss | safeHTML }}{{ end }}
+{{- else -}}
{{ if .Site.Params.fancybox }}<link href="{{ "lib/fancybox/jquery.fancybox-3.1.20.min.css" | relURL }}" rel="stylesheet">{{ end }}
{{- end }}
@@ -66,6 +68,6 @@
<!-- Polyfill for old browsers -->
{{ `<!--[if lt IE 9]>
- <script src="https://cdn.bootcss.com/html5shiv/3.7.3/html5shiv.min.js"></script>
- <script src="https://cdn.bootcss.com/respond.js/1.4.2/respond.min.js"></script>
+ <script src="https://cdn.jsdelivr.net/npm/html5shiv@3.7.3/dist/html5shiv.min.js" integrity="sha256-9uAoNWHdszsUDhSXf/rVcWOqKPfi5/8V5R4UdbZle2A=" crossorigin="anonymous"></script>
+ <script src="https://cdn.jsdelivr.net/npm/respond.js@1.4.2/dest/respond.min.js" crossorigin="anonymous"></script>
<![endif]-->` | safeHTML }}