Sanity Admin Kit
A reusable kit of admin GUI primitives for Sanity-driven sites. Ships the construction layer — form fields, media pickers, document forms, vertical-specific recipes — so each consumer site keeps full control of its visual identity while sharing battle-tested editor UX with every site I build on it.
A reusable kit of admin GUI primitives for Sanity-driven sites. Ships the construction layer — form fields, media pickers, document forms, vertical-specific recipes — so each consumer site keeps full control of its visual identity while sharing battle-tested editor UX with every site I build on it.
Build Log
Codified five kit recipes — discriminated array items, exclusive flag (one-of-many), deferred upload, revalidation map, and clipboard paste — each with explicit Variations sections so consumers know what's safe to customize.
Brought the kit from 0.1.0 up to 0.3.0 — added ArrayItemAccordion, SocialLinksEditor, ArraySoftLimitWarning, useExclusiveFlag, a server-side revalidation helper, publish-only DocumentForm defaults, provider-mount config validation, and TipTap dup-extension fixes. Five recipes documented along the way.
Added clipboard-paste to the admin image uploader: explicit button plus Tab+Ctrl+V on the focused dropzone. Editors can paste a screenshot straight from the system clipboard without saving to disk first.
Shipped an AI-friendly SEO baseline as a kit standard — robots.ts and sitemap.ts scaffold templates that allow AI crawlers (GPTBot, ClaudeBot, PerplexityBot, Google-Extended, Applebot-Extended) by default. Many sites have started reflexively blocking AI crawlers and forfeiting AI-routed audience traffic; the kit's default is to stay open and discoverable.
Graduated three local admin primitives into the kit at v0.2.2 — a dual-mode MediaPicker (drag-drop upload plus browse-existing), a ResponsiveSheet dialog (centered modal on desktop, right drawer on mobile), and a VenueImageWithOverride form field with a one-click promote-to-venue checkbox. The reference consumer (AJ and the Groove) deleted its local copies; future consumer projects get all three for free.
Codified the live-performance vertical as a first-class kit canon. sanity-admin-kit/shows ships canonical Show and Venue types, GROQ projection fragments, and pure-function primitives (maps URLs, calendar event builders, ICS download), plus an <AddToCalendarMenu> component with portal-pattern containment baked in. AJ became the reference adopter; future band sites extend the canon via TypeScript intersection rather than carrying bespoke types.
