@openshift-assisted/ui-lib 5.0.0-cim → 5.0.1-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.
Files changed (382) hide show
  1. package/build/@types/cim/components/ClusterDeployment/ClusterDeploymentWizard.d.ts +1 -1
  2. package/build/@types/cim/components/ClusterDeployment/ClusterDeploymentWizard.d.ts.map +1 -1
  3. package/build/@types/cim/components/ClusterDeployment/clusterDetails/ACMClusterDeploymentDetailsStep.d.ts.map +1 -1
  4. package/build/@types/cim/components/ClusterDeployment/clusterDetails/ClusterDeploymentDetailsStep.d.ts +0 -17
  5. package/build/@types/cim/components/ClusterDeployment/clusterDetails/ClusterDeploymentDetailsStep.d.ts.map +1 -1
  6. package/build/@types/cim/components/ClusterDeployment/clusterDetails/ClusterDetailsFormFields.d.ts.map +1 -1
  7. package/build/@types/cim/components/ClusterDeployment/clusterDetails/useDetailsFormik.d.ts +19 -0
  8. package/build/@types/cim/components/ClusterDeployment/clusterDetails/useDetailsFormik.d.ts.map +1 -0
  9. package/build/@types/cim/components/ClusterDeployment/review/ClusterDeploymentReviewStep.d.ts.map +1 -1
  10. package/build/@types/cim/components/ClusterDeployment/types.d.ts +0 -1
  11. package/build/@types/cim/components/ClusterDeployment/types.d.ts.map +1 -1
  12. package/build/@types/cim/components/ClusterDeployment/wizardTransition.d.ts +1 -1
  13. package/build/@types/cim/components/ClusterDeployment/wizardTransition.d.ts.map +1 -1
  14. package/build/@types/cim/components/common/CpuArchitectureDropdown.d.ts.map +1 -1
  15. package/build/@types/cim/components/helpers/clusterDeployment.d.ts.map +1 -1
  16. package/build/@types/cim/components/modals/CimConfiguration/CimStorageMissingAlert.d.ts.map +1 -1
  17. package/build/@types/cim/components/modals/CimConfiguration/constants.d.ts +1 -1
  18. package/build/@types/cim/hooks/index.d.ts +1 -0
  19. package/build/@types/cim/hooks/index.d.ts.map +1 -1
  20. package/build/@types/cim/hooks/useAgents.d.ts +4 -0
  21. package/build/@types/cim/hooks/useAgents.d.ts.map +1 -0
  22. package/build/@types/common/components/clusterConfiguration/DiskEncryptionFields/DiskEncryptionControlGroup.d.ts +2 -1
  23. package/build/@types/common/components/clusterConfiguration/DiskEncryptionFields/DiskEncryptionControlGroup.d.ts.map +1 -1
  24. package/build/@types/common/components/clusterConfiguration/ExternalPlatformsDropdown.d.ts.map +1 -1
  25. package/build/@types/common/components/clusterConfiguration/utils.d.ts +9 -1
  26. package/build/@types/common/components/clusterConfiguration/utils.d.ts.map +1 -1
  27. package/build/@types/common/components/clusterDetail/ClusterCredentials.d.ts.map +1 -1
  28. package/build/@types/common/components/clusterDetail/ConsoleModal.d.ts +0 -5
  29. package/build/@types/common/components/clusterDetail/ConsoleModal.d.ts.map +1 -1
  30. package/build/@types/common/components/clusterWizard/ReviewValidations.d.ts.map +1 -1
  31. package/build/@types/common/components/clusterWizard/clusterDetailsValidation.d.ts.map +1 -1
  32. package/build/@types/common/components/clusterWizard/networkingSteps/AvailableSubnetsControl.d.ts.map +1 -1
  33. package/build/@types/common/components/clusterWizard/networkingSteps/StackTypeControlGroup.d.ts.map +1 -1
  34. package/build/@types/common/components/clusterWizard/validationsInfoUtils.d.ts +0 -1
  35. package/build/@types/common/components/clusterWizard/validationsInfoUtils.d.ts.map +1 -1
  36. package/build/@types/common/components/hosts/utils.d.ts.map +1 -1
  37. package/build/@types/common/config/constants.d.ts.map +1 -1
  38. package/build/@types/common/selectors/clusterSelectors.d.ts +1 -1
  39. package/build/@types/common/selectors/clusterSelectors.d.ts.map +1 -1
  40. package/build/@types/common/types/clusters.d.ts +2 -2
  41. package/build/@types/common/types/clusters.d.ts.map +1 -1
  42. package/build/@types/ocm/components/Routes.d.ts +1 -1
  43. package/build/@types/ocm/components/Routes.d.ts.map +1 -1
  44. package/build/@types/ocm/components/clusterConfiguration/DiscoveryImageForm.d.ts.map +1 -1
  45. package/build/@types/ocm/components/clusterConfiguration/DiscoveryImageModal.d.ts +0 -1
  46. package/build/@types/ocm/components/clusterConfiguration/DiscoveryImageModal.d.ts.map +1 -1
  47. package/build/@types/ocm/components/clusterConfiguration/OcmClusterDetailsFormFields.d.ts.map +1 -1
  48. package/build/@types/ocm/components/clusterConfiguration/manifestsConfiguration/CustomManifestsPage.d.ts.map +1 -1
  49. package/build/@types/ocm/components/clusterConfiguration/manifestsConfiguration/components/CustomManifestsForm.d.ts.map +1 -1
  50. package/build/@types/ocm/components/clusterConfiguration/manifestsConfiguration/components/utils.d.ts +4 -0
  51. package/build/@types/ocm/components/clusterConfiguration/manifestsConfiguration/components/utils.d.ts.map +1 -1
  52. package/build/@types/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfiguration.d.ts.map +1 -1
  53. package/build/@types/ocm/components/clusterConfiguration/networkConfiguration/networkConfigurationValidation.d.ts.map +1 -1
  54. package/build/@types/ocm/components/clusterConfiguration/operators/OperatorCheckbox.d.ts +3 -1
  55. package/build/@types/ocm/components/clusterConfiguration/operators/OperatorCheckbox.d.ts.map +1 -1
  56. package/build/@types/ocm/components/clusterConfiguration/operators/bundleSpecs.d.ts.map +1 -1
  57. package/build/@types/ocm/components/clusterConfiguration/operators/utils.d.ts +3 -6
  58. package/build/@types/ocm/components/clusterConfiguration/operators/utils.d.ts.map +1 -1
  59. package/build/@types/ocm/components/clusterConfiguration/review/ReviewNetworkingTable.d.ts.map +1 -1
  60. package/build/@types/ocm/components/clusterConfiguration/review/ReviewOperatorsTable.d.ts.map +1 -1
  61. package/build/@types/ocm/components/clusterConfiguration/review/ReviewSummary.d.ts.map +1 -1
  62. package/build/@types/ocm/components/clusterConfiguration/review/TableSummaryExpandable.d.ts +1 -0
  63. package/build/@types/ocm/components/clusterConfiguration/review/TableSummaryExpandable.d.ts.map +1 -1
  64. package/build/@types/ocm/components/clusterConfiguration/review/utils.d.ts +1 -1
  65. package/build/@types/ocm/components/clusterConfiguration/review/utils.d.ts.map +1 -1
  66. package/build/@types/ocm/components/clusterConfiguration/staticIp/components/StaticIpForm.d.ts.map +1 -1
  67. package/build/@types/ocm/components/clusterConfiguration/staticIp/components/StaticIpPage.d.ts.map +1 -1
  68. package/build/@types/ocm/components/clusterConfiguration/staticIp/data/formDataToInfraEnvField.d.ts.map +1 -1
  69. package/build/@types/ocm/components/clusterConfiguration/staticIp/data/nmstateTypes.d.ts +1 -0
  70. package/build/@types/ocm/components/clusterConfiguration/staticIp/data/nmstateTypes.d.ts.map +1 -1
  71. package/build/@types/ocm/components/clusterConfiguration/staticIp/data/nmstateYaml.d.ts +1 -1
  72. package/build/@types/ocm/components/clusterConfiguration/staticIp/data/nmstateYaml.d.ts.map +1 -1
  73. package/build/@types/ocm/components/clusterDetail/AssistedInstallerDetailCard.d.ts +1 -1
  74. package/build/@types/ocm/components/clusterDetail/AssistedInstallerDetailCard.d.ts.map +1 -1
  75. package/build/@types/ocm/components/clusterDetail/ClusterDetailsButtonGroup.d.ts.map +1 -1
  76. package/build/@types/ocm/components/clusterWizard/ClusterDetails.d.ts.map +1 -1
  77. package/build/@types/ocm/components/clusterWizard/ClusterWizardContextProvider.d.ts.map +1 -1
  78. package/build/@types/ocm/components/clusterWizard/NewClusterWizard.d.ts.map +1 -1
  79. package/build/@types/ocm/components/clusterWizard/Operators.d.ts.map +1 -1
  80. package/build/@types/ocm/components/clusterWizard/OperatorsBundle.d.ts +3 -3
  81. package/build/@types/ocm/components/clusterWizard/OperatorsBundle.d.ts.map +1 -1
  82. package/build/@types/ocm/components/clusterWizard/OperatorsSelect.d.ts.map +1 -1
  83. package/build/@types/ocm/components/clusterWizard/OptionalOperatorsDropdown.d.ts +13 -0
  84. package/build/@types/ocm/components/clusterWizard/OptionalOperatorsDropdown.d.ts.map +1 -0
  85. package/build/@types/ocm/components/clusterWizard/wizardTransition.d.ts +3 -4
  86. package/build/@types/ocm/components/clusterWizard/wizardTransition.d.ts.map +1 -1
  87. package/build/@types/ocm/components/clusters/ClustersListToolbar.d.ts +1 -2
  88. package/build/@types/ocm/components/clusters/ClustersListToolbar.d.ts.map +1 -1
  89. package/build/@types/ocm/components/clusters/ClustersTable.d.ts.map +1 -1
  90. package/build/@types/ocm/components/ui/Buttons/BackButton.d.ts +1 -1
  91. package/build/@types/ocm/components/ui/Buttons/BackButton.d.ts.map +1 -1
  92. package/build/@types/ocm/hooks/useLateBinding.d.ts.map +1 -1
  93. package/build/@types/ocm/services/InfraEnvsService.d.ts.map +1 -1
  94. package/build/@types/ocm/store/hooks.d.ts +1 -1
  95. package/build/@types/ocm/store/slices/clusters/selectors.d.ts +5 -61
  96. package/build/@types/ocm/store/slices/clusters/selectors.d.ts.map +1 -1
  97. package/build/@types/ocm/store/slices/current-cluster/slice.d.ts +2 -0
  98. package/build/@types/ocm/store/slices/current-cluster/slice.d.ts.map +1 -1
  99. package/build/@types/ocm/store/slices/feature-flags/selectors.d.ts +2 -20
  100. package/build/@types/ocm/store/slices/feature-flags/selectors.d.ts.map +1 -1
  101. package/build/@types/ocm/store/slices/infra-envs/selectors.d.ts +4 -21
  102. package/build/@types/ocm/store/slices/infra-envs/selectors.d.ts.map +1 -1
  103. package/build/cjs/cim/components/Agent/NoAgentsAlert.js +2 -2
  104. package/build/cjs/cim/components/Agent/NoAgentsAlert.js.map +1 -1
  105. package/build/cjs/cim/components/Agent/tableColumns.js +3 -3
  106. package/build/cjs/cim/components/Agent/tableColumns.js.map +1 -1
  107. package/build/cjs/cim/components/ClusterDeployment/ClusterDeploymentWizard.js +9 -1
  108. package/build/cjs/cim/components/ClusterDeployment/ClusterDeploymentWizard.js.map +1 -1
  109. package/build/cjs/cim/components/ClusterDeployment/clusterDetails/ACMClusterDeploymentDetailsStep.js +4 -2
  110. package/build/cjs/cim/components/ClusterDeployment/clusterDetails/ACMClusterDeploymentDetailsStep.js.map +1 -1
  111. package/build/cjs/cim/components/ClusterDeployment/clusterDetails/ClusterDeploymentDetailsStep.js +5 -31
  112. package/build/cjs/cim/components/ClusterDeployment/clusterDetails/ClusterDeploymentDetailsStep.js.map +1 -1
  113. package/build/cjs/cim/components/ClusterDeployment/clusterDetails/ClusterDetailsFormFields.js +1 -11
  114. package/build/cjs/cim/components/ClusterDeployment/clusterDetails/ClusterDetailsFormFields.js.map +1 -1
  115. package/build/cjs/cim/components/ClusterDeployment/clusterDetails/useDetailsFormik.js +41 -0
  116. package/build/cjs/cim/components/ClusterDeployment/clusterDetails/useDetailsFormik.js.map +1 -0
  117. package/build/cjs/cim/components/ClusterDeployment/review/ClusterDeploymentReviewStep.js +4 -4
  118. package/build/cjs/cim/components/ClusterDeployment/review/ClusterDeploymentReviewStep.js.map +1 -1
  119. package/build/cjs/cim/components/ClusterDeployment/wizardTransition.js +5 -1
  120. package/build/cjs/cim/components/ClusterDeployment/wizardTransition.js.map +1 -1
  121. package/build/cjs/cim/components/Hypershift/DetailsPage/NodePoolsTable.js +2 -2
  122. package/build/cjs/cim/components/Hypershift/DetailsPage/NodePoolsTable.js.map +1 -1
  123. package/build/cjs/cim/components/InfraEnv/AddHostDropdown.js +2 -2
  124. package/build/cjs/cim/components/InfraEnv/AddHostDropdown.js.map +1 -1
  125. package/build/cjs/cim/components/common/CpuArchitectureDropdown.js +1 -1
  126. package/build/cjs/cim/components/common/CpuArchitectureDropdown.js.map +1 -1
  127. package/build/cjs/cim/components/helpers/clusterDeployment.js +14 -10
  128. package/build/cjs/cim/components/helpers/clusterDeployment.js.map +1 -1
  129. package/build/cjs/cim/components/modals/CimConfiguration/CimConfigProgressAlert.js +3 -3
  130. package/build/cjs/cim/components/modals/CimConfiguration/CimConfigProgressAlert.js.map +1 -1
  131. package/build/cjs/cim/components/modals/CimConfiguration/CimConfigurationFormFields.js +1 -1
  132. package/build/cjs/cim/components/modals/CimConfiguration/CimConfigurationFormFields.js.map +1 -1
  133. package/build/cjs/cim/components/modals/CimConfiguration/CimConfigurationModal.js +2 -2
  134. package/build/cjs/cim/components/modals/CimConfiguration/CimConfigurationModal.js.map +1 -1
  135. package/build/cjs/cim/components/modals/CimConfiguration/CimStorageMissingAlert.js +3 -3
  136. package/build/cjs/cim/components/modals/CimConfiguration/CimStorageMissingAlert.js.map +1 -1
  137. package/build/cjs/cim/components/modals/CimConfiguration/constants.js +1 -1
  138. package/build/cjs/cim/components/modals/MassDeleteAgentModal.js +2 -2
  139. package/build/cjs/cim/components/modals/MassDeleteAgentModal.js.map +1 -1
  140. package/build/cjs/cim/hooks/index.js +1 -0
  141. package/build/cjs/cim/hooks/index.js.map +1 -1
  142. package/build/cjs/cim/hooks/useAgents.js +13 -0
  143. package/build/cjs/cim/hooks/useAgents.js.map +1 -0
  144. package/build/cjs/common/components/clusterConfiguration/DiskEncryptionFields/DiskEncryptionControlGroup.js +9 -3
  145. package/build/cjs/common/components/clusterConfiguration/DiskEncryptionFields/DiskEncryptionControlGroup.js.map +1 -1
  146. package/build/cjs/common/components/clusterConfiguration/ExternalPlatformsDropdown.js +1 -1
  147. package/build/cjs/common/components/clusterConfiguration/ExternalPlatformsDropdown.js.map +1 -1
  148. package/build/cjs/common/components/clusterConfiguration/utils.js +13 -1
  149. package/build/cjs/common/components/clusterConfiguration/utils.js.map +1 -1
  150. package/build/cjs/common/components/clusterConfiguration/utils.test.js +36 -0
  151. package/build/cjs/common/components/clusterConfiguration/utils.test.js.map +1 -1
  152. package/build/cjs/common/components/clusterDetail/ClusterCredentials.js +10 -9
  153. package/build/cjs/common/components/clusterDetail/ClusterCredentials.js.map +1 -1
  154. package/build/cjs/common/components/clusterDetail/ConsoleModal.js +1 -10
  155. package/build/cjs/common/components/clusterDetail/ConsoleModal.js.map +1 -1
  156. package/build/cjs/common/components/clusterWizard/ReviewValidations.js +16 -0
  157. package/build/cjs/common/components/clusterWizard/ReviewValidations.js.map +1 -1
  158. package/build/cjs/common/components/clusterWizard/clusterDetailsValidation.js +34 -19
  159. package/build/cjs/common/components/clusterWizard/clusterDetailsValidation.js.map +1 -1
  160. package/build/cjs/common/components/clusterWizard/networkingSteps/AvailableSubnetsControl.js +29 -31
  161. package/build/cjs/common/components/clusterWizard/networkingSteps/AvailableSubnetsControl.js.map +1 -1
  162. package/build/cjs/common/components/clusterWizard/networkingSteps/ManagedNetworkingControlGroup.js +3 -3
  163. package/build/cjs/common/components/clusterWizard/networkingSteps/StackTypeControlGroup.js +19 -30
  164. package/build/cjs/common/components/clusterWizard/networkingSteps/StackTypeControlGroup.js.map +1 -1
  165. package/build/cjs/common/components/clusterWizard/validationsInfoUtils.js +1 -17
  166. package/build/cjs/common/components/clusterWizard/validationsInfoUtils.js.map +1 -1
  167. package/build/cjs/common/components/hosts/utils.js +6 -1
  168. package/build/cjs/common/components/hosts/utils.js.map +1 -1
  169. package/build/cjs/common/config/constants.js +4 -0
  170. package/build/cjs/common/config/constants.js.map +1 -1
  171. package/build/cjs/common/selectors/clusterSelectors.js +7 -8
  172. package/build/cjs/common/selectors/clusterSelectors.js.map +1 -1
  173. package/build/cjs/common/types/clusters.js.map +1 -1
  174. package/build/cjs/common/validationSchemas/addressValidation.js +1 -1
  175. package/build/cjs/common/validationSchemas/addressValidation.js.map +1 -1
  176. package/build/cjs/ocm/components/Routes.js +8 -8
  177. package/build/cjs/ocm/components/Routes.js.map +1 -1
  178. package/build/cjs/ocm/components/clusterConfiguration/DiscoveryImageForm.js +5 -2
  179. package/build/cjs/ocm/components/clusterConfiguration/DiscoveryImageForm.js.map +1 -1
  180. package/build/cjs/ocm/components/clusterConfiguration/DiscoveryImageModal.js +2 -2
  181. package/build/cjs/ocm/components/clusterConfiguration/DiscoveryImageModal.js.map +1 -1
  182. package/build/cjs/ocm/components/clusterConfiguration/OcmClusterDetailsFormFields.js +6 -2
  183. package/build/cjs/ocm/components/clusterConfiguration/OcmClusterDetailsFormFields.js.map +1 -1
  184. package/build/cjs/ocm/components/clusterConfiguration/OcmClusterProgressItems.js +1 -1
  185. package/build/cjs/ocm/components/clusterConfiguration/OcmClusterProgressItems.js.map +1 -1
  186. package/build/cjs/ocm/components/clusterConfiguration/OcmDiscoveryImageConfigForm.js +1 -1
  187. package/build/cjs/ocm/components/clusterConfiguration/OcmDiscoveryImageConfigForm.js.map +1 -1
  188. package/build/cjs/ocm/components/clusterConfiguration/manifestsConfiguration/CustomManifestsPage.js +3 -1
  189. package/build/cjs/ocm/components/clusterConfiguration/manifestsConfiguration/CustomManifestsPage.js.map +1 -1
  190. package/build/cjs/ocm/components/clusterConfiguration/manifestsConfiguration/components/CustomManifestsForm.js +3 -1
  191. package/build/cjs/ocm/components/clusterConfiguration/manifestsConfiguration/components/CustomManifestsForm.js.map +1 -1
  192. package/build/cjs/ocm/components/clusterConfiguration/manifestsConfiguration/components/utils.js +11 -8
  193. package/build/cjs/ocm/components/clusterConfiguration/manifestsConfiguration/components/utils.js.map +1 -1
  194. package/build/cjs/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfiguration.js +68 -17
  195. package/build/cjs/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfiguration.js.map +1 -1
  196. package/build/cjs/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfigurationForm.js +1 -1
  197. package/build/cjs/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfigurationForm.js.map +1 -1
  198. package/build/cjs/ocm/components/clusterConfiguration/networkConfiguration/networkConfigurationValidation.js +50 -13
  199. package/build/cjs/ocm/components/clusterConfiguration/networkConfiguration/networkConfigurationValidation.js.map +1 -1
  200. package/build/cjs/ocm/components/clusterConfiguration/operators/OperatorCheckbox.js +39 -21
  201. package/build/cjs/ocm/components/clusterConfiguration/operators/OperatorCheckbox.js.map +1 -1
  202. package/build/cjs/ocm/components/clusterConfiguration/operators/bundleSpecs.js +1 -2
  203. package/build/cjs/ocm/components/clusterConfiguration/operators/bundleSpecs.js.map +1 -1
  204. package/build/cjs/ocm/components/clusterConfiguration/operators/utils.js +7 -25
  205. package/build/cjs/ocm/components/clusterConfiguration/operators/utils.js.map +1 -1
  206. package/build/cjs/ocm/components/clusterConfiguration/review/ReviewNetworkingTable.js +4 -2
  207. package/build/cjs/ocm/components/clusterConfiguration/review/ReviewNetworkingTable.js.map +1 -1
  208. package/build/cjs/ocm/components/clusterConfiguration/review/ReviewOperatorsTable.js +75 -20
  209. package/build/cjs/ocm/components/clusterConfiguration/review/ReviewOperatorsTable.js.map +1 -1
  210. package/build/cjs/ocm/components/clusterConfiguration/review/ReviewSummary.js +2 -2
  211. package/build/cjs/ocm/components/clusterConfiguration/review/ReviewSummary.js.map +1 -1
  212. package/build/cjs/ocm/components/clusterConfiguration/review/TableSummaryExpandable.css +3 -0
  213. package/build/cjs/ocm/components/clusterConfiguration/review/TableSummaryExpandable.js +2 -3
  214. package/build/cjs/ocm/components/clusterConfiguration/review/TableSummaryExpandable.js.map +1 -1
  215. package/build/cjs/ocm/components/clusterConfiguration/review/utils.js +8 -2
  216. package/build/cjs/ocm/components/clusterConfiguration/review/utils.js.map +1 -1
  217. package/build/cjs/ocm/components/clusterConfiguration/review/utils.test.js +35 -0
  218. package/build/cjs/ocm/components/clusterConfiguration/review/utils.test.js.map +1 -1
  219. package/build/cjs/ocm/components/clusterConfiguration/staticIp/components/StaticIpForm.js +10 -1
  220. package/build/cjs/ocm/components/clusterConfiguration/staticIp/components/StaticIpForm.js.map +1 -1
  221. package/build/cjs/ocm/components/clusterConfiguration/staticIp/components/StaticIpPage.js +5 -5
  222. package/build/cjs/ocm/components/clusterConfiguration/staticIp/components/StaticIpPage.js.map +1 -1
  223. package/build/cjs/ocm/components/clusterConfiguration/staticIp/data/formDataToInfraEnvField.js +2 -2
  224. package/build/cjs/ocm/components/clusterConfiguration/staticIp/data/formDataToInfraEnvField.js.map +1 -1
  225. package/build/cjs/ocm/components/clusterConfiguration/staticIp/data/nmstateTypes.js.map +1 -1
  226. package/build/cjs/ocm/components/clusterConfiguration/staticIp/data/nmstateYaml.js +3 -7
  227. package/build/cjs/ocm/components/clusterConfiguration/staticIp/data/nmstateYaml.js.map +1 -1
  228. package/build/cjs/ocm/components/clusterDetail/AssistedInstallerDetailCard.js +4 -4
  229. package/build/cjs/ocm/components/clusterDetail/AssistedInstallerDetailCard.js.map +1 -1
  230. package/build/cjs/ocm/components/clusterDetail/ClusterDetail.js +4 -4
  231. package/build/cjs/ocm/components/clusterDetail/ClusterDetail.js.map +1 -1
  232. package/build/cjs/ocm/components/clusterDetail/ClusterDetailsButtonGroup.js +8 -2
  233. package/build/cjs/ocm/components/clusterDetail/ClusterDetailsButtonGroup.js.map +1 -1
  234. package/build/cjs/ocm/components/clusterWizard/ClusterDetails.js +6 -13
  235. package/build/cjs/ocm/components/clusterWizard/ClusterDetails.js.map +1 -1
  236. package/build/cjs/ocm/components/clusterWizard/ClusterDetailsForm.js +2 -2
  237. package/build/cjs/ocm/components/clusterWizard/ClusterDetailsForm.js.map +1 -1
  238. package/build/cjs/ocm/components/clusterWizard/ClusterWizardContextProvider.js +6 -6
  239. package/build/cjs/ocm/components/clusterWizard/ClusterWizardContextProvider.js.map +1 -1
  240. package/build/cjs/ocm/components/clusterWizard/ClusterWizardFooter.js +2 -2
  241. package/build/cjs/ocm/components/clusterWizard/ClusterWizardFooter.js.map +1 -1
  242. package/build/cjs/ocm/components/clusterWizard/NewClusterWizard.js +6 -3
  243. package/build/cjs/ocm/components/clusterWizard/NewClusterWizard.js.map +1 -1
  244. package/build/cjs/ocm/components/clusterWizard/Operators.js +40 -12
  245. package/build/cjs/ocm/components/clusterWizard/Operators.js.map +1 -1
  246. package/build/cjs/ocm/components/clusterWizard/OperatorsBundle.js +34 -15
  247. package/build/cjs/ocm/components/clusterWizard/OperatorsBundle.js.map +1 -1
  248. package/build/cjs/ocm/components/clusterWizard/OperatorsSelect.js +18 -4
  249. package/build/cjs/ocm/components/clusterWizard/OperatorsSelect.js.map +1 -1
  250. package/build/cjs/ocm/components/clusterWizard/OperatorsSelect.test.js +11 -5
  251. package/build/cjs/ocm/components/clusterWizard/OperatorsSelect.test.js.map +1 -1
  252. package/build/cjs/ocm/components/clusterWizard/OperatorsStep.js +1 -1
  253. package/build/cjs/ocm/components/clusterWizard/OperatorsStep.js.map +1 -1
  254. package/build/cjs/ocm/components/clusterWizard/OptionalOperatorsDropdown.js +34 -0
  255. package/build/cjs/ocm/components/clusterWizard/OptionalOperatorsDropdown.js.map +1 -0
  256. package/build/cjs/ocm/components/clusterWizard/disconnected/ReviewStep.js +3 -3
  257. package/build/cjs/ocm/components/clusterWizard/disconnected/ReviewStep.js.map +1 -1
  258. package/build/cjs/ocm/components/clusterWizard/wizardTransition.js +69 -29
  259. package/build/cjs/ocm/components/clusterWizard/wizardTransition.js.map +1 -1
  260. package/build/cjs/ocm/components/clusters/ClusterBreadcrumbs.js +2 -2
  261. package/build/cjs/ocm/components/clusters/ClusterBreadcrumbs.js.map +1 -1
  262. package/build/cjs/ocm/components/clusters/ClusterPage.js +4 -4
  263. package/build/cjs/ocm/components/clusters/ClusterPage.js.map +1 -1
  264. package/build/cjs/ocm/components/clusters/Clusters.js +3 -3
  265. package/build/cjs/ocm/components/clusters/Clusters.js.map +1 -1
  266. package/build/cjs/ocm/components/clusters/ClustersListToolbar.js +5 -5
  267. package/build/cjs/ocm/components/clusters/ClustersListToolbar.js.map +1 -1
  268. package/build/cjs/ocm/components/clusters/ClustersTable.js +4 -3
  269. package/build/cjs/ocm/components/clusters/ClustersTable.js.map +1 -1
  270. package/build/cjs/ocm/components/featureSupportLevels/featureStateUtils.js +1 -1
  271. package/build/cjs/ocm/components/ui/Buttons/BackButton.js +2 -2
  272. package/build/cjs/ocm/components/ui/Buttons/BackButton.js.map +1 -1
  273. package/build/cjs/ocm/hooks/useInfraEnvId.js +2 -2
  274. package/build/cjs/ocm/hooks/useInfraEnvId.js.map +1 -1
  275. package/build/cjs/ocm/hooks/useLateBinding.js +41 -26
  276. package/build/cjs/ocm/hooks/useLateBinding.js.map +1 -1
  277. package/build/cjs/ocm/hooks/usePullSecret.js +2 -2
  278. package/build/cjs/ocm/services/InfraEnvsService.js +4 -1
  279. package/build/cjs/ocm/services/InfraEnvsService.js.map +1 -1
  280. package/build/cjs/ocm/store/slices/clusters/selectors.js +2 -2
  281. package/build/cjs/ocm/store/slices/clusters/selectors.js.map +1 -1
  282. package/build/cjs/ocm/store/slices/feature-flags/selectors.js.map +1 -1
  283. package/build/cjs/ocm/store/slices/infra-envs/selectors.js.map +1 -1
  284. package/lib/cim/components/Agent/NoAgentsAlert.tsx +1 -1
  285. package/lib/cim/components/Agent/tableColumns.tsx +1 -1
  286. package/lib/cim/components/ClusterDeployment/ClusterDeploymentWizard.tsx +10 -2
  287. package/lib/cim/components/ClusterDeployment/clusterDetails/ACMClusterDeploymentDetailsStep.tsx +3 -1
  288. package/lib/cim/components/ClusterDeployment/clusterDetails/ClusterDeploymentDetailsStep.tsx +5 -86
  289. package/lib/cim/components/ClusterDeployment/clusterDetails/ClusterDetailsFormFields.tsx +1 -12
  290. package/lib/cim/components/ClusterDeployment/clusterDetails/useDetailsFormik.tsx +97 -0
  291. package/lib/cim/components/ClusterDeployment/review/ClusterDeploymentReviewStep.tsx +18 -14
  292. package/lib/cim/components/ClusterDeployment/types.ts +0 -1
  293. package/lib/cim/components/ClusterDeployment/wizardTransition.ts +5 -1
  294. package/lib/cim/components/Hypershift/DetailsPage/NodePoolsTable.tsx +1 -1
  295. package/lib/cim/components/InfraEnv/AddHostDropdown.tsx +1 -1
  296. package/lib/cim/components/common/CpuArchitectureDropdown.tsx +2 -1
  297. package/lib/cim/components/helpers/clusterDeployment.ts +9 -4
  298. package/lib/cim/components/modals/CimConfiguration/CimConfigProgressAlert.tsx +2 -2
  299. package/lib/cim/components/modals/CimConfiguration/CimConfigurationFormFields.tsx +1 -1
  300. package/lib/cim/components/modals/CimConfiguration/CimConfigurationModal.tsx +2 -2
  301. package/lib/cim/components/modals/CimConfiguration/CimStorageMissingAlert.tsx +5 -2
  302. package/lib/cim/components/modals/CimConfiguration/constants.ts +1 -1
  303. package/lib/cim/components/modals/MassDeleteAgentModal.tsx +1 -1
  304. package/lib/cim/hooks/index.tsx +1 -0
  305. package/lib/cim/hooks/useAgents.tsx +15 -0
  306. package/lib/common/components/clusterConfiguration/DiskEncryptionFields/DiskEncryptionControlGroup.tsx +18 -8
  307. package/lib/common/components/clusterConfiguration/ExternalPlatformsDropdown.tsx +3 -1
  308. package/lib/common/components/clusterConfiguration/utils.test.ts +43 -1
  309. package/lib/common/components/clusterConfiguration/utils.ts +13 -0
  310. package/lib/common/components/clusterDetail/ClusterCredentials.tsx +49 -53
  311. package/lib/common/components/clusterDetail/ConsoleModal.tsx +0 -35
  312. package/lib/common/components/clusterWizard/ReviewValidations.tsx +24 -0
  313. package/lib/common/components/clusterWizard/clusterDetailsValidation.ts +38 -12
  314. package/lib/common/components/clusterWizard/networkingSteps/AvailableSubnetsControl.tsx +31 -57
  315. package/lib/common/components/clusterWizard/networkingSteps/ManagedNetworkingControlGroup.tsx +3 -3
  316. package/lib/common/components/clusterWizard/networkingSteps/StackTypeControlGroup.tsx +33 -38
  317. package/lib/common/components/clusterWizard/validationsInfoUtils.ts +0 -20
  318. package/lib/common/components/hosts/utils.ts +8 -1
  319. package/lib/common/config/constants.ts +4 -0
  320. package/lib/common/selectors/clusterSelectors.ts +9 -9
  321. package/lib/common/types/clusters.ts +3 -1
  322. package/lib/common/validationSchemas/addressValidation.tsx +2 -2
  323. package/lib/ocm/components/Routes.tsx +2 -2
  324. package/lib/ocm/components/clusterConfiguration/DiscoveryImageForm.tsx +11 -2
  325. package/lib/ocm/components/clusterConfiguration/DiscoveryImageModal.tsx +13 -3
  326. package/lib/ocm/components/clusterConfiguration/OcmClusterDetailsFormFields.tsx +9 -1
  327. package/lib/ocm/components/clusterConfiguration/OcmClusterProgressItems.tsx +2 -2
  328. package/lib/ocm/components/clusterConfiguration/OcmDiscoveryImageConfigForm.tsx +1 -1
  329. package/lib/ocm/components/clusterConfiguration/manifestsConfiguration/CustomManifestsPage.tsx +8 -1
  330. package/lib/ocm/components/clusterConfiguration/manifestsConfiguration/components/CustomManifestsForm.tsx +3 -1
  331. package/lib/ocm/components/clusterConfiguration/manifestsConfiguration/components/utils.tsx +12 -6
  332. package/lib/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfiguration.tsx +86 -22
  333. package/lib/ocm/components/clusterConfiguration/networkConfiguration/NetworkConfigurationForm.tsx +2 -2
  334. package/lib/ocm/components/clusterConfiguration/networkConfiguration/networkConfigurationValidation.ts +57 -20
  335. package/lib/ocm/components/clusterConfiguration/operators/OperatorCheckbox.tsx +48 -34
  336. package/lib/ocm/components/clusterConfiguration/operators/bundleSpecs.tsx +2 -3
  337. package/lib/ocm/components/clusterConfiguration/operators/utils.tsx +6 -37
  338. package/lib/ocm/components/clusterConfiguration/review/ReviewNetworkingTable.tsx +4 -2
  339. package/lib/ocm/components/clusterConfiguration/review/ReviewOperatorsTable.tsx +114 -24
  340. package/lib/ocm/components/clusterConfiguration/review/ReviewSummary.tsx +1 -4
  341. package/lib/ocm/components/clusterConfiguration/review/TableSummaryExpandable.css +3 -0
  342. package/lib/ocm/components/clusterConfiguration/review/TableSummaryExpandable.tsx +1 -1
  343. package/lib/ocm/components/clusterConfiguration/review/utils.test.ts +41 -0
  344. package/lib/ocm/components/clusterConfiguration/review/utils.tsx +6 -3
  345. package/lib/ocm/components/clusterConfiguration/staticIp/components/StaticIpForm.tsx +10 -1
  346. package/lib/ocm/components/clusterConfiguration/staticIp/components/StaticIpPage.tsx +9 -6
  347. package/lib/ocm/components/clusterConfiguration/staticIp/data/formDataToInfraEnvField.ts +2 -0
  348. package/lib/ocm/components/clusterConfiguration/staticIp/data/nmstateTypes.ts +1 -0
  349. package/lib/ocm/components/clusterConfiguration/staticIp/data/nmstateYaml.ts +2 -0
  350. package/lib/ocm/components/clusterDetail/AssistedInstallerDetailCard.tsx +1 -1
  351. package/lib/ocm/components/clusterDetail/ClusterDetail.tsx +3 -3
  352. package/lib/ocm/components/clusterDetail/ClusterDetailsButtonGroup.tsx +27 -2
  353. package/lib/ocm/components/clusterWizard/ClusterDetails.tsx +4 -16
  354. package/lib/ocm/components/clusterWizard/ClusterDetailsForm.tsx +1 -1
  355. package/lib/ocm/components/clusterWizard/ClusterWizardContextProvider.tsx +6 -14
  356. package/lib/ocm/components/clusterWizard/ClusterWizardFooter.tsx +1 -1
  357. package/lib/ocm/components/clusterWizard/NewClusterWizard.tsx +7 -3
  358. package/lib/ocm/components/clusterWizard/Operators.tsx +47 -12
  359. package/lib/ocm/components/clusterWizard/OperatorsBundle.tsx +72 -26
  360. package/lib/ocm/components/clusterWizard/OperatorsSelect.test.ts +11 -5
  361. package/lib/ocm/components/clusterWizard/OperatorsSelect.tsx +21 -4
  362. package/lib/ocm/components/clusterWizard/OperatorsStep.tsx +1 -1
  363. package/lib/ocm/components/clusterWizard/OptionalOperatorsDropdown.tsx +106 -0
  364. package/lib/ocm/components/clusterWizard/disconnected/ReviewStep.tsx +2 -2
  365. package/lib/ocm/components/clusterWizard/wizardTransition.ts +92 -37
  366. package/lib/ocm/components/clusters/ClusterBreadcrumbs.tsx +1 -1
  367. package/lib/ocm/components/clusters/ClusterPage.tsx +1 -1
  368. package/lib/ocm/components/clusters/Clusters.tsx +2 -2
  369. package/lib/ocm/components/clusters/ClustersListToolbar.tsx +5 -7
  370. package/lib/ocm/components/clusters/ClustersTable.tsx +60 -50
  371. package/lib/ocm/components/featureSupportLevels/featureStateUtils.ts +1 -1
  372. package/lib/ocm/components/ui/Buttons/BackButton.tsx +1 -1
  373. package/lib/ocm/hooks/useInfraEnvId.ts +2 -2
  374. package/lib/ocm/hooks/useLateBinding.ts +45 -24
  375. package/lib/ocm/hooks/usePullSecret.ts +2 -2
  376. package/lib/ocm/services/InfraEnvsService.ts +4 -1
  377. package/lib/ocm/store/slices/clusters/selectors.tsx +7 -5
  378. package/lib/ocm/store/slices/feature-flags/selectors.ts +5 -2
  379. package/lib/ocm/store/slices/infra-envs/selectors.ts +4 -2
  380. package/package.json +17 -17
  381. package/build/cjs/ocm/components/clusterConfiguration/DiscoveryImageModal.css +0 -3
  382. package/lib/ocm/components/clusterConfiguration/DiscoveryImageModal.css +0 -3
@@ -7,48 +7,63 @@ const useInfraEnvHosts_1 = tslib_1.__importDefault(require("./useInfraEnvHosts")
7
7
  const HostsService_1 = tslib_1.__importDefault(require("../services/HostsService"));
8
8
  const utils_1 = require("../../common/utils");
9
9
  const use_feature_1 = require("./use-feature");
10
+ const MAX_BIND_RETRY_ATTEMPTS = 3;
10
11
  const useLateBinding = (cluster) => {
11
12
  const [isBinding, setIsBinding] = (0, react_1.useState)(false);
12
13
  const { addAlert, removeAlert, alerts } = (0, common_1.useAlerts)();
13
14
  const isSingleClusterFeatureEnabled = (0, use_feature_1.useFeature)('ASSISTED_INSTALLER_SINGLE_CLUSTER_FEATURE');
15
+ const bindFailureCounts = (0, react_1.useRef)(new Map());
16
+ const alertsRef = (0, react_1.useRef)(alerts);
17
+ alertsRef.current = alerts;
14
18
  const { hosts: infraEnvHosts, error: infraEnvError, isLoading: infraEnvLoading, } = (0, useInfraEnvHosts_1.default)(isSingleClusterFeatureEnabled ? cluster.id : '', cluster.cpuArchitecture
15
19
  ? cluster.cpuArchitecture
16
20
  : common_1.CpuArchitecture.USE_DAY1_ARCHITECTURE, cluster.name, undefined, cluster.openshiftVersion);
21
+ const bindSingleHost = (0, react_1.useCallback)((host) => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
22
+ var _a, _b;
23
+ setIsBinding(true);
24
+ try {
25
+ yield HostsService_1.default.bind(host, cluster.id);
26
+ // Binding succeeded: reset the failure counter and clear any alert that
27
+ // was shown after previous exhausted retries.
28
+ bindFailureCounts.current.delete(host.id);
29
+ const alertKey = (_a = alertsRef.current.find((alert) => alert.key === host.id)) === null || _a === void 0 ? void 0 : _a.key;
30
+ if (alertKey) {
31
+ removeAlert(alertKey);
32
+ }
33
+ }
34
+ catch (error) {
35
+ const failureCount = ((_b = bindFailureCounts.current.get(host.id)) !== null && _b !== void 0 ? _b : 0) + 1;
36
+ bindFailureCounts.current.set(host.id, failureCount);
37
+ // Suppress transient errors (e.g. 5xx during self-healing) and only
38
+ // surface the alert once silent retries have been exhausted.
39
+ if (failureCount >= MAX_BIND_RETRY_ATTEMPTS) {
40
+ addAlert({
41
+ title: `Failed to bind host ${host.requestedHostname || ''}`,
42
+ message: (0, utils_1.getErrorMessage)(error),
43
+ key: host.id,
44
+ });
45
+ }
46
+ }
47
+ finally {
48
+ setIsBinding(false);
49
+ }
50
+ }), [cluster.id, addAlert, removeAlert]);
17
51
  const bindHosts = (0, react_1.useCallback)(() => tslib_1.__awaiter(void 0, void 0, void 0, function* () {
18
- var _a;
19
- if (infraEnvHosts && !infraEnvError && !infraEnvLoading && isSingleClusterFeatureEnabled) {
20
- for (const host of infraEnvHosts) {
21
- if (host.clusterId !== cluster.id) {
22
- setIsBinding(true);
23
- try {
24
- const alertKey = (_a = alerts.find((alert) => alert.key === host.id)) === null || _a === void 0 ? void 0 : _a.key;
25
- if (alertKey) {
26
- removeAlert(alertKey);
27
- }
28
- yield HostsService_1.default.bind(host, cluster.id);
29
- }
30
- catch (error) {
31
- addAlert({
32
- title: `Failed to bind host ${host.requestedHostname || ''}`,
33
- message: (0, utils_1.getErrorMessage)(error),
34
- key: host.id,
35
- });
36
- }
37
- finally {
38
- setIsBinding(false);
39
- }
40
- }
52
+ if (!infraEnvHosts || infraEnvError || infraEnvLoading || !isSingleClusterFeatureEnabled) {
53
+ return;
54
+ }
55
+ for (const host of infraEnvHosts) {
56
+ if (host.clusterId !== cluster.id) {
57
+ yield bindSingleHost(host);
41
58
  }
42
59
  }
43
- // eslint-disable-next-line react-hooks/exhaustive-deps
44
60
  }), [
45
61
  infraEnvHosts,
46
62
  infraEnvError,
47
63
  infraEnvLoading,
48
64
  isSingleClusterFeatureEnabled,
49
65
  cluster.id,
50
- addAlert,
51
- removeAlert,
66
+ bindSingleHost,
52
67
  ]);
53
68
  (0, react_1.useEffect)(() => {
54
69
  if (isSingleClusterFeatureEnabled) {
@@ -1 +1 @@
1
- {"version":3,"file":"useLateBinding.js","sourceRoot":"","sources":["../../../../lib/ocm/hooks/useLateBinding.ts"],"names":[],"mappings":";;;AAAA,iCAAyD;AAEzD,yCAA0D;AAC1D,kFAAkD;AAClD,oFAAo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C;QACnB,CAAC;IACH,CAAC,EAAE,CAAC,6BAA6B,EAAE,SAAS,CAAC,CAAC,CAAC;IAE/C,OAAO,eAAe,IAAI,SAAS,CAAC;AACtC,CAAC,CAAC;AAEF,kBAAe,cAAc,CAAC"}
@@ -7,8 +7,8 @@ const api_1 = require("../../common/api");
7
7
  const common_1 = require("../../common");
8
8
  const access_token_api_1 = require("../../common/api/accounts-management-service/access-token-api");
9
9
  /**
10
- * Standalone / disconnected UI: bridge serves GET /pull-secret from a mounted manifest
11
- * (see assisted-disconnected-ui proxy).
10
+ * Standalone / disconnected UI: proxy serves GET /api/pull-secret with pull-secret JSON
11
+ * `{ "auths": … }` extracted from the mounted Secret manifest (see assisted-disconnected-ui proxy).
12
12
  */
13
13
  function fetchPullSecretFromBridge() {
14
14
  return tslib_1.__awaiter(this, void 0, void 0, function* () {
@@ -10,7 +10,10 @@ const InfraEnvsService = {
10
10
  let infraEnvId = InfraEnvIdsCacheService_1.default.getInfraEnvId(clusterId, cpuArchitecture);
11
11
  if (infraEnvId instanceof Error) {
12
12
  const { data: infraEnvs } = yield apis_1.InfraEnvsAPI.list(!isSingleClusterFeatureEnabled ? clusterId : '');
13
- if (infraEnvs.length > 0) {
13
+ if (isSingleClusterFeatureEnabled) {
14
+ return infraEnvs[0].id;
15
+ }
16
+ if (infraEnvs.length > 0 && clusterId) {
14
17
  InfraEnvIdsCacheService_1.default.updateInfraEnvs(clusterId, infraEnvs);
15
18
  infraEnvId = InfraEnvIdsCacheService_1.default.getInfraEnvId(clusterId, cpuArchitecture);
16
19
  }
@@ -1 +1 @@
1
- {"version":3,"file":"InfraEnvsService.js","sourceRoot":"","sources":["../../../../lib/ocm/services/InfraEnvsService.ts"],"names":[],"mappings":";;;AAEA,iCAAsC;AACtC,gGAAsD;AACtD,0FAAmG;AAQnG,MAAM,gBAAgB,GAAG;IACjB,aAAa,CACjB,SAAwB,EACxB,eAAgC,EAChC,6BAAuC;;YAEvC,IAAI,UAAU,GAAG,iCAAa,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AAU,EAAE,EAAE;gBACjC,2EAA2E;gBAC3E,IAAI,UAAU,KAAK,iBAAiB,EAAE,CAAC;oBACrC,cAAc,CAAC,IAAI,CACjB,mBAAY,CAAC,MAAM,CAAC,UAAU,EAAE;wBAC9B,mBAAmB;qBACpB,CAAC,CACH,CAAC;gBACJ,CAAC;YACH,CAAC,CAAC,CAAC;YAEH,mGAAmG;YACnG,OAAO,OAAO,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC,IAAI,CAAC,GAAG,EAAE;gBAC3C,OAAO,eAAe,CAAC;YACzB,CAAC,CAAC,CAAC;QACL,CAAC;KAAA;IAED,gBAAgB,CAAC,eAAuB,EAAE,IAAa;QACrD,OAAO,GAAG,IAAI,IAAI,EAAE,cAAc,eAAe,EAAE,CAAC;IACtD,CAAC;CACF,CAAC;AAEF,kBAAe,gBAAgB,CAAC"}
@@ -4,7 +4,7 @@ exports.selectClusterNames = exports.selectClusterTableRows = exports.getCluster
4
4
  const tslib_1 = require("tslib");
5
5
  const react_1 = tslib_1.__importDefault(require("react"));
6
6
  const toolkit_1 = require("@reduxjs/toolkit");
7
- const react_router_dom_v5_compat_1 = require("react-router-dom-v5-compat");
7
+ const react_router_1 = require("react-router");
8
8
  const common_1 = require("../../../../common");
9
9
  const ClusterStatus_1 = tslib_1.__importStar(require("../../../components/clusters/ClusterStatus"));
10
10
  const selectClusters = (state) => state.clusters.data.filter((c) => c.kind !== 'DisconnectedCluster');
@@ -29,7 +29,7 @@ const clusterToClusterTableRow = (cluster, t) => {
29
29
  return {
30
30
  cells: [
31
31
  {
32
- title: (react_1.default.createElement(react_router_dom_v5_compat_1.Link, { key: name, to: id, id: `cluster-link-${id}` }, name)),
32
+ title: (react_1.default.createElement(react_router_1.Link, { key: name, to: id, id: `cluster-link-${id}` }, name)),
33
33
  props: { 'data-testid': `cluster-name-${name}` },
34
34
  sortableValue: name,
35
35
  },
@@ -1 +1 @@
1
- {"version":3,"file":"selectors.js","sourceRoot":"","sources":["../../../../../../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C,CAAC,IAAI,CAAC,CAC1C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"selectors.js","sourceRoot":"","sources":["../../../../../../lib/ocm/store/slices/feature-flags/selectors.ts"],"names":[],"mappings":";;;AAEA,8CAAkD;AAE3C,MAAM,uBAAuB,GAAG,CAAC,KAAoB,EAAE,EAAE,CAAC,KAAK,CAAC,YAAY,CAAC;AAAvE,QAAA,uBAAuB,2BAAgD;AAE7E,MAAM,gBAAgB,GAAG,CAAC,SAAgC,EAAE,EAAE,CACnE,IAAA,wBAAc,EACZ,+BAAuB,EACvB,CAAC,YAAwD,EAAE,EAAE,WAC3D,OAAA,MAAA,YAAY,CAAC,IAAI,CAAC,SAAS,CAAC,mCAAI,KAAK,CAAA,EAAA,CACxC,CAAC;AALS,QAAA,gBAAgB,oBAKzB"}
1
+ {"version":3,"file":"selectors.js","sourceRoot":"","sources":["../../../../../../lib/ocm/store/slices/feature-flags/selectors.ts"],"names":[],"mappings":";;;AAEA,8CAAkD;AAG3C,MAAM,uBAAuB,GAAG,CAAC,KAAoB,EAAE,EAAE,CAAC,KAAK,CAAC,YAAY,CAAC;AAAvE,QAAA,uBAAuB,2BAAgD;AAE7E,MAAM,gBAAgB,GAAG,CAC9B,SAAgC,EACE,EAAE,CACpC,IAAA,wBAAc,EACZ,+BAAuB,EACvB,CAAC,YAAwD,EAAW,EAAE,WACpE,OAAA,MAAA,YAAY,CAAC,IAAI,CAAC,SAAS,CAAC,mCAAI,KAAK,CAAA,EAAA,CACxC,CAAC;AAPS,QAAA,gBAAgB,oBAOzB"}
@@ -1 +1 @@
1
- {"version":3,"file":"selectors.js","sourceRoot":"","sources":["../../../../../../lib/ocm/store/slices/infra-envs/selectors.ts"],"names":[],"mappings":";;;AAAA,8CAAkD;AAI3C,MAAM,oBAAoB,GAAG,CAAC,KAAoB,EAAE,EAAE,CAAC,KAAK,CAAC,SAAS,CAAC;AAAjE,QAAA,oBAAoB,wBAA6C;AACjE,QAAA,+BAA+B,GAAG,IAAA,wBAAc,EAC3D,CAAC,4BAAoB,EAAE,CAAC,CAAgB,EAAE,eAAgC,EAAE,EAAE,CAAC,eAAe,CAAC,EAC/F,CAAC,SAAS,EAAE,eAAe,EAAE,EAAE,CAC7B,SAAS,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,eAAe,KAAK,eAAe,CAAC,CAC7E,CAAC"}
1
+ {"version":3,"file":"selectors.js","sourceRoot":"","sources":["../../../../../../lib/ocm/store/slices/infra-envs/selectors.ts"],"names":[],"mappings":";;;AAAA,8CAAkD;AAM3C,MAAM,oBAAoB,GAAG,CAAC,KAAoB,EAAE,EAAE,CAAC,KAAK,CAAC,SAAS,CAAC;AAAjE,QAAA,oBAAoB,wBAA6C;AACjE,QAAA,+BAA+B,GAAG,IAAA,wBAAc,EAC3D,CAAC,4BAAoB,EAAE,CAAC,CAAgB,EAAE,eAAgC,EAAE,EAAE,CAAC,eAAe,CAAC,EAC/F,CAAC,SAAS,EAAE,eAAe,EAAwB,EAAE,CACnD,SAAS,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,eAAe,KAAK,eAAe,CAAC,CACT,CAAC"}
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { Alert, AlertVariant, List, ListComponent, ListItem } from '@patternfly/react-core';
3
- import { Link } from 'react-router-dom-v5-compat';
3
+ import { Link } from 'react-router';
4
4
  import { useTranslation } from '../../../common/hooks/use-translation-wrapper';
5
5
  import { Trans } from 'react-i18next';
6
6
  import { architectureData, CpuArchitecture, SupportedCpuArchitecture } from '../../../common';
@@ -1,6 +1,6 @@
1
1
  import * as React from 'react';
2
2
  import { TFunction } from 'i18next';
3
- import { Link } from 'react-router-dom-v5-compat';
3
+ import { Link } from 'react-router';
4
4
  import { Host } from '@openshift-assisted/types/assisted-installer-service';
5
5
  import { HostsTableActions, getInventory, getHostname, Hostname } from '../../../common';
6
6
  import { TableRow } from '../../../common/components/hosts/AITable';
@@ -1,7 +1,7 @@
1
1
  import * as React from 'react';
2
2
  import { useTranslation } from '../../../common/hooks/use-translation-wrapper';
3
3
  import { Grid, GridItem, Wizard, WizardStep } from '@patternfly/react-core';
4
- import { AlertsContextProvider, LoadingState } from '../../../common';
4
+ import { AlertsContextProvider, ErrorState, LoadingState } from '../../../common';
5
5
  import { ClusterDeploymentWizardProps } from './types';
6
6
  import { ACMFeatureSupportLevelProvider } from '../featureSupportLevels';
7
7
  import { YamlPreview, useYamlPreview } from '../YamlPreview';
@@ -14,6 +14,7 @@ import { ClusterDeploymentHostsDiscoveryStep } from './hostDiscovery';
14
14
  import { ClusterDeploymentNetworkingStep } from './networking';
15
15
  import { ClusterDeploymentReviewStep } from './review';
16
16
  import { ClusterDeploymentCustomManifestsStep } from './customManifests';
17
+ import { useAgents } from '../../hooks';
17
18
 
18
19
  export const ClusterDeploymentWizard = ({
19
20
  className,
@@ -27,7 +28,6 @@ export const ClusterDeploymentWizard = ({
27
28
  fetchSecret,
28
29
  clusterDeployment,
29
30
  agentClusterInstall,
30
- agents,
31
31
  bareMetalHosts,
32
32
  clusterImages,
33
33
  aiConfigMap,
@@ -54,12 +54,20 @@ export const ClusterDeploymentWizard = ({
54
54
  fetchKlusterletAddonConfig,
55
55
  });
56
56
 
57
+ const [agents, loaded, error] = useAgents({ isList: true });
58
+
57
59
  // if initialStep is set, it is either 'host-selection' or 'host-discovery', both at index 4
58
60
  // if initialStep is not set, start at 'cluster-details' which is at index 2
59
61
  const startIndex = initialStep ? 4 : 2;
60
62
  const stepNames = wizardStepNames(t);
61
63
  const isAIFlow = !!infraEnv;
62
64
 
65
+ if (!loaded) {
66
+ return <LoadingState />;
67
+ } else if (error) {
68
+ return <ErrorState />;
69
+ }
70
+
63
71
  return (
64
72
  <Grid style={{ height: '100%' }}>
65
73
  <GridItem span={isPreviewOpen ? 7 : 12}>
@@ -4,7 +4,7 @@ import { Stack } from '@patternfly/react-core';
4
4
  import noop from 'lodash-es/noop.js';
5
5
  import { ClusterDetailsValues, getRichTextValidation } from '../../../../common';
6
6
  import { ClusterImageSetK8sResource } from '../../../types/k8s/cluster-image-set';
7
- import { useDetailsFormik } from './ClusterDeploymentDetailsStep';
7
+ import { useDetailsFormik } from './useDetailsFormik';
8
8
  import { ClusterDetailsFormFieldsProps } from './ClusterDetailsFormFields';
9
9
  import { OsImage } from '../../../types';
10
10
  import { getOCPVersions } from '../../helpers';
@@ -58,9 +58,11 @@ export const ACMClusterDeploymentDetailsStep: React.FC<ACMClusterDeploymentDetai
58
58
  ...rest
59
59
  }) => {
60
60
  const ocpVersions = getOCPVersions(clusterImages, !!isNutanix, osImages);
61
+ const allOcpVersions = getOCPVersions(clusterImages, !!isNutanix, osImages, true);
61
62
 
62
63
  const [initialValues, validationSchema] = useDetailsFormik({
63
64
  ocpVersions,
65
+ allOcpVersions,
64
66
  usedClusterNames,
65
67
  });
66
68
 
@@ -1,101 +1,18 @@
1
1
  import React from 'react';
2
2
  import { Formik } from 'formik';
3
- import { Lazy } from 'yup';
4
3
  import { Grid, GridItem, useWizardContext } from '@patternfly/react-core';
5
4
 
6
- import {
7
- useAlerts,
8
- getClusterDetailsInitialValues,
9
- getClusterDetailsValidationSchema,
10
- ClusterWizardStepHeader,
11
- ClusterDetailsValues,
12
- getRichTextValidation,
13
- OpenshiftVersionOptionType,
14
- } from '../../../../common';
5
+ import { useAlerts, ClusterWizardStepHeader, getRichTextValidation } from '../../../../common';
15
6
 
16
7
  import { ClusterDeploymentDetailsStepProps, ClusterDeploymentDetailsValues } from '../types';
17
- import { getAICluster, getNetworkType, getOCPVersions } from '../../helpers';
18
- import {
19
- AgentClusterInstallK8sResource,
20
- AgentK8sResource,
21
- ClusterDeploymentK8sResource,
22
- InfraEnvK8sResource,
23
- } from '../../../types';
8
+ import { getOCPVersions } from '../../helpers';
24
9
  import {
25
10
  ClusterDeploymentDetailsForm,
26
11
  ClusterDeploymentDetailsFormWrapper,
27
12
  } from './ClusterDeploymentDetailsForm';
28
13
  import { getGridSpans } from '../helpers';
29
14
  import { useTranslation } from '../../../../common/hooks/use-translation-wrapper';
30
-
31
- type UseDetailsFormikArgs = {
32
- usedClusterNames: string[];
33
- ocpVersions: OpenshiftVersionOptionType[];
34
- clusterDeployment?: ClusterDeploymentK8sResource;
35
- agentClusterInstall?: AgentClusterInstallK8sResource;
36
- agents?: AgentK8sResource[];
37
- infraEnv?: InfraEnvK8sResource;
38
- };
39
-
40
- export const useDetailsFormik = ({
41
- clusterDeployment,
42
- agentClusterInstall,
43
- agents,
44
- usedClusterNames,
45
- infraEnv,
46
- ocpVersions,
47
- }: UseDetailsFormikArgs): [
48
- ClusterDetailsValues & { networkType: 'OpenShiftSDN' | 'OVNKubernetes' },
49
- Lazy<{ baseDnsDomain: string }>,
50
- ] => {
51
- const { t } = useTranslation();
52
- const isEdit = !!clusterDeployment || !!agentClusterInstall;
53
-
54
- const cluster = React.useMemo(
55
- () =>
56
- clusterDeployment && agentClusterInstall
57
- ? getAICluster({
58
- clusterDeployment,
59
- agentClusterInstall,
60
- agents,
61
- infraEnv,
62
- })
63
- : undefined,
64
- [agentClusterInstall, clusterDeployment, agents, infraEnv],
65
- );
66
-
67
- const initialValues = React.useMemo(
68
- () => {
69
- const initValues = getClusterDetailsInitialValues({
70
- managedDomains: [], // not supported
71
- cluster,
72
- ocpVersions,
73
- });
74
-
75
- const ocpVersion = ocpVersions.find(
76
- (ocpVersion) => ocpVersion.value === initValues.openshiftVersion,
77
- );
78
- return {
79
- ...initValues,
80
- networkType: getNetworkType(ocpVersion),
81
- };
82
- },
83
- [], // eslint-disable-line react-hooks/exhaustive-deps
84
- );
85
-
86
- const validationSchema = React.useMemo(
87
- () =>
88
- getClusterDetailsValidationSchema({
89
- usedClusterNames,
90
- pullSecretSet: isEdit,
91
- validateUniqueName: true,
92
- t,
93
- }),
94
- [usedClusterNames, isEdit, t],
95
- );
96
-
97
- return [initialValues, validationSchema];
98
- };
15
+ import { useDetailsFormik } from './useDetailsFormik';
99
16
 
100
17
  export const ClusterDeploymentDetailsStep: React.FC<ClusterDeploymentDetailsStepProps> = ({
101
18
  clusterImages,
@@ -113,11 +30,13 @@ export const ClusterDeploymentDetailsStep: React.FC<ClusterDeploymentDetailsStep
113
30
  const { goToNextStep } = useWizardContext();
114
31
 
115
32
  const ocpVersions = getOCPVersions(clusterImages, isNutanix);
33
+ const allOcpVersions = getOCPVersions(clusterImages, isNutanix, undefined, true);
116
34
  const gridSpans = getGridSpans(isPreviewOpen);
117
35
 
118
36
  const [initialValues, validationSchema] = useDetailsFormik({
119
37
  clusterDeployment,
120
38
  ocpVersions,
39
+ allOcpVersions,
121
40
  agentClusterInstall,
122
41
  agents,
123
42
  usedClusterNames,
@@ -17,7 +17,6 @@ import { ClusterDetailsValues } from '../../../../common/components/clusterWizar
17
17
  import { useTranslation } from '../../../../common/hooks/use-translation-wrapper';
18
18
  import CpuArchitectureDropdown from '../../common/CpuArchitectureDropdown';
19
19
  import ControlPlaneNodesDropdown from '../../../../common/components/clusterConfiguration/ControlPlaneNodesDropdown';
20
- import { getNetworkType } from '../../helpers';
21
20
 
22
21
  export type ClusterDetailsFormFieldsProps = {
23
22
  isEditFlow: boolean;
@@ -59,19 +58,9 @@ export const ClusterDetailsFormFields: React.FC<ClusterDetailsFormFieldsProps> =
59
58
  const { t } = useTranslation();
60
59
  const nameInputRef = React.useRef<HTMLInputElement>();
61
60
  const [openshiftVersionModalOpen, setOpenshiftVersionModalOpen] = React.useState(false);
62
- const { values, setFieldValue } = useFormikContext<ClusterDetailsValues>();
61
+ const { values } = useFormikContext<ClusterDetailsValues>();
63
62
  const { name, baseDnsDomain } = values;
64
63
 
65
- React.useEffect(() => {
66
- if (!versions.length && !values.openshiftVersion && !isEditFlow) {
67
- const fallbackOpenShiftVersion = allVersions.find((version) => version.default);
68
- setFieldValue('customOpenshiftSelect', fallbackOpenShiftVersion?.value);
69
- setFieldValue('openshiftVersion', fallbackOpenShiftVersion?.value);
70
- setFieldValue('networkType', getNetworkType(fallbackOpenShiftVersion));
71
- }
72
- // eslint-disable-next-line react-hooks/exhaustive-deps
73
- }, []);
74
-
75
64
  React.useEffect(() => {
76
65
  nameInputRef.current?.focus();
77
66
  }, []);
@@ -0,0 +1,97 @@
1
+ import React from 'react';
2
+ import { Lazy } from 'yup';
3
+ import {
4
+ ClusterDetailsValues,
5
+ getClusterDetailsInitialValues,
6
+ getClusterDetailsValidationSchema,
7
+ OpenshiftVersionOptionType,
8
+ useTranslation,
9
+ } from '../../../../common';
10
+ import {
11
+ AgentClusterInstallK8sResource,
12
+ AgentK8sResource,
13
+ ClusterDeploymentK8sResource,
14
+ InfraEnvK8sResource,
15
+ } from '../../../types';
16
+ import { getAICluster, getNetworkType } from '../../helpers';
17
+
18
+ type UseDetailsFormikArgs = {
19
+ usedClusterNames: string[];
20
+ ocpVersions: OpenshiftVersionOptionType[];
21
+ allOcpVersions: OpenshiftVersionOptionType[];
22
+ clusterDeployment?: ClusterDeploymentK8sResource;
23
+ agentClusterInstall?: AgentClusterInstallK8sResource;
24
+ agents?: AgentK8sResource[];
25
+ infraEnv?: InfraEnvK8sResource;
26
+ };
27
+
28
+ export const useDetailsFormik = ({
29
+ clusterDeployment,
30
+ agentClusterInstall,
31
+ agents,
32
+ usedClusterNames,
33
+ infraEnv,
34
+ ocpVersions,
35
+ allOcpVersions,
36
+ }: UseDetailsFormikArgs): [
37
+ ClusterDetailsValues & { networkType: 'OpenShiftSDN' | 'OVNKubernetes' },
38
+ Lazy<{ baseDnsDomain: string }>,
39
+ ] => {
40
+ const { t } = useTranslation();
41
+ const isEdit = !!clusterDeployment || !!agentClusterInstall;
42
+
43
+ const cluster = React.useMemo(
44
+ () =>
45
+ clusterDeployment && agentClusterInstall
46
+ ? getAICluster({
47
+ clusterDeployment,
48
+ agentClusterInstall,
49
+ agents,
50
+ infraEnv,
51
+ })
52
+ : undefined,
53
+ [agentClusterInstall, clusterDeployment, agents, infraEnv],
54
+ );
55
+
56
+ const initialValues = React.useMemo(
57
+ () => {
58
+ let initValues = getClusterDetailsInitialValues({
59
+ managedDomains: [], // not supported
60
+ cluster,
61
+ ocpVersions,
62
+ });
63
+
64
+ let ocpVersion = ocpVersions.find(
65
+ (ocpVersion) => ocpVersion.value === initValues.openshiftVersion,
66
+ );
67
+
68
+ if (!ocpVersion) {
69
+ ocpVersion = allOcpVersions.find((version) => version.default);
70
+ initValues = {
71
+ ...initValues,
72
+ openshiftVersion: ocpVersion?.value || '',
73
+ customOpenshiftSelect: ocpVersion?.value || '',
74
+ };
75
+ }
76
+
77
+ return {
78
+ ...initValues,
79
+ networkType: getNetworkType(ocpVersion),
80
+ };
81
+ },
82
+ [], // eslint-disable-line react-hooks/exhaustive-deps
83
+ );
84
+
85
+ const validationSchema = React.useMemo(
86
+ () =>
87
+ getClusterDetailsValidationSchema({
88
+ usedClusterNames,
89
+ pullSecretSet: isEdit,
90
+ validateUniqueName: true,
91
+ t,
92
+ }),
93
+ [usedClusterNames, isEdit, t],
94
+ );
95
+
96
+ return [initialValues, validationSchema];
97
+ };
@@ -1,3 +1,4 @@
1
+ import * as React from 'react';
1
2
  import {
2
3
  Alert,
3
4
  AlertVariant,
@@ -7,7 +8,7 @@ import {
7
8
  useWizardFooter,
8
9
  WizardFooter,
9
10
  } from '@patternfly/react-core';
10
- import * as React from 'react';
11
+ import { PlatformType } from '@openshift-assisted/types/assisted-installer-service';
11
12
  import { canNextFromReviewStep } from '../wizardTransition';
12
13
  import {
13
14
  AgentClusterInstallK8sResource,
@@ -42,7 +43,6 @@ import { useTranslation } from '../../../../common/hooks/use-translation-wrapper
42
43
  import { ClusterDeploymentWizardContext } from '../ClusterDeploymentWizardContext';
43
44
  import { ReviewConfigMapsTable } from './ReviewConfigMapsTable';
44
45
  import { ValidationSection } from '../components/ValidationSection';
45
- import { PlatformType } from '@openshift-assisted/types/assisted-installer-service';
46
46
 
47
47
  type ClusterDeploymentReviewStepProps = {
48
48
  clusterDeployment: ClusterDeploymentK8sResource;
@@ -77,7 +77,8 @@ export const ClusterDeploymentReviewStep = ({
77
77
 
78
78
  const canContinue = canNextFromReviewStep(agentClusterInstall, clusterAgents);
79
79
  const { t } = useTranslation();
80
- const onNext = async () => {
80
+
81
+ const onNext = React.useCallback(async () => {
81
82
  clearAlerts();
82
83
  setSubmitting(true);
83
84
  try {
@@ -88,18 +89,21 @@ export const ClusterDeploymentReviewStep = ({
88
89
  } finally {
89
90
  setSubmitting(false);
90
91
  }
91
- };
92
+ }, [addAlert, clearAlerts, onFinish, t]);
92
93
 
93
- const footer = (
94
- <WizardFooter
95
- activeStep={activeStep}
96
- onNext={onNext}
97
- isNextDisabled={isSubmitting || !canContinue || !!syncError}
98
- nextButtonText={t('ai:Install cluster')}
99
- nextButtonProps={{ isLoading: isSubmitting }}
100
- onBack={goToPrevStep}
101
- onClose={close}
102
- />
94
+ const footer = React.useMemo(
95
+ () => (
96
+ <WizardFooter
97
+ activeStep={activeStep}
98
+ onNext={onNext}
99
+ isNextDisabled={isSubmitting || !canContinue || !!syncError}
100
+ nextButtonText={t('ai:Install cluster')}
101
+ nextButtonProps={{ isLoading: isSubmitting }}
102
+ onBack={goToPrevStep}
103
+ onClose={close}
104
+ />
105
+ ),
106
+ [activeStep, canContinue, close, goToPrevStep, isSubmitting, onNext, syncError, t],
103
107
  );
104
108
  useWizardFooter(footer);
105
109
 
@@ -141,7 +141,6 @@ export type ClusterDeploymentWizardProps = {
141
141
 
142
142
  clusterDeployment: ClusterDeploymentK8sResource;
143
143
  agentClusterInstall: AgentClusterInstallK8sResource;
144
- agents: AgentK8sResource[];
145
144
  bareMetalHosts: BareMetalHostK8sResource[];
146
145
  aiConfigMap?: ConfigMapK8sResource;
147
146
  infraEnv?: InfraEnvK8sResource;
@@ -69,7 +69,11 @@ const networkingStepValidationsMap: WizardStepValidationMap = {
69
69
  // Alternatively we would have to whitelist network validations instead of using group
70
70
  // TODO(mlibra): remove that container-images-available from soft validations and let backend drive it via disabling it.
71
71
  // Depends on: https://issues.redhat.com/browse/MGMT-5265
72
- softValidationIds: ['ntp-synced', 'container-images-available'],
72
+ softValidationIds: [
73
+ 'ntp-synced',
74
+ 'container-images-available',
75
+ 'custom-manifests-requirements-satisfied',
76
+ ],
73
77
  getPageURL: (host: Host, validationID: string) => {
74
78
  if (validationID === 'ntp-synced') {
75
79
  return {
@@ -1,5 +1,5 @@
1
1
  import * as React from 'react';
2
- import { Link } from 'react-router-dom-v5-compat';
2
+ import { Link } from 'react-router';
3
3
  import { Button, Label, Popover, Stack, StackItem } from '@patternfly/react-core';
4
4
  import { PlusCircleIcon } from '@patternfly/react-icons/dist/js/icons/plus-circle-icon';
5
5
  import { Table, Tbody, Td, Th, Thead, Tr } from '@patternfly/react-table';
@@ -18,7 +18,7 @@ import { AddBmcHostModal, AddBmcHostYamlModal, AddHostModal } from '../modals';
18
18
  import { AddHostDropdownProps } from './types';
19
19
  import './AddHostDropdown.css';
20
20
  import { Trans } from 'react-i18next';
21
- import { Link } from 'react-router-dom-v5-compat';
21
+ import { Link } from 'react-router';
22
22
  import { OutlinedQuestionCircleIcon } from '@patternfly/react-icons/dist/js/icons/outlined-question-circle-icon';
23
23
 
24
24
  type ModalType = 'iso' | 'bmc' | 'yaml' | 'ipxe' | undefined;