Jump to content

Template:Commentary: Difference between revisions

From Grantha
No edit summary
No edit summary
 
(8 intermediate revisions by the same user not shown)
Line 1: Line 1:
<!--
<includeonly><div
  Template:Commentary
   class="bhashyam-block"
  ═══════════════════
  data-verse="{{{verse_id|}}}"
  Collapsible commentary — toggle icon appears inline after verse text.
  data-commentary-id="{{{id|}}}">{{{text|}}}</div></includeonly><noinclude>
   Parameters:
== Template:Bhashyam ==
    verse_id  – e.g. NNS_C01_V01
Renders a primary bhāṣya commentary block as plain running prose.
    name      – slug identifier
No box, no title, no border flows as body text with left indent.
    label    – display name
 
    text      – commentary body
=== Parameters ===
-->
{| class="wikitable"
<span class="commentary-toggle"
|-
      id="toggle-{{{verse_id}}}-{{{name}}}"
! Parameter !! Required !! Description
      onclick="(function(){
|-
        var body = document.getElementById('commentary-body-{{{verse_id}}}-{{{name}}}');
| <code>verse_id</code> || Yes || ID of the parent verse, e.g. <code>ISH_C01_V01</code>
        var btn = document.getElementById('toggle-{{{verse_id}}}-{{{name}}}');
|-
        if(body.style.display === 'none' || body.style.display === ''){
| <code>id</code> || No || ID of this commentary block
          body.style.display = 'block';
|-
          btn.title = '{{{label}}} क्लिक करें बंद करने के लिए';
| <code>text</code> || Yes || The bhāṣya prose content
        } else {
|}
          body.style.display = 'none';
 
        }
=== Example ===
      })()"
<pre>
      title="{{{label}}}">💬</span><div class="commentary-body"
{{Bhashyam
    id="commentary-body-{{{verse_id}}}-{{{name}}}"
| verse_id = ISH_C01_V01
    style="display:none">
| id      = ISH_C01_V01_B01
  {{{text}}}
| text     =
</div>
ईशस्यावासयोग्यमीशावास्यम् । जगत्यां प्रकृतौ ।
}}
</pre>
[[Category:Templates]]
</noinclude>

Latest revision as of 08:53, 10 April 2026

Template:Bhashyam

Renders a primary bhāṣya commentary block as plain running prose. No box, no title, no border — flows as body text with left indent.

Parameters

Parameter Required Description
verse_id Yes ID of the parent verse, e.g. ISH_C01_V01
id No ID of this commentary block
text Yes The bhāṣya prose content

Example

{{Bhashyam
| verse_id = ISH_C01_V01
| id       = ISH_C01_V01_B01
| text     =
ईशस्यावासयोग्यमीशावास्यम् । जगत्यां प्रकृतौ ।
}}