: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in
import { Button, Modal } from '@wordpress/components';
import PropTypes from 'prop-types';
export const DisplayModal = ( props ) => {
onRequestClose={ () => props.cancel( false ) }
style={ { marginRight: '1rem' } }
<Button isSecondary onClick={ () => props.cancel( false ) }>
DisplayModal.propTypes = {
actionText: PropTypes.string,
cancelText: PropTypes.string,
action: PropTypes.func.isRequired,
cancel: PropTypes.func.isRequired