funda-ui 4.7.222 → 4.7.252

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.
@@ -5425,6 +5425,11 @@ var src_Date = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_reac
5425
5425
  e.target.select();
5426
5426
  resetDefauleValueExist();
5427
5427
 
5428
+ // Automatically pop up a pop-up window
5429
+ if (enableEntireAreaPopup) {
5430
+ handleShow();
5431
+ }
5432
+
5428
5433
  // If there is no valid default value in the input field,
5429
5434
  // onChange should be triggered only after the resetDefauleValueExist() function is processed
5430
5435
  if (!dateDefaultValueExist) {
@@ -5838,6 +5843,15 @@ var src_Date = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_reac
5838
5843
  setDateVal(_date);
5839
5844
  setChangedVal(_full);
5840
5845
  setTimeVal([splitVals[3], splitVals[4], splitVals[5]]);
5846
+
5847
+ // Auto focus to next input if year is 4 digits
5848
+ if (_val.length === 4) {
5849
+ var nextInput = splitInputs.current.get(splitInputsIds[1]);
5850
+ if (nextInput) {
5851
+ nextInput.focus();
5852
+ nextInput.select();
5853
+ }
5854
+ }
5841
5855
  }
5842
5856
  }, attributes)), dateDefaultValueExist ? DELIMITER_DATE : null, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("input", _extends({
5843
5857
  ref: function ref(node) {
@@ -5877,6 +5891,15 @@ var src_Date = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_reac
5877
5891
  setDateVal(_date);
5878
5892
  setChangedVal(_full);
5879
5893
  setTimeVal([splitVals[3], splitVals[4], splitVals[5]]);
5894
+
5895
+ // Auto focus to next input if month is 2 digits
5896
+ if (_val.length === 2) {
5897
+ var nextInput = splitInputs.current.get(splitInputsIds[2]);
5898
+ if (nextInput) {
5899
+ nextInput.focus();
5900
+ nextInput.select();
5901
+ }
5902
+ }
5880
5903
  }
5881
5904
  }, attributes)), dateDefaultValueExist ? DELIMITER_DATE : null, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("input", _extends({
5882
5905
  ref: function ref(node) {
@@ -5921,6 +5944,15 @@ var src_Date = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_reac
5921
5944
  setDateVal(_date);
5922
5945
  setChangedVal(_full);
5923
5946
  setTimeVal([splitVals[3], splitVals[4], splitVals[5]]);
5947
+
5948
+ // Auto focus to next input if day is 2 digits
5949
+ if (_val.length === 2) {
5950
+ var nextInput = splitInputs.current.get(splitInputsIds[3]);
5951
+ if (nextInput) {
5952
+ nextInput.focus();
5953
+ nextInput.select();
5954
+ }
5955
+ }
5924
5956
  }
5925
5957
  }, attributes)), "\xA0") : null, COM_HAS_TIME ? /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement((external_root_React_commonjs2_react_commonjs_react_amd_react_default()).Fragment, null, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("input", _extends({
5926
5958
  ref: function ref(node) {
@@ -5957,6 +5989,15 @@ var src_Date = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_reac
5957
5989
  setDateVal(_date);
5958
5990
  setChangedVal(_full);
5959
5991
  setTimeVal([_val, splitVals[4], splitVals[5]]);
5992
+
5993
+ // Auto focus to next input if hour is 2 digits
5994
+ if (_val.length === 2) {
5995
+ var nextInput = splitInputs.current.get(splitInputsIds[4]);
5996
+ if (nextInput) {
5997
+ nextInput.focus();
5998
+ nextInput.select();
5999
+ }
6000
+ }
5960
6001
  }
5961
6002
  }, attributes)), dateDefaultValueExist ? DELIMITER_TIME : null, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("input", _extends({
5962
6003
  ref: function ref(node) {
@@ -5993,6 +6034,15 @@ var src_Date = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_reac
5993
6034
  setDateVal(_date);
5994
6035
  setChangedVal(_full);
5995
6036
  setTimeVal([splitVals[3], _val, splitVals[5]]);
6037
+
6038
+ // Auto focus to next input if minute is 2 digits
6039
+ if (_val.length === 2) {
6040
+ var nextInput = splitInputs.current.get(splitInputsIds[5]);
6041
+ if (nextInput) {
6042
+ nextInput.focus();
6043
+ nextInput.select();
6044
+ }
6045
+ }
5996
6046
  }
5997
6047
  }, attributes)), COM_NO_SECONDS ? /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement((external_root_React_commonjs2_react_commonjs_react_amd_react_default()).Fragment, null, dateDefaultValueExist ? DELIMITER_TIME : null, /*#__PURE__*/external_root_React_commonjs2_react_commonjs_react_amd_react_default().createElement("input", _extends({
5998
6048
  ref: function ref(node) {
@@ -6029,6 +6079,7 @@ var src_Date = /*#__PURE__*/(0,external_root_React_commonjs2_react_commonjs_reac
6029
6079
  setDateVal(_date);
6030
6080
  setChangedVal(_full);
6031
6081
  setTimeVal([splitVals[3], splitVals[4], _val]);
6082
+ // No auto focus for the last input (seconds)
6032
6083
  }
6033
6084
  }, attributes))) : null) : null), propExist(iconRight) ? tools() : null),
