Bug 265719 - HTMLDocument::isCaseSensitiveAttribute() misses direction attribute
Summary: HTMLDocument::isCaseSensitiveAttribute() misses direction attribute
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: DOM (show other bugs)
Version: Safari Technology Preview
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Anne van Kesteren
URL:
Keywords: BrowserCompat, GoodFirstBug, InRadar
Depends on:
Blocks:
 
Reported: 2023-12-02 06:40 PST by Ahmad Saleem
Modified: 2023-12-18 08:50 PST (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ahmad Saleem 2023-12-02 06:40:49 PST
Hi Team,

While looking into Blink source and then comparing it WebKit, I noticed that we don't have 'direction' (of HTML Marquee - I know I know) as case sensitive selector. I was not able to find Web-spec reference, so I went to 'Anne' (HTML Champion), if he can help and he did.

Web-Spec: https://html.spec.whatwg.org/#case-sensitivity-of-selectors

WebKit Source: https://github.com/WebKit/WebKit/blob/b10105f3d6b7e01e12f1c141a0aebc023f2324c9/Source/WebCore/html/HTMLDocument.cpp#L184

We need to add direction (&directionAttr,) in alphabetical order.

Failing Test (again thanks to Anne) - data:text/html,<style>marquee[direction=left]{background:lime}</style><marquee%20direction=LEFT>BLAH</marquee>

^ We don't get 'lime' color but Blink does.

Just raising so we can fix it.

@Anne - Thanks for your help as always. Appreciate it.

Thanks!
Comment 1 Karl Dubost 2023-12-07 20:11:54 PST
Probably it would be good to add a WPT test for it too. 

Maybe in https://wpt.fyi/results/css/selectors/attribute-selectors/attribute-case/syntax.html
Comment 2 Radar WebKit Bug Importer 2023-12-09 06:41:12 PST
<rdar://problem/119432066>
Comment 3 Anne van Kesteren 2023-12-18 07:21:35 PST
Pull request: https://github.com/WebKit/WebKit/pull/21966
Comment 4 EWS 2023-12-18 08:50:15 PST
Committed 272219@main (629d6a1da6c4): <https://commits.webkit.org/272219@main>

Reviewed commits have been landed. Closing PR #21966 and removing active labels.