mirror of
https://github.com/dillonzq/LoveIt.git
synced 2024-11-15 03:16:30 +01:00
8 lines
No EOL
489 B
HTML
8 lines
No EOL
489 B
HTML
{{- $content := .Inner | .Page.RenderString -}}
|
|
{{- $id := partial "function/id.html" (dict "content" $content) -}}
|
|
{{- $tag := .Get 1 | default "div" -}}
|
|
{{- $style := .Get 0 | printf "#%s{%s}" $id -}}
|
|
{{- $res := resources.FromString "css/shortcode/style.scss" $style -}}
|
|
{{- $res = $res | toCSS (dict "targetPath" "css/shortcode/style.css" "outputStyle" "compressed") -}}
|
|
{{- printf `<%s id="%s">%s</%s>` $tag $id $content $tag | safeHTML -}}
|
|
<style>{{ $res.Content | safeCSS }}</style> |