V2Wizard: Add <CentOSAcknowledgement> to Target Output step

The state from RTK is now used to determine whether or not to display
the CentOS acknowledgement.
This commit is contained in:
lucasgarfield 2024-01-06 09:56:26 +01:00 committed by Sanne Raymaekers
parent 779416785f
commit f41f3c51b7

View file

@ -3,13 +3,18 @@ import React from 'react';
import { Text, Form, Title } from '@patternfly/react-core';
import ArchSelect from './ArchSelect';
import CentOSAcknowledgement from './CentOSAcknowledgement';
import ReleaseLifecycle from './ReleaseLifecycle';
import ReleaseSelect from './ReleaseSelect';
import TargetEnvironment from './TargetEnvironment';
import { useAppSelector } from '../../../../store/hooks';
import { selectDistribution } from '../../../../store/wizardSlice';
import DocumentationButton from '../../../sharedComponents/DocumentationButton';
const ImageOutputStep = () => {
const distribution = useAppSelector((state) => selectDistribution(state));
return (
<Form>
<Title headingLevel="h2">Image output</Title>
@ -20,6 +25,7 @@ const ImageOutputStep = () => {
<DocumentationButton />
</Text>
<ReleaseSelect />
{distribution.match('centos-*') && <CentOSAcknowledgement />}
<ReleaseLifecycle />
<ArchSelect />
<TargetEnvironment />