Page MenuHomePhabricator

Valid input in TagMultiselectWidget flagged as invalid on Special:ApiSandbox
Closed, ResolvedPublic

Description

Steps to reproduce:

  1. Go to https://en.wikipedia.org/wiki/Special:ApiSandbox.
  2. Select action=query, change to that page.
  3. Enable prop, type "c", select "categories" from the list.

Alternatively, in step 3 you can type "categories" and press enter, without using the list.

Expected: Input is valid, so it shouldn't be flagged.
Actual: Border and cursor are red, indicating an invalid input.

Removing the focus from the input fixes the display (until the next time you enter something via keyboard), but shouldn't be necessary.

Event Timeline

Schnark created this task.Dec 1 2018, 10:27 AM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptDec 1 2018, 10:27 AM
Anomie added a subscriber: Anomie.

Nothing to do with the API here, it affects any use of TagMultiselectWidget with a list of allowed values. In core I see Special:ActiveUsers is also affected.

It's not just invalid, it's a weird semi-valid semi-invalid border. It should never be half red, half blue.

Looks similar to T199838: [Regression wmf.13] Input field getting both red and blue highlight at the same time in Citation dialog (not sure if it's actually relevant, but maybe it helps in some debugging).

I can see the red-blue border in Vector, but Timeless has a completely red border.

Tchanders added a subscriber: Tchanders.EditedDec 5 2018, 2:51 PM

This is affecting the TitlesMultiselectWidget on Special:Block too (with partial blocks enabled).

Change 477792 had a related patch set uploaded (by Tchanders; owner: Tchanders):
[oojs/ui@master] OO.ui.TagMultiselectWidget: Allow empty input to be valid

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

Volker_E moved this task from Backlog to Reviewing on the OOUI board.Dec 5 2018, 4:07 PM

Change 477792 merged by jenkins-bot:
[oojs/ui@master] OO.ui.MenuTagMultiselectWidget: Clear input before adding tag

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

Change 481239 had a related patch set uploaded (by Jforrester; owner: Jforrester):
[mediawiki/core@master] Update OOUI to v0.30.0

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

Change 481239 merged by jenkins-bot:
[mediawiki/core@master] Update OOUI to v0.30.0

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

Jdforrester-WMF closed this task as Resolved.Jan 1 2019, 4:07 PM
Jdforrester-WMF assigned this task to Tchanders.