Skip to content

Commit 36ff6f9

Browse files
electroheadfxclaude
andcommitted
feat: v0.7.0 Monorepo & Paint Enhancements
- Phase 26: pnpm monorepo scaffold (app/ rename, workspace config) - Phase 33: 3-mode paint system (flat/FX/physical), inline 4-mode color picker (Box/TSL/RVB/CMYK), FX wireframe overlay, stroke draw-reveal animation, circle cursor, brush persistence, undo/FX cache fixes Phases 27-32 (engine adapter approach) abandoned — deferred to v0.8.0. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2 parents f8c5735 + fc4c735 commit 36ff6f9

File tree

84 files changed

+10431
-693
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

84 files changed

+10431
-693
lines changed

.planning/MILESTONES.md

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,37 @@
11
# Milestones
22

3+
## v0.7.0 Monorepo & Paint Enhancements (Shipped: 2026-04-05)
4+
5+
**Phases completed:** 2 phases, 23 plans, 40 tasks
6+
7+
**Key accomplishments:**
8+
9+
- Renamed Application/ to app/ via isolated git mv with full --follow history, moved lockfile to workspace root, updated .gitignore for monorepo paths
10+
- 1. [Rule 1 - Bug] Removed redundant pnpm.onlyBuiltDependencies from paint package.json
11+
- Full monorepo verification suite — 8 automated checks passed, dev server and Tauri build confirmed working
12+
- Fixed all undo/redo rendering bugs with _notifyVisualChange + FX cache invalidation, enabled immediate FX brush drawing, and implemented 4 UX quick wins (auto-enter paint mode, no-confirm clear, orange exit button, sidebar reorder)
13+
- Brush color/size persist via LazyStore with #203769/35px defaults, plus circle cursor overlay that scales with zoom
14+
- Realtime color picker without Apply/Cancel buttons, no dark overlay, positioned near mouse click with bounds clamping
15+
- 3-mode paint system with flat/FX exclusivity, conversion dialogs, transparent flat background, and layer blend/opacity controls in paint edit mode
16+
- 4-mode inline color picker (Box HSV/TSL/RVB/CMYK) with HEX input, recent + favorite swatches persisted via LazyStore
17+
- Dashed wireframe path and bounding box overlay for selected FX strokes with expanded bounding-box hit testing
18+
- Speed-based stroke animation distributing points across frames with inverse distance weighting and atomic single-Cmd+Z undo
19+
- Fixed infinite re-render loop in InlineColorPicker via useRef guard and restored blend mode functionality in paint edit mode
20+
- FX cache invalidation on clearFrame/color change, color-aware cache keys, activePaintMode with persistence, and mode-aware white/transparent background
21+
- Fixed cursor position offset with high-contrast visibility, strengthened exit button pulsate, modal conversion dialog with dark overlay, and multi-stroke animation support
22+
- InlineColorPicker relocated from sidebar to canvas-adjacent panel with shared paintStore signal for cross-component visibility control
23+
- Per-layer paint mode with brushStyle reset on mode switch, frame content inference, and flat-to-FX stroke batch conversion
24+
- Exit Paint Mode button pulsate animation replaced with glow-only effect (orange-to-red background + box-shadow), scale bounce removed
25+
- Await initFromPreferences before render so brush color/size persist across restart
26+
- paintVersion bump after FX cache refresh in setBrushColor triggers immediate preview re-render without requiring pointer movement
27+
- Fixed circle cursor centering by calculating cursorPos relative to overlayRef instead of containerRef
28+
- Auto-set white bg on FX mode switch with per-frame bgColor persistence in paint sidecar JSON
29+
- Removed createPortal and fixed positioning from InlineColorPicker so it renders inside the CanvasArea 260px flex container
30+
- CSS linear-gradient backgrounds on TSL/RVB/CMYK slider tracks with rAF-throttled drag for smooth interaction
31+
- Simplified brush stroke hit testing to bbox-only selection and verified wireframe renders for all brush types
32+
33+
---
34+
335
## v0.6.0 Various Enhancements (Shipped: 2026-04-03)
436

