mirror of
https://github.com/penpot/penpot.git
synced 2026-11-21 01:22:01 +00:00
A copy of a hidden variant sits in a grid without a cell, as a hidden child takes no part in the grid's flow. Switching it to a shown variant put the parent's cells back as they were, so the shown head had no cell and the next reflow of the grid failed. The switch now assigns the parent grid's cells again when the new head enters or leaves the flow, as a sync of the head does. Benchmark (scripts/bench-components, ms, lower 2.5% quantile): | :world | :baseline | :now | :mean | :ratio | |------------------------------------+-----------+---------+---------+--------| | deepest-edit-through-three-levels | 35.215 | 19.977 | 21.701 | 0.57 | | edit-through-a-chain-of-dependents | 68.931 | 39.77 | 41.277 | 0.58 | | library-update-into-copies | 83.083 | 52.24 | 53.439 | 0.63 | | main-edit-among-many-shapes | 4.837 | 2.095 | 2.487 | 0.43 | | main-edit-into-10-copies | 1.79 | 0.962 | 1.002 | 0.54 | | main-edit-into-100-copies | 15.415 | 9.465 | 10.586 | 0.61 | | main-edit-into-1000-copies | 153.086 | 104.614 | 107.085 | 0.68 | | variant-switch-into-copies | 32.052 | 22.023 | 22.427 | 0.69 | AI-assisted-by: claude-opus-5-5