Notifications
i need change the styles in the notifications, but i can find how can i do it in the docs, someone can help me?
3 Replies
Hi @mauryo. I'm kapa.ai, your friendly support bot. I will try to answer your question by searching through the knowledge base. :wave:
----------------------
To change the styles of notifications in Refine, you can customize the notification providers. Refine supports multiple UI frameworks, including Ant Design, Material UI, Mantine, and Chakra UI. Below are some steps and examples to help you customize the notification styles.
Using Ant Design
If you are using Ant Design and want to ensure that notifications follow the theme style (e.g., dark theme), you can update the
notificationProvider
to use the notification.useNotification
hook as mentioned in the GitHub issue (https://github.com/refinedev/refine/issues/4654).
Example with Chakra UI
Here is an example of how to open and close notifications using the useNotification
hook with Chakra UI:
Source (https://refine.dev/docs/guides-concepts/notifications/#notification-providers)
Customizing Notification Messages
You can also customize the notification messages using the i18n
provider. Here is an example of how to override the default notification messages:
Source (https://refine.dev/docs/guides-concepts/notifications/#notification-providers)
Customizing Notifications in Data Hooks
You can also customize notifications in data hooks like useUpdate
and useForm
:
Source (https://refine.dev/docs/guides-concepts/notifications/#notification-providers)
For more detailed information, you can refer to the [Refine documentation on notifications](https://refine.dev
----------------------
Note: you can ask me a follow up question by @ mentioning me again :speech_balloon:
----------------------<@737073867532796026> kapa.ai is still learning and improving, please let us know how it did by reacting below
stormy-goldOP•5mo ago
with this only modify some props, but i need to change css propierties