Template:AbilitySection/doc: Difference between revisions

From The Deadlock Wiki
Jump to navigation Jump to search
Vergir (talk | contribs)
Add AbilitySection doc
 
Vergir (talk | contribs)
m (ninjafix)
Line 3: Line 3:
Two-column layout wrapping [[Template:Ability card v2]] on the left and an optional tabbed details panel on the right. Backed by [[Module:AbilitySection]].
Two-column layout wrapping [[Template:Ability card v2]] on the left and an optional tabbed details panel on the right. Backed by [[Module:AbilitySection]].


On narrow viewports the two columns stack vertically via CSS flex-wrap. Styles are loaded from [[Template:Vergir/AbilitySection/styles.css]] via TemplateStyles.
On narrow viewports the two columns stack vertically via CSS flex-wrap. Styles are loaded from [[Template:AbilitySection/styles.css]] via TemplateStyles.


Intended to replace [[Template:Ability tabs]] on hero pages. Editors place four of these blocks in sequence, one per ability, each under its own <code>=== Ability Name ===</code> heading directly on the hero page.
Intended to replace [[Template:Ability tabs]] on hero pages. Editors place four of these blocks in sequence, one per ability, each under its own <code>=== Ability Name ===</code> heading directly on the hero page.
Line 18: Line 18:
| <code>notes</code> || Freeform wikitext for the Notes tab. Supports links, templates, bullet points. || No
| <code>notes</code> || Freeform wikitext for the Notes tab. Supports links, templates, bullet points. || No
|-
|-
| <code>interactions</code> || One or more [[User:Vergir/AbilityInteraction]] calls for the Interactions tab. || No
| <code>interactions</code> ||Freeform wikitext for the Interactions tab. || No
|-
|-
| <code>tips</code> || Freeform wikitext for the Tips tab. || No
| <code>tips</code> || Freeform wikitext for the Tips tab. || No
Line 33: Line 33:
=== Call Bell ===
=== Call Bell ===


{{User:Vergir/AbilitySection
{{AbilitySection
| hero_name  = The Doorman
| hero_name  = The Doorman
| ability_num = 1
| ability_num = 1

Revision as of 10:07, 1 May 2026

Overview

Two-column layout wrapping Template:Ability card v2 on the left and an optional tabbed details panel on the right. Backed by Module:AbilitySection.

On narrow viewports the two columns stack vertically via CSS flex-wrap. Styles are loaded from Template:AbilitySection/styles.css via TemplateStyles.

Intended to replace Template:Ability tabs on hero pages. Editors place four of these blocks in sequence, one per ability, each under its own === Ability Name === heading directly on the hero page.

Parameters

Parameter Description Required
hero_name Hero name, passed to Template:Ability card v2. Yes
ability_num Ability index (1–4), passed to Template:Ability card v2. Yes
notes Freeform wikitext for the Notes tab. Supports links, templates, bullet points. No
interactions Freeform wikitext for the Interactions tab. No
tips Freeform wikitext for the Tips tab. No

Tab visibility rules:

  • Only tabs with content are shown.
  • A Show All tab is appended if two or more tabs with content
  • If no parameters are provided, no notes panel is rendered at all.

Example

=== Call Bell ===

{{AbilitySection
| hero_name   = The Doorman
| ability_num = 1
| notes       =
* Bells can be detonated by [[Melee Attack|melee attacks]].
| interactions =
* The cast range (throwing distance) is not affected by Ability Range
| tips =
* T3 talent allows stacking several bells for making high damage traps.
}}