From 400126fa91a1ba3b30a4b7abcfacf2b68e0604b0 Mon Sep 17 00:00:00 2001 From: Jon Robson Date: Mon, 3 Oct 2022 16:50:08 -0700 Subject: [PATCH] Revert back Minerva icon features not ready for production In Ifccaadabd72a12814d3d4d01200931f7254c6cd5 we made some modifications to the icon specification. I haven't run these by Alex yet (as focus is on Vector 2022) and don't want to rush them, so for now temporarily undoing those changes here. Changes: - Reverts icon touch areas from new 44x44 to old 46x46 - Undoes decrease in margins between labels and icons Bug: T319071 Change-Id: I9a02191c57b7e2d24a8bc909f820ba8db942c028 --- skin.json | 3 +++ skinStyles/mediawiki.ui.icon.less | 27 +++++++++++++++++++++++++++ 2 files changed, 30 insertions(+) create mode 100644 skinStyles/mediawiki.ui.icon.less diff --git a/skin.json b/skin.json index eee58f110..4854b50f0 100644 --- a/skin.json +++ b/skin.json @@ -193,6 +193,9 @@ "mediawiki.action.history.styles": [ "skinStyles/mediawiki.action.history.styles.less" ], + "+mediawiki.ui.icon": [ + "skinStyles/mediawiki.ui.icon.less" + ], "mediawiki.interface.helpers.styles": [ "skinStyles/mediawiki.interface.helpers.styles.less" ], diff --git a/skinStyles/mediawiki.ui.icon.less b/skinStyles/mediawiki.ui.icon.less new file mode 100644 index 000000000..967bc7405 --- /dev/null +++ b/skinStyles/mediawiki.ui.icon.less @@ -0,0 +1,27 @@ +@import '../minerva.less/minerva.variables.less'; + +// Temporarily revert back from 44x44 (0.6875em) to 46x46 (0.75em) +.mw-ui-icon-element.mw-ui-button { + padding: 0.75em; // 46x46 +} + +// Disable desktop touch area special handling. +@media ( min-width: @width-breakpoint-desktop ) { + .mw-ui-icon-element.mw-ui-button { + padding: 0.75em; + } +} + +// Revert back to old spacing between text and icon. +.mw-ui-icon + span:not( :empty ) { + margin-left: 8px; +} + +.mw-ui-icon-with-label-desktop:before { + margin-right: 8px; +} + +// Revert back to old flush left rule. +.mw-ui-icon-small.mw-ui-icon-flush-left { + margin-left: -0.5625em; +}