1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-25 15:35:06 +00:00
serenity/Userland/Libraries/LibWeb/CSS/Properties.json
Sam Atkins 11f0ece58f 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! :^)
2021-11-10 21:58:14 +01:00

1385 lines
24 KiB
JSON

{
"align-items": {
"inherited": false,
"initial": "stretch",
"valid-identifiers": [
"center",
"baseline",
"flex-end",
"flex-start",
"stretch"
]
},
"background": {
"inherited": false,
"initial": "transparent",
"longhands": [
"background-attachment",
"background-clip",
"background-color",
"background-image",
"background-origin",
"background-position",
"background-repeat",
"background-size"
]
},
"background-attachment": {
"inherited": false,
"initial": "scroll",
"valid-identifiers": [
"fixed",
"local",
"scroll"
]
},
"background-clip": {
"inherited": false,
"initial": "border-box",
"valid-identifiers": [
"border-box",
"content-box",
"padding-box"
]
},
"background-color": {
"inherited": false,
"initial": "transparent",
"valid-types": [
"color"
],
"quirks": [
"hashless-hex-color"
]
},
"background-image": {
"inherited": false,
"initial": "none",
"valid-types": [
"image"
],
"valid-identifiers": [
"none"
]
},
"background-origin": {
"inherited": false,
"initial": "padding-box",
"valid-identifiers": [
"border-box",
"content-box",
"padding-box"
]
},
"background-position": {
"inherited": false,
"initial": "0% 0%",
"max-values": 4,
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"bottom",
"center",
"left",
"right",
"top"
],
"quirks": [
"unitless-length"
]
},
"background-repeat": {
"inherited": false,
"initial": "repeat",
"max-values": 2,
"valid-identifiers": [
"no-repeat",
"repeat",
"repeat-x",
"repeat-y",
"round",
"space"
]
},
"background-size": {
"inherited": false,
"initial": "auto",
"max-values": 2,
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto",
"cover",
"contain"
]
},
"border": {
"inherited": false,
"initial": "medium currentcolor none",
"longhands": [
"border-width",
"border-style",
"border-color"
]
},
"border-top": {
"inherited": false,
"initial": "medium currentcolor none",
"longhands": [
"border-top-width",
"border-top-style",
"border-top-color"
]
},
"border-right": {
"inherited": false,
"initial": "medium currentcolor none",
"longhands": [
"border-right-width",
"border-right-style",
"border-right-color"
]
},
"border-bottom": {
"inherited": false,
"initial": "medium currentcolor none",
"longhands": [
"border-bottom-width",
"border-bottom-style",
"border-bottom-color"
]
},
"border-left": {
"inherited": false,
"initial": "medium currentcolor none",
"longhands": [
"border-left-width",
"border-left-style",
"border-left-color"
]
},
"border-bottom-color": {
"initial": "currentcolor",
"inherited": false,
"valid-types": [
"color"
],
"quirks": [
"hashless-hex-color"
]
},
"border-bottom-left-radius": {
"initial": "0",
"inherited": false,
"max-values": 2,
"valid-types": [
"length",
"percentage"
]
},
"border-bottom-right-radius": {
"initial": "0",
"inherited": false,
"max-values": 2,
"valid-types": [
"length",
"percentage"
]
},
"border-bottom-style": {
"initial": "none",
"inherited": false,
"valid-identifiers": [
"dashed",
"dotted",
"double",
"groove",
"hidden",
"inset",
"none",
"outset",
"ridge",
"solid"
]
},
"border-bottom-width": {
"initial": "medium",
"inherited": false,
"valid-types": [
"length"
],
"valid-identifiers": [
"medium",
"thick",
"thin"
],
"quirks": [
"unitless-length"
]
},
"border-color": {
"initial": "currentcolor",
"longhands": [
"border-top-color",
"border-right-color",
"border-bottom-color",
"border-left-color"
],
"max-values": 4,
"valid-types": [
"color"
],
"quirks": [
"hashless-hex-color"
]
},
"border-collapse": {
"inherited": true,
"initial": "separate",
"valid-identifiers": [
"collapse",
"separate"
]
},
"border-left-color": {
"initial": "currentcolor",
"inherited": false,
"valid-types": [
"color"
],
"quirks": [
"hashless-hex-color"
]
},
"border-left-style": {
"initial": "none",
"inherited": false,
"valid-identifiers": [
"dashed",
"dotted",
"double",
"groove",
"hidden",
"inset",
"none",
"outset",
"ridge",
"solid"
]
},
"border-left-width": {
"initial": "medium",
"inherited": false,
"valid-types": [
"length"
],
"valid-identifiers": [
"medium",
"thick",
"thin"
],
"quirks": [
"unitless-length"
]
},
"border-radius": {
"inherited": false,
"initial": "0",
"longhands": [
"border-top-left-radius",
"border-top-right-radius",
"border-bottom-left-radius",
"border-bottom-right-radius"
]
},
"border-right-color": {
"initial": "currentcolor",
"inherited": false,
"valid-types": [
"color"
],
"quirks": [
"hashless-hex-color"
]
},
"border-right-style": {
"initial": "none",
"inherited": false,
"valid-identifiers": [
"dashed",
"dotted",
"double",
"groove",
"hidden",
"inset",
"none",
"outset",
"ridge",
"solid"
]
},
"border-right-width": {
"initial": "medium",
"inherited": false,
"valid-types": [
"length"
],
"valid-identifiers": [
"medium",
"thick",
"thin"
],
"quirks": [
"unitless-length"
]
},
"border-spacing": {
"inherited": true,
"initial": "0",
"quirks": [
"unitless-length"
]
},
"border-style": {
"initial": "none",
"longhands": [
"border-top-style",
"border-right-style",
"border-bottom-style",
"border-left-style"
],
"max-values": 4,
"valid-identifiers": [
"dashed",
"dotted",
"double",
"groove",
"hidden",
"inset",
"none",
"outset",
"ridge",
"solid"
]
},
"border-top-color": {
"initial": "currentcolor",
"inherited": false,
"quirks": [
"hashless-hex-color"
]
},
"border-top-left-radius": {
"initial": "0",
"inherited": false,
"max-values": 2,
"valid-types": [
"length",
"percentage"
]
},
"border-top-right-radius": {
"initial": "0",
"inherited": false,
"max-values": 2,
"valid-types": [
"length",
"percentage"
]
},
"border-top-style": {
"initial": "none",
"inherited": false,
"valid-identifiers": [
"dashed",
"dotted",
"double",
"groove",
"hidden",
"inset",
"none",
"outset",
"ridge",
"solid"
]
},
"border-top-width": {
"initial": "medium",
"inherited": false,
"valid-types": [
"length"
],
"valid-identifiers": [
"medium",
"thick",
"thin"
],
"quirks": [
"unitless-length"
]
},
"border-width": {
"initial": "medium",
"longhands": [
"border-top-width",
"border-right-width",
"border-bottom-width",
"border-left-width"
],
"max-values": 4,
"valid-types": [
"length"
],
"valid-identifiers": [
"medium",
"thick",
"thin"
],
"quirks": [
"unitless-length"
]
},
"bottom": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"box-shadow": {
"inherited": false,
"initial": "none",
"valid-identifiers": [
"none"
]
},
"box-sizing": {
"inherited": false,
"initial": "content-box",
"valid-identifiers": [
"border-box",
"content-box"
]
},
"caption-side": {
"inherited": true,
"initial": "top",
"valid-identifiers": [
"bottom",
"top"
]
},
"clear": {
"inherited": false,
"initial": "none",
"valid-identifiers": [
"both",
"left",
"none",
"right"
]
},
"clip": {
"inherited": true,
"initial": "auto",
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"color": {
"inherited": true,
"initial": "-libweb-palette-base-text",
"valid-types": [
"color"
],
"quirks": [
"hashless-hex-color"
]
},
"cursor": {
"inherited": true,
"initial": "auto",
"valid-types": [
"url"
],
"valid-identifiers": [
"alias",
"all-scroll",
"auto",
"cell",
"col-resize",
"context-menu",
"copy",
"crosshair",
"default",
"e-resize",
"ew-resize",
"grab",
"grabbing",
"help",
"move",
"n-resize",
"ne-resize",
"nesw-resize",
"no-drop",
"none",
"not-allowed",
"ns-resize",
"nw-resize",
"nwse-resize",
"pointer",
"progress",
"row-resize",
"s-resize",
"se-resize",
"sw-resize",
"text",
"vertical-text",
"w-resize",
"wait",
"zoom-in",
"zoom-out"
]
},
"direction": {
"inherited": true,
"initial": "ltr",
"valid-identifiers": [
"ltr",
"rtl"
]
},
"display": {
"inherited": false,
"initial": "inline",
"valid-identifiers": [
"block",
"flex",
"inline",
"inline-block",
"inline-table",
"list-item",
"none",
"table",
"table-caption",
"table-cell",
"table-column",
"table-column-group",
"table-footer-group",
"table-header-group",
"table-row",
"table-row-group"
]
},
"fill": {
"inherited": true,
"initial": "black",
"valid-types": [
"color"
]
},
"flex": {
"inherited": false,
"initial": "0 1 auto",
"longhands": [
"flex-grow",
"flex-shrink",
"flex-basis"
]
},
"flex-basis": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto",
"content"
]
},
"flex-direction": {
"inherited": false,
"initial": "row",
"valid-identifiers": [
"column",
"column-reverse",
"row",
"row-reverse"
]
},
"flex-flow": {
"inherited": false,
"initial": "row nowrap",
"longhands": [
"flex-direction",
"flex-wrap"
]
},
"flex-grow": {
"inherited": false,
"initial": "0",
"valid-types": [
"number"
]
},
"flex-shrink": {
"inherited": false,
"initial": "1",
"valid-types": [
"number"
]
},
"flex-wrap": {
"inherited": false,
"initial": "nowrap",
"valid-identifiers": [
"nowrap",
"wrap",
"wrap-reverse"
]
},
"float": {
"inherited": false,
"initial": "none",
"valid-identifiers": [
"left",
"none",
"right"
]
},
"font": {
"inherited": true,
"initial": "normal medium sans-serif",
"longhands": [
"font-family",
"font-size",
"font-variant",
"font-weight"
]
},
"font-family": {
"inherited": true,
"initial": "sans-serif"
},
"font-size": {
"inherited": true,
"initial": "medium",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"large",
"larger",
"medium",
"small",
"smaller",
"x-large",
"x-small",
"xx-large",
"xx-small",
"xxx-large"
],
"quirks": [
"unitless-length"
]
},
"font-style": {
"inherited": true,
"initial": "normal",
"valid-identifiers": [
"italic",
"normal",
"oblique"
]
},
"font-variant": {
"inherited": true,
"initial": "normal",
"valid-identifiers": [
"normal",
"small-caps"
]
},
"font-weight": {
"inherited": true,
"initial": "normal",
"valid-types": [
"number [1,1000]"
],
"valid-identifiers": [
"bold",
"bolder",
"lighter",
"normal"
]
},
"height": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"justify-content": {
"inherited": false,
"initial": "flex-start",
"valid-identifiers": [
"center",
"flex-end",
"flex-start",
"space-around",
"space-between"
]
},
"left": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"letter-spacing": {
"inherited": true,
"initial": "normal",
"valid-types": [
"length"
],
"valid-identifiers": [
"normal"
],
"quirks": [
"unitless-length"
]
},
"line-height": {
"inherited": true,
"initial": "normal",
"valid-types": [
"length",
"number",
"percentage"
],
"valid-identifiers": [
"normal"
]
},
"list-style": {
"inherited": true,
"initial": "outside disc",
"longhands": [
"list-style-type",
"list-style-position",
"list-style-image"
]
},
"list-style-image": {
"inherited": true,
"initial": "none",
"valid-types": [
"image"
],
"valid-identifiers": [
"none"
]
},
"list-style-position": {
"inherited": true,
"initial": "outside",
"valid-identifiers": [
"inside",
"outside"
]
},
"list-style-type": {
"inherited": true,
"initial": "disc",
"valid-types": [
"string"
],
"valid-identifiers": [
"circle",
"decimal",
"decimal-leading-zero",
"disc",
"lower-alpha",
"lower-latin",
"lower-roman",
"none",
"square",
"upper-alpha",
"upper-latin",
"upper-roman"
]
},
"margin": {
"inherited": false,
"initial": "0",
"longhands": [
"margin-top",
"margin-right",
"margin-bottom",
"margin-left"
],
"max-values": 4,
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"margin-bottom": {
"inherited": false,
"initial": "0",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"margin-left": {
"inherited": false,
"initial": "0",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"margin-right": {
"inherited": false,
"initial": "0",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"margin-top": {
"inherited": false,
"initial": "0",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"max-height": {
"inherited": false,
"initial": "none",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"none"
],
"quirks": [
"unitless-length"
]
},
"max-width": {
"inherited": false,
"initial": "none",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"none"
],
"quirks": [
"unitless-length"
]
},
"min-height": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"none"
],
"quirks": [
"unitless-length"
]
},
"min-width": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"none"
],
"quirks": [
"unitless-length"
]
},
"opacity": {
"inherited": false,
"initial": "1",
"valid-types": [
"number",
"percentage"
]
},
"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",
"outline-width"
]
},
"outline-color": {
"inherited": false,
"initial": "invert",
"valid-types": [
"color"
],
"valid-identifiers": [
"invert"
]
},
"outline-style": {
"inherited": false,
"initial": "none",
"valid-identifiers": [
"dashed",
"dotted",
"double",
"groove",
"hidden",
"inset",
"none",
"outset",
"ridge",
"solid"
]
},
"outline-width": {
"inherited": false,
"initial": "medium",
"valid-types": [
"length"
],
"valid-identifiers": [
"medium",
"thick",
"thin"
]
},
"overflow": {
"longhands": [
"overflow-x",
"overflow-y"
],
"inherited": false,
"initial": "visible",
"max-values": 2,
"valid-identifiers": [
"auto",
"clip",
"hidden",
"scroll",
"visible"
]
},
"overflow-x": {
"inherited": false,
"initial": "visible",
"valid-identifiers": [
"auto",
"clip",
"hidden",
"scroll",
"visible"
]
},
"overflow-y": {
"inherited": false,
"initial": "visible",
"valid-identifiers": [
"auto",
"clip",
"hidden",
"scroll",
"visible"
]
},
"padding": {
"inherited": false,
"initial": "0",
"longhands": [
"padding-top",
"padding-right",
"padding-bottom",
"padding-left"
],
"max-values": 4,
"valid-types": [
"length",
"percentage"
],
"quirks": [
"unitless-length"
]
},
"padding-bottom": {
"inherited": false,
"initial": "0",
"valid-types": [
"length",
"percentage"
],
"quirks": [
"unitless-length"
]
},
"padding-left": {
"inherited": false,
"initial": "0",
"valid-types": [
"length",
"percentage"
],
"quirks": [
"unitless-length"
]
},
"padding-right": {
"inherited": false,
"initial": "0",
"valid-types": [
"length",
"percentage"
],
"quirks": [
"unitless-length"
]
},
"padding-top": {
"inherited": false,
"initial": "0",
"valid-types": [
"length",
"percentage"
],
"quirks": [
"unitless-length"
]
},
"pointer-events": {
"inherited": true,
"initial": "auto",
"valid-identifiers": [
"auto",
"none"
]
},
"position": {
"inherited": false,
"initial": "static",
"valid-identifiers": [
"absolute",
"fixed",
"relative",
"static",
"sticky"
]
},
"right": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"stroke": {
"inherited": true,
"initial": "transparent",
"valid-types": [
"color"
]
},
"stroke-width": {
"inherited": true,
"initial": "1px",
"valid-types": [
"length",
"number",
"percentage"
]
},
"text-align": {
"inherited": true,
"initial": "left",
"valid-identifiers": [
"center",
"justify",
"left",
"right",
"-libweb-center"
]
},
"text-decoration": {
"inherited": false,
"initial": "none",
"longhands": [
"text-decoration-color",
"text-decoration-line",
"text-decoration-style",
"text-decoration-thickness"
]
},
"text-decoration-color": {
"inherited": false,
"initial": "currentcolor",
"valid-types": [
"color"
]
},
"text-decoration-line": {
"__comment": "FIXME: This property is not supposed to be inherited, but we currently rely on inheritance to propagate decorations into line boxes.",
"inherited": true,
"initial": "none",
"valid-identifiers": [
"blink",
"line-through",
"none",
"overline",
"underline"
]
},
"text-decoration-style": {
"inherited": false,
"initial": "solid",
"valid-identifiers": [
"dashed",
"dotted",
"double",
"solid",
"wavy"
]
},
"text-decoration-thickness": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto",
"from-font"
]
},
"text-indent": {
"inherited": true,
"initial": "0",
"valid-types": [
"length",
"percentage"
],
"quirks": [
"unitless-length"
]
},
"text-transform": {
"inherited": true,
"initial": "none",
"valid-identifiers": [
"capitalize",
"full-size-kana",
"full-width",
"lowercase",
"none",
"uppercase"
]
},
"top": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"transform": {
"inherited": false,
"initial": "none"
},
"user-select": {
"inherited": false,
"initial": "auto",
"valid-identifiers": [
"all",
"auto",
"contain",
"none",
"text"
]
},
"vertical-align": {
"inherited": false,
"initial": "baseline",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"baseline",
"bottom",
"middle",
"sub",
"super",
"text-bottom",
"text-top",
"top"
],
"quirks": [
"unitless-length"
]
},
"visibility": {
"inherited": true,
"initial": "visible",
"valid-identifiers": [
"collapse",
"hidden",
"visible"
]
},
"width": {
"inherited": false,
"initial": "auto",
"valid-types": [
"length",
"percentage"
],
"valid-identifiers": [
"auto"
],
"quirks": [
"unitless-length"
]
},
"white-space": {
"inherited": true,
"initial": "normal",
"valid-identifiers": [
"normal",
"nowrap",
"pre",
"pre-line",
"pre-wrap"
]
},
"word-spacing": {
"inherited": true,
"initial": "normal",
"valid-types": [
"length"
],
"valid-identifiers": [
"normal"
],
"quirks": [
"unitless-length"
]
},
"word-wrap": {
"inherited": true,
"initial": "normal",
"valid-identifiers": [
"anywhere",
"break-word",
"normal"
]
},
"z-index": {
"inherited": false,
"initial": "auto",
"valid-types": [
"integer"
],
"valid-identifiers": [
"auto"
]
}
}