Skip to content

Commit 9790ba1

Browse files
authored
Solving problems with custom OCP version selected and platform and cpu dropdowns (#2540)
1 parent d3bdf4f commit 9790ba1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Diff for: libs/ui-lib/lib/common/components/ui/OpenShiftVersionDropdown.tsx

+3-1
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,9 @@ export const OpenShiftVersionDropdown = ({
8383

8484
React.useEffect(() => {
8585
setCurrent(defaultLabel);
86-
}, [defaultLabel]);
86+
setValue(defaultValue);
87+
// eslint-disable-next-line react-hooks/exhaustive-deps
88+
}, [defaultLabel, defaultValue]);
8789

8890
const parsedVersionsForItems = getParsedVersions(items);
8991
const dropdownItems = parsedVersionsForItems.parsedVersions.map(({ y, versions }) => {

0 commit comments

Comments
 (0)