jenkins-bot has submitted this change and it was merged.
Change subject: Hygiene: Use explicit classes on main menu
......................................................................
Hygiene: Use explicit classes on main menu
We should never use icon classes since they could change in
future e.g. if we move to oojsui
Change-Id: If767feb2bf55c35d885ca23bec450264afe31832
---
M includes/skins/SkinMinerva.php
M less/mainmenu.less
M less/specials/mobilemenu.less
3 files changed, 9 insertions(+), 12 deletions(-)
Approvals:
Bmansurov: Looks good to me, approved
jenkins-bot: Verified
diff --git a/includes/skins/SkinMinerva.php b/includes/skins/SkinMinerva.php
index f768211..b60ce6d 100644
--- a/includes/skins/SkinMinerva.php
+++ b/includes/skins/SkinMinerva.php
@@ -528,14 +528,14 @@
array(
'text' => $username,
'href' =>
SpecialPage::getTitleFor( 'UserProfile', $username )->getLocalUrl(),
- 'class' => MobileUI::iconClass(
'profile', 'before', 'truncated-text' ),
+ 'class' => MobileUI::iconClass(
'profile', 'before', 'truncated-text primary-action' ),
'data-event-name' => 'profile',
),
array(
'text' => wfMessage(
'mobile-frontend-main-menu-logout' )->escaped(),
'href' => $url,
'class' => MobileUI::iconClass(
- 'secondary-logout',
'element', 'icon-24px icon-secondary truncated-text' ),
+ 'secondary-logout',
'element', 'secondary-action truncated-text' ),
'data-event-name' => 'logout',
),
),
diff --git a/less/mainmenu.less b/less/mainmenu.less
index 1bc7d95..c5161b9 100644
--- a/less/mainmenu.less
+++ b/less/mainmenu.less
@@ -56,7 +56,9 @@
.client-js & {
- .icon-secondary {
+ // FIXME: Remove when cache cleared.
+ .icon-secondary,
+ .secondary-action {
border: none;
position: absolute;
right: 0;
@@ -64,15 +66,11 @@
bottom: 0;
padding-right: 0;
border-left: 1px solid @colorGray7;
-
- // FIXME: Remove when cache cleared and using mw-ui-icon
- &.icon {
- width: 0;
- }
}
+ // FIXME: Remove when cache cleared.
.icon-profile,
- .mw-ui-icon-profile {
+ .primary-action {
// 1px for the logout icon border-left
margin-right: @menuLinkLineHeight * 2 + 1;
}
diff --git a/less/specials/mobilemenu.less b/less/specials/mobilemenu.less
index 2533354..45e5663 100644
--- a/less/specials/mobilemenu.less
+++ b/less/specials/mobilemenu.less
@@ -48,12 +48,11 @@
.client-nojs {
#mw-mf-page-left {
- .icon,
- .icon.icon-anon {
+ ul li a {
background-image: none;
padding-left: 0;
}
- .icon-secondary {
+ .secondary-action {
display: none;
}
}
--
To view, visit https://gerrit.wikimedia.org/r/204001
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: If767feb2bf55c35d885ca23bec450264afe31832
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: Jdlrobson <[email protected]>
Gerrit-Reviewer: Bmansurov <[email protected]>
Gerrit-Reviewer: Jdlrobson <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits