@stenajs-webui/modal 19.0.4 → 20.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (29) hide show
  1. package/dist/building-blocks/ModalActionButtons.d.ts +6 -0
  2. package/dist/building-blocks/ModalBody.d.ts +5 -0
  3. package/dist/building-blocks/ModalHeader.d.ts +6 -0
  4. package/dist/building-blocks/ModalHeading.d.ts +5 -0
  5. package/dist/common-types.d.ts +3 -0
  6. package/dist/{components → declarative-modals}/drawer/Drawer.d.ts +1 -3
  7. package/dist/{components/center-modal/CenterModal.d.ts → declarative-modals/modal/Modal.d.ts} +1 -1
  8. package/dist/{components/modal/BaseModal.d.ts → declarative-modals/window/BaseWindow.d.ts} +2 -2
  9. package/dist/declarative-modals/window/Window.d.ts +11 -0
  10. package/dist/declarative-modals/window/WindowFooter.d.ts +6 -0
  11. package/dist/{components/modal/ModalHeader.d.ts → declarative-modals/window/WindowHeader.d.ts} +2 -2
  12. package/dist/dialog/DialogCommands.d.ts +3 -0
  13. package/dist/dialog/DialogContext.d.ts +7 -0
  14. package/dist/dialog/UseDialog.d.ts +23 -0
  15. package/dist/dialog/UseDialogPromise.d.ts +2 -0
  16. package/dist/dialog/alert/UseAlertDialog.d.ts +3 -0
  17. package/dist/dialog/drawer/UseDrawerDialog.d.ts +7 -0
  18. package/dist/dialog/modal/UseModalDialog.d.ts +3 -0
  19. package/dist/index.d.ts +20 -8
  20. package/dist/index.es.js +412 -191
  21. package/dist/index.es.js.map +1 -1
  22. package/dist/index.js +2 -2
  23. package/dist/index.js.map +1 -1
  24. package/dist/ready-made-modals/InfoAlert.d.ts +13 -0
  25. package/package.json +12 -5
  26. package/dist/components/modal/Modal.d.ts +0 -11
  27. package/dist/components/modal/ModalFooter.d.ts +0 -6
  28. /package/dist/{components → declarative-modals}/drawer/DrawerHeader.d.ts +0 -0
  29. /package/dist/{components → declarative-modals}/loading-modal/LoadingModal.d.ts +0 -0
package/dist/index.es.js CHANGED
@@ -1,48 +1,49 @@
1
- (function(){"use strict";try{var o=document.createElement("style");o.appendChild(document.createTextNode("._overlay_5x3op_1{--swui-modal-animation-time: var(--swui-animation-time-fast);--swui-modal-overlay-bg-color: var(--swui-overlay-bg-color);--swui-modal-content-bg-color: var(--swui-white);--swui-modal-width: 960px;--swui-modal-max-width: 100%;--swui-modal-header-border-color: var(--lhds-color-ui-300);--swui-modal-shadow: var(--swui-shadow-modal);--swui-modal-footer-shadow: var(--swui-shadow-modal);position:fixed;z-index:10;top:0;left:0;right:0;bottom:0;background-color:var(--swui-modal-overlay-bg-color);overflow:auto;display:flex;flex-direction:column;justify-content:flex-start;align-items:center;animation:_fadeIn_5x3op_1 var(--swui-modal-animation-time) cubic-bezier(.645,.045,.355,1) both}@media print{._overlay_5x3op_1{background-color:#fff}}._overlay_5x3op_1 ._modal_5x3op_31{max-width:100%;outline:none;pointer-events:none}@media (max-width: 768px){._overlay_5x3op_1 ._modal_5x3op_31{width:100%}}._overlay_5x3op_1 ._content_5x3op_41{position:relative;display:block;background:var(--swui-modal-content-bg-color);box-shadow:var(--swui-modal-shadow);pointer-events:all;top:calc(var(--swui-metrics-space) * 2);width:var(--swui-modal-width);max-width:var(--swui-modal-max-width)}@media (max-width: 768px){._overlay_5x3op_1 ._content_5x3op_41{top:0;width:100%;max-width:100%}}._overlay_5x3op_1 ._content_5x3op_41{animation:_appear_5x3op_1 var(--swui-animation-time-fast) cubic-bezier(.645,.045,.355,1) both}@media print{._overlay_5x3op_1 ._content_5x3op_41{box-shadow:none;top:0}}._overlay_5x3op_1 ._content_5x3op_41 :focus{outline:0}._overlay_5x3op_1 ._content_5x3op_41._isDraggable_5x3op_70 .draggable-modal-handle{cursor:move}._overlay_5x3op_1 ._content_5x3op_41._isDraggable_5x3op_70 .draggable-modal-handle .draggable-modal-cancel,._overlay_5x3op_1 ._content_5x3op_41._isDraggable_5x3op_70 .draggable-modal-handle [role=tooltip]{cursor:initial}@keyframes _fadeIn_5x3op_1{0%{background-color:var(--swui-hidden)}to{background-color:var(--swui-modal-overlay-bg-color)}}@keyframes _appear_5x3op_1{0%{opacity:0}to{opacity:1}}._footer_5x3op_101{background-color:var(--swui-modal-content-bg-color)}._stickyFooter_5x3op_105{position:-webkit-sticky;position:sticky;bottom:0;box-shadow:var(--swui-modal-footer-shadow)}@media print{._stickyFooter_5x3op_105{position:static;box-shadow:none}}._portal_17ze5_1{--drawer-width: 370px}._portal_17ze5_1 ._overlay_17ze5_4{position:fixed;inset:0}._portal_17ze5_1 ._content_17ze5_9{box-shadow:var(--swui-shadow-modal);background:white;position:absolute;transition:transform var(--swui-animation-time-medium) ease-in-out}._portal_17ze5_1 ._content_17ze5_9._floating_17ze5_15{margin:var(--swui-metrics-space);border-radius:var(--swui-border-radius)}@media (max-width: 768px){._portal_17ze5_1 ._content_17ze5_9._floating_17ze5_15{margin:0;border-radius:0}}._portal_17ze5_1 ._content_17ze5_9:focus-visible{outline:unset}._portal_17ze5_1 ._content_17ze5_9._slideFromLeft_17ze5_29,._portal_17ze5_1 ._content_17ze5_9._slideFromRight_17ze5_30{transform:translate(var(--translate-x-outside-screen, 0));overflow-y:auto;top:0;bottom:0}._portal_17ze5_1 ._content_17ze5_9._slideFromLeft_17ze5_29._afterOpen_17ze5_36,._portal_17ze5_1 ._content_17ze5_9._slideFromRight_17ze5_30._afterOpen_17ze5_36{transform:translate(0)}._portal_17ze5_1 ._content_17ze5_9._slideFromLeft_17ze5_29._beforeClose_17ze5_40,._portal_17ze5_1 ._content_17ze5_9._slideFromRight_17ze5_30._beforeClose_17ze5_40{transform:translate(var(--translate-x-outside-screen))}._portal_17ze5_1 ._content_17ze5_9._slideFromTop_17ze5_45,._portal_17ze5_1 ._content_17ze5_9._slideFromBottom_17ze5_46{transform:translateY(var(--translate-y-outside-screen, 0));overflow-x:auto;left:0;right:0}._portal_17ze5_1 ._content_17ze5_9._slideFromTop_17ze5_45._afterOpen_17ze5_36,._portal_17ze5_1 ._content_17ze5_9._slideFromBottom_17ze5_46._afterOpen_17ze5_36{transform:translateY(0)}._portal_17ze5_1 ._content_17ze5_9._slideFromTop_17ze5_45._beforeClose_17ze5_40,._portal_17ze5_1 ._content_17ze5_9._slideFromBottom_17ze5_46._beforeClose_17ze5_40{transform:translateY(var(--translate-y-outside-screen))}._portal_17ze5_1 ._content_17ze5_9._slideFromLeft_17ze5_29{--translate-x-outside-screen: -100%;width:var(--drawer-width);left:0}._portal_17ze5_1 ._content_17ze5_9._slideFromRight_17ze5_30{--translate-x-outside-screen: 100%;width:var(--drawer-width);right:0}._portal_17ze5_1 ._content_17ze5_9._slideFromTop_17ze5_45{--translate-y-outside-screen: -100%;height:var(--drawer-width);top:0}._portal_17ze5_1 ._content_17ze5_9._slideFromBottom_17ze5_46{--translate-y-outside-screen: 100%;height:var(--drawer-width);bottom:0}._modal_4fwgb_1{display:flex;justify-content:center;align-items:center;position:fixed;top:0;left:0;right:0;bottom:0;background-color:transparent}._overlay_4fwgb_13{position:fixed;top:0;left:0;right:0;bottom:0;background-color:var(--swui-overlay-bg-color)}")),document.head.appendChild(o)}catch(e){console.error("vite-plugin-css-injected-by-js",e)}})();
2
- import { jsx as e, jsxs as l, Fragment as y } from "react/jsx-runtime";
3
- import p from "react-modal";
4
- import I from "react-draggable";
5
- import h from "classnames";
6
- import { exhaustSwitchCase as B, Spacing as b, Row as c, Space as u, Heading as C, Column as F, Box as _, Indent as A, Txt as D } from "@stenajs-webui/core";
7
- import { Icon as w, FlatButton as L, stenaTimes as M, Spinner as k, CloseButton as O } from "@stenajs-webui/elements";
8
- import { cssColor as R } from "@stenajs-webui/theme";
9
- const $ = "_overlay_5x3op_1", E = "_fadeIn_5x3op_1", j = "_modal_5x3op_31", G = "_content_5x3op_41", H = "_appear_5x3op_1", T = "_isDraggable_5x3op_70", J = "_footer_5x3op_101", K = "_stickyFooter_5x3op_105", s = {
10
- overlay: $,
11
- fadeIn: E,
12
- modal: j,
13
- content: G,
14
- appear: H,
15
- isDraggable: T,
16
- footer: J,
17
- stickyFooter: K
18
- }, x = "draggable-modal-handle", N = "draggable-modal-cancel", Q = ({
19
- width: o,
20
- maxWidth: t,
21
- draggable: n = !1,
1
+ (function(){"use strict";try{if(typeof document<"u"){var o=document.createElement("style");o.appendChild(document.createTextNode("._overlay_5x3op_1{--swui-modal-animation-time: var(--swui-animation-time-fast);--swui-modal-overlay-bg-color: var(--swui-overlay-bg-color);--swui-modal-content-bg-color: var(--swui-white);--swui-modal-width: 960px;--swui-modal-max-width: 100%;--swui-modal-header-border-color: var(--lhds-color-ui-300);--swui-modal-shadow: var(--swui-shadow-modal);--swui-modal-footer-shadow: var(--swui-shadow-modal);position:fixed;z-index:10;top:0;left:0;right:0;bottom:0;background-color:var(--swui-modal-overlay-bg-color);overflow:auto;display:flex;flex-direction:column;justify-content:flex-start;align-items:center;animation:_fadeIn_5x3op_1 var(--swui-modal-animation-time) cubic-bezier(.645,.045,.355,1) both}@media print{._overlay_5x3op_1{background-color:#fff}}._overlay_5x3op_1 ._modal_5x3op_31{max-width:100%;outline:none;pointer-events:none}@media (max-width: 768px){._overlay_5x3op_1 ._modal_5x3op_31{width:100%}}._overlay_5x3op_1 ._content_5x3op_41{position:relative;display:block;background:var(--swui-modal-content-bg-color);box-shadow:var(--swui-modal-shadow);pointer-events:all;top:calc(var(--swui-metrics-space) * 2);width:var(--swui-modal-width);max-width:var(--swui-modal-max-width)}@media (max-width: 768px){._overlay_5x3op_1 ._content_5x3op_41{top:0;width:100%;max-width:100%}}._overlay_5x3op_1 ._content_5x3op_41{animation:_appear_5x3op_1 var(--swui-animation-time-fast) cubic-bezier(.645,.045,.355,1) both}@media print{._overlay_5x3op_1 ._content_5x3op_41{box-shadow:none;top:0}}._overlay_5x3op_1 ._content_5x3op_41 :focus{outline:0}._overlay_5x3op_1 ._content_5x3op_41._isDraggable_5x3op_70 .draggable-modal-handle{cursor:move}._overlay_5x3op_1 ._content_5x3op_41._isDraggable_5x3op_70 .draggable-modal-handle .draggable-modal-cancel,._overlay_5x3op_1 ._content_5x3op_41._isDraggable_5x3op_70 .draggable-modal-handle [role=tooltip]{cursor:initial}@keyframes _fadeIn_5x3op_1{0%{background-color:var(--swui-hidden)}to{background-color:var(--swui-modal-overlay-bg-color)}}@keyframes _appear_5x3op_1{0%{opacity:0}to{opacity:1}}._footer_5x3op_101{background-color:var(--swui-modal-content-bg-color)}._stickyFooter_5x3op_105{position:-webkit-sticky;position:sticky;bottom:0;box-shadow:var(--swui-modal-footer-shadow)}@media print{._stickyFooter_5x3op_105{position:static;box-shadow:none}}._portal_17ze5_1{--drawer-width: 370px}._portal_17ze5_1 ._overlay_17ze5_4{position:fixed;top:0;right:0;bottom:0;left:0}._portal_17ze5_1 ._content_17ze5_9{box-shadow:var(--swui-shadow-modal);background:#fff;position:absolute;transition:transform var(--swui-animation-time-medium) ease-in-out}._portal_17ze5_1 ._content_17ze5_9._floating_17ze5_15{margin:var(--swui-metrics-space);border-radius:var(--swui-border-radius)}@media (max-width: 768px){._portal_17ze5_1 ._content_17ze5_9._floating_17ze5_15{margin:0;border-radius:0}}._portal_17ze5_1 ._content_17ze5_9:focus-visible{outline:unset}._portal_17ze5_1 ._content_17ze5_9._slideFromLeft_17ze5_29,._portal_17ze5_1 ._content_17ze5_9._slideFromRight_17ze5_30{transform:translate(var(--translate-x-outside-screen, 0));overflow-y:auto;top:0;bottom:0}._portal_17ze5_1 ._content_17ze5_9._slideFromLeft_17ze5_29._afterOpen_17ze5_36,._portal_17ze5_1 ._content_17ze5_9._slideFromRight_17ze5_30._afterOpen_17ze5_36{transform:translate(0)}._portal_17ze5_1 ._content_17ze5_9._slideFromLeft_17ze5_29._beforeClose_17ze5_40,._portal_17ze5_1 ._content_17ze5_9._slideFromRight_17ze5_30._beforeClose_17ze5_40{transform:translate(var(--translate-x-outside-screen))}._portal_17ze5_1 ._content_17ze5_9._slideFromTop_17ze5_45,._portal_17ze5_1 ._content_17ze5_9._slideFromBottom_17ze5_46{transform:translateY(var(--translate-y-outside-screen, 0));overflow-x:auto;left:0;right:0}._portal_17ze5_1 ._content_17ze5_9._slideFromTop_17ze5_45._afterOpen_17ze5_36,._portal_17ze5_1 ._content_17ze5_9._slideFromBottom_17ze5_46._afterOpen_17ze5_36{transform:translateY(0)}._portal_17ze5_1 ._content_17ze5_9._slideFromTop_17ze5_45._beforeClose_17ze5_40,._portal_17ze5_1 ._content_17ze5_9._slideFromBottom_17ze5_46._beforeClose_17ze5_40{transform:translateY(var(--translate-y-outside-screen))}._portal_17ze5_1 ._content_17ze5_9._slideFromLeft_17ze5_29{--translate-x-outside-screen: -100%;width:var(--drawer-width);left:0}._portal_17ze5_1 ._content_17ze5_9._slideFromRight_17ze5_30{--translate-x-outside-screen: 100%;width:var(--drawer-width);right:0}._portal_17ze5_1 ._content_17ze5_9._slideFromTop_17ze5_45{--translate-y-outside-screen: -100%;height:var(--drawer-width);top:0}._portal_17ze5_1 ._content_17ze5_9._slideFromBottom_17ze5_46{--translate-y-outside-screen: 100%;height:var(--drawer-width);bottom:0}._overlay_1rolx_1{--swui-modal-animation-time: var(--swui-animation-time-fast);--swui-modal-overlay-bg-color: var(--swui-overlay-bg-color);--swui-modal-content-bg-color: var(--swui-white);--swui-modal-width: 960px;--swui-modal-max-width: 100%;--swui-modal-header-border-color: var(--lhds-color-ui-300);--swui-modal-shadow: var(--swui-shadow-modal);--swui-modal-footer-shadow: var(--swui-shadow-modal);position:fixed;z-index:10;top:0;left:0;right:0;bottom:0;background-color:var(--swui-modal-overlay-bg-color);overflow:auto;display:flex;flex-direction:column;justify-content:flex-start;align-items:center;animation:_fadeIn_1rolx_1 var(--swui-modal-animation-time) cubic-bezier(.645,.045,.355,1) both}@media print{._overlay_1rolx_1{background-color:#fff}}._overlay_1rolx_1 ._modal_1rolx_31{max-width:100%;outline:none;pointer-events:none}@media (max-width: 768px){._overlay_1rolx_1 ._modal_1rolx_31{width:100%}}._overlay_1rolx_1 ._content_1rolx_41{position:relative;display:block;background:var(--swui-modal-content-bg-color);box-shadow:var(--swui-modal-shadow);border-radius:var(--swui-border-radius-large);pointer-events:all;width:var(--swui-modal-width);max-width:var(--swui-modal-max-width)}@media (max-width: 768px){._overlay_1rolx_1 ._content_1rolx_41{border-radius:0;width:100%;max-width:100%;height:100vh}}._overlay_1rolx_1 ._content_1rolx_41{animation:_appear_1rolx_1 var(--swui-animation-time-fast) cubic-bezier(.645,.045,.355,1) both}@media print{._overlay_1rolx_1 ._content_1rolx_41{box-shadow:none;top:0}}._overlay_1rolx_1 ._content_1rolx_41 :focus{outline:0}._overlay_1rolx_1 ._content_1rolx_41._isDraggable_1rolx_71 .draggable-modal-handle{cursor:move}._overlay_1rolx_1 ._content_1rolx_41._isDraggable_1rolx_71 .draggable-modal-handle .draggable-modal-cancel,._overlay_1rolx_1 ._content_1rolx_41._isDraggable_1rolx_71 .draggable-modal-handle [role=tooltip]{cursor:initial}@keyframes _fadeIn_1rolx_1{0%{background-color:var(--swui-hidden)}to{background-color:var(--swui-modal-overlay-bg-color)}}@keyframes _appear_1rolx_1{0%{opacity:0}to{opacity:1}}._footer_1rolx_102{background-color:var(--swui-modal-content-bg-color)}._stickyFooter_1rolx_106{position:-webkit-sticky;position:sticky;bottom:0;box-shadow:var(--swui-modal-footer-shadow)}@media print{._stickyFooter_1rolx_106{position:static;box-shadow:none}}._modal_4fwgb_1{display:flex;justify-content:center;align-items:center;position:fixed;top:0;left:0;right:0;bottom:0;background-color:transparent}._overlay_4fwgb_13{position:fixed;top:0;left:0;right:0;bottom:0;background-color:var(--swui-overlay-bg-color)}._alertDialog_14t8t_1{border:0;outline:0;border-radius:var(--swui-border-radius-large);margin:auto;padding:0;overscroll-behavior:contain;opacity:0;pointer-events:none;box-shadow:#0003 0 0 10px 4px}._alertDialog_14t8t_1:not([open]){display:none}._alertDialog_14t8t_1[open]{opacity:1;pointer-events:auto;animation:_slideIn_14t8t_1 .25s forwards}._alertDialog_14t8t_1._closing_14t8t_22[open]{animation:_slideOut_14t8t_1 .25s forwards}._alertDialog_14t8t_1::backdrop{position:fixed;top:0;right:0;bottom:0;left:0;background-color:#0d0e1080;animation:_fadeIn_14t8t_1 .25s forwards}._alertDialog_14t8t_1._closing_14t8t_22::backdrop{animation:_fadeOut_14t8t_1 .25s forwards}@keyframes _fadeIn_14t8t_1{0%{opacity:0}to{opacity:1}}@keyframes _fadeOut_14t8t_1{0%{opacity:1}to{opacity:0}}@keyframes _slideIn_14t8t_1{0%{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}@keyframes _slideOut_14t8t_1{0%{transform:translateY(0);opacity:1}to{transform:translateY(-100%);opacity:0}}._drawerDialog_3e8xf_1{max-height:100%;max-width:100%;border:0;outline:0;margin:0;padding:0;overscroll-behavior:contain;box-shadow:#0003 0 0 10px 4px;position:fixed}._drawerDialog_3e8xf_1._left_3e8xf_12,._drawerDialog_3e8xf_1._right_3e8xf_13{height:100%;top:0;bottom:0}._drawerDialog_3e8xf_1._left_3e8xf_12 ._contentWrapper_3e8xf_18,._drawerDialog_3e8xf_1._right_3e8xf_13 ._contentWrapper_3e8xf_18{height:100%}@media (max-width: 768px){._drawerDialog_3e8xf_1._left_3e8xf_12,._drawerDialog_3e8xf_1._right_3e8xf_13{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}}._drawerDialog_3e8xf_1._left_3e8xf_12{left:0;right:unset}._drawerDialog_3e8xf_1._left_3e8xf_12[open]{animation:_slideInLeft_3e8xf_1 .25s forwards}._drawerDialog_3e8xf_1._left_3e8xf_12._closing_3e8xf_35[open]{animation:_slideOutLeft_3e8xf_1 .25s forwards}._drawerDialog_3e8xf_1._right_3e8xf_13{left:unset;right:0}._drawerDialog_3e8xf_1._right_3e8xf_13[open]{animation:_slideInRight_3e8xf_1 .25s forwards}._drawerDialog_3e8xf_1._right_3e8xf_13._closing_3e8xf_35[open]{animation:_slideOutRight_3e8xf_1 .25s forwards}._drawerDialog_3e8xf_1._top_3e8xf_53,._drawerDialog_3e8xf_1._bottom_3e8xf_54{width:100%;left:0;right:0}@media (max-width: 768px){._drawerDialog_3e8xf_1._top_3e8xf_53,._drawerDialog_3e8xf_1._bottom_3e8xf_54{height:-webkit-fit-content;height:-moz-fit-content;height:fit-content}}._drawerDialog_3e8xf_1._top_3e8xf_53{top:0;bottom:unset}._drawerDialog_3e8xf_1._top_3e8xf_53[open]{animation:_slideInTop_3e8xf_1 .25s forwards}._drawerDialog_3e8xf_1._top_3e8xf_53._closing_3e8xf_35[open]{animation:_slideOutTop_3e8xf_1 .25s forwards}._drawerDialog_3e8xf_1._bottom_3e8xf_54{top:unset;bottom:0}._drawerDialog_3e8xf_1._bottom_3e8xf_54[open]{animation:_slideInBottom_3e8xf_1 .25s forwards}._drawerDialog_3e8xf_1._bottom_3e8xf_54._closing_3e8xf_35[open]{animation:_slideOutBottom_3e8xf_1 .25s forwards}._drawerDialog_3e8xf_1[open]{opacity:1;pointer-events:auto}@keyframes _slideInLeft_3e8xf_1{0%{transform:translate(-100%);opacity:0}to{transform:translate(0);opacity:1}}@keyframes _slideOutLeft_3e8xf_1{0%{transform:translate(0);opacity:0}to{transform:translate(-100%);opacity:1}}@keyframes _slideInTop_3e8xf_1{0%{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}@keyframes _slideOutTop_3e8xf_1{0%{transform:translateY(0);opacity:0}to{transform:translateY(-100%);opacity:1}}@keyframes _slideInRight_3e8xf_1{0%{transform:translate(100%);opacity:0}to{transform:translate(0);opacity:1}}@keyframes _slideOutRight_3e8xf_1{0%{transform:translate(0);opacity:0}to{transform:translate(100%);opacity:1}}@keyframes _slideInBottom_3e8xf_1{0%{transform:translateY(100%);opacity:0}to{transform:translateY(0);opacity:1}}@keyframes _slideOutBottom_3e8xf_1{0%{transform:translateY(0);opacity:0}to{transform:translateY(100%);opacity:1}}._modalDialog_1czrs_1{border:0;outline:0;margin:auto;padding:0;overscroll-behavior:contain;opacity:0;pointer-events:none;box-shadow:#0003 0 0 10px 4px}@media (min-width: 769px){._modalDialog_1czrs_1{border-radius:var(--swui-border-radius-large)}}._modalDialog_1czrs_1:not([open]){display:none}._modalDialog_1czrs_1[open]{opacity:1;pointer-events:auto;animation:_slideIn_1czrs_1 .25s forwards}._modalDialog_1czrs_1._closing_1czrs_25[open]{animation:_slideOut_1czrs_1 .25s forwards}@media (max-width: 768px){._modalDialog_1czrs_1{margin:0;width:100%;max-width:100%;height:100%;max-height:100%}}._modalDialog_1czrs_1::backdrop{position:fixed;top:0;right:0;bottom:0;left:0;background-color:#0d0e1080;animation:_fadeIn_1czrs_1 .25s forwards}._modalDialog_1czrs_1._closing_1czrs_25::backdrop{animation:_fadeOut_1czrs_1 .25s forwards}@keyframes _fadeIn_1czrs_1{0%{opacity:0}to{opacity:1}}@keyframes _fadeOut_1czrs_1{0%{opacity:1}to{opacity:0}}@keyframes _slideIn_1czrs_1{0%{transform:translateY(-100%);opacity:0}to{transform:translateY(0);opacity:1}}@keyframes _slideOut_1czrs_1{0%{transform:translateY(0);opacity:1}to{transform:translateY(-100%);opacity:0}}._modalActionButtons_s27nj_1{display:flex;flex-direction:row;gap:16px;justify-content:center}@media (max-width: 768px){._modalActionButtons_s27nj_1{flex-direction:column;justify-content:stretch}}")),document.head.appendChild(o)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})();
2
+ import { jsx as t, jsxs as s, Fragment as F } from "react/jsx-runtime";
3
+ import B from "react-modal";
4
+ import q from "react-draggable";
5
+ import d from "classnames";
6
+ import { exhaustSwitchCase as p, Spacing as S, Row as y, Space as j, Heading as M, Column as V, Box as N, Indent as ee, Txt as le, Text as te } from "@stenajs-webui/core";
7
+ import { Icon as J, FlatButton as ae, stenaTimes as re, Spinner as ce, CloseButton as K, CircledIcon as ne } from "@stenajs-webui/elements";
8
+ import { cssColor as se } from "@stenajs-webui/theme";
9
+ import { createContext as de, useRef as I, useReducer as oe, useState as H, useCallback as R, useMemo as ie, createElement as P, useContext as _e } from "react";
10
+ const me = "_overlay_5x3op_1", ue = "_fadeIn_5x3op_1", fe = "_modal_5x3op_31", ge = "_content_5x3op_41", he = "_appear_5x3op_1", Ce = "_isDraggable_5x3op_70", ye = "_footer_5x3op_101", xe = "_stickyFooter_5x3op_105", v = {
11
+ overlay: me,
12
+ fadeIn: ue,
13
+ modal: fe,
14
+ content: ge,
15
+ appear: he,
16
+ isDraggable: Ce,
17
+ footer: ye,
18
+ stickyFooter: xe
19
+ }, Q = "draggable-modal-handle", U = "draggable-modal-cancel", ve = ({
20
+ width: l,
21
+ maxWidth: e,
22
+ draggable: a = !1,
22
23
  children: r,
23
- ...i
24
- }) => /* @__PURE__ */ e(
25
- p,
24
+ ...c
25
+ }) => /* @__PURE__ */ t(
26
+ B,
26
27
  {
27
- overlayClassName: s.overlay,
28
- className: s.modal,
29
- ...i,
30
- children: /* @__PURE__ */ e(
31
- I,
28
+ overlayClassName: v.overlay,
29
+ className: v.modal,
30
+ ...c,
31
+ children: /* @__PURE__ */ t(
32
+ q,
32
33
  {
33
- handle: `.${x}`,
34
- cancel: `.${N}, button, [role="tooltip"]`,
34
+ handle: `.${Q}`,
35
+ cancel: `.${U}, button, [role="tooltip"]`,
35
36
  bounds: ".ReactModal__Overlay",
36
- disabled: !n,
37
- children: /* @__PURE__ */ e(
37
+ disabled: !a,
38
+ children: /* @__PURE__ */ t(
38
39
  "div",
39
40
  {
40
41
  style: {
41
- ["--swui-modal-width"]: o,
42
- ["--swui-modal-max-width"]: t
42
+ "--swui-modal-width": l,
43
+ "--swui-modal-max-width": e
43
44
  },
44
- className: h(s.content, {
45
- [s.isDraggable]: n
45
+ className: d(v.content, {
46
+ [v.isDraggable]: a
46
47
  }),
47
48
  children: r
48
49
  }
@@ -50,141 +51,154 @@ const $ = "_overlay_5x3op_1", E = "_fadeIn_5x3op_1", j = "_modal_5x3op_31", G =
50
51
  }
51
52
  )
52
53
  }
53
- ), U = "_portal_17ze5_1", V = "_overlay_17ze5_4", W = "_content_17ze5_9", X = "_floating_17ze5_15", Y = "_slideFromLeft_17ze5_29", Z = "_slideFromRight_17ze5_30", q = "_afterOpen_17ze5_36", P = "_beforeClose_17ze5_40", ee = "_slideFromTop_17ze5_45", oe = "_slideFromBottom_17ze5_46", a = {
54
- portal: U,
55
- overlay: V,
56
- content: W,
57
- floating: X,
58
- slideFromLeft: Y,
59
- slideFromRight: Z,
60
- afterOpen: q,
61
- beforeClose: P,
62
- slideFromTop: ee,
63
- slideFromBottom: oe
64
- }, he = ({
65
- background: o,
66
- zIndex: t,
67
- children: n,
54
+ ), Ne = "_portal_17ze5_1", be = "_overlay_17ze5_4", Oe = "_content_17ze5_9", Ie = "_floating_17ze5_15", we = "_slideFromLeft_17ze5_29", De = "_slideFromRight_17ze5_30", $e = "_afterOpen_17ze5_36", Fe = "_beforeClose_17ze5_40", Be = "_slideFromTop_17ze5_45", ke = "_slideFromBottom_17ze5_46", n = {
55
+ portal: Ne,
56
+ overlay: be,
57
+ content: Oe,
58
+ floating: Ie,
59
+ slideFromLeft: we,
60
+ slideFromRight: De,
61
+ afterOpen: $e,
62
+ beforeClose: Fe,
63
+ slideFromTop: Be,
64
+ slideFromBottom: ke
65
+ }, kl = ({
66
+ background: l,
67
+ zIndex: e,
68
+ children: a,
68
69
  slideFrom: r = "left",
69
- portalTarget: i,
70
- floating: f,
71
- ...d
70
+ portalTarget: c,
71
+ floating: g,
72
+ ...o
72
73
  }) => {
73
- const { height: g, width: m } = d;
74
- return /* @__PURE__ */ e(
75
- p,
74
+ const { height: m, width: i } = o;
75
+ return /* @__PURE__ */ t(
76
+ B,
76
77
  {
77
78
  closeTimeoutMS: 250,
78
- portalClassName: a.portal,
79
+ portalClassName: n.portal,
79
80
  overlayClassName: {
80
- base: a.overlay,
81
- afterOpen: a.afterOpen,
82
- beforeClose: a.beforeClose
81
+ base: n.overlay,
82
+ afterOpen: n.afterOpen,
83
+ beforeClose: n.beforeClose
83
84
  },
84
85
  className: {
85
- base: h(
86
- a.content,
87
- te(r),
88
- f && a.floating
86
+ base: d(
87
+ n.content,
88
+ ze(r),
89
+ g && n.floating
89
90
  ),
90
- afterOpen: a.afterOpen,
91
- beforeClose: a.beforeClose
91
+ afterOpen: n.afterOpen,
92
+ beforeClose: n.beforeClose
92
93
  },
93
- style: { content: { width: m, height: g, background: o }, overlay: { zIndex: t } },
94
- parentSelector: i ? () => i : void 0,
95
- ...d,
96
- children: n
94
+ style: { content: { width: i, height: m, background: l }, overlay: { zIndex: e } },
95
+ parentSelector: c ? () => c : void 0,
96
+ ...o,
97
+ children: a
97
98
  }
98
99
  );
99
- }, te = (o) => {
100
- switch (o) {
100
+ }, ze = (l) => {
101
+ switch (l) {
101
102
  case "left":
102
- return a.slideFromLeft;
103
+ return n.slideFromLeft;
103
104
  case "right":
104
- return a.slideFromRight;
105
+ return n.slideFromRight;
105
106
  case "top":
106
- return a.slideFromTop;
107
+ return n.slideFromTop;
107
108
  case "bottom":
108
- return a.slideFromBottom;
109
+ return n.slideFromBottom;
109
110
  default:
110
- return B(o, a.slideFromLeft);
111
+ return p(l, n.slideFromLeft);
111
112
  }
112
- }, ye = ({
113
- header: o,
114
- contentRight: t,
115
- onRequestClose: n,
113
+ }, zl = ({
114
+ header: l,
115
+ contentRight: e,
116
+ onRequestClose: a,
116
117
  icon: r
117
- }) => /* @__PURE__ */ e(
118
- b,
118
+ }) => /* @__PURE__ */ t(
119
+ S,
119
120
  {
120
121
  position: "sticky",
121
122
  top: 0,
122
123
  zIndex: 100,
123
- background: R("--lhds-color-ui-50"),
124
- children: /* @__PURE__ */ l(
125
- c,
124
+ background: se("--lhds-color-ui-50"),
125
+ children: /* @__PURE__ */ s(
126
+ y,
126
127
  {
127
128
  justifyContent: "space-between",
128
129
  alignItems: "center",
129
130
  height: "48px",
130
131
  children: [
131
- /* @__PURE__ */ l(c, { alignItems: "center", gap: 2, children: [
132
- /* @__PURE__ */ e(u, { num: 1 }),
133
- r && /* @__PURE__ */ e(w, { icon: r, size: 24 }),
134
- /* @__PURE__ */ e(C, { variant: "h4", children: o })
132
+ /* @__PURE__ */ s(y, { alignItems: "center", gap: 2, children: [
133
+ /* @__PURE__ */ t(j, { num: 1 }),
134
+ r && /* @__PURE__ */ t(J, { icon: r, size: 24 }),
135
+ /* @__PURE__ */ t(M, { variant: "h4", children: l })
135
136
  ] }),
136
- /* @__PURE__ */ l(c, { gap: 1, children: [
137
- t,
138
- /* @__PURE__ */ e(
139
- L,
137
+ /* @__PURE__ */ s(y, { gap: 1, children: [
138
+ e,
139
+ /* @__PURE__ */ t(
140
+ ae,
140
141
  {
141
- leftIcon: M,
142
- onClick: n,
142
+ leftIcon: re,
143
+ onClick: a,
143
144
  variant: "danger"
144
145
  }
145
146
  ),
146
- /* @__PURE__ */ e(u, { num: 0.5 })
147
+ /* @__PURE__ */ t(j, { num: 0.5 })
147
148
  ] })
148
149
  ]
149
150
  }
150
151
  )
151
152
  }
152
- ), ne = { overlay: { justifyContent: "center" } }, ue = ({
153
- children: o,
154
- ...t
155
- }) => /* @__PURE__ */ e(
156
- p,
153
+ ), Re = "_overlay_1rolx_1", Ae = "_fadeIn_1rolx_1", Le = "_modal_1rolx_31", We = "_content_1rolx_41", Se = "_appear_1rolx_1", Me = "_isDraggable_1rolx_71", Ee = "_footer_1rolx_102", Te = "_stickyFooter_1rolx_106", A = {
154
+ overlay: Re,
155
+ fadeIn: Ae,
156
+ modal: Le,
157
+ content: We,
158
+ appear: Se,
159
+ isDraggable: Me,
160
+ footer: Ee,
161
+ stickyFooter: Te
162
+ }, je = { overlay: { justifyContent: "center" } }, Rl = ({
163
+ children: l,
164
+ ...e
165
+ }) => /* @__PURE__ */ t(
166
+ B,
157
167
  {
158
- overlayClassName: s.overlay,
159
- className: s.modal,
160
- style: ne,
161
- ...t,
162
- children: /* @__PURE__ */ e(
168
+ overlayClassName: A.overlay,
169
+ className: A.modal,
170
+ style: je,
171
+ ...e,
172
+ children: /* @__PURE__ */ t(
163
173
  "div",
164
174
  {
165
- className: s.content,
166
- style: { ["--swui-modal-width"]: "fit-content" },
167
- children: o
175
+ className: A.content,
176
+ style: { "--swui-modal-width": "fit-content" },
177
+ children: l
168
178
  }
169
179
  )
170
180
  }
171
- ), ae = "_modal_4fwgb_1", re = "_overlay_4fwgb_13", v = {
172
- modal: ae,
173
- overlay: re
174
- }, ve = ({
175
- headerIconLeft: o,
176
- headerText: t,
177
- ...n
178
- }) => /* @__PURE__ */ e(
179
- p,
181
+ ), He = "_modal_4fwgb_1", Pe = "_overlay_4fwgb_13", G = {
182
+ modal: He,
183
+ overlay: Pe
184
+ }, Al = ({
185
+ headerIconLeft: l,
186
+ headerText: e,
187
+ shouldCloseOnOverlayClick: a = !1,
188
+ shouldCloseOnEsc: r = !1,
189
+ ...c
190
+ }) => /* @__PURE__ */ t(
191
+ B,
180
192
  {
181
- ...n,
193
+ ...c,
182
194
  isOpen: !0,
183
- className: v.modal,
184
- overlayClassName: v.overlay,
185
- children: /* @__PURE__ */ l(F, { spacing: 2, alignItems: "center", children: [
186
- /* @__PURE__ */ e(
187
- _,
195
+ shouldCloseOnOverlayClick: a,
196
+ shouldCloseOnEsc: r,
197
+ className: G.modal,
198
+ overlayClassName: G.overlay,
199
+ children: /* @__PURE__ */ s(V, { spacing: 2, alignItems: "center", children: [
200
+ /* @__PURE__ */ t(
201
+ N,
188
202
  {
189
203
  alignItems: "center",
190
204
  justifyContent: "center",
@@ -193,90 +207,297 @@ const $ = "_overlay_5x3op_1", E = "_fadeIn_5x3op_1", j = "_modal_5x3op_31", G =
193
207
  borderRadius: "50%",
194
208
  background: "white",
195
209
  shadow: "modal",
196
- children: /* @__PURE__ */ e(k, { size: "small" })
210
+ children: /* @__PURE__ */ t(ce, { size: "small" })
197
211
  }
198
212
  ),
199
- (o || t) && /* @__PURE__ */ l(y, { children: [
200
- /* @__PURE__ */ e(b, {}),
201
- /* @__PURE__ */ l(c, { indent: 2, children: [
202
- o && /* @__PURE__ */ l(y, { children: [
203
- /* @__PURE__ */ e(w, { size: 14, icon: o, color: "white" }),
204
- /* @__PURE__ */ e(A, {})
213
+ (l || e) && /* @__PURE__ */ s(F, { children: [
214
+ /* @__PURE__ */ t(S, {}),
215
+ /* @__PURE__ */ s(y, { indent: 2, children: [
216
+ l && /* @__PURE__ */ s(F, { children: [
217
+ /* @__PURE__ */ t(J, { size: 14, icon: l, color: "white" }),
218
+ /* @__PURE__ */ t(ee, {})
205
219
  ] }),
206
- t && /* @__PURE__ */ e(C, { variant: "h4", color: "white", children: t })
220
+ e && /* @__PURE__ */ t(M, { variant: "h4", color: "white", children: e })
207
221
  ] })
208
222
  ] })
209
223
  ] })
210
224
  }
211
- ), le = ({
212
- onRequestClose: o,
213
- header: t,
214
- headerText: n,
225
+ ), Ge = ({
226
+ onRequestClose: l,
227
+ header: e,
228
+ headerText: a,
215
229
  closeButtonClassName: r
216
- }) => /* @__PURE__ */ l(
217
- c,
230
+ }) => /* @__PURE__ */ s(
231
+ y,
218
232
  {
219
233
  spacing: 2,
220
234
  indent: 2,
221
- borderBottom: "1px solid var(--swui-modal-header-border-color)",
222
- className: x,
235
+ borderBottom: "1px solid var(--lhds-color-ui-300)",
236
+ className: Q,
223
237
  children: [
224
- /* @__PURE__ */ l(c, { flex: 1, indent: !0, alignItems: "center", children: [
225
- n && /* @__PURE__ */ e(D, { className: N, size: "large", children: n }),
226
- t
238
+ /* @__PURE__ */ s(y, { flex: 1, indent: !0, alignItems: "center", children: [
239
+ a && /* @__PURE__ */ t(le, { className: U, size: "large", children: a }),
240
+ e
227
241
  ] }),
228
- /* @__PURE__ */ e(_, { alignSelf: "flex-start", children: /* @__PURE__ */ e(
229
- O,
242
+ /* @__PURE__ */ t(N, { alignSelf: "flex-start", children: /* @__PURE__ */ t(
243
+ K,
230
244
  {
231
245
  className: r,
232
- onClick: o
246
+ onClick: l
233
247
  }
234
248
  ) })
235
249
  ]
236
250
  }
237
- ), be = ({
238
- header: o,
239
- headerText: t,
240
- children: n,
251
+ ), Ll = ({
252
+ header: l,
253
+ headerText: e,
254
+ children: a,
241
255
  spacing: r,
242
- indent: i,
243
- draggable: f = !1,
244
- onRequestClose: d,
245
- closeButtonClassName: g,
246
- footer: m,
247
- disableStickyFooter: z = !1,
248
- ...S
249
- }) => /* @__PURE__ */ l(Q, { ...S, onRequestClose: d, draggable: f, children: [
250
- /* @__PURE__ */ e(
251
- le,
252
- {
253
- onRequestClose: d,
254
- header: o,
255
- headerText: t,
256
- closeButtonClassName: g
257
- }
258
- ),
259
- /* @__PURE__ */ e(_, { spacing: typeof r == "number" ? r : 1, indent: typeof i == "number" ? i : 1, children: n }),
260
- m && /* @__PURE__ */ e(
261
- _,
262
- {
263
- className: h(s.footer, {
264
- [s.stickyFooter]: !z
265
- }),
266
- children: m
267
- }
268
- )
269
- ] }), Ce = ({ children: o }) => /* @__PURE__ */ e(F, { indent: 2, spacing: 2, children: o });
256
+ indent: c,
257
+ draggable: g = !1,
258
+ onRequestClose: o,
259
+ closeButtonClassName: m,
260
+ footer: i,
261
+ disableStickyFooter: x = !1,
262
+ ...b
263
+ }) => /* @__PURE__ */ s(
264
+ ve,
265
+ {
266
+ ...b,
267
+ onRequestClose: o,
268
+ draggable: g,
269
+ children: [
270
+ /* @__PURE__ */ t(
271
+ Ge,
272
+ {
273
+ onRequestClose: o,
274
+ header: l,
275
+ headerText: e,
276
+ closeButtonClassName: m
277
+ }
278
+ ),
279
+ /* @__PURE__ */ t(N, { spacing: typeof r == "number" ? r : 1, indent: typeof c == "number" ? c : 1, children: a }),
280
+ i && /* @__PURE__ */ t(
281
+ N,
282
+ {
283
+ className: d(v.footer, {
284
+ [v.stickyFooter]: !x
285
+ }),
286
+ children: i
287
+ }
288
+ )
289
+ ]
290
+ }
291
+ ), Wl = ({ children: l }) => /* @__PURE__ */ t(V, { indent: 2, spacing: 2, children: l }), X = de(
292
+ void 0
293
+ );
294
+ function E(l, e) {
295
+ const a = I(null), r = e.ref ?? a, [c, g] = oe((_) => _ + 1, 0), o = I(), m = I(), i = I(), x = I(), [b, w] = H(!1), [k, O] = H(!1), z = l, Z = R(
296
+ (_) => {
297
+ var u, f;
298
+ return o.current = new Promise(
299
+ (h, C) => {
300
+ m.current = h, x.current = C;
301
+ }
302
+ ), O(!1), w(!0), g(), i.current = _, e != null && e.modal ? (u = r.current) == null || u.showModal() : (f = r.current) == null || f.show(), o.current;
303
+ },
304
+ [r, e == null ? void 0 : e.modal]
305
+ ), T = R(
306
+ (_) => {
307
+ var u;
308
+ O(!0), (u = r.current) == null || u.addEventListener(
309
+ "animationend",
310
+ () => {
311
+ var f, h, C;
312
+ O(!1), w(!1), (f = r.current) == null || f.close(), (h = m.current) == null || h.call(m, _), i.current = void 0, (C = e == null ? void 0 : e.onResolve) == null || C.call(e);
313
+ },
314
+ { once: !0 }
315
+ );
316
+ },
317
+ [r, e]
318
+ ), D = R(
319
+ (_) => {
320
+ var u;
321
+ O(!0), (u = r.current) == null || u.addEventListener(
322
+ "animationend",
323
+ () => {
324
+ var f, h, C;
325
+ O(!1), w(!1), (f = r.current) == null || f.close(), (h = x.current) == null || h.call(x, _), (C = e == null ? void 0 : e.onReject) == null || C.call(e), i.current = void 0;
326
+ },
327
+ { once: !0 }
328
+ );
329
+ },
330
+ [r, e]
331
+ );
332
+ return [ie(
333
+ () => /* @__PURE__ */ t(X.Provider, { value: { resolve: T, reject: D }, children: /* @__PURE__ */ t(
334
+ "dialog",
335
+ {
336
+ onClick: e != null && e.disableCloseOnClickOutside ? void 0 : () => D(),
337
+ ref: r,
338
+ className: d(
339
+ e == null ? void 0 : e.className,
340
+ k && (e == null ? void 0 : e.closingClassName)
341
+ ),
342
+ style: e == null ? void 0 : e.dialogStyle,
343
+ children: e != null && e.disableCloseOnClickOutside ? /* @__PURE__ */ t(F, { children: b && /* @__PURE__ */ P(z, { ...i.current, key: c }) }) : /* @__PURE__ */ t(
344
+ "div",
345
+ {
346
+ className: e == null ? void 0 : e.contentWrapperClassName,
347
+ onClick: e != null && e.disableCloseOnClickOutside ? void 0 : (_) => _.stopPropagation(),
348
+ children: b && /* @__PURE__ */ P(z, { ...i.current, key: c })
349
+ }
350
+ )
351
+ }
352
+ ) }),
353
+ [
354
+ T,
355
+ D,
356
+ e == null ? void 0 : e.disableCloseOnClickOutside,
357
+ e == null ? void 0 : e.className,
358
+ e == null ? void 0 : e.closingClassName,
359
+ e == null ? void 0 : e.dialogStyle,
360
+ e == null ? void 0 : e.contentWrapperClassName,
361
+ r,
362
+ k,
363
+ b,
364
+ z,
365
+ c
366
+ ]
367
+ ), { show: Z, reject: D }];
368
+ }
369
+ const Sl = () => {
370
+ const l = _e(X);
371
+ if (l == null)
372
+ throw new Error("useDialogPromise is being used outside of dialog.");
373
+ return l;
374
+ }, Ve = "_alertDialog_14t8t_1", Je = "_slideIn_14t8t_1", Ke = "_closing_14t8t_22", Qe = "_slideOut_14t8t_1", Ue = "_fadeIn_14t8t_1", Xe = "_fadeOut_14t8t_1", L = {
375
+ alertDialog: Ve,
376
+ slideIn: Je,
377
+ closing: Ke,
378
+ slideOut: Qe,
379
+ fadeIn: Ue,
380
+ fadeOut: Xe
381
+ };
382
+ function Ml(l, e) {
383
+ return E(l, {
384
+ ...e,
385
+ modal: !0,
386
+ closingClassName: d(e == null ? void 0 : e.closingClassName, L.closing),
387
+ contentWrapperClassName: d(
388
+ e == null ? void 0 : e.contentWrapperClassName,
389
+ L.contentWrapper
390
+ ),
391
+ className: d(e == null ? void 0 : e.className, L.alertDialog)
392
+ });
393
+ }
394
+ const Ye = "_drawerDialog_3e8xf_1", Ze = "_left_3e8xf_12", qe = "_right_3e8xf_13", pe = "_contentWrapper_3e8xf_18", el = "_slideInLeft_3e8xf_1", ll = "_closing_3e8xf_35", tl = "_slideOutLeft_3e8xf_1", al = "_slideInRight_3e8xf_1", rl = "_slideOutRight_3e8xf_1", cl = "_top_3e8xf_53", nl = "_bottom_3e8xf_54", sl = "_slideInTop_3e8xf_1", dl = "_slideOutTop_3e8xf_1", ol = "_slideInBottom_3e8xf_1", il = "_slideOutBottom_3e8xf_1", $ = {
395
+ drawerDialog: Ye,
396
+ left: Ze,
397
+ right: qe,
398
+ contentWrapper: pe,
399
+ slideInLeft: el,
400
+ closing: ll,
401
+ slideOutLeft: tl,
402
+ slideInRight: al,
403
+ slideOutRight: rl,
404
+ top: cl,
405
+ bottom: nl,
406
+ slideInTop: sl,
407
+ slideOutTop: dl,
408
+ slideInBottom: ol,
409
+ slideOutBottom: il
410
+ };
411
+ function El(l, e = "left", a) {
412
+ return E(l, {
413
+ ...a,
414
+ disableCloseOnClickOutside: !0,
415
+ modal: !1,
416
+ closingClassName: d(a == null ? void 0 : a.closingClassName, $.closing),
417
+ contentWrapperClassName: d(
418
+ a == null ? void 0 : a.contentWrapperClassName,
419
+ $.contentWrapper
420
+ ),
421
+ className: d(a == null ? void 0 : a.className, $.drawerDialog, $[e])
422
+ });
423
+ }
424
+ const _l = "_modalDialog_1czrs_1", ml = "_slideIn_1czrs_1", ul = "_closing_1czrs_25", fl = "_slideOut_1czrs_1", gl = "_fadeIn_1czrs_1", hl = "_fadeOut_1czrs_1", W = {
425
+ modalDialog: _l,
426
+ slideIn: ml,
427
+ closing: ul,
428
+ slideOut: fl,
429
+ fadeIn: gl,
430
+ fadeOut: hl
431
+ };
432
+ function Tl(l, e) {
433
+ return E(l, {
434
+ ...e,
435
+ modal: !0,
436
+ closingClassName: d(e == null ? void 0 : e.closingClassName, W.closing),
437
+ contentWrapperClassName: d(
438
+ e == null ? void 0 : e.contentWrapperClassName,
439
+ W.contentWrapper
440
+ ),
441
+ className: d(e == null ? void 0 : e.className, W.modalDialog)
442
+ });
443
+ }
444
+ const Y = ({ children: l }) => /* @__PURE__ */ t(M, { variant: "h3", as: "h2", children: l }), Cl = "_modalActionButtons_s27nj_1", yl = {
445
+ modalActionButtons: Cl
446
+ }, xl = ({
447
+ buttons: l
448
+ }) => /* @__PURE__ */ t("div", { className: yl.modalActionButtons, children: l }), vl = ({ gap: l = 2, ...e }) => /* @__PURE__ */ t(N, { indent: 4, spacing: 4, gap: l, ...e }), jl = ({
449
+ icon: l,
450
+ buttons: e,
451
+ heading: a,
452
+ text: r,
453
+ children: c,
454
+ maxWidth: g,
455
+ minWidth: o
456
+ }) => /* @__PURE__ */ s(
457
+ vl,
458
+ {
459
+ flexDirection: "column",
460
+ alignItems: "center",
461
+ maxWidth: g,
462
+ minWidth: o,
463
+ children: [
464
+ l && /* @__PURE__ */ t(ne, { icon: l, size: "large" }),
465
+ /* @__PURE__ */ t(Y, { children: a }),
466
+ r && /* @__PURE__ */ t(te, { textAlign: "center", children: r }),
467
+ c,
468
+ e && /* @__PURE__ */ t(F, { children: /* @__PURE__ */ s(N, { width: "100%", children: [
469
+ /* @__PURE__ */ t(S, {}),
470
+ /* @__PURE__ */ t(xl, { buttons: e })
471
+ ] }) })
472
+ ]
473
+ }
474
+ ), Hl = ({
475
+ heading: l,
476
+ onClickClose: e
477
+ }) => /* @__PURE__ */ s(y, { justifyContent: "space-between", children: [
478
+ l && /* @__PURE__ */ t(Y, { children: l }),
479
+ /* @__PURE__ */ t(K, { onClick: e })
480
+ ] });
270
481
  export {
271
- Q as BaseModal,
272
- ue as CenterModal,
273
- N as DRAGGABLE_CANCEL_CLASSNAME,
274
- x as DRAGGABLE_HANDLE_CLASSNAME,
275
- he as Drawer,
276
- ye as DrawerHeader,
277
- ve as LoadingModal,
278
- be as Modal,
279
- Ce as ModalFooter,
280
- le as ModalHeader
482
+ ve as BaseWindow,
483
+ U as DRAGGABLE_CANCEL_CLASSNAME,
484
+ Q as DRAGGABLE_HANDLE_CLASSNAME,
485
+ kl as Drawer,
486
+ zl as DrawerHeader,
487
+ jl as InfoAlert,
488
+ Al as LoadingModal,
489
+ Rl as Modal,
490
+ xl as ModalActionButtons,
491
+ vl as ModalBody,
492
+ Hl as ModalHeader,
493
+ Y as ModalHeading,
494
+ Ll as Window,
495
+ Wl as WindowFooter,
496
+ Ge as WindowHeader,
497
+ Ml as useAlertDialog,
498
+ E as useDialog,
499
+ Sl as useDialogPromise,
500
+ El as useDrawerDialog,
501
+ Tl as useModalDialog
281
502
  };
282
503
  //# sourceMappingURL=index.es.js.map