537
**Phases:** 4 (Phases 22-25) | **Plans:** 14 | **Tasks:** 28

.planning/PROJECT.md

Lines changed: 17 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -88,32 +88,25 @@ Users can import key photographs, arrange them into timed sequences with FX laye
8888
- ✓ Bezier/spline stroke path editing with anchor/handle manipulation — v0.6.0
8989
- ✓ Add, move, and delete bezier control points on existing strokes — v0.6.0
9090
- ✓ Stroke list panel with drag-reorder, delete, selection sync, and visibility toggle — v0.6.0
91+
- ✓ Paint undo/redo FX cache invalidation and visual refresh for all operations — v0.7.0 Phase 33
92+
- ✓ Brush preferences persistence (color, size) with session restore — v0.7.0 Phase 33
93+
- ✓ Circle cursor overlay at brush size with zoom scaling — v0.7.0 Phase 33
94+
- ✓ 3-mode paint system (flat/FX/physical-placeholder) with per-frame mode exclusivity — v0.7.0 Phase 33
95+
- ✓ Inline color picker with 4 modes (Box/TSL/RVB/CMYK) and swatches — v0.7.0 Phase 33
96+
- ✓ Modal color picker: no buttons, no overlay, positioned near mouse — v0.7.0 Phase 33
97+
- ✓ FX stroke wireframe overlay for selection visibility — v0.7.0 Phase 33
98+
- ✓ Stroke draw-reveal animation with speed-based distribution — v0.7.0 Phase 33
99+
- ✓ Inline color picker positioned adjacent to canvas (left panel, 260px) — v0.7.0 Phase 33
91100

92101
### Active
93102

94-
- [ ] pnpm monorepo scaffold with `app/` and `packages/efx-physic-paint/`
95-
- [ ] Replace `perfect-freehand` + `p5.brush` with `@efxlab/efx-physic-paint` physics brush engine
96-
- [ ] Connect existing paint features to new engine API (strokes, FX styles, eraser, onion skinning)
97-
- [ ] Paper/canvas texture support via `efx-physic-paint`
98-
- [ ] Transparency layer support via `efx-physic-paint`
99-
- [ ] New JSON brush format integration
100-
- [ ] Brush caching, re-render, and physics integration
101-
- [ ] Adapt `efx-physic-paint` API for editor-specific requirements
103+
- [ ] efx-physic-paint as standalone window with transport to editor (v0.8.0)
102104

103-
## Current Milestone: v0.7.0 Pure Monorepo & Paint Engine Swap
105+
## Latest Milestone: v0.7.0 Monorepo & Paint Enhancements (Shipped 2026-04-05)
104106

105-
**Goal:** Convert to pnpm monorepo with `efx-physic-paint` as a workspace package, then replace the `perfect-freehand` + `p5.brush` painting engine with the new physics-based paint engine.
107+
2 completed phases (26, 33), 23 plans, 112 commits. Phases 27-32 failed (adapter approach abandoned — efx-physic-paint deferred to v0.8.0 as standalone window). See `.planning/MILESTONES.md` for details.
106108

107-
**Target features:**
108-
- Monorepo scaffold: root `package.json`, `pnpm-workspace.yaml`, lockfile migration, rename `Application/` to `app/`, copy `efx-physic-paint` into `packages/`
109-
- Replace `perfect-freehand` + `p5.brush` with `@efxlab/efx-physic-paint` brush engine (physics, transparency, animation support)
110-
- Connect existing paint features (stroke rendering, FX brush styles, eraser, onion skinning) to the new engine API
111-
- Paper/canvas texture support and transparency layers via `efx-physic-paint`
112-
- Brush caching, re-render, and physics integration
113-
- New JSON brush format support
114-
- Adapt `efx-physic-paint` API where needed for editor-specific requirements
115-
116-
## Latest Milestone: v0.6.0 Various Enhancements (Shipped 2026-04-03)
109+
## Previous Milestone: v0.6.0 Various Enhancements (Shipped 2026-04-03)
117110

118111
4 phases, 14 plans over 8 days. See `.planning/MILESTONES.md` for details.
119112

