RESOLVED INVALID217207
CSS 'all' shorthand makes SVG child elements forget various HTML attributes
https://bugs.webkit.org/show_bug.cgi?id=217207
Summary CSS 'all' shorthand makes SVG child elements forget various HTML attributes
bugmenot
Reported 2020-10-02 03:19:41 PDT
Steps to reproduce: 1. In HTML, create an inline SVG 2. In CSS, select the children of the SVG 3. Set the all shorthand to one of the global values (inherit, initial, unset) Expected results: The SVG children elements are visible and drawn as specified by their HTML attributes. Actual results: Multiple SVG children elements don't show up or are not drawn as specified by their HTML attributes (color, fill, stroke, etc.). Reduced test case: https://jsfiddle.net/1c2t7o8n/
Attachments
bugmenot
Comment 1 2020-10-02 03:24:09 PDT
Similar bugs in Chrome and Firefox. Additionally in Chrome, the <path> element is not visible. https://bugs.chromium.org/p/chromium/issues/detail?id=1134543 https://bugzilla.mozilla.org/show_bug.cgi?id=1668770
Radar WebKit Bug Importer
Comment 2 2020-10-03 10:01:26 PDT
bugmenot
Comment 3 2020-10-04 02:41:58 PDT
Works as intended as per SVG specification: "The presentation attributes thus will participate in the CSS2 cascade as if they were replaced by corresponding CSS style rules placed at the start of the author style sheet with a specificity of zero. In general, this means that the presentation attributes have lower priority than other CSS style rules specified in author style sheets or ‘style’ attributes." https://www.w3.org/TR/SVG11/styling.html
Note You need to log in before you can comment on or make changes to this bug.