shadcn.io is not affiliated with official shadcn/ui
Release Notes Command Menu Block for React
A release-notes tool's changelog as a command menu shown open under a What's new bell: a select says which version you are on, the list shows what came after it with fixed dates, chips filter by New, Improved or Fixed, and the count line says how many changes break something.
Installation
Overview
Tell people what changed since they last looked with this release notes command menu for React with Base UI. It opens from the What's new page of Notchwell, a release-notes tool, whose header holds an outline field with its ⌘ K cap, and the product page is drawn under a soft scrim inside a hairline frame with a plus mark on each corner, a bell at the end of its bar that the menu hangs from. The menu is the catalog Command. A Native Select says which version you are on, "You're on 4.0", and the list re-derives to what came after it: version by version, newest first, each heading with its fixed date, each change a row with a word, New, Improved or Fixed, and its text, and the word Breaking after the ones that break something. Chips, a Toggle Group, filter by word and carry their counts. The foot counts what is listed, "14 changes since 4.0, 2 breaking", and says it aloud when you change the version. Pick the newest version and the list says you are up to date. Choosing a change names it on the drawn page; nothing opens. For preview the menu is drawn open in place when the page loads; the field, or Ctrl or ⌘ K while focus is in the block, opens the real command dialog with the same version, word and query. For products with release notes, apps that update and libraries with a changelog worth reading.
FAQ
Why is the menu already open, and what do I keep?
So you can see it without a click. On load the menu is the Command drawn inline under the drawn bell, in a plain shell that is not modal, so nothing is trapped, hidden or focused and the page around the preview keeps working. The header's field opens the real command dialog, modal, with its focus trap, Escape and focus return, and the inline copy stays closed until a reload. Both show the same Palette and share the block's state, so the version, the word and the text you typed in the copy are in the real dialog. In your app keep the dialog and drop the copy: the "in-place" state, the scrim with its shell and the Escape and blur effects.
How does the version re-derive the list?
afterOf(since) takes the releases newer than the one you are on, and rowsFor lists their changes, grouped under each release's number and date. The counts on the chips and the count line come from the same releases, so they never disagree with the list. In your app the version you are on is the one you are running, read when the page loads, and the releases come from your changelog.
Why a native select?
A select that opens a popup inside a dialog fights the dialog's focus trap and its scrim, on some libraries more than others. The native one is the same on every library, works with the keyboard and the touch picker of every phone, and is named for screen readers ("The version you are on"). Changing it says how many changes there are since the version you picked.
How is a breaking change shown?
With the word Breaking after its text, in bold, never a colour; the count line counts them for what is listed ("2 breaking"), so filtering by word or typing changes it. Two of the fourteen changes since 4.0 break something in this demo.
Is it accessible from the keyboard?
Yes. Type to search, the arrow keys move through the changes, Enter opens the highlighted one and Escape closes the menu and puts focus on the field; Ctrl or ⌘ K opens the dialog while focus is inside the block, and only then. The select and the chips are above the input, in the tab order. The rows are options of a cmdk listbox; the block turns off its own fuzzy filter and lists the rows itself.
How does it look on a phone?
The select takes the full width above the chips, which scroll sideways. The copy shown on load docks to the top of the page at full width, so the keyboard does not cover the foot; the key hints go and the count stays. The real dialog keeps the Command dialog's own phone layout.
Related
- Pro
Filterable Changelog
Filters and browsingThe plainest filtered release list: one row of choices with counts (All, New, Improved, Fixed, Security) over nine releases, a live count of what is showing, and a height that never changes.
- 471Pro
Docs Search Command Menu
Search everythingA docs host's scoped search shown open under the header field: chips for All, Guides, Reference and Releases that carry how many pages match, and results with a path and one line of the page with the matched words marked.
- Pro
Recent Items Command Menu
Search everythingA project hub's command menu shown open on what you opened lately: Today, Yesterday and Earlier buckets before you type, recent matches first when you do, opening a row moves it to the top, and a last row clears the list.
- Pro
Help Center Command Menu
Pages and docsA messaging app's help centre as a command menu shown open beside an article pane: articles and video tutorials filter as you type, the pane shows the highlighted one's first paragraph, three headings and related reading, and a contact support row is never filtered out.
- Pro
Expandable Release Entries
Lists and timelinesFour release rows that each open to a sentence and a copyable migration snippet in a focusable code region; the newest is open on load and any number can be open.
- Pro
Notification Bell Navbar
Meters and progressAn app navbar for a team inbox with a bell whose count follows what you do: the bell opens a panel with All and Unread tabs, rows you can mark read, mark unread or dismiss, and Mark all as read, and a drawer on phones.