mirror of
https://github.com/jparkerweb/plan2code.git
synced 2026-11-16 20:45:33 -08:00
Steady the dashboard rows page test against redraws and derive its expected columns
AI Assisted
This commit is contained in:
1 parent
3fe1de51ed
commit
e6257e92bf
2 files changed
+17
-7
No files matched your search
@@ -304,8 +304,10 @@ function fitCardRows(root) {
|
||||
}
|
||||
|
||||
// One watcher, on the menu drawn last: a resize refits its groups. Fitting
|
||||
// changes only the menu's height, which refits to the same columns, so the
|
||||
// watcher never feeds itself.
|
||||
// changes the menu's height, which usually refits to the same columns. It can
|
||||
// feed itself only when that height change adds or removes the main column's
|
||||
// scrollbar and the grid's width sits within a scrollbar's width of a column
|
||||
// break; then the count may swap back and forth.
|
||||
const rowsObserver = typeof ResizeObserver === "function" ? new ResizeObserver((entries) => entries.forEach((e) => fitCardRows(e.target))) : null;
|
||||
function watchCardRows(wrap) {
|
||||
if (!rowsObserver) return;
|
||||
|
||||
Reference in new issue
Block a user