The default bug view has changed. See this FAQ.

[css3-transforms] Unprefix transforms

RESOLVED FIXED in mozilla16

Status

()

Core
CSS Parsing and Computation
RESOLVED FIXED
5 years ago
4 years ago

People

(Reporter: Ms2ger, Assigned: Ms2ger)

Tracking

(Depends on: 4 bugs, Blocks: 1 bug, {dev-doc-complete})

Trunk
mozilla16
dev-doc-complete
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(blocking-kilimanjaro:+)

Details

(Whiteboard: [qa+])

Attachments

(3 attachments, 1 obsolete attachment)

(Assignee)

Description

5 years ago
Filing this bug to track what needs to be done before we unprefix CSS transforms.
(Assignee)

Comment 1

5 years ago
Created attachment 615160 [details] [diff] [review]
Part a: Remove prefixes from functions and enums

We appear to be inconsistent about using moz-prefixes internally. I think it would probably be good to get rid of them already. (Note that the enum is prefixed for transform / transform-origin, but not for backface-visibility / perspective / perspective-origin / transform-style.)
Assignee: nobody → Ms2ger
Status: NEW → ASSIGNED
Attachment #615160 - Flags: review?(dbaron)
(Assignee)

Comment 2

5 years ago
Created attachment 615161 [details] [diff] [review]
Part b: Unprefix

For later.
Comment on attachment 615160 [details] [diff] [review]
Part a: Remove prefixes from functions and enums

>   -. 'id' should be the same as 'name' except that all hyphens ('-')
>-  in 'name' are converted to underscores ('_') in 'id'. This lets us
>-  do nice things with the macros without having to copy/convert strings
>-  at runtime.  These are the names used for the enum values of the
>-  nsCSSProperty enumeration defined in nsCSSProps.h.
>+  in 'name' are converted to underscores ('_') in 'id', and any '-moz-'
>+  prefix is removed in 'id'. This lets us do nice things with the
>+  macros without having to copy/convert strings at runtime.  These are
>+  the names used for the enum values of the nsCSSProperty enumeration
>+  defined in nsCSSProps.h.

I think this should say that *for properties on a standards track*, any '-moz-' prefix is removed in 'id'.  I think we probably still want it for things that aren't standards-track at all, although those a relatively rare.

But otherwise agreed that we should be avoiding prefixes here.

(And we should probably also remove the use of prefixes through nsComputedDOMStyle as well... at least until we get around to bug 264517 which would make the issue moot.)
Attachment #615160 - Flags: review?(dbaron) → review+
(Assignee)

Comment 4

5 years ago
Comment on attachment 615160 [details] [diff] [review]
Part a: Remove prefixes from functions and enums

https://hg.mozilla.org/mozilla-central/rev/5852f4fd12f8
Attachment #615160 - Flags: checkin+

Updated

5 years ago
blocking-kilimanjaro: --- → ?
Transforms were heavily shown as evidence to being a problem in John Jensen's report with top sites. Nominating for kilimanjaro, as this affects many top sites.

Updated

5 years ago
blocking-kilimanjaro: ? → +

Updated

5 years ago
Depends on: 689498, 735373, 726766, 732153

Comment 6

5 years ago
Matt: Please review the 4 bugs I added as "blockers." We need to determine if we should fix those issues prior to unprefixing.

Comment 7

5 years ago
Note, the CSS Working Group has agreed to give the go-ahead to browser implementers to unprefix CSS3 Transitions, Transforms, and Animations:

http://lists.w3.org/Archives/Public/www-style/2012Jun/0105.html
(Assignee)

Comment 8

5 years ago
Do we want to keep supporting the -moz- versions for now? If not, we'll need a patch to fix the places where we use those.
(In reply to :Ms2ger from comment #8)
> Do we want to keep supporting the -moz- versions for now? If not, we'll need
> a patch to fix the places where we use those.

For now, yes, though we probably want to go through the tree sooner rather than later.

(Better to do the search-and-replace closer to adding support for unprefixed, and then another pass (to fix stuff that was in people's trees or copied) before landing the removal of the prefixed support.)
Comment on attachment 615161 [details] [diff] [review]
Part b: Unprefix

You're probably going to want to add aliases to nsCSSPropAliasList and nsIDOMCSS2Properties for the prefixed versions, for now.  (Probably not for too long, though.)
Comment on attachment 615161 [details] [diff] [review]
Part b: Unprefix

And I think you're at the very least going to need to update the tests in layout/style/ at the same time as this.

Updated

5 years ago
Keywords: dev-doc-needed
(Assignee)

Comment 12

5 years ago
Created attachment 636145 [details] [diff] [review]
Part b: Unprefix and update tests in layout/style

I don't really have time to fix up the whole tree at the moment; can I push that to a followup?
Attachment #615161 - Attachment is obsolete: true
Attachment #636145 - Flags: review?(dbaron)
Comment on attachment 636145 [details] [diff] [review]
Part b: Unprefix and update tests in layout/style

Re-sort the tests in test_transitions_per_property.html and r=dbaron.

Sorry for the delay.
Attachment #636145 - Flags: review?(dbaron) → review+
Comment on attachment 636145 [details] [diff] [review]
Part b: Unprefix and update tests in layout/style

And also:

>diff --git a/dom/interfaces/css/nsIDOMCSS2Properties.idl b/dom/interfaces/css/nsIDOMCSS2Properties.idl

need to rev IID
(Assignee)

Comment 15

5 years ago
Comment on attachment 636145 [details] [diff] [review]
Part b: Unprefix and update tests in layout/style

https://hg.mozilla.org/mozilla-central/rev/4004407a1f49
Attachment #636145 - Flags: checkin+
(Assignee)

Updated

5 years ago
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla16
John - Do you have a list of top sites that use -moz-transform? We could probably QA to do a quick pass to make sure nothing looks busted.

Jean-Yves - Can you get the MDN doc up to date for transforms?

David - If I understand correctly, unprefixing transforms is low risk for regressions, right? Is there anything special a web developer needs to do to migrate from using -moz-transform to the unprefixed version?
Whiteboard: [qa+]

Comment 17

5 years ago
May need additional unprefixing in this Layout test:
layout/base/tests/test_bug731777.html
(Assignee)

Updated

5 years ago
Depends on: 770560

Updated

5 years ago
Blocks: 772342

Updated

5 years ago
Blocks: 772462

Updated

5 years ago
Blocks: 772463

Comment 18

5 years ago
Created attachment 640857 [details]
List of top domains that use -moz-transform, collected using Fennec UA

> John - Do you have a list of top sites that use -moz-transform? We could probably QA to do a quick pass to make sure nothing looks busted.

Sorry about the delay in seeing/replying to this; was on PTO. See attached.

Updated

5 years ago
Blocks: 775235
Mention has been added in:
https://developer-new.mozilla.org/en-US/docs/Firefox_16_for_developers

And I've updated:
https://developer-new.mozilla.org/en-US/docs/CSS/backface-visibility
https://developer-new.mozilla.org/en-US/docs/CSS/perspective
https://developer-new.mozilla.org/en-US/docs/CSS/perspective-origin
https://developer-new.mozilla.org/en-US/docs/CSS/transform
https://developer-new.mozilla.org/en-US/docs/CSS/transform-origin
https://developer-new.mozilla.org/en-US/docs/CSS/transform-style
https://developer-new.mozilla.org/en-US/docs/CSS/Using_CSS_transforms

The expermimental banner will be removed when the spec reach CR. Also this is living on developer-new until Kuma is launched.
Keywords: dev-doc-needed → dev-doc-complete

Updated

5 years ago
Depends on: 790915
Depends on: 802285

Updated

5 years ago
No longer depends on: 802285
Depends on: 802285

Updated

5 years ago
Depends on: 803126

Updated

5 years ago
Depends on: 807636
Blocks: 814214

Updated

4 years ago
Depends on: 849203
You need to log in before you can comment on or make changes to this bug.