A nested head whose parent is a swapped layout head kept its authored
layout sizing after a reset: the reset pairs the parent with the ref's
parent through the parent's shape-ref, and a swapped head refers to its
position, not to the main of its own component. A later sync of that head
then gave the child its main's sizing. The reset now also pairs a parent
that is a copy of the component whose main root holds the ref.
Test: resetting-a-nested-copy-of-a-swapped-layout-head-restores-its-sizing
(the variant gate program of round 12, seed 371855618). Composable
generated, reset and swap group tests: 433 tests, 0 failures.
Benchmark (scripts/bench-components, ms, lower 2.5% quantile):
| :world | :baseline | :now | :mean | :ratio |
|------------------------------------+-----------+--------+---------+--------|
| deepest-edit-through-three-levels | 35.215 | 20.1 | 20.737 | 0.57 |
| edit-through-a-chain-of-dependents | 68.931 | 40.911 | 41.855 | 0.59 |
| library-update-into-copies | 83.083 | 47.542 | 52.797 | 0.57 |
| main-edit-among-many-shapes | 4.837 | 2.495 | 2.627 | 0.52 |
| main-edit-into-10-copies | 1.79 | 0.99 | 1.045 | 0.55 |
| main-edit-into-100-copies | 15.415 | 9.458 | 9.877 | 0.61 |
| main-edit-into-1000-copies | 153.086 | 97.254 | 101.408 | 0.64 |
| variant-switch-into-copies | 32.052 | 20.235 | 21.101 | 0.63 |
AI-assisted-by: claude-opus-5-5