primereact 10.6.5 → 10.6.6

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 (169) hide show
  1. package/README.md +1 -1
  2. package/api/api.d.ts +8 -0
  3. package/chart/chart.d.ts +1 -13
  4. package/column/column.d.ts +6 -0
  5. package/core/core.js +94 -30
  6. package/core/core.min.js +8 -8
  7. package/datatable/datatable.cjs.js +56 -46
  8. package/datatable/datatable.cjs.min.js +1 -1
  9. package/datatable/datatable.esm.js +56 -46
  10. package/datatable/datatable.esm.min.js +1 -1
  11. package/datatable/datatable.js +56 -46
  12. package/datatable/datatable.min.js +1 -1
  13. package/dialog/dialog.cjs.js +5 -3
  14. package/dialog/dialog.cjs.min.js +1 -1
  15. package/dialog/dialog.esm.js +5 -3
  16. package/dialog/dialog.esm.min.js +1 -1
  17. package/dialog/dialog.js +5 -3
  18. package/dialog/dialog.min.js +1 -1
  19. package/dropdown/dropdown.cjs.js +3 -3
  20. package/dropdown/dropdown.cjs.min.js +1 -1
  21. package/dropdown/dropdown.esm.js +3 -3
  22. package/dropdown/dropdown.esm.min.js +1 -1
  23. package/dropdown/dropdown.js +3 -3
  24. package/dropdown/dropdown.min.js +1 -1
  25. package/galleria/galleria.cjs.js +7 -0
  26. package/galleria/galleria.cjs.min.js +1 -1
  27. package/galleria/galleria.esm.js +8 -1
  28. package/galleria/galleria.esm.min.js +1 -1
  29. package/galleria/galleria.js +7 -0
  30. package/galleria/galleria.min.js +1 -1
  31. package/inputnumber/inputnumber.cjs.js +14 -11
  32. package/inputnumber/inputnumber.cjs.min.js +1 -1
  33. package/inputnumber/inputnumber.esm.js +14 -11
  34. package/inputnumber/inputnumber.esm.min.js +1 -1
  35. package/inputnumber/inputnumber.js +14 -11
  36. package/inputnumber/inputnumber.min.js +1 -1
  37. package/inputotp/inputotp.cjs.js +25 -1
  38. package/inputotp/inputotp.cjs.min.js +1 -1
  39. package/inputotp/inputotp.esm.js +26 -2
  40. package/inputotp/inputotp.esm.min.js +1 -1
  41. package/inputotp/inputotp.js +25 -1
  42. package/inputotp/inputotp.min.js +1 -1
  43. package/keyfilter/keyfilter.cjs.js +1 -1
  44. package/keyfilter/keyfilter.cjs.min.js +1 -1
  45. package/keyfilter/keyfilter.esm.js +1 -1
  46. package/keyfilter/keyfilter.esm.min.js +1 -1
  47. package/keyfilter/keyfilter.js +1 -1
  48. package/keyfilter/keyfilter.min.js +1 -1
  49. package/metergroup/metergroup.cjs.js +2 -1
  50. package/metergroup/metergroup.cjs.min.js +1 -1
  51. package/metergroup/metergroup.esm.js +2 -1
  52. package/metergroup/metergroup.esm.min.js +1 -1
  53. package/metergroup/metergroup.js +2 -1
  54. package/metergroup/metergroup.min.js +1 -1
  55. package/multiselect/multiselect.cjs.js +2 -2
  56. package/multiselect/multiselect.cjs.min.js +1 -1
  57. package/multiselect/multiselect.esm.js +2 -2
  58. package/multiselect/multiselect.esm.min.js +1 -1
  59. package/multiselect/multiselect.js +2 -2
  60. package/multiselect/multiselect.min.js +1 -1
  61. package/package.json +1 -1
  62. package/paginator/paginator.cjs.js +1 -1
  63. package/paginator/paginator.cjs.min.js +1 -1
  64. package/paginator/paginator.esm.js +1 -1
  65. package/paginator/paginator.esm.min.js +1 -1
  66. package/paginator/paginator.js +1 -1
  67. package/paginator/paginator.min.js +1 -1
  68. package/panelmenu/panelmenu.cjs.js +13 -12
  69. package/panelmenu/panelmenu.cjs.min.js +1 -1
  70. package/panelmenu/panelmenu.esm.js +13 -12
  71. package/panelmenu/panelmenu.esm.min.js +1 -1
  72. package/panelmenu/panelmenu.js +13 -12
  73. package/panelmenu/panelmenu.min.js +1 -1
  74. package/password/password.cjs.js +2 -2
  75. package/password/password.cjs.min.js +1 -1
  76. package/password/password.esm.js +2 -2
  77. package/password/password.esm.min.js +1 -1
  78. package/password/password.js +2 -2
  79. package/password/password.min.js +1 -1
  80. package/primereact.all.cjs.js +2859 -1916
  81. package/primereact.all.cjs.min.js +1 -1
  82. package/primereact.all.esm.js +2856 -1917
  83. package/primereact.all.esm.min.js +1 -1
  84. package/primereact.all.js +2859 -1916
  85. package/primereact.all.min.js +1 -1
  86. package/resources/themes/arya-blue/theme.css +62 -0
  87. package/resources/themes/arya-green/theme.css +62 -0
  88. package/resources/themes/arya-orange/theme.css +62 -0
  89. package/resources/themes/bootstrap4-dark-blue/theme.css +62 -0
  90. package/resources/themes/bootstrap4-dark-purple/theme.css +207 -43
  91. package/resources/themes/bootstrap4-light-blue/theme.css +62 -0
  92. package/resources/themes/bootstrap4-light-purple/theme.css +207 -43
  93. package/resources/themes/fluent-light/theme.css +62 -0
  94. package/resources/themes/lara-dark-amber/theme.css +62 -9
  95. package/resources/themes/lara-dark-blue/theme.css +62 -9
  96. package/resources/themes/lara-dark-cyan/theme.css +62 -9
  97. package/resources/themes/lara-dark-green/theme.css +62 -9
  98. package/resources/themes/lara-dark-indigo/theme.css +62 -9
  99. package/resources/themes/lara-dark-pink/theme.css +62 -9
  100. package/resources/themes/lara-dark-teal/theme.css +62 -9
  101. package/resources/themes/lara-light-amber/theme.css +62 -9
  102. package/resources/themes/lara-light-blue/theme.css +62 -9
  103. package/resources/themes/lara-light-cyan/theme.css +62 -9
  104. package/resources/themes/lara-light-green/theme.css +62 -9
  105. package/resources/themes/lara-light-indigo/theme.css +62 -9
  106. package/resources/themes/lara-light-pink/theme.css +62 -9
  107. package/resources/themes/lara-light-teal/theme.css +62 -9
  108. package/resources/themes/luna-amber/theme.css +62 -0
  109. package/resources/themes/luna-blue/theme.css +62 -0
  110. package/resources/themes/luna-green/theme.css +62 -0
  111. package/resources/themes/luna-pink/theme.css +62 -0
  112. package/resources/themes/md-dark-deeppurple/theme.css +225 -43
  113. package/resources/themes/md-dark-indigo/theme.css +213 -151
  114. package/resources/themes/md-light-deeppurple/theme.css +225 -43
  115. package/resources/themes/md-light-indigo/theme.css +62 -0
  116. package/resources/themes/mdc-dark-deeppurple/theme.css +225 -43
  117. package/resources/themes/mdc-dark-indigo/theme.css +213 -151
  118. package/resources/themes/mdc-light-deeppurple/theme.css +225 -43
  119. package/resources/themes/mdc-light-indigo/theme.css +62 -0
  120. package/resources/themes/mira/theme.css +62 -0
  121. package/resources/themes/nano/theme.css +62 -0
  122. package/resources/themes/nova/theme.css +62 -0
  123. package/resources/themes/nova-accent/theme.css +62 -0
  124. package/resources/themes/nova-alt/theme.css +62 -0
  125. package/resources/themes/rhea/theme.css +62 -0
  126. package/resources/themes/saga-blue/theme.css +62 -0
  127. package/resources/themes/saga-green/theme.css +62 -0
  128. package/resources/themes/saga-orange/theme.css +62 -0
  129. package/resources/themes/soho-dark/theme.css +87 -25
  130. package/resources/themes/soho-light/theme.css +62 -0
  131. package/resources/themes/tailwind-light/theme.css +62 -0
  132. package/resources/themes/vela-blue/theme.css +62 -0
  133. package/resources/themes/vela-green/theme.css +62 -0
  134. package/resources/themes/vela-orange/theme.css +62 -0
  135. package/resources/themes/viva-dark/theme.css +62 -0
  136. package/resources/themes/viva-light/theme.css +62 -0
  137. package/tabview/tabview.cjs.js +0 -2
  138. package/tabview/tabview.cjs.min.js +1 -1
  139. package/tabview/tabview.esm.js +0 -2
  140. package/tabview/tabview.esm.min.js +1 -1
  141. package/tabview/tabview.js +0 -2
  142. package/tabview/tabview.min.js +1 -1
  143. package/tooltip/tooltip.cjs.js +2 -2
  144. package/tooltip/tooltip.cjs.min.js +1 -1
  145. package/tooltip/tooltip.esm.js +2 -2
  146. package/tooltip/tooltip.esm.min.js +1 -1
  147. package/tooltip/tooltip.js +2 -2
  148. package/tooltip/tooltip.min.js +1 -1
  149. package/tree/tree.cjs.js +45 -8
  150. package/tree/tree.cjs.min.js +1 -1
  151. package/tree/tree.esm.js +45 -8
  152. package/tree/tree.esm.min.js +1 -1
  153. package/tree/tree.js +45 -8
  154. package/tree/tree.min.js +1 -1
  155. package/treetable/treetable.cjs.js +240 -7
  156. package/treetable/treetable.cjs.min.js +1 -1
  157. package/treetable/treetable.d.ts +29 -0
  158. package/treetable/treetable.esm.js +240 -7
  159. package/treetable/treetable.esm.min.js +1 -1
  160. package/treetable/treetable.js +240 -7
  161. package/treetable/treetable.min.js +1 -1
  162. package/utils/utils.d.ts +7 -4
  163. package/virtualscroller/virtualscroller.cjs.js +23 -1
  164. package/virtualscroller/virtualscroller.cjs.min.js +1 -1
  165. package/virtualscroller/virtualscroller.esm.js +23 -1
  166. package/virtualscroller/virtualscroller.esm.min.js +1 -1
  167. package/virtualscroller/virtualscroller.js +23 -1
  168. package/virtualscroller/virtualscroller.min.js +1 -1
  169. package/web-types.json +66 -28
@@ -326,7 +326,7 @@ var classes = {
326
326
  },
327
327
  transition: 'p-dialog'
328
328
  };
