@wbc-ui/core2 1.0.0-r06 → 1.0.0-r07
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/assets/engine-flow.svg +89 -0
- package/assets/hero-input-output.spec.md +193 -0
- package/assets/hero-input-output.svg +165 -0
- package/assets/tier-badges.svg +27 -0
- package/dist/build-info.json +2 -2
- package/package.json +2 -1
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 780 420" width="780" height="420">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="bg" x1="0" y1="0" x2="0" y2="1">
|
|
4
|
+
<stop offset="0%" stop-color="#f8fafc"/>
|
|
5
|
+
<stop offset="100%" stop-color="#e2e8f0"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
<linearGradient id="blue" x1="0" y1="0" x2="0" y2="1">
|
|
8
|
+
<stop offset="0%" stop-color="#1976D2"/>
|
|
9
|
+
<stop offset="100%" stop-color="#0D47A1"/>
|
|
10
|
+
</linearGradient>
|
|
11
|
+
<linearGradient id="green" x1="0" y1="0" x2="0" y2="1">
|
|
12
|
+
<stop offset="0%" stop-color="#43A047"/>
|
|
13
|
+
<stop offset="100%" stop-color="#2E7D32"/>
|
|
14
|
+
</linearGradient>
|
|
15
|
+
<filter id="shadow">
|
|
16
|
+
<feDropShadow dx="0" dy="1.5" stdDeviation="2" flood-opacity="0.12"/>
|
|
17
|
+
</filter>
|
|
18
|
+
<marker id="arrowBlue" viewBox="0 0 10 10" refX="8" refY="5" markerWidth="5" markerHeight="5" orient="auto">
|
|
19
|
+
<path d="M0,0 L10,5 L0,10" fill="#1976D2"/>
|
|
20
|
+
</marker>
|
|
21
|
+
<marker id="arrowGreen" viewBox="0 0 10 10" refX="8" refY="5" markerWidth="5" markerHeight="5" orient="auto">
|
|
22
|
+
<path d="M0,0 L10,5 L0,10" fill="#2E7D32"/>
|
|
23
|
+
</marker>
|
|
24
|
+
</defs>
|
|
25
|
+
|
|
26
|
+
<rect width="780" height="420" rx="10" fill="url(#bg)"/>
|
|
27
|
+
|
|
28
|
+
<!-- Title -->
|
|
29
|
+
<text x="390" y="28" text-anchor="middle" font-family="Arial,sans-serif" font-weight="900" font-size="16" fill="#1a202c">WBC Rendering Engine — Detection → Dispatch → Decorate → Output</text>
|
|
30
|
+
|
|
31
|
+
<!-- Stage labels -->
|
|
32
|
+
<text x="108" y="45" text-anchor="middle" font-family="Arial" font-size="9" fill="#94A3B8" font-weight="700">INPUT</text>
|
|
33
|
+
<text x="338" y="45" text-anchor="middle" font-family="Arial" font-size="9" fill="#94A3B8" font-weight="700">DISPATCH</text>
|
|
34
|
+
<text x="585" y="45" text-anchor="middle" font-family="Arial" font-size="9" fill="#94A3B8" font-weight="700">RENDER</text>
|
|
35
|
+
<text x="585" y="300" text-anchor="middle" font-family="Arial" font-size="9" fill="#94A3B8" font-weight="700">DECORATE</text>
|
|
36
|
+
<text x="585" y="398" text-anchor="middle" font-family="Arial" font-size="9" fill="#94A3B8" font-weight="700">OUTPUT</text>
|
|
37
|
+
|
|
38
|
+
<!-- ── Row 1: Input ── -->
|
|
39
|
+
<rect x="20" y="55" width="176" height="38" rx="6" fill="white" stroke="#1976D2" stroke-width="1.5" filter="url(#shadow)"/>
|
|
40
|
+
<text x="108" y="71" text-anchor="middle" font-family="monospace" font-weight="700" font-size="12" fill="#1565C0">Input: data</text>
|
|
41
|
+
<text x="108" y="85" text-anchor="middle" font-family="Arial" font-size="9" fill="#64748B">JSON · string · file</text>
|
|
42
|
+
|
|
43
|
+
<!-- Arrow input → detection (ends at detection edge) -->
|
|
44
|
+
<line x1="196" y1="74" x2="252" y2="74" stroke="#1976D2" stroke-width="1.8" marker-end="url(#arrowBlue)"/>
|
|
45
|
+
|
|
46
|
+
<!-- ── Row 2: Type Detection ── -->
|
|
47
|
+
<rect x="260" y="52" width="156" height="44" rx="6" fill="url(#blue)" filter="url(#shadow)"/>
|
|
48
|
+
<text x="338" y="70" text-anchor="middle" font-family="Arial" font-weight="700" font-size="12" fill="white">Type Detection</text>
|
|
49
|
+
<text x="338" y="88" text-anchor="middle" font-family="monospace" font-size="9" fill="#BBDEFB">string ? object ? array ? file ?</text>
|
|
50
|
+
|
|
51
|
+
<!-- Branch arrows detection → renderers (all end at renderer left edge x=500) -->
|
|
52
|
+
<line x1="416" y1="62" x2="492" y2="88" stroke="#43A047" stroke-width="1.5"/>
|
|
53
|
+
<line x1="416" y1="74" x2="492" y2="162" stroke="#1976D2" stroke-width="1.5"/>
|
|
54
|
+
<line x1="416" y1="86" x2="492" y2="236" stroke="#7B1FA2" stroke-width="1.5"/>
|
|
55
|
+
|
|
56
|
+
<!-- ── Renderers ── -->
|
|
57
|
+
<rect x="500" y="62" width="170" height="52" rx="5" fill="#E8F5E9" stroke="#43A047" stroke-width="1.2"/>
|
|
58
|
+
<text x="585" y="84" text-anchor="middle" font-family="monospace" font-weight="700" font-size="10" fill="#2E7D32">renderString</text>
|
|
59
|
+
<text x="585" y="102" text-anchor="middle" font-family="Arial" font-size="8" fill="#4CAF50">pipe | syntax</text>
|
|
60
|
+
|
|
61
|
+
<rect x="500" y="136" width="170" height="52" rx="5" fill="#E3F2FD" stroke="#1976D2" stroke-width="1.2"/>
|
|
62
|
+
<text x="585" y="158" text-anchor="middle" font-family="monospace" font-weight="700" font-size="10" fill="#1565C0">renderObject</text>
|
|
63
|
+
<text x="585" y="176" text-anchor="middle" font-family="Arial" font-size="8" fill="#1976D2">{ comp, options, items }</text>
|
|
64
|
+
|
|
65
|
+
<rect x="500" y="210" width="170" height="52" rx="5" fill="#F3E5F5" stroke="#7B1FA2" stroke-width="1.2"/>
|
|
66
|
+
<text x="585" y="232" text-anchor="middle" font-family="monospace" font-weight="700" font-size="10" fill="#6A1B9A">renderArray·File·Func·Prim</text>
|
|
67
|
+
<text x="585" y="250" text-anchor="middle" font-family="Arial" font-size="8" fill="#8E24AA">lists / images / code / values</text>
|
|
68
|
+
|
|
69
|
+
<!-- Arrow renderers merge → decorator (from LAST box bottom=262 to decorator top=302) -->
|
|
70
|
+
<line x1="585" y1="262" x2="585" y2="295" stroke="#64748B" stroke-width="1.5"/>
|
|
71
|
+
<polygon points="580,290 585,300 590,290" fill="#64748B"/>
|
|
72
|
+
|
|
73
|
+
<!-- ── Decorator Chain ── -->
|
|
74
|
+
<rect x="500" y="302" width="170" height="60" rx="5" fill="white" stroke="#7986CB" stroke-width="1.5" filter="url(#shadow)"/>
|
|
75
|
+
<text x="585" y="322" text-anchor="middle" font-family="Arial" font-weight="700" font-size="10" fill="#3949AB">Decorator Chain</text>
|
|
76
|
+
<text x="585" y="340" text-anchor="middle" font-family="monospace" font-size="8" fill="#7986CB">Focus → RTL → Select →</text>
|
|
77
|
+
<text x="585" y="354" text-anchor="middle" font-family="monospace" font-size="8" fill="#7986CB">wbCode → Flattener</text>
|
|
78
|
+
|
|
79
|
+
<!-- Arrow decorator → output (from decorator bottom=362 to output top=388) -->
|
|
80
|
+
<line x1="585" y1="362" x2="585" y2="378" stroke="#43A047" stroke-width="2" marker-end="url(#arrowGreen)"/>
|
|
81
|
+
|
|
82
|
+
<!-- ── Output ── -->
|
|
83
|
+
<rect x="530" y="388" width="110" height="30" rx="5" fill="url(#green)" filter="url(#shadow)"/>
|
|
84
|
+
<text x="585" y="407" text-anchor="middle" font-family="Arial" font-weight="700" font-size="10" fill="white">VNodes → DOM</text>
|
|
85
|
+
|
|
86
|
+
<!-- Vertical flow guide lines -->
|
|
87
|
+
<line x1="338" y1="96" x2="338" y2="330" stroke="#64748B" stroke-width="0.8" stroke-dasharray="5,4" opacity="0.25"/>
|
|
88
|
+
<line x1="338" y1="330" x2="500" y2="330" stroke="#7986CB" stroke-width="0.8" stroke-dasharray="5,4" opacity="0.25"/>
|
|
89
|
+
</svg>
|
|
@@ -0,0 +1,193 @@
|
|
|
1
|
+
# Spec — `hero-input-output.svg` (README hero asset)
|
|
2
|
+
|
|
3
|
+
> **Status:** Authoritative spec for the still image embedded at [README.md:27-29](../../README.md#L27-L29).
|
|
4
|
+
> **Decision history:** vhs-screencast approach attempted 2026-05-19 → rejected (terminal frame reads as "CLI tool", not "UI engine"). This spec replaces it.
|
|
5
|
+
> **Owner:** open — designer / DS V4 Pro / human can produce; spec is tool-agnostic.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## 1. Purpose
|
|
10
|
+
|
|
11
|
+
A single image that, in **one glance**, proves the core @wbc-ui/core2 pitch:
|
|
12
|
+
|
|
13
|
+
> *"You write `<WBC :item='...'>` once. The engine renders real Material Design UI."*
|
|
14
|
+
|
|
15
|
+
The reader on `npmjs.com/package/@wbc-ui/core2` has 2-3 seconds before scrolling. The hero asset must do its job in that window — no animation, no waiting, no terminal.
|
|
16
|
+
|
|
17
|
+
## 2. Composition (the only thing that matters)
|
|
18
|
+
|
|
19
|
+
**Split-screen still, 16:9-ish, ≈1280×640 logical pixels.**
|
|
20
|
+
|
|
21
|
+
```
|
|
22
|
+
┌─────────────────────────────────┬─────────────────────────────────┐
|
|
23
|
+
│ │ │
|
|
24
|
+
│ LEFT — "WHAT YOU WRITE" │ RIGHT — "WHAT GETS RENDERED" │
|
|
25
|
+
│ (monospace code, dark bg) │ (real-looking Vuetify UI) │
|
|
26
|
+
│ │ │
|
|
27
|
+
│ <WBC :item="…"/> │ [Material card + content] │
|
|
28
|
+
│ │ │
|
|
29
|
+
└─────────────────────────────────┴─────────────────────────────────┘
|
|
30
|
+
↑ source-of-truth ↑ DOM result
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
**Centre divider:** a thin vertical line + a single `→` arrow at vertical centre. NOT animated. The arrow is the visual claim.
|
|
34
|
+
|
|
35
|
+
**Heading band (full-width, above the split):** small text — `<WBC :item="…" /> · one component, real DOM` — centred, secondary colour.
|
|
36
|
+
|
|
37
|
+
## 3. The 5 scenarios — pick ONE for the still
|
|
38
|
+
|
|
39
|
+
A previous attempt tried to cram all 5 into a single frame. **Don't.** A still shows ONE pairing; if more is needed, that's option C (animated SVG / Lottie) and a separate sub-plan.
|
|
40
|
+
|
|
41
|
+
**Recommended for hero:** **Scenario 4 — JSON → VCard**. It's the most visually convincing because the gap between "looks like a tiny config" and "renders as a polished Material card" is the largest. The other scenarios are documented here so future variants (or scenario rotation) have a single source.
|
|
42
|
+
|
|
43
|
+
| # | Scenario | LEFT (source) | RIGHT (rendered) | Why this one |
|
|
44
|
+
|---|---|---|---|---|
|
|
45
|
+
| 1 | Hello World | `<WBC :item="'Welcome to @wbc-ui/core2\|text-h3 primary--text'" />` | A large blue heading reading **Welcome to @wbc-ui/core2** | Cleanest demo of pipe-syntax, but visually thin |
|
|
46
|
+
| 2 | Link | `<WBC :item="'Read the docs\|text-h6\|/docs'" />` | A blue underlined h6 link reading **Read the docs** | Tiny on screen, weak hero |
|
|
47
|
+
| 3 | File → image | `<WBC :item="'./hero.png\|rounded elevation-4'" />` | An actual image with rounded corners + drop shadow | Visually strong but requires a real source image |
|
|
48
|
+
| **4** | **JSON → VCard ⭐** | A pretty-printed 5-line object: `{ comp: 'VCard', options: { props: { elevation: 4 }, html: '<h2>Q3 Revenue</h2><p>+24% YoY</p>' } }` | A Material VCard with title, body text, light grey background, elevation-4 shadow | **Strongest visual claim — pick this** |
|
|
49
|
+
| 5 | Markdown | `<WBC :item="'./landing.md'" />` | A rendered markdown page (TOC sidebar, syntax-highlighted code block) | Best for the docs section, NOT the hero (too dense) |
|
|
50
|
+
|
|
51
|
+
## 4. Visual specification (Scenario 4 — the chosen still)
|
|
52
|
+
|
|
53
|
+
### Left half — source pane
|
|
54
|
+
|
|
55
|
+
- **Background:** `#1e1e2e` (Catppuccin Mocha base) or any IDE-dark.
|
|
56
|
+
- **Font:** monospace, **16–18 px**, soft white (`#cdd6f4`).
|
|
57
|
+
- **Code block — exact content (no truncation):**
|
|
58
|
+
|
|
59
|
+
```vue
|
|
60
|
+
<WBC :item="{
|
|
61
|
+
comp: 'VCard',
|
|
62
|
+
options: {
|
|
63
|
+
props: { elevation: 4 },
|
|
64
|
+
html: '<h2>Q3 Revenue</h2><p>+24% YoY</p>',
|
|
65
|
+
class: 'pa-4'
|
|
66
|
+
}
|
|
67
|
+
}" />
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
- **Syntax colours (light hint):** tag-name purple, attribute teal, string yellow-amber. Don't over-decorate.
|
|
71
|
+
- **Padding:** ≥ 32 px on all sides.
|
|
72
|
+
|
|
73
|
+
### Right half — rendered pane
|
|
74
|
+
|
|
75
|
+
- **Background:** `#f5f5f5` (light Material surface) — the visual contrast with the left side IS the claim.
|
|
76
|
+
- **Card to render:** Material `<v-card class="pa-4" elevation="4">` with:
|
|
77
|
+
- **Title (`h2`):** "Q3 Revenue" — 24 px, dark-grey, semibold.
|
|
78
|
+
- **Body (`p`):** "+24% YoY" — 16 px, success-green (`#1976D2` or `#43A047`). Optionally add a tiny up-arrow `▲`.
|
|
79
|
+
- **Card size:** ~ 260 × 120 px logical.
|
|
80
|
+
- **Drop shadow:** Material elevation-4 (soft, offset-y ≈ 4 px, blur ≈ 12 px, opacity ≈ 0.16).
|
|
81
|
+
- **Card position:** vertically + horizontally centred in the right pane.
|
|
82
|
+
- **Padding:** ≥ 32 px on all sides.
|
|
83
|
+
|
|
84
|
+
### Centre divider
|
|
85
|
+
|
|
86
|
+
- **Vertical line:** 1 px, `#3b3b4f` (mid-tone — visible on both sides).
|
|
87
|
+
- **Arrow:** at vertical centre, slightly larger circle (24 px) containing a `→` glyph in white. Background of circle: `#1976D2` (the WBC primary).
|
|
88
|
+
|
|
89
|
+
### Top band (above the split)
|
|
90
|
+
|
|
91
|
+
- Full width, ~ 48 px tall.
|
|
92
|
+
- Background: `#0d0d14` (deeper than left pane) → seamless transition to dark side.
|
|
93
|
+
- Centred text: `<WBC :item="…" />` (monospace, 18 px, dimmed white) `·` `one component, real DOM` (sans-serif, 14 px, secondary).
|
|
94
|
+
|
|
95
|
+
## 5. Format & size budget
|
|
96
|
+
|
|
97
|
+
| Property | Target |
|
|
98
|
+
|---|---|
|
|
99
|
+
| **Format** | SVG strongly preferred (scales, ≤ 30 KB possible). PNG @ 2× acceptable. AVIF if hosting allows. |
|
|
100
|
+
| **Logical size** | 1280 × 640 |
|
|
101
|
+
| **File size** | ≤ 80 KB SVG / ≤ 250 KB PNG. **Hard ceiling: 400 KB** (anything above and the npm page degrades on 3G). |
|
|
102
|
+
| **Aspect** | 2:1 — matches the `<img width="780">` slot already reserved in README. |
|
|
103
|
+
| **Colour space** | sRGB. No CMYK. No P3. |
|
|
104
|
+
| **Background** | Two-tone (dark left, light right) — must NOT be transparent (npm light-mode breaks transparent assets). |
|
|
105
|
+
|
|
106
|
+
## 6. Production paths (pick one)
|
|
107
|
+
|
|
108
|
+
| Path | Tool | Time | Output | Notes |
|
|
109
|
+
|---|---|---|---|---|
|
|
110
|
+
| **A** | Hand-rolled SVG | 1–2 h | `hero-input-output.svg` | Most precise, smallest file. Editable in text editor for tweaks. **Best for owner/lead.** |
|
|
111
|
+
| **B** | Figma → export SVG | 1 h | `hero-input-output.svg` | Fastest visual iteration if you already use Figma. Watch exported size (often bloated). |
|
|
112
|
+
| **C** | Excalidraw → export PNG/SVG | 30 min | `hero-input-output.svg` | Lowest fidelity but fastest. Hand-drawn style may not match the rest of the README. |
|
|
113
|
+
| **D** | Real screenshot of the live demo | 15 min | `hero-input-output.png` | Take a 1280×640 screenshot of `demo.wbc-ui.com` rendering Scenario 4, then composite the source code on the left in any image editor. Most authentic but tied to the current demo's exact theme. |
|
|
114
|
+
| **E** | AI-image generation | 5 min | `hero-input-output.png` | NOT recommended — AI image models reliably get monospace code wrong and produce uncanny Material cards. |
|
|
115
|
+
|
|
116
|
+
## 7. Verification checklist (before embedding)
|
|
117
|
+
|
|
118
|
+
- [ ] File at `docs/media/hero-input-output.svg` (or `.png`)
|
|
119
|
+
- [ ] File size ≤ 400 KB
|
|
120
|
+
- [ ] Renders correctly in **GitHub light mode** (no transparent bg surprises)
|
|
121
|
+
- [ ] Renders correctly in **GitHub dark mode** (the dark left pane stays visually distinct from GitHub's `#0d1117` background — add a 1-px outer border if needed)
|
|
122
|
+
- [ ] Source code on left is **readable at 780 px wide** (the README slot width) — letter height ≥ 14 px on a typical laptop screen
|
|
123
|
+
- [ ] Material card on right does NOT bleed off the canvas
|
|
124
|
+
- [ ] Logical 2:1 aspect ratio preserved
|
|
125
|
+
- [ ] No proprietary fonts embedded (use system monospace + sans-serif fallback chains)
|
|
126
|
+
|
|
127
|
+
## 8. README integration (when ready)
|
|
128
|
+
|
|
129
|
+
Once the file exists:
|
|
130
|
+
|
|
131
|
+
```html
|
|
132
|
+
<!-- replace the current TODO-commented block at README.md:27-29 -->
|
|
133
|
+
<p align="center">
|
|
134
|
+
<img src="docs/media/hero-input-output.svg"
|
|
135
|
+
alt="@wbc-ui/core2 — write <WBC :item='...'>, render real Material UI"
|
|
136
|
+
width="780"/>
|
|
137
|
+
</p>
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
(Note: `<` and `>` in the `alt` attribute must be HTML-entity-escaped or quoted with `'…'` — npm's alt-text renderer is strict.)
|
|
141
|
+
|
|
142
|
+
## 9. What this spec replaces
|
|
143
|
+
|
|
144
|
+
- **Killed:** vhs `.tape` approach (`docs/media/hero-pipe-syntax.tape` — deleted 2026-05-19 13:21).
|
|
145
|
+
- **Killed:** terminal-screencast GIF (`docs/media/hero-pipe-syntax.gif` — deleted 2026-05-19 13:21).
|
|
146
|
+
- **Killed:** sub-plan rows 7.1–7.4 (vhs recording chain — cancelled in plan).
|
|
147
|
+
- **Replaced by:** sub-plan rows 7.5–7.7 (produce SVG · embed · verify).
|
|
148
|
+
|
|
149
|
+
## 10. Future variants (not for v1)
|
|
150
|
+
|
|
151
|
+
- **Animated SVG** rotating through Scenarios 1, 3, 4, 5 — half-day production, hold for v1.1 of the README.
|
|
152
|
+
- **Locale variants** (Arabic RTL hero) — defer to `/wbTranslate` pass.
|
|
153
|
+
- **Tier variants** (free vs pro hero) — defer; the existing `tier-badges.svg` already covers tier signalling.
|
|
154
|
+
|
|
155
|
+
---
|
|
156
|
+
|
|
157
|
+
## 🔍 Validation (QA) — *(Opus 4.7 via Claude Code — 13:48)*
|
|
158
|
+
|
|
159
|
+
> **Validator:** Opus 4.7 (same model as author — self-validation bias acknowledged) · **Mode:** PASS ✅ · **Score: 8/10**
|
|
160
|
+
> **Note:** appending here because per the wbValid template, the spec IS the task 7.5 deliverable; there is no separate `tasks/task_7.5/` report folder.
|
|
161
|
+
|
|
162
|
+
### What I checked
|
|
163
|
+
|
|
164
|
+
| Criterion | Result |
|
|
165
|
+
|---|---|
|
|
166
|
+
| File exists at the path the plan claims | ✅ `docs/media/hero-input-output.spec.md` (9,063 bytes) |
|
|
167
|
+
| Section count matches report claim ("10 sections") | ✅ `grep -c '^## '` = 10 |
|
|
168
|
+
| Standalone-readable (no plan-file dependency) | ✅ — verified by re-reading sections 1–10 without context |
|
|
169
|
+
| Composition spec unambiguous (designer could execute) | ⚠️ §2 abstract; §4 detailed but missing reference image |
|
|
170
|
+
| Scenario chosen (one of the 5)? | ✅ Scenario 4 — JSON → VCard — explicitly marked ⭐ in §3 |
|
|
171
|
+
| Size budget concrete? | ✅ ≤ 80 KB SVG / ≤ 250 KB PNG / hard ceiling 400 KB |
|
|
172
|
+
| Production paths recommend a default? | ❌ §6 lists A/B/C/D/E but doesn't pick. **Defect.** |
|
|
173
|
+
| Failure modes pre-empted? | ✅ Path E (AI image-gen) explicitly rejected; transparent-bg + dark-mode + npm-alt-escaping all flagged |
|
|
174
|
+
| Verification checklist actionable? | ✅ §7 — 8 boxes, all concrete |
|
|
175
|
+
| README-integration snippet provided? | ✅ §8 — drop-in HTML with escaped `<` / `>` warning |
|
|
176
|
+
|
|
177
|
+
### Defects (the 2-point deduction)
|
|
178
|
+
|
|
179
|
+
| # | Defect | Severity | Note |
|
|
180
|
+
|---|---|---|---|
|
|
181
|
+
| D1 | §6 surveys 5 production paths but doesn't recommend a default. A spec should opine, not just enumerate. | −1.0 | Recommend stating "Path A (hand-rolled SVG) is the default; pick another only if you have a specific reason." |
|
|
182
|
+
| D2 | §2 composition is described in prose + a rough ASCII frame; a designer would still have to imagine the result. A 10-line richer ASCII mockup (with the actual code snippet on the left side and a sketch of the card on the right) would close the gap. | −0.5 | Low-cost fix: replace lines 30-40 with a richer mockup. |
|
|
183
|
+
| D3 | §3 scenario table mentions "future scenario rotation" but §10 doesn't tie back to that. Minor consistency issue, not blocking. | −0.5 | One-line cross-reference would resolve. |
|
|
184
|
+
|
|
185
|
+
### Why 8/10 and not lower
|
|
186
|
+
|
|
187
|
+
The spec is a genuine working document. A designer or a model hand-rolling SVG could open it and produce something usable on a first attempt. The defects above are improvements, not blockers. None of the production paths in §6 are wrong — D1 is "the spec is under-opinionated," not "the spec is incorrect."
|
|
188
|
+
|
|
189
|
+
### Suggested follow-up
|
|
190
|
+
|
|
191
|
+
Fold D1 + D2 fixes into the next spec edit (before kicking off 7.6, not after). Cost: 5-10 min, no new plan row needed — they're micro-edits.
|
|
192
|
+
|
|
193
|
+
**Verdict:** ✅ PASS — spec is production-ready; could be sharper with two small revisions.
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1280 640" width="1280" height="640">
|
|
2
|
+
<defs>
|
|
3
|
+
<!-- Material elevation-4 shadow filter -->
|
|
4
|
+
<filter id="elevation4" x="-10%" y="-10%" width="130%" height="140%">
|
|
5
|
+
<feDropShadow dx="0" dy="4" stdDeviation="6" flood-color="#000" flood-opacity="0.16"/>
|
|
6
|
+
</filter>
|
|
7
|
+
<!-- Monospace font stack -->
|
|
8
|
+
<style>
|
|
9
|
+
@import url('https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500&family=Inter:wght@400;500;600&display=swap');
|
|
10
|
+
.mono { font-family: 'JetBrains Mono', 'Cascadia Code', 'Fira Code', 'Consolas', monospace; }
|
|
11
|
+
.sans { font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif; }
|
|
12
|
+
</style>
|
|
13
|
+
</defs>
|
|
14
|
+
|
|
15
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
16
|
+
<!-- TOP BAND — full width, 48px tall -->
|
|
17
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
18
|
+
<rect x="0" y="0" width="1280" height="48" fill="#0d0d14"/>
|
|
19
|
+
<!-- Monospace part -->
|
|
20
|
+
<text x="520" y="30" class="mono" font-size="16" fill="#8a8aa0" text-anchor="end">
|
|
21
|
+
<WBC :item="…" />
|
|
22
|
+
</text>
|
|
23
|
+
<!-- Separator dot -->
|
|
24
|
+
<text x="540" y="30" class="sans" font-size="14" fill="#4a4a5e" text-anchor="middle">·</text>
|
|
25
|
+
<!-- Sans-serif part -->
|
|
26
|
+
<text x="560" y="30" class="sans" font-size="14" fill="#6c6c80" text-anchor="start">
|
|
27
|
+
one component, real DOM
|
|
28
|
+
</text>
|
|
29
|
+
|
|
30
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
31
|
+
<!-- LEFT PANE — dark code editor background -->
|
|
32
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
33
|
+
<rect x="0" y="48" width="636" height="592" fill="#1e1e2e"/>
|
|
34
|
+
|
|
35
|
+
<!-- Subtle "WHAT YOU WRITE" label -->
|
|
36
|
+
<text x="40" y="88" class="sans" font-size="11" fill="#585870" font-weight="500" letter-spacing="1.5">
|
|
37
|
+
WHAT YOU WRITE
|
|
38
|
+
</text>
|
|
39
|
+
|
|
40
|
+
<!-- Code block — Scenario 4: JSON → VCard -->
|
|
41
|
+
<!-- Line 1: <WBC :item="{ -->
|
|
42
|
+
<text x="56" y="150" class="mono" font-size="16">
|
|
43
|
+
<tspan fill="#cba6f7"><</tspan><tspan fill="#89b4fa">WBC</tspan>
|
|
44
|
+
<tspan fill="#a6e3a1"> :item</tspan><tspan fill="#cdd6f4">=</tspan><tspan fill="#f9e2af">"</tspan><tspan fill="#cdd6f4">{</tspan>
|
|
45
|
+
</text>
|
|
46
|
+
|
|
47
|
+
<!-- Line 2: comp: 'VCard', -->
|
|
48
|
+
<text x="56" y="180" class="mono" font-size="16">
|
|
49
|
+
<tspan fill="#cdd6f4"> comp</tspan><tspan fill="#89b4fa">:</tspan>
|
|
50
|
+
<tspan fill="#f9e2af"> 'VCard'</tspan><tspan fill="#cdd6f4">,</tspan>
|
|
51
|
+
</text>
|
|
52
|
+
|
|
53
|
+
<!-- Line 3: options: { -->
|
|
54
|
+
<text x="56" y="210" class="mono" font-size="16">
|
|
55
|
+
<tspan fill="#cdd6f4"> options</tspan><tspan fill="#89b4fa">:</tspan>
|
|
56
|
+
<tspan fill="#cdd6f4"> {</tspan>
|
|
57
|
+
</text>
|
|
58
|
+
|
|
59
|
+
<!-- Line 4: props: { elevation: 4 }, -->
|
|
60
|
+
<text x="56" y="240" class="mono" font-size="16">
|
|
61
|
+
<tspan fill="#cdd6f4"> props</tspan><tspan fill="#89b4fa">:</tspan>
|
|
62
|
+
<tspan fill="#cdd6f4"> { </tspan><tspan fill="#cdd6f4">elevation</tspan><tspan fill="#89b4fa">:</tspan>
|
|
63
|
+
<tspan fill="#fab387"> 4</tspan><tspan fill="#cdd6f4"> },</tspan>
|
|
64
|
+
</text>
|
|
65
|
+
|
|
66
|
+
<!-- Line 5: html: '<h2>Q3 Revenue</h2> -->
|
|
67
|
+
<text x="56" y="270" class="mono" font-size="16">
|
|
68
|
+
<tspan fill="#cdd6f4"> html</tspan><tspan fill="#89b4fa">:</tspan>
|
|
69
|
+
<tspan fill="#f9e2af"> '<h2>Q3 Revenue</h2></tspan>
|
|
70
|
+
</text>
|
|
71
|
+
|
|
72
|
+
<!-- Line 6: <p>+24% YoY</p>', -->
|
|
73
|
+
<text x="56" y="300" class="mono" font-size="16">
|
|
74
|
+
<tspan fill="#f9e2af"> <p>+24% YoY</p>'</tspan><tspan fill="#cdd6f4">,</tspan>
|
|
75
|
+
</text>
|
|
76
|
+
|
|
77
|
+
<!-- Line 7: class: 'pa-4' -->
|
|
78
|
+
<text x="56" y="330" class="mono" font-size="16">
|
|
79
|
+
<tspan fill="#cdd6f4"> class</tspan><tspan fill="#89b4fa">:</tspan>
|
|
80
|
+
<tspan fill="#f9e2af"> 'pa-4'</tspan>
|
|
81
|
+
</text>
|
|
82
|
+
|
|
83
|
+
<!-- Line 8: } -->
|
|
84
|
+
<text x="56" y="360" class="mono" font-size="16">
|
|
85
|
+
<tspan fill="#cdd6f4"> }</tspan>
|
|
86
|
+
</text>
|
|
87
|
+
|
|
88
|
+
<!-- Line 9: }" /> -->
|
|
89
|
+
<text x="56" y="390" class="mono" font-size="16">
|
|
90
|
+
<tspan fill="#cdd6f4"> }</tspan><tspan fill="#f9e2af">"</tspan>
|
|
91
|
+
<tspan fill="#cdd6f4"> </tspan><tspan fill="#cba6f7">/></tspan>
|
|
92
|
+
</text>
|
|
93
|
+
|
|
94
|
+
<!-- Line numbers (subtle) -->
|
|
95
|
+
<text x="40" y="150" class="mono" font-size="12" fill="#45475a" text-anchor="end">1</text>
|
|
96
|
+
<text x="40" y="180" class="mono" font-size="12" fill="#45475a" text-anchor="end">2</text>
|
|
97
|
+
<text x="40" y="210" class="mono" font-size="12" fill="#45475a" text-anchor="end">3</text>
|
|
98
|
+
<text x="40" y="240" class="mono" font-size="12" fill="#45475a" text-anchor="end">4</text>
|
|
99
|
+
<text x="40" y="270" class="mono" font-size="12" fill="#45475a" text-anchor="end">5</text>
|
|
100
|
+
<text x="40" y="300" class="mono" font-size="12" fill="#45475a" text-anchor="end">6</text>
|
|
101
|
+
<text x="40" y="330" class="mono" font-size="12" fill="#45475a" text-anchor="end">7</text>
|
|
102
|
+
<text x="40" y="360" class="mono" font-size="12" fill="#45475a" text-anchor="end">8</text>
|
|
103
|
+
<text x="40" y="390" class="mono" font-size="12" fill="#45475a" text-anchor="end">9</text>
|
|
104
|
+
|
|
105
|
+
<!-- Subtle filename tab -->
|
|
106
|
+
<rect x="56" y="105" width="130" height="26" rx="4" fill="#313244"/>
|
|
107
|
+
<text x="70" y="122" class="mono" font-size="11" fill="#89b4fa">App.vue</text>
|
|
108
|
+
<circle cx="172" cy="118" r="3" fill="#45475a"/>
|
|
109
|
+
|
|
110
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
111
|
+
<!-- CENTRE DIVIDER — line + arrow -->
|
|
112
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
113
|
+
<line x1="640" y1="48" x2="640" y2="640" stroke="#3b3b4f" stroke-width="1"/>
|
|
114
|
+
|
|
115
|
+
<!-- Arrow circle at vertical centre -->
|
|
116
|
+
<circle cx="640" cy="344" r="18" fill="#1976D2"/>
|
|
117
|
+
<text x="640" y="351" class="sans" font-size="20" fill="#ffffff" text-anchor="middle" font-weight="600">→</text>
|
|
118
|
+
|
|
119
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
120
|
+
<!-- RIGHT PANE — light Material surface -->
|
|
121
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
122
|
+
<rect x="644" y="48" width="636" height="592" fill="#f5f5f5"/>
|
|
123
|
+
|
|
124
|
+
<!-- Subtle "WHAT GETS RENDERED" label -->
|
|
125
|
+
<text x="680" y="88" class="sans" font-size="11" fill="#9e9e9e" font-weight="500" letter-spacing="1.5">
|
|
126
|
+
WHAT GETS RENDERED
|
|
127
|
+
</text>
|
|
128
|
+
|
|
129
|
+
<!-- Material VCard — centred in right pane -->
|
|
130
|
+
<!-- Card background with elevation-4 shadow -->
|
|
131
|
+
<rect x="832" y="264" width="280" height="160" rx="8" fill="#ffffff" filter="url(#elevation4)"/>
|
|
132
|
+
|
|
133
|
+
<!-- Card inner padding area -->
|
|
134
|
+
<!-- Title: Q3 Revenue -->
|
|
135
|
+
<text x="856" y="308" class="sans" font-size="24" fill="#212121" font-weight="600">
|
|
136
|
+
Q3 Revenue
|
|
137
|
+
</text>
|
|
138
|
+
|
|
139
|
+
<!-- Divider line inside card -->
|
|
140
|
+
<line x1="856" y1="320" x2="1088" y2="320" stroke="#e0e0e0" stroke-width="1"/>
|
|
141
|
+
|
|
142
|
+
<!-- Body: +24% YoY with up arrow -->
|
|
143
|
+
<text x="856" y="368" class="sans" font-size="32" fill="#43A047" font-weight="600">
|
|
144
|
+
<tspan fill="#66BB6A" font-size="18">▲ </tspan>+24% YoY
|
|
145
|
+
</text>
|
|
146
|
+
|
|
147
|
+
<!-- Subtle "Vuetify Material" badge below the card -->
|
|
148
|
+
<rect x="906" y="440" width="130" height="24" rx="12" fill="#e8eaf6"/>
|
|
149
|
+
<text x="971" y="456" class="sans" font-size="10" fill="#5c6bc0" text-anchor="middle" font-weight="500">
|
|
150
|
+
Vuetify · Material UI
|
|
151
|
+
</text>
|
|
152
|
+
|
|
153
|
+
<!-- Browser chrome hint — dots in top-right corner -->
|
|
154
|
+
<circle cx="700" cy="118" r="5" fill="#e0e0e0"/>
|
|
155
|
+
<circle cx="716" cy="118" r="5" fill="#e0e0e0"/>
|
|
156
|
+
<circle cx="732" cy="118" r="5" fill="#e0e0e0"/>
|
|
157
|
+
<!-- URL bar hint -->
|
|
158
|
+
<rect x="750" y="112" width="180" height="12" rx="6" fill="#eeeeee"/>
|
|
159
|
+
<text x="840" y="122" class="mono" font-size="8" fill="#9e9e9e" text-anchor="middle">localhost:5173</text>
|
|
160
|
+
|
|
161
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
162
|
+
<!-- OUTER BORDER (1px, spec §7 dark-mode safe) -->
|
|
163
|
+
<!-- ═══════════════════════════════════════════ -->
|
|
164
|
+
<rect x="0" y="0" width="1280" height="640" rx="0" fill="none" stroke="#2a2a3c" stroke-width="1"/>
|
|
165
|
+
</svg>
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 560 70" width="560" height="70">
|
|
2
|
+
<defs>
|
|
3
|
+
<linearGradient id="free" x1="0" y1="0" x2="1" y2="0">
|
|
4
|
+
<stop offset="0%" stop-color="#43A047"/>
|
|
5
|
+
<stop offset="100%" stop-color="#66BB6A"/>
|
|
6
|
+
</linearGradient>
|
|
7
|
+
<linearGradient id="pro" x1="0" y1="0" x2="1" y2="0">
|
|
8
|
+
<stop offset="0%" stop-color="#7B1FA2"/>
|
|
9
|
+
<stop offset="100%" stop-color="#AB47BC"/>
|
|
10
|
+
</linearGradient>
|
|
11
|
+
</defs>
|
|
12
|
+
|
|
13
|
+
<!-- Free badge -->
|
|
14
|
+
<rect x="0" y="0" width="270" height="70" rx="10" fill="url(#free)"/>
|
|
15
|
+
<text x="135" y="28" text-anchor="middle" font-family="Arial,sans-serif" font-weight="900" font-size="18" fill="white">🆓 FREE</text>
|
|
16
|
+
<text x="135" y="48" text-anchor="middle" font-family="Arial,sans-serif" font-weight="600" font-size="11" fill="#C8E6C9">Builder · 3 hooks · 10 depth</text>
|
|
17
|
+
<text x="135" y="63" text-anchor="middle" font-family="Arial,sans-serif" font-size="9" fill="#A5D6A7">Render everything. Publish anywhere.</text>
|
|
18
|
+
|
|
19
|
+
<!-- Arrow -->
|
|
20
|
+
<text x="280" y="42" text-anchor="middle" font-size="20" fill="#64748B">→</text>
|
|
21
|
+
|
|
22
|
+
<!-- Pro badge -->
|
|
23
|
+
<rect x="290" y="0" width="270" height="70" rx="10" fill="url(#pro)"/>
|
|
24
|
+
<text x="425" y="28" text-anchor="middle" font-family="Arial,sans-serif" font-weight="900" font-size="18" fill="white">💎 PRO</text>
|
|
25
|
+
<text x="425" y="48" text-anchor="middle" font-family="Arial,sans-serif" font-weight="600" font-size="11" fill="#E1BEE7">Architect · 7 hooks · Unlimited</text>
|
|
26
|
+
<text x="425" y="63" text-anchor="middle" font-family="Arial,sans-serif" font-size="9" fill="#CE93D8">Command states. Extract everything.</text>
|
|
27
|
+
</svg>
|
package/dist/build-info.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@wbc-ui/core2",
|
|
3
|
-
"version": "1.0.0-
|
|
3
|
+
"version": "1.0.0-r07",
|
|
4
4
|
"description": "Advanced Dynamic UI Engine for Vue 2 — Part of the @wbc-ui ecosystem",
|
|
5
5
|
"author": "Wissem Boughamoura <wissemb11@gmail.com> (https://www.wi-bg.com)",
|
|
6
6
|
"homepage": "https://wbc-ui.com",
|
|
@@ -30,6 +30,7 @@
|
|
|
30
30
|
"README.md",
|
|
31
31
|
"LICENSE",
|
|
32
32
|
"logo/",
|
|
33
|
+
"assets/",
|
|
33
34
|
"vite-plugin.mjs",
|
|
34
35
|
"wbc.webpack.js"
|
|
35
36
|
],
|