How to change the color of the bell?
I wish to change the color of the bell icon of the notification center
24 Replies
@emilpearce are you using react/iframe?
@emilpearce this should work:
either from the iframe or React
NovuProvider
componentAnd what if I want another SVG?
@emilpearce You could have your own bell component https://docs.novu.co/notification-center/react/react-components#customizing-the-ui
React Component | Novu
Novu provides the @novu/notification-center a React library that helps to add a fully functioning notification center to your web application in minutes. Let's do a quick recap on how we can easily use it in your application.
I want also:
- Change the size of the bell
- Change the color of the dot
- Change the stroke-width of the dot
styles = {
bellButton: {
dot: {
color: 'white',
},
root: {
svg: {
color: 'white',
}
}
}
@paweltymczuk can you help me here?
@emilpearce this should do the thing
@emilpearce the dot is not positioned properly, you have to adjust it some other values like:
10px assumes that the dot size is 20px, so it's half it's size
@emilpearce @Pawan Jain any of you willing to write an article on this? It's a recurrent challenge.
Yes, I am working on an example app
Hope to complete end of this week
Ah, perfecto! thanks @Pawan Jain
We need to have someone presenting all the possible variations of customisation 😄
Yes, I think we can all review Pawan's submission to ensure it has all the possible variations
Yeah
I want to change the text color and the cog icon, also, I wish to disable the option to modify the preferences
Can any of you folks help me?
That's my current code
the cog icon could be updated with path like:
header.cog
and time text with notifications.listItem.timestamp
the whole list of components could be find in this file: packages/notification-center/src/store/styles/styles-provider.types.ts
Disable the option to modify the preference. You mean to prevent this from showing up?
Yes
there is a prop on the
NotificationCenter
component that allows to hide it: showUserPreferences
like:
should do the thingyou can also disable it from the dashboard
it will disable just one template, but the preferences settings will be still visible in the NC
Oh, I see.