Skip to content

The fastest, cheapest, most efficient open-source agent harness. Run more than 500 agents on a $10 VPS.

fix(settings): correct provider auth section to show saved key indicator

Steven Enamakelb39f794ac3e0
diff --git a/app/src/components/settings/panels/ai/ProviderAuthSection.tsx b/app/src/components/settings/panels/ai/ProviderAuthSection.tsx
index 94382b14d8..0a90bba55f 100644
--- a/app/src/components/settings/panels/ai/ProviderAuthSection.tsx
+++ b/app/src/components/settings/panels/ai/ProviderAuthSection.tsx
@@ -18,12 +18,13 @@
*/
import { LuCircleAlert } from 'react-icons/lu';
+import { useState } from 'react';
+
import { useT } from '../../../../lib/i18n/I18nContext';
import type { ProviderAuthError } from '../../../../services/api/aiSettingsApi';
import Alert from '../../../ui/Alert';
import Badge from '../../../ui/Badge';
import Button from '../../../ui/Button';
-import Card from '../../../ui/Card';
import StatusLine from '../../../ui/StatusLine';
import Switch from '../../../ui/Switch';
import { routingWithProviderRemoved } from '../aiRouting';
@@ -105,6 +106,7 @@ export const ProviderAuthSection = ({
onEditCustomProvider: (provider: CloudProvider) => void;
}) => {
const { t } = useT();
+ const [addOpen, setAddOpen] = useState(false);
/** Drop a provider and scrub every routing entry pinned to it, so a workload
* cannot keep pointing at a provider that no longer exists. */
@@ -159,6 +161,7 @@ export const ProviderAuthSection = ({
];
const handlePick = (slug: string) => {
+ setAddOpen(false);
if (slug === CUSTOM_OPTION) {
onAddCustomProvider();
return;