Bug 243832 - ::first-letter styles should apply to text in slot element
Summary: ::first-letter styles should apply to text in slot element
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: Safari 15
Hardware: Mac (Apple Silicon) macOS 12
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-08-11 09:41 PDT by Sarah Gebauer
Modified: 2022-08-11 09:53 PDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sarah Gebauer 2022-08-11 09:41:20 PDT
Example https://codepen.io/xgebi/pen/zYWJZZj

In both, Firefox and Chrome, when I try to style first letter of a div element which gets its content through slot, ::first-letter styles should apply. In the example above 'A' should be blue and 'bc' red.

At the moment Safari can detect ::first-letter styles but does not apply them.
Comment 1 Sarah Gebauer 2022-08-11 09:53:26 PDT
(In reply to Sarah Gebauer from comment #0)
> Example https://codepen.io/xgebi/pen/zYWJZZj
> 
> In both, Firefox and Chrome, when I try to style first letter of a div
> element which gets its content through slot, ::first-letter styles should
> apply. In the example above 'A' should be blue and 'bc' red.
> 
> At the moment Safari can detect ::first-letter styles but does not apply
> them.

It's resolved in Safari TP.