@m4l/components 3.1.7 → 3.1.8
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.
- package/index.js +183 -340
- package/node_modules-CQtkw0uG.js +7350 -0
- package/package.json +1 -1
- package/vendor-AfIOyqRr.js +24636 -0
- package/components/AccountPopover/index-Dm2-k-Mv.js +0 -334
- package/components/AppBar/index-i0rhG3J1.js +0 -93
- package/components/BaseModule/index-CiNNlxzS.js +0 -30
- package/components/CommonActions/components/ActionCancel/index-CIdpDXkr.js +0 -12
- package/components/CommonActions/components/ActionFormCancel/index-CpyASN3q.js +0 -56
- package/components/CommonActions/components/ActionFormIntro/index-7KKtcUra.js +0 -33
- package/components/CommonActions/components/ActionIntro/index-CqqDZZcG.js +0 -25
- package/components/CommonActions/components/Actions/index-CuG1pnXW.js +0 -70
- package/components/DataGrid/constants-8L7QgBKi.js +0 -10
- package/components/DataGrid/formatters/ColumnBooleanFormatter/index-CveSCbq_.js +0 -26
- package/components/DataGrid/formatters/ColumnConcatenatedValueFormatter/index-CHqvieM2.js +0 -22
- package/components/DataGrid/formatters/ColumnDateFormatter/index-CKg8CJ6A.js +0 -19
- package/components/DataGrid/formatters/ColumnInteractiveCheckFormatter/index-DE6bwaKP.js +0 -23
- package/components/DataGrid/formatters/ColumnNestedValueFormatter/index-BslXGK-A.js +0 -14
- package/components/DataGrid/formatters/ColumnPointsFormatter/index-BXGW2CsK.js +0 -10
- package/components/DataGrid/formatters/ColumnPriceFormatter/index-O11tBykn.js +0 -10
- package/components/DataGrid/formatters/ColumnSetCheckFormatter/index-BaCawLr1.js +0 -36
- package/components/DataGrid/formatters/ColumnUncertaintyFormatter/index-Cq7a-jnE.js +0 -10
- package/components/DataGrid/formatters/index-CrZXPa0e.js +0 -13
- package/components/DataGrid/index-BZ-lbmuU.js +0 -908
- package/components/DataGrid/subcomponents/Actions/index-CHvPZ4Ru.js +0 -549
- package/components/DataGrid/subcomponents/editors/TextEditor/index-BIFm8akr.js +0 -80
- package/components/DragResizeWindow/index-D2jLYExo.js +0 -505
- package/components/DynamicFilter/constants-ByqmFATV.js +0 -31
- package/components/DynamicFilter/dictionary-PrbXU3VZ.js +0 -51
- package/components/DynamicFilter/index-DZiJc9h7.js +0 -116
- package/components/DynamicFilter/slots/SlotsEnum-cawFeNzx.js +0 -34
- package/components/DynamicFilter/slots/dynamicFilterSlots-DHxelhXP.js +0 -151
- package/components/DynamicFilter/slots/index-l0sNRNKZ.js +0 -1
- package/components/DynamicFilter/store/index-BT-eWVnJ.js +0 -254
- package/components/DynamicFilter/subcomponents/AppliedFilterChip/index-B32bAzi-.js +0 -60
- package/components/DynamicFilter/subcomponents/AppliedFilters/index-Bha19drV.js +0 -26
- package/components/DynamicFilter/subcomponents/DynamicFilterBase/index-BmvzoHit.js +0 -40
- package/components/DynamicFilter/subcomponents/FieldTypes/BooleanFilter/index-BcO3SlP5.js +0 -129
- package/components/DynamicFilter/subcomponents/FieldTypes/DateTimeFilter/index-BCJhpNS8.js +0 -171
- package/components/DynamicFilter/subcomponents/FieldTypes/NumberFilter/index-DCNhz68u.js +0 -153
- package/components/DynamicFilter/subcomponents/FieldTypes/SelectFilter/index-BdypjM1Y.js +0 -146
- package/components/DynamicFilter/subcomponents/FieldTypes/StringFilter/index-D-NFIVnK.js +0 -114
- package/components/DynamicFilter/subcomponents/FieldTypes/index-BwQHJqk9.js +0 -38
- package/components/DynamicFilter/subcomponents/FilterActions/index-B9UWmk07.js +0 -88
- package/components/DynamicFilter/subcomponents/InputFilter/index-CfGb1TfV.js +0 -188
- package/components/DynamicFilter/subcomponents/PopoverFilter/index-DkfRGrlO.js +0 -158
- package/components/DynamicFilter/subcomponents/PopoverMenuFields/index-DSegwAm2.js +0 -63
- package/components/FieldLabel/index-CI57EizR.js +0 -54
- package/components/GridLayout/index-C4HyxNYX.js +0 -1044
- package/components/GridLayout/subcomponents/Griditem/index-C7jT4s8t.js +0 -395
- package/components/GridLayout/subcomponents/Responsive/index-BKcU2OnF.js +0 -348
- package/components/GridLayout/subcomponents/SizeProvider/index-1aJ-e_54.js +0 -71
- package/components/HelperText/index-Crn_XIPF.js +0 -50
- package/components/Icon/index-C89MAkeH.js +0 -176
- package/components/Image/index-COp8vP0X.js +0 -175
- package/components/LanguagePopover/index-BA2Igs9L.js +0 -179
- package/components/LinearProgressIndeterminate/index-BwI756Mb.js +0 -55
- package/components/Loadable/index-BMbi9ISF.js +0 -9
- package/components/LoadingError/index-Cf0oGUrL.js +0 -89
- package/components/MFIsolationApp/index-V4R55hNU.js +0 -169
- package/components/MFLoader/index-BI8vQZSH.js +0 -299
- package/components/ModalDialog/index-CEVQBQ7W.js +0 -77
- package/components/NavLink/index-D1S_vtFO.js +0 -55
- package/components/NoItemSelected/index-B9oM26AX.js +0 -54
- package/components/ObjectLogs/index-CiXOJpS4.js +0 -233
- package/components/PDFViewer/index-GVN2rfd6.js +0 -51
- package/components/Page/index-DZMkYmr4.js +0 -117
- package/components/PaperForm/index-DwgAfjci.js +0 -59
- package/components/Period/index-2pJG3VmY.js +0 -238
- package/components/PrintingSystem/index-B2qcnfw0.js +0 -187
- package/components/PrintingSystem/subcomponents/BodyNode/index-Cv2aoy8S.js +0 -49
- package/components/PrintingSystem/subcomponents/ChartNode/index-BmJm8v_C.js +0 -105
- package/components/PrintingSystem/subcomponents/DividerNode/index-MpFhE-H0.js +0 -20
- package/components/PrintingSystem/subcomponents/FooterNode/index-ZEcWdMSM.js +0 -49
- package/components/PrintingSystem/subcomponents/GridNode/index-SsKax2xu.js +0 -74
- package/components/PrintingSystem/subcomponents/HeaderNode/index-Cs8TOOBL.js +0 -49
- package/components/PrintingSystem/subcomponents/PaperNode/index-DBb25Ecg.js +0 -30
- package/components/PrintingSystem/subcomponents/PropertyValueNode/index-CTVn7J9Q.js +0 -47
- package/components/PrintingSystem/subcomponents/SectionNode/index-iYPM3EaS.js +0 -49
- package/components/PrintingSystem/subcomponents/TextBoxNode/index-DGjXCFKJ.js +0 -24
- package/components/PropertyValue/index-Bh-Jnrte.js +0 -264
- package/components/Resizeable/index-DdP1xfE9.js +0 -20
- package/components/ScrollBar/index-f2URPPE2.js +0 -35
- package/components/ScrollToTop/index-TxORk5dB.js +0 -12
- package/components/SideBar/index-PUBBe0yH.js +0 -758
- package/components/SplitLayout/index-Bu1hcO6G.js +0 -89
- package/components/ToastContainer/index-DK1d8NNd.js +0 -191
- package/components/WrapperComponent/index-BHV-CsDU.js +0 -14
- package/components/animate/LoadingScreen/index-CkVLOrMz.js +0 -70
- package/components/animate/MotionContainer/index-eartnWyO.js +0 -34
- package/components/animate/MotionLazyContainer/index-Be8osTiG.js +0 -9
- package/components/animate/PropagateLoader/index-Bkq8V2SN.js +0 -23
- package/components/animate/features-BbnE33u3.js +0 -5
- package/components/animate/index-BsWiJfzp.js +0 -89
- package/components/animate/variants/bounce-DanQqHAX.js +0 -101
- package/components/animate/variants/container-Dmpr6tg5.js +0 -22
- package/components/animate/variants/fade-CAOJNn06.js +0 -65
- package/components/animate/variants/index-l0sNRNKZ.js +0 -1
- package/components/animate/variants/transition-B9W5SWTa.js +0 -20
- package/components/areas/components/AreasAdmin/index-OxQU3P8Y.js +0 -699
- package/components/areas/components/AreasViewer/index-DQ0aPioP.js +0 -805
- package/components/areas/components/index-l0sNRNKZ.js +0 -1
- package/components/areas/constants-rqODZNZe.js +0 -6
- package/components/areas/contexts/AreasContext/index-BqRlA7JA.js +0 -1110
- package/components/areas/contexts/DynamicMFParmsContext/index-22c6E7vK.js +0 -36
- package/components/areas/contexts/WindowToolsMFContext/index-DkE30fhm.js +0 -12
- package/components/areas/contexts/index-l0sNRNKZ.js +0 -1
- package/components/areas/dictionary-YUsP9beq.js +0 -36
- package/components/areas/hooks/index-l0sNRNKZ.js +0 -1
- package/components/areas/hooks/useAreas/index-BSbwbJLS.js +0 -11
- package/components/areas/hooks/useDynamicMFParameters/index-DhbcZPs9.js +0 -12
- package/components/areas/hooks/useSetWindowsTitle/useSetWindowsTitle-BzPD-miW.js +0 -31
- package/components/areas/hooks/useWindowToolsMF/index-BECQfhbC.js +0 -10
- package/components/areas/icons-CwFr-alN.js +0 -24
- package/components/areas/index-B_Odny9h.js +0 -22
- package/components/commercial/AppBarCommercial/index-CHq3P3GY.js +0 -28
- package/components/commercial/SectionCommercial/index-BeABGtdr.js +0 -56
- package/components/commercial/TopBar/index-F1repmti.js +0 -232
- package/components/commercial/index-CxDzs6Ax.js +0 -81
- package/components/formatters/BooleanFormatter/index-DktIidqW.js +0 -44
- package/components/formatters/DateFormatter/index-CGcRZ8BA.js +0 -43
- package/components/formatters/PointsFormatter/index-C7sR8iqk.js +0 -25
- package/components/formatters/PriceFormatter/index-CsvRawmc.js +0 -35
- package/components/formatters/UncertaintyFormatter/index-B9ESVEVp.js +0 -29
- package/components/formatters/index-pnJhDYKe.js +0 -109
- package/components/hook-form/HelperError/index-BVnmUazV.js +0 -19
- package/components/hook-form/RHFAutocomplete/index-BtPL16HR.js +0 -657
- package/components/hook-form/RHFAutocompleteAsync/index-BfzjLHG8.js +0 -226
- package/components/hook-form/RHFCheckbox/index-Vyttu8Vx.js +0 -132
- package/components/hook-form/RHFColorPicker/index-Cxxb5Wa_.js +0 -191
- package/components/hook-form/RHFDateTime/index-CW1Slb-f.js +0 -190
- package/components/hook-form/RHFMultiCheckbox/index-BARudV1A.js +0 -34
- package/components/hook-form/RHFPeriod/index-r-HeIOoZ.js +0 -98
- package/components/hook-form/RHFRadioGroup/index-CTD-0zKo.js +0 -52
- package/components/hook-form/RHFSelect/index-LdwRuFz-.js +0 -29
- package/components/hook-form/RHFTextField/index-B6ufruSB.js +0 -337
- package/components/hook-form/RHFUpload/index-CDPbm8NR.js +0 -253
- package/components/maps/components/GpsTools/index-5MXlhIEt.js +0 -1948
- package/components/maps/components/Map/index-2Lx5ARXa.js +0 -2546
- package/components/maps/index-Ci-7-FHg.js +0 -7
- package/components/modal/WindowBase-Gd27v5FU.js +0 -44
- package/components/modal/WindowConfirm-u6vAMFo7.js +0 -73
- package/components/modal/index-CydPIpKZ.js +0 -65
- package/components/mui_extended/Accordion/index-DMLYJL7o.js +0 -124
- package/components/mui_extended/Avatar/index-ClBa-6eF.js +0 -64
- package/components/mui_extended/Badge/index-zI-F_Qkq.js +0 -29
- package/components/mui_extended/BoxIcon/index-BUTJ2tKw.js +0 -22
- package/components/mui_extended/Breadcrumbs/index-DTS7rOZH.js +0 -86
- package/components/mui_extended/Button/index-CGfZbaea.js +0 -222
- package/components/mui_extended/CheckBox-BXUrbonB.js +0 -76
- package/components/mui_extended/CircularProgress/index-Bnnti_G6.js +0 -8
- package/components/mui_extended/IconButton/classes/constants-ChY2jKkp.js +0 -4
- package/components/mui_extended/IconButton/classes/index-BxjJGAqZ.js +0 -45
- package/components/mui_extended/IconButton/index-CusYFjie.js +0 -97
- package/components/mui_extended/IconButton/styledIconButton-fAsbGoFS.js +0 -7
- package/components/mui_extended/LinearProgress/index-CGgW8jq2.js +0 -9
- package/components/mui_extended/LinkWithRoute/index-BC2miUjR.js +0 -15
- package/components/mui_extended/MenuActions/MenuActions-C6CjSU6C.js +0 -149
- package/components/mui_extended/MenuActions/constants-BwsU9chA.js +0 -10
- package/components/mui_extended/MenuActions/dictionary-Dj_07puT.js +0 -11
- package/components/mui_extended/MenuActions/slots/MenuActionsEnum-Bu-L6eWU.js +0 -13
- package/components/mui_extended/MenuActions/slots/MenuActionsSlots-D65KZAKF.js +0 -46
- package/components/mui_extended/Pager/index-DCbxiTZA.js +0 -257
- package/components/mui_extended/Popover/index-DfrJAQkV.js +0 -153
- package/components/mui_extended/Stack/index-DzEeCYfp.js +0 -31
- package/components/mui_extended/Tab/index-Bu3dPidV.js +0 -129
- package/components/mui_extended/ToggleButton/index-C9cBkT1V.js +0 -18
- package/components/mui_extended/ToggleIconButton/index--0b3Td6C.js +0 -26
- package/components/mui_extended/Tooltip/index-B8QUytCK.js +0 -42
- package/components/mui_extended/Typography/index-Cf_4Zw8f.js +0 -54
- package/components/mui_extended/index-l0sNRNKZ.js +0 -1
- package/components/popups/PopupsProvider/index-DhSxmtfJ.js +0 -172
- package/components/popups/PopupsViewer/constants-DuyD7aCn.js +0 -4
- package/components/popups/PopupsViewer/icons-BUujqqbu.js +0 -7
- package/components/popups/PopupsViewer/index-BecevSns.js +0 -172
- package/components/popups/PopupsViewer/slots/index-B98CiRLa.js +0 -14
- package/components/popups/PopupsViewer/slots/popupsViewerSlots-BXH77nCF.js +0 -46
- package/components/popups/index-l0sNRNKZ.js +0 -1
- package/contexts/ModalContext/index-CPfNnfTL.js +0 -39
- package/contexts/RHFormContext/index-D_nK759o.js +0 -78
- package/hocs/withToggle/index-C1_DMZD3.js +0 -14
- package/hooks/useFormAddEdit/index-D9oSjUn1.js +0 -90
- package/hooks/useFormReadyForUpdate/index-B3HygFCM.js +0 -20
- package/hooks/useModal/index-BJSQOX3U.js +0 -10
- package/hooks/useSizeContainer/index-D4hDjM1P.js +0 -37
- package/hooks/useStateRef/index-C3P6ZK3m.js +0 -15
- package/hooks/useTab/index-B_GEQFOP.js +0 -12
- package/react-data-grid-BfYuZ6AK.js +0 -2606
- package/react-draggable-DsCPdgQP.js +0 -811
- package/react-json-view-bhqIAaNg.js +0 -2576
- package/react-resizable-eBbFl2dX.js +0 -618
- package/react-spinners-TpKN9lZg.js +0 -123
- package/react-splitter-layout-C-JTsNGs.js +0 -158
- package/styles/DynamicFilter-CJFsIegc.js +0 -319
- package/styles/MenuActions-lTi-ynPM.js +0 -42
- package/styles/index-DKj6m8SL.js +0 -1691
- package/test/constants_no_mock-CF-669v-.js +0 -4
- package/test/getNameDataTestId-BaBTWhBr.js +0 -10
- package/utils/index-DiMrtgIu.js +0 -502
- /package/components/GridLayout/subcomponents/{Griditem → GridItem}/index.d.ts +0 -0
- /package/components/GridLayout/subcomponents/{Griditem → GridItem}/types.d.ts +0 -0
|
@@ -1,618 +0,0 @@
|
|
|
1
|
-
import React__default from "react";
|
|
2
|
-
import { c as cjsExports } from "./react-draggable-DsCPdgQP.js";
|
|
3
|
-
import { u as utils } from "./utils/index-DiMrtgIu.js";
|
|
4
|
-
import require$$1 from "prop-types";
|
|
5
|
-
var reactResizable = { exports: {} };
|
|
6
|
-
var Resizable$2 = {};
|
|
7
|
-
var propTypes = {};
|
|
8
|
-
propTypes.__esModule = true;
|
|
9
|
-
propTypes.resizableProps = void 0;
|
|
10
|
-
var _propTypes$2 = _interopRequireDefault$1(require$$1);
|
|
11
|
-
function _interopRequireDefault$1(obj) {
|
|
12
|
-
return obj && obj.__esModule ? obj : { default: obj };
|
|
13
|
-
}
|
|
14
|
-
var resizableProps = {
|
|
15
|
-
/*
|
|
16
|
-
* Restricts resizing to a particular axis (default: 'both')
|
|
17
|
-
* 'both' - allows resizing by width or height
|
|
18
|
-
* 'x' - only allows the width to be changed
|
|
19
|
-
* 'y' - only allows the height to be changed
|
|
20
|
-
* 'none' - disables resizing altogether
|
|
21
|
-
* */
|
|
22
|
-
axis: _propTypes$2.default.oneOf(["both", "x", "y", "none"]),
|
|
23
|
-
className: _propTypes$2.default.string,
|
|
24
|
-
/*
|
|
25
|
-
* Require that one and only one child be present.
|
|
26
|
-
* */
|
|
27
|
-
children: _propTypes$2.default.element.isRequired,
|
|
28
|
-
/*
|
|
29
|
-
* These will be passed wholesale to react-draggable's DraggableCore
|
|
30
|
-
* */
|
|
31
|
-
draggableOpts: _propTypes$2.default.shape({
|
|
32
|
-
allowAnyClick: _propTypes$2.default.bool,
|
|
33
|
-
cancel: _propTypes$2.default.string,
|
|
34
|
-
children: _propTypes$2.default.node,
|
|
35
|
-
disabled: _propTypes$2.default.bool,
|
|
36
|
-
enableUserSelectHack: _propTypes$2.default.bool,
|
|
37
|
-
offsetParent: _propTypes$2.default.node,
|
|
38
|
-
grid: _propTypes$2.default.arrayOf(_propTypes$2.default.number),
|
|
39
|
-
handle: _propTypes$2.default.string,
|
|
40
|
-
nodeRef: _propTypes$2.default.object,
|
|
41
|
-
onStart: _propTypes$2.default.func,
|
|
42
|
-
onDrag: _propTypes$2.default.func,
|
|
43
|
-
onStop: _propTypes$2.default.func,
|
|
44
|
-
onMouseDown: _propTypes$2.default.func,
|
|
45
|
-
scale: _propTypes$2.default.number
|
|
46
|
-
}),
|
|
47
|
-
/*
|
|
48
|
-
* Initial height
|
|
49
|
-
* */
|
|
50
|
-
height: function height() {
|
|
51
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
52
|
-
args[_key] = arguments[_key];
|
|
53
|
-
}
|
|
54
|
-
var props = args[0];
|
|
55
|
-
if (props.axis === "both" || props.axis === "y") {
|
|
56
|
-
var _PropTypes$number;
|
|
57
|
-
return (_PropTypes$number = _propTypes$2.default.number).isRequired.apply(_PropTypes$number, args);
|
|
58
|
-
}
|
|
59
|
-
return _propTypes$2.default.number.apply(_propTypes$2.default, args);
|
|
60
|
-
},
|
|
61
|
-
/*
|
|
62
|
-
* Customize cursor resize handle
|
|
63
|
-
* */
|
|
64
|
-
handle: _propTypes$2.default.oneOfType([_propTypes$2.default.node, _propTypes$2.default.func]),
|
|
65
|
-
/*
|
|
66
|
-
* If you change this, be sure to update your css
|
|
67
|
-
* */
|
|
68
|
-
handleSize: _propTypes$2.default.arrayOf(_propTypes$2.default.number),
|
|
69
|
-
lockAspectRatio: _propTypes$2.default.bool,
|
|
70
|
-
/*
|
|
71
|
-
* Max X & Y measure
|
|
72
|
-
* */
|
|
73
|
-
maxConstraints: _propTypes$2.default.arrayOf(_propTypes$2.default.number),
|
|
74
|
-
/*
|
|
75
|
-
* Min X & Y measure
|
|
76
|
-
* */
|
|
77
|
-
minConstraints: _propTypes$2.default.arrayOf(_propTypes$2.default.number),
|
|
78
|
-
/*
|
|
79
|
-
* Called on stop resize event
|
|
80
|
-
* */
|
|
81
|
-
onResizeStop: _propTypes$2.default.func,
|
|
82
|
-
/*
|
|
83
|
-
* Called on start resize event
|
|
84
|
-
* */
|
|
85
|
-
onResizeStart: _propTypes$2.default.func,
|
|
86
|
-
/*
|
|
87
|
-
* Called on resize event
|
|
88
|
-
* */
|
|
89
|
-
onResize: _propTypes$2.default.func,
|
|
90
|
-
/*
|
|
91
|
-
* Defines which resize handles should be rendered (default: 'se')
|
|
92
|
-
* 's' - South handle (bottom-center)
|
|
93
|
-
* 'w' - West handle (left-center)
|
|
94
|
-
* 'e' - East handle (right-center)
|
|
95
|
-
* 'n' - North handle (top-center)
|
|
96
|
-
* 'sw' - Southwest handle (bottom-left)
|
|
97
|
-
* 'nw' - Northwest handle (top-left)
|
|
98
|
-
* 'se' - Southeast handle (bottom-right)
|
|
99
|
-
* 'ne' - Northeast handle (top-center)
|
|
100
|
-
* */
|
|
101
|
-
resizeHandles: _propTypes$2.default.arrayOf(_propTypes$2.default.oneOf(["s", "w", "e", "n", "sw", "nw", "se", "ne"])),
|
|
102
|
-
/*
|
|
103
|
-
* If `transform: scale(n)` is set on the parent, this should be set to `n`.
|
|
104
|
-
* */
|
|
105
|
-
transformScale: _propTypes$2.default.number,
|
|
106
|
-
/*
|
|
107
|
-
* Initial width
|
|
108
|
-
*/
|
|
109
|
-
width: function width() {
|
|
110
|
-
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
111
|
-
args[_key2] = arguments[_key2];
|
|
112
|
-
}
|
|
113
|
-
var props = args[0];
|
|
114
|
-
if (props.axis === "both" || props.axis === "x") {
|
|
115
|
-
var _PropTypes$number2;
|
|
116
|
-
return (_PropTypes$number2 = _propTypes$2.default.number).isRequired.apply(_PropTypes$number2, args);
|
|
117
|
-
}
|
|
118
|
-
return _propTypes$2.default.number.apply(_propTypes$2.default, args);
|
|
119
|
-
}
|
|
120
|
-
};
|
|
121
|
-
propTypes.resizableProps = resizableProps;
|
|
122
|
-
Resizable$2.__esModule = true;
|
|
123
|
-
Resizable$2.default = void 0;
|
|
124
|
-
var React$1 = _interopRequireWildcard$1(React__default);
|
|
125
|
-
var _reactDraggable = cjsExports;
|
|
126
|
-
var _utils = utils;
|
|
127
|
-
var _propTypes$1 = propTypes;
|
|
128
|
-
var _excluded$1 = ["children", "className", "draggableOpts", "width", "height", "handle", "handleSize", "lockAspectRatio", "axis", "minConstraints", "maxConstraints", "onResize", "onResizeStop", "onResizeStart", "resizeHandles", "transformScale"];
|
|
129
|
-
function _getRequireWildcardCache$1(nodeInterop) {
|
|
130
|
-
if (typeof WeakMap !== "function") return null;
|
|
131
|
-
var cacheBabelInterop = /* @__PURE__ */ new WeakMap();
|
|
132
|
-
var cacheNodeInterop = /* @__PURE__ */ new WeakMap();
|
|
133
|
-
return (_getRequireWildcardCache$1 = function _getRequireWildcardCache2(nodeInterop2) {
|
|
134
|
-
return nodeInterop2 ? cacheNodeInterop : cacheBabelInterop;
|
|
135
|
-
})(nodeInterop);
|
|
136
|
-
}
|
|
137
|
-
function _interopRequireWildcard$1(obj, nodeInterop) {
|
|
138
|
-
if (obj && obj.__esModule) {
|
|
139
|
-
return obj;
|
|
140
|
-
}
|
|
141
|
-
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
142
|
-
return { default: obj };
|
|
143
|
-
}
|
|
144
|
-
var cache = _getRequireWildcardCache$1(nodeInterop);
|
|
145
|
-
if (cache && cache.has(obj)) {
|
|
146
|
-
return cache.get(obj);
|
|
147
|
-
}
|
|
148
|
-
var newObj = {};
|
|
149
|
-
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
150
|
-
for (var key in obj) {
|
|
151
|
-
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
152
|
-
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
153
|
-
if (desc && (desc.get || desc.set)) {
|
|
154
|
-
Object.defineProperty(newObj, key, desc);
|
|
155
|
-
} else {
|
|
156
|
-
newObj[key] = obj[key];
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
newObj.default = obj;
|
|
161
|
-
if (cache) {
|
|
162
|
-
cache.set(obj, newObj);
|
|
163
|
-
}
|
|
164
|
-
return newObj;
|
|
165
|
-
}
|
|
166
|
-
function _extends$1() {
|
|
167
|
-
_extends$1 = Object.assign ? Object.assign.bind() : function(target) {
|
|
168
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
169
|
-
var source = arguments[i];
|
|
170
|
-
for (var key in source) {
|
|
171
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
172
|
-
target[key] = source[key];
|
|
173
|
-
}
|
|
174
|
-
}
|
|
175
|
-
}
|
|
176
|
-
return target;
|
|
177
|
-
};
|
|
178
|
-
return _extends$1.apply(this, arguments);
|
|
179
|
-
}
|
|
180
|
-
function _objectWithoutPropertiesLoose$1(source, excluded) {
|
|
181
|
-
if (source == null) return {};
|
|
182
|
-
var target = {};
|
|
183
|
-
var sourceKeys = Object.keys(source);
|
|
184
|
-
var key, i;
|
|
185
|
-
for (i = 0; i < sourceKeys.length; i++) {
|
|
186
|
-
key = sourceKeys[i];
|
|
187
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
188
|
-
target[key] = source[key];
|
|
189
|
-
}
|
|
190
|
-
return target;
|
|
191
|
-
}
|
|
192
|
-
function ownKeys$1(object, enumerableOnly) {
|
|
193
|
-
var keys = Object.keys(object);
|
|
194
|
-
if (Object.getOwnPropertySymbols) {
|
|
195
|
-
var symbols = Object.getOwnPropertySymbols(object);
|
|
196
|
-
enumerableOnly && (symbols = symbols.filter(function(sym) {
|
|
197
|
-
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
198
|
-
})), keys.push.apply(keys, symbols);
|
|
199
|
-
}
|
|
200
|
-
return keys;
|
|
201
|
-
}
|
|
202
|
-
function _objectSpread$1(target) {
|
|
203
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
204
|
-
var source = null != arguments[i] ? arguments[i] : {};
|
|
205
|
-
i % 2 ? ownKeys$1(Object(source), true).forEach(function(key) {
|
|
206
|
-
_defineProperty$1(target, key, source[key]);
|
|
207
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys$1(Object(source)).forEach(function(key) {
|
|
208
|
-
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
209
|
-
});
|
|
210
|
-
}
|
|
211
|
-
return target;
|
|
212
|
-
}
|
|
213
|
-
function _defineProperty$1(obj, key, value) {
|
|
214
|
-
key = _toPropertyKey$1(key);
|
|
215
|
-
if (key in obj) {
|
|
216
|
-
Object.defineProperty(obj, key, { value, enumerable: true, configurable: true, writable: true });
|
|
217
|
-
} else {
|
|
218
|
-
obj[key] = value;
|
|
219
|
-
}
|
|
220
|
-
return obj;
|
|
221
|
-
}
|
|
222
|
-
function _toPropertyKey$1(arg) {
|
|
223
|
-
var key = _toPrimitive$1(arg, "string");
|
|
224
|
-
return typeof key === "symbol" ? key : String(key);
|
|
225
|
-
}
|
|
226
|
-
function _toPrimitive$1(input, hint) {
|
|
227
|
-
if (typeof input !== "object" || input === null) return input;
|
|
228
|
-
var prim = input[Symbol.toPrimitive];
|
|
229
|
-
if (prim !== void 0) {
|
|
230
|
-
var res = prim.call(input, hint || "default");
|
|
231
|
-
if (typeof res !== "object") return res;
|
|
232
|
-
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
233
|
-
}
|
|
234
|
-
return (hint === "string" ? String : Number)(input);
|
|
235
|
-
}
|
|
236
|
-
function _inheritsLoose$1(subClass, superClass) {
|
|
237
|
-
subClass.prototype = Object.create(superClass.prototype);
|
|
238
|
-
subClass.prototype.constructor = subClass;
|
|
239
|
-
_setPrototypeOf$1(subClass, superClass);
|
|
240
|
-
}
|
|
241
|
-
function _setPrototypeOf$1(o, p) {
|
|
242
|
-
_setPrototypeOf$1 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o2, p2) {
|
|
243
|
-
o2.__proto__ = p2;
|
|
244
|
-
return o2;
|
|
245
|
-
};
|
|
246
|
-
return _setPrototypeOf$1(o, p);
|
|
247
|
-
}
|
|
248
|
-
var Resizable$1 = /* @__PURE__ */ function(_React$Component) {
|
|
249
|
-
_inheritsLoose$1(Resizable2, _React$Component);
|
|
250
|
-
function Resizable2() {
|
|
251
|
-
var _this;
|
|
252
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
253
|
-
args[_key] = arguments[_key];
|
|
254
|
-
}
|
|
255
|
-
_this = _React$Component.call.apply(_React$Component, [this].concat(args)) || this;
|
|
256
|
-
_this.handleRefs = {};
|
|
257
|
-
_this.lastHandleRect = null;
|
|
258
|
-
_this.slack = null;
|
|
259
|
-
return _this;
|
|
260
|
-
}
|
|
261
|
-
var _proto = Resizable2.prototype;
|
|
262
|
-
_proto.componentWillUnmount = function componentWillUnmount() {
|
|
263
|
-
this.resetData();
|
|
264
|
-
};
|
|
265
|
-
_proto.resetData = function resetData() {
|
|
266
|
-
this.lastHandleRect = this.slack = null;
|
|
267
|
-
};
|
|
268
|
-
_proto.runConstraints = function runConstraints(width2, height2) {
|
|
269
|
-
var _this$props = this.props, minConstraints = _this$props.minConstraints, maxConstraints = _this$props.maxConstraints, lockAspectRatio = _this$props.lockAspectRatio;
|
|
270
|
-
if (!minConstraints && !maxConstraints && !lockAspectRatio) return [width2, height2];
|
|
271
|
-
if (lockAspectRatio) {
|
|
272
|
-
var ratio = this.props.width / this.props.height;
|
|
273
|
-
var deltaW = width2 - this.props.width;
|
|
274
|
-
var deltaH = height2 - this.props.height;
|
|
275
|
-
if (Math.abs(deltaW) > Math.abs(deltaH * ratio)) {
|
|
276
|
-
height2 = width2 / ratio;
|
|
277
|
-
} else {
|
|
278
|
-
width2 = height2 * ratio;
|
|
279
|
-
}
|
|
280
|
-
}
|
|
281
|
-
var oldW = width2, oldH = height2;
|
|
282
|
-
var _ref = this.slack || [0, 0], slackW = _ref[0], slackH = _ref[1];
|
|
283
|
-
width2 += slackW;
|
|
284
|
-
height2 += slackH;
|
|
285
|
-
if (minConstraints) {
|
|
286
|
-
width2 = Math.max(minConstraints[0], width2);
|
|
287
|
-
height2 = Math.max(minConstraints[1], height2);
|
|
288
|
-
}
|
|
289
|
-
if (maxConstraints) {
|
|
290
|
-
width2 = Math.min(maxConstraints[0], width2);
|
|
291
|
-
height2 = Math.min(maxConstraints[1], height2);
|
|
292
|
-
}
|
|
293
|
-
this.slack = [slackW + (oldW - width2), slackH + (oldH - height2)];
|
|
294
|
-
return [width2, height2];
|
|
295
|
-
};
|
|
296
|
-
_proto.resizeHandler = function resizeHandler(handlerName, axis) {
|
|
297
|
-
var _this2 = this;
|
|
298
|
-
return function(e, _ref2) {
|
|
299
|
-
var node = _ref2.node, deltaX = _ref2.deltaX, deltaY = _ref2.deltaY;
|
|
300
|
-
if (handlerName === "onResizeStart") _this2.resetData();
|
|
301
|
-
var canDragX = (_this2.props.axis === "both" || _this2.props.axis === "x") && axis !== "n" && axis !== "s";
|
|
302
|
-
var canDragY = (_this2.props.axis === "both" || _this2.props.axis === "y") && axis !== "e" && axis !== "w";
|
|
303
|
-
if (!canDragX && !canDragY) return;
|
|
304
|
-
var axisV = axis[0];
|
|
305
|
-
var axisH = axis[axis.length - 1];
|
|
306
|
-
var handleRect = node.getBoundingClientRect();
|
|
307
|
-
if (_this2.lastHandleRect != null) {
|
|
308
|
-
if (axisH === "w") {
|
|
309
|
-
var deltaLeftSinceLast = handleRect.left - _this2.lastHandleRect.left;
|
|
310
|
-
deltaX += deltaLeftSinceLast;
|
|
311
|
-
}
|
|
312
|
-
if (axisV === "n") {
|
|
313
|
-
var deltaTopSinceLast = handleRect.top - _this2.lastHandleRect.top;
|
|
314
|
-
deltaY += deltaTopSinceLast;
|
|
315
|
-
}
|
|
316
|
-
}
|
|
317
|
-
_this2.lastHandleRect = handleRect;
|
|
318
|
-
if (axisH === "w") deltaX = -deltaX;
|
|
319
|
-
if (axisV === "n") deltaY = -deltaY;
|
|
320
|
-
var width2 = _this2.props.width + (canDragX ? deltaX / _this2.props.transformScale : 0);
|
|
321
|
-
var height2 = _this2.props.height + (canDragY ? deltaY / _this2.props.transformScale : 0);
|
|
322
|
-
var _this2$runConstraints = _this2.runConstraints(width2, height2);
|
|
323
|
-
width2 = _this2$runConstraints[0];
|
|
324
|
-
height2 = _this2$runConstraints[1];
|
|
325
|
-
var dimensionsChanged = width2 !== _this2.props.width || height2 !== _this2.props.height;
|
|
326
|
-
var cb = typeof _this2.props[handlerName] === "function" ? _this2.props[handlerName] : null;
|
|
327
|
-
var shouldSkipCb = handlerName === "onResize" && !dimensionsChanged;
|
|
328
|
-
if (cb && !shouldSkipCb) {
|
|
329
|
-
e.persist == null ? void 0 : e.persist();
|
|
330
|
-
cb(e, {
|
|
331
|
-
node,
|
|
332
|
-
size: {
|
|
333
|
-
width: width2,
|
|
334
|
-
height: height2
|
|
335
|
-
},
|
|
336
|
-
handle: axis
|
|
337
|
-
});
|
|
338
|
-
}
|
|
339
|
-
if (handlerName === "onResizeStop") _this2.resetData();
|
|
340
|
-
};
|
|
341
|
-
};
|
|
342
|
-
_proto.renderResizeHandle = function renderResizeHandle(handleAxis, ref) {
|
|
343
|
-
var handle = this.props.handle;
|
|
344
|
-
if (!handle) {
|
|
345
|
-
return /* @__PURE__ */ React$1.createElement("span", {
|
|
346
|
-
className: "react-resizable-handle react-resizable-handle-" + handleAxis,
|
|
347
|
-
ref
|
|
348
|
-
});
|
|
349
|
-
}
|
|
350
|
-
if (typeof handle === "function") {
|
|
351
|
-
return handle(handleAxis, ref);
|
|
352
|
-
}
|
|
353
|
-
var isDOMElement = typeof handle.type === "string";
|
|
354
|
-
var props = _objectSpread$1({
|
|
355
|
-
ref
|
|
356
|
-
}, isDOMElement ? {} : {
|
|
357
|
-
handleAxis
|
|
358
|
-
});
|
|
359
|
-
return /* @__PURE__ */ React$1.cloneElement(handle, props);
|
|
360
|
-
};
|
|
361
|
-
_proto.render = function render() {
|
|
362
|
-
var _this3 = this;
|
|
363
|
-
var _this$props2 = this.props, children = _this$props2.children, className = _this$props2.className, draggableOpts = _this$props2.draggableOpts;
|
|
364
|
-
_this$props2.width;
|
|
365
|
-
_this$props2.height;
|
|
366
|
-
_this$props2.handle;
|
|
367
|
-
_this$props2.handleSize;
|
|
368
|
-
_this$props2.lockAspectRatio;
|
|
369
|
-
_this$props2.axis;
|
|
370
|
-
_this$props2.minConstraints;
|
|
371
|
-
_this$props2.maxConstraints;
|
|
372
|
-
_this$props2.onResize;
|
|
373
|
-
_this$props2.onResizeStop;
|
|
374
|
-
_this$props2.onResizeStart;
|
|
375
|
-
var resizeHandles = _this$props2.resizeHandles;
|
|
376
|
-
_this$props2.transformScale;
|
|
377
|
-
var p = _objectWithoutPropertiesLoose$1(_this$props2, _excluded$1);
|
|
378
|
-
return (0, _utils.cloneElement)(children, _objectSpread$1(_objectSpread$1({}, p), {}, {
|
|
379
|
-
className: (className ? className + " " : "") + "react-resizable",
|
|
380
|
-
children: [].concat(children.props.children, resizeHandles.map(function(handleAxis) {
|
|
381
|
-
var _this3$handleRefs$han;
|
|
382
|
-
var ref = (_this3$handleRefs$han = _this3.handleRefs[handleAxis]) != null ? _this3$handleRefs$han : _this3.handleRefs[handleAxis] = /* @__PURE__ */ React$1.createRef();
|
|
383
|
-
return /* @__PURE__ */ React$1.createElement(_reactDraggable.DraggableCore, _extends$1({}, draggableOpts, {
|
|
384
|
-
nodeRef: ref,
|
|
385
|
-
key: "resizableHandle-" + handleAxis,
|
|
386
|
-
onStop: _this3.resizeHandler("onResizeStop", handleAxis),
|
|
387
|
-
onStart: _this3.resizeHandler("onResizeStart", handleAxis),
|
|
388
|
-
onDrag: _this3.resizeHandler("onResize", handleAxis)
|
|
389
|
-
}), _this3.renderResizeHandle(handleAxis, ref));
|
|
390
|
-
}))
|
|
391
|
-
}));
|
|
392
|
-
};
|
|
393
|
-
return Resizable2;
|
|
394
|
-
}(React$1.Component);
|
|
395
|
-
Resizable$2.default = Resizable$1;
|
|
396
|
-
Resizable$1.propTypes = _propTypes$1.resizableProps;
|
|
397
|
-
Resizable$1.defaultProps = {
|
|
398
|
-
axis: "both",
|
|
399
|
-
handleSize: [20, 20],
|
|
400
|
-
lockAspectRatio: false,
|
|
401
|
-
minConstraints: [20, 20],
|
|
402
|
-
maxConstraints: [Infinity, Infinity],
|
|
403
|
-
resizeHandles: ["se"],
|
|
404
|
-
transformScale: 1
|
|
405
|
-
};
|
|
406
|
-
var ResizableBox$2 = {};
|
|
407
|
-
ResizableBox$2.__esModule = true;
|
|
408
|
-
ResizableBox$2.default = void 0;
|
|
409
|
-
var React = _interopRequireWildcard(React__default);
|
|
410
|
-
var _propTypes = _interopRequireDefault(require$$1);
|
|
411
|
-
var _Resizable = _interopRequireDefault(Resizable$2);
|
|
412
|
-
var _propTypes2 = propTypes;
|
|
413
|
-
var _excluded = ["handle", "handleSize", "onResize", "onResizeStart", "onResizeStop", "draggableOpts", "minConstraints", "maxConstraints", "lockAspectRatio", "axis", "width", "height", "resizeHandles", "style", "transformScale"];
|
|
414
|
-
function _interopRequireDefault(obj) {
|
|
415
|
-
return obj && obj.__esModule ? obj : { default: obj };
|
|
416
|
-
}
|
|
417
|
-
function _getRequireWildcardCache(nodeInterop) {
|
|
418
|
-
if (typeof WeakMap !== "function") return null;
|
|
419
|
-
var cacheBabelInterop = /* @__PURE__ */ new WeakMap();
|
|
420
|
-
var cacheNodeInterop = /* @__PURE__ */ new WeakMap();
|
|
421
|
-
return (_getRequireWildcardCache = function _getRequireWildcardCache2(nodeInterop2) {
|
|
422
|
-
return nodeInterop2 ? cacheNodeInterop : cacheBabelInterop;
|
|
423
|
-
})(nodeInterop);
|
|
424
|
-
}
|
|
425
|
-
function _interopRequireWildcard(obj, nodeInterop) {
|
|
426
|
-
if (obj && obj.__esModule) {
|
|
427
|
-
return obj;
|
|
428
|
-
}
|
|
429
|
-
if (obj === null || typeof obj !== "object" && typeof obj !== "function") {
|
|
430
|
-
return { default: obj };
|
|
431
|
-
}
|
|
432
|
-
var cache = _getRequireWildcardCache(nodeInterop);
|
|
433
|
-
if (cache && cache.has(obj)) {
|
|
434
|
-
return cache.get(obj);
|
|
435
|
-
}
|
|
436
|
-
var newObj = {};
|
|
437
|
-
var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor;
|
|
438
|
-
for (var key in obj) {
|
|
439
|
-
if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) {
|
|
440
|
-
var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null;
|
|
441
|
-
if (desc && (desc.get || desc.set)) {
|
|
442
|
-
Object.defineProperty(newObj, key, desc);
|
|
443
|
-
} else {
|
|
444
|
-
newObj[key] = obj[key];
|
|
445
|
-
}
|
|
446
|
-
}
|
|
447
|
-
}
|
|
448
|
-
newObj.default = obj;
|
|
449
|
-
if (cache) {
|
|
450
|
-
cache.set(obj, newObj);
|
|
451
|
-
}
|
|
452
|
-
return newObj;
|
|
453
|
-
}
|
|
454
|
-
function _extends() {
|
|
455
|
-
_extends = Object.assign ? Object.assign.bind() : function(target) {
|
|
456
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
457
|
-
var source = arguments[i];
|
|
458
|
-
for (var key in source) {
|
|
459
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
460
|
-
target[key] = source[key];
|
|
461
|
-
}
|
|
462
|
-
}
|
|
463
|
-
}
|
|
464
|
-
return target;
|
|
465
|
-
};
|
|
466
|
-
return _extends.apply(this, arguments);
|
|
467
|
-
}
|
|
468
|
-
function ownKeys(object, enumerableOnly) {
|
|
469
|
-
var keys = Object.keys(object);
|
|
470
|
-
if (Object.getOwnPropertySymbols) {
|
|
471
|
-
var symbols = Object.getOwnPropertySymbols(object);
|
|
472
|
-
enumerableOnly && (symbols = symbols.filter(function(sym) {
|
|
473
|
-
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
474
|
-
})), keys.push.apply(keys, symbols);
|
|
475
|
-
}
|
|
476
|
-
return keys;
|
|
477
|
-
}
|
|
478
|
-
function _objectSpread(target) {
|
|
479
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
480
|
-
var source = null != arguments[i] ? arguments[i] : {};
|
|
481
|
-
i % 2 ? ownKeys(Object(source), true).forEach(function(key) {
|
|
482
|
-
_defineProperty(target, key, source[key]);
|
|
483
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function(key) {
|
|
484
|
-
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
485
|
-
});
|
|
486
|
-
}
|
|
487
|
-
return target;
|
|
488
|
-
}
|
|
489
|
-
function _defineProperty(obj, key, value) {
|
|
490
|
-
key = _toPropertyKey(key);
|
|
491
|
-
if (key in obj) {
|
|
492
|
-
Object.defineProperty(obj, key, { value, enumerable: true, configurable: true, writable: true });
|
|
493
|
-
} else {
|
|
494
|
-
obj[key] = value;
|
|
495
|
-
}
|
|
496
|
-
return obj;
|
|
497
|
-
}
|
|
498
|
-
function _toPropertyKey(arg) {
|
|
499
|
-
var key = _toPrimitive(arg, "string");
|
|
500
|
-
return typeof key === "symbol" ? key : String(key);
|
|
501
|
-
}
|
|
502
|
-
function _toPrimitive(input, hint) {
|
|
503
|
-
if (typeof input !== "object" || input === null) return input;
|
|
504
|
-
var prim = input[Symbol.toPrimitive];
|
|
505
|
-
if (prim !== void 0) {
|
|
506
|
-
var res = prim.call(input, hint || "default");
|
|
507
|
-
if (typeof res !== "object") return res;
|
|
508
|
-
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
509
|
-
}
|
|
510
|
-
return (hint === "string" ? String : Number)(input);
|
|
511
|
-
}
|
|
512
|
-
function _objectWithoutPropertiesLoose(source, excluded) {
|
|
513
|
-
if (source == null) return {};
|
|
514
|
-
var target = {};
|
|
515
|
-
var sourceKeys = Object.keys(source);
|
|
516
|
-
var key, i;
|
|
517
|
-
for (i = 0; i < sourceKeys.length; i++) {
|
|
518
|
-
key = sourceKeys[i];
|
|
519
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
520
|
-
target[key] = source[key];
|
|
521
|
-
}
|
|
522
|
-
return target;
|
|
523
|
-
}
|
|
524
|
-
function _inheritsLoose(subClass, superClass) {
|
|
525
|
-
subClass.prototype = Object.create(superClass.prototype);
|
|
526
|
-
subClass.prototype.constructor = subClass;
|
|
527
|
-
_setPrototypeOf(subClass, superClass);
|
|
528
|
-
}
|
|
529
|
-
function _setPrototypeOf(o, p) {
|
|
530
|
-
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf2(o2, p2) {
|
|
531
|
-
o2.__proto__ = p2;
|
|
532
|
-
return o2;
|
|
533
|
-
};
|
|
534
|
-
return _setPrototypeOf(o, p);
|
|
535
|
-
}
|
|
536
|
-
var ResizableBox$1 = /* @__PURE__ */ function(_React$Component) {
|
|
537
|
-
_inheritsLoose(ResizableBox2, _React$Component);
|
|
538
|
-
function ResizableBox2() {
|
|
539
|
-
var _this;
|
|
540
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
541
|
-
args[_key] = arguments[_key];
|
|
542
|
-
}
|
|
543
|
-
_this = _React$Component.call.apply(_React$Component, [this].concat(args)) || this;
|
|
544
|
-
_this.state = {
|
|
545
|
-
width: _this.props.width,
|
|
546
|
-
height: _this.props.height,
|
|
547
|
-
propsWidth: _this.props.width,
|
|
548
|
-
propsHeight: _this.props.height
|
|
549
|
-
};
|
|
550
|
-
_this.onResize = function(e, data) {
|
|
551
|
-
var size = data.size;
|
|
552
|
-
if (_this.props.onResize) {
|
|
553
|
-
e.persist == null ? void 0 : e.persist();
|
|
554
|
-
_this.setState(size, function() {
|
|
555
|
-
return _this.props.onResize && _this.props.onResize(e, data);
|
|
556
|
-
});
|
|
557
|
-
} else {
|
|
558
|
-
_this.setState(size);
|
|
559
|
-
}
|
|
560
|
-
};
|
|
561
|
-
return _this;
|
|
562
|
-
}
|
|
563
|
-
ResizableBox2.getDerivedStateFromProps = function getDerivedStateFromProps(props, state) {
|
|
564
|
-
if (state.propsWidth !== props.width || state.propsHeight !== props.height) {
|
|
565
|
-
return {
|
|
566
|
-
width: props.width,
|
|
567
|
-
height: props.height,
|
|
568
|
-
propsWidth: props.width,
|
|
569
|
-
propsHeight: props.height
|
|
570
|
-
};
|
|
571
|
-
}
|
|
572
|
-
return null;
|
|
573
|
-
};
|
|
574
|
-
var _proto = ResizableBox2.prototype;
|
|
575
|
-
_proto.render = function render() {
|
|
576
|
-
var _this$props = this.props, handle = _this$props.handle, handleSize = _this$props.handleSize;
|
|
577
|
-
_this$props.onResize;
|
|
578
|
-
var onResizeStart = _this$props.onResizeStart, onResizeStop = _this$props.onResizeStop, draggableOpts = _this$props.draggableOpts, minConstraints = _this$props.minConstraints, maxConstraints = _this$props.maxConstraints, lockAspectRatio = _this$props.lockAspectRatio, axis = _this$props.axis;
|
|
579
|
-
_this$props.width;
|
|
580
|
-
_this$props.height;
|
|
581
|
-
var resizeHandles = _this$props.resizeHandles, style = _this$props.style, transformScale = _this$props.transformScale, props = _objectWithoutPropertiesLoose(_this$props, _excluded);
|
|
582
|
-
return /* @__PURE__ */ React.createElement(_Resizable.default, {
|
|
583
|
-
axis,
|
|
584
|
-
draggableOpts,
|
|
585
|
-
handle,
|
|
586
|
-
handleSize,
|
|
587
|
-
height: this.state.height,
|
|
588
|
-
lockAspectRatio,
|
|
589
|
-
maxConstraints,
|
|
590
|
-
minConstraints,
|
|
591
|
-
onResizeStart,
|
|
592
|
-
onResize: this.onResize,
|
|
593
|
-
onResizeStop,
|
|
594
|
-
resizeHandles,
|
|
595
|
-
transformScale,
|
|
596
|
-
width: this.state.width
|
|
597
|
-
}, /* @__PURE__ */ React.createElement("div", _extends({}, props, {
|
|
598
|
-
style: _objectSpread(_objectSpread({}, style), {}, {
|
|
599
|
-
width: this.state.width + "px",
|
|
600
|
-
height: this.state.height + "px"
|
|
601
|
-
})
|
|
602
|
-
})));
|
|
603
|
-
};
|
|
604
|
-
return ResizableBox2;
|
|
605
|
-
}(React.Component);
|
|
606
|
-
ResizableBox$2.default = ResizableBox$1;
|
|
607
|
-
ResizableBox$1.propTypes = _objectSpread(_objectSpread({}, _propTypes2.resizableProps), {}, {
|
|
608
|
-
children: _propTypes.default.element
|
|
609
|
-
});
|
|
610
|
-
reactResizable.exports = function() {
|
|
611
|
-
throw new Error("Don't instantiate Resizable directly! Use require('react-resizable').Resizable");
|
|
612
|
-
};
|
|
613
|
-
var Resizable = reactResizable.exports.Resizable = Resizable$2.default;
|
|
614
|
-
var ResizableBox = reactResizable.exports.ResizableBox = ResizableBox$2.default;
|
|
615
|
-
export {
|
|
616
|
-
Resizable as R,
|
|
617
|
-
ResizableBox as a
|
|
618
|
-
};
|