assistant2: Add a way to quickly configure tools for the current profile (#27714)

This PR adds a new entry to the profile selector to quickly access tool
customization for the current profile:

<img width="228" alt="Screenshot 2025-03-28 at 7 08 51 PM"
src="https://github.com/user-attachments/assets/929ae5e7-5a16-4bf2-8043-6c09b621fc61"
/>

Release Notes:

- N/A
This commit is contained in:
Marshall Bowers 2025-03-28 19:25:39 -04:00 committed by GitHub
parent e171d16ae3
commit 8ecf553279
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 43 additions and 6 deletions

View file

@ -94,9 +94,21 @@ impl ProfileSelector {
}
menu = menu.separator();
menu = menu.item(ContextMenuEntry::new("Configure Profiles").handler(
menu = menu.header("Customize Current Profile");
menu = menu.item(ContextMenuEntry::new("Tools…").handler({
let profile_id = settings.default_profile.clone();
move |window, cx| {
window.dispatch_action(ManageProfiles.boxed_clone(), cx);
window.dispatch_action(
ManageProfiles::customize_tools(profile_id.clone()).boxed_clone(),
cx,
);
}
}));
menu = menu.separator();
menu = menu.item(ContextMenuEntry::new("Configure Profiles…").handler(
move |window, cx| {
window.dispatch_action(ManageProfiles::default().boxed_clone(), cx);
},
));