Skip to content

Commit b75f637

Browse files
authored
docs: clean up example.html (twbs#39528)
1 parent 21624b9 commit b75f637

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

site/layouts/shortcodes/example.html

+7-7
Original file line numberDiff line numberDiff line change
@@ -13,23 +13,23 @@
1313
{{- $id := .Get "id" -}}
1414
{{- $class := .Get "class" -}}
1515
{{- $lang := .Get "lang" | default "html" -}}
16-
{{- $stackblitz_add_js := .Get "stackblitz_add_js" | default false -}}
1716
{{- $show_markup := .Get "show_markup" | default true -}}
1817
{{- $show_preview := .Get "show_preview" | default true -}}
19-
{{- $input := .Inner -}}
18+
{{- $stackblitz_add_js := .Get "stackblitz_add_js" | default false -}}
19+
2020
{{- $content := .Inner -}}
2121

2222
<div class="bd-example-snippet bd-code-snippet">
23-
{{- if eq $show_preview true -}}
23+
{{- if eq $show_preview true }}
2424
<div{{ with $id }} id="{{ . }}"{{ end }} class="bd-example m-0 border-0{{ with $class }} {{ . }}{{ end }}">
25-
{{- $input -}}
25+
{{ $content }}
2626
</div>
27-
{{- end -}}
27+
{{- end }}
2828

2929
{{- if eq $show_markup true -}}
3030
{{- if eq $show_preview true -}}
3131
<div class="d-flex align-items-center highlight-toolbar ps-3 pe-2 py-1 border-0 border-top border-bottom">
32-
<small class="font-monospace text-body-secondary text-uppercase">{{- $lang -}}</small>
32+
<small class="font-monospace text-body-secondary text-uppercase">{{ $lang }}</small>
3333
<div class="d-flex ms-auto">
3434
<button type="button" class="btn-edit text-nowrap"{{ with $stackblitz_add_js }} data-sb-js-snippet="{{ $stackblitz_add_js }}"{{ end }} title="Try it on StackBlitz">
3535
<svg class="bi" aria-hidden="true"><use xlink:href="#lightning-charge-fill"/></svg>
@@ -45,5 +45,5 @@
4545
{{- $content = replaceRE `<img class="bd-placeholder-img(?:-lg)?(?: *?bd-placeholder-img-lg)? ?(.*?)".*?>` `<img src="..." class="$1" alt="...">` $content -}}
4646
{{- $content = replaceRE ` (class=" *?")` "" $content -}}
4747
{{- highlight (trim $content "\n") $lang "" -}}
48-
{{- end -}}
48+
{{- end }}
4949
</div>

0 commit comments

Comments
 (0)