-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Make component CSP safe #2057
Copy link
Copy link
Closed
Description
Feature request
Overview
As discovered in mantinedev/mantine#3597 @radix-ui/react-scroll-area currently can't be used in a CSP enabled environment without setting style-src: unsafe-inline.
By being able to configure a nonce or getting rid of the inline styles this scenario would be possible.
Implementation idea
Provide a property to specify a nonce. This nonce then gets passed to the style tag.
Who does this impact? Who is this for?
This is relevant for applications in CSP enabled environments that use strict rules to enhance security.
Additional context
Inline styles are set here:
https://github.com/radix-ui/primitives/blob/main/packages/react/scroll-area/src/ScrollArea.tsx#L152
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels