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

Use class to hide SVG symbols #16832

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

mikelkew
Copy link

An example of using a class instead of inline-CSS to hide the SVG symbols, as discussed in #16827.

Obviously this would need to apply to all the JS/CSS distributions within the repo, am just using svg-core as an example.

In my testing locally (FF/Chrome latest), this works as expected and does not require style-src: unsafe-inline in the Content Security Policy as the existing implementation does.

I understand that:

  • I'm submitting this PR for reference only. It shows an example of what I'd like to see changed but
    I understand that it will not be merged and I will not be listed as a contributor on this project.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant