You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
NotificationBell ignores unseenCount when the context is available.
This is bad because it makes it impossible to use the built in notification bell when you want to change the effective value of unseenCount, e.g. when you want to use different feeds and only "count" one of them.
👟 Reproduction steps
Connect to novu with a NovuProvider
Inside the NovuProvider, use a NotificationBell inside PopoverNotificationCenter
hardcode a value for unseenCount of NotificationBell.
👍 Expected behavior
NotificationBell should honor the count passed to it before looking at context.
👎 Actual Behavior with Screenshots
The total number of items is the value in context, not the value given.
📃 Provide any additional context for the Bug.
In general, the components you have are very useful for getting started, but it would be much nicer if they were designed to allow the user to wrap and change behavior, view, or both.
i.e. instead of using a context for the header, listItem, etc. props, and having one component calculate all the data and then just render the component in the context if that's provided, it would be nice to expose props and allow higher-order components there.
There's loads of work in the header, for example, and I don't want to have to throw out the whole settings widget and panel just because I want to change the displayed count of items. There's loads of work in the listItem renderer, and I don't want to have to rewrite it all just to conditionally add some react components into the message body.
I'm guessing that the unseenCount was either obsoleted, or designed for unit tests but someone writing the documentation didn't notice.
👀 Have you spent some time to check if this bug has been raised before?
📜 Description
NotificationBell ignores unseenCount when the context is available.
This is bad because it makes it impossible to use the built in notification bell when you want to change the effective value of unseenCount, e.g. when you want to use different feeds and only "count" one of them.
👟 Reproduction steps
👍 Expected behavior
NotificationBell should honor the count passed to it before looking at context.
👎 Actual Behavior with Screenshots
The total number of items is the value in context, not the value given.
📃 Provide any additional context for the Bug.
In general, the components you have are very useful for getting started, but it would be much nicer if they were designed to allow the user to wrap and change behavior, view, or both.
i.e. instead of using a context for the
header
,listItem
, etc. props, and having one component calculate all the data and then just render the component in the context if that's provided, it would be nice to expose props and allow higher-order components there.There's loads of work in the header, for example, and I don't want to have to throw out the whole settings widget and panel just because I want to change the displayed count of items. There's loads of work in the listItem renderer, and I don't want to have to rewrite it all just to conditionally add some react components into the message body.
I'm guessing that the unseenCount was either obsoleted, or designed for unit tests but someone writing the documentation didn't notice.
👀 Have you spent some time to check if this bug has been raised before?
🏢 Have you read the Contributing Guidelines?
Are you willing to submit PR?
None
NV-2150
The text was updated successfully, but these errors were encountered: