Page MenuHomePhabricator

Disabled icon on any ButtonWidget should be gray. Currently `constructive` (colored).
Closed, ResolvedPublic1 Estimated Story Points

Description

Screenshot 2015-09-28 15.16.20.png (60×292 px, 13 KB)

Event Timeline

violetto assigned this task to Volker_E.
violetto raised the priority of this task from to Needs Triage.
violetto updated the task description. (Show Details)
violetto added subscribers: Aklapper, violetto.

@violetto This isn't possible with the current implementation of SVG icons, we'd need to go for an inline SVG solution, where we can use the CSS fill property on those SVGs.

@violetto This isn't possible with the current implementation of SVG icons, we'd need to go for an inline SVG solution, where we can use the CSS fill property on those SVGs.

We already generate a grey and green variant of this icon. It's already used by the non-constructive disabled variant of the widget:

Screen Shot 2016-02-22 at 20.38.29.png (266×712 px, 28 KB)

Seems like this is simply a selector issue. The constructive selector is overriding the disabled selector. If we give the latter more weight, it should resolve itself.

@Krinkle It's not the selector only, it's the way OOjs UI connects the icon variants to the selectors. It's all done in a build step from JSON files. https://phabricator.wikimedia.org/diffusion/GOJU/browse/master/src/themes/mediawiki/icons.json;7e71548b739e8a70f9136f706c61f6baf550c0d8$68
Without explicitly defining "disabled" as variant and programmatically adding that variant class to the corresponding element it's not changeable by selector.

Change 272626 had a related patch set uploaded (by VolkerE):
MediaWiki theme: Disabled buttonElement icon should be gray

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

Patch adds filter: grayscale() to icon – currently available in Firefox 35+ and Edge behind flag. Blink doesn't support filters on SVGs yet.

Volker_E renamed this task from Disabled icon on any ButtonWidget should be gray. Currently green. to Disabled icon on any ButtonWidget should be gray. Currently `constructive` (colored). .Mar 11 2016, 12:47 AM

Change 272626 merged by jenkins-bot:
MediaWiki theme: Disabled ButtonElement icon should not be colored

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

Jdforrester-WMF triaged this task as Medium priority.
Jdforrester-WMF moved this task from Backlog to OOjs-UI-0.16.3 on the OOUI board.
Jdforrester-WMF edited projects, added OOUI (OOjs-UI-0.16.3); removed OOUI.
Jdforrester-WMF removed a project: Patch-For-Review.
Jdforrester-WMF set the point value for this task to 1.