204 Pro components and page blocks

Get Pro

Updated

Seat Map

Pro

Preview

Customize

Color
Seats per order6
Hold10min
USD
Width560px

Installation

Pro

Seat Map is a Pro component

Sign in to see the source, or install it with a license key. The live preview and props above are free to explore.

Install with a key

  1. Add the Pro registry to components.json:
    components.json
    {
      "registries": {
        "@uibrik-pro": {
          "url": "https://uibrik.com/r/pro/{name}.json",
          "headers": { "Authorization": "Bearer ${UIBRIK_LICENSE}" }
        }
      }
    }
  2. Put your key in .env.local and add that file to .gitignore:
    .env.local
    UIBRIK_LICENSE=your-license-key
  3. Install it:
    Terminal
    npx shadcn@latest add @uibrik-pro/seat-map

Usage

import { SeatMap } from "@/components/uibrik/seat-map/seat-map";​const sections = [  { id: "orchestra", name: "Orchestra", from: 64, to: 116, inner: 64, outer: 142, rows: 10, price: 120, premiumRows: 3, premium: 30, view: "Full view of the stage" },  { id: "left", name: "Left wing", from: 121, to: 154, inner: 64, outer: 142, rows: 10, price: 90, view: "Side view, close to the stage" },  // …2 more];​<SeatMap  color="#2f7cf6"  max={6}  hold={10}  currency="USD"  cta="Checkout"  width={560}  sections={sections}  defaultValue={[]}  onCheckout={(seats) => {}}  // taken={["…"]}  // accessible={["…"]}  // value={["…"]}  // onChange={(ids, seats) => {}}/>

Where to use Seat Map

  • Event and theatre ticketing

    Sections first, seats on zoom, so buyers choose by price and view without a wall of dots.

    Pairs with Checkout Flow

  • Flight and train seat selection

    Swap the sections for cabins and the same zoom and tray handle seat picks.

    Pairs with Boarding Pass

  • Venue and table booking

    Seats left and prices per section answer the first questions before anyone zooms in.

Props

SeatMap
color
Type string
"#2f7cf6"
Colour the price tiers are shaded from.
max
Type number
6
Most seats one person can pick.
hold
Type number
10
Minutes picked seats are held; 0 turns the timer off.
currency
Type "USD" | "EUR" | "GBP" | "INR" | "JPY"
"USD"
Currency for prices.
cta
Type string
"Checkout"
Label of the button in the tray.
width
Type number
560
Width of the card; never wider than its container.
sections
Type { id; name; from; to; inner; outer; rows; price; premiumRows?; premium? }[]
–
Sections as arcs around the stage: angles in degrees (90 faces the stage), distances for the first and last row, and a price; the first rows can cost more.
taken
Type string[]
–
Sold seat ids, e.g. "orchestra-C-7". Defaults to a sample.
accessible
Type string[]
–
Wheelchair space ids. Defaults to the ends of each back row.
value / onChange
Type string[] / (ids, seats) => void
–
Picked seat ids, controlled.
defaultValue
Type string[]
[]
Picked seats on mount when uncontrolled.
onCheckout
Type (seats: Seat[]) => void
–
Called when the tray button is pressed.
className
Type string
–
Classes for the wrapper.