import { type ShopBrief } from "./brief.js"; /** * Apply the AI brief to the scaffold so the shop actually renders in its own * design + catalog. Three activations (all on the customer's copy): * 1. Catalog → overwrite the REGISTERED generic template seed-data.ts, so * `brand.industryTemplate: "generic"` seeds the brief's categories/products * (no industry-templates/index.ts patch needed). * 2. Theme → recolour the active theme file (themes/generic.css) sol-* token * VALUES with the brief palette, so the storefront renders in those colours. * 3. Reference files → themes/.css + lib/ai/prompts/.ts. */ export declare function injectBriefFiles(targetDir: string, brief: ShopBrief): void; export declare function injectModernWebDoc(targetDir: string): void; export declare const MODERN_WEB_MD = "# Cartwright Modern Web Baseline\n\nYour Cartwright store ships with these modern web platform features wired up out of the box. Each one is built into Cartwright's default code \u2014 you don't need to write the boilerplate. Some are on by default; some are opt-in via `brand.features.*` in your `brand.config.ts`.\n\n**For your AI coding agent:** this file is a directory of capabilities. Whenever you're asked to \"add a modal\", \"speed up the cart\", \"make the page accessible\", reach for the listed primitive first, not a third-party library.\n\n**For your marketing:** every line here is a real, shipping feature you can list on your product page.\n\n---\n\n## Structured data (the AI-citation lever)\n\n| Feature | Status | Where |\n|---|---|---|\n| JSON-LD: `Organization` | \u2705 on root layout | `components/JsonLd.tsx` |\n| JSON-LD: `Product` + `Offer` | \u2705 on every PDP | `app/[locale]/product/[slug]/page.tsx` |\n| JSON-LD: `BreadcrumbList` | \u2705 on PLP + PDP | server-side via JsonLd helper |\n| JSON-LD: `AggregateRating` | gated by `brand.features.reviews` | rendered on PDP when reviews are on |\n\nSchema.org markup is what AI search engines (Google AI Overviews, Perplexity, ChatGPT browse) cite. Cartwright ships all structured data server-side \u2014 crawlers and LLM-scrapers see it without executing JS.\n\n---\n\n## Accessibility baseline (Phase B1)\n\n| Feature | Status | Where |\n|---|---|---|\n| `aria-live` announcements (cart adds, review submits, errors) | \u2705 always on | `components/a11y/LiveRegion.tsx` |\n| `prefers-reduced-motion` respected | \u2705 in globals.css + components | `app/[locale]/globals.css`, RevealOnScroll |\n| Focus management on modals | gated by `brand.features.popoverApi` | native `` when on |\n\n---\n\n## Performance baseline (Phase 0 + B2)\n\n| Feature | Status | Where |\n|---|---|---|\n| `fetchpriority=\"high\"` on LCP candidates | \u2705 via next/image `priority` prop | PDP hero, PLP first cards |\n| `loading=\"lazy\"` below the fold | \u2705 next/image default + manual on raw imgs | every `` below-fold |\n| `decoding=\"async\"` on raw imgs | \u2705 on case studies + tech badges | various |\n| Save-data respect on heavy assets | \u2705 in HeroVideo | `components/HeroVideo.tsx` |\n\n---\n\n## Modern UI primitives (Phase B3 + B4)\n\n| Feature | Status | Where |\n|---|---|---|\n| Container queries on ProductCard | gated by `brand.features.containerQueries` | `@sm:` Tailwind v4 variants |\n| Native `` + Popover API for modals | gated by `brand.features.popoverApi` | `components/WelcomeGuide.tsx` |\n| Runtime feature detection (``, popover, view transitions) | \u2705 always available | `lib/features.ts` |\n\n---\n\n## Navigation (Phase B5)\n\n| Feature | Status | Where |\n|---|---|---|\n| View Transitions on PLP \u2192 PDP | gated by `brand.features.viewTransitions` | `app/lib/view-transitions.ts`, `TransitionLink` |\n| Shared `view-transition-name` on hero image | \u2705 when viewTransitions flag is on | PLP card + PDP hero |\n| Graceful fallback in non-supporting browsers (Firefox) | \u2705 automatic | wrapNavigation runs nav directly |\n\n---\n\n## Authentication\n\nNot in a `--profile site` scaffold, which has no login.\n\n| Feature | Status | Where |\n|---|---|---|\n| Email + password sign-in | \u2705 on | `/account/login` \u2192 Password tab (NextAuth credentials) |\n| Magic-link sign-in | offered once a Resend key is set (`RESEND_API_KEY`) | NextAuth email provider + Resend |\n\n---\n\n## AI-agent integrations\n\n| Feature | Status | Where |\n|---|---|---|\n| Project-level `CLAUDE.md` for Claude Code | \u2705 shipped in scaffold | `.claude/CLAUDE.md` |\n| Project-level Cursor rules | \u2705 shipped in scaffold | `.cursor/rules/cartwright.mdc` |\n| GitHub Copilot instructions | \u2705 shipped in scaffold | `.github/copilot-instructions.md` |\n| `cartwright-guidance` agent skill | \u2705 shipped in scaffold | `.claude/skills/cartwright-guidance/SKILL.md` |\n| `modern-web-guidance` (Chrome team) skill | installed during scaffold (optional) | global `~/.agents/skills/` |\n| MCP server (`/api/mcp`) | gated by `brand.features.mcpPublic` | exposes tools to AI agents |\n\n---\n\n## Turning features on\n\nOpen `brand.config.ts`, find the `features` object, and flip the flag from `false` to `true`. Each flag has a JSDoc comment explaining what it switches on and any dependencies.\n\nTypical first steps for a fresh shop:\n- `webshop: true` \u2014 unlock cart, checkout, account routes (set automatically by `--template coffee` / `--template sunglasses` / `--template generic`)\n- `reviews: true` \u2014 turn on the moderation flow and `AggregateRating` JSON-LD\n- `containerQueries: true`, `popoverApi: true`, `viewTransitions: true` \u2014 opt in to the Phase B baseline\n\n---\n\n_Generated by `create-cartwright`. Edit freely \u2014 Cartwright won't overwrite this file on later runs._\n";