Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup inline-styles with lightningcss for cleanupEnableBackground #50

Open
noahbald opened this issue Nov 24, 2024 · 0 comments
Open
Labels
enhancement New feature or request

Comments

@noahbald
Copy link
Owner

noahbald commented Nov 24, 2024

See the todo in cleanupEnableBackground

    /// Cleans up `enable-background`, unless document uses `<filter>` elements.
    ///
    /// Only cleans up attribute values
    /// TODO: Clean up inline-styles
    ///
    /// This job will:
    /// - Drop `enable-background` on `<svg>` node, if it matches the node's width and height
    /// - Set `enable-background` to `"new"` on `<mask>` or `<pattern>` nodes, if it matches the
    ///   node's width and height

We have context to provide styles now, and this would be preferrable to the current approach using regex

@noahbald noahbald added the enhancement New feature or request label Nov 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant