A tick box for choosing options or marking things done
Space ticks the box in focus; the parent ticks both
pnpm dlx shadcn@latest add https://notchset.dev/r/checkbox.jsonA box you tick: a rounded square in a form, round for completing something.
Every shadcn style · one file
Import it and pass your content. The props that matter most are listed next.
"use client";
import * as React from "react";
import { Check } from "@/lib/notchset/icons";
import { cn } from "@/lib/utils";
import { Checkbox } from "@/components/ui/notchset/checkbox";
import { RollingNumber } from "@/components/ui/notchset/rolling-number";
import { buttonBase, buttonIntents, buttonSizes, QUIET_PILL } from "@/lib/notchset/button-look";
import { useLessMotion } from "@/lib/notchset/motion";
import { pressIn, useSelfPlay } from "./self-play";
import { FormCard } from "./scene-kit/hosts";
import { METRICS } from "./scene-kit/data";
/* At work, an export of deals to Dropbox. Each box changes what the export holds, so the button's count and the file line
answer every tick; the whole row is the target. Export fills green from where you pressed it, becomes its result
with an Undo, and the card glows once. With the consent row (the Consent required state), Export refuses until the
addendum is ticked: the row shakes once and says why. */
const OPEN = METRICS.find((m) => m.id === "deals")?.value ?? 248;
const CLOSED = 61;
const fileLine = (deals: number, notes: boolean, files: boolean) => {
const mb = deals * 0.005 + (notes ? deals * 0.009 : 0) + (files ? deals * 0.6 : 0);
return `${files ? "ZIP" : "CSV"} · ${mb < 10 ? mb.toFixed(1) : Math.round(mb)} MB`;
};
/* changed words leave by a short blur and the new ones clear from it, in one cell; nothing on arrival */
function Swap({ id, render, className }: { id: string; render: (id: string) => React.ReactNode; className?: string }) {
const [shown, setShown] = React.useState<{ id: string; was: string | null; n: number }>({ id, was: null, n: 0 });
if (shown.id !== id) setShown({ id, was: shown.id, n: shown.n + 1 });
return (
<span className={cn("inline-grid [&>*]:[grid-area:1/1]", className)}>
{shown.was !== null ? (
<span key={`was-${shown.n}`} aria-hidden data-ns-play-out="" className="[animation:ns-play-swap-out_var(--ns-play-swap)_var(--ns-ease-exit)_both]" onAnimationEnd={() => setShown((s) => ({ ...s, was: null }))}>
{render(shown.was)}
</span>
) : null}
<span key={`now-${shown.n}`} data-ns-play={shown.n ? "" : undefined} className={shown.n ? "[animation:ns-play-swap-in_var(--ns-play-swap)_var(--ns-ease)_both]" : undefined}>
{render(id)}
</span>
</span>
);
}
/* the button's width follows its words, easing, so a swap never leaves it roomy and never jumps a neighbour */
function EasedWidth({ children }: { children: React.ReactNode }) {
const inner = React.useRef<HTMLSpanElement>(null);
const [w, setW] = React.useState<number | null>(null);
React.useLayoutEffect(() => {
const el = inner.current;
if (!el) return;
const ro = new ResizeObserver(() => setW(el.offsetWidth));
ro.observe(el);
return () => ro.disconnect();
}, []);
return (
<span data-ns-glide="" className="relative inline-flex justify-center overflow-hidden transition-[width] duration-[var(--ns-play-swap)] ease-[var(--ns-ease-move)]" style={w === null ? undefined : { width: w }}>
<span ref={inner} className="inline-flex shrink-0 whitespace-nowrap">
{children}
</span>
</span>
);
}
/* The stage: a round task box over a square form box, alone and enlarged; on arrival each ticks once, the task then the
form, and they rest ticked. Ticking the task blooms its fill, draws the tick and
rings once, and its words fade to ink-3 (never struck); the form box squashes and its tick pops. Indeterminate: a
parent over two choices, mixed while one is on; ticking it ticks both, and from all on it clears both (on arrival it
ticks both once). Space ticks the box in focus. */
type Variant = "default" | "indeterminate";
const ROWS = { task: "Call Ana back", form: "Remember me" };
const NOTIFY = { parent: "Notify me", email: "By email", phone: "On my phone" };
const ROW = "text-[length:var(--ns-text-body)] leading-5";
export default function CheckboxDemo() {
const variant = "default" as Variant;
const root = React.useRef<HTMLDivElement>(null);
const less = useLessMotion();
const play = useSelfPlay(root, { beats: [400, 700], off: less });
React.useEffect(() => {
if (play.mine || play.taken === 0) return;
const boxes = root.current?.querySelectorAll<HTMLElement>("[data-slot=checkbox]");
if (variant === "indeterminate") {
if (play.taken === 1) pressIn(root.current, "[data-slot=checkbox]");
return;
}
boxes?.[play.taken - 1]?.click();
}, [play.taken, play.mine, variant]);
/* each variant's rows sit centred as a block, their width their own words */
return (
<div ref={root} onPointerDownCapture={play.handOver} onKeyDownCapture={play.handOver} className="flex w-full justify-center">
<div className="">{variant === "indeterminate" ? <Notify /> : <TaskAndForm />}</div>
</div>
);
}
function TaskAndForm() {
const words = ROWS;
const [done, setDone] = React.useState(false);
return (
<div className="flex w-fit flex-col items-start gap-4 pointer-coarse:gap-6">
<Checkbox variant="round" checked={done} onCheckedChange={setDone}>
<span className={cn(ROW, "transition-[color] duration-[var(--ns-btn-tick)]", done ? "text-[var(--ns-ink-3)]" : "text-[var(--ns-ink)]")}>{words.task}</span>
</Checkbox>
<Checkbox>
<span className={ROW}>{words.form}</span>
</Checkbox>
</div>
);
}
function Notify() {
const words = NOTIFY;
const [on, setOn] = React.useState({ email: true, phone: false });
const all = on.email && on.phone;
const some = on.email || on.phone;
return (
<div className="flex w-fit flex-col items-start gap-3 pointer-coarse:gap-6">
<Checkbox checked={all} indeterminate={some && !all} onCheckedChange={() => setOn(all ? { email: false, phone: false } : { email: true, phone: true })}>
<span className={ROW}>{words.parent}</span>
</Checkbox>
<div className="flex flex-col items-start gap-3 ps-7 pointer-coarse:gap-6">
<Checkbox checked={on.email} onCheckedChange={(v) => setOn((o) => ({ ...o, email: v }))}>
<span className={ROW}>{words.email}</span>
</Checkbox>
<Checkbox checked={on.phone} onCheckedChange={(v) => setOn((o) => ({ ...o, phone: v }))}>
<span className={ROW}>{words.phone}</span>
</Checkbox>
</div>
</div>
);
}
/* At work: an export of deals, each box changing what the export holds; the consent row refuses until ticked. */
export function AtWork() {
return <ExportDeals consent={false} />;
}
function ExportDeals({ consent }: { consent: boolean }) {
const said = { label: "Include closed deals", hint: "Required before deals leave the workspace" };
const words = said;
const [closed, setClosed] = React.useState(false);
const [notes, setNotes] = React.useState(false);
const [files, setFiles] = React.useState(false);
const [dpa, setDpa] = React.useState(false);
const [refused, setRefused] = React.useState(false);
const [done, setDone] = React.useState<number | null>(null);
const [press, setPress] = React.useState({ x: "50%", y: "50%" });
const deals = OPEN + (closed ? CLOSED : 0);
const blocked = consent && !dpa;
const change = (set: (v: boolean) => void) => (v: boolean) => {
set(v);
setDone(null);
};
const exportNow = (e: React.MouseEvent<HTMLButtonElement>) => {
if (done !== null) return;
if (blocked) {
/* a second refusal plays again: the error lifts for a frame and comes back */
setRefused(false);
requestAnimationFrame(() => requestAnimationFrame(() => setRefused(true)));
return;
}
/* the fill starts where the hand pressed; from the keyboard, at the centre */
const r = e.currentTarget.getBoundingClientRect();
const keyed = e.detail === 0;
setPress({ x: keyed ? "50%" : `${Math.round(e.clientX - r.left)}px`, y: keyed ? "50%" : `${Math.round(e.clientY - r.top)}px` });
setDone((n) => (n ?? 0) + 1);
};
const label = (form: string) => (
<span className="inline-flex items-center gap-1.5">
{form === "done" ? <Check className="size-4" aria-hidden /> : null}
<span>
{form === "done" ? "Exported" : "Export"} <RollingNumber value={String(deals)} className="tabular-nums" /> deals
</span>
</span>
);
return (
<FormCard
title="Export deals"
company="dropbox"
meta={
<>
To Dropbox · <Swap id={fileLine(deals, notes, files)} render={(t) => t} />
</>
}
className="relative [&_[data-slot=checkbox-label]]:flex [&_[data-slot=checkbox-label]]:w-full [&_[data-slot=checkbox-label]]:rounded-[var(--ns-radius-control)] [&_[data-slot=checkbox-label]]:px-3 [&_[data-slot=checkbox-label]]:py-2.5 [&_[data-slot=checkbox-label]]:[--ns-play-lift-shadow:var(--ns-depth-lift)] [&_[data-slot=checkbox-label]]:transition-[background-color,color] [&_[data-slot=checkbox-label]]:duration-[var(--ns-time-color)] [&_[data-slot=checkbox-label]:hover]:bg-[var(--ns-hover)] [&_[data-slot=checkbox-label]:has([aria-invalid=true])]:bg-[color-mix(in_oklab,var(--ns-bad)_var(--ns-tint-row),transparent)]"
footer={
<>
{done !== null ? (
<>
<span key={done} aria-hidden data-ns-play="ring" className="pointer-events-none absolute inset-0 rounded-[var(--ns-radius-card)] [animation:ns-play-ring_var(--ns-play-ring)_var(--ns-ease)_var(--ns-play-swap)_both]" />
<button type="button" data-ns-press="" data-ns-play="" className={cn(QUIET_PILL, "[animation:ns-play-swap-in_var(--ns-play-swap)_var(--ns-ease)_both]")} onClick={() => setDone(null)}>
Undo
</button>
</>
) : null}
<button
type="button"
data-ns-press=""
aria-disabled={blocked || undefined}
onClick={exportNow}
className={cn(
buttonBase,
buttonSizes.md,
"overflow-hidden tabular-nums",
done !== null
? "cursor-default px-[max(var(--ns-control-pad),14px)] bg-[var(--primary)] text-[var(--ns-on-fill)]"
: blocked
? "px-[max(var(--ns-control-pad),14px)] bg-[color-mix(in_oklab,var(--primary)_40%,transparent)] text-[var(--primary-foreground)]"
: buttonIntents.primary,
)}
style={{ "--ns-press-x": press.x, "--ns-press-y": press.y } as React.CSSProperties}
>
{done !== null ? <span key={done} aria-hidden data-ns-play="" className="absolute inset-0 bg-[var(--ns-play-fill-color)] [animation:ns-play-fill_var(--ns-play-fill)_var(--ns-ease-move)_both]" /> : null}
<EasedWidth>
<Swap id={done !== null ? "done" : "export"} render={label} />
</EasedWidth>
</button>
</>
}
>
<Checkbox checked={closed} onCheckedChange={change(setClosed)}>
{words.label}
</Checkbox>
<Checkbox checked={notes} onCheckedChange={change(setNotes)}>
Include notes
</Checkbox>
<Checkbox checked={files} onCheckedChange={change(setFiles)}>
Include attachments
</Checkbox>
{consent ? (
<div className="mt-1 border-t border-[var(--ns-line-soft)] pt-1">
<Checkbox
checked={dpa}
onCheckedChange={(v: boolean) => {
setDpa(v);
setRefused(false);
}}
hint={refused && !dpa ? undefined : words.hint}
error={refused && !dpa ? "Tick this to export" : undefined}
>
I accept the Data Processing Addendum
</Checkbox>
</div>
) : null}
</FormCard>
);
}"use client";
import * as React from "react";
import { Check } from "@/lib/notchset/icons";
import { cn } from "@/lib/utils";
import { Checkbox } from "@/components/ui/notchset/checkbox";
import { RollingNumber } from "@/components/ui/notchset/rolling-number";
import { buttonBase, buttonIntents, buttonSizes, QUIET_PILL } from "@/lib/notchset/button-look";
import { useLessMotion } from "@/lib/notchset/motion";
import { pressIn, useSelfPlay } from "./self-play";
import { FormCard } from "./scene-kit/hosts";
import { METRICS } from "./scene-kit/data";
/* At work, an export of deals to Dropbox. Each box changes what the export holds, so the button's count and the file line
answer every tick; the whole row is the target. Export fills green from where you pressed it, becomes its result
with an Undo, and the card glows once. With the consent row (the Consent required state), Export refuses until the
addendum is ticked: the row shakes once and says why. */
const OPEN = METRICS.find((m) => m.id === "deals")?.value ?? 248;
const CLOSED = 61;
const fileLine = (deals: number, notes: boolean, files: boolean) => {
const mb = deals * 0.005 + (notes ? deals * 0.009 : 0) + (files ? deals * 0.6 : 0);
return `${files ? "ZIP" : "CSV"} · ${mb < 10 ? mb.toFixed(1) : Math.round(mb)} MB`;
};
/* changed words leave by a short blur and the new ones clear from it, in one cell; nothing on arrival */
function Swap({ id, render, className }: { id: string; render: (id: string) => React.ReactNode; className?: string }) {
const [shown, setShown] = React.useState<{ id: string; was: string | null; n: number }>({ id, was: null, n: 0 });
if (shown.id !== id) setShown({ id, was: shown.id, n: shown.n + 1 });
return (
<span className={cn("inline-grid [&>*]:[grid-area:1/1]", className)}>
{shown.was !== null ? (
<span key={`was-${shown.n}`} aria-hidden data-ns-play-out="" className="[animation:ns-play-swap-out_var(--ns-play-swap)_var(--ns-ease-exit)_both]" onAnimationEnd={() => setShown((s) => ({ ...s, was: null }))}>
{render(shown.was)}
</span>
) : null}
<span key={`now-${shown.n}`} data-ns-play={shown.n ? "" : undefined} className={shown.n ? "[animation:ns-play-swap-in_var(--ns-play-swap)_var(--ns-ease)_both]" : undefined}>
{render(id)}
</span>
</span>
);
}
/* the button's width follows its words, easing, so a swap never leaves it roomy and never jumps a neighbour */
function EasedWidth({ children }: { children: React.ReactNode }) {
const inner = React.useRef<HTMLSpanElement>(null);
const [w, setW] = React.useState<number | null>(null);
React.useLayoutEffect(() => {
const el = inner.current;
if (!el) return;
const ro = new ResizeObserver(() => setW(el.offsetWidth));
ro.observe(el);
return () => ro.disconnect();
}, []);
return (
<span data-ns-glide="" className="relative inline-flex justify-center overflow-hidden transition-[width] duration-[var(--ns-play-swap)] ease-[var(--ns-ease-move)]" style={w === null ? undefined : { width: w }}>
<span ref={inner} className="inline-flex shrink-0 whitespace-nowrap">
{children}
</span>
</span>
);
}
/* The stage: a round task box over a square form box, alone and enlarged; on arrival each ticks once, the task then the
form, and they rest ticked. Ticking the task blooms its fill, draws the tick and
rings once, and its words fade to ink-3 (never struck); the form box squashes and its tick pops. Indeterminate: a
parent over two choices, mixed while one is on; ticking it ticks both, and from all on it clears both (on arrival it
ticks both once). Space ticks the box in focus. */
type Variant = "default" | "indeterminate";
const ROWS = { task: "Call Ana back", form: "Remember me" };
const NOTIFY = { parent: "Notify me", email: "By email", phone: "On my phone" };
const ROW = "text-[length:var(--ns-text-body)] leading-5";
export default function CheckboxDemo() {
const variant = "default" as Variant;
const root = React.useRef<HTMLDivElement>(null);
const less = useLessMotion();
const play = useSelfPlay(root, { beats: [400, 700], off: less });
React.useEffect(() => {
if (play.mine || play.taken === 0) return;
const boxes = root.current?.querySelectorAll<HTMLElement>("[data-slot=checkbox]");
if (variant === "indeterminate") {
if (play.taken === 1) pressIn(root.current, "[data-slot=checkbox]");
return;
}
boxes?.[play.taken - 1]?.click();
}, [play.taken, play.mine, variant]);
/* each variant's rows sit centred as a block, their width their own words */
return (
<div ref={root} onPointerDownCapture={play.handOver} onKeyDownCapture={play.handOver} className="flex w-full justify-center">
<div className="">{variant === "indeterminate" ? <Notify /> : <TaskAndForm />}</div>
</div>
);
}
function TaskAndForm() {
const words = ROWS;
const [done, setDone] = React.useState(false);
return (
<div className="flex w-fit flex-col items-start gap-4 pointer-coarse:gap-6">
<Checkbox variant="round" checked={done} onCheckedChange={setDone}>
<span className={cn(ROW, "transition-[color] duration-[var(--ns-btn-tick)]", done ? "text-[var(--ns-ink-3)]" : "text-[var(--ns-ink)]")}>{words.task}</span>
</Checkbox>
<Checkbox>
<span className={ROW}>{words.form}</span>
</Checkbox>
</div>
);
}
function Notify() {
const words = NOTIFY;
const [on, setOn] = React.useState({ email: true, phone: false });
const all = on.email && on.phone;
const some = on.email || on.phone;
return (
<div className="flex w-fit flex-col items-start gap-3 pointer-coarse:gap-6">
<Checkbox checked={all} indeterminate={some && !all} onCheckedChange={() => setOn(all ? { email: false, phone: false } : { email: true, phone: true })}>
<span className={ROW}>{words.parent}</span>
</Checkbox>
<div className="flex flex-col items-start gap-3 ps-7 pointer-coarse:gap-6">
<Checkbox checked={on.email} onCheckedChange={(v) => setOn((o) => ({ ...o, email: v }))}>
<span className={ROW}>{words.email}</span>
</Checkbox>
<Checkbox checked={on.phone} onCheckedChange={(v) => setOn((o) => ({ ...o, phone: v }))}>
<span className={ROW}>{words.phone}</span>
</Checkbox>
</div>
</div>
);
}
/* At work: an export of deals, each box changing what the export holds; the consent row refuses until ticked. */
export function AtWork() {
return <ExportDeals consent={false} />;
}
function ExportDeals({ consent }: { consent: boolean }) {
const said = { label: "Include closed deals", hint: "Required before deals leave the workspace" };
const words = said;
const [closed, setClosed] = React.useState(false);
const [notes, setNotes] = React.useState(false);
const [files, setFiles] = React.useState(false);
const [dpa, setDpa] = React.useState(false);
const [refused, setRefused] = React.useState(false);
const [done, setDone] = React.useState<number | null>(null);
const [press, setPress] = React.useState({ x: "50%", y: "50%" });
const deals = OPEN + (closed ? CLOSED : 0);
const blocked = consent && !dpa;
const change = (set: (v: boolean) => void) => (v: boolean) => {
set(v);
setDone(null);
};
const exportNow = (e: React.MouseEvent<HTMLButtonElement>) => {
if (done !== null) return;
if (blocked) {
/* a second refusal plays again: the error lifts for a frame and comes back */
setRefused(false);
requestAnimationFrame(() => requestAnimationFrame(() => setRefused(true)));
return;
}
/* the fill starts where the hand pressed; from the keyboard, at the centre */
const r = e.currentTarget.getBoundingClientRect();
const keyed = e.detail === 0;
setPress({ x: keyed ? "50%" : `${Math.round(e.clientX - r.left)}px`, y: keyed ? "50%" : `${Math.round(e.clientY - r.top)}px` });
setDone((n) => (n ?? 0) + 1);
};
const label = (form: string) => (
<span className="inline-flex items-center gap-1.5">
{form === "done" ? <Check className="size-4" aria-hidden /> : null}
<span>
{form === "done" ? "Exported" : "Export"} <RollingNumber value={String(deals)} className="tabular-nums" /> deals
</span>
</span>
);
return (
<FormCard
title="Export deals"
company="dropbox"
meta={
<>
To Dropbox · <Swap id={fileLine(deals, notes, files)} render={(t) => t} />
</>
}
className="relative [&_[data-slot=checkbox-label]]:flex [&_[data-slot=checkbox-label]]:w-full [&_[data-slot=checkbox-label]]:rounded-[var(--ns-radius-control)] [&_[data-slot=checkbox-label]]:px-3 [&_[data-slot=checkbox-label]]:py-2.5 [&_[data-slot=checkbox-label]]:[--ns-play-lift-shadow:var(--ns-depth-lift)] [&_[data-slot=checkbox-label]]:transition-[background-color,color] [&_[data-slot=checkbox-label]]:duration-[var(--ns-time-color)] [&_[data-slot=checkbox-label]:hover]:bg-[var(--ns-hover)] [&_[data-slot=checkbox-label]:has([aria-invalid=true])]:bg-[color-mix(in_oklab,var(--ns-bad)_var(--ns-tint-row),transparent)]"
footer={
<>
{done !== null ? (
<>
<span key={done} aria-hidden data-ns-play="ring" className="pointer-events-none absolute inset-0 rounded-[var(--ns-radius-card)] [animation:ns-play-ring_var(--ns-play-ring)_var(--ns-ease)_var(--ns-play-swap)_both]" />
<button type="button" data-ns-press="" data-ns-play="" className={cn(QUIET_PILL, "[animation:ns-play-swap-in_var(--ns-play-swap)_var(--ns-ease)_both]")} onClick={() => setDone(null)}>
Undo
</button>
</>
) : null}
<button
type="button"
data-ns-press=""
aria-disabled={blocked || undefined}
onClick={exportNow}
className={cn(
buttonBase,
buttonSizes.md,
"overflow-hidden tabular-nums",
done !== null
? "cursor-default px-[max(var(--ns-control-pad),14px)] bg-[var(--primary)] text-[var(--ns-on-fill)]"
: blocked
? "px-[max(var(--ns-control-pad),14px)] bg-[color-mix(in_oklab,var(--primary)_40%,transparent)] text-[var(--primary-foreground)]"
: buttonIntents.primary,
)}
style={{ "--ns-press-x": press.x, "--ns-press-y": press.y } as React.CSSProperties}
>
{done !== null ? <span key={done} aria-hidden data-ns-play="" className="absolute inset-0 bg-[var(--ns-play-fill-color)] [animation:ns-play-fill_var(--ns-play-fill)_var(--ns-ease-move)_both]" /> : null}
<EasedWidth>
<Swap id={done !== null ? "done" : "export"} render={label} />
</EasedWidth>
</button>
</>
}
>
<Checkbox checked={closed} onCheckedChange={change(setClosed)}>
{words.label}
</Checkbox>
<Checkbox checked={notes} onCheckedChange={change(setNotes)}>
Include notes
</Checkbox>
<Checkbox checked={files} onCheckedChange={change(setFiles)}>
Include attachments
</Checkbox>
{consent ? (
<div className="mt-1 border-t border-[var(--ns-line-soft)] pt-1">
<Checkbox
checked={dpa}
onCheckedChange={(v: boolean) => {
setDpa(v);
setRefused(false);
}}
hint={refused && !dpa ? undefined : words.hint}
error={refused && !dpa ? "Tick this to export" : undefined}
>
I accept the Data Processing Addendum
</Checkbox>
</div>
) : null}
</FormCard>
);
}"use client";
import * as React from "react";
/*
* A demo that plays itself until the first touch: the script lives in the demo, never in the piece, which only gets
* the props a person would give it. It moves 0.4 s after the piece is first seen, then takes each step on its beat;
* off screen or paused it waits. The first press, key or focus on the piece (bind `handOver` to it; a scroll over it never counts) makes it the
* visitor's for good and drops every queued step; with less motion (`off`) it never plays and rests in its first frame.
* A host can hand it over from outside the piece too (a settings panel beside it the visitor has used): under
* <HandedOver value>, it never plays, a remount included.
*
* const play = useSelfPlay(root, { beats: [2800, 2800], loop: true, off: less });
* <div ref={root} onPointerDownCapture={play.handOver} onKeyDownCapture={play.handOver} onFocusCapture={play.handOver}>
* play.step // the step it is at, -1 before its first
* play.control // "pause" while it plays, "play" once paused (a new take), "replay" once it is over or yours
*
* Each step presses the piece's own controls (pressIn), so the script shows exactly what a hand can do.
*
* A host that shows the piece once (<PlayOnce value={{ settle }}>) changes three things: the script starts when the
* piece is first half in view and never again on coming back, it never loops, and with less motion (or `settle`) it
* takes every step at once, so the piece rests on the END of its moment. `hold` is a reason not to play at all that is
* not motion (a mode with nothing to show): it holds in every host. Under <PlayOnce value={{ active: false }}> (a look
* that is mounted but not shown) it waits until it is shown.
*/
type SelfPlayOptions = {
/** how long each step waits after the one before it, in ms; the first step waits 0.4 s after the piece is seen */
beats: readonly number[];
/** starts over after the last step; without it the script plays once and rests */
loop?: boolean | undefined;
/** no self-play at all (less motion): the piece is the visitor's from the start */
off: boolean;
/** no self-play for a reason other than motion (a mode with nothing to show), in every host */
hold?: boolean | undefined;
};
/** How a host shows the piece: once on arrival (see useSelfPlay). */
type PlayOnceHost = {
/** rest on the end at once, without playing (less motion, or a reset) */
settle?: boolean | undefined;
/** false while the piece is mounted but not shown: it waits */
active?: boolean | undefined;
};
const START = 400;
/**
* Whether a demo plays itself at all. Off: every piece rests in its first frame and is
* the visitor's from the start; nothing presses its controls for them.
*/
const SELF_PLAY: boolean = false;
/** True where the visitor has already taken the piece from outside it: nothing under it plays itself. */
const HandedOver = React.createContext(false);
/** A host that shows the piece once: play once on arrival, rest on the end (null: play as the demo asks). */
const PlayOnce = React.createContext<PlayOnceHost | null>(null);
function useSelfPlay(root: React.RefObject<Element | null>, { beats, loop: looped = false, off: still, hold = false }: SelfPlayOptions) {
const once = React.useContext(PlayOnce);
const active = once?.active !== false;
/* shown once: less motion (or a settled host) takes every step at once and rests on the end */
const quick = once != null && (still || Boolean(once.settle));
const loop = once == null && looped;
/* the first touch hands it over for good */
const [mine, setMine] = React.useState(false);
const handOver = React.useCallback(() => setMine(true), []);
const handedOver = React.useContext(HandedOver);
const off = !SELF_PLAY || hold || (quick ? false : still) || mine || (handedOver && !quick);
const [seen, setSeen] = React.useState(false);
const [paused, setPaused] = React.useState(false);
const [taken, setTaken] = React.useState(0);
const n = Math.max(1, beats.length);
const done = !loop && taken >= n;
React.useEffect(() => {
const el = root.current;
if (!active) return;
/* without an observer (an old browser, a test) it counts as seen */
if (!el || typeof IntersectionObserver === "undefined" || quick) {
const t = window.setTimeout(() => setSeen(true));
return () => window.clearTimeout(t);
}
/* shown once: first half in view starts it, and leaving never stops or restarts it */
const io = once
? new IntersectionObserver((es) => {
if (es.some((e) => e.isIntersecting && e.intersectionRatio >= 0.5)) {
setSeen(true);
io.disconnect();
}
}, { threshold: 0.5 })
: new IntersectionObserver((es) => setSeen(es.some((e) => e.isIntersecting)));
io.observe(el);
return () => io.disconnect();
}, [root, active, once, quick]);
const playing = !off && seen && active && !paused && !done;
const delay = quick ? 0 : taken === 0 ? START : (beats[taken % n] ?? START);
React.useEffect(() => {
if (!playing) return;
const t = window.setTimeout(() => setTaken((k) => k + 1), delay);
return () => window.clearTimeout(t);
}, [playing, taken, delay]);
/* one control in one place: Pause while it plays, Play (a new take) once paused, Replay once it is over or yours */
/* self-play off: never "over", so a demo rests in its FIRST frame, not its end frame */
const control: "pause" | "play" | "replay" = paused || !SELF_PLAY ? "play" : off || done ? "replay" : "pause";
return { step: taken === 0 ? -1 : (taken - 1) % n, taken, playing, control, mine, handOver, pause: () => setPaused(true) };
}
/**
* Presses a real control inside `root`, as the visitor would: the first match of `selector`, or the one whose text is
* `text`. A click only, so it never counts as the visitor's touch.
*/
function pressIn(root: Element | null, selector: string, text?: string) {
const all = [...(root?.querySelectorAll<HTMLElement>(selector) ?? [])];
(text == null ? all[0] : all.find((el) => el.textContent?.trim() === text))?.click();
}
export { HandedOver, PlayOnce, pressIn, useSelfPlay, type PlayOnceHost, type SelfPlayOptions };"use client";
import * as React from "react";
import { cn } from "@/lib/utils";
import { Avatar } from "@/components/ui/notchset/avatar";
import { Card } from "@/components/ui/notchset/card";
import { CompanyMark } from "@/components/ui/notchset/company-mark";
import { brandGlyph } from "../brands";
import { company as companyOf, type Person } from "./data";
/*
* The places a piece is shown at work: eight hosts (a record card, a list card with rows, a form card, a settings
* group, a page header with its trail, a chat thread, a toolbar strip and an inline row), each a card at one of the
* four widths, sized to what it holds and standing on the signature's depth in light and dark. A host takes a title
* and children and knows nothing about what you put in it.
*/
type Width = "sm" | "md" | "lg" | "xl";
const WIDTH: Record<Width, string> = {
sm: "w-[var(--ns-width-sm)]",
md: "w-[var(--ns-width-md)]",
lg: "w-[var(--ns-width-lg)]",
xl: "w-[var(--ns-width-xl)]",
};
type HostProps = { title: string; children?: React.ReactNode; width?: Width | undefined; className?: string | undefined; frame?: "standard" | "brackets" | undefined };
/* the card every host stands on: the depth role's surface and shadow, one width, as tall as what it holds. It is the
app round a piece, not the piece's own frame: `data-scene-host` marks it so the stage checks can tell the two apart */
function HostCard({ width = "md", label, className, frame, children }: { width?: Width | undefined; label: string; className?: string | undefined; frame?: HostProps["frame"]; children: React.ReactNode }) {
return (
<Card frame={frame} data-scene-host="" aria-label={label} className={cn(WIDTH[width], "max-w-full bg-[var(--ns-depth-surface)] text-[var(--ns-ink)] shadow-[var(--ns-depth-card)]", className)}>
{children}
</Card>
);
}
const Title = ({ children }: { children: React.ReactNode }) => (
<h3 className="text-[length:var(--ns-text-small)] leading-5 font-[number:var(--ns-weight-medium)] text-[var(--ns-ink)]">{children}</h3>
);
const Meta = ({ children, className }: { children: React.ReactNode; className?: string }) => (
<p className={cn("text-[length:var(--ns-text-meta)] leading-4 text-[var(--ns-ink-3)] tabular-nums", className)}>{children}</p>
);
/* a company's own mark, from the sample's companies */
function Mark({ company, size = "md" }: { company: string; size?: "sm" | "md" }) {
const c = companyOf(company);
return <CompanyMark name={c.name} color={c.color} glyph={brandGlyph(c.brand)} size={size} />;
}
/* 1. A record: a company's head (its mark, name and a line about it), then what you show about it */
function RecordCard({ title, company, meta, aside, children, width, className, frame }: HostProps & { company?: string; meta?: React.ReactNode; aside?: React.ReactNode }) {
return (
<HostCard width={width} label={title} className={className} frame={frame}>
<header className="flex items-center gap-3 px-5 pt-5 pb-4">
{company ? <Mark company={company} /> : null}
<div className="min-w-0 flex-1">
<Title>{title}</Title>
{meta ? <Meta>{meta}</Meta> : null}
</div>
{aside}
</header>
{children ? <div className="flex flex-col gap-3 border-t border-[var(--ns-line-soft)] px-5 py-4">{children}</div> : null}
</HostCard>
);
}
/* 2. A list: its title and count over rows split by hairlines; a row is the whole target */
function ListCard({ title, count, aside, children, width, className }: HostProps & { count?: number; aside?: React.ReactNode }) {
return (
<HostCard width={width} label={title} className={className}>
<header className="flex items-center gap-2 px-5 pt-4 pb-3">
<Title>{title}</Title>
{count !== undefined ? <Meta>{count}</Meta> : null}
{aside ? <div className="ms-auto">{aside}</div> : null}
</header>
<ul className="flex flex-col border-t border-[var(--ns-line-soft)] px-2 py-1">{children}</ul>
</HostCard>
);
}
function ListRow({ lead, title, meta, trail, children }: { lead?: React.ReactNode; title: React.ReactNode; meta?: React.ReactNode; trail?: React.ReactNode; children?: React.ReactNode }) {
return (
<li className="flex min-h-12 items-center gap-3 rounded-[var(--ns-radius-control)] px-3 py-2 text-[length:var(--ns-text-small)]">
{lead}
<div className="min-w-0 flex-1">
<div className="truncate leading-5">{title}</div>
{meta ? <Meta className="truncate">{meta}</Meta> : null}
</div>
{children}
{trail ? <div className="shrink-0 text-[var(--ns-ink-3)] tabular-nums">{trail}</div> : null}
</li>
);
}
/* 3. A form: its head (a mark, a title and what it does), the fields, and the actions at its foot */
function FormCard({ title, company, meta, footer, children, width, className }: HostProps & { company?: string; meta?: React.ReactNode; footer?: React.ReactNode }) {
return (
<HostCard width={width} label={title} className={className}>
<header className="flex items-center gap-3 px-5 pt-5 pb-3">
{company ? <Mark company={company} /> : null}
<div className="min-w-0">
<Title>{title}</Title>
{meta ? <Meta>{meta}</Meta> : null}
</div>
</header>
<div className="flex flex-col px-2 pb-2 text-[length:var(--ns-text-small)]">{children}</div>
{footer ? <footer className="flex items-center justify-end gap-2 border-t border-[var(--ns-line-soft)] px-4 py-3">{footer}</footer> : null}
</HostCard>
);
}
/* 4. A settings group: a title and a line about it, then rows of a label, its hint and its control */
function SettingsGroup({ title, meta, children, width, className }: HostProps & { meta?: React.ReactNode }) {
return (
<HostCard width={width} label={title} className={className}>
<header className="px-5 pt-5 pb-3">
<Title>{title}</Title>
{meta ? <Meta>{meta}</Meta> : null}
</header>
<div className="flex flex-col divide-y divide-[var(--ns-line-soft)] border-t border-[var(--ns-line-soft)]">{children}</div>
</HostCard>
);
}
function SettingsRow({ label, hint, children }: { label: React.ReactNode; hint?: React.ReactNode; children?: React.ReactNode }) {
return (
<div className="flex items-center gap-4 px-5 py-3.5 text-[length:var(--ns-text-small)]">
<div className="min-w-0 flex-1">
<div className="leading-5">{label}</div>
{hint ? <Meta>{hint}</Meta> : null}
</div>
{children}
</div>
);
}
/* 5. A page's head: the trail to it, its title and a line about it, and its actions; children sit under it */
/* `trail` is a live trail (a Breadcrumb) set above the title, first in reading order, so a screen reader hears where the
page sits before its name; `crumbs` is a quiet one in words */
function PageHeader({ title, crumbs = [], trail, meta, actions, children, width = "lg", className }: HostProps & { crumbs?: string[]; trail?: React.ReactNode; meta?: React.ReactNode; actions?: React.ReactNode }) {
return (
<HostCard width={width} label={title} className={className}>
<header className="flex flex-wrap items-end gap-x-4 gap-y-3 px-6 pt-5 pb-5">
<div className="min-w-0 flex-1">
{trail ? (
<div data-slot="page-trail" className="mb-1.5 min-w-0">
{trail}
</div>
) : crumbs.length ? (
<nav aria-label="Breadcrumb" className="mb-1.5 flex flex-wrap items-center gap-1.5 text-[length:var(--ns-text-meta)] leading-4 text-[var(--ns-ink-3)]">
{crumbs.map((c, i) => (
<React.Fragment key={c}>
{i ? <span aria-hidden>/</span> : null}
<span>{c}</span>
</React.Fragment>
))}
</nav>
) : null}
<h2 className="text-[length:var(--ns-text-title)] leading-7 font-[number:var(--ns-weight-medium)]">{title}</h2>
{meta ? <Meta className="mt-0.5">{meta}</Meta> : null}
</div>
{actions ? <div className="flex items-center gap-2">{actions}</div> : null}
</header>
{children ? <div className="border-t border-[var(--ns-line-soft)] px-6 py-4">{children}</div> : null}
</HostCard>
);
}
/* 6. A conversation: its title, then messages, each with the person who sent it and when */
function ChatThread({ title, meta, children, footer, width, className }: HostProps & { meta?: React.ReactNode; footer?: React.ReactNode }) {
return (
<HostCard width={width} label={title} className={className}>
<header className="px-5 pt-4 pb-3">
<Title>{title}</Title>
{meta ? <Meta>{meta}</Meta> : null}
</header>
<ol className="flex flex-col gap-4 border-t border-[var(--ns-line-soft)] px-5 py-4">{children}</ol>
{footer ? <footer className="border-t border-[var(--ns-line-soft)] px-4 py-3">{footer}</footer> : null}
</HostCard>
);
}
function ChatMessage({ from, time, children }: { from: Person; time: string; children: React.ReactNode }) {
return (
<li className="flex gap-3 text-[length:var(--ns-text-small)]">
<Avatar name={from.name} size="sm" />
<div className="min-w-0 flex-1">
<div className="flex items-baseline gap-2 leading-5">
<span className="font-[number:var(--ns-weight-medium)]">{from.name}</span>
<Meta className="leading-5">{time}</Meta>
</div>
<div className="leading-5 [overflow-wrap:anywhere]">{children}</div>
</div>
</li>
);
}
/* 7. A toolbar over its content: the title at the start, the controls you pass after it, the content below */
function ToolbarStrip({ title, tools, children, width = "lg", className }: HostProps & { tools?: React.ReactNode }) {
return (
<HostCard width={width} label={title} className={className}>
<div className="flex flex-wrap items-center gap-2 px-4 py-3">
<Title>{title}</Title>
<div className="ms-auto flex flex-wrap items-center gap-2">{tools}</div>
</div>
{children ? <div className="border-t border-[var(--ns-line-soft)] px-4 py-4">{children}</div> : null}
</HostCard>
);
}
/* 8. An inline row for a small mark: what it says, and the mark where it is read, inside a sentence-sized card */
function InlineRow({ title, label, children, width = "sm", className }: HostProps & { label: React.ReactNode }) {
return (
<HostCard width={width} label={title} className={className}>
<div className="flex min-h-14 items-center gap-3 px-5 py-3 text-[length:var(--ns-text-small)]">
<span className="min-w-0 flex-1 text-[var(--ns-ink-3)]">{label}</span>
{children}
</div>
</HostCard>
);
}
export { ChatMessage, ChatThread, FormCard, InlineRow, ListCard, ListRow, PageHeader, RecordCard, SettingsGroup, SettingsRow, ToolbarStrip, type Width };/*
* The sample a scene draws: one sales team of six, the six accounts they sell to (real companies, drawn with their own
* marks), their open deals, this week's tasks, twelve weeks of activity and five headline figures. Every scene reads
* from here, so the same people and companies meet you on every page. Replace it with your own records.
*/
export type Person = { id: string; name: string; role: string };
export type Company = { id: string; name: string; brand: string; color: string };
export type Deal = { id: string; company: string; title: string; owner: string; amount: number; stage: "Lead" | "Qualified" | "Proposal" | "Negotiation" | "Won" | "Lost"; closes: string };
export type Task = { id: string; title: string; owner: string; due: string; done: boolean };
export type Metric = { id: string; label: string; value: number; unit: "count" | "usd" | "percent" | "days"; change: number };
const CAST: Person[] = [
{ id: "ana", name: "Ana Ruiz", role: "Account executive" },
{ id: "kevin", name: "Kevin Ito", role: "Solutions engineer" },
{ id: "marcus", name: "Marcus Bell", role: "Head of sales" },
{ id: "lena", name: "Lena Ortiz", role: "Account manager" },
{ id: "priya", name: "Priya Raman", role: "Account executive" },
{ id: "omar", name: "Omar Haddad", role: "Sales operations" },
];
/* each company's own colour, for its mark (CompanyMark's color, with brandGlyph(brand) as its glyph) */
const COMPANIES: Company[] = [
{ id: "stripe", name: "Stripe", brand: "stripe", color: "#635bff" },
{ id: "notion", name: "Notion", brand: "notion", color: "#191919" },
{ id: "linear", name: "Linear", brand: "linear", color: "#5e6ad2" },
{ id: "dropbox", name: "Dropbox", brand: "dropbox", color: "#0061ff" },
{ id: "vercel", name: "Vercel", brand: "vercel", color: "#000000" },
{ id: "airtable", name: "Airtable", brand: "airtable", color: "#18bfff" },
];
const DEALS: Deal[] = [
{ id: "d-stripe", company: "stripe", title: "Stripe, 120 seats", owner: "ana", amount: 84000, stage: "Negotiation", closes: "Nov 28" },
{ id: "d-notion", company: "notion", title: "Notion, workspace renewal", owner: "lena", amount: 42000, stage: "Proposal", closes: "Dec 4" },
{ id: "d-linear", company: "linear", title: "Linear, sales team pilot", owner: "priya", amount: 18500, stage: "Qualified", closes: "Dec 12" },
{ id: "d-dropbox", company: "dropbox", title: "Dropbox, EMEA rollout", owner: "marcus", amount: 126000, stage: "Won", closes: "Nov 6" },
{ id: "d-vercel", company: "vercel", title: "Vercel, annual upgrade", owner: "ana", amount: 36000, stage: "Lead", closes: "Jan 15" },
{ id: "d-airtable", company: "airtable", title: "Airtable, 40 seats", owner: "priya", amount: 22800, stage: "Lost", closes: "Oct 30" },
];
const TASKS: Task[] = [
{ id: "t-1", title: "Send the Stripe order form", owner: "ana", due: "Today", done: false },
{ id: "t-2", title: "Book the Notion security review", owner: "lena", due: "Tomorrow", done: false },
{ id: "t-3", title: "Share the Linear pilot plan", owner: "priya", due: "Fri", done: true },
{ id: "t-4", title: "Run the Dropbox kickoff", owner: "kevin", due: "Mon", done: false },
{ id: "t-5", title: "Clean up the Q4 forecast", owner: "omar", due: "Tue", done: false },
];
/* deals touched per week, oldest first: twelve weeks to this one */
const ACTIVITY: { week: string; deals: number }[] = [
{ week: "Aug 24", deals: 18 },
{ week: "Aug 31", deals: 22 },
{ week: "Sep 7", deals: 19 },
{ week: "Sep 14", deals: 27 },
{ week: "Sep 21", deals: 31 },
{ week: "Sep 28", deals: 26 },
{ week: "Oct 5", deals: 34 },
{ week: "Oct 12", deals: 38 },
{ week: "Oct 19", deals: 33 },
{ week: "Oct 26", deals: 41 },
{ week: "Nov 2", deals: 45 },
{ week: "Nov 9", deals: 52 },
];
/* change: against the quarter before, in the figure's own unit (points for a percentage) */
const METRICS: Metric[] = [
{ id: "pipeline", label: "Open pipeline", value: 203300, unit: "usd", change: 12.4 },
{ id: "won", label: "Won this quarter", value: 126000, unit: "usd", change: 8.1 },
{ id: "win-rate", label: "Win rate", value: 31, unit: "percent", change: 3 },
{ id: "cycle", label: "Sales cycle", value: 38, unit: "days", change: -4 },
{ id: "deals", label: "Open deals", value: 248, unit: "count", change: 17 },
];
const person = (id: string) => CAST.find((p) => p.id === id) ?? CAST[0]!;
const company = (id: string) => COMPANIES.find((c) => c.id === id) ?? COMPANIES[0]!;
export { ACTIVITY, CAST, COMPANIES, DEALS, METRICS, TASKS, company, person };/*
* The demos' real companies' own marks for CompanyMark's glyph: 24×24 paths, one copy, so every demo that shows one
* of these companies draws the same mark. Sample content, copied with a demo's usage; a buyer's app passes its own
* companies' marks: <CompanyMark name="Stripe" color="#635bff" glyph={brandGlyph("Stripe")} />
*/
const BRAND_GLYPHS = {
anthropic: "M17.3041 3.541h-3.6718l6.696 16.918H24Zm-10.6082 0L0 20.459h3.7442l1.3693-3.5527h7.0052l1.3693 3.5528h3.7442L10.5363 3.5409Zm-.3712 10.2232 2.2914-5.9456 2.2914 5.9456Z",
airtable: "M11.992 1.966c-.434 0-.87.086-1.28.257L1.779 5.917c-.503.208-.49.908.012 1.116l8.982 3.558a3.266 3.266 0 0 0 2.454 0l8.982-3.558c.503-.196.503-.908.012-1.116l-8.957-3.694a3.255 3.255 0 0 0-1.272-.257zM23.4 8.056a.589.589 0 0 0-.222.045l-10.012 3.877a.612.612 0 0 0-.38.564v8.896a.6.6 0 0 0 .821.552L23.62 18.1a.583.583 0 0 0 .38-.551V8.653a.6.6 0 0 0-.6-.596zM.676 8.095a.644.644 0 0 0-.48.19C.086 8.396 0 8.53 0 8.69v8.355c0 .442.515.737.908.54l6.27-3.006.307-.147 2.969-1.436c.466-.22.43-.908-.061-1.092L.883 8.138a.57.57 0 0 0-.207-.044z",
calendly: "M19.655 14.262c.281 0 .557.023.828.064 0 .005-.005.01-.005.014-.105.267-.234.534-.381.786l-1.219 2.106c-1.112 1.936-3.177 3.127-5.411 3.127h-2.432c-2.23 0-4.294-1.191-5.412-3.127l-1.218-2.106a6.251 6.251 0 0 1 0-6.252l1.218-2.106C6.736 4.832 8.8 3.641 11.035 3.641h2.432c2.23 0 4.294 1.191 5.411 3.127l1.219 2.106c.147.252.271.519.381.786 0 .004.005.009.005.014-.267.041-.543.064-.828.064-1.816 0-2.501-.607-3.291-1.306-.764-.676-1.711-1.517-3.44-1.517h-1.029c-1.251 0-2.387.455-3.2 1.278-.796.805-1.233 1.904-1.233 3.099v1.411c0 1.196.437 2.295 1.233 3.099.813.823 1.949 1.278 3.2 1.278h1.034c1.729 0 2.676-.841 3.439-1.517.791-.703 1.471-1.306 3.287-1.301Zm.005-3.237c.399 0 .794-.036 1.179-.11-.002-.004-.002-.01-.002-.014-.073-.414-.193-.823-.349-1.218.731-.12 1.407-.396 1.986-.819 0-.004-.005-.013-.005-.018-.331-1.085-.832-2.101-1.489-3.03-.649-.915-1.435-1.719-2.331-2.395-1.867-1.398-4.088-2.138-6.428-2.138-1.448 0-2.855.28-4.175.841-1.273.543-2.423 1.315-3.407 2.299S2.878 6.552 2.341 7.83c-.557 1.324-.842 2.726-.842 4.175 0 1.448.281 2.855.842 4.174.542 1.274 1.314 2.423 2.298 3.407s2.129 1.761 3.407 2.299c1.324.556 2.727.841 4.175.841 2.34 0 4.561-.74 6.428-2.137a10.815 10.815 0 0 0 2.331-2.396c.652-.929 1.158-1.949 1.489-3.03 0-.004.005-.014.005-.018-.579-.423-1.255-.699-1.986-.819.161-.395.276-.804.349-1.218.005-.009.005-.014.005-.023.869.166 1.692.506 2.404 1.035.685.505.552 1.075.446 1.416C22.184 20.437 17.619 24 12.221 24c-6.625 0-12-5.375-12-12s5.37-12 12-12c5.398 0 9.963 3.563 11.471 8.464.106.341.239.915-.446 1.421-.717.529-1.535.873-2.404 1.034.128.716.128 1.45 0 2.166-.387-.074-.782-.11-1.182-.11-4.184 0-3.968 2.823-6.736 2.823h-1.029c-1.899 0-3.15-1.357-3.15-3.095v-1.411c0-1.738 1.251-3.094 3.15-3.094h1.034c2.768 0 2.552 2.823 6.731 2.827Z",
dropbox: "M6 1.807L0 5.629l6 3.822 6.001-3.822L6 1.807zM18 1.807l-6 3.822 6 3.822 6-3.822-6-3.822zM0 13.274l6 3.822 6.001-3.822L6 9.452l-6 3.822zM18 9.452l-6 3.822 6 3.822 6-3.822-6-3.822zM6 18.371l6.001 3.822 6-3.822-6-3.822L6 18.371z",
"google drive": "M12.01 1.485c-2.082 0-3.754.02-3.743.047.01.02 1.708 3.001 3.774 6.62l3.76 6.574h3.76c2.081 0 3.753-.02 3.742-.047-.005-.02-1.708-3.001-3.775-6.62l-3.76-6.574zm-4.76 1.73a789.828 789.861 0 0 0-3.63 6.319L0 15.868l1.89 3.298 1.885 3.297 3.62-6.335 3.618-6.33-1.88-3.287C8.1 4.704 7.255 3.22 7.25 3.214zm2.259 12.653-.203.348c-.114.198-.96 1.672-1.88 3.287a423.93 423.948 0 0 1-1.698 2.97c-.01.026 3.24.042 7.222.042h7.244l1.796-3.157c.992-1.734 1.85-3.23 1.906-3.323l.104-.167h-7.249z",
figma: "M15.852 8.981h-4.588V0h4.588c2.476 0 4.49 2.014 4.49 4.49s-2.014 4.491-4.49 4.491zM12.735 7.51h3.117c1.665 0 3.019-1.355 3.019-3.019s-1.355-3.019-3.019-3.019h-3.117V7.51zm0 1.471H8.148c-2.476 0-4.49-2.014-4.49-4.49S5.672 0 8.148 0h4.588v8.981zm-4.587-7.51c-1.665 0-3.019 1.355-3.019 3.019s1.354 3.02 3.019 3.02h3.117V1.471H8.148zm4.587 15.019H8.148c-2.476 0-4.49-2.014-4.49-4.49s2.014-4.49 4.49-4.49h4.588v8.98zM8.148 8.981c-1.665 0-3.019 1.355-3.019 3.019s1.355 3.019 3.019 3.019h3.117V8.981H8.148zM8.172 24c-2.489 0-4.515-2.014-4.515-4.49s2.014-4.49 4.49-4.49h4.588v4.441c0 2.503-2.047 4.539-4.563 4.539zm-.024-7.51a3.023 3.023 0 0 0-3.019 3.019c0 1.665 1.365 3.019 3.044 3.019 1.705 0 3.093-1.376 3.093-3.068v-2.97H8.148zm7.704 0h-.098c-2.476 0-4.49-2.014-4.49-4.49s2.014-4.49 4.49-4.49h.098c2.476 0 4.49 2.014 4.49 4.49s-2.014 4.49-4.49 4.49zm-.097-7.509c-1.665 0-3.019 1.355-3.019 3.019s1.355 3.019 3.019 3.019h.098c1.665 0 3.019-1.355 3.019-3.019s-1.355-3.019-3.019-3.019h-.098z",
framer: "M4 0h16v8h-8zM4 8h8l8 8H4zM4 16h8v8z",
linear: "M2.886 4.18A11.982 11.982 0 0 1 11.99 0C18.624 0 24 5.376 24 12.009c0 3.64-1.62 6.903-4.18 9.105L2.887 4.18ZM1.817 5.626l16.556 16.556c-.524.33-1.075.62-1.65.866L.951 7.277c.247-.575.537-1.126.866-1.65ZM.322 9.163l14.515 14.515c-.71.172-1.443.282-2.195.322L0 11.358a12 12 0 0 1 .322-2.195Zm-.17 4.862 9.823 9.824a12.02 12.02 0 0 1-9.824-9.824Z",
notion: "M4.459 4.208c.746.606 1.026.56 2.428.466l13.215-.793c.28 0 .047-.28-.046-.326L17.86 1.968c-.42-.326-.981-.7-2.055-.607L3.01 2.295c-.466.046-.56.28-.374.466zm.793 3.08v13.904c0 .747.373 1.027 1.214.98l14.523-.84c.841-.046.935-.56.935-1.167V6.354c0-.606-.233-.933-.748-.887l-15.177.887c-.56.047-.747.327-.747.933zm14.337.745c.093.42 0 .84-.42.888l-.7.14v10.264c-.608.327-1.168.514-1.635.514-.748 0-.935-.234-1.495-.933l-4.577-7.186v6.952L12.21 19s0 .84-1.168.84l-3.222.186c-.093-.186 0-.653.327-.746l.84-.233V9.854L7.822 9.76c-.094-.42.14-1.026.793-1.073l3.456-.233 4.764 7.279v-6.44l-1.215-.139c-.093-.514.28-.887.747-.933zM1.936 1.035l13.31-.98c1.634-.14 2.055-.047 3.082.7l4.249 2.986c.7.513.934.653.934 1.213v16.378c0 1.026-.373 1.634-1.68 1.726l-15.458.934c-.98.047-1.448-.093-1.962-.747l-3.129-4.06c-.56-.747-.793-1.306-.793-1.96V2.667c0-.839.374-1.54 1.447-1.632z",
openai: "M22.2819 9.8211a5.9847 5.9847 0 0 0-.5157-4.9108 6.0462 6.0462 0 0 0-6.5098-2.9A6.0651 6.0651 0 0 0 4.9807 4.1818a5.9847 5.9847 0 0 0-3.9977 2.9 6.0462 6.0462 0 0 0 .7427 7.0966 5.98 5.98 0 0 0 .511 4.9107 6.051 6.051 0 0 0 6.5146 2.9001A5.9847 5.9847 0 0 0 13.2599 24a6.0557 6.0557 0 0 0 5.7718-4.2058 5.9894 5.9894 0 0 0 3.9977-2.9001 6.0557 6.0557 0 0 0-.7475-7.0729zm-9.022 12.6081a4.4755 4.4755 0 0 1-2.8764-1.0408l.1419-.0804 4.7783-2.7582a.7948.7948 0 0 0 .3927-.6813v-6.7369l2.02 1.1686a.071.071 0 0 1 .038.052v5.5826a4.504 4.504 0 0 1-4.4945 4.4944zm-9.6607-4.1254a4.4708 4.4708 0 0 1-.5346-3.0137l.142.0852 4.783 2.7582a.7712.7712 0 0 0 .7806 0l5.8428-3.3685v2.3324a.0804.0804 0 0 1-.0332.0615L9.74 19.9502a4.4992 4.4992 0 0 1-6.1408-1.6464zM2.3408 7.8956a4.485 4.485 0 0 1 2.3655-1.9728V11.6a.7664.7664 0 0 0 .3879.6765l5.8144 3.3543-2.0201 1.1685a.0757.0757 0 0 1-.071 0l-4.8303-2.7865A4.504 4.504 0 0 1 2.3408 7.872zm16.5963 3.8558L13.1038 8.364 15.1192 7.2a.0757.0757 0 0 1 .071 0l4.8303 2.7913a4.4944 4.4944 0 0 1-.6765 8.1042v-5.6772a.79.79 0 0 0-.407-.667zm2.0107-3.0231l-.142-.0852-4.7735-2.7818a.7759.7759 0 0 0-.7854 0L9.409 9.2297V6.8974a.0662.0662 0 0 1 .0284-.0615l4.8303-2.7866a4.4992 4.4992 0 0 1 6.6802 4.66zM8.3065 12.863l-2.02-1.1638a.0804.0804 0 0 1-.038-.0567V6.0742a4.4992 4.4992 0 0 1 7.3757-3.4537l-.142.0805L8.704 5.459a.7948.7948 0 0 0-.3927.6813zm1.0976-2.3654l2.602-1.4998 2.6069 1.4998v2.9994l-2.5974 1.4997-2.6067-1.4997Z",
posthog: "M9.854 14.5 5 9.647.854 5.5A.5.5 0 0 0 0 5.854V8.44a.5.5 0 0 0 .146.353L5 13.647l.147.146L9.854 18.5l.146.147v-.049c.065.03.134.049.207.049h2.586a.5.5 0 0 0 .353-.854L9.854 14.5zm0-5-4-4a.487.487 0 0 0-.409-.144.515.515 0 0 0-.356.21.493.493 0 0 0-.089.288V8.44a.5.5 0 0 0 .147.353l9 9a.5.5 0 0 0 .853-.354v-2.585a.5.5 0 0 0-.146-.354l-5-5zm1-4a.5.5 0 0 0-.854.354V8.44a.5.5 0 0 0 .147.353l4 4a.5.5 0 0 0 .853-.354V9.854a.5.5 0 0 0-.146-.354l-4-4zm12.647 11.515a3.863 3.863 0 0 1-2.232-1.1l-4.708-4.707a.5.5 0 0 0-.854.354v6.585a.5.5 0 0 0 .5.5H23.5a.5.5 0 0 0 .5-.5v-.6c0-.276-.225-.497-.499-.532zm-5.394.032a.8.8 0 1 1 0-1.6.8.8 0 0 1 0 1.6zM.854 15.5a.5.5 0 0 0-.854.354v2.293a.5.5 0 0 0 .5.5h2.293c.222 0 .39-.135.462-.309a.493.493 0 0 0-.109-.545L.854 15.501zM5 14.647.854 10.5a.5.5 0 0 0-.854.353v2.586a.5.5 0 0 0 .146.353L4.854 18.5l.146.147h2.793a.5.5 0 0 0 .353-.854L5 14.647z",
raycast: "M6.004 15.492v2.504L0 11.992l1.258-1.249Zm2.504 2.504H6.004L12.008 24l1.253-1.253zm14.24-4.747L24 11.997 12.003 0 10.75 1.251 15.491 6h-2.865L9.317 2.692 8.065 3.944l2.06 2.06H8.691v9.31H18v-1.432l2.06 2.06 1.252-1.252-3.312-3.32V8.506ZM6.63 5.372 5.38 6.625l1.342 1.343 1.251-1.253Zm10.655 10.655-1.247 1.251 1.342 1.343 1.253-1.251zM3.944 8.059 2.692 9.31l3.312 3.314v-2.506zm9.936 9.937h-2.504l3.314 3.312 1.25-1.252z",
revolut: "M20.9133 6.9566C20.9133 3.1208 17.7898 0 13.9503 0H2.424v3.8605h10.9782c1.7376 0 3.177 1.3651 3.2087 3.043.016.84-.2994 1.633-.8878 2.2324-.5886.5998-1.375.9303-2.2144.9303H9.2322a.2756.2756 0 0 0-.2755.2752v3.431c0 .0585.018.1142.052.1612L16.2646 24h5.3114l-7.2727-10.094c3.6625-.1838 6.61-3.2612 6.61-6.9494zM6.8943 5.9229H2.424V24h4.4704z",
sentry: "M13.91 2.505c-.873-1.448-2.972-1.448-3.844 0L6.904 7.92a15.478 15.478 0 0 1 8.53 12.811h-2.221A13.301 13.301 0 0 0 5.784 9.814l-2.926 5.06a7.65 7.65 0 0 1 4.435 5.848H2.194a.365.365 0 0 1-.298-.534l1.413-2.402a5.16 5.16 0 0 0-1.614-.913L.296 19.275a2.182 2.182 0 0 0 .812 2.999 2.24 2.24 0 0 0 1.086.288h6.983a9.322 9.322 0 0 0-3.845-8.318l1.11-1.922a11.47 11.47 0 0 1 4.95 10.24h5.915a17.242 17.242 0 0 0-7.885-15.28l2.244-3.845a.37.37 0 0 1 .504-.13c.255.14 9.75 16.708 9.928 16.9a.365.365 0 0 1-.327.543h-2.287c.029.612.029 1.223 0 1.831h2.297a2.206 2.206 0 0 0 1.922-3.31z",
shopify: "M15.337 23.979l7.216-1.561s-2.604-17.613-2.625-17.73c-.018-.116-.114-.192-.211-.192s-1.929-.136-1.929-.136-1.275-1.274-1.439-1.411c-.045-.037-.075-.057-.121-.074l-.914 21.104h.023zM11.71 11.305s-.81-.424-1.774-.424c-1.447 0-1.504.906-1.504 1.141 0 1.232 3.24 1.715 3.24 4.629 0 2.295-1.44 3.76-3.406 3.76-2.354 0-3.54-1.465-3.54-1.465l.646-2.086s1.245 1.066 2.28 1.066c.675 0 .975-.545.975-.932 0-1.619-2.654-1.694-2.654-4.359-.034-2.237 1.571-4.416 4.827-4.416 1.257 0 1.875.361 1.875.361l-.945 2.715-.02.01zM11.17.83c.136 0 .271.038.405.135-.984.465-2.064 1.639-2.508 3.992-.656.213-1.293.405-1.889.578C7.697 3.75 8.951.84 11.17.84V.83zm1.235 2.949v.135c-.754.232-1.583.484-2.394.736.466-1.777 1.333-2.645 2.085-2.971.193.501.309 1.176.309 2.1zm.539-2.234c.694.074 1.141.867 1.429 1.755-.349.114-.735.231-1.158.366v-.252c0-.752-.096-1.371-.271-1.871v.002zm2.992 1.289c-.02 0-.06.021-.078.021s-.289.075-.714.21c-.423-1.233-1.176-2.37-2.508-2.37h-.115C12.135.209 11.669 0 11.265 0 8.159 0 6.675 3.877 6.21 5.846c-1.194.365-2.063.636-2.16.674-.675.213-.694.232-.772.87-.075.462-1.83 14.063-1.83 14.063L15.009 24l.927-21.166z",
slack: "M5.042 15.165a2.528 2.528 0 0 1-2.52 2.523A2.528 2.528 0 0 1 0 15.165a2.527 2.527 0 0 1 2.522-2.52h2.52v2.52zM6.313 15.165a2.527 2.527 0 0 1 2.521-2.52 2.527 2.527 0 0 1 2.521 2.52v6.313A2.528 2.528 0 0 1 8.834 24a2.528 2.528 0 0 1-2.521-2.522v-6.313zM8.834 5.042a2.528 2.528 0 0 1-2.521-2.52A2.528 2.528 0 0 1 8.834 0a2.528 2.528 0 0 1 2.521 2.522v2.52H8.834zM8.834 6.313a2.528 2.528 0 0 1 2.521 2.521 2.528 2.528 0 0 1-2.521 2.521H2.522A2.528 2.528 0 0 1 0 8.834a2.528 2.528 0 0 1 2.522-2.521h6.312zM18.956 8.834a2.528 2.528 0 0 1 2.522-2.521A2.528 2.528 0 0 1 24 8.834a2.528 2.528 0 0 1-2.522 2.521h-2.522V8.834zM17.688 8.834a2.528 2.528 0 0 1-2.523 2.521 2.527 2.527 0 0 1-2.52-2.521V2.522A2.527 2.527 0 0 1 15.165 0a2.528 2.528 0 0 1 2.523 2.522v6.312zM15.165 18.956a2.528 2.528 0 0 1 2.523 2.522A2.528 2.528 0 0 1 15.165 24a2.527 2.527 0 0 1-2.52-2.522v-2.522h2.52zM15.165 17.688a2.527 2.527 0 0 1-2.52-2.523 2.526 2.526 0 0 1 2.52-2.52h6.313A2.527 2.527 0 0 1 24 15.165a2.528 2.528 0 0 1-2.522 2.523h-6.313z",
snowflake: "M24 3.459c0 .646-.418 1.18-1.141 1.18-.723 0-1.142-.534-1.142-1.18 0-.647.419-1.18 1.142-1.18.723 0 1.141.533 1.141 1.18zm-.228 0c0-.533-.38-.951-.913-.951s-.913.38-.913.95c0 .533.38.952.913.952.57 0 .913-.419.913-.951zm-1.37-.533h.495c.266 0 .456.152.456.38 0 .153-.076.229-.19.305l.19.266v.038h-.266l-.19-.266h-.229v.266h-.266zm.495.228h-.229v.267h.229c.114 0 .152-.038.152-.114.038-.077-.038-.153-.152-.153zM7.602 12.4c.038-.151.076-.304.076-.456 0-.114-.038-.228-.038-.342-.114-.343-.304-.647-.646-.838l-4.87-2.777c-.685-.38-1.56-.152-1.94.533-.381.685-.153 1.56.532 1.94l2.701 1.56-2.701 1.56c-.685.38-.913 1.256-.533 1.94.38.685 1.256.914 1.94.533l4.832-2.777c.343-.267.571-.533.647-.876zm1.332 2.626c-.266-.038-.57.038-.837.19l-4.832 2.777c-.685.38-.913 1.256-.532 1.94.38.686 1.255.914 1.94.533l2.701-1.56v3.12c0 .8.647 1.408 1.446 1.408.799 0 1.407-.647 1.407-1.408v-5.592c0-.761-.57-1.37-1.293-1.408zm4.946-6.088c.266.038.57-.038.837-.19l4.832-2.777c.685-.38.913-1.256.532-1.94-.38-.686-1.255-.914-1.94-.533l-2.701 1.56V1.975c0-.799-.647-1.408-1.446-1.408-.799 0-1.446.609-1.446 1.408V7.53c0 .76.609 1.37 1.332 1.407zM3.265 5.97l4.832 2.777c.266.152.533.19.837.19.723-.038 1.331-.684 1.331-1.407V1.975c0-.799-.646-1.408-1.407-1.408-.799 0-1.446.647-1.446 1.408v3.12l-2.701-1.56c-.685-.38-1.56-.152-1.94.533-.419.646-.19 1.521.494 1.902zm9.093 6.011a.412.412 0 00-.114-.266l-.57-.571a.346.346 0 00-.267-.114.412.412 0 00-.266.114l-.571.57a.411.411 0 00-.114.267c0 .076.038.19.114.267l.57.57a.345.345 0 00.267.114c.076 0 .19-.038.266-.114l.571-.57a.412.412 0 00.114-.267zm1.598.533L11.94 14.53c-.039.038-.153.114-.229.114h-.608a.411.411 0 01-.267-.114L8.82 12.514a.408.408 0 01-.076-.229v-.608c0-.076.038-.19.114-.267l2.016-2.016a.41.41 0 01.267-.114h.608a.41.41 0 01.267.114l2.016 2.016a.347.347 0 01.114.267v.608c-.076.077-.114.19-.19.229zm5.593 5.44l-4.832-2.777c-.266-.152-.57-.19-.837-.152-.723.038-1.332.684-1.332 1.408v5.554c0 .8.647 1.408 1.408 1.408.799 0 1.446-.647 1.446-1.408v-3.12l2.7 1.56c.686.38 1.561.152 1.941-.533.419-.646.19-1.521-.494-1.94zm2.549-7.533l-2.701 1.56 2.7 1.56c.686.38.914 1.256.533 1.94-.38.685-1.255.913-1.94.533l-4.832-2.778a1.644 1.644 0 01-.647-.798c-.037-.153-.076-.305-.076-.457 0-.114.039-.228.039-.342.114-.343.342-.647.646-.837l4.832-2.778c.685-.38 1.56-.152 1.94.533.457.609.19 1.484-.494 1.864",
strava: "M15.387 17.944l-2.089-4.116h-3.065L15.387 24l5.15-10.172h-3.066m-7.008-5.599l2.836 5.598h4.172L10.463 0l-7 13.828h4.169",
stripe: "M13.976 9.15c-2.172-.806-3.356-1.426-3.356-2.409 0-.831.683-1.305 1.901-1.305 2.227 0 4.515.858 6.09 1.631l.89-5.494C18.252.975 15.697 0 12.165 0 9.667 0 7.589.654 6.104 1.872 4.56 3.147 3.757 4.992 3.757 7.218c0 4.039 2.467 5.76 6.476 7.219 2.585.92 3.445 1.574 3.445 2.583 0 .98-.84 1.545-2.354 1.545-1.875 0-4.965-.921-6.99-2.109l-.9 5.555C5.175 22.99 8.385 24 11.714 24c2.641 0 4.843-.624 6.328-1.813 1.664-1.305 2.525-3.236 2.525-5.732 0-4.128-2.524-5.851-6.594-7.305h.003z",
vercel: "m12 1.608 12 20.784H0Z",
visa: "M9.112 8.262L5.97 15.758H3.92L2.374 9.775c-.094-.368-.175-.503-.461-.658C1.447 8.864.677 8.627 0 8.479l.046-.217h3.3a.904.904 0 01.894.764l.817 4.338 2.018-5.102zm8.033 5.049c.008-1.979-2.736-2.088-2.717-2.972.006-.269.262-.555.822-.628a3.66 3.66 0 011.913.336l.34-1.59a5.207 5.207 0 00-1.814-.333c-1.917 0-3.266 1.02-3.278 2.479-.012 1.079.963 1.68 1.698 2.04.756.367 1.01.603 1.006.931-.005.504-.602.725-1.16.734-.975.015-1.54-.263-1.992-.473l-.351 1.642c.453.208 1.289.39 2.156.398 2.037 0 3.37-1.006 3.377-2.564m5.061 2.447H24l-1.565-7.496h-1.656a.883.883 0 00-.826.55l-2.909 6.946h2.036l.405-1.12h2.488zm-2.163-2.656l1.02-2.815.588 2.815zm-8.16-4.84l-1.603 7.496H8.34l1.605-7.496z",
/* Zoom's app icon: its camera (the body and the lens), drawn on Zoom's blue tile; the wordmark is unreadable at 16px */
zoom: "M6.5 7h7A2.5 2.5 0 0 1 16 9.5v5a2.5 2.5 0 0 1-2.5 2.5h-7A2.5 2.5 0 0 1 4 14.5v-5A2.5 2.5 0 0 1 6.5 7Zm10.5 3.6 2.4-1.75c.66-.48 1.6-.01 1.6.81v6.68c0 .82-.94 1.29-1.6.81L17 15.4Z",
webflow: "m24 4.515-7.658 14.97H9.149l3.205-6.204h-.144C9.566 16.713 5.621 18.973 0 19.485v-6.118s3.596-.213 5.71-2.435H0V4.515h6.417v5.278l.144-.001 2.622-5.277h4.854v5.244h.144l2.72-5.244H24Z",
yelp: "m7.6885 15.1415-3.6715.8483c-.3769.0871-.755.183-1.1452.155-.2611-.0188-.5122-.0414-.7606-.213a1.179 1.179 0 0 1-.331-.3594c-.3486-.5519-.3656-1.3661-.3697-2.0004a6.2874 6.2874 0 0 1 .3314-2.0642 1.857 1.857 0 0 1 .1073-.2474 2.3426 2.3426 0 0 1 .1255-.2165 2.4572 2.4572 0 0 1 .1563-.1975 1.1736 1.1736 0 0 1 .399-.2831 1.082 1.082 0 0 1 .4592-.0837c.2355.0016.5139.052.91.1734.0555.0191.1237.0382.1856.0572.3277.1013.7048.2404 1.1499.3987.6863.2404 1.3663.487 2.0463.7397l1.2117.4423c.2217.0807.4363.18.6412.297.174.0984.3273.2298.4512.387a1.217 1.217 0 0 1 .192.4309 1.2205 1.2205 0 0 1-.872 1.4522c-.0468.0151-.0852.0239-.1085.0293l-1.105.2553-.0031-.001zM18.8208 7.565a1.8506 1.8506 0 0 0-.2042-.1754 2.4082 2.4082 0 0 0-.2077-.1394 2.3607 2.3607 0 0 0-.2269-.109 1.1705 1.1705 0 0 0-.482-.0796 1.0862 1.0862 0 0 0-.4498.1263c-.2107.1048-.4388.2732-.742.5551-.042.0417-.0947.0886-.142.133-.2502.2351-.5286.5252-.8599.863a114.6363 114.6363 0 0 0-1.5166 1.5629l-.8962.9293a4.1897 4.1897 0 0 0-.4466.5483 1.541 1.541 0 0 0-.2364.5459 1.2199 1.2199 0 0 0 .0107.4518l.0046.02a1.218 1.218 0 0 0 1.4184.923 1.162 1.162 0 0 0 .1105-.0213l4.7781-1.104c.3766-.087.7587-.1667 1.097-.3631.2269-.1316.4428-.262.5909-.5252a1.1793 1.1793 0 0 0 .1405-.4683c.0733-.6512-.2668-1.3908-.5403-1.963a6.2792 6.2792 0 0 0-1.2001-1.7103zM8.9703.0754a8.6724 8.6724 0 0 0-.83.1564c-.2754.066-.548.1383-.8146.2236-.868.2844-2.0884.8063-2.295 1.8065-.1165.5655.1595 1.1439.3737 1.66.2595.6254.614 1.1889.9373 1.7777.8543 1.5545 1.7245 3.0993 2.5922 4.6457.259.4617.5416 1.0464 1.043 1.2856a1.058 1.058 0 0 0 .1013.0383c.2248.0851.4699.1016.7041.0471a4.3015 4.3015 0 0 0 .0418-.0097 1.2136 1.2136 0 0 0 .5658-.3397 1.1033 1.1033 0 0 0 .079-.0822c.3463-.435.3454-1.0833.3764-1.6134.1042-1.771.2139-3.5423.3009-5.3142.0332-.6712.1055-1.3333.0655-2.0096-.0328-.5579-.0368-1.1984-.3891-1.6563-.6218-.8073-1.9476-.741-2.8523-.6158zm2.084 15.9505a1.1053 1.1053 0 0 0-1.2306-.4145 1.1398 1.1398 0 0 0-.1526.0633 1.4806 1.4806 0 0 0-.2171.1354c-.1992.1475-.3668.3392-.5196.5315-.0386.049-.074.1143-.12.1562l-.7686 1.0573a113.9168 113.9168 0 0 0-1.2913 1.789c-.278.3895-.5184.7184-.7083 1.0094-.036.0547-.0734.116-.1075.1647-.2277.3522-.3566.6092-.4228.8381a1.0945 1.0945 0 0 0-.046.4721c.0211.1655.0768.3246.1635.467.046.0715.0957.1406.1487.207a2.334 2.334 0 0 0 .1754.1825 1.843 1.843 0 0 0 .2108.1732c.5304.369 1.1112.6342 1.722.8391a6.0958 6.0958 0 0 0 1.5716.3004c.091.0046.1821.0025.2728-.006a2.3878 2.3878 0 0 0 .2506-.0351 2.3862 2.3862 0 0 0 .2447-.071 1.1927 1.1927 0 0 0 .4175-.2658c.1127-.113.1994-.249.2541-.3989.0889-.2214.1473-.5026.1857-.92.0034-.0593.0118-.1305.0177-.1958.0304-.3463.0443-.7531.0666-1.2315.0375-.7357.067-1.4681.0903-2.2026 0 0 .0495-1.3053.0494-1.306.0113-.3008.002-.6342-.0814-.9336a1.396 1.396 0 0 0-.1756-.4054zm8.6754 2.0439c-.1605-.176-.3878-.3514-.7462-.5682-.0518-.0288-.1124-.0674-.1684-.1009-.2985-.1795-.658-.3684-1.078-.5965a120.7615 120.7615 0 0 0-1.9427-1.042l-1.1515-.6107c-.0597-.0175-.1203-.0607-.1766-.0878-.2212-.1058-.4558-.2045-.6992-.2498a1.4915 1.4915 0 0 0-.2545-.0265 1.1527 1.1527 0 0 0-.1648.01 1.1077 1.1077 0 0 0-.9227.9133 1.4186 1.4186 0 0 0 .0159.439c.0563.3065.1932.6096.3346.875l.615 1.1526c.3422.65.6884 1.2963 1.0435 1.9406.229.4202.4196.7799.5982 1.078.0338.056.0721.1163.1011.1682.2173.3584.392.584.569.7458.1146.1107.252.195.4026.247.1583.0525.326.071.4919.0546a2.368 2.368 0 0 0 .251-.0435c.0817-.022.1622-.048.241-.0784a1.863 1.863 0 0 0 .2475-.1143 6.1018 6.1018 0 0 0 1.2818-.9597c.4596-.4522.8659-.9454 1.182-1.51.044-.08.0819-.163.1138-.2483a2.49 2.49 0 0 0 .0773-.2411c.0186-.083.033-.1669.0429-.2513a1.188 1.188 0 0 0-.0565-.491 1.0933 1.0933 0 0 0-.248-.4041zm2.86 3.742a.8523.8523 0 0 1-.111.4236c-.074.132-.178.2377-.3115.3172a.8428.8428 0 0 1-.4385.119.847.847 0 0 1-.4373-.1179.8526.8526 0 0 1-.3125-.3171.8548.8548 0 0 1-.111-.4248c0-.1526.038-.2958.1143-.4294a.8405.8405 0 0 1 .315-.3159.849.849 0 0 1 .4315-.1156.8514.8514 0 0 1 .4294.1144.84.84 0 0 1 .316.3148.8494.8494 0 0 1 .1156.4317zm-.1202 0c0-.1328-.0332-.256-.0996-.3698s-.1564-.2038-.2702-.2702a.7125.7125 0 0 0-.371-.1007.7204.7204 0 0 0-.3698.0996.7487.7487 0 0 0-.2713.2702.7181.7181 0 0 0-.0996.3709c0 .132.0332.2557.0996.371a.7355.7355 0 0 0 .2713.2713.7354.7354 0 0 0 .3698.0985.7205.7205 0 0 0 .3698-.0996.7423.7423 0 0 0 .2702-.2691.7186.7186 0 0 0 .1008-.3721zm-.577.0584.2724.4522h-.1922l-.237-.4052h-.1546v.4052h-.1695v-1.02h.2988c.1268 0 .2195.0247.2783.0744.0595.0496.0892.1252.0892.2267a.2785.2785 0 0 1-.0492.1625c-.032.0466-.0775.0813-.1362.1042zm-.0412-.1408a.1532.1532 0 0 0 .056-.1214c0-.0573-.0164-.0981-.0491-.1225-.0329-.0251-.0847-.0377-.1557-.0377h-.1214v.3285h.1237c.061 0 .1098-.0157.1465-.047z",
} as const satisfies Record<string, string>;
type BrandName = keyof typeof BRAND_GLYPHS;
/** A real company's mark by its name, case-insensitive ("Stripe", "stripe"); undefined for one with none, which then shows its initial. */
const brandGlyph = (name: string): string | undefined => BRAND_GLYPHS[name.trim().toLowerCase() as BrandName];
export { BRAND_GLYPHS, brandGlyph };This example also uses Avatar, Button, Card, Company mark, Rolling number. This command installs them with it, so the example pastes as it is:
pnpm dlx shadcn@latest add https://notchset.dev/r/checkbox.json https://notchset.dev/r/avatar.json https://notchset.dev/r/button.json https://notchset.dev/r/card.json https://notchset.dev/r/company-mark.json https://notchset.dev/r/rolling-number.jsoncomponents/ui/notchset/checkbox.tsx
LevelAtom: uses no other piece.
Made ofNothing else from the library: the foundation alone.
Free, no account or key. One command for every shadcn style. With the @notchset registry added, @notchset/<name> works too.
Works with React 18.3 or 19 on Tailwind CSS v4, in any shadcn project. What's tested
pnpm add @base-ui/react@^1The CLI adds the styles to the CSS file named in components.json (tailwind.css). Check that it points at your global stylesheet, that the project uses Tailwind CSS v4, and that the file is imported in your root layout. Installed by hand: paste styles.css into that file.
The sound you hear is this page's: the piece you install plays none, and calls onFeedback on each move so you can add your own.
checked–
booleanticked (controlled, with onCheckedChange); Base UI's own, passed straight through
defaultChecked–
booleanticked at first (uncontrolled)
indeterminate–
booleanmixed: some of what it stands for are ticked (a dash)
disabled–
booleancan't change; give `reason` to say why
variant"square"
"square" | "round"square (default): a softly rounded square, saved with a form or choosing rows; round: for completing something, popping once on the tick
reason–
stringwhy it can't change, with `disabled`: read in the hint's place
error–
React.ReactNodewhat is wrong (a required box left unticked), under the label in the bad colour
hint–
React.ReactNodeA quieter line under the label.
onFeedback–
(e: FeedbackEvent) => voidcalled once per move, for your sound or haptics
Three usesagreeing to terms before signing up · a setting in a form · a list row's selection
Give your coding assistant the Markdown guide instead of screenshots.
https://notchset.dev/api/mcp (setup)v1.1.0 · 2026-11-17
New props: onFeedback. Ships feedback.ts (FeedbackEvent, FeedbackProps), which it now uses.
v1.0.0 · 2026-11-09
Released free with the Notchset system.