Skip to content

Commit a9bef04

Browse files
committed
chat: fix dropdown action order to match default
- Reorders dropdown actions to show queue/steer (the default actions) before stop and send (destructive action) - Marks the configured default action as checked so it's focused when the dropdown opens with keyboard - This ensures the dropdown pre-selection matches the action that would be triggered by pressing Enter Fixes #297559 (Commit message generated by Copilot)
1 parent ac857d4 commit a9bef04

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/vs/workbench/contrib/chat/browser/widget/input/chatQueuePickerActionItem.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,11 +159,14 @@ export class ChatQueuePickerActionItem extends BaseActionViewItem {
159159
}
160160

161161
private _getDropdownActions(): IActionWidgetDropdownAction[] {
162+
const isSteerDefault = this._isSteerDefault();
163+
162164
const queueAction: IActionWidgetDropdownAction = {
163165
id: ChatQueueMessageAction.ID,
164166
label: localize('chat.queueMessage', "Add to Queue"),
165167
tooltip: '',
166168
enabled: true,
169+
checked: !isSteerDefault,
167170
icon: Codicon.add,
168171
class: undefined,
169172
hover: {
@@ -179,6 +182,7 @@ export class ChatQueuePickerActionItem extends BaseActionViewItem {
179182
label: localize('chat.steerWithMessage', "Steer with Message"),
180183
tooltip: '',
181184
enabled: true,
185+
checked: isSteerDefault,
182186
icon: Codicon.arrowRight,
183187
class: undefined,
184188
hover: {
@@ -204,7 +208,7 @@ export class ChatQueuePickerActionItem extends BaseActionViewItem {
204208
}
205209
};
206210

207-
return [sendAction, queueAction, steerAction];
211+
return [queueAction, steerAction, sendAction];
208212
}
209213
}
210214

0 commit comments

Comments
 (0)