Skip to content

[css-shadow-parts][css-pseudo] ::part* and *::before* and *::after* pseudo elements #3510

Closed
@frivoal

Description

@frivoal

(Split from issue #3467, reported by @stefsullrew)

It appears the ::before and ::after pseudo elements/selectors do not function with ::part. Is this intentionally blocked, if so why? If not are there plans to add this functionality in the future?

// add an asterisk prefix to the title part
x-foo::part(title)::before {
    content: '*';
    color: red;
    margin-right: 0.25rem;
}

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions