Announcement
News badge link for what's new and product updates: a pill built on the secondary Badge, with a headline that truncates first and a Learn more action beside a short divider. Renders as an anchor, suited to hero announcements.
pnpm dlx shadcn add @01orbital/announcementThe source comes with full access.
One payment of $149 opens the source right here and lets the CLI install every paid component, with lifetime updates.
The example also imports @phosphor-icons/react from npm, which the install does not add:
pnpm add @phosphor-icons/reactnpm install @phosphor-icons/reactyarn add @phosphor-icons/reactbun add @phosphor-icons/reactUsage
import { Announcement } from "@/components/announcement/announcement"Anatomy
Announcement is built from 3 parts. In the example they nest like this:
Announcement
├─ AnnouncementText
└─ AnnouncementActionAnnouncement: A small pill that links to news, such as a launch, above a heading. It renders an<a>styled as the secondaryBadge, at reading size. Put anAnnouncementTextand anAnnouncementActioninside.AnnouncementText: The headline insideAnnouncement. When space runs short it is cut off with an ellipsis, whileAnnouncementActionkeeps its full width.AnnouncementAction: The call to action at the end ofAnnouncement, such as "Learn more" and a caret icon. A short vertical rule sets it apart fromAnnouncementText, and it never shrinks.
API reference
Announcement
A small pill that links to news, such as a launch, above a heading. It renders an <a> styled as the secondary Badge, at reading size. Put an AnnouncementText and an AnnouncementAction inside.
Over artwork, add className="dark" so the pill takes the dark theme's colors. Pass render to use your framework's link in place of the <a>.
It accepts the props of the Base UI part it wraps, and the HTML attributes of the element it renders.
AnnouncementText
The headline inside Announcement. When space runs short it is cut off with an ellipsis, while AnnouncementAction keeps its full width.
It accepts the HTML attributes of the element it renders.
AnnouncementAction
The call to action at the end of Announcement, such as "Learn more" and a caret icon. A short vertical rule sets it apart from AnnouncementText, and it never shrinks.
It accepts the HTML attributes of the element it renders.
Dependencies
npm: @base-ui/react, cn. The CLI installs them for you. cn merges Tailwind class names, in place of clsx and tailwind-merge.
Registry pieces it installs with it:
Used in blocks
5 blocks are built with Announcement: