Template:Tooltip: Difference between revisions
GreytideSkye (talk | contribs) m (Test cases updated. I don't love this but for some reason it just doesn't love me.) |
GreytideSkye (talk | contribs) m (TemplateData is a real thing) |
||
Line 11: | Line 11: | ||
Ideally, this paragraph should appear as a single paragraph, where the next bit is a {{Tooltip|multi word tooltip|with punctuation? with wizardry?}}, with the comma directly adjacent to the words. This part | Ideally, this paragraph should appear as a single paragraph, where the next bit is a {{Tooltip|multi word tooltip|with punctuation? with wizardry?}}, with the comma directly adjacent to the words. This part '''ought to be, morally''' still be on the same line. If it doesn't, '''and it does not at this time''', that's alright; use [[Template:TooltipInline]] in these cases. | ||
Table below should consist of 1 chemical, Prefactor B, with the formula 1 part Phenol, 3 parts Ethanol, 1 part Plasma High temperature, where Phenol has a tooltip to expand with its own nested tooltip. [[Template:RecursiveChem/Prefactor_b]] | Table below should consist of 1 chemical, Prefactor B, with the formula 1 part Phenol, 3 parts Ethanol, 1 part Plasma High temperature, where Phenol has a tooltip to expand with its own nested tooltip. [[Template:RecursiveChem/Prefactor_b]] | ||
Line 27: | Line 27: | ||
|} | |} | ||
For some reason, recursive tooltips don't love span, choosing to dump everything after the tooltip into the deepest tooltip instead of... fully after the top-most tooltip. | For some reason, recursive tooltips don't love '''span''', choosing to dump everything after the tooltip into the deepest tooltip instead of... fully after the top-most tooltip. | ||
[[Category:Templates]][[Category:Maintenance templates]][[Category:Misc Styling Templates]]</noinclude> | [[Category:Templates]][[Category:Maintenance templates]][[Category:Misc Styling Templates]]<templatedata> | ||
{ | |||
"params": { | |||
"Display Text": { | |||
"aliases": [ | |||
"text" | |||
], | |||
"label": "Display Text", | |||
"description": "The text that is displayed on the page. It will appear with a dotted line underneath, and the user will mouse over it to expand a tooltip. It is likely that this will break the text into several paragraphs. If this is undesired, use TooltipInline.", | |||
"example": "Chemical X", | |||
"type": "string", | |||
"default": "CHEMICAL X", | |||
"required": true, | |||
"suggestedvalues": [ | |||
"The reagent name, without the 1 Part or so." | |||
] | |||
}, | |||
"Tooltip": { | |||
"aliases": [ | |||
"tooltip", | |||
"box" | |||
], | |||
"label": "Tooltip", | |||
"description": "The text that appears in a gray box when the user hovers over the display text. Links are functional, and this template may be used recursively.", | |||
"type": "content", | |||
"suggestedvalues": [ | |||
"Tooltip" | |||
], | |||
"default": "Tooltip Text", | |||
"required": true | |||
} | |||
}, | |||
"paramOrder": [ | |||
"Display Text", | |||
"Tooltip" | |||
], | |||
"description": "An in-line tooltip that displays a short text with a dotted line underneath, which when moused over, displays a gray box overtop the text, with its own tooltip text. Should not be used recursively, as Span is not a very stable keyword." | |||
} | |||
</templatedata></noinclude> |
Latest revision as of 01:19, 21 June 2024
Test Cases
Blank tooltip:
Ideally, this paragraph should appear as a single paragraph, where the next bit is a
, with the comma directly adjacent to the words. This part ought to be, morally still be on the same line. If it doesn't, and it does not at this time, that's alright; use Template:TooltipInline in these cases.
Table below should consist of 1 chemical, Prefactor B, with the formula 1 part Phenol, 3 parts Ethanol, 1 part Plasma High temperature, where Phenol has a tooltip to expand with its own nested tooltip. Template:RecursiveChem/Prefactor_b
Name | Formula | Reaction conditions | Description |
---|---|---|---|
Prefactor b▮ | 1 part 3 parts Ethanol |
Required temp: 50K Overheat temp: 500K Optimal pH range: 5 to 8 Min purity: 0.35 Extremely Endothermic minor H+ producing Dangerously volitile |
This is part of a competitive reaction between Purity Tester and Tempomyocin. This outcompetes when the reaction is hot. |
For some reason, recursive tooltips don't love span, choosing to dump everything after the tooltip into the deepest tooltip instead of... fully after the top-most tooltip.
An in-line tooltip that displays a short text with a dotted line underneath, which when moused over, displays a gray box overtop the text, with its own tooltip text. Should not be used recursively, as Span is not a very stable keyword.
Parameter | Description | Type | Status | |
---|---|---|---|---|
Display Text | Display Text text | The text that is displayed on the page. It will appear with a dotted line underneath, and the user will mouse over it to expand a tooltip. It is likely that this will break the text into several paragraphs. If this is undesired, use TooltipInline.
| String | required |
Tooltip | Tooltip tooltip box | The text that appears in a gray box when the user hovers over the display text. Links are functional, and this template may be used recursively.
| Content | required |