fix(ui): fix scroll overflow in Menu and Select popovers

When viewport height constrains the popover, content now scrolls
instead of overflowing.

- Menu: add flex column layout and overflow hidden to .bui-MenuInner
- Select: add overflow auto and min-height 0 to .bui-SelectList

Signed-off-by: Johan Persson <johanopersson@gmail.com>
This commit is contained in:
Johan Persson
2026-02-27 13:10:13 +01:00
parent acb2714ca8
commit 9027b10643
3 changed files with 22 additions and 6 deletions
+7
View File
@@ -0,0 +1,7 @@
---
'@backstage/ui': patch
---
Fixed scroll overflow in Menu and Select popover content when constrained by viewport height.
**Affected components:** Menu, Select
@@ -58,6 +58,10 @@
.bui-MenuInner {
border-radius: var(--menu-border-radius);
display: flex;
flex-direction: column;
min-height: 0;
overflow: hidden;
}
.bui-MenuContent {
@@ -116,12 +116,17 @@
}
}
.bui-SelectList:focus-visible {
/* Remove default focus-visible outline because React Aria
* triggers it on mouse click open of the list for some reason.
* On keyboard use, the top item receives the focus style,
* so it's not needed anyway. */
outline: none;
.bui-SelectList {
overflow: auto;
min-height: 0;
&:focus-visible {
/* Remove default focus-visible outline because React Aria
* triggers it on mouse click open of the list for some reason.
* On keyboard use, the top item receives the focus style,
* so it's not needed anyway. */
outline: none;
}
}
.bui-SelectItem {