Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(507)

Issue 1824283002: Ensure that we don't allow 'normal' alongside other values in content property (Closed)

Created:
4 years, 9 months ago by nainar
Modified:
4 years, 8 months ago
Reviewers:
Timothy Loh
CC:
darktears, apavlov+blink_chromium.org, blink-reviews, blink-reviews-css, chromium-reviews, dglazkov+blink, rwlbuis
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Ensure that we don't allow 'normal' alongside other values in content property Currently Chrome accepts a list of values that include "normal" along with other values as an acceptable input for CSS property content. This breaks from the spec stated here: https://drafts.csswg.org/css2/generate.html#content where "normal" is only accepted as a valid input if it is the only value assigned to content. This patch fixes that behaviour. Other browsers (FF, IE and Edge are consistent with spec here.) Committed: https://crrev.com/ae95f37d78cfa0a3d0cc28e89531d68050c1c707 Cr-Commit-Position: refs/heads/master@{#383690}

Patch Set 1 #

Patch Set 2 : #

Patch Set 3 : #

Total comments: 5

Patch Set 4 : #

Total comments: 4

Patch Set 5 : #

Total comments: 2

Patch Set 6 : #

Unified diffs Side-by-side diffs Delta from patch set Stats (+45 lines, -3 lines) Patch
M third_party/WebKit/LayoutTests/css-parser/content-parsing.html View 1 2 3 1 chunk +10 lines, -0 lines 0 comments Download
A third_party/WebKit/LayoutTests/css-parser/content-parsing-invalid.html View 1 chunk +21 lines, -0 lines 0 comments Download
M third_party/WebKit/LayoutTests/fast/css/content/content-none.html View 1 2 3 4 5 1 chunk +3 lines, -0 lines 0 comments Download
M third_party/WebKit/Source/core/css/parser/CSSPropertyParser.cpp View 1 1 chunk +5 lines, -2 lines 0 comments Download
M third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp View 1 2 3 4 5 2 chunks +6 lines, -1 line 0 comments Download

Dependent Patchsets:

Messages

Total messages: 29 (14 generated)
nainar
@timloh, PTAL? Thanks!
4 years, 9 months ago (2016-03-23 06:31:22 UTC) #2
Timothy Loh
Surely this will hit an crash/assert in applyValueCSSPropertyCustom? :\ Patch title should give more detail, ...
4 years, 9 months ago (2016-03-23 06:45:48 UTC) #3
nainar
Tim, I've edited the patch description as well as added more cases to the layout ...
4 years, 9 months ago (2016-03-24 04:31:44 UTC) #5
Timothy Loh
The linked bug isn't relevant. In fact I think for the other patch you're better ...
4 years, 9 months ago (2016-03-24 04:38:41 UTC) #6
nainar
@timloh, PTAL? Thanks! https://codereview.chromium.org/1824283002/diff/40001/third_party/WebKit/LayoutTests/css-parser/content-parsing.html File third_party/WebKit/LayoutTests/css-parser/content-parsing.html (right): https://codereview.chromium.org/1824283002/diff/40001/third_party/WebKit/LayoutTests/css-parser/content-parsing.html#newcode12 third_party/WebKit/LayoutTests/css-parser/content-parsing.html:12: assert_invalid_value("content", 'normal "a"'); Done. https://codereview.chromium.org/1824283002/diff/40001/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp File ...
4 years, 8 months ago (2016-03-29 00:56:39 UTC) #9
Timothy Loh
ok lgtm https://codereview.chromium.org/1824283002/diff/60001/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp File third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp (right): https://codereview.chromium.org/1824283002/diff/60001/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp#newcode733 third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp:733: // normal and none do not have ...
4 years, 8 months ago (2016-03-29 03:10:54 UTC) #10
nainar
Made the changes, committing. Thanks for the review! https://codereview.chromium.org/1824283002/diff/60001/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp File third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp (right): https://codereview.chromium.org/1824283002/diff/60001/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp#newcode733 third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp:733: // ...
4 years, 8 months ago (2016-03-29 06:37:49 UTC) #11
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1824283002/80001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1824283002/80001
4 years, 8 months ago (2016-03-29 06:38:06 UTC) #14
Timothy Loh
https://codereview.chromium.org/1824283002/diff/80001/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp File third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp (right): https://codereview.chromium.org/1824283002/diff/80001/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp#newcode739 third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp:739: state.style()->clearContent(); ...this is wrong, this just makes us never ...
4 years, 8 months ago (2016-03-29 06:51:38 UTC) #15
Timothy Loh
https://codereview.chromium.org/1824283002/diff/80001/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp File third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp (right): https://codereview.chromium.org/1824283002/diff/80001/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp#newcode733 third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp:733: // normal and none do not have any effect. ...
4 years, 8 months ago (2016-03-29 06:52:40 UTC) #16
nainar
changed the comment to remove reference to normal. Not adding the asserts as per discussed.
4 years, 8 months ago (2016-03-29 07:28:52 UTC) #19
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1824283002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1824283002/100001
4 years, 8 months ago (2016-03-29 07:29:15 UTC) #22
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1824283002/100001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1824283002/100001
4 years, 8 months ago (2016-03-29 07:30:25 UTC) #26
commit-bot: I haz the power
Committed patchset #6 (id:100001)
4 years, 8 months ago (2016-03-29 08:44:24 UTC) #27
commit-bot: I haz the power
4 years, 8 months ago (2016-03-29 08:45:29 UTC) #29
Message was sent while issue was closed.
Patchset 6 (id:??) landed as
https://crrev.com/ae95f37d78cfa0a3d0cc28e89531d68050c1c707
Cr-Commit-Position: refs/heads/master@{#383690}

Powered by Google App Engine
This is Rietveld 408576698