6034
6085
  style: style
@@ -1496,7 +1496,8 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1496
1496
  onClose = props.onClose,
1497
1497
  onSubmit = props.onSubmit,
1498
1498
  id = props.id,
1499
- children = props.children;
1499
+ children = props.children,
1500
+ onPressEnter = props.onPressEnter;
1500
1501
  var DEPTH = depth || 1055; // the default value same as bootstrap
1501
1502
  var M_WIDTH = fullscreen ? undefined : typeof maxWidth === 'function' ? maxWidth() : maxWidth ? maxWidth : undefined;
1502
1503
  var M_HEIGHT = typeof minHeight === 'function' ? minHeight() : minHeight ? minHeight : undefined;
@@ -1574,12 +1575,10 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1574
1575
  openAction();
1575
1576
 
1576
1577
  //
1577
- var callback = function callback(e) {
1578
- return function () {
1579
- handleCloseWin(e);
1580
- };
1578
+ var callback = function callback() {
1579
+ handleCloseWin(e);
1581
1580
  };
1582
- onOpen === null || onOpen === void 0 ? void 0 : onOpen(e, callback(e));
1581
+ onOpen === null || onOpen === void 0 ? void 0 : onOpen(e, callback);
1583
1582
  }
1584
1583
  function closeAction() {
1585
1584
  // pause video without controls
@@ -1739,6 +1738,22 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1739
1738
  };
1740
1739
  }, [show, data, modalRef.current]); // When show`` defaults to true, `modalRef.current` will be null
1741
1740
 
1741
+ // 监听回车键
1742
+ (0, react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {
1743
+ if (!modalShow || !onPressEnter) return;
1744
+ var handleKeyDown = function handleKeyDown(e) {
1745
+ if (e.key === 'Enter' || e.key === 'NumpadEnter') {
1746
+ var _callback = function _callback() {
1747
+ handleCloseWin(null);
1748
+ };
1749
+ onPressEnter === null || onPressEnter === void 0 ? void 0 : onPressEnter(_callback);
1750
+ }
1751
+ };
1752
+ window.addEventListener('keydown', handleKeyDown);
1753
+ return function () {
1754
+ window.removeEventListener('keydown', handleKeyDown);
1755
+ };
1756
+ }, [modalShow, onPressEnter]);
1742
1757
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react__WEBPACK_IMPORTED_MODULE_0___default().Fragment, null, triggerContent ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react__WEBPACK_IMPORTED_MODULE_0___default().Fragment, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
1743
1758
  className: triggerClassName ? triggerClassName : 'd-inline w-auto',
1744
1759
  ref: triggerRef,
@@ -1780,7 +1795,9 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1780
1795
  type: "button",
1781
1796
  className: enableVideo ? 'btn-close btn-close-white' : 'btn-close',
1782
1797
  "data-close": "1",
1783
- onClick: handleCloseWin
1798
+ onClick: function onClick(e) {
1799
+ return handleCloseWin(e);
1800
+ }
1784
1801
  }) : null)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
