Template:SidebarRkts: Difference between revisions
(Collapsed rKTs catalogue section for the sidebar) |
(VSCode edit) |
||
| Line 1: | Line 1: | ||
<includeonly>{{#if: {{GetItemData|prop=RktsNumber}}<!-- | <includeonly>{{#if: {{GetItemData|prop=RktsNumber}}<!-- | ||
rKTs catalogue data for this work, in the library-item sidebar. | rKTs catalogue data for this work, in the library-item sidebar. | ||
A definition list rather than a table. The tab version is a two-column | |||
table, which needs horizontal room this column does not have: labels like | |||
"Alternate Titles - Devanagari" wrap to three lines and squeeze the value | |||
into a few characters. As dt/dd the label sits on its own line above the | |||
value, which is what a narrow column can actually show. | |||
Collapsed by default. This is catalogue apparatus — canon section, colophon, | Collapsed by default. This is catalogue apparatus — canon section, colophon, | ||
alternate titles in three scripts — | alternate titles in three scripts — that matters to scholars working with the | ||
Kangyur and Tengyur and is noise for everyone else. Present on fewer than | |||
half of Classical Works, so it renders only when there is a RktsNumber. | half of Classical Works, so it renders only when there is a RktsNumber. | ||
| Line 11: | Line 17: | ||
uses for the relationship table. | uses for the relationship table. | ||
Each field renders only when set, so a sparse record shows a short list | |||
rather than a column of empty labels. | |||
-->|<div class="sidebar-section sidebar-rkts mw-collapsible mw-collapsed" data-expandtext="Show rKTs data" data-collapsetext="Hide rKTs data"> | -->|<div class="sidebar-section sidebar-rkts mw-collapsible mw-collapsed" data-expandtext="Show rKTs data" data-collapsetext="Hide rKTs data"> | ||
<div class="sidebar-section-heading">rKTs catalogue</div> | <div class="sidebar-section-heading">rKTs catalogue</div> | ||
<div class="mw-collapsible-content">{{ | <div class="mw-collapsible-content"><dl class="sidebar-rkts-list">{{#if: {{GetItemData|prop=RktsNumber}}|<dt>Number</dt><dd>{{GetItemData|prop=RktsNumber}}</dd>|}}{{#if: {{GetItemData|prop=RktsCanon}}|<dt>Canon</dt><dd>{{GetItemData|prop=RktsCanon}}</dd>|}}{{#if: {{GetItemData|prop=RktsSkt}}|<dt>Sanskrit</dt><dd>{{GetItemData|prop=RktsSkt}}</dd>|}}{{#if: {{GetItemData|prop=RktsAltTitles}}|<dt>Alternate titles</dt><dd>{{GetItemData|prop=RktsAltTitles}}</dd>|}}{{#if: {{GetItemData|prop=RktsAltTitlesSkt}}|<dt>Alternate titles — Sanskrit</dt><dd>{{GetItemData|prop=RktsAltTitlesSkt}}</dd>|}}{{#if: {{GetItemData|prop=RktsAltTitlesDev}}|<dt>Alternate titles — Devanagari</dt><dd>{{GetItemData|prop=RktsAltTitlesDev}}</dd>|}}{{#if: {{GetItemData|prop=RktsRelationships}}|<dt>Relationships</dt><dd>{{GetItemData|prop=RktsRelationships}}</dd>|}}{{#if: {{GetItemData|prop=RktsNotes}}|<dt>Notes</dt><dd>{{GetItemData|prop=RktsNotes}}</dd>|}}{{#if: {{GetItemData|prop=RktstAuthor}}|<dt>Author</dt><dd>{{GetItemData|prop=RktstAuthor}}</dd>|}}{{#if: {{GetItemData|prop=RktstAuthorTib}}|<dt>Author (Tibetan)</dt><dd>{{GetItemData|prop=RktstAuthorTib}}</dd>|}}{{#if: {{GetItemData|prop=RktstTranslator}}|<dt>Translator</dt><dd>{{GetItemData|prop=RktstTranslator}}</dd>|}}{{#if: {{GetItemData|prop=RktstTranslatorPandita}}|<dt>Translator Pandita</dt><dd>{{GetItemData|prop=RktstTranslatorPandita}}</dd>|}}{{#if: {{GetItemData|prop=RktsColophon}}|<dt>Colophon</dt><dd>{{GetItemData|prop=RktsColophon}}</dd>|}}{{#if: {{GetItemData|prop=RktsColophonTitle}}|<dt>Title from colophon</dt><dd>{{GetItemData|prop=RktsColophonTitle}}</dd>|}}</dl></div> | ||
</div> | </div> | ||
| | | | ||
}}</includeonly><noinclude>{{TemplateTag}} | }}</includeonly><noinclude>{{TemplateTag}} | ||
The rKTs catalogue block in a library-item sidebar, collapsed by default. | The rKTs catalogue block in a library-item sidebar, collapsed by default, as a | ||
Renders nothing unless the work has a <code>RktsNumber</code>. | definition list. Renders nothing unless the work has a <code>RktsNumber</code>. | ||
[[Template:RktsTable]]. | |||
The tab version, [[Template:RktsTable]], is a two-column table and is kept for | |||
anywhere with the width for it. | |||
</noinclude> | </noinclude> | ||
Latest revision as of 14:01, 25 August 2026
The rKTs catalogue block in a library-item sidebar, collapsed by default, as a
definition list. Renders nothing unless the work has a RktsNumber.
The tab version, Template:RktsTable, is a two-column table and is kept for anywhere with the width for it.