TidalUI

Notification center preview

A notification bell and modal center for filtering, opening and marking persistent product updates.

pro · Navigation · composite

When to use

Alternatives

Configure components.json and the @tidal-pro namespace before installing Pro components.

Installation

npx shadcn@latest add @tidal-pro/notification-center

Import components/ui/tidal.css, components/ui/notification-center.css. Wrap installed components in tidal-scope.

Preview

Notification center component preview

Open interactive preview

Minimal example

import"./components/ui/tidal.css";
import"./components/ui/notification-center.css";
import{TidalNotificationCenter}from"./components/ui/notification-center";
export default(p:Parameters<typeof TidalNotificationCenter>[0])=><div className="tidal-scope"><TidalNotificationCenter {...p}/></div>;

API and props

TidalNotificationCenterPage.filters (required)
ReadonlyArray<TidalNotificationFilterOption>

Required filters value accepted by this exported component.

TidalNotificationCenterPage.filterValue (required)
string

Required filter value value accepted by this exported component.

TidalNotificationCenterPage.notifications (required)
ReadonlyArray<TidalNotificationRecord>

Required notifications value accepted by this exported component.

TidalNotificationCenterPage.onFilterChange (required)
(value: string, event: MouseEvent<HTMLButtonElement>) => void

Callback invoked when the filter change interaction is proposed.

TidalNotificationCenterPage.onMarkAllRead (required)
(notificationIds: readonly string[], event: MouseEvent<HTMLButtonElement>) => void

Callback invoked when the mark all read interaction is proposed.

TidalNotificationCenterPage.onReadChange (required)
(notification: TidalNotificationRecord, read: boolean, event: MouseEvent<HTMLButtonElement>) => void

Callback invoked when the read change interaction is proposed.

TidalNotificationCenterPage.title (required)
ReactNode

Required title value accepted by this exported component.

TidalNotificationCenterPage.description
ReactNode

Optional description value accepted by this exported component.

TidalNotificationCenterPage.disabled
boolean | undefined

Optional disabled value accepted by this exported component.

TidalNotificationCenterPage.emptyMessage
ReactNode

Optional empty message value accepted by this exported component.

TidalNotificationCenterPage.headingLevel
"h2" | "h3" | "h4" | "h5" | "h6" | undefined

Optional heading level value accepted by this exported component.

TidalNotificationCenterPage.labels
Partial<TidalNotificationCenterLabels> | undefined

Optional labels value accepted by this exported component.

TidalNotificationCenterPage.loading
boolean | undefined

Optional loading value accepted by this exported component.

TidalNotificationCenterPage.markAllButtonProps
NativeButtonProps | undefined

Optional mark all button props value accepted by this exported component.

TidalNotificationCenterPage.markAllButtonRef
Ref<HTMLButtonElement> | undefined

Optional mark all button ref value accepted by this exported component.

TidalNotificationCenter.filters (required)
ReadonlyArray<TidalNotificationFilterOption>

Required filters value accepted by this exported component.

TidalNotificationCenter.filterValue (required)
string

Required filter value value accepted by this exported component.

TidalNotificationCenter.notifications (required)
ReadonlyArray<TidalNotificationRecord>

Required notifications value accepted by this exported component.

TidalNotificationCenter.onFilterChange (required)
(value: string, event: MouseEvent<HTMLButtonElement>) => void

Callback invoked when the filter change interaction is proposed.

TidalNotificationCenter.onMarkAllRead (required)
(notificationIds: readonly string[], event: MouseEvent<HTMLButtonElement>) => void

Callback invoked when the mark all read interaction is proposed.

TidalNotificationCenter.onOpenChange (required)
(open: boolean) => void

Callback invoked when the open change interaction is proposed.

TidalNotificationCenter.onReadChange (required)
(notification: TidalNotificationRecord, read: boolean, event: MouseEvent<HTMLButtonElement>) => void

Callback invoked when the read change interaction is proposed.

TidalNotificationCenter.open (required)
boolean

Required open value accepted by this exported component.

TidalNotificationCenter.title (required)
ReactNode

Required title value accepted by this exported component.

TidalNotificationCenter.description
ReactNode

Optional description value accepted by this exported component.

TidalNotificationCenter.disabled
boolean | undefined

Optional disabled value accepted by this exported component.

TidalNotificationCenter.emptyMessage
ReactNode

Optional empty message value accepted by this exported component.

TidalNotificationCenter.headingLevel
"h2" | "h3" | "h4" | "h5" | "h6" | undefined

Optional heading level value accepted by this exported component.

TidalNotificationCenter.labels
Partial<TidalNotificationCenterLabels> | undefined

Optional labels value accepted by this exported component.

TidalNotificationCenter.loading
boolean | undefined

Optional loading value accepted by this exported component.

TidalNotificationCenter.markAllButtonProps
NativeButtonProps | undefined

Optional mark all button props value accepted by this exported component.

TidalNotificationCenter.markAllButtonRef
Ref<HTMLButtonElement> | undefined

Optional mark all button ref value accepted by this exported component.

TidalNotificationCenter.sheetProps
NotificationSheetProps | undefined

Optional sheet props value accepted by this exported component.

TidalNotificationCenter.triggerLabel
ReactNode

Optional trigger label value accepted by this exported component.

TidalNotificationCenter.triggerProps
NativeButtonProps | undefined

Optional trigger props value accepted by this exported component.

TidalNotificationCenter.triggerRef
Ref<HTMLButtonElement> | undefined

Optional trigger ref value accepted by this exported component.

TidalNotificationCenter.viewRef
Ref<HTMLElement> | undefined

Optional view ref value accepted by this exported component.

Complete usage

Full example, stylesheet imports, API and accessibility documentation

Gotchas