Skip to content

Scope CSS to the preview #1

@sonnyp

Description

@sonnyp

The CSS currently applies to the whole window so something like label { color: blue; } will leak outside the preview and into the application controls.

As pointed out in 2e02792 a solution would simply be to prefix all selectors with an id so that everything is scoped to the preview.

With a proper css ast-like parser and serializer it should be straightforward

cool explorer for css ast solutions https://astexplorer.net/

Screenshot from 2022-01-30 17-25-02

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions