Repository navigation
Commit 4bae34d
refactor(engine,editor): replay + adjustment-editor seam splits, ported to origin (#212)
* refactor(editor): split adjustment editor into adjustmentEditors/ modules (Batch B/B-11)
Pure code motion: the 2,405-line AdjustmentEditor.tsx becomes a 15-line definition shell (same four named exports, dispatcher body verbatim, CSS import once) plus 24 modules under adjustmentEditors/ (every module <=400 lines; largest 322). LegacyAdjustmentEditor (807 lines) is split into a runtime hook (hooks and hueSaturationRange state stay in the base order) plus four plain phase renderers that keep the switch's case bodies verbatim; the nested LutEditor stays nested so its remount semantics are unchanged. HalftoneEditor (446 lines) becomes a hook, a shell with the S1-S5 JSX verbatim, and an unconditionally mounted advanced phase so the disclosure state lifetime is unchanged. BooleanRow, AdjustmentEditorProps, the family editors, the color converters, and the halftone options each get exactly one home; the original path re-exports the moved public names by name.
Proof: refactor-verify --base master --dest .../adjustmentEditors exit 0 {ok:true, baseCount:24, presentCount:33, missing:[], missingExports:[]}; covering suite AdjustmentEditor.test.tsx + AdjustmentPanel.test.tsx 32/32 passed before and after (18/18 direct target, test untouched); direct recursive tsc substitute 22 projects exit 0 with 0 diagnostics; biome clean; audit-health passed; partition proof 2,405 = 50 import-region + 2,307 moved + 23 wrapper + 25 blank lines. Baseline: 0 added, 0 grown, exactly one removed, 945 -> 944; repo map regenerated from the staged tree. No visual surface changed; no e2e/visual/lockfile/manifest/dated-doc changes.
(cherry picked from commit 42207fe)
* refactor(engine): split Canvas2D replay into replay/ modules (Batch C/C-01)
Move the 3,898-line Canvas2D IR replay entry into one module per replay
family plus orchestrator phases under packages/engine/src/replay/. The entry
keeps its path and public surface as a 371-line orchestrator: the COMPLEXITY
header, the four per-replay state bindings (now exported for sibling reads),
the 281-line replayIr item pass, the two existing re-export statements and six
explicit re-exports of the moved public names.
Destination modules (all <=400 lines; largest text.ts 370, typography 355,
effect 317, backdrop 312, primitive 290): types, color, isolatedSurface,
primitive (paintShapeFill with its per-kind monomorphic switch, traceOutline,
traceSquirclePath, paintPathFill, TAU), primitiveBounds, effect,
effectDiagnostics, alphaMask, backdrop (shadowOps/alphaStrokeOps, backdrop
blur, glass material), backdropCache, fill, fillImage, fillImageMask, table,
raster, text (paintText dispatch), textRich, textCanonical, textPath,
typography. No dispatch table, no renames, no behavior change.
Proof: extraction script asserted 107/107 block assignment, source tiling
identity and the 400-line cap before writing; independent verifier vs
git show 8082741 reports base statements 107 = after statements 107 + 6
planned re-exports, AST-printer identity missing 0/extra 0, comments 238/238
exact (18 exact-text diffs are biome line-rewrap only); planned edits are
export prefixes and 14 inline import() specifier rebases. refactor-verify
--base master --dest packages/engine/src/replay exits 0 ({ok:true,
baseCount:105,presentCount:105,missing:[],missingExports:[]}) before tests and
after biome.
Covering set unchanged: replay.test.ts 10/10, replay*.test.ts 29 files/224
tests, __goldens__ 3 files/12 tests, before and after, 0 failures; no test
file edited. Direct recursive tsc substitute (20 package tsconfigs +
apps/desktop + tests/e2e): 22 projects/0 failures before and after; engine
tsc 0; biome clean on 21 files; audit-health exit 0; audit:emoji,
audit:committed-imports and the staged commit checkpoint pass.
Batch C benchmark: canonical replay bench before/after 100 and 1,000 rects
plus an extended same-harness 10k/50k measurement (temporary untracked copy,
removed before staging); audit-render-perf --ci before PASS and after two
quiet runs PASS with no performance baseline regeneration (one intermediate
loaded run flagged only the sub-millisecond 100-node panZoom ratio boundary
and was re-verified). Architecture cycle identity delta recorded in
SEAM_SPEC.md (engine madge identities 11 -> 19; the pre-existing
audit-architecture gate was already red from B-05, no allowlist update).
Baseline: added 0, grown 0, removed exactly packages/engine/src/replay.ts,
944 -> 943; report 6,333 scanned / 943 frozen / 0 stale / 0 WIP / 289,430
excess lines. Worktree .worktrees/C-01, branch seam/C/C-01-replay created
from seam/B/B-11-adjustment-editor 9c9da88 and rebased onto local master
39e9be0 (HEAD 8082741); local master was not advanced. No visual surface
changed; front-end gate not triggered and visual validation not required.
(cherry picked from commit 2bf4871)
* fix(engine): break replay split cycles without behavior change
(cherry picked from commit 7694e7a)
---------
Co-authored-by: Kevin Arthur <hello@kevinarthur.design>1 parent 3bbe2ae commit 4bae34d
57 files changed
Lines changed: 8172 additions & 6013 deletions
File tree
- packages
- editor/src/components/AdjustmentLayer
- adjustmentEditors
- halftone
- legacy
- engine/src
- replay
- remediation
- B-11
- C-01
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
| 122 | + | |
| 123 | + | |
| 124 | + | |
| 125 | + | |
| 126 | + | |
| 127 | + | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
0 commit comments