Page MenuHomePhabricator

DateInputWidget unusable when JavaScript is disabled
Closed, ResolvedPublic

Description

If you disable JavaScript, DateInputWidget should fall back to being a regular date input field and let the user type in the date. Currently, however, the field becomes completely unusable due to the CSS:

.mw-widget-dateInputWidget.oo-ui-textInputWidget input {
 -webkit-user-select: none;
 -moz-user-select: none;
 -ms-user-select: none;
 user-select: none;
}

See src/mediawiki.widgets/mw.widgets.DateInputWidget.less line 14.
This CSS should be applied by the OOjs-UI JavaScript, not in the LESS file (or overridden by a .client-nojs rule).

Event Timeline

kaldari created this task.May 26 2017, 9:45 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMay 26 2017, 9:45 PM
kaldari updated the task description. (Show Details)May 26 2017, 9:49 PM
Sn1per added a subscriber: Sn1per.May 27 2017, 4:24 PM
Volker_E moved this task from Backlog to Next-up on the OOUI board.May 29 2017, 4:06 PM

Change 356066 had a related patch set uploaded (by Bartosz Dziewoński; owner: Bartosz Dziewoński):
[mediawiki/core@master] mw.widgets.DateInputWidget: Remove accidental 'user-select' on PHP widget's input

https://gerrit.wikimedia.org/r/356066

Note that this seems to only affect Firefox. Chrome has support for <input type=date> and apparently ignores user-select: none; on those elements.

matmarex edited projects, added MediaWiki-Interface; removed CSS, OOUI.May 29 2017, 4:38 PM

Change 356066 merged by VolkerE:
[mediawiki/core@master] mw.widgets.DateInputWidget: Remove accidental 'user-select' on PHP widget's input

https://gerrit.wikimedia.org/r/356066

Volker_E closed this task as Resolved.May 29 2017, 4:38 PM
Volker_E assigned this task to matmarex.
Volker_E triaged this task as Normal priority.
Volker_E removed a project: Patch-For-Review.
Jdforrester-WMF added a subscriber: Jdforrester-WMF.

Mass-moving all items tagged for MediaWiki 1.30.0-wmf.3, as that was never released; instead, we're using -wmf.4.