Products
Product management header
Title, share URL and actions above the product editor.
Available
Needs mock props
Examples
Rendered live from the maintained Storybook story. Lantern stores only the story id and embeds Storybook rather than duplicating the component or its demo.
Product management header
Rendered live from Storybook
Storybook must be running for this to load — bun run start:storybook from the monorepo root, or set NEXT_PUBLIC_STORYBOOK_URL to a deployed instance.
Props
The component's public API, read from its TypeScript source. Descriptions come from TSDoc on the prop, so this table cannot drift from the component.
| Prop | Type | Default | Description |
|---|---|---|---|
title* | string | — | Product name. Truncates; the badge beside it never shrinks. |
typeLabel* | string | — | Category pill copy — "Course", "Event", "Merch"… |
onDelete* | () => void | — | Delete was chosen from the overflow menu. |
onBack | () => void | — | Back was pressed, from either the desktop button or the mobile icon. Replaces `navigate("/creator/products?space=…")`. |
onCopyUrl | (url: string) => void | — | Copy URL was chosen. Receives `shareUrl`. The app wrote to the clipboard and fired a toast itself; the host owns both now — see the promotion note. |
onEdit | () => void | — | Edit product was chosen. |
shareUrl | string | DEFAULT_PRODUCT_SHARE_URL | The URL handed to `onCopyUrl`. Replaces the `window.location.href` read. |
defaultMenuOpen | boolean | — | Uncontrolled seed for the overflow menu, so the open menu is a snapshot. |
menuOpen | boolean | — | Controlled overflow menu state. |
onMenuOpenChange | (open: boolean) => void | — | Undocumented — add TSDoc to the prop in the library. |
className | string | — | Undocumented — add TSDoc to the prop in the library. |
Reference
Transcribed from the component audit. If this disagrees with the source, the source is right.
- Source
src/components/products/ProductManagementHeader.tsx- Portability
- Needs its app dependencies replaced by props before it renders in isolation.