1785
1802
  className: "".concat(enableVideo ? 'modal-body m-0 p-0' : 'modal-body', " ").concat(modalBodyClassName || '')
1786
1803
  }, enableVideo ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react__WEBPACK_IMPORTED_MODULE_0___default().Fragment, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
@@ -1793,19 +1810,19 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1793
1810
  className: "modal-footer ".concat(modalFooterClassName || '')
1794
1811
  }, !closeDisabled ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react__WEBPACK_IMPORTED_MODULE_0___default().Fragment, null, closeBtnLabel ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
1795
1812
  "data-close": "1",
1796
- onClick: handleCloseWin,
1813
+ onClick: function onClick(e) {
1814
+ return handleCloseWin(e);
1815
+ },
1797
1816
  type: "button",
1798
1817
  className: closeBtnClassName ? closeBtnClassName : 'btn btn-secondary'
1799
1818
  }, closeBtnLabel) : null) : null, submitBtnLabel ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
1800
1819
  "data-confirm": "1",
1801
1820
  "data-incoming-data": "".concat(incomingData),
1802
1821
  onClick: function onClick(e) {
1803
- var callback = function callback(e) {
1804
- return function () {
1805
- handleCloseWin(e);
1806
- };
1822
+ var callback = function callback() {
1823
+ handleCloseWin(e);
1807
1824
  };
1808
- onSubmit === null || onSubmit === void 0 ? void 0 : onSubmit(e, callback(e), incomingData);
1825
+ onSubmit === null || onSubmit === void 0 ? void 0 : onSubmit(e, callback, incomingData);
1809
1826
  },
1810
1827
  type: "button",
1811
1828
  className: submitBtnClassName ? submitBtnClassName : 'btn btn-primary'
@@ -1496,7 +1496,8 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1496
1496
  onClose = props.onClose,
1497
1497
  onSubmit = props.onSubmit,
1498
1498
  id = props.id,
1499
- children = props.children;
1499
+ children = props.children,
1500
+ onPressEnter = props.onPressEnter;
1500
1501
  var DEPTH = depth || 1055; // the default value same as bootstrap
1501
1502
  var M_WIDTH = fullscreen ? undefined : typeof maxWidth === 'function' ? maxWidth() : maxWidth ? maxWidth : undefined;
1502
1503
  var M_HEIGHT = typeof minHeight === 'function' ? minHeight() : minHeight ? minHeight : undefined;
@@ -1574,12 +1575,10 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1574
1575
  openAction();
1575
1576
 
1576
1577
  //
1577
- var callback = function callback(e) {
1578
- return function () {
1579
- handleCloseWin(e);
1580
- };
1578
+ var callback = function callback() {
1579
+ handleCloseWin(e);
1581
1580
  };
1582
- onOpen === null || onOpen === void 0 ? void 0 : onOpen(e, callback(e));
1581
+ onOpen === null || onOpen === void 0 ? void 0 : onOpen(e, callback);
1583
1582
  }
1584
1583
  function closeAction() {
1585
1584
  // pause video without controls
@@ -1739,6 +1738,22 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1739
1738
  };
1740
1739
  }, [show, data, modalRef.current]); // When show`` defaults to true, `modalRef.current` will be null
1741
1740
 
1741
+ // 监听回车键
1742
+ (0, react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {
1743
+ if (!modalShow || !onPressEnter) return;
1744
+ var handleKeyDown = function handleKeyDown(e) {
1745
+ if (e.key === 'Enter' || e.key === 'NumpadEnter') {
1746
+ var _callback = function _callback() {
1747
+ handleCloseWin(null);
1748
+ };
1749
+ onPressEnter === null || onPressEnter === void 0 ? void 0 : onPressEnter(_callback);
1750
+ }
1751
+ };
1752
+ window.addEventListener('keydown', handleKeyDown);
1753
+ return function () {
1754
+ window.removeEventListener('keydown', handleKeyDown);
1755
+ };
1756
+ }, [modalShow, onPressEnter]);
1742
1757
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react__WEBPACK_IMPORTED_MODULE_0___default().Fragment, null, triggerContent ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react__WEBPACK_IMPORTED_MODULE_0___default().Fragment, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
1743
1758
  className: triggerClassName ? triggerClassName : 'd-inline w-auto',
