From 2430f46a9948b38b06880606a95dec357d01f619 Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Sun, 5 May 2024 18:11:56 +0200 Subject: feat: render markdown in option descriptions --- frontend/templates/blocks/options.gotmpl | 20 ++++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) (limited to 'frontend/templates/blocks') diff --git a/frontend/templates/blocks/options.gotmpl b/frontend/templates/blocks/options.gotmpl index d5171c3..1172e52 100644 --- a/frontend/templates/blocks/options.gotmpl +++ b/frontend/templates/blocks/options.gotmpl @@ -1,28 +1,32 @@ {{ define "results" }} - {{- range $opt, $data := .Results }} -
+ {{- range .Results }} +
- {{ $opt }} + {{ .Option }}

- {{ $data.Description }} + {{ HTML .Description.HTML }}

- {{- with $data.Type }} + {{- with .Type }}
Type
{{ . }}
{{- end }} - {{- with $data.Default }} + {{- with .Default }}
Default
{{ .Text }}
{{- end }} - {{- with $data.Example }} + {{- with .Example }} {{- if .Text }}
Example
{{ .Text }}
{{- end }} {{- end }} - {{- with $data.Declarations }} + {{- with .RelatedPackages.HTML }} +
Related Packages
+
{{ . }}
+ {{- end }} + {{- with .Declarations }}
Declared
{{- range . }}
-- cgit 1.4.1