aboutsummaryrefslogtreecommitdiffstats
path: root/vendor/twbs/bootstrap/site/layouts/partials/stylesheet.html
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/twbs/bootstrap/site/layouts/partials/stylesheet.html')
-rw-r--r--vendor/twbs/bootstrap/site/layouts/partials/stylesheet.html22
1 files changed, 12 insertions, 10 deletions
diff --git a/vendor/twbs/bootstrap/site/layouts/partials/stylesheet.html b/vendor/twbs/bootstrap/site/layouts/partials/stylesheet.html
index 7a5b077bc..9969ee44f 100644
--- a/vendor/twbs/bootstrap/site/layouts/partials/stylesheet.html
+++ b/vendor/twbs/bootstrap/site/layouts/partials/stylesheet.html
@@ -1,25 +1,27 @@
-<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@docsearch/css@3">
-
-{{ if eq hugo.Environment "production" -}}
+{{ if hugo.IsProduction -}}
{{ if eq .Page.Params.direction "rtl" -}}
-<link href="/docs/{{ .Site.Params.docs_version }}/dist/css/bootstrap.rtl.min.css" rel="stylesheet" {{ printf "integrity=%q" .Site.Params.cdn.css_rtl_hash | safeHTMLAttr }} crossorigin="anonymous">
+<link href="/docs/{{ .Site.Params.docs_version }}/dist/css/bootstrap.rtl.min.css" rel="stylesheet" {{ printf "integrity=%q" .Site.Params.cdn.css_rtl_hash | safeHTMLAttr }}>
{{- else -}}
-<link href="/docs/{{ .Site.Params.docs_version }}/dist/css/bootstrap.min.css" rel="stylesheet" {{ printf "integrity=%q" .Site.Params.cdn.css_hash | safeHTMLAttr }} crossorigin="anonymous">
+<link href="/docs/{{ .Site.Params.docs_version }}/dist/css/bootstrap.min.css" rel="stylesheet" {{ printf "integrity=%q" .Site.Params.cdn.css_hash | safeHTMLAttr }}>
{{- end -}}
{{- else -}}
<link href="/docs/{{ .Site.Params.docs_version }}/dist/css/bootstrap{{ if eq .Page.Params.direction "rtl" }}.rtl{{ end }}.css" rel="stylesheet">
{{- end }}
{{- if (ne .Page.Layout "examples") }}
-{{- $targetDocsCssPath := path.Join "/docs" .Site.Params.docs_version "assets/css/docs.css" -}}
-{{- $sassOptions := dict "targetPath" $targetDocsCssPath "outputStyle" "expanded" "precision" 6 -}}
+{{- $sassOptions := dict "outputStyle" "expanded" "precision" 6 -}}
{{- $postcssOptions := dict "use" "autoprefixer" "noMap" true -}}
-{{ if eq hugo.Environment "production" -}}
+{{- $targetDocsCssPath := path.Join "/docs" .Site.Params.docs_version "assets/css/docs.css" -}}
+{{- $targetSearchCssPath := path.Join "/docs" .Site.Params.docs_version "assets/css/search.css" -}}
+
+{{ if hugo.IsProduction -}}
{{- $sassOptions = merge $sassOptions (dict "outputStyle" "compressed") -}}
{{- end -}}
-{{- $style := resources.Get "scss/docs.scss" | toCSS $sassOptions | postCSS $postcssOptions }}
+{{- $docsCss := resources.Get "scss/docs.scss" | toCSS (merge (dict "targetPath" $targetDocsCssPath) $sassOptions) | postCSS $postcssOptions -}}
+{{- $searchCss := resources.Get "scss/search.scss" | toCSS (merge (dict "targetPath" $targetSearchCssPath) $sassOptions) | postCSS $postcssOptions -}}
-<link href="{{ $style.Permalink | relURL }}" rel="stylesheet">
+<link href="{{ $docsCss.RelPermalink }}" rel="stylesheet">
+<link href="{{ $searchCss.RelPermalink }}" rel="stylesheet">
{{- end }}