Template:Tooltip/testcases

{{testcases}}

Testing [[Template:Tooltip]]

These are tests of using Template:Sronly inside Template:Tooltip, for accessibility improvements.

=Manually linking the term inside the template=

This was not advised because of a Chrome bug, but it is long since fixed. However, there is a still a problem: the link automatically has a title supplied by MediaWiki (the page name), and this in most browsers will override the tooltip title of the surrounding span. So, the intended tooltip will actually only be available to:

  1. screen readers
  2. in any graphical browser case in which a link is included but is not the entire term content, in which case the intended tooltip will be available when focus is over the span but is not over the part that is a link.
  3. in a graphical browser that doesn't treat link titles as tooltip but only as something to show in some other interface element such as the window footer (and here it will not matter if the entire term content is a link or not).

For this reason, the template instructions to prefer wrapping the template in the link should be retained, along with addition of the new three-parameter version ({{tlx|tooltip|linkTarget|termText|tooltipText}}).

Code:

{{tooltip/sandbox|conflict of interest|in the specific sense employed in Wikipedia policy}}

Sandbox template output:

{{tooltip/sandbox|conflict of interest|in the specific sense employed in Wikipedia policy}}

Current template output (lacks sronly):

{{tooltip|conflict of interest|in the specific sense employed in Wikipedia policy}}

=Using the dotted=no parameter=

Code:

{{tooltip/sandbox|conflict of interest|in the specific sense employed in Wikipedia policy|dotted=no}}

Sandbox template output:

{{tooltip/sandbox|conflict of interest|in the specific sense employed in Wikipedia policy|dotted=no}}

Current template output (lacks sronly):

{{tooltip|conflict of interest|in the specific sense employed in Wikipedia policy|dotted=no}}

=Hebrew text=

Code:

{{tooltip/sandbox|תוכן נִסתָר|תוכן ברור|dotted=no}}

Sandbox template output:

{{tooltip/sandbox|תוכן נִסתָר|תוכן ברור|dotted=no}}

Current template output (lacks sronly):

{{tooltip|תוכן נִסתָר|תוכן ברור|dotted=no}}

=Double quotes in title text=

Code:

{{tooltip/sandbox|conflict of interest|often abbreviated "coi"}}

Sandbox template output:

{{tooltip/sandbox|conflict of interest|often abbreviated "coi"}}

Current template output (lacks sronly):

{{tooltip|conflict of interest|often abbreviated "coi"}}