mediawiki-skins-Vector/includes/templates/UserLinks.mustache
Jon Robson e153561255 Component: UserLinks
Simplify the user links component
Introduce MenuListItem and IconLink components.

HTML changes:
* Logout, login and account links are now wrapped in a ul and li tag
instead of a DIV for consistent with other menus (this occurs due
to use of MenuContents). Code reviewer can see tests
for an understanding of how the template data and markup has changed.

VISUAL CHANGE:
* Increased margins in user links menu relating to change from DIV to
UL / LI tags.

Bug: T320927
Change-Id: Ia24be48105e1ff85da227883abb5dddb3d54388d
2023-01-11 21:48:11 +00:00

21 lines
733 B
Plaintext

<nav class="vector-user-links{{#is-wide}} vector-user-links-wide{{/is-wide}}" aria-label="{{msg-personaltools}}" role="navigation" >
{{#data-user-menu-overflow}}{{>Menu}}{{/data-user-menu-overflow}}
{{#data-user-menu-dropdown}}
{{>Dropdown/Open}}
{{#is-anon}}
{{#is-temp-user}}
{{>UserLinks__templogin}}
{{/is-temp-user}}
{{^is-temp-user}}
{{>UserLinks__login}}
{{/is-temp-user}}
{{/is-anon}}
{{#data-dropdown-menu}}{{>MenuContents}}{{/data-dropdown-menu}}
{{^is-anon}}
{{!-- The #pt-logout ID is required for the AJAX enabled logout in mediawiki.page.ready to work.}}
{{#data-account-links}}{{>MenuContents}}{{/data-account-links}}
{{/is-anon}}
{{>Dropdown/Close}}
{{/data-user-menu-dropdown}}
</nav>