Changeset 276551 in webkit


Ignore:
Timestamp:
Apr 24, 2021 12:32:35 PM (15 months ago)
Author:
graouts@webkit.org
Message:

Computed style for the translate CSS property should use px for the z value
https://bugs.webkit.org/show_bug.cgi?id=225018

Reviewed by Dean Jackson.

LayoutTests/imported/w3c:

Mark a single WPT progression.

  • web-platform-tests/css/css-transforms/animation/translate-composition-expected.txt:
  • web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-002-expected.txt:

Source/WebCore:

  • css/CSSComputedStyleDeclaration.cpp:

(WebCore::computedTranslate):

Location:
trunk
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/LayoutTests/imported/w3c/ChangeLog

    r276521 r276551  
     12021-04-24  Antoine Quint  <graouts@webkit.org>
     2
     3        Computed style for the translate CSS property should use px for the z value
     4        https://bugs.webkit.org/show_bug.cgi?id=225018
     5
     6        Reviewed by Dean Jackson.
     7
     8        Mark a single WPT progression.
     9
     10        * web-platform-tests/css/css-transforms/animation/translate-composition-expected.txt:
     11        * web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-002-expected.txt:
     12
    1132021-04-23  Cathie Chen  <cathiechen@igalia.com>
    214
  • trunk/LayoutTests/imported/w3c/web-platform-tests/css/css-transforms/animation/translate-composition-expected.txt

    r274353 r276551  
    11
    2 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (-1) should be [-100% calc(200px + 100%) 300px] assert_equals: expected "0px 200px 300 " but got "- 100px "
    3 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (0) should be [calc(50px + 0%) calc(200px + 50%) 300px] assert_equals: expected "50px 200px 300 " but got "- 50px "
    4 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (0.25) should be [calc(62.5px + 25%) calc(200px + 37.5%) 300px] assert_equals: expected "62.5px 200px 300 " but got "- 37.5px "
    5 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (0.75) should be [calc(87.5px + 75%) calc(200px + 12.5%) 300px] assert_equals: expected "87.5px 200px 300 " but got "- 12.5px "
    6 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (1) should be [calc(100px + 100%) calc(200px + 0%) 300px] assert_equals: expected "100px 200px 300 " but got "0px "
    7 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (2) should be [calc(150px + 200%) calc(200px - 50%) 300px] assert_equals: expected "150px 200px 300 " but got "50px "
    8 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (-1) should be [100% calc(600px - 50%) 500px] assert_equals: expected "0px 600px 500 " but got "- 200px 200px - 100 "
    9 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (0) should be [calc(100px + 50%) calc(300px + 0%) 300px] assert_equals: expected "100px 300px 300 " but got "0px 100px "
    10 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (0.25) should be [calc(125px + 37.5%) calc(225px + 12.5%) 250px] assert_equals: expected "125px 225px 250 " but got "50px 75px 25 "
    11 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (0.75) should be [calc(175px + 12.5%) calc(75px + 37.5%) 150px] assert_equals: expected "175px 75px 150 " but got "150px 25px 75 "
     2FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (-1) should be [-100% calc(200px + 100%) 300px] assert_equals: expected "0px 200px 300px " but got "- 100px "
     3FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (0) should be [calc(50px + 0%) calc(200px + 50%) 300px] assert_equals: expected "50px 200px 300px " but got "- 50px "
     4FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (0.25) should be [calc(62.5px + 25%) calc(200px + 37.5%) 300px] assert_equals: expected "62.5px 200px 300px " but got "- 37.5px "
     5FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (0.75) should be [calc(87.5px + 75%) calc(200px + 12.5%) 300px] assert_equals: expected "87.5px 200px 300px " but got "- 12.5px "
     6FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (1) should be [calc(100px + 100%) calc(200px + 0%) 300px] assert_equals: expected "100px 200px 300px " but got "0px "
     7FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [-50px 50%] to add [100%] at (2) should be [calc(150px + 200%) calc(200px - 50%) 300px] assert_equals: expected "150px 200px 300px " but got "50px "
     8FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (-1) should be [100% calc(600px - 50%) 500px] assert_equals: expected "0px 600px 500px " but got "- 200px 200px - 100px "
     9FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (0) should be [calc(100px + 50%) calc(300px + 0%) 300px] assert_equals: expected "100px 300px 300px " but got "0px 100px "
     10FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (0.25) should be [calc(125px + 37.5%) calc(225px + 12.5%) 250px] assert_equals: expected "125px 225px 250px " but got "50px 75px 25px "
     11FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (0.75) should be [calc(175px + 12.5%) calc(75px + 37.5%) 150px] assert_equals: expected "175px 75px 150px " but got "150px 25px 75px "
    1212PASS Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (1) should be [calc(200px + 0%) 50% 100px]
    13 FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (2) should be [calc(300px - 50%) calc(-300px + 100%) -100px] assert_equals: expected "300px - 300px - 100 " but got "400px - 100px 200 "
    14 FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (-1) should be [calc(-300px + 100%) -50% -400px] assert_equals: expected "- 300px 0px - 400 " but got "- 200px 200px - 100 "
     13FAIL Compositing: property <translate> underlying [100px 200px 300px] from add [50% 100px] to replace [200px 50% 100px] at (2) should be [calc(300px - 50%) calc(-300px + 100%) -100px] assert_equals: expected "300px - 300px - 100px " but got "400px - 100px 200px "
     14FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (-1) should be [calc(-300px + 100%) -50% -400px] assert_equals: expected "- 300px 0px - 400px " but got "- 200px 200px - 100px "
    1515PASS Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (0) should be [50%  calc(100px + 0%)]
    16 FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (0.25) should be [calc(75px + 37.5%) calc(125px + 12.5%) 100px] assert_equals: expected "75px 125px 100 " but got "50px 75px 25 "
    17 FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (0.75) should be [calc(225px + 12.5%) calc(175px + 37.5%) 300px] assert_equals: expected "225px 175px 300 " but got "150px 25px 75 "
    18 FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (1) should be [calc(300px + 0%) calc(200px + 50%) 400px] assert_equals: expected "300px 200px 400 " but got "200px 0px 100 "
    19 FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (2) should be [calc(600px - 50%) calc(300px + 100%) 800px] assert_equals: expected "600px 300px 800 " but got "400px - 100px 200 "
     16FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (0.25) should be [calc(75px + 37.5%) calc(125px + 12.5%) 100px] assert_equals: expected "75px 125px 100px " but got "50px 75px 25px "
     17FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (0.75) should be [calc(225px + 12.5%) calc(175px + 37.5%) 300px] assert_equals: expected "225px 175px 300px " but got "150px 25px 75px "
     18FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (1) should be [calc(300px + 0%) calc(200px + 50%) 400px] assert_equals: expected "300px 200px 400px " but got "200px 0px 100px "
     19FAIL Compositing: property <translate> underlying [100px 200px 300px] from replace [50% 100px] to add [200px 50% 100px] at (2) should be [calc(600px - 50%) calc(300px + 100%) 800px] assert_equals: expected "600px 300px 800px " but got "400px - 100px 200px "
    2020PASS Compositing: property <translate> underlying [none] from replace [none] to add [100px] at (-1) should be [-100px]
    2121PASS Compositing: property <translate> underlying [none] from replace [none] to add [100px] at (0) should be [none]
     
    4242PASS Compositing: property <translate> underlying [none] from replace [0px 40px 60px] to add [none] at (1) should be [none]
    4343PASS Compositing: property <translate> underlying [none] from replace [0px 40px 60px] to add [none] at (2) should be [0px -40px -60px]
    44 FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (-1) should be [160px 0px -60px] assert_equals: expected "160px 0px - 60 " but got "0px - 40px - 60 "
     44FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (-1) should be [160px 0px -60px] assert_equals: expected "160px 0px - 60px " but got "0px - 40px - 60px "
    4545FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (0) should be [80px 20px] assert_equals: expected "80px 20px " but got "none "
    46 FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (0.25) should be [60px 25px 15px] assert_equals: expected "60px 25px 15 " but got "0px 10px 15 "
    47 FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (0.5) should be [40px 30px 30px] assert_equals: expected "40px 30px 30 " but got "0px 20px 30 "
    48 FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (0.75) should be [20px 35px 45px] assert_equals: expected "20px 35px 45 " but got "0px 30px 45 "
     46FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (0.25) should be [60px 25px 15px] assert_equals: expected "60px 25px 15px " but got "0px 10px 15px "
     47FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (0.5) should be [40px 30px 30px] assert_equals: expected "40px 30px 30px " but got "0px 20px 30px "
     48FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (0.75) should be [20px 35px 45px] assert_equals: expected "20px 35px 45px " but got "0px 30px 45px "
    4949PASS Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (1) should be [0px 40px 60px]
    50 FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (2) should be [-80px 60px 120px] assert_equals: expected "- 80px 60px 120 " but got "0px 80px 120 "
    51 FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (-1) should be [160px 120px 120px] assert_equals: expected "160px 120px 120 " but got "0px 80px 120 "
    52 FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (0) should be [80px 60px 60px] assert_equals: expected "80px 60px 60 " but got "0px 40px 60 "
    53 FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (0.25) should be [60px 45px 45px] assert_equals: expected "60px 45px 45 " but got "0px 30px 45 "
    54 FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (0.5) should be [40px 30px 30px] assert_equals: expected "40px 30px 30 " but got "0px 20px 30 "
    55 FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (0.75) should be [20px 15px 15px] assert_equals: expected "20px 15px 15 " but got "0px 10px 15 "
     50FAIL Compositing: property <translate> underlying [80px 20px] from add [none] to replace [0px 40px 60px] at (2) should be [-80px 60px 120px] assert_equals: expected "- 80px 60px 120px " but got "0px 80px 120px "
     51FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (-1) should be [160px 120px 120px] assert_equals: expected "160px 120px 120px " but got "0px 80px 120px "
     52FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (0) should be [80px 60px 60px] assert_equals: expected "80px 60px 60px " but got "0px 40px 60px "
     53FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (0.25) should be [60px 45px 45px] assert_equals: expected "60px 45px 45px " but got "0px 30px 45px "
     54FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (0.5) should be [40px 30px 30px] assert_equals: expected "40px 30px 30px " but got "0px 20px 30px "
     55FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (0.75) should be [20px 15px 15px] assert_equals: expected "20px 15px 15px " but got "0px 10px 15px "
    5656PASS Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (1) should be [none]
    57 FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (2) should be [-80px -60px -60px] assert_equals: expected "- 80px - 60px - 60 " but got "0px - 40px - 60 "
     57FAIL Compositing: property <translate> underlying [80px 20px] from add [0px 40px 60px] to replace [none] at (2) should be [-80px -60px -60px] assert_equals: expected "- 80px - 60px - 60px " but got "0px - 40px - 60px "
    5858
  • trunk/LayoutTests/imported/w3c/web-platform-tests/web-animations/animation-model/animation-types/interpolation-per-property-002-expected.txt

    r276231 r276551  
    217217PASS translate with two unspecified values
    218218PASS translate with one unspecified value
    219 FAIL translate with all three values specified assert_equals: The value should be 300px 100px 200px at 500ms expected "300px 100px 200px" but got "300px 100px 200"
    220 FAIL translate with combination of percentages and lengths assert_equals: The value should be calc(0% + 200px) calc(25% - 50.5px) 200px at 500ms expected "calc(0% + 200px) calc(25% - 50.5px) 200px" but got "200px -50.5px 200"
     219PASS translate with all three values specified
     220FAIL translate with combination of percentages and lengths assert_equals: The value should be calc(0% + 200px) calc(25% - 50.5px) 200px at 500ms expected "calc(0% + 200px) calc(25% - 50.5px) 200px" but got "200px -50.5px 200px"
    221221PASS scale (type: scaleList) has testInterpolation function
    222222PASS scale with two unspecified values
  • trunk/Source/WebCore/ChangeLog

    r276550 r276551  
     12021-04-24  Antoine Quint  <graouts@webkit.org>
     2
     3        Computed style for the translate CSS property should use px for the z value
     4        https://bugs.webkit.org/show_bug.cgi?id=225018
     5
     6        Reviewed by Dean Jackson.
     7
     8        * css/CSSComputedStyleDeclaration.cpp:
     9        (WebCore::computedTranslate):
     10
    1112021-04-24  Tyler Wilcock  <twilco.o@protonmail.com>
    212
  • trunk/Source/WebCore/css/CSSComputedStyleDeclaration.cpp

    r276488 r276551  
    624624        list->append(zoomAdjustedPixelValue(transform.m41(), style));
    625625        list->append(zoomAdjustedPixelValue(transform.m42(), style));
    626         list->append(zoomAdjustedNumberValue(transform.m43(), style));
     626        list->append(zoomAdjustedPixelValue(transform.m43(), style));
    627627    }
    628628
Note: See TracChangeset for help on using the changeset viewer.