Template:TopicPage: Difference between revisions

From Bodhicitta
(VSCode edit)
Tag: Manual revert
(VSCode edit)
Line 20: Line 20:
|
|
}}
}}
}}
}}<!--
<div class="row mt-5">
=== BIBLIOGRAPHIC VIEW ===
<div class="col-md-3 order-md-last">
 
<div class="sidebar position-sticky" style="top: 100px;">
Full width, no sidebar.
<div>__TOC__</div>
 
</div>
The sidebar here held only a table of contents jumping between five class
</div>
headings. Measured across the 1,108 topics actually in use, the median topic
<div class="col-md-9">
carries SEVEN items and 96% carry fifteen or fewer — so on almost every topic
{{#if:{{#ask:[[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]}}
page that rail helped a reader scroll past a single screen of content, and on
|{{#widget:filterInput}}
the 39% of topics with five items or fewer it listed headings for sections
|''No pages tagged with this topic!''
that were empty.
}}


Items are shown as citations rather than tiles. Citation is present on 99% of
tagged items and already carries author, title, publisher and year in one
formatted line, which is what someone scanning a topic bibliography actually
wants. A tile shows a cover image and a truncated description instead.


<h3 class="pt-0">Editorial Content</h3>
Grouping is deliberate. A single flat list is used by default, because with
{{TileQuery
seven items five class headings create more structure than content. Sections
|query=[[Category:Editorial Content]][[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]
appear only once the topic is large enough for them to help — see the
|classes=col-lg-6 mb-4 filterable
threshold below, which is set so it keeps working as topic assignments grow.
|intro=<div class="row filterableContent">
-->
|outro=</div>
<div class="row mt-4">
<div class="col-12">{{#if:{{#ask:[[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]}}
|<div class="topic-biblio-controls">
<div class="row">
<div class="col-md-7 col-lg-5">{{#widget:filterInput|placeholder=Filter {{#ask:[[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]|format=count}} entries...}}</div>
</div><!--
Class pills. Each is a plain filter link handled by tws.js, keyed on the
data-class attribute the rows carry. Only classes that actually occur on this
topic get a pill, so a topic with no dissertations shows no dissertations
filter.
--> <div class="topic-biblio-pills">
<span class="topic-biblio-pill is-active" data-filter-class="">All <span class="rel-count">{{#ask:[[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]|format=count}}</span></span>{{#arraymap:Books;Articles;Classical Works;Multimedia;Dissertations;Tibetan Publications;Editorial Content
|;
|@@@
|{{#ifexpr:{{#ask:[[Class::@@@]][[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]|format=count}}>0
|<span class="topic-biblio-pill" data-filter-class="@@@">@@@ <span class="rel-count">{{#ask:[[Class::@@@]][[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]|format=count}}</span></span>
|
}}
|
}}
</div>
</div>{{#ifexpr:{{#ask:[[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]|format=count}}>{{{ groupThreshold | 25 }}}<!--
LARGE TOPIC — group by class, so a long bibliography stays navigable.
Each section renders only if it has entries.
--> |<div class="filterableContent">{{#arraymap:Books;Articles;Classical Works;Multimedia;Dissertations;Tibetan Publications;Editorial Content
|;
|@@@
|{{TopicBiblioSection
|heading=@@@
|query=[[Class::@@@]][[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]
}}
|
}}</div>
<!--
SMALL TOPIC — one flat list, sorted so classes still cluster together.
--> |<div class="filterableContent">{{TopicBiblioSection
|query=[[TermTopics::{{#titleparts:{{SUBPAGENAME}}}}||{{ucfirst:{{#titleparts:{{SUBPAGENAME}}}}}}]]
}}</div>
}}
}}
 
|''No pages tagged with this topic!''
{{TopicQuery|Books}}
}}
{{TopicQuery|Dissertations}}
{{TopicQuery|Articles}}
{{TopicQuery|Classical Works}}
{{TopicQuery|Multimedia}}
</div>
</div>
</div>{{#set:
</div>{{#set:
Line 60: Line 96:
|FrontCoverImg=File:Shantideva-Eric-reduced.jpg
|FrontCoverImg=File:Shantideva-Eric-reduced.jpg
}}[[Category:Topic Pages]]  
}}[[Category:Topic Pages]]  
</includeonly><noinclude>{{TemplateTag}}</noinclude>
</includeonly><noinclude>{{TemplateTag}}
 
Topic pages present a bibliography, so entries are listed as citations rather
than tiles. <code>Citation</code> is set on 99% of tagged items and already
carries author, title, publisher and year in one formatted line.
 
There is no sidebar. Measured across the 1,108 topics in use, the median topic
carries seven items and 96% carry fifteen or fewer, so the table-of-contents rail
that used to sit here helped a reader scroll past a single screen — and on the
39% of topics with five items or fewer it listed headings for empty sections.
 
== Parameters ==
 
{| class="wikitable"
! Parameter !! Description
|-
| <code>description</code> || Intro text, shown when the topic has no matching Key Terms entry.
|-
| <code>groupThreshold</code> || Item count above which the list splits into per-class sections. Defaults to 25.
|}
</noinclude>

Revision as of 18:43, 21 August 2026


Topic pages present a bibliography, so entries are listed as citations rather than tiles. Citation is set on 99% of tagged items and already carries author, title, publisher and year in one formatted line.

There is no sidebar. Measured across the 1,108 topics in use, the median topic carries seven items and 96% carry fifteen or fewer, so the table-of-contents rail that used to sit here helped a reader scroll past a single screen — and on the 39% of topics with five items or fewer it listed headings for empty sections.

Parameters

Parameter Description
description Intro text, shown when the topic has no matching Key Terms entry.
groupThreshold Item count above which the list splits into per-class sections. Defaults to 25.