Template:LibraryItem: Difference between revisions
From Bodhicitta
(Defer the citations panel so it does not slow the page parse) |
(Defer the citations panel so it does not slow the page parse) |
||
| Line 304: | Line 304: | ||
would run the module during the parse and undo the deferral. Read with #show, | would run the module during the parse and undo the deferral. Read with #show, | ||
not GetItemData — that helper does not carry this property. | not GetItemData — that helper does not carry this property. | ||
Tested for the "RKTS" prefix, not merely for being set: every library item | |||
has a DrlPageName, but on a modern book it is the title ("The Intelligent | |||
Heart"). Only a catalogue number can match a QuoteSource. | |||
Any canonical text has the property, so the panel renders on 256 pages while | Any canonical text has the property, so the panel renders on 256 pages while | ||
only 112 are cited. tws.js removes it once the deferred block lands empty. | only 112 are cited. tws.js removes it once the deferred block lands empty. | ||
-->{{# | -->{{#ifeq: {{#sub:{{#show:{{FULLPAGENAME}}|?DrlPageName}}|0|4}}|RKTS | ||
|<div class="ssc-citations-block mw-collapsible mw-collapsed" data-expandtext="Show the passages" data-collapsetext="Hide the passages"> | |<div class="ssc-citations-block mw-collapsible mw-collapsed" data-expandtext="Show the passages" data-collapsetext="Hide the passages"> | ||
<div class="ssc-citations-heading"><i class="fa-sharp-duotone fa-solid fa-quote-left fa-sm mr-2"></i>Quoted in the aligned translations</div> | <div class="ssc-citations-heading"><i class="fa-sharp-duotone fa-solid fa-quote-left fa-sm mr-2"></i>Quoted in the aligned translations</div> | ||