329
- var styles = "\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n \n .p-dialog-visible {\n display: flex;\n }\n \n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n \n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n \n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n \n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n \n .p-dialog-footer {\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n \n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n \n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n \n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n \n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n \n .p-dialog-enter-done {\n transform: none;\n }\n \n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n \n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n \n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n \n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n \n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n \n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n \n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n \n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n \n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n \n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n \n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n \n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n \n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n } \n}\n";
329
+ var styles = "\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n\n .p-dialog-visible {\n display: flex;\n }\n\n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n\n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n\n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n\n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .p-dialog-footer {\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n\n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n\n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n\n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n\n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n\n .p-dialog-enter-done {\n transform: none;\n }\n\n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n\n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n\n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n\n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n\n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n\n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n\n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n\n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n\n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n\n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n\n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n\n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n\n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n }\n}\n";
330
330
  var inlineStyles = {
331
331
  mask: function mask(_ref6) {
332
332
  var props = _ref6.props;
@@ -679,7 +679,6 @@ var Dialog = /*#__PURE__*/React__namespace.forwardRef(function (inProps, ref) {
679
679
  }
680
680
  };
681
681
  var onExited = function onExited() {
682
- props.onHide && props.onHide();
683
682
  dragging.current = false;
684
683
  utils.ZIndexUtils.clear(maskRef.current);
685
684
  setMaskVisibleState(false);
@@ -848,7 +847,10 @@ var Dialog = /*#__PURE__*/React__namespace.forwardRef(function (inProps, ref) {
848
847
  type: 'button',
849
848
  className: cx('closeButton'),
850
849
  'aria-label': ariaLabel,
851
- onClick: onClose
850
+ onClick: onClose,
851
+ onKeyDown: function onKeyDown(ev) {
852
+ return ev.stopPropagation();
853
+ }
852
854
  }, ptm('closeButton'));
853
855
  return /*#__PURE__*/React__namespace.createElement("button", closeButtonProps, headerCloseIcon, /*#__PURE__*/React__namespace.createElement(ripple.Ripple, null));
854
856
  }
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("primereact/api"),n=require("primereact/componentbase"),r=require("primereact/csstransition"),o=require("primereact/hooks"),i=require("primereact/utils"),a=require("primereact/icons/times"),l=require("primereact/icons/windowmaximize"),c=require("primereact/icons/windowminimize"),s=require("primereact/portal"),u=require("primereact/ripple");function p(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function d(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}var m=p(e),f=d(e),g=p(t);function b(){return b=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},b.apply(this,arguments)}function h(e){return h="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},h(e)}function y(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function v(e){if(Array.isArray(e))return y(e)}function x(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function O(e,t){if(e){if("string"==typeof e)return y(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?y(e,t):void 0}}function w(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function E(e,t){if("object"!==h(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==h(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function D(e){var t=E(e,"string");return"symbol"===h(t)?t:String(t)}function S(e,t,n){return(t=D(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function P(e){if(Array.isArray(e))return e}function j(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw o}}return l}}function z(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function I(e,t){return P(e)||j(e,t)||O(e,t)||z()}var k=n.ComponentBase.extend({defaultProps:{__TYPE:"FocusTrap",children:void 0},css:{styles:""},getProps:function(e){return i.ObjectUtils.getMergedProps(e,k.defaultProps)},getOtherProps:function(e){return i.ObjectUtils.getDiffProps(e,k.defaultProps)}});function C(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function H(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?C(Object(n),!0).forEach((function(t){S(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):C(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var R=m.default.memo(m.default.forwardRef((function(e,n){var r=m.default.useRef(null),a=m.default.useRef(null),l=m.default.useRef(null),c=m.default.useContext(t.PrimeReactContext),s=k.getProps(e,c),u={props:s};o.useStyle(k.css.styles,{name:"focustrap"});k.setMetaData(H({},u));m.default.useImperativeHandle(n,(function(){return{props:s,getInk:function(){return a.current},getTarget:function(){return r.current}}})),o.useMountEffect((function(){s.disabled||(r.current=h(),y(r.current))}));var p,d,f,g,b,h=function(){return a.current&&a.current.parentElement},y=function(e){var t=s||{},n=t.autoFocusSelector,r=t.firstFocusableSelector,o=void 0===r?"":r,a=t.autoFocus,l=void 0!==a&&a,c=i.DomHandler.getFirstFocusableElement(e,"[autofocus]".concat(v(void 0===n?"":n)));l&&!c&&(c=i.DomHandler.getFirstFocusableElement(e,v(o))),i.DomHandler.focus(c)},v=function(e){return':not(.p-hidden-focusable):not([data-p-hidden-focusable="true"])'.concat(null!=e?e:"")},x=function(e){var t,n=e.currentTarget,o=e.relatedTarget,a=o!==n.$_pfocustrap_firsthiddenfocusableelement&&null!==(t=r.current)&&void 0!==t&&t.contains(o)?n.$_pfocustrap_firsthiddenfocusableelement:i.DomHandler.getLastFocusableElement(n.parentElement,v(n.$_pfocustrap_focusableselector));i.DomHandler.focus(a)};return d=void 0===(p=(s||{}).tabIndex)?0:p,g=(f=function(e,t){return m.default.createElement("span",{ref:"firstfocusableelement"===t?a:l,className:"p-hidden-accessible p-hidden-focusable",tabIndex:d,role:"presentation","aria-hidden":!0,"data-p-hidden-accessible":!0,"data-p-hidden-focusable":!0,onFocus:e,"data-pc-section":t})})((function(e){var t,n=e.currentTarget,o=e.relatedTarget,a=o!==n.$_pfocustrap_lasthiddenfocusableelement&&null!==(t=r.current)&&void 0!==t&&t.contains(o)?n.$_pfocustrap_lasthiddenfocusableelement:i.DomHandler.getFirstFocusableElement(n.parentElement,v(n.$_pfocustrap_focusableselector));i.DomHandler.focus(a)}),"firstfocusableelement"),b=f(x,"lastfocusableelement"),g.ref.current&&b.ref.current&&(g.ref.current.$_pfocustrap_lasthiddenfocusableelement=b.ref.current,b.ref.current.$_pfocustrap_firsthiddenfocusableelement=g.ref.current),m.default.createElement(m.default.Fragment,null,g,s.children,b)})));function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function N(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){S(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var M=n.ComponentBase.extend({defaultProps:{__TYPE:"Dialog",__parentMetadata:null,appendTo:null,ariaCloseIconLabel:null,baseZIndex:0,blockScroll:!1,breakpoints:null,className:null,closable:!0,closeIcon:null,closeOnEscape:!0,content:null,contentClassName:null,contentStyle:null,dismissableMask:!1,draggable:!0,focusOnShow:!0,footer:null,footerClassName:null,header:null,headerClassName:null,headerStyle:null,icons:null,id:null,keepInViewport:!0,maskClassName:null,maskStyle:null,maximizable:!1,maximizeIcon:null,maximized:!1,minX:0,minY:0,minimizeIcon:null,modal:!0,onClick:null,onDrag:null,onDragEnd:null,onDragStart:null,onHide:null,onMaskClick:null,onMaximize:null,onResize:null,onResizeEnd:null,onResizeStart:null,onShow:null,position:"center",resizable:!0,rtl:!1,showHeader:!0,style:null,transitionOptions:null,visible:!1,children:void 0},css:{classes:{closeButtonIcon:"p-dialog-header-close-icon",closeButton:"p-dialog-header-icon p-dialog-header-close p-link",maximizableIcon:"p-dialog-header-maximize-icon",maximizableButton:"p-dialog-header-icon p-dialog-header-maximize p-link",header:function(e){return i.classNames("p-dialog-header",e.props.headerClassName)},headerTitle:"p-dialog-title",headerIcons:"p-dialog-header-icons",content:function(e){return i.classNames("p-dialog-content",e.props.contentClassName)},footer:function(e){return i.classNames("p-dialog-footer",e.props.footerClassName)},mask:function(e){var t=e.props,n=e.maskVisibleState,r=["center","left","right","top","top-left","top-right","bottom","bottom-left","bottom-right"].find((function(e){return e===t.position||e.replace("-","")===t.position}));return i.classNames("p-dialog-mask",r?"p-dialog-".concat(r):"",{"p-component-overlay p-component-overlay-enter":t.modal,"p-dialog-visible":n,"p-dialog-draggable":t.draggable,"p-dialog-resizable":t.resizable},t.maskClassName)},root:function(e){var t=e.maximized,n=e.context;return i.classNames("p-dialog p-component",{"p-dialog-rtl":e.props.rtl,"p-dialog-maximized":t,"p-dialog-default":!t,"p-input-filled":n&&"filled"===n.inputStyle||"filled"===g.default.inputStyle,"p-ripple-disabled":n&&!1===n.ripple||!1===g.default.ripple})},transition:"p-dialog"},styles:"\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n \n .p-dialog-visible {\n display: flex;\n }\n \n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n \n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n \n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n \n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n \n .p-dialog-footer {\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n \n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n \n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n \n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n \n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n \n .p-dialog-enter-done {\n transform: none;\n }\n \n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n \n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n \n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n \n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n \n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n \n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n \n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n \n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n \n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n \n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n \n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n \n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n \n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n } \n}\n",inlineStyles:{mask:function(e){var t=e.props;return N({position:"fixed",height:"100%",width:"100%",left:0,top:0,display:"flex",justifyContent:"left"===t.position||"top-left"===t.position||"bottom-left"===t.position?"flex-start":"right"===t.position||"top-right"===t.position||"bottom-right"===t.position?"flex-end":"center",alignItems:"top"===t.position||"top-left"===t.position||"top-right"===t.position?"flex-start":"bottom"===t.position||"bottom-left"===t.position||"bottom-right"===t.position?"flex-end":"center",pointerEvents:!t.modal&&"none"},t.maskStyle)}}}});function T(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function B(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?T(Object(n),!0).forEach((function(t){S(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):T(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var F=f.forwardRef((function(e,p){var d=o.useMergeProps(),m=f.useContext(t.PrimeReactContext),h=M.getProps(e,m),y=h.id?h.id:i.UniqueComponentId(),E=I(f.useState(y),2),D=E[0],S=I(f.useState(!1),2),P=S[0],j=S[1],z=I(f.useState(!1),2),k=z[0],C=z[1],H=I(f.useState(h.maximized),2),_=H[0],N=H[1],T=f.useRef(null),F=f.useRef(null),U=f.useRef(null),X=f.useRef(null),A=f.useRef(null),q=f.useRef(null),L=f.useRef(null),Y=f.useRef(!1),$=f.useRef(!1),V=f.useRef(null),Z=f.useRef(null),J=f.useRef(null),W=f.useRef(y),G=f.useRef(null),K=h.onMaximize?h.maximized:_,Q=k&&(h.blockScroll||h.maximizable&&K),ee=h.closable&&h.closeOnEscape&&k,te=o.useDisplayOrder("dialog",ee),ne=M.setMetaData(B(B({props:h},h.__parentMetadata),{},{state:{id:D,maximized:K,containerVisible:P}})),re=ne.ptm,oe=ne.cx,ie=ne.sx,ae=ne.isUnstyled;n.useHandleStyle(M.css.styles,ae,{name:"dialog"}),o.useGlobalOnEscapeKey({callback:function(e){ve(e)},when:ee&&te,priority:[o.ESC_KEY_HANDLING_PRIORITIES.DIALOG,te]});var le=I(o.useEventListener({type:"mousemove",target:function(){return window.document},listener:function(e){return ze(e)}}),2),ce=le[0],se=le[1],ue=I(o.useEventListener({type:"mouseup",target:function(){return window.document},listener:function(e){return Ie(e)}}),2),pe=ue[0],de=ue[1],me=I(o.useEventListener({type:"mousemove",target:function(){return window.document},listener:function(e){return De(e)}}),2),fe=me[0],ge=me[1],be=I(o.useEventListener({type:"mouseup",target:function(){return window.document},listener:function(e){return Se(e)}}),2),he=be[0],ye=be[1],ve=function(e){h.onHide(),e.preventDefault()},xe=function(e){U.current=e.target,h.onPointerDown&&h.onPointerDown(e)},Oe=function(e){h.dismissableMask&&h.modal&&F.current===e.target&&!U.current&&ve(e),h.onMaskClick&&h.onMaskClick(e),U.current=null},we=function(e){h.onMaximize?h.onMaximize({originalEvent:e,maximized:!K}):N((function(e){return!e})),e.preventDefault()},Ee=function(e){i.DomHandler.hasClass(e.target,"p-dialog-header-icon")||i.DomHandler.hasClass(e.target.parentElement,"p-dialog-header-icon")||h.draggable&&(Y.current=!0,V.current=e.pageX,Z.current=e.pageY,T.current.style.margin="0",i.DomHandler.addClass(document.body,"p-unselectable-text"),h.onDragStart&&h.onDragStart(e))},De=function(e){if(Y.current){var t=i.DomHandler.getOuterWidth(T.current),n=i.DomHandler.getOuterHeight(T.current),r=e.pageX-V.current,o=e.pageY-Z.current,a=T.current.getBoundingClientRect(),l=a.left+r,c=a.top+o,s=i.DomHandler.getViewport(),u=getComputedStyle(T.current),p=parseFloat(u.marginLeft),d=parseFloat(u.marginTop);T.current.style.position="fixed",h.keepInViewport?(l>=h.minX&&l+t<s.width&&(V.current=e.pageX,T.current.style.left=l-p+"px"),c>=h.minY&&c+n<s.height&&(Z.current=e.pageY,T.current.style.top=c-d+"px")):(V.current=e.pageX,T.current.style.left=l-p+"px",Z.current=e.pageY,T.current.style.top=c-d+"px"),h.onDrag&&h.onDrag(e)}},Se=function(e){Y.current&&(Y.current=!1,i.DomHandler.removeClass(document.body,"p-unselectable-text"),h.onDragEnd&&h.onDragEnd(e))},Pe=function(e){h.resizable&&($.current=!0,V.current=e.pageX,Z.current=e.pageY,i.DomHandler.addClass(document.body,"p-unselectable-text"),h.onResizeStart&&h.onResizeStart(e))},je=function(e,t,n){!n&&(n=i.DomHandler.getViewport());var r=parseInt(e);return/^(\d+|(\.\d+))(\.\d+)?%$/.test(e)?r*(n[t]/100):r},ze=function(e){if($.current){var t=e.pageX-V.current,n=e.pageY-Z.current,r=i.DomHandler.getOuterWidth(T.current),o=i.DomHandler.getOuterHeight(T.current),a=T.current.getBoundingClientRect(),l=i.DomHandler.getViewport(),c=!parseInt(T.current.style.top)||!parseInt(T.current.style.left),s=je(T.current.style.minWidth,"width",l),u=je(T.current.style.minHeight,"height",l),p=r+t,d=o+n;c&&(p+=t,d+=n),(!s||p>s)&&a.left+p<l.width&&(T.current.style.width=p+"px"),(!u||d>u)&&a.top+d<l.height&&(T.current.style.height=d+"px"),V.current=e.pageX,Z.current=e.pageY,h.onResize&&h.onResize(e)}},Ie=function(e){$.current&&($.current=!1,i.DomHandler.removeClass(document.body,"p-unselectable-text"),h.onResizeEnd&&h.onResizeEnd(e))},ke=function(){T.current.style.position="",T.current.style.left="",T.current.style.top="",T.current.style.margin=""},Ce=function(){T.current.setAttribute(W.current,"")},He=function(){var e;h.onShow&&h.onShow(),h.focusOnShow&&!((e=document.activeElement)&&T.current&&T.current.contains(e))&&h.closable&&h.showHeader&&L.current&&L.current.focus(),Ne()},Re=function(){h.modal&&!ae()&&i.DomHandler.addClass(F.current,"p-component-overlay-leave")},_e=function(){h.onHide&&h.onHide(),Y.current=!1,i.ZIndexUtils.clear(F.current),j(!1),Me(),i.DomHandler.focus(G.current),G.current=null},Ne=function(){Be()},Me=function(){Fe()},Te=function(e){if(e&&k){var t={id:D,hasBlockScroll:Q};document.primeDialogParams||(document.primeDialogParams=[]);var n=document.primeDialogParams.findIndex((function(e){return e.id===D}));document.primeDialogParams=-1===n?[].concat(v(r=document.primeDialogParams)||x(r)||O(r)||w(),[t]):document.primeDialogParams.toSpliced(n,1,t)}else document.primeDialogParams=document.primeDialogParams&&document.primeDialogParams.filter((function(e){return e.id!==D}));var r;document.primeDialogParams&&document.primeDialogParams.some((function(e){return e.hasBlockScroll}))?i.DomHandler.blockBodyScroll():i.DomHandler.unblockBodyScroll()},Be=function(){h.draggable&&(fe(),he()),h.resizable&&(ce(),pe())},Fe=function(){ge(),ye(),se(),de()},Ue=function(){J.current=i.DomHandler.createInlineStyle(m&&m.nonce||g.default.nonce,m&&m.styleContainer);var e="";for(var t in h.breakpoints)e+="\n @media screen and (max-width: ".concat(t,') {\n [data-pc-name="dialog"][').concat(W.current,"] {\n width: ").concat(h.breakpoints[t]," !important;\n }\n }\n ");J.current.innerHTML=e};o.useMountEffect((function(){Te(!0),h.visible&&j(!0)})),f.useEffect((function(){return h.breakpoints&&Ue(),function(){J.current=i.DomHandler.removeInlineStyle(J.current)}}),[h.breakpoints]),o.useUpdateEffect((function(){h.visible&&!P&&j(!0),h.visible!==k&&P&&C(h.visible),h.visible&&(G.current=document.activeElement)}),[h.visible,P]),o.useUpdateEffect((function(){P&&(i.ZIndexUtils.set("modal",F.current,m&&m.autoZIndex||g.default.autoZIndex,h.baseZIndex||m&&m.zIndex.modal||g.default.zIndex.modal),C(!0))}),[P]),o.useUpdateEffect((function(){Te(!0)}),[Q,k]),o.useUnmountEffect((function(){Me(),Te(!1),i.DomHandler.removeInlineStyle(J.current),i.ZIndexUtils.clear(F.current)})),f.useImperativeHandle(p,(function(){return{props:h,resetPosition:ke,getElement:function(){return T.current},getMask:function(){return F.current},getContent:function(){return X.current},getHeader:function(){return A.current},getFooter:function(){return q.current},getCloseButton:function(){return L.current}}}));var Xe=function(){if(h.closable){var e=h.ariaCloseIconLabel||t.localeOption("close"),n=d({className:oe("closeButtonIcon"),"aria-hidden":!0},re("closeButtonIcon")),r=i.IconUtils.getJSXIcon(h.closeIcon||f.createElement(a.TimesIcon,n),B({},n),{props:h}),o=d({ref:L,type:"button",className:oe("closeButton"),"aria-label":e,onClick:ve},re("closeButton"));return f.createElement("button",o,r,f.createElement(u.Ripple,null))}return null},Ae=function(){var e=d({className:oe("maximizableIcon")},re("maximizableIcon")),t=i.IconUtils.getJSXIcon(K?h.minimizeIcon||f.createElement(c.WindowMinimizeIcon,e):h.maximizeIcon||f.createElement(l.WindowMaximizeIcon,e),e,{props:h});if(h.maximizable){var n=d({type:"button",className:oe("maximizableButton"),onClick:we},re("maximizableButton"));return f.createElement("button",n,t,f.createElement(u.Ripple,null))}return null},qe=function(){if(h.showHeader){var e=Xe(),t=Ae(),n=i.ObjectUtils.getJSXElement(h.icons,h),r=i.ObjectUtils.getJSXElement(h.header,h),o=D+"_header",a=d({ref:A,style:h.headerStyle,className:oe("header"),onMouseDown:Ee},re("header")),l=d({id:o,className:oe("headerTitle")},re("headerTitle")),c=d({className:oe("headerIcons")},re("headerIcons"));return f.createElement("div",a,f.createElement("div",l,r),f.createElement("div",c,n,t,e))}return null},Le=function(){var e=i.ObjectUtils.getJSXElement(h.footer,h),t=d({ref:q,className:oe("footer")},re("footer"));return e&&f.createElement("div",t,e)};return P&&function(){var t,n,o,a,l,c,u=D+"_header",p=D+"_content",g={enter:"center"===h.position?150:300,exit:"center"===h.position?150:300},y=d({ref:F,style:ie("mask"),className:oe("mask"),onPointerUp:Oe},re("mask")),v=d({ref:T,id:D,className:i.classNames(h.className,oe("root",{props:h,maximized:K,context:m})),style:h.style,onClick:h.onClick,role:"dialog","aria-labelledby":u,"aria-describedby":p,"aria-modal":h.modal,onPointerDown:xe},M.getOtherProps(h),re("root")),x=d({classNames:oe("transition"),timeout:g,in:k,options:h.transitionOptions,unmountOnExit:!0,onEnter:Ce,onEntered:He,onExiting:Re,onExited:_e},re("transition")),O=null;null!=e&&e.content?(c={header:h.header,content:h.message,message:null==h||null===(l=h.children)||void 0===l||null===(l=l[1])||void 0===l||null===(l=l.props)||void 0===l?void 0:l.children},O=i.ObjectUtils.getJSXElement(e.content,{headerRef:A,contentRef:X,footerRef:q,closeRef:L,hide:ve,message:c})):(n=qe(),t=d({id:D+"_content",ref:X,style:h.contentStyle,className:oe("content")},re("content")),o=f.createElement("div",t,h.children),a=Le(),O=f.createElement(f.Fragment,null,n,o,a,h.resizable?f.createElement("span",{className:"p-resizable-handle",style:{zIndex:90},onMouseDown:Pe}):null));var w=f.createElement("div",y,f.createElement(r.CSSTransition,b({nodeRef:T},x),f.createElement("div",v,f.createElement(R,{autoFocus:!0},O))));return f.createElement(s.Portal,{element:w,appendTo:h.appendTo,visible:!0})}()}));F.displayName="Dialog",exports.Dialog=F;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),t=require("primereact/api"),n=require("primereact/componentbase"),r=require("primereact/csstransition"),o=require("primereact/hooks"),i=require("primereact/utils"),a=require("primereact/icons/times"),l=require("primereact/icons/windowmaximize"),c=require("primereact/icons/windowminimize"),s=require("primereact/portal"),u=require("primereact/ripple");function p(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function d(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}var m=p(e),f=d(e),g=p(t);function b(){return b=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},b.apply(this,arguments)}function y(e){return y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},y(e)}function h(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function v(e){if(Array.isArray(e))return h(e)}function x(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function O(e,t){if(e){if("string"==typeof e)return h(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?h(e,t):void 0}}function w(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function E(e,t){if("object"!==y(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==y(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function D(e){var t=E(e,"string");return"symbol"===y(t)?t:String(t)}function S(e,t,n){return(t=D(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function P(e){if(Array.isArray(e))return e}function j(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw o}}return l}}function z(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function I(e,t){return P(e)||j(e,t)||O(e,t)||z()}var k=n.ComponentBase.extend({defaultProps:{__TYPE:"FocusTrap",children:void 0},css:{styles:""},getProps:function(e){return i.ObjectUtils.getMergedProps(e,k.defaultProps)},getOtherProps:function(e){return i.ObjectUtils.getDiffProps(e,k.defaultProps)}});function C(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?C(Object(n),!0).forEach((function(t){S(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):C(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var H=m.default.memo(m.default.forwardRef((function(e,n){var r=m.default.useRef(null),a=m.default.useRef(null),l=m.default.useRef(null),c=m.default.useContext(t.PrimeReactContext),s=k.getProps(e,c),u={props:s};o.useStyle(k.css.styles,{name:"focustrap"});k.setMetaData(R({},u));m.default.useImperativeHandle(n,(function(){return{props:s,getInk:function(){return a.current},getTarget:function(){return r.current}}})),o.useMountEffect((function(){s.disabled||(r.current=y(),h(r.current))}));var p,d,f,g,b,y=function(){return a.current&&a.current.parentElement},h=function(e){var t=s||{},n=t.autoFocusSelector,r=t.firstFocusableSelector,o=void 0===r?"":r,a=t.autoFocus,l=void 0!==a&&a,c=i.DomHandler.getFirstFocusableElement(e,"[autofocus]".concat(v(void 0===n?"":n)));l&&!c&&(c=i.DomHandler.getFirstFocusableElement(e,v(o))),i.DomHandler.focus(c)},v=function(e){return':not(.p-hidden-focusable):not([data-p-hidden-focusable="true"])'.concat(null!=e?e:"")},x=function(e){var t,n=e.currentTarget,o=e.relatedTarget,a=o!==n.$_pfocustrap_firsthiddenfocusableelement&&null!==(t=r.current)&&void 0!==t&&t.contains(o)?n.$_pfocustrap_firsthiddenfocusableelement:i.DomHandler.getLastFocusableElement(n.parentElement,v(n.$_pfocustrap_focusableselector));i.DomHandler.focus(a)};return d=void 0===(p=(s||{}).tabIndex)?0:p,g=(f=function(e,t){return m.default.createElement("span",{ref:"firstfocusableelement"===t?a:l,className:"p-hidden-accessible p-hidden-focusable",tabIndex:d,role:"presentation","aria-hidden":!0,"data-p-hidden-accessible":!0,"data-p-hidden-focusable":!0,onFocus:e,"data-pc-section":t})})((function(e){var t,n=e.currentTarget,o=e.relatedTarget,a=o!==n.$_pfocustrap_lasthiddenfocusableelement&&null!==(t=r.current)&&void 0!==t&&t.contains(o)?n.$_pfocustrap_lasthiddenfocusableelement:i.DomHandler.getFirstFocusableElement(n.parentElement,v(n.$_pfocustrap_focusableselector));i.DomHandler.focus(a)}),"firstfocusableelement"),b=f(x,"lastfocusableelement"),g.ref.current&&b.ref.current&&(g.ref.current.$_pfocustrap_lasthiddenfocusableelement=b.ref.current,b.ref.current.$_pfocustrap_firsthiddenfocusableelement=g.ref.current),m.default.createElement(m.default.Fragment,null,g,s.children,b)})));function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function N(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){S(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var M=n.ComponentBase.extend({defaultProps:{__TYPE:"Dialog",__parentMetadata:null,appendTo:null,ariaCloseIconLabel:null,baseZIndex:0,blockScroll:!1,breakpoints:null,className:null,closable:!0,closeIcon:null,closeOnEscape:!0,content:null,contentClassName:null,contentStyle:null,dismissableMask:!1,draggable:!0,focusOnShow:!0,footer:null,footerClassName:null,header:null,headerClassName:null,headerStyle:null,icons:null,id:null,keepInViewport:!0,maskClassName:null,maskStyle:null,maximizable:!1,maximizeIcon:null,maximized:!1,minX:0,minY:0,minimizeIcon:null,modal:!0,onClick:null,onDrag:null,onDragEnd:null,onDragStart:null,onHide:null,onMaskClick:null,onMaximize:null,onResize:null,onResizeEnd:null,onResizeStart:null,onShow:null,position:"center",resizable:!0,rtl:!1,showHeader:!0,style:null,transitionOptions:null,visible:!1,children:void 0},css:{classes:{closeButtonIcon:"p-dialog-header-close-icon",closeButton:"p-dialog-header-icon p-dialog-header-close p-link",maximizableIcon:"p-dialog-header-maximize-icon",maximizableButton:"p-dialog-header-icon p-dialog-header-maximize p-link",header:function(e){return i.classNames("p-dialog-header",e.props.headerClassName)},headerTitle:"p-dialog-title",headerIcons:"p-dialog-header-icons",content:function(e){return i.classNames("p-dialog-content",e.props.contentClassName)},footer:function(e){return i.classNames("p-dialog-footer",e.props.footerClassName)},mask:function(e){var t=e.props,n=e.maskVisibleState,r=["center","left","right","top","top-left","top-right","bottom","bottom-left","bottom-right"].find((function(e){return e===t.position||e.replace("-","")===t.position}));return i.classNames("p-dialog-mask",r?"p-dialog-".concat(r):"",{"p-component-overlay p-component-overlay-enter":t.modal,"p-dialog-visible":n,"p-dialog-draggable":t.draggable,"p-dialog-resizable":t.resizable},t.maskClassName)},root:function(e){var t=e.maximized,n=e.context;return i.classNames("p-dialog p-component",{"p-dialog-rtl":e.props.rtl,"p-dialog-maximized":t,"p-dialog-default":!t,"p-input-filled":n&&"filled"===n.inputStyle||"filled"===g.default.inputStyle,"p-ripple-disabled":n&&!1===n.ripple||!1===g.default.ripple})},transition:"p-dialog"},styles:"\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n\n .p-dialog-visible {\n display: flex;\n }\n\n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n\n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n\n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n\n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .p-dialog-footer {\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n\n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n\n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n\n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n\n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n\n .p-dialog-enter-done {\n transform: none;\n }\n\n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n\n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n\n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n\n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n\n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n\n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n\n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n\n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n\n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n\n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n\n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n\n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n\n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n }\n}\n",inlineStyles:{mask:function(e){var t=e.props;return N({position:"fixed",height:"100%",width:"100%",left:0,top:0,display:"flex",justifyContent:"left"===t.position||"top-left"===t.position||"bottom-left"===t.position?"flex-start":"right"===t.position||"top-right"===t.position||"bottom-right"===t.position?"flex-end":"center",alignItems:"top"===t.position||"top-left"===t.position||"top-right"===t.position?"flex-start":"bottom"===t.position||"bottom-left"===t.position||"bottom-right"===t.position?"flex-end":"center",pointerEvents:!t.modal&&"none"},t.maskStyle)}}}});function T(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function B(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?T(Object(n),!0).forEach((function(t){S(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):T(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var F=f.forwardRef((function(e,p){var d=o.useMergeProps(),m=f.useContext(t.PrimeReactContext),y=M.getProps(e,m),h=y.id?y.id:i.UniqueComponentId(),E=I(f.useState(h),2),D=E[0],S=I(f.useState(!1),2),P=S[0],j=S[1],z=I(f.useState(!1),2),k=z[0],C=z[1],R=I(f.useState(y.maximized),2),_=R[0],N=R[1],T=f.useRef(null),F=f.useRef(null),U=f.useRef(null),X=f.useRef(null),A=f.useRef(null),q=f.useRef(null),L=f.useRef(null),Y=f.useRef(!1),$=f.useRef(!1),V=f.useRef(null),Z=f.useRef(null),J=f.useRef(null),W=f.useRef(h),G=f.useRef(null),K=y.onMaximize?y.maximized:_,Q=k&&(y.blockScroll||y.maximizable&&K),ee=y.closable&&y.closeOnEscape&&k,te=o.useDisplayOrder("dialog",ee),ne=M.setMetaData(B(B({props:y},y.__parentMetadata),{},{state:{id:D,maximized:K,containerVisible:P}})),re=ne.ptm,oe=ne.cx,ie=ne.sx,ae=ne.isUnstyled;n.useHandleStyle(M.css.styles,ae,{name:"dialog"}),o.useGlobalOnEscapeKey({callback:function(e){ve(e)},when:ee&&te,priority:[o.ESC_KEY_HANDLING_PRIORITIES.DIALOG,te]});var le=I(o.useEventListener({type:"mousemove",target:function(){return window.document},listener:function(e){return ze(e)}}),2),ce=le[0],se=le[1],ue=I(o.useEventListener({type:"mouseup",target:function(){return window.document},listener:function(e){return Ie(e)}}),2),pe=ue[0],de=ue[1],me=I(o.useEventListener({type:"mousemove",target:function(){return window.document},listener:function(e){return De(e)}}),2),fe=me[0],ge=me[1],be=I(o.useEventListener({type:"mouseup",target:function(){return window.document},listener:function(e){return Se(e)}}),2),ye=be[0],he=be[1],ve=function(e){y.onHide(),e.preventDefault()},xe=function(e){U.current=e.target,y.onPointerDown&&y.onPointerDown(e)},Oe=function(e){y.dismissableMask&&y.modal&&F.current===e.target&&!U.current&&ve(e),y.onMaskClick&&y.onMaskClick(e),U.current=null},we=function(e){y.onMaximize?y.onMaximize({originalEvent:e,maximized:!K}):N((function(e){return!e})),e.preventDefault()},Ee=function(e){i.DomHandler.hasClass(e.target,"p-dialog-header-icon")||i.DomHandler.hasClass(e.target.parentElement,"p-dialog-header-icon")||y.draggable&&(Y.current=!0,V.current=e.pageX,Z.current=e.pageY,T.current.style.margin="0",i.DomHandler.addClass(document.body,"p-unselectable-text"),y.onDragStart&&y.onDragStart(e))},De=function(e){if(Y.current){var t=i.DomHandler.getOuterWidth(T.current),n=i.DomHandler.getOuterHeight(T.current),r=e.pageX-V.current,o=e.pageY-Z.current,a=T.current.getBoundingClientRect(),l=a.left+r,c=a.top+o,s=i.DomHandler.getViewport(),u=getComputedStyle(T.current),p=parseFloat(u.marginLeft),d=parseFloat(u.marginTop);T.current.style.position="fixed",y.keepInViewport?(l>=y.minX&&l+t<s.width&&(V.current=e.pageX,T.current.style.left=l-p+"px"),c>=y.minY&&c+n<s.height&&(Z.current=e.pageY,T.current.style.top=c-d+"px")):(V.current=e.pageX,T.current.style.left=l-p+"px",Z.current=e.pageY,T.current.style.top=c-d+"px"),y.onDrag&&y.onDrag(e)}},Se=function(e){Y.current&&(Y.current=!1,i.DomHandler.removeClass(document.body,"p-unselectable-text"),y.onDragEnd&&y.onDragEnd(e))},Pe=function(e){y.resizable&&($.current=!0,V.current=e.pageX,Z.current=e.pageY,i.DomHandler.addClass(document.body,"p-unselectable-text"),y.onResizeStart&&y.onResizeStart(e))},je=function(e,t,n){!n&&(n=i.DomHandler.getViewport());var r=parseInt(e);return/^(\d+|(\.\d+))(\.\d+)?%$/.test(e)?r*(n[t]/100):r},ze=function(e){if($.current){var t=e.pageX-V.current,n=e.pageY-Z.current,r=i.DomHandler.getOuterWidth(T.current),o=i.DomHandler.getOuterHeight(T.current),a=T.current.getBoundingClientRect(),l=i.DomHandler.getViewport(),c=!parseInt(T.current.style.top)||!parseInt(T.current.style.left),s=je(T.current.style.minWidth,"width",l),u=je(T.current.style.minHeight,"height",l),p=r+t,d=o+n;c&&(p+=t,d+=n),(!s||p>s)&&a.left+p<l.width&&(T.current.style.width=p+"px"),(!u||d>u)&&a.top+d<l.height&&(T.current.style.height=d+"px"),V.current=e.pageX,Z.current=e.pageY,y.onResize&&y.onResize(e)}},Ie=function(e){$.current&&($.current=!1,i.DomHandler.removeClass(document.body,"p-unselectable-text"),y.onResizeEnd&&y.onResizeEnd(e))},ke=function(){T.current.style.position="",T.current.style.left="",T.current.style.top="",T.current.style.margin=""},Ce=function(){T.current.setAttribute(W.current,"")},Re=function(){var e;y.onShow&&y.onShow(),y.focusOnShow&&!((e=document.activeElement)&&T.current&&T.current.contains(e))&&y.closable&&y.showHeader&&L.current&&L.current.focus(),Ne()},He=function(){y.modal&&!ae()&&i.DomHandler.addClass(F.current,"p-component-overlay-leave")},_e=function(){Y.current=!1,i.ZIndexUtils.clear(F.current),j(!1),Me(),i.DomHandler.focus(G.current),G.current=null},Ne=function(){Be()},Me=function(){Fe()},Te=function(e){if(e&&k){var t={id:D,hasBlockScroll:Q};document.primeDialogParams||(document.primeDialogParams=[]);var n=document.primeDialogParams.findIndex((function(e){return e.id===D}));document.primeDialogParams=-1===n?[].concat(v(r=document.primeDialogParams)||x(r)||O(r)||w(),[t]):document.primeDialogParams.toSpliced(n,1,t)}else document.primeDialogParams=document.primeDialogParams&&document.primeDialogParams.filter((function(e){return e.id!==D}));var r;document.primeDialogParams&&document.primeDialogParams.some((function(e){return e.hasBlockScroll}))?i.DomHandler.blockBodyScroll():i.DomHandler.unblockBodyScroll()},Be=function(){y.draggable&&(fe(),ye()),y.resizable&&(ce(),pe())},Fe=function(){ge(),he(),se(),de()},Ue=function(){J.current=i.DomHandler.createInlineStyle(m&&m.nonce||g.default.nonce,m&&m.styleContainer);var e="";for(var t in y.breakpoints)e+="\n @media screen and (max-width: ".concat(t,') {\n [data-pc-name="dialog"][').concat(W.current,"] {\n width: ").concat(y.breakpoints[t]," !important;\n }\n }\n ");J.current.innerHTML=e};o.useMountEffect((function(){Te(!0),y.visible&&j(!0)})),f.useEffect((function(){return y.breakpoints&&Ue(),function(){J.current=i.DomHandler.removeInlineStyle(J.current)}}),[y.breakpoints]),o.useUpdateEffect((function(){y.visible&&!P&&j(!0),y.visible!==k&&P&&C(y.visible),y.visible&&(G.current=document.activeElement)}),[y.visible,P]),o.useUpdateEffect((function(){P&&(i.ZIndexUtils.set("modal",F.current,m&&m.autoZIndex||g.default.autoZIndex,y.baseZIndex||m&&m.zIndex.modal||g.default.zIndex.modal),C(!0))}),[P]),o.useUpdateEffect((function(){Te(!0)}),[Q,k]),o.useUnmountEffect((function(){Me(),Te(!1),i.DomHandler.removeInlineStyle(J.current),i.ZIndexUtils.clear(F.current)})),f.useImperativeHandle(p,(function(){return{props:y,resetPosition:ke,getElement:function(){return T.current},getMask:function(){return F.current},getContent:function(){return X.current},getHeader:function(){return A.current},getFooter:function(){return q.current},getCloseButton:function(){return L.current}}}));var Xe=function(){if(y.closable){var e=y.ariaCloseIconLabel||t.localeOption("close"),n=d({className:oe("closeButtonIcon"),"aria-hidden":!0},re("closeButtonIcon")),r=i.IconUtils.getJSXIcon(y.closeIcon||f.createElement(a.TimesIcon,n),B({},n),{props:y}),o=d({ref:L,type:"button",className:oe("closeButton"),"aria-label":e,onClick:ve,onKeyDown:function(e){return e.stopPropagation()}},re("closeButton"));return f.createElement("button",o,r,f.createElement(u.Ripple,null))}return null},Ae=function(){var e=d({className:oe("maximizableIcon")},re("maximizableIcon")),t=i.IconUtils.getJSXIcon(K?y.minimizeIcon||f.createElement(c.WindowMinimizeIcon,e):y.maximizeIcon||f.createElement(l.WindowMaximizeIcon,e),e,{props:y});if(y.maximizable){var n=d({type:"button",className:oe("maximizableButton"),onClick:we},re("maximizableButton"));return f.createElement("button",n,t,f.createElement(u.Ripple,null))}return null},qe=function(){if(y.showHeader){var e=Xe(),t=Ae(),n=i.ObjectUtils.getJSXElement(y.icons,y),r=i.ObjectUtils.getJSXElement(y.header,y),o=D+"_header",a=d({ref:A,style:y.headerStyle,className:oe("header"),onMouseDown:Ee},re("header")),l=d({id:o,className:oe("headerTitle")},re("headerTitle")),c=d({className:oe("headerIcons")},re("headerIcons"));return f.createElement("div",a,f.createElement("div",l,r),f.createElement("div",c,n,t,e))}return null},Le=function(){var e=i.ObjectUtils.getJSXElement(y.footer,y),t=d({ref:q,className:oe("footer")},re("footer"));return e&&f.createElement("div",t,e)};return P&&function(){var t,n,o,a,l,c,u=D+"_header",p=D+"_content",g={enter:"center"===y.position?150:300,exit:"center"===y.position?150:300},h=d({ref:F,style:ie("mask"),className:oe("mask"),onPointerUp:Oe},re("mask")),v=d({ref:T,id:D,className:i.classNames(y.className,oe("root",{props:y,maximized:K,context:m})),style:y.style,onClick:y.onClick,role:"dialog","aria-labelledby":u,"aria-describedby":p,"aria-modal":y.modal,onPointerDown:xe},M.getOtherProps(y),re("root")),x=d({classNames:oe("transition"),timeout:g,in:k,options:y.transitionOptions,unmountOnExit:!0,onEnter:Ce,onEntered:Re,onExiting:He,onExited:_e},re("transition")),O=null;null!=e&&e.content?(c={header:y.header,content:y.message,message:null==y||null===(l=y.children)||void 0===l||null===(l=l[1])||void 0===l||null===(l=l.props)||void 0===l?void 0:l.children},O=i.ObjectUtils.getJSXElement(e.content,{headerRef:A,contentRef:X,footerRef:q,closeRef:L,hide:ve,message:c})):(n=qe(),t=d({id:D+"_content",ref:X,style:y.contentStyle,className:oe("content")},re("content")),o=f.createElement("div",t,y.children),a=Le(),O=f.createElement(f.Fragment,null,n,o,a,y.resizable?f.createElement("span",{className:"p-resizable-handle",style:{zIndex:90},onMouseDown:Pe}):null));var w=f.createElement("div",h,f.createElement(r.CSSTransition,b({nodeRef:T},x),f.createElement("div",v,f.createElement(H,{autoFocus:!0},O))));return f.createElement(s.Portal,{element:w,appendTo:y.appendTo,visible:!0})}()}));F.displayName="Dialog",exports.Dialog=F;
@@ -299,7 +299,7 @@ var classes = {
299
299
  },
