Fixed auto-focus in prompt and env dropdown

This commit is contained in:
Gregory Schier
2023-10-28 22:14:12 -07:00
parent 6dcbe45a53
commit 25c0db502e
5 changed files with 25 additions and 23 deletions

View File

@@ -36,21 +36,17 @@ export const EnvironmentActionsDropdown = memo(function EnvironmentActionsDropdo
[activeEnvironment?.id],
),
{ type: 'separator', label: 'Environments' },
...((environments.length > 0
? [
{
key: 'edit',
label: 'Manage Environments',
leftSlot: <Icon icon="gear" />,
onSelect: async () => {
dialog.show({
title: 'Environments',
render: () => <EnvironmentEditDialog />,
});
},
},
]
: []) as DropdownItem[]),
{
key: 'edit',
label: 'Manage Environments',
leftSlot: <Icon icon="gear" />,
onSelect: async () => {
dialog.show({
title: 'Environments',
render: () => <EnvironmentEditDialog />,
});
},
},
],
[activeEnvironment, dialog, environments, routes],
);