clikit-plugin 0.2.28 → 0.2.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +30 -32
- package/README.md +45 -26
- package/command/create.md +37 -122
- package/command/handoff.md +45 -69
- package/command/init.md +125 -48
- package/command/plan.md +101 -159
- package/command/research.md +1 -1
- package/command/resume.md +34 -55
- package/command/vision.md +132 -64
- package/dist/.tsbuildinfo +1 -0
- package/dist/agents/index.d.ts.map +1 -1
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +95 -11
- package/dist/clikit.schema.json +245 -0
- package/dist/commands/index.d.ts.map +1 -1
- package/dist/config.d.ts +43 -43
- package/dist/config.d.ts.map +1 -1
- package/dist/hooks/git-guard.test.d.ts +2 -0
- package/dist/hooks/git-guard.test.d.ts.map +1 -0
- package/dist/hooks/index.d.ts +3 -14
- package/dist/hooks/index.d.ts.map +1 -1
- package/dist/hooks/memory-digest.d.ts +27 -0
- package/dist/hooks/memory-digest.d.ts.map +1 -0
- package/dist/hooks/security-check.test.d.ts +2 -0
- package/dist/hooks/security-check.test.d.ts.map +1 -0
- package/dist/hooks/todo-beads-sync.d.ts +23 -0
- package/dist/hooks/todo-beads-sync.d.ts.map +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +740 -909
- package/dist/skills/index.d.ts.map +1 -1
- package/dist/tools/beads-memory-sync.d.ts.map +1 -1
- package/dist/tools/context-summary.d.ts.map +1 -1
- package/dist/tools/memory-db.d.ts +12 -0
- package/dist/tools/memory-db.d.ts.map +1 -0
- package/dist/tools/memory.d.ts.map +1 -1
- package/dist/tools/observation.d.ts.map +1 -1
- package/memory/_templates/plan.md +18 -0
- package/package.json +7 -4
- package/src/agents/AGENTS.md +11 -39
- package/src/agents/build.md +152 -94
- package/src/agents/index.ts +31 -5
- package/src/agents/looker.md +5 -0
- package/src/agents/oracle.md +2 -0
- package/src/agents/plan.md +247 -44
- package/src/agents/review.md +1 -0
- package/src/agents/vision.md +251 -115
- package/dist/cli.test.d.ts +0 -2
- package/dist/cli.test.d.ts.map +0 -1
- package/dist/hooks/auto-format.d.ts +0 -30
- package/dist/hooks/auto-format.d.ts.map +0 -1
- package/dist/hooks/comment-checker.d.ts +0 -17
- package/dist/hooks/comment-checker.d.ts.map +0 -1
- package/dist/hooks/compaction.d.ts +0 -60
- package/dist/hooks/compaction.d.ts.map +0 -1
- package/dist/hooks/env-context.d.ts +0 -43
- package/dist/hooks/env-context.d.ts.map +0 -1
- package/dist/hooks/ritual-enforcer.d.ts +0 -29
- package/dist/hooks/ritual-enforcer.d.ts.map +0 -1
- package/dist/hooks/session-notification.d.ts +0 -23
- package/dist/hooks/session-notification.d.ts.map +0 -1
- package/dist/hooks/session-notification.test.d.ts +0 -2
- package/dist/hooks/session-notification.test.d.ts.map +0 -1
- package/dist/hooks/typecheck-gate.d.ts +0 -31
- package/dist/hooks/typecheck-gate.d.ts.map +0 -1
- package/memory/handoffs/2026-02-15-complete-audit.md +0 -136
- package/memory/handoffs/2026-02-15-complete-fix.md +0 -140
- package/memory/handoffs/2026-02-15-importmeta-fix.md +0 -121
- package/memory/handoffs/2026-02-15-installing.md +0 -90
- package/memory/handoffs/2026-02-15-plugin-install-fix.md +0 -140
- package/memory/handoffs/2026-02-15-runtime-fixes.md +0 -80
- package/memory/plans/2026-02-16-plugin-install.md +0 -195
- package/memory/research/2026-02-16-opencode-plugin-alignment.md +0 -128
package/src/agents/vision.md
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
description:
|
|
2
|
+
description: Design architect + visual implementer. Prompt-to-UI pipeline with variant exploration, image-to-code, iterative refinement. Inspired by Google Stitch and Amp Painter.
|
|
3
3
|
mode: subagent
|
|
4
4
|
model: proxypal/gemini-3-pro
|
|
5
5
|
temperature: 0.4
|
|
@@ -14,146 +14,282 @@ permission:
|
|
|
14
14
|
|
|
15
15
|
# Vision Agent
|
|
16
16
|
|
|
17
|
-
You are the Vision Agent
|
|
17
|
+
You are the Vision Agent — a design architect who turns prompts, sketches, and screenshots into production-quality UI. You combine Stitch-style variant exploration with Painter-style visual generation and pixel-perfect code execution.
|
|
18
18
|
|
|
19
|
-
|
|
19
|
+
**YOU DESIGN AND IMPLEMENT. You don't plan features or write backend code.**
|
|
20
20
|
|
|
21
|
-
|
|
21
|
+
Capabilities: Image analysis (multimodal), visual design, code generation, component architecture, design system creation, CSS/styling, responsive layouts, accessibility, animation
|
|
22
22
|
|
|
23
|
-
|
|
24
|
-
2. CSS/Styling Implementation: Write clean, maintainable stylesheets (CSS, SCSS, Tailwind, CSS-in-JS)
|
|
25
|
-
3. Component Building: Create reusable UI components with proper props, slots, variants
|
|
26
|
-
4. Responsive Layouts: Implement layouts that work across breakpoints and devices
|
|
27
|
-
5. Design System Maintenance: Tokens, variables, theme configuration, component libraries
|
|
28
|
-
6. Animation & Motion: Transitions, keyframes, scroll-driven animations, micro-interactions
|
|
29
|
-
7. Accessibility: ARIA attributes, focus management, color contrast, screen reader support
|
|
23
|
+
## Phase 0: Input Classification (EVERY REQUEST)
|
|
30
24
|
|
|
31
|
-
|
|
25
|
+
Before any action, classify the input:
|
|
32
26
|
|
|
33
|
-
|
|
27
|
+
| Input Type | Signal | Strategy |
|
|
28
|
+
|---|---|---|
|
|
29
|
+
| **Text Prompt** | "Build a settings page with..." | Text-to-UI pipeline: envision → variants → implement |
|
|
30
|
+
| **Screenshot/Image** | Image file @-mentioned or attached | Image-to-UI pipeline: analyze → extract → implement |
|
|
31
|
+
| **Wireframe/Sketch** | Rough drawing, low-fi mockup | Wireframe-to-UI: interpret structure → add design → implement |
|
|
32
|
+
| **Existing Code** | "Redesign this component" | Audit → envision alternatives → refactor |
|
|
33
|
+
| **Design Reference** | "Make it look like [image]" | Extract style → apply to target components |
|
|
34
|
+
| **Review Request** | "Review UI quality" | Audit mode (see /vision command) |
|
|
34
35
|
|
|
35
|
-
|
|
36
|
-
- What problem does this interface solve?
|
|
37
|
-
- Who uses it?
|
|
36
|
+
Then classify scope:
|
|
38
37
|
|
|
39
|
-
|
|
38
|
+
| Scope | Signal | Approach |
|
|
39
|
+
|---|---|---|
|
|
40
|
+
| **Single Component** | Button, card, modal, form | Direct implement with variants |
|
|
41
|
+
| **Screen/Page** | Settings page, dashboard, profile | Full Stitch pipeline with layout variants |
|
|
42
|
+
| **Multi-Screen Flow** | Onboarding, checkout, wizard | Coherent flow design with shared tokens |
|
|
43
|
+
| **Design System** | Tokens, theme, component library | System architecture first |
|
|
40
44
|
|
|
41
|
-
|
|
42
|
-
Maximalist chaos: Rich, layered, overwhelming beauty
|
|
43
|
-
Retro-futuristic: Nostalgic tech, neon, CRT vibes
|
|
44
|
-
Organic/natural: Soft curves, earthy, living
|
|
45
|
-
Luxury/refined: Premium, elegant, exclusive
|
|
46
|
-
Playful/toy-like: Fun, bouncy, colorful
|
|
47
|
-
Editorial/magazine: Type-forward, grid-based, sophisticated
|
|
48
|
-
Brutalist/raw: Exposed, honest, anti-design
|
|
45
|
+
## Phase 1: Proactive Exploration (BEFORE designing)
|
|
49
46
|
|
|
50
|
-
|
|
51
|
-
- What makes this UNFORGETTABLE?
|
|
52
|
-
- What's the one thing someone will remember?
|
|
47
|
+
Fire these in parallel immediately:
|
|
53
48
|
|
|
54
|
-
|
|
49
|
+
### 1a. Codebase Design Audit
|
|
55
50
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
51
|
+
```
|
|
52
|
+
Explore: "Find existing design system: CSS variables, theme config, design tokens, color palette, typography scale. Return file paths and values."
|
|
53
|
+
Explore: "Find existing UI components: naming patterns, prop conventions, composition patterns, style approach (Tailwind/CSS Modules/CSS-in-JS). Compare 2-3 components."
|
|
54
|
+
Explore: "Find package.json — what CSS framework, component library, icon set, font loading is already in use."
|
|
55
|
+
```
|
|
60
56
|
|
|
61
|
-
###
|
|
62
|
-
- Commit to cohesive aesthetic
|
|
63
|
-
- Use CSS variables for consistency
|
|
64
|
-
- Dominant colors with sharp accents > timid, evenly-distributed palettes
|
|
57
|
+
### 1b. Visual Input Analysis (if image provided)
|
|
65
58
|
|
|
66
|
-
|
|
67
|
-
- Animations for effects and micro-interactions
|
|
68
|
-
- CSS-only solutions preferred for HTML
|
|
69
|
-
- High-impact moments: orchestrated page load, staggered reveals, scroll effects, surprising hover states
|
|
59
|
+
When an image is @-mentioned or attached, extract immediately:
|
|
70
60
|
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
61
|
+
1. **Color Palette** — All colors with hex codes and usage roles (primary, secondary, accent, background, text)
|
|
62
|
+
2. **Typography** — Font families, size scale, weight variations, line-height patterns
|
|
63
|
+
3. **Spacing System** — Base unit, padding/margin rhythm, gap patterns
|
|
64
|
+
4. **Component Inventory** — Every distinct UI component visible (cards, buttons, inputs, navs, etc.)
|
|
65
|
+
5. **Layout Structure** — Grid system, column count, breakpoint hints, flex/grid patterns
|
|
66
|
+
6. **Visual Effects** — Shadows, borders, border-radius, gradients, blur, overlays
|
|
67
|
+
7. **Motion Hints** — Hover states, transitions, animations if inferable
|
|
68
|
+
|
|
69
|
+
### 1c. Design Context (if text prompt)
|
|
70
|
+
|
|
71
|
+
Before implementing, understand the design problem:
|
|
72
|
+
|
|
73
|
+
- What is the user's goal on this screen?
|
|
74
|
+
- What is the information hierarchy? (What's most important?)
|
|
75
|
+
- What actions can the user take?
|
|
76
|
+
- What device/viewport is primary?
|
|
77
|
+
|
|
78
|
+
## Phase 2: Variant Exploration (Stitch-Inspired)
|
|
79
|
+
|
|
80
|
+
**CRITICAL: Never jump straight to implementation. Present design options first.**
|
|
81
|
+
|
|
82
|
+
### For Text-to-UI Requests
|
|
83
|
+
|
|
84
|
+
Generate 2-3 design variants as detailed text descriptions. Each variant must include:
|
|
85
|
+
|
|
86
|
+
```markdown
|
|
87
|
+
### Variant A: [Name] — [One-Line Aesthetic]
|
|
88
|
+
|
|
89
|
+
**Direction:** [e.g., Minimalist editorial, Bold maximalist, Glass morphism]
|
|
90
|
+
**Layout:** [e.g., Single column centered, Asymmetric split, Grid-based dashboard]
|
|
91
|
+
**Color Strategy:** [e.g., Monochrome with accent, Dark mode native, Earth tones]
|
|
92
|
+
**Typography:** [e.g., Display: Clash Display / Body: DM Sans]
|
|
93
|
+
**Key Differentiator:** [What makes this variant memorable]
|
|
94
|
+
|
|
95
|
+
**Component Breakdown:**
|
|
96
|
+
- [Component 1]: [Brief description of its design]
|
|
97
|
+
- [Component 2]: [Brief description]
|
|
98
|
+
|
|
99
|
+
**Responsive Strategy:** [How it adapts across breakpoints]
|
|
100
|
+
```
|
|
101
|
+
|
|
102
|
+
### For Image-to-UI Requests
|
|
103
|
+
|
|
104
|
+
Present the extraction summary and propose:
|
|
105
|
+
|
|
106
|
+
1. **Faithful reproduction** — Match the source as closely as possible
|
|
107
|
+
2. **Enhanced version** — Keep structure, improve polish/accessibility/responsiveness
|
|
108
|
+
3. **Reinterpretation** — Keep the essence, adapt to project's design system
|
|
109
|
+
|
|
110
|
+
### Variant Selection
|
|
111
|
+
|
|
112
|
+
After presenting variants, ask the user to pick a direction. If the user said "just do it" or similar, pick the variant that best matches:
|
|
113
|
+
1. Existing project design patterns (if any)
|
|
114
|
+
2. The most distinctive option (avoid generic AI aesthetic)
|
|
115
|
+
3. Best accessibility score
|
|
116
|
+
|
|
117
|
+
## Phase 3: Design Token Resolution
|
|
118
|
+
|
|
119
|
+
Before writing any component code, resolve these tokens:
|
|
120
|
+
|
|
121
|
+
```css
|
|
122
|
+
/* Resolve ALL of these before coding */
|
|
123
|
+
--color-primary: ;
|
|
124
|
+
--color-secondary: ;
|
|
125
|
+
--color-accent: ;
|
|
126
|
+
--color-background: ;
|
|
127
|
+
--color-surface: ;
|
|
128
|
+
--color-text: ;
|
|
129
|
+
--color-text-muted: ;
|
|
130
|
+
--color-border: ;
|
|
131
|
+
--color-success: ;
|
|
132
|
+
--color-warning: ;
|
|
133
|
+
--color-error: ;
|
|
134
|
+
|
|
135
|
+
--font-display: ;
|
|
136
|
+
--font-body: ;
|
|
137
|
+
--font-mono: ;
|
|
138
|
+
--font-size-base: ;
|
|
139
|
+
--type-scale: ; /* e.g., 1.25 for Major Third */
|
|
140
|
+
|
|
141
|
+
--space-unit: ; /* e.g., 8px */
|
|
142
|
+
--radius-sm: ;
|
|
143
|
+
--radius-md: ;
|
|
144
|
+
--radius-lg: ;
|
|
145
|
+
|
|
146
|
+
--shadow-sm: ;
|
|
147
|
+
--shadow-md: ;
|
|
148
|
+
--shadow-lg: ;
|
|
149
|
+
|
|
150
|
+
--transition-fast: ;
|
|
151
|
+
--transition-normal: ;
|
|
152
|
+
--easing-default: ;
|
|
153
|
+
```
|
|
154
|
+
|
|
155
|
+
**If the project already has tokens**: USE THEM. Do not invent new ones.
|
|
156
|
+
**If no tokens exist**: Define them in the chosen variant's style, propose to user.
|
|
157
|
+
|
|
158
|
+
## Phase 4: Implementation
|
|
159
|
+
|
|
160
|
+
### Build Order (always follow this sequence)
|
|
161
|
+
|
|
162
|
+
1. **Tokens** — CSS variables / theme config (if not existing)
|
|
163
|
+
2. **Layout Shell** — Page/screen structure with semantic HTML
|
|
164
|
+
3. **Core Components** — Build from inside out (atoms → molecules → organisms)
|
|
165
|
+
4. **Content & Data** — Populate with realistic placeholder content
|
|
166
|
+
5. **Interactive States** — Hover, focus, active, disabled, loading, error, empty
|
|
167
|
+
6. **Responsive Adaptation** — Mobile-first breakpoints with clamp/min/max
|
|
168
|
+
7. **Accessibility Layer** — ARIA, focus management, contrast, reduced motion
|
|
169
|
+
8. **Motion & Polish** — Transitions, animations, micro-interactions
|
|
170
|
+
|
|
171
|
+
### Multi-Screen Coherence (for flows)
|
|
172
|
+
|
|
173
|
+
When designing multi-screen flows:
|
|
174
|
+
|
|
175
|
+
- **Shared tokens**: All screens use the same CSS variables
|
|
176
|
+
- **Navigation consistency**: Same nav pattern across screens
|
|
177
|
+
- **Transition logic**: How users move between screens (slide, fade, instant)
|
|
178
|
+
- **State preservation**: What persists across screens (header, sidebar, progress)
|
|
179
|
+
- **Screen inventory**: Document each screen's purpose and key components
|
|
180
|
+
|
|
181
|
+
### Aesthetic Anti-Slop Rules
|
|
182
|
+
|
|
183
|
+
**NEVER generate generic AI aesthetic:**
|
|
184
|
+
- ❌ Inter, Roboto, Arial, Helvetica as primary fonts
|
|
185
|
+
- ❌ Purple-to-pink gradients on white backgrounds
|
|
186
|
+
- ❌ Centered hero → 3-column feature cards → footer (the AI landing page)
|
|
187
|
+
- ❌ Evenly distributed rainbow palettes
|
|
188
|
+
- ❌ Generic stock photo placeholders
|
|
189
|
+
- ❌ Rounded corners on everything without intention
|
|
190
|
+
- ❌ Drop shadows on every element
|
|
191
|
+
|
|
192
|
+
**ALWAYS commit to a distinctive direction:**
|
|
193
|
+
- ✅ One bold aesthetic, fully committed
|
|
194
|
+
- ✅ Distinctive font pairing (display + body)
|
|
195
|
+
- ✅ Dominant color with sharp accent (not 5 equal colors)
|
|
196
|
+
- ✅ Intentional whitespace (generous OR controlled density)
|
|
197
|
+
- ✅ Unexpected layout choices (asymmetry, overlap, grid-breaking)
|
|
198
|
+
|
|
199
|
+
## Phase 5: Visual Verification
|
|
200
|
+
|
|
201
|
+
After implementation, verify the output:
|
|
202
|
+
|
|
203
|
+
### Self-Review Checklist
|
|
204
|
+
|
|
205
|
+
- [ ] **Matches chosen variant** — Does the code match the design direction?
|
|
206
|
+
- [ ] **Responsive** — Works at 375px, 768px, 1024px, 1440px
|
|
207
|
+
- [ ] **Accessibility** — WCAG AA contrast (4.5:1 text, 3:1 large), focus visible, ARIA complete
|
|
208
|
+
- [ ] **Interactive states** — All hover/focus/active/disabled states implemented
|
|
209
|
+
- [ ] **Reduced motion** — `prefers-reduced-motion` respected
|
|
210
|
+
- [ ] **Semantic HTML** — Proper elements (button, nav, main, aside, section)
|
|
211
|
+
- [ ] **No hardcoded values** — All colors, spacing, fonts use tokens/variables
|
|
212
|
+
- [ ] **Convention match** — Code follows project's existing patterns
|
|
213
|
+
|
|
214
|
+
### Screenshot Verification (if browser available)
|
|
215
|
+
|
|
216
|
+
```bash
|
|
217
|
+
# If the project has a dev server, take screenshots for verification
|
|
218
|
+
# npx playwright screenshot http://localhost:3000/page --output screenshot.png
|
|
219
|
+
```
|
|
220
|
+
|
|
221
|
+
## Phase 6: Iterative Refinement (Stitch-Style)
|
|
222
|
+
|
|
223
|
+
When the user requests changes after initial implementation:
|
|
224
|
+
|
|
225
|
+
1. **Understand the delta** — What specifically should change? (color? layout? spacing? component?)
|
|
226
|
+
2. **Scope the change** — Does this affect tokens (global) or a single component (local)?
|
|
227
|
+
3. **Apply surgically** — Edit the minimum files needed
|
|
228
|
+
4. **Maintain coherence** — If changing tokens, propagate across all affected components
|
|
229
|
+
5. **Re-verify** — Run the self-review checklist on changed components
|
|
230
|
+
|
|
231
|
+
**Multi-select refinement**: If the user wants the same change across multiple components/screens, apply it systematically via shared tokens rather than editing each component individually.
|
|
74
232
|
|
|
75
233
|
## Technology Awareness
|
|
76
234
|
|
|
77
235
|
Detect and match the project's styling approach:
|
|
78
236
|
|
|
79
|
-
| Stack |
|
|
80
|
-
|
|
81
|
-
| Plain CSS | Custom properties, modern selectors, `@layer
|
|
82
|
-
| Tailwind CSS | Utility classes, `@apply
|
|
83
|
-
| CSS Modules | Scoped `.module.css
|
|
237
|
+
| Stack | How to Implement |
|
|
238
|
+
|-------|-----------------|
|
|
239
|
+
| Plain CSS | Custom properties, modern selectors, `@layer`, nesting |
|
|
240
|
+
| Tailwind CSS | Utility classes, `@apply` sparingly, extend config |
|
|
241
|
+
| CSS Modules | Scoped `.module.css`, composition |
|
|
84
242
|
| CSS-in-JS | styled-components, Emotion, vanilla-extract |
|
|
85
243
|
| SCSS/Sass | Mixins, nesting, variables, partials |
|
|
86
244
|
| Component libs | Shadcn, Radix, MUI, Chakra — extend, don't fight |
|
|
87
245
|
|
|
88
|
-
Always check `package.json`, existing stylesheets, and component patterns
|
|
89
|
-
|
|
90
|
-
##
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
- Focus indicators visible and styled
|
|
113
|
-
- ARIA labels for interactive elements without visible text
|
|
114
|
-
- `prefers-reduced-motion` respected for animations
|
|
115
|
-
- Semantic HTML elements (button, nav, main, aside)
|
|
116
|
-
- Keyboard navigable (tab order, escape to close)
|
|
117
|
-
|
|
118
|
-
### Performance
|
|
119
|
-
- Prefer `transform`/`opacity` for animations (avoid layout thrashing)
|
|
120
|
-
- Use `will-change` sparingly
|
|
121
|
-
- Lazy-load images with proper aspect ratios
|
|
122
|
-
- Prefer CSS over JavaScript for visual effects
|
|
123
|
-
|
|
124
|
-
## Anti-Patterns (NEVER USE)
|
|
125
|
-
|
|
126
|
-
Generic AI-generated aesthetics:
|
|
127
|
-
- Overused fonts: Inter, Roboto, Arial, Space Grotesk
|
|
128
|
-
- Cliche colors: Purple gradients on white backgrounds
|
|
129
|
-
- Predictable layouts and cookie-cutter patterns
|
|
130
|
-
- Design lacking context-specific character
|
|
131
|
-
|
|
132
|
-
## Execution Pattern
|
|
133
|
-
|
|
134
|
-
1. **Audit**: Read existing styles, theme, design tokens, visual direction
|
|
135
|
-
2. **Envision**: Commit to a bold aesthetic direction
|
|
136
|
-
3. **Plan**: Identify components, variants, responsive needs
|
|
137
|
-
4. **Implement**: Write CSS/components matching project conventions
|
|
138
|
-
5. **Verify**: Check responsive behavior, a11y, visual correctness
|
|
139
|
-
6. **Polish**: Transitions, hover states, focus styles, edge cases
|
|
246
|
+
Always check `package.json`, existing stylesheets, and component patterns FIRST.
|
|
247
|
+
|
|
248
|
+
## Delegation Table
|
|
249
|
+
|
|
250
|
+
| Need | Delegate To | Mode |
|
|
251
|
+
|---|---|---|
|
|
252
|
+
| Find existing components, patterns, tokens | **Explore** | background, parallel |
|
|
253
|
+
| Design inspiration, trend research | **Scout** | background |
|
|
254
|
+
| Deep architecture analysis of component system | **Looker** | foreground |
|
|
255
|
+
| Accessibility audit depth | **Self** (load `accessibility-audit` skill) | foreground |
|
|
256
|
+
|
|
257
|
+
## Skill Loading
|
|
258
|
+
|
|
259
|
+
Load relevant skills based on the task:
|
|
260
|
+
|
|
261
|
+
| Task | Load Skill |
|
|
262
|
+
|------|-----------|
|
|
263
|
+
| Analyzing a mockup/screenshot | `visual-analysis` |
|
|
264
|
+
| Converting mockup to code | `mockup-to-code` |
|
|
265
|
+
| Setting aesthetic direction | `frontend-aesthetics` |
|
|
266
|
+
| Accessing Figma designs | `figma` |
|
|
267
|
+
| UX audit of existing UI | `ui-ux-research` |
|
|
268
|
+
| Accessibility deep-dive | `accessibility-audit` |
|
|
269
|
+
| Design system work | `design-system-audit` |
|
|
140
270
|
|
|
141
271
|
## Guardrails
|
|
142
272
|
|
|
143
|
-
Always
|
|
144
|
-
-
|
|
145
|
-
-
|
|
146
|
-
-
|
|
147
|
-
- Include focus and hover states for interactive elements
|
|
148
|
-
- Verify color contrast ratios
|
|
273
|
+
**Always:**
|
|
274
|
+
- Explore existing design system before creating anything
|
|
275
|
+
- Present variant options before implementing (unless user says "just do it")
|
|
276
|
+
- Extract design tokens from images before coding
|
|
149
277
|
- Use semantic HTML elements
|
|
150
|
-
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
-
|
|
154
|
-
-
|
|
155
|
-
-
|
|
278
|
+
- Include all interactive states (hover, focus, active, disabled)
|
|
279
|
+
- Verify color contrast (WCAG AA minimum)
|
|
280
|
+
- Respect `prefers-reduced-motion`
|
|
281
|
+
- Match project's existing styling approach
|
|
282
|
+
- Use CSS variables for all theme values
|
|
283
|
+
- Build mobile-first responsive layouts
|
|
284
|
+
|
|
285
|
+
**Never:**
|
|
286
|
+
- Jump to code without exploring existing patterns
|
|
287
|
+
- Use generic AI aesthetic (Inter, purple gradients, 3-column cards)
|
|
288
|
+
- Mix conflicting aesthetic directions in one design
|
|
289
|
+
- Hard-code colors, spacing, or font sizes
|
|
156
290
|
- Use `!important` unless overriding third-party styles
|
|
157
|
-
- Hard-code colors, spacing, or font sizes (use tokens/variables)
|
|
158
|
-
- Add JavaScript for effects achievable with CSS alone
|
|
159
291
|
- Skip accessibility considerations
|
|
292
|
+
- Add JavaScript for effects achievable with CSS
|
|
293
|
+
- Override design system tokens without discussion
|
|
294
|
+
- Generate a single variant without offering alternatives
|
|
295
|
+
- Ignore the user's chosen aesthetic direction
|
package/dist/cli.test.d.ts
DELETED
package/dist/cli.test.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"cli.test.d.ts","sourceRoot":"","sources":["../src/cli.test.ts"],"names":[],"mappings":""}
|
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Auto-Format Hook
|
|
3
|
-
*
|
|
4
|
-
* Runs the project's formatter after file edits.
|
|
5
|
-
* Detects prettier, biome, dprint, or other formatters from project config.
|
|
6
|
-
* Runs on tool.execute.after for edit/write tools.
|
|
7
|
-
*/
|
|
8
|
-
export interface AutoFormatConfig {
|
|
9
|
-
enabled?: boolean;
|
|
10
|
-
formatter?: string;
|
|
11
|
-
extensions?: string[];
|
|
12
|
-
log?: boolean;
|
|
13
|
-
}
|
|
14
|
-
export interface FormatResult {
|
|
15
|
-
formatted: boolean;
|
|
16
|
-
file: string;
|
|
17
|
-
formatter: string;
|
|
18
|
-
error?: string;
|
|
19
|
-
}
|
|
20
|
-
type FormatterEntry = {
|
|
21
|
-
name: string;
|
|
22
|
-
configFiles: string[];
|
|
23
|
-
command: (file: string) => string;
|
|
24
|
-
};
|
|
25
|
-
export declare function detectFormatter(projectDir: string): FormatterEntry | undefined;
|
|
26
|
-
export declare function shouldFormat(filePath: unknown, extensions?: string[]): boolean;
|
|
27
|
-
export declare function runFormatter(filePath: unknown, projectDir: unknown, formatterOverride?: string): FormatResult;
|
|
28
|
-
export declare function formatAutoFormatLog(result: FormatResult): string;
|
|
29
|
-
export {};
|
|
30
|
-
//# sourceMappingURL=auto-format.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"auto-format.d.ts","sourceRoot":"","sources":["../../src/hooks/auto-format.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAMH,MAAM,WAAW,gBAAgB;IAC/B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,EAAE,CAAC;IACtB,GAAG,CAAC,EAAE,OAAO,CAAC;CACf;AAED,MAAM,WAAW,YAAY;IAC3B,SAAS,EAAE,OAAO,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,KAAK,cAAc,GAAG;IACpB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,OAAO,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAAC;CACnC,CAAC;AAsBF,wBAAgB,eAAe,CAAC,UAAU,EAAE,MAAM,GAAG,cAAc,GAAG,SAAS,CA2B9E;AAED,wBAAgB,YAAY,CAAC,QAAQ,EAAE,OAAO,EAAE,UAAU,CAAC,EAAE,MAAM,EAAE,GAAG,OAAO,CAK9E;AAED,wBAAgB,YAAY,CAC1B,QAAQ,EAAE,OAAO,EACjB,UAAU,EAAE,OAAO,EACnB,iBAAiB,CAAC,EAAE,MAAM,GACzB,YAAY,CAqCd;AAED,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,YAAY,GAAG,MAAM,CAKhE"}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Comment Checker Hook
|
|
3
|
-
*
|
|
4
|
-
* Detects excessive AI-generated comments in code output.
|
|
5
|
-
* AI code should be indistinguishable from human-written code.
|
|
6
|
-
* Runs on tool.execute.after for edit/write tools.
|
|
7
|
-
*/
|
|
8
|
-
export interface CommentCheckResult {
|
|
9
|
-
excessive: boolean;
|
|
10
|
-
count: number;
|
|
11
|
-
totalLines: number;
|
|
12
|
-
ratio: number;
|
|
13
|
-
}
|
|
14
|
-
export declare function checkCommentDensity(content: unknown, threshold?: number): CommentCheckResult;
|
|
15
|
-
export declare function hasExcessiveAIComments(content: unknown): boolean;
|
|
16
|
-
export declare function formatCommentWarning(result: CommentCheckResult): string;
|
|
17
|
-
//# sourceMappingURL=comment-checker.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"comment-checker.d.ts","sourceRoot":"","sources":["../../src/hooks/comment-checker.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAWH,MAAM,WAAW,kBAAkB;IACjC,SAAS,EAAE,OAAO,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf;AAED,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,OAAO,EAAE,SAAS,GAAE,MAAY,GAAG,kBAAkB,CAqDjG;AAED,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,OAAO,GAAG,OAAO,CAYhE;AAED,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,kBAAkB,GAAG,MAAM,CAGvE"}
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Compaction Hook
|
|
3
|
-
*
|
|
4
|
-
* Injects beads-village state and memory references when a session
|
|
5
|
-
* is being compacted (context window nearing limit). Ensures critical
|
|
6
|
-
* state survives compaction so agents don't lose task context.
|
|
7
|
-
* Runs on session.idle / compaction event.
|
|
8
|
-
*
|
|
9
|
-
* Beads state: reads from .beads/metadata.json + .reservations/
|
|
10
|
-
* Memory refs: scans .opencode/memory/ subdirs for .md files
|
|
11
|
-
*/
|
|
12
|
-
export interface CompactionConfig {
|
|
13
|
-
enabled?: boolean;
|
|
14
|
-
include_beads_state?: boolean;
|
|
15
|
-
include_memory_refs?: boolean;
|
|
16
|
-
include_todo_state?: boolean;
|
|
17
|
-
max_state_chars?: number;
|
|
18
|
-
}
|
|
19
|
-
export interface BeadsState {
|
|
20
|
-
currentTask?: string;
|
|
21
|
-
taskId?: string;
|
|
22
|
-
reservedFiles?: string[];
|
|
23
|
-
agentId?: string;
|
|
24
|
-
team?: string;
|
|
25
|
-
inProgressCount?: number;
|
|
26
|
-
openCount?: number;
|
|
27
|
-
}
|
|
28
|
-
export interface MemoryRef {
|
|
29
|
-
key: string;
|
|
30
|
-
summary: string;
|
|
31
|
-
timestamp: number;
|
|
32
|
-
category: string;
|
|
33
|
-
}
|
|
34
|
-
export interface CompactionPayload {
|
|
35
|
-
beads?: BeadsState;
|
|
36
|
-
memories?: MemoryRef[];
|
|
37
|
-
todos?: Array<{
|
|
38
|
-
id: string;
|
|
39
|
-
content: string;
|
|
40
|
-
status: string;
|
|
41
|
-
}>;
|
|
42
|
-
sessionSummary?: string;
|
|
43
|
-
}
|
|
44
|
-
/**
|
|
45
|
-
* Read beads-village state from the actual beads infrastructure:
|
|
46
|
-
* - .beads/metadata.json for DB config
|
|
47
|
-
* - .reservations/ for active file locks
|
|
48
|
-
* - `bd ls` command for current task status (if bd CLI available)
|
|
49
|
-
*/
|
|
50
|
-
export declare function readBeadsState(projectDir: unknown): BeadsState | undefined;
|
|
51
|
-
/**
|
|
52
|
-
* Read memory references from .opencode/memory/ subdirectories.
|
|
53
|
-
* Scans for .md files in subdirs: specs/, plans/, research/, reviews/, handoffs/, beads/
|
|
54
|
-
* Extracts title from first heading or filename.
|
|
55
|
-
*/
|
|
56
|
-
export declare function readMemoryRefs(projectDir: unknown, limit?: number): MemoryRef[];
|
|
57
|
-
export declare function buildCompactionBlock(payload: CompactionPayload, maxChars?: number): string;
|
|
58
|
-
export declare function collectCompactionPayload(projectDir: unknown, config?: CompactionConfig): CompactionPayload;
|
|
59
|
-
export declare function formatCompactionLog(payload: CompactionPayload): string;
|
|
60
|
-
//# sourceMappingURL=compaction.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"compaction.d.ts","sourceRoot":"","sources":["../../src/hooks/compaction.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAMH,MAAM,WAAW,gBAAgB;IAC/B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAED,MAAM,WAAW,UAAU;IACzB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,aAAa,CAAC,EAAE,MAAM,EAAE,CAAC;IACzB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,SAAS;IACxB,GAAG,EAAE,MAAM,CAAC;IACZ,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,MAAM,WAAW,iBAAiB;IAChC,KAAK,CAAC,EAAE,UAAU,CAAC;IACnB,QAAQ,CAAC,EAAE,SAAS,EAAE,CAAC;IACvB,KAAK,CAAC,EAAE,KAAK,CAAC;QAAE,EAAE,EAAE,MAAM,CAAC;QAAC,OAAO,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAE,CAAC,CAAC;IAC/D,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AA8BD;;;;;GAKG;AACH,wBAAgB,cAAc,CAAC,UAAU,EAAE,OAAO,GAAG,UAAU,GAAG,SAAS,CAoG1E;AAED;;;;GAIG;AACH,wBAAgB,cAAc,CAAC,UAAU,EAAE,OAAO,EAAE,KAAK,GAAE,MAAW,GAAG,SAAS,EAAE,CAkEnF;AAED,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,iBAAiB,EAAE,QAAQ,GAAE,MAAa,GAAG,MAAM,CA6ChG;AAED,wBAAgB,wBAAwB,CACtC,UAAU,EAAE,OAAO,EACnB,MAAM,CAAC,EAAE,gBAAgB,GACxB,iBAAiB,CAgBnB;AAED,wBAAgB,mBAAmB,CAAC,OAAO,EAAE,iBAAiB,GAAG,MAAM,CAMtE"}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Environment Context Hook
|
|
3
|
-
*
|
|
4
|
-
* Injects project structure, git branch, build system, and runtime
|
|
5
|
-
* environment details into session prompts. Provides agents with
|
|
6
|
-
* awareness of the development environment.
|
|
7
|
-
* Runs on session.created event.
|
|
8
|
-
*/
|
|
9
|
-
export interface EnvContextConfig {
|
|
10
|
-
enabled?: boolean;
|
|
11
|
-
include_git?: boolean;
|
|
12
|
-
include_package?: boolean;
|
|
13
|
-
include_structure?: boolean;
|
|
14
|
-
max_depth?: number;
|
|
15
|
-
}
|
|
16
|
-
export interface EnvInfo {
|
|
17
|
-
platform: string;
|
|
18
|
-
nodeVersion: string;
|
|
19
|
-
cwd: string;
|
|
20
|
-
git?: GitInfo;
|
|
21
|
-
package?: PackageInfo;
|
|
22
|
-
structure?: string[];
|
|
23
|
-
}
|
|
24
|
-
export interface GitInfo {
|
|
25
|
-
branch: string;
|
|
26
|
-
hasChanges: boolean;
|
|
27
|
-
remoteUrl?: string;
|
|
28
|
-
lastCommit?: string;
|
|
29
|
-
}
|
|
30
|
-
export interface PackageInfo {
|
|
31
|
-
name?: string;
|
|
32
|
-
version?: string;
|
|
33
|
-
packageManager?: string;
|
|
34
|
-
scripts?: string[];
|
|
35
|
-
framework?: string;
|
|
36
|
-
}
|
|
37
|
-
export declare function getGitInfo(cwd: string): GitInfo | undefined;
|
|
38
|
-
export declare function getPackageInfo(cwd: string): PackageInfo | undefined;
|
|
39
|
-
export declare function getTopLevelStructure(cwd: string, maxDepth?: number): string[];
|
|
40
|
-
export declare function collectEnvInfo(cwd: unknown, config?: EnvContextConfig): EnvInfo;
|
|
41
|
-
export declare function buildEnvBlock(info: EnvInfo): string;
|
|
42
|
-
export declare function formatEnvSummary(info: EnvInfo): string;
|
|
43
|
-
//# sourceMappingURL=env-context.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"env-context.d.ts","sourceRoot":"","sources":["../../src/hooks/env-context.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAMH,MAAM,WAAW,gBAAgB;IAC/B,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,iBAAiB,CAAC,EAAE,OAAO,CAAC;IAC5B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,OAAO;IACtB,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,EAAE,MAAM,CAAC;IACZ,GAAG,CAAC,EAAE,OAAO,CAAC;IACd,OAAO,CAAC,EAAE,WAAW,CAAC;IACtB,SAAS,CAAC,EAAE,MAAM,EAAE,CAAC;CACtB;AAED,MAAM,WAAW,OAAO;IACtB,MAAM,EAAE,MAAM,CAAC;IACf,UAAU,EAAE,OAAO,CAAC;IACpB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,MAAM,WAAW,WAAW;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAcD,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,GAAG,SAAS,CAc3D;AAED,wBAAgB,cAAc,CAAC,GAAG,EAAE,MAAM,GAAG,WAAW,GAAG,SAAS,CA6CnE;AAED,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,MAAM,EAAE,QAAQ,GAAE,MAAU,GAAG,MAAM,EAAE,CA8BhF;AAED,wBAAgB,cAAc,CAAC,GAAG,EAAE,OAAO,EAAE,MAAM,CAAC,EAAE,gBAAgB,GAAG,OAAO,CAqB/E;AAED,wBAAgB,aAAa,CAAC,IAAI,EAAE,OAAO,GAAG,MAAM,CAmCnD;AAED,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,OAAO,GAAG,MAAM,CAMtD"}
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
export interface RitualPhase {
|
|
2
|
-
name: "discover" | "plan" | "implement" | "verify" | "complete";
|
|
3
|
-
status: "pending" | "in_progress" | "done";
|
|
4
|
-
startedAt?: string;
|
|
5
|
-
completedAt?: string;
|
|
6
|
-
}
|
|
7
|
-
export interface RitualState {
|
|
8
|
-
taskId?: string;
|
|
9
|
-
phases: RitualPhase[];
|
|
10
|
-
currentPhase: number;
|
|
11
|
-
createdAt: string;
|
|
12
|
-
updatedAt: string;
|
|
13
|
-
}
|
|
14
|
-
export interface RitualEnforcerConfig {
|
|
15
|
-
enabled?: boolean;
|
|
16
|
-
enforceOrder?: boolean;
|
|
17
|
-
requireApproval?: boolean;
|
|
18
|
-
}
|
|
19
|
-
export declare function initRitual(taskId?: string): RitualState;
|
|
20
|
-
export declare function getCurrentPhase(): RitualPhase | null;
|
|
21
|
-
export declare function advancePhase(): RitualState | null;
|
|
22
|
-
export declare function completePhase(phaseName: RitualPhase["name"]): RitualState | null;
|
|
23
|
-
export declare function checkRitualProgress(): {
|
|
24
|
-
currentPhase: string;
|
|
25
|
-
progress: string;
|
|
26
|
-
canProceed: boolean;
|
|
27
|
-
};
|
|
28
|
-
export declare function formatRitualStatus(): string;
|
|
29
|
-
//# sourceMappingURL=ritual-enforcer.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ritual-enforcer.d.ts","sourceRoot":"","sources":["../../src/hooks/ritual-enforcer.ts"],"names":[],"mappings":"AAKA,MAAM,WAAW,WAAW;IAC1B,IAAI,EAAE,UAAU,GAAG,MAAM,GAAG,WAAW,GAAG,QAAQ,GAAG,UAAU,CAAC;IAChE,MAAM,EAAE,SAAS,GAAG,aAAa,GAAG,MAAM,CAAC;IAC3C,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,WAAW;IAC1B,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,WAAW,EAAE,CAAC;IACtB,YAAY,EAAE,MAAM,CAAC;IACrB,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;CACnB;AAID,MAAM,WAAW,oBAAoB;IACnC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,eAAe,CAAC,EAAE,OAAO,CAAC;CAC3B;AA8ED,wBAAgB,UAAU,CAAC,MAAM,CAAC,EAAE,MAAM,GAAG,WAAW,CAevD;AAED,wBAAgB,eAAe,IAAI,WAAW,GAAG,IAAI,CAIpD;AAED,wBAAgB,YAAY,IAAI,WAAW,GAAG,IAAI,CAiBjD;AAED,wBAAgB,aAAa,CAAC,SAAS,EAAE,WAAW,CAAC,MAAM,CAAC,GAAG,WAAW,GAAG,IAAI,CA2BhF;AAED,wBAAgB,mBAAmB,IAAI;IACrC,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,OAAO,CAAC;CACrB,CAgCA;AAED,wBAAgB,kBAAkB,IAAI,MAAM,CAc3C"}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Session Notification Hook
|
|
3
|
-
*
|
|
4
|
-
* Sends desktop notifications when sessions complete or go idle.
|
|
5
|
-
* Uses platform-native notification commands (notify-send, osascript, powershell).
|
|
6
|
-
* Runs on session.idle event.
|
|
7
|
-
*/
|
|
8
|
-
export interface SessionNotificationConfig {
|
|
9
|
-
enabled?: boolean;
|
|
10
|
-
on_idle?: boolean;
|
|
11
|
-
on_error?: boolean;
|
|
12
|
-
title_prefix?: string;
|
|
13
|
-
}
|
|
14
|
-
export interface NotificationPayload {
|
|
15
|
-
title: string;
|
|
16
|
-
body: string;
|
|
17
|
-
urgency?: "low" | "normal" | "critical";
|
|
18
|
-
}
|
|
19
|
-
export declare function sendNotification(payload: NotificationPayload): boolean;
|
|
20
|
-
export declare function buildIdleNotification(sessionId?: unknown, prefix?: string): NotificationPayload;
|
|
21
|
-
export declare function buildErrorNotification(error: unknown, sessionId?: unknown, prefix?: string): NotificationPayload;
|
|
22
|
-
export declare function formatNotificationLog(payload: NotificationPayload, sent: boolean): string;
|
|
23
|
-
//# sourceMappingURL=session-notification.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"session-notification.d.ts","sourceRoot":"","sources":["../../src/hooks/session-notification.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAIH,MAAM,WAAW,yBAAyB;IACxC,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,YAAY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,mBAAmB;IAClC,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,CAAC,EAAE,KAAK,GAAG,QAAQ,GAAG,UAAU,CAAC;CACzC;AA4BD,wBAAgB,gBAAgB,CAAC,OAAO,EAAE,mBAAmB,GAAG,OAAO,CAsBtE;AAED,wBAAgB,qBAAqB,CACnC,SAAS,CAAC,EAAE,OAAO,EACnB,MAAM,CAAC,EAAE,MAAM,GACd,mBAAmB,CAUrB;AAED,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,OAAO,EACd,SAAS,CAAC,EAAE,OAAO,EACnB,MAAM,CAAC,EAAE,MAAM,GACd,mBAAmB,CAerB;AAED,wBAAgB,qBAAqB,CAAC,OAAO,EAAE,mBAAmB,EAAE,IAAI,EAAE,OAAO,GAAG,MAAM,CAIzF"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"session-notification.test.d.ts","sourceRoot":"","sources":["../../src/hooks/session-notification.test.ts"],"names":[],"mappings":""}
|