agent ui: Make some UI elements more consistent (#45319)

Danilo Leal created

- Both the mode, profile, and model selectors have the option to cycle
through its options with a keybinding. In the tooltip that shows it, in
some of them the "Cycle Through..." label was at the top, and in others
at the bottom. Now it's all at the bottom.
- We used different language in different places for "going to a file".
The tool call edit card's header said "_Jump_ to File" while the edit
files list said "_Go_ to File". Now it's both "Go to File".

Release Notes:

- N/A

Change summary

crates/agent_ui/src/acp/mode_selector.rs | 14 +++++++-------
crates/agent_ui/src/acp/thread_view.rs   |  2 +-
crates/agent_ui/src/profile_selector.rs  |  6 +++---
3 files changed, 11 insertions(+), 11 deletions(-)

Detailed changes

crates/agent_ui/src/acp/mode_selector.rs 🔗

@@ -188,25 +188,25 @@ impl Render for ModeSelector {
                             .gap_1()
                             .child(
                                 h_flex()
-                                    .pb_1()
                                     .gap_2()
                                     .justify_between()
-                                    .border_b_1()
-                                    .border_color(cx.theme().colors().border_variant)
-                                    .child(Label::new("Cycle Through Modes"))
+                                    .child(Label::new("Toggle Mode Menu"))
                                     .child(KeyBinding::for_action_in(
-                                        &CycleModeSelector,
+                                        &ToggleProfileSelector,
                                         &focus_handle,
                                         cx,
                                     )),
                             )
                             .child(
                                 h_flex()
+                                    .pb_1()
                                     .gap_2()
                                     .justify_between()
-                                    .child(Label::new("Toggle Mode Menu"))
+                                    .border_b_1()
+                                    .border_color(cx.theme().colors().border_variant)
+                                    .child(Label::new("Cycle Through Modes"))
                                     .child(KeyBinding::for_action_in(
-                                        &ToggleProfileSelector,
+                                        &CycleModeSelector,
                                         &focus_handle,
                                         cx,
                                     )),

crates/agent_ui/src/acp/thread_view.rs 🔗

@@ -2718,7 +2718,7 @@ impl AcpThreadView {
                             ..default_markdown_style(false, true, window, cx)
                         },
                     ))
-                    .tooltip(Tooltip::text("Jump to File"))
+                    .tooltip(Tooltip::text("Go to File"))
                     .on_click(cx.listener(move |this, _, window, cx| {
                         this.open_tool_call_location(entry_ix, 0, window, cx);
                     }))

crates/agent_ui/src/profile_selector.rs 🔗

@@ -191,6 +191,9 @@ impl Render for ProfileSelector {
                     let container = || h_flex().gap_1().justify_between();
                     v_flex()
                         .gap_1()
+                        .child(container().child(Label::new("Toggle Profile Menu")).child(
+                            KeyBinding::for_action_in(&ToggleProfileSelector, &focus_handle, cx),
+                        ))
                         .child(
                             container()
                                 .pb_1()
@@ -203,9 +206,6 @@ impl Render for ProfileSelector {
                                     cx,
                                 )),
                         )
-                        .child(container().child(Label::new("Toggle Profile Menu")).child(
-                            KeyBinding::for_action_in(&ToggleProfileSelector, &focus_handle, cx),
-                        ))
                         .into_any()
                 }
             }),