import { Canvas, Meta, ArgTypes } from '@storybook/blocks'; import { ThemeProvider } from 'styled-components'; import Modal from './'; import ModalHeader from './ModalHeader'; import ModalButton from './ModalButton'; import ModalButtonGroup from './ModalButtonGroup'; import { ModalDemo } from './Modal.stories'; import { lightTheme } from '../../../theme/'; import { GlobalStyles } from '../../../theme/GlobalStyles'; import * as ModalStories from './Modal.stories.tsx'; # Modal The Modal component renders as an overlay over the rest of the application. You can click outside of the modal to close the modal. While the modal is open, it will trap the user's focus. The modal itself is composed of other components including ModalHeader, ModalBody, ModalButtonGroup, and ModalButton. Other elements can also be included in the modal. ## Importing ```javascript import { Modal, ModalHeader, ModalBody, ModalButtonGroup, ModalButton, } from 'amazon-chime-sdk-component-library-react'; ``` ## Example ```jsx { isOpen && ( setIsOpen(false)} rootId="modal-root">

This is information presented in a modal

{}} label="submit" variant="primary" />, ]} secondaryButtons={[ {}} label="More info" variant="secondary" />, ]} />
); } ``` ## Props ### Modal ### ModalHeader ### ModalButtonGroup ### ModalButton