agent: Polish single-file review toolbar controls (#29866)

This commit is contained in:
Danilo Leal 2025-05-04 07:53:21 -03:00 committed by GitHub
parent 545ae27079
commit 2e3baef299
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 56 additions and 60 deletions

View file

@ -15,8 +15,8 @@ use gpui::{
use search::{BufferSearchBar, buffer_search};
use settings::{Settings, SettingsStore};
use ui::{
ButtonStyle, ContextMenu, ContextMenuEntry, IconButton, IconButtonShape, IconName, IconSize,
PopoverMenu, PopoverMenuHandle, Tooltip, prelude::*,
ButtonStyle, ContextMenu, ContextMenuEntry, IconButton, IconName, IconSize, PopoverMenu,
PopoverMenuHandle, Tooltip, prelude::*,
};
use vim_mode_setting::VimModeSetting;
use workspace::{
@ -141,7 +141,6 @@ impl Render for QuickActionBar {
PopoverMenu::new("editor-selections-dropdown")
.trigger_with_tooltip(
IconButton::new("toggle_editor_selections_icon", IconName::CursorIBeam)
.shape(IconButtonShape::Square)
.icon_size(IconSize::Small)
.style(ButtonStyle::Subtle)
.toggle_state(self.toggle_selections_handle.is_deployed()),
@ -190,7 +189,6 @@ impl Render for QuickActionBar {
PopoverMenu::new("editor-settings")
.trigger_with_tooltip(
IconButton::new("toggle_editor_settings_icon", IconName::Sliders)
.shape(IconButtonShape::Square)
.icon_size(IconSize::Small)
.style(ButtonStyle::Subtle)
.toggle_state(self.toggle_settings_handle.is_deployed()),
@ -435,7 +433,8 @@ impl Render for QuickActionBar {
h_flex()
.id("quick action bar")
.gap(DynamicSpacing::Base04.rems(cx))
.p(DynamicSpacing::Base08.rems(cx))
.gap(DynamicSpacing::Base01.rems(cx))
.children(self.render_repl_menu(cx))
.children(self.render_toggle_markdown_preview(self.workspace.clone(), cx))
.children(search_button)
@ -490,7 +489,6 @@ impl RenderOnce for QuickActionBarButton {
let action = self.action.boxed_clone();
IconButton::new(self.id.clone(), self.icon)
.shape(IconButtonShape::Square)
.icon_size(IconSize::Small)
.style(ButtonStyle::Subtle)
.toggle_state(self.toggled)