Skip to content

pastetaste

Pickup Slot Order

FormsInteractionSections

A three-step pickup ordering sheet: pick a counter, pick a day and a 15-minute slot from that counter's opening hours (full slots struck out), add name and phone, with a live order list that unlocks the order button.

Paste it into Claude Code: it installs the component, asks for your brand and content, and places it on the page you name.

Install

Or by hand, in a Next.js project with shadcn set up. It writes components/pastetaste/pickup-slot-order.tsx.

npx shadcn@latest add https://pastetaste.com/r/pickup-slot-order.json

Prompt

Install the pastetaste component "Pickup Slot Order" (pickup-slot-order) into this Next.js project and use it.

What it is: A three-step pickup ordering sheet: pick a counter, pick a day and a 15-minute slot from that counter's opening hours (full slots struck out), add name and phone, with a live order list that unlocks the order button.

Before you place it, ask me (one short message, in my language; "skip" = sensible default): which page and section it goes in, my brand colour (hex), the text, labels or images it should show, and whether I want my logo or my own copy in the demo content. Then:

Steps:
1. If the project has no components.json, run: npx shadcn@latest init -y -d. Then run: npx shadcn@latest add https://pastetaste.com/r/pickup-slot-order.json
   (it writes components/pastetaste/pickup-slot-order.tsx; install any npm packages it reports).
2. Import it: import { PickupSlotOrder } from "@/components/pastetaste/pickup-slot-order" (check the file for the exact named export).
3. Put it where it fits on the page I name, keep the rest of the page untouched, and pass props for my colours instead of editing the installed file.
4. It does not depend on Tailwind; colours come from CSS variables (--pt-*) or props.
5. It supports prefers-reduced-motion with a still state; do not remove it.

Props (all optional unless the type has no default):
- locations: PickupLocation[] — Counters with id, name, optional detail and hours: seven [open, close] pairs, Sunday first.
- initialLines: PickupLine[] = [] — Order lines { key, name, desc?, price, qty } the cart starts with.
- step: number = 15 — Minutes between slots.
- days: number = 2 — Days offered, starting today.
- lead: number = 15 — Minimum minutes before the first slot of today.
- isFull: ({ location, dayOffset, minute }) => boolean — Marks a slot as full; the default fills about one in six deterministically.
- currency: string = '$' — Currency symbol.
- heading / note: string = 'Order for pickup' / 'Pay at the counter.' — Title and the line under it.
- onPlace: (order, lines) => void — Called with the placed order (code, when, location, total, name, phone).
- className / style: string / CSSProperties — On the root.

Live preview: https://pastetaste.com/c/pickup-slot-order
Then run the dev server, check it in the browser at desktop and mobile width, and tell me the page URL.

Props 10

PropTypeDefaultDescription
locationsPickupLocation[]-Counters with id, name, optional detail and hours: seven [open, close] pairs, Sunday first.
initialLinesPickupLine[][]Order lines { key, name, desc?, price, qty } the cart starts with.
stepnumber15Minutes between slots.
daysnumber2Days offered, starting today.
leadnumber15Minimum minutes before the first slot of today.
isFull({ location, dayOffset, minute }) => boolean-Marks a slot as full; the default fills about one in six deterministically.
currencystring'$'Currency symbol.
heading / notestring'Order for pickup' / 'Pay at the counter.'Title and the line under it.
onPlace(order, lines) => void-Called with the placed order (code, when, location, total, name, phone).
className / stylestring / CSSProperties-On the root.
View all →