New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 641877 link

Starred by 17 users

Issue metadata

Status: Started
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 2
Type: Task


Sign in to add a comment

Houdini: CSS Properties and Values API Level 1

Project Member Reported by timloh@chromium.org, Aug 29 2016

Issue description

Change description:
The CSS Properties and Values API spec defines an registerProperty() function which can be called from JavaScript to register typed and animatable custom CSS properties. This API expands the existing CSS custom properties to improve usability of other Houdini APIs. Being able to animate these and customise inheritance and initial values makes it more useful for custom layout/paint, and having types associated with these allows the typed OM to work more effectively with custom properties.

Changes to API surface:
New API: CSS.registerProperty(), CSS.unregisterProperty()

Links:
Spec: https://drafts.css-houdini.org/css-properties-values-api/

Support in other browsers:
Internet Explorer: Not implemented
Firefox: Implementation in progress https://bugzilla.mozilla.org/show_bug.cgi?id=1273706
Safari: Not implemented
 
Project Member

Comment 1 by bugdroid1@chromium.org, Sep 8 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/01ce431409e3a019858677626a983c55168da6dc

commit 01ce431409e3a019858677626a983c55168da6dc
Author: timloh <timloh@chromium.org>
Date: Thu Sep 08 09:22:33 2016

Skeleton implementation of CSS Properties and Values API

This patch provides a basic skeleton implementation of the
CSS Properties and Values API. In particular, the pipeline from
registration to reading from computed styles is supported but with
many missing bits along the way.

Some of the missing bits:
- Only * and <length> syntax supported with trivial parsing logic.
- All properties assumed to be inherited.
- Computation logic is currently a no-op (needs to resolve ems, etc.)
- CSSOM on specified styles aren't yet affected by (un)registration

Spec: https://drafts.css-houdini.org/css-properties-values-api/
Design notes: https://docs.google.com/document/d/1IBT3qlZK-BznqcVANckj6kjMjpyFHc-KHdBLz1n4M4c

BUG=641877

