@camunda/ccma-saas-frontend 0.1.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (189) hide show
  1. package/lib/esm/components/c4-billing-page/c4-billing-page.mocks.d.ts +3 -0
  2. package/lib/esm/components/c4-billing-page/c4-billing-page.mocks.js +154 -0
  3. package/lib/esm/components/c4-billing-page/elements/value-metric.d.ts +2 -0
  4. package/lib/esm/components/c4-billing-page/elements/value-metric.js +14 -3
  5. package/lib/esm/components/c4-billing-page/elements/value-metric.spec.js +18 -0
  6. package/lib/esm/components/c4-charts-dashboard/elements/alluvial-chart.js +58 -1
  7. package/lib/esm/components/c4-charts-dashboard/elements/bar-chart.js +40 -6
  8. package/lib/esm/components/c4-charts-dashboard/elements/line-chart.js +6 -0
  9. package/lib/esm/components/c4-cluster-details-alerts/c4-cluster-details-alerts.mocks.d.ts +5 -0
  10. package/lib/esm/components/c4-cluster-details-alerts/c4-cluster-details-alerts.mocks.js +83 -0
  11. package/lib/esm/components/c4-cluster-details-clients/c4-cluster-details-clients.mocks.d.ts +6 -0
  12. package/lib/esm/components/c4-cluster-details-clients/c4-cluster-details-clients.mocks.js +79 -0
  13. package/lib/esm/components/c4-cluster-details-connector-secrets/c4-cluster-details-connector-secrets.mocks.d.ts +3 -0
  14. package/lib/esm/components/c4-cluster-details-connector-secrets/c4-cluster-details-connector-secrets.mocks.js +65 -0
  15. package/lib/esm/components/c4-cluster-details-hot-backups/c4-cluster-details-hot-backups.mocks.d.ts +60 -0
  16. package/lib/esm/components/c4-cluster-details-hot-backups/c4-cluster-details-hot-backups.mocks.js +143 -0
  17. package/lib/esm/components/c4-cluster-details-ip-whitelist/c4-cluster-details-ip-whitelist.mocks.d.ts +6 -0
  18. package/lib/esm/components/c4-cluster-details-ip-whitelist/c4-cluster-details-ip-whitelist.mocks.js +51 -0
  19. package/lib/esm/components/c4-cluster-list/c4-cluster-list.d.ts +1 -1
  20. package/lib/esm/components/c4-cluster-list/c4-cluster-list.js +63 -2
  21. package/lib/esm/components/c4-cluster-list/c4-cluster-list.mocks.d.ts +4 -0
  22. package/lib/esm/components/c4-cluster-list/c4-cluster-list.mocks.js +132 -0
  23. package/lib/esm/components/c4-cluster-list/c4-cluster-list.types.d.ts +7 -0
  24. package/lib/esm/components/c4-cluster-overview/applications.js +17 -3
  25. package/lib/esm/components/c4-cluster-overview/applications.spec.js +27 -1
  26. package/lib/esm/components/c4-cluster-overview/c4-cluster-overview.mocks.d.ts +8 -0
  27. package/lib/esm/components/c4-cluster-overview/c4-cluster-overview.mocks.js +203 -0
  28. package/lib/esm/components/c4-cluster-overview/cluster-details.d.ts +2 -0
  29. package/lib/esm/components/c4-cluster-overview/cluster-details.js +59 -9
  30. package/lib/esm/components/c4-cluster-overview/cluster-load.js +38 -3
  31. package/lib/esm/components/c4-cluster-settings/c4-cluster-settings.mocks.d.ts +16 -0
  32. package/lib/esm/components/c4-cluster-settings/c4-cluster-settings.mocks.js +104 -0
  33. package/lib/esm/components/c4-cluster-settings/elements/app-integrations-toggle.d.ts +14 -0
  34. package/lib/esm/components/c4-cluster-settings/elements/app-integrations-toggle.js +12 -0
  35. package/lib/esm/components/c4-cluster-settings/elements/cluster-settings.d.ts +5 -1
  36. package/lib/esm/components/c4-cluster-settings/elements/cluster-settings.js +10 -3
  37. package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider-modal.d.ts +20 -0
  38. package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider-modal.js +85 -0
  39. package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider-modal.spec.d.ts +1 -0
  40. package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider-modal.spec.js +93 -0
  41. package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider.d.ts +20 -0
  42. package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider.js +15 -0
  43. package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider.spec.d.ts +1 -0
  44. package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider.spec.js +50 -0
  45. package/lib/esm/components/c4-cluster-settings/elements/optimize-filtering-settings.d.ts +10 -4
  46. package/lib/esm/components/c4-cluster-settings/elements/optimize-filtering-settings.js +116 -24
  47. package/lib/esm/components/c4-cluster-settings/elements/optimize-filtering-settings.spec.d.ts +1 -0
  48. package/lib/esm/components/c4-cluster-settings/elements/optimize-filtering-settings.spec.js +120 -0
  49. package/lib/esm/components/c4-cluster-tag-selector/c4-cluster-tag-selector.js +19 -1
  50. package/lib/esm/components/c4-console-dashboard/c4-console-dashboard.mocks.d.ts +2 -0
  51. package/lib/esm/components/c4-console-dashboard/c4-console-dashboard.mocks.js +186 -0
  52. package/lib/esm/components/c4-create-alert-modal/c4-create-alert-modal.d.ts +2 -0
  53. package/lib/esm/components/c4-create-alert-modal/c4-create-alert-modal.js +132 -0
  54. package/lib/esm/components/c4-create-alert-modal/c4-create-alert-modal.mocks.d.ts +2 -0
  55. package/lib/esm/components/c4-create-alert-modal/c4-create-alert-modal.mocks.js +20 -0
  56. package/lib/esm/components/c4-create-alert-modal/c4-create-alert-modal.types.d.ts +22 -0
  57. package/lib/esm/components/c4-create-alert-modal/c4-create-alert-modal.types.js +6 -0
  58. package/lib/esm/components/c4-create-cluster/c4-create-cluster-tile-grid.d.ts +32 -0
  59. package/lib/esm/components/c4-create-cluster/c4-create-cluster-tile-grid.js +71 -0
  60. package/lib/esm/components/c4-create-cluster/c4-create-cluster-tile-grid.spec.d.ts +1 -0
  61. package/lib/esm/components/c4-create-cluster/c4-create-cluster-tile-grid.spec.js +83 -0
  62. package/lib/esm/components/c4-create-cluster/c4-create-cluster.js +31 -58
  63. package/lib/esm/components/c4-create-cluster/c4-create-cluster.mocks.d.ts +64 -0
  64. package/lib/esm/components/c4-create-cluster/c4-create-cluster.mocks.js +298 -0
  65. package/lib/esm/components/c4-create-cluster-api-client-modal/c4-create-cluster-api-client-modal.js +48 -30
  66. package/lib/esm/components/c4-create-cluster-api-client-modal/c4-create-cluster-api-client-modal.mocks.d.ts +2 -0
  67. package/lib/esm/components/c4-create-cluster-api-client-modal/c4-create-cluster-api-client-modal.mocks.js +23 -0
  68. package/lib/esm/components/c4-create-cluster-api-client-modal/c4-create-cluster-api-client-modal.types.d.ts +2 -0
  69. package/lib/esm/components/c4-create-connector-secret-modal/c4-create-connector-secret-modal.mocks.d.ts +2 -0
  70. package/lib/esm/components/c4-create-connector-secret-modal/c4-create-connector-secret-modal.mocks.js +15 -0
  71. package/lib/esm/components/c4-create-console-api-client-modal/c4-create-console-api-client-modal.js +5 -5
  72. package/lib/esm/components/c4-create-console-api-client-modal/c4-create-console-api-client-modal.mocks.d.ts +2 -0
  73. package/lib/esm/components/c4-create-console-api-client-modal/c4-create-console-api-client-modal.mocks.js +13 -0
  74. package/lib/esm/components/c4-create-console-api-client-modal/c4-create-console-api-client-modal.types.d.ts +1 -0
  75. package/lib/esm/components/c4-create-ip-whitelist-modal/c4-create-ip-whitelist-modal.d.ts +2 -0
  76. package/lib/esm/components/c4-create-ip-whitelist-modal/c4-create-ip-whitelist-modal.js +77 -0
  77. package/lib/esm/components/c4-create-ip-whitelist-modal/c4-create-ip-whitelist-modal.mocks.d.ts +2 -0
  78. package/lib/esm/components/c4-create-ip-whitelist-modal/c4-create-ip-whitelist-modal.mocks.js +11 -0
  79. package/lib/esm/components/c4-create-ip-whitelist-modal/c4-create-ip-whitelist-modal.types.d.ts +14 -0
  80. package/lib/esm/components/c4-create-ip-whitelist-modal/c4-create-ip-whitelist-modal.types.js +6 -0
  81. package/lib/esm/components/c4-data-table/c4-data-table.js +117 -34
  82. package/lib/esm/components/c4-data-table/c4-data-table.stability.spec.d.ts +1 -0
  83. package/lib/esm/components/c4-data-table/c4-data-table.stability.spec.js +151 -0
  84. package/lib/esm/components/c4-job-dashboard-details-page/c4-job-dashboard-details-page.mocks.d.ts +2 -0
  85. package/lib/esm/components/c4-job-dashboard-details-page/c4-job-dashboard-details-page.mocks.js +231 -0
  86. package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-piechart.js +56 -2
  87. package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-time-chart.js +36 -1
  88. package/lib/esm/components/c4-job-dashboard-overview-page/c4-job-dashboard-overview.mocks.d.ts +2 -0
  89. package/lib/esm/components/c4-job-dashboard-overview-page/c4-job-dashboard-overview.mocks.js +102 -0
  90. package/lib/esm/components/c4-job-dashboard-shared/c4-job-dashboard-ds-colors.d.ts +10 -0
  91. package/lib/esm/components/c4-job-dashboard-shared/c4-job-dashboard-ds-colors.js +16 -0
  92. package/lib/esm/components/c4-management-activity/c4-management-activity.d.ts +1 -1
  93. package/lib/esm/components/c4-management-activity/c4-management-activity.js +103 -1
  94. package/lib/esm/components/c4-management-activity/c4-management-activity.mocks.d.ts +4 -0
  95. package/lib/esm/components/c4-management-activity/c4-management-activity.mocks.js +63 -0
  96. package/lib/esm/components/c4-management-activity/c4-management-activity.types.d.ts +11 -0
  97. package/lib/esm/components/c4-management-api/c4-management-api.mocks.d.ts +43 -0
  98. package/lib/esm/components/c4-management-api/c4-management-api.mocks.js +118 -0
  99. package/lib/esm/components/c4-management-overview/c4-management-overview.js +6 -4
  100. package/lib/esm/components/c4-old-dashboard/c4-old-dashboard.js +1 -1
  101. package/lib/esm/components/c4-old-dashboard/c4-old-dashboard.types.d.ts +1 -0
  102. package/lib/esm/components/c4-selectable-tile/c4-selectable-tile.js +4 -1
  103. package/lib/esm/components/c4-telemetry-page/telemetry-for-component.js +58 -36
  104. package/lib/esm/components/c4-usage-history/elements/usage-history-charts.js +6 -0
  105. package/lib/esm/components/c4-user-details/tabs/authorized-resources.js +3 -1
  106. package/lib/esm/components/shared-charts/ds-charts.smoke.spec.d.ts +1 -0
  107. package/lib/esm/components/shared-charts/ds-charts.smoke.spec.js +47 -0
  108. package/lib/esm/components/shared-charts/ds-line-chart.d.ts +33 -0
  109. package/lib/esm/components/shared-charts/ds-line-chart.js +55 -0
  110. package/lib/esm/components/shared-charts/ds-meter-chart.d.ts +22 -0
  111. package/lib/esm/components/shared-charts/ds-meter-chart.js +48 -0
  112. package/lib/esm/components/shared-charts/recharts-tokens.d.ts +24 -0
  113. package/lib/esm/components/shared-charts/recharts-tokens.js +51 -0
  114. package/lib/esm/externalUrls.const.d.ts +2 -0
  115. package/lib/esm/externalUrls.const.js +7 -0
  116. package/lib/esm/externalUrls.const.spec.js +2 -0
  117. package/lib/esm/i18n/en/entities/orgroles.json +0 -16
  118. package/lib/esm/i18n/en/pages/clusterdetails.json +9 -1
  119. package/lib/esm/i18n/en/pages/orgmanagement.json +9 -2
  120. package/lib/esm/index.d.ts +16 -1
  121. package/lib/esm/index.js +10 -1
  122. package/lib/esm/runtime/c4-console-authz.d.ts +26 -0
  123. package/lib/esm/runtime/c4-console-authz.js +58 -28
  124. package/lib/esm/runtime/c4-console-authz.spec.js +84 -17
  125. package/lib/esm/runtime/c4-console-data-context.js +40 -0
  126. package/lib/esm/runtime/c4-console-data-context.types.d.ts +19 -1
  127. package/lib/esm/runtime/c4-console-data-store.d.ts +25 -1
  128. package/lib/esm/runtime/c4-console-data-store.js +145 -31
  129. package/lib/esm/runtime/c4-console-data-store.nav.spec.d.ts +1 -0
  130. package/lib/esm/runtime/c4-console-data-store.nav.spec.js +121 -0
  131. package/lib/esm/runtime/c4-console-data-store.spec.js +35 -6
  132. package/lib/esm/runtime/c4-console-events-context.d.ts +18 -0
  133. package/lib/esm/runtime/c4-console-events-context.js +62 -0
  134. package/lib/esm/runtime/c4-console-runtime.types.d.ts +12 -0
  135. package/lib/esm/runtime/c4-user-notifications-context.d.ts +19 -0
  136. package/lib/esm/runtime/c4-user-notifications-context.js +201 -0
  137. package/lib/esm/runtime/c4-user-notifications-context.spec.d.ts +1 -0
  138. package/lib/esm/runtime/c4-user-notifications-context.spec.js +80 -0
  139. package/lib/esm/runtime/c4-user-notifications-context.types.d.ts +31 -0
  140. package/lib/esm/runtime/c4-user-notifications-context.types.js +6 -0
  141. package/lib/esm/runtime/c4-user-theme.d.ts +27 -0
  142. package/lib/esm/runtime/c4-user-theme.js +106 -0
  143. package/lib/esm/runtime/decode-access-token.d.ts +12 -0
  144. package/lib/esm/runtime/decode-access-token.js +39 -0
  145. package/lib/esm/runtime/nav/camunda-apps.d.ts +45 -0
  146. package/lib/esm/runtime/nav/camunda-apps.js +100 -0
  147. package/lib/esm/runtime/nav/camunda-apps.spec.d.ts +1 -0
  148. package/lib/esm/runtime/nav/camunda-apps.spec.js +90 -0
  149. package/lib/esm/runtime/nav/use-webapp-nav-data.d.ts +75 -0
  150. package/lib/esm/runtime/nav/use-webapp-nav-data.js +211 -0
  151. package/lib/esm/runtime/nav/use-webapp-nav-data.spec.d.ts +1 -0
  152. package/lib/esm/runtime/nav/use-webapp-nav-data.spec.js +91 -0
  153. package/lib/esm/runtime/to-api-config.js +4 -0
  154. package/lib/esm/ui/index.d.ts +1 -0
  155. package/lib/esm/ui/index.js +3 -2
  156. package/lib/esm/widgets/cluster-details/c4-cluster-details-app.d.ts +1 -0
  157. package/lib/esm/widgets/cluster-details/c4-cluster-details-app.js +32 -13
  158. package/lib/esm/widgets/cluster-details/c4-cluster-details-app.merge.spec.d.ts +1 -0
  159. package/lib/esm/widgets/cluster-details/c4-cluster-details-app.merge.spec.js +49 -0
  160. package/lib/esm/widgets/cluster-details/c4-cluster-details-app.types.d.ts +8 -0
  161. package/lib/esm/widgets/cluster-details/cluster-details-tabs.d.ts +23 -0
  162. package/lib/esm/widgets/cluster-details/cluster-details-tabs.js +83 -0
  163. package/lib/esm/widgets/cluster-details/cluster-details-tabs.spec.d.ts +1 -0
  164. package/lib/esm/widgets/cluster-details/cluster-details-tabs.spec.js +33 -0
  165. package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-alerts-tab.js +17 -84
  166. package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-ip-whitelist-tab.js +19 -35
  167. package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-overview-tab.js +38 -18
  168. package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-overview-tab.spec.js +38 -14
  169. package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-settings-tab.d.ts +2 -0
  170. package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-settings-tab.js +190 -3
  171. package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-settings-tab.spec.js +60 -1
  172. package/lib/esm/widgets/clusters/c4-clusters-page.js +80 -44
  173. package/lib/esm/widgets/clusters/c4-clusters-page.spec.js +48 -48
  174. package/lib/esm/widgets/clusters/c4-clusters-page.types.d.ts +2 -0
  175. package/lib/esm/widgets/connector-management/c4-connector-management-page.spec.js +32 -0
  176. package/lib/esm/widgets/connector-management/c4-connector-management.shared.js +4 -3
  177. package/lib/esm/widgets/dashboard/c4-dashboard-app.js +21 -2
  178. package/lib/esm/widgets/group-details/c4-group-details-page.js +3 -2
  179. package/lib/esm/widgets/management/c4-management-app.js +80 -24
  180. package/lib/esm/widgets/management/c4-management-app.spec.js +32 -10
  181. package/lib/esm/widgets/management/management-tabs.d.ts +22 -0
  182. package/lib/esm/widgets/management/management-tabs.js +76 -0
  183. package/lib/esm/widgets/management/management-tabs.spec.d.ts +1 -0
  184. package/lib/esm/widgets/management/management-tabs.spec.js +28 -0
  185. package/lib/esm/widgets/management/tabs/c4-management-overview-tab.d.ts +2 -1
  186. package/lib/esm/widgets/management/tabs/c4-management-overview-tab.js +11 -2
  187. package/lib/esm/widgets/management/tabs/c4-management-users-tab.js +0 -10
  188. package/lib/esm/widgets/user-details/c4-user-details-page.js +0 -10
  189. package/package.json +9 -7
