Module:GameInfo/Skills/doc
More actions
This is the documentation page for Module:GameInfo/Skills
Module:GameInfo/Skills renders the compiled “Skill card” payload used by
.
Contract
This module expects a compiled JSON payload provided via |data=.
It is strict (no backwards-compat / no schema guessing).
Entry point
GameInfo loads this module via Module:GameInfo and calls render(frame).
Typical invocation:
{{#invoke:GameInfo|Skills|id=...|index=...|notes=...|data=...}}
TemplateStyles
This module sets:
STYLE_SRC = "Module:GameInfo/styles.css"
GameInfo will emit that TemplateStyles tag before the rendered output.
Required arguments
data: JSON string payload (must decode to an object withschema=1)
Optional arguments
id: HTML id for the root card. If omitted, one is generated from display name + index.index: Used only for generating a stable id. Default1.notes: Wikitext content shown in the Notes popup.debug: If1, error output includes a nowiki preview of the first ~480 chars of the raw JSON.
Payload schema (schema=1)
At minimum, the payload should include:
identity: display name, description, sprite infolevel: default/max (used for slider + value selection)meta_row: 4 meta cells (icon + label lines)requirements/users: grouped lists (optional)scaling_top: damage/modifier/scaling lines (supports series values)core_stats: list of core stat cells (supports series values)tabs: mechanics grid, keyword pills, effects/events reference cards
Values may be plain strings/numbers, or objects like:
{"text":"..."}{"series":[...]}(emitsdata-seriesfor JS and selects by level)
Images and missing icons
Image references are validated with a small existence cache.
If a file page does not exist, the renderer outputs a small “?” badge (sv-miss) instead of a redlink image.
Keyword pills
Keyword pill strings in the form Domain|Key are expanded to:
{{def|Domain|Key}}
Other strings are rendered as plain text.
Interactive UI hooks
The module emits semantic hooks used by Common.js:
- Popups:
data-sv-toggle="1"withsv-hidden - Tabs:
data-tabs="1"/data-tabs-root - Slider:
data-sv-slider="1"with ARIA slider attributes