Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
54 commits
Select commit Hold shift + click to select a range
7f3975e
docs(agents): add agent skills configuration
pasqualevitiello Nov 20, 2026
54fc641
docs: add glossary and the booker data-layer decision record
pasqualevitiello Nov 20, 2026
8964873
feat(booker): carry over the booker atom work in progress
pasqualevitiello Nov 20, 2026
d52d319
chore(booker): add a throwaway prototype of the booking form
pasqualevitiello Nov 20, 2026
d49c754
chore(booker): refine the form prototype variants
pasqualevitiello Nov 20, 2026
a9951ad
chore(booker): keep only the chosen form layout in the prototype
pasqualevitiello Nov 20, 2026
aeaf08a
chore(booker): add a throwaway prototype of the confirmation screen
pasqualevitiello Nov 20, 2026
01c44d5
chore(booker): keep only the chosen confirmation layout in the prototype
pasqualevitiello Nov 20, 2026
fab7b5f
chore(booker): add a throwaway prototype of reschedule and cancel
pasqualevitiello Nov 20, 2026
941708d
fix(booker): give the reschedule pane in prototype variant A a width
pasqualevitiello Nov 21, 2026
0eb7bd4
chore(booker): reschedule on the Booker's own select step in the prot…
pasqualevitiello Nov 21, 2026
bf3cb62
refactor(booker): let BookerSteps take any step key
pasqualevitiello Nov 21, 2026
5f02d8a
chore(booker): prototype reschedule and cancel as steps of the bookin…
pasqualevitiello Nov 21, 2026
751b5f2
chore(booker): add a throwaway prototype of the email verification step
pasqualevitiello Nov 21, 2026
db66a9d
refactor(booker): animate BookerSteps without motion
pasqualevitiello Nov 21, 2026
3fabeb7
refactor(booker): remove every animation from the Booker for now
pasqualevitiello Nov 21, 2026
cdb997a
fix(booker): give headings the weights coss uses
pasqualevitiello Nov 21, 2026
97849bb
chore(booker): keep only the chosen email verification variant
pasqualevitiello Nov 21, 2026
9334f48
chore(playground): hide the variant arrows when a prototype has one v…
pasqualevitiello Nov 23, 2026
dd1857f
chore(booker): add a throwaway prototype of the instant meeting flow
pasqualevitiello Nov 23, 2026
4db8b41
fix(booker): build the host avatars on AvatarGroup, and use them in e…
pasqualevitiello Nov 23, 2026
8e76f85
chore(booker): add a bottom-bar variant to the instant meeting prototype
pasqualevitiello Nov 23, 2026
9d6a81d
chore(booker): keep only the chosen instant meeting variant
pasqualevitiello Nov 23, 2026
8c2a97f
chore(booker): add a throwaway prototype of recurring and seated book…
pasqualevitiello Nov 23, 2026
a8265aa
chore(booker): follow the design system for recurrence and seats in t…
pasqualevitiello Nov 23, 2026
a87bb86
chore(booker): copy the design system's recurrence and seat markup ex…
pasqualevitiello Nov 23, 2026
c7e3ad9
chore(booker): add a throwaway prototype of the collective host picker
pasqualevitiello Nov 23, 2026
0446ee6
chore(booker): pick hosts with a combobox, as Cal's HostSelect does
pasqualevitiello Nov 23, 2026
e095506
chore(booker): go back to the multiple Select for picking hosts
pasqualevitiello Nov 23, 2026
13b4259
chore(booker): pick hosts with coss's multiple combobox
pasqualevitiello Nov 23, 2026
553d8dc
chore(booker): pick hosts from a button combobox that allows several
pasqualevitiello Nov 23, 2026
dde81f0
chore(booker): add a Clear button to the host picker, as Cal's filter…
pasqualevitiello Nov 23, 2026
10e5e01
chore(booker): drop the host picker's Clear button
pasqualevitiello Nov 23, 2026
40841d1
fix(booker): give the host picker prototype times when every host is …
pasqualevitiello Nov 23, 2026
7b22925
feat(booker): rebuild the time list on the design system's Booker tim…
pasqualevitiello Nov 23, 2026
f6e0183
feat(booker): match the event information to the design system
pasqualevitiello Nov 23, 2026
a72c77f
feat(booker): port the design system's Booker calendar
pasqualevitiello Nov 23, 2026
62552d7
feat(booker): build the prototypes' event information and select step…
pasqualevitiello Nov 23, 2026
d47bf6f
Merge remote-tracking branch 'origin/main' into feat/booker-atom
pasqualevitiello Nov 23, 2026
b21ab74
feat(booker): show the decided confirmation screen after a booking
pasqualevitiello Nov 23, 2026
7141586
fix(booker): use the design system's plain icons in the location popover
pasqualevitiello Nov 23, 2026
929debe
fix(booker): keep the provider logos in the location popover, without…
pasqualevitiello Nov 23, 2026
76368cb
fix(booker): take a group link's week start from its first username
pasqualevitiello Nov 23, 2026
05e7ff9
fix(booker): set the Cal.com wordmark in the font guide's brand role
pasqualevitiello Nov 23, 2026
08cda8e
fix(booker): set the Cal.com logo smaller, with GEOM 50 and opsz 32
pasqualevitiello Nov 23, 2026
5e2172f
Revert "fix(booker): take a group link's week start from its first us…
pasqualevitiello Nov 23, 2026
0776522
fix(booker): keep the variation settings on the logo only
pasqualevitiello Nov 23, 2026
022229f
feat(booker): stronger fill on available days and times, and group ti…
pasqualevitiello Nov 23, 2026
401e205
fix(booker): put available days and times back on bg-muted
pasqualevitiello Nov 23, 2026
d49c6d4
revert(booker): show the times as one flat list again
pasqualevitiello Nov 24, 2026
71486dd
feat(booker): show load errors in Cal Video's error card
pasqualevitiello Nov 24, 2026
533edae
feat(booker): ship the Booker as one registry item
pasqualevitiello Nov 24, 2026
1407e75
feat(booker): show the split first and last name field
pasqualevitiello Nov 24, 2026
f79d77a
feat(booker): render the event description as Cal's Booker does
pasqualevitiello Nov 24, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,17 @@ The comprehensive agent guidelines for this repository are located in:
## Typography

Set type per the [Cal Sans font guide](packages/ui/src/fonts/font-guide.md): no added letter-spacing, `font-optical-sizing: auto` instead of a hard-coded `opsz`, one `GEOM` value per role, no synthesized bold or italic, and typeset punctuation (’ – − “ ”) in UI strings.

## Agent skills

### Issue tracker

Issues and specs live as markdown files under `.scratch/<feature-slug>/`. See `docs/agents/issue-tracker.md`.

### Triage labels

The five default triage roles, recorded as a `Status:` line in each issue file. See `docs/agents/triage-labels.md`.

### Domain docs

Single-context: one `GLOSSARY.md` and `docs/adr/` at the repo root. See `docs/agents/domain.md`.
33 changes: 33 additions & 0 deletions GLOSSARY.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# coss ui

A registry of copy-paste React components installed with the shadcn CLI. This glossary fixes the words used for the kinds of thing the registry ships.

## Language

**Atom**:
A registry item that connects coss ui components to the Cal.com API, so it works against real scheduling data once installed.
_Avoid_: Cal atom, widget, block, embed

**Booker**:
The atom that lets someone pick a time and book a Cal.com event.
_Avoid_: Booking widget, scheduler, calendar embed

**Event type**:
What an attendee books: a kind of meeting a host offers on Cal.com, with its own title, duration, locations and rules.
_Avoid_: Event, target, meeting type, booking link

**Attendee**:
The person booking an event through the Booker.
_Avoid_: Booker (for the person), visitor, user, customer

**Guest**:
A person the attendee adds to their booking.
_Avoid_: Additional attendee, invitee

**Fallback**:
What the Booker shows in place of the booking flow when an event cannot be booked through it: a short message and a link to the event's own Cal.com booking page.
_Avoid_: Error state, unsupported screen

