mirror of
https://github.com/jlengrand/Maestro.git
synced 2026-03-10 08:31:19 +00:00
fix: resolve select dropdown z-index issue in group chat modals
The native HTML select element's dropdown menu was being rendered behind the modal overlay, making it impossible to interact with the options. This was caused by a z-index stacking context issue where the modal's overlay had a higher z-index than the select element. Fixed by explicitly setting zIndex: 10000 on the select container and select element, and zIndex: 10001 on the icon, ensuring the dropdown renders above the modal overlay (z-index: 9999). Fixes the issue in both NewGroupChatModal and EditGroupChatModal.
This commit is contained in:
@@ -347,23 +347,22 @@ export function EditGroupChatModal({
|
|||||||
) : (
|
) : (
|
||||||
<div className="flex items-center gap-2">
|
<div className="flex items-center gap-2">
|
||||||
{/* Dropdown */}
|
{/* Dropdown */}
|
||||||
<div className="relative flex-1">
|
<div className="relative flex-1" style={{ zIndex: 10000 }}>
|
||||||
<select
|
<select
|
||||||
value={selectedAgent || ''}
|
value={selectedAgent || ''}
|
||||||
onChange={(e) => handleAgentChange(e.target.value)}
|
onChange={(e) => handleAgentChange(e.target.value)}
|
||||||
className="w-full px-3 py-2 pr-10 rounded-lg border outline-none appearance-none cursor-pointer text-sm"
|
className="w-full px-3 py-2 pr-10 rounded-lg border outline-none appearance-none cursor-pointer text-sm relative"
|
||||||
style={{
|
style={{
|
||||||
backgroundColor: theme.colors.bgMain,
|
backgroundColor: theme.colors.bgMain,
|
||||||
borderColor: theme.colors.border,
|
borderColor: theme.colors.border,
|
||||||
color: theme.colors.textMain,
|
color: theme.colors.textMain,
|
||||||
|
zIndex: 10000,
|
||||||
}}
|
}}
|
||||||
aria-label="Select moderator agent"
|
aria-label="Select moderator agent"
|
||||||
>
|
>
|
||||||
{availableTiles.map((tile) => {
|
{availableTiles.map((tile) => {
|
||||||
const isBeta =
|
const isBeta =
|
||||||
tile.id === 'codex' ||
|
tile.id === 'codex' || tile.id === 'opencode' || tile.id === 'factory-droid';
|
||||||
tile.id === 'opencode' ||
|
|
||||||
tile.id === 'factory-droid';
|
|
||||||
return (
|
return (
|
||||||
<option key={tile.id} value={tile.id}>
|
<option key={tile.id} value={tile.id}>
|
||||||
{tile.name}
|
{tile.name}
|
||||||
@@ -374,7 +373,7 @@ export function EditGroupChatModal({
|
|||||||
</select>
|
</select>
|
||||||
<ChevronDown
|
<ChevronDown
|
||||||
className="absolute right-3 top-1/2 -translate-y-1/2 w-4 h-4 pointer-events-none"
|
className="absolute right-3 top-1/2 -translate-y-1/2 w-4 h-4 pointer-events-none"
|
||||||
style={{ color: theme.colors.textDim }}
|
style={{ color: theme.colors.textDim, zIndex: 10001 }}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
@@ -340,15 +340,16 @@ export function NewGroupChatModal({
|
|||||||
) : (
|
) : (
|
||||||
<div className="flex items-center gap-2">
|
<div className="flex items-center gap-2">
|
||||||
{/* Dropdown */}
|
{/* Dropdown */}
|
||||||
<div className="relative flex-1">
|
<div className="relative flex-1" style={{ zIndex: 10000 }}>
|
||||||
<select
|
<select
|
||||||
value={selectedAgent || ''}
|
value={selectedAgent || ''}
|
||||||
onChange={(e) => handleAgentChange(e.target.value)}
|
onChange={(e) => handleAgentChange(e.target.value)}
|
||||||
className="w-full px-3 py-2 pr-10 rounded-lg border outline-none appearance-none cursor-pointer text-sm"
|
className="w-full px-3 py-2 pr-10 rounded-lg border outline-none appearance-none cursor-pointer text-sm relative"
|
||||||
style={{
|
style={{
|
||||||
backgroundColor: theme.colors.bgMain,
|
backgroundColor: theme.colors.bgMain,
|
||||||
borderColor: theme.colors.border,
|
borderColor: theme.colors.border,
|
||||||
color: theme.colors.textMain,
|
color: theme.colors.textMain,
|
||||||
|
zIndex: 10000,
|
||||||
}}
|
}}
|
||||||
aria-label="Select moderator agent"
|
aria-label="Select moderator agent"
|
||||||
>
|
>
|
||||||
@@ -365,7 +366,7 @@ export function NewGroupChatModal({
|
|||||||
</select>
|
</select>
|
||||||
<ChevronDown
|
<ChevronDown
|
||||||
className="absolute right-3 top-1/2 -translate-y-1/2 w-4 h-4 pointer-events-none"
|
className="absolute right-3 top-1/2 -translate-y-1/2 w-4 h-4 pointer-events-none"
|
||||||
style={{ color: theme.colors.textDim }}
|
style={{ color: theme.colors.textDim, zIndex: 10001 }}
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user