@voyantjs/catalog-react
v0.117.1
Published
The catalog client tier: headless data hooks/clients plus the styled UI primitives and page-level compositions (formerly `@voyantjs/catalog-ui`).
Readme
@voyantjs/catalog-react
The catalog client tier: headless data hooks/clients plus the styled UI
primitives and page-level compositions (formerly @voyantjs/catalog-ui).
Headless consumers (storefronts, portals) import from the root, ./hooks,
./client, or ./booking-engine — these pull no styling peers. Styled
surfaces live under ./ui, ./components/*, ./admin, ./i18n, and
./styles.css, whose heavier peers (@voyantjs/ui, @voyantjs/admin,
@tanstack/react-table, sonner) are optional and only needed when you
import those subpaths.
Page Compositions
CatalogPage owns the tabbed catalog search layout and default vertical columns.
Apps provide routing and deployment-specific behavior through callbacks:
search,onTabChange,onQueryChange, andonPageChangefor URL state.formatSupplierfor supplier id labels.onBookHit,onBookDeparture,onOpenProductEditor, andonLoadProductDetailfor route transitions and content APIs.detailSheetWidth,detailHeaderExtras,renderDetailBrochure,renderDetailMedia,renderDetailItineraryDay, andrenderDetailExtraSectionsfor consumer-specific catalog detail sections such as brochure downloads, print actions, provenance cards, and richer media or itinerary layouts.
CatalogBookingPage owns the quote-to-book form. Apps pass the route state plus
fetchers, typically from createCatalogBookingFetchers({ baseUrl }), and may
slot in their own contact picker via renderContactPicker.
I18n
The package exports CatalogUiMessagesProvider, catalogUiEn, and
catalogUiRo from @voyantjs/catalog-react/i18n. Components fall back to English
when no provider is mounted.