1744
1759
  ref: triggerRef,
@@ -1780,7 +1795,9 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1780
1795
  type: "button",
1781
1796
  className: enableVideo ? 'btn-close btn-close-white' : 'btn-close',
1782
1797
  "data-close": "1",
1783
- onClick: handleCloseWin
1798
+ onClick: function onClick(e) {
1799
+ return handleCloseWin(e);
1800
+ }
1784
1801
  }) : null)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
1785
1802
  className: "".concat(enableVideo ? 'modal-body m-0 p-0' : 'modal-body', " ").concat(modalBodyClassName || '')
1786
1803
  }, enableVideo ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react__WEBPACK_IMPORTED_MODULE_0___default().Fragment, null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
@@ -1793,19 +1810,19 @@ var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_
1793
1810
  className: "modal-footer ".concat(modalFooterClassName || '')
1794
1811
  }, !closeDisabled ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement(react__WEBPACK_IMPORTED_MODULE_0___default().Fragment, null, closeBtnLabel ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
1795
1812
  "data-close": "1",
1796
- onClick: handleCloseWin,
1813
+ onClick: function onClick(e) {
1814
+ return handleCloseWin(e);
1815
+ },
1797
1816
  type: "button",
1798
1817
  className: closeBtnClassName ? closeBtnClassName : 'btn btn-secondary'
1799
1818
  }, closeBtnLabel) : null) : null, submitBtnLabel ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
1800
1819
  "data-confirm": "1",
1801
1820
  "data-incoming-data": "".concat(incomingData),
1802
1821
  onClick: function onClick(e) {
1803
- var callback = function callback(e) {
1804
- return function () {
1805
- handleCloseWin(e);
1806
- };
1822
+ var callback = function callback() {
1823
+ handleCloseWin(e);
1807
1824
  };
1808
- onSubmit === null || onSubmit === void 0 ? void 0 : onSubmit(e, callback(e), incomingData);
1825
+ onSubmit === null || onSubmit === void 0 ? void 0 : onSubmit(e, callback, incomingData);
1809
1826
  },
1810
1827
  type: "button",
1811
1828
  className: submitBtnClassName ? submitBtnClassName : 'btn btn-primary'
@@ -70,10 +70,14 @@ export declare type ModalDialogProps = {
70
70
  /** This function is called whenever the data is updated.
71
71
  * Exposes the JSON format data about the option as an argument.
72
72
  */
73
- onLoad?: (openFunc: any, closeFunc: any) => void;
74
- onOpen?: (e: any, callback: any) => void;
75
- onClose?: (e: any) => void;
76
- onSubmit?: (e: any, callback: any, incomingData: string | null | undefined) => void;
73
+ onLoad?: (openFunc: () => void, closeFunc: () => void) => void;
74
+ onOpen?: (e: React.MouseEvent<HTMLElement> | null, callback: () => void) => void;
75
+ onClose?: (e: React.MouseEvent<HTMLElement> | null) => void;
76
+ onSubmit?: (e: React.MouseEvent<HTMLButtonElement>, callback: () => void, incomingData: string | null | undefined) => void;
77
+ /**
78
+ * Called when Enter key is pressed while modal is open
79
+ */
80
+ onPressEnter?: (callback: () => void) => void;
77
81
  };
78
82
  declare const ModalDialog: React.ForwardRefExoticComponent<ModalDialogProps & React.RefAttributes<ModalDialogRef>>;
79
83
  export default ModalDialog;
@@ -1360,7 +1360,8 @@ var ModalDialog = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)
1360
1360
  onClose = props.onClose,
1361
1361
  onSubmit = props.onSubmit,
1362
1362
  id = props.id,
1363
- children = props.children;
1363
+ children = props.children,
1364
+ onPressEnter = props.onPressEnter;
1364
1365
  var DEPTH = depth || 1055; // the default value same as bootstrap
1365
1366
  var M_WIDTH = fullscreen ? undefined : typeof maxWidth === 'function' ? maxWidth() : maxWidth ? maxWidth : undefined;
1366
1367
  var M_HEIGHT = typeof minHeight === 'function' ? minHeight() : minHeight ? minHeight : undefined;
