import React from 'react'; import { Button, DrawerActions, DrawerCloseButton, DrawerColorVariant, DrawerHead, DrawerPanelContent } from '@patternfly/react-core'; import { Wizard as WizardDeprecated } from '@patternfly/react-core/deprecated'; export const WizardWithDrawer: React.FunctionComponent = () => { const [isDrawerExpanded, setIsDrawerExpanded] = React.useState(false); const drawerRef = React.useRef(null); const onExpandDrawer = () => { drawerRef.current && drawerRef.current.focus(); }; const onOpenClick = () => { setIsDrawerExpanded(true); }; const onCloseClick = () => { setIsDrawerExpanded(false); }; const panel1Content = ( drawer-panel-1 content ); const panel2Content = ( drawer-panel-2 content ); const panel3Content = ( drawer-panel-3 content ); const drawerToggleButton = ( ); const steps = [ { name: 'Information', component:

Information step content

, drawerPanelContent: panel1Content, drawerToggleButton }, { name: 'Configuration', steps: [ { name: 'Substep A', component:

Substep A content

, drawerPanelContent: panel2Content, drawerToggleButton }, { name: 'Substep B', component:

Substep B content

, drawerPanelContent: panel2Content, drawerToggleButton }, { name: 'Substep C', component:

Substep C content

, drawerPanelContent: panel2Content, drawerToggleButton } ] }, { name: 'Additional', component:

Additional step content

, drawerPanelContent: panel3Content, drawerToggleButton }, { name: 'Review', component:

Review step content

, nextButtonText: 'Finish' } ]; const title = 'Wizard with drawer example'; return ( ); };