**Particle**:
A pre-assembled registry item that combines several primitives into a ready-to-use piece of interface, with no connection to an outside service.
_Avoid_: Block, pattern, atom
50 changes: 50 additions & 0 deletions apps/ui/app/playground/booker/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
import type { Metadata } from "next";
import { Booker } from "@/registry/default/booker/booker";
import { fetchRawBookerDataAction } from "@/registry/default/booker/lib/actions";
import type { BookerTarget } from "@/registry/default/booker/lib/target";

export const metadata: Metadata = {
title: "Booker Playground - coss ui",
};

const defaultBookingUrl = "https://i.cal.com/pasquale/15min";
const timeZone = "Europe/Rome";

type BookerPlaygroundPageProps = {
searchParams: Promise<{ bookingUrl?: string | string[] }>;
};

// Temporary demo page. Pass `?bookingUrl=` to point the Booker at another
// event, e.g. `?bookingUrl=cal.com/rickastley/15min`.
export default async function BookerPlaygroundPage({
searchParams,
}: BookerPlaygroundPageProps) {
const { bookingUrl } = await searchParams;
const target = {
bookingUrl:
typeof bookingUrl === "string" && bookingUrl.trim()
? bookingUrl
: defaultBookingUrl,
type: "link",
} satisfies BookerTarget;

const initialInput = {
fetchMeta: true,
monthIso: new Date().toISOString(),
monthsToFetch: 3,
target,
timeZone,
};
const initialData = {
monthIso: initialInput.monthIso,
monthsToFetch: initialInput.monthsToFetch,
result: await fetchRawBookerDataAction(initialInput),
timeZone: initialInput.timeZone,
};

return (
<main className="container flex min-h-svh w-full items-center py-10">
<Booker initialData={initialData} target={target} />
</main>
);
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
"use client";

// PROTOTYPE ONLY. Mounts one confirmation variant with a synthetic booking,
// the state panel and the switcher.

import { useEffect, useState } from "react";
import { PrototypeSwitcher } from "../../prototype-switcher";
import {
bookings,
type ScenarioKey,
scenarios,
type VariantKey,
variants,
} from "./fixtures";
import { VariantA, type VariantProps } from "./variants";

const variantComponents: Record<
VariantKey,
(props: VariantProps) => React.ReactElement
> = { A: VariantA };

export function ConfirmationPrototype({
variant,
scenario,
}: {
variant: VariantKey;
scenario: ScenarioKey;
}) {
const [lastAction, setLastAction] = useState("none");
const booking = bookings[scenario];
const Variant = variantComponents[variant];

// biome-ignore lint/correctness/useExhaustiveDependencies: reset on switch
useEffect(() => {
setLastAction("none");
}, [scenario, variant]);

return (
<div className="@container flex w-full flex-col items-center gap-4 pb-24">
<Variant booking={booking} onAction={setLastAction} />

<pre className="w-full max-w-3xl overflow-x-auto rounded-lg border border-dashed p-3 text-muted-foreground text-xs">
{JSON.stringify(
{ lastAction: `${lastAction} (stub)`, scenario, variant, booking },
null,
2,
)}
</pre>

<PrototypeSwitcher
scenario={scenario}
scenarios={scenarios.map((item) => ({ ...item }))}
variant={variant}
variants={variants.map((item) => ({ ...item }))}
/>
</div>
);
}
117 changes: 117 additions & 0 deletions apps/ui/app/playground/booker/prototype-confirmation/fixtures.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,117 @@
// PROTOTYPE ONLY. Synthetic bookings, modelled on what Cal's API returns after
// a booking is created. No network.

export type ProtoLocation =
| { kind: "video"; label: string; link: string }
| { kind: "address"; label: string; address: string }
| { kind: "phone"; label: string; phone: string };

export type ProtoOccurrence = { date: string; time: string };

export type ProtoBooking = {
status: "accepted" | "pending";
title: string;
description: string;
host: string;
hostInitials: string;
date: string;
time: string;
// The same start, local time, for the event pane's selected time.
start: Date;
durationMinutes: number;
timeZone: string;
location: ProtoLocation;
attendee: { name: string; email: string };
guests: string[];
notes?: string;
// Set for a recurring series; `date` and `time` are then the first one.
occurrences?: ProtoOccurrence[];
};

const base: ProtoBooking = {
attendee: { email: "dana@example.com", name: "Dana Whitfield" },
date: "Monday, November 23, 2026",
description: "A walkthrough tailored to your team, with time for questions.",
durationMinutes: 30,
guests: [],
host: "Rick Astley",
hostInitials: "RA",
location: {
kind: "video",
label: "Cal Video",
link: "https://app.cal.com/video/abc123",
},
start: new Date(2026, 10, 23, 10, 0),
status: "accepted",
time: "10:00 – 10:30am",
timeZone: "Europe/Rome",
title: "Product demo",
};

export const bookings = {
accepted: base,
inPerson: {
...base,
guests: ["sam@example.com", "priya@example.com"],
location: {
address: "Via Torino 12, 20123 Milan",
kind: "address",
label: "In person",
},
notes: "We would like to see the routing features in particular.",
},
pending: { ...base, status: "pending" },
recurring: {
...base,
occurrences: [
{ date: "Monday, November 23, 2026", time: "10:00 – 10:30am" },
{ date: "Monday, November 30, 2026", time: "10:00 – 10:30am" },
{ date: "Monday, December 7, 2026", time: "10:00 – 10:30am" },
{ date: "Monday, December 14, 2026", time: "10:00 – 10:30am" },
],
},
} satisfies Record<string, ProtoBooking>;

export const variants = [{ key: "A", label: "In place" }] as const;

export type VariantKey = (typeof variants)[number]["key"];

export const scenarios = [
{ key: "accepted", label: "Confirmed" },
{ key: "pending", label: "Awaiting the host" },
{ key: "recurring", label: "Recurring series" },
{ key: "inPerson", label: "In person, guests, notes" },
] as const;

export type ScenarioKey = (typeof scenarios)[number]["key"];

export const calendars = ["Google", "Outlook", "Apple or other (.ics)"];

export function getHeadline(booking: ProtoBooking) {
if (booking.status === "pending") {
return {
text: `${booking.host} needs to confirm this booking. We’ll email ${booking.attendee.email} when they do.`,
title: "Waiting for confirmation",
};
}
if (booking.occurrences) {
return {
text: `Calendar invitations are on their way to ${booking.attendee.email}.`,
title: `${booking.occurrences.length} meetings booked`,
};
}
return {
text: `A calendar invitation is on its way to ${booking.attendee.email}.`,
title: "You’re booked",
};
}

export function getLocationText(location: ProtoLocation) {
if (location.kind === "video") {
return location.label;
}
if (location.kind === "address") {
return location.address;
}
return location.phone;
}
44 changes: 44 additions & 0 deletions apps/ui/app/playground/booker/prototype-confirmation/page.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
// PROTOTYPE ONLY. Throwaway route for the wayfinder ticket "The confirmation
// screen" (.scratch/booker/issues/09-confirmation-screen.md).
//
// The chosen layout of what an attendee sees after booking, with a synthetic
// booking picked by the `scenario` search param. Nothing is sent. The two
// layouts that lost are on the `prototype/booker-confirmation` branch.

import type { Metadata } from "next";
import { ConfirmationPrototype } from "./confirmation-prototype";
import {
type ScenarioKey,
scenarios,
type VariantKey,
variants,
} from "./fixtures";

export const metadata: Metadata = {
title: "Booker confirmation prototype - coss ui",
};

type PageProps = {
searchParams: Promise<{
variant?: string | string[];
scenario?: string | string[];
}>;
};

export default async function BookerConfirmationPrototypePage({
searchParams,
}: PageProps) {
const params = await searchParams;
const variant =
variants.find((item) => item.key === params.variant)?.key ??
("A" satisfies VariantKey);
const scenario =
scenarios.find((item) => item.key === params.scenario)?.key ??
("accepted" satisfies ScenarioKey);

return (
<main className="container flex min-h-svh w-full items-start py-10">
<ConfirmationPrototype scenario={scenario} variant={variant} />
</main>
);
}
Loading
Loading