Remove paige.content.{class,hide} params
This commit is contained in:
@@ -245,8 +245,6 @@ paige:
|
|||||||
utterances: # See https://utteranc.es
|
utterances: # See https://utteranc.es
|
||||||
github_repo: ""
|
github_repo: ""
|
||||||
content:
|
content:
|
||||||
class: "mw-100 paige-content"
|
|
||||||
hide: false
|
|
||||||
max_width: ""
|
max_width: ""
|
||||||
credit:
|
credit:
|
||||||
data:
|
data:
|
||||||
|
@@ -8,15 +8,10 @@
|
|||||||
{{ $page = $params.page }}
|
{{ $page = $params.page }}
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
{{ $class := $page.Param "paige.content.class" | default "mw-100 paige-content" }}
|
{{ $content := cond ($fullpages | not) ($page.Content | replaceRE `(<h[1-6] id="([^"]+)".+)(</h[1-6]+>)` (printf `${1}<a aria-label="%v" class="paige-header-link" href="#${2}">#</a>${3}` (i18n "paige_aria_section_link")) | safeHTML) $page.Content }}
|
||||||
{{ $content := "" }}
|
|
||||||
|
|
||||||
{{ if $page.Param "paige.content.hide" | not }}
|
|
||||||
{{ $content = cond ($fullpages | not) ($page.Content | replaceRE `(<h[1-6] id="([^"]+)".+)(</h[1-6]+>)` (printf `${1}<a aria-label="%v" class="paige-header-link" href="#${2}">#</a>${3}` (i18n "paige_aria_section_link")) | safeHTML) $page.Content }}
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
{{ with $content }}
|
{{ with $content }}
|
||||||
<section class="{{ $class }}">
|
<section class="mw-100 paige-content">
|
||||||
{{ . }}
|
{{ . }}
|
||||||
</section>
|
</section>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
Reference in New Issue
Block a user