Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BREAKING - Revamps the kb tags 'toc' and 'tocEntry'/'tocLink' #1870

Merged
merged 2 commits into from
Nov 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 11 additions & 7 deletions src/main/resources/default/taglib/k/toc.html.pasta
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
<i:arg type="String" name="headingKey" default="KnowledgeBase.tableOfContent.heading" description="Contains the i18n key for a localised heading." />
<i:arg type="String" name="heading" default="@i18n(headingKey)" description="Contains the heading, defaulting to a localised generic string like &quot;Table of Content&quot;."/>
<i:arg name="headingKey"
type="String"
default="KnowledgeBase.tableOfContent.heading"
description="Contains the i18n key for a localised heading."/>
<i:arg name="heading"
type="String"
default="@i18n(headingKey)"
description="Contains the heading, defaulting to a localised generic string like &quot;Table of Content&quot;."/>

<i:pragma name="description">
Renders a table of content uniformly.
</i:pragma>

<k:section heading="@heading" anchor="toc">
<ul class="mt-3">
<i:render name="body"/>
</ul>
</k:section>
<t:navbox label="@heading">
<i:render name="body"/>
</t:navbox>
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,6 @@
Renders an entry for the table of content. Should be used within the k:toc tag.
</i:pragma>

<li class="mt-2">
<a href="@link"><i:render name="body"/></a>
</li>
<t:navboxLink url="@link">
<i:render name="body"/>
</t:navboxLink>