@camunda/ccma-saas-frontend 0.4.0 → 0.5.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/README.md +24 -1
- package/lib/esm/components/c4-activity-graph/c4-activity-graph.d.ts +1 -1
- package/lib/esm/components/c4-advanced-search-filters/ArrayFieldContainer.d.ts +2 -2
- package/lib/esm/components/c4-advanced-search-filters/FieldRow.d.ts +2 -2
- package/lib/esm/components/c4-advanced-search-filters/FiltersSection.d.ts +2 -2
- package/lib/esm/components/c4-advanced-search-filters/OrSection.d.ts +2 -2
- package/lib/esm/components/c4-advanced-search-filters/c4-advanced-search-filters.d.ts +1 -1
- package/lib/esm/components/c4-advanced-search-filters/state.types.d.ts +1 -1
- package/lib/esm/components/c4-advanced-search-filters/utils.d.ts +1 -1
- package/lib/esm/components/c4-ai-usage/c4-ai-usage.d.ts +1 -1
- package/lib/esm/components/c4-alpha-cluster-at-checkout/c4-alpha-cluster-at-checkout.d.ts +1 -1
- package/lib/esm/components/c4-app-teaser-card/c4-app-teaster-card.d.ts +1 -1
- package/lib/esm/components/c4-app-teaser-cards/c4-app-teaser-cards.d.ts +1 -1
- package/lib/esm/components/c4-app-teaser-cards/c4-app-teaser-cards.types.d.ts +1 -1
- package/lib/esm/components/c4-async-modal/c4-async-modal.d.ts +1 -1
- package/lib/esm/components/c4-audit-log/c4-audit-log.d.ts +1 -1
- package/lib/esm/components/c4-billing-page/c4-billing-page.d.ts +1 -1
- package/lib/esm/components/c4-billing-page/c4-billing-page.mocks.d.ts +1 -1
- package/lib/esm/components/c4-billing-page/c4-billing-page.types.d.ts +4 -4
- package/lib/esm/components/c4-billing-page/elements/current-usage-metrics.d.ts +4 -3
- package/lib/esm/components/c4-billing-page/elements/current-usage-metrics.js +6 -1
- package/lib/esm/components/c4-bottom-links/c4-bottom-links.d.ts +1 -1
- package/lib/esm/components/c4-bottom-links/c4-bottom-links.types.d.ts +1 -1
- package/lib/esm/components/c4-breadcrumb/c4-breadcrumb.d.ts +1 -1
- package/lib/esm/components/c4-charts-dashboard/c4-charts-dashboard.d.ts +1 -1
- package/lib/esm/components/c4-charts-dashboard/elements/alluvial-chart.d.ts +1 -1
- package/lib/esm/components/c4-charts-dashboard/elements/bar-chart.d.ts +1 -1
- package/lib/esm/components/c4-charts-dashboard/elements/line-chart.d.ts +1 -1
- package/lib/esm/components/c4-cluster-byom-clients/c4-cluster-byom-clients.d.ts +1 -1
- package/lib/esm/components/c4-cluster-client-credentials/c4-cluster-client-credentials.d.ts +1 -1
- package/lib/esm/components/c4-cluster-client-credentials-identity/c4-cluster-client-credentials-identity.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-activity/c4-cluster-details-activity.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-alerts/c4-cluster-details-alerts.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-alerts/c4-cluster-details-alerts.mocks.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-clients/c4-cluster-details-clients.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-clients/c4-cluster-details-clients.mocks.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-connector-secrets/c4-cluster-details-connector-secrets.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-connector-secrets/c4-cluster-details-connector-secrets.mocks.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-encryption/c4-cluster-details-encryption.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-hot-backups/c4-cluster-details-hot-backups.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-hot-backups/c4-cluster-details-hot-backups.js +22 -2
- package/lib/esm/components/c4-cluster-details-hot-backups/c4-cluster-details-hot-backups.mocks.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-hot-backups-restore/c4-cluster-details-hot-backups-restore.d.ts +2 -2
- package/lib/esm/components/c4-cluster-details-hot-backups-restore/c4-cluster-details-hot-backups-restore.js +4 -2
- package/lib/esm/components/c4-cluster-details-hot-backups-restore/c4-cluster-details-hot-backups-restore.types.d.ts +2 -0
- package/lib/esm/components/c4-cluster-details-ip-whitelist/c4-cluster-details-ip-whitelist.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-ip-whitelist/c4-cluster-details-ip-whitelist.mocks.d.ts +1 -1
- package/lib/esm/components/c4-cluster-details-secure-connectivity/c4-cluster-details-secure-connectivity.d.ts +1 -1
- package/lib/esm/components/c4-cluster-list/c4-cluster-list.d.ts +1 -1
- package/lib/esm/components/c4-cluster-list/c4-cluster-list.js +5 -2
- package/lib/esm/components/c4-cluster-list/c4-cluster-list.mocks.d.ts +1 -1
- package/lib/esm/components/c4-cluster-overview/c4-cluster-overview.d.ts +1 -1
- package/lib/esm/components/c4-cluster-overview/c4-cluster-overview.mocks.d.ts +3 -3
- package/lib/esm/components/c4-cluster-overview/c4-cluster-overview.types.d.ts +4 -4
- package/lib/esm/components/c4-cluster-settings/c4-cluster-settings.d.ts +1 -1
- package/lib/esm/components/c4-cluster-settings/c4-cluster-settings.mocks.d.ts +8 -8
- package/lib/esm/components/c4-cluster-settings/c4-cluster-settings.types.d.ts +5 -5
- package/lib/esm/components/c4-cluster-settings/elements/cluster-settings.d.ts +11 -11
- package/lib/esm/components/c4-cluster-settings/elements/tasklist-mode-settings.d.ts +1 -1
- package/lib/esm/components/c4-cluster-tag-selector/c4-cluster-tag-selector.d.ts +1 -1
- package/lib/esm/components/c4-clusters-empty-state/c4-clusters-empty-state.d.ts +1 -1
- package/lib/esm/components/c4-clusters-trial-notification/c4-clusters-trial-notification.d.ts +1 -1
- package/lib/esm/components/c4-console-dashboard/c4-console-dashboard.d.ts +1 -1
- package/lib/esm/components/c4-console-dashboard/c4-console-dashboard.js +26 -5
- package/lib/esm/components/c4-console-dashboard/c4-console-dashboard.mocks.d.ts +1 -1
- package/lib/esm/components/c4-console-dashboard/c4-console-dashboard.mocks.js +1 -0
- package/lib/esm/components/c4-console-dashboard/c4-console-dashboard.types.d.ts +1 -0
- package/lib/esm/components/c4-console-dashboard/elements/empty-state.d.ts +1 -1
- package/lib/esm/components/c4-convert-trial-organization-modal/c4-convert-trial-organization-modal.d.ts +1 -1
- package/lib/esm/components/c4-convert-trial-organization-modal/c4-convert-trial-organization-modal.types.d.ts +1 -1
- package/lib/esm/components/c4-create-alert-modal/c4-create-alert-modal.d.ts +1 -1
- package/lib/esm/components/c4-create-alert-modal/c4-create-alert-modal.mocks.d.ts +1 -1
- package/lib/esm/components/c4-create-cluster/c4-create-cluster-tile-grid.js +16 -1
- package/lib/esm/components/c4-create-cluster/c4-create-cluster.d.ts +1 -1
- package/lib/esm/components/c4-create-cluster/c4-create-cluster.js +5 -2
- package/lib/esm/components/c4-create-cluster/c4-create-cluster.mocks.d.ts +1 -1
- package/lib/esm/components/c4-create-cluster-api-client-modal/c4-create-cluster-api-client-modal.d.ts +1 -1
- package/lib/esm/components/c4-create-cluster-api-client-modal/c4-create-cluster-api-client-modal.mocks.d.ts +1 -1
- package/lib/esm/components/c4-create-connector-secret-modal/c4-create-connector-secret-modal.d.ts +1 -1
- package/lib/esm/components/c4-create-connector-secret-modal/c4-create-connector-secret-modal.mocks.d.ts +1 -1
- package/lib/esm/components/c4-create-console-api-client-modal/c4-create-console-api-client-modal.d.ts +1 -1
- package/lib/esm/components/c4-create-console-api-client-modal/c4-create-console-api-client-modal.mocks.d.ts +1 -1
- package/lib/esm/components/c4-create-ip-whitelist-modal/c4-create-ip-whitelist-modal.d.ts +1 -1
- package/lib/esm/components/c4-create-ip-whitelist-modal/c4-create-ip-whitelist-modal.mocks.d.ts +1 -1
- package/lib/esm/components/c4-create-trial-organization-modal/c4-create-trial-organization-modal.d.ts +1 -1
- package/lib/esm/components/c4-dashboard-first-launch/c4-dashboard-first-launch.d.ts +1 -1
- package/lib/esm/components/c4-dashboard-first-launch/c4-dashboard-first-launch.types.d.ts +1 -1
- package/lib/esm/components/c4-delete-organization-modal/c4-delete-organization-modal.d.ts +1 -1
- package/lib/esm/components/c4-divider/c4-divider.d.ts +1 -1
- package/lib/esm/components/c4-extend-trial-modal/c4-extend-trial-modal.d.ts +1 -1
- package/lib/esm/components/c4-external-link/c4-external-link.d.ts +1 -1
- package/lib/esm/components/c4-help-center/c4-help-center.d.ts +1 -1
- package/lib/esm/components/c4-info-tooltip/c4-info-tooltip.d.ts +1 -1
- package/lib/esm/components/c4-invite-user-to-organization-modal/c4-invite-user-to-organization-modal.d.ts +1 -1
- package/lib/esm/components/c4-invite-user-to-organization-modal/c4-invite-user-to-organization-modal.js +2 -47
- package/lib/esm/components/c4-job-dashboard-details-page/c4-job-dashboard-details-page.d.ts +1 -1
- package/lib/esm/components/c4-job-dashboard-details-page/c4-job-dashboard-details-page.mocks.d.ts +1 -1
- package/lib/esm/components/c4-job-dashboard-details-page/c4-job-dashboard-details-page.types.d.ts +4 -4
- package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-error-table.d.ts +2 -2
- package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-piechart.d.ts +3 -3
- package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-time-chart.d.ts +3 -3
- package/lib/esm/components/c4-job-dashboard-details-page/elements/c4-job-dashboard-worker-table.d.ts +2 -2
- package/lib/esm/components/c4-job-dashboard-entry-point/c4-job-dashboard-entry-point.d.ts +1 -1
- package/lib/esm/components/c4-job-dashboard-entry-point/c4-job-dashboard-entry-point.types.d.ts +2 -2
- package/lib/esm/components/c4-job-dashboard-overview-page/c4-job-dashboard-overview.d.ts +1 -1
- package/lib/esm/components/c4-job-dashboard-overview-page/c4-job-dashboard-overview.mocks.d.ts +1 -1
- package/lib/esm/components/c4-job-dashboard-overview-page/c4-job-dashboard-overview.types.d.ts +4 -4
- package/lib/esm/components/c4-job-dashboard-shared/c4-job-dashboard-error-handler.d.ts +1 -1
- package/lib/esm/components/c4-job-dashboard-shared/c4-stories-data-generator.d.ts +2 -2
- package/lib/esm/components/c4-leave-organization-modal/c4-leave-organization-modal.d.ts +1 -1
- package/lib/esm/components/c4-link-button/c4-link-button.d.ts +1 -1
- package/lib/esm/components/c4-llm-usage-meter/c4-llm-usage-meter.d.ts +1 -1
- package/lib/esm/components/c4-management-activity/c4-management-activity.d.ts +1 -1
- package/lib/esm/components/c4-management-activity/c4-management-activity.mocks.d.ts +1 -1
- package/lib/esm/components/c4-management-api/c4-management-api.d.ts +1 -1
- package/lib/esm/components/c4-management-api/c4-management-api.mocks.d.ts +1 -1
- package/lib/esm/components/c4-management-overview/c4-management-overview.d.ts +1 -1
- package/lib/esm/components/c4-management-settings/c4-management-settings.d.ts +1 -1
- package/lib/esm/components/c4-management-users/c4-management-users.d.ts +1 -1
- package/lib/esm/components/c4-multi-step-modal/c4-multi-step-modal.d.ts +1 -1
- package/lib/esm/components/c4-multi-step-modal-ugly/c4-multi-step-modal-ugly.d.ts +1 -1
- package/lib/esm/components/c4-navigation/c4-navigation.d.ts +2 -2
- package/lib/esm/components/c4-number-input/c4-number-input.d.ts +1 -1
- package/lib/esm/components/c4-old-dashboard/c4-old-dashboard.d.ts +1 -1
- package/lib/esm/components/c4-optimize-activation-modal/c4-optimize-activation-modal.d.ts +1 -1
- package/lib/esm/components/c4-page-template/c4-page-template.d.ts +9 -4
- package/lib/esm/components/c4-page-template/c4-page-template.js +1 -1
- package/lib/esm/components/c4-permission-error-page/c4-permission-error-page.d.ts +1 -1
- package/lib/esm/components/c4-pricing/c4-pricing.d.ts +1 -1
- package/lib/esm/components/c4-pricing/c4-pricing.types.d.ts +1 -1
- package/lib/esm/components/c4-pricing-card/c4-pricing-card.d.ts +1 -1
- package/lib/esm/components/c4-pricing-card/c4-pricing-card.utils.d.ts +1 -1
- package/lib/esm/components/c4-rename-organization-modal/c4-rename-organization-modal.d.ts +1 -1
- package/lib/esm/components/c4-search/c4-search-results.d.ts +1 -1
- package/lib/esm/components/c4-search/c4-search-results.types.d.ts +1 -1
- package/lib/esm/components/c4-search/c4-search.d.ts +2 -2
- package/lib/esm/components/c4-search/c4-search.types.d.ts +1 -1
- package/lib/esm/components/c4-search/search.utils.d.ts +3 -3
- package/lib/esm/components/c4-sm-cluster-details/automation-components.d.ts +1 -1
- package/lib/esm/components/c4-sm-cluster-details/c4-sm-cluster-details.d.ts +1 -1
- package/lib/esm/components/c4-sm-cluster-details/c4-sm-cluster-details.types.d.ts +3 -3
- package/lib/esm/components/c4-sm-cluster-details/custom-properties.d.ts +1 -1
- package/lib/esm/components/c4-sm-cluster-details/details.d.ts +1 -1
- package/lib/esm/components/c4-sm-cluster-details/zeebe-components.d.ts +1 -1
- package/lib/esm/components/c4-sm-dashboard/c4-sm-dashboard.d.ts +1 -1
- package/lib/esm/components/c4-sm-dashboard/c4-sm-dashboard.types.d.ts +2 -2
- package/lib/esm/components/c4-sm-dashboard/cluster-tile.d.ts +1 -1
- package/lib/esm/components/c4-sm-dashboard/explore.d.ts +1 -1
- package/lib/esm/components/c4-sm-dashboard/health-status.d.ts +1 -1
- package/lib/esm/components/c4-sm-dashboard/overview.d.ts +1 -1
- package/lib/esm/components/c4-stat/c4-stat.d.ts +1 -1
- package/lib/esm/components/c4-stateful-button/c4-stateful-button.d.ts +1 -1
- package/lib/esm/components/c4-tabs/c4-tabs.d.ts +1 -1
- package/lib/esm/components/c4-telemetry-page/c4-telemetry-page.d.ts +1 -1
- package/lib/esm/components/c4-telemetry-page/c4-telemetry-page.types.d.ts +1 -1
- package/lib/esm/components/c4-telemetry-page/telemetry-for-component.d.ts +2 -2
- package/lib/esm/components/c4-telemetry-teaser-page/c4-telemetry-teaser-page.d.ts +1 -1
- package/lib/esm/components/c4-theme-switcher/c4-theme-switcher.d.ts +1 -1
- package/lib/esm/components/c4-tile-with-title-and-action/c4-tile-with-title-and-action.d.ts +1 -1
- package/lib/esm/components/c4-toggle/c4-toggle.d.ts +1 -1
- package/lib/esm/components/c4-tsuga-links/c4-tsuga-links.d.ts +8 -0
- package/lib/esm/components/c4-tsuga-links/c4-tsuga-links.js +18 -0
- package/lib/esm/components/c4-tsuga-links/c4-tsuga-links.types.d.ts +15 -0
- package/lib/esm/components/c4-tsuga-links/tsuga-logs-url.d.ts +5 -0
- package/lib/esm/components/c4-tsuga-links/tsuga-logs-url.js +36 -0
- package/lib/esm/components/c4-tutorial-tile/c4-tutorial-tile.d.ts +1 -1
- package/lib/esm/components/c4-tutorial-tile/c4-tutorial-tile.utils.d.ts +1 -1
- package/lib/esm/components/c4-usage-alert-update-modal/c4-usage-alert-update-modal.d.ts +1 -1
- package/lib/esm/components/c4-usage-history/c4-usage-history.d.ts +1 -1
- package/lib/esm/components/c4-usage-history/c4-usage-history.types.d.ts +1 -1
- package/lib/esm/components/c4-usage-metrics-per-cluster/c4-usage-metrics-per-cluster.d.ts +1 -1
- package/lib/esm/components/c4-user-details/c4-user-details.d.ts +1 -1
- package/lib/esm/components/c4-user-details/c4-user-details.types.d.ts +3 -3
- package/lib/esm/components/shared-charts/recharts-tokens.d.ts +14 -2
- package/lib/esm/components/shared-charts/recharts-tokens.js +22 -1
- package/lib/esm/externalUrls.const.d.ts +6 -6
- package/lib/esm/i18n/en/entities/orgroles.json +2 -0
- package/lib/esm/i18n/en/modals/users.json +0 -1
- package/lib/esm/i18n/en/pages/clusterdetails.json +14 -3
- package/lib/esm/i18n/en/pages/dashboard.json +1 -0
- package/lib/esm/i18n/en/pages/orgmanagement.json +8 -0
- package/lib/esm/icons/c4-icons.d.ts +1 -1
- package/lib/esm/index.d.ts +237 -253
- package/lib/esm/index.js +6 -11
- package/lib/esm/modals/c4-create-cluster-api-client-modal-handle.d.ts +1 -1
- package/lib/esm/modals/c4-create-connector-secret-modal-handle.d.ts +1 -1
- package/lib/esm/modals/c4-create-console-api-client-modal-handle.d.ts +1 -1
- package/lib/esm/modals/c4-invite-user-to-organization-modal-handle.d.ts +1 -1
- package/lib/esm/modals/c4-rename-organization-modal-handle.d.ts +1 -1
- package/lib/esm/notifications/c4-console-notifications-handle.d.ts +1 -1
- package/lib/esm/runtime/build-cluster-swagger-url.d.ts +1 -1
- package/lib/esm/runtime/c4-console-data-context.d.ts +2 -2
- package/lib/esm/runtime/c4-console-data-store.d.ts +1 -1
- package/lib/esm/runtime/c4-console-notifications-context.d.ts +1 -1
- package/lib/esm/runtime/c4-console-runtime-context.d.ts +1 -1
- package/lib/esm/runtime/c4-user-notifications-context.d.ts +1 -1
- package/lib/esm/runtime/index.d.ts +40 -0
- package/lib/esm/runtime/index.js +18 -0
- package/lib/esm/runtime/to-api-config.d.ts +1 -1
- package/lib/esm/runtime/to-api-domain.d.ts +1 -1
- package/lib/esm/runtime/to-identity-api-base-url.d.ts +1 -1
- package/lib/esm/ui/c4-modal-dialog.js +16 -3
- package/lib/esm/ui/index.d.ts +2 -2
- package/lib/esm/ui/index.js +28 -2
- package/lib/esm/utils/role-labels.d.ts +20 -0
- package/lib/esm/utils/role-labels.js +79 -0
- package/lib/esm/widgets/cluster-client-details/c4-cluster-client-details-app.d.ts +1 -1
- package/lib/esm/widgets/cluster-client-details/c4-cluster-client-details-app.types.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/c4-cluster-details-app.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/c4-cluster-details-app.js +55 -2
- package/lib/esm/widgets/cluster-details/c4-cluster-details-page.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/c4-cluster-details-page.js +8 -0
- package/lib/esm/widgets/cluster-details/c4-cluster-details-page.types.d.ts +4 -1
- package/lib/esm/widgets/cluster-details/cluster-details-tabs.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-activity-tab.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-alerts-tab.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-audit-log-tab.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-byom-clients-tab.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-clients-tab.d.ts +5 -0
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-clients-tab.js +4 -4
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-hot-backups-tab.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-hot-backups-tab.js +26 -5
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-overview-tab.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-overview-tab.js +18 -7
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-settings-tab.d.ts +1 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-settings-tab.js +115 -45
- package/lib/esm/widgets/cluster-details/tabs/use-restart-confirm.d.ts +36 -0
- package/lib/esm/widgets/cluster-details/tabs/use-restart-confirm.js +58 -0
- package/lib/esm/widgets/clusters/c4-clusters-page.d.ts +1 -1
- package/lib/esm/widgets/clusters/c4-clusters-page.js +2 -2
- package/lib/esm/widgets/clusters/c4-clusters-page.types.d.ts +1 -1
- package/lib/esm/widgets/connector-management/c4-connector-management-executable-details-page.d.ts +1 -1
- package/lib/esm/widgets/connector-management/c4-connector-management-executables-table-page.d.ts +1 -1
- package/lib/esm/widgets/connector-management/c4-connector-management-outbound-details-page.d.ts +1 -1
- package/lib/esm/widgets/connector-management/c4-connector-management-page.d.ts +1 -1
- package/lib/esm/widgets/create-cluster/c4-create-cluster-page.d.ts +1 -1
- package/lib/esm/widgets/dashboard/c4-dashboard-app.d.ts +1 -1
- package/lib/esm/widgets/dashboard/c4-dashboard-app.js +1 -0
- package/lib/esm/widgets/group-details/c4-group-details-page.d.ts +1 -1
- package/lib/esm/widgets/job-worker/c4-job-worker-details-page.d.ts +1 -1
- package/lib/esm/widgets/job-worker/c4-job-worker-overview-page.d.ts +1 -1
- package/lib/esm/widgets/job-worker/c4-job-worker.helpers.d.ts +1 -1
- package/lib/esm/widgets/management/c4-management-app.d.ts +2 -2
- package/lib/esm/widgets/management/c4-management-app.js +142 -22
- package/lib/esm/widgets/management/c4-management-app.types.d.ts +16 -1
- package/lib/esm/widgets/management/c4-management-page.d.ts +1 -1
- package/lib/esm/widgets/management/c4-management-page.types.d.ts +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-activity-tab.d.ts +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-api-tab.d.ts +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-billing-tab.d.ts +3 -0
- package/lib/esm/widgets/management/tabs/c4-management-billing-tab.js +19 -3
- package/lib/esm/widgets/management/tabs/c4-management-pricing-tab.d.ts +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-settings-tab.d.ts +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-usage-tab.d.ts +1 -1
- package/lib/esm/widgets/management/tabs/c4-management-users-tab.d.ts +4 -8
- package/lib/esm/widgets/management/tabs/c4-management-users-tab.js +63 -87
- package/lib/esm/widgets/user-details/c4-user-details-page.d.ts +1 -1
- package/lib/esm/widgets/user-details/c4-user-details-page.js +29 -82
- package/package.json +45 -28
- package/lib/esm/components/c4-app-teaser-card/c4-app-teaster-card.spec.d.ts +0 -1
- package/lib/esm/components/c4-app-teaser-card/c4-app-teaster-card.spec.js +0 -43
- package/lib/esm/components/c4-billing-page/elements/value-metric.spec.d.ts +0 -1
- package/lib/esm/components/c4-billing-page/elements/value-metric.spec.js +0 -67
- package/lib/esm/components/c4-cluster-list/c4-cluster-list.spec.d.ts +0 -1
- package/lib/esm/components/c4-cluster-list/c4-cluster-list.spec.js +0 -132
- package/lib/esm/components/c4-cluster-list/c4-cluster-list.waiting.spec.d.ts +0 -1
- package/lib/esm/components/c4-cluster-list/c4-cluster-list.waiting.spec.js +0 -87
- package/lib/esm/components/c4-cluster-overview/applications.spec.d.ts +0 -1
- package/lib/esm/components/c4-cluster-overview/applications.spec.js +0 -58
- package/lib/esm/components/c4-cluster-overview/cluster-load.formatNumber.test.d.ts +0 -1
- package/lib/esm/components/c4-cluster-overview/cluster-load.formatNumber.test.js +0 -38
- package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider-modal.spec.d.ts +0 -1
- package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider-modal.spec.js +0 -93
- package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider.spec.d.ts +0 -1
- package/lib/esm/components/c4-cluster-settings/elements/external-identity-provider.spec.js +0 -50
- package/lib/esm/components/c4-cluster-settings/elements/multi-tenancy.spec.d.ts +0 -1
- package/lib/esm/components/c4-cluster-settings/elements/multi-tenancy.spec.js +0 -42
- package/lib/esm/components/c4-cluster-settings/elements/optimize-filtering-settings.spec.d.ts +0 -1
- package/lib/esm/components/c4-cluster-settings/elements/optimize-filtering-settings.spec.js +0 -120
- package/lib/esm/components/c4-clusters-empty-state/c4-clusters-empty-state.spec.d.ts +0 -1
- package/lib/esm/components/c4-clusters-empty-state/c4-clusters-empty-state.spec.js +0 -40
- package/lib/esm/components/c4-create-cluster/c4-create-cluster-tile-grid.spec.d.ts +0 -1
- package/lib/esm/components/c4-create-cluster/c4-create-cluster-tile-grid.spec.js +0 -83
- package/lib/esm/components/c4-create-cluster/c4-create-cluster.spec.d.ts +0 -1
- package/lib/esm/components/c4-create-cluster/c4-create-cluster.spec.js +0 -350
- package/lib/esm/components/c4-data-table/c4-data-table.spec.d.ts +0 -1
- package/lib/esm/components/c4-data-table/c4-data-table.spec.js +0 -122
- package/lib/esm/components/c4-data-table/c4-data-table.stability.spec.d.ts +0 -1
- package/lib/esm/components/c4-data-table/c4-data-table.stability.spec.js +0 -151
- package/lib/esm/components/c4-extend-trial-modal/c4-extend-trial-modal.spec.d.ts +0 -1
- package/lib/esm/components/c4-extend-trial-modal/c4-extend-trial-modal.spec.js +0 -33
- package/lib/esm/components/c4-page-template/c4-page-template.spec.d.ts +0 -1
- package/lib/esm/components/c4-page-template/c4-page-template.spec.js +0 -58
- package/lib/esm/components/c4-page-template/c4-page-template.stories.d.ts +0 -6
- package/lib/esm/components/c4-page-template/c4-page-template.stories.js +0 -73
- package/lib/esm/components/c4-stackdriver-links/c4-stackdriver-links.d.ts +0 -3
- package/lib/esm/components/c4-stackdriver-links/c4-stackdriver-links.js +0 -25
- package/lib/esm/components/c4-stackdriver-links/c4-stackdriver-links.types.d.ts +0 -12
- package/lib/esm/components/c4-tabs/c4-tabs.spec.d.ts +0 -1
- package/lib/esm/components/c4-tabs/c4-tabs.spec.js +0 -97
- package/lib/esm/components/c4-tabs/c4-tabs.stories.d.ts +0 -6
- package/lib/esm/components/c4-tabs/c4-tabs.stories.js +0 -35
- package/lib/esm/components/shared-charts/ds-charts.smoke.spec.d.ts +0 -1
- package/lib/esm/components/shared-charts/ds-charts.smoke.spec.js +0 -47
- package/lib/esm/externalUrls.const.spec.d.ts +0 -1
- package/lib/esm/externalUrls.const.spec.js +0 -102
- package/lib/esm/runtime/c4-console-authz.spec.d.ts +0 -1
- package/lib/esm/runtime/c4-console-authz.spec.js +0 -202
- package/lib/esm/runtime/c4-console-data-context.spec.d.ts +0 -1
- package/lib/esm/runtime/c4-console-data-context.spec.js +0 -354
- package/lib/esm/runtime/c4-console-data-store.nav.spec.d.ts +0 -1
- package/lib/esm/runtime/c4-console-data-store.nav.spec.js +0 -122
- package/lib/esm/runtime/c4-console-data-store.spec.d.ts +0 -1
- package/lib/esm/runtime/c4-console-data-store.spec.js +0 -409
- package/lib/esm/runtime/c4-user-notifications-context.spec.d.ts +0 -1
- package/lib/esm/runtime/c4-user-notifications-context.spec.js +0 -82
- package/lib/esm/runtime/nav/camunda-apps.spec.d.ts +0 -1
- package/lib/esm/runtime/nav/camunda-apps.spec.js +0 -90
- package/lib/esm/runtime/nav/use-webapp-nav-data.spec.d.ts +0 -1
- package/lib/esm/runtime/nav/use-webapp-nav-data.spec.js +0 -91
- package/lib/esm/setupTests.d.ts +0 -1
- package/lib/esm/setupTests.js +0 -37
- package/lib/esm/widgets/cluster-details/c4-cluster-details-app.merge.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/c4-cluster-details-app.merge.spec.js +0 -49
- package/lib/esm/widgets/cluster-details/c4-cluster-details-app.permissions.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/c4-cluster-details-app.permissions.spec.js +0 -471
- package/lib/esm/widgets/cluster-details/c4-cluster-details-page.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/c4-cluster-details-page.spec.js +0 -95
- package/lib/esm/widgets/cluster-details/cluster-details-tabs.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/cluster-details-tabs.spec.js +0 -33
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-alerts-tab.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-alerts-tab.spec.js +0 -72
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-byom-clients-tab.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-byom-clients-tab.spec.js +0 -85
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-clients-tab.mcp.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-clients-tab.mcp.spec.js +0 -105
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-clients-tab.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-clients-tab.spec.js +0 -226
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-hot-backups-tab.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-hot-backups-tab.spec.js +0 -179
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-overview-tab.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-overview-tab.spec.js +0 -1255
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-secure-connectivity-tab.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-secure-connectivity-tab.spec.js +0 -397
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-settings-tab.spec.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/tabs/c4-cluster-details-settings-tab.spec.js +0 -488
- package/lib/esm/widgets/cluster-details/tabs/url-utils.test.d.ts +0 -1
- package/lib/esm/widgets/cluster-details/tabs/url-utils.test.js +0 -34
- package/lib/esm/widgets/clusters/c4-clusters-page.spec.d.ts +0 -1
- package/lib/esm/widgets/clusters/c4-clusters-page.spec.js +0 -502
- package/lib/esm/widgets/connector-management/c4-connector-management-page.spec.d.ts +0 -1
- package/lib/esm/widgets/connector-management/c4-connector-management-page.spec.js +0 -226
- package/lib/esm/widgets/create-cluster/c4-create-cluster-page.spec.d.ts +0 -1
- package/lib/esm/widgets/create-cluster/c4-create-cluster-page.spec.js +0 -191
- package/lib/esm/widgets/group-details/c4-group-details-page.spec.d.ts +0 -1
- package/lib/esm/widgets/group-details/c4-group-details-page.spec.js +0 -35
- package/lib/esm/widgets/management/c4-management-app.spec.d.ts +0 -1
- package/lib/esm/widgets/management/c4-management-app.spec.js +0 -509
- package/lib/esm/widgets/management/c4-management-page.spec.d.ts +0 -1
- package/lib/esm/widgets/management/c4-management-page.spec.js +0 -40
- package/lib/esm/widgets/management/management-tabs.spec.d.ts +0 -1
- package/lib/esm/widgets/management/management-tabs.spec.js +0 -28
- package/lib/esm/widgets/management/tabs/c4-management-billing-tab.spec.d.ts +0 -1
- package/lib/esm/widgets/management/tabs/c4-management-billing-tab.spec.js +0 -246
- package/lib/esm/widgets/management/tabs/c4-management-users-tab.spec.d.ts +0 -1
- package/lib/esm/widgets/management/tabs/c4-management-users-tab.spec.js +0 -225
- package/lib/esm/widgets/use-extend-trial.spec.d.ts +0 -1
- package/lib/esm/widgets/use-extend-trial.spec.js +0 -79
- package/lib/esm/widgets/user-details/c4-user-details-page.spec.d.ts +0 -1
- package/lib/esm/widgets/user-details/c4-user-details-page.spec.js +0 -65
- /package/lib/esm/components/{c4-stackdriver-links/c4-stackdriver-links.types.js → c4-tsuga-links/c4-tsuga-links.types.js} +0 -0
|
@@ -16,6 +16,11 @@ interface C4ClusterDetailsClientsTabProps {
|
|
|
16
16
|
springZeebeConfigDocsUrl: string;
|
|
17
17
|
apiConfig: RequestBaseParamsConfig;
|
|
18
18
|
canMutateCluster: boolean;
|
|
19
|
+
clientsPermissions?: {
|
|
20
|
+
canCreate: boolean;
|
|
21
|
+
canUpdate: boolean;
|
|
22
|
+
canDelete: boolean;
|
|
23
|
+
};
|
|
19
24
|
useClusterSecretsLabel?: boolean;
|
|
20
25
|
t: TranslateFn | undefined;
|
|
21
26
|
onNavigate?: (event: unknown) => void;
|
|
@@ -73,7 +73,7 @@ function renderInlineLink(value, opts) {
|
|
|
73
73
|
}
|
|
74
74
|
export const C4ClusterDetailsClientsTab = (props) => {
|
|
75
75
|
const runtime = useC4ConsoleRuntime();
|
|
76
|
-
const { cluster, clients, clientsLoading, clientsError, hasIdentityIntegration, orgId, clusterId, clientsDocsUrl, mcpSetupDocsUrl: mcpSetupDocsUrlFromProps, identityAuthorizationDocsUrl, springZeebeGettingStartedDocsUrl, springZeebeConfigDocsUrl, apiConfig, canMutateCluster, useClusterSecretsLabel, t, onNavigate, onReloadClients, } = props;
|
|
76
|
+
const { cluster, clients, clientsLoading, clientsError, hasIdentityIntegration, orgId, clusterId, clientsDocsUrl, mcpSetupDocsUrl: mcpSetupDocsUrlFromProps, identityAuthorizationDocsUrl, springZeebeGettingStartedDocsUrl, springZeebeConfigDocsUrl, apiConfig, canMutateCluster, clientsPermissions, useClusterSecretsLabel, t, onNavigate, onReloadClients, } = props;
|
|
77
77
|
const oauthTokenUrl = useMemo(() => {
|
|
78
78
|
const base = runtime.publicUrls?.loginBaseUrl || runtime.backendUrls.identityApiBaseUrl;
|
|
79
79
|
return base ? joinUrl(base, '/oauth/token') : '';
|
|
@@ -174,9 +174,9 @@ export const C4ClusterDetailsClientsTab = (props) => {
|
|
|
174
174
|
identity: cluster?.status?.identityUrl ?? '',
|
|
175
175
|
docs: clientsDocsUrl,
|
|
176
176
|
}, permissions: {
|
|
177
|
-
canCreate: canMutateCluster,
|
|
178
|
-
canUpdate: canMutateCluster,
|
|
179
|
-
canDelete: canMutateCluster,
|
|
177
|
+
canCreate: clientsPermissions?.canCreate ?? canMutateCluster,
|
|
178
|
+
canUpdate: clientsPermissions?.canUpdate ?? canMutateCluster,
|
|
179
|
+
canDelete: clientsPermissions?.canDelete ?? canMutateCluster,
|
|
180
180
|
}, onNavigateToClient: (clientId) => {
|
|
181
181
|
trackEvent('apiClients:details:open', 'Open Api Client Details Modal', {
|
|
182
182
|
clientId,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { RequestBaseParamsConfig } from '@camunda/ccma-api';
|
|
2
2
|
import type { ConsoleClusterDto } from '@camunda/ccma-shared-types';
|
|
3
3
|
import type { JSX } from 'react';
|
|
4
|
-
import type { C4ClusterDetailsNavigateEvent } from '../c4-cluster-details-app.types';
|
|
4
|
+
import type { C4ClusterDetailsNavigateEvent } from '../c4-cluster-details-app.types.js';
|
|
5
5
|
type TranslateFn = (key: string, options?: Record<string, unknown>) => string;
|
|
6
6
|
interface C4ClusterDetailsHotBackupsTabProps {
|
|
7
7
|
cluster: ConsoleClusterDto | undefined;
|
|
@@ -140,6 +140,13 @@ const C4ClusterDetailsHotBackupsTabImpl = (props) => {
|
|
|
140
140
|
const [selectedBackupId, setSelectedBackupId] = useState('');
|
|
141
141
|
const [backupMutationBusy, setBackupMutationBusy] = useState(false);
|
|
142
142
|
const [backupMutationError, setBackupMutationError] = useState('');
|
|
143
|
+
// Synchronous re-entrancy guard for restore: `backupMutationBusy` state lags
|
|
144
|
+
// a render behind, so a rapid double-click on the modal's Restore button
|
|
145
|
+
// could invoke `onConfirm` again before the button's disabled state
|
|
146
|
+
// repaints. The ref flips synchronously and makes a second call a no-op
|
|
147
|
+
// while a restore is in flight, preventing duplicate restore requests.
|
|
148
|
+
// Mirrors the guard in `use-restart-confirm.tsx`.
|
|
149
|
+
const restoreSubmittingRef = useRef(false);
|
|
143
150
|
// Schedule states
|
|
144
151
|
const [editScheduleOpen, setEditScheduleOpen] = useState(false);
|
|
145
152
|
const [deleteScheduleOpen, setDeleteScheduleOpen] = useState(false);
|
|
@@ -156,7 +163,13 @@ const C4ClusterDetailsHotBackupsTabImpl = (props) => {
|
|
|
156
163
|
return;
|
|
157
164
|
}
|
|
158
165
|
hotBackupsLoadingRef.current = true;
|
|
159
|
-
|
|
166
|
+
// Only show the full-section skeleton on the first load (or after a
|
|
167
|
+
// cluster switch, which resets `hotBackupsLoadedRef`). Background/SSE-driven
|
|
168
|
+
// refreshes keep existing rows mounted and update them in place, avoiding a
|
|
169
|
+
// skeleton flicker on every backup status-transition event.
|
|
170
|
+
if (!hotBackupsLoadedRef.current) {
|
|
171
|
+
setHotBackupsLoading(true);
|
|
172
|
+
}
|
|
160
173
|
setHotBackupsError(false);
|
|
161
174
|
const [backupsResult, scheduleResult] = await Promise.allSettled([
|
|
162
175
|
ConsoleHotBackupsService.getHotBackups({
|
|
@@ -521,12 +534,19 @@ const C4ClusterDetailsHotBackupsTabImpl = (props) => {
|
|
|
521
534
|
name: selectedBackup.name,
|
|
522
535
|
version: selectedBackup.generationName ?? '-',
|
|
523
536
|
completedAt: completedAt === '-' ? '' : completedAt,
|
|
524
|
-
}, currentClusterVersion: cluster?.generation?.name ?? '-', onRequestClose: () => {
|
|
537
|
+
}, currentClusterVersion: cluster?.generation?.name ?? '-', isSubmitting: backupMutationBusy, onRequestClose: () => {
|
|
525
538
|
trackEvent('listBackups:restore:cancel', 'Close Restore Backup Modal', { backupId: selectedBackupId });
|
|
526
539
|
setRestoreBackupOpen(false);
|
|
527
540
|
}, onConfirm: (backupId) => {
|
|
528
541
|
if (!isHotBackupEnabled)
|
|
529
542
|
return;
|
|
543
|
+
// Synchronous guard: `backupMutationBusy` only disables the
|
|
544
|
+
// button after a re-render, so a rapid double-click could reach
|
|
545
|
+
// here twice first. Bail out on the second call instead of
|
|
546
|
+
// firing a duplicate restore request.
|
|
547
|
+
if (restoreSubmittingRef.current)
|
|
548
|
+
return;
|
|
549
|
+
restoreSubmittingRef.current = true;
|
|
530
550
|
void (async () => {
|
|
531
551
|
trackEvent('listBackups:restore:confirm', 'Confirm Restore Backup Modal', { backupId });
|
|
532
552
|
setBackupMutationBusy(true);
|
|
@@ -557,6 +577,7 @@ const C4ClusterDetailsHotBackupsTabImpl = (props) => {
|
|
|
557
577
|
});
|
|
558
578
|
}
|
|
559
579
|
finally {
|
|
580
|
+
restoreSubmittingRef.current = false;
|
|
560
581
|
setBackupMutationBusy(false);
|
|
561
582
|
}
|
|
562
583
|
})();
|
|
@@ -568,9 +589,9 @@ const C4ClusterDetailsHotBackupsTabImpl = (props) => {
|
|
|
568
589
|
versionLabel: safeTranslate(t, 'clusterdetails:hotbackups.restoreModal.versionLabel', 'Version'),
|
|
569
590
|
confirmButton: safeTranslate(t, 'clusterdetails:hotbackups.restoreModal.confirmButton', 'Restore'),
|
|
570
591
|
cancelButton: safeTranslate(t, 'clusterdetails:hotbackups.restoreModal.cancelButton', 'Cancel'),
|
|
571
|
-
versionMismatchTitle: safeTranslate(t, 'clusterdetails:hotbackups.restoreModal.versionMismatchTitle', '
|
|
572
|
-
versionMismatchBody: safeTranslate(t, 'clusterdetails:hotbackups.restoreModal.versionMismatchBody', '
|
|
573
|
-
acknowledgmentLabel: safeTranslate(t, 'clusterdetails:hotbackups.restoreModal.acknowledgmentLabel', 'I understand
|
|
592
|
+
versionMismatchTitle: safeTranslate(t, 'clusterdetails:hotbackups.restoreModal.versionMismatchTitle', 'This will change your cluster version'),
|
|
593
|
+
versionMismatchBody: safeTranslate(t, 'clusterdetails:hotbackups.restoreModal.versionMismatchBody', 'Restoring changes your cluster from {currentVersion} to {backupVersion} and permanently overwrites your current data. Cancel to back up first.'),
|
|
594
|
+
acknowledgmentLabel: safeTranslate(t, 'clusterdetails:hotbackups.restoreModal.acknowledgmentLabel', 'I understand the version change.'),
|
|
574
595
|
} }));
|
|
575
596
|
})(), _jsx(Modal, { open: editScheduleOpen, modalHeading: scheduleIsCreate
|
|
576
597
|
? safeTranslate(t, 'backups:schedule.create.title', 'Create backup schedule')
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type RequestBaseParamsConfig } from '@camunda/ccma-api';
|
|
2
2
|
import type { ClusterPlanTypesToReserved, ConsoleClusterDto, HdpPrometheusDataCapacityDataPoint } from '@camunda/ccma-shared-types';
|
|
3
3
|
import { type JSX } from 'react';
|
|
4
|
-
import type { C4ClusterDetailsNavigateEvent } from '../c4-cluster-details-app.types';
|
|
4
|
+
import type { C4ClusterDetailsNavigateEvent } from '../c4-cluster-details-app.types.js';
|
|
5
5
|
type TranslateFn = (key: string, options?: Record<string, unknown>) => string;
|
|
6
6
|
interface ConsoleClusterCreationParametersDto {
|
|
7
7
|
regions?: Array<{
|
|
@@ -439,11 +439,15 @@ const C4ClusterDetailsOverviewTabImpl = (props) => {
|
|
|
439
439
|
current: currentVersions?.connectorBridge ?? currentVersions?.zeebe,
|
|
440
440
|
target: targetVersions?.connectorBridge ?? targetVersions?.zeebe,
|
|
441
441
|
}),
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
442
|
+
// Generations still ship an Optimize image when the plan allocates no
|
|
443
|
+
// Optimize replicas, so gate on the plan (see the Optimize tile below).
|
|
444
|
+
cluster?.hasOptimize === false
|
|
445
|
+
? undefined
|
|
446
|
+
: versionDelta({
|
|
447
|
+
label: 'Optimize',
|
|
448
|
+
current: currentVersions?.optimize,
|
|
449
|
+
target: targetVersions?.optimize,
|
|
450
|
+
}),
|
|
447
451
|
].filter((value) => typeof value === 'string');
|
|
448
452
|
return items;
|
|
449
453
|
})();
|
|
@@ -1198,8 +1202,15 @@ const C4ClusterDetailsOverviewTabImpl = (props) => {
|
|
|
1198
1202
|
description: appDescription.operate,
|
|
1199
1203
|
linkLabel: launchLabel,
|
|
1200
1204
|
}),
|
|
1201
|
-
|
|
1202
|
-
|
|
1205
|
+
// `hasOptimize === false` means the plan allocates no Optimize replicas, so
|
|
1206
|
+
// console-backend never renders an Optimize spec for this cluster. Its
|
|
1207
|
+
// status/version fields can still be populated from a plan change that
|
|
1208
|
+
// disabled Optimize while the workloads were running, so they cannot gate the
|
|
1209
|
+
// tile on their own. `undefined` (plan not readable) keeps the legacy
|
|
1210
|
+
// status-based behaviour rather than hiding a tile we can't rule out.
|
|
1211
|
+
optimize: cluster.hasOptimize !== false &&
|
|
1212
|
+
(cluster.status?.optimizeStatus !== undefined ||
|
|
1213
|
+
cluster.generation?.versions?.optimize !== undefined)
|
|
1203
1214
|
? toAppTileProps({
|
|
1204
1215
|
name: 'Optimize',
|
|
1205
1216
|
status: cluster.status?.optimizeStatus,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { RequestBaseParamsConfig } from '@camunda/ccma-api';
|
|
2
2
|
import { type ConsoleClusterDto } from '@camunda/ccma-shared-types';
|
|
3
3
|
import { type JSX } from 'react';
|
|
4
|
-
import type { C4ClusterDetailsNavigateEvent } from '../c4-cluster-details-app.types';
|
|
4
|
+
import type { C4ClusterDetailsNavigateEvent } from '../c4-cluster-details-app.types.js';
|
|
5
5
|
type TranslateFn = (key: string, options?: Record<string, unknown>) => string;
|
|
6
6
|
interface C4ClusterDetailsSettingsTabProps {
|
|
7
7
|
cluster: ConsoleClusterDto | undefined;
|
|
@@ -9,6 +9,7 @@ import { buildClusterSwaggerUrl } from '../../../runtime/build-cluster-swagger-u
|
|
|
9
9
|
import { useC4ConsoleRuntime } from '../../../runtime/c4-console-runtime-context.js';
|
|
10
10
|
import { Link, Modal } from '../../../ui/index.js';
|
|
11
11
|
import { isClusterReconciliationPaused } from '../../is-cluster-reconciliation-paused.js';
|
|
12
|
+
import { useRestartConfirm } from './use-restart-confirm.js';
|
|
12
13
|
// Helper to translate with fallback
|
|
13
14
|
function safeTranslate(translateFn, key, fallback, options) {
|
|
14
15
|
try {
|
|
@@ -65,6 +66,45 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
65
66
|
const [authorizationsConfirmError, setAuthorizationsConfirmError] = useState(undefined);
|
|
66
67
|
const [operationError, setOperationError] = useState(undefined);
|
|
67
68
|
const settingUpdateFailedFallback = safeTranslate(props.t, 'clusterdetails:settings.operationError.fallback', 'Could not update setting. Please try again.');
|
|
69
|
+
// Restart-confirm modal: any setting that feeds the generated Kubernetes spec
|
|
70
|
+
// restarts the cluster when changed. Restart-affecting toggles pop a shared
|
|
71
|
+
// confirmation before applying.
|
|
72
|
+
const restartConfirm = useRestartConfirm({
|
|
73
|
+
heading: safeTranslate(props.t, 'clusterdetails:settings.restartConfirm.heading', 'Restart required'),
|
|
74
|
+
primaryButtonText: safeTranslate(props.t, 'clusterdetails:settings.restartConfirm.confirm', 'Continue'),
|
|
75
|
+
secondaryButtonText: safeTranslate(props.t, 'clusterdetails:settings.restartConfirm.cancel', 'Cancel'),
|
|
76
|
+
body: (_jsx("p", { children: safeTranslate(props.t, 'clusterdetails:settings.restartConfirm.body', 'Changing this setting restarts your cluster. Your cluster is briefly unavailable while it restarts.') })),
|
|
77
|
+
errorFallback: settingUpdateFailedFallback,
|
|
78
|
+
});
|
|
79
|
+
// Fire-and-forget wrapper for atomic toggles: asks for restart confirmation
|
|
80
|
+
// before applying.
|
|
81
|
+
const applyWithRestartConfirm = useCallback((apply) => () => {
|
|
82
|
+
restartConfirm.request({ onConfirm: apply });
|
|
83
|
+
}, [restartConfirm]);
|
|
84
|
+
// Promise-based wrapper for controls that await their apply callback (e.g. the
|
|
85
|
+
// optimize data-filters panel). Resolves after the PATCH on confirm, or
|
|
86
|
+
// immediately without applying on cancel.
|
|
87
|
+
const applyWithRestartConfirmAsync = useCallback((apply) => {
|
|
88
|
+
return new Promise((resolve, reject) => {
|
|
89
|
+
restartConfirm.request({
|
|
90
|
+
onConfirm: async () => {
|
|
91
|
+
try {
|
|
92
|
+
await apply();
|
|
93
|
+
resolve();
|
|
94
|
+
}
|
|
95
|
+
catch (error) {
|
|
96
|
+
// Settle the awaited promise so the caller's cleanup (e.g. the
|
|
97
|
+
// optimize-filtering panel clearing its loading flag) runs, and
|
|
98
|
+
// rethrow so `useRestartConfirm` still surfaces the in-modal error
|
|
99
|
+
// and keeps the modal open.
|
|
100
|
+
reject(error);
|
|
101
|
+
throw error;
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
onCancel: () => resolve(),
|
|
105
|
+
});
|
|
106
|
+
});
|
|
107
|
+
}, [restartConfirm]);
|
|
68
108
|
const isReconciliationPaused = isClusterReconciliationPaused(props.cluster);
|
|
69
109
|
const effectiveCanEdit = props.canEditCluster && !isReconciliationPaused && !props.restoreInProgress;
|
|
70
110
|
const checkClusterVersion = useCallback((minVersion) => {
|
|
@@ -490,10 +530,13 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
490
530
|
setIsUpdatingExternalIdp(false);
|
|
491
531
|
}
|
|
492
532
|
}, [props, runtime.telemetry, settingUpdateFailedFallback]);
|
|
493
|
-
// BYOIDP
|
|
494
|
-
//
|
|
495
|
-
//
|
|
496
|
-
//
|
|
533
|
+
// BYOIDP (camunda-operator#5760): save config from the modal. Write the secret
|
|
534
|
+
// FIRST, then persist config and enable — the secret now lands via the cloud
|
|
535
|
+
// secret manager + ESO sync rather than a direct K8s Secret write, so it's
|
|
536
|
+
// eventually (not immediately) consistent; the settings row's statusText reflects
|
|
537
|
+
// that via the OidcProvidersPending condition. secretUpdatedAt is bumped here
|
|
538
|
+
// whenever a new secret was entered, so a rotation changes the CR and rolls the
|
|
539
|
+
// pods once the sync completes.
|
|
497
540
|
const submitExternalIdp = useCallback(async ({ config, clientSecret, }) => {
|
|
498
541
|
setIsUpdatingExternalIdp(true);
|
|
499
542
|
setExternalIdpError(undefined);
|
|
@@ -544,10 +587,9 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
544
587
|
const shouldShowResourceBasedAuthorizations = useMemo(() => {
|
|
545
588
|
return checkClusterVersion('8.6.0') && !checkClusterVersion('8.8.0-alpha5');
|
|
546
589
|
}, [checkClusterVersion]);
|
|
547
|
-
const isMultiTenancyFeatureEnabled = runtime.featureFlags?.isEnabled?.('console.multiTenancy') ?? false;
|
|
548
590
|
const shouldShowMultiTenancy = useMemo(() => {
|
|
549
|
-
return checkClusterVersion('8.8.0-alpha7')
|
|
550
|
-
}, [checkClusterVersion
|
|
591
|
+
return checkClusterVersion('8.8.0-alpha7');
|
|
592
|
+
}, [checkClusterVersion]);
|
|
551
593
|
// BYOIDP Phase 1 (#3190). TODO(byoidp): byoidp remove gate at GA rollout
|
|
552
594
|
const isByoidpFeatureEnabled = runtime.featureFlags?.isEnabled?.('console.byoidp') ?? false;
|
|
553
595
|
const shouldShowExternalIdp = useMemo(() => {
|
|
@@ -555,9 +597,17 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
555
597
|
}, [checkClusterVersion, isByoidpFeatureEnabled]);
|
|
556
598
|
const isOptimizeFilteringFeatureEnabled = runtime.featureFlags?.isEnabled?.('console.optimizeFiltering') ?? false;
|
|
557
599
|
const shouldShowOptimizeFiltering = useMemo(() => {
|
|
558
|
-
return (
|
|
600
|
+
return (
|
|
601
|
+
// `hasOptimize === false` means the plan allocates no Optimize replicas, so
|
|
602
|
+
// there is no Optimize deployment for these filters to configure.
|
|
603
|
+
props.cluster?.hasOptimize !== false &&
|
|
604
|
+
checkClusterVersion(OPTIMIZE_FILTERING_MIN_VERSION) &&
|
|
559
605
|
isOptimizeFilteringFeatureEnabled);
|
|
560
|
-
}, [
|
|
606
|
+
}, [
|
|
607
|
+
props.cluster?.hasOptimize,
|
|
608
|
+
checkClusterVersion,
|
|
609
|
+
isOptimizeFilteringFeatureEnabled,
|
|
610
|
+
]);
|
|
561
611
|
const isAppIntegrationsFeatureEnabled = runtime.featureFlags?.isEnabled?.('console.appIntegrations') ?? false;
|
|
562
612
|
const shouldShowAppIntegrations = useMemo(() => {
|
|
563
613
|
const zeebeVersion = props.cluster?.generation?.versions?.zeebe;
|
|
@@ -580,44 +630,53 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
580
630
|
isAppIntegrationsFeatureEnabled,
|
|
581
631
|
checkClusterVersion,
|
|
582
632
|
]);
|
|
633
|
+
// Optimize data filters feed the generated spec, so a change restarts the
|
|
634
|
+
// cluster. The toggle/save actions are awaited by the child panel, so route
|
|
635
|
+
// them through the promise-based restart-confirm wrapper.
|
|
583
636
|
const handleOptimizeFilteringToggle = useCallback(async (enabled) => {
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
637
|
+
await applyWithRestartConfirmAsync(async () => {
|
|
638
|
+
try {
|
|
639
|
+
await ConsoleClusterService.updateCluster({
|
|
640
|
+
config: props.apiConfig,
|
|
641
|
+
params: { orgId: props.orgId, clusterId: props.clusterId },
|
|
642
|
+
body: { optimizeFiltering: enabled ? {} : null },
|
|
643
|
+
});
|
|
644
|
+
await props.onReloadCluster();
|
|
645
|
+
}
|
|
646
|
+
catch (error) {
|
|
647
|
+
setOperationError(settingUpdateFailedFallback);
|
|
648
|
+
throw error;
|
|
649
|
+
}
|
|
650
|
+
});
|
|
596
651
|
}, [
|
|
597
652
|
props.apiConfig,
|
|
598
653
|
props.orgId,
|
|
599
654
|
props.clusterId,
|
|
600
655
|
props.onReloadCluster,
|
|
601
656
|
settingUpdateFailedFallback,
|
|
657
|
+
applyWithRestartConfirmAsync,
|
|
602
658
|
]);
|
|
603
659
|
const handleOptimizeFilteringSave = useCallback(async (config) => {
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
660
|
+
await applyWithRestartConfirmAsync(async () => {
|
|
661
|
+
try {
|
|
662
|
+
await ConsoleClusterService.updateCluster({
|
|
663
|
+
config: props.apiConfig,
|
|
664
|
+
params: { orgId: props.orgId, clusterId: props.clusterId },
|
|
665
|
+
body: { optimizeFiltering: config },
|
|
666
|
+
});
|
|
667
|
+
await props.onReloadCluster();
|
|
668
|
+
}
|
|
669
|
+
catch (error) {
|
|
670
|
+
setOperationError(settingUpdateFailedFallback);
|
|
671
|
+
}
|
|
672
|
+
});
|
|
615
673
|
}, [
|
|
616
674
|
props.apiConfig,
|
|
617
675
|
props.orgId,
|
|
618
676
|
props.clusterId,
|
|
619
677
|
props.onReloadCluster,
|
|
620
678
|
settingUpdateFailedFallback,
|
|
679
|
+
applyWithRestartConfirmAsync,
|
|
621
680
|
]);
|
|
622
681
|
if (!props.cluster)
|
|
623
682
|
return _jsx(_Fragment, {});
|
|
@@ -751,7 +810,7 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
751
810
|
enabled: props.cluster.multiTenancyEnabled ?? false,
|
|
752
811
|
action: {
|
|
753
812
|
label: safeTranslate(props.t, 'clusterdetails:settings.multiTenancy.title', 'Multi-tenancy'),
|
|
754
|
-
onClick: () => updateMultiTenancy(!(props.cluster?.multiTenancyEnabled ?? false)),
|
|
813
|
+
onClick: applyWithRestartConfirm(() => updateMultiTenancy(!(props.cluster?.multiTenancyEnabled ?? false))),
|
|
755
814
|
},
|
|
756
815
|
permissions: {
|
|
757
816
|
mayToggle: effectiveCanEdit && !isUpdatingMultiTenancy,
|
|
@@ -765,9 +824,19 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
765
824
|
enabled: props.cluster.externalIdpEnabled ?? false,
|
|
766
825
|
configured: Boolean(props.cluster.externalIdpConfig),
|
|
767
826
|
displayName: props.cluster.externalIdpConfig?.clientName,
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
827
|
+
// BYOIDP (camunda-operator#5760): the secret now reaches the cluster via
|
|
828
|
+
// a cloud secret manager + ESO sync, which is eventually consistent
|
|
829
|
+
// rather than synchronous. Surface the operator's condition instead of
|
|
830
|
+
// assuming the write completed the moment the modal closed. The
|
|
831
|
+
// condition clears when the operator either drops it or flips its
|
|
832
|
+
// status to 'False', so treat present-and-not-False as pending (the
|
|
833
|
+
// backend allowlists this type in clusterConditions.utils.ts).
|
|
834
|
+
statusText: !props.cluster.externalIdpConfig
|
|
835
|
+
? 'Not configured'
|
|
836
|
+
: props.cluster.status?.conditions?.some((condition) => condition.type === 'OidcProvidersPending' &&
|
|
837
|
+
condition.status !== 'False')
|
|
838
|
+
? `Pending: ${props.cluster.externalIdpConfig.clientName} (secret sync in progress)`
|
|
839
|
+
: `Configured: ${props.cluster.externalIdpConfig.clientName}`,
|
|
771
840
|
action: {
|
|
772
841
|
label: props.cluster.externalIdpConfig ? 'Edit' : 'Configure',
|
|
773
842
|
onClick: () => {
|
|
@@ -782,7 +851,8 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
782
851
|
setShowExternalIdpModal(true);
|
|
783
852
|
return;
|
|
784
853
|
}
|
|
785
|
-
|
|
854
|
+
const toggleExternalIdp = applyWithRestartConfirm(() => updateExternalIdpEnabled(!(props.cluster?.externalIdpEnabled ?? false)));
|
|
855
|
+
toggleExternalIdp();
|
|
786
856
|
},
|
|
787
857
|
permissions: {
|
|
788
858
|
mayToggle: effectiveCanEdit && !isUpdatingExternalIdp,
|
|
@@ -812,7 +882,7 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
812
882
|
},
|
|
813
883
|
action: {
|
|
814
884
|
label: safeTranslate(props.t, 'clusterdetails:settings.enforceGroups.title', 'Enforce user task restrictions'),
|
|
815
|
-
onClick: toggleEnforceGroups,
|
|
885
|
+
onClick: applyWithRestartConfirm(toggleEnforceGroups),
|
|
816
886
|
disabled: isUpdatingEnforceGroups,
|
|
817
887
|
},
|
|
818
888
|
},
|
|
@@ -825,7 +895,7 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
825
895
|
},
|
|
826
896
|
action: {
|
|
827
897
|
label: safeTranslate(props.t, 'clusterdetails:settings.lowLatency.title', 'Low latency updates'),
|
|
828
|
-
onClick: toggleLowLatency,
|
|
898
|
+
onClick: applyWithRestartConfirm(toggleLowLatency),
|
|
829
899
|
disabled: isUpdatingLowLatency,
|
|
830
900
|
},
|
|
831
901
|
},
|
|
@@ -847,7 +917,7 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
847
917
|
},
|
|
848
918
|
action: {
|
|
849
919
|
label: safeTranslate(props.t, 'clusterdetails:settings.swagger.title', 'Enable Swagger'),
|
|
850
|
-
onClick: toggleSwagger,
|
|
920
|
+
onClick: applyWithRestartConfirm(toggleSwagger),
|
|
851
921
|
disabled: isUpdatingSwagger,
|
|
852
922
|
},
|
|
853
923
|
},
|
|
@@ -861,7 +931,7 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
861
931
|
},
|
|
862
932
|
action: {
|
|
863
933
|
label: safeTranslate(props.t, 'clusterdetails:settings.mcp.title', 'Enable MCP Support'),
|
|
864
|
-
onClick: toggleMcp,
|
|
934
|
+
onClick: applyWithRestartConfirm(toggleMcp),
|
|
865
935
|
disabled: isUpdatingMcp,
|
|
866
936
|
},
|
|
867
937
|
},
|
|
@@ -875,7 +945,7 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
875
945
|
},
|
|
876
946
|
action: {
|
|
877
947
|
label: safeTranslate(props.t, 'clusterdetails:settings.businessIdUniqueness.title', 'Enable Business ID Uniqueness'),
|
|
878
|
-
onClick: toggleBusinessIdUniqueness,
|
|
948
|
+
onClick: applyWithRestartConfirm(toggleBusinessIdUniqueness),
|
|
879
949
|
disabled: isUpdatingBusinessIdUniqueness,
|
|
880
950
|
},
|
|
881
951
|
},
|
|
@@ -890,7 +960,7 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
890
960
|
},
|
|
891
961
|
action: {
|
|
892
962
|
label: safeTranslate(props.t, 'clusterdetails:settings.appIntegrations.title', 'Enable App Integrations'),
|
|
893
|
-
onClick: toggleAppIntegrations,
|
|
963
|
+
onClick: applyWithRestartConfirm(toggleAppIntegrations),
|
|
894
964
|
disabled: isUpdatingAppIntegrations,
|
|
895
965
|
},
|
|
896
966
|
},
|
|
@@ -945,7 +1015,7 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
945
1015
|
setTasklistV2UpgradeError(undefined);
|
|
946
1016
|
}, onRequestSubmit: () => {
|
|
947
1017
|
void submitTasklistV2Upgrade();
|
|
948
|
-
}, size: 'sm', children: [_jsx("p", { children: safeTranslate(props.t, 'clusterdetails:settings.tasklistMode.modal.description', 'This action cannot be undone. Once upgraded to Tasklist v2, downgrading back to v1 will not be possible.') }), tasklistV2UpgradeError && (_jsx(C4InlineNotification, { lowContrast: true, kind: 'error', hideCloseButton: true, title: '', subtitle: tasklistV2UpgradeError }))] })), authorizationsConfirm && (_jsxs(Modal, { open: true, modalHeading: authorizationsConfirmTitle, primaryButtonText: authorizationsConfirmPrimaryText, secondaryButtonText: safeTranslate(props.t, 'clusterdetails:settings.authorizations.modal.buttons.cancel', 'Cancel'), primaryButtonDisabled: isUpdatingRba || isUpdatingIdentityAuthorizations, onRequestClose: () => {
|
|
1018
|
+
}, size: 'sm', children: [_jsx("p", { children: safeTranslate(props.t, 'clusterdetails:settings.tasklistMode.modal.description', 'This action cannot be undone. Once upgraded to Tasklist v2, downgrading back to v1 will not be possible.') }), _jsx("p", { children: safeTranslate(props.t, 'clusterdetails:settings.restartConfirm.note', 'Changing this setting also restarts your cluster. Your cluster is briefly unavailable while it restarts.') }), tasklistV2UpgradeError && (_jsx(C4InlineNotification, { lowContrast: true, kind: 'error', hideCloseButton: true, title: '', subtitle: tasklistV2UpgradeError }))] })), authorizationsConfirm && (_jsxs(Modal, { open: true, modalHeading: authorizationsConfirmTitle, primaryButtonText: authorizationsConfirmPrimaryText, secondaryButtonText: safeTranslate(props.t, 'clusterdetails:settings.authorizations.modal.buttons.cancel', 'Cancel'), primaryButtonDisabled: isUpdatingRba || isUpdatingIdentityAuthorizations, onRequestClose: () => {
|
|
949
1019
|
if (isUpdatingRba || isUpdatingIdentityAuthorizations) {
|
|
950
1020
|
return;
|
|
951
1021
|
}
|
|
@@ -953,7 +1023,7 @@ export const C4ClusterDetailsSettingsTab = (props) => {
|
|
|
953
1023
|
setAuthorizationsConfirmError(undefined);
|
|
954
1024
|
}, onRequestSubmit: () => {
|
|
955
1025
|
void submitAuthorizationsConfirmation();
|
|
956
|
-
}, size: 'sm', children: [authorizationsConfirmDescription, authorizationsConfirmError && (_jsx(C4InlineNotification, { lowContrast: true, kind: 'error', hideCloseButton: true, title: '', subtitle: authorizationsConfirmError }))] })), shouldShowExternalIdp && (_jsx(ExternalIdentityProviderModal, { open: showExternalIdpModal, initialConfig: props.cluster.externalIdpConfig, saving: isUpdatingExternalIdp, error: externalIdpError, onClose: () => {
|
|
1026
|
+
}, size: 'sm', children: [authorizationsConfirmDescription, _jsx("p", { children: safeTranslate(props.t, 'clusterdetails:settings.restartConfirm.note', 'Changing this setting also restarts your cluster. Your cluster is briefly unavailable while it restarts.') }), authorizationsConfirmError && (_jsx(C4InlineNotification, { lowContrast: true, kind: 'error', hideCloseButton: true, title: '', subtitle: authorizationsConfirmError }))] })), restartConfirm.modal, shouldShowExternalIdp && (_jsx(ExternalIdentityProviderModal, { open: showExternalIdpModal, initialConfig: props.cluster.externalIdpConfig, saving: isUpdatingExternalIdp, error: externalIdpError, onClose: () => {
|
|
957
1027
|
if (isUpdatingExternalIdp)
|
|
958
1028
|
return;
|
|
959
1029
|
setShowExternalIdpModal(false);
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { type JSX, type ReactNode } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Shared restart-confirmation controller for the cluster settings tab.
|
|
4
|
+
*
|
|
5
|
+
* Cluster settings that feed the generated Kubernetes spec restart the cluster
|
|
6
|
+
* when changed. Rather than duplicating a confirmation modal per toggle, this
|
|
7
|
+
* hook holds a single piece of pending state and renders one shared modal: a
|
|
8
|
+
* restart-affecting toggle calls `request({ onConfirm })` instead of applying
|
|
9
|
+
* immediately, and the atomic PATCH runs only once the user confirms. On cancel
|
|
10
|
+
* nothing is applied, so the toggle re-syncs to the persisted cluster value on
|
|
11
|
+
* the next render. Each toggle stays atomic — there is no staged save.
|
|
12
|
+
*/
|
|
13
|
+
export interface RestartConfirmCopy {
|
|
14
|
+
heading: string;
|
|
15
|
+
primaryButtonText: string;
|
|
16
|
+
secondaryButtonText: string;
|
|
17
|
+
/** Default body shown when a request does not pass its own `body`. */
|
|
18
|
+
body: ReactNode;
|
|
19
|
+
/** Fallback message when `onConfirm` rejects without an Error message. */
|
|
20
|
+
errorFallback: string;
|
|
21
|
+
}
|
|
22
|
+
export interface RestartConfirmRequest {
|
|
23
|
+
/** Optional per-setting body node; defaults to the shared restart message. */
|
|
24
|
+
body?: ReactNode;
|
|
25
|
+
/** The atomic PATCH + reload to run once the user confirms. */
|
|
26
|
+
onConfirm: () => Promise<void>;
|
|
27
|
+
/** Called when the user dismisses the modal without confirming. */
|
|
28
|
+
onCancel?: () => void;
|
|
29
|
+
}
|
|
30
|
+
export interface UseRestartConfirm {
|
|
31
|
+
/** Ask the user to confirm a restart before running `onConfirm`. */
|
|
32
|
+
request: (req: RestartConfirmRequest) => void;
|
|
33
|
+
/** The shared modal to render; `undefined` when nothing is pending. */
|
|
34
|
+
modal: JSX.Element | undefined;
|
|
35
|
+
}
|
|
36
|
+
export declare function useRestartConfirm(copy: RestartConfirmCopy): UseRestartConfirm;
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
/*
|
|
3
|
+
* Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH
|
|
4
|
+
* under one or more contributor license agreements. Licensed under a commercial license.
|
|
5
|
+
* You may not use this file except in compliance with the commercial license.
|
|
6
|
+
*/
|
|
7
|
+
import { useCallback, useRef, useState } from 'react';
|
|
8
|
+
import { C4InlineNotification } from '../../../components/c4-inline-notification/c4-inline-notification.js';
|
|
9
|
+
import { Modal } from '../../../ui/index.js';
|
|
10
|
+
export function useRestartConfirm(copy) {
|
|
11
|
+
const [pending, setPending] = useState(undefined);
|
|
12
|
+
const [isSubmitting, setIsSubmitting] = useState(false);
|
|
13
|
+
// Synchronous re-entrancy guard: `isSubmitting` state lags a render behind, so
|
|
14
|
+
// a rapid double-click / Enter could invoke `submit` again before the button's
|
|
15
|
+
// disabled state repaints. The ref flips synchronously and makes a second call
|
|
16
|
+
// a no-op while a confirm is in flight, preventing duplicate PATCH requests.
|
|
17
|
+
const submittingRef = useRef(false);
|
|
18
|
+
const [error, setError] = useState(undefined);
|
|
19
|
+
const request = useCallback((req) => {
|
|
20
|
+
setError(undefined);
|
|
21
|
+
setPending({
|
|
22
|
+
body: req.body ?? copy.body,
|
|
23
|
+
onConfirm: req.onConfirm,
|
|
24
|
+
onCancel: req.onCancel,
|
|
25
|
+
});
|
|
26
|
+
}, [copy.body]);
|
|
27
|
+
const cancel = useCallback(() => {
|
|
28
|
+
pending?.onCancel?.();
|
|
29
|
+
setPending(undefined);
|
|
30
|
+
setError(undefined);
|
|
31
|
+
}, [pending]);
|
|
32
|
+
const submit = useCallback(async () => {
|
|
33
|
+
if (!pending || submittingRef.current)
|
|
34
|
+
return;
|
|
35
|
+
submittingRef.current = true;
|
|
36
|
+
setError(undefined);
|
|
37
|
+
setIsSubmitting(true);
|
|
38
|
+
try {
|
|
39
|
+
await pending.onConfirm();
|
|
40
|
+
setPending(undefined);
|
|
41
|
+
}
|
|
42
|
+
catch (submitError) {
|
|
43
|
+
setError(submitError instanceof Error ? submitError.message : copy.errorFallback);
|
|
44
|
+
}
|
|
45
|
+
finally {
|
|
46
|
+
submittingRef.current = false;
|
|
47
|
+
setIsSubmitting(false);
|
|
48
|
+
}
|
|
49
|
+
}, [pending, copy.errorFallback]);
|
|
50
|
+
const modal = pending ? (_jsxs(Modal, { open: true, modalHeading: copy.heading, primaryButtonText: copy.primaryButtonText, secondaryButtonText: copy.secondaryButtonText, primaryButtonDisabled: isSubmitting, onRequestClose: () => {
|
|
51
|
+
if (isSubmitting)
|
|
52
|
+
return;
|
|
53
|
+
cancel();
|
|
54
|
+
}, onRequestSubmit: () => {
|
|
55
|
+
void submit();
|
|
56
|
+
}, size: 'sm', children: [pending.body, error && (_jsx(C4InlineNotification, { lowContrast: true, kind: 'error', hideCloseButton: true, subtitle: error }))] })) : undefined;
|
|
57
|
+
return { request, modal };
|
|
58
|
+
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { C4ClustersPageProps } from './c4-clusters-page.types';
|
|
1
|
+
import type { C4ClustersPageProps } from './c4-clusters-page.types.js';
|
|
2
2
|
export declare const C4ClustersPage: (({ orgId, gettingStartedHref, onNavigate, translations, permissionsOverride, clusterCapMessage, isClusterPaused: isClusterPausedOverride, isRunningOnUnsupportedGeneration: isRunningOnUnsupportedGenerationOverride, onRequestAssignTag, onRequestDeleteCluster, onRequestWakeCluster, onRequestFailoverCluster, onNeedsReload, }: C4ClustersPageProps) => import("react").JSX.Element) & {
|
|
3
3
|
displayName: string;
|
|
4
4
|
};
|
|
@@ -831,7 +831,7 @@ export const C4ClustersPage = observer(({ orgId, gettingStartedHref, onNavigate,
|
|
|
831
831
|
}
|
|
832
832
|
// Only surface failover for supported reverse-region pairs (#9120) —
|
|
833
833
|
// the backend enforces the same list as a backstop.
|
|
834
|
-
if (!isSupportedFailoverRegionPair(backupRegionCodes[0], backupRegionCodes[1])) {
|
|
834
|
+
if (!isSupportedFailoverRegionPair(backupRegionCodes[0], backupRegionCodes[1], runtime.stage)) {
|
|
835
835
|
continue;
|
|
836
836
|
}
|
|
837
837
|
// Must use the same priority as mapClusterToListItem so the ID stored
|
|
@@ -854,7 +854,7 @@ export const C4ClustersPage = observer(({ orgId, gettingStartedHref, onNavigate,
|
|
|
854
854
|
multiRegionClusterIds: eligible,
|
|
855
855
|
syncPendingClusterIds: syncPending,
|
|
856
856
|
};
|
|
857
|
-
}, [rawClusters]);
|
|
857
|
+
}, [rawClusters, runtime.stage]);
|
|
858
858
|
const isMultiRegionClusterFallback = useCallback((clusterId) => multiRegionClusterIds.has(clusterId), [multiRegionClusterIds]);
|
|
859
859
|
const isFailoverSyncPending = useCallback((clusterId) => syncPendingClusterIds.has(clusterId), [syncPendingClusterIds]);
|
|
860
860
|
const isPageLoading = isLoading || authz.isLoading;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ClusterListPermissions } from '../../components/c4-cluster-list/c4-cluster-list.types';
|
|
1
|
+
import type { ClusterListPermissions } from '../../components/c4-cluster-list/c4-cluster-list.types.js';
|
|
2
2
|
export type C4ClustersNavigateEvent = {
|
|
3
3
|
kind: 'clusterDetails';
|
|
4
4
|
orgId: string;
|
package/lib/esm/widgets/connector-management/c4-connector-management-executable-details-page.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { C4ConnectorManagementExecutableDetailsPageProps } from './c4-connector-management-executable-details-page.types';
|
|
1
|
+
import type { C4ConnectorManagementExecutableDetailsPageProps } from './c4-connector-management-executable-details-page.types.js';
|
|
2
2
|
export declare const C4ConnectorManagementExecutableDetailsPage: (({ orgId, clusterId, connectorId, connectorInstanceId, onNavigate, }: C4ConnectorManagementExecutableDetailsPageProps) => import("react").JSX.Element) & {
|
|
3
3
|
displayName: string;
|
|
4
4
|
};
|
package/lib/esm/widgets/connector-management/c4-connector-management-executables-table-page.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { C4ConnectorManagementExecutablesTablePageProps } from './c4-connector-management-executables-table-page.types';
|
|
1
|
+
import type { C4ConnectorManagementExecutablesTablePageProps } from './c4-connector-management-executables-table-page.types.js';
|
|
2
2
|
export declare const C4ConnectorManagementExecutablesTablePage: (({ orgId, clusterId, connectorId, onNavigate, }: C4ConnectorManagementExecutablesTablePageProps) => import("react").JSX.Element) & {
|
|
3
3
|
displayName: string;
|
|
4
4
|
};
|
package/lib/esm/widgets/connector-management/c4-connector-management-outbound-details-page.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { C4ConnectorManagementOutboundDetailsPageProps } from './c4-connector-management-outbound-details-page.types';
|
|
1
|
+
import type { C4ConnectorManagementOutboundDetailsPageProps } from './c4-connector-management-outbound-details-page.types.js';
|
|
2
2
|
export declare const C4ConnectorManagementOutboundDetailsPage: (({ orgId, clusterId, connectorType, onNavigate, }: C4ConnectorManagementOutboundDetailsPageProps) => import("react").JSX.Element) & {
|
|
3
3
|
displayName: string;
|
|
4
4
|
};
|