summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Atkins <atkinssj@serenityos.org>2021-11-10 13:43:52 +0000
committerAndreas Kling <kling@serenityos.org>2021-11-10 21:58:14 +0100
commit11f0ece58f28cd588119cf2264d0d6600498927e (patch)
treeb68a46afc8e6ecbdc5cd8bd5192a166dcc6a579b
parentca3b86c922b885e96789987534790c48b1cb2873 (diff)
downloadserenity-11f0ece58f28cd588119cf2264d0d6600498927e.zip
LibWeb: Add initial values for all CSS properties
It's a little verbose to repeat these in cases like the borders, but if everything has an initial value, we can guarantee that `property_initial_value()` will return something! :^)
-rw-r--r--Userland/Libraries/LibWeb/CSS/Properties.json25
1 files changed, 25 insertions, 0 deletions
diff --git a/Userland/Libraries/LibWeb/CSS/Properties.json b/Userland/Libraries/LibWeb/CSS/Properties.json
index 487271f5b3..70da58ff6a 100644
--- a/Userland/Libraries/LibWeb/CSS/Properties.json
+++ b/Userland/Libraries/LibWeb/CSS/Properties.json
@@ -118,6 +118,8 @@
]
},
"border": {
+ "inherited": false,
+ "initial": "medium currentcolor none",
"longhands": [
"border-width",
"border-style",
@@ -125,6 +127,8 @@
]
},
"border-top": {
+ "inherited": false,
+ "initial": "medium currentcolor none",
"longhands": [
"border-top-width",
"border-top-style",
@@ -132,6 +136,8 @@
]
},
"border-right": {
+ "inherited": false,
+ "initial": "medium currentcolor none",
"longhands": [
"border-right-width",
"border-right-style",
@@ -139,6 +145,8 @@
]
},
"border-bottom": {
+ "inherited": false,
+ "initial": "medium currentcolor none",
"longhands": [
"border-bottom-width",
"border-bottom-style",
@@ -146,6 +154,8 @@
]
},
"border-left": {
+ "inherited": false,
+ "initial": "medium currentcolor none",
"longhands": [
"border-left-width",
"border-left-style",
@@ -277,6 +287,8 @@
]
},
"border-radius": {
+ "inherited": false,
+ "initial": "0",
"longhands": [
"border-top-left-radius",
"border-top-right-radius",
@@ -581,6 +593,8 @@
]
},
"flex": {
+ "inherited": false,
+ "initial": "0 1 auto",
"longhands": [
"flex-grow",
"flex-shrink",
@@ -610,6 +624,8 @@
]
},
"flex-flow": {
+ "inherited": false,
+ "initial": "row nowrap",
"longhands": [
"flex-direction",
"flex-wrap"
@@ -648,6 +664,8 @@
]
},
"font": {
+ "inherited": true,
+ "initial": "normal medium sans-serif",
"longhands": [
"font-family",
"font-size",
@@ -778,6 +796,7 @@
},
"list-style": {
"inherited": true,
+ "initial": "outside disc",
"longhands": [
"list-style-type",
"list-style-position",
@@ -824,6 +843,8 @@
]
},
"margin": {
+ "inherited": false,
+ "initial": "0",
"longhands": [
"margin-top",
"margin-right",
@@ -964,6 +985,8 @@
},
"outline": {
"inherited": false,
+ "__comment": "FIXME: Initial value is really `medium invert none` but we don't yet parse the outline shorthand.",
+ "initial": "none",
"longhands": [
"outline-color",
"outline-style",
@@ -1047,6 +1070,8 @@
]
},
"padding": {
+ "inherited": false,
+ "initial": "0",
"longhands": [
"padding-top",
"padding-right",