From 7ac8251c993f301b1c2f1076492235ef619a99af Mon Sep 17 00:00:00 2001 From: Alex Carpenter Date: Fri, 10 Apr 2026 13:53:19 -0400 Subject: [PATCH 1/2] chore(ui): Add OauthConsent localizations pt 1 --- packages/localizations/src/en-US.ts | 12 +++++++++ packages/shared/src/types/localization.ts | 12 +++++++++ .../components/OAuthConsent/OAuthConsent.tsx | 27 ++++++++++++------- 3 files changed, 42 insertions(+), 9 deletions(-) diff --git a/packages/localizations/src/en-US.ts b/packages/localizations/src/en-US.ts index 70ea6c728fa..1dc4688e9bc 100644 --- a/packages/localizations/src/en-US.ts +++ b/packages/localizations/src/en-US.ts @@ -294,6 +294,18 @@ export const enUS: LocalizationResource = { title: 'Choose an account', titleWithoutPersonal: 'Choose an organization', }, + oauthConsent: { + action__allow: 'Allow', + action__deny: 'Deny', + redirectUriModal: { + subtitle: 'Make sure you trust {{applicationName}} and that this URL belongs to {{applicationName}}.', + title: 'Redirect URL', + }, + scopeList: { + title: 'This will allow {{applicationName}} access to:', + }, + subtitle: 'wants to access {{applicationName}} on behalf of {{identifier}}', + }, organizationProfile: { apiKeysPage: { title: 'API keys', diff --git a/packages/shared/src/types/localization.ts b/packages/shared/src/types/localization.ts index 5e65b15004e..e58d9c3697a 100644 --- a/packages/shared/src/types/localization.ts +++ b/packages/shared/src/types/localization.ts @@ -1252,6 +1252,18 @@ export type __internal_LocalizationResource = { suggestionsAcceptedLabel: LocalizationValue; action__createOrganization: LocalizationValue; }; + oauthConsent: { + subtitle: LocalizationValue<'applicationName' | 'identifier'>; + scopeList: { + title: LocalizationValue<'applicationName'>; + }; + action__deny: LocalizationValue; + action__allow: LocalizationValue; + redirectUriModal: { + title: LocalizationValue; + subtitle: LocalizationValue<'applicationName'>; + }; + }; unstable__errors: UnstableErrors; dates: { previous6Days: LocalizationValue<'date'>; diff --git a/packages/ui/src/components/OAuthConsent/OAuthConsent.tsx b/packages/ui/src/components/OAuthConsent/OAuthConsent.tsx index bc610b673a5..d61fd4af7e2 100644 --- a/packages/ui/src/components/OAuthConsent/OAuthConsent.tsx +++ b/packages/ui/src/components/OAuthConsent/OAuthConsent.tsx @@ -2,7 +2,7 @@ import { useUser } from '@clerk/shared/react'; import { useState } from 'react'; import { useEnvironment, useOAuthConsentContext } from '@/ui/contexts'; -import { Box, Button, Flow, Grid, Text } from '@/ui/customizables'; +import { Box, Button, Flow, Grid, localizationKeys, Text } from '@/ui/customizables'; import { ApplicationLogo } from '@/ui/elements/ApplicationLogo'; import { Card } from '@/ui/elements/Card'; import { withCardStateProvider } from '@/ui/elements/contexts'; @@ -10,8 +10,6 @@ import { Header } from '@/ui/elements/Header'; import { Modal } from '@/ui/elements/Modal'; import { Tooltip } from '@/ui/elements/Tooltip'; import { Alert, Textarea } from '@/ui/primitives'; -import { common } from '@/ui/styledSystem'; -import { colors } from '@/ui/utils/colors'; import { LogoGroup, LogoGroupItem, LogoGroupIcon, LogoGroupSeparator } from './LogoGroup'; import { OrgSelect } from './OrgSelect'; import { @@ -125,7 +123,12 @@ export function OAuthConsentInternal() { )} - + {selectOptions.length > 0 && ( @@ -138,7 +141,11 @@ export function OAuthConsentInternal() { - + {displayedScopes.map(item => ( @@ -187,11 +194,11 @@ export function OAuthConsentInternal() {