Template:Tooltip: Difference between revisions

From Rhythm Heaven Wiki
Jump to navigation Jump to search
m (HyperNervie moved page Template:Tt to Template:Tooltip)
({{shortcut}})
 
Line 1: Line 1:
<includeonly><span class="tooltip" title="{{#tag:nowiki|{{{2}}}}}" style="text-decoration: underline; text-decoration-style: dotted">{{{1}}}</span></includeonly><noinclude>{{Documentation|content=
<includeonly><span class="tooltip" title="{{#tag:nowiki|{{{2}}}}}" style="text-decoration: underline; text-decoration-style: dotted">{{{1}}}</span></includeonly><noinclude>{{Documentation|content=
{{shortcut|template=1|tt}}
This template adds a dotted underline and a tooltip (passed as {{param|2}}) to a piece of text (passed as {{param|1}}). On desktop view, the tooltip shows when cursor hovers on the text. On mobile view, tapping on the text changes itself to the tooltip; tapping again changes it back to the original text.
This template adds a dotted underline and a tooltip (passed as {{param|2}}) to a piece of text (passed as {{param|1}}). On desktop view, the tooltip shows when cursor hovers on the text. On mobile view, tapping on the text changes itself to the tooltip; tapping again changes it back to the original text.



Latest revision as of 20:10, 24 September 2025

Template-info.svg Template Documentation
Shortcut

This template adds a dotted underline and a tooltip (passed as {{{2}}}) to a piece of text (passed as {{{1}}}). On desktop view, the tooltip shows when cursor hovers on the text. On mobile view, tapping on the text changes itself to the tooltip; tapping again changes it back to the original text.

Any Wikitext and HTML markups (e.g. ''italic'', <br>) in tooltip are escaped. To insert newlines, use the character entity reference &#10;, &#xA;, &#xa; or &NewLine;.

Examples:

  • {{tt|Text|Tooltip}}Text
  • {{tt|Text|Tool<br>Tip}}Text
  • {{tt|Text|Tool&#10;Tip}}Text