Skip to content

The agent that grows with you

refactor(desktop): move externalOpenFailed copy into an i18n sibling

Austin Pickettff3d4ab61504
diff --git a/apps/desktop/src/i18n/en.ts b/apps/desktop/src/i18n/en.ts
index c9092361c85..3b2b5b495c3 100644
--- a/apps/desktop/src/i18n/en.ts
+++ b/apps/desktop/src/i18n/en.ts
@@ -9,6 +9,7 @@ import { enClarify } from './en_clarify'
import { enConnectorAccounts } from './en_connector_accounts'
import { enConnectorCard } from './en_connector_card'
import { enGatewayGroupOpen, enSkillDeepLink } from './en_deep_links'
+import { enExternalOpenFailed } from './en_external_open'
import { enFirstRun } from './en_first_run'
import { enLocalModels } from './en_local_models'
import { enModelMenu } from './en_model_menu'
@@ -23,16 +24,7 @@ import { enUpdateChannel } from './en_update_channel'
import type { Translations } from './types'
export const en: Translations = {
- externalOpenFailed: {
- title: 'Couldn’t open this link',
- message: 'No browser is registered to open this address. Copy the link and open it manually.',
- copyUrl: 'Copy link',
- close: 'Close',
- missing: {
- title: 'File not found',
- message: 'This file does not exist — it may have been deleted or moved, or it lives on another machine.'
- }
- },
+ externalOpenFailed: enExternalOpenFailed,
sharedMetrics: enSharedMetrics,
appTour: enAppTour,
firstRun: enFirstRun,
diff --git a/apps/desktop/src/i18n/en_external_open.ts b/apps/desktop/src/i18n/en_external_open.ts
new file mode 100644
index 00000000000..483cbc75246
--- /dev/null
+++ b/apps/desktop/src/i18n/en_external_open.ts
@@ -0,0 +1,12 @@
+import type { ExternalOpenFailedCopy } from './types_external_open'
+
+export const enExternalOpenFailed: ExternalOpenFailedCopy = {
+ title: 'Couldn’t open this link',
+ message: 'No browser is registered to open this address. Copy the link and open it manually.',
+ copyUrl: 'Copy link',
+ close: 'Close',
+ missing: {
+ title: 'File not found',
+ message: 'This file does not exist — it may have been deleted or moved, or it lives on another machine.'
+ }
+}
diff --git a/apps/desktop/src/i18n/types.ts b/apps/desktop/src/i18n/types.ts
index 7632d053727..61f693d6a7a 100644
--- a/apps/desktop/src/i18n/types.ts
+++ b/apps/desktop/src/i18n/types.ts
@@ -16,6 +16,7 @@ import type { CatalogInstallTranslations } from './types_catalog_install'
import type { ClarifyCopy } from './types_clarify'
import type { ConnectorAccountsTranslations, ConnectorCardTranslations } from './types_connectors'
import type { GatewayGroupOpenCopy, SkillDeepLinkCopy } from './types_deep_links'
+import type { ExternalOpenFailedCopy } from './types_external_open'
import type { FirstRunCopy } from './types_first_run'
import type { ModelMenuTranslations } from './types_model_menu'
import type { ModelSettingsTranslations } from './types_model_settings'
@@ -84,16 +85,7 @@ export interface Translations extends NoticeTranslations {
sharedMetrics: SharedMetricsTranslations
appTour: AppTourTranslations
firstRun: FirstRunCopy
- externalOpenFailed: {
- title: string
- message: string
- copyUrl: string
- close: string
- missing: {
- title: string
- message: string
- }
- }
+ externalOpenFailed: ExternalOpenFailedCopy
intro: {
stock: Record<string, string[]>
custom: (label: string) => string[]
diff --git a/apps/desktop/src/i18n/types_external_open.ts b/apps/desktop/src/i18n/types_external_open.ts
new file mode 100644
index 00000000000..526398906f1
--- /dev/null
+++ b/apps/desktop/src/i18n/types_external_open.ts
@@ -0,0 +1,10 @@
+export interface ExternalOpenFailedCopy {
+ title: string
+ message: string
+ copyUrl: string
+ close: string
+ missing: {
+ title: string
+ message: string
+ }
+}