Streamline full page sidebar with blog post sidebar

Add the table of content in same way with proper linking to sections
(content elements) and summary feature.
This commit is contained in:
Daniel Siepmann 2022-01-05 09:37:36 +01:00
parent 41c70fde4b
commit ed2f6b2bc4

View file

@ -40,16 +40,20 @@
<f:section name="TableOfContent">
<nav>
<h1>Table of Content</h1>
<details open>
<summary>
<h2>Table of Content</h2>
</summary>
<ol>
<f:for each="{pageContent}" as="contentEntry">
<f:if condition="{contentEntry.data.header}">
<li>
<a href="#c{contentEntry.data.uid}">{contentEntry.data.header}</a>
<a href="#{contentEntry.data.header -> f:format.id()}">{contentEntry.data.header}</a>
</li>
</f:if>
</f:for>
</ol>
</details>
</nav>
</f:section>
</html>