Closed Bug 1496085 Opened 1 year ago Closed 1 year ago

[wpt-sync] Sync PR 13334 - [css-properties-values-api] Proper behavior for direct CSSStyleValues.


(Core :: CSS Parsing and Computation, enhancement, P4)




Tracking Status
firefox64 --- fixed


(Reporter: wptsync, Unassigned)




(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 13334 into mozilla-central (this bug is closed when the sync is complete).

Details from upstream follow.

Anders Hartvoll Ruud <> wrote:
>  [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.
>  Bug: 641877
>  Change-Id: I99af4745d1d33365759e9fd4acef5082ab213229
>  Reviewed-on:
>  WPT-Export-Revision: 21317723232b50675dbdb89ce60ffdd35ba4bf3a
Component: web-platform-tests → CSS Parsing and Computation
Product: Testing → Core
Ran 1 tests and 20 subtests
FAIL   : 20
ERROR  : 1
Pushed by
[wpt PR 13334] - [css-properties-values-api] Proper behavior for direct CSSStyleValues., a=testonly
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla64
You need to log in before you can comment on or make changes to this bug.