Skip to content

Commit 7649f65

Browse files
rodrigoB-CBclaude
andcommitted
fix(web): render dropdowns above toasts
Toast notifications sat at z-index 100 while menus, popovers, selects, comboboxes and autocompletes sat at 50-60, so any toast painted over an open dropdown. Because the toast viewport also captures pointer events, a click aimed at a covered menu item hit the toast (or its dismiss button) instead of the item. Move the five popup positioners to z-index 130. Toasts stay above every normal surface, including dialogs and sheets, but the menu the user is actively holding open now wins -- it is the focused interaction, while a toast is ambient and dismisses itself a few seconds later. 130 clears the theme inspector cluster (100-120) as well, so dropdowns opened from the theme editor keep working. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
1 parent 65b005f commit 7649f65

5 files changed

Lines changed: 5 additions & 5 deletions

File tree

‎apps/web/src/components/ui/autocomplete.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ function AutocompletePopup({
9797
align={align}
9898
alignOffset={alignOffset}
9999
anchor={anchor}
100-
className="z-50 select-none"
100+
className="z-[130] select-none"
101101
data-slot="autocomplete-positioner"
102102
side={side}
103103
sideOffset={sideOffset}

‎apps/web/src/components/ui/combobox.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ function ComboboxPopup({
163163
align={align}
164164
alignOffset={alignOffset}
165165
anchor={anchor}
166-
className="z-50 select-none"
166+
className="z-[130] select-none"
167167
data-slot="combobox-positioner"
168168
side={side}
169169
sideOffset={sideOffset}

‎apps/web/src/components/ui/menu.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ function MenuPopup({
4242
align={align}
4343
alignOffset={alignOffset}
4444
anchor={anchor}
45-
className="z-[60]"
45+
className="z-[130]"
4646
data-slot="menu-positioner"
4747
side={side}
4848
sideOffset={sideOffset}

‎apps/web/src/components/ui/popover.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ function PopoverPopup({
4242
align={align}
4343
alignOffset={alignOffset}
4444
anchor={anchor}
45-
className="z-[60] h-(--positioner-height) w-(--positioner-width) max-w-(--available-width) transition-transform data-instant:transition-none"
45+
className="z-[130] h-(--positioner-height) w-(--positioner-width) max-w-(--available-width) transition-transform data-instant:transition-none"
4646
data-slot="popover-positioner"
4747
side={side}
4848
sideOffset={sideOffset}

‎apps/web/src/components/ui/select.tsx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ function SelectPopup({
132132
alignItemWithTrigger={alignItemWithTrigger}
133133
alignOffset={alignOffset}
134134
anchor={anchor}
135-
className="z-50 select-none"
135+
className="z-[130] select-none"
136136
data-slot="select-positioner"
137137
side={side}
138138
sideOffset={sideOffset}

0 commit comments

Comments
 (0)