SearchCtrlK

  • ↑↓navigate
  • ↵open
  • escclose

Can’t find it? Contact us

On this page

BoardingPass

A wallet-style boarding pass.

Larkwing Air

From MRWMarrow Bay08:40

To VLSVellis11:05

Passenger
Ana Ortiz
Flight
LK 482
Date
14 Mar
Boards
08:05
Gate
B12
Seat
14C
Zone
3
Cabin
Economy
Confirmation
K7Q2XR
View code
tsx
<BoardingPass
	label="Boarding pass, Marrow Bay to Vellis"
	airline={{ name: "Larkwing Air", mark: <LarkwingMark /> }}
	passenger="Ana Ortiz"
	from={{ code: "MRW", city: "Marrow Bay", time: "08:40" }}
	to={{ code: "VLS", city: "Vellis", time: "11:05" }}
	flight="LK 482"
	date="14 Mar"
	boards="08:05"
	gate="B12"
	seat="14C"
	zone="3"
	cabin="Economy"
	confirmation="K7Q2XR"
	code="LK482|20260314|MRWVLS|14C|K7Q2XR"
	labels={{
		passenger: "Passenger", flight: "Flight", date: "Date", boards: "Boards", gate: "Gate",
		seat: "Seat", zone: "Zone", cabin: "Cabin", confirmation: "Confirmation",
		from: "From", to: "To", code: "Boarding code for confirmation K7Q2XR",
	}}
/>

Installation

An ordinary dependency: install it, import the theme once, and import the component where it is used.

Terminal
npm add @sdxc/ui remix
typescript
import "@sdxc/ui/theme.css";

Usage

typescript
import { BoardingPass } from "@sdxc/ui/travel";

Renders the pass: an <article> named by label whose top part holds the airline band, the route and the details as a <dl>, and whose stub, below a perforated tear, holds the PassCode. It prints in full colour, unshadowed and outlined, on one page.

Props

Read from the component's own types, so every prop, every default and every allowed value is listed.

PropTypeRequiredDescription
labelstringYesNames the pass for assistive technology, e.g. "Boarding pass, MRW to VLS".
airlineAirlineYes
passengerRemixNodeYes
fromPlaceYes
toPlaceYes
flightRemixNodeYes
dateRemixNodeYes
gateRemixNodeYes
boardsRemixNodeYesWhen boarding starts, formatted by the caller.
seatRemixNodeYes
zoneRemixNodeYes
cabinRemixNodeYes
confirmationRemixNodeYes
codestringYesThe data the code art stands for; the same string always draws the same pattern.
labelsLabelsYes

Also accepts everything in Omit<TagProps<"article">, "children">.

Other components this module publishes.

  • PassCode
@sdxc/ui

Can’t find it? Contact us