A copy grid with its own cells that lost the row its main removed, and
grew one back to hold its children, fitted its cells into the fewer
tracks first. Its authored empty cell (`align-self :end` at row 2,
column 2) was merged into an occupied one and lost (F594). User
decision: the cell keeps its place.
`assign-inherited-grid-cells` now grows the track lists its children
need before fitting the cells (`grow-for-children`), so a grid that
grows back the tracks it lost keeps its cells where they were. Only the
track lists grow; the cells it holds keep their places.
Found by a fresh gate round (seed 20261117, grid property).
Test: generated
`generated-a-copy-grid-keeps-an-authored-empty-cell-where-it-was-when-it-grows-back`
(JVM and frontend replay).
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 21.906 | 23.299 | 0.62 |
| edit-through-a-chain-of-dependents | 68.931 | 46.008 | 46.834 | 0.67 |
| library-update-into-copies | 83.083 | 53.933 | 55.436 | 0.65 |
| main-edit-among-many-shapes | 4.837 | 2.497 | 2.639 | 0.52 |
| main-edit-into-10-copies | 1.79 | 1.185 | 1.228 | 0.66 |
| main-edit-into-100-copies | 15.415 | 11.262 | 11.561 | 0.73 |
| main-edit-into-1000-copies | 153.086 | 108.966 | 112.568 | 0.71 |
| variant-switch-into-copies | 32.052 | 23.931 | 24.195 | 0.75 |
AI-assisted-by: claude-opus-5-5
After a turn and a fill resize, nested copies sit a few thousandths of a
pixel from where their mains place them. A detach that advanced them,
and a resize that scaled a swapped head by that much, made their
geometry an override for the noise alone: they stopped following their
mains' geometry (F593).
`turned-like-parent?`, the place check of
`generate-keep-advanced-placement` (`close-geometry?` now takes a
precision) and the resize check of `author-resized-swapped-heads`
compare sizes and corners to a hundredth of a pixel, as the rest of sync
compares them. The composable model's `sync-scaled-heads` does the same.
Found by a fresh gate round (seed 20261117, variant property).
Test: generated `generated-a-detach-authors-no-geometry-for-float-noise`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 21.107 | 21.817 | 0.6 |
| edit-through-a-chain-of-dependents | 68.931 | 46.08 | 47.003 | 0.67 |
| library-update-into-copies | 83.083 | 56.955 | 57.969 | 0.69 |
| main-edit-among-many-shapes | 4.837 | 2.37 | 2.545 | 0.49 |
| main-edit-into-10-copies | 1.79 | 1.068 | 1.11 | 0.6 |
| main-edit-into-100-copies | 15.415 | 10.438 | 10.941 | 0.68 |
| main-edit-into-1000-copies | 153.086 | 103.384 | 109.082 | 0.68 |
| variant-switch-into-copies | 32.052 | 24.999 | 25.423 | 0.78 |
AI-assisted-by: claude-opus-5-5
A swapped nested head pasted out of every copy level becomes a plain
copy of the component it shows. It kept as overrides the placement that
differs from its new main, but left the rest as it was: a nil constraint,
the default of its old board, kept meaning something else at the page
root while its main states `:left`, so it no longer matched its main
(F592). Users reach it by copying such a copy and pasting it.
`rehead-swapped` now gives the placement attributes it does not override
the new main's values.
Found by a fresh gate round (seed 20261117, library property).
Test (swap-group-test, fails before the fix):
`paste-gives-a-swapped-head-the-placement-of-its-new-main`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 20.608 | 21.876 | 0.59 |
| edit-through-a-chain-of-dependents | 68.931 | 42.175 | 44.133 | 0.61 |
| library-update-into-copies | 83.083 | 50.77 | 52.63 | 0.61 |
| main-edit-among-many-shapes | 4.837 | 2.352 | 2.51 | 0.49 |
| main-edit-into-10-copies | 1.79 | 1.043 | 1.087 | 0.58 |
| main-edit-into-100-copies | 15.415 | 10.185 | 10.428 | 0.66 |
| main-edit-into-1000-copies | 153.086 | 101.226 | 105.622 | 0.66 |
| variant-switch-into-copies | 32.052 | 22.621 | 23.491 | 0.71 |
AI-assisted-by: claude-opus-5-5
Pasting a copy held in a swapped head inside a copy inside a main left
an invalid file (`:ref-not-in-near-main`). The clipboard advanced each
shape by the number of copy levels it leaves, but the swap above makes
its references reach the component's main one step sooner, so its nested
copies overshot past that main. Users reach it by copying such a copy
and pasting it on the page (F591).
Every copy the clipboard advances now refers each shape to its
counterpart in the main of its component: the first of its content
references there, which a swapped head below follows by its slot. It
keeps the overrides of the references it skips. The level count stays
only as the fallback when a shape finds no counterpart. This generalizes
the case of a swapped reference among those it skips (F590).
Found by a fresh gate round (seed 20261117, variant property).
Test (swap-group-test, fails before the fix):
`paste-out-of-a-swapped-head-reaches-the-nested-copies-of-its-component`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 21.742 | 22.873 | 0.62 |
| edit-through-a-chain-of-dependents | 68.931 | 46.657 | 47.664 | 0.68 |
| library-update-into-copies | 83.083 | 52.163 | 53.121 | 0.63 |
| main-edit-among-many-shapes | 4.837 | 2.34 | 2.519 | 0.48 |
| main-edit-into-10-copies | 1.79 | 1.103 | 1.136 | 0.62 |
| main-edit-into-100-copies | 15.415 | 10.677 | 11.348 | 0.69 |
| main-edit-into-1000-copies | 153.086 | 108.821 | 113.548 | 0.71 |
| variant-switch-into-copies | 32.052 | 21.95 | 22.607 | 0.68 |
AI-assisted-by: claude-opus-5-5
The structure programs now cover what their worlds lacked:
- `:interact` gives a shape on a main, a copy head or a copy child its
prototype interactions (open-URL actions, so no board ties them to
deletions), through the prototype panel's add, edit and remove events
in the frontend replay. Interactions are no sync attribute: the target
must end with what was set, no other operation may change those of a
shape that stays, and a swap or a switch keeps a head's.
- `:paste` also takes a nested copy head a copy holds, which the
clipboard advances to its component's main. The model gives the pasted
shapes the overrides of the references they skip, and drops the swap
of a swapped head, now a plain copy of its component.
- Worlds with `:pages` hold a second page that a paste can land on, and
`:library-paste` pastes library mains and copies into the consumer,
where both become copies of the library's components. Off the current
page or file, the node and the frontend put the pasted corner at the
same free point; the frontend pastes with nothing selected and the
pointer there.
- A transform no longer targets a shape without area, as a union of
hidden shapes, which no transform can size.
Samples of 150 structure, swap and scale programs found F588, F589 and
F590 (fixed) and are then clean.
Harness only; the benchmark is not run.
AI-assisted-by: claude-opus-5-5
An update main that pushes a transformed fill child into the nested copy
its main holds fixes that copy's layout sizing, as a resize does, so the
layout keeps the pushed size. It did not mark the sizing as the nested
copy's own override: the copy differed from its reference without an
override, and the next sync would give it the fill back and undo the
pushed size (F588, reachable since moves are generated).
A main that is itself a copy now touches the sizing groups the push
fixes. The composable model expects it to author them.
Test: generated
`generated-an-update-main-into-a-nested-copy-authors-the-sizing-it-fixes`
(JVM and frontend replay).
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+--------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 21.333 | 22.41 | 0.61 |
| edit-through-a-chain-of-dependents | 68.931 | 42.992 | 44.734 | 0.62 |
| library-update-into-copies | 83.083 | 55.577 | 58.064 | 0.67 |
| main-edit-among-many-shapes | 4.837 | 2.625 | 3.164 | 0.54 |
| main-edit-into-10-copies | 1.79 | 1.131 | 1.216 | 0.63 |
| main-edit-into-100-copies | 15.415 | 11.226 | 12.849 | 0.73 |
| main-edit-into-1000-copies | 153.086 | 103.22 | 108.455 | 0.67 |
| variant-switch-into-copies | 32.052 | 23.27 | 24.267 | 0.73 |
AI-assisted-by: claude-opus-5-5
A nested copy pasted out of its copy, where the main the copy refers to
had swapped that head, advanced its refs by level through the replaced
slot of the old component and passed on the swap, which left an invalid
file (`:ref-shape-not-found`, `:misplaced-swap-group`). Users reach it
by copying such a copy and pasting it on the page (F590).
When the references a pasted head skips include a swapped head, each of
its shapes now refers to its counterpart in the main of the component it
shows, the first of its content references there, and keeps the
overrides of those it skips, without the swap.
Found by the generated programs once they paste nested copies (a
variant program with a swap in a main).
Test (swap-group-test, fails before the fix):
`paste-out-of-a-copy-follows-a-swap-in-its-main`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 21.672 | 24.681 | 0.62 |
| edit-through-a-chain-of-dependents | 68.931 | 43.664 | 46.149 | 0.63 |
| library-update-into-copies | 83.083 | 51.625 | 55.322 | 0.62 |
| main-edit-among-many-shapes | 4.837 | 2.582 | 3.817 | 0.53 |
| main-edit-into-10-copies | 1.79 | 1.063 | 1.179 | 0.59 |
| main-edit-into-100-copies | 15.415 | 10.715 | 11.354 | 0.7 |
| main-edit-into-1000-copies | 153.086 | 104.404 | 110.116 | 0.68 |
| variant-switch-into-copies | 32.052 | 21.823 | 24.319 | 0.68 |
AI-assisted-by: claude-opus-5-5
A nested copy pasted out of its copy advances its refs to the component
it copies and takes the touched groups of the references it skips, so it
keeps the values they gave it. The clipboard also took those of its new
reference: a pasted rect then overrode a fill its new reference itself
overrides, and stopped following that reference's later edits. A shape
with no touched group was also left an empty touched set, which an undo
then removed, so undo did not restore the state exactly (F589).
`advance-copied-objects` takes only the touched groups of the references
between the shape and its new one, and leaves no touched set when there
are none. The golden master's case AZ, which pastes such a copy, records
its states again: its pasted head no longer has an empty touched set.
Test (copying-and-duplicating-test, fails before the fix):
`a-pasted-nested-copy-takes-only-the-overrides-of-the-references-it-skips`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 22.2 | 22.701 | 0.63 |
| edit-through-a-chain-of-dependents | 68.931 | 43.557 | 45.725 | 0.63 |
| library-update-into-copies | 83.083 | 52.452 | 54.294 | 0.63 |
| main-edit-among-many-shapes | 4.837 | 2.766 | 2.895 | 0.57 |
| main-edit-into-10-copies | 1.79 | 1.142 | 1.178 | 0.64 |
| main-edit-into-100-copies | 15.415 | 11.615 | 12.834 | 0.75 |
| main-edit-into-1000-copies | 153.086 | 106.297 | 109.039 | 0.69 |
| variant-switch-into-copies | 32.052 | 23.09 | 23.778 | 0.72 |
AI-assisted-by: claude-opus-5-5
The plugin suite's random case said every settled step retains authored
values, but its programs check only fills and opacity against their own
model: resizes and turns carry no geometry assertions, and no step
undoes, swaps, switches variants, edits text or checks touched groups.
The case is now `RandomFillOpacitySmoke` and says so, pointing to the
generated programs of common and their frontend and WASM replays for the
rest.
Harness only; the benchmark is not run.
AI-assisted-by: claude-opus-5-5
Under one flip a shape can store either of two turns for the same
transform: the one before its flip, which flips and turns produce, or
the opposite one after it, which sync may store when it orients a copy
child under a flipped parent. A transform adds its turn to the stored
rotation, and a flip negates it, as for the turn before the flip, so a
shape storing the other one was left with a rotation its transform does
not have: a child turned 45 degrees after its flip and turned again by
45 stored 90 over a plain flip.
`apply-transform-generic` now first takes, for a mirrored shape with an
unskewed transform, the turn before its flip that the transform gives.
Found by checking the shapes of the pinned generated programs for
rotations and flips that do not compose their transform (program 332:
rotate, flip the parent, rotate it, update main); none is left there but
the skew a layout or a scale constraint gives a turned child.
Test (geom-shapes-test, fails before the fix):
`a-rotation-turns-a-mirror-that-stores-the-turn-after-its-flip`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+--------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 21.448 | 23.648 | 0.61 |
| edit-through-a-chain-of-dependents | 68.931 | 41.076 | 43.132 | 0.6 |
| library-update-into-copies | 83.083 | 54.822 | 56.18 | 0.66 |
| main-edit-among-many-shapes | 4.837 | 2.275 | 2.358 | 0.47 |
| main-edit-into-10-copies | 1.79 | 1.08 | 1.103 | 0.6 |
| main-edit-into-100-copies | 15.415 | 10.411 | 11.35 | 0.68 |
| main-edit-into-1000-copies | 153.086 | 110.32 | 118.294 | 0.72 |
| variant-switch-into-copies | 32.052 | 21.161 | 23.07 | 0.66 |
AI-assisted-by: claude-opus-5-5
A replayed step that navigates replaces the page's query string, so the
replay read its `debug` and `watch` parameters as unset from then on and
logged no shapes at the end of such a program. It reads them once, as
the page loads.
Harness only; the benchmark is not run.
AI-assisted-by: claude-opus-5-5
With the WASM engine, a bool whose children turn measured its path with
an axis-aligned box: a 50 px union turned 45 degrees came out 70.7 px
wide. In a grid, that widened its track and moved its siblings, so a
turned grid copy laid out its children elsewhere than a reflow of the
same grid did, and elsewhere than the persisted changes put them.
`calculate_bool_bounds` now takes the path's extent along the axes of
the bool's bounds, as groups measure theirs; a bool without usable axes
keeps the axis-aligned box.
Found by the WASM replay of the pinned generated programs (program 156,
a turned grid copy holding a union), which passes with it.
Test: render-wasm `test_turned_bool_bounds_keep_its_orientation` (fails
before the fix).
WASM only; the benchmark covers JVM code and is not run.
AI-assisted-by: claude-opus-5-5
A variant switch that carries a turn onto a flipped child gives it the
turn before or after its flips, whichever lies nearer the axes the child
had (`unskewed`). For an unflipped 45-degree turn given a horizontal flip
both lie equally far, and the tie went to the order the engines'
rounding favoured: with the WASM engine the switched child stored
`flipX·R45`, the same shape turned the other way, while its rotation and
flips say `R45·flipX`.
A tie within 1e-9 now takes the turn before the flips, as the function
already intends for axes that tell neither apart.
Found by the WASM replay of the pinned generated programs (program 87, a
switch onto a flipped variant), which passes with it.
Test (comp-expected-geometry-test, fails before the fix with the WASM
engine's axes): `an-unskewed-turn-that-tells-no-flip-apart-turns-before-it`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 22.123 | 22.948 | 0.63 |
| edit-through-a-chain-of-dependents | 68.931 | 41.395 | 43.459 | 0.6 |
| library-update-into-copies | 83.083 | 51.144 | 55.732 | 0.62 |
| main-edit-among-many-shapes | 4.837 | 2.373 | 2.539 | 0.49 |
| main-edit-into-10-copies | 1.79 | 1.047 | 1.091 | 0.58 |
| main-edit-into-100-copies | 15.415 | 10.442 | 10.86 | 0.68 |
| main-edit-into-1000-copies | 153.086 | 105.735 | 109.461 | 0.69 |
| variant-switch-into-copies | 32.052 | 21.661 | 23.984 | 0.68 |
AI-assisted-by: claude-opus-5-5
An ungroup in a grid main ungroups its copies too. A copy with its own
cells gave the shapes the ungroup brings into it its free cells in the
reverse of its own layer order. That matches sync only when the copy
keeps the reverse of its references' order, as under a main, whose grid
the layout update reorders by its cells. A copy of a copy refers to a
copy, which keeps the order the ungroup gives, so its shapes took each
other's cells (F581).
The copy now ranks them by where their references sit in the grid it
refers to; a main's grid is ranked as `ctl/reorder-grid-children` leaves
it. Shapes whose reference is not there follow, in the reverse of the
copy's own order.
Test (composable-gen-test, fails before the fix; the earlier ungroup
tests pass):
`an-ungroup-fills-a-grid-copy-of-a-copy-in-its-references-layer-order`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+--------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 22.348 | 22.994 | 0.63 |
| edit-through-a-chain-of-dependents | 68.931 | 44.01 | 45.457 | 0.64 |
| library-update-into-copies | 83.083 | 51.822 | 52.723 | 0.62 |
| main-edit-among-many-shapes | 4.837 | 2.384 | 2.681 | 0.49 |
| main-edit-into-10-copies | 1.79 | 1.107 | 1.139 | 0.62 |
| main-edit-into-100-copies | 15.415 | 10.509 | 10.797 | 0.68 |
| main-edit-into-1000-copies | 153.086 | 99.974 | 103.416 | 0.65 |
| variant-switch-into-copies | 32.052 | 21.852 | 22.437 | 0.68 |
AI-assisted-by: claude-opus-5-5
The WASM replay's debug log read every shape's content as text, which a
path's content is not; it reads only texts now and logs how many shapes
the page ends with.
Harness only; the benchmark is not run.
AI-assisted-by: claude-opus-5-5
A layout update applied its modifiers and then settled the placement of
the copy shapes they moved, as a transform does. For a swapped head
turned with its main and filling a row, the settle gave back the
unskewed turn of its main and undid the skew the layout gives it, which
its main keeps (F441: a swapped head turned to fill takes the skew of
its main).
A layout update no longer settles placement (`apply-modifiers` and
`apply-wasm-modifiers` take `:settle-component-placement? false`); a
transform still does. The composable model's reflow, which settled
placement since `bac1443729` to match the old update, no longer does:
with it, layout and settle undid each other and never settled.
Test: frontend generated
`generated-a-turned-fill-swap-keeps-the-skew-its-row-gives`.
ClojureScript only; the benchmark covers JVM code and is not run.
AI-assisted-by: claude-opus-5-5
With the WASM engine, a grid track sized a fill child by its minimum
width alone, so a fill child that is itself a grid shrank to its cell
and its content overflowed it. The CLJS engine sizes the track by the
larger of that minimum and the size the child's content needs, as CSS
gives a grid item its min-content size (user decision: match CLJS).
`min_size` now takes, for a fill grid child, its content size: its
tracks at the sizes its children need, its gaps and its paddings, as a
grid that hugs sizes itself.
Found by the WASM replay of the pinned generated programs (program 290,
a fill grid turned 45 degrees in a grid), which passes with it.
Test: render-wasm `test_a_fill_grid_child_takes_the_size_its_content_needs`.
WASM only; the benchmark covers JVM code and is not run.
AI-assisted-by: claude-opus-5-5
The content bounds of a grid or flex layout, which size a fill child
that is itself a layout and a layout that hugs, read the four stored
paddings. A simple padding type repeats the top and right values on the
bottom and left, so a layout whose sides were edited one by one before
its type was set to simple measured its content with the stale left and
bottom values: a fill grid with paddings 3, 6, 9 and 12 came out 6 px
wider than its content.
Both use `ctl/paddings`, as the layouts themselves do.
Test: `geom-grid-layout-test/grid-content-bounds-take-simple-paddings`
(fails before the fix).
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+--------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 22.925 | 23.239 | 0.65 |
| edit-through-a-chain-of-dependents | 68.931 | 45.225 | 46.994 | 0.66 |
| library-update-into-copies | 83.083 | 54.842 | 57.554 | 0.66 |
| main-edit-among-many-shapes | 4.837 | 2.528 | 2.705 | 0.52 |
| main-edit-into-10-copies | 1.79 | 1.136 | 1.163 | 0.63 |
| main-edit-into-100-copies | 15.415 | 10.746 | 11.596 | 0.7 |
| main-edit-into-1000-copies | 153.086 | 109.63 | 113.323 | 0.72 |
| variant-switch-into-copies | 32.052 | 23.103 | 24.367 | 0.72 |
AI-assisted-by: claude-opus-5-5
Two turned-shape programs of the frontend replay differed from the
composable model:
- Setting a turned variant to fill in its hugging variant board: the
sidebar fixes the board's width first, the model's property edit did
not, and a layout pass of a fill child in a hugging row collapses a
turned child before growing it, which left it a singular transform.
The model's edit of a layout child now applies the same sizing fixes
(`cls/fix-child-sizing`, `cls/fix-parent-sizing`).
- A swapped head turned with its main, filling a row: the frontend's
layout update settles the placement of the copy shapes it moves, which
gives the head its main's unskewed turn; the model's reflow did not,
and kept the layout's skew. The model's reflow settles them too
(`cll/generate-sync-transformed-placement`).
Both programs now pass in the frontend replay with WASM off (frontend
generated tests).
Harness only; the benchmark is not run.
Also in this commit:
- Log each shape's parent id in the WASM replay's debug output. The debug log
named each shape's parent, which copies and their mains share; it now gives
the parent's id too, so a subtree can be told apart from its copies'.
AI-assisted-by: claude-opus-5-5
`fix-child-sizing` and `fix-parent-sizing` give a layout's children and
parent the sizing a hugging layout allows when the sidebar edits a
layout child. They move from the frontend's shape layout events to
`app.common.logic.shapes`, unchanged, so the composable model can apply
them as the sidebar does.
No behavior change; the benchmark covers sync and is not run.
AI-assisted-by: claude-opus-5-5
A masked group takes all its geometry from its mask. When a copy turned
the mask of a masked group, a sync gave the copy's group the geometry of
its main's group, square to the page, and fitted only the group's
parents, so the group no longer matched its turned mask; a reflow then
fitted it again, and settling and a full sync gave different files.
After a sync writes a masked group's attributes, the group fits its mask
again along with its parents.
Test: generated `a-synced-masked-group-fits-the-mask-its-copy-turned`
(fails before the fix).
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+--------+--------|
| deepest-edit-through-three-levels | 35.215 | 22.245 | 23.118 | 0.63 |
| edit-through-a-chain-of-dependents | 68.931 | 43.743 | 44.839 | 0.63 |
| library-update-into-copies | 83.083 | 54.447 | 57.814 | 0.66 |
| main-edit-among-many-shapes | 4.837 | 2.742 | 2.876 | 0.57 |
| main-edit-into-10-copies | 1.79 | 1.077 | 1.135 | 0.6 |
| main-edit-into-100-copies | 15.415 | 10.488 | 11.093 | 0.68 |
| main-edit-into-1000-copies | 153.086 | 106.222 | 112.37 | 0.69 |
| variant-switch-into-copies | 32.052 | 23.155 | 23.929 | 0.72 |
AI-assisted-by: claude-opus-5-5
Since F570 a flip moves a shape's radius tokens with the corners they
apply to. The composable model kept the tokens of a copy's authored
radius on the corners they named before the flip, so a flipped copy
that had set one corner by hand failed I9.
After each step and each settle, the model's authored radius takes the
tokens in the orientation the shape ends with
(`shadow/radius-orientation`). The token property passes at 300
programs.
Test: generated `a-flip-moves-the-radius-tokens-a-copy-authored`.
Harness only; the benchmark is not run.
Also in this commit:
- Block a shape the model moves into a blocked board. A move relocates a shape
as a nest does, and a shape relocated into a blocked parent is blocked, an
override on a copy. The composable model applied that to nests only, so moving
a copy into a board blocked by hand failed I2.
- Predict a mask's move through the group it moves. The composable model
predicts where a transformed shape lands. The mask of a masked group passes
its change to the group, so the prediction applied the change to the mask
alone and skipped the modifier tree. A flex that places the group puts it back
after the move, so moving the mask of such a group left it where it was, and
the prediction failed I9.
- Compare a pasted copy with the main its file accepted. The composable model
expects a copy pasted on the page to author the geometry it shows when that
differs from its main's. It read the main as loaded, so in a stale library
world, after the library resized a main the file had not accepted, a pasted
copy showing the accepted size was expected to author it, and the property
failed I3.
AI-assisted-by: claude-opus-5-5
Converting a rect to a path gave an outline that went back to its start
with a line and stayed open, so a stroke missed its join at the first
corner. With the WASM engine on, the engine converts the rect and closes
the outline, so the two engines gave different paths for one shape.
The rect's outline now ends with `close-path`, as the WASM engine's does
(user decision). The path editor closes subpaths its own way on entry,
which its lifecycle test now expects.
Found by the WASM replay of the pinned generated programs (program 329),
which passes with the change.
Tests: `path-data-test/shape-to-path-rect-closes-its-outline`.
The conversion is outside the paths the component benchmark measures;
it is not run.
AI-assisted-by: claude-opus-5-5
With WASM on, a pure move skips the engine unless a moved shape is in a
layout's flow. A shape moved inside a group or bool that a layout places
took that shortcut: the group grew to it and stayed where the move left
it, where the CLJS engine's layout puts the group back in its place.
The check now walks up through the groups and bools around a moved
shape, and a move whose group a layout places goes through the engine.
Found by the WASM replay of the pinned generated programs (program 169,
`{:world [1 0 {:layout :flex :layout-children true}] :ops [[:structure
0 0 19] [:transform 10 0 0 12]]}`), which passes now; the WASM path does
not run in the node tests.
ClojureScript only; the benchmark covers JVM code and is not run.
AI-assisted-by: claude-opus-5-5
A bool whose only child was a group kept, after ungrouping that group,
the content it had made of the group: the outlines of its shapes one
after the other, not the boolean result of them. The next refit of the
bool, such as the undo of a later edit of one of its shapes, recomputed
it, so that undo did not give back the state before the edit.
An ungroup now refits the group or bool around the ungrouped shape, with
the undo values of the refit.
Tests: `groups-test/ungrouping-a-group-in-a-bool-combines-its-shapes-again`
(fails before the fix), generated
`an-ungroup-in-a-bool-combines-its-shapes-again`.
The ungroup is outside the paths the component benchmark measures; it is
not run.
AI-assisted-by: claude-opus-5-5
The composable model carried a switched copy's geometry onto the new
head as a plain value, while the other carried shapes keep the parent
whose later resizes size them. Resizing the copy that holds the head then
scaled it through its constraint in production, and the model expected
its old size.
The head now carries its geometry with its parent too, its size only:
its place is its position's.
Test: generated `a-switched-head-in-a-copy-scales-with-its-parent`.
Harness only; the benchmark is not run.
Also in this commit:
- Draw 100 programs per random property on the JVM. The coverage check of a
random composition test asks each kind for 0.5% of the run's changes. At 50
programs a seed could draw a kind too few times: the stale library property
drew its child removal 4 times, all changing state, and failed its check while
its property passed. At 100 programs that seed passes, and the shares vary
less.
AI-assisted-by: claude-opus-5-5
Update main of a copy that swapped a nested copy, pushed inside a copy of
the main, puts the swapped shapes in the position's place and points them
at the position's subtree. Their differing content became overrides, but
their constraints did not: a pushed icon kept the copy's fixed scroll
while its new reference scrolls fixed, untouched and different from its
main.
A shape pushed below the head now marks its constraints group when its
constraints differ from those of its new reference, keeping what the copy
showed, as the head already does. The composable model expects that
override.
Test: generated
`an-update-main-of-a-swap-keeps-the-constraints-its-children-showed`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 21.399 | 22.081 | 0.61 |
| edit-through-a-chain-of-dependents | 68.931 | 41.679 | 43.499 | 0.6 |
| library-update-into-copies | 83.083 | 50.272 | 54.817 | 0.61 |
| main-edit-among-many-shapes | 4.837 | 2.258 | 2.591 | 0.47 |
| main-edit-into-10-copies | 1.79 | 1.034 | 1.071 | 0.58 |
| main-edit-into-100-copies | 15.415 | 10.439 | 11.139 | 0.68 |
| main-edit-into-1000-copies | 153.086 | 101.545 | 105.155 | 0.66 |
| variant-switch-into-copies | 32.052 | 23.541 | 24.772 | 0.73 |
AI-assisted-by: claude-opus-5-5
A radius token names a corner as its shape shows it, but a copy mirrored
unlike its main inherited the main's corners as they were. A token value
edit then rounded the corner the main keeps square: the copy's tokens
named its other corners.
A flip now moves a shape's radius tokens with the corners they apply
to, and a transform writes them without making them an override. Sync,
reset, update main and a switch carry tokens into the orientation the
destination ends with (`ctsr/tokens-in-orientation`,
`cll/oriented-by`). The composable oracle compares a copy's radius
group with its main's in the copy's orientation.
Tests: `token-apply-test/a-flip-moves-a-radius-token-with-its-corner`,
generated `a-token-edit-keeps-the-square-corner-of-a-mirrored-copy`.
Benchmark (bench-components, alone):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+---------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 22.352 | 23.145 | 0.63 |
| edit-through-a-chain-of-dependents | 68.931 | 44.184 | 45.036 | 0.64 |
| library-update-into-copies | 83.083 | 52.481 | 54.229 | 0.63 |
| main-edit-among-many-shapes | 4.837 | 2.354 | 2.498 | 0.49 |
| main-edit-into-10-copies | 1.79 | 1.031 | 1.1 | 0.58 |
| main-edit-into-100-copies | 15.415 | 10.729 | 10.946 | 0.7 |
| main-edit-into-1000-copies | 153.086 | 103.496 | 105.968 | 0.68 |
| variant-switch-into-copies | 32.052 | 23.207 | 23.7 | 0.72 |
AI-assisted-by: claude-opus-5-5
Pushing a grid copy's column direction to its main left the main's
children in their row order, and pushing a copy's grid cells left the
main's children where they were before, outside the cells they took. A
sync reflows the layouts of the copies it changes, but `update-component`
reflowed none, so the main never laid out again.
It now emits a layout update for the frames its changes touch in the
current file, the main's among them when its component is local, in the
undo group of the update.
Test: frontend generated
`generated-an-update-main-of-a-grid-direction-orders-the-main-by-it`.
The frontend golden master of `case-ak-update-main-pushes-grid-cells` is
recorded again: its main and copy children now sit at their cells, where
they were left stacked outside their boards.
ClojureScript only; the benchmark covers JVM code and is not run.
AI-assisted-by: claude-opus-5-5
Ungrouping a board in a grid main whose copies are ungrouped alike took
two Ctrl+Z to undo: the first only moved the copies' children back. The
layout update after the ungroup stacks onto its history entry with an
undo group of its own, which the entry records among the groups stacked
into it. The component sync that update causes commits later under that
group without stacking, and `append-undo` gave it a new entry when the
matching entry was the latest. Undo walks entries by their own undo
group, so the new entry was undone alone.
Such a commit now joins the entry that holds its group among the stacked
ones. Commits of one group in a row still keep their entries, which undo
walks together.
Tests: `workspace-undo-test/a-delayed-commit-joins-the-entry-its-group-
was-stacked-into` (fails before the fix), `adjacent-commits-of-one-group-
keep-their-entries`, and the frontend generated `generated-an-ungroup-in-
a-grid-main-undoes-in-one-step`.
ClojureScript only; the benchmark covers JVM code and is not run.
AI-assisted-by: claude-opus-5-5
The frontend interpreter recorded three library steps unlike the pure
runner, so three replayed programs differed from the model with no
difference in production:
- A detach leaves a nested copy's child plain when the loaded library no
longer has its main; the interpreter now records those children, as the
detach node does, and the oracle reads each as its main's child.
- A duplicate takes the reference inputs of the shapes it copies, so a
duplicate of a copy back on an older library holds that version.
- A library sync remembers its copies against the synced library as
loaded and the other libraries as accepted.
The detach node and the interpreter share `n/record-unlinked-children`.
Frontend generated tests replay the three programs.
Harness only; the benchmark is not run.
AI-assisted-by: claude-opus-5-5
Two dashboard templates, Avataaars and Tutorial for beginners, hold the
filter attribute of some shapes as a map an old reader split out of its
text, as `{:url(#filter_2) nil}` for `url(#filter_2)`. The svg attribute
schema takes only scalars outside `:style`, so their import failed the
file validation after migrating.
Migration 0039 turns such a map back into the reference to one of the
shape's defs it names, matched to the defs id as stored though 0035 may
have kebab-cased the map, and drops any other map value. Both templates
then import valid, with their filters.
The benchmark is not run: the change is a file migration.
AI-assisted-by: claude-opus-5-5
The model kept the geometry a shape authored relative to the parent it
authored it in. A move keeps where and how the shape shows, so moved into
a turned board it was expected turned with it, where production keeps
its turn on the page. The model records the authored geometry again in
the shape's new parent after a move.
Harness only; the benchmark is not run.
Also in this commit:
- Draw fewer random programs in JS and check coverage on the JVM. The random
composition properties drew 50 programs in JS as on the JVM, which made the JS
run of the common tests take about two and a half hours. JS runs the same
model and production code, so it now draws 15 programs per property as a
parity check, and the coverage shares, which need the JVM's 50 programs to
tell, are asserted on the JVM only.
AI-assisted-by: claude-opus-5-5
An update main that adds a copy's new shape to the main makes the
differences between the pushed shape and its new reference authored. A
pasted shape holds empty fill and stroke lists where its main holds none,
so pushing it marked its fills and strokes overridden though nothing
shows differently. No fills or strokes and an empty list of them are the
same there.
Benchmark (bench-components, run alone):
| world | baseline | now | mean | ratio |
|------------------------------------+----------+---------+---------+-------|
| deepest-edit-through-three-levels | 35.215 | 24.875 | 25.599 | 0.71 |
| edit-through-a-chain-of-dependents | 68.931 | 47.991 | 52.684 | 0.7 |
| library-update-into-copies | 83.083 | 60.901 | 62.895 | 0.73 |
| main-edit-among-many-shapes | 4.837 | 3.193 | 3.451 | 0.66 |
| main-edit-into-10-copies | 1.79 | 1.199 | 1.252 | 0.67 |
| main-edit-into-100-copies | 15.415 | 10.375 | 11.472 | 0.67 |
| main-edit-into-1000-copies | 153.086 | 113.348 | 121.731 | 0.74 |
| variant-switch-into-copies | 32.052 | 23.113 | 24.522 | 0.72 |
AI-assisted-by: claude-opus-5-5
With `PENPOT_REPLAY_PROGRAMS` naming an EDN file of programs, a frontend
generated test replays each of them and logs its own results, which
compares the frontend with the model on many programs without a browser.
Without it the test does nothing.
Harness only; the benchmark is not run.
Also in this commit:
- Give the generated text component a measurable size. The generated worlds'
text component had a board and a text of a hundredth of a pixel, where turning
or moving them left the transform to float noise and the checks reported
differences no design shows. The board is 100 by 100 and the text 100 by 20;
`add-frame-with-text` sets up its text with the size its child params give.
AI-assisted-by: claude-opus-5-5
Saving a token from its form committed the edit, then propagated the new
value to the shapes in an undo transaction of its own, opened only once
the tokens resolved. One undo reverted the shapes and left the token with
its new value.
The propagation opens its transaction before the tokens resolve, and the
form commits the edit and the propagation in one transaction, which the
propagation's nests in. The frontend replay commits a token edit as the
form does.
The benchmark covers JVM code; this change is ClojureScript only, so it
is not run.
AI-assisted-by: claude-opus-5-5
A bool takes the bounds of its result, smaller than those of the shapes
it combines for an intersection, but creating it did not update the
layout it is in, so in a grid board it kept a place the layout does not
give it. It now updates the layout of its parent, as grouping does.
The benchmark covers JVM code; this change is ClojureScript only, so it
is not run.
AI-assisted-by: claude-opus-5-5
Unmasking a group gives it the bounds of all its children instead of its
mask's, but the event did not update the layout the group is in, so in a
flex or grid board it kept the place of its old bounds and overlapped its
neighbours. It now updates the layouts of the groups' parents, as group,
mask and ungroup do.
The benchmark covers JVM code; this change is ClojureScript only, so it
is not run.
AI-assisted-by: claude-opus-5-5
`oracle/inequivalence` compared a shape's values on their own, so the
geometry tolerance of `equivalent?` did not apply and float noise was
named as the first difference. Each key is compared within the shape it
belongs to.
Harness only; the benchmark is not run.
Also in this commit:
- Replay layout, structure and grid track edits as the UI does. The frontend
interpreter set a layout's gap, padding and item alignment and a layout
child's margin with a plain shape update, where the sidebar goes through the
layout events that reflow the layout; a copy then kept its children where the
old gap put them. It dispatches those events now.
- Watch the targets of a replayed program in the browser. With `watch`, the
browser replay logs the events the store handles and each move of the shapes
the program's operations target.
AI-assisted-by: claude-opus-5-5
A fill child of a grid takes the size of its content, which the grid's
fill then fits to its cell. An absolute child is not filled by the grid,
and the content of a grid whose flex columns span its width is that width
and its padding, so an absolute fill board of a grid grew by its padding
at every layout pass and never settled.
An absolute child keeps its size.
Benchmark (bench-components, run alone):
| world | baseline | now | mean | ratio |
|------------------------------------+----------+---------+---------+-------|
| deepest-edit-through-three-levels | 35.215 | 23.593 | 26.323 | 0.67 |
| edit-through-a-chain-of-dependents | 68.931 | 50.077 | 55.477 | 0.73 |
| library-update-into-copies | 83.083 | 50.157 | 52.815 | 0.6 |
| main-edit-among-many-shapes | 4.837 | 2.511 | 3.077 | 0.52 |
| main-edit-into-10-copies | 1.79 | 1.172 | 1.215 | 0.65 |
| main-edit-into-100-copies | 15.415 | 9.878 | 12.423 | 0.64 |
| main-edit-into-1000-copies | 153.086 | 123.768 | 175.446 | 0.81 |
| variant-switch-into-copies | 32.052 | 21.933 | 22.474 | 0.68 |
AI-assisted-by: claude-opus-5-5
A text style edit that applies the generated typography in a world whose
file holds none named a typography that resolves to nothing, so the model
wrote a dangling reference the copies then had to match. Without the
typography, that edit clears the text's typography instead.
Harness only; the benchmark is not run.
AI-assisted-by: claude-opus-5-5
Ungrouping a board in a grid main ungroups its copies alike. A copy with
its own cells placed the shapes the ungroup brought in by its own flow,
which adds tracks along its direction: a copy flowing in columns grew a
row its main did not have, so tracks it never overrode stopped following
its main's.
A copy with its own cells now first takes the tracks the ungroup left in
the grid it refers to, on the axes it does not override, then gives its
free cells to the new shapes in its main's layer order.
Benchmark (bench-components, run alone):
| world | baseline | now | mean | ratio |
|------------------------------------+----------+---------+---------+-------|
| deepest-edit-through-three-levels | 35.215 | 22.032 | 22.764 | 0.63 |
| edit-through-a-chain-of-dependents | 68.931 | 43.547 | 51.026 | 0.63 |
| library-update-into-copies | 83.083 | 52.297 | 57.441 | 0.63 |
| main-edit-among-many-shapes | 4.837 | 2.474 | 4.362 | 0.51 |
| main-edit-into-10-copies | 1.79 | 1.091 | 1.162 | 0.61 |
| main-edit-into-100-copies | 15.415 | 11.465 | 12.265 | 0.74 |
| main-edit-into-1000-copies | 153.086 | 111.337 | 115.898 | 0.73 |
| variant-switch-into-copies | 32.052 | 22.186 | 27.148 | 0.69 |
AI-assisted-by: claude-opus-5-5
When a board shrinks below the margins of a child constrained left-right
or top-bottom, the child's sides cross. The CLJS engine sizes the child by
the length between them; the WASM engine divided their signed distance
and mirrored the child.
The WASM engine takes the length between the sides too.
The benchmark covers JVM code; this change is in the WASM engine only, so
it is not run.
AI-assisted-by: claude-opus-5-5
A board's children keep their distances to its sides through a transform
by the side projections of `Bounds`, which change sign for a mirrored box.
They took the signs of the box matrix's diagonal for its flips; a box
turned a quarter has that diagonal at float noise, so after flipping a
turned board the signs came out at random and its constrained children
were thrown off, twice as far for each nested board.
A box is mirrored when its matrix's determinant is negative.
The benchmark covers JVM code; this change is in the WASM engine only, so
it is not run.
AI-assisted-by: claude-opus-5-5
With `debug`, the browser replay logs each target and the shapes every
program ends with whether the WASM engine is on or off, so a WASM failure
can be compared with the same program on the plain engine.
Harness only; the benchmark is not run.
Also in this commit:
- Apply the generated typography only where the file holds it. A text style edit
picks the generated typography for one of its values, but only worlds with
text styles add that typography to the file. In the others the model applied
the edit's styles while the frontend applied a missing typography, which sets
no style, so the two diverged. The edit names the typography only when the
file holds it.
- Replay programs in the browser as the frontend tests do. The browser replay
mocks the backend and the timers as the frontend generated tests do, turns the
WASM engine off for the plain engine even when the page's configuration turns
it on, and in debug logs the content a text edit commits and each text's
characters and font weights.
- Name the boards a deleted component's main was held by. The canonical design
data names shapes and components by their place in the tree, so the model and
the frontend compare although each allocates its own ids. A deleted component
keeps the ids of the board that held its main, as a variant's component keeps
its container's once the variant is undone; with that board gone the ids
stayed raw and differed between the two runs. They are named after the
component when no live shape is.
- Report where the model and the frontend first differ. A backend mismatch in
the frontend replay printed the whole diff of the two canonical designs, which
lists float noise the comparison accepts next to the difference it rejects.
`oracle/inequivalence` walks the two designs as `equivalent?` compares them
and returns the path of the first rejected value with both sides; the mismatch
message leads with it.
- Keep text sizes and take inline programs in the browser replay. With the WASM
engine on, the replay keeps each text's stored size in place of the engine's
text resizes: the model keeps stored sizes, and the generated texts are too
narrow to measure, so a new copy's measured text differed from its main's
unmeasured one. The page also takes the programs inline in an `edn` query
parameter, which a shrink loop drives.
AI-assisted-by: claude-opus-5-5
The component watcher drops a translation commit that moves only shapes
outside mains or whole mains. It found the main of each moved shape with
`get-component-shape`, which stops at the nearest copy head, so a copy
placed in a main, or a shape inside one, looked like a shape outside any
main: moving it with the WASM engine on, whose drags commit as
translations, left the main's copies where they were.
The watcher now walks up through nested copies to the main instance the
shape lies in.
The benchmark covers JVM code; this change is ClojureScript only, so it
is not run.
AI-assisted-by: claude-opus-5-5
The replay page takes a `start` index to resume a long run, an `engine`
of `plain` to replay the same programs with the WASM engine off, and a
`debug` flag that logs each target, each WASM layout with its result and
the shapes of a failing program.
Harness only; the benchmark is not run.
AI-assisted-by: claude-opus-5-5
A `:simple` padding or margin type repeats the top and right values on
the bottom and left, as `ctl/paddings` and `ctl/child-margins` read them,
but the WASM engine received the four stored values. A board whose type
was switched to simple after editing its sides laid out its children with
the stale bottom and left values in the WASM engine only, so moving one
child shifted all of them and marked copies as touched.
Both the shape payload and the per-attribute calls now send the values
the layout functions return.
The benchmark covers JVM code; this change is ClojureScript only, so it
is not run.
AI-assisted-by: claude-opus-5-5
With WASM on, a pure move took a shortcut: the translation was applied
to the moved shapes and their subtrees without asking the engine to lay
them out. A shape in a layout's flow then stayed where it was moved,
where the CLJS engine's layout put it back, and a copy shape kept the
move as a geometry override. A move of a shape that a layout places now
goes through the engine like any other transform.
Found by replaying generated programs in the browser with WASM on. The
JVM benchmark does not run the WASM path; it is not run.
AI-assisted-by: claude-opus-5-5
The frontend replay of generated component programs runs in node, where
the WASM render engine is not available. A `test-wasm` build runs the same
replay in a browser page: it loads the engine on a canvas, turns on
render-wasm/v1 and loads the shapes of the replayed page into the engine
whenever they change, so every layout goes through it. Text edits commit
through the SVG editor, as the WASM editor needs its own editing session.
The page reads the programs the common tests pin, which a script writes
out, and reports each one to the console.
Build with `pnpm run build:test-wasm`, then open
`/test-wasm.html?programs=programs.js`.
Test tooling only; the benchmark is not run.
AI-assisted-by: claude-opus-5-5