2018-05-05 16:00:51 +00:00
{{ define "side-menu" }}
2024-08-14 00:15:13 +00:00
{{ partial "docs/side-menu.html" . }}
2018-05-05 16:00:51 +00:00
{{ end }}
2020-06-15 19:09:57 +00:00
{{ define "main" }}
2024-03-12 23:41:24 +00:00
{{ partial "deprecation-warning.html" . }}
2018-05-05 16:00:51 +00:00
< h1 > {{ .Title }}< / h1 >
2019-04-17 00:36:01 +00:00
< p > {{ T "layouts_docs_glossary_description" }}< / p >
2018-05-05 16:00:51 +00:00
< div id = "tag-container" >
2024-08-14 00:15:13 +00:00
< p > < em > {{ T "layouts_docs_glossary_filter" }}< / em > < / p >
2018-05-05 16:00:51 +00:00
< div class = "tag-description invisible" id = "placeholder" > .< / div >
2019-02-05 16:33:23 +00:00
{{ range (index site.Data "canonical-tags") }}
2018-05-05 16:00:51 +00:00
< div class = "tag-description hide" id = "{{ printf " tag- % s-description " . id } } " >
2024-08-14 00:15:13 +00:00
{{ T (printf "layout_docs_glossary_%s_description" .id) }}
2018-05-05 16:00:51 +00:00
< / div >
{{ end }}
2022-11-19 14:55:43 +00:00
{{ $sorted_tags := sort (index site.Data "canonical-tags") "id" }}
2018-05-05 16:00:51 +00:00
{{ range $sorted_tags }}
{{ $full_tag_name := printf "tag-%s" .id }}
< span id = "{{ $full_tag_name }}" class = "tag-option canonical-tag" data-target = "{{ $full_tag_name }}" >
2022-11-19 14:55:43 +00:00
< a href = "javascript:void(0)" > {{ T (printf "layout_docs_glossary_%s_name" .id) }}< / a >
2018-05-05 16:00:51 +00:00
< / span >
{{ end }}
2019-04-17 00:36:01 +00:00
< span class = "tag-option" > < a id = "select-all-tags" href = "javascript:void(0)" > {{ T "layouts_docs_glossary_select_all" }}< / a > < / span >
< span class = "tag-option" > < a id = "deselect-all-tags" href = "javascript:void(0)" > {{ T "layouts_docs_glossary_deselect_all" }}< / a > < / span >
2018-05-05 16:00:51 +00:00
< / div >
2024-08-14 00:15:13 +00:00
< p id = "glossary-details-before" > {{ T "layouts_docs_glossary_click_details_before" }} < a href = "javascript:void(0)" class = "no-underline" > [+]< / a > {{ T "layouts_docs_glossary_click_details_after" }}< / p >
2018-10-01 19:38:37 +00:00
{{ partial "docs/glossary-terms.html" . }}
{{ $glossary_items := $.Scratch.Get "glossary_items" }}
{{ with $glossary_items }}
{{ $glossary_terms := sort . "Title" "asc" }}
2024-08-14 00:15:13 +00:00
< ul class = "glossary-terms" >
2018-05-05 16:00:51 +00:00
{{ range $glossary_terms }}
{{ $.Scratch.Set "tag_classes" "" }}
{{ range .Params.tags }}
{{ $.Scratch.Add "tag_classes" (printf "tag-%s " .) }}
{{ end }}
{{ $term_identifier := (printf "term-%s" .Params.id) }}
< li class = "{{ $.Scratch.Get " tag_classes " } } hide " data-show-count = "0" >
< div id = "{{ $term_identifier }}" class = "term-anchor" > < / div >
2024-08-14 00:15:13 +00:00
< div class = "term-name" data-pagefind-index-attrs = "term" > < span class = "glossary-term-name" > {{ .Title }}< / span > < a href = "{{ printf " # % s " $ term_identifier } } " class = "permalink" >
{{- with resources.Get "icons/link.svg" -}}
{{- .Content | safeHTML -}}
{{- end -}}
< / a > < / div >
< div class = "term-definition" >
2018-05-05 16:00:51 +00:00
{{ with .Params.aka }}
2024-08-14 00:15:13 +00:00
{{ T "layouts_docs_glossary_aka" }}: < span class = "glossary-aka" > {{ delimit . ", " }}< / span >
< br / >
2018-05-05 16:00:51 +00:00
{{ end }}
< span class = "preview-text" > {{ .Summary }} < a href = "javascript:void(0)" class = "click-controller no-underline" data-target = "{{ .Params.id }}" > [+]< / a > < / span >
< div id = "{{ .Params.id }}" class = "hide" >
{{ .Content | strings.TrimPrefix .Summary | safeHTML }}
< / div >
< / div >
< / li >
{{ end }}
< / ul >
{{ end }}
2018-10-01 19:38:37 +00:00
{{ end }}
2018-05-05 16:00:51 +00:00