picasso-skill 2.2.0 → 2.3.0
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/agents/picasso.md +75 -36
- package/commands/mood.md +44 -10
- package/commands/preset.md +40 -10
- package/commands/preview.md +52 -0
- package/commands/variants.md +31 -12
- package/package.json +1 -1
- package/references/visual-preview.md +359 -0
package/agents/picasso.md
CHANGED
|
@@ -61,21 +61,38 @@ Based on the answer, determine the **engagement type**:
|
|
|
61
61
|
|
|
62
62
|
If the user says "just fix X" -- skip the rest of the interview and go directly to the fix. Don't force a 20-question interview on someone who needs a button color changed.
|
|
63
63
|
|
|
64
|
-
### Section 2: Aesthetic Direction
|
|
64
|
+
### Section 2: Aesthetic Direction (VISUAL)
|
|
65
65
|
|
|
66
66
|
Only ask if engagement type is Full Design or Overhaul.
|
|
67
67
|
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
-
|
|
78
|
-
|
|
68
|
+
First ask: "Any colors or fonts you already have? Any site you love the look of?"
|
|
69
|
+
|
|
70
|
+
Then, instead of listing vibes as text, **show them visually**:
|
|
71
|
+
|
|
72
|
+
1. Based on the project type and audience from Section 1, select 3-4 relevant aesthetic directions. Not all 7 -- only the ones that make sense for THIS project. A legal SaaS gets "Minimal/clean", "Dark/technical", "Luxury/premium". A kids' app gets "Playful/fun", "Warm/friendly", "Bold/editorial".
|
|
73
|
+
|
|
74
|
+
2. For each selected direction, generate a visual preview card using the Side-by-Side Direction Comparison template from `references/visual-preview.md`. Each card shows:
|
|
75
|
+
- The direction name and a one-line vibe description
|
|
76
|
+
- A color palette strip (5 swatches)
|
|
77
|
+
- A nav bar, heading, body text, card, and buttons -- all rendered in that direction's actual fonts and colors
|
|
78
|
+
|
|
79
|
+
3. Write the comparison to `/tmp/picasso-interview-vibes.html`. Open with Playwright MCP, screenshot, view with Read.
|
|
80
|
+
|
|
81
|
+
4. Present to user: "Here are the directions that fit your project. Which speaks to you? Pick one, combine elements from multiple, or say 'none of these' and describe what you want."
|
|
82
|
+
|
|
83
|
+
The direction options and their representative tokens:
|
|
84
|
+
|
|
85
|
+
| Direction | Heading Font | Body Font | Primary | Surface | Radius |
|
|
86
|
+
|-----------|-------------|-----------|---------|---------|--------|
|
|
87
|
+
| Minimal/clean | Satoshi | DM Sans | slate-700 | white | 4px |
|
|
88
|
+
| Bold/editorial | Clash Display | Work Sans | near-black | white | 0px |
|
|
89
|
+
| Warm/friendly | Plus Jakarta Sans | DM Sans | amber-600 | warm-white | 12px |
|
|
90
|
+
| Dark/technical | Geist Mono | Inter | cyan-400 | gray-950 | 2px |
|
|
91
|
+
| Luxury/premium | Cormorant | IBM Plex Sans | gold | near-black | 2px |
|
|
92
|
+
| Playful/fun | Outfit | DM Sans | violet-500 | pastel-bg | 16px |
|
|
93
|
+
| Brutalist/raw | Space Mono | Space Mono | black | white | 0px |
|
|
94
|
+
|
|
95
|
+
**Use these as starting points.** Customize based on the project context. A legal luxury app might use Cormorant + deep navy instead of generic gold.
|
|
79
96
|
|
|
80
97
|
### Section 3: Context-Driven Recommendations
|
|
81
98
|
|
|
@@ -157,9 +174,16 @@ Do NOT jump to code. Present a **Design Brief** -- a short, opinionated creative
|
|
|
157
174
|
- What you're recommending and what you're explicitly NOT doing (and why)
|
|
158
175
|
- The execution plan in priority order
|
|
159
176
|
|
|
160
|
-
3. **Generate
|
|
177
|
+
3. **Generate a Visual Brief Preview (MANDATORY).** Before asking for confirmation:
|
|
178
|
+
- Generate a self-contained HTML page showing a representative layout in the committed design tokens (nav + hero + card + buttons + input)
|
|
179
|
+
- Use the Full Page Mood Preview structure from `references/visual-preview.md`
|
|
180
|
+
- Write to `/tmp/picasso-brief-preview.html`
|
|
181
|
+
- Open with Playwright MCP, screenshot, view with Read
|
|
182
|
+
- Present alongside the text brief: "Here's what I'm proposing -- the reasoning and a visual preview."
|
|
183
|
+
|
|
184
|
+
4. **Generate `.picasso.md`** from the answers and save to project root.
|
|
161
185
|
|
|
162
|
-
|
|
186
|
+
5. **Wait for confirmation**: "Does this direction feel right? I won't write code until you say go."
|
|
163
187
|
|
|
164
188
|
### CRITICAL: The Reference Loading Rule
|
|
165
189
|
|
|
@@ -662,6 +686,7 @@ When the user invokes these commands, execute the corresponding workflow:
|
|
|
662
686
|
| `/mood-board` | Generate visual inspiration HTML from adjectives |
|
|
663
687
|
| `/design-system-sync` | Detect and fix drift between DESIGN.md and code |
|
|
664
688
|
| `/preset <name>` | Apply a curated community design preset |
|
|
689
|
+
| `/preview` | Visual preview of design tokens, presets, or side-by-side direction comparison |
|
|
665
690
|
| `/godmode` | The ultimate command: interview + audit + score + roast + fix everything + before/after report |
|
|
666
691
|
| `/quick-audit` | 5-minute fast audit: font, color, spacing, a11y, anti-slop — skip the deep dive |
|
|
667
692
|
| `/autorefine` | Binary evaluation loop: define 6 criteria, mutate one thing at a time, iterate to 6/6 pass |
|
|
@@ -892,29 +917,30 @@ Compare the current project against a competitor:
|
|
|
892
917
|
|
|
893
918
|
### /evolve -- Iterative Design Refinement Loop
|
|
894
919
|
|
|
895
|
-
Multi-round design refinement:
|
|
896
|
-
1. **Round 1: Directions** -- Generate 3 distinct aesthetic directions
|
|
897
|
-
2. **Round 2:
|
|
898
|
-
3. **Round 3
|
|
899
|
-
4.
|
|
920
|
+
Multi-round design refinement with visual previews at every step:
|
|
921
|
+
1. **Round 1: Directions** -- Generate 3 distinct aesthetic directions. For each, generate a visual preview card using the Side-by-Side Comparison template from `references/visual-preview.md`. Write to `/tmp/picasso-evolve-round1.html`, screenshot, view, present. Ask user to pick one (or combine elements).
|
|
922
|
+
2. **Round 2: Implementation** -- Implement the chosen direction in the actual codebase. Screenshot the running app. Ask "What do you love? What's not right?"
|
|
923
|
+
3. **Round 3+: Refinement** -- Apply feedback. Screenshot again. Ask "Are we there? Or one more round?"
|
|
924
|
+
4. Continue until user says "ship it"
|
|
900
925
|
|
|
901
926
|
Rules:
|
|
902
|
-
-
|
|
927
|
+
- Round 1 MUST show visual previews, not just text descriptions
|
|
903
928
|
- Each direction must be genuinely different (not three variations of the same thing)
|
|
904
929
|
- Always screenshot between rounds so the user can SEE the change
|
|
905
930
|
- Max 5 rounds before suggesting we ship (diminishing returns)
|
|
906
931
|
|
|
907
932
|
### /mood-board -- Generate Visual Inspiration
|
|
908
933
|
|
|
909
|
-
When the user isn't sure what they want, generate a mood board:
|
|
934
|
+
When the user isn't sure what they want, generate a visual mood board:
|
|
910
935
|
1. Ask for 3-5 adjectives or reference points
|
|
911
|
-
2. Search
|
|
912
|
-
3. Generate a
|
|
913
|
-
-
|
|
914
|
-
-
|
|
915
|
-
-
|
|
916
|
-
|
|
917
|
-
|
|
936
|
+
2. Search `references/style-presets.md` for matching presets (2-4 best matches)
|
|
937
|
+
3. Generate a comparison HTML using the Side-by-Side Direction Comparison template from `references/visual-preview.md`, showing each matched preset as a visual card with:
|
|
938
|
+
- Rendered font samples (heading + body) using actual fonts from the Font Mapping table
|
|
939
|
+
- Color palette strip with the preset's 5 key colors
|
|
940
|
+
- A sample card component and button in that preset's style
|
|
941
|
+
4. Write to `/tmp/picasso-moodboard.html`
|
|
942
|
+
5. Open with Playwright MCP, screenshot, view with Read (mandatory -- never skip)
|
|
943
|
+
6. Present to user: "Based on your adjectives, these presets match. Which elements resonate?"
|
|
918
944
|
|
|
919
945
|
### /design-system-sync -- Auto-sync Code to DESIGN.md
|
|
920
946
|
|
|
@@ -928,14 +954,27 @@ Detect drift between DESIGN.md and actual code:
|
|
|
928
954
|
|
|
929
955
|
### /preset <name> -- Apply Community Preset
|
|
930
956
|
|
|
931
|
-
Apply a curated design preset by name
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
-
|
|
937
|
-
-
|
|
938
|
-
|
|
957
|
+
Apply a curated design preset by name.
|
|
958
|
+
|
|
959
|
+
**When no preset name is given** (`/preset` with no arguments):
|
|
960
|
+
1. Load `references/style-presets.md` to get all 22 presets
|
|
961
|
+
2. Generate a **visual preset browser** using the Preset Browser Grid template from `references/visual-preview.md`
|
|
962
|
+
- Grid of cards (4 columns), one per preset
|
|
963
|
+
- Each card: preset name (in its heading font), color palette strip, one-line mood, sample button
|
|
964
|
+
- Card background uses the preset's surface color, text uses its text color
|
|
965
|
+
3. Write to `/tmp/picasso-preset-browser.html`
|
|
966
|
+
4. Open with Playwright MCP, screenshot, view with Read
|
|
967
|
+
5. Present: "Here are all 22 presets. Which one catches your eye?"
|
|
968
|
+
6. Wait for user to pick before proceeding
|
|
969
|
+
|
|
970
|
+
**When a preset name is given** (`/preset bold-signal`):
|
|
971
|
+
1. Load the named preset from `references/style-presets.md`
|
|
972
|
+
2. Generate a **visual preview** of the preset (Full Page Mood Preview from `references/visual-preview.md`)
|
|
973
|
+
3. Write to `/tmp/picasso-preset-{name}.html`, screenshot, view
|
|
974
|
+
4. Present: "Here's what {name} looks like. Apply it?"
|
|
975
|
+
5. After confirmation:
|
|
976
|
+
- Generate `.picasso.md` + `DESIGN.md` from the preset
|
|
977
|
+
- Apply to the codebase (CSS variables, Tailwind config, font imports, component styling)
|
|
939
978
|
|
|
940
979
|
## Advanced Automation Commands
|
|
941
980
|
|
package/commands/mood.md
CHANGED
|
@@ -1,17 +1,51 @@
|
|
|
1
|
-
|
|
1
|
+
---
|
|
2
|
+
name: mood
|
|
3
|
+
description: "Generate a complete design system from a mood word, with a visual preview before committing."
|
|
4
|
+
---
|
|
2
5
|
|
|
3
|
-
|
|
6
|
+
# /mood -- Design System from a Word
|
|
4
7
|
|
|
5
|
-
|
|
6
|
-
- Color palette (5-7 OKLCH values)
|
|
7
|
-
- Font pairing (display + body + mono)
|
|
8
|
-
- Border radius scale
|
|
9
|
-
- Shadow style
|
|
10
|
-
- Motion intensity
|
|
11
|
-
- Spacing density
|
|
8
|
+
Generate a complete design system from a mood word or phrase, and show a visual preview before writing any config files.
|
|
12
9
|
|
|
13
|
-
|
|
10
|
+
## Arguments
|
|
11
|
+
|
|
12
|
+
The mood word: `$ARGUMENTS`
|
|
14
13
|
|
|
15
14
|
Common moods: cyberpunk, cottage, brutalist, luxury, editorial, playful, corporate, dark-tech, warm-saas, minimal. Also accepts combinations like "brutalist-banking" or "warm-editorial".
|
|
16
15
|
|
|
17
16
|
If no mood word is provided, ask the user for one.
|
|
17
|
+
|
|
18
|
+
## Steps
|
|
19
|
+
|
|
20
|
+
1. Parse the mood word(s) and map to design tokens:
|
|
21
|
+
- Color palette (5-7 values with hex)
|
|
22
|
+
- Font pairing (display + body + mono)
|
|
23
|
+
- Border radius scale
|
|
24
|
+
- Shadow style
|
|
25
|
+
- Motion intensity
|
|
26
|
+
- Spacing density
|
|
27
|
+
|
|
28
|
+
2. **Generate a visual preview (MANDATORY -- before writing any config files):**
|
|
29
|
+
- Load `references/visual-preview.md` and use the Full Page Mood Preview structure
|
|
30
|
+
- Generate a self-contained HTML page showing a representative layout in the mood's tokens:
|
|
31
|
+
- Nav bar with logo text, links, and CTA button
|
|
32
|
+
- Hero section with large heading, subtitle, and primary button
|
|
33
|
+
- 2-3 sample cards in a grid
|
|
34
|
+
- A form input with button
|
|
35
|
+
- Footer with muted text
|
|
36
|
+
- Load fonts using the Font Mapping table from `references/visual-preview.md`
|
|
37
|
+
- Write to `/tmp/picasso-mood-{word}.html`
|
|
38
|
+
- Open via Playwright MCP, screenshot at 1440x900, view with Read tool
|
|
39
|
+
- Present to user: "This is what '{word}' looks like as a design system. Does this feel right, or should I adjust?"
|
|
40
|
+
|
|
41
|
+
3. **Wait for confirmation.** Do not write `.picasso.md` or `DESIGN.md` until the user approves the visual direction.
|
|
42
|
+
|
|
43
|
+
4. After confirmation, generate:
|
|
44
|
+
- `.picasso.md` with the mood's tokens and preferences
|
|
45
|
+
- `DESIGN.md` with the full design system specification
|
|
46
|
+
|
|
47
|
+
## Rules
|
|
48
|
+
|
|
49
|
+
- Never write config files before showing the visual preview
|
|
50
|
+
- If the user says "adjust" or "not quite", iterate on the tokens and regenerate the preview
|
|
51
|
+
- If Playwright MCP is unavailable, write the HTML and tell user the path to open manually
|
package/commands/preset.md
CHANGED
|
@@ -1,14 +1,44 @@
|
|
|
1
|
-
|
|
1
|
+
---
|
|
2
|
+
name: preset
|
|
3
|
+
description: "Browse and apply curated design presets with visual previews."
|
|
4
|
+
---
|
|
2
5
|
|
|
3
|
-
|
|
6
|
+
# /preset -- Apply a Design Preset
|
|
4
7
|
|
|
5
|
-
|
|
8
|
+
Browse or apply a curated design preset with a visual preview before committing.
|
|
6
9
|
|
|
7
|
-
|
|
8
|
-
1. Load the preset from style-presets.md reference
|
|
9
|
-
2. Generate .picasso.md + DESIGN.md from the preset
|
|
10
|
-
3. Update CSS variables / Tailwind config to match
|
|
11
|
-
4. Update font imports
|
|
12
|
-
5. Show a summary of what was applied
|
|
10
|
+
## Arguments
|
|
13
11
|
|
|
14
|
-
|
|
12
|
+
The preset name: `$ARGUMENTS`
|
|
13
|
+
|
|
14
|
+
## Steps
|
|
15
|
+
|
|
16
|
+
### No preset name given (`/preset`)
|
|
17
|
+
|
|
18
|
+
1. Load all 22 presets from `references/style-presets.md`
|
|
19
|
+
2. Generate a **visual preset browser** using the Preset Browser Grid template from `references/visual-preview.md`:
|
|
20
|
+
- 4-column grid of cards, one per preset
|
|
21
|
+
- Each card: preset name (in its heading font), 5-swatch color palette strip, one-line mood description, a sample button in the preset's primary color and radius
|
|
22
|
+
- Card backgrounds use the preset's surface color, text uses its text color
|
|
23
|
+
3. Write to `/tmp/picasso-preset-browser.html`
|
|
24
|
+
4. Open with Playwright MCP, screenshot at 1440x900, view with Read
|
|
25
|
+
5. Present: "Here are all 22 presets. Which one catches your eye?"
|
|
26
|
+
6. Wait for the user to pick
|
|
27
|
+
|
|
28
|
+
### Preset name given (`/preset bold-signal`)
|
|
29
|
+
|
|
30
|
+
1. Load the named preset from `references/style-presets.md`
|
|
31
|
+
2. Generate a **visual preview** using the Full Page Mood Preview structure from `references/visual-preview.md`:
|
|
32
|
+
- Nav bar, hero, cards, form, footer -- all in the preset's tokens
|
|
33
|
+
3. Write to `/tmp/picasso-preset-{name}.html`, screenshot, view with Read
|
|
34
|
+
4. Present: "Here's what {name} looks like applied. Want to use it?"
|
|
35
|
+
5. After confirmation:
|
|
36
|
+
- Generate `.picasso.md` + `DESIGN.md` from the preset
|
|
37
|
+
- Update CSS variables / Tailwind config to match
|
|
38
|
+
- Update font imports
|
|
39
|
+
- Show a summary of what was applied
|
|
40
|
+
|
|
41
|
+
## Rules
|
|
42
|
+
|
|
43
|
+
- Never apply a preset without showing a visual preview first
|
|
44
|
+
- If Playwright MCP is unavailable, write the HTML and give the user the file path
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: preview
|
|
3
|
+
description: "Generate visual previews of design directions, presets, or current tokens. Shows what options actually look like before committing."
|
|
4
|
+
---
|
|
5
|
+
|
|
6
|
+
# /preview -- Visual Design Preview
|
|
7
|
+
|
|
8
|
+
Generate and display visual previews of design options.
|
|
9
|
+
|
|
10
|
+
## Usage
|
|
11
|
+
|
|
12
|
+
- `/preview` -- Preview current `.picasso.md` tokens as a rendered page
|
|
13
|
+
- `/preview <preset-name>` -- Preview a specific style preset (e.g., `/preview bold-signal`)
|
|
14
|
+
- `/preview compare <a> <b> [c]` -- Side-by-side comparison of 2-3 presets or directions
|
|
15
|
+
|
|
16
|
+
## Steps
|
|
17
|
+
|
|
18
|
+
### `/preview` (current tokens)
|
|
19
|
+
|
|
20
|
+
1. Read `.picasso.md` from the project root. If not found, tell the user to run `/picasso` first.
|
|
21
|
+
2. Extract design tokens: fonts, colors, radius, spacing density.
|
|
22
|
+
3. Load `references/visual-preview.md` and use the Full Page Mood Preview template structure.
|
|
23
|
+
4. Generate a self-contained HTML file showing a complete page in the current design tokens:
|
|
24
|
+
- Nav bar, hero section, card grid, form, footer
|
|
25
|
+
- All styled with the project's committed tokens
|
|
26
|
+
5. Write to `/tmp/picasso-preview.html`
|
|
27
|
+
6. Open via Playwright MCP (`mcp__playwright__browser_navigate` to `file:///tmp/picasso-preview.html`)
|
|
28
|
+
7. Screenshot at 1440x900, view with Read tool
|
|
29
|
+
8. Present to user: "Here's what your current design tokens look like rendered. Open `/tmp/picasso-preview.html` in your browser for full resolution."
|
|
30
|
+
|
|
31
|
+
### `/preview <preset-name>`
|
|
32
|
+
|
|
33
|
+
1. Load `references/style-presets.md` and find the named preset.
|
|
34
|
+
2. Extract its tokens (colors, fonts, radius, signature element).
|
|
35
|
+
3. Generate a Full Page Mood Preview HTML using those tokens.
|
|
36
|
+
4. Write, screenshot, view, present (same as above).
|
|
37
|
+
|
|
38
|
+
### `/preview compare <a> <b> [c]`
|
|
39
|
+
|
|
40
|
+
1. Load `references/style-presets.md` and find each named preset.
|
|
41
|
+
2. Load `references/visual-preview.md` and use the Side-by-Side Direction Comparison template.
|
|
42
|
+
3. Generate a comparison HTML with 2-3 direction cards side by side.
|
|
43
|
+
4. Write to `/tmp/picasso-preview-compare.html`
|
|
44
|
+
5. Screenshot at 1440x900 (wide enough for side-by-side), view with Read.
|
|
45
|
+
6. Present: "Here are the directions compared. Which speaks to you?"
|
|
46
|
+
|
|
47
|
+
## Rules
|
|
48
|
+
|
|
49
|
+
- Always load font URLs from the Font Mapping table in `references/visual-preview.md`
|
|
50
|
+
- If Playwright MCP is unavailable, write the file and tell the user the path to open manually
|
|
51
|
+
- Never describe what the preview looks like without viewing the screenshot first
|
|
52
|
+
- The HTML must be fully self-contained (inline styles, external font imports only)
|
package/commands/variants.md
CHANGED
|
@@ -1,18 +1,37 @@
|
|
|
1
|
-
|
|
1
|
+
---
|
|
2
|
+
name: variants
|
|
3
|
+
description: "Generate 2-3 distinct visual directions with side-by-side visual previews for A/B comparison."
|
|
4
|
+
---
|
|
2
5
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
6
|
+
# /variants -- Visual Direction Comparison
|
|
7
|
+
|
|
8
|
+
Generate 2-3 genuinely different aesthetic directions and show them as a side-by-side visual preview.
|
|
9
|
+
|
|
10
|
+
## Steps
|
|
11
|
+
|
|
12
|
+
1. Read the current project's design context (`.picasso.md`, `DESIGN.md`, or infer from code)
|
|
13
|
+
2. Study the project type, audience, and competitive landscape to inform direction choices
|
|
14
|
+
3. Generate 2-3 genuinely different aesthetic directions. NOT slight variations -- each must differ in at least 3 of: font, color palette, layout structure, border-radius philosophy, motion intensity
|
|
15
|
+
4. For each direction:
|
|
7
16
|
- Name it (e.g., "Editorial Minimalist", "Dark Terminal", "Warm Organic")
|
|
8
|
-
- List the 5 key design tokens (font, accent color, radius, shadow style
|
|
9
|
-
- Describe what makes it distinctive in 1
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
17
|
+
- List the 5 key design tokens (heading font, body font, accent color, radius, shadow style)
|
|
18
|
+
- Describe what makes it distinctive in 1 sentence
|
|
19
|
+
5. **Generate a visual preview (MANDATORY):**
|
|
20
|
+
- Load `references/visual-preview.md` and use the Side-by-Side Direction Comparison template
|
|
21
|
+
- For each direction, render a preview card showing: color palette strip, nav bar, heading, body text, sample card, primary/secondary buttons, input field -- all in that direction's tokens
|
|
22
|
+
- Load fonts using the Font Mapping table from `references/visual-preview.md`
|
|
23
|
+
- Write the comparison HTML to `/tmp/picasso-variants.html`
|
|
24
|
+
- Open via Playwright MCP: `mcp__playwright__browser_navigate` to `file:///tmp/picasso-variants.html`
|
|
25
|
+
- Screenshot at 1440x900 viewport
|
|
26
|
+
- View the screenshot with the Read tool
|
|
27
|
+
6. Present the visual comparison to the user: "Here are the directions. Which speaks to you? Pick one, combine elements, or reject all."
|
|
28
|
+
7. Also tell the user: "Open `/tmp/picasso-variants.html` in your browser for full resolution."
|
|
29
|
+
|
|
30
|
+
## Rules
|
|
13
31
|
|
|
14
|
-
Rules:
|
|
15
32
|
- Each direction must pass the 3-second anti-slop test independently
|
|
16
|
-
- No two directions can share the same font
|
|
33
|
+
- No two directions can share the same heading font
|
|
17
34
|
- At least one direction must be surprising or unconventional
|
|
18
35
|
- Always include one "safe" option and one "bold" option
|
|
36
|
+
- Visual preview is MANDATORY, not optional. If Playwright MCP is unavailable, write the HTML file and tell the user the path to open manually.
|
|
37
|
+
- Never describe what the directions look like without viewing the screenshot first
|
package/package.json
CHANGED
|
@@ -0,0 +1,359 @@
|
|
|
1
|
+
# Visual Preview Reference
|
|
2
|
+
|
|
3
|
+
Generate self-contained HTML previews to show users what design options look like before they commit. This replaces text-only descriptions with actual visual examples.
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
## 1. The Preview Protocol
|
|
8
|
+
|
|
9
|
+
Every time Picasso presents 2+ aesthetic options for the user to choose from, generate a visual preview. Text-only option lists are banned for aesthetic decisions.
|
|
10
|
+
|
|
11
|
+
### Standard Flow
|
|
12
|
+
|
|
13
|
+
1. **Generate** a self-contained HTML file with inline styles and font imports
|
|
14
|
+
2. **Write** to `/tmp/picasso-preview-{name}.html`
|
|
15
|
+
3. **Open** via Playwright MCP: `mcp__playwright__browser_navigate` to `file:///tmp/picasso-preview-{name}.html`
|
|
16
|
+
4. **Screenshot** via `mcp__playwright__browser_take_screenshot`
|
|
17
|
+
5. **View** the screenshot with `Read` tool (mandatory -- never skip this)
|
|
18
|
+
6. **Present** to the user with the file path so they can also open it in their browser
|
|
19
|
+
|
|
20
|
+
### If Playwright MCP Is Unavailable
|
|
21
|
+
|
|
22
|
+
1. Write the HTML file to `/tmp/`
|
|
23
|
+
2. Tell the user: "I've generated a visual preview at `/tmp/picasso-preview-{name}.html` -- open it in your browser to see the options."
|
|
24
|
+
3. Do NOT make visual claims about what the preview looks like without viewing it
|
|
25
|
+
|
|
26
|
+
### File Naming
|
|
27
|
+
|
|
28
|
+
- Interview aesthetics: `/tmp/picasso-interview-vibes.html`
|
|
29
|
+
- Design brief preview: `/tmp/picasso-brief-preview.html`
|
|
30
|
+
- Variants comparison: `/tmp/picasso-variants.html`
|
|
31
|
+
- Mood preview: `/tmp/picasso-mood-{word}.html`
|
|
32
|
+
- Preset browser: `/tmp/picasso-preset-browser.html`
|
|
33
|
+
- Standalone preview: `/tmp/picasso-preview.html`
|
|
34
|
+
|
|
35
|
+
---
|
|
36
|
+
|
|
37
|
+
## 2. HTML Template: Side-by-Side Direction Comparison
|
|
38
|
+
|
|
39
|
+
Use this when showing 2-4 aesthetic directions for the user to choose from (interview, /variants, /preview compare).
|
|
40
|
+
|
|
41
|
+
Generate the full HTML dynamically. For each direction, substitute the actual font, colors, radius, and spacing values. The template below is a structural guide -- adapt the content to match each specific direction.
|
|
42
|
+
|
|
43
|
+
```html
|
|
44
|
+
<!DOCTYPE html>
|
|
45
|
+
<html lang="en">
|
|
46
|
+
<head>
|
|
47
|
+
<meta charset="UTF-8">
|
|
48
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
49
|
+
<title>Picasso: Choose a Direction</title>
|
|
50
|
+
<!-- Import fonts for all directions shown -->
|
|
51
|
+
<link rel="preconnect" href="https://fonts.googleapis.com">
|
|
52
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
|
53
|
+
<link href="https://fonts.googleapis.com/css2?family={FONT_1}&family={FONT_2}&family={FONT_3}&display=swap" rel="stylesheet">
|
|
54
|
+
<style>
|
|
55
|
+
* { margin: 0; padding: 0; box-sizing: border-box; }
|
|
56
|
+
body {
|
|
57
|
+
font-family: system-ui, sans-serif;
|
|
58
|
+
background: #f5f5f5;
|
|
59
|
+
padding: 32px;
|
|
60
|
+
color: #1a1a1a;
|
|
61
|
+
}
|
|
62
|
+
h1 {
|
|
63
|
+
text-align: center;
|
|
64
|
+
font-size: 20px;
|
|
65
|
+
font-weight: 600;
|
|
66
|
+
margin-bottom: 8px;
|
|
67
|
+
letter-spacing: -0.02em;
|
|
68
|
+
}
|
|
69
|
+
.subtitle {
|
|
70
|
+
text-align: center;
|
|
71
|
+
font-size: 13px;
|
|
72
|
+
color: #666;
|
|
73
|
+
margin-bottom: 32px;
|
|
74
|
+
}
|
|
75
|
+
.grid {
|
|
76
|
+
display: grid;
|
|
77
|
+
grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
|
|
78
|
+
gap: 24px;
|
|
79
|
+
max-width: 1200px;
|
|
80
|
+
margin: 0 auto;
|
|
81
|
+
}
|
|
82
|
+
.direction {
|
|
83
|
+
border-radius: 12px;
|
|
84
|
+
overflow: hidden;
|
|
85
|
+
box-shadow: 0 2px 12px rgba(0,0,0,0.08);
|
|
86
|
+
}
|
|
87
|
+
.direction-label {
|
|
88
|
+
padding: 12px 16px;
|
|
89
|
+
font-size: 13px;
|
|
90
|
+
font-weight: 600;
|
|
91
|
+
letter-spacing: 0.05em;
|
|
92
|
+
text-transform: uppercase;
|
|
93
|
+
background: #fff;
|
|
94
|
+
border-bottom: 1px solid #eee;
|
|
95
|
+
display: flex;
|
|
96
|
+
align-items: center;
|
|
97
|
+
justify-content: space-between;
|
|
98
|
+
}
|
|
99
|
+
.direction-label span {
|
|
100
|
+
font-size: 11px;
|
|
101
|
+
font-weight: 400;
|
|
102
|
+
text-transform: none;
|
|
103
|
+
letter-spacing: 0;
|
|
104
|
+
color: #999;
|
|
105
|
+
}
|
|
106
|
+
/* Each .preview is a mini page rendered in the direction's style */
|
|
107
|
+
.preview {
|
|
108
|
+
padding: 24px;
|
|
109
|
+
min-height: 400px;
|
|
110
|
+
display: flex;
|
|
111
|
+
flex-direction: column;
|
|
112
|
+
gap: 16px;
|
|
113
|
+
}
|
|
114
|
+
/* Palette strip */
|
|
115
|
+
.palette {
|
|
116
|
+
display: flex;
|
|
117
|
+
gap: 4px;
|
|
118
|
+
height: 24px;
|
|
119
|
+
border-radius: 4px;
|
|
120
|
+
overflow: hidden;
|
|
121
|
+
}
|
|
122
|
+
.palette .swatch {
|
|
123
|
+
flex: 1;
|
|
124
|
+
position: relative;
|
|
125
|
+
}
|
|
126
|
+
/* Sample nav */
|
|
127
|
+
.sample-nav {
|
|
128
|
+
display: flex;
|
|
129
|
+
align-items: center;
|
|
130
|
+
justify-content: space-between;
|
|
131
|
+
padding: 8px 0;
|
|
132
|
+
}
|
|
133
|
+
.sample-nav .logo {
|
|
134
|
+
font-weight: 700;
|
|
135
|
+
font-size: 15px;
|
|
136
|
+
}
|
|
137
|
+
.sample-nav .links {
|
|
138
|
+
display: flex;
|
|
139
|
+
gap: 16px;
|
|
140
|
+
font-size: 12px;
|
|
141
|
+
opacity: 0.6;
|
|
142
|
+
}
|
|
143
|
+
/* Sample card */
|
|
144
|
+
.sample-card {
|
|
145
|
+
padding: 16px;
|
|
146
|
+
display: flex;
|
|
147
|
+
flex-direction: column;
|
|
148
|
+
gap: 8px;
|
|
149
|
+
}
|
|
150
|
+
.sample-card h3 {
|
|
151
|
+
font-size: 16px;
|
|
152
|
+
font-weight: 600;
|
|
153
|
+
}
|
|
154
|
+
.sample-card p {
|
|
155
|
+
font-size: 12px;
|
|
156
|
+
line-height: 1.6;
|
|
157
|
+
opacity: 0.7;
|
|
158
|
+
}
|
|
159
|
+
/* Sample button */
|
|
160
|
+
.sample-btn {
|
|
161
|
+
display: inline-flex;
|
|
162
|
+
align-items: center;
|
|
163
|
+
justify-content: center;
|
|
164
|
+
padding: 8px 20px;
|
|
165
|
+
font-size: 12px;
|
|
166
|
+
font-weight: 600;
|
|
167
|
+
border: none;
|
|
168
|
+
cursor: pointer;
|
|
169
|
+
width: fit-content;
|
|
170
|
+
}
|
|
171
|
+
/* Sample input */
|
|
172
|
+
.sample-input {
|
|
173
|
+
padding: 8px 12px;
|
|
174
|
+
font-size: 12px;
|
|
175
|
+
border: 1px solid;
|
|
176
|
+
background: transparent;
|
|
177
|
+
width: 100%;
|
|
178
|
+
}
|
|
179
|
+
/* Font info footer */
|
|
180
|
+
.font-info {
|
|
181
|
+
font-size: 10px;
|
|
182
|
+
opacity: 0.4;
|
|
183
|
+
padding-top: 8px;
|
|
184
|
+
border-top: 1px solid;
|
|
185
|
+
border-color: inherit;
|
|
186
|
+
}
|
|
187
|
+
</style>
|
|
188
|
+
</head>
|
|
189
|
+
<body>
|
|
190
|
+
|
|
191
|
+
<h1>Choose a Direction</h1>
|
|
192
|
+
<p class="subtitle">Pick one, combine elements, or describe something different.</p>
|
|
193
|
+
|
|
194
|
+
<div class="grid">
|
|
195
|
+
|
|
196
|
+
<!-- Direction A -->
|
|
197
|
+
<div class="direction">
|
|
198
|
+
<div class="direction-label">
|
|
199
|
+
A: {DIRECTION_A_NAME}
|
|
200
|
+
<span>{DIRECTION_A_VIBE}</span>
|
|
201
|
+
</div>
|
|
202
|
+
<div class="preview" style="background: {A_BG}; color: {A_TEXT}; font-family: '{A_BODY_FONT}', sans-serif;">
|
|
203
|
+
<div class="palette">
|
|
204
|
+
<div class="swatch" style="background: {A_COLOR_1};"></div>
|
|
205
|
+
<div class="swatch" style="background: {A_COLOR_2};"></div>
|
|
206
|
+
<div class="swatch" style="background: {A_COLOR_3};"></div>
|
|
207
|
+
<div class="swatch" style="background: {A_COLOR_4};"></div>
|
|
208
|
+
<div class="swatch" style="background: {A_COLOR_5};"></div>
|
|
209
|
+
</div>
|
|
210
|
+
<div class="sample-nav">
|
|
211
|
+
<div class="logo" style="font-family: '{A_HEADING_FONT}', sans-serif;">AppName</div>
|
|
212
|
+
<div class="links">Features Pricing Docs</div>
|
|
213
|
+
</div>
|
|
214
|
+
<div style="font-family: '{A_HEADING_FONT}', sans-serif; font-size: 22px; font-weight: 700; line-height: 1.2; letter-spacing: -0.02em;">
|
|
215
|
+
Build something people actually want
|
|
216
|
+
</div>
|
|
217
|
+
<div style="font-size: 13px; line-height: 1.6; opacity: 0.7;">
|
|
218
|
+
A short description that shows what body text looks like in this direction. Notice the font, weight, and spacing.
|
|
219
|
+
</div>
|
|
220
|
+
<div class="sample-card" style="background: {A_SURFACE}; border-radius: {A_RADIUS};">
|
|
221
|
+
<h3 style="font-family: '{A_HEADING_FONT}', sans-serif;">Sample Card</h3>
|
|
222
|
+
<p>This is how cards look in this direction. Pay attention to padding, radius, and depth.</p>
|
|
223
|
+
</div>
|
|
224
|
+
<div style="display: flex; gap: 8px;">
|
|
225
|
+
<div class="sample-btn" style="background: {A_PRIMARY}; color: {A_PRIMARY_TEXT}; border-radius: {A_RADIUS};">
|
|
226
|
+
Primary Action
|
|
227
|
+
</div>
|
|
228
|
+
<div class="sample-btn" style="background: transparent; color: {A_TEXT}; border: 1px solid {A_BORDER}; border-radius: {A_RADIUS};">
|
|
229
|
+
Secondary
|
|
230
|
+
</div>
|
|
231
|
+
</div>
|
|
232
|
+
<div class="sample-input" style="border-color: {A_BORDER}; border-radius: {A_RADIUS}; color: {A_TEXT};" placeholder="Input field...">
|
|
233
|
+
Input field...
|
|
234
|
+
</div>
|
|
235
|
+
<div class="font-info">
|
|
236
|
+
{A_HEADING_FONT} + {A_BODY_FONT} · {A_RADIUS} radius
|
|
237
|
+
</div>
|
|
238
|
+
</div>
|
|
239
|
+
</div>
|
|
240
|
+
|
|
241
|
+
<!-- Repeat for Direction B, C, D... -->
|
|
242
|
+
|
|
243
|
+
</div>
|
|
244
|
+
|
|
245
|
+
</body>
|
|
246
|
+
</html>
|
|
247
|
+
```
|
|
248
|
+
|
|
249
|
+
### How to Use This Template
|
|
250
|
+
|
|
251
|
+
1. Do NOT copy-paste this template literally. Generate the HTML dynamically with actual values substituted for each direction.
|
|
252
|
+
2. Each `{PLACEHOLDER}` must be replaced with real values from the direction you're previewing.
|
|
253
|
+
3. The font `<link>` tag must include ALL fonts used across ALL directions being compared.
|
|
254
|
+
4. The number of directions (2, 3, or 4) determines the grid columns.
|
|
255
|
+
5. Keep the preview compact -- users should see all options without scrolling.
|
|
256
|
+
|
|
257
|
+
---
|
|
258
|
+
|
|
259
|
+
## 3. HTML Template: Full Page Mood Preview
|
|
260
|
+
|
|
261
|
+
Use this for /mood and Design Brief previews. Shows a complete page layout in the specified style.
|
|
262
|
+
|
|
263
|
+
Generate a full-page HTML that includes:
|
|
264
|
+
- A navigation bar with logo text, 3-4 links, and a CTA button
|
|
265
|
+
- A hero section with a large heading, subtitle, and primary button
|
|
266
|
+
- A 3-column feature/card section
|
|
267
|
+
- A form section with an input and button
|
|
268
|
+
- A footer with muted text
|
|
269
|
+
|
|
270
|
+
All styled with the mood's tokens (colors, fonts, radius, spacing). The content should be generic but realistic (not lorem ipsum). Size the page to 1440px viewport width.
|
|
271
|
+
|
|
272
|
+
---
|
|
273
|
+
|
|
274
|
+
## 4. HTML Template: Preset Browser Grid
|
|
275
|
+
|
|
276
|
+
Use this for /preset without arguments. Shows all presets as a browsable grid.
|
|
277
|
+
|
|
278
|
+
Generate an HTML page with:
|
|
279
|
+
- A title: "Picasso Style Presets"
|
|
280
|
+
- A grid of cards (4 columns, wrapping), one per preset
|
|
281
|
+
- Each card shows:
|
|
282
|
+
- Preset name (in the preset's heading font)
|
|
283
|
+
- A 5-swatch color palette strip
|
|
284
|
+
- A one-line mood description
|
|
285
|
+
- A tiny sample button in the preset's primary color and radius
|
|
286
|
+
- Cards should be ~280px wide, ~180px tall
|
|
287
|
+
- The card background should use the preset's surface color
|
|
288
|
+
- Card text should use the preset's text color
|
|
289
|
+
|
|
290
|
+
This gives users a visual catalog to browse before choosing.
|
|
291
|
+
|
|
292
|
+
---
|
|
293
|
+
|
|
294
|
+
## 5. Font Loading
|
|
295
|
+
|
|
296
|
+
### Google Fonts
|
|
297
|
+
|
|
298
|
+
Most fonts can be loaded via Google Fonts. Construct the URL:
|
|
299
|
+
```
|
|
300
|
+
https://fonts.googleapis.com/css2?family={FontName}:wght@400;600;700&display=swap
|
|
301
|
+
```
|
|
302
|
+
|
|
303
|
+
Replace spaces with `+` in font names.
|
|
304
|
+
|
|
305
|
+
### Fontshare (for fonts not on Google)
|
|
306
|
+
|
|
307
|
+
Some popular Picasso fonts are on Fontshare:
|
|
308
|
+
```
|
|
309
|
+
https://api.fontshare.com/v2/css?f[]=satoshi@400,500,700&display=swap
|
|
310
|
+
https://api.fontshare.com/v2/css?f[]=cabinet-grotesk@400,700,800&display=swap
|
|
311
|
+
https://api.fontshare.com/v2/css?f[]=general-sans@400,500,600&display=swap
|
|
312
|
+
https://api.fontshare.com/v2/css?f[]=clash-display@400,600,700&display=swap
|
|
313
|
+
```
|
|
314
|
+
|
|
315
|
+
### Common Font Mappings
|
|
316
|
+
|
|
317
|
+
| Font Name | Source | Import URL |
|
|
318
|
+
|-----------|--------|-----------|
|
|
319
|
+
| Satoshi | Fontshare | `https://api.fontshare.com/v2/css?f[]=satoshi@400,500,700&display=swap` |
|
|
320
|
+
| Cabinet Grotesk | Fontshare | `https://api.fontshare.com/v2/css?f[]=cabinet-grotesk@400,700,800&display=swap` |
|
|
321
|
+
| General Sans | Fontshare | `https://api.fontshare.com/v2/css?f[]=general-sans@400,500,600&display=swap` |
|
|
322
|
+
| Clash Display | Fontshare | `https://api.fontshare.com/v2/css?f[]=clash-display@400,600,700&display=swap` |
|
|
323
|
+
| Archivo Black | Google | `family=Archivo+Black&display=swap` |
|
|
324
|
+
| Manrope | Google | `family=Manrope:wght@300;400;500;600;700;800&display=swap` |
|
|
325
|
+
| Syne | Google | `family=Syne:wght@400;600;700;800&display=swap` |
|
|
326
|
+
| Space Mono | Google | `family=Space+Mono:wght@400;700&display=swap` |
|
|
327
|
+
| Cormorant | Google | `family=Cormorant:ital,wght@0,400;0,600;1,400&display=swap` |
|
|
328
|
+
| IBM Plex Sans | Google | `family=IBM+Plex+Sans:wght@300;400;500;600&display=swap` |
|
|
329
|
+
| DM Sans | Google | `family=DM+Sans:wght@400;500;600;700&display=swap` |
|
|
330
|
+
| Plus Jakarta Sans | Google | `family=Plus+Jakarta+Sans:wght@400;500;600;700&display=swap` |
|
|
331
|
+
| Outfit | Google | `family=Outfit:wght@300;400;500;600;700&display=swap` |
|
|
332
|
+
| Fraunces | Google | `family=Fraunces:ital,wght@0,400;0,600;1,400&display=swap` |
|
|
333
|
+
| Work Sans | Google | `family=Work+Sans:wght@400;500;600;700&display=swap` |
|
|
334
|
+
| JetBrains Mono | Google | `family=JetBrains+Mono:wght@400;500;700&display=swap` |
|
|
335
|
+
| Bodoni Moda | Google | `family=Bodoni+Moda:ital,wght@0,400;0,700;1,400&display=swap` |
|
|
336
|
+
| Inter | Google | `family=Inter:wght@400;500;600;700&display=swap` |
|
|
337
|
+
| Geist | Local/Vercel | Use `system-ui` as fallback in previews |
|
|
338
|
+
|
|
339
|
+
### Fallback Rule
|
|
340
|
+
|
|
341
|
+
If a font fails to load (offline, CORS, not available), the preview should still render correctly using `system-ui, -apple-system, sans-serif` as fallback. The font name should be displayed in the `.font-info` footer so the user knows what was intended.
|
|
342
|
+
|
|
343
|
+
---
|
|
344
|
+
|
|
345
|
+
## 6. The Show-Don't-Tell Rule
|
|
346
|
+
|
|
347
|
+
| Decision Type | Show Visual? | Why |
|
|
348
|
+
|---------------|-------------|-----|
|
|
349
|
+
| Aesthetic direction / vibe | YES | Users can't imagine "Bold Signal" from text |
|
|
350
|
+
| Color palette | YES | Hex values mean nothing without seeing them |
|
|
351
|
+
| Font pairing | YES | Font names mean nothing without rendering them |
|
|
352
|
+
| Layout structure | YES | "Asymmetric grid" means different things to everyone |
|
|
353
|
+
| Animation intensity | NO | Must be experienced in running code, not a static preview |
|
|
354
|
+
| Mobile priority level | NO | A number (1-5) is sufficient |
|
|
355
|
+
| Accessibility level | NO | A standard (AA/AAA) is sufficient |
|
|
356
|
+
| Performance budget | NO | A number is sufficient |
|
|
357
|
+
| Sound/haptics | NO | Must be experienced in running code |
|
|
358
|
+
|
|
359
|
+
The rule: if the decision involves how something LOOKS, show it. If it involves behavior, policy, or priority, text is fine.
|