300
300
  transition: 'p-dialog'
301
301
  };
302
- var styles = "\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n \n .p-dialog-visible {\n display: flex;\n }\n \n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n \n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n \n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n \n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n \n .p-dialog-footer {\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n \n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n \n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n \n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n \n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n \n .p-dialog-enter-done {\n transform: none;\n }\n \n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n \n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n \n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n \n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n \n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n \n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n \n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n \n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n \n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n \n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n \n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n \n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n \n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n } \n}\n";
302
+ var styles = "\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n\n .p-dialog-visible {\n display: flex;\n }\n\n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n\n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n\n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n\n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .p-dialog-footer {\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n\n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n\n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n\n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n\n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n\n .p-dialog-enter-done {\n transform: none;\n }\n\n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n\n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n\n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n\n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n\n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n\n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n\n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n\n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n\n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n\n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n\n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n\n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n\n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n }\n}\n";
303
303
  var inlineStyles = {
304
304
  mask: function mask(_ref6) {
305
305
  var props = _ref6.props;
@@ -652,7 +652,6 @@ var Dialog = /*#__PURE__*/React.forwardRef(function (inProps, ref) {
652
652
  }
653
653
  };
654
654
  var onExited = function onExited() {
655
- props.onHide && props.onHide();
656
655
  dragging.current = false;
657
656
  ZIndexUtils.clear(maskRef.current);
658
657
  setMaskVisibleState(false);
@@ -821,7 +820,10 @@ var Dialog = /*#__PURE__*/React.forwardRef(function (inProps, ref) {
821
820
  type: 'button',
822
821
  className: cx('closeButton'),
823
822
  'aria-label': ariaLabel,
824
- onClick: onClose
823
+ onClick: onClose,
824
+ onKeyDown: function onKeyDown(ev) {
825
+ return ev.stopPropagation();
826
+ }
825
827
  }, ptm('closeButton'));
826
828
  return /*#__PURE__*/React.createElement("button", closeButtonProps, headerCloseIcon, /*#__PURE__*/React.createElement(Ripple, null));
827
829
  }
@@ -1 +1 @@
1
- import*as e from"react";import t from"react";import n,{PrimeReactContext as r,localeOption as o}from"primereact/api";import{ComponentBase as i,useHandleStyle as a}from"primereact/componentbase";import{CSSTransition as l}from"primereact/csstransition";import{useStyle as c,useMountEffect as s,useMergeProps as u,useDisplayOrder as p,useGlobalOnEscapeKey as d,ESC_KEY_HANDLING_PRIORITIES as m,useEventListener as f,useUpdateEffect as g,useUnmountEffect as b}from"primereact/hooks";import{ObjectUtils as h,DomHandler as y,classNames as v,UniqueComponentId as x,ZIndexUtils as w,IconUtils as O}from"primereact/utils";import{TimesIcon as S}from"primereact/icons/times";import{WindowMaximizeIcon as E}from"primereact/icons/windowmaximize";import{WindowMinimizeIcon as z}from"primereact/icons/windowminimize";import{Portal as P}from"primereact/portal";import{Ripple as k}from"primereact/ripple";function j(){return j=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},j.apply(this,arguments)}function I(e){return I="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},I(e)}function D(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function R(e){if(Array.isArray(e))return D(e)}function C(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function _(e,t){if(e){if("string"==typeof e)return D(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?D(e,t):void 0}}function N(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function T(e,t){if("object"!==I(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==I(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function M(e){var t=T(e,"string");return"symbol"===I(t)?t:String(t)}function F(e,t,n){return(t=M(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function B(e){if(Array.isArray(e))return e}function X(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw o}}return l}}function H(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function A(e,t){return B(e)||X(e,t)||_(e,t)||H()}var Y=i.extend({defaultProps:{__TYPE:"FocusTrap",children:void 0},css:{styles:""},getProps:function(e){return h.getMergedProps(e,Y.defaultProps)},getOtherProps:function(e){return h.getDiffProps(e,Y.defaultProps)}});function $(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function L(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?$(Object(n),!0).forEach((function(t){F(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var V=t.memo(t.forwardRef((function(e,n){var o=t.useRef(null),i=t.useRef(null),a=t.useRef(null),l=t.useContext(r),u=Y.getProps(e,l),p={props:u};c(Y.css.styles,{name:"focustrap"});Y.setMetaData(L({},p));t.useImperativeHandle(n,(function(){return{props:u,getInk:function(){return i.current},getTarget:function(){return o.current}}})),s((function(){u.disabled||(o.current=h(),v(o.current))}));var d,m,f,g,b,h=function(){return i.current&&i.current.parentElement},v=function(e){var t=u||{},n=t.autoFocusSelector,r=t.firstFocusableSelector,o=void 0===r?"":r,i=t.autoFocus,a=void 0!==i&&i,l=y.getFirstFocusableElement(e,"[autofocus]".concat(x(void 0===n?"":n)));a&&!l&&(l=y.getFirstFocusableElement(e,x(o))),y.focus(l)},x=function(e){return':not(.p-hidden-focusable):not([data-p-hidden-focusable="true"])'.concat(null!=e?e:"")},w=function(e){var t,n=e.currentTarget,r=e.relatedTarget,i=r!==n.$_pfocustrap_firsthiddenfocusableelement&&null!==(t=o.current)&&void 0!==t&&t.contains(r)?n.$_pfocustrap_firsthiddenfocusableelement:y.getLastFocusableElement(n.parentElement,x(n.$_pfocustrap_focusableselector));y.focus(i)};return m=void 0===(d=(u||{}).tabIndex)?0:d,g=(f=function(e,n){return t.createElement("span",{ref:"firstfocusableelement"===n?i:a,className:"p-hidden-accessible p-hidden-focusable",tabIndex:m,role:"presentation","aria-hidden":!0,"data-p-hidden-accessible":!0,"data-p-hidden-focusable":!0,onFocus:e,"data-pc-section":n})})((function(e){var t,n=e.currentTarget,r=e.relatedTarget,i=r!==n.$_pfocustrap_lasthiddenfocusableelement&&null!==(t=o.current)&&void 0!==t&&t.contains(r)?n.$_pfocustrap_lasthiddenfocusableelement:y.getFirstFocusableElement(n.parentElement,x(n.$_pfocustrap_focusableselector));y.focus(i)}),"firstfocusableelement"),b=f(w,"lastfocusableelement"),g.ref.current&&b.ref.current&&(g.ref.current.$_pfocustrap_lasthiddenfocusableelement=b.ref.current,b.ref.current.$_pfocustrap_firsthiddenfocusableelement=g.ref.current),t.createElement(t.Fragment,null,g,u.children,b)})));function J(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Z(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?J(Object(n),!0).forEach((function(t){F(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):J(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var U=i.extend({defaultProps:{__TYPE:"Dialog",__parentMetadata:null,appendTo:null,ariaCloseIconLabel:null,baseZIndex:0,blockScroll:!1,breakpoints:null,className:null,closable:!0,closeIcon:null,closeOnEscape:!0,content:null,contentClassName:null,contentStyle:null,dismissableMask:!1,draggable:!0,focusOnShow:!0,footer:null,footerClassName:null,header:null,headerClassName:null,headerStyle:null,icons:null,id:null,keepInViewport:!0,maskClassName:null,maskStyle:null,maximizable:!1,maximizeIcon:null,maximized:!1,minX:0,minY:0,minimizeIcon:null,modal:!0,onClick:null,onDrag:null,onDragEnd:null,onDragStart:null,onHide:null,onMaskClick:null,onMaximize:null,onResize:null,onResizeEnd:null,onResizeStart:null,onShow:null,position:"center",resizable:!0,rtl:!1,showHeader:!0,style:null,transitionOptions:null,visible:!1,children:void 0},css:{classes:{closeButtonIcon:"p-dialog-header-close-icon",closeButton:"p-dialog-header-icon p-dialog-header-close p-link",maximizableIcon:"p-dialog-header-maximize-icon",maximizableButton:"p-dialog-header-icon p-dialog-header-maximize p-link",header:function(e){return v("p-dialog-header",e.props.headerClassName)},headerTitle:"p-dialog-title",headerIcons:"p-dialog-header-icons",content:function(e){return v("p-dialog-content",e.props.contentClassName)},footer:function(e){return v("p-dialog-footer",e.props.footerClassName)},mask:function(e){var t=e.props,n=e.maskVisibleState,r=["center","left","right","top","top-left","top-right","bottom","bottom-left","bottom-right"].find((function(e){return e===t.position||e.replace("-","")===t.position}));return v("p-dialog-mask",r?"p-dialog-".concat(r):"",{"p-component-overlay p-component-overlay-enter":t.modal,"p-dialog-visible":n,"p-dialog-draggable":t.draggable,"p-dialog-resizable":t.resizable},t.maskClassName)},root:function(e){var t=e.maximized,r=e.context;return v("p-dialog p-component",{"p-dialog-rtl":e.props.rtl,"p-dialog-maximized":t,"p-dialog-default":!t,"p-input-filled":r&&"filled"===r.inputStyle||"filled"===n.inputStyle,"p-ripple-disabled":r&&!1===r.ripple||!1===n.ripple})},transition:"p-dialog"},styles:"\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n \n .p-dialog-visible {\n display: flex;\n }\n \n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n \n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n \n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n \n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n \n .p-dialog-footer {\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n \n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n \n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n \n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n \n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n \n .p-dialog-enter-done {\n transform: none;\n }\n \n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n \n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n \n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n \n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n \n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n \n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n \n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n \n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n \n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n \n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n \n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n \n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n \n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n } \n}\n",inlineStyles:{mask:function(e){var t=e.props;return Z({position:"fixed",height:"100%",width:"100%",left:0,top:0,display:"flex",justifyContent:"left"===t.position||"top-left"===t.position||"bottom-left"===t.position?"flex-start":"right"===t.position||"top-right"===t.position||"bottom-right"===t.position?"flex-end":"center",alignItems:"top"===t.position||"top-left"===t.position||"top-right"===t.position?"flex-start":"bottom"===t.position||"bottom-left"===t.position||"bottom-right"===t.position?"flex-end":"center",pointerEvents:!t.modal&&"none"},t.maskStyle)}}}});function W(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function G(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?W(Object(n),!0).forEach((function(t){F(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):W(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var q=e.forwardRef((function(t,i){var c=u(),I=e.useContext(r),D=U.getProps(t,I),T=D.id?D.id:x(),M=A(e.useState(T),2),F=M[0],B=A(e.useState(!1),2),X=B[0],H=B[1],Y=A(e.useState(!1),2),$=Y[0],L=Y[1],J=A(e.useState(D.maximized),2),Z=J[0],W=J[1],q=e.useRef(null),K=e.useRef(null),Q=e.useRef(null),ee=e.useRef(null),te=e.useRef(null),ne=e.useRef(null),re=e.useRef(null),oe=e.useRef(!1),ie=e.useRef(!1),ae=e.useRef(null),le=e.useRef(null),ce=e.useRef(null),se=e.useRef(T),ue=e.useRef(null),pe=D.onMaximize?D.maximized:Z,de=$&&(D.blockScroll||D.maximizable&&pe),me=D.closable&&D.closeOnEscape&&$,fe=p("dialog",me),ge=U.setMetaData(G(G({props:D},D.__parentMetadata),{},{state:{id:F,maximized:pe,containerVisible:X}})),be=ge.ptm,he=ge.cx,ye=ge.sx,ve=ge.isUnstyled;a(U.css.styles,ve,{name:"dialog"}),d({callback:function(e){Ce(e)},when:me&&fe,priority:[m.DIALOG,fe]});var xe=A(f({type:"mousemove",target:function(){return window.document},listener:function(e){return Ae(e)}}),2),we=xe[0],Oe=xe[1],Se=A(f({type:"mouseup",target:function(){return window.document},listener:function(e){return Ye(e)}}),2),Ee=Se[0],ze=Se[1],Pe=A(f({type:"mousemove",target:function(){return window.document},listener:function(e){return Fe(e)}}),2),ke=Pe[0],je=Pe[1],Ie=A(f({type:"mouseup",target:function(){return window.document},listener:function(e){return Be(e)}}),2),De=Ie[0],Re=Ie[1],Ce=function(e){D.onHide(),e.preventDefault()},_e=function(e){Q.current=e.target,D.onPointerDown&&D.onPointerDown(e)},Ne=function(e){D.dismissableMask&&D.modal&&K.current===e.target&&!Q.current&&Ce(e),D.onMaskClick&&D.onMaskClick(e),Q.current=null},Te=function(e){D.onMaximize?D.onMaximize({originalEvent:e,maximized:!pe}):W((function(e){return!e})),e.preventDefault()},Me=function(e){y.hasClass(e.target,"p-dialog-header-icon")||y.hasClass(e.target.parentElement,"p-dialog-header-icon")||D.draggable&&(oe.current=!0,ae.current=e.pageX,le.current=e.pageY,q.current.style.margin="0",y.addClass(document.body,"p-unselectable-text"),D.onDragStart&&D.onDragStart(e))},Fe=function(e){if(oe.current){var t=y.getOuterWidth(q.current),n=y.getOuterHeight(q.current),r=e.pageX-ae.current,o=e.pageY-le.current,i=q.current.getBoundingClientRect(),a=i.left+r,l=i.top+o,c=y.getViewport(),s=getComputedStyle(q.current),u=parseFloat(s.marginLeft),p=parseFloat(s.marginTop);q.current.style.position="fixed",D.keepInViewport?(a>=D.minX&&a+t<c.width&&(ae.current=e.pageX,q.current.style.left=a-u+"px"),l>=D.minY&&l+n<c.height&&(le.current=e.pageY,q.current.style.top=l-p+"px")):(ae.current=e.pageX,q.current.style.left=a-u+"px",le.current=e.pageY,q.current.style.top=l-p+"px"),D.onDrag&&D.onDrag(e)}},Be=function(e){oe.current&&(oe.current=!1,y.removeClass(document.body,"p-unselectable-text"),D.onDragEnd&&D.onDragEnd(e))},Xe=function(e){D.resizable&&(ie.current=!0,ae.current=e.pageX,le.current=e.pageY,y.addClass(document.body,"p-unselectable-text"),D.onResizeStart&&D.onResizeStart(e))},He=function(e,t,n){!n&&(n=y.getViewport());var r=parseInt(e);return/^(\d+|(\.\d+))(\.\d+)?%$/.test(e)?r*(n[t]/100):r},Ae=function(e){if(ie.current){var t=e.pageX-ae.current,n=e.pageY-le.current,r=y.getOuterWidth(q.current),o=y.getOuterHeight(q.current),i=q.current.getBoundingClientRect(),a=y.getViewport(),l=!parseInt(q.current.style.top)||!parseInt(q.current.style.left),c=He(q.current.style.minWidth,"width",a),s=He(q.current.style.minHeight,"height",a),u=r+t,p=o+n;l&&(u+=t,p+=n),(!c||u>c)&&i.left+u<a.width&&(q.current.style.width=u+"px"),(!s||p>s)&&i.top+p<a.height&&(q.current.style.height=p+"px"),ae.current=e.pageX,le.current=e.pageY,D.onResize&&D.onResize(e)}},Ye=function(e){ie.current&&(ie.current=!1,y.removeClass(document.body,"p-unselectable-text"),D.onResizeEnd&&D.onResizeEnd(e))},$e=function(){q.current.style.position="",q.current.style.left="",q.current.style.top="",q.current.style.margin=""},Le=function(){q.current.setAttribute(se.current,"")},Ve=function(){var e;D.onShow&&D.onShow(),D.focusOnShow&&!((e=document.activeElement)&&q.current&&q.current.contains(e))&&D.closable&&D.showHeader&&re.current&&re.current.focus(),Ue()},Je=function(){D.modal&&!ve()&&y.addClass(K.current,"p-component-overlay-leave")},Ze=function(){D.onHide&&D.onHide(),oe.current=!1,w.clear(K.current),H(!1),We(),y.focus(ue.current),ue.current=null},Ue=function(){qe()},We=function(){Ke()},Ge=function(e){if(e&&$){var t={id:F,hasBlockScroll:de};document.primeDialogParams||(document.primeDialogParams=[]);var n=document.primeDialogParams.findIndex((function(e){return e.id===F}));document.primeDialogParams=-1===n?[].concat(R(r=document.primeDialogParams)||C(r)||_(r)||N(),[t]):document.primeDialogParams.toSpliced(n,1,t)}else document.primeDialogParams=document.primeDialogParams&&document.primeDialogParams.filter((function(e){return e.id!==F}));var r;document.primeDialogParams&&document.primeDialogParams.some((function(e){return e.hasBlockScroll}))?y.blockBodyScroll():y.unblockBodyScroll()},qe=function(){D.draggable&&(ke(),De()),D.resizable&&(we(),Ee())},Ke=function(){je(),Re(),Oe(),ze()},Qe=function(){ce.current=y.createInlineStyle(I&&I.nonce||n.nonce,I&&I.styleContainer);var e="";for(var t in D.breakpoints)e+="\n @media screen and (max-width: ".concat(t,') {\n [data-pc-name="dialog"][').concat(se.current,"] {\n width: ").concat(D.breakpoints[t]," !important;\n }\n }\n ");ce.current.innerHTML=e};s((function(){Ge(!0),D.visible&&H(!0)})),e.useEffect((function(){return D.breakpoints&&Qe(),function(){ce.current=y.removeInlineStyle(ce.current)}}),[D.breakpoints]),g((function(){D.visible&&!X&&H(!0),D.visible!==$&&X&&L(D.visible),D.visible&&(ue.current=document.activeElement)}),[D.visible,X]),g((function(){X&&(w.set("modal",K.current,I&&I.autoZIndex||n.autoZIndex,D.baseZIndex||I&&I.zIndex.modal||n.zIndex.modal),L(!0))}),[X]),g((function(){Ge(!0)}),[de,$]),b((function(){We(),Ge(!1),y.removeInlineStyle(ce.current),w.clear(K.current)})),e.useImperativeHandle(i,(function(){return{props:D,resetPosition:$e,getElement:function(){return q.current},getMask:function(){return K.current},getContent:function(){return ee.current},getHeader:function(){return te.current},getFooter:function(){return ne.current},getCloseButton:function(){return re.current}}}));var et=function(){if(D.closable){var t=D.ariaCloseIconLabel||o("close"),n=c({className:he("closeButtonIcon"),"aria-hidden":!0},be("closeButtonIcon")),r=O.getJSXIcon(D.closeIcon||e.createElement(S,n),G({},n),{props:D}),i=c({ref:re,type:"button",className:he("closeButton"),"aria-label":t,onClick:Ce},be("closeButton"));return e.createElement("button",i,r,e.createElement(k,null))}return null},tt=function(){var t=c({className:he("maximizableIcon")},be("maximizableIcon")),n=O.getJSXIcon(pe?D.minimizeIcon||e.createElement(z,t):D.maximizeIcon||e.createElement(E,t),t,{props:D});if(D.maximizable){var r=c({type:"button",className:he("maximizableButton"),onClick:Te},be("maximizableButton"));return e.createElement("button",r,n,e.createElement(k,null))}return null},nt=function(){if(D.showHeader){var t=et(),n=tt(),r=h.getJSXElement(D.icons,D),o=h.getJSXElement(D.header,D),i=F+"_header",a=c({ref:te,style:D.headerStyle,className:he("header"),onMouseDown:Me},be("header")),l=c({id:i,className:he("headerTitle")},be("headerTitle")),s=c({className:he("headerIcons")},be("headerIcons"));return e.createElement("div",a,e.createElement("div",l,o),e.createElement("div",s,r,n,t))}return null},rt=function(){var t=h.getJSXElement(D.footer,D),n=c({ref:ne,className:he("footer")},be("footer"));return t&&e.createElement("div",n,t)};return X&&function(){var n,r,o,i,a,s,u=F+"_header",p=F+"_content",d={enter:"center"===D.position?150:300,exit:"center"===D.position?150:300},m=c({ref:K,style:ye("mask"),className:he("mask"),onPointerUp:Ne},be("mask")),f=c({ref:q,id:F,className:v(D.className,he("root",{props:D,maximized:pe,context:I})),style:D.style,onClick:D.onClick,role:"dialog","aria-labelledby":u,"aria-describedby":p,"aria-modal":D.modal,onPointerDown:_e},U.getOtherProps(D),be("root")),g=c({classNames:he("transition"),timeout:d,in:$,options:D.transitionOptions,unmountOnExit:!0,onEnter:Le,onEntered:Ve,onExiting:Je,onExited:Ze},be("transition")),b=null;null!=t&&t.content?(s={header:D.header,content:D.message,message:null==D||null===(a=D.children)||void 0===a||null===(a=a[1])||void 0===a||null===(a=a.props)||void 0===a?void 0:a.children},b=h.getJSXElement(t.content,{headerRef:te,contentRef:ee,footerRef:ne,closeRef:re,hide:Ce,message:s})):(r=nt(),n=c({id:F+"_content",ref:ee,style:D.contentStyle,className:he("content")},be("content")),o=e.createElement("div",n,D.children),i=rt(),b=e.createElement(e.Fragment,null,r,o,i,D.resizable?e.createElement("span",{className:"p-resizable-handle",style:{zIndex:90},onMouseDown:Xe}):null));var y=e.createElement("div",m,e.createElement(l,j({nodeRef:q},g),e.createElement("div",f,e.createElement(V,{autoFocus:!0},b))));return e.createElement(P,{element:y,appendTo:D.appendTo,visible:!0})}()}));q.displayName="Dialog";export{q as Dialog};
1
+ import*as e from"react";import t from"react";import n,{PrimeReactContext as r,localeOption as o}from"primereact/api";import{ComponentBase as i,useHandleStyle as a}from"primereact/componentbase";import{CSSTransition as l}from"primereact/csstransition";import{useStyle as c,useMountEffect as s,useMergeProps as u,useDisplayOrder as p,useGlobalOnEscapeKey as d,ESC_KEY_HANDLING_PRIORITIES as m,useEventListener as f,useUpdateEffect as g,useUnmountEffect as b}from"primereact/hooks";import{ObjectUtils as h,DomHandler as y,classNames as v,UniqueComponentId as x,ZIndexUtils as w,IconUtils as O}from"primereact/utils";import{TimesIcon as S}from"primereact/icons/times";import{WindowMaximizeIcon as E}from"primereact/icons/windowmaximize";import{WindowMinimizeIcon as P}from"primereact/icons/windowminimize";import{Portal as z}from"primereact/portal";import{Ripple as k}from"primereact/ripple";function j(){return j=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},j.apply(this,arguments)}function I(e){return I="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},I(e)}function D(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function R(e){if(Array.isArray(e))return D(e)}function C(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function _(e,t){if(e){if("string"==typeof e)return D(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?D(e,t):void 0}}function N(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function T(e,t){if("object"!==I(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==I(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function M(e){var t=T(e,"string");return"symbol"===I(t)?t:String(t)}function F(e,t,n){return(t=M(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function B(e){if(Array.isArray(e))return e}function X(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw o}}return l}}function A(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function H(e,t){return B(e)||X(e,t)||_(e,t)||A()}var Y=i.extend({defaultProps:{__TYPE:"FocusTrap",children:void 0},css:{styles:""},getProps:function(e){return h.getMergedProps(e,Y.defaultProps)},getOtherProps:function(e){return h.getDiffProps(e,Y.defaultProps)}});function $(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function L(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?$(Object(n),!0).forEach((function(t){F(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):$(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var V=t.memo(t.forwardRef((function(e,n){var o=t.useRef(null),i=t.useRef(null),a=t.useRef(null),l=t.useContext(r),u=Y.getProps(e,l),p={props:u};c(Y.css.styles,{name:"focustrap"});Y.setMetaData(L({},p));t.useImperativeHandle(n,(function(){return{props:u,getInk:function(){return i.current},getTarget:function(){return o.current}}})),s((function(){u.disabled||(o.current=h(),v(o.current))}));var d,m,f,g,b,h=function(){return i.current&&i.current.parentElement},v=function(e){var t=u||{},n=t.autoFocusSelector,r=t.firstFocusableSelector,o=void 0===r?"":r,i=t.autoFocus,a=void 0!==i&&i,l=y.getFirstFocusableElement(e,"[autofocus]".concat(x(void 0===n?"":n)));a&&!l&&(l=y.getFirstFocusableElement(e,x(o))),y.focus(l)},x=function(e){return':not(.p-hidden-focusable):not([data-p-hidden-focusable="true"])'.concat(null!=e?e:"")},w=function(e){var t,n=e.currentTarget,r=e.relatedTarget,i=r!==n.$_pfocustrap_firsthiddenfocusableelement&&null!==(t=o.current)&&void 0!==t&&t.contains(r)?n.$_pfocustrap_firsthiddenfocusableelement:y.getLastFocusableElement(n.parentElement,x(n.$_pfocustrap_focusableselector));y.focus(i)};return m=void 0===(d=(u||{}).tabIndex)?0:d,g=(f=function(e,n){return t.createElement("span",{ref:"firstfocusableelement"===n?i:a,className:"p-hidden-accessible p-hidden-focusable",tabIndex:m,role:"presentation","aria-hidden":!0,"data-p-hidden-accessible":!0,"data-p-hidden-focusable":!0,onFocus:e,"data-pc-section":n})})((function(e){var t,n=e.currentTarget,r=e.relatedTarget,i=r!==n.$_pfocustrap_lasthiddenfocusableelement&&null!==(t=o.current)&&void 0!==t&&t.contains(r)?n.$_pfocustrap_lasthiddenfocusableelement:y.getFirstFocusableElement(n.parentElement,x(n.$_pfocustrap_focusableselector));y.focus(i)}),"firstfocusableelement"),b=f(w,"lastfocusableelement"),g.ref.current&&b.ref.current&&(g.ref.current.$_pfocustrap_lasthiddenfocusableelement=b.ref.current,b.ref.current.$_pfocustrap_firsthiddenfocusableelement=g.ref.current),t.createElement(t.Fragment,null,g,u.children,b)})));function J(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function Z(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?J(Object(n),!0).forEach((function(t){F(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):J(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var U=i.extend({defaultProps:{__TYPE:"Dialog",__parentMetadata:null,appendTo:null,ariaCloseIconLabel:null,baseZIndex:0,blockScroll:!1,breakpoints:null,className:null,closable:!0,closeIcon:null,closeOnEscape:!0,content:null,contentClassName:null,contentStyle:null,dismissableMask:!1,draggable:!0,focusOnShow:!0,footer:null,footerClassName:null,header:null,headerClassName:null,headerStyle:null,icons:null,id:null,keepInViewport:!0,maskClassName:null,maskStyle:null,maximizable:!1,maximizeIcon:null,maximized:!1,minX:0,minY:0,minimizeIcon:null,modal:!0,onClick:null,onDrag:null,onDragEnd:null,onDragStart:null,onHide:null,onMaskClick:null,onMaximize:null,onResize:null,onResizeEnd:null,onResizeStart:null,onShow:null,position:"center",resizable:!0,rtl:!1,showHeader:!0,style:null,transitionOptions:null,visible:!1,children:void 0},css:{classes:{closeButtonIcon:"p-dialog-header-close-icon",closeButton:"p-dialog-header-icon p-dialog-header-close p-link",maximizableIcon:"p-dialog-header-maximize-icon",maximizableButton:"p-dialog-header-icon p-dialog-header-maximize p-link",header:function(e){return v("p-dialog-header",e.props.headerClassName)},headerTitle:"p-dialog-title",headerIcons:"p-dialog-header-icons",content:function(e){return v("p-dialog-content",e.props.contentClassName)},footer:function(e){return v("p-dialog-footer",e.props.footerClassName)},mask:function(e){var t=e.props,n=e.maskVisibleState,r=["center","left","right","top","top-left","top-right","bottom","bottom-left","bottom-right"].find((function(e){return e===t.position||e.replace("-","")===t.position}));return v("p-dialog-mask",r?"p-dialog-".concat(r):"",{"p-component-overlay p-component-overlay-enter":t.modal,"p-dialog-visible":n,"p-dialog-draggable":t.draggable,"p-dialog-resizable":t.resizable},t.maskClassName)},root:function(e){var t=e.maximized,r=e.context;return v("p-dialog p-component",{"p-dialog-rtl":e.props.rtl,"p-dialog-maximized":t,"p-dialog-default":!t,"p-input-filled":r&&"filled"===r.inputStyle||"filled"===n.inputStyle,"p-ripple-disabled":r&&!1===r.ripple||!1===n.ripple})},transition:"p-dialog"},styles:"\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n\n .p-dialog-visible {\n display: flex;\n }\n\n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n\n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n\n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n\n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .p-dialog-footer {\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n\n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n\n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n\n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n\n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n\n .p-dialog-enter-done {\n transform: none;\n }\n\n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n\n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n\n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n\n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n\n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n\n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n\n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n\n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n\n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n\n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n\n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n\n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n\n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n }\n}\n",inlineStyles:{mask:function(e){var t=e.props;return Z({position:"fixed",height:"100%",width:"100%",left:0,top:0,display:"flex",justifyContent:"left"===t.position||"top-left"===t.position||"bottom-left"===t.position?"flex-start":"right"===t.position||"top-right"===t.position||"bottom-right"===t.position?"flex-end":"center",alignItems:"top"===t.position||"top-left"===t.position||"top-right"===t.position?"flex-start":"bottom"===t.position||"bottom-left"===t.position||"bottom-right"===t.position?"flex-end":"center",pointerEvents:!t.modal&&"none"},t.maskStyle)}}}});function W(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function G(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?W(Object(n),!0).forEach((function(t){F(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):W(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var K=e.forwardRef((function(t,i){var c=u(),I=e.useContext(r),D=U.getProps(t,I),T=D.id?D.id:x(),M=H(e.useState(T),2),F=M[0],B=H(e.useState(!1),2),X=B[0],A=B[1],Y=H(e.useState(!1),2),$=Y[0],L=Y[1],J=H(e.useState(D.maximized),2),Z=J[0],W=J[1],K=e.useRef(null),q=e.useRef(null),Q=e.useRef(null),ee=e.useRef(null),te=e.useRef(null),ne=e.useRef(null),re=e.useRef(null),oe=e.useRef(!1),ie=e.useRef(!1),ae=e.useRef(null),le=e.useRef(null),ce=e.useRef(null),se=e.useRef(T),ue=e.useRef(null),pe=D.onMaximize?D.maximized:Z,de=$&&(D.blockScroll||D.maximizable&&pe),me=D.closable&&D.closeOnEscape&&$,fe=p("dialog",me),ge=U.setMetaData(G(G({props:D},D.__parentMetadata),{},{state:{id:F,maximized:pe,containerVisible:X}})),be=ge.ptm,he=ge.cx,ye=ge.sx,ve=ge.isUnstyled;a(U.css.styles,ve,{name:"dialog"}),d({callback:function(e){Ce(e)},when:me&&fe,priority:[m.DIALOG,fe]});var xe=H(f({type:"mousemove",target:function(){return window.document},listener:function(e){return He(e)}}),2),we=xe[0],Oe=xe[1],Se=H(f({type:"mouseup",target:function(){return window.document},listener:function(e){return Ye(e)}}),2),Ee=Se[0],Pe=Se[1],ze=H(f({type:"mousemove",target:function(){return window.document},listener:function(e){return Fe(e)}}),2),ke=ze[0],je=ze[1],Ie=H(f({type:"mouseup",target:function(){return window.document},listener:function(e){return Be(e)}}),2),De=Ie[0],Re=Ie[1],Ce=function(e){D.onHide(),e.preventDefault()},_e=function(e){Q.current=e.target,D.onPointerDown&&D.onPointerDown(e)},Ne=function(e){D.dismissableMask&&D.modal&&q.current===e.target&&!Q.current&&Ce(e),D.onMaskClick&&D.onMaskClick(e),Q.current=null},Te=function(e){D.onMaximize?D.onMaximize({originalEvent:e,maximized:!pe}):W((function(e){return!e})),e.preventDefault()},Me=function(e){y.hasClass(e.target,"p-dialog-header-icon")||y.hasClass(e.target.parentElement,"p-dialog-header-icon")||D.draggable&&(oe.current=!0,ae.current=e.pageX,le.current=e.pageY,K.current.style.margin="0",y.addClass(document.body,"p-unselectable-text"),D.onDragStart&&D.onDragStart(e))},Fe=function(e){if(oe.current){var t=y.getOuterWidth(K.current),n=y.getOuterHeight(K.current),r=e.pageX-ae.current,o=e.pageY-le.current,i=K.current.getBoundingClientRect(),a=i.left+r,l=i.top+o,c=y.getViewport(),s=getComputedStyle(K.current),u=parseFloat(s.marginLeft),p=parseFloat(s.marginTop);K.current.style.position="fixed",D.keepInViewport?(a>=D.minX&&a+t<c.width&&(ae.current=e.pageX,K.current.style.left=a-u+"px"),l>=D.minY&&l+n<c.height&&(le.current=e.pageY,K.current.style.top=l-p+"px")):(ae.current=e.pageX,K.current.style.left=a-u+"px",le.current=e.pageY,K.current.style.top=l-p+"px"),D.onDrag&&D.onDrag(e)}},Be=function(e){oe.current&&(oe.current=!1,y.removeClass(document.body,"p-unselectable-text"),D.onDragEnd&&D.onDragEnd(e))},Xe=function(e){D.resizable&&(ie.current=!0,ae.current=e.pageX,le.current=e.pageY,y.addClass(document.body,"p-unselectable-text"),D.onResizeStart&&D.onResizeStart(e))},Ae=function(e,t,n){!n&&(n=y.getViewport());var r=parseInt(e);return/^(\d+|(\.\d+))(\.\d+)?%$/.test(e)?r*(n[t]/100):r},He=function(e){if(ie.current){var t=e.pageX-ae.current,n=e.pageY-le.current,r=y.getOuterWidth(K.current),o=y.getOuterHeight(K.current),i=K.current.getBoundingClientRect(),a=y.getViewport(),l=!parseInt(K.current.style.top)||!parseInt(K.current.style.left),c=Ae(K.current.style.minWidth,"width",a),s=Ae(K.current.style.minHeight,"height",a),u=r+t,p=o+n;l&&(u+=t,p+=n),(!c||u>c)&&i.left+u<a.width&&(K.current.style.width=u+"px"),(!s||p>s)&&i.top+p<a.height&&(K.current.style.height=p+"px"),ae.current=e.pageX,le.current=e.pageY,D.onResize&&D.onResize(e)}},Ye=function(e){ie.current&&(ie.current=!1,y.removeClass(document.body,"p-unselectable-text"),D.onResizeEnd&&D.onResizeEnd(e))},$e=function(){K.current.style.position="",K.current.style.left="",K.current.style.top="",K.current.style.margin=""},Le=function(){K.current.setAttribute(se.current,"")},Ve=function(){var e;D.onShow&&D.onShow(),D.focusOnShow&&!((e=document.activeElement)&&K.current&&K.current.contains(e))&&D.closable&&D.showHeader&&re.current&&re.current.focus(),Ue()},Je=function(){D.modal&&!ve()&&y.addClass(q.current,"p-component-overlay-leave")},Ze=function(){oe.current=!1,w.clear(q.current),A(!1),We(),y.focus(ue.current),ue.current=null},Ue=function(){Ke()},We=function(){qe()},Ge=function(e){if(e&&$){var t={id:F,hasBlockScroll:de};document.primeDialogParams||(document.primeDialogParams=[]);var n=document.primeDialogParams.findIndex((function(e){return e.id===F}));document.primeDialogParams=-1===n?[].concat(R(r=document.primeDialogParams)||C(r)||_(r)||N(),[t]):document.primeDialogParams.toSpliced(n,1,t)}else document.primeDialogParams=document.primeDialogParams&&document.primeDialogParams.filter((function(e){return e.id!==F}));var r;document.primeDialogParams&&document.primeDialogParams.some((function(e){return e.hasBlockScroll}))?y.blockBodyScroll():y.unblockBodyScroll()},Ke=function(){D.draggable&&(ke(),De()),D.resizable&&(we(),Ee())},qe=function(){je(),Re(),Oe(),Pe()},Qe=function(){ce.current=y.createInlineStyle(I&&I.nonce||n.nonce,I&&I.styleContainer);var e="";for(var t in D.breakpoints)e+="\n @media screen and (max-width: ".concat(t,') {\n [data-pc-name="dialog"][').concat(se.current,"] {\n width: ").concat(D.breakpoints[t]," !important;\n }\n }\n ");ce.current.innerHTML=e};s((function(){Ge(!0),D.visible&&A(!0)})),e.useEffect((function(){return D.breakpoints&&Qe(),function(){ce.current=y.removeInlineStyle(ce.current)}}),[D.breakpoints]),g((function(){D.visible&&!X&&A(!0),D.visible!==$&&X&&L(D.visible),D.visible&&(ue.current=document.activeElement)}),[D.visible,X]),g((function(){X&&(w.set("modal",q.current,I&&I.autoZIndex||n.autoZIndex,D.baseZIndex||I&&I.zIndex.modal||n.zIndex.modal),L(!0))}),[X]),g((function(){Ge(!0)}),[de,$]),b((function(){We(),Ge(!1),y.removeInlineStyle(ce.current),w.clear(q.current)})),e.useImperativeHandle(i,(function(){return{props:D,resetPosition:$e,getElement:function(){return K.current},getMask:function(){return q.current},getContent:function(){return ee.current},getHeader:function(){return te.current},getFooter:function(){return ne.current},getCloseButton:function(){return re.current}}}));var et=function(){if(D.closable){var t=D.ariaCloseIconLabel||o("close"),n=c({className:he("closeButtonIcon"),"aria-hidden":!0},be("closeButtonIcon")),r=O.getJSXIcon(D.closeIcon||e.createElement(S,n),G({},n),{props:D}),i=c({ref:re,type:"button",className:he("closeButton"),"aria-label":t,onClick:Ce,onKeyDown:function(e){return e.stopPropagation()}},be("closeButton"));return e.createElement("button",i,r,e.createElement(k,null))}return null},tt=function(){var t=c({className:he("maximizableIcon")},be("maximizableIcon")),n=O.getJSXIcon(pe?D.minimizeIcon||e.createElement(P,t):D.maximizeIcon||e.createElement(E,t),t,{props:D});if(D.maximizable){var r=c({type:"button",className:he("maximizableButton"),onClick:Te},be("maximizableButton"));return e.createElement("button",r,n,e.createElement(k,null))}return null},nt=function(){if(D.showHeader){var t=et(),n=tt(),r=h.getJSXElement(D.icons,D),o=h.getJSXElement(D.header,D),i=F+"_header",a=c({ref:te,style:D.headerStyle,className:he("header"),onMouseDown:Me},be("header")),l=c({id:i,className:he("headerTitle")},be("headerTitle")),s=c({className:he("headerIcons")},be("headerIcons"));return e.createElement("div",a,e.createElement("div",l,o),e.createElement("div",s,r,n,t))}return null},rt=function(){var t=h.getJSXElement(D.footer,D),n=c({ref:ne,className:he("footer")},be("footer"));return t&&e.createElement("div",n,t)};return X&&function(){var n,r,o,i,a,s,u=F+"_header",p=F+"_content",d={enter:"center"===D.position?150:300,exit:"center"===D.position?150:300},m=c({ref:q,style:ye("mask"),className:he("mask"),onPointerUp:Ne},be("mask")),f=c({ref:K,id:F,className:v(D.className,he("root",{props:D,maximized:pe,context:I})),style:D.style,onClick:D.onClick,role:"dialog","aria-labelledby":u,"aria-describedby":p,"aria-modal":D.modal,onPointerDown:_e},U.getOtherProps(D),be("root")),g=c({classNames:he("transition"),timeout:d,in:$,options:D.transitionOptions,unmountOnExit:!0,onEnter:Le,onEntered:Ve,onExiting:Je,onExited:Ze},be("transition")),b=null;null!=t&&t.content?(s={header:D.header,content:D.message,message:null==D||null===(a=D.children)||void 0===a||null===(a=a[1])||void 0===a||null===(a=a.props)||void 0===a?void 0:a.children},b=h.getJSXElement(t.content,{headerRef:te,contentRef:ee,footerRef:ne,closeRef:re,hide:Ce,message:s})):(r=nt(),n=c({id:F+"_content",ref:ee,style:D.contentStyle,className:he("content")},be("content")),o=e.createElement("div",n,D.children),i=rt(),b=e.createElement(e.Fragment,null,r,o,i,D.resizable?e.createElement("span",{className:"p-resizable-handle",style:{zIndex:90},onMouseDown:Xe}):null));var y=e.createElement("div",m,e.createElement(l,j({nodeRef:K},g),e.createElement("div",f,e.createElement(V,{autoFocus:!0},b))));return e.createElement(z,{element:y,appendTo:D.appendTo,visible:!0})}()}));K.displayName="Dialog";export{K as Dialog};
package/dialog/dialog.js CHANGED
@@ -313,7 +313,7 @@ this.primereact.dialog = (function (exports, React, PrimeReact, componentbase, c
313
313
  },
314
314
  transition: 'p-dialog'
315
315
  };
