Skip to content

Commit ad69374

Browse files
fabianrbzlena-larionova
authored andcommitted
fix(indices): liquid variables in titles
1 parent 5a7db3b commit ad69374

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

app/_includes/indices.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
{% for section in group.sections %}{% unless section.hidden %}
1515
<div class="flex flex-col gap-5 heading-section card p-6 rounded-lg shadow-primary">
1616
{% if section.title %}
17-
<h3 id="{% if group.title %}{{ group.title | slugify }}--{% endif %}{{ section.title | slugify }}" class="always-link mb-2" data-skip-process-heading-id="true">{{ section.title | liquify }}</h3>
17+
<h3 id="{% if group.title %}{{ group.title | liquify | slugify }}--{% endif %}{{ section.title | liquify | slugify }}" class="always-link mb-2" data-skip-process-heading-id="true">{{ section.title | liquify }}</h3>
1818
{% endif %}
1919

2020
<div class="content">

app/_plugins/generators/indices.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -219,7 +219,8 @@ def template
219219
def render(index, groups, site)
220220
context = {
221221
'index' => index,
222-
'groups' => groups
222+
'groups' => groups,
223+
'site' => site.config
223224
}
224225
Liquid::Template.parse(template).render(context, registers: { site: site })
225226
end

0 commit comments

Comments
 (0)