@@ -23,7 +23,7 @@ import { KibanaPageTemplate } from '@kbn/shared-ux-page-kibana-template';
23
23
import { i18n } from '@kbn/i18n' ;
24
24
import { css } from '@emotion/css' ;
25
25
import { IntegrationListView } from './integration_list_view' ;
26
- import { getIntegrationIcon } from '../utils' ;
26
+ import { getIntegrationIcon , isIntegrationDisabled } from '../utils' ;
27
27
import { useNavigation } from '../../../hooks/use_navigation' ;
28
28
import { appPaths } from '../../../app_paths' ;
29
29
@@ -44,7 +44,7 @@ const integrationCards: Record<IntegrationType, IntegrationCardData> = {
44
44
defaultMessage :
45
45
'Choose an existing index to connect and start using it in your workflows without re-importing your data' ,
46
46
} ) ,
47
- disabled : false ,
47
+ disabled : isIntegrationDisabled ( IntegrationType . index_source ) ,
48
48
} ,
49
49
[ IntegrationType . external_server ] : {
50
50
title : i18n . translate ( 'workchatApp.integrations.listView.externalServerCard' , {
@@ -54,7 +54,7 @@ const integrationCards: Record<IntegrationType, IntegrationCardData> = {
54
54
description : i18n . translate ( 'workchatApp.integrations.listView.externalServerDescription' , {
55
55
defaultMessage : 'Connect to external servers for data processing.' ,
56
56
} ) ,
57
- disabled : false ,
57
+ disabled : isIntegrationDisabled ( IntegrationType . external_server ) ,
58
58
} ,
59
59
[ IntegrationType . salesforce ] : {
60
60
title : i18n . translate ( 'workchatApp.integrations.listView.salesforceCard' , {
@@ -65,7 +65,7 @@ const integrationCards: Record<IntegrationType, IntegrationCardData> = {
65
65
defaultMessage :
66
66
'Connect your Salesforce account to bring in customer records, case data, and account insights for use in workflows' ,
67
67
} ) ,
68
- disabled : false ,
68
+ disabled : isIntegrationDisabled ( IntegrationType . salesforce ) ,
69
69
} ,
70
70
[ IntegrationType . google_drive ] : {
71
71
title : i18n . translate ( 'workchatApp.integrations.listView.googleDriveCard' , {
@@ -75,7 +75,7 @@ const integrationCards: Record<IntegrationType, IntegrationCardData> = {
75
75
description : i18n . translate ( 'workchatApp.integrations.listView.googleDriveDescription' , {
76
76
defaultMessage : 'Search and summarize content from your Drive files' ,
77
77
} ) ,
78
- disabled : true ,
78
+ disabled : isIntegrationDisabled ( IntegrationType . google_drive ) ,
79
79
} ,
80
80
[ IntegrationType . sharepoint ] : {
81
81
title : i18n . translate ( 'workchatApp.integrations.listView.sharepointCard' , {
@@ -85,7 +85,7 @@ const integrationCards: Record<IntegrationType, IntegrationCardData> = {
85
85
description : i18n . translate ( 'workchatApp.integrations.listView.sharepointDescription' , {
86
86
defaultMessage : 'Connect internal documents and sites for enterprise-wide search.' ,
87
87
} ) ,
88
- disabled : true ,
88
+ disabled : isIntegrationDisabled ( IntegrationType . sharepoint ) ,
89
89
} ,
90
90
[ IntegrationType . slack ] : {
91
91
title : i18n . translate ( 'workchatApp.integrations.listView.slackCard' , {
@@ -95,7 +95,7 @@ const integrationCards: Record<IntegrationType, IntegrationCardData> = {
95
95
description : i18n . translate ( 'workchatApp.integrations.listView.slackDescription' , {
96
96
defaultMessage : 'Search conversations and surface relevant team discussions.' ,
97
97
} ) ,
98
- disabled : true ,
98
+ disabled : isIntegrationDisabled ( IntegrationType . slack ) ,
99
99
} ,
100
100
[ IntegrationType . confluence ] : {
101
101
title : i18n . translate ( 'workchatApp.integrations.listView.confluenceCard' , {
@@ -105,7 +105,7 @@ const integrationCards: Record<IntegrationType, IntegrationCardData> = {
105
105
description : i18n . translate ( 'workchatApp.integrations.listView.confluenceDescription' , {
106
106
defaultMessage : 'Tap into your internal knowledge base for accurate answers.' ,
107
107
} ) ,
108
- disabled : true ,
108
+ disabled : isIntegrationDisabled ( IntegrationType . confluence ) ,
109
109
} ,
110
110
[ IntegrationType . jira ] : {
111
111
title : i18n . translate ( 'workchatApp.integrations.listView.jiraCard' , {
@@ -115,7 +115,7 @@ const integrationCards: Record<IntegrationType, IntegrationCardData> = {
115
115
description : i18n . translate ( 'workchatApp.integrations.listView.jiraDescription' , {
116
116
defaultMessage : 'Bring in issue tracking, tickets, and project context.' ,
117
117
} ) ,
118
- disabled : true ,
118
+ disabled : isIntegrationDisabled ( IntegrationType . jira ) ,
119
119
} ,
120
120
[ IntegrationType . github ] : {
121
121
title : i18n . translate ( 'workchatApp.integrations.listView.githubCard' , {
@@ -125,7 +125,7 @@ const integrationCards: Record<IntegrationType, IntegrationCardData> = {
125
125
description : i18n . translate ( 'workchatApp.integrations.listView.githubDescription' , {
126
126
defaultMessage : 'Search repos, issues, and documentation for engineering insights.' ,
127
127
} ) ,
128
- disabled : true ,
128
+ disabled : isIntegrationDisabled ( IntegrationType . github ) ,
129
129
} ,
130
130
} ;
131
131
0 commit comments