A salon appointment booking screen built with Tailwind CSS: service cards, stylist avatars, a date strip for the next 14 days, a time slot grid and a summary bottom sheet with confirm. It is an HTML mobile template for salon websites and PWAs and can be packaged as a native app with Capacitor. Use it as the booking flow or appointment scheduling UI of a hair salon, beauty studio or barber app.
How it works
The root .sab-app is a phone-width column with a sticky top app bar, the booking sections and a sticky .sab-bar that shows the running total and duration. Each .sab-svc card is a toggle button with aria-pressed; its data-price and data-min values feed updateTotals(), so several services can be combined. Stylists are native radio inputs inside .sab-sty labels.
script.js builds the date strip from today forward (DAYS_AHEAD), so the dates never go stale. Weekdays in CLOSED_WEEKDAYS are marked Closed and disabled. Picking a date or stylist re-renders the SLOTS grid; past slots and those isBooked() marks as taken are disabled.
Review booking checks that a service and a time are chosen, then opens #sab-sheet, a native <dialog> bottom sheet with the summary and a contact form. Confirm validates name and phone, simulates the request and shows a booking code.
Customization
--sab-rose,--sab-rose-darkand--sab-softon.sab-appinstyle.css: primary colour of selected cards, the date strip and buttons.- Add or remove services by copying a
.sab-svcbutton; setdata-sab-svc,data-priceanddata-min. SLOTSinscript.js: the opening times shown in the grid.CLOSED_WEEKDAYSandDAYS_AHEADinscript.js: closing days and how far ahead clients can book.isBooked(): replace the sample availability with data from your booking API.- Add a stylist by copying a
.sab-stylabel with a newvalueanddata-name, and add the id to the list used for Any stylist inrenderSlots(). font-familyon.sab-app: replace Jost and update the Google Fonts URL.
Use cases
- Hair salons: clients pick services, a stylist and a free time in one screen.
- Beauty, nail and brow studios: combine treatments with a live total.
- Barber shops: quick booking with stylist choice.
- Spa and wellness apps: schedule treatments in a PWA or Capacitor app.
Accessibility
Service cards announce their state with aria-pressed, and total changes are read out through a polite live region. Stylists, dates and slots are radio groups: arrow keys, Home and End move the selection, unavailable slots are disabled and labelled. Validation messages appear next to the fields with aria-invalid and aria-describedby. The sheet is a modal dialog that closes with Escape or the backdrop and returns focus to Review booking. All targets are at least 44 px and the sheet animation stops under prefers-reduced-motion.
Usage notes
The photos come from Unsplash; replace them with your own salon and team images. Swap the setTimeout in the submit handler for a fetch() call to your booking backend.