fix(code): repeated initialization of the code tab in the encryption page

This commit is contained in:
Cell
2026-03-21 00:03:07 +08:00
parent b09555981b
commit d9e45154ff
5 changed files with 15 additions and 17 deletions
@@ -71,12 +71,14 @@
{{- $isFirst := not (.Page.Store.Get $groupKey) -}}
{{- if $isFirst -}}
{{- .Page.Store.Set $groupKey true -}}
{{- else -}}
{{- $targetClass = add $targetClass " d-none" -}}
{{- end -}}
{{- $hidden := cond $isFirst "" " data-hidden" -}}
{{- $wrapper =
replace $wrapper
(printf `class="%s"` $class)
(printf `class="%s" data-tab-group="%s" data-tab-title="%s"%s` $class $config.group $tabTitle $hidden) -}}
(printf `class="%s" data-tab-title="%s"` $class $tabTitle)
-}}
{{- end -}}
{{- if ne .Options.linenostart nil -}}
{{- $wrapper =