Skip to content

Commit 79ebcca

Browse files
matt2eclaude
andauthored
fix: open agent dropdown upward in session dialogs (#556)
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 20e8f36 commit 79ebcca

2 files changed

Lines changed: 11 additions & 3 deletions

File tree

apps/staged/src/lib/features/agents/AgentSelector.svelte

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,10 @@
2525
disabled?: boolean;
2626
remote?: boolean;
2727
projectId?: string | null;
28+
dropUp?: boolean;
2829
}
2930
30-
let { disabled = false, remote = false, projectId = null }: Props = $props();
31+
let { disabled = false, remote = false, projectId = null, dropUp = false }: Props = $props();
3132
3233
let showDropdown = $state(false);
3334
@@ -86,7 +87,7 @@
8687
{/if}
8788
</button>
8889
{#if showDropdown}
89-
<div class="selector-dropdown">
90+
<div class="selector-dropdown" class:drop-up={dropUp}>
9091
{#each agents as provider (provider.id)}
9192
<button
9293
type="button"
@@ -155,6 +156,13 @@
155156
min-width: 140px;
156157
}
157158
159+
.selector-dropdown.drop-up {
160+
top: auto;
161+
bottom: 100%;
162+
margin-top: 0;
163+
margin-bottom: 4px;
164+
}
165+
158166
.selector-option {
159167
display: flex;
160168
align-items: center;

apps/staged/src/lib/features/sessions/NewSessionModal.svelte

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -371,7 +371,7 @@
371371
/>
372372

373373
<div class="form-actions">
374-
<AgentSelector disabled={starting} {remote} />
374+
<AgentSelector disabled={starting} {remote} dropUp />
375375
<div class="form-actions-right">
376376
<button type="button" class="cancel-btn" onclick={handleClose} disabled={starting}>
377377
Cancel

0 commit comments

Comments
 (0)