2020-04-21 16:55:06 +02:00
|
|
|
{{- $params := .Scratch.Get "params" -}}
|
|
|
|
{{- $cdn := .Scratch.Get "cdn" | default dict -}}
|
|
|
|
{{- $fingerprint := .Scratch.Get "fingerprint" -}}
|
|
|
|
{{- $config := (.Scratch.Get "this").config -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
|
2020-04-15 09:46:50 +02:00
|
|
|
{{- /* Search */ -}}
|
2020-05-04 07:20:01 +02:00
|
|
|
{{- if .Site.Params.search | and .Site.Params.search.enable -}}
|
|
|
|
{{- $search := .Site.Params.search -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.autocompleteJS | default "lib/autocomplete/autocomplete.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-05-04 07:20:01 +02:00
|
|
|
{{- $config = dict "maxResultLength" $search.maxResultLength "snippetLength" $search.snippetLength "highlightTag" $search.highlightTag "noResultsFound" (T "noResultsFound") | dict "search" | merge $config -}}
|
|
|
|
{{- if eq $search.type "lunr" -}}
|
2020-04-15 09:46:50 +02:00
|
|
|
{{- with .Site.Home.OutputFormats.Get "json" -}}
|
2020-05-04 07:20:01 +02:00
|
|
|
{{- $config = dict "type" "lunr" "lunrIndexURL" .RelPermalink | dict "search" | merge $config -}}
|
2020-04-15 09:46:50 +02:00
|
|
|
{{- end -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.lunrJS | default "lib/lunr/lunr.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-05-06 17:50:10 +02:00
|
|
|
{{- if T "lunrLanguageLib" -}}
|
2020-05-04 07:20:01 +02:00
|
|
|
{{- $config = T "lunrLanguageCode" | dict "lunrLanguageCode" | dict "search" | merge $config -}}
|
2020-05-06 17:50:10 +02:00
|
|
|
{{- with T "lunrSegmentitLib" -}}
|
|
|
|
{{- $config = dict "lunrSegmentitURL" (resources.Get .).RelPermalink | dict "search" | merge $config -}}
|
2020-04-15 09:46:50 +02:00
|
|
|
{{- end -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" "lib/lunr/lunr.stemmer.support.js" "Minify" true "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
|
|
|
{{- dict "Source" (T "lunrLanguageLib") "Minify" true "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-04-15 09:46:50 +02:00
|
|
|
{{- end -}}
|
2020-05-04 07:20:01 +02:00
|
|
|
{{- else if eq $search.type "algolia" -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.algoliasearchJS | default "lib/algoliasearch/algoliasearch-lite.umd.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-05-04 07:20:01 +02:00
|
|
|
{{- $config = dict "type" "algolia" "algoliaIndex" $search.algolia.index "algoliaAppID" $search.algolia.appID "algoliaSearchKey" $search.algolia.searchKey | dict "search" | merge $config -}}
|
2020-02-17 19:53:07 +01:00
|
|
|
{{- end -}}
|
|
|
|
{{- end -}}
|
|
|
|
|
2020-02-24 10:53:08 +01:00
|
|
|
{{- /* lazysizes */ -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.lazysizesJS | default "lib/lazysizes/lazysizes.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-02-24 10:00:39 +01:00
|
|
|
|
2020-04-26 20:27:26 +02:00
|
|
|
{{- /* twemoji */ -}}
|
|
|
|
{{- if $params.twemoji -}}
|
|
|
|
{{- $source := $cdn.twemojiJS | default "lib/twemoji/twemoji.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-04-26 20:27:26 +02:00
|
|
|
{{- $config = dict "twemoji" true | merge $config -}}
|
|
|
|
{{- end -}}
|
|
|
|
|
2022-05-11 23:35:34 +02:00
|
|
|
{{- /* lightgallery */ -}}
|
2020-04-21 16:55:06 +02:00
|
|
|
{{- if $params.lightgallery -}}
|
2022-06-22 17:57:53 +02:00
|
|
|
{{- $source := $cdn.lightgalleryCSS | default "lib/lightgallery/css/lightgallery-bundle.min.css" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/style.html" -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.lightgalleryJS | default "lib/lightgallery/lightgallery.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2022-06-22 17:57:53 +02:00
|
|
|
{{- $source := $cdn.lightgalleryThumbnailJS | default "lib/lightgallery/plugins/thumbnail/lg-thumbnail.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2022-06-22 17:57:53 +02:00
|
|
|
{{- $source := $cdn.lightgalleryZoomJS | default "lib/lightgallery/plugins/zoom/lg-zoom.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2022-05-11 23:35:34 +02:00
|
|
|
{{- $config = dict "lightgallery" true | merge $config -}}
|
2020-04-15 09:46:50 +02:00
|
|
|
{{- end -}}
|
|
|
|
|
2020-04-25 21:25:10 +02:00
|
|
|
{{- $code := $params.code | default dict -}}
|
|
|
|
{{- $config = cond (ne $code.maxShownLines nil) $code.maxShownLines 10 | dict "maxShownLines" | dict "code" | merge $config -}}
|
|
|
|
|
2020-04-18 14:54:54 +02:00
|
|
|
{{- /* clipboard.js */ -}}
|
2020-04-25 21:25:10 +02:00
|
|
|
{{- if ne $code.copy false -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.clipboardJS | default "lib/clipboard/clipboard.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-04-25 21:25:10 +02:00
|
|
|
{{- $config = T "copyToClipboard" | dict "copyTitle" | dict "code" | merge $config -}}
|
2020-04-18 14:54:54 +02:00
|
|
|
{{- end -}}
|
|
|
|
|
2020-04-15 09:46:50 +02:00
|
|
|
{{- /* Sharer.js */ -}}
|
2020-04-21 16:55:06 +02:00
|
|
|
{{- if $params.share.enable -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.sharerJS | default "lib/sharer/sharer.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
{{- end -}}
|
|
|
|
|
2020-02-24 10:53:08 +01:00
|
|
|
{{- /* TypeIt */ -}}
|
2020-04-21 16:55:06 +02:00
|
|
|
{{- with (.Scratch.Get "this").typeitMap -}}
|
2020-05-04 07:20:01 +02:00
|
|
|
{{- $typeit := $.Site.Params.typeit -}}
|
2022-05-08 05:55:58 +02:00
|
|
|
{{- $source := $cdn.typeitJS | default "lib/typeit/index.umd.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" $.Scratch "Data" | partial "scratch/script.html" -}}
|
2020-05-04 07:20:01 +02:00
|
|
|
{{- $config = dict "speed" $typeit.speed "cursorSpeed" $typeit.cursorSpeed "cursorChar" $typeit.cursorChar "duration" $typeit.duration "data" . | dict "typeit" | merge $config -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
{{- end -}}
|
|
|
|
|
2020-02-24 10:53:08 +01:00
|
|
|
{{- /* KaTeX */ -}}
|
2020-05-12 16:40:49 +02:00
|
|
|
{{- $math := $params.math -}}
|
|
|
|
{{- if eq $math true -}}
|
|
|
|
{{- $math = .Site.Params.page.math | default dict -}}
|
|
|
|
{{- else if eq $math false -}}
|
|
|
|
{{- $math = dict "enable" false -}}
|
|
|
|
{{- end -}}
|
|
|
|
{{- if $math.enable -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.katexCSS | default "lib/katex/katex.min.css" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/style.html" -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.katexJS | default "lib/katex/katex.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2022-05-25 17:33:36 +02:00
|
|
|
{{- $source := $cdn.katexAutoRenderJS | default "lib/katex/contrib/auto-render.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-02-16 19:32:52 +01:00
|
|
|
{{- if $math.copyTex -}}
|
2022-05-25 17:33:36 +02:00
|
|
|
{{- $source := $cdn.katexCopyTexJS | default "lib/katex/contrib/copy-tex.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
{{- end -}}
|
|
|
|
{{- if $math.mhchem -}}
|
2022-05-25 17:33:36 +02:00
|
|
|
{{- $source := $cdn.katexMhchemJS | default "lib/katex/contrib/mhchem.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
{{- end -}}
|
2022-05-04 20:49:12 +02:00
|
|
|
{{- $delimiters := slice (dict "left" "$$" "right" "$$" "display" true) (dict "left" "\\[" "right" "\\]" "display" true) -}}
|
2022-05-04 20:34:17 +02:00
|
|
|
{{- $delimiters = $delimiters | append (dict "left" "\\begin{equation}" "right" "\\end{equation}" "display" true) -}}
|
|
|
|
{{- $delimiters = $delimiters | append (dict "left" "\\begin{equation*}" "right" "\\end{equation*}" "display" true) -}}
|
|
|
|
{{- $delimiters = $delimiters | append (dict "left" "\\begin{align}" "right" "\\end{align}" "display" true) -}}
|
|
|
|
{{- $delimiters = $delimiters | append (dict "left" "\\begin{align*}" "right" "\\end{align*}" "display" true) -}}
|
|
|
|
{{- $delimiters = $delimiters | append (dict "left" "\\begin{alignat}" "right" "\\end{alignat}" "display" true) -}}
|
|
|
|
{{- $delimiters = $delimiters | append (dict "left" "\\begin{alignat*}" "right" "\\end{alignat*}" "display" true) -}}
|
|
|
|
{{- $delimiters = $delimiters | append (dict "left" "\\begin{gather}" "right" "\\end{gather}" "display" true) -}}
|
|
|
|
{{- $delimiters = $delimiters | append (dict "left" "\\begin{CD}" "right" "\\end{CD}" "display" true) -}}
|
|
|
|
{{- if and $math.blockLeftDelimiter $math.blockRightDelimiter -}}
|
|
|
|
{{- $delimiters = $delimiters | append (dict "left" $math.blockLeftDelimiter "right" $math.blockRightDelimiter "display" true) -}}
|
|
|
|
{{- end -}}
|
2022-05-04 20:49:12 +02:00
|
|
|
{{- $delimiters = $delimiters | append (dict "left" "$" "right" "$" "display" false) (dict "left" "\\(" "right" "\\)" "display" false) -}}
|
|
|
|
{{- if and $math.inlineLeftDelimiter $math.inlineRightDelimiter -}}
|
|
|
|
{{- $delimiters = $delimiters | append (dict "left" $math.inlineRightDelimiter "right" $math.inlineRightDelimiter "display" false) -}}
|
|
|
|
{{- end -}}
|
2020-05-04 07:20:01 +02:00
|
|
|
{{- $config = dict "strict" false "delimiters" $delimiters | dict "math" | merge $config -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
{{- end -}}
|
|
|
|
|
2020-02-24 10:53:08 +01:00
|
|
|
{{- /* mermaid */ -}}
|
2020-04-21 16:55:06 +02:00
|
|
|
{{- if (.Scratch.Get "this").mermaid -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.mermaidJS | default "lib/mermaid/mermaid.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2022-05-07 09:36:44 +02:00
|
|
|
{{- $_ := (resources.Get "lib/mermaid/mermaid.min.js.map").RelPermalink -}}
|
2020-02-27 13:14:40 +01:00
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- /* ECharts */ -}}
|
2020-04-21 16:55:06 +02:00
|
|
|
{{- if (.Scratch.Get "this").echarts -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.echartsJS | default "lib/echarts/echarts.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2022-05-10 07:24:16 +02:00
|
|
|
{{- $lightTheme := resources.Get "lib/echarts/theme/light.yml" | transform.Unmarshal -}}
|
|
|
|
{{- $darkTheme := resources.Get "lib/echarts/theme/dark.yml" | transform.Unmarshal -}}
|
|
|
|
{{- $config = dict "lightTheme" $lightTheme "darkTheme" $darkTheme | dict "echarts" | merge $config -}}
|
2020-03-21 09:59:23 +01:00
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- /* Mapbox GL */ -}}
|
2020-04-21 16:55:06 +02:00
|
|
|
{{- if (.Scratch.Get "this").mapbox -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.mapboxGLCSS | default "lib/mapbox-gl/mapbox-gl.min.css" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/style.html" -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.mapboxGLJS | default "lib/mapbox-gl/mapbox-gl.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
|
|
|
{{- dict "Source" "lib/mapbox-gl/mapbox-gl-language.js" "Minify" true "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-04-21 16:55:06 +02:00
|
|
|
{{- $config = dict "accessToken" $params.mapbox.accessToken "RTLTextPlugin" "https://api.mapbox.com/mapbox-gl-js/plugins/mapbox-gl-rtl-text/v0.2.0/mapbox-gl-rtl-text.js" | dict "mapbox" | merge $config -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- /* Music */ -}}
|
2020-04-21 16:55:06 +02:00
|
|
|
{{- if (.Scratch.Get "this").music -}}
|
2020-02-24 10:53:08 +01:00
|
|
|
{{- /* APlayer */ -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.aplayerCSS | default "lib/aplayer/APlayer.min.css" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/style.html" -}}
|
2020-04-27 19:38:22 +02:00
|
|
|
{{- $options := dict "targetPath" "lib/aplayer/dark.min.css" "enableSourceMap" true -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" "lib/aplayer/dark.scss" "ToCSS" $options "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/style.html" -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.aplayerJS | default "lib/aplayer/APlayer.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
|
2020-02-24 10:53:08 +01:00
|
|
|
{{- /* MetingJS */ -}}
|
2020-04-24 17:47:47 +02:00
|
|
|
{{- $source := $cdn.metingJS | default "lib/meting/Meting.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-05-13 15:19:39 +02:00
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- /* Cookie Consent */ -}}
|
|
|
|
{{- if .Site.Params.cookieconsent | and .Site.Params.cookieconsent.enable -}}
|
|
|
|
{{- $source := $cdn.cookieconsentCSS | default "lib/cookieconsent/cookieconsent.min.css" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/style.html" -}}
|
2020-05-13 15:19:39 +02:00
|
|
|
{{- $source := $cdn.cookieconsentJS | default "lib/cookieconsent/cookieconsent.min.js" -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" $source "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-05-13 15:19:39 +02:00
|
|
|
{{- $cookieconsentConfig := dict "popup" (dict "background" "#1aa3ff") "button" (dict "background" "#f0f0f0") | dict "theme" "edgeless" "palette" -}}
|
|
|
|
{{- $cookieconsentConfig = .Site.Params.cookieconsent | merge $cookieconsentConfig -}}
|
|
|
|
{{- $cookieconsentConfig = dict "message" ($cookieconsentConfig.content.message | default (T "cookieconsentMessage")) "dismiss" ($cookieconsentConfig.content.dismiss | default (T "cookieconsentDismiss")) "link" ($cookieconsentConfig.content.link | default (T "cookieconsentLink")) | dict "content" | merge $cookieconsentConfig -}}
|
|
|
|
{{- $config = $cookieconsentConfig | dict "cookieconsent" | merge $config -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
{{- end -}}
|
|
|
|
|
2020-05-13 16:12:51 +02:00
|
|
|
{{- range $params.library.css -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" . "Fingerprint" $fingerprint | dict "Scratch" $.Scratch "Data" | partial "scratch/style.html" -}}
|
2020-05-13 16:12:51 +02:00
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- range $params.library.js -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- dict "Source" . "Fingerprint" $fingerprint | dict "Scratch" $.Scratch "Data" | partial "scratch/script.html" -}}
|
2020-05-13 16:12:51 +02:00
|
|
|
{{- end -}}
|
|
|
|
|
2020-05-15 11:43:04 +02:00
|
|
|
{{- with (.Scratch.Get "this").styleArr -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- $content := delimit . "" -}}
|
|
|
|
{{- $path := substr (md5 $content) 0 6 | printf "css/%v" -}}
|
|
|
|
{{- $options := printf "%v.min.css" $path | dict "targetPath" -}}
|
|
|
|
{{- dict "Content" $content "Path" (printf "%v.scss" $path) "ToCSS" $options | dict "Scratch" $.Scratch "Data" | partial "scratch/style.html" -}}
|
2020-05-15 11:43:04 +02:00
|
|
|
{{- end -}}
|
|
|
|
|
|
|
|
{{- /* Config script */ -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- $config | jsonify | printf "window.config=%s;" | dict "Content" | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-05-15 11:43:04 +02:00
|
|
|
|
2020-02-24 13:34:00 +01:00
|
|
|
{{- /* Theme script */ -}}
|
2022-05-03 12:05:41 +02:00
|
|
|
{{- dict "Source" "js/theme.js" "Minify" true "Fingerprint" $fingerprint | dict "Scratch" .Scratch "Data" | partial "scratch/script.html" -}}
|
2020-02-24 13:34:00 +01:00
|
|
|
|
2020-05-15 11:43:04 +02:00
|
|
|
{{- with (.Scratch.Get "this").scriptArr -}}
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- delimit . "\n" | dict "Content" | dict "Scratch" $.Scratch "Data" | partial "scratch/script.html" -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
{{- end -}}
|
|
|
|
|
2020-05-15 11:43:04 +02:00
|
|
|
{{- range (.Scratch.Get "this").style -}}
|
|
|
|
{{- partial "plugin/style.html" . -}}
|
2020-04-28 20:34:28 +02:00
|
|
|
{{- end -}}
|
|
|
|
|
2020-04-21 16:55:06 +02:00
|
|
|
{{- range (.Scratch.Get "this").script -}}
|
2020-04-15 09:46:50 +02:00
|
|
|
{{- partial "plugin/script.html" . -}}
|
2020-02-14 14:09:21 +01:00
|
|
|
{{- end -}}
|
2020-02-16 17:41:08 +01:00
|
|
|
|
2020-05-28 11:05:37 +02:00
|
|
|
{{- partial "plugin/analytics.html" . -}}
|