Skip to content

Commit af1f151

Browse files
committed
replace integration configuration form title to include integration type
1 parent 67d2557 commit af1f151

File tree

1 file changed

+23
-4
lines changed

1 file changed

+23
-4
lines changed

src/webviews/webview-side/integrations/ConfigurationForm.tsx

Lines changed: 23 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,27 @@ import { SQLServerForm } from './SQLServerForm';
1919
import { TrinoForm } from './TrinoForm';
2020
import { ConfigurableDatabaseIntegrationConfig, ConfigurableDatabaseIntegrationType } from './types';
2121

22+
// Localized labels for integration types (duplicated from sqlCellStatusBarProvider.ts due to import restrictions)
23+
const integrationTypeLabels: Record<ConfigurableDatabaseIntegrationType, string> = {
24+
alloydb: 'AlloyDB',
25+
athena: 'Amazon Athena',
26+
'big-query': 'BigQuery',
27+
clickhouse: 'ClickHouse',
28+
databricks: 'Databricks',
29+
dremio: 'Dremio',
30+
mariadb: 'MariaDB',
31+
materialize: 'Materialize',
32+
mindsdb: 'MindsDB',
33+
mongodb: 'MongoDB',
34+
mysql: 'MySQL',
35+
pgsql: 'PostgreSQL',
36+
redshift: 'Amazon Redshift',
37+
snowflake: 'Snowflake',
38+
spanner: 'Google Cloud Spanner',
39+
'sql-server': 'SQL Server',
40+
trino: 'Trino'
41+
};
42+
2243
export interface IConfigurationFormProps {
2344
integrationId: string;
2445
existingConfig: ConfigurableDatabaseIntegrationConfig | null;
@@ -36,10 +57,8 @@ export const ConfigurationForm: React.FC<IConfigurationFormProps> = ({
3657
onSave,
3758
onCancel
3859
}) => {
39-
const title = getLocString('integrationsConfigureTitle', 'Configure Integration: {0}').replace(
40-
'{0}',
41-
integrationId
42-
);
60+
const typeLabel = integrationTypeLabels[integrationType] || integrationType;
61+
const title = getLocString('integrationsConfigureTitle', '{0} integration').replace('{0}', typeLabel);
4362

4463
return (
4564
<div className="configuration-form-overlay">

0 commit comments

Comments
 (0)