DocSpace-client/packages/components/modal-dialog
2023-11-15 15:48:31 +03:00
..
components Web:Modal: Fixed close icon 2023-10-26 17:33:16 +05:00
handlers Added mobileMore media query const 2023-10-09 18:02:32 +04:00
views Client: fix modal and aside height for ipad 2023-11-15 15:48:31 +03:00
index.js Client: Fixed pop-up window blocking in FF 2023-10-13 17:52:41 +05:00
modal-dialog.stories.js Fix media queries (replaced hugeMobile, smallTablet) by design 2023-10-06 15:11:39 +04:00
modal-dialog.test.js Web: Moved all clients app to packages directory 2022-07-22 22:01:25 +03:00
README.md Web: Moved all clients app to packages directory 2022-07-22 22:01:25 +03:00
styled-modal-dialog.js Web: Components: Increase font in Components when rtl 2023-11-09 17:43:16 +01:00

ModalDialog

ModalDialog is used for displaying modal dialogs

Usage

import ModalDialog from "@docspace/components/modal-dialog";
<ModalDialog visible={false} scale={false} displayType="auto" zIndex={310}>
  <ModalDialog.Header>"Change password"</ModalDialog.Header>
  <ModalDialog.Body>
    <div>
      Send the password change instruction to the{" "}
      <a href="mailto:asc@story.book">asc@story.book</a> email address
    </div>
  </ModalDialog.Body>
  <ModalDialog.Footer>
    <Button
      label="Send"
      size="big"
      primary={true}
      onClick={() => alert("It's works!")}
    />
  </ModalDialog.Footer>
</ModalDialog>

Properties

Props Type Required Values Default Description
visible bool - - - Display dialog or not
displayType oneOf - auto, modal, aside auto Display type
scale bool - - - Indicates the side panel has scale
onClose func - - - Will be triggered when a close button is clicked
zIndex number - - 310 CSS z-index
modalBodyPadding string - - 16px 0 CSS padding props for modal body section
asideBodyPadding string - - 16px 0 CSS padding props for aside body section