mediawiki-skins-Vector/includes/templates/TableOfContents.mustache
bwang 0f7411bdf2 Update TOC to use PinnableHeader
- Update 'collapsed' naming convention to 'pinned'
- Introduce VectorComponentPinnableHeader

Bug: T317897
Change-Id: I752eadc9bf54d58c799060a9eaefa0b125dd7952
2022-11-15 16:37:50 -06:00

28 lines
1 KiB
Plaintext

<nav id="mw-panel-toc" class="sidebar-toc" role="navigation" aria-label="{{ msg-vector-toc-label }}" data-event-name="ui.sidebar-toc">
{{^is-page-tools-enabled}}
<div id="sidebar-toc-label" class="sidebar-toc-header">
<p class="sidebar-toc-title">
{{ msg-vector-toc-label }}
<button class="vector-toc-uncollapse-button">{{msg-vector-pin-element-label}}</button>
<button class="vector-toc-collapse-button">{{msg-vector-unpin-element-label}}</button>
</p>
</div>
{{/is-page-tools-enabled}}
{{#is-page-tools-enabled}}
{{#data-pinnable-header}}{{>PinnableHeader}}{{/data-pinnable-header}}
{{/is-page-tools-enabled}}
<ul class="sidebar-toc-contents" id="mw-panel-toc-list">
{{#is-vector-toc-beginning-enabled}}
<li id="toc-mw-content-text"
class="sidebar-toc-list-item sidebar-toc-level-1">
<a href="#" class="sidebar-toc-link">
<div class="sidebar-toc-text">{{ msg-vector-toc-beginning }}</div>
</a>
</li>
{{/is-vector-toc-beginning-enabled}}
{{#array-sections}}
{{>TableOfContents__line}}
{{/array-sections}}
</ul>
</nav>