@@ -130,13 +123,11 @@ Users can import key photographs, arrange them into timed sequences with FX laye
130123

131124
## Context
132125

133-
Shipped v0.6.0 with ~40,688 LOC TypeScript across 107 commits since v0.5.0 (8 days).
134-
Tech stack: Tauri 2.0, Preact + Preact Signals, Motion Canvas (@efxlab v4.0.0), Vite 5, Tailwind CSS v4, pnpm, p5.brush (standalone), fit-curve, bezier-js.
135-
Architecture: 13 reactive signal stores, Rust image pipeline, Canvas 2D PreviewRenderer with multi-layer compositing (including paint layers with per-frame FX cache and bezier-aware rendering), WebGL2 GPU blur/GLSL runtime/motion blur, p5.brush adapter for spectral pigment mixing, bezierPath.ts math module (10 pure functions for curve conversion, sampling, editing), StrokeList component with SortableJS, PaintOverlay with pen tool bezier interaction system, perfect-freehand brush engine, paint sidecar JSON persistence, sub-frame accumulation export pipeline, command-pattern undo/redo engine with snapshot-before/commit-on-release pattern for all transform gestures, tinykeys keyboard shortcuts, exportRenderer with FFmpeg encoding.
126+
Shipped v0.7.0 with 112 commits across 80 files (10k insertions). pnpm monorepo with app/ + packages/efx-physic-paint/. Paint engine enhanced with 3-mode system (flat/FX/physical), inline 4-mode color picker, wireframe overlay, stroke animation, circle cursor, and brush persistence.
127+
Tech stack: Tauri 2.0, Preact + Preact Signals, Motion Canvas (@efxlab v4.0.0), Vite 5, Tailwind CSS v4, pnpm workspaces, p5.brush (standalone), perfect-freehand, fit-curve, bezier-js.
128+
Architecture: 13 reactive signal stores, Rust image pipeline, Canvas 2D PreviewRenderer with multi-layer compositing (including paint layers with per-frame FX cache and bezier-aware rendering), WebGL2 GPU blur/GLSL runtime/motion blur, p5.brush adapter for spectral pigment mixing, 3-mode paint system with per-frame mode exclusivity, inline color picker with LazyStore persistence, bezierPath.ts math module, StrokeList with SortableJS, PaintOverlay with pen/bezier interaction, paint sidecar JSON persistence, sub-frame accumulation export pipeline, command-pattern undo/redo engine, tinykeys shortcuts, exportRenderer with FFmpeg encoding.
136129
Project format: .mce v15 with backward compatibility (v1 through v15).
137130

138-
v0.7.0 context: `efx-physic-paint` (v0.1.0) is a standalone physics-based paint engine at `~/Dev/efx-physic-paint`. It supports physics brush rendering, transparency, animation, and a JSON brush format — but has no bezier editing. It will be copied into `packages/efx-physic-paint/` as a workspace package. `Application/` will be renamed to `app/`. The `perfect-freehand` + `p5.brush` stack will be replaced by the new engine. Bezier path editing (fit-curve, bezier-js) remains in the editor.
139-
140131
Known technical debt:
141132
- S key shortcut lacks isPaintEditMode() guard (low severity) — from v0.6.0
142133
- 2 medium-severity export edge cases (content-overlay image preload, FX generator frame offset) — carried from v0.2.0
@@ -221,4 +212,4 @@ This document evolves at phase transitions and milestone boundaries.
221212
4. Update Context with current state
222213

223214
---
224-
*Last updated: 2026-04-03 after starting v0.7.0 milestonemonorepo & paint engine swap*
215+
*Last updated: 2026-04-05 after Phase 33 complete — paint engine enhanced with bug fixes, 3-mode system, inline color picker, wireframe overlay, stroke animation*

.planning/REQUIREMENTS.md

Lines changed: 32 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,22 @@
2323
- [ ] **ENGN-05**: Per-frame FX cache with aggressive caching -- engine rendering is not real-time, all frames pre-rendered and cached for playback and animation propagation
2424
- [ ] **ENGN-06**: Old v0.6.0 project strokes render via existing Canvas 2D flat brush path; default brush preset for new strokes is **flat**
2525

