@oliasoft-open-source/react-ui-library 4.19.6 → 4.19.7
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/README.md +1 -0
- package/dist/index.d.ts +2 -1
- package/dist/index.js +127 -128
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1360,6 +1360,7 @@ The `OptionDropdown` component is used to display a dropdown menu with selectabl
|
|
|
1360
1360
|
| `onChange` | A function to be called when the selected options change. | - |
|
|
1361
1361
|
| `showHeader` | A boolean indicating whether to display a header above the dropdown options. | `true` |
|
|
1362
1362
|
| `maxHeight` | The maximum height of the dropdown menu. | `'40vh'` |
|
|
1363
|
+
| `testId` | Test ID used for testing purposes. | - |
|
|
1363
1364
|
|
|
1364
1365
|
### Usage Example
|
|
1365
1366
|
|
package/dist/index.d.ts
CHANGED
|
@@ -955,6 +955,7 @@ export declare interface IOptionDropdownProps {
|
|
|
955
955
|
showHeader?: boolean;
|
|
956
956
|
maxHeight?: string;
|
|
957
957
|
small?: boolean;
|
|
958
|
+
testId?: string;
|
|
958
959
|
}
|
|
959
960
|
|
|
960
961
|
declare interface IOptionItem {
|
|
@@ -1693,7 +1694,7 @@ export declare const NativeSelect: ({ disabled, error, warning, tooltip, options
|
|
|
1693
1694
|
|
|
1694
1695
|
export declare const NumberInput: ({ name, placeholder, disabled, error, left, small, width, value, onChange, onFocus, onBlur, selectOnFocus, tabIndex, testId, tooltip, warning, validationCallback, allowEmpty, isInTable, groupOrder, enableCosmeticRounding, enableDisplayRounding, roundDisplayValue, disableInternalErrorValidationMessages, }: INumberInputProps) => JSX_2.Element;
|
|
1695
1696
|
|
|
1696
|
-
export declare const OptionDropdown: ({ name, label, options, onChange, small, showHeader, maxHeight, }: IOptionDropdownProps) => ReactElement;
|
|
1697
|
+
export declare const OptionDropdown: ({ name, label, options, onChange, small, showHeader, maxHeight, testId, }: IOptionDropdownProps) => ReactElement;
|
|
1697
1698
|
|
|
1698
1699
|
export declare const Page: ({ children, left, padding: paddingProp, scroll, top, }: ILayoutPageProps) => JSX_2.Element;
|
|
1699
1700
|
|
package/dist/index.js
CHANGED
|
@@ -199,27 +199,21 @@ function _objectWithoutPropertiesLoose$5(r2, e2) {
|
|
|
199
199
|
}
|
|
200
200
|
return t;
|
|
201
201
|
}
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
(function(module) {
|
|
208
|
-
function _extends3() {
|
|
209
|
-
return module.exports = _extends3 = Object.assign ? Object.assign.bind() : function(n2) {
|
|
210
|
-
for (var e2 = 1; e2 < arguments.length; e2++) {
|
|
211
|
-
var t = arguments[e2];
|
|
212
|
-
for (var r2 in t) ({}).hasOwnProperty.call(t, r2) && (n2[r2] = t[r2]);
|
|
213
|
-
}
|
|
214
|
-
return n2;
|
|
215
|
-
}, module.exports.__esModule = true, module.exports["default"] = module.exports, _extends3.apply(null, arguments);
|
|
202
|
+
function _extends$4() {
|
|
203
|
+
return _extends$4 = Object.assign ? Object.assign.bind() : function(n2) {
|
|
204
|
+
for (var e2 = 1; e2 < arguments.length; e2++) {
|
|
205
|
+
var t = arguments[e2];
|
|
206
|
+
for (var r2 in t) ({}).hasOwnProperty.call(t, r2) && (n2[r2] = t[r2]);
|
|
216
207
|
}
|
|
217
|
-
|
|
218
|
-
}
|
|
219
|
-
return _extends$6.exports;
|
|
208
|
+
return n2;
|
|
209
|
+
}, _extends$4.apply(null, arguments);
|
|
220
210
|
}
|
|
221
|
-
|
|
222
|
-
|
|
211
|
+
const _extends$5 = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
212
|
+
__proto__: null,
|
|
213
|
+
get default() {
|
|
214
|
+
return _extends$4;
|
|
215
|
+
}
|
|
216
|
+
}, Symbol.toStringTag, { value: "Module" }));
|
|
223
217
|
function _setPrototypeOf$3(t, e2) {
|
|
224
218
|
return _setPrototypeOf$3 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function(t2, e3) {
|
|
225
219
|
return t2.__proto__ = e3, t2;
|
|
@@ -798,7 +792,7 @@ var ReactSVG = /* @__PURE__ */ function(_React$Component) {
|
|
|
798
792
|
};
|
|
799
793
|
_proto.componentDidUpdate = function componentDidUpdate(prevProps) {
|
|
800
794
|
var _this3 = this;
|
|
801
|
-
if (shallowDiffers(_extends$
|
|
795
|
+
if (shallowDiffers(_extends$4({}, prevProps), this.props)) {
|
|
802
796
|
this.setState(function() {
|
|
803
797
|
return _this3.initialState;
|
|
804
798
|
}, function() {
|
|
@@ -826,7 +820,7 @@ var ReactSVG = /* @__PURE__ */ function(_React$Component) {
|
|
|
826
820
|
_this$props2.useRequestCache;
|
|
827
821
|
var wrapper2 = _this$props2.wrapper, rest = _objectWithoutPropertiesLoose$5(_this$props2, _excluded$8);
|
|
828
822
|
var Wrapper2 = wrapper2;
|
|
829
|
-
return /* @__PURE__ */ React$4.createElement(Wrapper2, _extends$
|
|
823
|
+
return /* @__PURE__ */ React$4.createElement(Wrapper2, _extends$4({}, rest, {
|
|
830
824
|
ref: this.refCallback
|
|
831
825
|
}, wrapper2 === "svg" ? {
|
|
832
826
|
xmlns: svgNamespace,
|
|
@@ -2241,8 +2235,8 @@ function _createClass(Constructor, protoProps, staticProps) {
|
|
|
2241
2235
|
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
|
2242
2236
|
return Constructor;
|
|
2243
2237
|
}
|
|
2244
|
-
function _extends$
|
|
2245
|
-
_extends$
|
|
2238
|
+
function _extends$3() {
|
|
2239
|
+
_extends$3 = Object.assign || function(target) {
|
|
2246
2240
|
for (var i = 1; i < arguments.length; i++) {
|
|
2247
2241
|
var source = arguments[i];
|
|
2248
2242
|
for (var key2 in source) {
|
|
@@ -2253,7 +2247,7 @@ function _extends$4() {
|
|
|
2253
2247
|
}
|
|
2254
2248
|
return target;
|
|
2255
2249
|
};
|
|
2256
|
-
return _extends$
|
|
2250
|
+
return _extends$3.apply(this, arguments);
|
|
2257
2251
|
}
|
|
2258
2252
|
function _inheritsLoose$2(subClass, superClass) {
|
|
2259
2253
|
subClass.prototype = Object.create(superClass.prototype);
|
|
@@ -2577,7 +2571,7 @@ function useTrackElements(_ref) {
|
|
|
2577
2571
|
var layerRef = useTrackRef(useCallback(function(layer2) {
|
|
2578
2572
|
var _get3 = get3(), previousLayer = _get3.layer;
|
|
2579
2573
|
set2(function(state) {
|
|
2580
|
-
return _extends$
|
|
2574
|
+
return _extends$3({}, state, {
|
|
2581
2575
|
layer: layer2
|
|
2582
2576
|
});
|
|
2583
2577
|
});
|
|
@@ -2600,7 +2594,7 @@ function useTrackElements(_ref) {
|
|
|
2600
2594
|
var scrollContainers = getScrollContainers(trigger2);
|
|
2601
2595
|
var _get4 = get3(), previousTrigger = _get4.trigger;
|
|
2602
2596
|
set2(function(state) {
|
|
2603
|
-
return _extends$
|
|
2597
|
+
return _extends$3({}, state, {
|
|
2604
2598
|
trigger: trigger2,
|
|
2605
2599
|
scrollContainers
|
|
2606
2600
|
});
|
|
@@ -2613,7 +2607,7 @@ function useTrackElements(_ref) {
|
|
|
2613
2607
|
return;
|
|
2614
2608
|
}
|
|
2615
2609
|
set2(function(state) {
|
|
2616
|
-
return _extends$
|
|
2610
|
+
return _extends$3({}, state, {
|
|
2617
2611
|
scrollContainers: getScrollContainers(triggerOptionParent)
|
|
2618
2612
|
});
|
|
2619
2613
|
});
|
|
@@ -2780,7 +2774,7 @@ var BoundSide = {
|
|
|
2780
2774
|
left: /* @__PURE__ */ createSide("left"),
|
|
2781
2775
|
right: /* @__PURE__ */ createSide("right")
|
|
2782
2776
|
};
|
|
2783
|
-
var Side = /* @__PURE__ */ _extends$
|
|
2777
|
+
var Side = /* @__PURE__ */ _extends$3({}, BoundSide, {
|
|
2784
2778
|
center: /* @__PURE__ */ createSide("center")
|
|
2785
2779
|
});
|
|
2786
2780
|
var SIDES = ["top", "left", "bottom", "right"];
|
|
@@ -2876,7 +2870,7 @@ var Bounds = /* @__PURE__ */ function() {
|
|
|
2876
2870
|
var _environment$getCompu = environment2.getComputedStyle(element), width2 = _environment$getCompu.width, height2 = _environment$getCompu.height, boxSizing = _environment$getCompu.boxSizing, borderLeft = _environment$getCompu.borderLeft, borderRight = _environment$getCompu.borderRight, borderTop = _environment$getCompu.borderTop, borderBottom = _environment$getCompu.borderBottom, paddingLeft = _environment$getCompu.paddingLeft, paddingRight = _environment$getCompu.paddingRight, paddingTop = _environment$getCompu.paddingTop, paddingBottom = _environment$getCompu.paddingBottom;
|
|
2877
2871
|
var boxWidth = boxSizing === "border-box" ? getPixelValue(width2) : sumOfPropertyValues(width2, borderLeft, borderRight, paddingLeft, paddingRight);
|
|
2878
2872
|
var boxHeight = boxSizing === "border-box" ? getPixelValue(height2) : sumOfPropertyValues(height2, borderTop, borderBottom, paddingTop, paddingBottom);
|
|
2879
|
-
bounds = new Bounds2(_extends$
|
|
2873
|
+
bounds = new Bounds2(_extends$3({}, bounds, {
|
|
2880
2874
|
width: boxWidth,
|
|
2881
2875
|
height: boxHeight
|
|
2882
2876
|
}));
|
|
@@ -2923,7 +2917,7 @@ var Bounds = /* @__PURE__ */ function() {
|
|
|
2923
2917
|
};
|
|
2924
2918
|
_proto.merge = function merge(partialBoundsOrMergeFn) {
|
|
2925
2919
|
var current = this.toObject();
|
|
2926
|
-
return new Bounds2(_extends$
|
|
2920
|
+
return new Bounds2(_extends$3({}, current, typeof partialBoundsOrMergeFn === "function" ? partialBoundsOrMergeFn(current) : partialBoundsOrMergeFn));
|
|
2927
2921
|
};
|
|
2928
2922
|
_proto.substract = function substract(bounds) {
|
|
2929
2923
|
var result = this.toObject();
|
|
@@ -2990,7 +2984,7 @@ var Placement = /* @__PURE__ */ function() {
|
|
|
2990
2984
|
typeof layerDimensions === "function" ? layerDimensions(this.primary.prop) : layerDimensions
|
|
2991
2985
|
);
|
|
2992
2986
|
this.subjectsBounds = subjectBounds.merge({
|
|
2993
|
-
layer: _extends$
|
|
2987
|
+
layer: _extends$3({}, subjectBounds.layer, dimensions)
|
|
2994
2988
|
});
|
|
2995
2989
|
};
|
|
2996
2990
|
_proto.getLayerBounds = function getLayerBounds(secondaryOffset) {
|
|
@@ -3165,7 +3159,7 @@ function getArrowStyle(subjectsBounds, placement, arrowOffset) {
|
|
|
3165
3159
|
var primarySide = placement.primary.prop;
|
|
3166
3160
|
var secondarySide = placement.primary.oppositeCssProp;
|
|
3167
3161
|
var secondaryValue = triggerIsBigger ? layer2[sizeProperty] / 2 + negativeOffset : trigger2[secondarySide] + trigger2[sizeProperty] / 2 - layer2[secondarySide];
|
|
3168
|
-
return _extends$
|
|
3162
|
+
return _extends$3({}, STYLE_BASE, (_extends22 = {}, _extends22[primarySide] = "100%", _extends22[secondarySide] = limit(secondaryValue, min, max), _extends22));
|
|
3169
3163
|
}
|
|
3170
3164
|
var Placements = /* @__PURE__ */ function() {
|
|
3171
3165
|
function Placements2(placements, config, subjectsBounds) {
|
|
@@ -3294,11 +3288,11 @@ var Placements = /* @__PURE__ */ function() {
|
|
|
3294
3288
|
var arrow2 = getArrowStyle(this.subjectsBounds.merge({
|
|
3295
3289
|
layer: layerBounds
|
|
3296
3290
|
}), placement, this.config.arrowOffset);
|
|
3297
|
-
var layer2 = this.config.overflowContainer ? _extends$
|
|
3291
|
+
var layer2 = this.config.overflowContainer ? _extends$3({}, layerStyleBase, {
|
|
3298
3292
|
position: "fixed",
|
|
3299
3293
|
top: layerBounds.top,
|
|
3300
3294
|
left: layerBounds.left
|
|
3301
|
-
}) : _extends$
|
|
3295
|
+
}) : _extends$3({}, layerStyleBase, {
|
|
3302
3296
|
position: "absolute",
|
|
3303
3297
|
top: layerBounds.top - this.subjectsBounds.parent.top + scrollOffsets.top - borderOffsets.top,
|
|
3304
3298
|
left: layerBounds.left - this.subjectsBounds.parent.left + scrollOffsets.left - borderOffsets.left
|
|
@@ -3373,7 +3367,7 @@ var SubjectsBounds = /* @__PURE__ */ function() {
|
|
|
3373
3367
|
};
|
|
3374
3368
|
var _proto = SubjectsBounds2.prototype;
|
|
3375
3369
|
_proto.merge = function merge(subjectsBounds) {
|
|
3376
|
-
return new SubjectsBounds2(_extends$
|
|
3370
|
+
return new SubjectsBounds2(_extends$3({}, this, subjectsBounds), this.overflowContainer);
|
|
3377
3371
|
};
|
|
3378
3372
|
_proto.offsetsToScrollContainers = function offsetsToScrollContainers(subject, allContainers) {
|
|
3379
3373
|
if (allContainers === void 0) {
|
|
@@ -3608,10 +3602,10 @@ var Arrow = /* @__PURE__ */ forwardRef(function Arrow2(_ref2, ref) {
|
|
|
3608
3602
|
var sizeA = size2;
|
|
3609
3603
|
var sizeB = getWidthBasedOnAngle(angle, size2) * 2;
|
|
3610
3604
|
var maxSize = Math.max(sizeA, sizeB);
|
|
3611
|
-
return createElement("svg", _extends$
|
|
3605
|
+
return createElement("svg", _extends$3({
|
|
3612
3606
|
ref
|
|
3613
3607
|
}, rest, {
|
|
3614
|
-
style: _extends$
|
|
3608
|
+
style: _extends$3({}, style, {
|
|
3615
3609
|
transform: "translate" + (side.isHorizontal ? "Y" : "X") + "(-50%)"
|
|
3616
3610
|
}),
|
|
3617
3611
|
width: maxSize,
|
|
@@ -8275,8 +8269,8 @@ function _interopRequireWildcard$2(obj, nodeInterop) {
|
|
|
8275
8269
|
}
|
|
8276
8270
|
return newObj;
|
|
8277
8271
|
}
|
|
8278
|
-
function _extends$
|
|
8279
|
-
_extends$
|
|
8272
|
+
function _extends$2() {
|
|
8273
|
+
_extends$2 = Object.assign ? Object.assign.bind() : function(target) {
|
|
8280
8274
|
for (var i = 1; i < arguments.length; i++) {
|
|
8281
8275
|
var source = arguments[i];
|
|
8282
8276
|
for (var key2 in source) {
|
|
@@ -8287,7 +8281,7 @@ function _extends$3() {
|
|
|
8287
8281
|
}
|
|
8288
8282
|
return target;
|
|
8289
8283
|
};
|
|
8290
|
-
return _extends$
|
|
8284
|
+
return _extends$2.apply(this, arguments);
|
|
8291
8285
|
}
|
|
8292
8286
|
function _objectWithoutPropertiesLoose$3(source, excluded) {
|
|
8293
8287
|
if (source == null) return {};
|
|
@@ -8492,7 +8486,7 @@ var Resizable$1 = /* @__PURE__ */ function(_React$Component) {
|
|
|
8492
8486
|
children: [].concat(children.props.children, resizeHandles.map(function(handleAxis) {
|
|
8493
8487
|
var _this3$handleRefs$han;
|
|
8494
8488
|
var ref = (_this3$handleRefs$han = _this3.handleRefs[handleAxis]) != null ? _this3$handleRefs$han : _this3.handleRefs[handleAxis] = /* @__PURE__ */ React$2.createRef();
|
|
8495
|
-
return /* @__PURE__ */ React$2.createElement(_reactDraggable.DraggableCore, _extends$
|
|
8489
|
+
return /* @__PURE__ */ React$2.createElement(_reactDraggable.DraggableCore, _extends$2({}, draggableOpts, {
|
|
8496
8490
|
nodeRef: ref,
|
|
8497
8491
|
key: "resizableHandle-" + handleAxis,
|
|
8498
8492
|
onStop: _this3.resizeHandler("onResizeStop", handleAxis),
|
|
@@ -8563,8 +8557,8 @@ function _interopRequireWildcard$1(obj, nodeInterop) {
|
|
|
8563
8557
|
}
|
|
8564
8558
|
return newObj;
|
|
8565
8559
|
}
|
|
8566
|
-
function _extends$
|
|
8567
|
-
_extends$
|
|
8560
|
+
function _extends$1() {
|
|
8561
|
+
_extends$1 = Object.assign ? Object.assign.bind() : function(target) {
|
|
8568
8562
|
for (var i = 1; i < arguments.length; i++) {
|
|
8569
8563
|
var source = arguments[i];
|
|
8570
8564
|
for (var key2 in source) {
|
|
@@ -8575,7 +8569,7 @@ function _extends$2() {
|
|
|
8575
8569
|
}
|
|
8576
8570
|
return target;
|
|
8577
8571
|
};
|
|
8578
|
-
return _extends$
|
|
8572
|
+
return _extends$1.apply(this, arguments);
|
|
8579
8573
|
}
|
|
8580
8574
|
function ownKeys$1(object2, enumerableOnly) {
|
|
8581
8575
|
var keys2 = Object.keys(object2);
|
|
@@ -8706,7 +8700,7 @@ var ResizableBox = /* @__PURE__ */ function(_React$Component) {
|
|
|
8706
8700
|
resizeHandles,
|
|
8707
8701
|
transformScale,
|
|
8708
8702
|
width: this.state.width
|
|
8709
|
-
}, /* @__PURE__ */ React$1.createElement("div", _extends$
|
|
8703
|
+
}, /* @__PURE__ */ React$1.createElement("div", _extends$1({}, props, {
|
|
8710
8704
|
style: _objectSpread$5(_objectSpread$5({}, style), {}, {
|
|
8711
8705
|
width: this.state.width + "px",
|
|
8712
8706
|
height: this.state.height + "px"
|
|
@@ -15194,77 +15188,86 @@ const Layer$1 = ({
|
|
|
15194
15188
|
options,
|
|
15195
15189
|
onChangeOptions,
|
|
15196
15190
|
showHeader,
|
|
15197
|
-
maxHeight
|
|
15191
|
+
maxHeight,
|
|
15192
|
+
testId
|
|
15198
15193
|
}) => {
|
|
15199
|
-
return /* @__PURE__ */ jsxs(
|
|
15200
|
-
|
|
15201
|
-
|
|
15202
|
-
|
|
15203
|
-
|
|
15204
|
-
|
|
15205
|
-
|
|
15206
|
-
|
|
15207
|
-
|
|
15208
|
-
|
|
15209
|
-
|
|
15210
|
-
|
|
15211
|
-
|
|
15212
|
-
|
|
15213
|
-
|
|
15214
|
-
|
|
15215
|
-
|
|
15216
|
-
|
|
15217
|
-
|
|
15218
|
-
|
|
15219
|
-
const next2 = options.map((option2) => ({
|
|
15220
|
-
...option2,
|
|
15221
|
-
selected: false
|
|
15222
|
-
}));
|
|
15223
|
-
onChangeOptions(evt, next2);
|
|
15224
|
-
},
|
|
15225
|
-
children: "Clear"
|
|
15226
|
-
}
|
|
15227
|
-
),
|
|
15228
|
-
/* @__PURE__ */ jsx(
|
|
15229
|
-
"a",
|
|
15230
|
-
{
|
|
15231
|
-
onClick: (evt) => {
|
|
15232
|
-
const next2 = options.map((option2) => ({
|
|
15233
|
-
...option2,
|
|
15234
|
-
selected: !(option2 == null ? void 0 : option2.selected)
|
|
15235
|
-
}));
|
|
15236
|
-
onChangeOptions(evt, next2);
|
|
15237
|
-
},
|
|
15238
|
-
children: "Invert"
|
|
15239
|
-
}
|
|
15240
|
-
)
|
|
15241
|
-
] }),
|
|
15242
|
-
/* @__PURE__ */ jsx(Divider, { margin: 0 })
|
|
15243
|
-
] }),
|
|
15244
|
-
options.map((option2, index2) => {
|
|
15245
|
-
switch (option2.type) {
|
|
15246
|
-
case DropdownType.HEADING:
|
|
15247
|
-
return /* @__PURE__ */ jsx(Heading$1, { label: option2.label }, index2);
|
|
15248
|
-
case DropdownType.DIVIDER:
|
|
15249
|
-
return /* @__PURE__ */ jsx(Divider, { margin: 0 }, index2);
|
|
15250
|
-
default:
|
|
15251
|
-
return /* @__PURE__ */ jsx(
|
|
15252
|
-
Option$1,
|
|
15253
|
-
{
|
|
15254
|
-
option: option2,
|
|
15255
|
-
onChange: (evt) => {
|
|
15256
|
-
const { value } = option2;
|
|
15257
|
-
const next2 = options.map(
|
|
15258
|
-
(option22) => option22.value !== value ? option22 : { ...option22, selected: !(option22 == null ? void 0 : option22.selected) }
|
|
15259
|
-
);
|
|
15260
|
-
onChangeOptions(evt, next2);
|
|
15194
|
+
return /* @__PURE__ */ jsxs(
|
|
15195
|
+
"div",
|
|
15196
|
+
{
|
|
15197
|
+
className: cx$2("menu", styles$r.menu),
|
|
15198
|
+
style: { maxHeight },
|
|
15199
|
+
"data-testid": testId ? `${testId}-option-dropdown-layer` : void 0,
|
|
15200
|
+
children: [
|
|
15201
|
+
showHeader && /* @__PURE__ */ jsxs(Fragment$1, { children: [
|
|
15202
|
+
/* @__PURE__ */ jsxs("div", { className: styles$r.header, children: [
|
|
15203
|
+
/* @__PURE__ */ jsx(
|
|
15204
|
+
"a",
|
|
15205
|
+
{
|
|
15206
|
+
onClick: (evt) => {
|
|
15207
|
+
const next2 = options.map((option2) => ({
|
|
15208
|
+
...option2,
|
|
15209
|
+
selected: true
|
|
15210
|
+
}));
|
|
15211
|
+
onChangeOptions(evt, next2);
|
|
15212
|
+
},
|
|
15213
|
+
children: "All"
|
|
15261
15214
|
}
|
|
15262
|
-
|
|
15263
|
-
|
|
15264
|
-
|
|
15265
|
-
|
|
15266
|
-
|
|
15267
|
-
|
|
15215
|
+
),
|
|
15216
|
+
/* @__PURE__ */ jsx(
|
|
15217
|
+
"a",
|
|
15218
|
+
{
|
|
15219
|
+
onClick: (evt) => {
|
|
15220
|
+
const next2 = options.map((option2) => ({
|
|
15221
|
+
...option2,
|
|
15222
|
+
selected: false
|
|
15223
|
+
}));
|
|
15224
|
+
onChangeOptions(evt, next2);
|
|
15225
|
+
},
|
|
15226
|
+
children: "Clear"
|
|
15227
|
+
}
|
|
15228
|
+
),
|
|
15229
|
+
/* @__PURE__ */ jsx(
|
|
15230
|
+
"a",
|
|
15231
|
+
{
|
|
15232
|
+
onClick: (evt) => {
|
|
15233
|
+
const next2 = options.map((option2) => ({
|
|
15234
|
+
...option2,
|
|
15235
|
+
selected: !(option2 == null ? void 0 : option2.selected)
|
|
15236
|
+
}));
|
|
15237
|
+
onChangeOptions(evt, next2);
|
|
15238
|
+
},
|
|
15239
|
+
children: "Invert"
|
|
15240
|
+
}
|
|
15241
|
+
)
|
|
15242
|
+
] }),
|
|
15243
|
+
/* @__PURE__ */ jsx(Divider, { margin: 0 })
|
|
15244
|
+
] }),
|
|
15245
|
+
options.map((option2, index2) => {
|
|
15246
|
+
switch (option2.type) {
|
|
15247
|
+
case DropdownType.HEADING:
|
|
15248
|
+
return /* @__PURE__ */ jsx(Heading$1, { label: option2.label }, index2);
|
|
15249
|
+
case DropdownType.DIVIDER:
|
|
15250
|
+
return /* @__PURE__ */ jsx(Divider, { margin: 0 }, index2);
|
|
15251
|
+
default:
|
|
15252
|
+
return /* @__PURE__ */ jsx(
|
|
15253
|
+
Option$1,
|
|
15254
|
+
{
|
|
15255
|
+
option: option2,
|
|
15256
|
+
onChange: (evt) => {
|
|
15257
|
+
const { value } = option2;
|
|
15258
|
+
const next2 = options.map(
|
|
15259
|
+
(option22) => option22.value !== value ? option22 : { ...option22, selected: !(option22 == null ? void 0 : option22.selected) }
|
|
15260
|
+
);
|
|
15261
|
+
onChangeOptions(evt, next2);
|
|
15262
|
+
}
|
|
15263
|
+
},
|
|
15264
|
+
index2
|
|
15265
|
+
);
|
|
15266
|
+
}
|
|
15267
|
+
})
|
|
15268
|
+
]
|
|
15269
|
+
}
|
|
15270
|
+
);
|
|
15268
15271
|
};
|
|
15269
15272
|
const OptionDropdown = ({
|
|
15270
15273
|
name: name2,
|
|
@@ -15273,12 +15276,15 @@ const OptionDropdown = ({
|
|
|
15273
15276
|
onChange,
|
|
15274
15277
|
small: small2 = false,
|
|
15275
15278
|
showHeader = true,
|
|
15276
|
-
maxHeight = "40vh"
|
|
15279
|
+
maxHeight = "40vh",
|
|
15280
|
+
testId
|
|
15277
15281
|
}) => {
|
|
15278
15282
|
return /* @__PURE__ */ jsx(
|
|
15279
15283
|
Menu,
|
|
15280
15284
|
{
|
|
15285
|
+
testId,
|
|
15281
15286
|
menu: {
|
|
15287
|
+
testId: testId ? `${testId}-menu-layer` : void 0,
|
|
15282
15288
|
small: small2,
|
|
15283
15289
|
label: label2,
|
|
15284
15290
|
trigger: TriggerType.DROP_DOWN_BUTTON,
|
|
@@ -15286,6 +15292,7 @@ const OptionDropdown = ({
|
|
|
15286
15292
|
sections: /* @__PURE__ */ jsx(
|
|
15287
15293
|
Layer$1,
|
|
15288
15294
|
{
|
|
15295
|
+
testId,
|
|
15289
15296
|
options,
|
|
15290
15297
|
onChangeOptions: (evt, nextOptions) => {
|
|
15291
15298
|
evt.target.name = name2;
|
|
@@ -15698,15 +15705,6 @@ const useWindowWidth = () => {
|
|
|
15698
15705
|
}, []);
|
|
15699
15706
|
return width2;
|
|
15700
15707
|
};
|
|
15701
|
-
function _extends$1() {
|
|
15702
|
-
return _extends$1 = Object.assign ? Object.assign.bind() : function(n2) {
|
|
15703
|
-
for (var e2 = 1; e2 < arguments.length; e2++) {
|
|
15704
|
-
var t = arguments[e2];
|
|
15705
|
-
for (var r2 in t) ({}).hasOwnProperty.call(t, r2) && (n2[r2] = t[r2]);
|
|
15706
|
-
}
|
|
15707
|
-
return n2;
|
|
15708
|
-
}, _extends$1.apply(null, arguments);
|
|
15709
|
-
}
|
|
15710
15708
|
function _assertThisInitialized(e2) {
|
|
15711
15709
|
if (void 0 === e2) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
15712
15710
|
return e2;
|
|
@@ -16079,7 +16077,7 @@ function createListComponent(_ref) {
|
|
|
16079
16077
|
className,
|
|
16080
16078
|
onScroll,
|
|
16081
16079
|
ref: this._outerRefSetter,
|
|
16082
|
-
style: _extends$
|
|
16080
|
+
style: _extends$4({
|
|
16083
16081
|
position: "relative",
|
|
16084
16082
|
height: height2,
|
|
16085
16083
|
width: width2,
|
|
@@ -48167,6 +48165,7 @@ var interopRequireDefault = { exports: {} };
|
|
|
48167
48165
|
module.exports = _interopRequireDefault2, module.exports.__esModule = true, module.exports["default"] = module.exports;
|
|
48168
48166
|
})(interopRequireDefault);
|
|
48169
48167
|
var interopRequireDefaultExports = interopRequireDefault.exports;
|
|
48168
|
+
const require$$2 = /* @__PURE__ */ getAugmentedNamespace(_extends$5);
|
|
48170
48169
|
const richTextToolbar = "_richTextToolbar_1gbkk_1";
|
|
48171
48170
|
const richTextToolbarContainer = "_richTextToolbarContainer_1gbkk_5";
|
|
48172
48171
|
const styles$h = {
|
|
@@ -49467,7 +49466,7 @@ var Handle$2 = /* @__PURE__ */ React$4.forwardRef(function(props, ref) {
|
|
|
49467
49466
|
}
|
|
49468
49467
|
};
|
|
49469
49468
|
var positionStyle = getDirectionStyle(direction, value, min, max);
|
|
49470
|
-
var handleNode = /* @__PURE__ */ React$4.createElement("div", _extends$
|
|
49469
|
+
var handleNode = /* @__PURE__ */ React$4.createElement("div", _extends$4({
|
|
49471
49470
|
ref,
|
|
49472
49471
|
className: cx$2(handlePrefixCls, (_classNames = {}, _defineProperty$7(_classNames, "".concat(handlePrefixCls, "-").concat(valueIndex + 1), range2), _defineProperty$7(_classNames, "".concat(handlePrefixCls, "-dragging"), dragging), _classNames)),
|
|
49473
49472
|
style: _objectSpread2$1(_objectSpread2$1({}, positionStyle), style),
|
|
@@ -49511,7 +49510,7 @@ var Handles = /* @__PURE__ */ React$4.forwardRef(function(props, ref) {
|
|
|
49511
49510
|
};
|
|
49512
49511
|
});
|
|
49513
49512
|
return /* @__PURE__ */ React$4.createElement(React$4.Fragment, null, values2.map(function(value, index2) {
|
|
49514
|
-
return /* @__PURE__ */ React$4.createElement(Handle$2, _extends$
|
|
49513
|
+
return /* @__PURE__ */ React$4.createElement(Handle$2, _extends$4({
|
|
49515
49514
|
ref: function ref2(node2) {
|
|
49516
49515
|
if (!node2) {
|
|
49517
49516
|
delete handlesRef.current[index2];
|
|
@@ -50881,7 +50880,7 @@ Object.defineProperty(Handle$1, "__esModule", {
|
|
|
50881
50880
|
value: true
|
|
50882
50881
|
});
|
|
50883
50882
|
var default_1 = Handle$1.default = void 0;
|
|
50884
|
-
var _extends2 = _interopRequireDefault(
|
|
50883
|
+
var _extends2 = _interopRequireDefault(require$$2);
|
|
50885
50884
|
var _objectSpread2 = _interopRequireDefault(requireObjectSpread2());
|
|
50886
50885
|
var _defineProperty2 = _interopRequireDefault(requireDefineProperty());
|
|
50887
50886
|
var _objectWithoutProperties2 = _interopRequireDefault(requireObjectWithoutProperties());
|