mirror of
https://github.com/webstudio-is/webstudio.git
synced 2026-12-01 21:05:42 +09:00
1910a267bb3ad7e0983c379a5114222a4c32f86f
Selecting the first item on a large page rebuilt the whole Navigator, even though the root was already open. On a 2,000-item test page, that caused about 14,000 Navigator DOM mutations and recreated drag handlers for every row. The Navigator now expands only ancestors that can actually be collapsed. The root stays out of the expanded set. A regression assertion confirms that the first child selection keeps the existing flat tree. The recurring selection still takes about 0.55 seconds in this synthetic test. Its Navigator update touches only two rows, so this PR does not claim to resolve that remaining cost or the full end-to-end report. Ref #6678 ## Plan and checks - [x] Reproduce the first-selection tree rebuild and locate its cause. - [x] Skip the always-expanded root when revealing selected ancestors. - [x] Confirm the regression test fails before and passes after the fix. - [x] Run nearby Navigator tests, Builder typecheck, formatting, and lint. - [x] Review documentation impact: the Navigator guide needs no change for this internal performance fix. - [x] Confirm required CI checks pass.
Learning Resources
Social Media
License
- Webstudio core (all functionality in this repository) is free/open-source under AGPL-3.0-or-later.
- sdk-components-animation package (optional) is proprietary. You must accept the Webstudio, Inc. EULA located in sdk-components-animation/LICENSE before using it.
Languages
TypeScript
97.9%
PLpgSQL
1.5%
CSS
0.3%
Shell
0.2%
JavaScript
0.1%