195 Pro components and page blocks

Get Pro

Updated

Notification Bell

New

Preview

Customize

Count3
Max99
Color
Soft
Medium

Installation

npx shadcn@latest add https://uibrik.com/r/notification-bell.json
Adds the files to components/uibrik/notification-bell and installs @number-flow/react and motion. With the @uibrik namespace set up: npx shadcn@latest add @uibrik/notification-bell.

Usage

import { NotificationBell } from "@/components/uibrik/notification-bell/notification-bell";​<NotificationBell  defaultCount={3}  clearOnClick  max={99}  dot={false}  color="#dc2626"  variant="soft"  size="md"  onClick={() => {}}  // count={0}  // onCountChange={(count) => {}}/>

Where to use Notification Bell

  • App navbars

    The swing catches the eye only when something new arrives, so the bell can sit quietly the rest of the time.

    Pairs with Notification Center and Classic Navbar

  • Dashboards

    Counts roll up digit by digit, so a jump from 9 to 10 reads as more, not as a different number.

    Pairs with Project Dashboard

  • Inbox and mentions

    A dot mode suits places where the exact number matters less than knowing there is something.

    Pairs with Event Feed

Props

NotificationBell
defaultCount
Type number
3
Unread count on mount when uncontrolled.
clearOnClick
Type boolean
true
Mark everything read when pressed.
max
Type number
99
Counts above this show as "max+".
dot
Type boolean
false
A dot instead of a number.
color
Type string
"#dc2626"
Badge colour.
variant
Type "soft" | "ghost"
"soft"
Filled, or transparent until hovered.
size
Type "sm" | "md" | "lg"
"md"
Button and icon size.
count / onCountChange
Type number / (count) => void
–
Controlled unread count. Raising it swings the bell.
onClick
Type () => void
–
Called on press, e.g. to open a panel.
className
Type string
–
Classes for the button.