@@ -1438,12 +1439,10 @@ var ModalDialog = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)
1438
1439
  openAction();
1439
1440
 
1440
1441
  //
1441
- var callback = function callback(e) {
1442
- return function () {
1443
- handleCloseWin(e);
1444
- };
1442
+ var callback = function callback() {
1443
+ handleCloseWin(e);
1445
1444
  };
1446
- onOpen === null || onOpen === void 0 ? void 0 : onOpen(e, callback(e));
1445
+ onOpen === null || onOpen === void 0 ? void 0 : onOpen(e, callback);
1447
1446
  }
1448
1447
  function closeAction() {
1449
1448
  // pause video without controls
@@ -1603,6 +1602,22 @@ var ModalDialog = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)
1603
1602
  };
1604
1603
  }, [show, data, modalRef.current]); // When show`` defaults to true, `modalRef.current` will be null
1605
1604
 
1605
+ // 监听回车键
1606
+ (0,react__WEBPACK_IMPORTED_MODULE_0__.useEffect)(function () {
1607
+ if (!modalShow || !onPressEnter) return;
1608
+ var handleKeyDown = function handleKeyDown(e) {
1609
+ if (e.key === 'Enter' || e.key === 'NumpadEnter') {
1610
+ var _callback = function _callback() {
1611
+ handleCloseWin(null);
1612
+ };
1613
+ onPressEnter === null || onPressEnter === void 0 ? void 0 : onPressEnter(_callback);
1614
+ }
1615
+ };
1616
+ window.addEventListener('keydown', handleKeyDown);
1617
+ return function () {
1618
+ window.removeEventListener('keydown', handleKeyDown);
1619
+ };
1620
+ }, [modalShow, onPressEnter]);
1606
1621
  return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, triggerContent ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
1607
1622
  className: triggerClassName ? triggerClassName : 'd-inline w-auto',
1608
1623
  ref: triggerRef,
@@ -1644,7 +1659,9 @@ var ModalDialog = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)
1644
1659
  type: "button",
1645
1660
  className: enableVideo ? 'btn-close btn-close-white' : 'btn-close',
1646
1661
  "data-close": "1",
1647
- onClick: handleCloseWin
1662
+ onClick: function onClick(e) {
1663
+ return handleCloseWin(e);
1664
+ }
1648
1665
  }) : null)), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
1649
1666
  className: "".concat(enableVideo ? 'modal-body m-0 p-0' : 'modal-body', " ").concat(modalBodyClassName || '')
1650
1667
  }, enableVideo ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("div", {
@@ -1657,19 +1674,19 @@ var ModalDialog = /*#__PURE__*/(0,react__WEBPACK_IMPORTED_MODULE_0__.forwardRef)
1657
1674
  className: "modal-footer ".concat(modalFooterClassName || '')
1658
1675
  }, !closeDisabled ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement((react__WEBPACK_IMPORTED_MODULE_0___default().Fragment), null, closeBtnLabel ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
1659
1676
  "data-close": "1",
1660
- onClick: handleCloseWin,
1677
+ onClick: function onClick(e) {
1678
+ return handleCloseWin(e);
1679
+ },
1661
1680
  type: "button",
1662
1681
  className: closeBtnClassName ? closeBtnClassName : 'btn btn-secondary'
1663
1682
  }, closeBtnLabel) : null) : null, submitBtnLabel ? /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0___default().createElement("button", {
1664
1683
  "data-confirm": "1",
1665
1684
  "data-incoming-data": "".concat(incomingData),
1666
1685
  onClick: function onClick(e) {
1667
- var callback = function callback(e) {
1668
- return function () {
1669
- handleCloseWin(e);
1670
- };
1686
+ var callback = function callback() {
1687
+ handleCloseWin(e);
1671
1688
  };
1672
- onSubmit === null || onSubmit === void 0 ? void 0 : onSubmit(e, callback(e), incomingData);
1689
+ onSubmit === null || onSubmit === void 0 ? void 0 : onSubmit(e, callback, incomingData);
1673
1690
  },
1674
1691
  type: "button",
1675
1692
  className: submitBtnClassName ? submitBtnClassName : 'btn btn-primary'