@groeponline/pi-wishcraft 1.1.0 → 1.2.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/CHANGELOG.md +13 -0
- package/README.md +16 -7
- package/ROADMAP.md +41 -260
- package/docs/commands.md +6 -2
- package/docs/configuration.md +21 -0
- package/docs/design/accessibility.md +71 -0
- package/docs/design/deck-layout.md +69 -0
- package/docs/design/motion-gallery.md +80 -0
- package/docs/design/motion-system.md +119 -0
- package/docs/design/presets.md +196 -0
- package/docs/design/regression-testing.md +54 -0
- package/docs/design/responsive.md +53 -0
- package/docs/design/signal.md +68 -0
- package/docs/design/theme-contract.md +132 -0
- package/docs/design/vnext-overview.md +55 -0
- package/docs/design/vnext-release-plan.md +212 -0
- package/docs/index.md +19 -1
- package/docs/segments.md +1 -1
- package/package.json +2 -1
- package/src/config/appearance.ts +230 -0
- package/src/config/parse.ts +41 -0
- package/src/config/presets.ts +184 -0
- package/src/config/structural-presets.ts +555 -0
- package/src/config/tokens.ts +154 -0
- package/src/config/types.ts +210 -2
- package/src/extension/commands/commands.ts +36 -12
- package/src/extension/commands/powerline-completions.ts +4 -0
- package/src/extension/commands/queue-commands.ts +6 -0
- package/src/extension/core/segment-context.ts +7 -1
- package/src/extension/core/state.ts +14 -0
- package/src/extension/core/types.ts +7 -0
- package/src/extension/session/session-lifecycle.ts +20 -0
- package/src/extension/settings/appearance-write.ts +135 -0
- package/src/extension/settings/wishcraft-config-items.ts +119 -0
- package/src/extension/settings/wishcraft-config.ts +28 -114
- package/src/extension/skills/skill-manager.ts +5 -0
- package/src/extension/ui/deck/component.ts +358 -0
- package/src/extension/ui/deck/index.ts +34 -0
- package/src/extension/ui/deck/render.ts +260 -0
- package/src/extension/ui/deck/route-bodies.ts +209 -0
- package/src/extension/ui/deck/routes.ts +37 -0
- package/src/extension/ui/deck/session-snapshot.ts +104 -0
- package/src/extension/ui/deck/types.ts +92 -0
- package/src/extension/ui/powerline-menu-view.ts +19 -15
- package/src/extension/ui/signal-layout.ts +77 -0
- package/src/extension/ui/status-line-renderers.ts +20 -2
- package/src/motion/accessibility.ts +59 -0
- package/src/motion/catalog-extra.ts +429 -0
- package/src/motion/catalog.ts +336 -0
- package/src/motion/composer.ts +147 -0
- package/src/motion/frames.ts +84 -0
- package/src/motion/gallery.ts +77 -0
- package/src/motion/index.ts +78 -0
- package/src/motion/policy.ts +128 -0
- package/src/motion/scheduler.ts +159 -0
- package/src/motion/types.ts +132 -0
- package/src/render/timer.ts +1 -0
- package/src/signal/controller.ts +123 -0
- package/src/signal/integration.ts +42 -0
- package/src/signal/render.ts +178 -0
- package/src/theme/detect.ts +48 -0
- package/src/theme/tokens/index.ts +9 -0
- package/src/theme/tokens/mapping.ts +62 -0
- package/src/theme/tokens/types.ts +39 -0
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
# Motion Gallery & Composer Specification
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
The **Motion Gallery** provides an interactive catalog of animations categorized across curated styles. The **Motion Composer** allows developers and power users to author, preview, and assign custom motion definitions directly inside the terminal interface.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Gallery Categories
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
╭─ Motion Gallery ─────────────────────────────────────────────────────────────╮
|
|
13
|
+
│ / Search motions (e.g. "lunar", "sweep", "ember") │
|
|
14
|
+
├──────────────────────────────────────────────────────────────────────────────┤
|
|
15
|
+
│ Wishcraft Matrix Procedural Classic Custom │
|
|
16
|
+
│ │
|
|
17
|
+
│ ◈ Ember Relay ∞ Lemniscate ⠿ Helix Phase ⠋ Braille ✦ User-1 │
|
|
18
|
+
│ ◇ Wisp Drift ◎ Lunar Orbit ≋ Wave Stream ◐ Quarter │
|
|
19
|
+
│ ✦ Sigil Bloom △ Wing Pulse ⡿ Orbital Spin ▏ Bar Fill │
|
|
20
|
+
│ ⬡ Heat Propagate ✧ Petal Shimmer ≋ Ripple Surface ● Bounce │
|
|
21
|
+
├──────────────────────────────────────────────────────────────────────────────┤
|
|
22
|
+
│ PREVIEW: │
|
|
23
|
+
│ │
|
|
24
|
+
│ ━━━━━━╾✦╼━━━━━━━━━━━━━ │
|
|
25
|
+
│ → 90ms │
|
|
26
|
+
│ │
|
|
27
|
+
│ Channels: [✓] Working Glyph [✓] Signal Track [ ] Transient [✓] Task │
|
|
28
|
+
├──────────────────────────────────────────────────────────────────────────────┤
|
|
29
|
+
│ Space Play/Pause E Edit in Composer D Duplicate F Favorite Enter Apply│
|
|
30
|
+
╰──────────────────────────────────────────────────────────────────────────────╯
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
### 1. Wishcraft (Signature Metaphors)
|
|
34
|
+
- `ember-relay`: Traveling spark across segmented track.
|
|
35
|
+
- `wisp-drift`: Subtle breathing glyph with gentle phase oscillation.
|
|
36
|
+
- `sigil-bloom`: Expanding concentric geometry that settles upon completion.
|
|
37
|
+
- `heat-propagate`: Thermal matrix diffusion across block elements.
|
|
38
|
+
|
|
39
|
+
### 2. Matrix (Geometrical & Celestial)
|
|
40
|
+
- `lemniscate`: Infinity figure-eight traversal.
|
|
41
|
+
- `lunar-orbit`: Sinusoidal orbital node path.
|
|
42
|
+
- `wing-pulse`: Dual metronome oscillation.
|
|
43
|
+
- `petal-shimmer`: Expanding and contracting radial points.
|
|
44
|
+
|
|
45
|
+
### 3. Procedural (Fluid & Wave Mechanics)
|
|
46
|
+
- `helix-phase`: Intertwined dual-strand cycle.
|
|
47
|
+
- `wave-stream`: Progressive sine wave amplitude sweep.
|
|
48
|
+
- `ripple-surface`: Concentric wavefront propagation.
|
|
49
|
+
|
|
50
|
+
### 4. Classic (Reliable Terminal Spinners)
|
|
51
|
+
- `braille-cycle`: Canonical 8-dot Braille loop (`⠋⠙⠹⠸⠼⠴⠦⠧⠇⠏`).
|
|
52
|
+
- `quarter-circle`: Rotating four-quadrant glyphs (`◐◓◑◒`).
|
|
53
|
+
- `bar-fill`: Smooth horizontal bar progression (`▏▎▍▌▋▊▉█`).
|
|
54
|
+
|
|
55
|
+
---
|
|
56
|
+
|
|
57
|
+
## Motion Composer
|
|
58
|
+
|
|
59
|
+
The Composer enables real-time parameter tweaking and frame array authoring:
|
|
60
|
+
|
|
61
|
+
```
|
|
62
|
+
╭─ Motion Composer: Ember Relay ───────────────────────────────────────────────╮
|
|
63
|
+
│ TIMELINE │
|
|
64
|
+
│ 0ms 90ms 180ms 270ms 360ms │
|
|
65
|
+
│ ├───◇──────────├───◈──────────├───◆──────────├───◈──────────├───◇────────────│
|
|
66
|
+
│ │
|
|
67
|
+
│ PARAMETERS │
|
|
68
|
+
│ Geometry: Linear Track (1D) │
|
|
69
|
+
│ Interval: 90 ms │
|
|
70
|
+
│ Direction: Forward (→) │
|
|
71
|
+
│ Easing: Sinusoidal Pulse │
|
|
72
|
+
│ Color Role: motionHot (#fbbf24) │
|
|
73
|
+
│ Fallback Glyph: ◆ │
|
|
74
|
+
│ │
|
|
75
|
+
│ ASSIGNED CHANNELS │
|
|
76
|
+
│ [*] Working Glyph [*] Signal Track [ ] Border [*] Task Status │
|
|
77
|
+
├──────────────────────────────────────────────────────────────────────────────┤
|
|
78
|
+
│ Ctrl+S Save Tab Next Field Space Test Esc Discard │
|
|
79
|
+
╰──────────────────────────────────────────────────────────────────────────────╯
|
|
80
|
+
```
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
# Semantic Motion Engine & Scheduler
|
|
2
|
+
|
|
3
|
+
## Architectural Invariants
|
|
4
|
+
|
|
5
|
+
1. **Centralized Dispatch**: Components never launch ad-hoc `setInterval()` loops. All rendering cadences are driven by a single `MotionScheduler`.
|
|
6
|
+
2. **0 FPS Idle Guarantee**: When no animations or active consumers exist, timers are torn down completely. CPU usage is strictly 0%.
|
|
7
|
+
3. **Semantic Event Driven**: Animations are triggered by semantic agent lifecycle events (`streaming`, `tool.start`, `policy.deny`), not arbitrary frame tickers.
|
|
8
|
+
4. **Pure Function Calculations**: Motion algorithms, frame interpolations, and physics math are pure, unit-testable functions independent of the TUI renderer.
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## Semantic Motion Events
|
|
13
|
+
|
|
14
|
+
```typescript
|
|
15
|
+
export type MotionEvent =
|
|
16
|
+
| "idle" // System at rest
|
|
17
|
+
| "thinking" // Agent formulating response
|
|
18
|
+
| "streaming" // Token output active
|
|
19
|
+
| "tool.start" // Invoking external tool
|
|
20
|
+
| "tool.end" // Tool execution resolved
|
|
21
|
+
| "idea.capture" // Intent/Idea logged to deck
|
|
22
|
+
| "skill.insert" // Skill inserted into editor
|
|
23
|
+
| "policy.deny" // Action blocked by guardrail
|
|
24
|
+
| "repair" // Healing or recovering from error
|
|
25
|
+
| "compact" // Context window compaction
|
|
26
|
+
| "success" // Task completed successfully
|
|
27
|
+
| "warning" // Approaching threshold/warning
|
|
28
|
+
| "error"; // Exception or fatal failure
|
|
29
|
+
```
|
|
30
|
+
|
|
31
|
+
---
|
|
32
|
+
|
|
33
|
+
## Output Channels & Event Routing Matrix
|
|
34
|
+
|
|
35
|
+
There are six independent visual output channels:
|
|
36
|
+
- **`workingGlyph`**: Spinner or working status glyph in the prompt / header.
|
|
37
|
+
- **`signal`**: Animated track in the powerline.
|
|
38
|
+
- **`deckTransient`**: Ephemeral banner or toast inside the Deck overlay.
|
|
39
|
+
- **`panelIndicator`**: Localized progress indicator in active sub-panels.
|
|
40
|
+
- **`borderEmphasis`**: Transient glow or color pulse along outer frame borders.
|
|
41
|
+
- **`ambient`**: Subtle low-frequency breath when explicitly enabled.
|
|
42
|
+
|
|
43
|
+
```
|
|
44
|
+
┌───────────────┬──────────────┬──────────────┬───────────────┬─────────────────┬─────────────────┬───────────┐
|
|
45
|
+
│ EVENT │ WORKING GLYPH│ SIGNAL ANIM │ DECK TRANSIENT│ PANEL INDICATOR │ BORDER EMPHASIS │ AMBIENT │
|
|
46
|
+
├───────────────┼──────────────┼──────────────┼───────────────┼─────────────────┼─────────────────┼───────────┤
|
|
47
|
+
│ idle │ — │ — │ — │ — │ — │ ● (Opt) │
|
|
48
|
+
│ thinking │ ● Pulse │ ● Dim Sweep │ — │ — │ — │ — │
|
|
49
|
+
│ streaming │ ● Active │ ● Hot Sweep │ — │ ● Token Flow │ — │ — │
|
|
50
|
+
│ tool.start │ ● Working │ ● Segment Run│ — │ ● Tool Status │ — │ — │
|
|
51
|
+
│ tool.end │ — │ ● Settle │ — │ ● Checkmark │ — │ — │
|
|
52
|
+
│ idea.capture │ — │ — │ ● "+1 Idea" │ — │ — │ — │
|
|
53
|
+
│ skill.insert │ — │ ● Edge Jump │ ● Toast │ — │ — │ — │
|
|
54
|
+
│ policy.deny │ — │ — │ ● Blocked Card│ — │ ● Error Flash │ — │
|
|
55
|
+
│ repair │ ● Spinner │ — │ ● Recovery │ ● Diagnostic │ — │ — │
|
|
56
|
+
│ compact │ ● Compress │ ● Shrink Bar │ ● Compact Msg │ ● Context Bar │ — │ — │
|
|
57
|
+
│ success │ — │ ● Bloom (Fin)│ ● Done Banner │ — │ ● Success Flash │ — │
|
|
58
|
+
│ warning │ — │ — │ ● Warning Card│ — │ ● Warn Flash │ — │
|
|
59
|
+
│ error │ — │ — │ ● Error Modal │ — │ ● Error Flash │ — │
|
|
60
|
+
└───────────────┴──────────────┴──────────────┴───────────────┴─────────────────┴─────────────────┴───────────┘
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
## Channel Cadences & Scheduler Design
|
|
66
|
+
|
|
67
|
+
Different visual elements operate at distinct frame rates to optimize visual clarity while conserving system resources:
|
|
68
|
+
|
|
69
|
+
| Channel | Target Cadence | Lifecycle |
|
|
70
|
+
| :--- | :--- | :--- |
|
|
71
|
+
| **`workingGlyph`** | `80ms – 120ms` per frame | Active while agent processes |
|
|
72
|
+
| **`signal` Sweep** | `80ms – 120ms` per frame | Active during stream / tool execution |
|
|
73
|
+
| **`panelIndicator`** | `120ms – 250ms` per frame | Active while sub-view is busy |
|
|
74
|
+
| **`borderEmphasis`** | `200ms – 400ms` total burst | Finite (1 to 3 frames) |
|
|
75
|
+
| **`deckTransient`** | `250ms – 500ms` total display | Finite auto-dismissing |
|
|
76
|
+
| **`ambient` Idle** | `250ms – 750ms` per frame | Runs only when explicitly opted-in |
|
|
77
|
+
|
|
78
|
+
### State Transition Diagram
|
|
79
|
+
|
|
80
|
+
```mermaid
|
|
81
|
+
stateDiagram-v2
|
|
82
|
+
[*] --> Idle: Initialize
|
|
83
|
+
Idle --> ActiveMotion: MotionEvent Received (streaming, tool.start)
|
|
84
|
+
ActiveMotion --> ActiveMotion: Tick registered consumers (80-120ms)
|
|
85
|
+
ActiveMotion --> FiniteBurst: Success / Error Event
|
|
86
|
+
FiniteBurst --> Idle: Burst Complete (no consumers)
|
|
87
|
+
Idle --> [*]: Dispose Scheduler (0 FPS)
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
---
|
|
91
|
+
|
|
92
|
+
## Motion Definition Schema (`MotionDef`)
|
|
93
|
+
|
|
94
|
+
Motions are defined declaratively as pure data structures:
|
|
95
|
+
|
|
96
|
+
```typescript
|
|
97
|
+
export interface MotionDef {
|
|
98
|
+
id: string;
|
|
99
|
+
name: string;
|
|
100
|
+
category: "wishcraft" | "matrix" | "procedural" | "classic" | "custom";
|
|
101
|
+
kind: "frames" | "generator";
|
|
102
|
+
loop: "while-active" | "finite" | "ambient";
|
|
103
|
+
colorRole: keyof WishcraftTokens;
|
|
104
|
+
fallbackGlyph: string;
|
|
105
|
+
|
|
106
|
+
// Discrete Frame Sequences
|
|
107
|
+
frames?: string[];
|
|
108
|
+
|
|
109
|
+
// Procedural Generator Specification
|
|
110
|
+
generator?: {
|
|
111
|
+
geometry: "linear" | "orbit" | "wave" | "bloom" | "liquid";
|
|
112
|
+
interval: number;
|
|
113
|
+
trailLength?: number;
|
|
114
|
+
radius?: number;
|
|
115
|
+
direction?: "forward" | "reverse" | "pingpong";
|
|
116
|
+
easing?: "linear" | "sinusoidal" | "exponential";
|
|
117
|
+
};
|
|
118
|
+
}
|
|
119
|
+
```
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
# Structural Presets Specification
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
Wishcraft introduces **ten signature structural presets**. A preset is not merely a color skin; it defines a complete design system combining:
|
|
6
|
+
1. **Token Palette**: Cohesive semantic colors.
|
|
7
|
+
2. **Chrome Geometry**: Frame borders, corners, divider styles, and density.
|
|
8
|
+
3. **Signal Grammar**: Lane structure, module capsules, separators, and caps.
|
|
9
|
+
4. **Glyph Grammar**: Curated Unicode and Nerd Font iconography with clean ASCII fallbacks.
|
|
10
|
+
5. **Signature Motion**: Procedural animations reflecting the preset's identity.
|
|
11
|
+
|
|
12
|
+
---
|
|
13
|
+
|
|
14
|
+
## The Ten Structural Presets
|
|
15
|
+
|
|
16
|
+
```
|
|
17
|
+
┌────────────────────────────────────────────────────────────────────────────────────────┐
|
|
18
|
+
│ PRESET CHARACTER SIGNAL STRUCTURE SIGNATURE MOTION │
|
|
19
|
+
├────────────────────────────────────────────────────────────────────────────────────────┤
|
|
20
|
+
│ 1. Lanternwake Warm Amber / Signature Dark Fluid Segments Ember Breathe │
|
|
21
|
+
│ 2. Threadbound Woven Craft / Indigo Thin Knot Wire Stitch Travel │
|
|
22
|
+
│ 3. Scryglass Refractive Glass / Cyan Capsule Lenses Refraction Sweep │
|
|
23
|
+
│ 4. Runebloom Organic Alchemical Sigils Sparse Anchors Sigil Bloom │
|
|
24
|
+
│ 5. Moonwell Nocturnal Orbit / Silver Arc Segments Lunar Breathe │
|
|
25
|
+
│ 6. Hexforge Heavy Industrial Steel Block Hexagons Heat Propagation │
|
|
26
|
+
│ 7. Vellum Editorial Grimoire Borderless Line Writing Reveal │
|
|
27
|
+
│ 8. Wisp Ethereal Minimalist Max Whitespace Phase Drift │
|
|
28
|
+
│ 9. Starweave Celestial Cartography Constellation Nodes Path Traversal │
|
|
29
|
+
│ 10. Crucible Alchemical Fluid / Magma Cell Meter Rise Liquid Surge │
|
|
30
|
+
└────────────────────────────────────────────────────────────────────────────────────────┘
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
---
|
|
34
|
+
|
|
35
|
+
### 1. Lanternwake (Default Signature Identity)
|
|
36
|
+
- **Concept**: Warm amber and glowing embers in a dark room. Grounded in Wishcraft's original lantern metaphor.
|
|
37
|
+
- **Tokens**:
|
|
38
|
+
- `primary`: `#f59e0b` (Warm Amber)
|
|
39
|
+
- `accent`: `#ea580c` (Ember Orange)
|
|
40
|
+
- `surface`: `#0f172a` (Deep Slate)
|
|
41
|
+
- `motionHot`: `#fbbf24` (Golden Flare)
|
|
42
|
+
- `motionTrail`: `#78350f` (Ember Ash)
|
|
43
|
+
- **Signal Grammar**:
|
|
44
|
+
```
|
|
45
|
+
◇ GPT-5.6 ━━━╾✦╼━━━━ main ━━━━━ read ━━━━━ ctx 47%
|
|
46
|
+
```
|
|
47
|
+
- **Motion**: `ember.breathe` — utilizes the mathematical formula from `renderLantern` ($\sin(t \times 1.1) + \sin(t \times 7.3)$) to pulse only during active events.
|
|
48
|
+
|
|
49
|
+
---
|
|
50
|
+
|
|
51
|
+
### 2. Threadbound
|
|
52
|
+
- **Concept**: Artisan tailoring and woven loom mechanics.
|
|
53
|
+
- **Tokens**:
|
|
54
|
+
- `primary`: `#6366f1` (Indigo Thread)
|
|
55
|
+
- `accent`: `#ec4899` (Magenta Stitch)
|
|
56
|
+
- `surface`: `#18181b` (Zinc Weave)
|
|
57
|
+
- **Signal Grammar**:
|
|
58
|
+
```
|
|
59
|
+
model ──╼·╾──── branch ──╼·╾──── tool ──╼◆╾── context
|
|
60
|
+
```
|
|
61
|
+
- **Motion**: `stitch.travel` — step pulse traveling smoothly across thread nodes.
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
### 3. Scryglass
|
|
66
|
+
- **Concept**: Precision optics, lenses, and refractive glass capsules.
|
|
67
|
+
- **Tokens**:
|
|
68
|
+
- `primary`: `#06b6d4` (Prism Cyan)
|
|
69
|
+
- `accent`: `#8b5cf6` (Lens Violet)
|
|
70
|
+
- `surface`: `#090d16` (Deep Glass)
|
|
71
|
+
- **Signal Grammar**:
|
|
72
|
+
```
|
|
73
|
+
╭ GPT-5.6 ╮────╭ main ╮────╭ read ╮────╭ 47% ╮
|
|
74
|
+
╰─────────╯ ╰──────╯ ╰──────╯ ╰─────╯
|
|
75
|
+
```
|
|
76
|
+
- **Motion**: `refraction.sweep` — light wave passing through each capsule sequentially.
|
|
77
|
+
|
|
78
|
+
---
|
|
79
|
+
|
|
80
|
+
### 4. Runebloom
|
|
81
|
+
- **Concept**: Ancient stone sigils bursting into life upon magic release.
|
|
82
|
+
- **Tokens**:
|
|
83
|
+
- `primary`: `#10b981` (Emerald Moss)
|
|
84
|
+
- `accent`: `#eab308` (Rune Gold)
|
|
85
|
+
- `surface`: `#0c140f` (Forest Granite)
|
|
86
|
+
- **Signal Grammar**:
|
|
87
|
+
```
|
|
88
|
+
◇ GPT-5.6 · main · read · 47%
|
|
89
|
+
```
|
|
90
|
+
- **Motion**: `bloom.on-event` — geometry expands outwardly on state changes, then stabilizes into quiet repose.
|
|
91
|
+
|
|
92
|
+
---
|
|
93
|
+
|
|
94
|
+
### 5. Moonwell
|
|
95
|
+
- **Concept**: Nocturnal sanctuary, silver light, and celestial orbits.
|
|
96
|
+
- **Tokens**:
|
|
97
|
+
- `primary`: `#94a3b8` (Moon Silver)
|
|
98
|
+
- `accent`: `#38bdf8` (Starlight Sky)
|
|
99
|
+
- `surface`: `#020617` (Midnight Black)
|
|
100
|
+
- **Signal Grammar**:
|
|
101
|
+
```
|
|
102
|
+
◜ GPT-5.6 ─── ◝ main ─── ◞ read ─── ◟ 47%
|
|
103
|
+
```
|
|
104
|
+
- **Motion**: `lunar.breathe` — smooth sinusoidal phase transitions echoing orbital mechanics.
|
|
105
|
+
|
|
106
|
+
---
|
|
107
|
+
|
|
108
|
+
### 6. Hexforge
|
|
109
|
+
- **Concept**: Heavy forge machinery, steel plating, and thermal conduits.
|
|
110
|
+
- **Tokens**:
|
|
111
|
+
- `primary`: `#f97316` (Forge Orange)
|
|
112
|
+
- `accent`: `#ef4444` (Molten Red)
|
|
113
|
+
- `surface`: `#1c1917` (Anvil Dark)
|
|
114
|
+
- **Signal Grammar**:
|
|
115
|
+
```
|
|
116
|
+
⬡ GPT-5.6 ▰▰ MAIN ▰▰ ◆ READ ▰▰ 47% ⬡
|
|
117
|
+
```
|
|
118
|
+
- **Motion**: `heat.propagate` — thermal wave advancing across block matrices (`█▓▒░`).
|
|
119
|
+
|
|
120
|
+
---
|
|
121
|
+
|
|
122
|
+
### 7. Vellum
|
|
123
|
+
- **Concept**: Modern editorial, typography, and calligraphic ink strokes.
|
|
124
|
+
- **Tokens**:
|
|
125
|
+
- `primary`: `#d97706` (Old Gold Ink)
|
|
126
|
+
- `accent`: `#a16207` (Deep Sepia)
|
|
127
|
+
- `surface`: `#1a1815` (Dark Parchment)
|
|
128
|
+
- **Signal Grammar**:
|
|
129
|
+
```
|
|
130
|
+
Wishcraft / GPT-5.6
|
|
131
|
+
──────────────────────────────────────╾ main · read · ctx 47%
|
|
132
|
+
```
|
|
133
|
+
- **Motion**: `writing.reveal` — rule line draws from left to right during streaming output.
|
|
134
|
+
|
|
135
|
+
---
|
|
136
|
+
|
|
137
|
+
### 8. Wisp
|
|
138
|
+
- **Concept**: Minimalist ethereal calm, generous negative space, pure essential information.
|
|
139
|
+
- **Tokens**:
|
|
140
|
+
- `primary`: `#cbd5e1` (Morning Mist)
|
|
141
|
+
- `accent`: `#38bdf8` (Ethereal Blue)
|
|
142
|
+
- `surface`: `#0b0f19` (Void Blue)
|
|
143
|
+
- **Signal Grammar**:
|
|
144
|
+
```
|
|
145
|
+
◌ GPT-5.6 main · read · 47%
|
|
146
|
+
```
|
|
147
|
+
- **Motion**: `phase.drift` — subtle, low-frequency opacity breathing.
|
|
148
|
+
|
|
149
|
+
---
|
|
150
|
+
|
|
151
|
+
### 9. Starweave
|
|
152
|
+
- **Concept**: Astrological star maps, navigational geometry, and connected constellations.
|
|
153
|
+
- **Tokens**:
|
|
154
|
+
- `primary`: `#a855f7` (Cosmic Purple)
|
|
155
|
+
- `accent`: `#38bdf8` (Nebula Cyan)
|
|
156
|
+
- `surface`: `#050515` (Deep Space)
|
|
157
|
+
- **Signal Grammar**:
|
|
158
|
+
```
|
|
159
|
+
✦ GPT-5.6 ───· main ·───◆ read ───✦ 47%
|
|
160
|
+
```
|
|
161
|
+
- **Motion**: `path.traverse` — stellar particle moving across intersecting coordinate edges.
|
|
162
|
+
|
|
163
|
+
---
|
|
164
|
+
|
|
165
|
+
### 10. Crucible
|
|
166
|
+
- **Concept**: Dynamic alchemical fluid levels, bubbling reactions, and exothermic changes.
|
|
167
|
+
- **Tokens**:
|
|
168
|
+
- `primary`: `#ec4899` (Alchemical Rose)
|
|
169
|
+
- `accent`: `#f43f5e` (Catalyst Crimson)
|
|
170
|
+
- `surface`: `#110b11` (Basalt Stone)
|
|
171
|
+
- **Signal Grammar**:
|
|
172
|
+
```
|
|
173
|
+
[▓▓▓ GPT-5.6] [▒▒ main] [░ read] [█ 47%]
|
|
174
|
+
```
|
|
175
|
+
- **Motion**: `liquid.rise` — cell density shifts dynamically in response to token consumption rates.
|
|
176
|
+
|
|
177
|
+
---
|
|
178
|
+
|
|
179
|
+
## Decoupled Customization Architecture
|
|
180
|
+
|
|
181
|
+
Presets represent harmonious default pairings, but Wishcraft allows complete independence across every dimension:
|
|
182
|
+
|
|
183
|
+
```
|
|
184
|
+
┌────────────────────────────────────────────────────────┐
|
|
185
|
+
│ User Custom Configuration │
|
|
186
|
+
│ │
|
|
187
|
+
│ Base Preset: Lanternwake │
|
|
188
|
+
│ Signal Layout: Threadbound │
|
|
189
|
+
│ Token Palette: Scryglass │
|
|
190
|
+
│ Working Motion: Lunar Breathe │
|
|
191
|
+
│ Tool Motion: Heat Propagate │
|
|
192
|
+
│ Frame Chrome: Vellum │
|
|
193
|
+
│ Glyph Set: Nerd Font (Full) │
|
|
194
|
+
└────────────────────────────────────────────────────────┘
|
|
195
|
+
```
|
|
196
|
+
No layer is locked; users can selectively override any aspect without fork or code changes.
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# Automated Regression Testing & TUI Quality Strategy
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
A polished terminal application requires strict regression testing across layout math, animation timelines, token calculations, and ANSI output correctness.
|
|
6
|
+
|
|
7
|
+
Wishcraft establishes a multi-tiered test strategy that verifies behavior without unstable end-to-end terminal dependencies.
|
|
8
|
+
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
## Testing Tiers
|
|
12
|
+
|
|
13
|
+
```
|
|
14
|
+
┌────────────────────────────────────────────────────────┐
|
|
15
|
+
│ 1. Pure Unit Tests (Fast, 100% Deterministic) │
|
|
16
|
+
│ - Token color mappings │
|
|
17
|
+
│ - Preset resolution & overrides │
|
|
18
|
+
│ - Motion frame calculations │
|
|
19
|
+
│ - Event router dispatch matrices │
|
|
20
|
+
└───────────────────────────┬────────────────────────────┘
|
|
21
|
+
│
|
|
22
|
+
┌───────────────────────────▼────────────────────────────┐
|
|
23
|
+
│ 2. Layout & String Geometry Tests │
|
|
24
|
+
│ - Grapheme cluster width calculation │
|
|
25
|
+
│ - Responsive breakpoint truncation │
|
|
26
|
+
│ - Box-drawing alignment & corner connections │
|
|
27
|
+
└───────────────────────────┬────────────────────────────┘
|
|
28
|
+
│
|
|
29
|
+
┌───────────────────────────▼────────────────────────────┐
|
|
30
|
+
│ 3. Snapshot & Golden Master Tests │
|
|
31
|
+
│ - ANSI escape sequence validation │
|
|
32
|
+
│ - 10 Preset layout golden snapshots │
|
|
33
|
+
│ - NO_COLOR and ASCII fallback exports │
|
|
34
|
+
└────────────────────────────────────────────────────────┘
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
## Test Automation Invariants
|
|
40
|
+
|
|
41
|
+
1. **No Headless TUI Requirement**: Core algorithms must never instantiate `ctx.ui` or direct terminal stdout in tests. Renderers emit plain string buffers or token trees.
|
|
42
|
+
2. **Deterministic Time Control**: The `MotionScheduler` accepts an injected virtual clock or step function for precise, millisecond-accurate timeline assertions.
|
|
43
|
+
3. **Circular Dependency Prevention**: Verified automatically on every build via `npx madge --circular src/`.
|
|
44
|
+
4. **Strict TypeScript Checking**: `tsc --noEmit` runs under strict mode with zero implicit `any`.
|
|
45
|
+
|
|
46
|
+
---
|
|
47
|
+
|
|
48
|
+
## Golden Test Fixtures
|
|
49
|
+
|
|
50
|
+
Every signature preset maintains a golden ANSI snapshot for standard viewport dimensions (`120x30`, `80x24`, `50x15`):
|
|
51
|
+
- `tests/fixtures/presets/lanternwake-120x30.snap`
|
|
52
|
+
- `tests/fixtures/presets/scryglass-80x24.snap`
|
|
53
|
+
- `tests/fixtures/presets/hexforge-no-color.snap`
|
|
54
|
+
- `tests/fixtures/presets/vellum-ascii-fallback.snap`
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
# Responsive Layout & Terminal Viewport Adaptations
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
Terminal viewports vary significantly across devices, window panes, and split layouts. Wishcraft dynamically responds to viewport width and height constraints through intelligent layout degradation.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Responsive Breakpoints
|
|
10
|
+
|
|
11
|
+
| Viewport Width | Class | Layout Strategy |
|
|
12
|
+
| :--- | :--- | :--- |
|
|
13
|
+
| **$\ge 120$ cols** | **Wide** | Full 3-column Deck (Nav + Main View + Sidebar) + Full 3-Lane Signal |
|
|
14
|
+
| **$80 - 119$ cols**| **Standard**| 2-column Deck (Nav + Main View) + Standard 3-Lane Signal |
|
|
15
|
+
| **$50 - 79$ cols** | **Compact** | 1-column Deck (Collapsible Nav) + Compressed 2-Lane Signal |
|
|
16
|
+
| **$< 50$ cols** | **Minimal** | Modal Stack Deck + Single-Lane Essential Status |
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## Signal Lane Degradation
|
|
21
|
+
|
|
22
|
+
```
|
|
23
|
+
Wide (120+ cols):
|
|
24
|
+
◆ GPT-5.6 ╾━━━━ main (clean) ━━━━╾✦╼━━━━ read_file: src/render/powerline.ts ━━━━━━━ ctx █████░ 47% (94k)
|
|
25
|
+
|
|
26
|
+
Standard (80-119 cols):
|
|
27
|
+
◆ GPT-5.6 ╾━━━━ main ━━━━╾✦╼━━━━ read_file ━━━━━━━ ctx 47%
|
|
28
|
+
|
|
29
|
+
Compact (50-79 cols):
|
|
30
|
+
◆ GPT-5.6 ── main ── read ── 47%
|
|
31
|
+
|
|
32
|
+
Minimal (< 50 cols):
|
|
33
|
+
◆ GPT-5.6 · 47%
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
---
|
|
37
|
+
|
|
38
|
+
## Deck Viewport Adaptations
|
|
39
|
+
|
|
40
|
+
1. **Wide Viewport ($\ge 120$ cols)**:
|
|
41
|
+
- Navigation pane (20% width)
|
|
42
|
+
- Route workspace (55% width)
|
|
43
|
+
- Activity feed & health sidebar (25% width)
|
|
44
|
+
2. **Standard Viewport ($80 - 119$ cols)**:
|
|
45
|
+
- Sidebar collapses into tabbed secondary panes.
|
|
46
|
+
- Main workspace expands to utilize 75% width.
|
|
47
|
+
3. **Compact Viewport ($50 - 79$ cols)**:
|
|
48
|
+
- Top-level route icons replace full text navigation.
|
|
49
|
+
- Main workspace occupies full width.
|
|
50
|
+
- Jump shortcuts remain fully active.
|
|
51
|
+
4. **Vertical Constraints ($< 24$ rows)**:
|
|
52
|
+
- Ambient header and footer padding are compacted to single rows.
|
|
53
|
+
- Activity stream truncates to most recent 2 events.
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
# Signal — The Animated Powerline Specification
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
**Signal** is Wishcraft's animated powerline. While previous terminal footers were static rows of plain text, Signal turns status into an informative, living track.
|
|
6
|
+
|
|
7
|
+
- **Primary Command**: `/signal` (opens the Signal configuration deck or toggles view modes).
|
|
8
|
+
- **Compatibility Alias**: `/powerline` (retained for backward compatibility).
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## 3-Lane Architecture
|
|
13
|
+
|
|
14
|
+
Signal divides status information into three distinct, customizable lanes:
|
|
15
|
+
|
|
16
|
+
```
|
|
17
|
+
┌──────────────────────────────────────────────────────────────────────────────────┐
|
|
18
|
+
│ LEFT LANE CENTER LANE RIGHT LANE │
|
|
19
|
+
│ Model · Git Status Live Activity & Tools Context · Queue │
|
|
20
|
+
├──────────────────────────────┼──────────────────────────────┼────────────────────┤
|
|
21
|
+
│ ◆ GPT-5.6 ╾━━━━ main ━━━━ │ ╾✦╼━━━━ read_file ━━━━━━━ │ ctx █████░ 47% │
|
|
22
|
+
└──────────────────────────────┴──────────────────────────────┴────────────────────┘
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
1. **Left Lane (Identity & Workspace)**
|
|
26
|
+
- Active Model badge (with provider color accent)
|
|
27
|
+
- Git branch and repository clean/dirty status
|
|
28
|
+
- Workspace directory (truncated gracefully on compact displays)
|
|
29
|
+
|
|
30
|
+
2. **Center Lane (Live Activity & Motion)**
|
|
31
|
+
- Current agent state (Thinking, Streaming, Tool Execution)
|
|
32
|
+
- Active tool call indicator (`read_file`, `grep`, `execute_command`)
|
|
33
|
+
- Traveling motion pulse representing data throughput
|
|
34
|
+
|
|
35
|
+
3. **Right Lane (Metrics & Session)**
|
|
36
|
+
- Context window progress bar and percentage
|
|
37
|
+
- Queued user/agent instructions count
|
|
38
|
+
- Session cost / token consumption (if enabled)
|
|
39
|
+
|
|
40
|
+
---
|
|
41
|
+
|
|
42
|
+
## Live Motion Sweeps
|
|
43
|
+
|
|
44
|
+
Signal animates only when actual work is being processed. The track reflects execution states through traveling pulses:
|
|
45
|
+
|
|
46
|
+
### Token Streaming Wave
|
|
47
|
+
```
|
|
48
|
+
t0: ◆ GPT-5.6 ╾▓▒░━━━━ main ━━━━━━━━━ read ━━━━━━━━━ ctx 47%
|
|
49
|
+
t1: ◆ GPT-5.6 ━╾▓▒░━━━ main ━━━━━━━━━ read ━━━━━━━━━ ctx 47%
|
|
50
|
+
t2: ◆ GPT-5.6 ━━━╾▓▒░━ main ━━━━━━━━━ read ━━━━━━━━━ ctx 47%
|
|
51
|
+
t3: ◆ GPT-5.6 ━━━━━━━━ main ╾▓▒░━━━━━ read ━━━━━━━━━ ctx 47%
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### Tool Execution Traveling Pulse
|
|
55
|
+
```
|
|
56
|
+
t0: read ━━━╾✦╼━━━ grep ━━━━━━━━━ edit ━━━━━━━━━
|
|
57
|
+
t1: read ✓ ━━━━━━━ grep ━━━╾✦╼━━━ edit ━━━━━━━━━
|
|
58
|
+
t2: read ✓ ━━━━━━━ grep ✓ ━━━━━━━ edit ━━━╾✦╼━━━
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
---
|
|
62
|
+
|
|
63
|
+
## Fault Isolation & Error Boundaries
|
|
64
|
+
|
|
65
|
+
Signal builds on Pi-Wishcraft's existing segment architecture:
|
|
66
|
+
- Every segment executes in an isolated `try/catch` wrapper.
|
|
67
|
+
- If an individual segment fails (e.g. git command timeout or unexpected API response), it degrades gracefully to a silent fallback or a compact warning glyph without crashing the surrounding status line.
|
|
68
|
+
- Segment separators adjust dynamically when neighboring segments are hidden or empty.
|