jenkins-bot has submitted this change and it was merged.

Change subject: MediaWiki theme: Fix non-clickability of radios and checkboxes
......................................................................


MediaWiki theme: Fix non-clickability of radios and checkboxes

The formatting <span/> was displayed on top of the (invisible) <input/>,
making it unclickable (unless there was a wrapping FieldLayout providing
a <label/>). Display the <input/> on top instead.

This also happens to fix an issue with hover state not working, as that
was caused by the :hover pseudoclass being styled on the <input/> rather
than the <span/> (which used to be incorrect and now will be correct).

Bug: T88035
Change-Id: Ide47e8eb05743aabde43a0a15633d09e2d2ea188
---
M src/themes/mediawiki/widgets.less
1 file changed, 6 insertions(+), 0 deletions(-)

Approvals:
  Esanders: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/src/themes/mediawiki/widgets.less 
b/src/themes/mediawiki/widgets.less
index 5f8fbd4..3cef4d7 100644
--- a/src/themes/mediawiki/widgets.less
+++ b/src/themes/mediawiki/widgets.less
@@ -186,6 +186,9 @@
                // we hide the input element as instead we will style the span 
that follows
                // we use opacity so that VoiceOver software can still identify 
it
                opacity: 0;
+               // render "on top of" the span, so that it's still clickable
+               position: relative;
+               z-index: 1;
 
                // having a margin might offset the checkbox from the pseudo 
element
                // making only the overlap region react to events
@@ -296,6 +299,9 @@
                // we hide the input element as instead we will style the span 
that follows
                // we use opacity so that VoiceOver software can still identify 
it
                opacity: 0;
+               // render "on top of" the span, so that it's still clickable
+               position: relative;
+               z-index: 1;
 
                // having a margin might offset the checkbox from the pseudo 
element
                // making only the overlap region react to events

-- 
To view, visit https://gerrit.wikimedia.org/r/189361
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: Ide47e8eb05743aabde43a0a15633d09e2d2ea188
Gerrit-PatchSet: 2
Gerrit-Project: oojs/ui
Gerrit-Branch: master
Gerrit-Owner: Bartosz DziewoƄski <[email protected]>
Gerrit-Reviewer: Esanders <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to