316
- var styles = "\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n \n .p-dialog-visible {\n display: flex;\n }\n \n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n \n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n \n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n \n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n \n .p-dialog-footer {\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n \n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n \n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n \n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n \n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n \n .p-dialog-enter-done {\n transform: none;\n }\n \n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n \n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n \n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n \n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n \n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n \n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n \n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n \n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n \n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n \n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n \n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n \n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n \n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n } \n}\n";
316
+ var styles = "\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n\n .p-dialog-visible {\n display: flex;\n }\n\n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n\n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n\n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n\n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .p-dialog-footer {\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n\n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n\n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n\n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n\n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n\n .p-dialog-enter-done {\n transform: none;\n }\n\n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n\n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n\n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n\n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n\n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n\n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n\n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n\n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n\n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n\n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n\n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n\n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n\n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n }\n}\n";
317
317
  var inlineStyles = {
318
318
  mask: function mask(_ref6) {
319
319
  var props = _ref6.props;
@@ -666,7 +666,6 @@ this.primereact.dialog = (function (exports, React, PrimeReact, componentbase, c
666
666
  }
667
667
  };
668
668
  var onExited = function onExited() {
669
- props.onHide && props.onHide();
670
669
  dragging.current = false;
671
670
  utils.ZIndexUtils.clear(maskRef.current);
672
671
  setMaskVisibleState(false);
@@ -835,7 +834,10 @@ this.primereact.dialog = (function (exports, React, PrimeReact, componentbase, c
835
834
  type: 'button',
836
835
  className: cx('closeButton'),
837
836
  'aria-label': ariaLabel,
838
- onClick: onClose
837
+ onClick: onClose,
838
+ onKeyDown: function onKeyDown(ev) {
839
+ return ev.stopPropagation();
840
+ }
839
841
  }, ptm('closeButton'));
840
842
  return /*#__PURE__*/React__namespace.createElement("button", closeButtonProps, headerCloseIcon, /*#__PURE__*/React__namespace.createElement(ripple.Ripple, null));
841
843
  }
@@ -1 +1 @@
1
- this.primereact=this.primereact||{},this.primereact.dialog=function(e,t,n,r,o,i,a,l,c,s,u,p){"use strict";function d(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function m(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}var f=d(t),g=m(t),b=d(n);function h(){return h=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},h.apply(this,arguments)}function y(e){return y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},y(e)}function v(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function x(e){if(Array.isArray(e))return v(e)}function O(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function w(e,t){if(e){if("string"==typeof e)return v(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?v(e,t):void 0}}function E(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function D(e,t){if("object"!==y(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==y(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function S(e){var t=D(e,"string");return"symbol"===y(t)?t:String(t)}function P(e,t,n){return(t=S(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function j(e){if(Array.isArray(e))return e}function z(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw o}}return l}}function I(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function k(e,t){return j(e)||z(e,t)||w(e,t)||I()}var R=r.ComponentBase.extend({defaultProps:{__TYPE:"FocusTrap",children:void 0},css:{styles:""},getProps:function(e){return a.ObjectUtils.getMergedProps(e,R.defaultProps)},getOtherProps:function(e){return a.ObjectUtils.getDiffProps(e,R.defaultProps)}});function C(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function H(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?C(Object(n),!0).forEach((function(t){P(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):C(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var _=f.default.memo(f.default.forwardRef((function(e,t){var r=f.default.useRef(null),o=f.default.useRef(null),l=f.default.useRef(null),c=f.default.useContext(n.PrimeReactContext),s=R.getProps(e,c),u={props:s};i.useStyle(R.css.styles,{name:"focustrap"});R.setMetaData(H({},u));f.default.useImperativeHandle(t,(function(){return{props:s,getInk:function(){return o.current},getTarget:function(){return r.current}}})),i.useMountEffect((function(){s.disabled||(r.current=h(),y(r.current))}));var p,d,m,g,b,h=function(){return o.current&&o.current.parentElement},y=function(e){var t=s||{},n=t.autoFocusSelector,r=t.firstFocusableSelector,o=void 0===r?"":r,i=t.autoFocus,l=void 0!==i&&i,c=a.DomHandler.getFirstFocusableElement(e,"[autofocus]".concat(v(void 0===n?"":n)));l&&!c&&(c=a.DomHandler.getFirstFocusableElement(e,v(o))),a.DomHandler.focus(c)},v=function(e){return':not(.p-hidden-focusable):not([data-p-hidden-focusable="true"])'.concat(null!=e?e:"")},x=function(e){var t,n=e.currentTarget,o=e.relatedTarget,i=o!==n.$_pfocustrap_firsthiddenfocusableelement&&null!==(t=r.current)&&void 0!==t&&t.contains(o)?n.$_pfocustrap_firsthiddenfocusableelement:a.DomHandler.getLastFocusableElement(n.parentElement,v(n.$_pfocustrap_focusableselector));a.DomHandler.focus(i)};return d=void 0===(p=(s||{}).tabIndex)?0:p,g=(m=function(e,t){return f.default.createElement("span",{ref:"firstfocusableelement"===t?o:l,className:"p-hidden-accessible p-hidden-focusable",tabIndex:d,role:"presentation","aria-hidden":!0,"data-p-hidden-accessible":!0,"data-p-hidden-focusable":!0,onFocus:e,"data-pc-section":t})})((function(e){var t,n=e.currentTarget,o=e.relatedTarget,i=o!==n.$_pfocustrap_lasthiddenfocusableelement&&null!==(t=r.current)&&void 0!==t&&t.contains(o)?n.$_pfocustrap_lasthiddenfocusableelement:a.DomHandler.getFirstFocusableElement(n.parentElement,v(n.$_pfocustrap_focusableselector));a.DomHandler.focus(i)}),"firstfocusableelement"),b=m(x,"lastfocusableelement"),g.ref.current&&b.ref.current&&(g.ref.current.$_pfocustrap_lasthiddenfocusableelement=b.ref.current,b.ref.current.$_pfocustrap_firsthiddenfocusableelement=g.ref.current),f.default.createElement(f.default.Fragment,null,g,s.children,b)})));function N(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function M(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?N(Object(n),!0).forEach((function(t){P(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):N(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var T=r.ComponentBase.extend({defaultProps:{__TYPE:"Dialog",__parentMetadata:null,appendTo:null,ariaCloseIconLabel:null,baseZIndex:0,blockScroll:!1,breakpoints:null,className:null,closable:!0,closeIcon:null,closeOnEscape:!0,content:null,contentClassName:null,contentStyle:null,dismissableMask:!1,draggable:!0,focusOnShow:!0,footer:null,footerClassName:null,header:null,headerClassName:null,headerStyle:null,icons:null,id:null,keepInViewport:!0,maskClassName:null,maskStyle:null,maximizable:!1,maximizeIcon:null,maximized:!1,minX:0,minY:0,minimizeIcon:null,modal:!0,onClick:null,onDrag:null,onDragEnd:null,onDragStart:null,onHide:null,onMaskClick:null,onMaximize:null,onResize:null,onResizeEnd:null,onResizeStart:null,onShow:null,position:"center",resizable:!0,rtl:!1,showHeader:!0,style:null,transitionOptions:null,visible:!1,children:void 0},css:{classes:{closeButtonIcon:"p-dialog-header-close-icon",closeButton:"p-dialog-header-icon p-dialog-header-close p-link",maximizableIcon:"p-dialog-header-maximize-icon",maximizableButton:"p-dialog-header-icon p-dialog-header-maximize p-link",header:function(e){return a.classNames("p-dialog-header",e.props.headerClassName)},headerTitle:"p-dialog-title",headerIcons:"p-dialog-header-icons",content:function(e){return a.classNames("p-dialog-content",e.props.contentClassName)},footer:function(e){return a.classNames("p-dialog-footer",e.props.footerClassName)},mask:function(e){var t=e.props,n=e.maskVisibleState,r=["center","left","right","top","top-left","top-right","bottom","bottom-left","bottom-right"].find((function(e){return e===t.position||e.replace("-","")===t.position}));return a.classNames("p-dialog-mask",r?"p-dialog-".concat(r):"",{"p-component-overlay p-component-overlay-enter":t.modal,"p-dialog-visible":n,"p-dialog-draggable":t.draggable,"p-dialog-resizable":t.resizable},t.maskClassName)},root:function(e){var t=e.maximized,n=e.context;return a.classNames("p-dialog p-component",{"p-dialog-rtl":e.props.rtl,"p-dialog-maximized":t,"p-dialog-default":!t,"p-input-filled":n&&"filled"===n.inputStyle||"filled"===b.default.inputStyle,"p-ripple-disabled":n&&!1===n.ripple||!1===b.default.ripple})},transition:"p-dialog"},styles:"\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n \n .p-dialog-visible {\n display: flex;\n }\n \n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n \n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n \n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n \n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n \n .p-dialog-footer {\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n \n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n \n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n \n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n \n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n \n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n \n .p-dialog-enter-done {\n transform: none;\n }\n \n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n \n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n \n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n \n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n \n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n \n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n \n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n \n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n \n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n \n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n \n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n \n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n \n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n } \n}\n",inlineStyles:{mask:function(e){var t=e.props;return M({position:"fixed",height:"100%",width:"100%",left:0,top:0,display:"flex",justifyContent:"left"===t.position||"top-left"===t.position||"bottom-left"===t.position?"flex-start":"right"===t.position||"top-right"===t.position||"bottom-right"===t.position?"flex-end":"center",alignItems:"top"===t.position||"top-left"===t.position||"top-right"===t.position?"flex-start":"bottom"===t.position||"bottom-left"===t.position||"bottom-right"===t.position?"flex-end":"center",pointerEvents:!t.modal&&"none"},t.maskStyle)}}}});function B(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function F(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?B(Object(n),!0).forEach((function(t){P(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):B(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var U=g.forwardRef((function(e,t){var d=i.useMergeProps(),m=g.useContext(n.PrimeReactContext),f=T.getProps(e,m),y=f.id?f.id:a.UniqueComponentId(),v=k(g.useState(y),2),D=v[0],S=k(g.useState(!1),2),P=S[0],j=S[1],z=k(g.useState(!1),2),I=z[0],R=z[1],C=k(g.useState(f.maximized),2),H=C[0],N=C[1],M=g.useRef(null),B=g.useRef(null),U=g.useRef(null),X=g.useRef(null),A=g.useRef(null),L=g.useRef(null),Y=g.useRef(null),$=g.useRef(!1),V=g.useRef(!1),Z=g.useRef(null),J=g.useRef(null),W=g.useRef(null),G=g.useRef(y),K=g.useRef(null),q=f.onMaximize?f.maximized:H,Q=I&&(f.blockScroll||f.maximizable&&q),ee=f.closable&&f.closeOnEscape&&I,te=i.useDisplayOrder("dialog",ee),ne=T.setMetaData(F(F({props:f},f.__parentMetadata),{},{state:{id:D,maximized:q,containerVisible:P}})),re=ne.ptm,oe=ne.cx,ie=ne.sx,ae=ne.isUnstyled;r.useHandleStyle(T.css.styles,ae,{name:"dialog"}),i.useGlobalOnEscapeKey({callback:function(e){ve(e)},when:ee&&te,priority:[i.ESC_KEY_HANDLING_PRIORITIES.DIALOG,te]});var le=k(i.useEventListener({type:"mousemove",target:function(){return window.document},listener:function(e){return ze(e)}}),2),ce=le[0],se=le[1],ue=k(i.useEventListener({type:"mouseup",target:function(){return window.document},listener:function(e){return Ie(e)}}),2),pe=ue[0],de=ue[1],me=k(i.useEventListener({type:"mousemove",target:function(){return window.document},listener:function(e){return De(e)}}),2),fe=me[0],ge=me[1],be=k(i.useEventListener({type:"mouseup",target:function(){return window.document},listener:function(e){return Se(e)}}),2),he=be[0],ye=be[1],ve=function(e){f.onHide(),e.preventDefault()},xe=function(e){U.current=e.target,f.onPointerDown&&f.onPointerDown(e)},Oe=function(e){f.dismissableMask&&f.modal&&B.current===e.target&&!U.current&&ve(e),f.onMaskClick&&f.onMaskClick(e),U.current=null},we=function(e){f.onMaximize?f.onMaximize({originalEvent:e,maximized:!q}):N((function(e){return!e})),e.preventDefault()},Ee=function(e){a.DomHandler.hasClass(e.target,"p-dialog-header-icon")||a.DomHandler.hasClass(e.target.parentElement,"p-dialog-header-icon")||f.draggable&&($.current=!0,Z.current=e.pageX,J.current=e.pageY,M.current.style.margin="0",a.DomHandler.addClass(document.body,"p-unselectable-text"),f.onDragStart&&f.onDragStart(e))},De=function(e){if($.current){var t=a.DomHandler.getOuterWidth(M.current),n=a.DomHandler.getOuterHeight(M.current),r=e.pageX-Z.current,o=e.pageY-J.current,i=M.current.getBoundingClientRect(),l=i.left+r,c=i.top+o,s=a.DomHandler.getViewport(),u=getComputedStyle(M.current),p=parseFloat(u.marginLeft),d=parseFloat(u.marginTop);M.current.style.position="fixed",f.keepInViewport?(l>=f.minX&&l+t<s.width&&(Z.current=e.pageX,M.current.style.left=l-p+"px"),c>=f.minY&&c+n<s.height&&(J.current=e.pageY,M.current.style.top=c-d+"px")):(Z.current=e.pageX,M.current.style.left=l-p+"px",J.current=e.pageY,M.current.style.top=c-d+"px"),f.onDrag&&f.onDrag(e)}},Se=function(e){$.current&&($.current=!1,a.DomHandler.removeClass(document.body,"p-unselectable-text"),f.onDragEnd&&f.onDragEnd(e))},Pe=function(e){f.resizable&&(V.current=!0,Z.current=e.pageX,J.current=e.pageY,a.DomHandler.addClass(document.body,"p-unselectable-text"),f.onResizeStart&&f.onResizeStart(e))},je=function(e,t,n){!n&&(n=a.DomHandler.getViewport());var r=parseInt(e);return/^(\d+|(\.\d+))(\.\d+)?%$/.test(e)?r*(n[t]/100):r},ze=function(e){if(V.current){var t=e.pageX-Z.current,n=e.pageY-J.current,r=a.DomHandler.getOuterWidth(M.current),o=a.DomHandler.getOuterHeight(M.current),i=M.current.getBoundingClientRect(),l=a.DomHandler.getViewport(),c=!parseInt(M.current.style.top)||!parseInt(M.current.style.left),s=je(M.current.style.minWidth,"width",l),u=je(M.current.style.minHeight,"height",l),p=r+t,d=o+n;c&&(p+=t,d+=n),(!s||p>s)&&i.left+p<l.width&&(M.current.style.width=p+"px"),(!u||d>u)&&i.top+d<l.height&&(M.current.style.height=d+"px"),Z.current=e.pageX,J.current=e.pageY,f.onResize&&f.onResize(e)}},Ie=function(e){V.current&&(V.current=!1,a.DomHandler.removeClass(document.body,"p-unselectable-text"),f.onResizeEnd&&f.onResizeEnd(e))},ke=function(){M.current.style.position="",M.current.style.left="",M.current.style.top="",M.current.style.margin=""},Re=function(){M.current.setAttribute(G.current,"")},Ce=function(){var e;f.onShow&&f.onShow(),f.focusOnShow&&!((e=document.activeElement)&&M.current&&M.current.contains(e))&&f.closable&&f.showHeader&&Y.current&&Y.current.focus(),Ne()},He=function(){f.modal&&!ae()&&a.DomHandler.addClass(B.current,"p-component-overlay-leave")},_e=function(){f.onHide&&f.onHide(),$.current=!1,a.ZIndexUtils.clear(B.current),j(!1),Me(),a.DomHandler.focus(K.current),K.current=null},Ne=function(){Be()},Me=function(){Fe()},Te=function(e){if(e&&I){var t={id:D,hasBlockScroll:Q};document.primeDialogParams||(document.primeDialogParams=[]);var n=document.primeDialogParams.findIndex((function(e){return e.id===D}));document.primeDialogParams=-1===n?[].concat(x(r=document.primeDialogParams)||O(r)||w(r)||E(),[t]):document.primeDialogParams.toSpliced(n,1,t)}else document.primeDialogParams=document.primeDialogParams&&document.primeDialogParams.filter((function(e){return e.id!==D}));var r;document.primeDialogParams&&document.primeDialogParams.some((function(e){return e.hasBlockScroll}))?a.DomHandler.blockBodyScroll():a.DomHandler.unblockBodyScroll()},Be=function(){f.draggable&&(fe(),he()),f.resizable&&(ce(),pe())},Fe=function(){ge(),ye(),se(),de()},Ue=function(){W.current=a.DomHandler.createInlineStyle(m&&m.nonce||b.default.nonce,m&&m.styleContainer);var e="";for(var t in f.breakpoints)e+="\n @media screen and (max-width: ".concat(t,') {\n [data-pc-name="dialog"][').concat(G.current,"] {\n width: ").concat(f.breakpoints[t]," !important;\n }\n }\n ");W.current.innerHTML=e};i.useMountEffect((function(){Te(!0),f.visible&&j(!0)})),g.useEffect((function(){return f.breakpoints&&Ue(),function(){W.current=a.DomHandler.removeInlineStyle(W.current)}}),[f.breakpoints]),i.useUpdateEffect((function(){f.visible&&!P&&j(!0),f.visible!==I&&P&&R(f.visible),f.visible&&(K.current=document.activeElement)}),[f.visible,P]),i.useUpdateEffect((function(){P&&(a.ZIndexUtils.set("modal",B.current,m&&m.autoZIndex||b.default.autoZIndex,f.baseZIndex||m&&m.zIndex.modal||b.default.zIndex.modal),R(!0))}),[P]),i.useUpdateEffect((function(){Te(!0)}),[Q,I]),i.useUnmountEffect((function(){Me(),Te(!1),a.DomHandler.removeInlineStyle(W.current),a.ZIndexUtils.clear(B.current)})),g.useImperativeHandle(t,(function(){return{props:f,resetPosition:ke,getElement:function(){return M.current},getMask:function(){return B.current},getContent:function(){return X.current},getHeader:function(){return A.current},getFooter:function(){return L.current},getCloseButton:function(){return Y.current}}}));var Xe=function(){if(f.closable){var e=f.ariaCloseIconLabel||n.localeOption("close"),t=d({className:oe("closeButtonIcon"),"aria-hidden":!0},re("closeButtonIcon")),r=a.IconUtils.getJSXIcon(f.closeIcon||g.createElement(l.TimesIcon,t),F({},t),{props:f}),o=d({ref:Y,type:"button",className:oe("closeButton"),"aria-label":e,onClick:ve},re("closeButton"));return g.createElement("button",o,r,g.createElement(p.Ripple,null))}return null},Ae=function(){var e=d({className:oe("maximizableIcon")},re("maximizableIcon")),t=a.IconUtils.getJSXIcon(q?f.minimizeIcon||g.createElement(s.WindowMinimizeIcon,e):f.maximizeIcon||g.createElement(c.WindowMaximizeIcon,e),e,{props:f});if(f.maximizable){var n=d({type:"button",className:oe("maximizableButton"),onClick:we},re("maximizableButton"));return g.createElement("button",n,t,g.createElement(p.Ripple,null))}return null},Le=function(){if(f.showHeader){var e=Xe(),t=Ae(),n=a.ObjectUtils.getJSXElement(f.icons,f),r=a.ObjectUtils.getJSXElement(f.header,f),o=D+"_header",i=d({ref:A,style:f.headerStyle,className:oe("header"),onMouseDown:Ee},re("header")),l=d({id:o,className:oe("headerTitle")},re("headerTitle")),c=d({className:oe("headerIcons")},re("headerIcons"));return g.createElement("div",i,g.createElement("div",l,r),g.createElement("div",c,n,t,e))}return null},Ye=function(){var e=a.ObjectUtils.getJSXElement(f.footer,f),t=d({ref:L,className:oe("footer")},re("footer"));return e&&g.createElement("div",t,e)};return P&&function(){var t,n,r,i,l,c,s=D+"_header",p=D+"_content",b={enter:"center"===f.position?150:300,exit:"center"===f.position?150:300},y=d({ref:B,style:ie("mask"),className:oe("mask"),onPointerUp:Oe},re("mask")),v=d({ref:M,id:D,className:a.classNames(f.className,oe("root",{props:f,maximized:q,context:m})),style:f.style,onClick:f.onClick,role:"dialog","aria-labelledby":s,"aria-describedby":p,"aria-modal":f.modal,onPointerDown:xe},T.getOtherProps(f),re("root")),x=d({classNames:oe("transition"),timeout:b,in:I,options:f.transitionOptions,unmountOnExit:!0,onEnter:Re,onEntered:Ce,onExiting:He,onExited:_e},re("transition")),O=null;null!=e&&e.content?(c={header:f.header,content:f.message,message:null==f||null===(l=f.children)||void 0===l||null===(l=l[1])||void 0===l||null===(l=l.props)||void 0===l?void 0:l.children},O=a.ObjectUtils.getJSXElement(e.content,{headerRef:A,contentRef:X,footerRef:L,closeRef:Y,hide:ve,message:c})):(n=Le(),t=d({id:D+"_content",ref:X,style:f.contentStyle,className:oe("content")},re("content")),r=g.createElement("div",t,f.children),i=Ye(),O=g.createElement(g.Fragment,null,n,r,i,f.resizable?g.createElement("span",{className:"p-resizable-handle",style:{zIndex:90},onMouseDown:Pe}):null));var w=g.createElement("div",y,g.createElement(o.CSSTransition,h({nodeRef:M},x),g.createElement("div",v,g.createElement(_,{autoFocus:!0},O))));return g.createElement(u.Portal,{element:w,appendTo:f.appendTo,visible:!0})}()}));return U.displayName="Dialog",e.Dialog=U,Object.defineProperty(e,"__esModule",{value:!0}),e}({},React,primereact.api,primereact.componentbase,primereact.csstransition,primereact.hooks,primereact.utils,primereact.icons.times,primereact.icons.windowmaximize,primereact.icons.windowminimize,primereact.portal,primereact.ripple);
1
+ this.primereact=this.primereact||{},this.primereact.dialog=function(e,t,n,r,o,i,a,l,c,s,u,p){"use strict";function d(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function m(e){if(e&&e.__esModule)return e;var t=Object.create(null);return e&&Object.keys(e).forEach((function(n){if("default"!==n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})}})),t.default=e,Object.freeze(t)}var f=d(t),g=m(t),b=d(n);function h(){return h=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},h.apply(this,arguments)}function y(e){return y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},y(e)}function v(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function x(e){if(Array.isArray(e))return v(e)}function O(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}function w(e,t){if(e){if("string"==typeof e)return v(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?v(e,t):void 0}}function E(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function D(e,t){if("object"!==y(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,t||"default");if("object"!==y(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}function S(e){var t=D(e,"string");return"symbol"===y(t)?t:String(t)}function P(e,t,n){return(t=S(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function j(e){if(Array.isArray(e))return e}function z(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var r,o,i,a,l=[],c=!0,s=!1;try{if(i=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;c=!1}else for(;!(c=(r=i.call(n)).done)&&(l.push(r.value),l.length!==t);c=!0);}catch(e){s=!0,o=e}finally{try{if(!c&&null!=n.return&&(a=n.return(),Object(a)!==a))return}finally{if(s)throw o}}return l}}function I(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function k(e,t){return j(e)||z(e,t)||w(e,t)||I()}var R=r.ComponentBase.extend({defaultProps:{__TYPE:"FocusTrap",children:void 0},css:{styles:""},getProps:function(e){return a.ObjectUtils.getMergedProps(e,R.defaultProps)},getOtherProps:function(e){return a.ObjectUtils.getDiffProps(e,R.defaultProps)}});function C(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function H(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?C(Object(n),!0).forEach((function(t){P(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):C(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var _=f.default.memo(f.default.forwardRef((function(e,t){var r=f.default.useRef(null),o=f.default.useRef(null),l=f.default.useRef(null),c=f.default.useContext(n.PrimeReactContext),s=R.getProps(e,c),u={props:s};i.useStyle(R.css.styles,{name:"focustrap"});R.setMetaData(H({},u));f.default.useImperativeHandle(t,(function(){return{props:s,getInk:function(){return o.current},getTarget:function(){return r.current}}})),i.useMountEffect((function(){s.disabled||(r.current=h(),y(r.current))}));var p,d,m,g,b,h=function(){return o.current&&o.current.parentElement},y=function(e){var t=s||{},n=t.autoFocusSelector,r=t.firstFocusableSelector,o=void 0===r?"":r,i=t.autoFocus,l=void 0!==i&&i,c=a.DomHandler.getFirstFocusableElement(e,"[autofocus]".concat(v(void 0===n?"":n)));l&&!c&&(c=a.DomHandler.getFirstFocusableElement(e,v(o))),a.DomHandler.focus(c)},v=function(e){return':not(.p-hidden-focusable):not([data-p-hidden-focusable="true"])'.concat(null!=e?e:"")},x=function(e){var t,n=e.currentTarget,o=e.relatedTarget,i=o!==n.$_pfocustrap_firsthiddenfocusableelement&&null!==(t=r.current)&&void 0!==t&&t.contains(o)?n.$_pfocustrap_firsthiddenfocusableelement:a.DomHandler.getLastFocusableElement(n.parentElement,v(n.$_pfocustrap_focusableselector));a.DomHandler.focus(i)};return d=void 0===(p=(s||{}).tabIndex)?0:p,g=(m=function(e,t){return f.default.createElement("span",{ref:"firstfocusableelement"===t?o:l,className:"p-hidden-accessible p-hidden-focusable",tabIndex:d,role:"presentation","aria-hidden":!0,"data-p-hidden-accessible":!0,"data-p-hidden-focusable":!0,onFocus:e,"data-pc-section":t})})((function(e){var t,n=e.currentTarget,o=e.relatedTarget,i=o!==n.$_pfocustrap_lasthiddenfocusableelement&&null!==(t=r.current)&&void 0!==t&&t.contains(o)?n.$_pfocustrap_lasthiddenfocusableelement:a.DomHandler.getFirstFocusableElement(n.parentElement,v(n.$_pfocustrap_focusableselector));a.DomHandler.focus(i)}),"firstfocusableelement"),b=m(x,"lastfocusableelement"),g.ref.current&&b.ref.current&&(g.ref.current.$_pfocustrap_lasthiddenfocusableelement=b.ref.current,b.ref.current.$_pfocustrap_firsthiddenfocusableelement=g.ref.current),f.default.createElement(f.default.Fragment,null,g,s.children,b)})));function N(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function M(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?N(Object(n),!0).forEach((function(t){P(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):N(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var T=r.ComponentBase.extend({defaultProps:{__TYPE:"Dialog",__parentMetadata:null,appendTo:null,ariaCloseIconLabel:null,baseZIndex:0,blockScroll:!1,breakpoints:null,className:null,closable:!0,closeIcon:null,closeOnEscape:!0,content:null,contentClassName:null,contentStyle:null,dismissableMask:!1,draggable:!0,focusOnShow:!0,footer:null,footerClassName:null,header:null,headerClassName:null,headerStyle:null,icons:null,id:null,keepInViewport:!0,maskClassName:null,maskStyle:null,maximizable:!1,maximizeIcon:null,maximized:!1,minX:0,minY:0,minimizeIcon:null,modal:!0,onClick:null,onDrag:null,onDragEnd:null,onDragStart:null,onHide:null,onMaskClick:null,onMaximize:null,onResize:null,onResizeEnd:null,onResizeStart:null,onShow:null,position:"center",resizable:!0,rtl:!1,showHeader:!0,style:null,transitionOptions:null,visible:!1,children:void 0},css:{classes:{closeButtonIcon:"p-dialog-header-close-icon",closeButton:"p-dialog-header-icon p-dialog-header-close p-link",maximizableIcon:"p-dialog-header-maximize-icon",maximizableButton:"p-dialog-header-icon p-dialog-header-maximize p-link",header:function(e){return a.classNames("p-dialog-header",e.props.headerClassName)},headerTitle:"p-dialog-title",headerIcons:"p-dialog-header-icons",content:function(e){return a.classNames("p-dialog-content",e.props.contentClassName)},footer:function(e){return a.classNames("p-dialog-footer",e.props.footerClassName)},mask:function(e){var t=e.props,n=e.maskVisibleState,r=["center","left","right","top","top-left","top-right","bottom","bottom-left","bottom-right"].find((function(e){return e===t.position||e.replace("-","")===t.position}));return a.classNames("p-dialog-mask",r?"p-dialog-".concat(r):"",{"p-component-overlay p-component-overlay-enter":t.modal,"p-dialog-visible":n,"p-dialog-draggable":t.draggable,"p-dialog-resizable":t.resizable},t.maskClassName)},root:function(e){var t=e.maximized,n=e.context;return a.classNames("p-dialog p-component",{"p-dialog-rtl":e.props.rtl,"p-dialog-maximized":t,"p-dialog-default":!t,"p-input-filled":n&&"filled"===n.inputStyle||"filled"===b.default.inputStyle,"p-ripple-disabled":n&&!1===n.ripple||!1===b.default.ripple})},transition:"p-dialog"},styles:"\n@layer primereact {\n .p-dialog-mask {\n background-color: transparent;\n transition-property: background-color;\n }\n\n .p-dialog-visible {\n display: flex;\n }\n\n .p-dialog-mask.p-component-overlay {\n pointer-events: auto;\n }\n\n .p-dialog {\n display: flex;\n flex-direction: column;\n pointer-events: auto;\n max-height: 90%;\n transform: scale(1);\n position: relative;\n }\n\n .p-dialog-content {\n overflow-y: auto;\n flex-grow: 1;\n }\n\n .p-dialog-header {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .p-dialog-footer {\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icons {\n display: flex;\n align-items: center;\n align-self: flex-start;\n flex-shrink: 0;\n }\n\n .p-dialog .p-dialog-header-icon {\n display: flex;\n align-items: center;\n justify-content: center;\n overflow: hidden;\n position: relative;\n }\n\n .p-dialog .p-dialog-title {\n flex-grow: 1;\n }\n\n /* Fluid */\n .p-fluid .p-dialog-footer .p-button {\n width: auto;\n }\n\n /* Animation */\n /* Center */\n .p-dialog-enter {\n opacity: 0;\n transform: scale(0.7);\n }\n\n .p-dialog-enter-active {\n opacity: 1;\n transform: scale(1);\n transition: all 150ms cubic-bezier(0, 0, 0.2, 1);\n }\n\n .p-dialog-enter-done {\n transform: none;\n }\n\n .p-dialog-exit-active {\n opacity: 0;\n transform: scale(0.7);\n transition: all 150ms cubic-bezier(0.4, 0, 0.2, 1);\n }\n\n /* Top, Bottom, Left, Right, Top* and Bottom* */\n .p-dialog-top .p-dialog,\n .p-dialog-bottom .p-dialog,\n .p-dialog-left .p-dialog,\n .p-dialog-right .p-dialog,\n .p-dialog-top-left .p-dialog,\n .p-dialog-top-right .p-dialog,\n .p-dialog-bottom-left .p-dialog,\n .p-dialog-bottom-right .p-dialog {\n margin: 0.75em;\n }\n\n .p-dialog-top .p-dialog-enter,\n .p-dialog-top .p-dialog-exit-active {\n transform: translate3d(0px, -100%, 0px);\n }\n\n .p-dialog-bottom .p-dialog-enter,\n .p-dialog-bottom .p-dialog-exit-active {\n transform: translate3d(0px, 100%, 0px);\n }\n\n .p-dialog-left .p-dialog-enter,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-enter,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-enter,\n .p-dialog-bottom-left .p-dialog-exit-active {\n transform: translate3d(-100%, 0px, 0px);\n }\n\n .p-dialog-right .p-dialog-enter,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-enter,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-enter,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transform: translate3d(100%, 0px, 0px);\n }\n\n .p-dialog-top .p-dialog-enter-active,\n .p-dialog-bottom .p-dialog-enter-active,\n .p-dialog-left .p-dialog-enter-active,\n .p-dialog-top-left .p-dialog-enter-active,\n .p-dialog-bottom-left .p-dialog-enter-active,\n .p-dialog-right .p-dialog-enter-active,\n .p-dialog-top-right .p-dialog-enter-active,\n .p-dialog-bottom-right .p-dialog-enter-active {\n transform: translate3d(0px, 0px, 0px);\n transition: all 0.3s ease-out;\n }\n\n .p-dialog-top .p-dialog-exit-active,\n .p-dialog-bottom .p-dialog-exit-active,\n .p-dialog-left .p-dialog-exit-active,\n .p-dialog-top-left .p-dialog-exit-active,\n .p-dialog-bottom-left .p-dialog-exit-active,\n .p-dialog-right .p-dialog-exit-active,\n .p-dialog-top-right .p-dialog-exit-active,\n .p-dialog-bottom-right .p-dialog-exit-active {\n transition: all 0.3s ease-out;\n }\n\n /* Maximize */\n .p-dialog-maximized {\n transition: none;\n transform: none;\n margin: 0;\n width: 100vw !important;\n height: 100vh !important;\n max-height: 100%;\n top: 0px !important;\n left: 0px !important;\n }\n\n .p-dialog-maximized .p-dialog-content {\n flex-grow: 1;\n }\n\n .p-confirm-dialog .p-dialog-content {\n display: flex;\n align-items: center;\n }\n\n /* Resizable */\n .p-dialog .p-resizable-handle {\n position: absolute;\n font-size: 0.1px;\n display: block;\n cursor: se-resize;\n width: 12px;\n height: 12px;\n right: 1px;\n bottom: 1px;\n }\n\n .p-dialog-draggable .p-dialog-header {\n cursor: move;\n }\n}\n",inlineStyles:{mask:function(e){var t=e.props;return M({position:"fixed",height:"100%",width:"100%",left:0,top:0,display:"flex",justifyContent:"left"===t.position||"top-left"===t.position||"bottom-left"===t.position?"flex-start":"right"===t.position||"top-right"===t.position||"bottom-right"===t.position?"flex-end":"center",alignItems:"top"===t.position||"top-left"===t.position||"top-right"===t.position?"flex-start":"bottom"===t.position||"bottom-left"===t.position||"bottom-right"===t.position?"flex-end":"center",pointerEvents:!t.modal&&"none"},t.maskStyle)}}}});function B(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function F(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?B(Object(n),!0).forEach((function(t){P(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):B(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var U=g.forwardRef((function(e,t){var d=i.useMergeProps(),m=g.useContext(n.PrimeReactContext),f=T.getProps(e,m),y=f.id?f.id:a.UniqueComponentId(),v=k(g.useState(y),2),D=v[0],S=k(g.useState(!1),2),P=S[0],j=S[1],z=k(g.useState(!1),2),I=z[0],R=z[1],C=k(g.useState(f.maximized),2),H=C[0],N=C[1],M=g.useRef(null),B=g.useRef(null),U=g.useRef(null),X=g.useRef(null),A=g.useRef(null),L=g.useRef(null),Y=g.useRef(null),$=g.useRef(!1),V=g.useRef(!1),Z=g.useRef(null),J=g.useRef(null),W=g.useRef(null),G=g.useRef(y),K=g.useRef(null),q=f.onMaximize?f.maximized:H,Q=I&&(f.blockScroll||f.maximizable&&q),ee=f.closable&&f.closeOnEscape&&I,te=i.useDisplayOrder("dialog",ee),ne=T.setMetaData(F(F({props:f},f.__parentMetadata),{},{state:{id:D,maximized:q,containerVisible:P}})),re=ne.ptm,oe=ne.cx,ie=ne.sx,ae=ne.isUnstyled;r.useHandleStyle(T.css.styles,ae,{name:"dialog"}),i.useGlobalOnEscapeKey({callback:function(e){ve(e)},when:ee&&te,priority:[i.ESC_KEY_HANDLING_PRIORITIES.DIALOG,te]});var le=k(i.useEventListener({type:"mousemove",target:function(){return window.document},listener:function(e){return ze(e)}}),2),ce=le[0],se=le[1],ue=k(i.useEventListener({type:"mouseup",target:function(){return window.document},listener:function(e){return Ie(e)}}),2),pe=ue[0],de=ue[1],me=k(i.useEventListener({type:"mousemove",target:function(){return window.document},listener:function(e){return De(e)}}),2),fe=me[0],ge=me[1],be=k(i.useEventListener({type:"mouseup",target:function(){return window.document},listener:function(e){return Se(e)}}),2),he=be[0],ye=be[1],ve=function(e){f.onHide(),e.preventDefault()},xe=function(e){U.current=e.target,f.onPointerDown&&f.onPointerDown(e)},Oe=function(e){f.dismissableMask&&f.modal&&B.current===e.target&&!U.current&&ve(e),f.onMaskClick&&f.onMaskClick(e),U.current=null},we=function(e){f.onMaximize?f.onMaximize({originalEvent:e,maximized:!q}):N((function(e){return!e})),e.preventDefault()},Ee=function(e){a.DomHandler.hasClass(e.target,"p-dialog-header-icon")||a.DomHandler.hasClass(e.target.parentElement,"p-dialog-header-icon")||f.draggable&&($.current=!0,Z.current=e.pageX,J.current=e.pageY,M.current.style.margin="0",a.DomHandler.addClass(document.body,"p-unselectable-text"),f.onDragStart&&f.onDragStart(e))},De=function(e){if($.current){var t=a.DomHandler.getOuterWidth(M.current),n=a.DomHandler.getOuterHeight(M.current),r=e.pageX-Z.current,o=e.pageY-J.current,i=M.current.getBoundingClientRect(),l=i.left+r,c=i.top+o,s=a.DomHandler.getViewport(),u=getComputedStyle(M.current),p=parseFloat(u.marginLeft),d=parseFloat(u.marginTop);M.current.style.position="fixed",f.keepInViewport?(l>=f.minX&&l+t<s.width&&(Z.current=e.pageX,M.current.style.left=l-p+"px"),c>=f.minY&&c+n<s.height&&(J.current=e.pageY,M.current.style.top=c-d+"px")):(Z.current=e.pageX,M.current.style.left=l-p+"px",J.current=e.pageY,M.current.style.top=c-d+"px"),f.onDrag&&f.onDrag(e)}},Se=function(e){$.current&&($.current=!1,a.DomHandler.removeClass(document.body,"p-unselectable-text"),f.onDragEnd&&f.onDragEnd(e))},Pe=function(e){f.resizable&&(V.current=!0,Z.current=e.pageX,J.current=e.pageY,a.DomHandler.addClass(document.body,"p-unselectable-text"),f.onResizeStart&&f.onResizeStart(e))},je=function(e,t,n){!n&&(n=a.DomHandler.getViewport());var r=parseInt(e);return/^(\d+|(\.\d+))(\.\d+)?%$/.test(e)?r*(n[t]/100):r},ze=function(e){if(V.current){var t=e.pageX-Z.current,n=e.pageY-J.current,r=a.DomHandler.getOuterWidth(M.current),o=a.DomHandler.getOuterHeight(M.current),i=M.current.getBoundingClientRect(),l=a.DomHandler.getViewport(),c=!parseInt(M.current.style.top)||!parseInt(M.current.style.left),s=je(M.current.style.minWidth,"width",l),u=je(M.current.style.minHeight,"height",l),p=r+t,d=o+n;c&&(p+=t,d+=n),(!s||p>s)&&i.left+p<l.width&&(M.current.style.width=p+"px"),(!u||d>u)&&i.top+d<l.height&&(M.current.style.height=d+"px"),Z.current=e.pageX,J.current=e.pageY,f.onResize&&f.onResize(e)}},Ie=function(e){V.current&&(V.current=!1,a.DomHandler.removeClass(document.body,"p-unselectable-text"),f.onResizeEnd&&f.onResizeEnd(e))},ke=function(){M.current.style.position="",M.current.style.left="",M.current.style.top="",M.current.style.margin=""},Re=function(){M.current.setAttribute(G.current,"")},Ce=function(){var e;f.onShow&&f.onShow(),f.focusOnShow&&!((e=document.activeElement)&&M.current&&M.current.contains(e))&&f.closable&&f.showHeader&&Y.current&&Y.current.focus(),Ne()},He=function(){f.modal&&!ae()&&a.DomHandler.addClass(B.current,"p-component-overlay-leave")},_e=function(){$.current=!1,a.ZIndexUtils.clear(B.current),j(!1),Me(),a.DomHandler.focus(K.current),K.current=null},Ne=function(){Be()},Me=function(){Fe()},Te=function(e){if(e&&I){var t={id:D,hasBlockScroll:Q};document.primeDialogParams||(document.primeDialogParams=[]);var n=document.primeDialogParams.findIndex((function(e){return e.id===D}));document.primeDialogParams=-1===n?[].concat(x(r=document.primeDialogParams)||O(r)||w(r)||E(),[t]):document.primeDialogParams.toSpliced(n,1,t)}else document.primeDialogParams=document.primeDialogParams&&document.primeDialogParams.filter((function(e){return e.id!==D}));var r;document.primeDialogParams&&document.primeDialogParams.some((function(e){return e.hasBlockScroll}))?a.DomHandler.blockBodyScroll():a.DomHandler.unblockBodyScroll()},Be=function(){f.draggable&&(fe(),he()),f.resizable&&(ce(),pe())},Fe=function(){ge(),ye(),se(),de()},Ue=function(){W.current=a.DomHandler.createInlineStyle(m&&m.nonce||b.default.nonce,m&&m.styleContainer);var e="";for(var t in f.breakpoints)e+="\n @media screen and (max-width: ".concat(t,') {\n [data-pc-name="dialog"][').concat(G.current,"] {\n width: ").concat(f.breakpoints[t]," !important;\n }\n }\n ");W.current.innerHTML=e};i.useMountEffect((function(){Te(!0),f.visible&&j(!0)})),g.useEffect((function(){return f.breakpoints&&Ue(),function(){W.current=a.DomHandler.removeInlineStyle(W.current)}}),[f.breakpoints]),i.useUpdateEffect((function(){f.visible&&!P&&j(!0),f.visible!==I&&P&&R(f.visible),f.visible&&(K.current=document.activeElement)}),[f.visible,P]),i.useUpdateEffect((function(){P&&(a.ZIndexUtils.set("modal",B.current,m&&m.autoZIndex||b.default.autoZIndex,f.baseZIndex||m&&m.zIndex.modal||b.default.zIndex.modal),R(!0))}),[P]),i.useUpdateEffect((function(){Te(!0)}),[Q,I]),i.useUnmountEffect((function(){Me(),Te(!1),a.DomHandler.removeInlineStyle(W.current),a.ZIndexUtils.clear(B.current)})),g.useImperativeHandle(t,(function(){return{props:f,resetPosition:ke,getElement:function(){return M.current},getMask:function(){return B.current},getContent:function(){return X.current},getHeader:function(){return A.current},getFooter:function(){return L.current},getCloseButton:function(){return Y.current}}}));var Xe=function(){if(f.closable){var e=f.ariaCloseIconLabel||n.localeOption("close"),t=d({className:oe("closeButtonIcon"),"aria-hidden":!0},re("closeButtonIcon")),r=a.IconUtils.getJSXIcon(f.closeIcon||g.createElement(l.TimesIcon,t),F({},t),{props:f}),o=d({ref:Y,type:"button",className:oe("closeButton"),"aria-label":e,onClick:ve,onKeyDown:function(e){return e.stopPropagation()}},re("closeButton"));return g.createElement("button",o,r,g.createElement(p.Ripple,null))}return null},Ae=function(){var e=d({className:oe("maximizableIcon")},re("maximizableIcon")),t=a.IconUtils.getJSXIcon(q?f.minimizeIcon||g.createElement(s.WindowMinimizeIcon,e):f.maximizeIcon||g.createElement(c.WindowMaximizeIcon,e),e,{props:f});if(f.maximizable){var n=d({type:"button",className:oe("maximizableButton"),onClick:we},re("maximizableButton"));return g.createElement("button",n,t,g.createElement(p.Ripple,null))}return null},Le=function(){if(f.showHeader){var e=Xe(),t=Ae(),n=a.ObjectUtils.getJSXElement(f.icons,f),r=a.ObjectUtils.getJSXElement(f.header,f),o=D+"_header",i=d({ref:A,style:f.headerStyle,className:oe("header"),onMouseDown:Ee},re("header")),l=d({id:o,className:oe("headerTitle")},re("headerTitle")),c=d({className:oe("headerIcons")},re("headerIcons"));return g.createElement("div",i,g.createElement("div",l,r),g.createElement("div",c,n,t,e))}return null},Ye=function(){var e=a.ObjectUtils.getJSXElement(f.footer,f),t=d({ref:L,className:oe("footer")},re("footer"));return e&&g.createElement("div",t,e)};return P&&function(){var t,n,r,i,l,c,s=D+"_header",p=D+"_content",b={enter:"center"===f.position?150:300,exit:"center"===f.position?150:300},y=d({ref:B,style:ie("mask"),className:oe("mask"),onPointerUp:Oe},re("mask")),v=d({ref:M,id:D,className:a.classNames(f.className,oe("root",{props:f,maximized:q,context:m})),style:f.style,onClick:f.onClick,role:"dialog","aria-labelledby":s,"aria-describedby":p,"aria-modal":f.modal,onPointerDown:xe},T.getOtherProps(f),re("root")),x=d({classNames:oe("transition"),timeout:b,in:I,options:f.transitionOptions,unmountOnExit:!0,onEnter:Re,onEntered:Ce,onExiting:He,onExited:_e},re("transition")),O=null;null!=e&&e.content?(c={header:f.header,content:f.message,message:null==f||null===(l=f.children)||void 0===l||null===(l=l[1])||void 0===l||null===(l=l.props)||void 0===l?void 0:l.children},O=a.ObjectUtils.getJSXElement(e.content,{headerRef:A,contentRef:X,footerRef:L,closeRef:Y,hide:ve,message:c})):(n=Le(),t=d({id:D+"_content",ref:X,style:f.contentStyle,className:oe("content")},re("content")),r=g.createElement("div",t,f.children),i=Ye(),O=g.createElement(g.Fragment,null,n,r,i,f.resizable?g.createElement("span",{className:"p-resizable-handle",style:{zIndex:90},onMouseDown:Pe}):null));var w=g.createElement("div",y,g.createElement(o.CSSTransition,h({nodeRef:M},x),g.createElement("div",v,g.createElement(_,{autoFocus:!0},O))));return g.createElement(u.Portal,{element:w,appendTo:f.appendTo,visible:!0})}()}));return U.displayName="Dialog",e.Dialog=U,Object.defineProperty(e,"__esModule",{value:!0}),e}({},React,primereact.api,primereact.componentbase,primereact.csstransition,primereact.hooks,primereact.utils,primereact.icons.times,primereact.icons.windowmaximize,primereact.icons.windowminimize,primereact.portal,primereact.ripple);
@@ -413,7 +413,7 @@ var DropdownItem = /*#__PURE__*/React__namespace.memo(function (props) {
413
413
  if (selected) {
414
414
  var checkIconProps = mergeProps({
415
415
  className: cx('checkIcon')
416
- }, getPTOptions('checIcon'));
416
+ }, getPTOptions('checkIcon'));
417
417
  return /*#__PURE__*/React__namespace.createElement(check.CheckIcon, checkIconProps);
418
418
  }
419
419
  var blankIconProps = mergeProps({
@@ -500,7 +500,7 @@ var DropdownPanel = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__name
500
500
  height: scrollerOptions.props ? scrollerOptions.props.itemSize : undefined
501
501
  };
502
502
  style = _objectSpread$1(_objectSpread$1({}, style), option.style);
503
- if (option.group && props.optionGroupLabel) {
503
+ if (option.group && option.optionGroup && props.optionGroupLabel) {
504
504
  var optionGroupLabel = props.optionGroupLabel;
505
505
  var groupContent = props.optionGroupTemplate ? utils.ObjectUtils.getJSXElement(props.optionGroupTemplate, option, index) : props.getOptionGroupLabel(option);
506
506
  var key = index + '_' + props.getOptionGroupRenderKey(option);
@@ -1374,7 +1374,7 @@ var Dropdown = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
1374
1374
  }
1375
1375
  };
1376
1376
  var getOptionLabel = function getOptionLabel(option) {
1377
- return props.optionLabel ? utils.ObjectUtils.resolveFieldData(option, props.optionLabel) : utils.ObjectUtils.resolveFieldData(option, 'label');
1377
+ return props.optionLabel ? utils.ObjectUtils.resolveFieldData(option, props.optionLabel) : utils.ObjectUtils.resolveFieldData(option, 'label') || option;
1378
1378
  };
1379
1379
  var getOptionValue = function getOptionValue(option) {
1380
1380
  return props.optionValue ? utils.ObjectUtils.resolveFieldData(option, props.optionValue) : utils.ObjectUtils.resolveFieldData(option, 'value') || option;