@@ -2688,7 +2688,7 @@ The way that a {{CSSStyleValue}} serializes is dependent on how the value was co
2688
2688
: otherwise, if the value was constructed using an IDL constructor
2689
2689
:: the serialization is specified in the sections below.
2690
2690
: otherwise, if the value was extracted from the CSSOM
2691
- :: the serialization matches the CSSOM serialization of the corresponding value .
2691
+ :: the serialization is specified in [[#cssom- serialization]] below .
2692
2692
2693
2693
<div class='example'>
2694
2694
@@ -2801,6 +2801,36 @@ of serializations of the contained {{CSSTransformComponent}} objects.
2801
2801
{{CSSFontFaceValue}} objects are serialized to the value of their contained
2802
2802
{{CSSFontFaceValue/fontFamilyName}} .
2803
2803
2804
+ Serialization from CSSOM Values {#cssom-serialization}
2805
+ ------------------------------------------------------
2806
+
2807
+ {{CSSStyleValue}} objects produced by the user agent from values in the CSSOM,
2808
+ rather than directly constructed by the author,
2809
+ are serialized according to the following rules,
2810
+ depending on the property they came from:
2811
+
2812
+ : 'border-image'
2813
+ ::
2814
+ 1. Let |values| initially be the empty [=list=] .
2815
+ 2. If 'border-image-source' is not ''border-image-source/none'' ,
2816
+ serialize 'border-image-source' and append it to |values|.
2817
+ 3. If 'border-image-slice' does not specify ''100%'' for all sides and omits the ''border-image-slice/fill'' keyword,
2818
+ serialize 'border-image-slice' and append it to |values|.
2819
+ 4. If 'border-image-width' does not specify ''1'' for all sides,
2820
+ append "/ " (U+002F FORWARD SLASH followed by U+0020 SPACE)
2821
+ to the result of serializing 'border-image-width' and append it to |values|.
2822
+ 5. If 'border-image-outset' does not specify ''0'' for all sides,
2823
+ append "/ " (U+002F FORWARD SLASH followed by U+0020 SPACE)
2824
+ to the result of serializing 'border-image-outset' and append it to |values|.
2825
+ 6. If 'border-image-repeat' is not ''border-image-repeat/stretch'' in both axises,
2826
+ serialize 'border-image-repeat' and append it to |values|.
2827
+ 7. If |values| is [=list/empty=] ,
2828
+ serialize the keyword <css> none</css> and append it to |values|.
2829
+ 8. Return the result of concatenating all the items in |values|,
2830
+ separated by " " (U+0020 SPACE).
2831
+
2832
+
2833
+
2804
2834
Security Considerations {#security-considerations}
2805
2835
==================================================
2806
2836
0 commit comments