medesign 0.0.0-stage → 1.4.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/LICENSE +21 -0
- package/README.md +223 -3
- package/bin/medesign.js +691 -0
- package/integrations/claude-code/SKILL.md +20 -0
- package/integrations/cursor/medesign.mdc +26 -0
- package/medesign.config.js +46 -0
- package/package.json +69 -6
- package/presets/apple/design-tokens.css +115 -0
- package/presets/apple/guidelines.md +19 -0
- package/presets/apple/preset.json +53 -0
- package/presets/metha/design-tokens.css +127 -0
- package/presets/metha/guidelines.md +23 -0
- package/presets/metha/preset.json +53 -0
- package/presets/schema.json +102 -0
- package/presets/tesla/design-tokens.css +112 -0
- package/presets/tesla/guidelines.md +17 -0
- package/presets/tesla/preset.json +53 -0
- package/references/ai-tells.md +127 -0
- package/references/appendices.md +220 -0
- package/references/architecture.md +39 -0
- package/references/argon-design-archetypes.md +317 -0
- package/references/banner-sizes-and-styles.md +118 -0
- package/references/block-library.md +61 -0
- package/references/brand-design-tokens.md +42 -0
- package/references/catalog.json +1023 -0
- package/references/cip-deliverable-guide.md +95 -0
- package/references/cip-design.md +121 -0
- package/references/cip-prompt-engineering.md +84 -0
- package/references/cip-style-guide.md +68 -0
- package/references/cli-architecture.md +146 -0
- package/references/components.md +240 -0
- package/references/dark-mode.md +23 -0
- package/references/design-core.md +42 -0
- package/references/design-md-protocol.md +75 -0
- package/references/design-routing.md +207 -0
- package/references/eng-imagery-content.md +71 -0
- package/references/eng-layout.md +28 -0
- package/references/eng-other.md +26 -0
- package/references/eng-states-theme.md +22 -0
- package/references/eng-type-color.md +44 -0
- package/references/icon-design.md +122 -0
- package/references/image-mockup-direction.md +53 -0
- package/references/image-to-code.md +46 -0
- package/references/impeccable-polish.md +85 -0
- package/references/intake.md +90 -0
- package/references/logo-color-psychology.md +101 -0
- package/references/logo-design.md +110 -0
- package/references/logo-prompt-engineering.md +158 -0
- package/references/logo-style-guide.md +109 -0
- package/references/mesurv-dna.md +104 -0
- package/references/micro-interactions-and-auto-animate.md +71 -0
- package/references/modern-craft-invariants.md +332 -0
- package/references/motion-tokens.md +99 -0
- package/references/preflight.md +110 -0
- package/references/proactive-motion.md +167 -0
- package/references/quality-gate.md +147 -0
- package/references/redesign-audit.md +38 -0
- package/references/redesign.md +52 -0
- package/references/slides-copywriting-formulas.md +84 -0
- package/references/slides-create.md +4 -0
- package/references/slides-html-template.md +295 -0
- package/references/slides-layout-patterns.md +137 -0
- package/references/slides-strategies.md +94 -0
- package/references/slides.md +42 -0
- package/references/social-photos-design.md +329 -0
- package/references/spatial-canvas-engine.md +160 -0
- package/references/stitch-system.md +184 -0
- package/references/style-extraction.md +17 -0
- package/references/styles/brutalist.md +88 -0
- package/references/styles/minimalist.md +81 -0
- package/references/styles/soft.md +94 -0
- package/references/threeui-spatial-engine.md +224 -0
- package/references/ui-styling-shadcn.md +336 -0
- package/references/ui-ux-vocabulary-vault.json +1223 -0
- package/references/ui-ux-vocabulary-vault.md +438 -0
- package/references/vocab-protocol.md +52 -0
- package/references/vocabulary.md +78 -0
- package/scripts/export-tokens.js +403 -0
- package/tests/browser-audit.js +442 -0
- package/tests/linter.js +412 -0
- package/tests/schemas/sarif-2.1.0.schema.json +2915 -0
- package/tests/visual-testbed.html +681 -0
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* ME-DESIGN Preset: Tesla Cybertruck & In-Vehicle Telemetry
|
|
3
|
+
* Version: 1.0.0
|
|
4
|
+
* Architecture: 3-Layer Design Tokens (Global -> Semantic -> Component)
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
:root {
|
|
8
|
+
/* 01. Typography */
|
|
9
|
+
--font-display: "Space Grotesk", "Inter", sans-serif;
|
|
10
|
+
--font-sans: "Inter", sans-serif;
|
|
11
|
+
--font-mono: "IBM Plex Mono", "JetBrains Mono", monospace;
|
|
12
|
+
--tracking-heading: -0.015em;
|
|
13
|
+
--tracking-badge: 0.08em;
|
|
14
|
+
--leading-ui: 1.22;
|
|
15
|
+
--leading-prose: 1.55;
|
|
16
|
+
--thai-headroom: 2px;
|
|
17
|
+
|
|
18
|
+
/* 02. Color Tokens */
|
|
19
|
+
--color-canvas: #050505;
|
|
20
|
+
--color-surface-raised: #111111;
|
|
21
|
+
--color-surface-inset: #0a0a0a;
|
|
22
|
+
--color-text-primary: #ffffff;
|
|
23
|
+
--color-text-secondary: #8e8e93;
|
|
24
|
+
--color-text-tertiary: #48484a;
|
|
25
|
+
--color-border-subtle: rgba(255, 255, 255, 0.08);
|
|
26
|
+
--color-border-strong: rgba(255, 255, 255, 0.20);
|
|
27
|
+
--color-border-focus: oklch(0.65 0.24 28);
|
|
28
|
+
|
|
29
|
+
--color-accent: oklch(0.58 0.24 28);
|
|
30
|
+
--color-accent-hover: oklch(0.64 0.24 28);
|
|
31
|
+
--color-accent-fg: #ffffff;
|
|
32
|
+
|
|
33
|
+
--color-status-info: oklch(0.78 0.15 200);
|
|
34
|
+
--color-status-success: oklch(0.72 0.20 142);
|
|
35
|
+
--color-status-warning: oklch(0.80 0.18 75);
|
|
36
|
+
--color-status-critical: oklch(0.60 0.25 28);
|
|
37
|
+
|
|
38
|
+
/* 03. Optical Geometry (Strict Low-Radius Chamfer) */
|
|
39
|
+
--radius-outer: 4px;
|
|
40
|
+
--radius-inner: 2px;
|
|
41
|
+
--hit-target-min: 44px;
|
|
42
|
+
|
|
43
|
+
/* 04. Motion Tokens (High-Velocity Precision) */
|
|
44
|
+
--duration-entry: 100ms;
|
|
45
|
+
--duration-exit: 70ms;
|
|
46
|
+
--ease-entry: cubic-bezier(0.2, 0, 0, 1);
|
|
47
|
+
--ease-exit: cubic-bezier(0.4, 0, 1, 1);
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
/* Light Mode Overrides */
|
|
51
|
+
@media (prefers-color-scheme: light) {
|
|
52
|
+
:root {
|
|
53
|
+
--color-canvas: #f4f4f4;
|
|
54
|
+
--color-surface-raised: #ffffff;
|
|
55
|
+
--color-surface-inset: #e5e5e5;
|
|
56
|
+
--color-text-primary: #111111;
|
|
57
|
+
--color-text-secondary: #5c5c5c;
|
|
58
|
+
--color-border-subtle: rgba(0, 0, 0, 0.10);
|
|
59
|
+
--color-border-strong: rgba(0, 0, 0, 0.25);
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
/* Core Component Utilities */
|
|
64
|
+
.tesla-panel {
|
|
65
|
+
background: var(--color-surface-raised);
|
|
66
|
+
border: 1px solid var(--color-border-subtle);
|
|
67
|
+
border-radius: var(--radius-outer);
|
|
68
|
+
padding: 16px 20px;
|
|
69
|
+
transition: border-color var(--duration-entry) var(--ease-entry);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.tesla-btn {
|
|
73
|
+
display: inline-flex;
|
|
74
|
+
align-items: center;
|
|
75
|
+
justify-content: center;
|
|
76
|
+
min-height: var(--hit-target-min);
|
|
77
|
+
padding: 0 16px;
|
|
78
|
+
border-radius: var(--radius-outer);
|
|
79
|
+
font-family: var(--font-sans);
|
|
80
|
+
font-size: 13px;
|
|
81
|
+
font-weight: 600;
|
|
82
|
+
text-transform: uppercase;
|
|
83
|
+
letter-spacing: var(--tracking-badge);
|
|
84
|
+
background: var(--color-accent);
|
|
85
|
+
color: var(--color-accent-fg);
|
|
86
|
+
border: 1px solid transparent;
|
|
87
|
+
cursor: pointer;
|
|
88
|
+
outline-offset: 2px;
|
|
89
|
+
transition: background var(--duration-entry) var(--ease-entry);
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.tesla-btn:focus-visible {
|
|
93
|
+
outline: 2px solid var(--color-border-focus);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.tesla-btn:active .visual-surface {
|
|
97
|
+
transform: scale(0.98);
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.telemetry-val {
|
|
101
|
+
font-family: var(--font-mono);
|
|
102
|
+
font-variant-numeric: tabular-nums;
|
|
103
|
+
font-weight: 700;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
@media (prefers-reduced-motion: reduce) {
|
|
107
|
+
*, *::before, *::after {
|
|
108
|
+
animation-duration: 0.01ms !important;
|
|
109
|
+
animation-iteration-count: 1 !important;
|
|
110
|
+
transition-duration: 0.01ms !important;
|
|
111
|
+
}
|
|
112
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Tesla Preset Guidelines (`/medesign tesla`)
|
|
2
|
+
|
|
3
|
+
## Archetype Mapping
|
|
4
|
+
- **Primary Archetype:** Archetype 18 (Industrial / Hardware Product)
|
|
5
|
+
- **Secondary Archetype:** Archetype 32 (GIS Situation Awareness & Telemetry)
|
|
6
|
+
|
|
7
|
+
## Invariants & Design Principles
|
|
8
|
+
1. **Brutal Geometry & Minimal Radii:**
|
|
9
|
+
Outer card radius `4px`, inner nested radius `2px`. Avoid large bubbly curves; adhere to razor-sharp automotive engineering surfaces.
|
|
10
|
+
2. **Telemetric Typography:**
|
|
11
|
+
- Display/Headlines: Space Grotesk / Gotham with crisp technical presence.
|
|
12
|
+
- Values & Metrics: Monospace (`IBM Plex Mono` / `JetBrains Mono`) with `tabular-nums` for real-time telemetry readouts.
|
|
13
|
+
- Letter-spacing: `+0.08em` uppercase tracking on status badges and controls.
|
|
14
|
+
3. **High-Velocity Precision Motion:**
|
|
15
|
+
`precision` motion profile (100ms entry, 70ms exit). State feedback must feel immediate, like physical vehicle switches.
|
|
16
|
+
4. **Contrast & Night Mode Invariant:**
|
|
17
|
+
Deep obsidian background `#050505`, crisp white metrics `#ffffff`, Tesla Crimson accent `oklch(0.58 0.24 28)` for primary action and critical warnings.
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "../schema.json",
|
|
3
|
+
"id": "tesla",
|
|
4
|
+
"name": "Tesla Cybertruck & In-Vehicle Telemetry",
|
|
5
|
+
"version": "1.0.0",
|
|
6
|
+
"archetype": "Archetype 18: Industrial / Hardware Product & Archetype 32: GIS / Telemetry",
|
|
7
|
+
"description": "Brutal hardware minimalism: razor-sharp 2px-4px chamfer radii, deep obsidian/pure black contrast, precision 90-120ms telemetry response, and electric red/cyan telemetry accents.",
|
|
8
|
+
"typography": {
|
|
9
|
+
"display": "'Gotham', 'Inter', 'Space Grotesk', sans-serif",
|
|
10
|
+
"sans": "'Inter', 'Roboto', sans-serif",
|
|
11
|
+
"mono": "'IBM Plex Mono', 'JetBrains Mono', monospace",
|
|
12
|
+
"headingTracking": "-0.015em",
|
|
13
|
+
"uiLineHeight": "1.22",
|
|
14
|
+
"proseLineHeight": "1.55",
|
|
15
|
+
"thaiHeadroom": "2px"
|
|
16
|
+
},
|
|
17
|
+
"color": {
|
|
18
|
+
"canvas": "#050505",
|
|
19
|
+
"surfaceRaised": "#111111",
|
|
20
|
+
"surfaceInset": "#0a0a0a",
|
|
21
|
+
"borderSubtle": "rgba(255, 255, 255, 0.08)",
|
|
22
|
+
"borderFocus": "oklch(0.65 0.24 28)",
|
|
23
|
+
"accent": "oklch(0.58 0.24 28)",
|
|
24
|
+
"accentForeground": "#ffffff",
|
|
25
|
+
"status": {
|
|
26
|
+
"info": "oklch(0.78 0.15 200)",
|
|
27
|
+
"success": "oklch(0.72 0.20 142)",
|
|
28
|
+
"warning": "oklch(0.80 0.18 75)",
|
|
29
|
+
"critical": "oklch(0.60 0.25 28)"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
"geometry": {
|
|
33
|
+
"radiusBase": "2px",
|
|
34
|
+
"radiusOuter": "4px",
|
|
35
|
+
"concentricFormula": "max(0px, 4px - 1px - 2px) = 1px",
|
|
36
|
+
"scalingFormula": "clamp(0.97, 1 - 2.0/max(W, H), 0.995)",
|
|
37
|
+
"hitTargetMinTouch": "44px"
|
|
38
|
+
},
|
|
39
|
+
"motion": {
|
|
40
|
+
"profile": "precision",
|
|
41
|
+
"durationEntry": "100ms",
|
|
42
|
+
"durationExit": "70ms",
|
|
43
|
+
"easingEntry": "cubic-bezier(0.2, 0, 0, 1)",
|
|
44
|
+
"easingExit": "cubic-bezier(0.4, 0, 1, 1)"
|
|
45
|
+
},
|
|
46
|
+
"rules": [
|
|
47
|
+
"MD001_FOCUS_RING",
|
|
48
|
+
"MD002_REDUCED_MOTION",
|
|
49
|
+
"MD003_HIT_TARGET_ISOLATION",
|
|
50
|
+
"MD004_DEAD_BUTTON_CONTRACT",
|
|
51
|
+
"MD101_BENTO_ROW_FLOW"
|
|
52
|
+
]
|
|
53
|
+
}
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
## 9. AI TELLS (Forbidden Patterns)
|
|
2
|
+
|
|
3
|
+
Avoid these signatures unless the brief explicitly asks for them.
|
|
4
|
+
|
|
5
|
+
### 9.A Visual & CSS
|
|
6
|
+
* **NO neon / outer glows** by default. Use inner borders or subtle tinted shadows.
|
|
7
|
+
* **NO pure black (`#000000`).** Off-black, zinc-950, or charcoal.
|
|
8
|
+
* **NO oversaturated accents.** Desaturate to blend with neutrals.
|
|
9
|
+
* **NO excessive gradient text** for large headers.
|
|
10
|
+
* **NO custom mouse cursors.** Outdated, accessibility-hostile, perf-hostile.
|
|
11
|
+
|
|
12
|
+
### 9.B Typography
|
|
13
|
+
* **AVOID Inter as default.** See Section 4.1. Override path exists.
|
|
14
|
+
* **NO oversized H1s** that just scream. Control hierarchy with weight + color, not raw scale.
|
|
15
|
+
* **Serif constraints:** Serif for editorial / luxury / publication. Not for dashboards.
|
|
16
|
+
|
|
17
|
+
### 9.C Layout & Spacing
|
|
18
|
+
* **Mathematically perfect** padding and margins. No floating elements with awkward gaps.
|
|
19
|
+
* **NO 3-column equal feature cards.** The generic "three identical cards horizontally" feature row is banned. Use 2-column zig-zag, asymmetric grid, scroll-pinned, or horizontal-scroll alternative.
|
|
20
|
+
|
|
21
|
+
### 9.D Content & Data ("Jane Doe" Effect)
|
|
22
|
+
* **NO generic names.** "John Doe", "Sarah Chan", "Jack Su" → use creative, realistic, locale-appropriate names.
|
|
23
|
+
* **NO generic avatars.** No SVG "egg" or Lucide user icons → use believable photo placeholders or specific styling.
|
|
24
|
+
* **NO fake-perfect numbers.** Avoid `99.99%`, `50%`, `1234567`. Use organic, messy data (`47.2%`, `+1 (312) 847-1928`).
|
|
25
|
+
* **NO startup-slop brand names.** "Acme", "Nexus", "SmartFlow", "Cloudly" → invent contextual, premium names that sound real.
|
|
26
|
+
* **NO filler verbs.** "Elevate", "Seamless", "Unleash", "Next-Gen", "Revolutionize" → concrete verbs only.
|
|
27
|
+
|
|
28
|
+
### 9.E External Resources & Components
|
|
29
|
+
* **NO hand-rolled SVG icons.** Use Phosphor / HugeIcons / Radix / Tabler. Lucide on explicit request only.
|
|
30
|
+
* **Hand-rolled decorative SVGs strongly discouraged** as default (see Section 4.8).
|
|
31
|
+
* **NO div-based fake screenshots.** Never build a fake product UI out of `<div>` rectangles to simulate a screenshot. Use real images, generated images, or skip the preview.
|
|
32
|
+
* **NO broken Unsplash links.** Use `https://picsum.photos/seed/{descriptive-string}/{w}/{h}`, or generated photo placeholders, or actual assets.
|
|
33
|
+
* **shadcn/ui customization:** Allowed, but NEVER in default state. Customize radii, colors, shadows, typography to the project aesthetic.
|
|
34
|
+
* **Production-Ready Cleanliness:** Code visually clean, memorable, meticulously refined.
|
|
35
|
+
|
|
36
|
+
### 9.F Production-Test Tells (banned outright)
|
|
37
|
+
|
|
38
|
+
These patterns came out of real LLM-generated landing-page tests. They are the signatures the model defaults to when it tries to "look designed." Treat them as hard bans unless the brief explicitly calls for one.
|
|
39
|
+
|
|
40
|
+
**Hero & top-of-page**
|
|
41
|
+
* **NO version labels in the hero.** `V0.6`, `v2.0`, `BETA`, `INVITE-ONLY PREVIEW`, `EARLY ACCESS`, `ALPHA` - banned as default eyebrows. Only acceptable when the brief is explicitly about a product launch / preview status.
|
|
42
|
+
* **NO "Brand · No. 01"-style sub-eyebrows.** "Marrow · No. 01 · The 6-quart" type micro-meta lines. Skip them.
|
|
43
|
+
|
|
44
|
+
**Section numbering & micro-labels**
|
|
45
|
+
* **NO section-number eyebrows.** `00 / INDEX`, `001 · Capabilities`, `002 · Featured commission`, `06 · how it works`, `05 · The honest table` - banned. Eyebrows should name the topic in plain language, not enumerate.
|
|
46
|
+
* **NO `01 / 4`-style pagination on images or bento tiles.** If the user can count, they don't need the label.
|
|
47
|
+
* **NO `Scroll · 001 Capabilities`-style scroll cues.** A simple arrow or "Scroll" is enough; no section-number prefix.
|
|
48
|
+
* **NO "Index of Work, 2018 - 2026"-style range labels** as eyebrows. Just say what the section is.
|
|
49
|
+
|
|
50
|
+
**Separators & dots**
|
|
51
|
+
* **The middle-dot (`·`) is rationed.** Maximum 1 per line in metadata strips. Do NOT use it as the default separator for everything ("foo · bar · baz · qux · quux"). If you need a separator family, prefer line breaks, hairlines, or columns.
|
|
52
|
+
* **NO decorative colored status dots on every list/nav/badge.** A colored dot before "ONE Q4 SLOT OPEN" or before every nav link, or every task row - banned by default. Acceptable only when the dot conveys actual semantic state (a server status, an availability flag) and is used sparingly.
|
|
53
|
+
|
|
54
|
+
**Em-dashes & typography flourishes**
|
|
55
|
+
* **NO em-dash (`—`) as a design element OR anywhere else.** See Section 9.G below for the complete, non-negotiable ban. The em-dash character is forbidden in headlines, eyebrows, pills, body copy, quotes, attribution, captions, button text, and alt text. Use the regular hyphen (`-`).
|
|
56
|
+
* **NO `<br>`-broken-and-italicized headlines** as a default "design move." "for thirty\<br\>*years.*" type splits. Headlines should read naturally first, get clever only when the brief demands it.
|
|
57
|
+
* **NO vertical rotated text** ("INDEX OF WORK, 2018 - 2026" rotated 90°). Agency-portfolio cliché. Use it only when the brief is explicitly agency / Awwwards / experimental AND it serves a real composition purpose.
|
|
58
|
+
* **NO crosshair / hairline grid lines as decoration.** Vertical and horizontal lines drawn just to make the page "feel designed" - banned. Use them only when they organize real content.
|
|
59
|
+
|
|
60
|
+
**Fake product previews**
|
|
61
|
+
* **NO div-based fake product UI in the hero** (fake task list, fake terminal, fake dashboard built from styled divs). It is the #1 LLM-design Tell. Use a real screenshot, a generated image, a real component preview, or none at all.
|
|
62
|
+
* **NO fake version footers** ("v0.6.2-rc.1", "last sync 4s ago · main") inside fake screenshots. Adds nothing, screams AI.
|
|
63
|
+
|
|
64
|
+
**Marketing-copy Tells**
|
|
65
|
+
* **NO "Quietly in use at" / "Quietly trusted by"** social-proof headers. Use natural language: "Trusted by", "Used at", "Customers include", or skip the heading entirely if the logos speak.
|
|
66
|
+
* **NO "From the field" / "Field notes" / "Currently on the bench" / "On our desks" / "Loose plates" style poetic labels** on quote, blog, or sidebar sections. Reads as performative-craftsman. Use plain functional labels ("Testimonials", "Latest writing", "Now working on") or skip the label.
|
|
67
|
+
* **NO "We respect the French ones"-style** mock-humble industry-references in body copy. Cute and AI-y.
|
|
68
|
+
* **NO weather / locale strips** ("LIS 14:23 · 18°C") in headers/footers unless the brief is explicitly about a place / time-zone-distributed studio.
|
|
69
|
+
* **NO micro-meta-sentences under eyebrows.** Sentences like *"Each of these is a feature we ship today, not a roadmap promise. The list will stay short on purpose."* sitting under a section heading are clutter. Eyebrow + Headline + Body is enough.
|
|
70
|
+
* **NO generic step labels.** "Stage 1 / Stage 2 / Stage 3", "Step 1 / Step 2 / Step 3", "Phase 01 / Phase 02 / Phase 03", "Pass One / Pass Two / Pass Three". Banned. The actual step content is the label. If you must show progression, use the verb-noun directly ("Install", "Configure", "Ship") not "Stage 1: Install".
|
|
71
|
+
|
|
72
|
+
**Pills, labels and version stamps**
|
|
73
|
+
* **NO pills/labels/tags overlaid on images.** No `<span>` overlays on photos with tags like `Brand · 02`, `PLATE · BRAND`, `Field notes - journal`. Either let the image speak alone, or add a caption directly below (outside the image).
|
|
74
|
+
* **NO photo-credit captions as decoration.** Strings like `Field study no. 12 · Ines Caetano`, `Plate 03 · House archive`, `Frame XII · 35mm` under stock/picsum images are pretentious. Photo credit is allowed ONLY when there is a real photographer being credited for a real photo (with permission). Otherwise: skip the caption or use a one-line functional caption ("The 6-quart, in Sage.").
|
|
75
|
+
* **NO version footers on marketing pages.** Footer strings like `v1.4.2`, `Build 0048`, `last sync 4s ago · main` are CLI / devtool fixtures, not landing-page content. Banned on marketing/landing/portfolio pages.
|
|
76
|
+
* **NO "Reservation 412 of 800"-style live-stock counters** as decoration. Only if the brief is explicitly a limited-run waitlist with real data.
|
|
77
|
+
|
|
78
|
+
**Decoration text strips**
|
|
79
|
+
* **NO decoration text strip at hero bottom.** Patterns like `BRAND. MOTION. SPATIAL.`, `TYPE / FORM / MOTION`, `DESIGN · BUILD · SHIP`, `ESTD. 2018 · LISBON · BRAND. MOTION. SPATIAL.` as a small mono-caps strip across the bottom of the hero are an agency-portfolio cliché. Banned by default. Only acceptable when the strip carries real, navigable links (sticky bottom nav) or real status info (cookie banner, build info on a docs site).
|
|
80
|
+
* **NO floating top-right sub-text in section headings.** Pattern: section has a giant left-aligned headline; in the top-right corner of the same section header there is a small explainer paragraph floating with no clear alignment to anything else. That floater is the Tell. Either put the sub-text directly under the headline, or build a clean 2-column header (left: headline, right: aligned body), but not a tiny corner paragraph.
|
|
81
|
+
|
|
82
|
+
**Lists, dividers and scoring**
|
|
83
|
+
* **NO `border-t` + `border-b` on every row of a long list / spec table.** Pick one (bottom-border between rows OR top-border above the group) and use it sparsely. A 10-row spec table with hairlines under each row is the laziest layout - see Section 4.9 for alternative UI components.
|
|
84
|
+
* **NO scoring/progress bars with filled background tracks** as comparison visuals. If you need to show "X out of Y" comparisons, prefer a number + small icon, or a tiny inline bar WITHOUT a background track. Big filled `bg-zinc-200` tracks with a partial fill on top are dashboard-UI clutter on a landing page.
|
|
85
|
+
|
|
86
|
+
**Locale, time, scroll cues**
|
|
87
|
+
* **Locale / city-name / time / weather strips are banned for 99% of briefs.** "Lisbon, working with founders" in the hero, "1200-690 Lisbon, Portugal" in the footer, "Lisbon 14:23 · 18°C" in the nav. These are agency-portfolio decoration tells. Allowed ONLY when: the brief explicitly describes a globally-distributed studio with timezone-relevant work, OR a travel-focused brand, OR a real-world physical venue. A single contact-address mention in the footer is fine; an atmospheric locale strip is not.
|
|
88
|
+
* **Scroll cues are banned.** `Scroll`, `↓ scroll`, `Scroll to explore`, `Scroll to walk through it`, animated mouse-wheel icons. If the user has not scrolled yet, they are looking at the hero. They know what scroll is. The bottom of the viewport does not need a label.
|
|
89
|
+
* **ZERO decorative status dots by default.** A coloured dot before nav items, before list rows, before badges, before status labels is a Tell. Only acceptable when conveying real semantic state (a live indicator on actual server status, a live availability flag) and limited to one per page section.
|
|
90
|
+
|
|
91
|
+
### 9.G EM-DASH BAN (the single most-violated Tell)
|
|
92
|
+
|
|
93
|
+
**Em-dash (`—`) is COMPLETELY banned.** It is the LLM's signature stylistic crutch and it is the #1 visual Tell in production tests. There is no "limited use" allowance, no "natural language frequency" allowance, no "in body copy is fine" allowance. None.
|
|
94
|
+
|
|
95
|
+
* **Banned in headlines.** Use a period or a comma.
|
|
96
|
+
* **Banned in eyebrows / labels / pills / button text / image captions / nav items.** Replace with line breaks, columns, or hairlines.
|
|
97
|
+
* **Banned in body copy.** Restructure the sentence: two sentences with a period, OR a comma, OR parentheses, OR a colon.
|
|
98
|
+
* **Banned in quote attribution.** Use a normal hyphen with spaces (` - `) or a line break + smaller-weight name.
|
|
99
|
+
* **Banned in en-dash form too (`–`) when used as a separator.** Date ranges (`2018-2026`) use a hyphen. Number ranges (`€40-80k`) use a hyphen.
|
|
100
|
+
|
|
101
|
+
The ONLY permitted dash characters on the page are:
|
|
102
|
+
* Regular hyphen `-` (for compound words, ranges, line dividers in markup)
|
|
103
|
+
* Minus sign in math (`-5°C`)
|
|
104
|
+
|
|
105
|
+
If your output contains a single `—` or `–` anywhere visible to the user, the output fails the Pre-Flight Check and must be rewritten.
|
|
106
|
+
|
|
107
|
+
This rule is non-negotiable. The agent has historically ignored em-dash limits when phrased as "use sparingly." The phrasing here is binary: zero em-dashes.
|
|
108
|
+
|
|
109
|
+
Scope: text rendered in the UI being built; does not apply to chat replies or skill metadata.
|
|
110
|
+
|
|
111
|
+
---
|
|
112
|
+
|
|
113
|
+
|
|
114
|
+
### 9.H Structural, IA & Interaction Slop (Decisionless Uniformity)
|
|
115
|
+
|
|
116
|
+
การป้องกัน AI Slop ที่แท้จริงต้องก้าวข้ามการห้ามแค่สไตล์ผิวเผิน ไปสู่การสกัดกั้น **"ความสม่ำเสมอที่ไร้การตัดสินใจ" (Decisionless Uniformity)**:
|
|
117
|
+
|
|
118
|
+
1. **Structural & Layout Slop:**
|
|
119
|
+
- **NO Equal-Weight Metric Uniformity:** ห้ามทำ Dashboard ที่แจกแจงการ์ดขนาดเท่ากัน 4-6 ใบโดยไม่ระบุว่าตัวเลขใดคือ Primary Decision Metric และตัวเลขใดคือ Secondary Context
|
|
120
|
+
- **NO Unjustified Table-to-Card Conversion:** ห้ามแปลงตารางข้อมูลเชิงวิเคราะห์/พิกัด/ราคา ให้เป็นการ์ดสี่เหลี่ยมเรียงต่อกัน หากการแปลงนั้นทำให้ผู้ใช้สูญเสียความสามารถในการสแกนเปรียบเทียบค่าทางสายตา (Visual Row Scanning)
|
|
121
|
+
- **NO Workflow-Agnostic Responsive Stacking:** บนมือถือ ห้ามแค่สั่ง `grid-cols-1` ทื่อๆ โดยไม่จัดลำดับความสำคัญใหม่ หน้าทำงานระดับวิศวกรรมต้องตรึงเครื่องมือหลักและแผนที่/กราฟไว้ด้านบนเสมอ
|
|
122
|
+
|
|
123
|
+
2. **Interaction Slop (Dead Feedback):**
|
|
124
|
+
- **NO Cosmetic Hover on Static Elements:** ห้ามใส่ `hover:-translate-y-1` หรือ Hover Glow บนการ์ดที่คลิกไม่ได้และไม่มี Navigation Link
|
|
125
|
+
- **NO Broken State Contract:** ทุกปุ่มต้องมีสถานะครบ 6 ชั้น (`default → hover → pressed → focus-visible → disabled/loading → success/error`) ห้ามมีปุ่มที่กดแล้วนิ่งสนิท
|
|
126
|
+
- **NO Accent Color Inflation:** สีเน้น (Accent Color) ต้องใช้ไม่เกิน 10-15% ของพื้นที่หน้าจอทั้งหมด ห้ามระบายสีเน้นลงบนไอคอน หัวข้อ และการ์ดทุกใบจนปุ่ม CTA สูญเสียแรงดึงดูดสายตา (Visual Gravity)
|
|
127
|
+
|
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
## Appendix A - Install Commands per Design System
|
|
2
|
+
|
|
3
|
+
```bash
|
|
4
|
+
# Material Web (Material 3)
|
|
5
|
+
npm install @material/web
|
|
6
|
+
|
|
7
|
+
# Fluent UI React (v9)
|
|
8
|
+
npm install @fluentui/react-components
|
|
9
|
+
|
|
10
|
+
# Fluent UI Web Components (framework-free)
|
|
11
|
+
npm install @fluentui/web-components @fluentui/tokens
|
|
12
|
+
|
|
13
|
+
# IBM Carbon
|
|
14
|
+
npm install @carbon/react @carbon/styles
|
|
15
|
+
|
|
16
|
+
# Radix Themes
|
|
17
|
+
npm install @radix-ui/themes
|
|
18
|
+
|
|
19
|
+
# shadcn/ui (open code, owned components)
|
|
20
|
+
npx shadcn@latest init
|
|
21
|
+
npx shadcn@latest add button card badge separator input
|
|
22
|
+
|
|
23
|
+
# Primer CSS (GitHub product/devtool UI)
|
|
24
|
+
npm install --save @primer/css
|
|
25
|
+
|
|
26
|
+
# Primer Brand (GitHub marketing UI)
|
|
27
|
+
npm install @primer/react-brand
|
|
28
|
+
|
|
29
|
+
# GOV.UK Frontend
|
|
30
|
+
npm install govuk-frontend
|
|
31
|
+
|
|
32
|
+
# USWDS (US Web Design System)
|
|
33
|
+
npm install uswds
|
|
34
|
+
|
|
35
|
+
# Atlassian Design System (Atlaskit)
|
|
36
|
+
yarn add @atlaskit/css-reset @atlaskit/tokens @atlaskit/button @atlaskit/badge @atlaskit/section-message @atlaskit/card
|
|
37
|
+
|
|
38
|
+
# Bootstrap 5.3
|
|
39
|
+
npm install bootstrap
|
|
40
|
+
|
|
41
|
+
# Shopify Polaris Web Components (Shopify apps only)
|
|
42
|
+
# Add this to your app HTML head:
|
|
43
|
+
# <meta name="shopify-api-key" content="%SHOPIFY_API_KEY%" />
|
|
44
|
+
# <script src="https://cdn.shopify.com/shopifycloud/polaris.js"></script>
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
## Appendix B - Canonical Sources (read these before reinventing)
|
|
48
|
+
|
|
49
|
+
### Material Web
|
|
50
|
+
- https://github.com/material-components/material-web
|
|
51
|
+
- https://material-web.dev/theming/material-theming/
|
|
52
|
+
- https://m3.material.io/develop/web
|
|
53
|
+
|
|
54
|
+
### Fluent UI
|
|
55
|
+
- https://fluent2.microsoft.design/get-started/develop
|
|
56
|
+
- https://fluent2.microsoft.design/components/web/react/
|
|
57
|
+
- https://github.com/microsoft/fluentui
|
|
58
|
+
- https://learn.microsoft.com/en-us/fluent-ui/web-components/
|
|
59
|
+
|
|
60
|
+
### Carbon
|
|
61
|
+
- https://carbondesignsystem.com/
|
|
62
|
+
- https://github.com/carbon-design-system/carbon
|
|
63
|
+
- https://carbondesignsystem.com/developing/react-tutorial/overview/
|
|
64
|
+
- https://carbondesignsystem.com/developing/web-components-tutorial/overview/
|
|
65
|
+
|
|
66
|
+
### Shopify Polaris
|
|
67
|
+
- https://shopify.dev/docs/api/app-home/web-components
|
|
68
|
+
- https://github.com/Shopify/polaris-react
|
|
69
|
+
- https://polaris-react.shopify.com/components
|
|
70
|
+
|
|
71
|
+
### Atlassian
|
|
72
|
+
- https://atlassian.design/get-started/develop
|
|
73
|
+
- https://atlassian.design/components/button/examples
|
|
74
|
+
- https://atlaskit.atlassian.com/packages/design-system/button/example/disabled
|
|
75
|
+
- https://atlassian.design/tokens/design-tokens
|
|
76
|
+
|
|
77
|
+
### Primer
|
|
78
|
+
- https://primer.style/
|
|
79
|
+
- https://github.com/primer/css
|
|
80
|
+
- https://github.com/primer/brand
|
|
81
|
+
|
|
82
|
+
### GOV.UK
|
|
83
|
+
- https://design-system.service.gov.uk/components/button/
|
|
84
|
+
- https://design-system.service.gov.uk/styles/layout/
|
|
85
|
+
- https://github.com/alphagov/govuk-frontend
|
|
86
|
+
|
|
87
|
+
### USWDS
|
|
88
|
+
- https://designsystem.digital.gov/documentation/developers/
|
|
89
|
+
- https://designsystem.digital.gov/components/button/
|
|
90
|
+
- https://designsystem.digital.gov/components/card/
|
|
91
|
+
- https://github.com/uswds/uswds
|
|
92
|
+
|
|
93
|
+
### Bootstrap
|
|
94
|
+
- https://getbootstrap.com/docs/5.3/layout/grid/
|
|
95
|
+
- https://getbootstrap.com/docs/5.3/components/card/
|
|
96
|
+
|
|
97
|
+
### Tailwind
|
|
98
|
+
- https://tailwindcss.com/docs/dark-mode
|
|
99
|
+
- https://tailwindcss.com/blog/tailwindcss-v4
|
|
100
|
+
|
|
101
|
+
### Radix
|
|
102
|
+
- https://www.radix-ui.com/themes/docs/components/theme
|
|
103
|
+
- https://www.radix-ui.com/themes/docs/components/card
|
|
104
|
+
- https://github.com/radix-ui/themes
|
|
105
|
+
|
|
106
|
+
### shadcn/ui
|
|
107
|
+
- https://ui.shadcn.com/docs
|
|
108
|
+
- https://ui.shadcn.com/docs/components/card
|
|
109
|
+
- https://github.com/shadcn-ui/ui
|
|
110
|
+
|
|
111
|
+
### Native CSS / W3C standards
|
|
112
|
+
- https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/Properties/backdrop-filter
|
|
113
|
+
- https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules/@media/prefers-color-scheme
|
|
114
|
+
- https://developer.mozilla.org/en-US/docs/Web/CSS/Reference/At-rules/@media/prefers-reduced-motion
|
|
115
|
+
- https://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Grid_layout
|
|
116
|
+
- https://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Scroll-driven_animations
|
|
117
|
+
- https://drafts.csswg.org/scroll-animations-1/
|
|
118
|
+
|
|
119
|
+
### Apple Liquid Glass (Apple platforms only)
|
|
120
|
+
- https://developer.apple.com/design/human-interface-guidelines/materials
|
|
121
|
+
- https://developer.apple.com/documentation/TechnologyOverviews/liquid-glass
|
|
122
|
+
- https://developer.apple.com/documentation/TechnologyOverviews/adopting-liquid-glass
|
|
123
|
+
- https://developer.apple.com/documentation/SwiftUI/Material
|
|
124
|
+
|
|
125
|
+
---
|
|
126
|
+
|
|
127
|
+
## Appendix C - Apple Liquid Glass: Honest Web Approximation
|
|
128
|
+
|
|
129
|
+
Do **not** treat random CSS snippets as official Apple Liquid Glass.
|
|
130
|
+
|
|
131
|
+
### What is official
|
|
132
|
+
Apple documents Liquid Glass inside Apple's Human Interface Guidelines and Developer Documentation for **Apple platforms**. It is a dynamic material used across Apple platform UI. Apple's native implementation belongs to Apple platform APIs and system components, **not a public web CSS package**.
|
|
133
|
+
|
|
134
|
+
Relevant official docs:
|
|
135
|
+
- Apple Human Interface Guidelines → Materials
|
|
136
|
+
- Apple Developer Documentation → Liquid Glass
|
|
137
|
+
- Apple Developer Documentation → Adopting Liquid Glass
|
|
138
|
+
- SwiftUI → Material
|
|
139
|
+
|
|
140
|
+
### What is NOT official
|
|
141
|
+
There is no `liquid-glass.css` from Apple for normal websites.
|
|
142
|
+
|
|
143
|
+
A web approximation can use:
|
|
144
|
+
- `backdrop-filter`
|
|
145
|
+
- transparent backgrounds
|
|
146
|
+
- layered borders
|
|
147
|
+
- highlight overlays
|
|
148
|
+
- gradients
|
|
149
|
+
- motion
|
|
150
|
+
- strong contrast fallbacks
|
|
151
|
+
|
|
152
|
+
But that is **web glassmorphism / frosted-glass approximation**, not official Apple Liquid Glass. Label it as such in comments.
|
|
153
|
+
|
|
154
|
+
### Safer web approximation skeleton
|
|
155
|
+
|
|
156
|
+
```css
|
|
157
|
+
.liquid-glass-web-approx {
|
|
158
|
+
position: relative;
|
|
159
|
+
isolation: isolate;
|
|
160
|
+
overflow: hidden;
|
|
161
|
+
border-radius: 999px;
|
|
162
|
+
border: 1px solid rgb(255 255 255 / .32);
|
|
163
|
+
background:
|
|
164
|
+
linear-gradient(135deg, rgb(255 255 255 / .30), rgb(255 255 255 / .08)),
|
|
165
|
+
rgb(255 255 255 / .12);
|
|
166
|
+
backdrop-filter: blur(24px) saturate(180%) contrast(1.05);
|
|
167
|
+
-webkit-backdrop-filter: blur(24px) saturate(180%) contrast(1.05);
|
|
168
|
+
box-shadow:
|
|
169
|
+
inset 0 1px 0 rgb(255 255 255 / .48),
|
|
170
|
+
inset 0 -1px 0 rgb(255 255 255 / .12),
|
|
171
|
+
0 18px 60px rgb(0 0 0 / .18);
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.liquid-glass-web-approx::before {
|
|
175
|
+
content: "";
|
|
176
|
+
position: absolute;
|
|
177
|
+
inset: 0;
|
|
178
|
+
z-index: -1;
|
|
179
|
+
border-radius: inherit;
|
|
180
|
+
background:
|
|
181
|
+
radial-gradient(circle at 20% 0%, rgb(255 255 255 / .55), transparent 34%),
|
|
182
|
+
linear-gradient(90deg, rgb(255 255 255 / .18), transparent 42%, rgb(255 255 255 / .14));
|
|
183
|
+
pointer-events: none;
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
.liquid-glass-web-approx::after {
|
|
187
|
+
content: "";
|
|
188
|
+
position: absolute;
|
|
189
|
+
inset: 1px;
|
|
190
|
+
border-radius: inherit;
|
|
191
|
+
border: 1px solid rgb(255 255 255 / .14);
|
|
192
|
+
pointer-events: none;
|
|
193
|
+
}
|
|
194
|
+
|
|
195
|
+
@media (prefers-color-scheme: dark) {
|
|
196
|
+
.liquid-glass-web-approx {
|
|
197
|
+
border-color: rgb(255 255 255 / .18);
|
|
198
|
+
background:
|
|
199
|
+
linear-gradient(135deg, rgb(255 255 255 / .16), rgb(255 255 255 / .04)),
|
|
200
|
+
rgb(15 23 42 / .42);
|
|
201
|
+
box-shadow:
|
|
202
|
+
inset 0 1px 0 rgb(255 255 255 / .22),
|
|
203
|
+
0 18px 60px rgb(0 0 0 / .42);
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
@media (prefers-reduced-transparency: reduce) {
|
|
208
|
+
.liquid-glass-web-approx {
|
|
209
|
+
background: rgb(255 255 255 / .96);
|
|
210
|
+
backdrop-filter: none;
|
|
211
|
+
-webkit-backdrop-filter: none;
|
|
212
|
+
}
|
|
213
|
+
}
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
**Important:** `prefers-reduced-transparency` has uneven browser support; test it. Always provide enough contrast even without blur.
|
|
217
|
+
|
|
218
|
+
---
|
|
219
|
+
|
|
220
|
+
**End of appendices.** Install commands above are reality anchors. The Apple Liquid Glass skeleton is a labeled approximation, not an Apple-issued package. For canonical docs per design system, consult the system's official docs (links in Section 2 plus Appendix B).
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
## 3. DEFAULT ARCHITECTURE & CONVENTIONS
|
|
2
|
+
|
|
3
|
+
Unless the design read picks a real design system (Section 2.A), these are the defaults:
|
|
4
|
+
|
|
5
|
+
### 3.A Stack
|
|
6
|
+
* **Framework:** React or Next.js. Default to Server Components (RSC).
|
|
7
|
+
* **RSC SAFETY:** Global state works ONLY in Client Components. In Next.js, wrap providers in a `"use client"` component.
|
|
8
|
+
* **INTERACTIVITY ISOLATION:** Any component using Motion, scroll listeners, or pointer physics MUST be an isolated leaf with `'use client'` at the top. Server Components render static layouts only.
|
|
9
|
+
* **Styling:** **Tailwind v4** (default). Tailwind v3 only if the existing project demands it.
|
|
10
|
+
* For v4: do NOT use `tailwindcss` plugin in `postcss.config.js`. Use `@tailwindcss/postcss` or the Vite plugin.
|
|
11
|
+
* **Animation:** **Motion** (the library formerly known as Framer Motion). Import from `motion/react` (`import { motion } from "motion/react"`). The `framer-motion` package still works as a legacy alias - prefer `motion/react` in new code.
|
|
12
|
+
* **Fonts:** Always use `next/font` (Next.js) or self-host with `@font-face` + `font-display: swap`. Never link Google Fonts via `<link>` in production.
|
|
13
|
+
|
|
14
|
+
### 3.B State
|
|
15
|
+
* Local `useState` / `useReducer` for isolated UI.
|
|
16
|
+
* Global state ONLY for deep prop-drilling avoidance - Zustand, Jotai, or React context.
|
|
17
|
+
* **NEVER** use `useState` to track continuous values driven by user input (mouse position, scroll progress, pointer physics, magnetic hover). Use Motion's `useMotionValue` / `useTransform` / `useScroll`. `useState` re-renders the React tree on every change and collapses on mobile.
|
|
18
|
+
|
|
19
|
+
### 3.C Icons
|
|
20
|
+
* **Allowed libraries (priority order):** `@phosphor-icons/react`, `hugeicons-react`, `@radix-ui/react-icons`, `@tabler/icons-react`.
|
|
21
|
+
* **Discouraged:** `lucide-react`. Acceptable only when the user explicitly asks for it or the project already depends on it.
|
|
22
|
+
* **NEVER hand-roll SVG icons.** If a glyph is missing, install a second library or compose from primitives - do not draw icon paths from scratch.
|
|
23
|
+
* **One family per project.** Do not mix Phosphor with Lucide in the same component tree.
|
|
24
|
+
* **Standardize `strokeWidth` globally** (e.g. `1.5` or `2.0`).
|
|
25
|
+
|
|
26
|
+
### 3.D Emoji Policy
|
|
27
|
+
Discouraged by default in code, markup, and visible text. Replace symbols with icon-library glyphs. **Override:** allow emojis only when the user explicitly asks for a playful / chat-style / social-native vibe - and even then use them sparingly with intent.
|
|
28
|
+
|
|
29
|
+
### 3.E Responsiveness & Layout Mechanics
|
|
30
|
+
* Standardize breakpoints (`sm 640`, `md 768`, `lg 1024`, `xl 1280`, `2xl 1536`).
|
|
31
|
+
* Contain page layouts using `max-w-[1400px] mx-auto` or `max-w-7xl`.
|
|
32
|
+
* **Viewport Stability:** NEVER use `h-screen` for full-height Hero sections. ALWAYS use `min-h-[100dvh]` to prevent layout jumping on mobile (iOS Safari address bar).
|
|
33
|
+
* **Grid over Flex-Math:** NEVER use complex flexbox percentage math (`w-[calc(33%-1rem)]`). ALWAYS use CSS Grid (`grid grid-cols-1 md:grid-cols-3 gap-6`).
|
|
34
|
+
|
|
35
|
+
### 3.F Dependency Verification (mandatory)
|
|
36
|
+
Before importing ANY 3rd-party library, check `package.json`. If the package is missing, output the install command first. **Never** assume a library exists.
|
|
37
|
+
|
|
38
|
+
---
|
|
39
|
+
|