tooltips: Use <div> tags inside tooltip's inner content.

By replacing `<span>` tags with `<div>` tags inside the tooltip's inner
content we remove the redundancy of having to use break tags to
separate the tooltip's title and it's content.

We also replace any `<p>` tags with `<div>` tags for the following
reasons:

- Since what we want to achieve are just block elements in order to
avoid the break tags, using `<div>` tags provide use with a wider
scope of use cases.

- We don't want the pause, screen readers often introduce after reading
the contents of a paragraph.

- The `<p>` tag cannot contain tables and other block-level elements.

- The semantic meaning of the <p> tag doesn't apply to the commonly
used tooltip content.
This commit is contained in:
Sayam Samal
2023-10-02 04:29:35 +05:30
committed by Tim Abbott
parent 456f3a0d94
commit 8d3f2baebf
7 changed files with 13 additions and 22 deletions

View File

@@ -1,7 +1,7 @@
<div>
<span>{{t 'Go to conversation' }}</span>
<div>{{t "Go to conversation"}}</div>
{{#if display_current_view}}
<p class="narrow_to_compose_recipient_current_view_help tooltip-inner-content italic">{{display_current_view}}</p>
<div class="tooltip-inner-content italic">{{display_current_view}}</div>
{{/if}}
</div>
{{tooltip_hotkey_hints "Ctrl" "."}}