Review-Url: https://codereview.chromium.org/2310823002
Cr-Commit-Position: refs/heads/master@{#417240}

[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/custom-properties/register-property.html
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/custom-properties/unregister-property.html
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/custom-properties/var-reference-registered-properties-expected.txt
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/custom-properties/var-reference-registered-properties.html
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/bindings/core/v8/BUILD.gn
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/core_idl_files.gni
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/BUILD.gn
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSComputedStyleDeclaration.cpp
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.cpp
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSVariableData.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSVariableData.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.h
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyDescriptor.idl
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistration.cpp
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistration.h
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistration.idl
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistry.cpp
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistry.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/parser/CSSVariableParser.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/parser/CSSVariableParser.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/dom/Document.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/dom/Document.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/dom/StyleChangeReason.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/dom/StyleChangeReason.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/style/ComputedStyle.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/style/ComputedStyle.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/style/StyleVariableData.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/style/StyleVariableData.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/platform/RuntimeEnabledFeatures.in

Project Member

Comment 2 by bugdroid1@chromium.org, Sep 8 2016

Labels: merge-merged-2854
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/01ce431409e3a019858677626a983c55168da6dc

commit 01ce431409e3a019858677626a983c55168da6dc
Author: timloh <timloh@chromium.org>
Date: Thu Sep 08 09:22:33 2016

Skeleton implementation of CSS Properties and Values API

This patch provides a basic skeleton implementation of the
CSS Properties and Values API. In particular, the pipeline from
registration to reading from computed styles is supported but with
many missing bits along the way.

Some of the missing bits:
- Only * and <length> syntax supported with trivial parsing logic.
- All properties assumed to be inherited.
- Computation logic is currently a no-op (needs to resolve ems, etc.)
- CSSOM on specified styles aren't yet affected by (un)registration

Spec: https://drafts.css-houdini.org/css-properties-values-api/
Design notes: https://docs.google.com/document/d/1IBT3qlZK-BznqcVANckj6kjMjpyFHc-KHdBLz1n4M4c

BUG=641877

Review-Url: https://codereview.chromium.org/2310823002
Cr-Commit-Position: refs/heads/master@{#417240}

[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/custom-properties/register-property.html
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/custom-properties/unregister-property.html
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/custom-properties/var-reference-registered-properties-expected.txt
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/custom-properties/var-reference-registered-properties.html
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/bindings/core/v8/BUILD.gn
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/core_idl_files.gni
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/BUILD.gn
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSComputedStyleDeclaration.cpp
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.cpp
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSVariableData.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/CSSVariableData.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.h
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyDescriptor.idl
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistration.cpp
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistration.h
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistration.idl
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistry.cpp
[add] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/PropertyRegistry.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/parser/CSSVariableParser.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/parser/CSSVariableParser.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/dom/Document.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/dom/Document.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/dom/StyleChangeReason.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/dom/StyleChangeReason.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/style/ComputedStyle.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/style/ComputedStyle.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/style/StyleVariableData.cpp
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/core/style/StyleVariableData.h
[modify] https://crrev.com/01ce431409e3a019858677626a983c55168da6dc/third_party/WebKit/Source/platform/RuntimeEnabledFeatures.in

Project Member

Comment 3 by bugdroid1@chromium.org, Sep 19 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f3c212113fa3578799a243e1940e533ac6eac927

commit f3c212113fa3578799a243e1940e533ac6eac927
Author: timloh <timloh@chromium.org>
Date: Mon Sep 19 10:21:26 2016

CSS Properties and Values API: Support more syntax strings

This patch implements proper parsing of syntax strings in the P&V API,
as well parsing of the actual values. In particular, we add support for
parsing of syntax strings like "<length> | <percentage>" and "<number>+".

- Whitespace is not mentioned in the spec but used in examples. This
patch allows whitespace in most places.
- The <ident> production is possibly not the best choice (see github
issue below), so until that is resolved we only allow name code points.
- <resolution> is not yet used in any CSS properties in Blink, so value
parsing support will be added separately.
- <transform-function> isn't factored to be trivially supported, so value
parsing support will also be added separately. There's also an
outstanding issue re. Typed OM integration which might result in changes
here.

https://drafts.css-houdini.org/css-properties-values-api/#supported-syntax-strings
https://github.com/w3c/css-houdini-drafts/issues/265

BUG=641877

Review-Url: https://codereview.chromium.org/2330893002
Cr-Commit-Position: refs/heads/master@{#419425}

[add] https://crrev.com/f3c212113fa3578799a243e1940e533ac6eac927/third_party/WebKit/LayoutTests/custom-properties/register-property-syntax-parsing-expected.txt
[add] https://crrev.com/f3c212113fa3578799a243e1940e533ac6eac927/third_party/WebKit/LayoutTests/custom-properties/register-property-syntax-parsing.html
[modify] https://crrev.com/f3c212113fa3578799a243e1940e533ac6eac927/third_party/WebKit/LayoutTests/custom-properties/unregister-property.html
[modify] https://crrev.com/f3c212113fa3578799a243e1940e533ac6eac927/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.cpp
[modify] https://crrev.com/f3c212113fa3578799a243e1940e533ac6eac927/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.h

Project Member

Comment 4 by bugdroid1@chromium.org, Sep 22 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1ed40ebf3aeeb391d0aa2e82c46988ad767c1c35

commit 1ed40ebf3aeeb391d0aa2e82c46988ad767c1c35
Author: timloh <timloh@chromium.org>
Date: Thu Sep 22 14:11:05 2016

CSS Properties and Values API: Implement computation / computational independence

This patch implements basic computation and computational independence
logic for registered custom properties. For now we just handle variable
references, length types and lists thereof, while images and transform
functions containing lengths will be properly handled later.

'Computationally independent' has recently been renamed from
'computationally idempotent', so the function is updated to match.

https://drafts.css-houdini.org/css-properties-values-api/#calculation-of-computed-values
https://drafts.css-houdini.org/css-properties-values-api/#computationally-independent

BUG=641877

Review-Url: https://codereview.chromium.org/2354463002
Cr-Commit-Position: refs/heads/master@{#420328}

[modify] https://crrev.com/1ed40ebf3aeeb391d0aa2e82c46988ad767c1c35/third_party/WebKit/LayoutTests/custom-properties/register-property-syntax-parsing-expected.txt
[modify] https://crrev.com/1ed40ebf3aeeb391d0aa2e82c46988ad767c1c35/third_party/WebKit/LayoutTests/custom-properties/register-property-syntax-parsing.html
[add] https://crrev.com/1ed40ebf3aeeb391d0aa2e82c46988ad767c1c35/third_party/WebKit/LayoutTests/custom-properties/registered-property-computation-expected.txt
[add] https://crrev.com/1ed40ebf3aeeb391d0aa2e82c46988ad767c1c35/third_party/WebKit/LayoutTests/custom-properties/registered-property-computation.html
[delete] https://crrev.com/e154e57cd6affbe81fd8c885334283e3aa3a6431/third_party/WebKit/LayoutTests/custom-properties/var-reference-registered-properties-expected.txt
[modify] https://crrev.com/1ed40ebf3aeeb391d0aa2e82c46988ad767c1c35/third_party/WebKit/Source/core/css/PropertyRegistration.cpp
[modify] https://crrev.com/1ed40ebf3aeeb391d0aa2e82c46988ad767c1c35/third_party/WebKit/Source/core/css/resolver/StyleBuilderConverter.cpp

Project Member

Comment 5 by bugdroid1@chromium.org, Sep 23 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a44ebf4ccff547bda5de22979e93ac65c3b2b93c

commit a44ebf4ccff547bda5de22979e93ac65c3b2b93c
Author: timloh <timloh@chromium.org>
Date: Fri Sep 23 05:04:59 2016

CSS Properties and Values API: Use initial value where appropriate for var()

This patch fixes var() references to registered properties to return
initial values where appropriate. When a registered property is not
explicitly set, var() references to it should result in that property's
initial value. We now store the initial value as a token stream as well
to accommodate this.

Any unregistered property in a var() cycle will continue to compute to
their initial value (i.e. the invalid value). Any registered property
in a var() cycle similar compute to their initial value (I don't think
this is explicitly mentioned in the spec, but for consistency this makes
more sense than the unset value). Valid references to properties in a
var() cycle will resolve to the referenced property'd initial value.

BUG=641877

Review-Url: https://codereview.chromium.org/2358203003
Cr-Commit-Position: refs/heads/master@{#420579}

[add] https://crrev.com/a44ebf4ccff547bda5de22979e93ac65c3b2b93c/third_party/WebKit/LayoutTests/custom-properties/var-reference-registered-properties-cycles.html
[modify] https://crrev.com/a44ebf4ccff547bda5de22979e93ac65c3b2b93c/third_party/WebKit/LayoutTests/custom-properties/var-reference-registered-properties.html
[modify] https://crrev.com/a44ebf4ccff547bda5de22979e93ac65c3b2b93c/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.cpp
[modify] https://crrev.com/a44ebf4ccff547bda5de22979e93ac65c3b2b93c/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.h
[modify] https://crrev.com/a44ebf4ccff547bda5de22979e93ac65c3b2b93c/third_party/WebKit/Source/core/css/PropertyRegistration.cpp
[modify] https://crrev.com/a44ebf4ccff547bda5de22979e93ac65c3b2b93c/third_party/WebKit/Source/core/css/PropertyRegistry.cpp
[modify] https://crrev.com/a44ebf4ccff547bda5de22979e93ac65c3b2b93c/third_party/WebKit/Source/core/css/PropertyRegistry.h
[modify] https://crrev.com/a44ebf4ccff547bda5de22979e93ac65c3b2b93c/third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.cpp

Project Member

Comment 6 by bugdroid1@chromium.org, Sep 27 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ad7e45054466325ed927146b20edfe976f80c608

commit ad7e45054466325ed927146b20edfe976f80c608
Author: timloh <timloh@chromium.org>
Date: Tue Sep 27 04:40:45 2016

Don't depend on unregisterProperty in register-property-syntax-parsing.html

It sounds like unregisterProperty will be removed from the first version
of the P&V API, so let's not depend on it in our test.

BUG=641877

Review-Url: https://codereview.chromium.org/2369813002
Cr-Commit-Position: refs/heads/master@{#421104}

[modify] https://crrev.com/ad7e45054466325ed927146b20edfe976f80c608/third_party/WebKit/LayoutTests/custom-properties/register-property-syntax-parsing-expected.txt
[modify] https://crrev.com/ad7e45054466325ed927146b20edfe976f80c608/third_party/WebKit/LayoutTests/custom-properties/register-property-syntax-parsing.html

Project Member

Comment 7 by bugdroid1@chromium.org, Sep 29 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/864454fb784c52c1202410dc28799c8dc0f9ad0c

commit 864454fb784c52c1202410dc28799c8dc0f9ad0c
Author: timloh <timloh@chromium.org>
Date: Thu Sep 29 08:00:19 2016

CSS Properties and Values API: Support non-inherited custom properties

This patch adds supports for registering non-inherited properties.
These properties are stored in a new class StyleNonInheritedVariables,
similar to StyleVariableData (now renamed to StyleInheritedVariables).
The new class differs in a couple of ways: it is not RefCounted and
there is no root optimisation (this wouldn't make sense anyway).

This patch fixes a bug in the getter on StyleInheritedVariables for
registered properties where we wouldn't check the root node. This is
covered by the added tests.

Non-inherited custom properties are not yet supported for the devtools
computed styles pane and @apply rules, and todos are added in relevant
places in the code.

BUG=641877

Review-Url: https://codereview.chromium.org/2366313006
Cr-Commit-Position: refs/heads/master@{#421776}

[add] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/LayoutTests/custom-properties/registered-properties-inheritance.html
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/css/ComputedStyleCSSValueMapping.cpp
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/css/PropertyRegistry.cpp
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.cpp
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.h
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/inspector/InspectorCSSAgent.cpp
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/BUILD.gn
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/ComputedStyle.cpp
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/ComputedStyle.h
[rename] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/StyleInheritedVariables.cpp
[add] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/StyleInheritedVariables.h
[add] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/StyleNonInheritedVariables.cpp
[add] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/StyleNonInheritedVariables.h
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/StyleRareInheritedData.cpp
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/StyleRareInheritedData.h
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/StyleRareNonInheritedData.cpp
[modify] https://crrev.com/864454fb784c52c1202410dc28799c8dc0f9ad0c/third_party/WebKit/Source/core/style/StyleRareNonInheritedData.h
[delete] https://crrev.com/4b73fe91b1242219730280be352207c1afd6b238/third_party/WebKit/Source/core/style/StyleVariableData.h

Project Member

Comment 9 by bugdroid1@chromium.org, Oct 7 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/483abaf5253f6e4864914f7824142995a51d8254

commit 483abaf5253f6e4864914f7824142995a51d8254
Author: timloh <timloh@chromium.org>
Date: Fri Oct 07 02:04:10 2016

Remove TODO about normalizing calc() values at parse time for registered properties

This patch removes a TODO which states we should normalize calc() values
when parsing them for registered properties. I don't recall exactly why
I added this TODO but it doesn't seem that the spec says this needs to
be done. We already simplify calc() values in computation as per spec.

https://drafts.css-houdini.org/css-properties-values-api/

BUG=641877

Review-Url: https://codereview.chromium.org/2399803002
Cr-Commit-Position: refs/heads/master@{#423778}

[modify] https://crrev.com/483abaf5253f6e4864914f7824142995a51d8254/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.cpp

Labels: -M-55 -merge-merged-2854 M-57
M55 branch has past, updating M label since this isn't yet done.

Comment 11 by meade@chromium.org, Oct 11 2016

Labels: Objective
Project Member

Comment 12 by bugdroid1@chromium.org, Oct 12 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/6f4d446b10b026ed240137444c95935baf99ca05

commit 6f4d446b10b026ed240137444c95935baf99ca05
Author: timloh <timloh@chromium.org>
Date: Wed Oct 12 05:27:17 2016

Remove CSS.unregisterProperty as the WG resolved to remove it for now

At the TPAC F2F last month, the WG resolved to remove property
deregistration (although it's likely to be re-added later).
This patch removes the unregisterProperty function for now.

The spec has not yet been update to remove the function.

https://logs.csswg.org/irc.w3.org/houdini/2016-09-22/#e727846

BUG=641877

Review-Url: https://codereview.chromium.org/2405153002
Cr-Commit-Position: refs/heads/master@{#424676}

[modify] https://crrev.com/6f4d446b10b026ed240137444c95935baf99ca05/third_party/WebKit/LayoutTests/custom-properties/register-property.html
[delete] https://crrev.com/6e6381c2d2b079e34b33bf60534df7cf1c2cc5e3/third_party/WebKit/LayoutTests/custom-properties/unregister-property.html
[modify] https://crrev.com/6f4d446b10b026ed240137444c95935baf99ca05/third_party/WebKit/LayoutTests/webexposed/global-interface-listing-expected.txt
[modify] https://crrev.com/6f4d446b10b026ed240137444c95935baf99ca05/third_party/WebKit/Source/core/css/PropertyRegistration.cpp
[modify] https://crrev.com/6f4d446b10b026ed240137444c95935baf99ca05/third_party/WebKit/Source/core/css/PropertyRegistration.h
[modify] https://crrev.com/6f4d446b10b026ed240137444c95935baf99ca05/third_party/WebKit/Source/core/css/PropertyRegistration.idl
[modify] https://crrev.com/6f4d446b10b026ed240137444c95935baf99ca05/third_party/WebKit/Source/core/css/PropertyRegistry.cpp
[modify] https://crrev.com/6f4d446b10b026ed240137444c95935baf99ca05/third_party/WebKit/Source/core/css/PropertyRegistry.h

Project Member

Comment 13 by bugdroid1@chromium.org, Oct 12 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/d334ba8f91d9dc54d00145dbd0deffc3f32e283f

commit d334ba8f91d9dc54d00145dbd0deffc3f32e283f
Author: timloh <timloh@chromium.org>
Date: Wed Oct 12 09:21:33 2016

Compute registered properties after resolving high priority properties

This patch moves computation of registered properties after that of
high priority properties. This makes em units work correctly when
the font-size is set on a given element.

Currently properties which are inherited will be re-computed since we
don't have a distinction between inherited properties and those which
we actually set. This does not affect correctness as computation is
idempotent.

As we resolve var() references as token streams, we don't issues with
cycles (e.g. --font-size: 10em; font-size: var(--font-size)). There's
an outstanding issue on the Houdini GitHub to work out what we should
actually do here.

https://github.com/w3c/css-houdini-drafts/issues/315

BUG=641877

Review-Url: https://codereview.chromium.org/2406203004
Cr-Commit-Position: refs/heads/master@{#424697}

[delete] https://crrev.com/1cb8c5294d2ae14bf07e140bf37b1460ffe65933/third_party/WebKit/LayoutTests/custom-properties/registered-property-computation-expected.txt
[modify] https://crrev.com/d334ba8f91d9dc54d00145dbd0deffc3f32e283f/third_party/WebKit/LayoutTests/custom-properties/registered-property-computation.html
[modify] https://crrev.com/d334ba8f91d9dc54d00145dbd0deffc3f32e283f/third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.cpp
[modify] https://crrev.com/d334ba8f91d9dc54d00145dbd0deffc3f32e283f/third_party/WebKit/Source/core/css/resolver/CSSVariableResolver.h
[modify] https://crrev.com/d334ba8f91d9dc54d00145dbd0deffc3f32e283f/third_party/WebKit/Source/core/css/resolver/StyleBuilderCustom.cpp
[modify] https://crrev.com/d334ba8f91d9dc54d00145dbd0deffc3f32e283f/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp

Project Member

Comment 14 by bugdroid1@chromium.org, Oct 18 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/647f07fb29ed0e52b09af26a537849f7f4ce8c48

commit 647f07fb29ed0e52b09af26a537849f7f4ce8c48
Author: timloh <timloh@chromium.org>
Date: Tue Oct 18 16:13:26 2016

Test usage of registered custom properties in custom paint

This patch adds tests for reading registered custom properties of types
<length> and <number> via custom paint.

BUG=641877

Review-Url: https://codereview.chromium.org/2428793002
Cr-Commit-Position: refs/heads/master@{#425982}

[add] https://crrev.com/647f07fb29ed0e52b09af26a537849f7f4ce8c48/third_party/WebKit/LayoutTests/csspaint/registered-properties-in-custom-paint-expected.txt
[add] https://crrev.com/647f07fb29ed0e52b09af26a537849f7f4ce8c48/third_party/WebKit/LayoutTests/csspaint/registered-properties-in-custom-paint.html
[modify] https://crrev.com/647f07fb29ed0e52b09af26a537849f7f4ce8c48/third_party/WebKit/LayoutTests/csspaint/resources/generate-paint-style-logging.js
[modify] https://crrev.com/647f07fb29ed0e52b09af26a537849f7f4ce8c48/third_party/WebKit/LayoutTests/csspaint/style-background-image-expected.txt
[modify] https://crrev.com/647f07fb29ed0e52b09af26a537849f7f4ce8c48/third_party/WebKit/LayoutTests/csspaint/style-background-image.html
[modify] https://crrev.com/647f07fb29ed0e52b09af26a537849f7f4ce8c48/third_party/WebKit/LayoutTests/csspaint/style-before-pseudo-expected.txt
[modify] https://crrev.com/647f07fb29ed0e52b09af26a537849f7f4ce8c48/third_party/WebKit/LayoutTests/csspaint/style-before-pseudo.html
[modify] https://crrev.com/647f07fb29ed0e52b09af26a537849f7f4ce8c48/third_party/WebKit/LayoutTests/csspaint/style-first-letter-pseudo-expected.txt
[modify] https://crrev.com/647f07fb29ed0e52b09af26a537849f7f4ce8c48/third_party/WebKit/LayoutTests/csspaint/style-first-letter-pseudo.html

Status: Started (was: Assigned)
Blockedon: 657706
Project Member

Comment 17 by bugdroid1@chromium.org, Oct 20 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/656fac63623b571cf135de0f5fe0e904f984b26a

commit 656fac63623b571cf135de0f5fe0e904f984b26a
Author: timloh <timloh@chromium.org>
Date: Thu Oct 20 06:27:09 2016

Invalidate properties registered as non-inherited for custom paint

This patch fixes custom paint invalidation for properties registered as
non-inherited. To avoid plumbing the property registry around more, we
check both the StyleInheritedVariables and StyleNonInheritedVariables
to get a custom property's value.

The invalidation for registered properties is not 100% precise as we
compare the token stream values instead of parsed values, so a value
could change representation (e.g. 160px to 10em) without a change in
computation value and we would still invalidate.

We also fail to invalidate when a property is registered. This could
result in a computed value being set to the initial value. Alternatively
the value could remain the same but registration could cause the value
returned in the FilteredComputedStylePropertyMap to no longer be an
unparsed value.

BUG=641877

Review-Url: https://chromiumcodereview.appspot.com/2426323003
Cr-Commit-Position: refs/heads/master@{#426421}

[modify] https://crrev.com/656fac63623b571cf135de0f5fe0e904f984b26a/third_party/WebKit/LayoutTests/csspaint/invalidation-background-image-expected.txt
[modify] https://crrev.com/656fac63623b571cf135de0f5fe0e904f984b26a/third_party/WebKit/LayoutTests/csspaint/invalidation-background-image.html
[modify] https://crrev.com/656fac63623b571cf135de0f5fe0e904f984b26a/third_party/WebKit/LayoutTests/csspaint/invalidation-border-image-expected.txt
[modify] https://crrev.com/656fac63623b571cf135de0f5fe0e904f984b26a/third_party/WebKit/LayoutTests/csspaint/invalidation-border-image.html
[modify] https://crrev.com/656fac63623b571cf135de0f5fe0e904f984b26a/third_party/WebKit/LayoutTests/csspaint/invalidation-content-image-expected.txt
[modify] https://crrev.com/656fac63623b571cf135de0f5fe0e904f984b26a/third_party/WebKit/LayoutTests/csspaint/invalidation-content-image.html
[modify] https://crrev.com/656fac63623b571cf135de0f5fe0e904f984b26a/third_party/WebKit/Source/core/style/ComputedStyle.cpp
[modify] https://crrev.com/656fac63623b571cf135de0f5fe0e904f984b26a/third_party/WebKit/Source/core/style/ComputedStyle.h

Blockedon: 671490
Project Member

Comment 19 by bugdroid1@chromium.org, Jan 4 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ed0f6121435448aa316c90be1468398ab2ef71b4

commit ed0f6121435448aa316c90be1468398ab2ef71b4
Author: timloh <timloh@chromium.org>
Date: Wed Jan 04 03:46:51 2017

Disallow setting invalid values for registered properties via CSSOM

This patch rejects setting invalid values for registered properties via
the CSSStyleDeclaration::setProperty function. The behaviour which we
decided on is that we will retain any values set prior to registration
and compute them as if they were the unset keyword if they are invalid
after registration, but disallow setting such values after registration.

CSS Typed OM is not yet hooked up aside from the filtered computed map
for custom paint, so we don't yet make any changes there.

BUG=641877

Review-Url: https://codereview.chromium.org/2607403002
Cr-Commit-Position: refs/heads/master@{#441313}

[add] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/LayoutTests/custom-properties/registered-property-cssom.html
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/bindings/core/v8/custom/V8CSSStyleDeclarationCustom.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/animation/EffectInput.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/animation/StringKeyframe.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/animation/StringKeyframe.h
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/CSSComputedStyleDeclaration.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/CSSComputedStyleDeclaration.h
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/CSSStyleDeclaration.h
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/CSSStyleDeclaration.idl
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/DOMWindowCSS.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/PropertySetCSSStyleDeclaration.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/PropertySetCSSStyleDeclaration.h
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/StylePropertySet.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/StylePropertySet.h
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/parser/CSSParser.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/parser/CSSParser.h
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/parser/CSSParserImpl.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/css/parser/CSSParserImpl.h
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/dom/Document.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/dom/Document.h
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/editing/VisiblePositionTest.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/editing/commands/RemoveCSSPropertyCommand.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/editing/commands/ReplaceSelectionCommand.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/html/HTMLMarqueeElement.cpp
[modify] https://crrev.com/ed0f6121435448aa316c90be1468398ab2ef71b4/third_party/WebKit/Source/core/inspector/InspectorCSSAgent.cpp

Project Member

Comment 21 by bugdroid1@chromium.org, Jan 9 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/eef2fbb63ea6f4d96cbc2f01f922f9122a453a77

commit eef2fbb63ea6f4d96cbc2f01f922f9122a453a77
Author: timloh <timloh@chromium.org>
Date: Mon Jan 09 05:20:37 2017

Properly test unset behavior of invalid registered property values

This patch fixes registered-property-cssom.html to properly test that
invalid registered property values are computed as unset. The test was
missing inherited values so the unset value was always resolving to the
initial value.

BUG=641877

Review-Url: https://codereview.chromium.org/2621553002
Cr-Commit-Position: refs/heads/master@{#442197}

[modify] https://crrev.com/eef2fbb63ea6f4d96cbc2f01f922f9122a453a77/third_party/WebKit/LayoutTests/custom-properties/registered-property-cssom.html

Blockedon: 679627
Labels: -M-57 M-59
Cc: -meade@chromium.org
Owner: meade@chromium.org
Status: Assigned (was: Started)
Assigning to meade@ to re-triage.
Labels: Update-Monthly

Comment 26 by meade@chromium.org, Apr 19 2017

Cc: meade@chromium.org
Labels: -Update-Monthly Update-Quarterly
Owner: shans@chromium.org
I believe shans was going to finish this off.
Project Member

Comment 27 by bugdroid1@chromium.org, Jun 23 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/130694fb49bf9eea4094ad28f765626b947d4261

commit 130694fb49bf9eea4094ad28f765626b947d4261
Author: hs1217.lee <hs1217.lee@samsung.com>
Date: Fri Jun 23 03:11:00 2017

CSS Properties & Values API:replace transform-function with transform-list.

transform-function is changed to transform-list.
<transform-list> is already a space separated list,
so <transform-list>+ is invalid.
parsing functions for transform-form type were moved to
CSSPropertyTransformUtils from CSSPropertyAPITransform.

https://drafts.css-houdini.org/css-properties-values-api-1/#supported-syntax-strings
https://github.com/w3c/css-houdini-drafts/issues/290

BUG=641877

Review-Url: https://codereview.chromium.org/2951763002
Cr-Commit-Position: refs/heads/master@{#481796}

[modify] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/LayoutTests/custom-properties/register-property-syntax-parsing-expected.txt
[modify] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/LayoutTests/custom-properties/register-property-syntax-parsing.html
[modify] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/Source/core/animation/CSSInterpolationTypesMap.cpp
[modify] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/Source/core/css/BUILD.gn
[modify] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.cpp
[modify] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/Source/core/css/CSSSyntaxDescriptor.h
[modify] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.cpp
[modify] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/Source/core/css/parser/CSSPropertyParserHelpers.h
[modify] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/Source/core/css/properties/CSSPropertyAPITransform.cpp
[add] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/Source/core/css/properties/CSSPropertyTransformUtils.cpp
[add] https://crrev.com/130694fb49bf9eea4094ad28f765626b947d4261/third_party/WebKit/Source/core/css/properties/CSSPropertyTransformUtils.h

Labels: migrated-launch-owp Type-Task
This issue has been automatically relabelled type=task because type=launch-owp issues are now officially deprecated. The deprecation is because they were creating confusion about how to get launch approvals, which should be instead done via type=launch issues.

We recommend this issue be used for implementation tracking (for public visibility), but if you already have an issue for that, you may mark this as duplicate.

For more details see here: https://docs.google.com/document/d/1JA6RohjtZQc26bTrGoIE_bSXGXUDQz8vc6G0n_sZJ2o/edit

For any questions, please contact owencm, sshruthi, larforge
Labels: -Update-Quarterly

Comment 30 by e...@chromium.org, Jan 30 2018

Owner: ----
Status: Available (was: Assigned)
Project Member

Comment 31 by bugdroid1@chromium.org, Mar 12 2018

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9

commit 26dfae3a15ae4653daa2f94bab9d6b2cca6488d9
Author: Chris Nardi <cnardi@chromium.org>
Date: Mon Mar 12 23:16:15 2018

Upstream registerProperty tests to WPT

Many tests of CSS.registerProperty were written, but none have been
upstreamed to WPT. Upstream these tests to ensure interoperability.

Bug: 641877
Change-Id: I8272b14c78cb75bb6f5f3cedb770091cbcba522a
Reviewed-on: https://chromium-review.googlesource.com/959422
Reviewed-by: Robert Ma <robertma@chromium.org>
Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org>
Commit-Queue: Chris Nardi <cnardi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#542649}
[modify] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/SmokeTests
[rename] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/register-property-syntax-parsing-expected.txt
[rename] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/register-property-syntax-parsing.html
[rename] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/register-property.html
[rename] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-properties-inheritance.html
[rename] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation.html
[rename] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-cssom.html
[rename] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-initial.html
[rename] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/var-reference-registered-properties-cycles.html
[rename] https://crrev.com/26dfae3a15ae4653daa2f94bab9d6b2cca6488d9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/var-reference-registered-properties.html

Owner: andruud@chromium.org
Status: Started (was: Available)
Blockedon: 848250
Blockedon: 848251
Blockedon: 848698
Blocking: 850018
Blocking: -850018
Blockedon: 850018
Blockedon: 850072
Blockedon: 851490
Blockedon: 859509
Blocking: 860289
Blocking: 860301
Blocking: 860309
Blocking: -860289
Blockedon: 860289
Blocking: -860301
Blockedon: 860301
Blocking: -860309
Blockedon: 860309
Blockedon: 862152
Project Member

Comment 52 by bugdroid1@chromium.org, Jul 13

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b21286bae4a741d7961beb2d7dad112c1049dbd1

commit b21286bae4a741d7961beb2d7dad112c1049dbd1
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Jul 13 08:20:15 2018

[css-properties-values-api] Add tests for Typed OM reification.

How registered custom properties are reified is currently not specified
[1]. For computed values, it should hopefully be pretty obvious how it
should work. (For declared/inline style it is less clear).

This patch adds tests for the computed style only.

Note:

 * <transform-function> is not tested, because it appears that this
   syntax was re-added to the spec by mistake, so I expect support for
   <transform-function> will be reverted.
 * <transform-list> and list syntaxes in general are not tested, because
   it's currently broken in Blink. Tests for list syntaxes will be added
   along with the fix for that.

[1] https://drafts.css-houdini.org/css-typed-om-1/#reify-stylevalue

R=chrishtr@chromium.org

Bug: 641877
Change-Id: Ic177bfe2b90897ec44ef4405c745171d8b226e82
Reviewed-on: https://chromium-review.googlesource.com/1134778
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#574858}
[add] https://crrev.com/b21286bae4a741d7961beb2d7dad112c1049dbd1/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html

Project Member

Comment 53 by bugdroid1@chromium.org, Jul 14

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/74ff2c231069c5746724df6f4f1e1c93fcac991e

commit 74ff2c231069c5746724df6f4f1e1c93fcac991e
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Sat Jul 14 11:04:31 2018

[css-properties-values-api] Add test for cascading behavior.

Registered custom properties should behave as if they weren't registered
for parsing and cascading purposes. Only at computed-value time does the
syntax from the registration come into play.

R=chrishtr@chromium.org

Bug: 641877
Change-Id: I5ed5b334318e653da660b88b2dd912cc0b59f36d
Reviewed-on: https://chromium-review.googlesource.com/1136448
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#575161}
[add] https://crrev.com/74ff2c231069c5746724df6f4f1e1c93fcac991e/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/property-cascade.html

Blockedon: 868959
Project Member

Comment 55 by bugdroid1@chromium.org, Aug 13

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/dafabe13f09dc05c3611de952f530fca940a80a9

commit dafabe13f09dc05c3611de952f530fca940a80a9
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Mon Aug 13 12:34:41 2018

[css-properties-values-api] Test var()-references w.r.t. registered lists.

R=futhark@chromium.org

Bug: 641877
Change-Id: Ia249aedc2abe7f249c28ab57732edfaf6c552f2e
Reviewed-on: https://chromium-review.googlesource.com/1172295
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#582557}
[modify] https://crrev.com/dafabe13f09dc05c3611de952f530fca940a80a9/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/var-reference-registered-properties.html

Project Member

Comment 56 by bugdroid1@chromium.org, Aug 13

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/3364c23332ed753b7f94cbcb1bff7c6aa329e127

commit 3364c23332ed753b7f94cbcb1bff7c6aa329e127
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Mon Aug 13 14:03:30 2018

[css-properties-values-api] Reify values from attributeStyleMap.get.

When retrieving values via attributeStyleMap.get/getAll, produce the
correct CSSStyleValue subclass according to the registration of the custom
property.

R=futhark@chromium.org

Bug: 641877
Change-Id: If564fb039506a22162ad2521479fcb1c3de9336c
Reviewed-on: https://chromium-review.googlesource.com/1172291
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#582569}
[modify] https://crrev.com/3364c23332ed753b7f94cbcb1bff7c6aa329e127/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/3364c23332ed753b7f94cbcb1bff7c6aa329e127/third_party/blink/renderer/core/css/cssom/inline_style_property_map.cc
[modify] https://crrev.com/3364c23332ed753b7f94cbcb1bff7c6aa329e127/third_party/blink/renderer/core/css/property_registry.cc
[modify] https://crrev.com/3364c23332ed753b7f94cbcb1bff7c6aa329e127/third_party/blink/renderer/core/css/property_registry.h

Project Member

Comment 57 by bugdroid1@chromium.org, Aug 16

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b786c57cab4e93f6736fecfcc986c36dfbddd507

commit b786c57cab4e93f6736fecfcc986c36dfbddd507
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Aug 16 17:00:04 2018

[css-properties-values-api] Support CSSStyleValues in StylePropertyMap.set.

In StyleValueToCSSValue, when checking whether a certain CSSStyleValue
matches the property in question, we now ask the registration (via
CSSOMTypes) if the CSSStyleValue matches. If it doesn't match, we throw
a TypeError like for normal properties. If it does match, the CSSStyleValue
is stringified, tokenized, and set on the style rule as tokens.

I have postponed support for <color> and <transform-function>, because
CSSUnsupportedStyleValue currently does not handle registered custom
properties at all. This is appropriate to fix in a separate CL.

Note that, because the string version of StylePropertyMap.set also uses
StyleValueToCSSValue, it will no longer be possible to set registered
custom properties with a string--even if the syntax is matched.
A subsequent CL will fix this.

R=futhark@chromium.org

Bug: 641877
Change-Id: Ie0cc2f87e39f8f59015824bfd1b81efaf402c326
Reviewed-on: https://chromium-review.googlesource.com/1175822
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#583695}
[modify] https://crrev.com/b786c57cab4e93f6736fecfcc986c36dfbddd507/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/b786c57cab4e93f6736fecfcc986c36dfbddd507/third_party/blink/renderer/build/scripts/core/css/templates/cssom_types.cc.tmpl
[modify] https://crrev.com/b786c57cab4e93f6736fecfcc986c36dfbddd507/third_party/blink/renderer/core/css/css_syntax_descriptor.cc
[modify] https://crrev.com/b786c57cab4e93f6736fecfcc986c36dfbddd507/third_party/blink/renderer/core/css/css_syntax_descriptor.h
[modify] https://crrev.com/b786c57cab4e93f6736fecfcc986c36dfbddd507/third_party/blink/renderer/core/css/cssom/cssom_types.h
[modify] https://crrev.com/b786c57cab4e93f6736fecfcc986c36dfbddd507/third_party/blink/renderer/core/css/cssom/style_property_map.cc

Project Member

Comment 58 by bugdroid1@chromium.org, Aug 16

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9f66bd02c1ec8d9af794aa2aa17825f5a40986bb

commit 9f66bd02c1ec8d9af794aa2aa17825f5a40986bb
Author: Xida Chen <xidachen@chromium.org>
Date: Thu Aug 16 18:29:15 2018

Revert "[css-properties-values-api] Support CSSStyleValues in StylePropertyMap.set."

This reverts commit b786c57cab4e93f6736fecfcc986c36dfbddd507.

Reason for revert: <INSERT REASONING HERE>
layout test failed:
https://ci.chromium.org/buildbot/chromium.webkit/WebKit%20Linux%20Trusty%20ASAN/15210

Original change's description:
> [css-properties-values-api] Support CSSStyleValues in StylePropertyMap.set.
> 
> In StyleValueToCSSValue, when checking whether a certain CSSStyleValue
> matches the property in question, we now ask the registration (via
> CSSOMTypes) if the CSSStyleValue matches. If it doesn't match, we throw
> a TypeError like for normal properties. If it does match, the CSSStyleValue
> is stringified, tokenized, and set on the style rule as tokens.
> 
> I have postponed support for <color> and <transform-function>, because
> CSSUnsupportedStyleValue currently does not handle registered custom
> properties at all. This is appropriate to fix in a separate CL.
> 
> Note that, because the string version of StylePropertyMap.set also uses
> StyleValueToCSSValue, it will no longer be possible to set registered
> custom properties with a string--even if the syntax is matched.
> A subsequent CL will fix this.
> 
> R=‚Äčfuthark@chromium.org
> 
> Bug: 641877
> Change-Id: Ie0cc2f87e39f8f59015824bfd1b81efaf402c326
> Reviewed-on: https://chromium-review.googlesource.com/1175822
> Commit-Queue: Anders Ruud <andruud@chromium.org>
> Reviewed-by: Rune Lillesveen <futhark@chromium.org>
> Cr-Commit-Position: refs/heads/master@{#583695}

TBR=futhark@chromium.org,andruud@chromium.org

Change-Id: I2486be60ce81497253bdf64903ea870832a0ef9e
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 641877
Reviewed-on: https://chromium-review.googlesource.com/1178503
Reviewed-by: Xida Chen <xidachen@chromium.org>
Commit-Queue: Xida Chen <xidachen@chromium.org>
Cr-Commit-Position: refs/heads/master@{#583747}
[modify] https://crrev.com/9f66bd02c1ec8d9af794aa2aa17825f5a40986bb/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/9f66bd02c1ec8d9af794aa2aa17825f5a40986bb/third_party/blink/renderer/build/scripts/core/css/templates/cssom_types.cc.tmpl
[modify] https://crrev.com/9f66bd02c1ec8d9af794aa2aa17825f5a40986bb/third_party/blink/renderer/core/css/css_syntax_descriptor.cc
[modify] https://crrev.com/9f66bd02c1ec8d9af794aa2aa17825f5a40986bb/third_party/blink/renderer/core/css/css_syntax_descriptor.h
[modify] https://crrev.com/9f66bd02c1ec8d9af794aa2aa17825f5a40986bb/third_party/blink/renderer/core/css/cssom/cssom_types.h
[modify] https://crrev.com/9f66bd02c1ec8d9af794aa2aa17825f5a40986bb/third_party/blink/renderer/core/css/cssom/style_property_map.cc

Project Member

Comment 59 by bugdroid1@chromium.org, Aug 17

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/439d3bfd0f93287486b94c1ff5f268af41f3b018

commit 439d3bfd0f93287486b94c1ff5f268af41f3b018
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Aug 17 11:48:03 2018

Support CSSStyleValues in StylePropertyMap.set. (Reland)

In StyleValueToCSSValue, when checking whether a certain CSSStyleValue
matches the property in question, we now ask the registration (via
CSSOMTypes) if the CSSStyleValue matches. If it doesn't match, we throw
a TypeError like for normal properties. If it does match, the CSSStyleValue
is stringified, tokenized, and set on the style rule as tokens.

I have postponed support for <color> and <transform-function>, because
CSSUnsupportedStyleValue currently does not handle registered custom
properties at all. This is appropriate to fix in a separate CL.

Note that, because the string version of StylePropertyMap.set also uses
StyleValueToCSSValue, it will no longer be possible to set registered
custom properties with a string--even if the syntax is matched.
A subsequent CL will fix this.

R=futhark@chromium.org

Bug: 641877
Change-Id: Ib5c31640f81e957620339c9bdf617ab1af5d3d47
Reviewed-on: https://chromium-review.googlesource.com/1179153
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#584024}
[modify] https://crrev.com/439d3bfd0f93287486b94c1ff5f268af41f3b018/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/439d3bfd0f93287486b94c1ff5f268af41f3b018/third_party/blink/renderer/build/scripts/core/css/templates/cssom_types.cc.tmpl
[modify] https://crrev.com/439d3bfd0f93287486b94c1ff5f268af41f3b018/third_party/blink/renderer/core/css/css_syntax_descriptor.cc
[modify] https://crrev.com/439d3bfd0f93287486b94c1ff5f268af41f3b018/third_party/blink/renderer/core/css/css_syntax_descriptor.h
[modify] https://crrev.com/439d3bfd0f93287486b94c1ff5f268af41f3b018/third_party/blink/renderer/core/css/cssom/cssom_types.h
[modify] https://crrev.com/439d3bfd0f93287486b94c1ff5f268af41f3b018/third_party/blink/renderer/core/css/cssom/style_property_map.cc

Project Member

Comment 60 by bugdroid1@chromium.org, Aug 27

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5e4847b3257566ffcd30bc37eacef06b4ba578a6

commit 5e4847b3257566ffcd30bc37eacef06b4ba578a6
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Mon Aug 27 15:15:03 2018

[css-properties-values-api] Don't -webkit-cross-fade <image> values.

It is not spec'ed anywhere that <image> values interpolate in this way.

They should however interpolate as gradients, but we don't have an
InterpolationType for that yet.

R=flackr@chromium.org

Bug: 641877
Change-Id: I1a554d578c505f228f728ad7e09c3d5b4e5117e7
Reviewed-on: https://chromium-review.googlesource.com/1186416
Reviewed-by: Robert Flack <flackr@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#586267}
[delete] https://crrev.com/a852107fdbd4dc9d4fc7293bdc1953c18c40a6c3/third_party/WebKit/LayoutTests/animations/custom-properties/image-type-interpolation.html
[modify] https://crrev.com/5e4847b3257566ffcd30bc37eacef06b4ba578a6/third_party/blink/renderer/core/animation/css_interpolation_types_map.cc

Project Member

Comment 61 by bugdroid1@chromium.org, Aug 30

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/d944b41aa3949ca8f9e4cbc2a7e2b5bb03c96a4a

commit d944b41aa3949ca8f9e4cbc2a7e2b5bb03c96a4a
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Aug 30 12:57:11 2018

[css-properties-values-api] Support string values in StylePropertyMap.set.

When producing a CSSStyleValue from a string for a registered custom
property, parse the value according to the syntax instead of always
creating a CSSUnparsedValue.

Note that <color> and <url> are still not supported, because
CSSUnsupportedProperty does not work properly for registered custom
properties (yet).

R=futhark@chromium.org

Bug: 641877
Change-Id: I806eb5b0c5112956e34457808791367423587c76
Reviewed-on: https://chromium-review.googlesource.com/1177755
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#587537}
[modify] https://crrev.com/d944b41aa3949ca8f9e4cbc2a7e2b5bb03c96a4a/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/d944b41aa3949ca8f9e4cbc2a7e2b5bb03c96a4a/third_party/blink/renderer/core/css/cssom/css_style_value.cc
[modify] https://crrev.com/d944b41aa3949ca8f9e4cbc2a7e2b5bb03c96a4a/third_party/blink/renderer/core/css/cssom/style_property_map.cc
[modify] https://crrev.com/d944b41aa3949ca8f9e4cbc2a7e2b5bb03c96a4a/third_party/blink/renderer/core/css/cssom/style_value_factory.cc
[modify] https://crrev.com/d944b41aa3949ca8f9e4cbc2a7e2b5bb03c96a4a/third_party/blink/renderer/core/css/cssom/style_value_factory.h

Project Member

Comment 62 by bugdroid1@chromium.org, Aug 31

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b7270b4d8f26cf26af4b02ef642ce6434b0ccfda

commit b7270b4d8f26cf26af4b02ef642ce6434b0ccfda
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Aug 31 12:42:05 2018

[css-properties-values-api] Typify CSSStyleValue.parse/All.

Passing the PropertyRegistration makes StyleValueFactory::FromString
find the typed value, and create appropriate and corresponding TypedOM
types.

Note: the check on property_id==CSSPropertyVariable isn't strictly
required, but it's nice to avoid the AtomicString creation if we know it's
not needed.

R=futhark@chromium.org

Bug: 641877
Change-Id: Id7f7f8c754f8aab7f64a92efd896243858d03757
Reviewed-on: https://chromium-review.googlesource.com/1199182
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#588001}
[modify] https://crrev.com/b7270b4d8f26cf26af4b02ef642ce6434b0ccfda/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/b7270b4d8f26cf26af4b02ef642ce6434b0ccfda/third_party/blink/renderer/core/css/cssom/css_style_value.cc
[modify] https://crrev.com/b7270b4d8f26cf26af4b02ef642ce6434b0ccfda/third_party/blink/renderer/core/css/property_registration.cc
[modify] https://crrev.com/b7270b4d8f26cf26af4b02ef642ce6434b0ccfda/third_party/blink/renderer/core/css/property_registration.h

Project Member

Comment 63 by bugdroid1@chromium.org, Sep 5

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/6204aad84a7aa3469b1b8937e34c1cd86b45347d

commit 6204aad84a7aa3469b1b8937e34c1cd86b45347d
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Wed Sep 05 12:22:38 2018

[css-properties-values-api] Reify values from styleMap.get.

This CL gives return values from element.styleMap.get the correct type
according to the current PropertyRegistration.

The expected behavior is exactly the same as for attributeStyleMap, so
those tests have been adapted to run for both API entry points.

Note: PrepopulatedComputedStylePropertyMap is available in worklets,
where the ExecutionContext is not a Document, but we don't need to
reify values in this case, because already-reified values are "pushed"
rather than "pulled". (See ::UpdateStyle).

Note: Exit ParseIfRegistered before registration lookup. This avoids
the lookup if we already know that we won't need it (which is the case
for [Prepopulated]ComputedStylePropertyMap).

Bug: 641877
Change-Id: Id54a22079c88368efccc372d01252fa3e7734d10
Reviewed-on: https://chromium-review.googlesource.com/1201302
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#588840}
[modify] https://crrev.com/6204aad84a7aa3469b1b8937e34c1cd86b45347d/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/6204aad84a7aa3469b1b8937e34c1cd86b45347d/third_party/blink/renderer/core/css/cssom/inline_style_property_map.cc
[modify] https://crrev.com/6204aad84a7aa3469b1b8937e34c1cd86b45347d/third_party/blink/renderer/core/css/cssom/prepopulated_computed_style_property_map_test.cc
[modify] https://crrev.com/6204aad84a7aa3469b1b8937e34c1cd86b45347d/third_party/blink/renderer/core/css/cssom/style_property_map_read_only.cc
[modify] https://crrev.com/6204aad84a7aa3469b1b8937e34c1cd86b45347d/third_party/blink/renderer/core/css/cssom/style_property_map_read_only.h
[modify] https://crrev.com/6204aad84a7aa3469b1b8937e34c1cd86b45347d/third_party/blink/renderer/core/css/cssom/style_property_map_read_only.idl
[modify] https://crrev.com/6204aad84a7aa3469b1b8937e34c1cd86b45347d/third_party/blink/renderer/core/css/property_registry.cc

Project Member

Comment 64 by bugdroid1@chromium.org, Sep 7

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/0ec5410a8277d73fb3f09f11017a3e32e43d93e0

commit 0ec5410a8277d73fb3f09f11017a3e32e43d93e0
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Sep 07 08:25:19 2018

Improve test coverage of registered properties in paint worklets.

The most important use case for css-properties-values-api is having typed
(and possibly interpolated) custom properties in paint worklets.

So naturally, this is the *least* well tested use case in WPT. This CL
improves that by adding tests for most of the syntax types. The test works
as a kind of "ref" test, which compares the output of CSSStyleValue.parse
/parseAll with the value observed inside the worklet.

<transform-function> and <transform-list> are not supported yet, so they
will come later.

Interpolations should also be tested, but that belongs in a separate test.

Bug: 641877
Change-Id: I4bd310ecd61a2a8989df9c4a5c818cdc7c179b3a
Reviewed-on: https://chromium-review.googlesource.com/1209711
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org>
Cr-Commit-Position: refs/heads/master@{#589461}
[delete] https://crrev.com/5f0cb178d891513ddf83421b927d6b612a00d23a/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-properties-in-custom-paint.https.html
[add] https://crrev.com/0ec5410a8277d73fb3f09f11017a3e32e43d93e0/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-type.https.html

Project Member

Comment 65 by bugdroid1@chromium.org, Sep 11

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/484778bf4611cd46a06e171a8bfa9c90894d1cce

commit 484778bf4611cd46a06e171a8bfa9c90894d1cce
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Tue Sep 11 11:59:05 2018

Remove PropertyRegistration::Create.

This was added recently for testing purposes, but I wasn't aware of
FRIEND_TEST_ALL_PREFIXES at the time. PropertyRegistration instances must
never exist unless CSSVariables2 is enabled, and I've been worried this
might accidentally happen ever since ::Create was added.

Added bonus DCHECK for even more inner peace.

R=futhark@chromium.org

Bug: 641877
Change-Id: I61780ec25fb09673a0f3325775ce1b891b0867cb
Reviewed-on: https://chromium-review.googlesource.com/1218702
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#590267}
[modify] https://crrev.com/484778bf4611cd46a06e171a8bfa9c90894d1cce/third_party/blink/renderer/core/css/property_registration.cc
[modify] https://crrev.com/484778bf4611cd46a06e171a8bfa9c90894d1cce/third_party/blink/renderer/core/css/property_registration.h
[modify] https://crrev.com/484778bf4611cd46a06e171a8bfa9c90894d1cce/third_party/blink/renderer/core/css/resolver/css_variable_resolver_test.cc

Project Member

Comment 66 by bugdroid1@chromium.org, Sep 17

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/d2d10b8f9fdd389a02bed05dfb0dda57be5c4c39

commit d2d10b8f9fdd389a02bed05dfb0dda57be5c4c39
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Mon Sep 17 10:39:10 2018

[css-properties-values-api] Detect font-relative units via var() refs.

The has[_root]_font_unit flags were accidentally ignored in one of
CSSVariableData's constructors, and also not propagated properly during
variable resolution. This caused us to lose any knowledge about these units
if they appeared via an inner var() reference.

Also:

 * Fix incorrect rem test which tested the wrong thing due to the
   'compute_dimension' utility mutating its style.
 * Reduce the chance of such errors in the future by cleaning the state
   between every test, and also at the end of 'compute_dimension'.

R=chrishtr@chromium.org

Bug: 641877
Change-Id: If67cf4453e886f4c9430826c7cbe358e380c3f64
Reviewed-on: https://chromium-review.googlesource.com/1226492
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#591634}
[modify] https://crrev.com/d2d10b8f9fdd389a02bed05dfb0dda57be5c4c39/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/unit-cycles.html
[modify] https://crrev.com/d2d10b8f9fdd389a02bed05dfb0dda57be5c4c39/third_party/blink/renderer/core/css/css_variable_data.h
[modify] https://crrev.com/d2d10b8f9fdd389a02bed05dfb0dda57be5c4c39/third_party/blink/renderer/core/css/resolver/css_variable_resolver.cc

Project Member

Comment 67 by bugdroid1@chromium.org, Sep 20

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/d8fab4348ea9d77316c7fd27ea48bbc603675ca8

commit d8fab4348ea9d77316c7fd27ea48bbc603675ca8
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Sep 20 13:59:10 2018

Return scoped_refptr<CSSVariableData> from ValueFromCustomProperty.

In the near future, it will be necessary for ValueForCustomProperty
to return a CSSVariableData which may not be stored elsewhere. This
is because we need to do a "non-destructive" pre-resolve of registered
custom properties that are used before high priority properties are
applied.

R=futhark@chromium.org

Bug: 641877
Change-Id: Idb1ab4ba7aae77187a4fd86877a0246e56fc82a4
Reviewed-on: https://chromium-review.googlesource.com/1235936
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592784}
[modify] https://crrev.com/d8fab4348ea9d77316c7fd27ea48bbc603675ca8/third_party/blink/renderer/core/css/resolver/css_variable_resolver.cc
[modify] https://crrev.com/d8fab4348ea9d77316c7fd27ea48bbc603675ca8/third_party/blink/renderer/core/css/resolver/css_variable_resolver.h

Project Member

Comment 68 by bugdroid1@chromium.org, Sep 20

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/befcd8a08c3b31a29b123e113bdd007f611ecf3c

commit befcd8a08c3b31a29b123e113bdd007f611ecf3c
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Sep 20 14:04:39 2018

Propagate Options via ValueForCustomProperty.

This Options object will soon need to carry information that
ValueForCustomProperty needs to act upon. Specifically, it
needs to know whether the resolved CSSVariableData should be
stored on the ComputedStyle before returning.

Also, since the Options object is now available here, let
ValueForCustomProperty return nullptr if a variable is disallowed.
This avoids an extra PropertyRegistation lookup at one of the
callsites.

R=futhark@chromium.org

Bug: 641877
Change-Id: I85f51ff23d23ab404f6fc133e2017f70dd5aea03
Reviewed-on: https://chromium-review.googlesource.com/1235721
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592787}
[modify] https://crrev.com/befcd8a08c3b31a29b123e113bdd007f611ecf3c/third_party/blink/renderer/core/css/resolver/css_variable_resolver.cc
[modify] https://crrev.com/befcd8a08c3b31a29b123e113bdd007f611ecf3c/third_party/blink/renderer/core/css/resolver/css_variable_resolver.h

Project Member

Comment 69 by bugdroid1@chromium.org, Sep 20

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a645a4a75f4f4439eec22016c56d28cc3b833bce

commit a645a4a75f4f4439eec22016c56d28cc3b833bce
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Sep 20 14:09:32 2018

Add variable set/get utilities on CSSVariableResolver.

R=futhark@chromium.org

Bug: 641877
Change-Id: I0b4dc43b29f7e30dbc3eab89f22ffa5505e6a333
Reviewed-on: https://chromium-review.googlesource.com/1235999
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592788}
[modify] https://crrev.com/a645a4a75f4f4439eec22016c56d28cc3b833bce/third_party/blink/renderer/core/css/resolver/css_variable_resolver.cc
[modify] https://crrev.com/a645a4a75f4f4439eec22016c56d28cc3b833bce/third_party/blink/renderer/core/css/resolver/css_variable_resolver.h

Project Member

Comment 70 by bugdroid1@chromium.org, Sep 20

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/687f17cae1a4d97b29cecf9718ada5bee749e470

commit 687f17cae1a4d97b29cecf9718ada5bee749e470
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Sep 20 14:24:35 2018

[css-properties-values-api] Add tests for explicit inheritance.

R=futhark@chromium.org

Bug: 641877
Change-Id: I5f12db2690ec02248cb0533b2f18da2613afea98
Reviewed-on: https://chromium-review.googlesource.com/1235723
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#592791}
[modify] https://crrev.com/687f17cae1a4d97b29cecf9718ada5bee749e470/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-properties-inheritance.html

Project Member

Comment 71 by bugdroid1@chromium.org, Sep 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/e2acbabcf55c13d6b97930d2f69ff7471893e732

commit e2acbabcf55c13d6b97930d2f69ff7471893e732
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Sep 21 09:45:32 2018

[css-properties-values-api] Remove root-inherited variables properly.

Currently, StyleInheritedVariables::RemoveVariable removes variable data
properly (i.e. it sets the value to nullptr locally), but only nullifies
the registered value if we already have an entry for that variable
locally. This means that if we inherit a variable via the root bucket,
calling ::RemoveVariable will not actually remove the variable.

Fix by setting registered value to nullptr if a non-nullptr value would
have been returned from the root.

R=futhark@chromium.org

Bug: 641877
Change-Id: I78f0442bd0a8eba26e74a8a152b5bee048fbc23c
Reviewed-on: https://chromium-review.googlesource.com/1235724
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#593135}
[modify] https://crrev.com/e2acbabcf55c13d6b97930d2f69ff7471893e732/third_party/blink/renderer/core/css/resolver/css_variable_resolver_test.cc
[modify] https://crrev.com/e2acbabcf55c13d6b97930d2f69ff7471893e732/third_party/blink/renderer/core/style/style_inherited_variables.cc

Project Member

Comment 72 by bugdroid1@chromium.org, Sep 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/c0ee2ba26af18ceeb53bc21dca96ca548b5f185c

commit c0ee2ba26af18ceeb53bc21dca96ca548b5f185c
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Sep 21 09:53:03 2018

Allow nullptr in Style[Non]InheritedVariables::SetVariable.

This does not currently cause a crash, entirely because of luck. A value
of nullptr is passed to SetVariable whenever an invalid var()-reference
is used (for example), but it just so happens that needs_resolution_ is
always true in this case, so it short circuits before attempting to de-
reference 'value'.

R=futhark@chromium.org

Bug: 641877
Change-Id: I8b3776a58efb82b5deef74b50561d2ebfd57b817
Reviewed-on: https://chromium-review.googlesource.com/1235725
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#593136}
[modify] https://crrev.com/c0ee2ba26af18ceeb53bc21dca96ca548b5f185c/third_party/blink/renderer/core/css/resolver/css_variable_resolver_test.cc
[modify] https://crrev.com/c0ee2ba26af18ceeb53bc21dca96ca548b5f185c/third_party/blink/renderer/core/style/style_inherited_variables.h
[modify] https://crrev.com/c0ee2ba26af18ceeb53bc21dca96ca548b5f185c/third_party/blink/renderer/core/style/style_non_inherited_variables.h

Project Member

Comment 73 by bugdroid1@chromium.org, Sep 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/13303bdbc5c565e103caebdae2f56285395fd627

commit 13303bdbc5c565e103caebdae2f56285395fd627
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Sep 21 10:36:47 2018

[css-properties-values-api] Refactor setting of custom properties.

We currently have lots of different functions on ComputedStyle for setting
registered properties in different states (resolved/unresolved, inherited/
non-inherited). This is not terribly useful, and mostly just makes the
calling code much more complicated.

Also, the current implementation of Variable::ApplyValue is hard to
understand. This CL refactors that using the new setters on ComputedStyle.

R=futhark@chromium.org

Bug: 641877
Change-Id: I5fc6bed24ec5aadd469a81353dc3b4e221e0f9d1
Reviewed-on: https://chromium-review.googlesource.com/1236004
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#593141}
[modify] https://crrev.com/13303bdbc5c565e103caebdae2f56285395fd627/third_party/blink/renderer/core/animation/css_interpolation_type.cc
[modify] https://crrev.com/13303bdbc5c565e103caebdae2f56285395fd627/third_party/blink/renderer/core/css/properties/longhands/variable.cc
[modify] https://crrev.com/13303bdbc5c565e103caebdae2f56285395fd627/third_party/blink/renderer/core/style/computed_style.cc
[modify] https://crrev.com/13303bdbc5c565e103caebdae2f56285395fd627/third_party/blink/renderer/core/style/computed_style.h

Project Member

Comment 74 by bugdroid1@chromium.org, Sep 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/91a1db293d61df0fcb85e0f36d28416121fe7d0a

commit 91a1db293d61df0fcb85e0f36d28416121fe7d0a
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Sep 21 11:03:38 2018

[css-properties-values-api] Use inherited value for substitution.

When a var()-reference produces tokens that are incompatible with the
current syntax, or the var()-reference refers to a variable that does not
exist, we currently always substitute the initial value, even for
inherited properties. This is incorrect, as the value should behave as
'unset', which means 'inherit' for inherited properties.

Note that if syntax-incompatible tokens are specified directly (not via a
var()-reference), we correctly behave as 'unset'. This is because the
var()-less case is handled by a different code path (variable.cc).

R=futhark@chromium.org

Bug: 641877
Change-Id: Ifdd5435ee77f4b8cd3998967713cb6fcb7e8d5f4
Reviewed-on: https://chromium-review.googlesource.com/1235579
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#593145}
[modify] https://crrev.com/91a1db293d61df0fcb85e0f36d28416121fe7d0a/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-properties-inheritance.html
[modify] https://crrev.com/91a1db293d61df0fcb85e0f36d28416121fe7d0a/third_party/blink/renderer/core/css/resolver/css_variable_resolver.cc

Project Member

Comment 75 by bugdroid1@chromium.org, Sep 25

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/10b193d11ac7733b30e6c7cdade84c0093fba682

commit 10b193d11ac7733b30e6c7cdade84c0093fba682
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Tue Sep 25 12:54:26 2018

[css-properties-values-api] Substitution behavior.

Currently, registered properties substitute into other values exactly
like specified (like unregistered properties). This means that, for
a <length>-registered property with a specified value "10em" (for
instance), when that property is substituted via var()-reference,
the tokens "10em" are inserted. This is not correct, and produces the
wrong result with e.g. inherited values.

This CL changes that, by implementing "absolutization" of registered
custom properties: a process which calculates the computed value of
the property, and then produces a token stream usable for substitution
which is equivalent to the computed value.

 * Currently we resolve var()-references on all custom properties
   before applying high-priority properties. This is no longer
   possible, because the true value of a custom property (also
   unregistered) can not be known until the font has been updated.
   Consider: --reg-len: 1em; --unreg:var(--reg-len). Here, the
   computed value of --unreg should be "16px" (assuming a font-size
   of 16px), and not "1em". If we destructively resolve --unreg
   before the font size is known, we end up with the wrong tokens.

   Hence the resolution process has been moved to after the font
   has been updated.

 * Custom properties must also be usable from high-priority properties.
   Since they are no longer resolved beforehand, they are resolved
   "on the fly", non-destructively. "Non-destructively" means that
   resolved token streams are not stored on ComputedStyle, such that
   any var()-references are kept for the _real_ resolution pass after
   the font has been updated.

   This works, because the high-priority properties do not require
   proper "absolute substitution" to produce the correct value.

   Note that font-size is special, in that font-relative units may
   not be used if they arrive via a registered custom property.

 * There is a special resolving pass for registered custom properties
   (ComputeRegisteredVariables). This pass produces non-absolute CSSValues
   for calculation of animation.

 * Parsing of registered properties now happens entirely in
   CSSVariableResolver, and no longer in variable.cc. Having this in
   multiple places is just confusing.

R=futhark@chromium.org

Bug: 641877
Change-Id: Ic705d0808ffcea0ae5db02fb20870767175bb706
Reviewed-on: https://chromium-review.googlesource.com/1240274
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#593902}
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-properties-inheritance.html
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/unit-cycles.html
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/var-reference-registered-properties.html
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/blink/renderer/core/css/css_variable_data.cc
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/blink/renderer/core/css/css_variable_data.h
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/blink/renderer/core/css/properties/longhands/variable.cc
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/blink/renderer/core/css/resolver/css_variable_resolver.cc
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/blink/renderer/core/css/resolver/css_variable_resolver.h
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/blink/renderer/core/css/resolver/style_resolver.cc
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/blink/renderer/core/css/style_environment_variables.cc
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/blink/renderer/core/style/style_inherited_variables.cc
[modify] https://crrev.com/10b193d11ac7733b30e6c7cdade84c0093fba682/third_party/blink/renderer/core/style/style_non_inherited_variables.cc

Project Member

Comment 76 by bugdroid1@chromium.org, Oct 4

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f2f7784d2b58668b8700d8e38115be6a6899927a

commit f2f7784d2b58668b8700d8e38115be6a6899927a
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Oct 04 09:38:21 2018

[css-properties-values-api] Temporary behavior for <transform-function>.

This CL treats custom properties registered with syntax
<transform-function> as direct CSSStyleValue subclasses, similar to how
e.g. <color> is treated.

This behavior does not get a WPT, because it's not specified (not even as
temporary behavior). It is however consistent with how other "don't know
yet"-types behave in TypedOM, and it's an infinitely more reasonable
temporary behavior that how master currently behaves: a
<transform-function> value becomes CSSUnitValues. For instance,
"transform(10px)" becomes "10px", which is obvious nonsense.

R=futhark@chromium.org

Bug: 641877
Change-Id: Ie06569592192f204d2c05a565458589baeb8378d
Reviewed-on: https://chromium-review.googlesource.com/c/1258328
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#596557}
[add] https://crrev.com/f2f7784d2b58668b8700d8e38115be6a6899927a/third_party/WebKit/LayoutTests/fast/css/css-typedom-transform-function.html
[modify] https://crrev.com/f2f7784d2b58668b8700d8e38115be6a6899927a/third_party/blink/renderer/core/css/cssom/style_value_factory.cc

Project Member

Comment 77 by bugdroid1@chromium.org, Oct 8

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/3cc7ca7b38807589618c722d9168d98266231922

commit 3cc7ca7b38807589618c722d9168d98266231922
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Mon Oct 08 09:26:27 2018

[css-properties-values-api] Proper behavior for direct CSSStyleValues.

In CSS Typed OM, types that are not yet supported by a specialized
CSSStyleValue subclass are represented by "direct" CSSStyleValue objects.
These objects are only valid for their associated property. For instance,
you may not get a (direct) CSSStyleValue object from 'color', and then
set it on 'background-color'; the (direct) CSSStyleValue acquired from
'color' is valid for 'color' only.

The same should apply for registered custom properties; a direct
CSSStyleValue acquired from '--x' is only valid for '--x'.

To do this, blink::CSSUnsupportedStyleValue must be aware of the
custom property name. This means the AtomicString with the custom property
name must be passed around to almost everything. However, if the property
at hand is not a custom property, I want to avoid AtomicString-ing the
name of the property. Hence there are DCHECKs to make sure this is avoided.

Reminder: this CL would be much less ... grotesque and perhaps less
error-prone if dynamic CSSProperties (Ribbon) were in place, but because
we like pain, we decided to not give that project a very high priority.

R=chrishtr@chromium.org

Bug: 641877
Change-Id: I99af4745d1d33365759e9fd4acef5082ab213229
Reviewed-on: https://chromium-review.googlesource.com/c/1257916
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#597503}
[modify] https://crrev.com/3cc7ca7b38807589618c722d9168d98266231922/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/3cc7ca7b38807589618c722d9168d98266231922/third_party/blink/renderer/build/scripts/core/css/templates/cssom_types.cc.tmpl
[modify] https://crrev.com/3cc7ca7b38807589618c722d9168d98266231922/third_party/blink/renderer/core/css/cssom/css_style_value.cc
[modify] https://crrev.com/3cc7ca7b38807589618c722d9168d98266231922/third_party/blink/renderer/core/css/cssom/css_unsupported_style_value.h
[modify] https://crrev.com/3cc7ca7b38807589618c722d9168d98266231922/third_party/blink/renderer/core/css/cssom/cssom_types.h
[modify] https://crrev.com/3cc7ca7b38807589618c722d9168d98266231922/third_party/blink/renderer/core/css/cssom/style_property_map.cc
[modify] https://crrev.com/3cc7ca7b38807589618c722d9168d98266231922/third_party/blink/renderer/core/css/cssom/style_property_map_read_only.cc
[modify] https://crrev.com/3cc7ca7b38807589618c722d9168d98266231922/third_party/blink/renderer/core/css/cssom/style_value_factory.cc
[modify] https://crrev.com/3cc7ca7b38807589618c722d9168d98266231922/third_party/blink/renderer/core/css/cssom/style_value_factory.h

Project Member

Comment 78 by bugdroid1@chromium.org, Oct 10

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b59c44708859da79e43f97807e971f266e5cb60d

commit b59c44708859da79e43f97807e971f266e5cb60d
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Wed Oct 10 07:33:31 2018

[css-properties-values-api] Include initial values in computedStyleMap.

Registered properties with initial values are currently missing from the
computedStyleMap, because such properties are not explicitly stored on
individual computed styles.

To fix this, do an extra pass over the PropertyRegistrations to "fill in
blanks" with initial values.

R=chrishtr@chromium.org

Bug: 641877
Change-Id: If36cb3ef3d419ff547e8b4073cdd9ec298c539a0
Reviewed-on: https://chromium-review.googlesource.com/c/1264575
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#598243}
[modify] https://crrev.com/b59c44708859da79e43f97807e971f266e5cb60d/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/b59c44708859da79e43f97807e971f266e5cb60d/third_party/blink/renderer/core/css/computed_style_css_value_mapping.cc
[modify] https://crrev.com/b59c44708859da79e43f97807e971f266e5cb60d/third_party/blink/renderer/core/css/property_registry.cc
[modify] https://crrev.com/b59c44708859da79e43f97807e971f266e5cb60d/third_party/blink/renderer/core/css/property_registry.h

Project Member

Comment 79 by bugdroid1@chromium.org, Oct 10

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/96ab66655c7395ccd27d3bcd41009460f84f0f57

commit 96ab66655c7395ccd27d3bcd41009460f84f0f57
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Wed Oct 10 07:38:00 2018

[css-properties-values-api] Proper types from StylePropertyMap iterator.

When iterating a StylePropertyMap, any registered custom properties in
that map must have the appropriate type according to the registration.
Currently all custom properties are always CSSUnparsedValue, which is only
correct for unregistered properties and properties registered as "*".

Fixed by parsing the value on its way out, similar to how get/getAll
implements the same behavior.

R=chrishtr@chromium.org

Bug: 641877
Change-Id: I5e0b2d064cd0ce4827eabf464a5cf0a0e138c5db
Reviewed-on: https://chromium-review.googlesource.com/c/1264540
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#598247}
[modify] https://crrev.com/96ab66655c7395ccd27d3bcd41009460f84f0f57/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-type.https.html
[modify] https://crrev.com/96ab66655c7395ccd27d3bcd41009460f84f0f57/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/96ab66655c7395ccd27d3bcd41009460f84f0f57/third_party/blink/renderer/core/css/cssom/style_property_map_read_only.cc

Project Member

Comment 80 by bugdroid1@chromium.org, Oct 11

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/84a2684f692acb201b434ae54d2915dc2d3143ce

commit 84a2684f692acb201b434ae54d2915dc2d3143ce
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Oct 11 02:13:30 2018

[css-typed-om] Refactor CSSValue coercion.

In CoerceStyleValuesOrStrings, instead of temporarily storing CSSValues
in a vector, then moving those values to a CSSValueList, store a
CSSStyleValueVector, and perform the CSSStyleValue -> CSSValue conversion
during the CSSValueList construction.

This is a preparatory CL for a subsequent change where it's necessary to
have a CSSStyleValueVector of the incoming values.

R=chrishtr@chromium.org

Bug: 641877
Change-Id: I76bd76c42c4194772b72f80c3ca86d57848a1c72
Reviewed-on: https://chromium-review.googlesource.com/c/1270997
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#598634}
[modify] https://crrev.com/84a2684f692acb201b434ae54d2915dc2d3143ce/third_party/blink/renderer/core/css/cssom/style_property_map.cc
[modify] https://crrev.com/84a2684f692acb201b434ae54d2915dc2d3143ce/third_party/blink/renderer/core/css/cssom/style_value_factory.cc
[modify] https://crrev.com/84a2684f692acb201b434ae54d2915dc2d3143ce/third_party/blink/renderer/core/css/cssom/style_value_factory.h

Project Member

Comment 81 by bugdroid1@chromium.org, Oct 11

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/490c0f22670e08c45fdaf54c81433c5eeb627ac5

commit 490c0f22670e08c45fdaf54c81433c5eeb627ac5
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Oct 11 18:17:24 2018

[css-properties-values-api] Avoid viewport dependent tests.

The test registered-property-computation.html fails on wpt.fyi, because
it assumes that the tests are run in a viewport with specific dimensions.

This CL fixes that by using a standard property as a reference. For
instance, to figure out the expected value in pixels for '10vw', we
compute min-height:10vw and use that result as the expected value.

Also added some generally useful utils, and rewrote the test using those
utils to make the test more understandable.

R=futhark@chromium.org

Bug: 641877
Change-Id: Ie1ceb334eefee6e76015447f24148638ad8c55a6
Reviewed-on: https://chromium-review.googlesource.com/c/1275893
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#598847}
[modify] https://crrev.com/490c0f22670e08c45fdaf54c81433c5eeb627ac5/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation.html
[add] https://crrev.com/490c0f22670e08c45fdaf54c81433c5eeb627ac5/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/resources/utils.js
[add] https://crrev.com/490c0f22670e08c45fdaf54c81433c5eeb627ac5/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/self-utils.html

Project Member

Comment 82 by bugdroid1@chromium.org, Oct 12

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/d84303e41153ea9cb0f6475b6bb9e430666022a2

commit d84303e41153ea9cb0f6475b6bb9e430666022a2
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Oct 12 10:33:59 2018

[css-properties-values-api] Multi-value StylePropertyMap.set.

This adds support for setting multiple values with TypedOM for list-valued
custom properties. For example, for a property --x with syntax <length>+,
it will now be possible to do:

  element.attributeStyleMap.set('--x', CSS.px(1), CSS.px(2));

This is done by producing a CSSVariableReferenceValue holding tokens
equivalent to the incoming CSSStyleValues, provided that those values
match the grammar of the custom property.

R=chrishtr@chromium.org

Bug: 641877
Change-Id: Ic28497edbbea894a9c09b840dcb6c8fb825d99bb
Reviewed-on: https://chromium-review.googlesource.com/c/1270963
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#599164}
[modify] https://crrev.com/d84303e41153ea9cb0f6475b6bb9e430666022a2/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/d84303e41153ea9cb0f6475b6bb9e430666022a2/third_party/blink/renderer/core/css/css_syntax_descriptor.h
[modify] https://crrev.com/d84303e41153ea9cb0f6475b6bb9e430666022a2/third_party/blink/renderer/core/css/cssom/style_property_map.cc

Project Member

Comment 83 by bugdroid1@chromium.org, Oct 12

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/84056b7e0dee6cb71b889254c2f33c0b338002fb

commit 84056b7e0dee6cb71b889254c2f33c0b338002fb
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Fri Oct 12 12:05:35 2018

[css-properties-values-api] Support StylePropertyMap.append.

This CL makes it possible to append values to list-valued properties.

To do this, we must produce a CSSStyleValueVector which holds the final
value produced by the append (i.e. the concatenation of the existing
values and the incoming values). Then (like for StylePropertyMap.set),
a CSSVariableReferenceValue with equivalent tokens is created from that
vector.

Bonus: Fix names of some tests to make it easier to read the output.

R=chrishtr@chromium.org

Bug: 641877
Change-Id: I0d58f66255a9ff7e14c1ee8f4d243353b9a4a0da
Reviewed-on: https://chromium-review.googlesource.com/c/1270967
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Cr-Commit-Position: refs/heads/master@{#599177}
[modify] https://crrev.com/84056b7e0dee6cb71b889254c2f33c0b338002fb/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/84056b7e0dee6cb71b889254c2f33c0b338002fb/third_party/blink/renderer/core/css/cssom/style_property_map.cc
[modify] https://crrev.com/84056b7e0dee6cb71b889254c2f33c0b338002fb/third_party/blink/renderer/core/css/cssom/style_property_map_read_only.cc
[modify] https://crrev.com/84056b7e0dee6cb71b889254c2f33c0b338002fb/third_party/blink/renderer/core/css/cssom/style_property_map_read_only.h

Project Member

Comment 84 by bugdroid1@chromium.org, Oct 18

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/294b36db8e7711715a631c4cbb508a5b8ed13554

commit 294b36db8e7711715a631c4cbb508a5b8ed13554
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Oct 18 08:50:00 2018

[css-properties-values-api] Test that interpolated values reach worklet.

R=ikilpatrick@chromium.org

Bug: 641877
Change-Id: Ic0403289f9deaf97369962d6901bafb58dc46931
Reviewed-on: https://chromium-review.googlesource.com/c/1283018
Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#600698}
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-001.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-002.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-003.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-004.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-005.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-006.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-007.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-008.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-009.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-interpolation-010.https.html
[add] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/resources/utils.js

Project Member

Comment 85 by bugdroid1@chromium.org, Oct 18

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7

commit 6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Oct 18 08:54:51 2018

[css-properties-values-api] Test styleMap in paint worklet.

Unfortunately, the existing test for this does too much behind a single
green square. If even a single assertion were to fail, it would hide the
result of all the other rests.

At the same time, adding 40something tests is perhaps a bit excessive, so
I've tried to reduce that number somewhat (mostly by only testing one
of the initial value cases, which I think is reasonable).

The aspect of the deleted test which verified that values were observable
from all API entry points (has, get, getAll, size and iterator) is now
a separate test as well.

R=ikilpatrick@chromium.org

Bug: 641877
Change-Id: Ie9316583ccef0ee4ddcaf688b7c1fac422649a39
Reviewed-on: https://chromium-review.googlesource.com/c/1286855
Reviewed-by: Ian Kilpatrick <ikilpatrick@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#600699}
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-stylemap.https.html
[delete] https://crrev.com/294b36db8e7711715a631c4cbb508a5b8ed13554/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-type.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-001.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-002.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-003.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-004.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-005.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-006.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-007.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-008.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-009.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-010.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-011.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-012.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-013.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-014.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-015.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-016.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-017.https.html
[add] https://crrev.com/6b9b9fb0e5eab79c2a1851c6862baeb6c7cfd1c7/third_party/WebKit/LayoutTests/external/wpt/css/css-paint-api/registered-property-value-018.https.html

Project Member

Comment 86 by bugdroid1@chromium.org, Oct 18

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/57c4e7d9c45df9419066cbd92cc75581be53669f

commit 57c4e7d9c45df9419066cbd92cc75581be53669f
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Oct 18 10:20:31 2018

[css-properties-values-api] Support calc() values for <integer>.

For custom properties registered with <integer>, it should according to
CSS Values and Units Level 4 be possible to apply non-integral values,
and then have the value round to the nearest integer computed value time.

To do this, this CL ...:

 * Changes the parsing of <integer> values such that non-integral calc()
   expressions are allowed.
 * Recognizes such calc()-expressions computed-value time, resolves them,
   and rounds them to the nearest integer.
 * Wraps values such as CSS.number(1.5) in calc() if necessary, when
   setting such values using Typed OM.

R=futhark@chromium.org

Bug: 641877
Change-Id: I2d4d7c4d72c9b2069f2fe10b1be1b4b94d5900e2
Reviewed-on: https://chromium-review.googlesource.com/c/1280663
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#600716}
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/register-property-syntax-parsing-expected.txt
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/register-property-syntax-parsing.html
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation.html
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/typedom.tentative.html
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/build/scripts/core/css/templates/cssom_types.cc.tmpl
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/css_syntax_descriptor.cc
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/css_syntax_descriptor.h
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/cssom/css_style_value.h
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/cssom/css_unit_value.cc
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/cssom/css_unit_value.h
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/cssom/cssom_types.h
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/cssom/style_property_map.cc
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/parser/css_property_parser_helpers.cc
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/parser/css_property_parser_helpers.h
[modify] https://crrev.com/57c4e7d9c45df9419066cbd92cc75581be53669f/third_party/blink/renderer/core/css/resolver/style_builder_converter.cc

Project Member

Comment 89 by bugdroid1@chromium.org, Oct 22

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7374df78652ad0a0a17cac686bf2068447b270e6

commit 7374df78652ad0a0a17cac686bf2068447b270e6
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Mon Oct 22 12:02:04 2018

[css-properties-values-api] Put image and transform values behind flags.

This CL adds new runtime flags which makes it possible to ship without
support for <image>, <transform-function> and <transform-list>.

Also replace comment near CSSPaintAPIArguments with 'depends_on'. (Added
before I knew 'depends_on' existed).

R=chrishtr@chromium.org

Bug: 641877
Change-Id: Ic50bdaffc84a7037c23841c9eb53eb9b331ad680
Reviewed-on: https://chromium-review.googlesource.com/c/1273061
Reviewed-by: Chris Harrelson <chrishtr@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#601534}
[modify] https://crrev.com/7374df78652ad0a0a17cac686bf2068447b270e6/third_party/WebKit/LayoutTests/VirtualTestSuites
[add] https://crrev.com/7374df78652ad0a0a17cac686bf2068447b270e6/third_party/WebKit/LayoutTests/virtual/stable/fast/css/stable/README.txt
[add] https://crrev.com/7374df78652ad0a0a17cac686bf2068447b270e6/third_party/WebKit/LayoutTests/virtual/stable/fast/css/stable/css-registered-custom-property-syntax.html
[modify] https://crrev.com/7374df78652ad0a0a17cac686bf2068447b270e6/third_party/blink/renderer/core/css/css_syntax_descriptor.cc
[modify] https://crrev.com/7374df78652ad0a0a17cac686bf2068447b270e6/third_party/blink/renderer/platform/runtime_enabled_features.json5

Project Member

Comment 90 by bugdroid1@chromium.org, Oct 29

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1bb2a50f710edb32de9063b71f23f80a8802de16

commit 1bb2a50f710edb32de9063b71f23f80a8802de16
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Mon Oct 29 21:15:39 2018

[css-properties-values-api] Proper computed value for <color>.

As of an imminent spec change, <color> values no longer compute to their
specified value, but behave like <color> values in general.

Note that color keywords are parsed as CSSIdentifierValue (holding a
CSSValueID), and custom idents are parsed as CSSCustomIdentValue (holding a
String), which is why the "tomato | <color>" works as it should.

R=futhark@chromium.org

Bug: 641877
Change-Id: I946536a9d54dbaa7af589cb99acdba72f37fe016
Reviewed-on: https://chromium-review.googlesource.com/c/1303365
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603628}
[modify] https://crrev.com/1bb2a50f710edb32de9063b71f23f80a8802de16/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation.html
[modify] https://crrev.com/1bb2a50f710edb32de9063b71f23f80a8802de16/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-cssom.html
[modify] https://crrev.com/1bb2a50f710edb32de9063b71f23f80a8802de16/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-initial.html
[modify] https://crrev.com/1bb2a50f710edb32de9063b71f23f80a8802de16/third_party/blink/renderer/core/css/property_registration.cc
[modify] https://crrev.com/1bb2a50f710edb32de9063b71f23f80a8802de16/third_party/blink/renderer/core/css/resolver/style_builder_converter.cc
[modify] https://crrev.com/1bb2a50f710edb32de9063b71f23f80a8802de16/third_party/blink/renderer/core/css/resolver/style_builder_converter.h

Project Member

Comment 91 by bugdroid1@chromium.org, Oct 29

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b75e4f1d8151eb16a067e1d9c9e995bef1bf2aba

commit b75e4f1d8151eb16a067e1d9c9e995bef1bf2aba
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Mon Oct 29 22:52:41 2018

[css-properties-values-api] Compute <angle> values to 'deg'.

R=futhark@chromium.org

Bug: 641877
Change-Id: I52878c9bca16765d3b32127b5637a7ec521e76dc
Reviewed-on: https://chromium-review.googlesource.com/c/1304416
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603672}
[modify] https://crrev.com/b75e4f1d8151eb16a067e1d9c9e995bef1bf2aba/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation.html
[modify] https://crrev.com/b75e4f1d8151eb16a067e1d9c9e995bef1bf2aba/third_party/blink/renderer/core/css/resolver/style_builder_converter.cc

Project Member

Comment 92 by bugdroid1@chromium.org, Oct 30

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/c2d00575676e5532dbc4841916ce513caa630e0d

commit c2d00575676e5532dbc4841916ce513caa630e0d
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Tue Oct 30 08:14:09 2018

[css-properties-values-api] Compute <time> values to seconds.

The CSSPrimitiveValue::IsTime function (non-static) did for some reason
use GetType() instead of TypeWithCalcResolved(), even though both
ComputeSeconds() and TypeWithCalcResolved() do seemingly handle calculated
time correctly.

R=futhark@chromium.org

Bug: 641877
Change-Id: I0e927265f01855b8262ed9201df9eae647171b8d
Reviewed-on: https://chromium-review.googlesource.com/c/1304481
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603832}
[modify] https://crrev.com/c2d00575676e5532dbc4841916ce513caa630e0d/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation.html
[modify] https://crrev.com/c2d00575676e5532dbc4841916ce513caa630e0d/third_party/blink/renderer/core/BUILD.gn
[modify] https://crrev.com/c2d00575676e5532dbc4841916ce513caa630e0d/third_party/blink/renderer/core/css/css_primitive_value.h
[add] https://crrev.com/c2d00575676e5532dbc4841916ce513caa630e0d/third_party/blink/renderer/core/css/css_primitive_value_test.cc
[modify] https://crrev.com/c2d00575676e5532dbc4841916ce513caa630e0d/third_party/blink/renderer/core/css/resolver/style_builder_converter.cc

Project Member

Comment 93 by bugdroid1@chromium.org, Oct 30

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/d5347428b4f0d263995c3f79fcc07c41878474a2

commit d5347428b4f0d263995c3f79fcc07c41878474a2
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Tue Oct 30 09:40:13 2018

[css-properties-values-api] Compute <resolution> values to 'dppx'.

Unfortunately, calc() in <resolution> values is not yet supported in Blink.
(Such values were not allowed for <resolution> before CSS Values and Units
Level 4).

R=futhark@chromium.org

Bug: 641877
Change-Id: I4b3fdcd24f37018a415489e7d15220dc34698c04
Reviewed-on: https://chromium-review.googlesource.com/c/1304554
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603843}
[add] https://crrev.com/d5347428b4f0d263995c3f79fcc07c41878474a2/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation-expected.txt
[modify] https://crrev.com/d5347428b4f0d263995c3f79fcc07c41878474a2/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation.html
[modify] https://crrev.com/d5347428b4f0d263995c3f79fcc07c41878474a2/third_party/blink/renderer/core/css/css_primitive_value.h
[modify] https://crrev.com/d5347428b4f0d263995c3f79fcc07c41878474a2/third_party/blink/renderer/core/css/css_primitive_value_test.cc
[modify] https://crrev.com/d5347428b4f0d263995c3f79fcc07c41878474a2/third_party/blink/renderer/core/css/resolver/style_builder_converter.cc

Project Member

Comment 94 by bugdroid1@chromium.org, Oct 30

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/cf3c92163fd0f8c4da56d0d30ab1a314c0448578

commit cf3c92163fd0f8c4da56d0d30ab1a314c0448578
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Tue Oct 30 10:16:48 2018

[css-properties-values-api] Test computed values individually.

 - Having large buckets of assertions in the same test is not great if
   one of those assertions fail.
 - Running all tests twice with and without inherited font size is not
   relevant for a large amount of the tests.

Therefore:

 - Use only one assertion per test, allowing fine-grained test
   expectations.
 - Only test inherited font-size for a few relevant cases.

R=futhark@chromium.org

Bug: 641877
Change-Id: I0a26dc29da4ca3be04f33b86bb063e48cb2f4c08
Reviewed-on: https://chromium-review.googlesource.com/c/1304520
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603850}
[modify] https://crrev.com/cf3c92163fd0f8c4da56d0d30ab1a314c0448578/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation-expected.txt
[modify] https://crrev.com/cf3c92163fd0f8c4da56d0d30ab1a314c0448578/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-computation.html

Project Member

Comment 95 by bugdroid1@chromium.org, Oct 30

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a70e4ab8a6afd62674990a4e6d36bc9e74806381

commit a70e4ab8a6afd62674990a4e6d36bc9e74806381
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Tue Oct 30 10:52:56 2018

[css-properties-values-api] Test initial values individually.

Split up the assertions of the initial value test into multiple tests.
This makes it possible to add test expectations for things which are not
supported yet.

R=futhark@chromium.org

Bug: 641877
Change-Id: I8756b2d066a8bc2ae542ca033d98754255aeb2b2
Reviewed-on: https://chromium-review.googlesource.com/c/1304560
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603859}
[modify] https://crrev.com/a70e4ab8a6afd62674990a4e6d36bc9e74806381/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/registered-property-initial.html

Project Member

Comment 96 by bugdroid1@chromium.org, Oct 30

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/109bf68cc0c62fdfde2c1ad50e3612da2b3a0217

commit 109bf68cc0c62fdfde2c1ad50e3612da2b3a0217
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Tue Oct 30 11:03:45 2018

[css-properties-values-api] Validate generate_property argument.

This prevents silently dropping invalid arguments. For example, the
following currently generates a non-inherited property:

  let name = generate_property(syntax: '<length>', inherited: true);

This is because 'inherited' is not an option for CSS.registerProperty (the
actual option is 'inherits').

With this change, an exception is thrown if unknown options are provided.

R=futhark@chromium.org

Bug: 641877
Change-Id: I7b639651c331aa705416db95a3de751353648031
Reviewed-on: https://chromium-review.googlesource.com/c/1304522
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#603862}
[modify] https://crrev.com/109bf68cc0c62fdfde2c1ad50e3612da2b3a0217/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/resources/utils.js
[modify] https://crrev.com/109bf68cc0c62fdfde2c1ad50e3612da2b3a0217/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/self-utils.html

Project Member

Comment 97 by bugdroid1@chromium.org, Nov 14

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/4c1c6809373770c7af95a3cd7b278dc55cdbcd12

commit 4c1c6809373770c7af95a3cd7b278dc55cdbcd12
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Wed Nov 14 16:59:37 2018

[css-properties-values-api] Support fallbacks.

According to css-variables-1, any custom property that participates in a
cycle is invalid. This also applies to registered custom properties.
In the current implementation, however, registered custom properties
with an initial value can not become invalid; they compute to their initial
value instead, as provided by registerProperty. A consequence of this, is
that fallbacks (specified by var()-references) are never triggered if the
referenced property is a registered property with an initial value defined.

The value for any unregistered custom property, if no other value is
specified, is the invalid initial value described by css-variables-1.
This means we can just avoid storing the variable on ComputedStyle, to
signify the invalid initial value.

However, the value for any registered custom property, if no other value is
specified, can be the initial value specified by registerProperty. When
there is no value explicitly stored on ComputedStyle, we check
StyleInitialData and fetch the initial value from there. Hence, we can not
use the absence of a value to signify an invalid registered variable, as
we already use this state to mean "initial value from registerProperty".
This means that we must explicitly store a value for registered properties
that participate in a cycle. This CL adds CSSInvalidVariableValue to do
this.

 * When resolving a registered custom property, if a cycle is detected, set
   the registered value to CSSInvalidVariableValue.
 * When looking up a registered custom property, if we already have the
   value CSSInvalidVariableValue, return nullptr instead of initial data.
   This triggers fallbacks.
 * The code that set the cycle_detected flag was weird; a cycle could be
   marked as detected, even though ResolveTokenRange succeeded. This meant
   that any custom property which referenced a property in a cycle would
   also be treated as part of the cycle, which is wrong. Fixed by only
   setting the cycle_detected flag when we have cycle start points.
 * CSSInterpolationType did not initialize its cycle_detected variable,
   which led to undefined behavior.

R=futhark@chromium.org

Bug: 641877
Change-Id: I2c518b176de26f7b2f05b36b568041a228fcb0ea
Reviewed-on: https://chromium-review.googlesource.com/c/1333758
Commit-Queue: Anders Ruud <andruud@chromium.org>
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Cr-Commit-Position: refs/heads/master@{#608014}
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/var-reference-registered-properties-cycles.html
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/BUILD.gn
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/animation/css_interpolation_type.cc
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/BUILD.gn
[add] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/css_invalid_variable_value.cc
[add] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/css_invalid_variable_value.h
[add] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/css_invalid_variable_value_test.cc
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/css_value.cc
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/css_value.h
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/css_value_pool.cc
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/css_value_pool.h
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/resolver/css_variable_resolver.cc
[modify] https://crrev.com/4c1c6809373770c7af95a3cd7b278dc55cdbcd12/third_party/blink/renderer/core/css/resolver/css_variable_resolver.h

Project Member

Comment 98 by bugdroid1@chromium.org, Nov 15

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/67e449b925663f3b91e0f588da99178bf696fbdf

commit 67e449b925663f3b91e0f588da99178bf696fbdf
Author: Anders Hartvoll Ruud <andruud@chromium.org>
Date: Thu Nov 15 14:56:10 2018

[css-properties-values-api] Validate var() fallbacks.

According to a recent spec edit, any fallback in a var()-reference must
match the syntax of the referenced property, otherwise the var()-reference
is invalid. This applies even if the fallback is not used.

To implement this, ResolveFallback now returns kNone/kFail/kSuccess instead
of a bool. This is necessary, because the kNone case may be both an error
state and a success state, depending on whether the fallback is being
used or not, hence a plain bool is not sufficient.

R=futhark@chromium.org

Bug: 641877
Change-Id: I951eef6335bf1cd4064d59959d73ec4fa39c9ee0
Reviewed-on: https://chromium-review.googlesource.com/c/1335576
Reviewed-by: Rune Lillesveen <futhark@chromium.org>
Commit-Queue: Anders Ruud <andruud@chromium.org>
Cr-Commit-Position: refs/heads/master@{#608365}
[modify] https://crrev.com/67e449b925663f3b91e0f588da99178bf696fbdf/third_party/WebKit/LayoutTests/external/wpt/css/css-properties-values-api/var-reference-registered-properties.html
[modify] https://crrev.com/67e449b925663f3b91e0f588da99178bf696fbdf/third_party/blink/renderer/core/css/resolver/css_variable_resolver.cc
[modify] https://crrev.com/67e449b925663f3b91e0f588da99178bf696fbdf/third_party/blink/renderer/core/css/resolver/css_variable_resolver.h

Sign in to add a comment