StealThis .dev
Pages Hard

Ticketing — Seat Selection Map

An interactive event-ticketing seat picker built with vanilla JavaScript and an SVG venue chart. Fans pan and zoom across a tiered arena, filter sections by price using a color legend, and tap open seats to add them to a live cart that totals subtotal, service fee, and grand total. Seat states cover available, selected, taken, and accessible, with a six-seat max guard, keyboard support, toast feedback, and a countdown to showtime.

Open in Lab
html css vanilla-js
Targets: JS HTML

Code

Seat Selection Map

A high-contrast event-ticketing seat picker for the fictional Aurora Pulse — World Tour date at The Helix Arena. The venue is drawn as a live SVG chart with a darkened stage, four banked sections, and hundreds of individually addressable seats. Each seat carries a price tier (VIP Pit, Lower Bowl, Mezzanine, Upper Deck) and a state — available, selected, taken, or wheelchair-accessible — distinguished by both fill and outline so the chart reads clearly without relying on color alone.

The map is fully zoomable and pannable: scroll or use the +/− controls to scale between 55% and 240%, drag to pan, and hit Reset to recenter. Clicking the color-coded legend chips filters the chart down to a single price tier, dimming the rest so a fan can scan only the seats in their budget. Tapping an open seat drops it into the selection rail, which animates each row in, shows the tier tag and price, and recomputes subtotal, a 14% service fee, and the running total instantly. A six-seat-per-order guard and a taken-seat block both fire friendly toast messages.

Everything is plain HTML, CSS custom properties, and a single dependency-free script. Seats are generated deterministically so the “taken” pattern stays stable, the selection cart is keyboard-operable, and a ticket-stub perforation plus a live countdown to doors complete the energetic ticketing feel — all responsive down to a 360px phone.

Illustrative UI only — fictional events, not a real ticketing service.