@@ -0,0 +1,3 @@
1
+ import type { C4BillingPageProps } from './c4-billing-page.types';
2
+ export declare const enterpriseProps: C4BillingPageProps;
3
+ export declare const enterpriseLicensingModel2025Props: C4BillingPageProps;
@@ -0,0 +1,154 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ const usageAlerts = {
3
+ title: 'Usage alerts',
4
+ description: 'Alerts are sent via email and in-app messages the day after thresholds are met.',
5
+ loading: false,
6
+ action: {
7
+ label: 'View change history',
8
+ onClick: () => console.log('view change history cta clicked'),
9
+ },
10
+ data: {
11
+ heading: {
12
+ metric: 'Metric',
13
+ threshold: 'Usage threshold',
14
+ status: 'Status',
15
+ },
16
+ rows: [
17
+ {
18
+ key: 'pi',
19
+ metric: 'Process instances',
20
+ threshold: '80%',
21
+ status: 'On',
22
+ action: {
23
+ label: 'Edit alert',
24
+ onClick: () => console.log('edit alert cta clicked'),
25
+ },
26
+ },
27
+ {
28
+ key: 'di',
29
+ metric: 'Decision instances',
30
+ threshold: '50%',
31
+ status: 'Off',
32
+ action: {
33
+ label: 'Edit alert',
34
+ onClick: () => console.log('edit alert cta clicked'),
35
+ },
36
+ },
37
+ ],
38
+ },
39
+ };
40
+ export const enterpriseProps = {
41
+ title: 'Billing',
42
+ subheading: (_jsxs("p", { children: ["Contact us for billing queries at", ' ', _jsx("a", { href: 'mailto:prof-user@camunda.com', children: "prof-user@camunda.com" })] })),
43
+ planDetails: {
44
+ title: 'Plan details',
45
+ description: 'Updated on April 27, 2023 at 6AM (UTC +1)',
46
+ loading: false,
47
+ plan: {
48
+ title: 'Enterprise',
49
+ subTitle: 'Plan',
50
+ },
51
+ additional: {
52
+ title: 'May 10, 2024',
53
+ subTitle: 'Renews',
54
+ },
55
+ },
56
+ usageAlerts,
57
+ currentUsageMetrics: {
58
+ title: _jsx("p", { children: "\"Current usage metrics\"" }),
59
+ description: 'Billing Period (July 10, 2023 - August 09, 2023)',
60
+ order: ['tu', 'gu', 'pi', 'di'],
61
+ taskUsers: {
62
+ title: 'Task users',
63
+ loading: false,
64
+ metric: {
65
+ kind: 'chart',
66
+ value: {
67
+ current: 5,
68
+ max: 10,
69
+ maxPostfix: 'total seats',
70
+ },
71
+ },
72
+ },
73
+ generalUsers: {
74
+ title: 'General users',
75
+ loading: false,
76
+ metric: {
77
+ kind: 'simple',
78
+ value: {
79
+ title: '5 used',
80
+ max: 'unlimited',
81
+ },
82
+ },
83
+ },
84
+ processInstances: {
85
+ title: 'Process instances',
86
+ loading: false,
87
+ metric: {
88
+ kind: 'chart',
89
+ value: {
90
+ current: 400000,
91
+ max: 500000,
92
+ maxPostfix: 'incl.',
93
+ },
94
+ },
95
+ },
96
+ decisionInstances: {
97
+ title: 'Decision instances',
98
+ loading: false,
99
+ metric: {
100
+ kind: 'chart',
101
+ value: {
102
+ current: 600000,
103
+ max: 500000,
104
+ maxPostfix: 'incl.',
105
+ },
106
+ overagesDescription: 'You are exceeding the usage included in your monthly plan. Additional usage will be billed in your next invoice. Contact prof-user@camunda.com if you have any questions.',
107
+ },
108
+ },
109
+ },
110
+ clusterReservations: {
111
+ title: 'Clusters',
112
+ description: 'Alerts are sent via email and in-app messages the day after thresholds are met.',
113
+ tooltip: 'Includes both active clusters and their size. Each size increase uses an additional reservation slot. To add more, contact your Customer Success Manager.',
114
+ loading: false,
115
+ data: {
116
+ heading: {
117
+ type: 'Type',
118
+ clusters: 'Clusters running',
119
+ used: 'Reservations used',
120
+ totalReserved: 'Total reservations',
121
+ },
122
+ rows: [
123
+ {
124
+ key: 'dev',
125
+ type: 'Advanced Offering Basic',
126
+ clusters: 0,
127
+ used: 0,
128
+ totalReserved: '0/10',
129
+ },
130
+ {
131
+ key: 'prod',
132
+ type: 'Production Cluster',
133
+ clusters: 1,
134
+ used: 1,
135
+ totalReserved: '1/3',
136
+ },
137
+ ],
138
+ },
139
+ },
140
+ };
141
+ export const enterpriseLicensingModel2025Props = {
142
+ ...enterpriseProps,
143
+ usageAlerts: {
144
+ ...usageAlerts,
145
+ data: {
146
+ ...usageAlerts.data,
147
+ rows: usageAlerts.data.rows.filter((row) => row.key === 'pi'),
148
+ },
149
+ },
150
+ currentUsageMetrics: {
151
+ ...enterpriseProps.currentUsageMetrics,
152
+ order: ['gu', 'pi'],
153
+ },
154
+ };
@@ -4,6 +4,8 @@ export declare enum CHART_COLORS {
4
4
  RED = "#FF832B",// Orange color (original "red")
5
5
  GREEN = "#24a148"
6
6
  }
