Bug 269878

Summary: baseline-shift initial value should be `0px` rather than `baseline`
Product: WebKit Reporter: Ahmad Saleem <ahmad.saleem792>
Component: CSSAssignee: Nobody <webkit-unassigned>
Status: NEW    
Severity: Normal CC: karlcow, ntim, webkit-bug-importer
Priority: P2 Keywords: InRadar, WPTImpact
Version: Safari Technology Preview   
Hardware: Unspecified   
OS: Unspecified   
See Also: https://bugs.webkit.org/show_bug.cgi?id=250012

Ahmad Saleem
Reported 2024-02-21 15:42:16 PST
Hi Team, As title says, this bug is to fix baseline-shift initial value as per CSS spec. NOTE - It was in SVG spec but now getting removed in SVG2 but it is in CSS Inline spec, which should be followed. Old SVG1.1 - https://www.w3.org/TR/SVG11/text.html#BaselineShiftProperty SVG2 (SVGWG) - https://svgwg.org/svg2-draft/text.html#BaselineShiftProperty "SVG 2 will deprecate ‘baseline-shift’ and use ‘vertical-align’ instead." CSS Spec - https://drafts.csswg.org/css-inline-3/#baseline-shift-property WPT Test - https://wpt.fyi/results/css/css-inline/inheritance.html?label=master&label=experimental&aligned > Property baseline-shift has initial value 0px __ It is easy to fix by modifying: > Source/WebCore/rendering/style/SVGRenderStyle.h From: static BaselineShift initialBaselineShift() { return BaselineShift::Baseline; } To: static BaselineShift initialBaselineShift() { return BaselineShift::Length; } and From: static SVGLengthValue initialBaselineShiftValue() { return SVGLengthValue(0, SVGLengthType::Number); } To: static SVGLengthValue initialBaselineShiftValue() { return SVGLengthValue(0, SVGLengthType::Pixels); } __ Any input is welcome. Thanks!
Attachments
Ahmad Saleem
Comment 1 2024-02-21 16:28:29 PST
Ahmad Saleem
Comment 2 2024-02-21 16:37:55 PST
Radar WebKit Bug Importer
Comment 3 2024-02-28 15:43:30 PST
Note You need to log in before you can comment on or make changes to this bug.