Closed Bug 1340014 Opened 5 years ago Closed 5 years ago

Investigate -moz-appearance inline usage (not in a style sheet file) in add-ons

Categories

(Firefox :: General, defect)

defect
Not set
normal

Tracking

()

RESOLVED WONTFIX
Tracking Status
firefox54 --- affected

People

(Reporter: MatsPalmgren_bugz, Unassigned)

References

Details

Boris had a concern regarding add-ons that use the CSS -moz-appearance property,
but not from a chrome sheet:
https://groups.google.com/forum/#!msg/mozilla.dev.platform/oZ9cPF8Y1pE/tR75Na-gBQAJ

> "Chrome sheets", for purposes of this discussion are sheets whose URI
> starts with "chrome://".
> 
> The biggest worry for me is that inline style is never a "chrome sheet"
> in this sense.
> 
> -Boris

When bug 1333482 lands, those will stop having an effect.  So it seems prudent
to search our database of add-ons and look for such uses of -moz-appearance
to see if that will break some add-ons.

I don't think I have the necessary skills, nor the access required, so I need
some help with gathering this data.
Jet, can you help me find an owner for this bug please?

(I'll hold off from landing bug 1333482 until we have some data on this, but it'd
be nice to have data soon-ish to avoid the patch set bit-rotting to bad.)
Blocks: 1333482
Flags: needinfo?(bugs)
Can we defer the "make -moz-apearance UA-sheet-only" part and ship the rest of it now? Maybe add a deprecation warning in the console for good measure?
That is, we can let the -moz prefix linger a bit after landing an unprefixed API, then we file a follow-up for the removal.
Flags: needinfo?(bugs)
Yeah, I guess we could enable both prefs so that all three properties
(-moz-appearance/appearance/-webkit-appearance) are available everywhere.

I'd like to avoid doing that though, for two reasons:
1. ignoring -moz-appearance is likely more web-compatible
2. we need to turn it off sooner or later anyway, so I don't
   think we gain much by waiting

So I think we should gather the data first before we make a decision.
(In reply to Mats Palmgren (:mats) from comment #4)
> Yeah, I guess we could enable both prefs so that all three properties
> (-moz-appearance/appearance/-webkit-appearance) are available everywhere.
> 
> I'd like to avoid doing that though, for two reasons:
> 1. ignoring -moz-appearance is likely more web-compatible

I'm not sure I follow. Shipping as proposed will be more web-compatible than what we ship today. The concern is about usage in add-ons, not the Web.

> 2. we need to turn it off sooner or later anyway, so I don't
>    think we gain much by waiting

We get to ship today, which is a good thing, I think.

> 
> So I think we should gather the data first before we make a decision.

I bet you're more likely to learn what you seek by shipping (behind #ifndef RELEASE if needed.) The top 20 add-ons [1] that are 95% of all add-ons used are the ones that will affect this decision, and we tend to hear about breaking changes real quickly.

We've unprefixed many CSS and DOM keywords this way [2] and it seems to work OK.

[1] https://addons.mozilla.org/en-US/firefox/extensions/?sort=users
[2] https://bugzilla.mozilla.org/show_bug.cgi?id=775235
I believe shipping support for all three properties is less web-compatible
than shipping support for only appearance/-webkit-appearance.
(Bug 1328474 would not have happened for example.)

> ... we tend to hear about breaking changes real quickly

It just seem unnecessary to do that if we have the data to determine that's
what will happen.

I don't feel that strongly about it though, so if you think it's not necessary
then I'll just land it and see what breaks.
On second thought, I think I'll just land it.  The effects of ignoring -moz-appearance
is fairly benign after all.
Status: NEW → RESOLVED
Closed: 5 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.