7
+ /** ds-mode equivalents of `CHART_COLORS`, shared with `cluster-load.tsx`. */
8
+ export declare const CHART_COLORS_DS: Record<CHART_COLORS, string>;
7
9
  export interface ValueMetricProps {
8
10
  title: string;
9
11
  loading: boolean;
@@ -7,16 +7,26 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
7
7
  import { MeterChart } from '@carbon/charts-react';
8
8
  import { DefinitionTooltip } from '@carbon/react';
9
9
  import { WarningAlt } from '@carbon/react/icons/index.esm.js';
10
- import { Stack } from '../../../ui/index.js';
10
+ import { useC4DesignSystem } from '../../../runtime/c4-console-runtime-context.js';
11
+ import { Stack, Tooltip } from '../../../ui/index.js';
11
12
  import { C4LinkButton } from '../../c4-link-button/c4-link-button.js';
12
13
  import { C4TileWithTitleAndAction } from '../../c4-tile-with-title-and-action/c4-tile-with-title-and-action.js';
14
+ import { DsMeterChart } from '../../shared-charts/ds-meter-chart.js';
15
+ import { DS_STATUS_COLORS } from '../../shared-charts/recharts-tokens.js';
13
16
  export var CHART_COLORS;
14
17
  (function (CHART_COLORS) {
15
18
  CHART_COLORS["BLUE"] = "#0F62FE";
16
19
  CHART_COLORS["RED"] = "#FF832B";
17
20
  CHART_COLORS["GREEN"] = "#24a148";
18
21
  })(CHART_COLORS || (CHART_COLORS = {}));
22
+ /** ds-mode equivalents of `CHART_COLORS`, shared with `cluster-load.tsx`. */
23
+ export const CHART_COLORS_DS = {
24
+ [CHART_COLORS.BLUE]: DS_STATUS_COLORS.info,
25
+ [CHART_COLORS.RED]: DS_STATUS_COLORS.danger,
26
+ [CHART_COLORS.GREEN]: DS_STATUS_COLORS.success,
27
+ };
19
28
  export const ValueMetric = ({ title, metric, loading, isEnterpriseOrg = false, }) => {
29
+ const designSystem = useC4DesignSystem();
20
30
  let chartProps;
21
31
  let simpleProps;
22
32
  switch (metric.kind) {
@@ -46,7 +56,7 @@ export const ValueMetric = ({ title, metric, loading, isEnterpriseOrg = false, }
46
56
  gap: '0.5rem',
47
57
  }, children: [_jsx(WarningAlt, { style: {
48
58
  color: CHART_COLORS.RED,
49
- } }), _jsxs("p", { children: [_jsx(DefinitionTooltip, { openOnHover: true, definition: metric.overagesDescription, children: _jsx("p", { children: "Overages" }) }), ' ', "applied"] })] }))] }) }));
59
+ } }), _jsxs("p", { children: [designSystem === 'ds' ? (_jsx(Tooltip, { label: metric.overagesDescription, children: _jsx("span", { style: { textDecoration: 'underline dotted' }, children: "Overages" }) })) : (_jsx(DefinitionTooltip, { openOnHover: true, definition: metric.overagesDescription, children: _jsx("p", { children: "Overages" }) })), ' ', "applied"] })] }))] }) }));
50
60
  return component;