26+
### Enhanced Current Engine
27+
28+
- [ ] **ECUR-01**: `Cmd+Z` after any paint operation (draw, clear, undo in FX mode) immediately re-renders canvas with correct visual state for both flat and FX strokes
29+
- [x] **ECUR-02**: Selecting an FX brush style (watercolor, ink, charcoal, pencil, marker) in FX mode actually paints in that style during drawing — no manual reselection required
30+
- [x] **ECUR-03**: Brush color and size persist across sessions in app preferences, defaulting to `#203769` at 35px
31+
- [x] **ECUR-04**: Paint brush shows a circle cursor at the current brush pixel size, scaling with canvas zoom (Photoshop behavior)
32+
- [ ] **ECUR-05**: Creating a new paint layer auto-switches to paint edit mode (equivalent to pressing `[p]`)
33+
- [ ] **ECUR-06**: "Clear Brush" button deletes all strokes on current frame; `Cmd+Z` properly undoes clear and re-renders
34+
- [x] **ECUR-07**: "Exit Paint Mode" button is larger and styled in orange with CSS pulsate color animation
35+
- [ ] **ECUR-08**: STROKES panel moves before SELECTION panel in sidebar ordering
36+
- [x] **ECUR-09**: Three brush modes in UI (Paint flat, FX Paint, Physical Paint grayed-out placeholder) with per-frame mutual exclusivity and conversion dialogs
37+
- [x] **ECUR-10**: Inline color picker on canvas side with 4 modes (Box/TSL/RVB/CMYK), HEX input, auto-apply, recent colors + saved favorites in persistent swatches
38+
- [ ] **ECUR-11**: Modal color picker removes Apply/Cancel buttons (realtime apply), removes dark overlay, opens near mouse position clamped to window bounds
39+
- [ ] **ECUR-12**: Selected FX stroke shows visible wireframe/path overlay for easy grab; transform bounding box for move within selection bounds
40+
- [x] **ECUR-13**: Stroke draw-reveal animation distributes selected stroke's points across target frame range using speed-based distribution (slow drawing = more frames, fast = fewer); single atomic undo
41+
2642
### Paint Tools
2743

2844
- [ ] **PAINT-01**: User can draw freehand strokes with pressure sensitivity via physics engine
@@ -84,6 +100,19 @@
84100
| ENGN-04 | Phase 28 | Pending |
85101
| ENGN-05 | Phase 28 | Pending |
86102
| ENGN-06 | Phase 28 | Pending |
103+
| ECUR-01 | Phase 33 | Pending |
104+
| ECUR-02 | Phase 33 | Complete |
105+
| ECUR-03 | Phase 33 | Complete |
106+
| ECUR-04 | Phase 33 | Complete |
107+
| ECUR-05 | Phase 33 | Pending |
108+
| ECUR-06 | Phase 33 | Pending |
109+
| ECUR-07 | Phase 33 | Complete |
110+
| ECUR-08 | Phase 33 | Pending |
111+
| ECUR-09 | Phase 33 | Complete |
112+
| ECUR-10 | Phase 33 | Complete |
113+
| ECUR-11 | Phase 33 | Pending |
114+
| ECUR-12 | Phase 33 | Pending |
115+
| ECUR-13 | Phase 33 | Complete |
87116
| PAINT-01 | Phase 29 | Pending |
88117
| PAINT-02 | Phase 29 | Pending |
89118
| PAINT-03 | Phase 29 | Pending |
@@ -104,10 +133,10 @@
104133
| PERS-03 | Phase 32 | Pending |
105134

106135
**Coverage:**
107-
- v0.7.0 requirements: 30 total
108-
- Mapped to phases: 30
136+
- v0.7.0 requirements: 43 total
137+
- Mapped to phases: 43
109138
- Unmapped: 0
110139

111140
---
112141
*Requirements defined: 2026-04-03*
113-
*Last updated: 2026-04-03 after roadmap creation*
142+
*Last updated: 2026-04-05 after adding ECUR requirements for Phase 33*

0 commit comments

Comments
 (0)