launchframe 0.2.1 → 0.2.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +21 -17
- package/bin/launchframe.mjs +99 -34
- package/package.json +2 -2
- package/template/.amazonq/cli-agents/clone-website.json +1 -1
- package/template/.amazonq/rules/project.md +50 -6
- package/template/.augment/commands/clone-website.md +32 -13
- package/template/.claude/skills/clone-website/SKILL.md +33 -14
- package/template/.clinerules +50 -6
- package/template/.codex/skills/clone-website/SKILL.md +33 -14
- package/template/.continue/commands/clone-website.md +32 -13
- package/template/.continue/rules/project.md +50 -6
- package/template/.cursor/commands/clone-website.md +32 -13
- package/template/.cursor/rules/project.mdc +16 -3
- package/template/.gemini/commands/clone-website.toml +32 -13
- package/template/.github/copilot-instructions.md +50 -6
- package/template/.github/skills/clone-website/SKILL.md +33 -14
- package/template/.opencode/commands/clone-website.md +32 -13
- package/template/.windsurf/workflows/clone-website.md +32 -13
- package/template/AGENTS.md +15 -0
- package/template/README.md +15 -24
- package/template/START_HERE.md +15 -0
- package/template/docs/research/INSPECTION_GUIDE.md +35 -6
- package/template/package.json +1 -0
|
@@ -10,6 +10,8 @@ argument-hint: "<url>"
|
|
|
10
10
|
|
|
11
11
|
You are about to reverse-engineer and rebuild a website as a pixel-perfect clone, then re-skin the copy/branding for the user's SaaS idea.
|
|
12
12
|
|
|
13
|
+
**Launchframe shorthand:** If the user only says **Build it**, **Go**, **Ship it**, **Clone the site**, or **Run launchframe** with no URL in the message, treat that as an invocation of this skill with empty `$ARGUMENTS` — **`launchframe.config.json` alone** supplies `url` and `idea`. Proceed without asking them to repeat those values unless the file is missing or invalid.
|
|
14
|
+
|
|
13
15
|
## Step 0: Read `launchframe.config.json`
|
|
14
16
|
|
|
15
17
|
**Before doing anything else**, read `launchframe.config.json` at the project root. This file was written by the `launchframe` CLI when the project was scaffolded and is the authoritative source of:
|
|
@@ -37,17 +39,23 @@ If the user provides additional instructions (specific fidelity level, deeper cu
|
|
|
37
39
|
|
|
38
40
|
## Pre-Flight
|
|
39
41
|
|
|
40
|
-
1. **Read `launchframe.config.json`** (see Step 0 above).
|
|
42
|
+
1. **Read `launchframe.config.json`** (see Step 0 above). After a fresh `npx launchframe` scaffold, proceed immediately — only echo `url`/`idea` for confirmation if the config looks wrong or the user asked to verify.
|
|
41
43
|
2. **Browser automation is required.** Check for available browser MCP tools (Chrome MCP, Playwright MCP, Browserbase MCP, Puppeteer MCP, etc.). Use whichever is available — if multiple exist, prefer Chrome MCP. If none are detected, ask the user which browser tool they have and how to connect it. This skill cannot work without browser automation.
|
|
42
44
|
3. Validate the resolved URL(s). Normalize and verify each is accessible via your browser MCP tool. If any are invalid, ask the user to correct `launchframe.config.json` (or pass an override) before proceeding.
|
|
43
45
|
4. Verify the base project builds: `npm run build`. The Next.js + shadcn/ui + Tailwind v4 scaffold should already be in place. If not, tell the user to run `npm install` first.
|
|
44
|
-
5. Create the output directories if they don't exist: `docs/research/`, `docs/research/components/`, `docs/design-references/`, `scripts/`. For multiple clones, also prepare per-site folders like `docs/research/<hostname>/` and `docs/design-references/<hostname>/`.
|
|
46
|
+
5. Create the output directories if they don't exist: `docs/research/`, `docs/research/components/`, `docs/design-references/`, `scripts/`. Plan `docs/research/MEDIA_MANIFEST.md` as soon as media is inventoried. For multiple clones, also prepare per-site folders like `docs/research/<hostname>/` and `docs/design-references/<hostname>/`.
|
|
45
47
|
6. When working with multiple sites in one command, optionally confirm whether to run them in parallel (recommended, if resources allow) or sequentially to avoid overload.
|
|
46
48
|
|
|
47
49
|
## Guiding Principles
|
|
48
50
|
|
|
49
51
|
These are the truths that separate a successful clone from a "close enough" mess. Internalize them — they should inform every decision you make.
|
|
50
52
|
|
|
53
|
+
### 0. Launchframe priorities: media & motion (do not defer)
|
|
54
|
+
|
|
55
|
+
**Raster & video are first-class.** Before you treat the page as “mostly typography,” run a dedicated **media inventory** (see `@docs/research/INSPECTION_GUIDE.md` Priority section): every `<img>`, `<picture>` / `<source>`, `<video>` (+ poster), and non-trivial `background-image`. Download to `public/images/` and `public/videos/` and write `docs/research/MEDIA_MANIFEST.md` (URL → local path, or `BLOCKED` + reason). Component specs MUST list concrete `public/...` paths; if you use a placeholder, say why in `docs/research/EXTRACTION_LIMITATIONS.md`. Never silently drop a hero layer, reel, or og visual.
|
|
56
|
+
|
|
57
|
+
**Motion defaults to Framer Motion.** This template lists `framer-motion` as a dependency. After foundation tokens, ensure `import { motion } from "framer-motion"` (and related APIs: `useScroll`, `useTransform`, `AnimatePresence`, `LayoutGroup`) for: scroll-triggered reveals, staggered children, layout transitions, and gestures — anything beyond a trivial one-property CSS `transition`. In each spec file, add a **Motion** subsection: trigger, duration, easing, delay/stagger, and **implementation: CSS | framer-motion**. Prefer CSS only when it matches the target exactly without JS.
|
|
58
|
+
|
|
51
59
|
### 1. Completeness Beats Speed
|
|
52
60
|
|
|
53
61
|
Every builder agent must receive **everything** it needs to do its job perfectly: screenshot, exact CSS values, downloaded assets with local paths, real text content, component structure. If a builder has to guess anything — a color, a font size, a padding value — you have failed at extraction. Take the extra minute to extract one more property rather than shipping an incomplete brief.
|
|
@@ -192,11 +200,12 @@ Save this as `docs/research/PAGE_TOPOLOGY.md` — it becomes your assembly bluep
|
|
|
192
200
|
This is sequential. Do it yourself (not delegated to an agent) since it touches many files:
|
|
193
201
|
|
|
194
202
|
1. **Update fonts** in `layout.tsx` to match the target site's actual fonts
|
|
195
|
-
2. **
|
|
196
|
-
3. **
|
|
197
|
-
4. **
|
|
198
|
-
5. **
|
|
199
|
-
6.
|
|
203
|
+
2. **Confirm Framer Motion** — `framer-motion` should already be in `package.json`. If missing, add it (`npm install framer-motion`) so builders can import `motion` without ad-hoc library drift.
|
|
204
|
+
3. **Update globals.css** with the target's color tokens, spacing values, keyframe animations, utility classes, and any **global scroll behaviors** (Lenis, smooth scroll CSS, scroll-snap on body)
|
|
205
|
+
4. **Media inventory + download (early, high priority)** — run the asset discovery script (below) via browser MCP, write `docs/research/MEDIA_MANIFEST.md`, then implement **`scripts/download-assets.mjs`** and execute it so **images** land in `public/images/` and **videos** (+ posters) in `public/videos/` (or a clear subdirectory scheme under `public/`). Batch parallel downloads (4 concurrent) with errors logged — do not claim success if URLs failed. This step should complete **before** most section components are built so builders use real paths.
|
|
206
|
+
5. **Create TypeScript interfaces** in `src/types/` for the content structures you've observed
|
|
207
|
+
6. **Extract SVG icons** — find all inline `<svg>` elements on the page, deduplicate them, and save as named React components in `src/components/icons.tsx`. Name them by visual function (e.g., `SearchIcon`, `ArrowRightIcon`, `LogoIcon`).
|
|
208
|
+
7. Verify: `npm run build` passes
|
|
200
209
|
|
|
201
210
|
### Asset Discovery Script Pattern
|
|
202
211
|
|
|
@@ -353,11 +362,16 @@ For each section (or sub-component, if you're breaking it up), create a spec fil
|
|
|
353
362
|
- **State A (before):** maxWidth: 100vw, boxShadow: none, borderRadius: 0
|
|
354
363
|
- **State B (after):** maxWidth: 1200px, boxShadow: 0 4px 20px rgba(0,0,0,0.1), borderRadius: 16px
|
|
355
364
|
- **Transition:** transition: all 0.3s ease
|
|
356
|
-
- **Implementation approach:** <CSS transition + scroll listener | IntersectionObserver | CSS animation-timeline | etc.>
|
|
365
|
+
- **Implementation approach:** <CSS transition + scroll listener | IntersectionObserver | CSS animation-timeline | **framer-motion** (`motion`, `whileInView`, stagger container) | etc.>
|
|
357
366
|
|
|
358
367
|
### Hover states
|
|
359
368
|
- **<Element>:** <property>: <before> → <after>, transition: <value>
|
|
360
369
|
|
|
370
|
+
## Motion (Framer Motion vs CSS)
|
|
371
|
+
- **Entrance / scroll reveals:** <e.g. fade+translateY, staggerChildren — specify duration, easing, delay, viewport `once`/`margin`>
|
|
372
|
+
- **Library:** <`framer-motion` | CSS-only — justify if CSS-only>
|
|
373
|
+
- **Keyframes / springs:** <if any — match target curve>
|
|
374
|
+
|
|
361
375
|
## Per-State Content (if applicable)
|
|
362
376
|
|
|
363
377
|
### State: "Featured"
|
|
@@ -369,9 +383,10 @@ For each section (or sub-component, if you're breaking it up), create a spec fil
|
|
|
369
383
|
- Title: "..."
|
|
370
384
|
- Cards: [...]
|
|
371
385
|
|
|
372
|
-
## Assets
|
|
373
|
-
-
|
|
374
|
-
-
|
|
386
|
+
## Assets (images & video — required detail)
|
|
387
|
+
- Raster: `public/images/<file>` — dimensions, `object-fit`, lazy if below fold
|
|
388
|
+
- Video: `public/videos/<file>` — poster `public/images/...` or `public/videos/...`, autoplay/muted/loop, controls
|
|
389
|
+
- Background layers: which div uses `background-image` and resolved URL → local path
|
|
375
390
|
- Icons used: <ArrowIcon>, <SearchIcon> from icons.tsx
|
|
376
391
|
|
|
377
392
|
## Text Content (verbatim)
|
|
@@ -445,7 +460,7 @@ For every section, replace:
|
|
|
445
460
|
7. **Metadata** — update `<title>`, meta description, OG tags, and favicon manifest in `src/app/layout.tsx` to reflect the new SaaS. Generate a simple favicon (initial letter on a brand-colored square) if no asset is provided.
|
|
446
461
|
|
|
447
462
|
What you must NOT change in this pass:
|
|
448
|
-
- Spacing, padding, typography scale, color tokens,
|
|
463
|
+
- Spacing, padding, typography scale, color tokens, **animation timing & motion choreography** (including Framer Motion `variants` / `transition` props), responsive breakpoints — those are still 1:1 to the original
|
|
449
464
|
- Section order, section count, component structure
|
|
450
465
|
- Interaction models (scroll-driven stays scroll-driven, etc.)
|
|
451
466
|
- Any computed-style value extracted in Phase 3
|
|
@@ -479,6 +494,8 @@ Before dispatching ANY builder agent, verify you can check every box. If you can
|
|
|
479
494
|
- [ ] For scroll-driven components: trigger threshold, before/after styles, and transition are recorded
|
|
480
495
|
- [ ] For hover states: before/after values and transition timing are recorded
|
|
481
496
|
- [ ] All images in the section are identified (including overlays and layered compositions)
|
|
497
|
+
- [ ] Any `<video>` (and poster), Lottie, or canvas-driven hero is identified — not approximated as a static div
|
|
498
|
+
- [ ] **Motion** subsection filled: CSS vs **framer-motion**, durations, easings, stagger, scroll triggers
|
|
482
499
|
- [ ] Responsive behavior is documented for at least desktop and mobile
|
|
483
500
|
- [ ] Text content is verbatim from the site, not paraphrased
|
|
484
501
|
- [ ] The builder prompt is under ~150 lines of spec; if over, the section needs to be split
|
|
@@ -495,6 +512,8 @@ These are lessons from previous failed clones — each one cost hours of rework:
|
|
|
495
512
|
- **Don't build everything in one monolithic commit.** The whole point of this pipeline is incremental progress with verified builds at each step.
|
|
496
513
|
- **Don't reference docs from builder prompts.** Each builder gets the CSS spec inline in its prompt — never "see DESIGN_TOKENS.md for colors." The builder should have zero need to read external docs.
|
|
497
514
|
- **Don't skip asset extraction.** Without real images, videos, and fonts, the clone will always look fake regardless of how perfect the CSS is.
|
|
515
|
+
- **Don't defer image/video download to the end.** Run `MEDIA_MANIFEST.md` + `download-assets.mjs` during foundation so components reference real `public/` paths from the first build.
|
|
516
|
+
- **Don't fake complex motion with a single CSS `transition` when the target uses staggered, scroll-scrubbed, or layout-driven animation** — use **`framer-motion`** (`motion`, `whileInView`, `variants`, `staggerChildren`) and match duration/easing from extraction.
|
|
498
517
|
- **Don't give a builder agent too much scope.** If you're writing a builder prompt and it's getting long because the section is complex, that's a signal to break it into smaller tasks.
|
|
499
518
|
- **Don't bundle unrelated sections into one agent.** A CTA section and a footer are different components with different designs — don't hand them both to one agent and hope for the best.
|
|
500
519
|
- **Don't skip responsive extraction.** If you only inspect at desktop width, the clone will break at tablet and mobile. Test at 1440, 768, and 390 during extraction.
|
|
@@ -509,7 +528,7 @@ When done, report:
|
|
|
509
528
|
- Total sections built
|
|
510
529
|
- Total components created
|
|
511
530
|
- Total spec files written (should match components)
|
|
512
|
-
- Total assets downloaded (images, videos, SVGs, fonts)
|
|
531
|
+
- Total assets downloaded (images, videos, SVGs, fonts) — path to `docs/research/MEDIA_MANIFEST.md`
|
|
513
532
|
- Rebrand summary (path to `docs/research/REBRAND.md`)
|
|
514
533
|
- Build status (`npm run build` result)
|
|
515
534
|
- Visual QA results (any remaining discrepancies)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: clone-website
|
|
3
|
-
description: Reverse-engineer and clone one or more websites in one shot —
|
|
3
|
+
description: Reverse-engineer and clone one or more websites in one shot — **prioritizes real images/videos** (download to public/) and **motion via Framer Motion** for non-trivial animation. Extracts assets, CSS, and content section-by-section and dispatches parallel builder agents in worktrees. Use this whenever the user wants to clone, replicate, rebuild, reverse-engineer, or copy any website. Also triggers on phrases like "make a copy of this site", "rebuild this page", "pixel-perfect clone", "launch a SaaS based on", "build me a clone of", and Launchframe shorthands **Build it**, **Go**, **Ship it**, **Clone the site** (read `launchframe.config.json` only — no URL in chat). This project was scaffolded by Launchframe — read `launchframe.config.json` for the target URL and the user's SaaS-idea rebranding directive before running. URLs can also be passed inline.
|
|
4
4
|
argument-hint: "[<url1> <url2> ...] (optional — defaults to launchframe.config.json)"
|
|
5
5
|
user-invocable: true
|
|
6
6
|
---
|
|
@@ -9,6 +9,8 @@ user-invocable: true
|
|
|
9
9
|
|
|
10
10
|
You are about to reverse-engineer and rebuild a website as a pixel-perfect clone, then re-skin the copy/branding for the user's SaaS idea.
|
|
11
11
|
|
|
12
|
+
**Launchframe shorthand:** If the user only says **Build it**, **Go**, **Ship it**, **Clone the site**, or **Run launchframe** with no URL in the message, treat that as an invocation of this skill with empty `$ARGUMENTS` — **`launchframe.config.json` alone** supplies `url` and `idea`. Proceed without asking them to repeat those values unless the file is missing or invalid.
|
|
13
|
+
|
|
12
14
|
## Step 0: Read `launchframe.config.json`
|
|
13
15
|
|
|
14
16
|
**Before doing anything else**, read `launchframe.config.json` at the project root. This file was written by the `launchframe` CLI when the project was scaffolded and is the authoritative source of:
|
|
@@ -36,17 +38,23 @@ If the user provides additional instructions (specific fidelity level, deeper cu
|
|
|
36
38
|
|
|
37
39
|
## Pre-Flight
|
|
38
40
|
|
|
39
|
-
1. **Read `launchframe.config.json`** (see Step 0 above).
|
|
41
|
+
1. **Read `launchframe.config.json`** (see Step 0 above). After a fresh `npx launchframe` scaffold, proceed immediately — only echo `url`/`idea` for confirmation if the config looks wrong or the user asked to verify.
|
|
40
42
|
2. **Browser automation is required.** Check for available browser MCP tools (Chrome MCP, Playwright MCP, Browserbase MCP, Puppeteer MCP, etc.). Use whichever is available — if multiple exist, prefer Chrome MCP. If none are detected, ask the user which browser tool they have and how to connect it. This skill cannot work without browser automation.
|
|
41
43
|
3. Validate the resolved URL(s). Normalize and verify each is accessible via your browser MCP tool. If any are invalid, ask the user to correct `launchframe.config.json` (or pass an override) before proceeding.
|
|
42
44
|
4. Verify the base project builds: `npm run build`. The Next.js + shadcn/ui + Tailwind v4 scaffold should already be in place. If not, tell the user to run `npm install` first.
|
|
43
|
-
5. Create the output directories if they don't exist: `docs/research/`, `docs/research/components/`, `docs/design-references/`, `scripts/`. For multiple clones, also prepare per-site folders like `docs/research/<hostname>/` and `docs/design-references/<hostname>/`.
|
|
45
|
+
5. Create the output directories if they don't exist: `docs/research/`, `docs/research/components/`, `docs/design-references/`, `scripts/`. Plan `docs/research/MEDIA_MANIFEST.md` as soon as media is inventoried. For multiple clones, also prepare per-site folders like `docs/research/<hostname>/` and `docs/design-references/<hostname>/`.
|
|
44
46
|
6. When working with multiple sites in one command, optionally confirm whether to run them in parallel (recommended, if resources allow) or sequentially to avoid overload.
|
|
45
47
|
|
|
46
48
|
## Guiding Principles
|
|
47
49
|
|
|
48
50
|
These are the truths that separate a successful clone from a "close enough" mess. Internalize them — they should inform every decision you make.
|
|
49
51
|
|
|
52
|
+
### 0. Launchframe priorities: media & motion (do not defer)
|
|
53
|
+
|
|
54
|
+
**Raster & video are first-class.** Before you treat the page as “mostly typography,” run a dedicated **media inventory** (see `@docs/research/INSPECTION_GUIDE.md` Priority section): every `<img>`, `<picture>` / `<source>`, `<video>` (+ poster), and non-trivial `background-image`. Download to `public/images/` and `public/videos/` and write `docs/research/MEDIA_MANIFEST.md` (URL → local path, or `BLOCKED` + reason). Component specs MUST list concrete `public/...` paths; if you use a placeholder, say why in `docs/research/EXTRACTION_LIMITATIONS.md`. Never silently drop a hero layer, reel, or og visual.
|
|
55
|
+
|
|
56
|
+
**Motion defaults to Framer Motion.** This template lists `framer-motion` as a dependency. After foundation tokens, ensure `import { motion } from "framer-motion"` (and related APIs: `useScroll`, `useTransform`, `AnimatePresence`, `LayoutGroup`) for: scroll-triggered reveals, staggered children, layout transitions, and gestures — anything beyond a trivial one-property CSS `transition`. In each spec file, add a **Motion** subsection: trigger, duration, easing, delay/stagger, and **implementation: CSS | framer-motion**. Prefer CSS only when it matches the target exactly without JS.
|
|
57
|
+
|
|
50
58
|
### 1. Completeness Beats Speed
|
|
51
59
|
|
|
52
60
|
Every builder agent must receive **everything** it needs to do its job perfectly: screenshot, exact CSS values, downloaded assets with local paths, real text content, component structure. If a builder has to guess anything — a color, a font size, a padding value — you have failed at extraction. Take the extra minute to extract one more property rather than shipping an incomplete brief.
|
|
@@ -191,11 +199,12 @@ Save this as `docs/research/PAGE_TOPOLOGY.md` — it becomes your assembly bluep
|
|
|
191
199
|
This is sequential. Do it yourself (not delegated to an agent) since it touches many files:
|
|
192
200
|
|
|
193
201
|
1. **Update fonts** in `layout.tsx` to match the target site's actual fonts
|
|
194
|
-
2. **
|
|
195
|
-
3. **
|
|
196
|
-
4. **
|
|
197
|
-
5. **
|
|
198
|
-
6.
|
|
202
|
+
2. **Confirm Framer Motion** — `framer-motion` should already be in `package.json`. If missing, add it (`npm install framer-motion`) so builders can import `motion` without ad-hoc library drift.
|
|
203
|
+
3. **Update globals.css** with the target's color tokens, spacing values, keyframe animations, utility classes, and any **global scroll behaviors** (Lenis, smooth scroll CSS, scroll-snap on body)
|
|
204
|
+
4. **Media inventory + download (early, high priority)** — run the asset discovery script (below) via browser MCP, write `docs/research/MEDIA_MANIFEST.md`, then implement **`scripts/download-assets.mjs`** and execute it so **images** land in `public/images/` and **videos** (+ posters) in `public/videos/` (or a clear subdirectory scheme under `public/`). Batch parallel downloads (4 concurrent) with errors logged — do not claim success if URLs failed. This step should complete **before** most section components are built so builders use real paths.
|
|
205
|
+
5. **Create TypeScript interfaces** in `src/types/` for the content structures you've observed
|
|
206
|
+
6. **Extract SVG icons** — find all inline `<svg>` elements on the page, deduplicate them, and save as named React components in `src/components/icons.tsx`. Name them by visual function (e.g., `SearchIcon`, `ArrowRightIcon`, `LogoIcon`).
|
|
207
|
+
7. Verify: `npm run build` passes
|
|
199
208
|
|
|
200
209
|
### Asset Discovery Script Pattern
|
|
201
210
|
|
|
@@ -352,11 +361,16 @@ For each section (or sub-component, if you're breaking it up), create a spec fil
|
|
|
352
361
|
- **State A (before):** maxWidth: 100vw, boxShadow: none, borderRadius: 0
|
|
353
362
|
- **State B (after):** maxWidth: 1200px, boxShadow: 0 4px 20px rgba(0,0,0,0.1), borderRadius: 16px
|
|
354
363
|
- **Transition:** transition: all 0.3s ease
|
|
355
|
-
- **Implementation approach:** <CSS transition + scroll listener | IntersectionObserver | CSS animation-timeline | etc.>
|
|
364
|
+
- **Implementation approach:** <CSS transition + scroll listener | IntersectionObserver | CSS animation-timeline | **framer-motion** (`motion`, `whileInView`, stagger container) | etc.>
|
|
356
365
|
|
|
357
366
|
### Hover states
|
|
358
367
|
- **<Element>:** <property>: <before> → <after>, transition: <value>
|
|
359
368
|
|
|
369
|
+
## Motion (Framer Motion vs CSS)
|
|
370
|
+
- **Entrance / scroll reveals:** <e.g. fade+translateY, staggerChildren — specify duration, easing, delay, viewport `once`/`margin`>
|
|
371
|
+
- **Library:** <`framer-motion` | CSS-only — justify if CSS-only>
|
|
372
|
+
- **Keyframes / springs:** <if any — match target curve>
|
|
373
|
+
|
|
360
374
|
## Per-State Content (if applicable)
|
|
361
375
|
|
|
362
376
|
### State: "Featured"
|
|
@@ -368,9 +382,10 @@ For each section (or sub-component, if you're breaking it up), create a spec fil
|
|
|
368
382
|
- Title: "..."
|
|
369
383
|
- Cards: [...]
|
|
370
384
|
|
|
371
|
-
## Assets
|
|
372
|
-
-
|
|
373
|
-
-
|
|
385
|
+
## Assets (images & video — required detail)
|
|
386
|
+
- Raster: `public/images/<file>` — dimensions, `object-fit`, lazy if below fold
|
|
387
|
+
- Video: `public/videos/<file>` — poster `public/images/...` or `public/videos/...`, autoplay/muted/loop, controls
|
|
388
|
+
- Background layers: which div uses `background-image` and resolved URL → local path
|
|
374
389
|
- Icons used: <ArrowIcon>, <SearchIcon> from icons.tsx
|
|
375
390
|
|
|
376
391
|
## Text Content (verbatim)
|
|
@@ -444,7 +459,7 @@ For every section, replace:
|
|
|
444
459
|
7. **Metadata** — update `<title>`, meta description, OG tags, and favicon manifest in `src/app/layout.tsx` to reflect the new SaaS. Generate a simple favicon (initial letter on a brand-colored square) if no asset is provided.
|
|
445
460
|
|
|
446
461
|
What you must NOT change in this pass:
|
|
447
|
-
- Spacing, padding, typography scale, color tokens,
|
|
462
|
+
- Spacing, padding, typography scale, color tokens, **animation timing & motion choreography** (including Framer Motion `variants` / `transition` props), responsive breakpoints — those are still 1:1 to the original
|
|
448
463
|
- Section order, section count, component structure
|
|
449
464
|
- Interaction models (scroll-driven stays scroll-driven, etc.)
|
|
450
465
|
- Any computed-style value extracted in Phase 3
|
|
@@ -478,6 +493,8 @@ Before dispatching ANY builder agent, verify you can check every box. If you can
|
|
|
478
493
|
- [ ] For scroll-driven components: trigger threshold, before/after styles, and transition are recorded
|
|
479
494
|
- [ ] For hover states: before/after values and transition timing are recorded
|
|
480
495
|
- [ ] All images in the section are identified (including overlays and layered compositions)
|
|
496
|
+
- [ ] Any `<video>` (and poster), Lottie, or canvas-driven hero is identified — not approximated as a static div
|
|
497
|
+
- [ ] **Motion** subsection filled: CSS vs **framer-motion**, durations, easings, stagger, scroll triggers
|
|
481
498
|
- [ ] Responsive behavior is documented for at least desktop and mobile
|
|
482
499
|
- [ ] Text content is verbatim from the site, not paraphrased
|
|
483
500
|
- [ ] The builder prompt is under ~150 lines of spec; if over, the section needs to be split
|
|
@@ -494,6 +511,8 @@ These are lessons from previous failed clones — each one cost hours of rework:
|
|
|
494
511
|
- **Don't build everything in one monolithic commit.** The whole point of this pipeline is incremental progress with verified builds at each step.
|
|
495
512
|
- **Don't reference docs from builder prompts.** Each builder gets the CSS spec inline in its prompt — never "see DESIGN_TOKENS.md for colors." The builder should have zero need to read external docs.
|
|
496
513
|
- **Don't skip asset extraction.** Without real images, videos, and fonts, the clone will always look fake regardless of how perfect the CSS is.
|
|
514
|
+
- **Don't defer image/video download to the end.** Run `MEDIA_MANIFEST.md` + `download-assets.mjs` during foundation so components reference real `public/` paths from the first build.
|
|
515
|
+
- **Don't fake complex motion with a single CSS `transition` when the target uses staggered, scroll-scrubbed, or layout-driven animation** — use **`framer-motion`** (`motion`, `whileInView`, `variants`, `staggerChildren`) and match duration/easing from extraction.
|
|
497
516
|
- **Don't give a builder agent too much scope.** If you're writing a builder prompt and it's getting long because the section is complex, that's a signal to break it into smaller tasks.
|
|
498
517
|
- **Don't bundle unrelated sections into one agent.** A CTA section and a footer are different components with different designs — don't hand them both to one agent and hope for the best.
|
|
499
518
|
- **Don't skip responsive extraction.** If you only inspect at desktop width, the clone will break at tablet and mobile. Test at 1440, 768, and 390 during extraction.
|
|
@@ -508,7 +527,7 @@ When done, report:
|
|
|
508
527
|
- Total sections built
|
|
509
528
|
- Total components created
|
|
510
529
|
- Total spec files written (should match components)
|
|
511
|
-
- Total assets downloaded (images, videos, SVGs, fonts)
|
|
530
|
+
- Total assets downloaded (images, videos, SVGs, fonts) — path to `docs/research/MEDIA_MANIFEST.md`
|
|
512
531
|
- Rebrand summary (path to `docs/research/REBRAND.md`)
|
|
513
532
|
- Build status (`npm run build` result)
|
|
514
533
|
- Visual QA results (any remaining discrepancies)
|
package/template/.clinerules
CHANGED
|
@@ -19,13 +19,26 @@ At the project root there is a `launchframe.config.json` containing:
|
|
|
19
19
|
|
|
20
20
|
**Always read this file first** at the start of any cloning or build task. The `/clone-website` skill depends on it.
|
|
21
21
|
|
|
22
|
+
## What the user says (zero-setup flow)
|
|
23
|
+
Users scaffold with `npx launchframe@latest <url> "<saas idea>"` — `npm install` already ran — then they open this folder and say **Build it** (or **Go**, **Ship it**, **Clone the site**).
|
|
24
|
+
|
|
25
|
+
When you see that with no other instructions, **start the full clone-website pipeline immediately** using only `launchframe.config.json` for `url` and `idea`. Do not ask them to repeat the URL unless the config is missing or invalid. `/clone-website` is an alias for the same work.
|
|
26
|
+
|
|
22
27
|
## Tech Stack
|
|
23
28
|
- **Framework:** Next.js 16 (App Router, React 19, TypeScript strict)
|
|
24
29
|
- **UI:** shadcn/ui (Radix primitives, Tailwind CSS v4, `cn()` utility)
|
|
30
|
+
- **Motion:** **Framer Motion** (`framer-motion`) — **default for non-trivial animation** (scroll reveals, staggers, layout, gestures). Use CSS `transition` / `@keyframes` only when they reproduce the target exactly without JS.
|
|
25
31
|
- **Icons:** Lucide React (default — will be replaced/supplemented by extracted SVGs)
|
|
26
32
|
- **Styling:** Tailwind CSS v4 with oklch design tokens
|
|
33
|
+
- **Media:** Real **images & videos** from the target URL, saved under `public/images/` and `public/videos/` (see `.claude/skills/clone-website/SKILL.md` and `docs/research/INSPECTION_GUIDE.md`). Do not ship a “pretty shell” with missing raster/video unless extraction is **blocked** and documented in `docs/research/EXTRACTION_LIMITATIONS.md`.
|
|
27
34
|
- **Deployment:** Vercel
|
|
28
35
|
|
|
36
|
+
## Priority: images, videos & motion
|
|
37
|
+
Treat these as **first-class deliverables**, not polish at the end.
|
|
38
|
+
|
|
39
|
+
1. **Raster & video** — Early in recon, inventory every `<img>`, `<picture>` / `<source>`, `<video>`, poster image, and meaningful `background-image` URL. Download into `public/` and reference **local paths** in specs and components. Hero bands and marketing sections often fail visually when a single layer is skipped.
|
|
40
|
+
2. **Motion** — Match the target’s feel: easing, duration, stagger, scroll triggers. Prefer **`motion` from `framer-motion`** for entrance sequences, viewport-driven animations, shared-layout-style transitions, and anything beyond a one-off CSS transition. Note in each component spec whether behavior is **CSS-only** vs **Framer Motion**.
|
|
41
|
+
|
|
29
42
|
## Commands
|
|
30
43
|
- `npm run dev` — Start dev server
|
|
31
44
|
- `npm run build` — Production build
|
|
@@ -41,6 +54,8 @@ At the project root there is a `launchframe.config.json` containing:
|
|
|
41
54
|
- Responsive: mobile-first
|
|
42
55
|
|
|
43
56
|
## Design Principles
|
|
57
|
+
- **Images & video fidelity** — prefer real downloaded assets; preserve aspect ratio, `object-fit`, layering, and poster frames. Rebrand pass may **swap** URLs for IP-safe alternates but must keep layout identical.
|
|
58
|
+
- **Motion fidelity** — timing and easing matter as much as color; use Framer Motion when CSS alone cannot match staggered or scroll-driven behavior.
|
|
44
59
|
- **Pixel-perfect emulation** — match the target's spacing, colors, typography exactly
|
|
45
60
|
- **No personal aesthetic changes during emulation phase** — match 1:1 first, rebrand later
|
|
46
61
|
- **Real content during extraction** — use actual text and assets from the target site so the clone scaffolds against real shapes
|
|
@@ -76,6 +91,31 @@ scripts/ # Asset download scripts
|
|
|
76
91
|
|
|
77
92
|
# Website Inspection Guide
|
|
78
93
|
|
|
94
|
+
## Priority (read first): media & motion
|
|
95
|
+
|
|
96
|
+
Launchframe clones live pages for a **visual** result. Two things most often separate a convincing build from a hollow one:
|
|
97
|
+
|
|
98
|
+
### 1. Images & video (do this before obsessing over utility classes)
|
|
99
|
+
|
|
100
|
+
- [ ] **Every `<img>`** — `src` / `srcset` / `currentSrc`, `sizes`, `loading`, `decoding`, `alt`, intrinsic dimensions
|
|
101
|
+
- [ ] **`<picture>` / `<source>`** — resolution switches, art direction, `type` (WebP/AVIF)
|
|
102
|
+
- [ ] **Every `<video>`** — `src` + nested `<source>`, **poster**, `autoplay`, `loop`, `muted`, `playsinline`, `controls`
|
|
103
|
+
- [ ] **Background images** — `background-image` on ancestors (hero stacks are often **layers** of img + gradient + PNG mockup)
|
|
104
|
+
- [ ] **Lazy / below-fold** — scroll the page once before asset discovery so `data-src` / lazy-loaded URLs resolve if the site uses them
|
|
105
|
+
- [ ] **Download** — mirror into `public/images/` and `public/videos/` with stable paths; list failures in `docs/research/EXTRACTION_LIMITATIONS.md`
|
|
106
|
+
|
|
107
|
+
If automation hits a bot wall, **do not pretend extraction succeeded** — capture what you can from successful fetches and document gaps.
|
|
108
|
+
|
|
109
|
+
### 2. Motion (prefer Framer Motion in this repo)
|
|
110
|
+
|
|
111
|
+
- [ ] **Entrance** — fade/slide/scale on mount or on **scroll into view** (note threshold / `margin`)
|
|
112
|
+
- [ ] **Stagger** — children animating in sequence (hero bullets, card grids)
|
|
113
|
+
- [ ] **Scroll-linked** — progress, parallax, pinned sections (may combine with CSS `animation-timeline` or libs)
|
|
114
|
+
- [ ] **Gestures** — drag, pan, hover follow (often Framer Motion)
|
|
115
|
+
- [ ] **Implementation rule** — use **`framer-motion`** for anything beyond trivial single-property CSS `transition`. Record **duration, easing, delay, stagger**, and **trigger** (scroll, hover, tap) in specs.
|
|
116
|
+
|
|
117
|
+
---
|
|
118
|
+
|
|
79
119
|
## How to Reverse-Engineer Any Website
|
|
80
120
|
|
|
81
121
|
This guide outlines what to capture when inspecting a target website via Chrome MCP or browser DevTools.
|
|
@@ -90,6 +130,8 @@ This guide outlines what to capture when inspecting a target website via Chrome
|
|
|
90
130
|
- [ ] Loading/skeleton states
|
|
91
131
|
- [ ] Empty states
|
|
92
132
|
- [ ] Error states
|
|
133
|
+
- [ ] **Video frames** — capture a frame mid-play for reference if motion is subtle
|
|
134
|
+
- [ ] **Hero / full-bleed** — wide crops where raster layers are easy to miss
|
|
93
135
|
|
|
94
136
|
### Design Tokens to Extract
|
|
95
137
|
- [ ] **Colors** — background, text (primary/secondary/muted), accent, border, hover, error, success, warning
|
|
@@ -112,7 +154,7 @@ For each distinct UI component, document:
|
|
|
112
154
|
4. **States** — default, hover, active, disabled, loading, error, empty
|
|
113
155
|
5. **Responsive behavior** — how does it change at different breakpoints?
|
|
114
156
|
6. **Interactions** — click, hover, focus, keyboard navigation
|
|
115
|
-
7. **Animations** — transitions, entrance/exit
|
|
157
|
+
7. **Animations** — transitions, entrance/exit, micro-interactions — **`framer-motion` vs CSS** and exact timing
|
|
116
158
|
|
|
117
159
|
### Common Components to Look For
|
|
118
160
|
- Navigation (top bar, sidebar, bottom bar)
|
|
@@ -126,6 +168,7 @@ For each distinct UI component, document:
|
|
|
126
168
|
- Loading skeletons
|
|
127
169
|
- Toast notifications
|
|
128
170
|
- Tooltips and popovers
|
|
171
|
+
- **Video / Lottie / canvas** blocks (do not substitute with static mockups without documenting why)
|
|
129
172
|
|
|
130
173
|
## Phase 3: Layout Architecture
|
|
131
174
|
|
|
@@ -143,14 +186,15 @@ For each distinct UI component, document:
|
|
|
143
186
|
- [ ] **State management** — Redux (check DevTools), React Query, Zustand, Pinia
|
|
144
187
|
- [ ] **API patterns** — REST, GraphQL (check network tab for `/graphql` requests)
|
|
145
188
|
- [ ] **Font loading** — Google Fonts, self-hosted, system fonts
|
|
146
|
-
- [ ] **Image strategy** — CDN, lazy loading, srcset, WebP/AVIF
|
|
147
|
-
- [ ] **Animation library** —
|
|
189
|
+
- [ ] **Image strategy** — CDN, lazy loading, srcset, WebP/AVIF — **mirror URLs you are allowed to fetch**
|
|
190
|
+
- [ ] **Animation library** — site may use GSAP, Lottie, Rive, or CSS only — **in the Next.js clone, default to Framer Motion** unless a different lib is required for parity
|
|
148
191
|
|
|
149
192
|
## Phase 5: Documentation Output
|
|
150
193
|
|
|
151
194
|
After inspection, create these files in `docs/research/`:
|
|
152
195
|
1. `DESIGN_TOKENS.md` — All extracted colors, typography, spacing
|
|
153
196
|
2. `COMPONENT_INVENTORY.md` — Every component with structure notes
|
|
154
|
-
3.
|
|
155
|
-
4. `
|
|
156
|
-
5. `
|
|
197
|
+
3. **`MEDIA_MANIFEST.md`** — (recommended) Table of every image/video/poster URL → local `public/` path or “blocked”
|
|
198
|
+
4. `LAYOUT_ARCHITECTURE.md` — Page layouts, grid system, responsive behavior
|
|
199
|
+
5. `INTERACTION_PATTERNS.md` — Animations: **CSS vs Framer Motion**, transitions, hover states
|
|
200
|
+
6. `TECH_STACK_ANALYSIS.md` — What the site uses and our chosen equivalents (Framer Motion for React animation)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: clone-website
|
|
3
|
-
description: Reverse-engineer and clone one or more websites in one shot —
|
|
3
|
+
description: Reverse-engineer and clone one or more websites in one shot — **prioritizes real images/videos** (download to public/) and **motion via Framer Motion** for non-trivial animation. Extracts assets, CSS, and content section-by-section and dispatches parallel builder agents in worktrees. Use this whenever the user wants to clone, replicate, rebuild, reverse-engineer, or copy any website. Also triggers on phrases like "make a copy of this site", "rebuild this page", "pixel-perfect clone", "launch a SaaS based on", "build me a clone of", and Launchframe shorthands **Build it**, **Go**, **Ship it**, **Clone the site** (read `launchframe.config.json` only — no URL in chat). This project was scaffolded by Launchframe — read `launchframe.config.json` for the target URL and the user's SaaS-idea rebranding directive before running. URLs can also be passed inline.
|
|
4
4
|
argument-hint: "[<url1> <url2> ...] (optional — defaults to launchframe.config.json)"
|
|
5
5
|
user-invocable: true
|
|
6
6
|
---
|
|
@@ -9,6 +9,8 @@ user-invocable: true
|
|
|
9
9
|
|
|
10
10
|
You are about to reverse-engineer and rebuild a website as a pixel-perfect clone, then re-skin the copy/branding for the user's SaaS idea.
|
|
11
11
|
|
|
12
|
+
**Launchframe shorthand:** If the user only says **Build it**, **Go**, **Ship it**, **Clone the site**, or **Run launchframe** with no URL in the message, treat that as an invocation of this skill with empty `$ARGUMENTS` — **`launchframe.config.json` alone** supplies `url` and `idea`. Proceed without asking them to repeat those values unless the file is missing or invalid.
|
|
13
|
+
|
|
12
14
|
## Step 0: Read `launchframe.config.json`
|
|
13
15
|
|
|
14
16
|
**Before doing anything else**, read `launchframe.config.json` at the project root. This file was written by the `launchframe` CLI when the project was scaffolded and is the authoritative source of:
|
|
@@ -36,17 +38,23 @@ If the user provides additional instructions (specific fidelity level, deeper cu
|
|
|
36
38
|
|
|
37
39
|
## Pre-Flight
|
|
38
40
|
|
|
39
|
-
1. **Read `launchframe.config.json`** (see Step 0 above).
|
|
41
|
+
1. **Read `launchframe.config.json`** (see Step 0 above). After a fresh `npx launchframe` scaffold, proceed immediately — only echo `url`/`idea` for confirmation if the config looks wrong or the user asked to verify.
|
|
40
42
|
2. **Browser automation is required.** Check for available browser MCP tools (Chrome MCP, Playwright MCP, Browserbase MCP, Puppeteer MCP, etc.). Use whichever is available — if multiple exist, prefer Chrome MCP. If none are detected, ask the user which browser tool they have and how to connect it. This skill cannot work without browser automation.
|
|
41
43
|
3. Validate the resolved URL(s). Normalize and verify each is accessible via your browser MCP tool. If any are invalid, ask the user to correct `launchframe.config.json` (or pass an override) before proceeding.
|
|
42
44
|
4. Verify the base project builds: `npm run build`. The Next.js + shadcn/ui + Tailwind v4 scaffold should already be in place. If not, tell the user to run `npm install` first.
|
|
43
|
-
5. Create the output directories if they don't exist: `docs/research/`, `docs/research/components/`, `docs/design-references/`, `scripts/`. For multiple clones, also prepare per-site folders like `docs/research/<hostname>/` and `docs/design-references/<hostname>/`.
|
|
45
|
+
5. Create the output directories if they don't exist: `docs/research/`, `docs/research/components/`, `docs/design-references/`, `scripts/`. Plan `docs/research/MEDIA_MANIFEST.md` as soon as media is inventoried. For multiple clones, also prepare per-site folders like `docs/research/<hostname>/` and `docs/design-references/<hostname>/`.
|
|
44
46
|
6. When working with multiple sites in one command, optionally confirm whether to run them in parallel (recommended, if resources allow) or sequentially to avoid overload.
|
|
45
47
|
|
|
46
48
|
## Guiding Principles
|
|
47
49
|
|
|
48
50
|
These are the truths that separate a successful clone from a "close enough" mess. Internalize them — they should inform every decision you make.
|
|
49
51
|
|
|
52
|
+
### 0. Launchframe priorities: media & motion (do not defer)
|
|
53
|
+
|
|
54
|
+
**Raster & video are first-class.** Before you treat the page as “mostly typography,” run a dedicated **media inventory** (see `@docs/research/INSPECTION_GUIDE.md` Priority section): every `<img>`, `<picture>` / `<source>`, `<video>` (+ poster), and non-trivial `background-image`. Download to `public/images/` and `public/videos/` and write `docs/research/MEDIA_MANIFEST.md` (URL → local path, or `BLOCKED` + reason). Component specs MUST list concrete `public/...` paths; if you use a placeholder, say why in `docs/research/EXTRACTION_LIMITATIONS.md`. Never silently drop a hero layer, reel, or og visual.
|
|
55
|
+
|
|
56
|
+
**Motion defaults to Framer Motion.** This template lists `framer-motion` as a dependency. After foundation tokens, ensure `import { motion } from "framer-motion"` (and related APIs: `useScroll`, `useTransform`, `AnimatePresence`, `LayoutGroup`) for: scroll-triggered reveals, staggered children, layout transitions, and gestures — anything beyond a trivial one-property CSS `transition`. In each spec file, add a **Motion** subsection: trigger, duration, easing, delay/stagger, and **implementation: CSS | framer-motion**. Prefer CSS only when it matches the target exactly without JS.
|
|
57
|
+
|
|
50
58
|
### 1. Completeness Beats Speed
|
|
51
59
|
|
|
52
60
|
Every builder agent must receive **everything** it needs to do its job perfectly: screenshot, exact CSS values, downloaded assets with local paths, real text content, component structure. If a builder has to guess anything — a color, a font size, a padding value — you have failed at extraction. Take the extra minute to extract one more property rather than shipping an incomplete brief.
|
|
@@ -191,11 +199,12 @@ Save this as `docs/research/PAGE_TOPOLOGY.md` — it becomes your assembly bluep
|
|
|
191
199
|
This is sequential. Do it yourself (not delegated to an agent) since it touches many files:
|
|
192
200
|
|
|
193
201
|
1. **Update fonts** in `layout.tsx` to match the target site's actual fonts
|
|
194
|
-
2. **
|
|
195
|
-
3. **
|
|
196
|
-
4. **
|
|
197
|
-
5. **
|
|
198
|
-
6.
|
|
202
|
+
2. **Confirm Framer Motion** — `framer-motion` should already be in `package.json`. If missing, add it (`npm install framer-motion`) so builders can import `motion` without ad-hoc library drift.
|
|
203
|
+
3. **Update globals.css** with the target's color tokens, spacing values, keyframe animations, utility classes, and any **global scroll behaviors** (Lenis, smooth scroll CSS, scroll-snap on body)
|
|
204
|
+
4. **Media inventory + download (early, high priority)** — run the asset discovery script (below) via browser MCP, write `docs/research/MEDIA_MANIFEST.md`, then implement **`scripts/download-assets.mjs`** and execute it so **images** land in `public/images/` and **videos** (+ posters) in `public/videos/` (or a clear subdirectory scheme under `public/`). Batch parallel downloads (4 concurrent) with errors logged — do not claim success if URLs failed. This step should complete **before** most section components are built so builders use real paths.
|
|
205
|
+
5. **Create TypeScript interfaces** in `src/types/` for the content structures you've observed
|
|
206
|
+
6. **Extract SVG icons** — find all inline `<svg>` elements on the page, deduplicate them, and save as named React components in `src/components/icons.tsx`. Name them by visual function (e.g., `SearchIcon`, `ArrowRightIcon`, `LogoIcon`).
|
|
207
|
+
7. Verify: `npm run build` passes
|
|
199
208
|
|
|
200
209
|
### Asset Discovery Script Pattern
|
|
201
210
|
|
|
@@ -352,11 +361,16 @@ For each section (or sub-component, if you're breaking it up), create a spec fil
|
|
|
352
361
|
- **State A (before):** maxWidth: 100vw, boxShadow: none, borderRadius: 0
|
|
353
362
|
- **State B (after):** maxWidth: 1200px, boxShadow: 0 4px 20px rgba(0,0,0,0.1), borderRadius: 16px
|
|
354
363
|
- **Transition:** transition: all 0.3s ease
|
|
355
|
-
- **Implementation approach:** <CSS transition + scroll listener | IntersectionObserver | CSS animation-timeline | etc.>
|
|
364
|
+
- **Implementation approach:** <CSS transition + scroll listener | IntersectionObserver | CSS animation-timeline | **framer-motion** (`motion`, `whileInView`, stagger container) | etc.>
|
|
356
365
|
|
|
357
366
|
### Hover states
|
|
358
367
|
- **<Element>:** <property>: <before> → <after>, transition: <value>
|
|
359
368
|
|
|
369
|
+
## Motion (Framer Motion vs CSS)
|
|
370
|
+
- **Entrance / scroll reveals:** <e.g. fade+translateY, staggerChildren — specify duration, easing, delay, viewport `once`/`margin`>
|
|
371
|
+
- **Library:** <`framer-motion` | CSS-only — justify if CSS-only>
|
|
372
|
+
- **Keyframes / springs:** <if any — match target curve>
|
|
373
|
+
|
|
360
374
|
## Per-State Content (if applicable)
|
|
361
375
|
|
|
362
376
|
### State: "Featured"
|
|
@@ -368,9 +382,10 @@ For each section (or sub-component, if you're breaking it up), create a spec fil
|
|
|
368
382
|
- Title: "..."
|
|
369
383
|
- Cards: [...]
|
|
370
384
|
|
|
371
|
-
## Assets
|
|
372
|
-
-
|
|
373
|
-
-
|
|
385
|
+
## Assets (images & video — required detail)
|
|
386
|
+
- Raster: `public/images/<file>` — dimensions, `object-fit`, lazy if below fold
|
|
387
|
+
- Video: `public/videos/<file>` — poster `public/images/...` or `public/videos/...`, autoplay/muted/loop, controls
|
|
388
|
+
- Background layers: which div uses `background-image` and resolved URL → local path
|
|
374
389
|
- Icons used: <ArrowIcon>, <SearchIcon> from icons.tsx
|
|
375
390
|
|
|
376
391
|
## Text Content (verbatim)
|
|
@@ -444,7 +459,7 @@ For every section, replace:
|
|
|
444
459
|
7. **Metadata** — update `<title>`, meta description, OG tags, and favicon manifest in `src/app/layout.tsx` to reflect the new SaaS. Generate a simple favicon (initial letter on a brand-colored square) if no asset is provided.
|
|
445
460
|
|
|
446
461
|
What you must NOT change in this pass:
|
|
447
|
-
- Spacing, padding, typography scale, color tokens,
|
|
462
|
+
- Spacing, padding, typography scale, color tokens, **animation timing & motion choreography** (including Framer Motion `variants` / `transition` props), responsive breakpoints — those are still 1:1 to the original
|
|
448
463
|
- Section order, section count, component structure
|
|
449
464
|
- Interaction models (scroll-driven stays scroll-driven, etc.)
|
|
450
465
|
- Any computed-style value extracted in Phase 3
|
|
@@ -478,6 +493,8 @@ Before dispatching ANY builder agent, verify you can check every box. If you can
|
|
|
478
493
|
- [ ] For scroll-driven components: trigger threshold, before/after styles, and transition are recorded
|
|
479
494
|
- [ ] For hover states: before/after values and transition timing are recorded
|
|
480
495
|
- [ ] All images in the section are identified (including overlays and layered compositions)
|
|
496
|
+
- [ ] Any `<video>` (and poster), Lottie, or canvas-driven hero is identified — not approximated as a static div
|
|
497
|
+
- [ ] **Motion** subsection filled: CSS vs **framer-motion**, durations, easings, stagger, scroll triggers
|
|
481
498
|
- [ ] Responsive behavior is documented for at least desktop and mobile
|
|
482
499
|
- [ ] Text content is verbatim from the site, not paraphrased
|
|
483
500
|
- [ ] The builder prompt is under ~150 lines of spec; if over, the section needs to be split
|
|
@@ -494,6 +511,8 @@ These are lessons from previous failed clones — each one cost hours of rework:
|
|
|
494
511
|
- **Don't build everything in one monolithic commit.** The whole point of this pipeline is incremental progress with verified builds at each step.
|
|
495
512
|
- **Don't reference docs from builder prompts.** Each builder gets the CSS spec inline in its prompt — never "see DESIGN_TOKENS.md for colors." The builder should have zero need to read external docs.
|
|
496
513
|
- **Don't skip asset extraction.** Without real images, videos, and fonts, the clone will always look fake regardless of how perfect the CSS is.
|
|
514
|
+
- **Don't defer image/video download to the end.** Run `MEDIA_MANIFEST.md` + `download-assets.mjs` during foundation so components reference real `public/` paths from the first build.
|
|
515
|
+
- **Don't fake complex motion with a single CSS `transition` when the target uses staggered, scroll-scrubbed, or layout-driven animation** — use **`framer-motion`** (`motion`, `whileInView`, `variants`, `staggerChildren`) and match duration/easing from extraction.
|
|
497
516
|
- **Don't give a builder agent too much scope.** If you're writing a builder prompt and it's getting long because the section is complex, that's a signal to break it into smaller tasks.
|
|
498
517
|
- **Don't bundle unrelated sections into one agent.** A CTA section and a footer are different components with different designs — don't hand them both to one agent and hope for the best.
|
|
499
518
|
- **Don't skip responsive extraction.** If you only inspect at desktop width, the clone will break at tablet and mobile. Test at 1440, 768, and 390 during extraction.
|
|
@@ -508,7 +527,7 @@ When done, report:
|
|
|
508
527
|
- Total sections built
|
|
509
528
|
- Total components created
|
|
510
529
|
- Total spec files written (should match components)
|
|
511
|
-
- Total assets downloaded (images, videos, SVGs, fonts)
|
|
530
|
+
- Total assets downloaded (images, videos, SVGs, fonts) — path to `docs/research/MEDIA_MANIFEST.md`
|
|
512
531
|
- Rebrand summary (path to `docs/research/REBRAND.md`)
|
|
513
532
|
- Build status (`npm run build` result)
|
|
514
533
|
- Visual QA results (any remaining discrepancies)
|