Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Template:Expandable table

Template page
Revision as of 04:23, 16 July 2026 by Aurelian (talk | contribs) (Created page with "<includeonly><table class="wikitable mw-collapsible mw-collapsed wizlords-magic-table wizlords-example-table {{{class|}}}"> <caption>{{{caption}}}</caption> {{{content}}} </table></includeonly><noinclude> == About this template == Creates a table that initially loads collapsed and can be expanded by selecting its caption. On phone and tablet, the caption also works as the accessible JavaScript-controlled toggle. The template keeps the existing <code>wizlords-example-tab...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

About this template

Creates a table that initially loads collapsed and can be expanded by selecting its caption. On phone and tablet, the caption also works as the accessible JavaScript-controlled toggle.

The template keeps the existing wizlords-example-table class required by the site JavaScript. Use HTML table rows inside content so wiki-table pipe characters do not interfere with template parameters.

Parameters

  • caption - title displayed above the table and used as the expandable control.
  • class - optional existing modifier classes, such as wizlords-example-table-full-heal or wizlords-reputation-table.
  • content - table header and data rows written with tr, th, and td elements.

Basic example

{{Expandable table
|caption=Example: Arcane Bolt
|content=
<tr>
<th>Spell Level</th>
<th>Spell Point Cost</th>
</tr>
<tr>
<td>Level 1</td>
<td>1 Spell Point</td>
</tr>
}}

Keep the caption and generated table classes unchanged because CSS, keyboard behavior, and JavaScript depend on them.