-
Notifications
You must be signed in to change notification settings - Fork 675
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[css-backgrounds] Change canonical serialization for box-shadow #2305
Comments
…w/drop-shadow() and implementations. #2305
Pushed out tentative edits, waiting for WG approval. |
Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed from inset? && <length>{2,4} && <color>? to <color>? && <length>{2,4} && inset?. Convert an existing box-shadow text into a testharness.js test in order to test serialization as well.
Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed from inset? && <length>{2,4} && <color>? to <color>? && <length>{2,4} && inset?. Convert an existing box-shadow text into a testharness.js test in order to test serialization as well.
The Working Group just discussed
The full IRC log of that discussion<dael> Topic: [css-backgrounds] Change canonical serialization for box-shadow<dael> github: https://github.com//issues/2305 <dael> TabAtkins: Going by standard rule that default serialization should match grammar that implies color after link but impl oes color before links. We should change grammer to match impl. <dael> Rossen_: Looks like edits were pushed out. So only thing we need to do is get consensus. <dael> Rossen_: Any other opinions as to why we shouldn't do this? <dbaron> This is part of why I am not a fan of that general rule being imposed without doing compatibility testing first... although I think we may have rolled back the rule a bit? <bradk> +1 <AmeliaBR> +1 to matching reality & also other properties <dael> Rossen_: Objections to switch the order to match current impl? <dael> RESOLVED: switch the order to match current implementations |
Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed to the color then lengths. https://drafts.csswg.org/css-text-decor-3/#text-shadow-property also defines the canonical serialization for text-shadow as the color and then lengths. This caused the test to fail in Firefox, Chrome, and Safari. Update the test to match the spec in both instances.
@fantasai I created two PRs for tests that should verify this change; they should be linked to this issue. |
@csnardi If you need more tests, you know that I have 15 tests targeting box-shadow in http://www.gtalbot.org/BrowserBugsSection/CSS3Backgrounds/ http://www.gtalbot.org/BrowserBugsSection/CSS3Backgrounds/box-shadow-021.xht |
@TalbotG Thanks, I didn't know that! I'll take a look at them a little bit later and add in any parsing cases I missed to the first pull request linked above. |
@fantasai Friendly reminder if you have some time for reviewing web-platform-tests/wpt#9800 and web-platform-tests/wpt#9519 which should close out this issue. |
Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed to the color then lengths. https://drafts.csswg.org/css-text-decor-3/#text-shadow-property also defines the canonical serialization for text-shadow as the color and then lengths. This caused the test to fail in Firefox, Chrome, and Safari. Update the test to match the spec in both instances.
Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed from inset? && <length>{2,4} && <color>? to <color>? && <length>{2,4} && inset?. Convert an existing box-shadow text into a testharness.js test in order to test serialization as well.
…ext-shadow, a=testonly Automatic update from web-platform-testsCorrect serialization of box-shadow and text-shadow Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed to the color then lengths. https://drafts.csswg.org/css-text-decor-3/#text-shadow-property also defines the canonical serialization for text-shadow as the color and then lengths. This caused the test to fail in Firefox, Chrome, and Safari. Update the test to match the spec in both instances. wpt-commits: a835486e59a94236a55107fe34925079b33ef247 wpt-pr: 9800 wpt-commits: a835486e59a94236a55107fe34925079b33ef247 wpt-pr: 9800
Automatic update from web-platform-testsTest box-shadow serialization (#9519) Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed from inset? && <length>{2,4} && <color>? to <color>? && <length>{2,4} && inset?. Convert an existing box-shadow text into a testharness.js test in order to test serialization as well. -- wpt-commits: 5a93530d4db27df7a3154d9a5b75a0f36d592c6a wpt-pr: 9519 wpt-commits: 5a93530d4db27df7a3154d9a5b75a0f36d592c6a wpt-pr: 9519
I think the needs testcase label can be removed now. |
…ext-shadow, a=testonly Automatic update from web-platform-testsCorrect serialization of box-shadow and text-shadow Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed to the color then lengths. https://drafts.csswg.org/css-text-decor-3/#text-shadow-property also defines the canonical serialization for text-shadow as the color and then lengths. This caused the test to fail in Firefox, Chrome, and Safari. Update the test to match the spec in both instances. wpt-commits: a835486e59a94236a55107fe34925079b33ef247 wpt-pr: 9800 wpt-commits: a835486e59a94236a55107fe34925079b33ef247 wpt-pr: 9800 UltraBlame original commit: 0b20cccaed6e6890823b8daad46167e0c89f8667
…ext-shadow, a=testonly Automatic update from web-platform-testsCorrect serialization of box-shadow and text-shadow Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed to the color then lengths. https://drafts.csswg.org/css-text-decor-3/#text-shadow-property also defines the canonical serialization for text-shadow as the color and then lengths. This caused the test to fail in Firefox, Chrome, and Safari. Update the test to match the spec in both instances. wpt-commits: a835486e59a94236a55107fe34925079b33ef247 wpt-pr: 9800 wpt-commits: a835486e59a94236a55107fe34925079b33ef247 wpt-pr: 9800 UltraBlame original commit: 0b20cccaed6e6890823b8daad46167e0c89f8667
Automatic update from web-platform-testsTest box-shadow serialization (#9519) Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed from inset? && <length>{2,4} && <color>? to <color>? && <length>{2,4} && inset?. Convert an existing box-shadow text into a testharness.js test in order to test serialization as well. -- wpt-commits: 5a93530d4db27df7a3154d9a5b75a0f36d592c6a wpt-pr: 9519 wpt-commits: 5a93530d4db27df7a3154d9a5b75a0f36d592c6a wpt-pr: 9519 UltraBlame original commit: 897ebf44f505010b0be8d4773368bc926c32315e
…ext-shadow, a=testonly Automatic update from web-platform-testsCorrect serialization of box-shadow and text-shadow Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed to the color then lengths. https://drafts.csswg.org/css-text-decor-3/#text-shadow-property also defines the canonical serialization for text-shadow as the color and then lengths. This caused the test to fail in Firefox, Chrome, and Safari. Update the test to match the spec in both instances. wpt-commits: a835486e59a94236a55107fe34925079b33ef247 wpt-pr: 9800 wpt-commits: a835486e59a94236a55107fe34925079b33ef247 wpt-pr: 9800 UltraBlame original commit: 0b20cccaed6e6890823b8daad46167e0c89f8667
Automatic update from web-platform-testsTest box-shadow serialization (#9519) Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed from inset? && <length>{2,4} && <color>? to <color>? && <length>{2,4} && inset?. Convert an existing box-shadow text into a testharness.js test in order to test serialization as well. -- wpt-commits: 5a93530d4db27df7a3154d9a5b75a0f36d592c6a wpt-pr: 9519 wpt-commits: 5a93530d4db27df7a3154d9a5b75a0f36d592c6a wpt-pr: 9519 UltraBlame original commit: 897ebf44f505010b0be8d4773368bc926c32315e
Automatic update from web-platform-testsTest box-shadow serialization (#9519) Following w3c/csswg-drafts#2305, the canonical serialization for box-shadow was changed from inset? && <length>{2,4} && <color>? to <color>? && <length>{2,4} && inset?. Convert an existing box-shadow text into a testharness.js test in order to test serialization as well. -- wpt-commits: 5a93530d4db27df7a3154d9a5b75a0f36d592c6a wpt-pr: 9519 wpt-commits: 5a93530d4db27df7a3154d9a5b75a0f36d592c6a wpt-pr: 9519 UltraBlame original commit: 897ebf44f505010b0be8d4773368bc926c32315e
The spec declares the syntax for a shadow in
box-shadow
to be:However, Firefox, WebKit, and Chrome all serialize this as
<color>? && <length>{2,4} && inset?
. This matches the serialization fordrop-shadow()
(see https://drafts.fxtf.org/filter-effects/#funcdef-filter-drop-shadow) andtext-shadow
(see https://drafts.csswg.org/css-text-decor-3/#text-shadow-property), which both are declared as<color>? && <length>{2,3}
.For consistency,
<shadow>
should be defined as:in order for serialization to match 3 out of the 4 major browsers and
text-shadow
/drop-shadow()
.The text was updated successfully, but these errors were encountered: