Skip to content

Apply polyfill to styles in CSS @imports #326

@jamesnw

Description

@jamesnw

Is your feature request related to how this polyfill works? Please describe.
When fetching styles to be polyfilled, we currently are not following any @import rules. This means that any anchor positioning-related rules in imported stylesheets will not be polyfilled.

Describe the solution you'd like
Before applying the polyfill, we would need to recursively parse all stylesheets for @import rules.

Alternatively, could we use document.stylesheets to do the initial gathering step for us? I'm unsure if imported stylesheets are included, and we'd need to find a solution that works for Shadow documents as well.

Additional context
#324 only addresses part of the issue, by allowing polyfilled stylesheets to import other stylesheets.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions