Bug 48704 - Percentage z offset in transform-origin should make the property invalid
: Percentage z offset in transform-origin should make the property invalid
Status: RESOLVED FIXED
Product: WebKit
Classification: Unclassified
Component: CSS
: 528+ (Nightly build)
: All Mac OS X 10.5
: P2 Normal
Assigned To: Nobody
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2010-10-29 18:11 PDT by Simon Fraser (smfr)
Modified: 2010-11-27 06:18 PST (History)
3 users (show)

See Also:


Attachments
Patch (7.47 KB, patch)
2010-11-21 01:54 PST, Rob Buis
no flags Details | Formatted Diff | Diff
I noticed that unfortunately my previous patch caused regressions, sorry about that! This one causes no regressions but ofcourse needs to rechecked. Cheers, Rob (7.74 KB, patch)
2010-11-23 23:35 PST, Rob Buis
simon.fraser: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Simon Fraser (smfr) 2010-10-29 18:11:39 PDT
transform-origin: 20% 10% 30%; should be ignored, since the % value for z offset is invalid.
Comment 1 Rob Buis 2010-11-21 01:54:46 PST
Created attachment 74497 [details]
Patch
Comment 2 Simon Fraser (smfr) 2010-11-21 08:31:41 PST
Comment on attachment 74497 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=74497&action=review

> LayoutTests/fast/css/script-tests/transform-origin-parsing.js:18
> +shouldBe('test("-webkit-transform-origin: 10px 10px 10px", "-webkit-transform-origin")', '"10px 10px 10px"');

It might be good to also test a lack of units on the z value:
"-webkit-transform-origin: 10px 10px 10"
This should not parse.
Comment 3 Rob Buis 2010-11-21 09:25:32 PST
Hi Simon,

(In reply to comment #2)
> (From update of attachment 74497 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=74497&action=review
> 
> > LayoutTests/fast/css/script-tests/transform-origin-parsing.js:18
> > +shouldBe('test("-webkit-transform-origin: 10px 10px 10px", "-webkit-transform-origin")', '"10px 10px 10px"');
> 
> It might be good to also test a lack of units on the z value:
> "-webkit-transform-origin: 10px 10px 10"
> This should not parse.

I added it locally and unfortunately it does parse. It is due to the m_strict usage in
parseTransformOriginShorthand, should I force it to true? Or is that something for
another patch/bug?
Cheers,

Rob.
Comment 4 Rob Buis 2010-11-23 23:35:49 PST
Created attachment 74724 [details]
I noticed that unfortunately my previous patch caused regressions, sorry about that! This one causes no regressions but ofcourse needs to rechecked. Cheers, Rob
Comment 5 Simon Fraser (smfr) 2010-11-26 10:26:27 PST
(In reply to comment #3)
> I added it locally and unfortunately it does parse. It is due to the m_strict usage in
> parseTransformOriginShorthand, should I force it to true? Or is that something for
> another patch/bug?

Hm, maybe that is expected to work. Let's leave that for another patch (if indeed it needs fixing).
Comment 6 Rob Buis 2010-11-27 06:18:24 PST
Landed in r72776.