mirror of
https://github.com/tiennm99/HugoBlox-kit.git
synced 2026-10-10 12:13:11 +00:00
feat: support fullstops in widget names
Supports Java package naming convention for unique widget names.
This commit is contained in:
1 parent
6d04dbe81a
commit
35287c2391
1 file changed
+3
-1
@@ -90,7 +90,9 @@
|
||||
{{ $use_container = false }}
|
||||
{{ end }}
|
||||
|
||||
<section id="{{$hash_id}}" class="home-section {{printf "wg-%s" (replace $widget "_" "-")}} {{if $bg.text_color_light}}dark{{end}} {{if $bg.image}} bg-image{{if ($bg.image_parallax | default true) }} parallax{{end}}{{end}} {{with $css_classes}}{{.}}{{end}}" {{with $style}}style="{{. | safeCSS}}"{{end}} {{print $extra_attributes | safeHTMLAttr}}>
|
||||
{{ $widget_class := printf "wg-%s" (replace (replace $widget "." "-") "_" "-") }}
|
||||
|
||||
<section id="{{$hash_id}}" class="home-section {{$widget_class}} {{if $bg.text_color_light}}dark{{end}} {{if $bg.image}} bg-image{{if ($bg.image_parallax | default true) }} parallax{{end}}{{end}} {{with $css_classes}}{{.}}{{end}}" {{with $style}}style="{{. | safeCSS}}"{{end}} {{print $extra_attributes | safeHTMLAttr}}>
|
||||
{{if $use_container}}<div class="container">{{end}}
|
||||
{{ partial $widget_path $widget_args }}
|
||||
{{if $use_container}}</div>{{end}}
|
||||
|
||||
Reference in new issue
Block a user