Conversation
There was a problem hiding this comment.
Pull request overview
This PR reverts toolbar changes in the chat input widget. It moves the contextUsageWidgetContainer back into the inputToolbars element (from the secondaryToolbar) and consolidates several action registrations (OpenSessionTargetPickerAction, OpenDelegationPickerAction, OpenWorkspacePickerAction) from having separate MenuId.ChatInput + MenuId.ChatInputSecondary entries (split by IsSessionsWindowContext) into a single unified MenuId.ChatInput entry.
Changes:
- DOM restructuring:
contextUsageWidgetContainermoved from.chat-secondary-toolbarinto.chat-input-toolbars - Session picker action menus simplified: three picker actions lost their
ChatInputSecondary/IsSessionsWindowContextdual registration and now use a singleChatInputregistration secondaryToolbarContainer.style.display = 'none'changed from being conditional onisSessionsWindowto unconditional
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
src/vs/workbench/contrib/chat/browser/widget/input/chatInputPart.ts |
Moves contextUsageWidgetContainer into inputToolbars in both compact and non-compact DOM layouts; unconditionally hides secondaryToolbarContainer; removes conditional toolbarsContainer.prepend call |
src/vs/workbench/contrib/chat/browser/actions/chatExecuteActions.ts |
Removes ChatInputSecondary menu registrations for OpenSessionTargetPickerAction, OpenDelegationPickerAction, and OpenWorkspacePickerAction, consolidating each to a single ChatInput registration |
You can also share your feedback on Copilot code review. Take the survey.
| if (this.options.isSessionsWindow) { | ||
| this.secondaryToolbarContainer.style.display = 'none'; | ||
| } | ||
| this.secondaryToolbarContainer.style.display = 'none'; |
There was a problem hiding this comment.
The secondaryToolbarContainer.style.display = 'none' is now applied unconditionally for all windows. Previously, this was guarded by if (this.options.isSessionsWindow), meaning only the Sessions window hid the secondary toolbar. The regular workbench still needs to show it for the OpenPermissionPickerAction (which is registered in MenuId.ChatInputSecondary with IsSessionsWindowContext.negate() at line 469 of chatExecuteActions.ts). With this change, the permission picker in the regular workbench (chat sidebar, panel, etc.) will never be visible, since the container is permanently hidden and nothing ever re-shows it.
| this.secondaryToolbarContainer.style.display = 'none'; | |
| if (this.options.isSessionsWindow) { | |
| this.secondaryToolbarContainer.style.display = 'none'; | |
| } |
just in case