51
61
  };
52
62
  const SimpleText = ({ title, subTitle }) => {
@@ -58,6 +68,7 @@ const SimpleText = ({ title, subTitle }) => {
58
68
  return component;
59
69
  };
60
70
  const MeterVisualization = ({ currentPrefix, current, currentPostfix, max, maxPostfix, label, isEnterpriseOrg = false, }) => {
71
+ const designSystem = useC4DesignSystem();
61
72
  // Determine color based on usage and organization type
62
73
  let barColor = CHART_COLORS.BLUE;
63
74
  if (current > max) {
@@ -104,7 +115,7 @@ const MeterVisualization = ({ currentPrefix, current, currentPostfix, max, maxPo
104
115
  display: 'grid',
105
116
  gridTemplateColumns: '1fr auto',
106
117
  width: '100%',
107
- }, children: [_jsx("p", { style: { fontSize: '18px' }, children: data.current }), _jsx("p", { style: { color: 'var(--cds-text-helper)', alignSelf: 'end' }, children: data.max })] }), max > 0 && (_jsx(MeterChart, { data: [
118
+ }, children: [_jsx("p", { style: { fontSize: '18px' }, children: data.current }), _jsx("p", { style: { color: 'var(--cds-text-helper)', alignSelf: 'end' }, children: data.max })] }), max > 0 && designSystem === 'ds' && (_jsx(DsMeterChart, { value: current, max: max, color: CHART_COLORS_DS[barColor] })), max > 0 && designSystem !== 'ds' && (_jsx(MeterChart, { data: [
108
119
  {
109
120
  group,
110
121
  value: current,
@@ -7,9 +7,18 @@ import { jsx as _jsx } from "react/jsx-runtime";
7
7
  import { render, screen } from '@testing-library/react';
8
8
  import { vi } from 'vitest';
9
9
  import { ValueMetric } from './value-metric.js';
10
+ const { mockUseC4DesignSystem } = vi.hoisted(() => ({
11
+ mockUseC4DesignSystem: vi.fn(() => 'carbon'),
12
+ }));
10
13
  vi.mock('@carbon/charts-react', () => ({
11
14
  MeterChart: ({ data }) => (_jsx("div", { "data-testid": 'meter-chart', "data-value": data[0]?.value })),
12
15
  }));
16
+ vi.mock('../../../runtime/c4-console-runtime-context', () => ({
17
+ useC4DesignSystem: mockUseC4DesignSystem,
18
+ }));
19
+ vi.mock('../../shared-charts/ds-meter-chart', () => ({
20
+ DsMeterChart: () => _jsx("div", { "data-testid": 'ds-meter-chart' }),
21
+ }));
13
22
  function buildChartProps(current, max = 500000) {
14
23
  return {
15
24
  title: 'Process instances',
@@ -24,6 +33,9 @@ function buildChartProps(current, max = 500000) {
24
33
  };
25
34
  }
26
35
  describe('ValueMetric', () => {
36
+ beforeEach(() => {
37
+ mockUseC4DesignSystem.mockReturnValue('carbon');
38
+ });
27
39
  describe('MeterChart (progress bar)', () => {
28
40
  it('renders the progress bar when included (max) > 0', () => {
29
41
  render(_jsx(ValueMetric, { ...buildChartProps(0, 500000) }));
@@ -45,5 +57,11 @@ describe('ValueMetric', () => {
45
57
  render(_jsx(ValueMetric, { ...buildChartProps(0, 0) }));
46
58
  expect(screen.getAllByText('0')).toHaveLength(2);
47
59
  });
60
+ it('renders ds meter chart in ds mode', () => {
61
+ mockUseC4DesignSystem.mockReturnValue('ds');
62
+ render(_jsx(ValueMetric, { ...buildChartProps(400000, 500000) }));
63
+ expect(screen.getByTestId('ds-meter-chart')).toBeInTheDocument();
64
+ expect(screen.queryByTestId('meter-chart')).not.toBeInTheDocument();
65
+ });
48
66
  });
49
67
  });
@@ -6,7 +6,54 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
6
6
  */
7
7
  import { AlluvialChart } from '@carbon/charts-react';
8
8
  import { useCallback, useEffect, useMemo, useRef, useState, } from 'react';
9
+ import { ResponsiveContainer, Sankey, Tooltip } from 'recharts';
10
+ import { useC4DesignSystem } from '../../../runtime/c4-console-runtime-context.js';
9
11
  import { Button, MultiSelect, Stack, Tile } from '../../../ui/index.js';
12
+ import { DS_CHART_TOOLTIP_PROPS, getDsSeriesColor, } from '../../shared-charts/recharts-tokens.js';
13
+ /** Maps each node to a categorical color, keyed by its `category` (falls back to node order). */
14
+ function buildNodeColorByName(nodes) {
15
+ const categories = [];
16
+ for (const node of nodes) {
17
+ if (node.category && !categories.includes(node.category)) {
18
+ categories.push(node.category);
19
+ }
20
+ }
21
+ const colorByName = new Map();
22
+ nodes.forEach((node, index) => {
23
+ const colorIndex = node.category ? categories.indexOf(node.category) : index;
24
+ colorByName.set(node.name, getDsSeriesColor(colorIndex));
25
+ });
26
+ return colorByName;
27
+ }
28
+ function buildSankeyData(nodes, dataPoints) {
29
+ const indexByName = new Map(nodes.map((node, index) => [node.name, index]));
30
+ const links = dataPoints.flatMap((point) => {
31
+ const source = indexByName.get(point.source);
32
+ const target = indexByName.get(point.target);
33
+ return source === undefined || target === undefined
34
+ ? []
35
+ : [{ source, target, value: point.value }];
36
+ });
37
+ return { nodes: nodes.map((node) => ({ name: node.name })), links };
38
+ }
39
+ function renderSankeyNode(colorByName) {
40
+ return function SankeyNodeShape(props) {
41
+ const { x, y, width, height, payload } = props;
42
+ const color = colorByName.get(payload.name) ?? getDsSeriesColor(0);
43
+ const isSink = payload.sourceLinks.length === 0;
44
+ return (_jsxs("g", { children: [_jsx("rect", { x: x, y: y, width: width, height: height, fill: color, rx: 2 }), _jsx("text", { x: isSink ? x - 6 : x + width + 6, y: y + height / 2, dy: '0.32em', fontSize: 11, textAnchor: isSink ? 'end' : 'start', fill: 'var(--neutral-foreground-strong)', children: payload.name })] }));
45
+ };
46
+ }
47
+ function renderSankeyLink(colorByName, gradient) {
48
+ return function SankeyLinkShape(props) {
49
+ const { sourceX, sourceY, sourceControlX, targetX, targetY, targetControlX, linkWidth, index, payload, } = props;
50
+ const sourceColor = colorByName.get(payload.source.name) ?? getDsSeriesColor(0);
51
+ const targetColor = colorByName.get(payload.target.name) ?? sourceColor;
52
+ const gradientId = `c4-alluvial-link-${index}`;
53
+ const d = `M${sourceX},${sourceY} C${sourceControlX},${sourceY} ${targetControlX},${targetY} ${targetX},${targetY}`;
54
+ return (_jsxs("g", { children: [gradient && (_jsx("defs", { children: _jsxs("linearGradient", { id: gradientId, x1: '0', x2: '1', y1: '0', y2: '0', children: [_jsx("stop", { offset: '0%', stopColor: sourceColor, stopOpacity: 0.55 }), _jsx("stop", { offset: '100%', stopColor: targetColor, stopOpacity: 0.55 })] }) })), _jsx("path", { d: d, fill: 'none', stroke: gradient ? `url(#${gradientId})` : sourceColor, strokeOpacity: gradient ? 1 : 0.4, strokeWidth: linkWidth })] }));
55
+ };
56
+ }
10
57
  export const C4AlluvialChart = ({ title, dataPoints, nodes, height = 600, gradient, theme, }) => {
11
58
  // Compute target node totals
12
59
  const targetTotals = useMemo(() => {
@@ -49,6 +96,11 @@ export const C4AlluvialChart = ({ title, dataPoints, nodes, height = 600, gradie
49
96
  }, [dataPoints, nodes, selectedTargets, sortedTargets]);
50
97
  // Key forces full re-render when the node set size or selectedTargets change materially
51
98
  const chartKey = useMemo(() => `alluvial-${filteredNodes.length}-${filteredDataPoints.length}-${selectedTargets.join(',')}`, [filteredNodes.length, filteredDataPoints.length, selectedTargets]);
99
+ const designSystem = useC4DesignSystem();
100
+ const nodeColorByName = useMemo(() => buildNodeColorByName(filteredNodes), [filteredNodes]);
101
+ const sankeyData = useMemo(() => buildSankeyData(filteredNodes, filteredDataPoints), [filteredNodes, filteredDataPoints]);
102
+ const sankeyNode = useMemo(() => renderSankeyNode(nodeColorByName), [nodeColorByName]);
103
+ const sankeyLink = useMemo(() => renderSankeyLink(nodeColorByName, gradient), [nodeColorByName, gradient]);
52
104
  const options = {
53
105
  title,
54
106
  alluvial: { nodes: filteredNodes, gradient },
@@ -83,5 +135,10 @@ export const C4AlluvialChart = ({ title, dataPoints, nodes, height = 600, gradie
83
135
  }
84
136
  }, [sortedTargets, selectedTargets]);
85
137
  // Removed debug logging
86
- return (_jsx(Tile, { children: _jsxs(Stack, { gap: 4, children: [_jsxs(Stack, { orientation: 'horizontal', gap: 2, style: { alignItems: 'flex-end' }, children: [_jsx(MultiSelect, { id: `${title}-targets-filter`, titleText: 'Targets', label: 'Targets', items: multiSelectItems, selectedItems: multiSelectItems.filter((i) => selectedTargets.includes(i.id)), itemToString: (item) => (item ? item.text : ''), onChange: onChange, selectionFeedback: 'top-after-reopen', helperText: 'Select targets' }), _jsx(Button, { kind: 'tertiary', size: 'sm', onClick: selectAll, children: "Select all" })] }), _jsx(AlluvialChart, { data: filteredDataPoints, options: options }, chartKey)] }) }));
138
+ return (_jsx(Tile, { children: _jsxs(Stack, { gap: 4, children: [_jsxs(Stack, { orientation: 'horizontal', gap: 2, style: { alignItems: 'flex-end' }, children: [_jsx(MultiSelect, { id: `${title}-targets-filter`, titleText: 'Targets', label: 'Targets', items: multiSelectItems, selectedItems: multiSelectItems.filter((i) => selectedTargets.includes(i.id)), itemToString: (item) => (item ? item.text : ''), onChange: onChange, selectionFeedback: 'top-after-reopen', helperText: 'Select targets' }), _jsx(Button, { kind: 'tertiary', size: 'sm', onClick: selectAll, children: "Select all" })] }), designSystem === 'ds' ? (_jsxs("div", { children: [title && (_jsx("div", { style: {
139
+ fontWeight: 600,
140
+ fontSize: 14,
141
+ marginBottom: 8,
142
+ color: 'var(--neutral-foreground-strong)',
143
+ }, children: title })), _jsx(ResponsiveContainer, { width: '100%', height: height, children: _jsx(Sankey, { data: sankeyData, node: sankeyNode, link: sankeyLink, nodePadding: 20, margin: { top: 8, right: 96, left: 8, bottom: 8 }, children: _jsx(Tooltip, { ...DS_CHART_TOOLTIP_PROPS }) }, chartKey) })] })) : (_jsx(AlluvialChart, { data: filteredDataPoints, options: options }, chartKey))] }) }));
87
144
  };
@@ -1,12 +1,51 @@
1
- import { jsx as _jsx } from "react/jsx-runtime";
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
2
  /*
3
3
  * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
4
4
  * under one or more contributor license agreements. Licensed under a commercial license.
5
5
  * You may not use this file except in compliance with the commercial license.
6
6
  */
7
+ import { BarChart } from '@camunda/design-system';
7
8
  import { GroupedBarChart, SimpleBarChart, StackedBarChart, } from '@carbon/charts-react';
9
+ import { useC4DesignSystem } from '../../../runtime/c4-console-runtime-context.js';
8
10
  import { Stack, Tile } from '../../../ui/index.js';
11
+ import { getDsSeriesColor } from '../../shared-charts/recharts-tokens.js';
12
+ /** Pivots flat {group, key, value} rows into one row per key, keyed by group. */
13
+ function pivotByKey(dataPoints) {
14
+ const groupSet = new Set();
15
+ const rowsByKey = new Map();
16
+ for (const point of dataPoints) {
17
+ groupSet.add(point.group);
18
+ const row = rowsByKey.get(point.key) ?? { key: point.key };
19
+ row[point.group] = point.value;
20
+ rowsByKey.set(point.key, row);
21
+ }
22
+ // Sort groups so the group→colour mapping stays stable regardless of the
23
+ // order the points arrive in.
24
+ return {
25
+ rows: Array.from(rowsByKey.values()),
26
+ groups: Array.from(groupSet).sort(),
27
+ };
28
+ }
9
29
  export const C4BarChart = ({ title, dataPoints, axes, stacked = false, mode, height = 400, theme, }) => {
30
+ const designSystem = useC4DesignSystem();
31
+ const effectiveMode = mode
32
+ ? mode
33
+ : stacked
34
+ ? 'stacked'
35
+ : 'grouped';
36
+ if (designSystem === 'ds') {
37
+ const { rows, groups } = pivotByKey(dataPoints);
38
+ const config = Object.fromEntries(groups.map((group, index) => [
39
+ group,
40
+ { label: group, color: getDsSeriesColor(index) },
41
+ ]));
42
+ return (_jsx(Tile, { children: _jsx(Stack, { children: _jsxs("div", { children: [title && (_jsx("div", { style: {
43
+ fontWeight: 600,
44
+ fontSize: 14,
45
+ marginBottom: 8,
46
+ color: 'var(--neutral-foreground-strong)',
47
+ }, children: title })), _jsx("div", { style: { height }, children: _jsx(BarChart, { className: 'h-full w-full', data: rows, categoryKey: 'key', config: config, stacked: effectiveMode === 'stacked' }) })] }) }) }));
48
+ }
10
49
  const data = dataPoints;
11
50
  const options = {
12
51
  title,
@@ -25,11 +64,6 @@ export const C4BarChart = ({ title, dataPoints, axes, stacked = false, mode, hei
25
64
  height: `${height}px`,
26
65
  theme: theme,
27
66
  };
28
- const effectiveMode = mode
29
- ? mode
30
- : stacked
31
- ? 'stacked'
32
- : 'grouped';
33
67
  if (effectiveMode === 'stacked') {
34
68
  options.axes.left.stacked = true;
35
69
  }
@@ -5,8 +5,14 @@ import { jsx as _jsx } from "react/jsx-runtime";
5
5
  * You may not use this file except in compliance with the commercial license.
6
6
  */
7
7
  import { LineChart } from '@carbon/charts-react';
8
+ import { useC4DesignSystem } from '../../../runtime/c4-console-runtime-context.js';
8
9
  import { Stack, Tile } from '../../../ui/index.js';
10
+ import { DsLineChart } from '../../shared-charts/ds-line-chart.js';
9
11
  export const C4LineChart = ({ title, dataPoints, axes, toolbar = { enabled: true }, zoomBar = { enabled: true }, thresholds, height = 400, theme, }) => {
12
+ const designSystem = useC4DesignSystem();
13
+ if (designSystem === 'ds') {
14
+ return (_jsx(Tile, { children: _jsx(Stack, { children: _jsx(DsLineChart, { title: title, dataPoints: dataPoints, axes: axes, thresholds: thresholds, height: height, zoomBar: zoomBar }) }) }));
15
+ }
10
16
  const data = dataPoints;
11
17
  const options = {
12
18
  title,
@@ -0,0 +1,5 @@
1
+ import type { Alert, C4ClusterDetailsAlertsProps } from './c4-cluster-details-alerts.types';
2
+ export declare const mockText: C4ClusterDetailsAlertsProps['text'];
3
+ export declare const mockPermissions: C4ClusterDetailsAlertsProps['permissions'];
4
+ export declare const mockAlerts: Alert[];
5
+ export declare const withAlertsProps: C4ClusterDetailsAlertsProps;
@@ -0,0 +1,83 @@
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
+ export const mockText = {
3
+ title: 'Alerts',
4
+ createButton: 'Create new alert',
5
+ searchLabel: 'Search',
6
+ deliveryTypeHeader: 'Delivery method',
7
+ createdAtHeader: 'Created at',
8
+ createdByHeader: 'Created by',
9
+ updateAction: 'Update',
10
+ deleteAction: 'Delete',
11
+ targetWebhookLabel: 'Payload URL',
12
+ targetEmailLabel: 'Email address',
13
+ updatedLabel: 'Last updated',
14
+ updatedByLabel: 'Updated by',
15
+ lastTimeTriggeredLabel: 'Last time triggered',
16
+ numberOfTimesTriggeredLabel: 'Amount triggered',
17
+ hmacEnabledLabel: 'HMAC enabled',
18
+ noAlertsTitle: 'Alerts keep you informed',
19
+ noAlertsDescription: (_jsxs(_Fragment, { children: ["Click ", _jsx("strong", { children: "Create an alert" }), " to be notified about incidents in your process instances. ", _jsx("br", {}), "Go straight from an alert to Operate to resolve an incident and unblock your instances."] })),
20
+ noAlertsButton: 'Create an alert',
21
+ noAlertsLink: 'View the alerts documentation',
22
+ infoText: (_jsxs(_Fragment, { children: ["Alerts can be used to get notified about important events in the cluster. See the ", _jsx("a", { href: '#', children: "alerts" }), " documentation to learn more details."] })),
23
+ };
24
+ export const mockPermissions = {
25
+ canCreate: true,
26
+ canCreateDisabled: false,
27
+ canUpdate: true,
28
+ canDelete: true,
29
+ };
30
+ export const mockAlerts = [
31
+ {
32
+ id: '1',
33
+ deliveryMethod: 'Email',
34
+ createdAt: '10 Nov 2025, 14:30',
35
+ createdBy: 'John Doe',
36
+ updatedAt: '11 Nov 2025, 09:15',
37
+ updatedBy: 'Jane Smith',
38
+ lastTimeTriggered: '12 Nov 2025, 08:45',
39
+ triggerCount: 5,
40
+ userIdOrWebhook: 'john.doe@example.com',
41
+ reportType: 'Email',
42
+ hmacEnabled: false,
43
+ canEdit: true,
44
+ },
45
+ {
46
+ id: '2',
47
+ deliveryMethod: 'Webhook',
48
+ createdAt: '08 Nov 2025, 10:20',
49
+ createdBy: 'Alice Johnson',
50
+ updatedAt: '09 Nov 2025, 16:30',
51
+ updatedBy: 'Bob Williams',
52
+ lastTimeTriggered: undefined,
53
+ triggerCount: 0,
54
+ userIdOrWebhook: 'https://example.com/webhook',
55
+ reportType: 'Webhook',
56
+ hmacEnabled: true,
57
+ canEdit: true,
58
+ },
59
+ {
60
+ id: '3',
61
+ deliveryMethod: 'Email',
62
+ createdAt: '05 Nov 2025, 11:45',
63
+ createdBy: 'Charlie Brown',
64
+ updatedAt: undefined,
65
+ updatedBy: undefined,
66
+ lastTimeTriggered: '10 Nov 2025, 12:00',
67
+ triggerCount: 12,
68
+ userIdOrWebhook: 'charlie.brown@example.com',
69
+ reportType: 'Email',
70
+ hmacEnabled: false,
71
+ canEdit: false,
72
+ },
73
+ ];
74
+ export const withAlertsProps = {
75
+ alerts: mockAlerts,
76
+ isLoading: false,
77
+ text: mockText,
78
+ permissions: mockPermissions,
79
+ onCreateAlert: () => console.log('Create alert clicked'),
80
+ onUpdateAlert: (id) => console.log('Update alert clicked:', id),
81
+ onDeleteAlert: (id) => console.log('Delete alert clicked:', id),
82
+ onNoAlertsDocsClick: () => console.log('No alerts docs link clicked'),
83
+ };
@@ -0,0 +1,6 @@
1
+ import type { C4ClusterDetailsClientsProps, ClientItem } from './c4-cluster-details-clients.types';
2
+ export declare const defaultText: C4ClusterDetailsClientsProps['text'];
3
+ export declare const defaultUrls: C4ClusterDetailsClientsProps['urls'];
4
+ export declare const defaultPermissions: C4ClusterDetailsClientsProps['permissions'];
5
+ export declare const sampleClients: ClientItem[];
6
+ export declare const defaultProps: C4ClusterDetailsClientsProps;
@@ -0,0 +1,79 @@
1
+ import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
2
+ export const defaultText = {
3
+ title: 'Client credentials',
4
+ subtitle: 'Open a set of credentials to see the base URLs, connection information, and more.',
5
+ subtitleIdentityPrefix: "To set up permissions, copy the client ID over to the cluster's Identity and configure the required access and roles. Learn more about",
6
+ subtitleIdentityLinkLabel: 'client credentials',
7
+ subtitleIdentitySuffix: '.',
8
+ identityButton: 'Configure authorizations in Identity',
9
+ createButton: 'Create new client',
10
+ createFirstClient: 'Create your first client',
11
+ searchLabel: 'Search',
12
+ headerName: 'Name',
13
+ headerClientId: 'Client Id',
14
+ headerScopes: 'Scopes',
15
+ headerCreated: 'Created',
16
+ headerLastUsed: 'Last Used',
17
+ renameAction: 'Rename',
18
+ deleteAction: 'Delete',
19
+ errorTitle: 'Error fetching clients',
20
+ errorDescription: 'An error occurred while fetching the client list.',
21
+ errorButton: 'Retry',
22
+ emptyTitle: 'Use our secure, scalable API',
23
+ emptyDescription: (_jsxs(_Fragment, { children: ["Click ", _jsx("strong", { children: "Create your first client" }), " to deploy processes, start instances, and interact with them programmatically."] })),
24
+ learnMoreLabel: 'View the Client Configuration documentation',
25
+ };
26
+ export const defaultUrls = {
27
+ clientDetails: (clientId) => `/org/123/clusters/456/clients/${clientId}`,
28
+ identity: 'https://identity.example.com',
29
+ docs: 'https://docs.camunda.io',
30
+ };
31
+ export const defaultPermissions = {
32
+ canCreate: true,
33
+ canUpdate: true,
34
+ canDelete: true,
35
+ };
36
+ export const sampleClients = [
37
+ {
38
+ id: 'client-1',
39
+ name: 'Production Client',
40
+ clientId: 'abc123def456',
41
+ scopes: ['Zeebe', 'Tasklist', 'Operate'],
42
+ created: new Date('2024-01-15T10:30:00Z'),
43
+ lastUsed: new Date('2024-11-15T14:20:00Z'),
44
+ },
45
+ {
46
+ id: 'client-2',
47
+ name: 'Development Client',
48
+ clientId: 'xyz789ghi012',
49
+ scopes: ['Orchestration', 'Optimize'],
50
+ created: new Date('2024-03-20T09:15:00Z'),
51
+ lastUsed: new Date('2024-11-10T11:45:00Z'),
52
+ },
53
+ {
54
+ id: 'client-3',
55
+ name: 'Test Client',
56
+ clientId: 'test123test456',
57
+ scopes: ['Zeebe'],
58
+ created: new Date('2024-06-10T15:00:00Z'),
59
+ lastUsed: undefined,
60
+ },
61
+ ];
62
+ export const defaultProps = {
63
+ clients: sampleClients,
64
+ isLoading: false,
65
+ hasError: false,
66
+ hasIdentityIntegration: false,
67
+ hasIdentityAuthorization: false,
68
+ hasZeebeUrl: true,
69
+ text: defaultText,
70
+ urls: defaultUrls,
71
+ permissions: defaultPermissions,
72
+ onNavigateToClient: (clientId) => console.log('Navigate to client:', clientId),
73
+ onCreateClient: () => console.log('Create client'),
74
+ onUpdateClient: (clientId) => console.log('Update client:', clientId),
75
+ onDeleteClient: (clientId) => console.log('Delete client:', clientId),
76
+ onRefresh: () => console.log('Refresh'),
77
+ onOpenIdentity: () => console.log('Open Identity'),
78
+ onOpenDocs: () => console.log('Open docs'),
79
+ };
@@ -0,0 +1,3 @@
1
+ import type { C4ClusterDetailsConnectorSecretsProps, ConnectorSecret } from './c4-cluster-details-connector-secrets.types';
2
+ export declare const mockSecrets: ConnectorSecret[];
3
+ export declare const withSecretsProps: C4ClusterDetailsConnectorSecretsProps;