perf(layout): track panel resizing at a stepped cadence

This commit is contained in:
dengjie zhang authored and GitHub committed 2026-09-18 01:48:27 +08:00
1 parent a78fc48a7b
commit 8eba12ea2f
17 files changed
+705 -34

No files matched your search

+4 -1
View File
@@ -197,7 +197,10 @@ test("embedded result toolbar progressively compacts when editing actions overfl
assert.match(dataGrid, /dataGridTopbarMutationObserver = new MutationObserver\(updateDataGridTopbarWidth\)/);
assert.match(dataGrid, /dataGridTopbarMutationObserver\.observe\(topbar, \{ childList: true, characterData: true, subtree: true \}\)/);
assert.match(dataGrid, /topbar\.scrollWidth > topbar\.clientWidth \+ 1/);
const measurementStart = dataGrid.indexOf("function updateDataGridTopbarWidth()");
const measurementEnd = dataGrid.indexOf("function resetDataGridTopbarOverflowCompact()", measurementStart);
assert.ok(measurementStart >= 0 && measurementEnd > measurementStart);
assert.match(dataGrid.slice(measurementStart, measurementEnd), /(\w+)\.scrollWidth > \1\.clientWidth \+ 1/);
assert.match(dataGrid, /dataGridTopbarOverflowCompact\.value = true/);
assert.match(dataGrid, /dataGridTopbarOverflowActionCount\.value = compactDataGridToolbarActionCount\.value \+ 1/);
assert.match(dataGrid, /dataGridTopbarWidth\.value >= dataGridTopbarExpandedRequiredWidth\.value/);