Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions lib/KListWithOverflow.vue
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,9 @@
const idx = overflowItemsIdx.pop();
const item = list.children[idx];
item.style.visibility = 'visible';
// Reset position; the overflow loop above set it to 'absolute' to
// remove the item from layout, which must be undone when restoring.
item.style.position = 'unset';
maxWidth += itemsSizes[idx].width;
}
}
Expand Down Expand Up @@ -268,9 +271,14 @@
.list {
position: relative;
display: flex;
flex-wrap: wrap;
flex-wrap: nowrap;
align-items: center;
overflow: visible;

/* Clip items during the brief window before setOverflowItems() runs on
resize; without this, items wrap visibly to a second row before being
hidden. nowrap keeps them on one line; overflow:hidden clips horizontal
extension before maxWidth is recomputed. */
overflow: hidden;
}

.list > * {
Expand Down
Loading