Skip to content

NotificationBadge

widgetsdisplay

NotificationBadge - a small count label rendered at a corner position

Installation

$ bunx termuijs add notification-badge

Copies the source into src/components/notification-badge/ and installs @termuijs/core, @termuijs/widgets.

Usage

ts
import { NotificationBadge } from '@termuijs/widgets'
ts
new NotificationBadge(opts: NotificationBadgeOptions = {}, style: Partial<Style> = {})

API Reference

NotificationBadge

PropTypeRequiredDescription
countnumberoptionalNotification count to display
positionBadgePositionoptionalCorner position for the badge
#display#notification-badge