Skip to content

feat(Alert): add custom role, status or alert#443

Merged
ddecrulle merged 1 commit into
codegouvfr:mainfrom
iNeoO:fix/438
Aug 12, 2025
Merged

feat(Alert): add custom role, status or alert#443
ddecrulle merged 1 commit into
codegouvfr:mainfrom
iNeoO:fix/438

Conversation

@iNeoO

@iNeoO iNeoO commented Aug 11, 2025

Copy link
Copy Markdown
Contributor

@ddecrulle ddecrulle changed the title feat(Alert.tsx): add custom role, status or alert feat(Alert): add custom role, status or alert Aug 12, 2025
@ddecrulle
ddecrulle merged commit da26384 into codegouvfr:main Aug 12, 2025
6 checks passed
@sylvaingi

Copy link
Copy Markdown

@iNeoO Even with this patch it looks like we cannot render an uncontrolled Alert (without passing a prop isClosed) with a custom role. Even in controlled mode it seems like the role is only set when the Alert transitions to closed. Am I missing something with the usage of this component?

@iNeoO

iNeoO commented Oct 8, 2025

Copy link
Copy Markdown
Contributor Author

Hi, shouldn t have probleme, can you provide an exemple of your usage ?

@sylvaingi

Copy link
Copy Markdown

Here's a reproduction: https://codesandbox.io/p/sandbox/reverent-worker-75w3gp?file=%2Fsrc%2FApp.js%3A8%2C27

Even if i set the role prop, it is not defined on the DOM node.

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.

3 participants