uibrik

Boarding Pass

New

Preview

Customize

Tear angle14°

Usage

import { BoardingPass } from "@/components/uibrik/boarding-pass/boarding-pass";

<BoardingPass />

Installation

npx shadcn@latest add https://uibrik.com/r/boarding-pass.json
Adds the files to components/uibrik/boarding-pass and installs @tabler/icons-react and motion. With the @uibrik namespace set up: npx shadcn@latest add @uibrik/boarding-pass.

Props

BoardingPass
from
Type string
"SFO"
Departure airport code.
to
Type string
"JFK"
Arrival airport code.
passenger
Type string
"Maya Chen"
Passenger name.
flight
Type string
"UB 204"
Flight number.
gate
Type string
"B12"
Boarding gate.
seat
Type string
"14A"
Seat, printed large on the stub.
tearAngle
Type number
14
How far the stub swings by the time the last bridge breaks.
fromCity
Type string
"San Francisco"
City under the departure code.
toCity
Type string
"New York"
City under the arrival code.
date
Type string
"14 Oct"
Shown top right until the stub is torn.
boarding
Type string
"09:40"
Boarding time.
torn
Type boolean
–
Torn state, when controlled.
defaultTorn
Type boolean
false
Initial torn state when uncontrolled.
onTornChange
Type (torn: boolean) => void
–
Called when the stub is torn.
className
Type string
–
Classes for the wrapper.