@samitouri / QOS-React / commits / 4c3470eef8

Refactor DOM attribute code (take two) (#11815)

* Harden tests around init/addition/update/removal of aliased attributes I noticed some patterns weren't being tested. * Call setValueForProperty() for null and undefined The branching before the call is unnecessary because setValueForProperty() already has an internal branch that delegates to deleteValueForProperty() for null and undefined through the shouldIgnoreValue() check. The goal is to start unifying these methods because their separation doesn't reflect the current behavior (e.g. for unknown properties) anymore, and obscures what actually happens with different inputs. * Inline deleteValueForProperty() into setValueForProperty() Now we don't read propertyInfo twice in this case. I also dropped a few early returns. I added them a while ago when we had Stack-only tracking of DOM operations, and some operations were being counted twice because of how this code is structured. This isn't a problem anymore (both because we don't track operations, and because I've just inlined this method call). * Inline deleteValueForAttribute() into setValueForAttribute() The special cases for null and undefined already exist in setValueForAttribute(). * Delete some dead code * Make setValueForAttribute() a branch of setValueForProperty() Their naming is pretty confusing by now. For example setValueForProperty() calls setValueForAttribute() when shouldSetAttribute() is false (!). I want to refactor (as in, inline and then maybe factor it out differently) the relation between them. For now, I'm consolidating the callers to use setValueForProperty(). * Make it more obvious where we skip and when we reset attributes The naming of these methods is still very vague and conflicting in some cases. Will need further work. * Rewrite setValueForProperty() with early exits This makes the flow clearer in my opinion. * Move shouldIgnoreValue() into DOMProperty It was previously duplicated. It's also suspiciously similar in purpose to shouldTreatAttributeValueAsNull() so I want to see if there is a way to unify them. * Use more specific methods for testing validity * Unify shouldTreatAttributeValueAsNull() and shouldIgnoreValue() * Remove shouldSetAttribute() Its naming was confusing and it was used all over the place instead of more specific checks. Now that we only have one call site, we might as well inline and get rid of it. * Remove unnecessary condition * Remove another unnecessary condition * Add Flow coverage * Oops * Fix lint (ESLint complains about Flow suppression) * Fix treatment of Symbol/Function values on boolean attributes They weren't being properly skipped because of the early return. I added tests for this case. * Avoid getPropertyInfo() calls I think this PR looks worse on benchmarks because we have to read propertyInfo in different places. Originally I tried to get rid of propertyInfo, but looks like it's important for performance after all. So now I'm going into the opposite direction, and precompute propertyInfo as early as possible, and then just pass it around. This way we can avoid extra lookups but keep functions nice and modular. * Pass propertyInfo as argument to getValueForProperty() It always exists because this function is only called for known properties. * Make it clearer this branch is boolean-specific I wrote this and then got confused myself. * Memoize whether propertyInfo accepts boolean value Since we run these checks for all booleans, might as well remember it. * Fix a crash when numeric property is given a Symbol * Record attribute table The changes reflect that SSR doesn't crash with symbols anymore (and just warns, consistently with the client). * Refactor attribute initialization Instead of using flags, explicitly group similar attributes/properties. * Optimization: we know built-in attributes are never invalid * Use strict comparison * Rename methods for clarity * Lint nit * Minor tweaks * Document all the different attribute types

Dan Abramov committed Dec 10, 2017 at 16:58 UTC 4c3470eef832d64e03d18c19a70f2501f9becbfd
9 files changed +913 -737
fixtures/attribute-behavior/AttributeTableSnapshot.md
+243 -243
@@ -118,8 +118,8 @@
118 | `accentHeight=(string 'false')`| (changed)| `"false"` |
119 | `accentHeight=(string 'on')`| (changed)| `"on"` |
120 | `accentHeight=(string 'off')`| (changed)| `"off"` |
121 -| `accentHeight=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
122 -| `accentHeight=(function)`| (initial, warning, ssr mismatch)| `<null>` |
121 +| `accentHeight=(symbol)`| (initial, warning)| `<null>` |
122 +| `accentHeight=(function)`| (initial, warning)| `<null>` |
123 | `accentHeight=(null)`| (initial)| `<null>` |
124 | `accentHeight=(undefined)`| (initial)| `<null>` |
125
@@ -218,8 +218,8 @@
218 | `acceptCharset=(string 'false')`| (changed)| `"false"` |
219 | `acceptCharset=(string 'on')`| (changed)| `"on"` |
220 | `acceptCharset=(string 'off')`| (changed)| `"off"` |
221 -| `acceptCharset=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<empty string>` |
222 -| `acceptCharset=(function)`| (initial, warning, ssr mismatch)| `<empty string>` |
221 +| `acceptCharset=(symbol)`| (initial, warning)| `<empty string>` |
222 +| `acceptCharset=(function)`| (initial, warning)| `<empty string>` |
223 | `acceptCharset=(null)`| (initial)| `<empty string>` |
224 | `acceptCharset=(undefined)`| (initial)| `<empty string>` |
225
@@ -368,8 +368,8 @@
368 | `alignmentBaseline=(string 'false')`| (changed)| `"false"` |
369 | `alignmentBaseline=(string 'on')`| (changed)| `"on"` |
370 | `alignmentBaseline=(string 'off')`| (changed)| `"off"` |
371 -| `alignmentBaseline=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
372 -| `alignmentBaseline=(function)`| (initial, warning, ssr mismatch)| `<null>` |
371 +| `alignmentBaseline=(symbol)`| (initial, warning)| `<null>` |
372 +| `alignmentBaseline=(function)`| (initial, warning)| `<null>` |
373 | `alignmentBaseline=(null)`| (initial)| `<null>` |
374 | `alignmentBaseline=(undefined)`| (initial)| `<null>` |
375
@@ -393,8 +393,8 @@
393 | `allowFullScreen=(string 'false')`| (changed)| `<boolean: true>` |
394 | `allowFullScreen=(string 'on')`| (changed)| `<boolean: true>` |
395 | `allowFullScreen=(string 'off')`| (changed)| `<boolean: true>` |
396 -| `allowFullScreen=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
397 -| `allowFullScreen=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
396 +| `allowFullScreen=(symbol)`| (initial, warning)| `<boolean: false>` |
397 +| `allowFullScreen=(function)`| (initial, warning)| `<boolean: false>` |
398 | `allowFullScreen=(null)`| (initial)| `<boolean: false>` |
399 | `allowFullScreen=(undefined)`| (initial)| `<boolean: false>` |
400
@@ -593,8 +593,8 @@
593 | `arabicForm=(string 'false')`| (changed)| `"false"` |
594 | `arabicForm=(string 'on')`| (changed)| `"on"` |
595 | `arabicForm=(string 'off')`| (changed)| `"off"` |
596 -| `arabicForm=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
597 -| `arabicForm=(function)`| (initial, warning, ssr mismatch)| `<null>` |
596 +| `arabicForm=(symbol)`| (initial, warning)| `<null>` |
597 +| `arabicForm=(function)`| (initial, warning)| `<null>` |
598 | `arabicForm=(null)`| (initial)| `<null>` |
599 | `arabicForm=(undefined)`| (initial)| `<null>` |
600
@@ -743,8 +743,8 @@
743 | `async=(string 'false')`| (changed)| `<boolean: true>` |
744 | `async=(string 'on')`| (changed)| `<boolean: true>` |
745 | `async=(string 'off')`| (changed)| `<boolean: true>` |
746 -| `async=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
747 -| `async=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
746 +| `async=(symbol)`| (initial, warning)| `<boolean: false>` |
747 +| `async=(function)`| (initial, warning)| `<boolean: false>` |
748 | `async=(null)`| (initial)| `<boolean: false>` |
749 | `async=(undefined)`| (initial)| `<boolean: false>` |
750
@@ -893,8 +893,8 @@
893 | `autoPlay=(string 'false')`| (changed)| `<boolean: true>` |
894 | `autoPlay=(string 'on')`| (changed)| `<boolean: true>` |
895 | `autoPlay=(string 'off')`| (changed)| `<boolean: true>` |
896 -| `autoPlay=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
897 -| `autoPlay=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
896 +| `autoPlay=(symbol)`| (initial, warning)| `<boolean: false>` |
897 +| `autoPlay=(function)`| (initial, warning)| `<boolean: false>` |
898 | `autoPlay=(null)`| (initial)| `<boolean: false>` |
899 | `autoPlay=(undefined)`| (initial)| `<boolean: false>` |
900
@@ -918,8 +918,8 @@
918 | `autoReverse=(string 'false')`| (initial, ssr mismatch)| `<null>` |
919 | `autoReverse=(string 'on')`| (initial, ssr mismatch)| `<null>` |
920 | `autoReverse=(string 'off')`| (initial, ssr mismatch)| `<null>` |
921 -| `autoReverse=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
922 -| `autoReverse=(function)`| (initial, warning, ssr mismatch)| `<null>` |
921 +| `autoReverse=(symbol)`| (initial, warning)| `<null>` |
922 +| `autoReverse=(function)`| (initial, warning)| `<null>` |
923 | `autoReverse=(null)`| (initial)| `<null>` |
924 | `autoReverse=(undefined)`| (initial)| `<null>` |
925
@@ -1043,8 +1043,8 @@
1043 | `baselineShift=(string 'false')`| (changed)| `"false"` |
1044 | `baselineShift=(string 'on')`| (changed)| `"on"` |
1045 | `baselineShift=(string 'off')`| (changed)| `"off"` |
1046 -| `baselineShift=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
1047 -| `baselineShift=(function)`| (initial, warning, ssr mismatch)| `<null>` |
1046 +| `baselineShift=(symbol)`| (initial, warning)| `<null>` |
1047 +| `baselineShift=(function)`| (initial, warning)| `<null>` |
1048 | `baselineShift=(null)`| (initial)| `<null>` |
1049 | `baselineShift=(undefined)`| (initial)| `<null>` |
1050
@@ -1243,8 +1243,8 @@
1243 | `capHeight=(string 'false')`| (changed)| `"false"` |
1244 | `capHeight=(string 'on')`| (changed)| `"on"` |
1245 | `capHeight=(string 'off')`| (changed)| `"off"` |
1246 -| `capHeight=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
1247 -| `capHeight=(function)`| (initial, warning, ssr mismatch)| `<null>` |
1246 +| `capHeight=(symbol)`| (initial, warning)| `<null>` |
1247 +| `capHeight=(function)`| (initial, warning)| `<null>` |
1248 | `capHeight=(null)`| (initial)| `<null>` |
1249 | `capHeight=(undefined)`| (initial)| `<null>` |
1250
@@ -1268,8 +1268,8 @@
1268 | `capture=(string 'false')`| (changed)| `"false"` |
1269 | `capture=(string 'on')`| (changed)| `"on"` |
1270 | `capture=(string 'off')`| (changed)| `"off"` |
1271 -| `capture=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
1272 -| `capture=(function)`| (initial, warning, ssr mismatch)| `<null>` |
1271 +| `capture=(symbol)`| (initial, warning)| `<null>` |
1272 +| `capture=(function)`| (initial, warning)| `<null>` |
1273 | `capture=(null)`| (initial)| `<null>` |
1274 | `capture=(undefined)`| (initial)| `<null>` |
1275
@@ -1393,8 +1393,8 @@
1393 | `checked=(string 'false')`| (changed)| `<boolean: true>` |
1394 | `checked=(string 'on')`| (changed)| `<boolean: true>` |
1395 | `checked=(string 'off')`| (changed)| `<boolean: true>` |
1396 -| `checked=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
1397 -| `checked=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
1396 +| `checked=(symbol)`| (initial, warning)| `<boolean: false>` |
1397 +| `checked=(function)`| (initial, warning)| `<boolean: false>` |
1398 | `checked=(null)`| (initial)| `<boolean: false>` |
1399 | `checked=(undefined)`| (initial)| `<boolean: false>` |
1400
@@ -1568,8 +1568,8 @@
1568 | `className=(string 'false')`| (changed)| `"false"` |
1569 | `className=(string 'on')`| (changed)| `"on"` |
1570 | `className=(string 'off')`| (changed)| `"off"` |
1571 -| `className=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<empty string>` |
1572 -| `className=(function)`| (initial, warning, ssr mismatch)| `<empty string>` |
1571 +| `className=(symbol)`| (initial, warning)| `<empty string>` |
1572 +| `className=(function)`| (initial, warning)| `<empty string>` |
1573 | `className=(null)`| (initial)| `<empty string>` |
1574 | `className=(undefined)`| (initial)| `<empty string>` |
1575
@@ -1643,8 +1643,8 @@
1643 | `clipPath=(string 'false')`| (changed)| `"false"` |
1644 | `clipPath=(string 'on')`| (changed)| `"on"` |
1645 | `clipPath=(string 'off')`| (changed)| `"off"` |
1646 -| `clipPath=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
1647 -| `clipPath=(function)`| (initial, warning, ssr mismatch)| `<null>` |
1646 +| `clipPath=(symbol)`| (initial, warning)| `<null>` |
1647 +| `clipPath=(function)`| (initial, warning)| `<null>` |
1648 | `clipPath=(null)`| (initial)| `<null>` |
1649 | `clipPath=(undefined)`| (initial)| `<null>` |
1650
@@ -1718,8 +1718,8 @@
1718 | `clipRule=(string 'false')`| (changed)| `"false"` |
1719 | `clipRule=(string 'on')`| (changed)| `"on"` |
1720 | `clipRule=(string 'off')`| (changed)| `"off"` |
1721 -| `clipRule=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
1722 -| `clipRule=(function)`| (initial, warning, ssr mismatch)| `<null>` |
1721 +| `clipRule=(symbol)`| (initial, warning)| `<null>` |
1722 +| `clipRule=(function)`| (initial, warning)| `<null>` |
1723 | `clipRule=(null)`| (initial)| `<null>` |
1724 | `clipRule=(undefined)`| (initial)| `<null>` |
1725
@@ -1793,8 +1793,8 @@
1793 | `colorInterpolation=(string 'false')`| (changed)| `"false"` |
1794 | `colorInterpolation=(string 'on')`| (changed)| `"on"` |
1795 | `colorInterpolation=(string 'off')`| (changed)| `"off"` |
1796 -| `colorInterpolation=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
1797 -| `colorInterpolation=(function)`| (initial, warning, ssr mismatch)| `<null>` |
1796 +| `colorInterpolation=(symbol)`| (initial, warning)| `<null>` |
1797 +| `colorInterpolation=(function)`| (initial, warning)| `<null>` |
1798 | `colorInterpolation=(null)`| (initial)| `<null>` |
1799 | `colorInterpolation=(undefined)`| (initial)| `<null>` |
1800
@@ -1843,8 +1843,8 @@
1843 | `colorInterpolationFilters=(string 'false')`| (changed)| `"false"` |
1844 | `colorInterpolationFilters=(string 'on')`| (changed)| `"on"` |
1845 | `colorInterpolationFilters=(string 'off')`| (changed)| `"off"` |
1846 -| `colorInterpolationFilters=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
1847 -| `colorInterpolationFilters=(function)`| (initial, warning, ssr mismatch)| `<null>` |
1846 +| `colorInterpolationFilters=(symbol)`| (initial, warning)| `<null>` |
1847 +| `colorInterpolationFilters=(function)`| (initial, warning)| `<null>` |
1848 | `colorInterpolationFilters=(null)`| (initial)| `<null>` |
1849 | `colorInterpolationFilters=(undefined)`| (initial)| `<null>` |
1850
@@ -1893,8 +1893,8 @@
1893 | `colorProfile=(string 'false')`| (changed)| `"false"` |
1894 | `colorProfile=(string 'on')`| (changed)| `"on"` |
1895 | `colorProfile=(string 'off')`| (changed)| `"off"` |
1896 -| `colorProfile=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
1897 -| `colorProfile=(function)`| (initial, warning, ssr mismatch)| `<null>` |
1896 +| `colorProfile=(symbol)`| (initial, warning)| `<null>` |
1897 +| `colorProfile=(function)`| (initial, warning)| `<null>` |
1898 | `colorProfile=(null)`| (initial)| `<null>` |
1899 | `colorProfile=(undefined)`| (initial)| `<null>` |
1900
@@ -1943,8 +1943,8 @@
1943 | `colorRendering=(string 'false')`| (changed)| `"false"` |
1944 | `colorRendering=(string 'on')`| (changed)| `"on"` |
1945 | `colorRendering=(string 'off')`| (changed)| `"off"` |
1946 -| `colorRendering=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
1947 -| `colorRendering=(function)`| (initial, warning, ssr mismatch)| `<null>` |
1946 +| `colorRendering=(symbol)`| (initial, warning)| `<null>` |
1947 +| `colorRendering=(function)`| (initial, warning)| `<null>` |
1948 | `colorRendering=(null)`| (initial)| `<null>` |
1949 | `colorRendering=(undefined)`| (initial)| `<null>` |
1950
@@ -1968,7 +1968,7 @@
1968 | `cols=(string 'false')`| (initial)| `<number: 20>` |
1969 | `cols=(string 'on')`| (initial)| `<number: 20>` |
1970 | `cols=(string 'off')`| (initial)| `<number: 20>` |
1971 -| `cols=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<number: 20>` |
1971 +| `cols=(symbol)`| (initial, warning)| `<number: 20>` |
1972 | `cols=(function)`| (initial, warning)| `<number: 20>` |
1973 | `cols=(null)`| (initial)| `<number: 20>` |
1974 | `cols=(undefined)`| (initial)| `<number: 20>` |
@@ -2043,7 +2043,7 @@
2043 | `contentEditable=(string 'false')`| (changed)| `"false"` |
2044 | `contentEditable=(string 'on')`| (initial)| `"inherit"` |
2045 | `contentEditable=(string 'off')`| (initial)| `"inherit"` |
2046 -| `contentEditable=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `"inherit"` |
2046 +| `contentEditable=(symbol)`| (initial, warning)| `"inherit"` |
2047 | `contentEditable=(function)`| (initial, warning)| `"inherit"` |
2048 | `contentEditable=(null)`| (initial)| `"inherit"` |
2049 | `contentEditable=(undefined)`| (initial)| `"inherit"` |
@@ -2143,8 +2143,8 @@
2143 | `controls=(string 'false')`| (changed)| `<boolean: true>` |
2144 | `controls=(string 'on')`| (changed)| `<boolean: true>` |
2145 | `controls=(string 'off')`| (changed)| `<boolean: true>` |
2146 -| `controls=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
2147 -| `controls=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
2146 +| `controls=(symbol)`| (initial, warning)| `<boolean: false>` |
2147 +| `controls=(function)`| (initial, warning)| `<boolean: false>` |
2148 | `controls=(null)`| (initial)| `<boolean: false>` |
2149 | `controls=(undefined)`| (initial)| `<boolean: false>` |
2150
@@ -2518,8 +2518,8 @@
2518 | `default=(string 'false')`| (changed)| `<boolean: true>` |
2519 | `default=(string 'on')`| (changed)| `<boolean: true>` |
2520 | `default=(string 'off')`| (changed)| `<boolean: true>` |
2521 -| `default=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
2522 -| `default=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
2521 +| `default=(symbol)`| (initial, warning)| `<boolean: false>` |
2522 +| `default=(function)`| (initial, warning)| `<boolean: false>` |
2523 | `default=(null)`| (initial)| `<boolean: false>` |
2524 | `default=(undefined)`| (initial)| `<boolean: false>` |
2525
@@ -2568,8 +2568,8 @@
2568 | `defaultChecked=(string 'false')`| (initial, ssr mismatch)| `<boolean: false>` |
2569 | `defaultChecked=(string 'on')`| (initial, ssr mismatch)| `<boolean: false>` |
2570 | `defaultChecked=(string 'off')`| (initial, ssr mismatch)| `<boolean: false>` |
2571 -| `defaultChecked=(symbol)`| (initial, ssr mismatch)| `<boolean: false>` |
2572 -| `defaultChecked=(function)`| (initial, ssr mismatch)| `<boolean: false>` |
2571 +| `defaultChecked=(symbol)`| (initial)| `<boolean: false>` |
2572 +| `defaultChecked=(function)`| (initial)| `<boolean: false>` |
2573 | `defaultChecked=(null)`| (initial)| `<boolean: false>` |
2574 | `defaultChecked=(undefined)`| (initial)| `<boolean: false>` |
2575
@@ -2593,8 +2593,8 @@
2593 | `defaultValue=(string 'false')`| (changed)| `"false"` |
2594 | `defaultValue=(string 'on')`| (changed)| `"on"` |
2595 | `defaultValue=(string 'off')`| (changed)| `"off"` |
2596 -| `defaultValue=(symbol)`| (initial, ssr error, ssr mismatch)| `<empty string>` |
2597 -| `defaultValue=(function)`| (initial, ssr mismatch)| `<empty string>` |
2596 +| `defaultValue=(symbol)`| (initial, ssr warning)| `<empty string>` |
2597 +| `defaultValue=(function)`| (initial, ssr warning)| `<empty string>` |
2598 | `defaultValue=(null)`| (initial, ssr warning)| `<empty string>` |
2599 | `defaultValue=(undefined)`| (initial)| `<empty string>` |
2600
@@ -2643,8 +2643,8 @@
2643 | `defer=(string 'false')`| (changed)| `<boolean: true>` |
2644 | `defer=(string 'on')`| (changed)| `<boolean: true>` |
2645 | `defer=(string 'off')`| (changed)| `<boolean: true>` |
2646 -| `defer=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
2647 -| `defer=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
2646 +| `defer=(symbol)`| (initial, warning)| `<boolean: false>` |
2647 +| `defer=(function)`| (initial, warning)| `<boolean: false>` |
2648 | `defer=(null)`| (initial)| `<boolean: false>` |
2649 | `defer=(undefined)`| (initial)| `<boolean: false>` |
2650
@@ -2768,8 +2768,8 @@
2768 | `disabled=(string 'false')`| (changed)| `<boolean: true>` |
2769 | `disabled=(string 'on')`| (changed)| `<boolean: true>` |
2770 | `disabled=(string 'off')`| (changed)| `<boolean: true>` |
2771 -| `disabled=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
2772 -| `disabled=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
2771 +| `disabled=(symbol)`| (initial, warning)| `<boolean: false>` |
2772 +| `disabled=(function)`| (initial, warning)| `<boolean: false>` |
2773 | `disabled=(null)`| (initial)| `<boolean: false>` |
2774 | `disabled=(undefined)`| (initial)| `<boolean: false>` |
2775
@@ -2868,8 +2868,8 @@
2868 | `dominantBaseline=(string 'false')`| (changed)| `"false"` |
2869 | `dominantBaseline=(string 'on')`| (changed)| `"on"` |
2870 | `dominantBaseline=(string 'off')`| (changed)| `"off"` |
2871 -| `dominantBaseline=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
2872 -| `dominantBaseline=(function)`| (initial, warning, ssr mismatch)| `<null>` |
2871 +| `dominantBaseline=(symbol)`| (initial, warning)| `<null>` |
2872 +| `dominantBaseline=(function)`| (initial, warning)| `<null>` |
2873 | `dominantBaseline=(null)`| (initial)| `<null>` |
2874 | `dominantBaseline=(undefined)`| (initial)| `<null>` |
2875
@@ -2893,8 +2893,8 @@
2893 | `download=(string 'false')`| (changed)| `"false"` |
2894 | `download=(string 'on')`| (changed)| `"on"` |
2895 | `download=(string 'off')`| (changed)| `"off"` |
2896 -| `download=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<empty string>` |
2897 -| `download=(function)`| (initial, warning, ssr mismatch)| `<empty string>` |
2896 +| `download=(symbol)`| (initial, warning)| `<empty string>` |
2897 +| `download=(function)`| (initial, warning)| `<empty string>` |
2898 | `download=(null)`| (initial)| `<empty string>` |
2899 | `download=(undefined)`| (initial)| `<empty string>` |
2900
@@ -2943,7 +2943,7 @@
2943 | `draggable=(string 'false')`| (initial)| `<boolean: false>` |
2944 | `draggable=(string 'on')`| (initial)| `<boolean: false>` |
2945 | `draggable=(string 'off')`| (initial)| `<boolean: false>` |
2946 -| `draggable=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<boolean: false>` |
2946 +| `draggable=(symbol)`| (initial, warning)| `<boolean: false>` |
2947 | `draggable=(function)`| (initial, warning)| `<boolean: false>` |
2948 | `draggable=(null)`| (initial)| `<boolean: false>` |
2949 | `draggable=(undefined)`| (initial)| `<boolean: false>` |
@@ -3168,8 +3168,8 @@
3168 | `enableBackground=(string 'false')`| (changed)| `"false"` |
3169 | `enableBackground=(string 'on')`| (changed)| `"on"` |
3170 | `enableBackground=(string 'off')`| (changed)| `"off"` |
3171 -| `enableBackground=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3172 -| `enableBackground=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3171 +| `enableBackground=(symbol)`| (initial, warning)| `<null>` |
3172 +| `enableBackground=(function)`| (initial, warning)| `<null>` |
3173 | `enableBackground=(null)`| (initial)| `<null>` |
3174 | `enableBackground=(undefined)`| (initial)| `<null>` |
3175
@@ -3268,7 +3268,7 @@
3268 | `externalResourcesRequired=(string 'false')`| (changed, ssr mismatch)| `"false"` |
3269 | `externalResourcesRequired=(string 'on')`| (changed, ssr mismatch)| `"on"` |
3270 | `externalResourcesRequired=(string 'off')`| (changed, ssr mismatch)| `"off"` |
3271 -| `externalResourcesRequired=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3271 +| `externalResourcesRequired=(symbol)`| (initial, warning)| `<null>` |
3272 | `externalResourcesRequired=(function)`| (initial, warning)| `<null>` |
3273 | `externalResourcesRequired=(null)`| (initial)| `<null>` |
3274 | `externalResourcesRequired=(undefined)`| (initial)| `<null>` |
@@ -3318,8 +3318,8 @@
3318 | `fillOpacity=(string 'false')`| (changed)| `"false"` |
3319 | `fillOpacity=(string 'on')`| (changed)| `"on"` |
3320 | `fillOpacity=(string 'off')`| (changed)| `"off"` |
3321 -| `fillOpacity=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3322 -| `fillOpacity=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3321 +| `fillOpacity=(symbol)`| (initial, warning)| `<null>` |
3322 +| `fillOpacity=(function)`| (initial, warning)| `<null>` |
3323 | `fillOpacity=(null)`| (initial)| `<null>` |
3324 | `fillOpacity=(undefined)`| (initial)| `<null>` |
3325
@@ -3368,8 +3368,8 @@
3368 | `fillRule=(string 'false')`| (changed)| `"false"` |
3369 | `fillRule=(string 'on')`| (changed)| `"on"` |
3370 | `fillRule=(string 'off')`| (changed)| `"off"` |
3371 -| `fillRule=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3372 -| `fillRule=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3371 +| `fillRule=(symbol)`| (initial, warning)| `<null>` |
3372 +| `fillRule=(function)`| (initial, warning)| `<null>` |
3373 | `fillRule=(null)`| (initial)| `<null>` |
3374 | `fillRule=(undefined)`| (initial)| `<null>` |
3375
@@ -3518,8 +3518,8 @@
3518 | `floodColor=(string 'false')`| (changed)| `"false"` |
3519 | `floodColor=(string 'on')`| (changed)| `"on"` |
3520 | `floodColor=(string 'off')`| (changed)| `"off"` |
3521 -| `floodColor=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3522 -| `floodColor=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3521 +| `floodColor=(symbol)`| (initial, warning)| `<null>` |
3522 +| `floodColor=(function)`| (initial, warning)| `<null>` |
3523 | `floodColor=(null)`| (initial)| `<null>` |
3524 | `floodColor=(undefined)`| (initial)| `<null>` |
3525
@@ -3568,8 +3568,8 @@
3568 | `floodOpacity=(string 'false')`| (changed)| `"false"` |
3569 | `floodOpacity=(string 'on')`| (changed)| `"on"` |
3570 | `floodOpacity=(string 'off')`| (changed)| `"off"` |
3571 -| `floodOpacity=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3572 -| `floodOpacity=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3571 +| `floodOpacity=(symbol)`| (initial, warning)| `<null>` |
3572 +| `floodOpacity=(function)`| (initial, warning)| `<null>` |
3573 | `floodOpacity=(null)`| (initial)| `<null>` |
3574 | `floodOpacity=(undefined)`| (initial)| `<null>` |
3575
@@ -3793,8 +3793,8 @@
3793 | `fontFamily=(string 'false')`| (changed)| `"false"` |
3794 | `fontFamily=(string 'on')`| (changed)| `"on"` |
3795 | `fontFamily=(string 'off')`| (changed)| `"off"` |
3796 -| `fontFamily=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3797 -| `fontFamily=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3796 +| `fontFamily=(symbol)`| (initial, warning)| `<null>` |
3797 +| `fontFamily=(function)`| (initial, warning)| `<null>` |
3798 | `fontFamily=(null)`| (initial)| `<null>` |
3799 | `fontFamily=(undefined)`| (initial)| `<null>` |
3800
@@ -3818,8 +3818,8 @@
3818 | `fontSize=(string 'false')`| (changed)| `"false"` |
3819 | `fontSize=(string 'on')`| (changed)| `"on"` |
3820 | `fontSize=(string 'off')`| (changed)| `"off"` |
3821 -| `fontSize=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3822 -| `fontSize=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3821 +| `fontSize=(symbol)`| (initial, warning)| `<null>` |
3822 +| `fontSize=(function)`| (initial, warning)| `<null>` |
3823 | `fontSize=(null)`| (initial)| `<null>` |
3824 | `fontSize=(undefined)`| (initial)| `<null>` |
3825
@@ -3843,8 +3843,8 @@
3843 | `fontSizeAdjust=(string 'false')`| (changed)| `"false"` |
3844 | `fontSizeAdjust=(string 'on')`| (changed)| `"on"` |
3845 | `fontSizeAdjust=(string 'off')`| (changed)| `"off"` |
3846 -| `fontSizeAdjust=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3847 -| `fontSizeAdjust=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3846 +| `fontSizeAdjust=(symbol)`| (initial, warning)| `<null>` |
3847 +| `fontSizeAdjust=(function)`| (initial, warning)| `<null>` |
3848 | `fontSizeAdjust=(null)`| (initial)| `<null>` |
3849 | `fontSizeAdjust=(undefined)`| (initial)| `<null>` |
3850
@@ -3868,8 +3868,8 @@
3868 | `fontStretch=(string 'false')`| (changed)| `"false"` |
3869 | `fontStretch=(string 'on')`| (changed)| `"on"` |
3870 | `fontStretch=(string 'off')`| (changed)| `"off"` |
3871 -| `fontStretch=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3872 -| `fontStretch=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3871 +| `fontStretch=(symbol)`| (initial, warning)| `<null>` |
3872 +| `fontStretch=(function)`| (initial, warning)| `<null>` |
3873 | `fontStretch=(null)`| (initial)| `<null>` |
3874 | `fontStretch=(undefined)`| (initial)| `<null>` |
3875
@@ -3893,8 +3893,8 @@
3893 | `fontStyle=(string 'false')`| (changed)| `"false"` |
3894 | `fontStyle=(string 'on')`| (changed)| `"on"` |
3895 | `fontStyle=(string 'off')`| (changed)| `"off"` |
3896 -| `fontStyle=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3897 -| `fontStyle=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3896 +| `fontStyle=(symbol)`| (initial, warning)| `<null>` |
3897 +| `fontStyle=(function)`| (initial, warning)| `<null>` |
3898 | `fontStyle=(null)`| (initial)| `<null>` |
3899 | `fontStyle=(undefined)`| (initial)| `<null>` |
3900
@@ -3918,8 +3918,8 @@
3918 | `fontVariant=(string 'false')`| (changed)| `"false"` |
3919 | `fontVariant=(string 'on')`| (changed)| `"on"` |
3920 | `fontVariant=(string 'off')`| (changed)| `"off"` |
3921 -| `fontVariant=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3922 -| `fontVariant=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3921 +| `fontVariant=(symbol)`| (initial, warning)| `<null>` |
3922 +| `fontVariant=(function)`| (initial, warning)| `<null>` |
3923 | `fontVariant=(null)`| (initial)| `<null>` |
3924 | `fontVariant=(undefined)`| (initial)| `<null>` |
3925
@@ -3943,8 +3943,8 @@
3943 | `fontWeight=(string 'false')`| (changed)| `"false"` |
3944 | `fontWeight=(string 'on')`| (changed)| `"on"` |
3945 | `fontWeight=(string 'off')`| (changed)| `"off"` |
3946 -| `fontWeight=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
3947 -| `fontWeight=(function)`| (initial, warning, ssr mismatch)| `<null>` |
3946 +| `fontWeight=(symbol)`| (initial, warning)| `<null>` |
3947 +| `fontWeight=(function)`| (initial, warning)| `<null>` |
3948 | `fontWeight=(null)`| (initial)| `<null>` |
3949 | `fontWeight=(undefined)`| (initial)| `<null>` |
3950
@@ -4143,8 +4143,8 @@
4143 | `formNoValidate=(string 'false')`| (changed)| `<boolean: true>` |
4144 | `formNoValidate=(string 'on')`| (changed)| `<boolean: true>` |
4145 | `formNoValidate=(string 'off')`| (changed)| `<boolean: true>` |
4146 -| `formNoValidate=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
4147 -| `formNoValidate=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
4146 +| `formNoValidate=(symbol)`| (initial, warning)| `<boolean: false>` |
4147 +| `formNoValidate=(function)`| (initial, warning)| `<boolean: false>` |
4148 | `formNoValidate=(null)`| (initial)| `<boolean: false>` |
4149 | `formNoValidate=(undefined)`| (initial)| `<boolean: false>` |
4150
@@ -4518,8 +4518,8 @@
4518 | `glyphName=(string 'false')`| (changed)| `"false"` |
4519 | `glyphName=(string 'on')`| (changed)| `"on"` |
4520 | `glyphName=(string 'off')`| (changed)| `"off"` |
4521 -| `glyphName=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
4522 -| `glyphName=(function)`| (initial, warning, ssr mismatch)| `<null>` |
4521 +| `glyphName=(symbol)`| (initial, warning)| `<null>` |
4522 +| `glyphName=(function)`| (initial, warning)| `<null>` |
4523 | `glyphName=(null)`| (initial)| `<null>` |
4524 | `glyphName=(undefined)`| (initial)| `<null>` |
4525
@@ -4543,8 +4543,8 @@
4543 | `glyphOrientationHorizontal=(string 'false')`| (changed)| `"false"` |
4544 | `glyphOrientationHorizontal=(string 'on')`| (changed)| `"on"` |
4545 | `glyphOrientationHorizontal=(string 'off')`| (changed)| `"off"` |
4546 -| `glyphOrientationHorizontal=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
4547 -| `glyphOrientationHorizontal=(function)`| (initial, warning, ssr mismatch)| `<null>` |
4546 +| `glyphOrientationHorizontal=(symbol)`| (initial, warning)| `<null>` |
4547 +| `glyphOrientationHorizontal=(function)`| (initial, warning)| `<null>` |
4548 | `glyphOrientationHorizontal=(null)`| (initial)| `<null>` |
4549 | `glyphOrientationHorizontal=(undefined)`| (initial)| `<null>` |
4550
@@ -4568,8 +4568,8 @@
4568 | `glyphOrientationVertical=(string 'false')`| (changed)| `"false"` |
4569 | `glyphOrientationVertical=(string 'on')`| (changed)| `"on"` |
4570 | `glyphOrientationVertical=(string 'off')`| (changed)| `"off"` |
4571 -| `glyphOrientationVertical=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
4572 -| `glyphOrientationVertical=(function)`| (initial, warning, ssr mismatch)| `<null>` |
4571 +| `glyphOrientationVertical=(symbol)`| (initial, warning)| `<null>` |
4572 +| `glyphOrientationVertical=(function)`| (initial, warning)| `<null>` |
4573 | `glyphOrientationVertical=(null)`| (initial)| `<null>` |
4574 | `glyphOrientationVertical=(undefined)`| (initial)| `<null>` |
4575
@@ -4768,8 +4768,8 @@
4768 | `hidden=(string 'false')`| (changed)| `<boolean: true>` |
4769 | `hidden=(string 'on')`| (changed)| `<boolean: true>` |
4770 | `hidden=(string 'off')`| (changed)| `<boolean: true>` |
4771 -| `hidden=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
4772 -| `hidden=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
4771 +| `hidden=(symbol)`| (initial, warning)| `<boolean: false>` |
4772 +| `hidden=(function)`| (initial, warning)| `<boolean: false>` |
4773 | `hidden=(null)`| (initial)| `<boolean: false>` |
4774 | `hidden=(undefined)`| (initial)| `<boolean: false>` |
4775
@@ -4868,8 +4868,8 @@
4868 | `horizAdvX=(string 'false')`| (changed)| `"false"` |
4869 | `horizAdvX=(string 'on')`| (changed)| `"on"` |
4870 | `horizAdvX=(string 'off')`| (changed)| `"off"` |
4871 -| `horizAdvX=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
4872 -| `horizAdvX=(function)`| (initial, warning, ssr mismatch)| `<null>` |
4871 +| `horizAdvX=(symbol)`| (initial, warning)| `<null>` |
4872 +| `horizAdvX=(function)`| (initial, warning)| `<null>` |
4873 | `horizAdvX=(null)`| (initial)| `<null>` |
4874 | `horizAdvX=(undefined)`| (initial)| `<null>` |
4875
@@ -4893,8 +4893,8 @@
4893 | `horizOriginX=(string 'false')`| (changed)| `"false"` |
4894 | `horizOriginX=(string 'on')`| (changed)| `"on"` |
4895 | `horizOriginX=(string 'off')`| (changed)| `"off"` |
4896 -| `horizOriginX=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
4897 -| `horizOriginX=(function)`| (initial, warning, ssr mismatch)| `<null>` |
4896 +| `horizOriginX=(symbol)`| (initial, warning)| `<null>` |
4897 +| `horizOriginX=(function)`| (initial, warning)| `<null>` |
4898 | `horizOriginX=(null)`| (initial)| `<null>` |
4899 | `horizOriginX=(undefined)`| (initial)| `<null>` |
4900
@@ -4968,8 +4968,8 @@
4968 | `htmlFor=(string 'false')`| (changed)| `"false"` |
4969 | `htmlFor=(string 'on')`| (changed)| `"on"` |
4970 | `htmlFor=(string 'off')`| (changed)| `"off"` |
4971 -| `htmlFor=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<empty string>` |
4972 -| `htmlFor=(function)`| (initial, warning, ssr mismatch)| `<empty string>` |
4971 +| `htmlFor=(symbol)`| (initial, warning)| `<empty string>` |
4972 +| `htmlFor=(function)`| (initial, warning)| `<empty string>` |
4973 | `htmlFor=(null)`| (initial)| `<empty string>` |
4974 | `htmlFor=(undefined)`| (initial)| `<empty string>` |
4975
@@ -5018,8 +5018,8 @@
5018 | `httpEquiv=(string 'false')`| (changed)| `"false"` |
5019 | `httpEquiv=(string 'on')`| (changed)| `"on"` |
5020 | `httpEquiv=(string 'off')`| (changed)| `"off"` |
5021 -| `httpEquiv=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<empty string>` |
5022 -| `httpEquiv=(function)`| (initial, warning, ssr mismatch)| `<empty string>` |
5021 +| `httpEquiv=(symbol)`| (initial, warning)| `<empty string>` |
5022 +| `httpEquiv=(function)`| (initial, warning)| `<empty string>` |
5023 | `httpEquiv=(null)`| (initial)| `<empty string>` |
5024 | `httpEquiv=(undefined)`| (initial)| `<empty string>` |
5025
@@ -5168,8 +5168,8 @@
5168 | `imageRendering=(string 'false')`| (changed)| `"false"` |
5169 | `imageRendering=(string 'on')`| (changed)| `"on"` |
5170 | `imageRendering=(string 'off')`| (changed)| `"off"` |
5171 -| `imageRendering=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
5172 -| `imageRendering=(function)`| (initial, warning, ssr mismatch)| `<null>` |
5171 +| `imageRendering=(symbol)`| (initial, warning)| `<null>` |
5172 +| `imageRendering=(function)`| (initial, warning)| `<null>` |
5173 | `imageRendering=(null)`| (initial)| `<null>` |
5174 | `imageRendering=(undefined)`| (initial)| `<null>` |
5175
@@ -5493,8 +5493,8 @@
5493 | `itemScope=(string 'false')`| (changed)| `<empty string>` |
5494 | `itemScope=(string 'on')`| (changed)| `<empty string>` |
5495 | `itemScope=(string 'off')`| (changed)| `<empty string>` |
5496 -| `itemScope=(symbol)`| (initial, warning, ssr mismatch)| `<null>` |
5497 -| `itemScope=(function)`| (initial, warning, ssr mismatch)| `<null>` |
5496 +| `itemScope=(symbol)`| (initial, warning)| `<null>` |
5497 +| `itemScope=(function)`| (initial, warning)| `<null>` |
5498 | `itemScope=(null)`| (initial)| `<null>` |
5499 | `itemScope=(undefined)`| (initial)| `<null>` |
5500
@@ -6093,8 +6093,8 @@
6093 | `letterSpacing=(string 'false')`| (changed)| `"false"` |
6094 | `letterSpacing=(string 'on')`| (changed)| `"on"` |
6095 | `letterSpacing=(string 'off')`| (changed)| `"off"` |
6096 -| `letterSpacing=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
6097 -| `letterSpacing=(function)`| (initial, warning, ssr mismatch)| `<null>` |
6096 +| `letterSpacing=(symbol)`| (initial, warning)| `<null>` |
6097 +| `letterSpacing=(function)`| (initial, warning)| `<null>` |
6098 | `letterSpacing=(null)`| (initial)| `<null>` |
6099 | `letterSpacing=(undefined)`| (initial)| `<null>` |
6100
@@ -6143,8 +6143,8 @@
6143 | `lightingColor=(string 'false')`| (changed)| `"false"` |
6144 | `lightingColor=(string 'on')`| (changed)| `"on"` |
6145 | `lightingColor=(string 'off')`| (changed)| `"off"` |
6146 -| `lightingColor=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
6147 -| `lightingColor=(function)`| (initial, warning, ssr mismatch)| `<null>` |
6146 +| `lightingColor=(symbol)`| (initial, warning)| `<null>` |
6147 +| `lightingColor=(function)`| (initial, warning)| `<null>` |
6148 | `lightingColor=(null)`| (initial)| `<null>` |
6149 | `lightingColor=(undefined)`| (initial)| `<null>` |
6150
@@ -6243,8 +6243,8 @@
6243 | `loop=(string 'false')`| (changed)| `<boolean: true>` |
6244 | `loop=(string 'on')`| (changed)| `<boolean: true>` |
6245 | `loop=(string 'off')`| (changed)| `<boolean: true>` |
6246 -| `loop=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
6247 -| `loop=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
6246 +| `loop=(symbol)`| (initial, warning)| `<boolean: false>` |
6247 +| `loop=(function)`| (initial, warning)| `<boolean: false>` |
6248 | `loop=(null)`| (initial)| `<boolean: false>` |
6249 | `loop=(undefined)`| (initial)| `<boolean: false>` |
6250
@@ -6443,8 +6443,8 @@
6443 | `markerEnd=(string 'false')`| (changed)| `"false"` |
6444 | `markerEnd=(string 'on')`| (changed)| `"on"` |
6445 | `markerEnd=(string 'off')`| (changed)| `"off"` |
6446 -| `markerEnd=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
6447 -| `markerEnd=(function)`| (initial, warning, ssr mismatch)| `<null>` |
6446 +| `markerEnd=(symbol)`| (initial, warning)| `<null>` |
6447 +| `markerEnd=(function)`| (initial, warning)| `<null>` |
6448 | `markerEnd=(null)`| (initial)| `<null>` |
6449 | `markerEnd=(undefined)`| (initial)| `<null>` |
6450
@@ -6493,8 +6493,8 @@
6493 | `markerMid=(string 'false')`| (changed)| `"false"` |
6494 | `markerMid=(string 'on')`| (changed)| `"on"` |
6495 | `markerMid=(string 'off')`| (changed)| `"off"` |
6496 -| `markerMid=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
6497 -| `markerMid=(function)`| (initial, warning, ssr mismatch)| `<null>` |
6496 +| `markerMid=(symbol)`| (initial, warning)| `<null>` |
6497 +| `markerMid=(function)`| (initial, warning)| `<null>` |
6498 | `markerMid=(null)`| (initial)| `<null>` |
6499 | `markerMid=(undefined)`| (initial)| `<null>` |
6500
@@ -6518,8 +6518,8 @@
6518 | `markerStart=(string 'false')`| (changed)| `"false"` |
6519 | `markerStart=(string 'on')`| (changed)| `"on"` |
6520 | `markerStart=(string 'off')`| (changed)| `"off"` |
6521 -| `markerStart=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
6522 -| `markerStart=(function)`| (initial, warning, ssr mismatch)| `<null>` |
6521 +| `markerStart=(symbol)`| (initial, warning)| `<null>` |
6522 +| `markerStart=(function)`| (initial, warning)| `<null>` |
6523 | `markerStart=(null)`| (initial)| `<null>` |
6524 | `markerStart=(undefined)`| (initial)| `<null>` |
6525
@@ -7068,8 +7068,8 @@
7068 | `multiple=(string 'false')`| (changed)| `<boolean: true>` |
7069 | `multiple=(string 'on')`| (changed)| `<boolean: true>` |
7070 | `multiple=(string 'off')`| (changed)| `<boolean: true>` |
7071 -| `multiple=(symbol)`| (changed, warning)| `<boolean: true>` |
7072 -| `multiple=(function)`| (changed, warning)| `<boolean: true>` |
7071 +| `multiple=(symbol)`| (changed, warning, ssr mismatch)| `<boolean: true>` |
7072 +| `multiple=(function)`| (changed, warning, ssr mismatch)| `<boolean: true>` |
7073 | `multiple=(null)`| (initial)| `<boolean: false>` |
7074 | `multiple=(undefined)`| (initial)| `<boolean: false>` |
7075
@@ -7193,8 +7193,8 @@
7193 | `noValidate=(string 'false')`| (changed)| `<boolean: true>` |
7194 | `noValidate=(string 'on')`| (changed)| `<boolean: true>` |
7195 | `noValidate=(string 'off')`| (changed)| `<boolean: true>` |
7196 -| `noValidate=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
7197 -| `noValidate=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
7196 +| `noValidate=(symbol)`| (initial, warning)| `<boolean: false>` |
7197 +| `noValidate=(function)`| (initial, warning)| `<boolean: false>` |
7198 | `noValidate=(null)`| (initial)| `<boolean: false>` |
7199 | `noValidate=(undefined)`| (initial)| `<boolean: false>` |
7200
@@ -7443,8 +7443,8 @@
7443 | `open=(string 'false')`| (changed)| `<boolean: true>` |
7444 | `open=(string 'on')`| (changed)| `<boolean: true>` |
7445 | `open=(string 'off')`| (changed)| `<boolean: true>` |
7446 -| `open=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
7447 -| `open=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
7446 +| `open=(symbol)`| (initial, warning)| `<boolean: false>` |
7447 +| `open=(function)`| (initial, warning)| `<boolean: false>` |
7448 | `open=(null)`| (initial)| `<boolean: false>` |
7449 | `open=(undefined)`| (initial)| `<boolean: false>` |
7450
@@ -7693,8 +7693,8 @@
7693 | `overlinePosition=(string 'false')`| (changed)| `"false"` |
7694 | `overlinePosition=(string 'on')`| (changed)| `"on"` |
7695 | `overlinePosition=(string 'off')`| (changed)| `"off"` |
7696 -| `overlinePosition=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
7697 -| `overlinePosition=(function)`| (initial, warning, ssr mismatch)| `<null>` |
7696 +| `overlinePosition=(symbol)`| (initial, warning)| `<null>` |
7697 +| `overlinePosition=(function)`| (initial, warning)| `<null>` |
7698 | `overlinePosition=(null)`| (initial)| `<null>` |
7699 | `overlinePosition=(undefined)`| (initial)| `<null>` |
7700
@@ -7718,8 +7718,8 @@
7718 | `overlineThickness=(string 'false')`| (changed)| `"false"` |
7719 | `overlineThickness=(string 'on')`| (changed)| `"on"` |
7720 | `overlineThickness=(string 'off')`| (changed)| `"off"` |
7721 -| `overlineThickness=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
7722 -| `overlineThickness=(function)`| (initial, warning, ssr mismatch)| `<null>` |
7721 +| `overlineThickness=(symbol)`| (initial, warning)| `<null>` |
7722 +| `overlineThickness=(function)`| (initial, warning)| `<null>` |
7723 | `overlineThickness=(null)`| (initial)| `<null>` |
7724 | `overlineThickness=(undefined)`| (initial)| `<null>` |
7725
@@ -7768,8 +7768,8 @@
7768 | `paintOrder=(string 'false')`| (changed)| `"false"` |
7769 | `paintOrder=(string 'on')`| (changed)| `"on"` |
7770 | `paintOrder=(string 'off')`| (changed)| `"off"` |
7771 -| `paintOrder=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
7772 -| `paintOrder=(function)`| (initial, warning, ssr mismatch)| `<null>` |
7771 +| `paintOrder=(symbol)`| (initial, warning)| `<null>` |
7772 +| `paintOrder=(function)`| (initial, warning)| `<null>` |
7773 | `paintOrder=(null)`| (initial)| `<null>` |
7774 | `paintOrder=(undefined)`| (initial)| `<null>` |
7775
@@ -7793,8 +7793,8 @@
7793 | `panose-1=(string 'false')`| (changed, warning)| `"false"` |
7794 | `panose-1=(string 'on')`| (changed, warning)| `"on"` |
7795 | `panose-1=(string 'off')`| (changed, warning)| `"off"` |
7796 -| `panose-1=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
7797 -| `panose-1=(function)`| (initial, warning, ssr mismatch)| `<null>` |
7796 +| `panose-1=(symbol)`| (initial, warning)| `<null>` |
7797 +| `panose-1=(function)`| (initial, warning)| `<null>` |
7798 | `panose-1=(null)`| (initial, warning)| `<null>` |
7799 | `panose-1=(undefined)`| (initial, warning)| `<null>` |
7800
@@ -7993,8 +7993,8 @@
7993 | `playsInline=(string 'false')`| (changed)| `<empty string>` |
7994 | `playsInline=(string 'on')`| (changed)| `<empty string>` |
7995 | `playsInline=(string 'off')`| (changed)| `<empty string>` |
7996 -| `playsInline=(symbol)`| (initial, warning, ssr mismatch)| `<null>` |
7997 -| `playsInline=(function)`| (initial, warning, ssr mismatch)| `<null>` |
7996 +| `playsInline=(symbol)`| (initial, warning)| `<null>` |
7997 +| `playsInline=(function)`| (initial, warning)| `<null>` |
7998 | `playsInline=(null)`| (initial)| `<null>` |
7999 | `playsInline=(undefined)`| (initial)| `<null>` |
8000
@@ -8043,8 +8043,8 @@
8043 | `pointerEvents=(string 'false')`| (changed)| `"false"` |
8044 | `pointerEvents=(string 'on')`| (changed)| `"on"` |
8045 | `pointerEvents=(string 'off')`| (changed)| `"off"` |
8046 -| `pointerEvents=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
8047 -| `pointerEvents=(function)`| (initial, warning, ssr mismatch)| `<null>` |
8046 +| `pointerEvents=(symbol)`| (initial, warning)| `<null>` |
8047 +| `pointerEvents=(function)`| (initial, warning)| `<null>` |
8048 | `pointerEvents=(null)`| (initial)| `<null>` |
8049 | `pointerEvents=(undefined)`| (initial)| `<null>` |
8050
@@ -8243,7 +8243,7 @@
8243 | `preserveAlpha=(string 'false')`| (initial)| `<boolean: false>` |
8244 | `preserveAlpha=(string 'on')`| (initial)| `<boolean: false>` |
8245 | `preserveAlpha=(string 'off')`| (initial)| `<boolean: false>` |
8246 -| `preserveAlpha=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<boolean: false>` |
8246 +| `preserveAlpha=(symbol)`| (initial, warning)| `<boolean: false>` |
8247 | `preserveAlpha=(function)`| (initial, warning)| `<boolean: false>` |
8248 | `preserveAlpha=(null)`| (initial)| `<boolean: false>` |
8249 | `preserveAlpha=(undefined)`| (initial)| `<boolean: false>` |
@@ -8468,8 +8468,8 @@
8468 | `readOnly=(string 'false')`| (changed)| `<boolean: true>` |
8469 | `readOnly=(string 'on')`| (changed)| `<boolean: true>` |
8470 | `readOnly=(string 'off')`| (changed)| `<boolean: true>` |
8471 -| `readOnly=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
8472 -| `readOnly=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
8471 +| `readOnly=(symbol)`| (initial, warning)| `<boolean: false>` |
8472 +| `readOnly=(function)`| (initial, warning)| `<boolean: false>` |
8473 | `readOnly=(null)`| (initial)| `<boolean: false>` |
8474 | `readOnly=(undefined)`| (initial)| `<boolean: false>` |
8475
@@ -8618,8 +8618,8 @@
8618 | `renderingIntent=(string 'false')`| (changed)| `"false"` |
8619 | `renderingIntent=(string 'on')`| (changed)| `"on"` |
8620 | `renderingIntent=(string 'off')`| (changed)| `"off"` |
8621 -| `renderingIntent=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
8622 -| `renderingIntent=(function)`| (initial, warning, ssr mismatch)| `<null>` |
8621 +| `renderingIntent=(symbol)`| (initial, warning)| `<null>` |
8622 +| `renderingIntent=(function)`| (initial, warning)| `<null>` |
8623 | `renderingIntent=(null)`| (initial)| `<null>` |
8624 | `renderingIntent=(undefined)`| (initial)| `<null>` |
8625
@@ -8693,8 +8693,8 @@
8693 | `required=(string 'false')`| (changed)| `<boolean: true>` |
8694 | `required=(string 'on')`| (changed)| `<boolean: true>` |
8695 | `required=(string 'off')`| (changed)| `<boolean: true>` |
8696 -| `required=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
8697 -| `required=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
8696 +| `required=(symbol)`| (initial, warning)| `<boolean: false>` |
8697 +| `required=(function)`| (initial, warning)| `<boolean: false>` |
8698 | `required=(null)`| (initial)| `<boolean: false>` |
8699 | `required=(undefined)`| (initial)| `<boolean: false>` |
8700
@@ -8868,8 +8868,8 @@
8868 | `reversed=(string 'false')`| (changed)| `<boolean: true>` |
8869 | `reversed=(string 'on')`| (changed)| `<boolean: true>` |
8870 | `reversed=(string 'off')`| (changed)| `<boolean: true>` |
8871 -| `reversed=(symbol)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
8872 -| `reversed=(function)`| (initial, warning, ssr mismatch)| `<boolean: false>` |
8871 +| `reversed=(symbol)`| (initial, warning)| `<boolean: false>` |
8872 +| `reversed=(function)`| (initial, warning)| `<boolean: false>` |
8873 | `reversed=(null)`| (initial)| `<boolean: false>` |
8874 | `reversed=(undefined)`| (initial)| `<boolean: false>` |
8875
@@ -8943,7 +8943,7 @@
8943 | `rows=(string 'false')`| (initial)| `<number: 2>` |
8944 | `rows=(string 'on')`| (initial)| `<number: 2>` |
8945 | `rows=(string 'off')`| (initial)| `<number: 2>` |
8946 -| `rows=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<number: 2>` |
8946 +| `rows=(symbol)`| (initial, warning)| `<number: 2>` |
8947 | `rows=(function)`| (initial, warning)| `<number: 2>` |
8948 | `rows=(null)`| (initial)| `<number: 2>` |
8949 | `rows=(undefined)`| (initial)| `<number: 2>` |
@@ -9118,8 +9118,8 @@
9118 | `scoped=(string 'false')`| (changed)| `<empty string>` |
9119 | `scoped=(string 'on')`| (changed)| `<empty string>` |
9120 | `scoped=(string 'off')`| (changed)| `<empty string>` |
9121 -| `scoped=(symbol)`| (initial, warning, ssr mismatch)| `<null>` |
9122 -| `scoped=(function)`| (initial, warning, ssr mismatch)| `<null>` |
9121 +| `scoped=(symbol)`| (initial, warning)| `<null>` |
9122 +| `scoped=(function)`| (initial, warning)| `<null>` |
9123 | `scoped=(null)`| (initial)| `<null>` |
9124 | `scoped=(undefined)`| (initial)| `<null>` |
9125
@@ -9168,8 +9168,8 @@
9168 | `seamless=(string 'false')`| (changed)| `<empty string>` |
9169 | `seamless=(string 'on')`| (changed)| `<empty string>` |
9170 | `seamless=(string 'off')`| (changed)| `<empty string>` |
9171 -| `seamless=(symbol)`| (initial, warning, ssr mismatch)| `<null>` |
9172 -| `seamless=(function)`| (initial, warning, ssr mismatch)| `<null>` |
9171 +| `seamless=(symbol)`| (initial, warning)| `<null>` |
9172 +| `seamless=(function)`| (initial, warning)| `<null>` |
9173 | `seamless=(null)`| (initial)| `<null>` |
9174 | `seamless=(undefined)`| (initial)| `<null>` |
9175
@@ -9343,8 +9343,8 @@
9343 | `shapeRendering=(string 'false')`| (changed)| `"false"` |
9344 | `shapeRendering=(string 'on')`| (changed)| `"on"` |
9345 | `shapeRendering=(string 'off')`| (changed)| `"off"` |
9346 -| `shapeRendering=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
9347 -| `shapeRendering=(function)`| (initial, warning, ssr mismatch)| `<null>` |
9346 +| `shapeRendering=(symbol)`| (initial, warning)| `<null>` |
9347 +| `shapeRendering=(function)`| (initial, warning)| `<null>` |
9348 | `shapeRendering=(null)`| (initial)| `<null>` |
9349 | `shapeRendering=(undefined)`| (initial)| `<null>` |
9350
@@ -9368,7 +9368,7 @@
9368 | `size=(string 'false')`| (initial)| `<number: 20>` |
9369 | `size=(string 'on')`| (initial)| `<number: 20>` |
9370 | `size=(string 'off')`| (initial)| `<number: 20>` |
9371 -| `size=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<number: 20>` |
9371 +| `size=(symbol)`| (initial, warning)| `<number: 20>` |
9372 | `size=(function)`| (initial, warning)| `<number: 20>` |
9373 | `size=(null)`| (initial)| `<number: 20>` |
9374 | `size=(undefined)`| (initial)| `<number: 20>` |
@@ -9568,7 +9568,7 @@
9568 | `spellCheck=(string 'false')`| (changed)| `<boolean: false>` |
9569 | `spellCheck=(string 'on')`| (initial)| `<boolean: true>` |
9570 | `spellCheck=(string 'off')`| (initial)| `<boolean: true>` |
9571 -| `spellCheck=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<boolean: true>` |
9571 +| `spellCheck=(symbol)`| (initial, warning)| `<boolean: true>` |
9572 | `spellCheck=(function)`| (initial, warning)| `<boolean: true>` |
9573 | `spellCheck=(null)`| (initial)| `<boolean: true>` |
9574 | `spellCheck=(undefined)`| (initial)| `<boolean: true>` |
@@ -9818,7 +9818,7 @@
9818 | `start=(string 'false')`| (initial)| `<number: 1>` |
9819 | `start=(string 'on')`| (initial)| `<number: 1>` |
9820 | `start=(string 'off')`| (initial)| `<number: 1>` |
9821 -| `start=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<number: 1>` |
9821 +| `start=(symbol)`| (initial, warning)| `<number: 1>` |
9822 | `start=(function)`| (initial, warning)| `<number: 1>` |
9823 | `start=(null)`| (initial)| `<number: 1>` |
9824 | `start=(undefined)`| (initial)| `<number: 1>` |
@@ -10068,8 +10068,8 @@
10068 | `stopColor=(string 'false')`| (changed)| `"false"` |
10069 | `stopColor=(string 'on')`| (changed)| `"on"` |
10070 | `stopColor=(string 'off')`| (changed)| `"off"` |
10071 -| `stopColor=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10072 -| `stopColor=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10071 +| `stopColor=(symbol)`| (initial, warning)| `<null>` |
10072 +| `stopColor=(function)`| (initial, warning)| `<null>` |
10073 | `stopColor=(null)`| (initial)| `<null>` |
10074 | `stopColor=(undefined)`| (initial)| `<null>` |
10075
@@ -10093,8 +10093,8 @@
10093 | `stopOpacity=(string 'false')`| (changed)| `"false"` |
10094 | `stopOpacity=(string 'on')`| (changed)| `"on"` |
10095 | `stopOpacity=(string 'off')`| (changed)| `"off"` |
10096 -| `stopOpacity=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10097 -| `stopOpacity=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10096 +| `stopOpacity=(symbol)`| (initial, warning)| `<null>` |
10097 +| `stopOpacity=(function)`| (initial, warning)| `<null>` |
10098 | `stopOpacity=(null)`| (initial)| `<null>` |
10099 | `stopOpacity=(undefined)`| (initial)| `<null>` |
10100
@@ -10168,8 +10168,8 @@
10168 | `strikethroughPosition=(string 'false')`| (changed)| `"false"` |
10169 | `strikethroughPosition=(string 'on')`| (changed)| `"on"` |
10170 | `strikethroughPosition=(string 'off')`| (changed)| `"off"` |
10171 -| `strikethroughPosition=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10172 -| `strikethroughPosition=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10171 +| `strikethroughPosition=(symbol)`| (initial, warning)| `<null>` |
10172 +| `strikethroughPosition=(function)`| (initial, warning)| `<null>` |
10173 | `strikethroughPosition=(null)`| (initial)| `<null>` |
10174 | `strikethroughPosition=(undefined)`| (initial)| `<null>` |
10175
@@ -10193,8 +10193,8 @@
10193 | `strikethroughThickness=(string 'false')`| (changed)| `"false"` |
10194 | `strikethroughThickness=(string 'on')`| (changed)| `"on"` |
10195 | `strikethroughThickness=(string 'off')`| (changed)| `"off"` |
10196 -| `strikethroughThickness=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10197 -| `strikethroughThickness=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10196 +| `strikethroughThickness=(symbol)`| (initial, warning)| `<null>` |
10197 +| `strikethroughThickness=(function)`| (initial, warning)| `<null>` |
10198 | `strikethroughThickness=(null)`| (initial)| `<null>` |
10199 | `strikethroughThickness=(undefined)`| (initial)| `<null>` |
10200
@@ -10468,8 +10468,8 @@
10468 | `strokeDasharray=(string 'false')`| (changed)| `"false"` |
10469 | `strokeDasharray=(string 'on')`| (changed)| `"on"` |
10470 | `strokeDasharray=(string 'off')`| (changed)| `"off"` |
10471 -| `strokeDasharray=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10472 -| `strokeDasharray=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10471 +| `strokeDasharray=(symbol)`| (initial, warning)| `<null>` |
10472 +| `strokeDasharray=(function)`| (initial, warning)| `<null>` |
10473 | `strokeDasharray=(null)`| (initial)| `<null>` |
10474 | `strokeDasharray=(undefined)`| (initial)| `<null>` |
10475
@@ -10493,8 +10493,8 @@
10493 | `strokeDashoffset=(string 'false')`| (changed)| `"false"` |
10494 | `strokeDashoffset=(string 'on')`| (changed)| `"on"` |
10495 | `strokeDashoffset=(string 'off')`| (changed)| `"off"` |
10496 -| `strokeDashoffset=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10497 -| `strokeDashoffset=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10496 +| `strokeDashoffset=(symbol)`| (initial, warning)| `<null>` |
10497 +| `strokeDashoffset=(function)`| (initial, warning)| `<null>` |
10498 | `strokeDashoffset=(null)`| (initial)| `<null>` |
10499 | `strokeDashoffset=(undefined)`| (initial)| `<null>` |
10500
@@ -10518,8 +10518,8 @@
10518 | `strokeLinecap=(string 'false')`| (changed)| `"false"` |
10519 | `strokeLinecap=(string 'on')`| (changed)| `"on"` |
10520 | `strokeLinecap=(string 'off')`| (changed)| `"off"` |
10521 -| `strokeLinecap=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10522 -| `strokeLinecap=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10521 +| `strokeLinecap=(symbol)`| (initial, warning)| `<null>` |
10522 +| `strokeLinecap=(function)`| (initial, warning)| `<null>` |
10523 | `strokeLinecap=(null)`| (initial)| `<null>` |
10524 | `strokeLinecap=(undefined)`| (initial)| `<null>` |
10525
@@ -10543,8 +10543,8 @@
10543 | `strokeLinejoin=(string 'false')`| (changed)| `"false"` |
10544 | `strokeLinejoin=(string 'on')`| (changed)| `"on"` |
10545 | `strokeLinejoin=(string 'off')`| (changed)| `"off"` |
10546 -| `strokeLinejoin=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10547 -| `strokeLinejoin=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10546 +| `strokeLinejoin=(symbol)`| (initial, warning)| `<null>` |
10547 +| `strokeLinejoin=(function)`| (initial, warning)| `<null>` |
10548 | `strokeLinejoin=(null)`| (initial)| `<null>` |
10549 | `strokeLinejoin=(undefined)`| (initial)| `<null>` |
10550
@@ -10568,8 +10568,8 @@
10568 | `strokeMiterlimit=(string 'false')`| (changed)| `"false"` |
10569 | `strokeMiterlimit=(string 'on')`| (changed)| `"on"` |
10570 | `strokeMiterlimit=(string 'off')`| (changed)| `"off"` |
10571 -| `strokeMiterlimit=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10572 -| `strokeMiterlimit=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10571 +| `strokeMiterlimit=(symbol)`| (initial, warning)| `<null>` |
10572 +| `strokeMiterlimit=(function)`| (initial, warning)| `<null>` |
10573 | `strokeMiterlimit=(null)`| (initial)| `<null>` |
10574 | `strokeMiterlimit=(undefined)`| (initial)| `<null>` |
10575
@@ -10593,8 +10593,8 @@
10593 | `strokeOpacity=(string 'false')`| (changed)| `"false"` |
10594 | `strokeOpacity=(string 'on')`| (changed)| `"on"` |
10595 | `strokeOpacity=(string 'off')`| (changed)| `"off"` |
10596 -| `strokeOpacity=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10597 -| `strokeOpacity=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10596 +| `strokeOpacity=(symbol)`| (initial, warning)| `<null>` |
10597 +| `strokeOpacity=(function)`| (initial, warning)| `<null>` |
10598 | `strokeOpacity=(null)`| (initial)| `<null>` |
10599 | `strokeOpacity=(undefined)`| (initial)| `<null>` |
10600
@@ -10618,8 +10618,8 @@
10618 | `strokeWidth=(string 'false')`| (changed)| `"false"` |
10619 | `strokeWidth=(string 'on')`| (changed)| `"on"` |
10620 | `strokeWidth=(string 'off')`| (changed)| `"off"` |
10621 -| `strokeWidth=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10622 -| `strokeWidth=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10621 +| `strokeWidth=(symbol)`| (initial, warning)| `<null>` |
10622 +| `strokeWidth=(function)`| (initial, warning)| `<null>` |
10623 | `strokeWidth=(null)`| (initial)| `<null>` |
10624 | `strokeWidth=(undefined)`| (initial)| `<null>` |
10625
@@ -10768,7 +10768,7 @@
10768 | `tabIndex=(string 'false')`| (initial)| `<number: -1>` |
10769 | `tabIndex=(string 'on')`| (initial)| `<number: -1>` |
10770 | `tabIndex=(string 'off')`| (initial)| `<number: -1>` |
10771 -| `tabIndex=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<number: -1>` |
10771 +| `tabIndex=(symbol)`| (initial, warning)| `<number: -1>` |
10772 | `tabIndex=(function)`| (initial, warning)| `<number: -1>` |
10773 | `tabIndex=(null)`| (initial)| `<number: -1>` |
10774 | `tabIndex=(undefined)`| (initial)| `<number: -1>` |
@@ -10793,7 +10793,7 @@
10793 | `tabIndex=(string 'false')`| (initial)| `<number: -1>` |
10794 | `tabIndex=(string 'on')`| (initial)| `<number: -1>` |
10795 | `tabIndex=(string 'off')`| (initial)| `<number: -1>` |
10796 -| `tabIndex=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<number: -1>` |
10796 +| `tabIndex=(symbol)`| (initial, warning)| `<number: -1>` |
10797 | `tabIndex=(function)`| (initial, warning)| `<number: -1>` |
10798 | `tabIndex=(null)`| (initial)| `<number: -1>` |
10799 | `tabIndex=(undefined)`| (initial)| `<number: -1>` |
@@ -10993,8 +10993,8 @@
10993 | `textAnchor=(string 'false')`| (changed)| `"false"` |
10994 | `textAnchor=(string 'on')`| (changed)| `"on"` |
10995 | `textAnchor=(string 'off')`| (changed)| `"off"` |
10996 -| `textAnchor=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
10997 -| `textAnchor=(function)`| (initial, warning, ssr mismatch)| `<null>` |
10996 +| `textAnchor=(symbol)`| (initial, warning)| `<null>` |
10997 +| `textAnchor=(function)`| (initial, warning)| `<null>` |
10998 | `textAnchor=(null)`| (initial)| `<null>` |
10999 | `textAnchor=(undefined)`| (initial)| `<null>` |
11000
@@ -11018,8 +11018,8 @@
11018 | `textDecoration=(string 'false')`| (changed)| `"false"` |
11019 | `textDecoration=(string 'on')`| (changed)| `"on"` |
11020 | `textDecoration=(string 'off')`| (changed)| `"off"` |
11021 -| `textDecoration=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
11022 -| `textDecoration=(function)`| (initial, warning, ssr mismatch)| `<null>` |
11021 +| `textDecoration=(symbol)`| (initial, warning)| `<null>` |
11022 +| `textDecoration=(function)`| (initial, warning)| `<null>` |
11023 | `textDecoration=(null)`| (initial)| `<null>` |
11024 | `textDecoration=(undefined)`| (initial)| `<null>` |
11025
@@ -11068,8 +11068,8 @@
11068 | `textRendering=(string 'false')`| (changed)| `"false"` |
11069 | `textRendering=(string 'on')`| (changed)| `"on"` |
11070 | `textRendering=(string 'off')`| (changed)| `"off"` |
11071 -| `textRendering=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
11072 -| `textRendering=(function)`| (initial, warning, ssr mismatch)| `<null>` |
11071 +| `textRendering=(symbol)`| (initial, warning)| `<null>` |
11072 +| `textRendering=(function)`| (initial, warning)| `<null>` |
11073 | `textRendering=(null)`| (initial)| `<null>` |
11074 | `textRendering=(undefined)`| (initial)| `<null>` |
11075
@@ -11343,8 +11343,8 @@
11343 | `underlinePosition=(string 'false')`| (changed)| `"false"` |
11344 | `underlinePosition=(string 'on')`| (changed)| `"on"` |
11345 | `underlinePosition=(string 'off')`| (changed)| `"off"` |
11346 -| `underlinePosition=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
11347 -| `underlinePosition=(function)`| (initial, warning, ssr mismatch)| `<null>` |
11346 +| `underlinePosition=(symbol)`| (initial, warning)| `<null>` |
11347 +| `underlinePosition=(function)`| (initial, warning)| `<null>` |
11348 | `underlinePosition=(null)`| (initial)| `<null>` |
11349 | `underlinePosition=(undefined)`| (initial)| `<null>` |
11350
@@ -11368,8 +11368,8 @@
11368 | `underlineThickness=(string 'false')`| (changed)| `"false"` |
11369 | `underlineThickness=(string 'on')`| (changed)| `"on"` |
11370 | `underlineThickness=(string 'off')`| (changed)| `"off"` |
11371 -| `underlineThickness=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
11372 -| `underlineThickness=(function)`| (initial, warning, ssr mismatch)| `<null>` |
11371 +| `underlineThickness=(symbol)`| (initial, warning)| `<null>` |
11372 +| `underlineThickness=(function)`| (initial, warning)| `<null>` |
11373 | `underlineThickness=(null)`| (initial)| `<null>` |
11374 | `underlineThickness=(undefined)`| (initial)| `<null>` |
11375
@@ -11468,8 +11468,8 @@
11468 | `unicodeBidi=(string 'false')`| (changed)| `"false"` |
11469 | `unicodeBidi=(string 'on')`| (changed)| `"on"` |
11470 | `unicodeBidi=(string 'off')`| (changed)| `"off"` |
11471 -| `unicodeBidi=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
11472 -| `unicodeBidi=(function)`| (initial, warning, ssr mismatch)| `<null>` |
11471 +| `unicodeBidi=(symbol)`| (initial, warning)| `<null>` |
11472 +| `unicodeBidi=(function)`| (initial, warning)| `<null>` |
11473 | `unicodeBidi=(null)`| (initial)| `<null>` |
11474 | `unicodeBidi=(undefined)`| (initial)| `<null>` |
11475
@@ -11493,8 +11493,8 @@
11493 | `unicodeRange=(string 'false')`| (changed)| `"false"` |
11494 | `unicodeRange=(string 'on')`| (changed)| `"on"` |
11495 | `unicodeRange=(string 'off')`| (changed)| `"off"` |
11496 -| `unicodeRange=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
11497 -| `unicodeRange=(function)`| (initial, warning, ssr mismatch)| `<null>` |
11496 +| `unicodeRange=(symbol)`| (initial, warning)| `<null>` |
11497 +| `unicodeRange=(function)`| (initial, warning)| `<null>` |
11498 | `unicodeRange=(null)`| (initial)| `<null>` |
11499 | `unicodeRange=(undefined)`| (initial)| `<null>` |
11500
@@ -11543,7 +11543,7 @@
11543 | `unitsPerEm=(string 'false')`| (initial)| `<null>` |
11544 | `unitsPerEm=(string 'on')`| (initial)| `<null>` |
11545 | `unitsPerEm=(string 'off')`| (initial)| `<null>` |
11546 -| `unitsPerEm=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
11546 +| `unitsPerEm=(symbol)`| (initial, warning)| `<null>` |
11547 | `unitsPerEm=(function)`| (initial, warning)| `<null>` |
11548 | `unitsPerEm=(null)`| (initial)| `<null>` |
11549 | `unitsPerEm=(undefined)`| (initial)| `<null>` |
@@ -11743,8 +11743,8 @@
11743 | `vAlphabetic=(string 'false')`| (changed)| `"false"` |
11744 | `vAlphabetic=(string 'on')`| (changed)| `"on"` |
11745 | `vAlphabetic=(string 'off')`| (changed)| `"off"` |
11746 -| `vAlphabetic=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
11747 -| `vAlphabetic=(function)`| (initial, warning, ssr mismatch)| `<null>` |
11746 +| `vAlphabetic=(symbol)`| (initial, warning)| `<null>` |
11747 +| `vAlphabetic=(function)`| (initial, warning)| `<null>` |
11748 | `vAlphabetic=(null)`| (initial)| `<null>` |
11749 | `vAlphabetic=(undefined)`| (initial)| `<null>` |
11750
@@ -11768,8 +11768,8 @@
11768 | `value=(string 'false')`| (changed)| `"false"` |
11769 | `value=(string 'on')`| (changed)| `"on"` |
11770 | `value=(string 'off')`| (changed)| `"off"` |
11771 -| `value=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<empty string>` |
11772 -| `value=(function)`| (initial, warning, ssr mismatch)| `<empty string>` |
11771 +| `value=(symbol)`| (initial, warning, ssr warning)| `<empty string>` |
11772 +| `value=(function)`| (initial, warning, ssr warning)| `<empty string>` |
11773 | `value=(null)`| (initial, warning, ssr warning)| `<empty string>` |
11774 | `value=(undefined)`| (initial)| `<empty string>` |
11775
@@ -11793,8 +11793,8 @@
11793 | `value=(string 'false')`| (changed)| `"false"` |
11794 | `value=(string 'on')`| (changed)| `"on"` |
11795 | `value=(string 'off')`| (changed)| `"off"` |
11796 -| `value=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<empty string>` |
11797 -| `value=(function)`| (initial, warning, ssr mismatch)| `<empty string>` |
11796 +| `value=(symbol)`| (initial, warning)| `<empty string>` |
11797 +| `value=(function)`| (initial, warning)| `<empty string>` |
11798 | `value=(null)`| (initial, warning, ssr warning)| `<empty string>` |
11799 | `value=(undefined)`| (initial)| `<empty string>` |
11800
@@ -11818,7 +11818,7 @@
11818 | `value=(string 'false')`| (initial)| `<empty string>` |
11819 | `value=(string 'on')`| (initial)| `<empty string>` |
11820 | `value=(string 'off')`| (initial)| `<empty string>` |
11821 -| `value=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<empty string>` |
11821 +| `value=(symbol)`| (initial, warning)| `<empty string>` |
11822 | `value=(function)`| (initial, warning)| `<empty string>` |
11823 | `value=(null)`| (initial, warning, ssr warning)| `<empty string>` |
11824 | `value=(undefined)`| (initial)| `<empty string>` |
@@ -11868,8 +11868,8 @@
11868 | `value=(string 'false')`| (changed)| `"false"` |
11869 | `value=(string 'on')`| (changed)| `"on"` |
11870 | `value=(string 'off')`| (changed)| `"off"` |
11871 -| `value=(symbol)`| (changed, error, warning, ssr error)| `` |
11872 -| `value=(function)`| (changed, warning)| `"function f() {}"` |
11871 +| `value=(symbol)`| (changed, error, warning, ssr mismatch)| `` |
11872 +| `value=(function)`| (changed, warning, ssr mismatch)| `"function f() {}"` |
11873 | `value=(null)`| (initial)| `<empty string>` |
11874 | `value=(undefined)`| (initial)| `<empty string>` |
11875
@@ -11968,8 +11968,8 @@
11968 | `vectorEffect=(string 'false')`| (changed)| `"false"` |
11969 | `vectorEffect=(string 'on')`| (changed)| `"on"` |
11970 | `vectorEffect=(string 'off')`| (changed)| `"off"` |
11971 -| `vectorEffect=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
11972 -| `vectorEffect=(function)`| (initial, warning, ssr mismatch)| `<null>` |
11971 +| `vectorEffect=(symbol)`| (initial, warning)| `<null>` |
11972 +| `vectorEffect=(function)`| (initial, warning)| `<null>` |
11973 | `vectorEffect=(null)`| (initial)| `<null>` |
11974 | `vectorEffect=(undefined)`| (initial)| `<null>` |
11975
@@ -12118,8 +12118,8 @@
12118 | `vertAdvY=(string 'false')`| (changed)| `"false"` |
12119 | `vertAdvY=(string 'on')`| (changed)| `"on"` |
12120 | `vertAdvY=(string 'off')`| (changed)| `"off"` |
12121 -| `vertAdvY=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12122 -| `vertAdvY=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12121 +| `vertAdvY=(symbol)`| (initial, warning)| `<null>` |
12122 +| `vertAdvY=(function)`| (initial, warning)| `<null>` |
12123 | `vertAdvY=(null)`| (initial)| `<null>` |
12124 | `vertAdvY=(undefined)`| (initial)| `<null>` |
12125
@@ -12143,8 +12143,8 @@
12143 | `vertOriginX=(string 'false')`| (changed)| `"false"` |
12144 | `vertOriginX=(string 'on')`| (changed)| `"on"` |
12145 | `vertOriginX=(string 'off')`| (changed)| `"off"` |
12146 -| `vertOriginX=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12147 -| `vertOriginX=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12146 +| `vertOriginX=(symbol)`| (initial, warning)| `<null>` |
12147 +| `vertOriginX=(function)`| (initial, warning)| `<null>` |
12148 | `vertOriginX=(null)`| (initial)| `<null>` |
12149 | `vertOriginX=(undefined)`| (initial)| `<null>` |
12150
@@ -12168,8 +12168,8 @@
12168 | `vertOriginY=(string 'false')`| (changed)| `"false"` |
12169 | `vertOriginY=(string 'on')`| (changed)| `"on"` |
12170 | `vertOriginY=(string 'off')`| (changed)| `"off"` |
12171 -| `vertOriginY=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12172 -| `vertOriginY=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12171 +| `vertOriginY=(symbol)`| (initial, warning)| `<null>` |
12172 +| `vertOriginY=(function)`| (initial, warning)| `<null>` |
12173 | `vertOriginY=(null)`| (initial)| `<null>` |
12174 | `vertOriginY=(undefined)`| (initial)| `<null>` |
12175
@@ -12193,8 +12193,8 @@
12193 | `vHanging=(string 'false')`| (changed)| `"false"` |
12194 | `vHanging=(string 'on')`| (changed)| `"on"` |
12195 | `vHanging=(string 'off')`| (changed)| `"off"` |
12196 -| `vHanging=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12197 -| `vHanging=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12196 +| `vHanging=(symbol)`| (initial, warning)| `<null>` |
12197 +| `vHanging=(function)`| (initial, warning)| `<null>` |
12198 | `vHanging=(null)`| (initial)| `<null>` |
12199 | `vHanging=(undefined)`| (initial)| `<null>` |
12200
@@ -12218,8 +12218,8 @@
12218 | `vIdeographic=(string 'false')`| (changed)| `"false"` |
12219 | `vIdeographic=(string 'on')`| (changed)| `"on"` |
12220 | `vIdeographic=(string 'off')`| (changed)| `"off"` |
12221 -| `vIdeographic=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12222 -| `vIdeographic=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12221 +| `vIdeographic=(symbol)`| (initial, warning)| `<null>` |
12222 +| `vIdeographic=(function)`| (initial, warning)| `<null>` |
12223 | `vIdeographic=(null)`| (initial)| `<null>` |
12224 | `vIdeographic=(undefined)`| (initial)| `<null>` |
12225
@@ -12343,8 +12343,8 @@
12343 | `vMathematical=(string 'false')`| (changed)| `"false"` |
12344 | `vMathematical=(string 'on')`| (changed)| `"on"` |
12345 | `vMathematical=(string 'off')`| (changed)| `"off"` |
12346 -| `vMathematical=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12347 -| `vMathematical=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12346 +| `vMathematical=(symbol)`| (initial, warning)| `<null>` |
12347 +| `vMathematical=(function)`| (initial, warning)| `<null>` |
12348 | `vMathematical=(null)`| (initial)| `<null>` |
12349 | `vMathematical=(undefined)`| (initial)| `<null>` |
12350
@@ -12518,8 +12518,8 @@
12518 | `wordSpacing=(string 'false')`| (changed)| `"false"` |
12519 | `wordSpacing=(string 'on')`| (changed)| `"on"` |
12520 | `wordSpacing=(string 'off')`| (changed)| `"off"` |
12521 -| `wordSpacing=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12522 -| `wordSpacing=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12521 +| `wordSpacing=(symbol)`| (initial, warning)| `<null>` |
12522 +| `wordSpacing=(function)`| (initial, warning)| `<null>` |
12523 | `wordSpacing=(null)`| (initial)| `<null>` |
12524 | `wordSpacing=(undefined)`| (initial)| `<null>` |
12525
@@ -12593,8 +12593,8 @@
12593 | `writingMode=(string 'false')`| (changed)| `"false"` |
12594 | `writingMode=(string 'on')`| (changed)| `"on"` |
12595 | `writingMode=(string 'off')`| (changed)| `"off"` |
12596 -| `writingMode=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12597 -| `writingMode=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12596 +| `writingMode=(symbol)`| (initial, warning)| `<null>` |
12597 +| `writingMode=(function)`| (initial, warning)| `<null>` |
12598 | `writingMode=(null)`| (initial)| `<null>` |
12599 | `writingMode=(undefined)`| (initial)| `<null>` |
12600
@@ -12743,8 +12743,8 @@
12743 | `xHeight=(string 'false')`| (changed)| `"false"` |
12744 | `xHeight=(string 'on')`| (changed)| `"on"` |
12745 | `xHeight=(string 'off')`| (changed)| `"off"` |
12746 -| `xHeight=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12747 -| `xHeight=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12746 +| `xHeight=(symbol)`| (initial, warning)| `<null>` |
12747 +| `xHeight=(function)`| (initial, warning)| `<null>` |
12748 | `xHeight=(null)`| (initial)| `<null>` |
12749 | `xHeight=(undefined)`| (initial)| `<null>` |
12750
@@ -12968,8 +12968,8 @@
12968 | `xlinkActuate=(string 'false')`| (changed)| `"false"` |
12969 | `xlinkActuate=(string 'on')`| (changed)| `"on"` |
12970 | `xlinkActuate=(string 'off')`| (changed)| `"off"` |
12971 -| `xlinkActuate=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
12972 -| `xlinkActuate=(function)`| (initial, warning, ssr mismatch)| `<null>` |
12971 +| `xlinkActuate=(symbol)`| (initial, warning)| `<null>` |
12972 +| `xlinkActuate=(function)`| (initial, warning)| `<null>` |
12973 | `xlinkActuate=(null)`| (initial)| `<null>` |
12974 | `xlinkActuate=(undefined)`| (initial)| `<null>` |
12975
@@ -13018,8 +13018,8 @@
13018 | `xlinkArcrole=(string 'false')`| (changed)| `"false"` |
13019 | `xlinkArcrole=(string 'on')`| (changed)| `"on"` |
13020 | `xlinkArcrole=(string 'off')`| (changed)| `"off"` |
13021 -| `xlinkArcrole=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13022 -| `xlinkArcrole=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13021 +| `xlinkArcrole=(symbol)`| (initial, warning)| `<null>` |
13022 +| `xlinkArcrole=(function)`| (initial, warning)| `<null>` |
13023 | `xlinkArcrole=(null)`| (initial)| `<null>` |
13024 | `xlinkArcrole=(undefined)`| (initial)| `<null>` |
13025
@@ -13043,8 +13043,8 @@
13043 | `xlinkHref=(string 'false')`| (changed)| `"false"` |
13044 | `xlinkHref=(string 'on')`| (changed)| `"on"` |
13045 | `xlinkHref=(string 'off')`| (changed)| `"off"` |
13046 -| `xlinkHref=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13047 -| `xlinkHref=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13046 +| `xlinkHref=(symbol)`| (initial, warning)| `<null>` |
13047 +| `xlinkHref=(function)`| (initial, warning)| `<null>` |
13048 | `xlinkHref=(null)`| (initial)| `<null>` |
13049 | `xlinkHref=(undefined)`| (initial)| `<null>` |
13050
@@ -13068,8 +13068,8 @@
13068 | `xlinkRole=(string 'false')`| (changed)| `"false"` |
13069 | `xlinkRole=(string 'on')`| (changed)| `"on"` |
13070 | `xlinkRole=(string 'off')`| (changed)| `"off"` |
13071 -| `xlinkRole=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13072 -| `xlinkRole=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13071 +| `xlinkRole=(symbol)`| (initial, warning)| `<null>` |
13072 +| `xlinkRole=(function)`| (initial, warning)| `<null>` |
13073 | `xlinkRole=(null)`| (initial)| `<null>` |
13074 | `xlinkRole=(undefined)`| (initial)| `<null>` |
13075
@@ -13093,8 +13093,8 @@
13093 | `xlinkShow=(string 'false')`| (changed)| `"false"` |
13094 | `xlinkShow=(string 'on')`| (changed)| `"on"` |
13095 | `xlinkShow=(string 'off')`| (changed)| `"off"` |
13096 -| `xlinkShow=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13097 -| `xlinkShow=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13096 +| `xlinkShow=(symbol)`| (initial, warning)| `<null>` |
13097 +| `xlinkShow=(function)`| (initial, warning)| `<null>` |
13098 | `xlinkShow=(null)`| (initial)| `<null>` |
13099 | `xlinkShow=(undefined)`| (initial)| `<null>` |
13100
@@ -13118,8 +13118,8 @@
13118 | `xlinkTitle=(string 'false')`| (changed)| `"false"` |
13119 | `xlinkTitle=(string 'on')`| (changed)| `"on"` |
13120 | `xlinkTitle=(string 'off')`| (changed)| `"off"` |
13121 -| `xlinkTitle=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13122 -| `xlinkTitle=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13121 +| `xlinkTitle=(symbol)`| (initial, warning)| `<null>` |
13122 +| `xlinkTitle=(function)`| (initial, warning)| `<null>` |
13123 | `xlinkTitle=(null)`| (initial)| `<null>` |
13124 | `xlinkTitle=(undefined)`| (initial)| `<null>` |
13125
@@ -13143,8 +13143,8 @@
13143 | `xlinkType=(string 'false')`| (changed)| `"false"` |
13144 | `xlinkType=(string 'on')`| (changed)| `"on"` |
13145 | `xlinkType=(string 'off')`| (changed)| `"off"` |
13146 -| `xlinkType=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13147 -| `xlinkType=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13146 +| `xlinkType=(symbol)`| (initial, warning)| `<null>` |
13147 +| `xlinkType=(function)`| (initial, warning)| `<null>` |
13148 | `xlinkType=(null)`| (initial)| `<null>` |
13149 | `xlinkType=(undefined)`| (initial)| `<null>` |
13150
@@ -13243,8 +13243,8 @@
13243 | `xmlBase=(string 'false')`| (changed)| `"false"` |
13244 | `xmlBase=(string 'on')`| (changed)| `"on"` |
13245 | `xmlBase=(string 'off')`| (changed)| `"off"` |
13246 -| `xmlBase=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13247 -| `xmlBase=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13246 +| `xmlBase=(symbol)`| (initial, warning)| `<null>` |
13247 +| `xmlBase=(function)`| (initial, warning)| `<null>` |
13248 | `xmlBase=(null)`| (initial)| `<null>` |
13249 | `xmlBase=(undefined)`| (initial)| `<null>` |
13250
@@ -13268,8 +13268,8 @@
13268 | `xmlLang=(string 'false')`| (changed)| `"false"` |
13269 | `xmlLang=(string 'on')`| (changed)| `"on"` |
13270 | `xmlLang=(string 'off')`| (changed)| `"off"` |
13271 -| `xmlLang=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13272 -| `xmlLang=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13271 +| `xmlLang=(symbol)`| (initial, warning)| `<null>` |
13272 +| `xmlLang=(function)`| (initial, warning)| `<null>` |
13273 | `xmlLang=(null)`| (initial)| `<null>` |
13274 | `xmlLang=(undefined)`| (initial)| `<null>` |
13275
@@ -13343,8 +13343,8 @@
13343 | `xmlnsXlink=(string 'false')`| (changed)| `"false"` |
13344 | `xmlnsXlink=(string 'on')`| (changed)| `"on"` |
13345 | `xmlnsXlink=(string 'off')`| (changed)| `"off"` |
13346 -| `xmlnsXlink=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13347 -| `xmlnsXlink=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13346 +| `xmlnsXlink=(symbol)`| (initial, warning)| `<null>` |
13347 +| `xmlnsXlink=(function)`| (initial, warning)| `<null>` |
13348 | `xmlnsXlink=(null)`| (initial)| `<null>` |
13349 | `xmlnsXlink=(undefined)`| (initial)| `<null>` |
13350
@@ -13368,8 +13368,8 @@
13368 | `xmlSpace=(string 'false')`| (changed)| `"false"` |
13369 | `xmlSpace=(string 'on')`| (changed)| `"on"` |
13370 | `xmlSpace=(string 'off')`| (changed)| `"off"` |
13371 -| `xmlSpace=(symbol)`| (initial, warning, ssr error, ssr mismatch)| `<null>` |
13372 -| `xmlSpace=(function)`| (initial, warning, ssr mismatch)| `<null>` |
13371 +| `xmlSpace=(symbol)`| (initial, warning)| `<null>` |
13372 +| `xmlSpace=(function)`| (initial, warning)| `<null>` |
13373 | `xmlSpace=(null)`| (initial)| `<null>` |
13374 | `xmlSpace=(undefined)`| (initial)| `<null>` |
13375
packages/react-dom/src/__tests__/ReactDOMComponent-test.js
+110
@@ -442,6 +442,97 @@ describe('ReactDOMComponent', () => {
442 expect(container.firstChild.className).toEqual('');
443 });
444
445 + it('should not set null/undefined attributes', () => {
446 + var container = document.createElement('div');
447 + // Initial render.
448 + ReactDOM.render(<img src={null} data-foo={undefined} />, container);
449 + var node = container.firstChild;
450 + expect(node.hasAttribute('src')).toBe(false);
451 + expect(node.hasAttribute('data-foo')).toBe(false);
452 + // Update in one direction.
453 + ReactDOM.render(<img src={undefined} data-foo={null} />, container);
454 + expect(node.hasAttribute('src')).toBe(false);
455 + expect(node.hasAttribute('data-foo')).toBe(false);
456 + // Update in another direction.
457 + ReactDOM.render(<img src={null} data-foo={undefined} />, container);
458 + expect(node.hasAttribute('src')).toBe(false);
459 + expect(node.hasAttribute('data-foo')).toBe(false);
460 + // Removal.
461 + ReactDOM.render(<img />, container);
462 + expect(node.hasAttribute('src')).toBe(false);
463 + expect(node.hasAttribute('data-foo')).toBe(false);
464 + // Addition.
465 + ReactDOM.render(<img src={undefined} data-foo={null} />, container);
466 + expect(node.hasAttribute('src')).toBe(false);
467 + expect(node.hasAttribute('data-foo')).toBe(false);
468 + });
469 +
470 + it('should apply React-specific aliases to HTML elements', () => {
471 + var container = document.createElement('div');
472 + ReactDOM.render(<form acceptCharset="foo" />, container);
473 + var node = container.firstChild;
474 + // Test attribute initialization.
475 + expect(node.getAttribute('accept-charset')).toBe('foo');
476 + expect(node.hasAttribute('acceptCharset')).toBe(false);
477 + // Test attribute update.
478 + ReactDOM.render(<form acceptCharset="boo" />, container);
479 + expect(node.getAttribute('accept-charset')).toBe('boo');
480 + expect(node.hasAttribute('acceptCharset')).toBe(false);
481 + // Test attribute removal by setting to null.
482 + ReactDOM.render(<form acceptCharset={null} />, container);
483 + expect(node.hasAttribute('accept-charset')).toBe(false);
484 + expect(node.hasAttribute('acceptCharset')).toBe(false);
485 + // Restore.
486 + ReactDOM.render(<form acceptCharset="foo" />, container);
487 + expect(node.getAttribute('accept-charset')).toBe('foo');
488 + expect(node.hasAttribute('acceptCharset')).toBe(false);
489 + // Test attribute removal by setting to undefined.
490 + ReactDOM.render(<form acceptCharset={undefined} />, container);
491 + expect(node.hasAttribute('accept-charset')).toBe(false);
492 + expect(node.hasAttribute('acceptCharset')).toBe(false);
493 + // Restore.
494 + ReactDOM.render(<form acceptCharset="foo" />, container);
495 + expect(node.getAttribute('accept-charset')).toBe('foo');
496 + expect(node.hasAttribute('acceptCharset')).toBe(false);
497 + // Test attribute removal.
498 + ReactDOM.render(<form />, container);
499 + expect(node.hasAttribute('accept-charset')).toBe(false);
500 + expect(node.hasAttribute('acceptCharset')).toBe(false);
501 + });
502 +
503 + it('should apply React-specific aliases to SVG elements', () => {
504 + var container = document.createElement('div');
505 + ReactDOM.render(<svg arabicForm="foo" />, container);
506 + var node = container.firstChild;
507 + // Test attribute initialization.
508 + expect(node.getAttribute('arabic-form')).toBe('foo');
509 + expect(node.hasAttribute('arabicForm')).toBe(false);
510 + // Test attribute update.
511 + ReactDOM.render(<svg arabicForm="boo" />, container);
512 + expect(node.getAttribute('arabic-form')).toBe('boo');
513 + expect(node.hasAttribute('arabicForm')).toBe(false);
514 + // Test attribute removal by setting to null.
515 + ReactDOM.render(<svg arabicForm={null} />, container);
516 + expect(node.hasAttribute('arabic-form')).toBe(false);
517 + expect(node.hasAttribute('arabicForm')).toBe(false);
518 + // Restore.
519 + ReactDOM.render(<svg arabicForm="foo" />, container);
520 + expect(node.getAttribute('arabic-form')).toBe('foo');
521 + expect(node.hasAttribute('arabicForm')).toBe(false);
522 + // Test attribute removal by setting to undefined.
523 + ReactDOM.render(<svg arabicForm={undefined} />, container);
524 + expect(node.hasAttribute('arabic-form')).toBe(false);
525 + expect(node.hasAttribute('arabicForm')).toBe(false);
526 + // Restore.
527 + ReactDOM.render(<svg arabicForm="foo" />, container);
528 + expect(node.getAttribute('arabic-form')).toBe('foo');
529 + expect(node.hasAttribute('arabicForm')).toBe(false);
530 + // Test attribute removal.
531 + ReactDOM.render(<svg />, container);
532 + expect(node.hasAttribute('arabic-form')).toBe(false);
533 + expect(node.hasAttribute('arabicForm')).toBe(false);
534 + });
535 +
536 it('should properly update custom attributes on custom elements', () => {
537 const container = document.createElement('div');
538 ReactDOM.render(<some-custom-element foo="bar" />, container);
@@ -451,6 +542,25 @@ describe('ReactDOMComponent', () => {
542 expect(node.getAttribute('bar')).toBe('buzz');
543 });
544
545 + it('should not apply React-specific aliases to custom elements', () => {
546 + var container = document.createElement('div');
547 + ReactDOM.render(<some-custom-element arabicForm="foo" />, container);
548 + var node = container.firstChild;
549 + // Should not get transformed to arabic-form as SVG would be.
550 + expect(node.getAttribute('arabicForm')).toBe('foo');
551 + expect(node.hasAttribute('arabic-form')).toBe(false);
552 + // Test attribute update.
553 + ReactDOM.render(<some-custom-element arabicForm="boo" />, container);
554 + expect(node.getAttribute('arabicForm')).toBe('boo');
555 + // Test attribute removal and addition.
556 + ReactDOM.render(<some-custom-element acceptCharset="buzz" />, container);
557 + // Verify the previous attribute was removed.
558 + expect(node.hasAttribute('arabicForm')).toBe(false);
559 + // Should not get transformed to accept-charset as HTML would be.
560 + expect(node.getAttribute('acceptCharset')).toBe('buzz');
561 + expect(node.hasAttribute('accept-charset')).toBe(false);
562 + });
563 +
564 it('should clear a single style prop when changing `style`', () => {
565 let styles = {display: 'none', color: 'red'};
566 const container = document.createElement('div');
packages/react-dom/src/__tests__/ReactDOMServerIntegrationAttributes-test.js
+56 -3
@@ -62,6 +62,16 @@ describe('ReactDOMServerIntegration', () => {
62 const e = await render(<div width={null} />);
63 expect(e.hasAttribute('width')).toBe(false);
64 });
65 +
66 + itRenders('no string prop with function value', async render => {
67 + const e = await render(<div width={function() {}} />, 1);
68 + expect(e.hasAttribute('width')).toBe(false);
69 + });
70 +
71 + itRenders('no string prop with symbol value', async render => {
72 + const e = await render(<div width={Symbol('foo')} />, 1);
73 + expect(e.hasAttribute('width')).toBe(false);
74 + });
75 });
76
77 describe('boolean properties', function() {
@@ -122,6 +132,16 @@ describe('ReactDOMServerIntegration', () => {
132 const e = await render(<div hidden={null} />);
133 expect(e.hasAttribute('hidden')).toBe(false);
134 });
135 +
136 + itRenders('no boolean prop with function value', async render => {
137 + const e = await render(<div hidden={function() {}} />, 1);
138 + expect(e.hasAttribute('hidden')).toBe(false);
139 + });
140 +
141 + itRenders('no boolean prop with symbol value', async render => {
142 + const e = await render(<div hidden={Symbol('foo')} />, 1);
143 + expect(e.hasAttribute('hidden')).toBe(false);
144 + });
145 });
146
147 describe('download property (combined boolean/string attribute)', function() {
@@ -164,6 +184,16 @@ describe('ReactDOMServerIntegration', () => {
184 const e = await render(<div download={undefined} />);
185 expect(e.hasAttribute('download')).toBe(false);
186 });
187 +
188 + itRenders('no download prop with function value', async render => {
189 + const e = await render(<div download={function() {}} />, 1);
190 + expect(e.hasAttribute('download')).toBe(false);
191 + });
192 +
193 + itRenders('no download prop with symbol value', async render => {
194 + const e = await render(<div download={Symbol('foo')} />, 1);
195 + expect(e.hasAttribute('download')).toBe(false);
196 + });
197 });
198
199 describe('className property', function() {
@@ -257,6 +287,11 @@ describe('ReactDOMServerIntegration', () => {
287 },
288 );
289
290 + itRenders('numeric property with zero value', async render => {
291 + const e = await render(<ol start={0} />);
292 + expect(e.getAttribute('start')).toBe('0');
293 + });
294 +
295 itRenders(
296 'no positive numeric property with zero value',
297 async render => {
@@ -265,9 +300,27 @@ describe('ReactDOMServerIntegration', () => {
300 },
301 );
302
268 - itRenders('numeric property with zero value', async render => {
269 - const e = await render(<ol start={0} />);
270 - expect(e.getAttribute('start')).toBe('0');
303 + itRenders('no numeric prop with function value', async render => {
304 + const e = await render(<ol start={function() {}} />, 1);
305 + expect(e.hasAttribute('start')).toBe(false);
306 + });
307 +
308 + itRenders('no numeric prop with symbol value', async render => {
309 + const e = await render(<ol start={Symbol('foo')} />, 1);
310 + expect(e.hasAttribute('start')).toBe(false);
311 + });
312 +
313 + itRenders(
314 + 'no positive numeric prop with function value',
315 + async render => {
316 + const e = await render(<input size={function() {}} />, 1);
317 + expect(e.hasAttribute('size')).toBe(false);
318 + },
319 + );
320 +
321 + itRenders('no positive numeric prop with symbol value', async render => {
322 + const e = await render(<input size={Symbol('foo')} />, 1);
323 + expect(e.hasAttribute('size')).toBe(false);
324 });
325 });
326
packages/react-dom/src/client/DOMPropertyOperations.js
+102 -136
@@ -3,95 +3,79 @@
3 *
4 * This source code is licensed under the MIT license found in the
5 * LICENSE file in the root directory of this source tree.
6 + *
7 + * @flow
8 */
9
10 import {
9 - ID_ATTRIBUTE_NAME,
10 - ROOT_ATTRIBUTE_NAME,
11 getPropertyInfo,
12 - shouldSetAttribute,
12 + shouldIgnoreAttribute,
13 + shouldRemoveAttribute,
14 isAttributeNameSafe,
15 + BOOLEAN,
16 + OVERLOADED_BOOLEAN,
17 } from '../shared/DOMProperty';
18
16 -// shouldIgnoreValue() is currently duplicated in DOMMarkupOperations.
17 -// TODO: Find a better place for this.
18 -function shouldIgnoreValue(propertyInfo, value) {
19 - return (
20 - value == null ||
21 - (propertyInfo.hasBooleanValue && !value) ||
22 - (propertyInfo.hasNumericValue && isNaN(value)) ||
23 - (propertyInfo.hasPositiveNumericValue && value < 1) ||
24 - (propertyInfo.hasOverloadedBooleanValue && value === false)
25 - );
26 -}
27 -
28 -/**
29 - * Operations for dealing with DOM properties.
30 - */
31 -
32 -export function setAttributeForID(node, id) {
33 - node.setAttribute(ID_ATTRIBUTE_NAME, id);
34 -}
35 -
36 -export function setAttributeForRoot(node) {
37 - node.setAttribute(ROOT_ATTRIBUTE_NAME, '');
38 -}
19 +import type {PropertyInfo} from '../shared/DOMProperty';
20
21 /**
22 * Get the value for a property on a node. Only used in DEV for SSR validation.
23 * The "expected" argument is used as a hint of what the expected value is.
24 * Some properties have multiple equivalent values.
25 */
45 -export function getValueForProperty(node, name, expected) {
26 +export function getValueForProperty(
27 + node: Element,
28 + name: string,
29 + expected: mixed,
30 + propertyInfo: PropertyInfo,
31 +): mixed {
32 if (__DEV__) {
47 - const propertyInfo = getPropertyInfo(name);
48 - if (propertyInfo) {
49 - if (propertyInfo.mustUseProperty) {
50 - return node[propertyInfo.propertyName];
51 - } else {
52 - const attributeName = propertyInfo.attributeName;
33 + if (propertyInfo.mustUseProperty) {
34 + const {propertyName} = propertyInfo;
35 + return (node: any)[propertyName];
36 + } else {
37 + const attributeName = propertyInfo.attributeName;
38
54 - let stringValue = null;
39 + let stringValue = null;
40
56 - if (propertyInfo.hasOverloadedBooleanValue) {
57 - if (node.hasAttribute(attributeName)) {
58 - const value = node.getAttribute(attributeName);
59 - if (value === '') {
60 - return true;
61 - }
62 - if (shouldIgnoreValue(propertyInfo, expected)) {
63 - return value;
64 - }
65 - if (value === '' + expected) {
66 - return expected;
67 - }
68 - return value;
41 + if (propertyInfo.type === OVERLOADED_BOOLEAN) {
42 + if (node.hasAttribute(attributeName)) {
43 + const value = node.getAttribute(attributeName);
44 + if (value === '') {
45 + return true;
46 }
70 - } else if (node.hasAttribute(attributeName)) {
71 - if (shouldIgnoreValue(propertyInfo, expected)) {
72 - // We had an attribute but shouldn't have had one, so read it
73 - // for the error message.
74 - return node.getAttribute(attributeName);
47 + if (shouldRemoveAttribute(name, expected, propertyInfo, false)) {
48 + return value;
49 }
76 - if (propertyInfo.hasBooleanValue) {
77 - // If this was a boolean, it doesn't matter what the value is
78 - // the fact that we have it is the same as the expected.
50 + if (value === '' + (expected: any)) {
51 return expected;
52 }
81 - // Even if this property uses a namespace we use getAttribute
82 - // because we assume its namespaced name is the same as our config.
83 - // To use getAttributeNS we need the local name which we don't have
84 - // in our config atm.
85 - stringValue = node.getAttribute(attributeName);
53 + return value;
54 }
87 -
88 - if (shouldIgnoreValue(propertyInfo, expected)) {
89 - return stringValue === null ? expected : stringValue;
90 - } else if (stringValue === '' + expected) {
55 + } else if (node.hasAttribute(attributeName)) {
56 + if (shouldRemoveAttribute(name, expected, propertyInfo, false)) {
57 + // We had an attribute but shouldn't have had one, so read it
58 + // for the error message.
59 + return node.getAttribute(attributeName);
60 + }
61 + if (propertyInfo.type === BOOLEAN) {
62 + // If this was a boolean, it doesn't matter what the value is
63 + // the fact that we have it is the same as the expected.
64 return expected;
92 - } else {
93 - return stringValue;
65 }
66 + // Even if this property uses a namespace we use getAttribute
67 + // because we assume its namespaced name is the same as our config.
68 + // To use getAttributeNS we need the local name which we don't have
69 + // in our config atm.
70 + stringValue = node.getAttribute(attributeName);
71 + }
72 +
73 + if (shouldRemoveAttribute(name, expected, propertyInfo, false)) {
74 + return stringValue === null ? expected : stringValue;
75 + } else if (stringValue === '' + (expected: any)) {
76 + return expected;
77 + } else {
78 + return stringValue;
79 }
80 }
81 }
@@ -102,7 +86,11 @@ export function getValueForProperty(node, name, expected) {
86 * The third argument is used as a hint of what the expected value is. Some
87 * attributes have multiple equivalent values.
88 */
105 -export function getValueForAttribute(node, name, expected) {
89 +export function getValueForAttribute(
90 + node: Element,
91 + name: string,
92 + expected: mixed,
93 +): mixed {
94 if (__DEV__) {
95 if (!isAttributeNameSafe(name)) {
96 return;
@@ -111,7 +99,7 @@ export function getValueForAttribute(node, name, expected) {
99 return expected === undefined ? undefined : null;
100 }
101 const value = node.getAttribute(name);
114 - if (value === '' + expected) {
102 + if (value === '' + (expected: any)) {
103 return expected;
104 }
105 return value;
@@ -125,84 +113,62 @@ export function getValueForAttribute(node, name, expected) {
113 * @param {string} name
114 * @param {*} value
115 */
128 -export function setValueForProperty(node, name, value) {
116 +export function setValueForProperty(
117 + node: Element,
118 + name: string,
119 + value: mixed,
120 + isCustomComponentTag: boolean,
121 +) {
122 const propertyInfo = getPropertyInfo(name);
130 -
131 - if (propertyInfo && shouldSetAttribute(name, value)) {
132 - if (shouldIgnoreValue(propertyInfo, value)) {
133 - deleteValueForProperty(node, name);
134 - return;
135 - } else if (propertyInfo.mustUseProperty) {
136 - // Contrary to `setAttribute`, object properties are properly
137 - // `toString`ed by IE8/9.
138 - node[propertyInfo.propertyName] = value;
139 - } else {
140 - const attributeName = propertyInfo.attributeName;
141 - const namespace = propertyInfo.attributeNamespace;
142 - // `setAttribute` with objects becomes only `[object]` in IE8/9,
143 - // ('' + value) makes it output the correct toString()-value.
144 - if (namespace) {
145 - node.setAttributeNS(namespace, attributeName, '' + value);
146 - } else if (
147 - propertyInfo.hasBooleanValue ||
148 - (propertyInfo.hasOverloadedBooleanValue && value === true)
149 - ) {
150 - node.setAttribute(attributeName, '');
123 + if (shouldIgnoreAttribute(name, propertyInfo, isCustomComponentTag)) {
124 + return;
125 + }
126 + if (shouldRemoveAttribute(name, value, propertyInfo, isCustomComponentTag)) {
127 + value = null;
128 + }
129 + // If the prop isn't in the special list, treat it as a simple attribute.
130 + if (isCustomComponentTag || propertyInfo === null) {
131 + if (isAttributeNameSafe(name)) {
132 + const attributeName = name;
133 + if (value === null) {
134 + node.removeAttribute(attributeName);
135 } else {
152 - node.setAttribute(attributeName, '' + value);
136 + node.setAttribute(attributeName, '' + (value: any));
137 }
138 }
155 - } else {
156 - setValueForAttribute(
157 - node,
158 - name,
159 - shouldSetAttribute(name, value) ? value : null,
160 - );
139 return;
140 }
163 -}
164 -
165 -export function setValueForAttribute(node, name, value) {
166 - if (!isAttributeNameSafe(name)) {
141 + const {mustUseProperty} = propertyInfo;
142 + if (mustUseProperty) {
143 + const {propertyName} = propertyInfo;
144 + if (value === null) {
145 + const {type} = propertyInfo;
146 + (node: any)[propertyName] = type === BOOLEAN ? false : '';
147 + } else {
148 + // Contrary to `setAttribute`, object properties are properly
149 + // `toString`ed by IE8/9.
150 + (node: any)[propertyName] = value;
151 + }
152 return;
153 }
169 - if (value == null) {
170 - node.removeAttribute(name);
154 + // The rest are treated as attributes with special cases.
155 + const {attributeName, attributeNamespace} = propertyInfo;
156 + if (value === null) {
157 + node.removeAttribute(attributeName);
158 } else {
172 - node.setAttribute(name, '' + value);
173 - }
174 -}
175 -
176 -/**
177 - * Deletes an attributes from a node.
178 - *
179 - * @param {DOMElement} node
180 - * @param {string} name
181 - */
182 -export function deleteValueForAttribute(node, name) {
183 - node.removeAttribute(name);
184 -}
185 -
186 -/**
187 - * Deletes the value for a property on a node.
188 - *
189 - * @param {DOMElement} node
190 - * @param {string} name
191 - */
192 -export function deleteValueForProperty(node, name) {
193 - const propertyInfo = getPropertyInfo(name);
194 - if (propertyInfo) {
195 - if (propertyInfo.mustUseProperty) {
196 - const propName = propertyInfo.propertyName;
197 - if (propertyInfo.hasBooleanValue) {
198 - node[propName] = false;
199 - } else {
200 - node[propName] = '';
201 - }
159 + const {type} = propertyInfo;
160 + let attributeValue;
161 + if (type === BOOLEAN || (type === OVERLOADED_BOOLEAN && value === true)) {
162 + attributeValue = '';
163 } else {
203 - node.removeAttribute(propertyInfo.attributeName);
164 + // `setAttribute` with objects becomes only `[object]` in IE8/9,
165 + // ('' + value) makes it output the correct toString()-value.
166 + attributeValue = '' + (value: any);
167 + }
168 + if (attributeNamespace) {
169 + node.setAttributeNS(attributeNamespace, attributeName, attributeValue);
170 + } else {
171 + node.setAttribute(attributeName, attributeValue);
172 }
205 - } else {
206 - node.removeAttribute(name);
173 }
174 }
packages/react-dom/src/client/ReactDOMFiberComponent.js
+34 -27
@@ -24,7 +24,11 @@ import setTextContent from './setTextContent';
24 import {listenTo, trapBubbledEvent} from '../events/ReactBrowserEventEmitter';
25 import * as CSSPropertyOperations from '../shared/CSSPropertyOperations';
26 import {Namespaces, getIntrinsicNamespace} from '../shared/DOMNamespaces';
27 -import {getPropertyInfo, shouldSetAttribute} from '../shared/DOMProperty';
27 +import {
28 + getPropertyInfo,
29 + shouldIgnoreAttribute,
30 + shouldRemoveAttribute,
31 +} from '../shared/DOMProperty';
32 import assertValidProps from '../shared/assertValidProps';
33 import {DOCUMENT_NODE, DOCUMENT_FRAGMENT_NODE} from '../shared/HTMLNodeType';
34 import isCustomComponent from '../shared/isCustomComponent';
@@ -314,13 +318,13 @@ function setInitialDOMProperties(
318 }
319 ensureListeningTo(rootContainerElement, propKey);
320 }
317 - } else if (isCustomComponentTag) {
318 - DOMPropertyOperations.setValueForAttribute(domElement, propKey, nextProp);
321 } else if (nextProp != null) {
320 - // If we're updating to null or undefined, we should remove the property
321 - // from the DOM node instead of inadvertently setting to a string. This
322 - // brings us in line with the same behavior we have on initial render.
323 - DOMPropertyOperations.setValueForProperty(domElement, propKey, nextProp);
322 + DOMPropertyOperations.setValueForProperty(
323 + domElement,
324 + propKey,
325 + nextProp,
326 + isCustomComponentTag,
327 + );
328 }
329 }
330 }
@@ -341,23 +345,13 @@ function updateDOMProperties(
345 setInnerHTML(domElement, propValue);
346 } else if (propKey === CHILDREN) {
347 setTextContent(domElement, propValue);
344 - } else if (isCustomComponentTag) {
345 - if (propValue != null) {
346 - DOMPropertyOperations.setValueForAttribute(
347 - domElement,
348 - propKey,
349 - propValue,
350 - );
351 - } else {
352 - DOMPropertyOperations.deleteValueForAttribute(domElement, propKey);
353 - }
354 - } else if (propValue != null) {
355 - DOMPropertyOperations.setValueForProperty(domElement, propKey, propValue);
348 } else {
357 - // If we're updating to null or undefined, we should remove the property
358 - // from the DOM node instead of inadvertently setting to a string. This
359 - // brings us in line with the same behavior we have on initial render.
360 - DOMPropertyOperations.deleteValueForProperty(domElement, propKey);
349 + DOMPropertyOperations.setValueForProperty(
350 + domElement,
351 + propKey,
352 + propValue,
353 + isCustomComponentTag,
354 + );
355 }
356 }
357 }
@@ -965,10 +959,14 @@ export function diffHydratedProperties(
959 }
960 ensureListeningTo(rootContainerElement, propKey);
961 }
968 - } else if (__DEV__) {
962 + } else if (
963 + __DEV__ &&
964 + // Convince Flow we've calculated it (it's DEV-only in this method.)
965 + typeof isCustomComponentTag === 'boolean'
966 + ) {
967 // Validate that the properties correspond to their expected values.
968 let serverValue;
971 - let propertyInfo;
969 + const propertyInfo = getPropertyInfo(propKey);
970 if (suppressHydrationWarning) {
971 // Don't bother comparing. We're ignoring all these warnings.
972 } else if (
@@ -1010,14 +1008,23 @@ export function diffHydratedProperties(
1008 if (nextProp !== serverValue) {
1009 warnForPropDifference(propKey, serverValue, nextProp);
1010 }
1013 - } else if (shouldSetAttribute(propKey, nextProp)) {
1014 - if ((propertyInfo = getPropertyInfo(propKey))) {
1011 + } else if (
1012 + !shouldIgnoreAttribute(propKey, propertyInfo, isCustomComponentTag) &&
1013 + !shouldRemoveAttribute(
1014 + propKey,
1015 + nextProp,
1016 + propertyInfo,
1017 + isCustomComponentTag,
1018 + )
1019 + ) {
1020 + if (propertyInfo !== null) {
1021 // $FlowFixMe - Should be inferred as not undefined.
1022 extraAttributeNames.delete(propertyInfo.attributeName);
1023 serverValue = DOMPropertyOperations.getValueForProperty(
1024 domElement,
1025 propKey,
1026 nextProp,
1027 + propertyInfo,
1028 );
1029 } else {
1030 let ownNamespace = parentNamespace;
packages/react-dom/src/client/ReactDOMFiberInput.js
+1 -1
@@ -133,7 +133,7 @@ export function updateChecked(element: Element, props: Object) {
133 const node = ((element: any): InputWithWrapperState);
134 const checked = props.checked;
135 if (checked != null) {
136 - DOMPropertyOperations.setValueForProperty(node, 'checked', checked);
136 + DOMPropertyOperations.setValueForProperty(node, 'checked', checked, false);
137 }
138 }
139
packages/react-dom/src/server/DOMMarkupOperations.js
+24 -35
@@ -3,30 +3,22 @@
3 *
4 * This source code is licensed under the MIT license found in the
5 * LICENSE file in the root directory of this source tree.
6 + *
7 + * @flow
8 */
9
10 import {
11 ID_ATTRIBUTE_NAME,
12 ROOT_ATTRIBUTE_NAME,
13 + BOOLEAN,
14 + OVERLOADED_BOOLEAN,
15 getPropertyInfo,
12 - shouldAttributeAcceptBooleanValue,
13 - shouldSetAttribute,
16 isAttributeNameSafe,
17 + shouldIgnoreAttribute,
18 + shouldRemoveAttribute,
19 } from '../shared/DOMProperty';
20 import quoteAttributeValueForBrowser from './quoteAttributeValueForBrowser';
21
18 -// shouldIgnoreValue() is currently duplicated in DOMPropertyOperations.
19 -// TODO: Find a better place for this.
20 -function shouldIgnoreValue(propertyInfo, value) {
21 - return (
22 - value == null ||
23 - (propertyInfo.hasBooleanValue && !value) ||
24 - (propertyInfo.hasNumericValue && isNaN(value)) ||
25 - (propertyInfo.hasPositiveNumericValue && value < 1) ||
26 - (propertyInfo.hasOverloadedBooleanValue && value === false)
27 - );
28 -}
29 -
22 /**
23 * Operations for dealing with DOM properties.
24 */
@@ -37,11 +29,11 @@ function shouldIgnoreValue(propertyInfo, value) {
29 * @param {string} id Unescaped ID.
30 * @return {string} Markup string.
31 */
40 -export function createMarkupForID(id) {
32 +export function createMarkupForID(id: string): string {
33 return ID_ATTRIBUTE_NAME + '=' + quoteAttributeValueForBrowser(id);
34 }
35
44 -export function createMarkupForRoot() {
36 +export function createMarkupForRoot(): string {
37 return ROOT_ATTRIBUTE_NAME + '=""';
38 }
39
@@ -52,31 +44,25 @@ export function createMarkupForRoot() {
44 * @param {*} value
45 * @return {?string} Markup string, or null if the property was invalid.
46 */
55 -export function createMarkupForProperty(name, value) {
47 +export function createMarkupForProperty(name: string, value: mixed): string {
48 const propertyInfo = getPropertyInfo(name);
57 - if (propertyInfo) {
58 - if (shouldIgnoreValue(propertyInfo, value)) {
59 - return '';
60 - }
49 + if (name !== 'style' && shouldIgnoreAttribute(name, propertyInfo, false)) {
50 + return '';
51 + }
52 + if (shouldRemoveAttribute(name, value, propertyInfo, false)) {
53 + return '';
54 + }
55 + if (propertyInfo !== null) {
56 const attributeName = propertyInfo.attributeName;
62 - if (
63 - propertyInfo.hasBooleanValue ||
64 - (propertyInfo.hasOverloadedBooleanValue && value === true)
65 - ) {
57 + const {type} = propertyInfo;
58 + if (type === BOOLEAN || (type === OVERLOADED_BOOLEAN && value === true)) {
59 return attributeName + '=""';
67 - } else if (
68 - typeof value !== 'boolean' ||
69 - shouldAttributeAcceptBooleanValue(name)
70 - ) {
60 + } else {
61 return attributeName + '=' + quoteAttributeValueForBrowser(value);
62 }
73 - } else if (shouldSetAttribute(name, value)) {
74 - if (value == null) {
75 - return '';
76 - }
63 + } else {
64 return name + '=' + quoteAttributeValueForBrowser(value);
65 }
79 - return null;
66 }
67
68 /**
@@ -86,7 +72,10 @@ export function createMarkupForProperty(name, value) {
72 * @param {*} value
73 * @return {string} Markup string, or empty string if the property was invalid.
74 */
89 -export function createMarkupForCustomAttribute(name, value) {
75 +export function createMarkupForCustomAttribute(
76 + name: string,
77 + value: mixed,
78 +): string {
79 if (!isAttributeNameSafe(name) || value == null) {
80 return '';
81 }
packages/react-dom/src/shared/DOMProperty.js
+336 -286
@@ -3,104 +3,55 @@
3 *
4 * This source code is licensed under the MIT license found in the
5 * LICENSE file in the root directory of this source tree.
6 + *
7 + * @flow
8 */
9
10 import warning from 'fbjs/lib/warning';
11
10 -// These attributes should be all lowercase to allow for
11 -// case insensitive checks
12 -const RESERVED_PROPS = {
13 - children: true,
14 - dangerouslySetInnerHTML: true,
15 - // TODO: This prevents the assignment of defaultValue to regular
16 - // elements (not just inputs). Now that ReactDOMInput assigns to the
17 - // defaultValue property -- do we need this?
18 - defaultValue: true,
19 - defaultChecked: true,
20 - innerHTML: true,
21 - suppressContentEditableWarning: true,
22 - suppressHydrationWarning: true,
23 - style: true,
24 -};
25 -
26 -function checkMask(value, bitmask) {
27 - return (value & bitmask) === bitmask;
28 -}
12 +type PropertyType = 0 | 1 | 2 | 3 | 4 | 5 | 6;
13
30 -const MUST_USE_PROPERTY = 0x1;
31 -const HAS_BOOLEAN_VALUE = 0x4;
32 -const HAS_NUMERIC_VALUE = 0x8;
33 -const HAS_POSITIVE_NUMERIC_VALUE = 0x10 | 0x8;
34 -const HAS_OVERLOADED_BOOLEAN_VALUE = 0x20;
35 -const HAS_STRING_BOOLEAN_VALUE = 0x40;
36 -
37 -function injectDOMPropertyConfig(domPropertyConfig) {
38 - const Properties = domPropertyConfig.Properties || {};
39 - const DOMAttributeNamespaces = domPropertyConfig.DOMAttributeNamespaces || {};
40 - const DOMAttributeNames = domPropertyConfig.DOMAttributeNames || {};
41 -
42 - for (const propName in Properties) {
43 - if (__DEV__) {
44 - warning(
45 - !properties.hasOwnProperty(propName),
46 - "injectDOMPropertyConfig(...): You're trying to inject DOM property " +
47 - "'%s' which has already been injected. You may be accidentally " +
48 - 'injecting the same DOM property config twice, or you may be ' +
49 - 'injecting two configs that have conflicting property names.',
50 - propName,
51 - );
52 - }
14 +// A reserved attribute.
15 +// It is handled by React separately and shouldn't be written to the DOM.
16 +export const RESERVED = 0;
17
54 - const lowerCased = propName.toLowerCase();
55 - const propConfig = Properties[propName];
56 -
57 - const propertyInfo = {
58 - attributeName: lowerCased,
59 - attributeNamespace: null,
60 - propertyName: propName,
61 -
62 - mustUseProperty: checkMask(propConfig, MUST_USE_PROPERTY),
63 - hasBooleanValue: checkMask(propConfig, HAS_BOOLEAN_VALUE),
64 - hasNumericValue: checkMask(propConfig, HAS_NUMERIC_VALUE),
65 - hasPositiveNumericValue: checkMask(
66 - propConfig,
67 - HAS_POSITIVE_NUMERIC_VALUE,
68 - ),
69 - hasOverloadedBooleanValue: checkMask(
70 - propConfig,
71 - HAS_OVERLOADED_BOOLEAN_VALUE,
72 - ),
73 - hasStringBooleanValue: checkMask(propConfig, HAS_STRING_BOOLEAN_VALUE),
74 - };
75 - if (__DEV__) {
76 - warning(
77 - propertyInfo.hasBooleanValue +
78 - propertyInfo.hasNumericValue +
79 - propertyInfo.hasOverloadedBooleanValue <=
80 - 1,
81 - 'DOMProperty: Value can be one of boolean, overloaded boolean, or ' +
82 - 'numeric value, but not a combination: %s',
83 - propName,
84 - );
85 - }
18 +// A simple string attribute.
19 +// Attributes that aren't in the whitelist are presumed to have this type.
20 +export const STRING = 1;
21
87 - if (DOMAttributeNames.hasOwnProperty(propName)) {
88 - const attributeName = DOMAttributeNames[propName];
22 +// A string attribute that accepts booleans in React. In HTML, these are called
23 +// "enumerated" attributes with "true" and "false" as possible values.
24 +// When true, it should be set to a "true" string.
25 +// When false, it should be set to a "false" string.
26 +export const BOOLEANISH_STRING = 2;
27
90 - propertyInfo.attributeName = attributeName;
91 - }
28 +// A real boolean attribute.
29 +// When true, it should be present (set either to an empty string or its name).
30 +// When false, it should be omitted.
31 +export const BOOLEAN = 3;
32
93 - if (DOMAttributeNamespaces.hasOwnProperty(propName)) {
94 - propertyInfo.attributeNamespace = DOMAttributeNamespaces[propName];
95 - }
33 +// An attribute that can be used as a flag as well as with a value.
34 +// When true, it should be present (set either to an empty string or its name).
35 +// When false, it should be omitted.
36 +// For any other value, should be present with that value.
37 +export const OVERLOADED_BOOLEAN = 4;
38
97 - // Downcase references to whitelist properties to check for membership
98 - // without case-sensitivity. This allows the whitelist to pick up
99 - // `allowfullscreen`, which should be written using the property configuration
100 - // for `allowFullscreen`
101 - properties[propName] = propertyInfo;
102 - }
103 -}
39 +// An attribute that must be numeric or parse as a numeric.
40 +// When falsy, it should be removed.
41 +export const NUMERIC = 5;
42 +
43 +// An attribute that must be positive numeric or parse as a positive numeric.
44 +// When falsy, it should be removed.
45 +export const POSITIVE_NUMERIC = 6;
46 +
47 +export type PropertyInfo = {|
48 + +acceptsBooleans: boolean,
49 + +attributeName: string,
50 + +attributeNamespace: string | null,
51 + +mustUseProperty: boolean,
52 + +propertyName: string,
53 + +type: PropertyType,
54 +|};
55
56 /* eslint-disable max-len */
57 export const ATTRIBUTE_NAME_START_CHAR =
@@ -118,7 +69,7 @@ export const VALID_ATTRIBUTE_NAME_REGEX = new RegExp(
69 const illegalAttributeNameCache = {};
70 const validatedAttributeNameCache = {};
71
121 -export function isAttributeNameSafe(attributeName) {
72 +export function isAttributeNameSafe(attributeName: string): boolean {
73 if (validatedAttributeNameCache.hasOwnProperty(attributeName)) {
74 return true;
75 }
@@ -136,39 +87,15 @@ export function isAttributeNameSafe(attributeName) {
87 return false;
88 }
89
139 -/**
140 - * Map from property "standard name" to an object with info about how to set
141 - * the property in the DOM. Each object contains:
142 - *
143 - * attributeName:
144 - * Used when rendering markup or with `*Attribute()`.
145 - * attributeNamespace
146 - * propertyName:
147 - * Used on DOM node instances. (This includes properties that mutate due to
148 - * external factors.)
149 - * mustUseProperty:
150 - * Whether the property must be accessed and mutated as an object property.
151 - * hasBooleanValue:
152 - * Whether the property should be removed when set to a falsey value.
153 - * hasNumericValue:
154 - * Whether the property must be numeric or parse as a numeric and should be
155 - * removed when set to a falsey value.
156 - * hasPositiveNumericValue:
157 - * Whether the property must be positive numeric or parse as a positive
158 - * numeric and should be removed when set to a falsey value.
159 - * hasOverloadedBooleanValue:
160 - * Whether the property can be used as a flag as well as with a value.
161 - * Removed when strictly equal to false; present without a value when
162 - * strictly equal to true; present with a value otherwise.
163 - */
164 -export const properties = {};
165 -
166 -/**
167 - * Checks whether a property name is a writeable attribute.
168 - * @method
169 - */
170 -export function shouldSetAttribute(name, value) {
171 - if (isReservedProp(name)) {
90 +export function shouldIgnoreAttribute(
91 + name: string,
92 + propertyInfo: PropertyInfo | null,
93 + isCustomComponentTag: boolean,
94 +): boolean {
95 + if (propertyInfo !== null) {
96 + return propertyInfo.type === RESERVED;
97 + }
98 + if (isCustomComponentTag) {
99 return false;
100 }
101 if (
@@ -176,147 +103,266 @@ export function shouldSetAttribute(name, value) {
103 (name[0] === 'o' || name[0] === 'O') &&
104 (name[1] === 'n' || name[1] === 'N')
105 ) {
179 - return false;
180 - }
181 - if (value === null) {
106 return true;
107 }
108 + return false;
109 +}
110 +
111 +export function shouldRemoveAttributeWithWarning(
112 + name: string,
113 + value: mixed,
114 + propertyInfo: PropertyInfo | null,
115 + isCustomComponentTag: boolean,
116 +): boolean {
117 + if (propertyInfo !== null && propertyInfo.type === RESERVED) {
118 + return false;
119 + }
120 switch (typeof value) {
185 - case 'boolean':
186 - return shouldAttributeAcceptBooleanValue(name);
187 - case 'undefined':
188 - case 'number':
189 - case 'string':
190 - case 'object':
121 + case 'function':
122 + // $FlowIssue symbol is perfectly valid here
123 + case 'symbol': // eslint-disable-line
124 return true;
125 + case 'boolean': {
126 + if (isCustomComponentTag) {
127 + return false;
128 + }
129 + if (propertyInfo !== null) {
130 + return !propertyInfo.acceptsBooleans;
131 + } else {
132 + const prefix = name.toLowerCase().slice(0, 5);
133 + return prefix !== 'data-' && prefix !== 'aria-';
134 + }
135 + }
136 default:
193 - // function, symbol
137 return false;
138 }
139 }
140
198 -export function getPropertyInfo(name) {
199 - return properties.hasOwnProperty(name) ? properties[name] : null;
200 -}
201 -
202 -export function shouldAttributeAcceptBooleanValue(name) {
203 - if (isReservedProp(name)) {
141 +export function shouldRemoveAttribute(
142 + name: string,
143 + value: mixed,
144 + propertyInfo: PropertyInfo | null,
145 + isCustomComponentTag: boolean,
146 +): boolean {
147 + if (value === null || typeof value === 'undefined') {
148 return true;
149 }
206 - let propertyInfo = getPropertyInfo(name);
207 - if (propertyInfo) {
208 - return (
209 - propertyInfo.hasBooleanValue ||
210 - propertyInfo.hasStringBooleanValue ||
211 - propertyInfo.hasOverloadedBooleanValue
212 - );
150 + if (
151 + shouldRemoveAttributeWithWarning(
152 + name,
153 + value,
154 + propertyInfo,
155 + isCustomComponentTag,
156 + )
157 + ) {
158 + return true;
159 + }
160 + if (propertyInfo !== null) {
161 + switch (propertyInfo.type) {
162 + case BOOLEAN:
163 + return !value;
164 + case OVERLOADED_BOOLEAN:
165 + return value === false;
166 + case NUMERIC:
167 + return isNaN(value);
168 + case POSITIVE_NUMERIC:
169 + return isNaN(value) || (value: any) < 1;
170 + }
171 }
214 - const prefix = name.toLowerCase().slice(0, 5);
215 - return prefix === 'data-' || prefix === 'aria-';
172 + return false;
173 }
174
218 -/**
219 - * Checks to see if a property name is within the list of properties
220 - * reserved for internal React operations. These properties should
221 - * not be set on an HTML element.
222 - *
223 - * @private
224 - * @param {string} name
225 - * @return {boolean} If the name is within reserved props
226 - */
227 -export function isReservedProp(name) {
228 - return RESERVED_PROPS.hasOwnProperty(name);
175 +export function getPropertyInfo(name: string): PropertyInfo | null {
176 + return properties.hasOwnProperty(name) ? properties[name] : null;
177 }
178
231 -const HTMLDOMPropertyConfig = {
232 - // When adding attributes to this list, be sure to also add them to
233 - // the `possibleStandardNames` module to ensure casing and incorrect
234 - // name warnings.
235 - Properties: {
236 - allowFullScreen: HAS_BOOLEAN_VALUE,
237 - // specifies target context for links with `preload` type
238 - async: HAS_BOOLEAN_VALUE,
239 - // Note: there is a special case that prevents it from being written to the DOM
240 - // on the client side because the browsers are inconsistent. Instead we call focus().
241 - autoFocus: HAS_BOOLEAN_VALUE,
242 - autoPlay: HAS_BOOLEAN_VALUE,
243 - capture: HAS_OVERLOADED_BOOLEAN_VALUE,
244 - checked: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE,
245 - cols: HAS_POSITIVE_NUMERIC_VALUE,
246 - contentEditable: HAS_STRING_BOOLEAN_VALUE,
247 - controls: HAS_BOOLEAN_VALUE,
248 - default: HAS_BOOLEAN_VALUE,
249 - defer: HAS_BOOLEAN_VALUE,
250 - disabled: HAS_BOOLEAN_VALUE,
251 - download: HAS_OVERLOADED_BOOLEAN_VALUE,
252 - draggable: HAS_STRING_BOOLEAN_VALUE,
253 - formNoValidate: HAS_BOOLEAN_VALUE,
254 - hidden: HAS_BOOLEAN_VALUE,
255 - loop: HAS_BOOLEAN_VALUE,
256 - // Caution; `option.selected` is not updated if `select.multiple` is
257 - // disabled with `removeAttribute`.
258 - multiple: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE,
259 - muted: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE,
260 - noValidate: HAS_BOOLEAN_VALUE,
261 - open: HAS_BOOLEAN_VALUE,
262 - playsInline: HAS_BOOLEAN_VALUE,
263 - readOnly: HAS_BOOLEAN_VALUE,
264 - required: HAS_BOOLEAN_VALUE,
265 - reversed: HAS_BOOLEAN_VALUE,
266 - rows: HAS_POSITIVE_NUMERIC_VALUE,
267 - rowSpan: HAS_NUMERIC_VALUE,
268 - scoped: HAS_BOOLEAN_VALUE,
269 - seamless: HAS_BOOLEAN_VALUE,
270 - selected: MUST_USE_PROPERTY | HAS_BOOLEAN_VALUE,
271 - size: HAS_POSITIVE_NUMERIC_VALUE,
272 - start: HAS_NUMERIC_VALUE,
273 - // support for projecting regular DOM Elements via V1 named slots ( shadow dom )
274 - span: HAS_POSITIVE_NUMERIC_VALUE,
275 - spellCheck: HAS_STRING_BOOLEAN_VALUE,
276 - // Style must be explicitly set in the attribute list. React components
277 - // expect a style object
278 - style: 0,
279 - // Keep it in the whitelist because it is case-sensitive for SVG.
280 - tabIndex: 0,
281 - // itemScope is for for Microdata support.
282 - // See http://schema.org/docs/gs.html
283 - itemScope: HAS_BOOLEAN_VALUE,
284 - // These attributes must stay in the white-list because they have
285 - // different attribute names (see DOMAttributeNames below)
286 - acceptCharset: 0,
287 - className: 0,
288 - htmlFor: 0,
289 - httpEquiv: 0,
290 - // Set the string boolean flag to allow the behavior
291 - value: HAS_STRING_BOOLEAN_VALUE,
292 - },
293 - DOMAttributeNames: {
294 - acceptCharset: 'accept-charset',
295 - className: 'class',
296 - htmlFor: 'for',
297 - httpEquiv: 'http-equiv',
298 - },
299 -};
300 -
301 -const NS = {
302 - xlink: 'http://www.w3.org/1999/xlink',
303 - xml: 'http://www.w3.org/XML/1998/namespace',
304 -};
179 +function PropertyInfoRecord(
180 + name: string,
181 + type: PropertyType,
182 + mustUseProperty: boolean,
183 + attributeName: string,
184 + attributeNamespace: string | null,
185 +) {
186 + this.acceptsBooleans =
187 + type === BOOLEANISH_STRING ||
188 + type === BOOLEAN ||
189 + type === OVERLOADED_BOOLEAN;
190 + this.attributeName = attributeName;
191 + this.attributeNamespace = attributeNamespace;
192 + this.mustUseProperty = mustUseProperty;
193 + this.propertyName = name;
194 + this.type = type;
195 +}
196
306 -/**
307 - * This is a list of all SVG attributes that need special casing,
308 - * namespacing, or boolean value assignment.
309 - *
310 - * When adding attributes to this list, be sure to also add them to
311 - * the `possibleStandardNames` module to ensure casing and incorrect
312 - * name warnings.
313 - *
314 - * SVG Attributes List:
315 - * https://www.w3.org/TR/SVG/attindex.html
316 - * SMIL Spec:
317 - * https://www.w3.org/TR/smil
318 - */
319 -const SVG_ATTRS = [
197 +// When adding attributes to this list, be sure to also add them to
198 +// the `possibleStandardNames` module to ensure casing and incorrect
199 +// name warnings.
200 +const properties = {};
201 +
202 +// These props are reserved by React. They shouldn't be written to the DOM.
203 +[
204 + 'children',
205 + 'dangerouslySetInnerHTML',
206 + // TODO: This prevents the assignment of defaultValue to regular
207 + // elements (not just inputs). Now that ReactDOMInput assigns to the
208 + // defaultValue property -- do we need this?
209 + 'defaultValue',
210 + 'defaultChecked',
211 + 'innerHTML',
212 + 'suppressContentEditableWarning',
213 + 'suppressHydrationWarning',
214 + 'style',
215 +].forEach(name => {
216 + properties[name] = new PropertyInfoRecord(
217 + name,
218 + RESERVED,
219 + false, // mustUseProperty
220 + name, // attributeName
221 + null, // attributeNamespace
222 + );
223 +});
224 +
225 +// A few React string attributes have a different name.
226 +// This is a mapping from React prop names to the attribute names.
227 +new Map([
228 + ['acceptCharset', 'accept-charset'],
229 + ['className', 'class'],
230 + ['htmlFor', 'for'],
231 + ['httpEquiv', 'http-equiv'],
232 +]).forEach((attributeName, name) => {
233 + properties[name] = new PropertyInfoRecord(
234 + name,
235 + STRING,
236 + false, // mustUseProperty
237 + attributeName, // attributeName
238 + null, // attributeNamespace
239 + );
240 +});
241 +
242 +// These are "enumerated" HTML attributes that accept "true" and "false".
243 +// In React, we let users pass `true` and `false` even though technically
244 +// these aren't boolean attributes (they are coerced to strings).
245 +['contentEditable', 'draggable', 'spellCheck', 'value'].forEach(name => {
246 + properties[name] = new PropertyInfoRecord(
247 + name,
248 + BOOLEANISH_STRING,
249 + false, // mustUseProperty
250 + name.toLowerCase(), // attributeName
251 + null, // attributeNamespace
252 + );
253 +});
254 +
255 +// These are "enumerated" SVG attributes that accept "true" and "false".
256 +// In React, we let users pass `true` and `false` even though technically
257 +// these aren't boolean attributes (they are coerced to strings).
258 +// Since these are SVG attributes, their attribute names are case-sensitive.
259 +['autoReverse', 'externalResourcesRequired', 'preserveAlpha'].forEach(name => {
260 + properties[name] = new PropertyInfoRecord(
261 + name,
262 + BOOLEANISH_STRING,
263 + false, // mustUseProperty
264 + name, // attributeName
265 + null, // attributeNamespace
266 + );
267 +});
268 +
269 +// These are HTML boolean attributes.
270 +[
271 + 'allowFullScreen',
272 + 'async',
273 + // Note: there is a special case that prevents it from being written to the DOM
274 + // on the client side because the browsers are inconsistent. Instead we call focus().
275 + 'autoFocus',
276 + 'autoPlay',
277 + 'controls',
278 + 'default',
279 + 'defer',
280 + 'disabled',
281 + 'formNoValidate',
282 + 'hidden',
283 + 'loop',
284 + 'noValidate',
285 + 'open',
286 + 'playsInline',
287 + 'readOnly',
288 + 'required',
289 + 'reversed',
290 + 'scoped',
291 + 'seamless',
292 + // Microdata
293 + 'itemScope',
294 +].forEach(name => {
295 + properties[name] = new PropertyInfoRecord(
296 + name,
297 + BOOLEAN,
298 + false, // mustUseProperty
299 + name.toLowerCase(), // attributeName
300 + null, // attributeNamespace
301 + );
302 +});
303 +
304 +// These are the few React props that we set as DOM properties
305 +// rather than attributes. These are all booleans.
306 +[
307 + 'checked',
308 + // Note: `option.selected` is not updated if `select.multiple` is
309 + // disabled with `removeAttribute`. We have special logic for handling this.
310 + 'multiple',
311 + 'muted',
312 + 'selected',
313 +].forEach(name => {
314 + properties[name] = new PropertyInfoRecord(
315 + name,
316 + BOOLEAN,
317 + true, // mustUseProperty
318 + name.toLowerCase(), // attributeName
319 + null, // attributeNamespace
320 + );
321 +});
322 +
323 +// These are HTML attributes that are "overloaded booleans": they behave like
324 +// booleans, but can also accept a string value.
325 +['capture', 'download'].forEach(name => {
326 + properties[name] = new PropertyInfoRecord(
327 + name,
328 + OVERLOADED_BOOLEAN,
329 + false, // mustUseProperty
330 + name.toLowerCase(), // attributeName
331 + null, // attributeNamespace
332 + );
333 +});
334 +
335 +// These are HTML attributes that must be positive numbers.
336 +['cols', 'rows', 'size', 'span'].forEach(name => {
337 + properties[name] = new PropertyInfoRecord(
338 + name,
339 + POSITIVE_NUMERIC,
340 + false, // mustUseProperty
341 + name.toLowerCase(), // attributeName
342 + null, // attributeNamespace
343 + );
344 +});
345 +
346 +// These are HTML attributes that must be numbers.
347 +['rowSpan', 'start'].forEach(name => {
348 + properties[name] = new PropertyInfoRecord(
349 + name,
350 + NUMERIC,
351 + false, // mustUseProperty
352 + name.toLowerCase(), // attributeName
353 + null, // attributeNamespace
354 + );
355 +});
356 +
357 +const CAMELIZE = /[\-\:]([a-z])/g;
358 +const capitalize = token => token[1].toUpperCase();
359 +
360 +// This is a list of all SVG attributes that need special casing, namespacing,
361 +// or boolean value assignment. Regular attributes that just accept strings
362 +// and have the same names are omitted, just like in the HTML whitelist.
363 +// Some of these attributes can be hard to find. This list was created by
364 +// scrapping the MDN documentation.
365 +[
366 'accent-height',
367 'alignment-baseline',
368 'arabic-form',
@@ -388,7 +434,21 @@ const SVG_ATTRS = [
434 'vert-origin-y',
435 'word-spacing',
436 'writing-mode',
437 + 'xmlns:xlink',
438 'x-height',
439 +].forEach(attributeName => {
440 + const name = attributeName.replace(CAMELIZE, capitalize);
441 + properties[name] = new PropertyInfoRecord(
442 + name,
443 + STRING,
444 + false, // mustUseProperty
445 + attributeName,
446 + null, // attributeNamespace
447 + );
448 +});
449 +
450 +// String SVG attributes with the xlink namespace.
451 +[
452 'xlink:actuate',
453 'xlink:arcrole',
454 'xlink:href',
@@ -396,46 +456,36 @@ const SVG_ATTRS = [
456 'xlink:show',
457 'xlink:title',
458 'xlink:type',
399 - 'xml:base',
400 - 'xmlns:xlink',
401 - 'xml:lang',
402 - 'xml:space',
403 -];
404 -
405 -const SVGDOMPropertyConfig = {
406 - Properties: {
407 - autoReverse: HAS_STRING_BOOLEAN_VALUE,
408 - externalResourcesRequired: HAS_STRING_BOOLEAN_VALUE,
409 - preserveAlpha: HAS_STRING_BOOLEAN_VALUE,
410 - },
411 - DOMAttributeNames: {
412 - autoReverse: 'autoReverse',
413 - externalResourcesRequired: 'externalResourcesRequired',
414 - preserveAlpha: 'preserveAlpha',
415 - },
416 - DOMAttributeNamespaces: {
417 - xlinkActuate: NS.xlink,
418 - xlinkArcrole: NS.xlink,
419 - xlinkHref: NS.xlink,
420 - xlinkRole: NS.xlink,
421 - xlinkShow: NS.xlink,
422 - xlinkTitle: NS.xlink,
423 - xlinkType: NS.xlink,
424 - xmlBase: NS.xml,
425 - xmlLang: NS.xml,
426 - xmlSpace: NS.xml,
427 - },
428 -};
429 -
430 -const CAMELIZE = /[\-\:]([a-z])/g;
431 -const capitalize = token => token[1].toUpperCase();
432 -
433 -SVG_ATTRS.forEach(original => {
434 - const reactName = original.replace(CAMELIZE, capitalize);
459 +].forEach(attributeName => {
460 + const name = attributeName.replace(CAMELIZE, capitalize);
461 + properties[name] = new PropertyInfoRecord(
462 + name,
463 + STRING,
464 + false, // mustUseProperty
465 + attributeName,
466 + 'http://www.w3.org/1999/xlink',
467 + );
468 +});
469
436 - SVGDOMPropertyConfig.Properties[reactName] = 0;
437 - SVGDOMPropertyConfig.DOMAttributeNames[reactName] = original;
470 +// String SVG attributes with the xml namespace.
471 +['xml:base', 'xml:lang', 'xml:space'].forEach(attributeName => {
472 + const name = attributeName.replace(CAMELIZE, capitalize);
473 + properties[name] = new PropertyInfoRecord(
474 + name,
475 + STRING,
476 + false, // mustUseProperty
477 + attributeName,
478 + 'http://www.w3.org/XML/1998/namespace',
479 + );
480 });
481
440 -injectDOMPropertyConfig(HTMLDOMPropertyConfig);
441 -injectDOMPropertyConfig(SVGDOMPropertyConfig);
482 +// Special case: this attribute exists both in HTML and SVG.
483 +// Its "tabindex" attribute name is case-sensitive in SVG so we can't just use
484 +// its React `tabIndex` name, like we do for attributes that exist only in HTML.
485 +properties.tabIndex = new PropertyInfoRecord(
486 + 'tabIndex',
487 + STRING,
488 + false, // mustUseProperty
489 + 'tabindex', // attributeName
490 + null, // attributeNamespace
491 +);
packages/react-dom/src/shared/ReactDOMUnknownPropertyHook.js
+7 -6
@@ -14,9 +14,9 @@ import warning from 'fbjs/lib/warning';
14
15 import {
16 ATTRIBUTE_NAME_CHAR,
17 - isReservedProp,
18 - shouldAttributeAcceptBooleanValue,
19 - shouldSetAttribute,
17 + RESERVED,
18 + shouldRemoveAttributeWithWarning,
19 + getPropertyInfo,
20 } from './DOMProperty';
21 import isCustomComponent from './isCustomComponent';
22 import possibleStandardNames from './possibleStandardNames';
@@ -155,7 +155,8 @@ if (__DEV__) {
155 return true;
156 }
157
158 - const isReserved = isReservedProp(name);
158 + const propertyInfo = getPropertyInfo(name);
159 + const isReserved = propertyInfo !== null && propertyInfo.type === RESERVED;
160
161 // Known attributes should match the casing specified in the property config.
162 if (possibleStandardNames.hasOwnProperty(lowerCasedName)) {
@@ -191,7 +192,7 @@ if (__DEV__) {
192
193 if (
194 typeof value === 'boolean' &&
194 - !shouldAttributeAcceptBooleanValue(name)
195 + shouldRemoveAttributeWithWarning(name, value, propertyInfo, false)
196 ) {
197 if (value) {
198 warning(
@@ -235,7 +236,7 @@ if (__DEV__) {
236 }
237
238 // Warn when a known attribute is a bad type
238 - if (!shouldSetAttribute(name, value)) {
239 + if (shouldRemoveAttributeWithWarning(name, value, propertyInfo, false)) {
240 warnedProperties[name] = true;
241 return false;
242 }