From 9da6deb4c7a1893c5f524991e7beef1d7a3ef692 Mon Sep 17 00:00:00 2001 From: Darren Shen Date: Thu, 1 Feb 2018 13:16:15 +1100 Subject: [PATCH] Extend match concept to other style values --- css-typed-om/Overview.bs | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/css-typed-om/Overview.bs b/css-typed-om/Overview.bs index 3ffff4eb..1ec4ab8f 100644 --- a/css-typed-om/Overview.bs +++ b/css-typed-om/Overview.bs @@ -355,7 +355,7 @@ probably in an appendix. and a [=string=] or {{CSSStyleValue}} |value|: : If |value| is a {{CSSStyleValue}}, - :: If |value| does not match the grammar of a [=list-valued property iteration=] of |property|, + :: If |value| does not [=match a CSS production|match the grammar=] of a [=list-valued property iteration=] of |property|, [=throw=] a {{TypeError}} and exit this algorithm. Otherwise, return the |value|. @@ -366,6 +366,18 @@ probably in an appendix. Note: This can throw a {{TypeError}} instead. +
+ A {{CSSStyleValue}} is said to match a CSS production + based on the following rules: + + * A {{CSSKeywordValue}} always matches <>. + * A {{CSSTransformValue}} always matches <>. + * A {{CSSPositionValue}} always matches <>. + * A {{CSSNumericValue}} matches what its type [=CSSNumericValue/matches=]. + * A {{CSSURLImageValue}} always matches <>. + * Any subclass of {{CSSImageValue}} always matches <>. +
+
The get(|property|) method, when called on a {{StylePropertyMap}} |this|,