import * as React from "react"; import PrimaryButton from "../../../button/components/PrimaryButton"; export interface ModalStoryContainerProps { children: any; } const ModalStoryContainer = ({ children }: ModalStoryContainerProps) => { const [isShowing, setIsShowing] = React.useState(false); function toggle() { setIsShowing(!isShowing); } return (
{children({ isOpen: isShowing, onClose: toggle })}
Open Modal
); }; export default ModalStoryContainer;