Template:Ss/doc: Difference between revisions

From The Deadlock Wiki
Jump to navigation Jump to search
LVL (talk | contribs)
Created page with "This template displays a Spirit Power scaling indicator next to a value. ==Usage== <pre>{{Ss|value}}</pre> <pre>{{Ss|value|font_size}}</pre> <pre>{{Ss|value|compact=yes}}</pre> ==Parameters== {| class="wikitable" ! Parameter !! Description !! Default |- | 1 || The scaling value || (empty) |- | 2 || Font size || 14px |- | icon_size || Size of the spirit icon || 25px |- | compact || Set to <code>yes</code> for icon-only mode with a tooltip on hover || (empty) |} ==Examp..."
 
LVL (talk | contribs)
Added TS template and templatedata
 
Line 1: Line 1:
{{TS}}
This template displays a Spirit Power scaling indicator next to a value.
This template displays a Spirit Power scaling indicator next to a value.


Line 5: Line 6:
<pre>{{Ss|value|font_size}}</pre>
<pre>{{Ss|value|font_size}}</pre>
<pre>{{Ss|value|compact=yes}}</pre>
<pre>{{Ss|value|compact=yes}}</pre>
==Parameters==
{| class="wikitable"
! Parameter !! Description !! Default
|-
| 1 || The scaling value || (empty)
|-
| 2 || Font size || 14px
|-
| icon_size || Size of the spirit icon || 25px
|-
| compact || Set to <code>yes</code> for icon-only mode with a tooltip on hover || (empty)
|}


==Examples==
==Examples==
<pre>30{{ss|0.1234}}m</pre>
<pre>30{{Ss|0.1234}}m</pre>
Outputs: 30{{ss|0.1234}}m
Outputs: 30{{Ss|0.1234}}m


<pre>30{{ss|0.1234|12px}}m</pre>
<pre>30{{Ss|0.1234|12px}}m</pre>
Outputs: 30{{ss|0.1234|12px}}m
Outputs: 30{{Ss|0.1234|12px}}m


<pre>{{Ss|0.1234|compact=yes}}</pre>
<pre>{{Ss|0.1234|compact=yes}}</pre>
Outputs: {{Ss|0.1234|compact=yes}}
Outputs: {{Ss|0.1234|compact=yes}}
<templatedata>
{
  "description": "Displays a Spirit Power scaling indicator next to a value.",
  "params": {
    "1": {
      "label": "Scaling value",
      "description": "The Spirit Power scaling value to display.",
      "type": "number",
      "required": true
    },
    "2": {
      "label": "Font size",
      "description": "Font size of the scaling text.",
      "type": "string",
      "default": "14px",
      "required": false
    },
    "icon_size": {
      "label": "Icon size",
      "description": "Size of the Spirit Power icon.",
      "type": "string",
      "default": "25px",
      "required": false
    },
    "compact": {
      "label": "Compact mode",
      "description": "Set to 'yes' to show only the icon with a tooltip on hover instead of the full indicator.",
      "type": "string",
      "required": false
    }
  },
  "format": "inline"
}
</templatedata>

Latest revision as of 20:38, 11 April 2026

CSS3 logo.svg
This template uses CSS found at Ss/styles.css.

This template displays a Spirit Power scaling indicator next to a value.

{{Ss|value}}
{{Ss|value|font_size}}
{{Ss|value|compact=yes}}

Examples

[edit source]
30{{Ss|0.1234}}m

Outputs: 30x0.1234m

30{{Ss|0.1234|12px}}m

Outputs: 30x0.1234m

{{Ss|0.1234|compact=yes}}

Outputs:

Displays a Spirit Power scaling indicator next to a value.

Template parameters

This template prefers inline formatting of parameters.

ParameterDescriptionTypeStatus
Scaling value1

The Spirit Power scaling value to display.

Numberrequired
Font size2

Font size of the scaling text.

Default
14px
Stringoptional
Icon sizeicon_size

Size of the Spirit Power icon.

Default
25px
Stringoptional
Compact modecompact

Set to 'yes' to show only the icon with a tooltip on hover instead of the full indicator.

Stringoptional