mirror of
https://github.com/RGBCube/serenity
synced 2025-07-29 04:07:34 +00:00
LibWeb: Support x
and y
attributes on nested SVGs
This allows positioning a child SVG relative to its parent SVG. Note: These have been implemented as CSS properties as in SVG 2, these are geometry properties that can be used in CSS (see https://www.w3.org/TR/SVG/geometry.html), but there is not much browser support for this. It is nicer to implement than the ad-hoc SVG attribute parsing though, so I feel it may make sense to port the rest of the attributes specified here (which should fix some issues with viewport relative sizes).
This commit is contained in:
parent
556679fedd
commit
b10f58a1fe
8 changed files with 91 additions and 2 deletions
|
@ -2196,6 +2196,32 @@
|
|||
"normal"
|
||||
]
|
||||
},
|
||||
"x": {
|
||||
"__comment": "This is an SVG 2 geometry property, see: https://www.w3.org/TR/SVG/geometry.html#X.",
|
||||
"inherited": false,
|
||||
"initial": "0",
|
||||
"valid-types": [
|
||||
"length [-∞,∞]",
|
||||
"percentage [-∞,∞]"
|
||||
],
|
||||
"percentages-resolve-to": "length",
|
||||
"quirks": [
|
||||
"unitless-length"
|
||||
]
|
||||
},
|
||||
"y": {
|
||||
"__comment": "This is an SVG 2 geometry property, see: https://www.w3.org/TR/SVG/geometry.html#Y.",
|
||||
"inherited": false,
|
||||
"initial": "0",
|
||||
"valid-types": [
|
||||
"length [-∞,∞]",
|
||||
"percentage [-∞,∞]"
|
||||
],
|
||||
"percentages-resolve-to": "length",
|
||||
"quirks": [
|
||||
"unitless-length"
|
||||
]
|
||||
},
|
||||
"z-index": {
|
||||
"affects-layout": false,
|
||||
"affects-stacking-context": true,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue