{{ if or (eq .Site.Params.colorScheme "auto") (eq .Site.Params.colorScheme "dark") }}
  {{ if hugo.IsServer }}
    {{ $cssOpts := (dict "targetPath" "css/coder-dark.css" "enableSourceMap" true ) }}
    {{ $styles := resources.Get "scss/coder-dark.scss" | resources.ExecuteAsTemplate "style.coder-dark.css" . | toCSS $cssOpts }}
    <link rel="stylesheet" href="{{ $styles.RelPermalink }}" media="screen">
  {{ else }}
    {{ $cssOpts := (dict "targetPath" "css/coder-dark.css" ) }}
    {{ $styles := resources.Get "scss/coder-dark.scss" | resources.ExecuteAsTemplate "style.coder-dark.css" . | toCSS $cssOpts | resources.Minify | resources.Fingerprint }}
    <link rel="stylesheet" href="{{ $styles.RelPermalink }}" integrity="{{ $styles.Data.Integrity }}" crossorigin="anonymous" media="screen" />
  {{ end }}
{{ end }}
