diff --git a/apps/web/src/components/settings/settingsLayout.tsx b/apps/web/src/components/settings/settingsLayout.tsx index 0794553cb8fba..7f8a777a50acc 100644 --- a/apps/web/src/components/settings/settingsLayout.tsx +++ b/apps/web/src/components/settings/settingsLayout.tsx @@ -172,6 +172,7 @@ export function SettingsSection({ title, hideTitle = false, icon, + badge, headerAction, variant = "grouped", children, @@ -181,6 +182,8 @@ export function SettingsSection({ title: string; hideTitle?: boolean; icon?: ReactNode; + /** Status shown right after the title, e.g. which profile is the default. */ + badge?: ReactNode; headerAction?: ReactNode; variant?: "grouped" | "plain"; children: ReactNode; @@ -205,6 +208,7 @@ export function SettingsSection({

{icon} {title} + {badge}

{headerAction}
diff --git a/apps/web/src/profileScope/EnvironmentProfiles.tsx b/apps/web/src/profileScope/EnvironmentProfiles.tsx index 52e5ad3fd9556..235eef56ce01e 100644 --- a/apps/web/src/profileScope/EnvironmentProfiles.tsx +++ b/apps/web/src/profileScope/EnvironmentProfiles.tsx @@ -149,27 +149,25 @@ export function EnvironmentProfiles({ key={id} title={profile.name} icon={} + badge={isDefault ? Default : null} headerAction={ - {isDefault ? ( - - Default - - ) : null} {readOnly ? null : isDefault ? ( - updateSettings({ providerProfileId: null })} > Unset default - + ) : ( - updateSettings({ providerProfileId: id })} > Make default - + )} {readOnly ? null : (