@camunda/ccma-saas-frontend 0.0.46 → 0.1.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.
- package/lib/esm/components/c4-actionable-notification/c4-actionable-notification.d.ts +20 -3
- package/lib/esm/components/c4-actionable-notification/c4-actionable-notification.js +50 -17
- package/lib/esm/components/c4-advanced-search-filters/ArrayFieldContainer.js +2 -1
- package/lib/esm/components/c4-advanced-search-filters/AutosuggestInput.js +1 -6
- package/lib/esm/components/c4-advanced-search-filters/FieldRow.js +4 -1
- package/lib/esm/components/c4-advanced-search-filters/FiltersSection.js +1 -6
- package/lib/esm/components/c4-advanced-search-filters/OrSection.js +3 -1
- package/lib/esm/components/c4-advanced-search-filters/c4-advanced-search-filters.js +3 -1
- package/lib/esm/components/c4-ai-usage/c4-ai-usage.js +2 -7
- package/lib/esm/components/c4-alpha-cluster-at-checkout/c4-alpha-cluster-at-checkout.js +7 -7
- package/lib/esm/components/c4-app-teaser-card/c4-app-teaster-card.js +1 -6
- package/lib/esm/components/c4-app-teaser-card/c4-app-teaster-card.spec.d.ts +1 -0
- package/lib/esm/components/c4-app-teaser-card/c4-app-teaster-card.spec.js +43 -0
- package/lib/esm/components/c4-app-teaser-cards/c4-app-teaser-cards.js +1 -1
- package/lib/esm/components/c4-async-modal/c4-async-modal.js +3 -2
- package/lib/esm/components/c4-audit-log/c4-audit-log.js +4 -3
- package/lib/esm/components/c4-billing-page/c4-billing-page.js +8 -6
- package/lib/esm/components/c4-billing-page/elements/cluster-reservations.js +9 -14
- package/lib/esm/components/c4-billing-page/elements/current-usage-metrics.js +2 -1
- package/lib/esm/components/c4-billing-page/elements/usage-alerts.js +3 -8
- package/lib/esm/components/c4-billing-page/elements/value-metric.js +2 -1
- package/lib/esm/components/c4-bottom-links/c4-bottom-links.js +1 -6
- package/lib/esm/components/c4-breadcrumb/c4-breadcrumb.js +3 -6
- package/lib/esm/components/c4-charts-dashboard/c4-charts-dashboard.js +1 -1
- package/lib/esm/components/c4-charts-dashboard/elements/alluvial-chart.js +1 -1
- package/lib/esm/components/c4-charts-dashboard/elements/bar-chart.js +1 -1
- package/lib/esm/components/c4-charts-dashboard/elements/line-chart.js +1 -1
- package/lib/esm/components/c4-cluster-byom-clients/c4-cluster-byom-clients.js +6 -10
- package/lib/esm/components/c4-cluster-client-credentials/c4-cluster-client-credentials.js +8 -3
- package/lib/esm/components/c4-cluster-client-credentials-identity/c4-cluster-client-credentials-identity.js +8 -3
- package/lib/esm/components/c4-cluster-details-activity/c4-cluster-details-activity.js +6 -5
- package/lib/esm/components/c4-cluster-details-alerts/c4-cluster-details-alerts.js +12 -14
- package/lib/esm/components/c4-cluster-details-clients/c4-cluster-details-clients.js +6 -10
- package/lib/esm/components/c4-cluster-details-connector-secrets/c4-cluster-details-connector-secrets.js +8 -11
- package/lib/esm/components/c4-cluster-details-encryption/c4-cluster-details-encryption.js +9 -4
- package/lib/esm/components/c4-cluster-details-hot-backups/c4-cluster-details-hot-backups.js +12 -8
- package/lib/esm/components/c4-cluster-details-hot-backups-restore/c4-cluster-details-hot-backups-restore.js +3 -2
- package/lib/esm/components/c4-cluster-details-ip-whitelist/c4-cluster-details-ip-whitelist.js +7 -10
- package/lib/esm/components/c4-cluster-details-secure-connectivity/c4-cluster-details-secure-connectivity.js +15 -21
- package/lib/esm/components/c4-cluster-list/c4-cluster-list.js +6 -4
- package/lib/esm/components/c4-cluster-overview/applications.js +2 -1
- package/lib/esm/components/c4-cluster-overview/c4-cluster-overview.js +4 -3
- package/lib/esm/components/c4-cluster-overview/cluster-details.js +12 -10
- package/lib/esm/components/c4-cluster-overview/cluster-load.js +1 -1
- package/lib/esm/components/c4-cluster-settings/c4-cluster-settings.js +1 -6
- package/lib/esm/components/c4-cluster-settings/elements/danger-zone.js +1 -6
- package/lib/esm/components/c4-cluster-settings/elements/optimize-filtering-settings.js +3 -3
- package/lib/esm/components/c4-cluster-settings/elements/resource-based-authorizations.js +2 -7
- package/lib/esm/components/c4-cluster-settings/elements/settings-tile.js +1 -6
- package/lib/esm/components/c4-cluster-settings/elements/tasklist-mode-toggle.js +1 -1
- package/lib/esm/components/c4-cluster-tag-selector/c4-cluster-tag-selector.js +4 -2
- package/lib/esm/components/c4-clusters-empty-state/c4-clusters-empty-state.js +18 -14
- package/lib/esm/components/c4-clusters-empty-state/c4-clusters-empty-state.spec.d.ts +1 -0
- package/lib/esm/components/c4-clusters-empty-state/c4-clusters-empty-state.spec.js +40 -0
- package/lib/esm/components/c4-clusters-empty-state/c4-clusters-empty-state.types.d.ts +2 -0
- package/lib/esm/components/c4-clusters-trial-notification/c4-clusters-trial-notification.js +4 -9
- package/lib/esm/components/c4-clusters-trial-notification/c4-clusters-trial-notification.types.d.ts +2 -0
- package/lib/esm/components/c4-console-dashboard/c4-console-dashboard.js +11 -7
- package/lib/esm/components/c4-console-dashboard/elements/empty-state.js +2 -2
- package/lib/esm/components/c4-create-cluster/c4-create-cluster.js +44 -15
- package/lib/esm/components/c4-create-cluster-api-client-modal/c4-create-cluster-api-client-modal.js +4 -2
- package/lib/esm/components/c4-create-connector-secret-modal/c4-create-connector-secret-modal.js +4 -2
- package/lib/esm/components/c4-create-console-api-client-modal/c4-create-console-api-client-modal.js +2 -1
- package/lib/esm/components/c4-create-trial-organization-modal/c4-create-trial-organization-modal.js +2 -1
- package/lib/esm/components/c4-dashboard-first-launch/c4-dashboard-first-launch.js +1 -6
- package/lib/esm/components/c4-data-table/c4-data-table-skeleton.d.ts +15 -0
- package/lib/esm/components/c4-data-table/c4-data-table-skeleton.js +26 -0
- package/lib/esm/components/c4-data-table/c4-data-table.d.ts +3 -0
- package/lib/esm/components/c4-data-table/c4-data-table.js +194 -0
- package/lib/esm/components/c4-data-table/c4-data-table.spec.d.ts +1 -0
- package/lib/esm/components/c4-data-table/c4-data-table.spec.js +71 -0
- package/lib/esm/components/c4-delete-organization-modal/c4-delete-organization-modal.js +3 -2
- package/lib/esm/components/c4-empty-state/c4-empty-state.d.ts +47 -0
- package/lib/esm/components/c4-empty-state/c4-empty-state.js +33 -0
- package/lib/esm/components/c4-extend-trial-modal/c4-extend-trial-modal.d.ts +3 -0
- package/lib/esm/components/c4-extend-trial-modal/c4-extend-trial-modal.js +51 -0
- package/lib/esm/components/c4-extend-trial-modal/c4-extend-trial-modal.spec.d.ts +1 -0
- package/lib/esm/components/c4-extend-trial-modal/c4-extend-trial-modal.spec.js +33 -0
- package/lib/esm/components/c4-extend-trial-modal/c4-extend-trial-modal.types.d.ts +8 -0
- package/lib/esm/components/c4-extend-trial-modal/c4-extend-trial-modal.types.js +1 -0
- package/lib/esm/components/c4-external-link/c4-external-link.js +1 -6
- package/lib/esm/components/c4-feedback-modal/c4-feedback-modal.d.ts +40 -0
- package/lib/esm/components/c4-feedback-modal/c4-feedback-modal.js +109 -0
- package/lib/esm/components/c4-help-center/c4-help-center.d.ts +50 -0
- package/lib/esm/components/c4-help-center/c4-help-center.js +39 -0
- package/lib/esm/components/c4-inline-notification/c4-inline-notification.d.ts +15 -0
- package/lib/esm/components/c4-inline-notification/c4-inline-notification.js +37 -0
- package/lib/esm/components/c4-invite-user-to-organization-modal/c4-invite-user-to-organization-modal.js +4 -3
- package/lib/esm/components/c4-job-dashboard-details-page/c4-job-dashboard-details-page.js +4 -2
- package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-chart-heading.js +1 -1
- package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-error-table.js +3 -8
- package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-time-chart.js +1 -1
- package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-worker-table.js +3 -3
- package/lib/esm/components/c4-job-dashboard-entry-point/c4-job-dashboard-entry-point.js +2 -1
- package/lib/esm/components/c4-job-dashboard-overview-page/c4-job-dashboard-overview.js +43 -46
- package/lib/esm/components/c4-job-dashboard-shared/c4-background-fetching-indicator.js +1 -6
- package/lib/esm/components/c4-job-dashboard-shared/c4-job-dashboard-error-handler.js +1 -1
- package/lib/esm/components/c4-job-dashboard-shared/c4-job-dashboard-table-heading-with-tooltip.js +1 -1
- package/lib/esm/components/c4-job-dashboard-shared/c4-job-dashboard-time-range-dropdown.js +1 -1
- package/lib/esm/components/c4-leave-organization-modal/c4-leave-organization-modal.js +1 -6
- package/lib/esm/components/c4-link-button/c4-link-button.js +1 -6
- package/lib/esm/components/c4-llm-usage-meter/c4-llm-usage-meter.js +1 -1
- package/lib/esm/components/c4-management-activity/c4-management-activity.js +7 -9
- package/lib/esm/components/c4-management-api/c4-management-api.js +9 -11
- package/lib/esm/components/c4-management-overview/c4-management-overview.js +8 -12
- package/lib/esm/components/c4-management-settings/c4-management-settings.js +9 -11
- package/lib/esm/components/c4-management-users/c4-management-users.js +4 -9
- package/lib/esm/components/c4-multi-step-modal/c4-multi-step-modal.js +4 -2
- package/lib/esm/components/c4-multi-step-modal-ugly/c4-multi-step-modal-ugly.js +4 -2
- package/lib/esm/components/c4-navigation/c4-navigation.d.ts +55 -0
- package/lib/esm/components/c4-navigation/c4-navigation.js +175 -0
- package/lib/esm/components/c4-old-dashboard/c4-old-dashboard.js +2 -1
- package/lib/esm/components/c4-page-layout/c4-page-layout.d.ts +13 -0
- package/lib/esm/components/c4-page-layout/c4-page-layout.js +23 -0
- package/lib/esm/components/c4-page-template/c4-page-template.js +14 -3
- package/lib/esm/components/c4-permission-error-page/c4-permission-error-page.js +1 -1
- package/lib/esm/components/c4-pricing/c4-pricing.js +3 -7
- package/lib/esm/components/c4-pricing-card/c4-pricing-card.js +1 -1
- package/lib/esm/components/c4-rename-organization-modal/c4-rename-organization-modal.js +1 -1
- package/lib/esm/components/c4-search/c4-search-results.js +2 -1
- package/lib/esm/components/c4-selectable-tile/c4-selectable-tile.d.ts +20 -0
- package/lib/esm/components/c4-selectable-tile/c4-selectable-tile.js +41 -0
- package/lib/esm/components/c4-sm-cluster-details/automation-components.js +2 -1
- package/lib/esm/components/c4-sm-cluster-details/c4-sm-cluster-details.js +1 -6
- package/lib/esm/components/c4-sm-cluster-details/custom-properties.js +4 -8
- package/lib/esm/components/c4-sm-cluster-details/details.js +5 -4
- package/lib/esm/components/c4-sm-cluster-details/zeebe-components.js +2 -1
- package/lib/esm/components/c4-sm-dashboard/c4-sm-dashboard.js +1 -1
- package/lib/esm/components/c4-sm-dashboard/c4-sm-dashboard.types.d.ts +1 -1
- package/lib/esm/components/c4-sm-dashboard/cluster-tile.js +2 -1
- package/lib/esm/components/c4-sm-dashboard/component-tile.js +2 -1
- package/lib/esm/components/c4-sm-dashboard/explore.js +1 -6
- package/lib/esm/components/c4-sm-dashboard/overview.js +1 -1
- package/lib/esm/components/c4-sm-dashboard/usage-tile.js +2 -1
- package/lib/esm/components/c4-stat/c4-stat.js +1 -6
- package/lib/esm/components/c4-stateful-button/c4-stateful-button.js +2 -1
- package/lib/esm/components/c4-structured-list/c4-structured-list.d.ts +21 -0
- package/lib/esm/components/c4-structured-list/c4-structured-list.js +75 -0
- package/lib/esm/components/c4-tabs/c4-tabs.js +2 -1
- package/lib/esm/components/c4-telemetry-page/c4-telemetry-page.js +6 -2
- package/lib/esm/components/c4-telemetry-page/component-metrics.js +1 -6
- package/lib/esm/components/c4-telemetry-page/telemetry-for-component.js +2 -1
- package/lib/esm/components/c4-telemetry-teaser-page/c4-telemetry-teaser-page.js +1 -1
- package/lib/esm/components/c4-theme-switcher/c4-theme-switcher.js +1 -1
- package/lib/esm/components/c4-tile-with-title-and-action/c4-tile-with-title-and-action.js +1 -1
- package/lib/esm/components/c4-toast-notification/c4-toast-notification.d.ts +14 -0
- package/lib/esm/components/c4-toast-notification/c4-toast-notification.js +27 -0
- package/lib/esm/components/c4-toggle/c4-toggle.js +6 -8
- package/lib/esm/components/c4-tutorial-tile/c4-tutorial-tile.js +1 -1
- package/lib/esm/components/c4-usage-alert-update-modal/c4-usage-alert-update-modal.js +4 -2
- package/lib/esm/components/c4-usage-history/c4-usage-history.js +5 -3
- package/lib/esm/components/c4-usage-history/elements/usage-history-charts.js +1 -1
- package/lib/esm/components/c4-usage-metrics-per-cluster/c4-usage-metrics-per-cluster.js +8 -7
- package/lib/esm/components/c4-user-details/c4-user-details.js +2 -2
- package/lib/esm/components/c4-user-details/tabs/authorized-resources.js +1 -1
- package/lib/esm/components/c4-user-details/tabs/details.js +6 -10
- package/lib/esm/components/c4-user-details/tabs/roles.js +3 -8
- package/lib/esm/i18n/c4-console-i18n.js +8 -0
- package/lib/esm/i18n/en/modals/clusters.json +0 -8
- package/lib/esm/i18n/en/pages/clusterdetails.json +5 -1
- package/lib/esm/i18n/en/pages/orgmanagement.json +3 -1
- package/lib/esm/index.d.ts +17 -0
- package/lib/esm/index.js +13 -0
- package/lib/esm/runtime/c4-console-authz.js +1 -1
- package/lib/esm/runtime/c4-console-authz.spec.js +3 -3
- package/lib/esm/runtime/c4-console-runtime-context.d.ts +8 -1
- package/lib/esm/runtime/c4-console-runtime-context.js +50 -1
- package/lib/esm/runtime/c4-console-runtime.types.d.ts +8 -0
- package/lib/esm/ui/c4-modal-dialog.d.ts +14 -0
- package/lib/esm/ui/c4-modal-dialog.js +35 -0
- package/lib/esm/ui/families.d.ts +42 -0
- package/lib/esm/ui/families.js +46 -0
- package/lib/esm/ui/index.d.ts +31 -0
- package/lib/esm/ui/index.js +94 -0
- package/lib/esm/ui/switchable.d.ts +14 -0
- package/lib/esm/ui/switchable.js +27 -0
- package/lib/esm/ui/tabs.d.ts +21 -0
- package/lib/esm/ui/tabs.js +27 -0
- package/lib/esm/widgets/cluster-client-details/c4-cluster-client-details-app.js +7 -5
- package/lib/esm/widgets/cluster-details/c4-cluster-details-app.js +7 -2
- package/lib/esm/widgets/cluster-details/c4-cluster-details-page.js +1 -1
- package/lib/esm/widgets/cluster-details/c4-cluster-details-page.spec.js +2 -0
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-alerts-tab.js +10 -6
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-byom-clients-tab.js +5 -3
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-clients-tab.js +7 -5
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-connector-secrets-tab.js +10 -6
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-hot-backups-tab.js +3 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-ip-whitelist-tab.js +7 -5
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-overview-tab.js +54 -21
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-overview-tab.spec.js +96 -5
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-secure-connectivity-tab.js +12 -9
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-settings-tab.js +5 -4
- package/lib/esm/widgets/clusters/c4-clusters-page.d.ts +1 -1
- package/lib/esm/widgets/clusters/c4-clusters-page.js +122 -66
- package/lib/esm/widgets/clusters/c4-clusters-page.spec.js +133 -0
- package/lib/esm/widgets/clusters/c4-clusters-page.types.d.ts +1 -0
- package/lib/esm/widgets/connector-management/c4-connector-management-executable-details-page.js +1 -1
- package/lib/esm/widgets/connector-management/c4-connector-management-executables-table-page.js +3 -2
- package/lib/esm/widgets/connector-management/c4-connector-management-outbound-details-page.d.ts +4 -0
- package/lib/esm/widgets/connector-management/c4-connector-management-outbound-details-page.js +59 -0
- package/lib/esm/widgets/connector-management/c4-connector-management-outbound-details-page.types.d.ts +18 -0
- package/lib/esm/widgets/connector-management/c4-connector-management-outbound-details-page.types.js +6 -0
- package/lib/esm/widgets/connector-management/c4-connector-management-page.d.ts +1 -1
- package/lib/esm/widgets/connector-management/c4-connector-management-page.js +38 -5
- package/lib/esm/widgets/connector-management/c4-connector-management-page.spec.js +54 -0
- package/lib/esm/widgets/connector-management/c4-connector-management-page.types.d.ts +11 -0
- package/lib/esm/widgets/connector-management/c4-connector-management.shared.d.ts +1 -0
- package/lib/esm/widgets/connector-management/c4-connector-management.shared.js +10 -2
- package/lib/esm/widgets/create-cluster/c4-create-cluster-page.js +1 -1
- package/lib/esm/widgets/management/c4-management-app.d.ts +1 -1
- package/lib/esm/widgets/management/c4-management-app.js +57 -4
- package/lib/esm/widgets/management/c4-management-app.spec.js +141 -1
- package/lib/esm/widgets/management/c4-management-app.types.d.ts +5 -0
- package/lib/esm/widgets/management/c4-management-page.js +1 -6
- package/lib/esm/widgets/management/tabs/c4-management-api-tab.js +4 -2
- package/lib/esm/widgets/management/tabs/c4-management-billing-tab.js +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-groups-tab.js +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-overview-tab.d.ts +2 -1
- package/lib/esm/widgets/management/tabs/c4-management-overview-tab.js +10 -3
- package/lib/esm/widgets/management/tabs/c4-management-pricing-tab.js +2 -1
- package/lib/esm/widgets/management/tabs/c4-management-settings-tab.js +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-usage-tab.d.ts +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-usage-tab.js +13 -11
- package/lib/esm/widgets/management/tabs/c4-management-users-tab.js +47 -5
- package/lib/esm/widgets/management/tabs/c4-management-users-tab.spec.js +98 -0
- package/lib/esm/widgets/use-extend-trial.d.ts +8 -0
- package/lib/esm/widgets/use-extend-trial.js +36 -0
- package/lib/esm/widgets/use-extend-trial.spec.d.ts +1 -0
- package/lib/esm/widgets/use-extend-trial.spec.js +79 -0
- package/lib/esm/widgets/user-details/c4-user-details-page.js +5 -4
- package/package.json +13 -6
|
@@ -6,7 +6,6 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
6
6
|
*/
|
|
7
7
|
import { AuditLoggerService, ConsoleAlertsService, ConsoleByomMonitoringService, ConsoleClusterClientsService, ConsoleClusterParametersService, ConsoleClusterService, HdpService, SaaSJobsService, } from '@camunda/ccma-api';
|
|
8
8
|
import { checkVersion, SseEntity, VersionCheckOperator, } from '@camunda/ccma-shared-types';
|
|
9
|
-
import { Modal, Stack, TextInput } from '@carbon/react';
|
|
10
9
|
import { observer } from 'mobx-react-lite';
|
|
11
10
|
import { useCallback, useEffect, useMemo, useRef, useState, } from 'react';
|
|
12
11
|
import { getC4ClusterDetailsUrls } from '../../externalUrls.const.js';
|
|
@@ -14,6 +13,7 @@ import { useC4ConsoleAuthz } from '../../runtime/c4-console-authz.js';
|
|
|
14
13
|
import { useC4ConsoleData } from '../../runtime/c4-console-data-context.js';
|
|
15
14
|
import { useC4ConsoleRuntime } from '../../runtime/c4-console-runtime-context.js';
|
|
16
15
|
import { toApiConfig } from '../../runtime/to-api-config.js';
|
|
16
|
+
import { Modal, Stack, TextInput } from '../../ui/index.js';
|
|
17
17
|
import { C4ClusterDetailsPage } from './c4-cluster-details-page.js';
|
|
18
18
|
import { C4ClusterDetailsActivityTab } from './tabs/c4-cluster-details-activity-tab.js';
|
|
19
19
|
import { C4ClusterDetailsAlertsTab } from './tabs/c4-cluster-details-alerts-tab.js';
|
|
@@ -715,7 +715,12 @@ export const C4ClusterDetailsApp = observer((props) => {
|
|
|
715
715
|
]);
|
|
716
716
|
// Get members from cache after fetch completes
|
|
717
717
|
const members = data.getMembers(props.orgId) ?? [];
|
|
718
|
-
|
|
718
|
+
// Defend against a non-array audit response (e.g. an undefined body or
|
|
719
|
+
// an unmocked service in tests): `groupAuditsByDate` iterates `audits`,
|
|
720
|
+
// so a non-iterable here throws "audits is not iterable" inside this
|
|
721
|
+
// async callback. When the component has already unmounted (tests), that
|
|
722
|
+
// rejection surfaces as an unhandled error and fails the run.
|
|
723
|
+
const grouped = groupAuditsByDate(Array.isArray(audits) ? audits : []);
|
|
719
724
|
// Map audits to activity items with fresh members and clients data
|
|
720
725
|
const mapAudits = (auditList) => auditList.map((audit) => auditToActivityItem(audit, members, clients));
|
|
721
726
|
setActivityGroups([
|
|
@@ -4,10 +4,10 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
|
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 { BreadcrumbSkeleton, Link, SkeletonText, Stack, TabsSkeleton, Tooltip, } from '@carbon/react';
|
|
8
7
|
import { WarningAltFilled } from '@carbon/react/icons/index.esm.js';
|
|
9
8
|
import { C4PageTemplate } from '../../components/c4-page-template/c4-page-template.js';
|
|
10
9
|
import { useC4ConsoleRuntime } from '../../runtime/c4-console-runtime-context.js';
|
|
10
|
+
import { BreadcrumbSkeleton, Link, SkeletonText, Stack, TabsSkeleton, Tooltip, } from '../../ui/index.js';
|
|
11
11
|
const breadCrumbWrapperStyles = {
|
|
12
12
|
minHeight: '40px',
|
|
13
13
|
display: 'grid',
|
|
@@ -42,6 +42,8 @@ describe('C4ClusterDetailsPage', () => {
|
|
|
42
42
|
onLearnMore,
|
|
43
43
|
};
|
|
44
44
|
renderPage({ banner });
|
|
45
|
+
// The Callout banner renders its content twice (visible copy + a
|
|
46
|
+
// visibility:hidden height-spacer), matching the deployed render.
|
|
45
47
|
expect(screen.getAllByText('Unmaintained cluster generation').length).toBe(2);
|
|
46
48
|
expect(screen.getAllByText('Alpha-generations can’t be updated. Create a new cluster to access the latest features.').length).toBe(2);
|
|
47
49
|
const learnMoreLinks = screen.getAllByText('Learn more');
|
|
@@ -4,11 +4,14 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
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 {
|
|
7
|
+
import { Form, PasswordInput } from '@carbon/react';
|
|
8
8
|
import { Fragment, useCallback, useState } from 'react';
|
|
9
9
|
import { C4ActionableNotification } from '../../../components/c4-actionable-notification/c4-actionable-notification.js';
|
|
10
10
|
import { C4ClusterDetailsAlerts } from '../../../components/c4-cluster-details-alerts/c4-cluster-details-alerts.js';
|
|
11
|
+
import { C4InlineNotification } from '../../../components/c4-inline-notification/c4-inline-notification.js';
|
|
11
12
|
import { useC4ConsoleRuntime } from '../../../runtime/c4-console-runtime-context.js';
|
|
13
|
+
import { Checkbox, Link, Modal, Stack, TextInput } from '../../../ui/index.js';
|
|
14
|
+
import { useRadioFamily } from '../../../ui/families.js';
|
|
12
15
|
// Helper to translate with fallback
|
|
13
16
|
function safeTranslate(translateFn, key, fallback, options) {
|
|
14
17
|
try {
|
|
@@ -41,6 +44,7 @@ function renderInlineStrongWithBreaks(value, renderStrong) {
|
|
|
41
44
|
return parts.map((part, index) => (_jsxs(Fragment, { children: [renderStrong(part.trim()), index < parts.length - 1 ? _jsx("br", {}) : null] }, `alert-empty-state-${part.trim()}-${index < parts.length - 1 ? 'break' : 'end'}`)));
|
|
42
45
|
}
|
|
43
46
|
export const C4ClusterDetailsAlertsTab = (props) => {
|
|
47
|
+
const { RadioButton, RadioButtonGroup } = useRadioFamily();
|
|
44
48
|
const runtime = useC4ConsoleRuntime();
|
|
45
49
|
const [createAlertOpen, setCreateAlertOpen] = useState(false);
|
|
46
50
|
const [updateAlertOpen, setUpdateAlertOpen] = useState(false);
|
|
@@ -200,7 +204,7 @@ export const C4ClusterDetailsAlertsTab = (props) => {
|
|
|
200
204
|
})();
|
|
201
205
|
}, children: _jsx(Form, { onSubmit: (e) => {
|
|
202
206
|
e.preventDefault();
|
|
203
|
-
}, children: _jsxs(Stack, { gap: 4, children: [alertMutationError && (_jsx(
|
|
207
|
+
}, children: _jsxs(Stack, { gap: 4, children: [alertMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: safeTranslate(props.t, 'alerts:create.error.generic', "We're having trouble creating the alert"), subtitle: alertMutationError, lowContrast: true, hideCloseButton: true })), _jsxs(RadioButtonGroup, { name: 'alert-create-report-type', legendText: safeTranslate(props.t, 'alerts:create.fields.reportType.label', 'Delivery method'), valueSelected: alertReportType, orientation: 'vertical', onChange: (value) => {
|
|
204
208
|
setAlertReportType(value);
|
|
205
209
|
setAlertUrlInvalid(false);
|
|
206
210
|
setAlertUrlInvalidText('');
|
|
@@ -214,7 +218,7 @@ export const C4ClusterDetailsAlertsTab = (props) => {
|
|
|
214
218
|
setAlertHmacSecret(event.target.value);
|
|
215
219
|
setAlertHmacInvalid(false);
|
|
216
220
|
setAlertHmacInvalidText('');
|
|
217
|
-
} }), _jsx(C4ActionableNotification, { lowContrast: true, kind: 'info', title: '', subtitle: safeTranslate(props.t, 'alerts:create.fields.webhookAuth.infoBannerForHmac.text', 'We will generate the SHA-256 hash of the request body using your HMAC secret and include it in the HTTP header X-Camunda-Signature-256.'), actionButtonLabel: safeTranslate(props.t, 'alerts:create.fields.webhookAuth.infoBannerForHmac.actionButtonLabel', 'Learn more'), onActionButtonClick: () => {
|
|
221
|
+
} }), _jsx(C4ActionableNotification, { appearance: 'banner', lowContrast: true, kind: 'info', title: '', subtitle: safeTranslate(props.t, 'alerts:create.fields.webhookAuth.infoBannerForHmac.text', 'We will generate the SHA-256 hash of the request body using your HMAC secret and include it in the HTTP header X-Camunda-Signature-256.'), actionButtonLabel: safeTranslate(props.t, 'alerts:create.fields.webhookAuth.infoBannerForHmac.actionButtonLabel', 'Learn more'), onActionButtonClick: () => {
|
|
218
222
|
trackEvent('docs:open', 'documentation clicked', {
|
|
219
223
|
from: 'console',
|
|
220
224
|
type: 'clusterdetails-alerts-no-alerts',
|
|
@@ -276,7 +280,7 @@ export const C4ClusterDetailsAlertsTab = (props) => {
|
|
|
276
280
|
})();
|
|
277
281
|
}, children: _jsx(Form, { onSubmit: (e) => {
|
|
278
282
|
e.preventDefault();
|
|
279
|
-
}, children: _jsxs(Stack, { gap: 6, children: [alertMutationError && (_jsx(
|
|
283
|
+
}, children: _jsxs(Stack, { gap: 6, children: [alertMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: safeTranslate(props.t, 'alerts:update.error.generic', "We're having trouble updating the alert"), subtitle: alertMutationError, lowContrast: true, hideCloseButton: true })), _jsxs(RadioButtonGroup, { name: 'alert-update-report-type', legendText: safeTranslate(props.t, 'alerts:update.fields.reportType.label', 'Delivery method'), valueSelected: alertReportType, orientation: 'vertical', onChange: (value) => {
|
|
280
284
|
setAlertReportType(value);
|
|
281
285
|
setAlertUrlInvalid(false);
|
|
282
286
|
setAlertUrlInvalidText('');
|
|
@@ -290,7 +294,7 @@ export const C4ClusterDetailsAlertsTab = (props) => {
|
|
|
290
294
|
setAlertHmacSecret(event.target.value);
|
|
291
295
|
setAlertHmacInvalid(false);
|
|
292
296
|
setAlertHmacInvalidText('');
|
|
293
|
-
} })), _jsx("br", {}), _jsx(C4ActionableNotification, { lowContrast: true, kind: 'info', title: '', subtitle: safeTranslate(props.t, 'alerts:create.fields.webhookAuth.infoBannerForHmac.text', 'We will generate the SHA-256 hash of the request body using your HMAC secret and include it in the HTTP header X-Camunda-Signature-256.'), actionButtonLabel: safeTranslate(props.t, 'alerts:create.fields.webhookAuth.infoBannerForHmac.actionButtonLabel', 'Learn more'), onActionButtonClick: () => {
|
|
297
|
+
} })), _jsx("br", {}), _jsx(C4ActionableNotification, { appearance: 'banner', lowContrast: true, kind: 'info', title: '', subtitle: safeTranslate(props.t, 'alerts:create.fields.webhookAuth.infoBannerForHmac.text', 'We will generate the SHA-256 hash of the request body using your HMAC secret and include it in the HTTP header X-Camunda-Signature-256.'), actionButtonLabel: safeTranslate(props.t, 'alerts:create.fields.webhookAuth.infoBannerForHmac.actionButtonLabel', 'Learn more'), onActionButtonClick: () => {
|
|
294
298
|
trackEvent('docs:open', 'documentation clicked', {
|
|
295
299
|
from: 'console',
|
|
296
300
|
type: 'clusterdetails-alerts-no-alerts',
|
|
@@ -320,5 +324,5 @@ export const C4ClusterDetailsAlertsTab = (props) => {
|
|
|
320
324
|
setAlertMutationBusy(false);
|
|
321
325
|
}
|
|
322
326
|
})();
|
|
323
|
-
}, children: _jsxs(Stack, { gap: 6, children: [alertMutationError && (_jsx(
|
|
327
|
+
}, children: _jsxs(Stack, { gap: 6, children: [alertMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: safeTranslate(props.t, 'alerts:delete.error.generic', "We're having trouble deleting the alert"), subtitle: alertMutationError, lowContrast: true, hideCloseButton: true })), _jsx("p", { children: safeTranslate(props.t, 'alerts:delete.description', 'Are you sure you want to delete the alert') })] }) })] }));
|
|
324
328
|
};
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { ConsoleByomMonitoringService, HttpError } from '@camunda/ccma-api';
|
|
3
|
-
import {
|
|
3
|
+
import { FormLabel, InlineLoading, Layer } from '@carbon/react';
|
|
4
4
|
import { CheckmarkFilled, Information, WarningFilled, } from '@carbon/react/icons/index.esm.js';
|
|
5
5
|
import { useCallback, useEffect, useMemo, useState } from 'react';
|
|
6
6
|
import { C4ClusterByomClients } from '../../../components/c4-cluster-byom-clients/c4-cluster-byom-clients.js';
|
|
7
|
+
import { C4InlineNotification } from '../../../components/c4-inline-notification/c4-inline-notification.js';
|
|
7
8
|
import { useC4ConsoleRuntime } from '../../../runtime/c4-console-runtime-context.js';
|
|
9
|
+
import { Button, CodeSnippet, Modal, Stack, TextInput } from '../../../ui/index.js';
|
|
8
10
|
// Helper function to ensure translations work
|
|
9
11
|
function safeTranslate(t, key, fallback) {
|
|
10
12
|
if (!t)
|
|
@@ -333,7 +335,7 @@ export const C4ClusterDetailsByomClientsTab = (props) => {
|
|
|
333
335
|
})();
|
|
334
336
|
}, children: _jsxs(Stack, { gap: 4, children: [_jsx("p", { children: safeTranslate(t, 'byomClients:create.createDescription', 'Create credentials for authentication in an external monitoring system.') }), byomMutationBusy && (_jsx(InlineLoading, { description: safeTranslate(t, 'byomClients:create.loading', 'Creating credentials…') })), _jsx(TextInput, { id: 'byom-username', name: 'username', labelText: safeTranslate(t, 'byomClients:create.fields.username', 'Username'), placeholder: safeTranslate(t, 'byomClients:create.fields.usernamePlaceholder', 'Enter username'), helperText: safeTranslate(t, 'byomClients:create.fields.usernameHelperText', 'Maximum 24 characters. Only alphanumeric characters, dashes, and underscores allowed.'), value: byomUsername, maxLength: 24, onChange: (event) => setByomUsername(event.target.value) }), _jsxs("div", { style: { display: 'flex', gap: '0.5rem', alignItems: 'center' }, children: [_jsx(Information, { size: 16 }), _jsx("span", { children: safeTranslate(t, 'byomClients:create.passwordGeneratedAfter', 'The password will be generated after creation.') })] }), byomMutationError && (_jsx("p", { style: { color: 'var(--cds-text-error)' }, children: byomMutationError }))] }) }), _jsx(Modal, { open: byomPasswordOpen, modalHeading: byomActivateOnSubmit
|
|
335
337
|
? safeTranslate(t, 'byomClients:create.successTitle', 'Monitoring endpoint activated')
|
|
336
|
-
: safeTranslate(t, 'byomClients:create.successTitle', 'New credentials created'), primaryButtonText: safeTranslate(t, 'byomClients:create.done', 'Got it'), secondaryButtonText: undefined, onRequestClose: () => setByomPasswordOpen(false), onRequestSubmit: () => setByomPasswordOpen(false), children: _jsxs(Stack, { gap: 5, children: [_jsx("p", { children: safeTranslate(t, 'byomClients:create.successDescription', 'Use the credentials below for authentication in an external monitoring system.') }), _jsxs("div", { children: [_jsx(FormLabel, { children: safeTranslate(t, 'byomClients:create.fields.username', 'Username') }), _jsx(CodeSnippet, { type: 'single', children: byomUsername })] }), _jsxs("div", { children: [_jsx(FormLabel, { children: safeTranslate(t, 'byomClients:create.fields.password', 'Password') }), _jsx(CodeSnippet, { type: 'single', children: byomPassword })] }), _jsx(
|
|
338
|
+
: safeTranslate(t, 'byomClients:create.successTitle', 'New credentials created'), primaryButtonText: safeTranslate(t, 'byomClients:create.done', 'Got it'), secondaryButtonText: undefined, onRequestClose: () => setByomPasswordOpen(false), onRequestSubmit: () => setByomPasswordOpen(false), children: _jsxs(Stack, { gap: 5, children: [_jsx("p", { children: safeTranslate(t, 'byomClients:create.successDescription', 'Use the credentials below for authentication in an external monitoring system.') }), _jsxs("div", { children: [_jsx(FormLabel, { children: safeTranslate(t, 'byomClients:create.fields.username', 'Username') }), _jsx(CodeSnippet, { type: 'single', children: byomUsername })] }), _jsxs("div", { children: [_jsx(FormLabel, { children: safeTranslate(t, 'byomClients:create.fields.password', 'Password') }), _jsx(CodeSnippet, { type: 'single', children: byomPassword })] }), _jsx(C4InlineNotification, { kind: 'warning', lowContrast: true, title: safeTranslate(t, 'byomClients:create.successNotificationTitle', 'The credentials will not be shown again.'), subtitle: safeTranslate(t, 'byomClients:create.successNotificationDescription', 'New password can be generated later.') })] }) }), _jsx(Modal, { open: byomRotateOpen, primaryButtonText: byomRotateBusy ? (_jsx(InlineLoading, {})) : (safeTranslate(t, 'byomClients:rotate.submit', 'Generate new password')), secondaryButtonText: safeTranslate(t, 'byomClients:rotate.cancel', 'Cancel'), primaryButtonDisabled: byomRotateBusy, onRequestClose: () => {
|
|
337
339
|
trackEvent('byomClients:rotate:cancel', 'Cancel Rotate BYOM Client Password Modal', { clientId: byomRotateClientId });
|
|
338
340
|
setByomRotateBusy(false);
|
|
339
341
|
setByomRotateOpen(false);
|
|
@@ -370,7 +372,7 @@ export const C4ClusterDetailsByomClientsTab = (props) => {
|
|
|
370
372
|
}, size: 'sm', modalHeading: safeTranslate(t, 'byomClients:rotate.title', 'Generate new password'), children: _jsxs(Stack, { gap: 5, children: [_jsx("p", { children: safeTranslate(t, 'byomClients:rotate.description', `Are you sure you want to rotate the password for the username "${byomClients.find((c) => c.id === byomRotateClientId)?.username ?? ''}"? The current password will be invalidated immediately.`) }), byomRotateError.title && (_jsxs("p", { style: { color: 'var(--cds-text-error)' }, children: [byomRotateError.title, byomRotateError.description
|
|
371
373
|
? `: ${byomRotateError.description}`
|
|
372
374
|
: ''] }))] }) }), _jsx(Modal, { open: byomRotateResponseOpen, primaryButtonText: safeTranslate(t, 'byomClients:rotate.done', 'Got it'), onRequestClose: () => setByomRotateResponseOpen(false), onRequestSubmit: () => setByomRotateResponseOpen(false), size: 'sm', modalHeading: safeTranslate(t, 'byomClients:rotate.successTitle', 'New password generated'), children: _jsxs(Stack, { gap: 5, children: [_jsx("p", { children: safeTranslate(t, 'byomClients:rotate.successDescription', 'Use the credentials below for authentication in an external monitoring system.') }), _jsxs("div", { children: [_jsx(FormLabel, { children: safeTranslate(t, 'byomClients:rotate.fields.username', 'Username') }), _jsx(CodeSnippet, { type: 'single', children: byomClients.find((c) => c.id === byomRotateClientId)?.username ??
|
|
373
|
-
'' })] }), _jsxs("div", { children: [_jsx(FormLabel, { children: safeTranslate(t, 'byomClients:rotate.fields.password', 'New Password') }), _jsx(CodeSnippet, { type: 'single', children: byomRotatePassword })] }), _jsx(
|
|
375
|
+
'' })] }), _jsxs("div", { children: [_jsx(FormLabel, { children: safeTranslate(t, 'byomClients:rotate.fields.password', 'New Password') }), _jsx(CodeSnippet, { type: 'single', children: byomRotatePassword })] }), _jsx(C4InlineNotification, { kind: 'warning', lowContrast: true, title: safeTranslate(t, 'byomClients:create.successNotificationTitle', 'The credentials will not be shown again.'), subtitle: safeTranslate(t, 'byomClients:create.successNotificationDescription', 'New password can be generated later.') })] }) }), _jsx(Modal, { open: byomDeleteOpen, danger: true, primaryButtonText: byomDeleteBusy ? (_jsx(InlineLoading, {})) : (safeTranslate(t, 'byomClients:delete.submit', 'Delete')), secondaryButtonText: safeTranslate(t, 'byomClients:delete.cancel', 'Cancel'), primaryButtonDisabled: byomDeleteBusy, onRequestClose: () => {
|
|
374
376
|
trackEvent('byomClients:delete:cancel', 'Cancel Delete BYOM Client Modal', { clientId: byomSelectedClientId });
|
|
375
377
|
setByomDeleteBusy(false);
|
|
376
378
|
setByomDeleteOpen(false);
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { ConsoleClusterClientsService, ConsoleConnectorSecretsService, } from '@camunda/ccma-api';
|
|
3
3
|
import { checkVersion, SseEntity, VersionCheckOperator, } from '@camunda/ccma-shared-types';
|
|
4
|
-
import {
|
|
4
|
+
import { Form } from '@carbon/react';
|
|
5
5
|
import { useCallback, useMemo, useState } from 'react';
|
|
6
6
|
import { C4ClusterClientCredentialsModal } from '../../../components/c4-cluster-client-credentials/c4-cluster-client-credentials.js';
|
|
7
7
|
import { C4ClusterClientCredentialsIdentityModal } from '../../../components/c4-cluster-client-credentials-identity/c4-cluster-client-credentials-identity.js';
|
|
8
8
|
import { C4ClusterDetailsClients } from '../../../components/c4-cluster-details-clients/c4-cluster-details-clients.js';
|
|
9
|
+
import { C4InlineNotification } from '../../../components/c4-inline-notification/c4-inline-notification.js';
|
|
9
10
|
import { useC4ConsoleRuntime } from '../../../runtime/c4-console-runtime-context.js';
|
|
11
|
+
import { Checkbox, Link, Modal, Stack, TextInput } from '../../../ui/index.js';
|
|
10
12
|
import { toHostWithoutProtocol } from './url-utils.js';
|
|
11
13
|
// Helper function to ensure translations work
|
|
12
14
|
function safeTranslate(t, key, fallback) {
|
|
@@ -278,7 +280,7 @@ export const C4ClusterDetailsClientsTab = (props) => {
|
|
|
278
280
|
}
|
|
279
281
|
})();
|
|
280
282
|
}, children: _jsx(Form, { noValidate: true, children: _jsxs(Stack, { gap: 6, children: [hasIdentityIntegration &&
|
|
281
|
-
Boolean(cluster?.identityBackendChecksEnabled) && (_jsxs(Stack, { gap: 3, children: [_jsx(
|
|
283
|
+
Boolean(cluster?.identityBackendChecksEnabled) && (_jsxs(Stack, { gap: 3, children: [_jsx(C4InlineNotification, { lowContrast: true, kind: 'info', hideCloseButton: true, title: 'Client credential updates for 8.8 clusters', subtitle: "Authorizations for client credentials should be configured directly within the cluster's Admin component, using the client ID as a reference.", style: { maxInlineSize: '100%' } }), _jsx("div", { children: _jsx(Link, { href: identityAuthorizationDocsUrl, onClick: (event) => {
|
|
282
284
|
if (!onNavigate) {
|
|
283
285
|
return;
|
|
284
286
|
}
|
|
@@ -287,7 +289,7 @@ export const C4ClusterDetailsClientsTab = (props) => {
|
|
|
287
289
|
kind: 'openUrl',
|
|
288
290
|
url: identityAuthorizationDocsUrl,
|
|
289
291
|
});
|
|
290
|
-
}, children: "Learn more about authorizations" }) })] })), clientMutationError && (_jsx(
|
|
292
|
+
}, children: "Learn more about authorizations" }) })] })), clientMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: safeTranslate(t, 'clusterclients:create.error.title', 'Error'), subtitle: clientMutationError, hideCloseButton: true, lowContrast: true })), _jsx(TextInput, { id: 'clusterClientName-create', name: 'name', "data-modal-primary-focus": true, labelText: safeTranslate(t, 'clusterclients:create.fields.name.label', 'Client Name'), maxLength: 50, value: clientName, placeholder: safeTranslate(t, 'clusterclients:create.fields.name.label', 'Client Name'), helperText: safeTranslate(t, 'clusterclients:create.fields.name.helperText', 'can contain letters, dashes, underscores, and digits'), invalid: Boolean(clientNameTouched && validateClientName(clientName)), invalidText: (clientNameTouched && validateClientName(clientName)) ?? '', onChange: (event) => {
|
|
291
293
|
setClientName(event.target.value);
|
|
292
294
|
}, onBlur: () => setClientNameTouched(true) }), _jsxs(Stack, { gap: 2, children: [_jsx("h3", { children: safeTranslate(t, 'clusterclients:create.fields.scopes.label', 'Scopes') }), _jsx("p", { children: safeTranslate(t, 'clusterclients:create.fields.scopes.helperText', 'Scopes define the access for client credentials.') }), hasIdentityIntegration && (_jsx("p", { children: safeTranslate(t, 'clusterclients:create.fields.scopes.helperText8_8', 'Granular authorizations for the Orchestration Cluster API can be managed via Orchestration Cluster Identity.') })), _jsx("div", { style: { marginBottom: '8px' }, children: renderInlineLink(safeTranslate(t, 'clusterclients:create.fields.scopes.learnMoreHelperText', 'Read more about <0>Scopes for Client Credentials</0>.'), {
|
|
293
295
|
href: clientsDocsUrl,
|
|
@@ -861,7 +863,7 @@ export const C4ClusterDetailsClientsTab = (props) => {
|
|
|
861
863
|
setClientMutationBusy(false);
|
|
862
864
|
}
|
|
863
865
|
})();
|
|
864
|
-
}, children: _jsxs(Stack, { gap: 4, children: [clientMutationError && (_jsx(
|
|
866
|
+
}, children: _jsxs(Stack, { gap: 4, children: [clientMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: safeTranslate(t, 'clusterclients:update.error.title', 'Error'), subtitle: clientMutationError, hideCloseButton: true, lowContrast: true })), _jsx(TextInput, { id: 'client-update-name', labelText: 'Name', value: clientName, onChange: (event) => setClientName(event.target.value) })] }) }), _jsx(Modal, { open: deleteClientOpen, danger: true, modalHeading: 'Delete API client', primaryButtonText: 'Delete', secondaryButtonText: 'Cancel', primaryButtonDisabled: clientMutationBusy, onRequestClose: () => {
|
|
865
867
|
trackEvent('apiClients:delete:cancel', 'Cancel Delete Api Client Modal');
|
|
866
868
|
setDeleteClientOpen(false);
|
|
867
869
|
}, onRequestSubmit: () => {
|
|
@@ -895,5 +897,5 @@ export const C4ClusterDetailsClientsTab = (props) => {
|
|
|
895
897
|
setClientMutationBusy(false);
|
|
896
898
|
}
|
|
897
899
|
})();
|
|
898
|
-
}, children: _jsxs(Stack, { gap: 4, children: [clientMutationError && (_jsx(
|
|
900
|
+
}, children: _jsxs(Stack, { gap: 4, children: [clientMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: safeTranslate(t, 'clusterclients:delete.error.title', 'Error'), subtitle: clientMutationError, hideCloseButton: true, lowContrast: true })), _jsx("p", { children: "Delete this client?" })] }) })] }));
|
|
899
901
|
};
|
|
@@ -1,11 +1,14 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { ConsoleConnectorSecretsService } from '@camunda/ccma-api';
|
|
3
3
|
import { SECRETS_MAX_LENGTH, SseEntity } from '@camunda/ccma-shared-types';
|
|
4
|
-
import {
|
|
4
|
+
import { FileUploader, Form, InlineLoading, PasswordInput } from '@carbon/react';
|
|
5
5
|
import { useCallback, useEffect, useRef, useState } from 'react';
|
|
6
6
|
import { C4ClusterDetailsConnectorSecrets } from '../../../components/c4-cluster-details-connector-secrets/c4-cluster-details-connector-secrets.js';
|
|
7
|
+
import { C4InlineNotification } from '../../../components/c4-inline-notification/c4-inline-notification.js';
|
|
7
8
|
import { useC4ConsoleData } from '../../../runtime/c4-console-data-context.js';
|
|
8
9
|
import { useC4ConsoleRuntime } from '../../../runtime/c4-console-runtime-context.js';
|
|
10
|
+
import { CodeSnippet, Link, Modal, Stack, TextArea, TextInput, } from '../../../ui/index.js';
|
|
11
|
+
import { useSelectFamily } from '../../../ui/families.js';
|
|
9
12
|
function safeTranslate(t, key, fallback) {
|
|
10
13
|
if (!t)
|
|
11
14
|
return fallback;
|
|
@@ -38,6 +41,7 @@ function renderInlineLink0(value, linkRenderer) {
|
|
|
38
41
|
return (_jsxs("span", { children: [before, linkRenderer(label), after] }));
|
|
39
42
|
}
|
|
40
43
|
export const C4ClusterDetailsConnectorSecretsTab = (props) => {
|
|
44
|
+
const { Select, SelectItem } = useSelectFamily();
|
|
41
45
|
const { orgId, clusterId, apiConfig, canMutateCluster, connectorSecretsPermissions, docsUrl, t, onNavigate, useClusterSecretsLabel, } = props;
|
|
42
46
|
const pickSecretsText = (connectorKey, connectorFallback, clusterKey, clusterFallback) => useClusterSecretsLabel
|
|
43
47
|
? safeTranslate(t, clusterKey, clusterFallback)
|
|
@@ -297,7 +301,7 @@ export const C4ClusterDetailsConnectorSecretsTab = (props) => {
|
|
|
297
301
|
setSecretMutationBusy(false);
|
|
298
302
|
}
|
|
299
303
|
})();
|
|
300
|
-
}, children: _jsxs(Stack, { gap: 6, children: [secretMutationError && (_jsx(
|
|
304
|
+
}, children: _jsxs(Stack, { gap: 6, children: [secretMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: 'Error', subtitle: secretMutationError, hideCloseButton: true, lowContrast: true })), _jsxs(Form, { children: [_jsx(TextInput, { id: 'secret-create-key', labelText: safeTranslate(t, 'connectorsecrets:create.fields.key', 'Key'), helperText: safeTranslate(t, 'connectorsecrets:create.fields.keyHelperText', 'Unique identifier for the secret'), maxLength: 50, value: secretKey, invalid: secretKeyInvalid, invalidText: 'Key is required', onChange: (event) => {
|
|
301
305
|
setSecretKey(event.target.value);
|
|
302
306
|
if (secretKeyInvalid && event.target.value.length > 0) {
|
|
303
307
|
setSecretKeyInvalid(false);
|
|
@@ -344,7 +348,7 @@ export const C4ClusterDetailsConnectorSecretsTab = (props) => {
|
|
|
344
348
|
setSecretMutationBusy(false);
|
|
345
349
|
}
|
|
346
350
|
})();
|
|
347
|
-
}, children: _jsxs(Stack, { gap: 6, children: [secretMutationError && (_jsx(
|
|
351
|
+
}, children: _jsxs(Stack, { gap: 6, children: [secretMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: 'Error', subtitle: secretMutationError, hideCloseButton: true, lowContrast: true })), _jsx(Form, { children: _jsx(PasswordInput, { id: 'secret-update-value', labelText: safeTranslate(t, 'connectorsecrets:update.fields.value', 'Value'), maxLength: SECRETS_MAX_LENGTH, value: secretValue, onChange: (event) => setSecretValue(event.target.value) }) })] }) }), _jsx(Modal, { open: secretDeleteOpen, danger: true, modalHeading: `${safeTranslate(t, 'connectorsecrets:delete.heading', 'Delete connector secret')}: ${secretKey}`, primaryButtonText: safeTranslate(t, 'connectorsecrets:delete.buttons.primary', 'Delete'), secondaryButtonText: safeTranslate(t, 'connectorsecrets:delete.buttons.secondary', 'Cancel'), primaryButtonDisabled: secretMutationBusy, onRequestClose: () => {
|
|
348
352
|
trackEvent('listConnectors:delete:cancel', 'Close Delete Connector Secret Modal', {
|
|
349
353
|
key: secretKey,
|
|
350
354
|
});
|
|
@@ -382,7 +386,7 @@ export const C4ClusterDetailsConnectorSecretsTab = (props) => {
|
|
|
382
386
|
setSecretMutationBusy(false);
|
|
383
387
|
}
|
|
384
388
|
})();
|
|
385
|
-
}, children: _jsxs(Stack, { gap: 6, children: [secretMutationError && (_jsx(
|
|
389
|
+
}, children: _jsxs(Stack, { gap: 6, children: [secretMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: 'Error', subtitle: secretMutationError, hideCloseButton: true, lowContrast: true })), _jsx("p", { children: safeTranslate(t, 'connectorsecrets:delete.description', 'Are you sure you want to delete this secret?') })] }) }), _jsx(Modal, { open: secretRevealOpen, modalLabel: safeTranslate(t, 'connectorsecrets:reveal.heading', 'Secret value'), modalHeading: secretKey, primaryButtonText: safeTranslate(t, 'close', 'Close'), secondaryButtonText: '', onRequestClose: () => {
|
|
386
390
|
trackEvent('listConnectors:reveal:close', 'Close Reveal Connector Secret Modal', {
|
|
387
391
|
key: secretKey,
|
|
388
392
|
});
|
|
@@ -477,7 +481,7 @@ export const C4ClusterDetailsConnectorSecretsTab = (props) => {
|
|
|
477
481
|
setBulkImportBusy(false);
|
|
478
482
|
}
|
|
479
483
|
})();
|
|
480
|
-
}, size: 'md', children: _jsxs(Stack, { gap: 6, children: [bulkImportError && (_jsx(
|
|
484
|
+
}, size: 'md', children: _jsxs(Stack, { gap: 6, children: [bulkImportError && (_jsx(C4InlineNotification, { kind: 'error', title: 'Error', subtitle: bulkImportError, hideCloseButton: true, lowContrast: true })), _jsx(FileUploader, { labelTitle: safeTranslate(t, 'connectorsecrets:bulkImport.fields.fileUploadLabel', 'Upload file'), labelDescription: safeTranslate(t, 'connectorsecrets:bulkImport.fields.fileUploadDescription', 'Select a .env or .txt file'), buttonLabel: safeTranslate(t, 'connectorsecrets:bulkImport.fields.fileUploadButton', 'Select file'), buttonKind: 'tertiary', size: 'md', filenameStatus: 'edit', accept: ['.env', '.txt'], multiple: false, iconDescription: 'Remove file', onChange: async (event) => {
|
|
481
485
|
const files = event.target.files;
|
|
482
486
|
if (files && files.length > 0) {
|
|
483
487
|
try {
|
|
@@ -557,7 +561,7 @@ export const C4ClusterDetailsConnectorSecretsTab = (props) => {
|
|
|
557
561
|
setImportFromClusterBusy(false);
|
|
558
562
|
}
|
|
559
563
|
})();
|
|
560
|
-
}, size: 'md', children: _jsxs(Stack, { gap: 6, children: [importFromClusterError && (_jsx(
|
|
564
|
+
}, size: 'md', children: _jsxs(Stack, { gap: 6, children: [importFromClusterError && (_jsx(C4InlineNotification, { kind: 'error', title: 'Error', subtitle: importFromClusterError, hideCloseButton: true, lowContrast: true })), availableClusters.length === 0 ? (_jsx("p", { children: safeTranslate(t, 'connectorsecrets:importFromCluster.noClusters', 'No other clusters available to import from') })) : (_jsxs(Form, { children: [_jsxs(Select, { id: 'source-cluster-select', labelText: safeTranslate(t, 'connectorsecrets:importFromCluster.fields.sourceCluster', 'Source cluster'), helperText: safeTranslate(t, 'connectorsecrets:importFromCluster.fields.sourceClusterHelperText', 'Select a cluster to import secrets from'), value: selectedSourceClusterId, invalid: sourceClusterInvalid, invalidText: 'Please select a cluster', onChange: async (event) => {
|
|
561
565
|
const clusterId = event.target.value;
|
|
562
566
|
setSelectedSourceClusterId(clusterId);
|
|
563
567
|
setSourceClusterInvalid(false);
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
2
|
import { ConsoleBackupScheduleService, ConsoleHotBackupsService, } from '@camunda/ccma-api';
|
|
3
3
|
import { BackupStatus, checkVersion, HOTBACKUP_MIN_CREATE_PERIOD, SseEntity, VersionCheckOperator, } from '@camunda/ccma-shared-types';
|
|
4
|
-
import { Checkbox, Modal, Select, SelectItem, Stack, TextInput, } from '@carbon/react';
|
|
5
4
|
import { CronExpression, CronExpressionParser, CronFieldCollection, } from 'cron-parser';
|
|
6
5
|
import { useCallback, useEffect, useRef, useState } from 'react';
|
|
7
6
|
import { C4ClusterDetailsHotBackups } from '../../../components/c4-cluster-details-hot-backups/c4-cluster-details-hot-backups.js';
|
|
@@ -9,6 +8,8 @@ import { C4ClusterDetailsHotBackupsRestore } from '../../../components/c4-cluste
|
|
|
9
8
|
import { useC4ConsoleData } from '../../../runtime/c4-console-data-context.js';
|
|
10
9
|
import { useC4ConsoleNotifications } from '../../../runtime/c4-console-notifications-context.js';
|
|
11
10
|
import { useC4ConsoleRuntime } from '../../../runtime/c4-console-runtime-context.js';
|
|
11
|
+
import { Checkbox, Modal, Stack, TextInput } from '../../../ui/index.js';
|
|
12
|
+
import { useSelectFamily } from '../../../ui/families.js';
|
|
12
13
|
const WEEKDAYS = [
|
|
13
14
|
'Monday',
|
|
14
15
|
'Tuesday',
|
|
@@ -95,6 +96,7 @@ function safeTranslate(t, key, fallback) {
|
|
|
95
96
|
return result === key ? fallback : result;
|
|
96
97
|
}
|
|
97
98
|
export const C4ClusterDetailsHotBackupsTab = (props) => {
|
|
99
|
+
const { Select, SelectItem } = useSelectFamily();
|
|
98
100
|
const { cluster, orgId, clusterId, apiConfig, canMutateCluster, isHotBackupEnabled, docsUrls, t, onNavigate, onReloadCluster, } = props;
|
|
99
101
|
const data = useC4ConsoleData();
|
|
100
102
|
const runtime = useC4ConsoleRuntime();
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { ConsoleIpWhitelistService, ConsoleSecureConnectivityService, } from '@camunda/ccma-api';
|
|
3
|
-
import { Form
|
|
3
|
+
import { Form } from '@carbon/react';
|
|
4
4
|
import { useCallback, useEffect, useState } from 'react';
|
|
5
5
|
import { C4ClusterDetailsIpWhitelist } from '../../../components/c4-cluster-details-ip-whitelist/c4-cluster-details-ip-whitelist.js';
|
|
6
|
+
import { C4InlineNotification } from '../../../components/c4-inline-notification/c4-inline-notification.js';
|
|
6
7
|
import { useC4ConsoleRuntime } from '../../../runtime/c4-console-runtime-context.js';
|
|
8
|
+
import { Modal, Stack, TextInput } from '../../../ui/index.js';
|
|
7
9
|
// Helper function to ensure translations work
|
|
8
10
|
function safeTranslate(t, key, fallback) {
|
|
9
11
|
if (!t)
|
|
@@ -152,7 +154,7 @@ export const C4ClusterDetailsIpWhitelistTab = (props) => {
|
|
|
152
154
|
...meta,
|
|
153
155
|
});
|
|
154
156
|
}, [clusterId, orgId, runtime.telemetry]);
|
|
155
|
-
return (_jsxs(_Fragment, { children: [showPrivateLinkConflictWarning && (_jsx(
|
|
157
|
+
return (_jsxs(_Fragment, { children: [showPrivateLinkConflictWarning && (_jsx(C4InlineNotification, { kind: 'warning', lowContrast: true, hideCloseButton: true, title: privateLinkConflictTitle, subtitle: privateLinkConflictSubtitle, style: {
|
|
156
158
|
maxWidth: '100%',
|
|
157
159
|
width: '100%',
|
|
158
160
|
marginBottom: 'var(--cds-spacing-05)',
|
|
@@ -234,7 +236,7 @@ export const C4ClusterDetailsIpWhitelistTab = (props) => {
|
|
|
234
236
|
})();
|
|
235
237
|
}, children: _jsx(Form, { onSubmit: (e) => {
|
|
236
238
|
e.preventDefault();
|
|
237
|
-
}, children: _jsxs(Stack, { gap: 6, children: [ipMutationError && (_jsx(
|
|
239
|
+
}, children: _jsxs(Stack, { gap: 6, children: [ipMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: safeTranslate(t, 'ipwhitelist:create.error.generic', "We're having trouble adding the IP(s)"), subtitle: ipMutationError, lowContrast: true, hideCloseButton: true })), _jsx(TextInput, { id: 'ip-input-whitelist-create', labelText: safeTranslate(t, 'ipwhitelist:create.fields.ips', 'IP(s)'), helperText: safeTranslate(t, 'ipwhitelist:create.fields.ipsHelper', 'Comma separated list of CIDRs, e.g. 10.0.0.0/24,172.10.0.1'), value: ipValue, maxLength: 50, onChange: (event) => setIpValue(event.target.value) }), _jsx(TextInput, { id: 'name-input-whitelist-create', labelText: safeTranslate(t, 'ipwhitelist:create.fields.description', 'Description (optional)'), value: ipDescription, maxLength: 1024, onChange: (event) => setIpDescription(event.target.value) })] }) }) }), _jsx(Modal, { open: updateIpOpen, modalHeading: `${safeTranslate(t, 'ipwhitelist:update.heading', 'Update IP(s)')}: ${ipWhitelistItems[selectedIpIndex]?.ip ?? ''}`, primaryButtonText: safeTranslate(t, 'ipwhitelist:update.buttons.primary', 'Update'), secondaryButtonText: safeTranslate(t, 'ipwhitelist:update.buttons.secondary', 'Cancel'), primaryButtonDisabled: ipMutationBusy || ipValue.length === 0, onRequestClose: () => {
|
|
238
240
|
trackEvent('clusterOverviewIpWhitelists:updateModal:cancel', 'Close Update IP Whitelist Modal', { ipIndex: selectedIpIndex });
|
|
239
241
|
setUpdateIpOpen(false);
|
|
240
242
|
}, onRequestSubmit: () => {
|
|
@@ -259,7 +261,7 @@ export const C4ClusterDetailsIpWhitelistTab = (props) => {
|
|
|
259
261
|
})();
|
|
260
262
|
}, children: _jsx(Form, { onSubmit: (e) => {
|
|
261
263
|
e.preventDefault();
|
|
262
|
-
}, children: _jsxs(Stack, { gap: 6, children: [ipMutationError && (_jsx(
|
|
264
|
+
}, children: _jsxs(Stack, { gap: 6, children: [ipMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: safeTranslate(t, 'ipwhitelist:update.error.generic', "We're having trouble updating the IP(s)"), subtitle: ipMutationError, lowContrast: true, hideCloseButton: true })), _jsx(TextInput, { id: 'ip-input-whitelist-update', labelText: safeTranslate(t, 'ipwhitelist:create.fields.ips', 'IP(s)'), helperText: safeTranslate(t, 'ipwhitelist:create.fields.ipsHelper', 'Comma separated list of CIDRs, e.g. 10.0.0.0/24,172.10.0.1'), value: ipValue, maxLength: 50, onChange: (event) => setIpValue(event.target.value) }), _jsx(TextInput, { id: 'name-input-whitelist-update', labelText: safeTranslate(t, 'ipwhitelist:create.fields.description', 'Description (optional)'), value: ipDescription, maxLength: 1024, onChange: (event) => setIpDescription(event.target.value) })] }) }) }), _jsx(Modal, { open: deleteIpOpen, danger: true, modalHeading: `${safeTranslate(t, 'ipwhitelist:delete.heading', 'Delete IP(s)')}: ${ipWhitelistItems[selectedIpIndex]?.ip ?? ''}`, primaryButtonText: safeTranslate(t, 'ipwhitelist:delete.buttons.primary', 'Delete'), secondaryButtonText: safeTranslate(t, 'ipwhitelist:delete.buttons.secondary', 'Cancel'), primaryButtonDisabled: ipMutationBusy, onRequestClose: () => {
|
|
263
265
|
trackEvent('clusterOverviewIpWhitelists:deleteModal:cancel', 'Close Delete IP Whitelist Modal', { ipIndex: selectedIpIndex });
|
|
264
266
|
setDeleteIpOpen(false);
|
|
265
267
|
}, onRequestSubmit: () => {
|
|
@@ -280,5 +282,5 @@ export const C4ClusterDetailsIpWhitelistTab = (props) => {
|
|
|
280
282
|
setIpMutationBusy(false);
|
|
281
283
|
}
|
|
282
284
|
})();
|
|
283
|
-
}, children: _jsxs(Stack, { gap: 6, children: [ipMutationError && (_jsx(
|
|
285
|
+
}, children: _jsxs(Stack, { gap: 6, children: [ipMutationError && (_jsx(C4InlineNotification, { kind: 'error', title: safeTranslate(t, 'ipwhitelist:delete.error.generic', "We're having trouble deleting the IP(s)"), subtitle: ipMutationError, lowContrast: true, hideCloseButton: true })), _jsx("p", { children: safeTranslate(t, 'ipwhitelist:delete.description', 'Are you sure you want to the delete these allowlisted IP(s)?') })] }) })] }));
|
|
284
286
|
};
|
|
@@ -7,17 +7,20 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
7
7
|
import { C3ClusterTag, useC3Profile, } from '@camunda/camunda-composite-components';
|
|
8
8
|
import { SaaSJobsService, } from '@camunda/ccma-api';
|
|
9
9
|
import { ClusterPlanTypeAvailabilityClass, ClusterPlanTypeCategory, checkVersion, MAX_HARDWARE_PACKAGE_COUNT, sortGenerationBySemverOfZeebe, VersionCheckOperator, } from '@camunda/ccma-shared-types';
|
|
10
|
-
import { Checkbox, InlineNotification, Link, Modal, RadioButton, RadioButtonGroup, Stack, Tag, } from '@carbon/react';
|
|
11
10
|
import { Api_1, ApiKey, CheckmarkFilled, Renew, Security, UserAccessLocked, } from '@carbon/react/icons/index.esm.js';
|
|
12
|
-
import { Fragment, useCallback, useEffect, useMemo, useState, } from 'react';
|
|
11
|
+
import { Fragment, useCallback, useEffect, useMemo, useRef, useState, } from 'react';
|
|
13
12
|
import { normalizeClusterStatus } from '../../../components/c4-cluster-overview/applications.js';
|
|
14
13
|
import { C4ClusterOverview } from '../../../components/c4-cluster-overview/c4-cluster-overview.js';
|
|
15
14
|
import { C4Divider } from '../../../components/c4-divider/c4-divider.js';
|
|
15
|
+
import { C4InlineNotification } from '../../../components/c4-inline-notification/c4-inline-notification.js';
|
|
16
16
|
import { C4MultiStepUglyModal } from '../../../components/c4-multi-step-modal-ugly/c4-multi-step-modal-ugly.js';
|
|
17
17
|
import { C4OptimizeActivationModal } from '../../../components/c4-optimize-activation-modal/c4-optimize-activation-modal.js';
|
|
18
|
+
import { addC4ConsoleNotification } from '../../../notifications/c4-console-notifications-handle.js';
|
|
18
19
|
import { buildClusterSwaggerUrl } from '../../../runtime/build-cluster-swagger-url.js';
|
|
19
20
|
import { useC4ConsoleData } from '../../../runtime/c4-console-data-context.js';
|
|
20
21
|
import { useC4ConsoleRuntime } from '../../../runtime/c4-console-runtime-context.js';
|
|
22
|
+
import { Checkbox, Link, Modal, Stack, Tag } from '../../../ui/index.js';
|
|
23
|
+
import { useRadioFamily } from '../../../ui/families.js';
|
|
21
24
|
import { isClusterReconciliationPaused } from '../../is-cluster-reconciliation-paused.js';
|
|
22
25
|
// Helper function to ensure translations work
|
|
23
26
|
function safeTranslate(t, key, fallback, options) {
|
|
@@ -46,8 +49,10 @@ function isUuidLike(value) {
|
|
|
46
49
|
return /^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(value);
|
|
47
50
|
}
|
|
48
51
|
export const C4ClusterDetailsOverviewTab = (props) => {
|
|
52
|
+
const { RadioButton, RadioButtonGroup } = useRadioFamily();
|
|
49
53
|
const c3Profile = useC3Profile();
|
|
50
54
|
const runtime = useC4ConsoleRuntime();
|
|
55
|
+
const wakeInFlight = useRef(false);
|
|
51
56
|
const { cluster, clusterError, creationParameters, clustersOfOrg, clusterPlanTypeReservations, clusterLoadLatest, clusterLoadPerDay, clusterLoad24h, clusterLoadLoading, canSeeClusterLoad, canEditCluster, canWakeCluster, canSleepCluster, canManageUsers, canViewConnectorsLink, hasIdentityIntegration, orgId, clusterId, jobDashboardEnabled, upgradeDocsUrls, statisticsConfig, apiConfig, t, onReloadCluster, onReloadClusterLoad, onNavigate, ignoreGracePeriod, clusterLoadDocsUrl, restoreInProgress, } = props;
|
|
52
57
|
const data = useC4ConsoleData();
|
|
53
58
|
const [tagModalOpen, setTagModalOpen] = useState(false);
|
|
@@ -367,7 +372,7 @@ export const C4ClusterDetailsOverviewTab = (props) => {
|
|
|
367
372
|
steps.push({
|
|
368
373
|
title: `Update available for Cluster ${cluster?.name ?? ''}.`,
|
|
369
374
|
label,
|
|
370
|
-
content: (_jsxs(Stack, { gap: 6, children: [_jsx(
|
|
375
|
+
content: (_jsxs(Stack, { gap: 6, children: [_jsx(C4InlineNotification, { lowContrast: true, kind: 'info', title: safeTranslate(t, 'clustermodals:upgrade.banner.tasklistV2Title', 'Tasklist v2 Upgrade'), hideCloseButton: true, children: _jsxs(Stack, { gap: 5, children: [_jsx("div", { style: { paddingTop: '4px' }, children: renderStrongTextTranslation(t, 'clustermodals:upgrade.banner.tasklistV2Line0', 'The Tasklist component currently uses the <0>deprecated</0> v1 API. We recommend upgrading to Tasklist v2, which integrates with the Orchestration Cluster API, uses the recommended Camunda user task implementation type, and offers improved performance.', { state: 'deprecated' }) }), _jsx("div", { children: renderStrongTextTranslation(t, 'clustermodals:upgrade.banner.tasklistV2Line1', "Before migrating to Tasklist v2, ensure that you're <0>not relying on</0> job worker-based user tasks, draft variables, or public start forms, as these features are only available in v1.", { support: 'not relying on' }) }), _jsx("div", { children: safeTranslate(t, 'clustermodals:upgrade.banner.tasklistV2Line2', 'After upgrading to v2, downgrading back to v1 will not be possible.') }), _jsx("div", { children: _jsx(Link, { rel: 'ignore', style: { cursor: 'pointer' }, onClick: () => {
|
|
371
376
|
window.open(upgradeDocsUrls?.tasklistApiVersions, '_blank', 'noopener,noreferrer');
|
|
372
377
|
}, children: safeTranslate(t, 'clustermodals:upgrade.banner.tasklistV2LearnMore', 'Learn more about upgrading from Tasklist v1 to v2') }) })] }) }), _jsxs(RadioButtonGroup, { name: 'upgrade-tasklist-mode', legendText: safeTranslate(t, 'clustermodals:upgrade.tasklistV2.legend', 'Select Tasklist version'), valueSelected: tasklistMode, orientation: 'vertical', onChange: (value) => {
|
|
373
378
|
setTasklistMode(value === 'v1' ? 'v1' : 'v2');
|
|
@@ -467,9 +472,9 @@ export const C4ClusterDetailsOverviewTab = (props) => {
|
|
|
467
472
|
? identityWizardTitle
|
|
468
473
|
: safeTranslate(t, 'clustermodals:upgrade.title', 'Update available'),
|
|
469
474
|
label,
|
|
470
|
-
content: (_jsxs(Stack, { gap: 6, children: [_jsxs("p", { style: { margin: 0 }, children: ["Update cluster generation from", ' ', _jsx("strong", { children: cluster?.generation?.name ?? '-' }), " to", ' ', _jsx("strong", { children: selectedUpgradeGeneration?.name ?? '-' })] }), showTasklistV1RemovalWarning ? (_jsxs(
|
|
475
|
+
content: (_jsxs(Stack, { gap: 6, children: [_jsxs("p", { style: { margin: 0 }, children: ["Update cluster generation from", ' ', _jsx("strong", { children: cluster?.generation?.name ?? '-' }), " to", ' ', _jsx("strong", { children: selectedUpgradeGeneration?.name ?? '-' })] }), showTasklistV1RemovalWarning ? (_jsxs(C4InlineNotification, { kind: 'warning', lowContrast: true, hideCloseButton: true, title: safeTranslate(t, 'clustermodals:upgrade.banner.tasklistV1RemovalTitle', 'Update removes Tasklist V1'), children: [_jsx("p", { style: { margin: '0.5rem 0 0 0' }, children: safeTranslate(t, 'clustermodals:upgrade.banner.tasklistV1RemovalBody', 'The 8.10 update removes the Tasklist V1 API. Applications on this cluster still using Tasklist V1 will break. Migrate to Tasklist V2 / Orchestration Cluster API before continuing.') }), upgradeDocsUrls?.tasklistApiVersions ? (_jsx("div", { style: { marginTop: '0.5rem' }, children: _jsx(Link, { rel: 'ignore', style: { cursor: 'pointer' }, onClick: () => {
|
|
471
476
|
window.open(upgradeDocsUrls.tasklistApiVersions, '_blank', 'noopener,noreferrer');
|
|
472
|
-
}, children: safeTranslate(t, 'clustermodals:upgrade.banner.tasklistV1RemovalLearnMore', 'Migration guide') }) })) : null] })) : null, _jsx(
|
|
477
|
+
}, children: safeTranslate(t, 'clustermodals:upgrade.banner.tasklistV1RemovalLearnMore', 'Migration guide') }) })) : null] })) : null, _jsx(C4InlineNotification, { kind: 'warning', lowContrast: true, title: safeTranslate(t, 'clustermodals:upgrade.banner.title', 'Camunda components will be temporarily unavailable'), hideCloseButton: true, subtitle: safeTranslate(t, 'clustermodals:upgrade.banner.line0', 'We recommend to backup the cluster before every update to ensure safe recovery if needed.'), children: _jsx("p", { style: { margin: '0.5rem 0 0 0' }, children: safeTranslate(t, 'clustermodals:upgrade.banner.line1', 'During the update, Camunda components will restart. The update duration depends mainly on the amount of processes and data stored in the cluster.') }) }), deltas.length > 0 ? (_jsxs("div", { children: [_jsx("p", { style: { margin: 0 }, children: safeTranslate(t, 'clustermodals:upgrade.details', 'This update includes:') }), _jsx("ul", { children: deltas.map((item) => (_jsx("li", { children: item }, item))) })] })) : null, canEditCluster ? (_jsx(Checkbox, { id: 'upgrade-cluster-enable-auto-update', labelText: safeTranslate(t, 'clustermodals:upgrade.autoUpdate', 'Automatically keep my cluster up to date'), checked: autoUpdateState, onChange: () => {
|
|
473
478
|
setAutoUpdateState((prev) => !prev);
|
|
474
479
|
} })) : null] })),
|
|
475
480
|
buttons: baseButtons({
|
|
@@ -1128,6 +1133,14 @@ export const C4ClusterDetailsOverviewTab = (props) => {
|
|
|
1128
1133
|
const launchLabel = safeTranslate(t, 'clusterdetails:overview.applications.launchLink', 'Launch');
|
|
1129
1134
|
const manageLabel = safeTranslate(t, 'clusterdetails:overview.applications.manageLink', 'Manage');
|
|
1130
1135
|
const connectorsManagementUrl = `/org/${orgId}/cluster/${clusterId}/connectors/management`;
|
|
1136
|
+
// Internal connectors-management page is only available for Zeebe 8.7+.
|
|
1137
|
+
const supportsConnectorsManagementLink = checkVersion({
|
|
1138
|
+
possiblyVersionOrDockerPath: cluster.generation?.versions?.zeebe,
|
|
1139
|
+
trueForSnapshot: true,
|
|
1140
|
+
trueOnInvalidVersion: false,
|
|
1141
|
+
versionToCompareTo: '8.7.0-alpha1',
|
|
1142
|
+
operator: VersionCheckOperator.GreaterThanOrEqual,
|
|
1143
|
+
});
|
|
1131
1144
|
const supportsInternalConnectorsManagement = checkVersion({
|
|
1132
1145
|
// Legacy (console-frontend) shows "Manage" for Connectors on Zeebe 8.8+.
|
|
1133
1146
|
possiblyVersionOrDockerPath: cluster.generation?.versions?.zeebe,
|
|
@@ -1204,16 +1217,13 @@ export const C4ClusterDetailsOverviewTab = (props) => {
|
|
|
1204
1217
|
? toAppTileProps({
|
|
1205
1218
|
name: 'Connectors',
|
|
1206
1219
|
status: cluster.status?.connectorsStatus,
|
|
1207
|
-
url:
|
|
1208
|
-
? connectorsManagementUrl
|
|
1209
|
-
: cluster.status?.connectorsUrl,
|
|
1220
|
+
url: connectorsManagementUrl,
|
|
1210
1221
|
version: toDisplayVersion(cluster.generation?.versions?.connectorBridge ??
|
|
1211
1222
|
cluster.generation?.versions?.zeebe),
|
|
1212
1223
|
description: appDescription.connectors,
|
|
1213
|
-
linkLabel:
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
linkVisible: canViewConnectorsLink,
|
|
1224
|
+
linkLabel: manageLabel,
|
|
1225
|
+
linkVisible: supportsConnectorsManagementLink &&
|
|
1226
|
+
(supportsInternalConnectorsManagement || canViewConnectorsLink),
|
|
1217
1227
|
})
|
|
1218
1228
|
: undefined,
|
|
1219
1229
|
identity: toAppTileProps({
|
|
@@ -1413,12 +1423,35 @@ export const C4ClusterDetailsOverviewTab = (props) => {
|
|
|
1413
1423
|
}
|
|
1414
1424
|
: undefined,
|
|
1415
1425
|
wakeAction: async () => {
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1426
|
+
if (wakeInFlight.current)
|
|
1427
|
+
return;
|
|
1428
|
+
wakeInFlight.current = true;
|
|
1429
|
+
try {
|
|
1430
|
+
const { ConsoleClusterService } = await import('@camunda/ccma-api');
|
|
1431
|
+
await ConsoleClusterService.wakeCluster({
|
|
1432
|
+
config: apiConfig,
|
|
1433
|
+
params: { orgId, clusterId },
|
|
1434
|
+
});
|
|
1435
|
+
await onReloadCluster();
|
|
1436
|
+
}
|
|
1437
|
+
catch (error) {
|
|
1438
|
+
runtime.telemetry?.captureException?.(error, {
|
|
1439
|
+
widget: 'C4ClusterDetailsOverviewTab',
|
|
1440
|
+
action: 'wake',
|
|
1441
|
+
orgId,
|
|
1442
|
+
clusterId,
|
|
1443
|
+
});
|
|
1444
|
+
addC4ConsoleNotification({
|
|
1445
|
+
kind: 'error',
|
|
1446
|
+
title: safeTranslate(t, 'clusterdetails:overview.clusterDetails.status.wakeError.title', 'Failed to resume cluster'),
|
|
1447
|
+
subtitle: error instanceof Error
|
|
1448
|
+
? error.message
|
|
1449
|
+
: safeTranslate(t, 'clusterdetails:overview.clusterDetails.status.wakeError.unknownError', 'Unknown error'),
|
|
1450
|
+
});
|
|
1451
|
+
}
|
|
1452
|
+
finally {
|
|
1453
|
+
wakeInFlight.current = false;
|
|
1454
|
+
}
|
|
1422
1455
|
},
|
|
1423
1456
|
wakeLabel: safeTranslate(t, 'clusterdetails:overview.clusterDetails.status.wakeLabel', 'Resume cluster'),
|
|
1424
1457
|
wakeVisibility: canWakeCluster && !isClusterPausedReconciliation && !restoreInProgress,
|
|
@@ -1475,20 +1508,20 @@ export const C4ClusterDetailsOverviewTab = (props) => {
|
|
|
1475
1508
|
if (hardwareBusy)
|
|
1476
1509
|
return;
|
|
1477
1510
|
setHardwareModalOpen(false);
|
|
1478
|
-
}, onRequestSubmit: submitHardwarePackageChange, size: 'sm', children: _jsxs(Stack, { gap: 5, children: [hardwareError ? (_jsx(
|
|
1511
|
+
}, onRequestSubmit: submitHardwarePackageChange, size: 'sm', children: _jsxs(Stack, { gap: 5, children: [hardwareError ? (_jsx(C4InlineNotification, { kind: 'error', lowContrast: true, title: safeTranslate(t, 'clusterdetails:overview.hardwarePackageModal.error.title', 'Error updating cluster size'), subtitle: hardwareError, hideCloseButton: true })) : null, _jsx("p", { children: safeTranslate(t, 'clusterdetails:overview.hardwarePackageModal.description', 'Increase the cluster size to enhance performance and capacity. Each size increase uses an additional reservation slot.') }), _jsxs("div", { children: [_jsx("p", { className: 'cds--label', style: { marginBottom: '0.75rem' }, children: safeTranslate(t, 'clusterdetails:overview.clusterDetails.hardwarePackages', 'Number of allocated Hardware Packages') }), _jsx("div", { style: { display: 'flex', gap: '0.75rem', flexWrap: 'wrap' }, children: Array.from({ length: MAX_HARDWARE_PACKAGE_COUNT }, (_unused, index) => index + 1).map((value) => (_jsxs(Tag, { id: `allocatedHardwarePackages-${value}`, onClick: () => {
|
|
1479
1512
|
setSelectedHardwarePackages(value);
|
|
1480
1513
|
}, type: selectedHardwarePackages === value
|
|
1481
1514
|
? 'high-contrast'
|
|
1482
1515
|
: 'outline', style: { borderWidth: '0px' }, disabled: hardwareBusy ||
|
|
1483
1516
|
value > availableHardwarePackages ||
|
|
1484
|
-
!!restoreInProgress, children: [value, "x"] }, `allocatedHardwarePackages-${value}`))) })] }), !hardwareReservationsAvailable ? (_jsx(
|
|
1517
|
+
!!restoreInProgress, children: [value, "x"] }, `allocatedHardwarePackages-${value}`))) })] }), !hardwareReservationsAvailable ? (_jsx(C4InlineNotification, { kind: 'info', lowContrast: true, title: safeTranslate(t, 'clusterdetails:overview.hardwarePackageModal.unavailable.title', 'Reservation data unavailable'), subtitle: safeTranslate(t, 'clusterdetails:overview.hardwarePackageModal.unavailable.subtitle', 'Larger sizes will be available once reservation data has loaded. You can keep the current size or choose a smaller size for now.'), hideCloseButton: true })) : availableHardwarePackages < MAX_HARDWARE_PACKAGE_COUNT ? (_jsx(C4InlineNotification, { kind: 'info', lowContrast: true, title: safeTranslate(t, 'clusterdetails:overview.hardwarePackageModal.info.title', 'Limited reservations'), subtitle: safeTranslate(t, 'clusterdetails:overview.hardwarePackageModal.info.subtitle', 'Increase your reservations to unlock more sizes.'), hideCloseButton: true })) : null] }) }), _jsx(Modal, { open: tagModalOpen, modalHeading: safeTranslate(t, 'clusterdetails:tags.modal.heading', 'Assign a cluster tag'), primaryButtonText: safeTranslate(t, 'clusterdetails:tags.modal.primary', 'Confirm'), secondaryButtonText: safeTranslate(t, 'clusterdetails:tags.modal.secondary', 'Cancel'), primaryButtonDisabled: tagBusy ||
|
|
1485
1518
|
selectedTag === '' ||
|
|
1486
1519
|
!canEditCluster ||
|
|
1487
1520
|
!!restoreInProgress, onRequestClose: () => {
|
|
1488
1521
|
if (tagBusy)
|
|
1489
1522
|
return;
|
|
1490
1523
|
setTagModalOpen(false);
|
|
1491
|
-
}, onRequestSubmit: submitTagChange, children: _jsxs(Stack, { gap: 5, children: [tagError ? (_jsx(
|
|
1524
|
+
}, onRequestSubmit: submitTagChange, children: _jsxs(Stack, { gap: 5, children: [tagError ? (_jsx(C4InlineNotification, { kind: 'error', lowContrast: true, title: safeTranslate(t, 'clusterdetails:tags.modal.error', 'Error updating tag'), subtitle: tagError, hideCloseButton: true })) : null, _jsx("p", { children: safeTranslate(t, 'clusterdetails:tags.modal.description', 'Assign a tag to make it easier for team members to clearly distinguish between different stages of the software development lifecycle. Tags have no impact on performance and can be changed later.') }), _jsx("div", { style: {
|
|
1492
1525
|
display: 'grid',
|
|
1493
1526
|
gridTemplateColumns: 'repeat(2, minmax(0, 1fr))',
|
|
1494
1527
|
gap: '1rem',
|