@openshift-assisted/ui-lib 2.8.2-cim → 2.8.4-cim
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/@types/cim/components/ClusterDeployment/ClusterDeploymentDetails.d.ts.map +1 -1
- package/@types/cim/components/ClusterDeployment/ClusterDeploymentDetailsStep.d.ts +6 -1
- package/@types/cim/components/ClusterDeployment/ClusterDeploymentDetailsStep.d.ts.map +1 -1
- package/@types/cim/components/ClusterDeployment/ClusterDeploymentHostSelectionStep.d.ts.map +1 -1
- package/@types/cim/components/ClusterDeployment/ClusterDeploymentHostsDiscoveryStep.d.ts.map +1 -1
- package/@types/cim/components/ClusterDeployment/ClusterDeploymentHostsSelectionBasic.d.ts.map +1 -1
- package/@types/cim/components/ClusterDeployment/ClusterDeploymentWizardNavigation.d.ts.map +1 -1
- package/@types/cim/components/ClusterDeployment/ClusterDetailsFormFields.d.ts.map +1 -1
- package/@types/cim/components/ClusterDeployment/helpers.d.ts +1 -1
- package/@types/cim/components/ClusterDeployment/helpers.d.ts.map +1 -1
- package/@types/cim/components/ClusterDeployment/validationSchemas.d.ts.map +1 -1
- package/@types/cim/components/Hypershift/HostedClusterWizard/NetworkStep/types.d.ts +0 -1
- package/@types/cim/components/Hypershift/HostedClusterWizard/NetworkStep/types.d.ts.map +1 -1
- package/@types/cim/components/Hypershift/modals/ManageHostsModal.d.ts.map +1 -1
- package/@types/cim/components/InfraEnv/InfraEnvFormPage.d.ts +2 -0
- package/@types/cim/components/InfraEnv/InfraEnvFormPage.d.ts.map +1 -1
- package/@types/cim/components/helpers/versions.d.ts +1 -0
- package/@types/cim/components/helpers/versions.d.ts.map +1 -1
- package/@types/cim/components/modals/AddHostModal.d.ts.map +1 -1
- package/@types/cim/components/modals/EditProxyModal.d.ts.map +1 -1
- package/@types/common/components/clusterConfiguration/DiscoveryImageConfigForm.d.ts +5 -1
- package/@types/common/components/clusterConfiguration/DiscoveryImageConfigForm.d.ts.map +1 -1
- package/@types/common/components/clusterConfiguration/DownloadIso.d.ts +2 -1
- package/@types/common/components/clusterConfiguration/DownloadIso.d.ts.map +1 -1
- package/@types/common/components/clusterConfiguration/OpenShiftVersionSelect.d.ts +2 -0
- package/@types/common/components/clusterConfiguration/OpenShiftVersionSelect.d.ts.map +1 -1
- package/@types/common/components/clusterWizard/ClusterWizardStep.d.ts +1 -1
- package/@types/common/components/clusterWizard/ClusterWizardStep.d.ts.map +1 -1
- package/@types/common/components/clusterWizard/networkingSteps/ManagedNetworkingControlGroup.d.ts.map +1 -1
- package/@types/common/components/fetching/EventListFetch.d.ts +1 -1
- package/@types/common/components/fetching/EventListFetch.d.ts.map +1 -1
- package/@types/common/components/hosts/TableToolbar.d.ts.map +1 -1
- package/@types/common/components/ui/ClusterEventsToolbar.d.ts.map +1 -1
- package/@types/common/components/ui/StaticTextField.d.ts +1 -1
- package/@types/common/components/ui/StaticTextField.d.ts.map +1 -1
- package/@types/common/components/ui/eventsModal.d.ts +4 -8
- package/@types/common/components/ui/eventsModal.d.ts.map +1 -1
- package/@types/common/components/ui/formik/UploadField.d.ts.map +1 -1
- package/@types/common/components/ui/formik/types.d.ts +2 -2
- package/@types/common/components/ui/formik/types.d.ts.map +1 -1
- package/@types/common/components/ui/formik/validationSchemas.d.ts +5 -1
- package/@types/common/components/ui/formik/validationSchemas.d.ts.map +1 -1
- package/@types/common/config/constants.d.ts +2 -1
- package/@types/common/config/constants.d.ts.map +1 -1
- package/@types/common/types/events.d.ts +9 -2
- package/@types/common/types/events.d.ts.map +1 -1
- package/@types/ocm/components/AddHosts/day2Wizard/Day2ClusterDetails.d.ts.map +1 -1
- package/@types/ocm/components/AddHosts/day2Wizard/Day2StaticIP.d.ts.map +1 -1
- package/@types/ocm/components/AddHosts/day2Wizard/Day2Wizard.d.ts.map +1 -1
- package/@types/ocm/components/HostsClusterDetailTab/HostsClusterDetailTabContent.d.ts.map +1 -1
- package/@types/ocm/components/HostsClusterDetailTab/types.d.ts +5 -0
- package/@types/ocm/components/HostsClusterDetailTab/types.d.ts.map +1 -1
- package/@types/ocm/components/HostsClusterDetailTab/utils.d.ts +2 -7
- package/@types/ocm/components/HostsClusterDetailTab/utils.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/CpuArchitectureDropdown.d.ts +2 -1
- package/@types/ocm/components/clusterConfiguration/CpuArchitectureDropdown.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/DiscoveryImageForm.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/OcmDiscoveryImageConfigForm.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/manifestsConfiguration/components/CustomManifestsForm.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/manifestsConfiguration/components/FolderDropdown.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/manifestsConfiguration/components/customManifestsValidationSchema.d.ts +1 -0
- package/@types/ocm/components/clusterConfiguration/manifestsConfiguration/components/customManifestsValidationSchema.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/networkConfiguration/AdvancedNetworkFields.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfigurationForm.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/networkConfiguration/StackTypeControl.d.ts.map +1 -1
- package/@types/ocm/components/clusterConfiguration/networkConfiguration/VirtualIPControlGroup.d.ts.map +1 -1
- package/@types/ocm/components/clusterDetail/AssistedInstallerDetailCard.d.ts.map +1 -1
- package/@types/ocm/components/clusterDetail/AssistedInstallerExtraDetailCard.d.ts.map +1 -1
- package/@types/ocm/components/clusterWizard/ClusterWizardContextProvider.d.ts.map +1 -1
- package/@types/ocm/components/clusterWizard/wizardTransition.d.ts +2 -1
- package/@types/ocm/components/clusterWizard/wizardTransition.d.ts.map +1 -1
- package/@types/ocm/components/clusters/ClusterPage.d.ts.map +1 -1
- package/@types/ocm/components/featureSupportLevels/FeatureSupportLevelProvider.d.ts.map +1 -1
- package/@types/ocm/components/fetching/fetchEvents.d.ts.map +1 -1
- package/@types/ocm/components/newFeatureSupportLevels/NewFeatureSupportLevelProvider.d.ts.map +1 -1
- package/@types/ocm/components/ui/OcmFormFields.d.ts +1 -1
- package/@types/ocm/hooks/useClusterCustomManifests.d.ts +1 -1
- package/@types/ocm/hooks/useClusterCustomManifests.d.ts.map +1 -1
- package/@types/ocm/hooks/useInfraEnv.d.ts +1 -1
- package/@types/ocm/hooks/useInfraEnv.d.ts.map +1 -1
- package/@types/ocm/hooks/useInfraEnvId.d.ts +1 -1
- package/@types/ocm/hooks/useInfraEnvId.d.ts.map +1 -1
- package/@types/ocm/selectors/clusters.d.ts +3 -3
- package/@types/ocm/services/Day2ClusterService.d.ts +3 -3
- package/@types/ocm/services/Day2ClusterService.d.ts.map +1 -1
- package/@types/ocm/services/InfraEnvIdsCacheService.d.ts +1 -1
- package/@types/ocm/services/InfraEnvIdsCacheService.d.ts.map +1 -1
- package/@types/ocm/services/InfraEnvsService.d.ts +4 -3
- package/@types/ocm/services/InfraEnvsService.d.ts.map +1 -1
- package/@types/ocm/services/apis/EventsAPI.d.ts +1 -0
- package/@types/ocm/services/apis/EventsAPI.d.ts.map +1 -1
- package/@types/ocm/store/slices/infraEnvs/selectors.d.ts +1 -1
- package/build/build.json +1 -1
- package/build/cim/components/Agent/BMCForm.js +2 -2
- package/build/cim/components/Agent/BMCForm.js.map +1 -1
- package/build/cim/components/ClusterDeployment/ClusterDeploymentDetails.js +59 -56
- package/build/cim/components/ClusterDeployment/ClusterDeploymentDetails.js.map +1 -1
- package/build/cim/components/ClusterDeployment/ClusterDeploymentDetailsStep.js +10 -6
- package/build/cim/components/ClusterDeployment/ClusterDeploymentDetailsStep.js.map +1 -1
- package/build/cim/components/ClusterDeployment/ClusterDeploymentHostSelectionStep.js +1 -9
- package/build/cim/components/ClusterDeployment/ClusterDeploymentHostSelectionStep.js.map +1 -1
- package/build/cim/components/ClusterDeployment/ClusterDeploymentHostsDiscoveryStep.js +1 -2
- package/build/cim/components/ClusterDeployment/ClusterDeploymentHostsDiscoveryStep.js.map +1 -1
- package/build/cim/components/ClusterDeployment/ClusterDeploymentHostsSelectionBasic.js +3 -10
- package/build/cim/components/ClusterDeployment/ClusterDeploymentHostsSelectionBasic.js.map +1 -1
- package/build/cim/components/ClusterDeployment/ClusterDeploymentWizardNavigation.js +2 -2
- package/build/cim/components/ClusterDeployment/ClusterDeploymentWizardNavigation.js.map +1 -1
- package/build/cim/components/ClusterDeployment/ClusterDetailsFormFields.js +6 -2
- package/build/cim/components/ClusterDeployment/ClusterDetailsFormFields.js.map +1 -1
- package/build/cim/components/ClusterDeployment/helpers.js +46 -7
- package/build/cim/components/ClusterDeployment/helpers.js.map +1 -1
- package/build/cim/components/ClusterDeployment/use-networking-formik.js +2 -2
- package/build/cim/components/ClusterDeployment/use-networking-formik.js.map +1 -1
- package/build/cim/components/ClusterDeployment/validationSchemas.js +0 -1
- package/build/cim/components/ClusterDeployment/validationSchemas.js.map +1 -1
- package/build/cim/components/Hypershift/HostedClusterWizard/NetworkStep/NetworkStep.js +2 -2
- package/build/cim/components/Hypershift/HostedClusterWizard/NetworkStep/NetworkStep.js.map +1 -1
- package/build/cim/components/Hypershift/modals/ManageHostsModal.js +1 -6
- package/build/cim/components/Hypershift/modals/ManageHostsModal.js.map +1 -1
- package/build/cim/components/Hypershift/utils/nodepool.js +5 -5
- package/build/cim/components/Hypershift/utils/nodepool.js.map +1 -1
- package/build/cim/components/InfraEnv/InfraEnvFormPage.js +13 -5
- package/build/cim/components/InfraEnv/InfraEnvFormPage.js.map +1 -1
- package/build/cim/components/helpers/versions.js +1 -0
- package/build/cim/components/helpers/versions.js.map +1 -1
- package/build/cim/components/modals/AddHostModal.js +4 -4
- package/build/cim/components/modals/AddHostModal.js.map +1 -1
- package/build/cim/components/modals/EditProxyModal.js +18 -7
- package/build/cim/components/modals/EditProxyModal.js.map +1 -1
- package/build/common/components/clusterConfiguration/DiscoveryImageConfigForm.js +9 -9
- package/build/common/components/clusterConfiguration/DiscoveryImageConfigForm.js.map +1 -1
- package/build/common/components/clusterConfiguration/DownloadIso.js +2 -2
- package/build/common/components/clusterConfiguration/DownloadIso.js.map +1 -1
- package/build/common/components/clusterConfiguration/OpenShiftVersionSelect.js +2 -2
- package/build/common/components/clusterConfiguration/OpenShiftVersionSelect.js.map +1 -1
- package/build/common/components/clusterWizard/ClusterWizardStep.js +1 -1
- package/build/common/components/clusterWizard/ClusterWizardStep.js.map +1 -1
- package/build/common/components/clusterWizard/networkingSteps/ManagedNetworkingControlGroup.js +5 -2
- package/build/common/components/clusterWizard/networkingSteps/ManagedNetworkingControlGroup.js.map +1 -1
- package/build/common/components/clusterWizard/networkingSteps/NetworkTypeControlGroup.js +1 -1
- package/build/common/components/clusterWizard/networkingSteps/NetworkTypeControlGroup.js.map +1 -1
- package/build/common/components/fetching/EventListFetch.js +14 -25
- package/build/common/components/fetching/EventListFetch.js.map +1 -1
- package/build/common/components/hosts/TableToolbar.js +3 -3
- package/build/common/components/hosts/TableToolbar.js.map +1 -1
- package/build/common/components/hosts/status.js +1 -1
- package/build/common/components/hosts/status.js.map +1 -1
- package/build/common/components/ui/ClusterEventsToolbar.js +1 -1
- package/build/common/components/ui/ClusterEventsToolbar.js.map +1 -1
- package/build/common/components/ui/eventsModal.js +12 -6
- package/build/common/components/ui/eventsModal.js.map +1 -1
- package/build/common/components/ui/formik/CodeField.js +1 -1
- package/build/common/components/ui/formik/CodeField.js.map +1 -1
- package/build/common/components/ui/formik/SelectField.js +1 -1
- package/build/common/components/ui/formik/SelectField.js.map +1 -1
- package/build/common/components/ui/formik/UploadField.js +1 -2
- package/build/common/components/ui/formik/UploadField.js.map +1 -1
- package/build/common/components/ui/formik/validationSchemas.js +20 -13
- package/build/common/components/ui/formik/validationSchemas.js.map +1 -1
- package/build/common/config/constants.js +3 -1
- package/build/common/config/constants.js.map +1 -1
- package/build/ocm/components/AddHosts/day2Wizard/Day2ClusterDetails.js +94 -20
- package/build/ocm/components/AddHosts/day2Wizard/Day2ClusterDetails.js.map +1 -1
- package/build/ocm/components/AddHosts/day2Wizard/Day2DownloadISO.js +1 -1
- package/build/ocm/components/AddHosts/day2Wizard/Day2DownloadISO.js.map +1 -1
- package/build/ocm/components/AddHosts/day2Wizard/Day2StaticIP.js +16 -9
- package/build/ocm/components/AddHosts/day2Wizard/Day2StaticIP.js.map +1 -1
- package/build/ocm/components/AddHosts/day2Wizard/Day2Wizard.js +1 -1
- package/build/ocm/components/AddHosts/day2Wizard/Day2Wizard.js.map +1 -1
- package/build/ocm/components/HostsClusterDetailTab/HostsClusterDetailTabContent.js +5 -2
- package/build/ocm/components/HostsClusterDetailTab/HostsClusterDetailTabContent.js.map +1 -1
- package/build/ocm/components/HostsClusterDetailTab/utils.js +35 -29
- package/build/ocm/components/HostsClusterDetailTab/utils.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/CpuArchitectureDropdown.js +5 -4
- package/build/ocm/components/clusterConfiguration/CpuArchitectureDropdown.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/DiscoveryImageForm.js +3 -1
- package/build/ocm/components/clusterConfiguration/DiscoveryImageForm.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/OcmDiscoveryImageConfigForm.js +11 -8
- package/build/ocm/components/clusterConfiguration/OcmDiscoveryImageConfigForm.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/manifestsConfiguration/components/CustomManifestsForm.js +49 -21
- package/build/ocm/components/clusterConfiguration/manifestsConfiguration/components/CustomManifestsForm.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/manifestsConfiguration/components/FolderDropdown.js +3 -9
- package/build/ocm/components/clusterConfiguration/manifestsConfiguration/components/FolderDropdown.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/manifestsConfiguration/components/customManifestsValidationSchema.js +37 -2
- package/build/ocm/components/clusterConfiguration/manifestsConfiguration/components/customManifestsValidationSchema.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/networkConfiguration/AdvancedNetworkFields.js +16 -5
- package/build/ocm/components/clusterConfiguration/networkConfiguration/AdvancedNetworkFields.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfigurationForm.js +5 -2
- package/build/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfigurationForm.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/networkConfiguration/StackTypeControl.js +1 -2
- package/build/ocm/components/clusterConfiguration/networkConfiguration/StackTypeControl.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/networkConfiguration/VirtualIPControlGroup.js +27 -16
- package/build/ocm/components/clusterConfiguration/networkConfiguration/VirtualIPControlGroup.js.map +1 -1
- package/build/ocm/components/clusterConfiguration/platformIntegration/PlatformIntegration.js +1 -1
- package/build/ocm/components/clusterConfiguration/platformIntegration/PlatformIntegration.js.map +1 -1
- package/build/ocm/components/clusterDetail/AssistedInstallerDetailCard.js +7 -2
- package/build/ocm/components/clusterDetail/AssistedInstallerDetailCard.js.map +1 -1
- package/build/ocm/components/clusterDetail/AssistedInstallerExtraDetailCard.js +7 -2
- package/build/ocm/components/clusterDetail/AssistedInstallerExtraDetailCard.js.map +1 -1
- package/build/ocm/components/clusterWizard/ClusterWizardContextProvider.js +13 -3
- package/build/ocm/components/clusterWizard/ClusterWizardContextProvider.js.map +1 -1
- package/build/ocm/components/clusterWizard/wizardTransition.js +10 -2
- package/build/ocm/components/clusterWizard/wizardTransition.js.map +1 -1
- package/build/ocm/components/clusters/ClusterPage.js +10 -4
- package/build/ocm/components/clusters/ClusterPage.js.map +1 -1
- package/build/ocm/components/featureSupportLevels/FeatureSupportLevelProvider.js +5 -2
- package/build/ocm/components/featureSupportLevels/FeatureSupportLevelProvider.js.map +1 -1
- package/build/ocm/components/fetching/fetchEvents.js +25 -4
- package/build/ocm/components/fetching/fetchEvents.js.map +1 -1
- package/build/ocm/components/newFeatureSupportLevels/NewFeatureSupportLevelProvider.js +5 -2
- package/build/ocm/components/newFeatureSupportLevels/NewFeatureSupportLevelProvider.js.map +1 -1
- package/build/ocm/hooks/useClusterCustomManifests.js +5 -3
- package/build/ocm/hooks/useClusterCustomManifests.js.map +1 -1
- package/build/ocm/hooks/useInfraEnv.js +2 -2
- package/build/ocm/hooks/useInfraEnv.js.map +1 -1
- package/build/ocm/hooks/useInfraEnvId.js +18 -3
- package/build/ocm/hooks/useInfraEnvId.js.map +1 -1
- package/build/ocm/hooks/useInfraEnvImageUrl.js +1 -1
- package/build/ocm/hooks/useInfraEnvImageUrl.js.map +1 -1
- package/build/ocm/hooks/useInfraEnvIpxeImageUrl.js +1 -1
- package/build/ocm/hooks/useInfraEnvIpxeImageUrl.js.map +1 -1
- package/build/ocm/services/ClustersService.js +2 -2
- package/build/ocm/services/ClustersService.js.map +1 -1
- package/build/ocm/services/Day2ClusterService.js +11 -20
- package/build/ocm/services/Day2ClusterService.js.map +1 -1
- package/build/ocm/services/InfraEnvIdsCacheService.js +5 -4
- package/build/ocm/services/InfraEnvIdsCacheService.js.map +1 -1
- package/build/ocm/services/InfraEnvsService.js +7 -4
- package/build/ocm/services/InfraEnvsService.js.map +1 -1
- package/build/ocm/services/apis/EventsAPI.js +13 -1
- package/build/ocm/services/apis/EventsAPI.js.map +1 -1
- package/lib/cim/components/Agent/BMCForm.tsx +2 -2
- package/lib/cim/components/ClusterDeployment/ClusterDeploymentDetails.tsx +112 -101
- package/lib/cim/components/ClusterDeployment/ClusterDeploymentDetailsStep.tsx +17 -5
- package/lib/cim/components/ClusterDeployment/ClusterDeploymentHostSelectionStep.tsx +1 -12
- package/lib/cim/components/ClusterDeployment/ClusterDeploymentHostsDiscoveryStep.tsx +1 -2
- package/lib/cim/components/ClusterDeployment/ClusterDeploymentHostsSelectionBasic.tsx +2 -10
- package/lib/cim/components/ClusterDeployment/ClusterDeploymentWizardNavigation.tsx +7 -2
- package/lib/cim/components/ClusterDeployment/ClusterDetailsFormFields.tsx +9 -2
- package/lib/cim/components/ClusterDeployment/helpers.ts +65 -15
- package/lib/cim/components/ClusterDeployment/use-networking-formik.ts +2 -2
- package/lib/cim/components/ClusterDeployment/validationSchemas.ts +0 -1
- package/lib/cim/components/Hypershift/HostedClusterWizard/NetworkStep/NetworkStep.tsx +2 -2
- package/lib/cim/components/Hypershift/HostedClusterWizard/NetworkStep/types.ts +0 -1
- package/lib/cim/components/Hypershift/modals/ManageHostsModal.tsx +1 -6
- package/lib/cim/components/Hypershift/utils/nodepool.ts +1 -1
- package/lib/cim/components/InfraEnv/InfraEnvFormPage.tsx +21 -4
- package/lib/cim/components/helpers/versions.ts +5 -0
- package/lib/cim/components/modals/AddHostModal.tsx +6 -0
- package/lib/cim/components/modals/EditProxyModal.tsx +15 -3
- package/lib/common/components/clusterConfiguration/DiscoveryImageConfigForm.tsx +18 -13
- package/lib/common/components/clusterConfiguration/DownloadIso.tsx +3 -1
- package/lib/common/components/clusterConfiguration/OpenShiftVersionSelect.tsx +4 -1
- package/lib/common/components/clusterWizard/ClusterWizardStep.tsx +5 -1
- package/lib/common/components/clusterWizard/networkingSteps/ManagedNetworkingControlGroup.tsx +11 -2
- package/lib/common/components/clusterWizard/networkingSteps/NetworkTypeControlGroup.tsx +1 -1
- package/lib/common/components/fetching/EventListFetch.tsx +31 -41
- package/lib/common/components/hosts/TableToolbar.tsx +3 -3
- package/lib/common/components/hosts/status.tsx +1 -1
- package/lib/common/components/ui/ClusterEventsToolbar.tsx +3 -0
- package/lib/common/components/ui/StaticTextField.tsx +1 -1
- package/lib/common/components/ui/eventsModal.tsx +28 -23
- package/lib/common/components/ui/formik/CodeField.tsx +1 -1
- package/lib/common/components/ui/formik/SelectField.tsx +1 -1
- package/lib/common/components/ui/formik/UploadField.tsx +2 -3
- package/lib/common/components/ui/formik/types.ts +2 -1
- package/lib/common/components/ui/formik/validationSchemas.test.ts +6 -0
- package/lib/common/components/ui/formik/validationSchemas.ts +33 -15
- package/lib/common/config/constants.ts +6 -2
- package/lib/common/types/events.ts +10 -3
- package/lib/ocm/components/AddHosts/day2Wizard/Day2ClusterDetails.tsx +129 -21
- package/lib/ocm/components/AddHosts/day2Wizard/Day2DownloadISO.tsx +1 -1
- package/lib/ocm/components/AddHosts/day2Wizard/Day2StaticIP.tsx +15 -10
- package/lib/ocm/components/AddHosts/day2Wizard/Day2Wizard.tsx +1 -0
- package/lib/ocm/components/HostsClusterDetailTab/HostsClusterDetailTabContent.tsx +7 -3
- package/lib/ocm/components/HostsClusterDetailTab/types.ts +6 -0
- package/lib/ocm/components/HostsClusterDetailTab/utils.ts +43 -37
- package/lib/ocm/components/clusterConfiguration/CpuArchitectureDropdown.tsx +6 -3
- package/lib/ocm/components/clusterConfiguration/DiscoveryImageForm.tsx +9 -1
- package/lib/ocm/components/clusterConfiguration/OcmDiscoveryImageConfigForm.tsx +25 -16
- package/lib/ocm/components/clusterConfiguration/manifestsConfiguration/components/CustomManifestsForm.tsx +69 -32
- package/lib/ocm/components/clusterConfiguration/manifestsConfiguration/components/FolderDropdown.tsx +3 -14
- package/lib/ocm/components/clusterConfiguration/manifestsConfiguration/components/customManifestsValidationSchema.tsx +59 -24
- package/lib/ocm/components/clusterConfiguration/networkConfiguration/AdvancedNetworkFields.tsx +29 -8
- package/lib/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfigurationForm.tsx +11 -2
- package/lib/ocm/components/clusterConfiguration/networkConfiguration/StackTypeControl.tsx +6 -13
- package/lib/ocm/components/clusterConfiguration/networkConfiguration/VirtualIPControlGroup.tsx +30 -32
- package/lib/ocm/components/clusterConfiguration/platformIntegration/PlatformIntegration.tsx +1 -1
- package/lib/ocm/components/clusterDetail/AssistedInstallerDetailCard.tsx +14 -2
- package/lib/ocm/components/clusterDetail/AssistedInstallerExtraDetailCard.tsx +11 -2
- package/lib/ocm/components/clusterWizard/ClusterWizardContextProvider.tsx +20 -2
- package/lib/ocm/components/clusterWizard/wizardTransition.ts +13 -1
- package/lib/ocm/components/clusters/ClusterPage.tsx +19 -5
- package/lib/ocm/components/featureSupportLevels/FeatureSupportLevelProvider.tsx +8 -2
- package/lib/ocm/components/fetching/fetchEvents.ts +31 -5
- package/lib/ocm/components/newFeatureSupportLevels/NewFeatureSupportLevelProvider.tsx +8 -2
- package/lib/ocm/hooks/useClusterCustomManifests.ts +9 -3
- package/lib/ocm/hooks/useInfraEnv.ts +10 -1
- package/lib/ocm/hooks/useInfraEnvId.ts +24 -4
- package/lib/ocm/hooks/useInfraEnvImageUrl.ts +1 -1
- package/lib/ocm/hooks/useInfraEnvIpxeImageUrl.ts +1 -1
- package/lib/ocm/services/ClustersService.ts +2 -2
- package/lib/ocm/services/Day2ClusterService.ts +12 -42
- package/lib/ocm/services/InfraEnvIdsCacheService.ts +9 -6
- package/lib/ocm/services/InfraEnvsService.ts +12 -13
- package/lib/ocm/services/apis/EventsAPI.ts +15 -1
- package/package.json +1 -1
|
@@ -31,7 +31,6 @@ import {
|
|
|
31
31
|
RadioField,
|
|
32
32
|
PopoverIcon,
|
|
33
33
|
pullSecretValidationSchema,
|
|
34
|
-
OCP_STATIC_IP_DOC,
|
|
35
34
|
CheckboxField,
|
|
36
35
|
AdditionalNTPSourcesField,
|
|
37
36
|
richNameValidationSchema,
|
|
@@ -42,6 +41,7 @@ import {
|
|
|
42
41
|
locationValidationMessages,
|
|
43
42
|
ntpSourceValidationSchema,
|
|
44
43
|
CpuArchitecture,
|
|
44
|
+
getOCPStaticIPDocLink,
|
|
45
45
|
} from '../../../common';
|
|
46
46
|
|
|
47
47
|
import './infra-env.css';
|
|
@@ -72,8 +72,16 @@ const validationSchema = (usedNames: string[], t: TFunction) =>
|
|
|
72
72
|
location: locationValidationSchema(t).required(t('ai:Location is a required field.')),
|
|
73
73
|
pullSecret: pullSecretValidationSchema.required(t('ai:Pull secret is a required field.')),
|
|
74
74
|
sshPublicKey: sshPublicKeyValidationSchema,
|
|
75
|
-
httpProxy: httpProxyValidationSchema(
|
|
76
|
-
|
|
75
|
+
httpProxy: httpProxyValidationSchema({
|
|
76
|
+
values,
|
|
77
|
+
pairValueName: 'httpsProxy',
|
|
78
|
+
allowEmpty: true,
|
|
79
|
+
}),
|
|
80
|
+
httpsProxy: httpProxyValidationSchema({
|
|
81
|
+
values,
|
|
82
|
+
pairValueName: 'httpProxy',
|
|
83
|
+
allowEmpty: true,
|
|
84
|
+
}), // share the schema, httpS is currently not supported
|
|
77
85
|
noProxy: noProxyValidationSchema,
|
|
78
86
|
labels: Yup.array()
|
|
79
87
|
.of(Yup.string())
|
|
@@ -110,6 +118,7 @@ type InfraEnvFormProps = {
|
|
|
110
118
|
onValuesChanged?: (values: EnvironmentStepFormValues) => void;
|
|
111
119
|
pullSecret?: string;
|
|
112
120
|
sshPublicKey?: string;
|
|
121
|
+
docVersion: string;
|
|
113
122
|
};
|
|
114
123
|
|
|
115
124
|
const InfraEnvForm: React.FC<InfraEnvFormProps> = ({
|
|
@@ -117,6 +126,7 @@ const InfraEnvForm: React.FC<InfraEnvFormProps> = ({
|
|
|
117
126
|
children,
|
|
118
127
|
pullSecret,
|
|
119
128
|
sshPublicKey,
|
|
129
|
+
docVersion,
|
|
120
130
|
}) => {
|
|
121
131
|
const { values, setFieldValue } = useFormikContext<EnvironmentStepFormValues>();
|
|
122
132
|
const { t } = useTranslation();
|
|
@@ -186,7 +196,13 @@ const InfraEnvForm: React.FC<InfraEnvFormProps> = ({
|
|
|
186
196
|
icon={<ExternalLinkAltIcon />}
|
|
187
197
|
iconPosition="right"
|
|
188
198
|
isInline
|
|
189
|
-
onClick={() =>
|
|
199
|
+
onClick={() =>
|
|
200
|
+
window.open(
|
|
201
|
+
getOCPStaticIPDocLink(docVersion),
|
|
202
|
+
'_blank',
|
|
203
|
+
'noopener',
|
|
204
|
+
)
|
|
205
|
+
}
|
|
190
206
|
>
|
|
191
207
|
{t('ai:View documentation')}
|
|
192
208
|
</Button>
|
|
@@ -274,6 +290,7 @@ type InfraEnvFormPageProps = InfraEnvFormProps & {
|
|
|
274
290
|
formRef: React.Ref<FormikProps<EnvironmentStepFormValues>>;
|
|
275
291
|
pullSecret?: string;
|
|
276
292
|
sshPublicKey?: string;
|
|
293
|
+
docVersion: string;
|
|
277
294
|
};
|
|
278
295
|
|
|
279
296
|
export const InfraEnvFormPage: React.FC<InfraEnvFormPageProps> = ({
|
|
@@ -80,3 +80,8 @@ export const getMajorMinorVersion = (version = '') => {
|
|
|
80
80
|
const match = /[0-9].[0-9][0-9]?/g.exec(version);
|
|
81
81
|
return match?.[0] || '';
|
|
82
82
|
};
|
|
83
|
+
|
|
84
|
+
export const getNetworkType = (
|
|
85
|
+
ocpVersion: OpenshiftVersionOptionType | undefined,
|
|
86
|
+
): 'OVNKubernetes' | 'OpenShiftSDN' =>
|
|
87
|
+
parseFloat(getMajorMinorVersion(ocpVersion?.version)) >= 4.12 ? 'OVNKubernetes' : 'OpenShiftSDN';
|
|
@@ -73,6 +73,8 @@ const AddHostModal: React.FC<AddHostModalProps> = ({
|
|
|
73
73
|
noProxy={noProxy}
|
|
74
74
|
hasDHCP={hasDHCP}
|
|
75
75
|
isIPXE={isIPXE}
|
|
76
|
+
allowEmpty
|
|
77
|
+
docVersion={docVersion}
|
|
76
78
|
/>
|
|
77
79
|
)}
|
|
78
80
|
{dialogType === 'download' && (
|
|
@@ -89,6 +91,7 @@ const AddHostModal: React.FC<AddHostModalProps> = ({
|
|
|
89
91
|
infraEnv={infraEnv}
|
|
90
92
|
onReset={agentClusterInstall ? () => setDialogType('config') : undefined}
|
|
91
93
|
hasDHCP={hasDHCP}
|
|
94
|
+
docVersion={docVersion}
|
|
92
95
|
/>
|
|
93
96
|
)}
|
|
94
97
|
</>
|
|
@@ -103,11 +106,13 @@ const GeneratingIsoDownload = ({
|
|
|
103
106
|
onClose,
|
|
104
107
|
onReset,
|
|
105
108
|
hasDHCP,
|
|
109
|
+
docVersion,
|
|
106
110
|
}: {
|
|
107
111
|
infraEnv: InfraEnvK8sResource;
|
|
108
112
|
onClose: VoidFunction;
|
|
109
113
|
onReset?: VoidFunction;
|
|
110
114
|
hasDHCP: boolean;
|
|
115
|
+
docVersion: string;
|
|
111
116
|
}) => {
|
|
112
117
|
const { t } = useTranslation();
|
|
113
118
|
return infraEnv.status?.isoDownloadURL ? (
|
|
@@ -116,6 +121,7 @@ const GeneratingIsoDownload = ({
|
|
|
116
121
|
downloadUrl={infraEnv.status.isoDownloadURL}
|
|
117
122
|
onReset={onReset}
|
|
118
123
|
hasDHCP={hasDHCP}
|
|
124
|
+
docVersion={docVersion}
|
|
119
125
|
/>
|
|
120
126
|
) : (
|
|
121
127
|
<EmptyState>
|
|
@@ -27,8 +27,16 @@ import { getWarningMessage } from './utils';
|
|
|
27
27
|
const validationSchema = () =>
|
|
28
28
|
Yup.lazy<ProxyFieldsType>((values) =>
|
|
29
29
|
Yup.object<ProxyFieldsType>().shape({
|
|
30
|
-
httpProxy: httpProxyValidationSchema(
|
|
31
|
-
|
|
30
|
+
httpProxy: httpProxyValidationSchema({
|
|
31
|
+
values,
|
|
32
|
+
pairValueName: 'httpsProxy',
|
|
33
|
+
allowEmpty: true,
|
|
34
|
+
}),
|
|
35
|
+
httpsProxy: httpProxyValidationSchema({
|
|
36
|
+
values,
|
|
37
|
+
pairValueName: 'httpProxy',
|
|
38
|
+
allowEmpty: true,
|
|
39
|
+
}),
|
|
32
40
|
noProxy: noProxyValidationSchema,
|
|
33
41
|
}),
|
|
34
42
|
);
|
|
@@ -62,6 +70,10 @@ const EditProxyModal: React.FC<EditProxyModalProps> = ({
|
|
|
62
70
|
const { t } = useTranslation();
|
|
63
71
|
const [error, setError] = React.useState<string>();
|
|
64
72
|
const warningMsg = getWarningMessage(hasAgents, hasBMHs, t);
|
|
73
|
+
const enableProxy =
|
|
74
|
+
!!infraEnv.spec?.proxy?.httpProxy ||
|
|
75
|
+
!!infraEnv.spec?.proxy?.httpsProxy ||
|
|
76
|
+
!!infraEnv.spec?.proxy?.noProxy;
|
|
65
77
|
return (
|
|
66
78
|
<Modal
|
|
67
79
|
aria-label={t('ai:Edit proxy settings')}
|
|
@@ -76,7 +88,7 @@ const EditProxyModal: React.FC<EditProxyModalProps> = ({
|
|
|
76
88
|
httpProxy: infraEnv.spec?.proxy?.httpProxy,
|
|
77
89
|
httpsProxy: infraEnv.spec?.proxy?.httpsProxy,
|
|
78
90
|
noProxy: infraEnv.spec?.proxy?.noProxy,
|
|
79
|
-
enableProxy
|
|
91
|
+
enableProxy,
|
|
80
92
|
}}
|
|
81
93
|
validationSchema={validationSchema}
|
|
82
94
|
onSubmit={async (values: ProxyFieldsType) => {
|
|
@@ -23,10 +23,10 @@ import { ProxyFieldsType, StatusErrorType } from '../../types';
|
|
|
23
23
|
import ProxyFields from './ProxyFields';
|
|
24
24
|
import UploadSSH from './UploadSSH';
|
|
25
25
|
import DiscoveryImageTypeControlGroup from './DiscoveryImageTypeControlGroup';
|
|
26
|
-
import {
|
|
26
|
+
import { getOCPStaticIPDocLink } from '../../config/constants';
|
|
27
27
|
import { useTranslation } from '../../hooks/use-translation-wrapper';
|
|
28
28
|
|
|
29
|
-
export const StaticIPInfo:
|
|
29
|
+
export const StaticIPInfo = ({ docVersion }: { docVersion?: string }) => {
|
|
30
30
|
const { t } = useTranslation();
|
|
31
31
|
return (
|
|
32
32
|
<Alert
|
|
@@ -41,7 +41,7 @@ export const StaticIPInfo: React.FC = () => {
|
|
|
41
41
|
icon={<ExternalLinkAltIcon />}
|
|
42
42
|
iconPosition="right"
|
|
43
43
|
isInline
|
|
44
|
-
onClick={() => window.open(
|
|
44
|
+
onClick={() => window.open(getOCPStaticIPDocLink(docVersion), '_blank', 'noopener')}
|
|
45
45
|
>
|
|
46
46
|
{t('ai:View documentation')}
|
|
47
47
|
</Button>
|
|
@@ -51,14 +51,15 @@ export const StaticIPInfo: React.FC = () => {
|
|
|
51
51
|
|
|
52
52
|
export type DiscoveryImageFormValues = ImageCreateParams & ProxyFieldsType;
|
|
53
53
|
|
|
54
|
-
const
|
|
55
|
-
Yup.
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
)
|
|
54
|
+
const getValidationSchema = (allowEmpty: boolean) =>
|
|
55
|
+
Yup.lazy<DiscoveryImageFormValues>((values) =>
|
|
56
|
+
Yup.object<DiscoveryImageFormValues>().shape({
|
|
57
|
+
sshPublicKey: sshPublicKeyValidationSchema,
|
|
58
|
+
httpProxy: httpProxyValidationSchema({ values, pairValueName: 'httpsProxy', allowEmpty }),
|
|
59
|
+
httpsProxy: httpProxyValidationSchema({ values, pairValueName: 'httpProxy', allowEmpty }), // share the schema, httpS is currently not supported
|
|
60
|
+
noProxy: noProxyValidationSchema,
|
|
61
|
+
}),
|
|
62
|
+
);
|
|
62
63
|
|
|
63
64
|
type DiscoveryImageConfigFormProps = Proxy & {
|
|
64
65
|
onCancel: () => void;
|
|
@@ -71,6 +72,8 @@ type DiscoveryImageConfigFormProps = Proxy & {
|
|
|
71
72
|
sshPublicKey?: string;
|
|
72
73
|
imageType?: ImageType;
|
|
73
74
|
isIPXE?: boolean;
|
|
75
|
+
allowEmpty?: boolean;
|
|
76
|
+
docVersion: string;
|
|
74
77
|
};
|
|
75
78
|
|
|
76
79
|
export const DiscoveryImageConfigForm: React.FC<DiscoveryImageConfigFormProps> = ({
|
|
@@ -84,6 +87,8 @@ export const DiscoveryImageConfigForm: React.FC<DiscoveryImageConfigFormProps> =
|
|
|
84
87
|
hideDiscoveryImageType,
|
|
85
88
|
hasDHCP,
|
|
86
89
|
isIPXE,
|
|
90
|
+
allowEmpty,
|
|
91
|
+
docVersion,
|
|
87
92
|
}) => {
|
|
88
93
|
const initialValues: DiscoveryImageFormValues = {
|
|
89
94
|
sshPublicKey: sshPublicKey || '',
|
|
@@ -99,7 +104,7 @@ export const DiscoveryImageConfigForm: React.FC<DiscoveryImageConfigFormProps> =
|
|
|
99
104
|
<Formik
|
|
100
105
|
initialValues={initialValues}
|
|
101
106
|
initialStatus={{ error: null }}
|
|
102
|
-
validationSchema={
|
|
107
|
+
validationSchema={getValidationSchema(!!allowEmpty)}
|
|
103
108
|
onSubmit={handleSubmit}
|
|
104
109
|
>
|
|
105
110
|
{({ submitForm, isSubmitting, status }) => {
|
|
@@ -120,7 +125,7 @@ export const DiscoveryImageConfigForm: React.FC<DiscoveryImageConfigFormProps> =
|
|
|
120
125
|
</StackItem>
|
|
121
126
|
{hasDHCP === false && (
|
|
122
127
|
<StackItem>
|
|
123
|
-
<StaticIPInfo />
|
|
128
|
+
<StaticIPInfo docVersion={docVersion} />
|
|
124
129
|
</StackItem>
|
|
125
130
|
)}
|
|
126
131
|
<StackItem>
|
|
@@ -23,6 +23,7 @@ export type DownloadISOProps = {
|
|
|
23
23
|
downloadUrl?: string;
|
|
24
24
|
onClose: () => void;
|
|
25
25
|
onReset?: () => void;
|
|
26
|
+
docVersion?: string;
|
|
26
27
|
};
|
|
27
28
|
|
|
28
29
|
const DownloadIso = ({
|
|
@@ -32,6 +33,7 @@ const DownloadIso = ({
|
|
|
32
33
|
onReset,
|
|
33
34
|
hasDHCP,
|
|
34
35
|
isSNO = false,
|
|
36
|
+
docVersion,
|
|
35
37
|
}: DownloadISOProps) => {
|
|
36
38
|
const wgetCommand = `wget -O ${fileName} '${downloadUrl || ''}'`;
|
|
37
39
|
const { t } = useTranslation();
|
|
@@ -53,7 +55,7 @@ const DownloadIso = ({
|
|
|
53
55
|
</StackItem>
|
|
54
56
|
{hasDHCP === false && (
|
|
55
57
|
<StackItem>
|
|
56
|
-
<StaticIPInfo />
|
|
58
|
+
<StaticIPInfo docVersion={docVersion} />
|
|
57
59
|
</StackItem>
|
|
58
60
|
)}
|
|
59
61
|
<StackItem>
|
|
@@ -12,6 +12,7 @@ import { OPENSHIFT_LIFE_CYCLE_DATES_LINK } from '../../config';
|
|
|
12
12
|
import { OpenshiftVersionOptionType } from '../../types';
|
|
13
13
|
import { SelectField } from '../ui';
|
|
14
14
|
import { useTranslation } from '../../hooks/use-translation-wrapper';
|
|
15
|
+
import { SelectFieldProps } from '../ui/formik/types';
|
|
15
16
|
|
|
16
17
|
const OpenShiftLifeCycleDatesLink = () => {
|
|
17
18
|
const { t } = useTranslation();
|
|
@@ -54,8 +55,9 @@ const getOpenshiftVersionHelperText =
|
|
|
54
55
|
|
|
55
56
|
type OpenShiftVersionSelectProps = {
|
|
56
57
|
versions: OpenshiftVersionOptionType[];
|
|
58
|
+
onChange?: SelectFieldProps['onChange'];
|
|
57
59
|
};
|
|
58
|
-
const OpenShiftVersionSelect: React.FC<OpenShiftVersionSelectProps> = ({ versions }) => {
|
|
60
|
+
const OpenShiftVersionSelect: React.FC<OpenShiftVersionSelectProps> = ({ versions, onChange }) => {
|
|
59
61
|
const selectOptions = React.useMemo(
|
|
60
62
|
() =>
|
|
61
63
|
versions
|
|
@@ -75,6 +77,7 @@ const OpenShiftVersionSelect: React.FC<OpenShiftVersionSelectProps> = ({ version
|
|
|
75
77
|
getHelperText={getOpenshiftVersionHelperText(versions)}
|
|
76
78
|
isDisabled={versions.length === 0}
|
|
77
79
|
isRequired
|
|
80
|
+
onChange={onChange}
|
|
78
81
|
/>
|
|
79
82
|
);
|
|
80
83
|
};
|
|
@@ -10,7 +10,11 @@ type ClusterWizardStepProps = {
|
|
|
10
10
|
navigation?: React.ReactNode;
|
|
11
11
|
};
|
|
12
12
|
|
|
13
|
-
const ClusterWizardStep
|
|
13
|
+
const ClusterWizardStep = ({
|
|
14
|
+
navigation,
|
|
15
|
+
footer,
|
|
16
|
+
children,
|
|
17
|
+
}: React.PropsWithChildren<ClusterWizardStepProps>) => {
|
|
14
18
|
// activeStep is required, but we're not passing it. Using the cast to avoid TS error
|
|
15
19
|
const activeStep = undefined as unknown as WizardBodyProps['activeStep'];
|
|
16
20
|
return (
|
package/lib/common/components/clusterWizard/networkingSteps/ManagedNetworkingControlGroup.tsx
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { FormGroup, TooltipProps } from '@patternfly/react-core';
|
|
3
|
-
import { getFieldId } from '../../ui';
|
|
3
|
+
import { PopoverIcon, getFieldId } from '../../ui';
|
|
4
4
|
import RadioFieldWithTooltip from '../../ui/formik/RadioFieldWithTooltip';
|
|
5
5
|
import { useTranslation } from '../../../hooks/use-translation-wrapper';
|
|
6
6
|
|
|
@@ -47,7 +47,16 @@ export const ManagedNetworkingControlGroup = ({
|
|
|
47
47
|
name={GROUP_NAME}
|
|
48
48
|
isDisabled={disabled}
|
|
49
49
|
value={'userManaged'}
|
|
50
|
-
label={
|
|
50
|
+
label={
|
|
51
|
+
<>
|
|
52
|
+
<span>{t('ai:User-Managed Networking')}</span>{' '}
|
|
53
|
+
<PopoverIcon
|
|
54
|
+
bodyContent={
|
|
55
|
+
"With User-Managed Networking, you'll need to provide and configure a load balancer for the API and ingress endpoints."
|
|
56
|
+
}
|
|
57
|
+
/>
|
|
58
|
+
</>
|
|
59
|
+
}
|
|
51
60
|
/>
|
|
52
61
|
</FormGroup>
|
|
53
62
|
);
|
|
@@ -39,7 +39,7 @@ export const NetworkTypeControlGroup = ({
|
|
|
39
39
|
<SplitItem>
|
|
40
40
|
<PopoverIcon
|
|
41
41
|
bodyContent={t(
|
|
42
|
-
"ai:
|
|
42
|
+
"ai:OVN separates the physical network topology from the logical one and is recommended if you're using new or telco features.",
|
|
43
43
|
)}
|
|
44
44
|
buttonStyle={{ top: '-4px' }}
|
|
45
45
|
/>
|
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { AxiosResponseHeaders } from 'axios';
|
|
3
2
|
import omit from 'lodash-es/omit.js';
|
|
4
3
|
import { Pagination, PaginationVariant } from '@patternfly/react-core';
|
|
5
|
-
import {
|
|
6
|
-
import { EVENTS_POLLING_INTERVAL
|
|
4
|
+
import { EventList } from '../../api';
|
|
5
|
+
import { EVENTS_POLLING_INTERVAL } from '../../config';
|
|
7
6
|
import { ClusterEventsFiltersType, EventListFetchProps } from '../../types';
|
|
8
7
|
import { useStateSafely } from '../../hooks';
|
|
9
8
|
import { ErrorState, LoadingState } from '../ui/uiState';
|
|
@@ -20,12 +19,15 @@ const initialSeverityCounts = {
|
|
|
20
19
|
warning: 0,
|
|
21
20
|
};
|
|
22
21
|
|
|
23
|
-
export const EventListFetch = ({
|
|
24
|
-
|
|
22
|
+
export const EventListFetch = ({
|
|
23
|
+
onFetchEvents,
|
|
24
|
+
disablePagination,
|
|
25
|
+
...props
|
|
26
|
+
}: EventListFetchProps) => {
|
|
27
|
+
const { cluster, hostId, className, entityKind, setLoading } = props;
|
|
25
28
|
|
|
26
29
|
const [lastPolling, setLastPolling] = useStateSafely(0);
|
|
27
30
|
const [error, setError] = useStateSafely('');
|
|
28
|
-
const [isLoading, setLoading] = useStateSafely(true);
|
|
29
31
|
const [events, setEvents] = useStateSafely<EventList | undefined>(undefined);
|
|
30
32
|
|
|
31
33
|
const [pageNum, setPageNum] = useStateSafely(1);
|
|
@@ -53,43 +55,29 @@ export const EventListFetch = ({ onFetchEvents, ...props }: EventListFetchProps)
|
|
|
53
55
|
setPageNum(newPage);
|
|
54
56
|
};
|
|
55
57
|
|
|
56
|
-
const parseHeaders = React.useCallback(
|
|
57
|
-
(headers: AxiosResponseHeaders) => {
|
|
58
|
-
const severities: Record<Event['severity'], number> = {
|
|
59
|
-
error: 0,
|
|
60
|
-
info: 0,
|
|
61
|
-
warning: 0,
|
|
62
|
-
critical: 0,
|
|
63
|
-
};
|
|
64
|
-
EVENT_SEVERITIES.forEach((severity) => {
|
|
65
|
-
const count = Number(headers[`severity-count-${severity}`]);
|
|
66
|
-
severities[severity] = count;
|
|
67
|
-
});
|
|
68
|
-
setTotalEvents(Number(headers['event-count']));
|
|
69
|
-
setSeverityCount(severities as SeverityCountsType);
|
|
70
|
-
},
|
|
71
|
-
[setSeverityCount, setTotalEvents],
|
|
72
|
-
);
|
|
73
|
-
|
|
74
58
|
React.useEffect(() => {
|
|
75
59
|
let timer: ReturnType<typeof setTimeout>;
|
|
76
60
|
setLoading(true);
|
|
77
61
|
|
|
78
|
-
|
|
62
|
+
onFetchEvents(
|
|
79
63
|
{
|
|
80
64
|
clusterId: cluster.id,
|
|
81
65
|
...omit(filters, 'selectAll'),
|
|
82
66
|
offset: perPage * (pageNum - 1),
|
|
83
67
|
limit: perPage,
|
|
84
68
|
},
|
|
85
|
-
({ data: newEvents,
|
|
69
|
+
({ data: newEvents, severities, totalEvents }) => {
|
|
86
70
|
setError('');
|
|
87
71
|
setEvents(newEvents);
|
|
88
72
|
setLoading(false);
|
|
89
|
-
|
|
73
|
+
setTotalEvents(totalEvents);
|
|
74
|
+
setSeverityCount(severities);
|
|
90
75
|
timer = setTimeout(() => setLastPolling(Date.now()), EVENTS_POLLING_INTERVAL);
|
|
91
76
|
},
|
|
92
|
-
|
|
77
|
+
(err: string) => {
|
|
78
|
+
setError(err);
|
|
79
|
+
setLoading(false);
|
|
80
|
+
},
|
|
93
81
|
);
|
|
94
82
|
|
|
95
83
|
return () => clearTimeout(timer);
|
|
@@ -100,13 +88,13 @@ export const EventListFetch = ({ onFetchEvents, ...props }: EventListFetchProps)
|
|
|
100
88
|
onFetchEvents,
|
|
101
89
|
perPage,
|
|
102
90
|
pageNum,
|
|
103
|
-
parseHeaders,
|
|
104
|
-
totalEvents,
|
|
105
91
|
filters,
|
|
106
92
|
setLoading,
|
|
107
93
|
setError,
|
|
108
94
|
setEvents,
|
|
109
95
|
setLastPolling,
|
|
96
|
+
setTotalEvents,
|
|
97
|
+
setSeverityCount,
|
|
110
98
|
]);
|
|
111
99
|
|
|
112
100
|
const forceRefetch = React.useCallback(() => {
|
|
@@ -125,7 +113,7 @@ export const EventListFetch = ({ onFetchEvents, ...props }: EventListFetchProps)
|
|
|
125
113
|
eventList = <ErrorState title={error} fetchData={forceRefetch} />;
|
|
126
114
|
}
|
|
127
115
|
|
|
128
|
-
if (
|
|
116
|
+
if (!events) {
|
|
129
117
|
eventList = <LoadingState />;
|
|
130
118
|
}
|
|
131
119
|
|
|
@@ -144,16 +132,18 @@ export const EventListFetch = ({ onFetchEvents, ...props }: EventListFetchProps)
|
|
|
144
132
|
severityCounts={severityCounts}
|
|
145
133
|
/>
|
|
146
134
|
{eventList}
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
135
|
+
{!disablePagination && (
|
|
136
|
+
<Pagination
|
|
137
|
+
perPageComponent="button"
|
|
138
|
+
itemCount={totalEvents}
|
|
139
|
+
widgetId="events-pagination"
|
|
140
|
+
perPage={perPage}
|
|
141
|
+
page={pageNum}
|
|
142
|
+
variant={PaginationVariant.bottom}
|
|
143
|
+
onSetPage={onSetPage}
|
|
144
|
+
onPerPageSelect={onPerPageSelect}
|
|
145
|
+
/>
|
|
146
|
+
)}
|
|
157
147
|
</>
|
|
158
148
|
);
|
|
159
149
|
};
|
|
@@ -17,9 +17,9 @@ import {
|
|
|
17
17
|
Tooltip,
|
|
18
18
|
} from '@patternfly/react-core';
|
|
19
19
|
import { CaretDownIcon } from '@patternfly/react-icons';
|
|
20
|
+
import { useTranslation } from '../../hooks/use-translation-wrapper';
|
|
20
21
|
|
|
21
22
|
import './TableToolbar.css';
|
|
22
|
-
import { useTranslation } from '../../hooks/use-translation-wrapper';
|
|
23
23
|
|
|
24
24
|
type TableToolbarProps = {
|
|
25
25
|
itemIDs: string[];
|
|
@@ -45,6 +45,7 @@ const TableToolbar: React.FC<TableToolbarProps> = ({
|
|
|
45
45
|
children,
|
|
46
46
|
...paginationProps
|
|
47
47
|
}) => {
|
|
48
|
+
const { t } = useTranslation();
|
|
48
49
|
const [actionsOpen, setActionsOpen] = React.useState(false);
|
|
49
50
|
const [selectOpen, setSelectOpen] = React.useState(false);
|
|
50
51
|
const onSelectToggle = React.useCallback(() => setSelectOpen(!selectOpen), [selectOpen]);
|
|
@@ -75,7 +76,7 @@ const TableToolbar: React.FC<TableToolbarProps> = ({
|
|
|
75
76
|
toggleIndicator={CaretDownIcon}
|
|
76
77
|
isDisabled={isDisabled}
|
|
77
78
|
>
|
|
78
|
-
Actions
|
|
79
|
+
{t('ai:Actions')}
|
|
79
80
|
</DropdownToggle>
|
|
80
81
|
}
|
|
81
82
|
isOpen={actionsOpen}
|
|
@@ -85,7 +86,6 @@ const TableToolbar: React.FC<TableToolbarProps> = ({
|
|
|
85
86
|
|
|
86
87
|
const onSelectAll = () => setSelectedIDs(itemIDs);
|
|
87
88
|
const onSelectNone = () => setSelectedIDs([]);
|
|
88
|
-
const { t } = useTranslation();
|
|
89
89
|
return (
|
|
90
90
|
<Split hasGutter>
|
|
91
91
|
<SplitItem isFilled>
|
|
@@ -217,7 +217,7 @@ export const hostStatus: HostStatus<Host['status'] | 'finalizing'> = Object.free
|
|
|
217
217
|
category: 'Installation related',
|
|
218
218
|
icon: <ExclamationTriangleIcon color={warningColor.value} />,
|
|
219
219
|
details:
|
|
220
|
-
'Host already booted from disk during previous installation. To finish resetting the installation
|
|
220
|
+
'Host has already been booted from disk during the previous installation. To finish resetting the installation, boot the host into the discovery image',
|
|
221
221
|
},
|
|
222
222
|
finalizing: {
|
|
223
223
|
key: 'finalizing',
|
|
@@ -226,6 +226,9 @@ const ClusterEventsToolbar = ({
|
|
|
226
226
|
isOpen={isHostExpanded}
|
|
227
227
|
placeholderText={<Placeholder text="Hosts" />}
|
|
228
228
|
isDisabled={allHosts.length === 0}
|
|
229
|
+
maxHeight={280}
|
|
230
|
+
zIndex={600}
|
|
231
|
+
menuAppendTo={document.body}
|
|
229
232
|
>
|
|
230
233
|
{[
|
|
231
234
|
<SelectOption
|
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import {
|
|
3
|
+
Button,
|
|
4
|
+
Modal,
|
|
5
|
+
ButtonVariant,
|
|
6
|
+
ModalVariant,
|
|
7
|
+
ModalBoxBody,
|
|
8
|
+
Spinner,
|
|
9
|
+
Title,
|
|
10
|
+
} from '@patternfly/react-core';
|
|
3
11
|
import { ExclamationTriangleIcon } from '@patternfly/react-icons';
|
|
4
12
|
import { global_warning_color_100 as globalWarningColor100 } from '@patternfly/react-tokens';
|
|
5
13
|
import { ToolbarButton } from './Toolbar';
|
|
@@ -12,17 +20,14 @@ import ErrorState from './uiState/ErrorState';
|
|
|
12
20
|
import './EventsModal.css';
|
|
13
21
|
import { useTranslation } from '../../hooks/use-translation-wrapper';
|
|
14
22
|
import { Trans } from 'react-i18next';
|
|
23
|
+
import { useStateSafely } from '../../hooks';
|
|
15
24
|
|
|
16
|
-
type EventsModalButtonProps = React.ComponentProps<typeof Button> &
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
entityKind: EventsEntityKind;
|
|
23
|
-
title: string;
|
|
24
|
-
fallbackEventsURL?: string;
|
|
25
|
-
};
|
|
25
|
+
type EventsModalButtonProps = React.ComponentProps<typeof Button> &
|
|
26
|
+
Omit<EventsModalProps, 'onClose' | 'isOpen' | 'hostId'> & {
|
|
27
|
+
ButtonComponent?: typeof Button | typeof ToolbarButton;
|
|
28
|
+
onClick?: () => void;
|
|
29
|
+
hostId?: Event['hostId'];
|
|
30
|
+
};
|
|
26
31
|
|
|
27
32
|
export const EventsModalButton = ({
|
|
28
33
|
ButtonComponent = ToolbarButton,
|
|
@@ -34,6 +39,7 @@ export const EventsModalButton = ({
|
|
|
34
39
|
children,
|
|
35
40
|
title,
|
|
36
41
|
fallbackEventsURL,
|
|
42
|
+
disablePagination,
|
|
37
43
|
...props
|
|
38
44
|
}: EventsModalButtonProps) => {
|
|
39
45
|
const [isModalOpen, setIsModalOpen] = React.useState(false);
|
|
@@ -53,6 +59,7 @@ export const EventsModalButton = ({
|
|
|
53
59
|
entityKind={entityKind}
|
|
54
60
|
onFetchEvents={onFetchEvents}
|
|
55
61
|
fallbackEventsURL={fallbackEventsURL}
|
|
62
|
+
disablePagination={disablePagination}
|
|
56
63
|
/>
|
|
57
64
|
</>
|
|
58
65
|
);
|
|
@@ -67,22 +74,26 @@ type EventsModalProps = {
|
|
|
67
74
|
isOpen: boolean;
|
|
68
75
|
title: string;
|
|
69
76
|
fallbackEventsURL?: string;
|
|
77
|
+
disablePagination?: boolean;
|
|
70
78
|
};
|
|
71
79
|
|
|
72
80
|
export const EventsModal = ({
|
|
73
|
-
onFetchEvents,
|
|
74
|
-
hostId,
|
|
75
|
-
cluster,
|
|
76
|
-
entityKind,
|
|
77
81
|
onClose,
|
|
78
82
|
isOpen,
|
|
79
83
|
title,
|
|
80
84
|
fallbackEventsURL,
|
|
85
|
+
...rest
|
|
81
86
|
}: EventsModalProps) => {
|
|
82
87
|
const { t } = useTranslation();
|
|
88
|
+
const [isLoading, setLoading] = useStateSafely(true);
|
|
89
|
+
|
|
83
90
|
return (
|
|
84
91
|
<Modal
|
|
85
|
-
|
|
92
|
+
header={
|
|
93
|
+
<Title headingLevel={'h1'}>
|
|
94
|
+
{title} {isLoading && <Spinner isSVG size="lg" />}
|
|
95
|
+
</Title>
|
|
96
|
+
}
|
|
86
97
|
isOpen={isOpen}
|
|
87
98
|
aria-label={t('ai:Displays events')}
|
|
88
99
|
hasNoBodyWrapper
|
|
@@ -111,13 +122,7 @@ export const EventsModal = ({
|
|
|
111
122
|
iconColor={globalWarningColor100.value}
|
|
112
123
|
/>
|
|
113
124
|
) : (
|
|
114
|
-
<EventListFetch
|
|
115
|
-
hostId={hostId}
|
|
116
|
-
cluster={cluster}
|
|
117
|
-
entityKind={entityKind}
|
|
118
|
-
onFetchEvents={onFetchEvents}
|
|
119
|
-
className="events-modal__event-list"
|
|
120
|
-
/>
|
|
125
|
+
<EventListFetch className="events-modal__event-list" setLoading={setLoading} {...rest} />
|
|
121
126
|
)}
|
|
122
127
|
</ModalBoxBody>
|
|
123
128
|
</Modal>
|
|
@@ -49,7 +49,7 @@ const SelectField: React.FC<SelectFieldProps> = ({
|
|
|
49
49
|
onChange={(value, event) => {
|
|
50
50
|
//customHandleChange enables calling formik change handler explicitly, useful for example to have the previous value
|
|
51
51
|
callFormikOnChange && field.onChange(event);
|
|
52
|
-
onChange && onChange(event);
|
|
52
|
+
onChange && onChange(value, event);
|
|
53
53
|
}}
|
|
54
54
|
>
|
|
55
55
|
{options.map((option, index) => (
|