Closed
Bug 1377302
Opened 7 years ago
Closed 7 years ago
Support fill="context-fill" for mozilla-signed WebExtension icons
Categories
(Firefox :: Theme, defect)
Firefox
Theme
Tracking
()
RESOLVED
FIXED
Firefox 56
People
(Reporter: ntim, Assigned: jaws)
References
Details
Attachments
(1 file)
(deleted),
text/x-review-board-request
|
dao
:
review+
lizzard
:
approval-mozilla-beta+
|
Details |
Comment 1•7 years ago
|
||
Calling out that this bug would be required to let Screenshots handle state changes to the icon coming from the browserAction.setIcon method gracefully for users in both light and dark themes.
It also seems like a more elegant way to handle icon color in SVG icons since it future proofs icons against possible changes to theme colors.
Updated•7 years ago
|
Flags: needinfo?(amckay)
Comment hidden (mozreview-request) |
Comment 3•7 years ago
|
||
mozreview-review |
Comment on attachment 8884081 [details]
Bug 1377302 - Support fill='context-fill' for WebExtension browser-actions.
https://reviewboard.mozilla.org/r/155014/#review160062
Attachment #8884081 -
Flags: review+
Updated•7 years ago
|
Assignee: nobody → jaws
Comment 4•7 years ago
|
||
wow, that was easier than i thought!
Comment 5•7 years ago
|
||
mozreview-review |
Comment on attachment 8884081 [details]
Bug 1377302 - Support fill='context-fill' for WebExtension browser-actions.
https://reviewboard.mozilla.org/r/155014/#review160068
::: browser/themes/shared/toolbarbutton-icons.inc.css:12
(Diff revision 1)
> -:-moz-any(@primaryToolbarButtons@) {
> +.toolbarbutton-1 {
> -moz-context-properties: fill;
> fill: var(--toolbarbutton-icon-fill);
> }
>
> toolbar[brighttext] :-moz-any(@primaryToolbarButtons@) {
Should :-moz-any(@primaryToolbarButtons@ be changed here also?
Assignee | ||
Comment 6•7 years ago
|
||
mozreview-review |
Comment on attachment 8884081 [details]
Bug 1377302 - Support fill='context-fill' for WebExtension browser-actions.
https://reviewboard.mozilla.org/r/155014/#review160070
::: browser/themes/shared/toolbarbutton-icons.inc.css:12
(Diff revision 1)
> -:-moz-any(@primaryToolbarButtons@) {
> +.toolbarbutton-1 {
> -moz-context-properties: fill;
> fill: var(--toolbarbutton-icon-fill);
> }
>
> toolbar[brighttext] :-moz-any(@primaryToolbarButtons@) {
Yes, thanks for catching that.
Comment hidden (mozreview-request) |
Updated•7 years ago
|
Flags: needinfo?(amckay)
Comment 8•7 years ago
|
||
I think screenshots will also need this uplifting to beta, so please remember to ask for that.
Comment 9•7 years ago
|
||
Andym... Screenshots 10.3 is in Beta currently.
I'll open a bug with a patch to do a dot bump with new icons icons and we will request uplift for a version when i can test against this patch to ensure we're good with color.
Comment 10•7 years ago
|
||
(In reply to [:jgruen] from comment #9)
> Andym... Screenshots 10.3 is in Beta currently.
Yeah so this patch will need uplifting if it works :)
Comment 11•7 years ago
|
||
Andym, yes! I'm pretty sure i wrote my last comment with one foot in another meeting and one foot out the door :)
Comment 12•7 years ago
|
||
mozreview-review |
Comment on attachment 8884081 [details]
Bug 1377302 - Support fill='context-fill' for WebExtension browser-actions.
https://reviewboard.mozilla.org/r/155014/#review160190
Attachment #8884081 -
Flags: review?(dao+bmo) → review+
Comment 13•7 years ago
|
||
Pushed by mwein@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/657ef58ae035
Support fill='context-fill' for WebExtension browser-actions. r=dao,mattw
Assignee | ||
Comment 14•7 years ago
|
||
[Tracking Requested - why for this release]: Screenshots needs this to allow for their toolbar icon to match the default toolbar icons that ship in Firefox when using Firefox with a dark theme. Screenshots is shipping in v55.
tracking-firefox55:
--- → ?
Comment 15•7 years ago
|
||
bugherder |
Status: NEW → RESOLVED
Closed: 7 years ago
status-firefox56:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → mozilla56
Comment 16•7 years ago
|
||
If "svg.context-properties.content.enabled" is set to false (default), the icon is allways black.
Comment 17•7 years ago
|
||
(In reply to fx4waldi from comment #16)
> If "svg.context-properties.content.enabled" is set to false (default), the
> icon is allways black.
When loaded in a content process, yes. This bug is about toolbar button icons.
Updated•7 years ago
|
Component: WebExtensions: General → Theme
Product: Toolkit → Firefox
Target Milestone: mozilla56 → ---
Updated•7 years ago
|
Target Milestone: --- → Firefox 56
Comment 18•7 years ago
|
||
(In reply to Dão Gottwald [::dao] from comment #17)
> (In reply to fx4waldi from comment #16)
> > If "svg.context-properties.content.enabled" is set to false (default), the
> > icon is allways black.
>
> When loaded in a content process, yes. This bug is about toolbar button
> icons.
The problem occurs on the toolbar buttons added by the webExtension. I tested on a clean profile in Windows 10.
Comment 19•7 years ago
|
||
(In reply to fx4waldi from comment #16)
> If "svg.context-properties.content.enabled" is set to false (default), the
> icon is allways black.
Can confirm after testing on Screenshots. Flipping the pref to true seems to resolve the issue, but it is not resolved by default. I'm not sure what side effects defaulting to true would have globally.
I made a demo webextension to try to completely isolate the what i'm seeing: https://github.com/johngruen/webext-demo
In the svg file you can see that I'm using `fill="context-fill"`. With the `svg.context-properties.content.enabled` defaulted to false, my icon shows up as black. Toggle the pref to true, reload the webextension in about:debugging and it turns white.
Note, I'm on 56.0a1 (2017-07-09) (64-bit)
Flags: needinfo?(jaws)
Reporter | ||
Comment 20•7 years ago
|
||
https://dxr.mozilla.org/mozilla-central/source/layout/svg/SVGContextPaint.cpp#63
The check is missing || scheme.EqualsLiteral("moz-extension")
Tracked for 55 based on comment 1 and Screenshots will go live in 55. Please nominate a patch for uplift to Beta55 soon.
status-firefox55:
--- → affected
Comment 22•7 years ago
|
||
Ritu, calling out that https://bugzilla.mozilla.org/show_bug.cgi?id=1379464 would need uplift as well, since this issue still requires a manual pref flip to enable context set icons
Assignee | ||
Comment 23•7 years ago
|
||
Comment on attachment 8884081 [details]
Bug 1377302 - Support fill='context-fill' for WebExtension browser-actions.
Approval Request Comment
[Feature/Bug causing the regression]: not a regression, needed to support various themes with system add-ons (Screenshots) in v55.
[User impact if declined]: Screenshots will show the wrong color icon if users enable a "dark" theme
[Is this code covered by automated tests?]: no
[Has the fix been verified in Nightly?]: no
[Needs manual test from QE? If yes, steps to reproduce]: no, see bug 1379464
[List of other uplifts needed for the feature/fix]: yes, bug 1379464
[Is the change risky?]: no
[Why is the change risky/not risky?]: simple CSS change to the front-end browser code that allows fill colors to get used by add-ons
[String changes made/needed]:
Flags: needinfo?(jaws)
Attachment #8884081 -
Flags: approval-mozilla-beta?
Assignee | ||
Comment 24•7 years ago
|
||
(In reply to Jared Wein [:jaws] (please needinfo? me) from comment #23)
> [String changes made/needed]: none
Comment on attachment 8884081 [details]
Bug 1377302 - Support fill='context-fill' for WebExtension browser-actions.
Web Extension support, seems low risk, let's uplift for beta 9.
Attachment #8884081 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Comment 26•7 years ago
|
||
bugherder uplift |
Comment 27•7 years ago
|
||
(In reply to Jared Wein [:jaws] (please needinfo? me) from comment #23)
> [Is this code covered by automated tests?]: no
> [Has the fix been verified in Nightly?]: no
> [Needs manual test from QE? If yes, steps to reproduce]: no, see bug 1379464
Setting qe-verify- based on Jared's assessment on manual testing needs.
Flags: qe-verify-
Comment 28•7 years ago
|
||
This bug is not fixed.
Tested using a new profile in 57.0b8.
Still requires `svg.context-properties.content.enabled` to be flipped for icons to properly change colour.
Comment 29•7 years ago
|
||
Still not working in 57.0b10.
Reporter | ||
Updated•7 years ago
|
Summary: Support fill="context-fill" for WebExtension icons → Support fill="context-fill" for mozilla-signed WebExtension icons
Comment 30•7 years ago
|
||
Still not working in 59.0b12.
Still requires `svg.context-properties.content.enabled` to be flipped for icons to properly change color.
Please fix this.
Comment 31•6 years ago
|
||
bug 1512878 has been opened for enabling this for ALL webextension toolbar icons, rather than just mozilla in-house webextensions
You need to log in
before you can comment on or make changes to this bug.
Description
•