AhaSlides Design
v0.52.0React · Vue · Lit

Components · Feedback

Notification

A richer, stacking message with a title + description — rendered through antd's notification API.

Examples

API

PropTypeDefaultNotes
messagestringThe bold title line
descriptionstringThe supporting body text
typesuccess | info | warning | errorStatus glyph + tone
placementtopLeft | topRight | bottomLeft | bottomRighttopRightWhich corner it stacks in
durationnumber4.5Seconds on screen; 0 keeps it until dismissed
btnReactNodeOne optional action (e.g. Undo) rendered in the card

Install

# .npmrc — once: point the @ahaslides-product scope at GitHub Packages
@ahaslides-product:registry=https://npm.pkg.github.com
//npm.pkg.github.com/:_authToken=${GITHUB_TOKEN}   # a GitHub token with read:packages

npm i @ahaslides-product/design
import '@ahaslides-product/design/tokens.css';   // once, at the app root
import '@ahaslides-product/design/notification-theme';   // registers <notification>

Agent feed for this component (absolute, fetchable anywhere): notification.agent.json · notification.md · notification.llms.txt

When to use

When to use
  • Notification — a message with a title + detail, or one from a background event the user may act on later
  • Toast — a one-line, past-tense confirmation with nothing to act on
  • Modal — the user must respond before continuing
Give it a short title and a one-sentence description. Put at most one action in it; anything more belongs in a Modal or the page itself.
Surfaces
editor dashboard settings

Spec

Card white elevated · 384 wide · radius 8 · Title ink #1A1A1A, SemiBold · Type success · info · warning · error (status glyph + tone) · Placement topRight default (4 corners) · Duration 4.5s default (0 = sticky)