@true-engineering/true-react-common-ui-kit 3.26.0 → 3.27.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -1
- package/dist/components/List/List.styles.d.ts +3 -1
- package/dist/components/List/components/ListItem/ListItem.d.ts +2 -0
- package/dist/components/List/components/ListItem/ListItem.styles.d.ts +1 -1
- package/dist/components/Select/Select.d.ts +6 -6
- package/dist/true-react-common-ui-kit.js +890 -886
- package/dist/true-react-common-ui-kit.js.map +1 -1
- package/dist/true-react-common-ui-kit.umd.cjs +855 -851
- package/dist/true-react-common-ui-kit.umd.cjs.map +1 -1
- package/package.json +1 -1
- package/src/components/Input/Input.stories.tsx +5 -0
- package/src/components/Input/Input.tsx +3 -4
- package/src/components/List/List.stories.tsx +21 -1
- package/src/components/List/List.styles.ts +9 -37
- package/src/components/List/List.tsx +37 -12
- package/src/components/List/components/ListItem/ListItem.styles.ts +6 -2
- package/src/components/List/components/ListItem/ListItem.tsx +16 -5
- package/src/components/Select/Select.tsx +13 -13
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
(function(global2, factory) {
|
|
2
|
-
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("react"), require("react-jss"), require("@true-engineering/true-react-platform-helpers"), require("react-transition-group"), require("clsx"), require("hex-to-rgba"), require("react-input-mask"), require("date-fns"), require("react-overlays"), require("ts-debounce"), require("scroll-into-view-if-needed"), require("react-datepicker"), require("filesize"), require("
|
|
3
|
-
})(this, function(exports2, React, reactJss, trueReactPlatformHelpers, reactTransitionGroup, clsx, hexToRgba, InputMask, dateFns, reactOverlays, tsDebounce, scrollIntoViewIfNeeded, ReactDatePicker, filesize,
|
|
2
|
+
typeof exports === "object" && typeof module !== "undefined" ? factory(exports, require("react"), require("react-jss"), require("@true-engineering/true-react-platform-helpers"), require("react-transition-group"), require("clsx"), require("hex-to-rgba"), require("@floating-ui/react"), require("react-input-mask"), require("date-fns"), require("react-overlays"), require("ts-debounce"), require("scroll-into-view-if-needed"), require("react-datepicker"), require("filesize"), require("country-flag-icons"), require("react-remove-scroll")) : typeof define === "function" && define.amd ? define(["exports", "react", "react-jss", "@true-engineering/true-react-platform-helpers", "react-transition-group", "clsx", "hex-to-rgba", "@floating-ui/react", "react-input-mask", "date-fns", "react-overlays", "ts-debounce", "scroll-into-view-if-needed", "react-datepicker", "filesize", "country-flag-icons", "react-remove-scroll"], factory) : (global2 = typeof globalThis !== "undefined" ? globalThis : global2 || self, factory(global2.TrueReactKitUiKit = {}, global2.React, global2.reactJss, global2.trueReactPlatformHelpers, global2.reactTransitionGroup, global2.clsx, global2.hexToRgba, global2.react, global2.InputMask, global2.dateFns, global2.reactOverlays, global2.tsDebounce, global2.scrollIntoViewIfNeeded, global2.ReactDatePicker, global2.filesize, global2.countryFlagIcons, global2.reactRemoveScroll));
|
|
3
|
+
})(this, function(exports2, React, reactJss, trueReactPlatformHelpers, reactTransitionGroup, clsx, hexToRgba, react, InputMask, dateFns, reactOverlays, tsDebounce, scrollIntoViewIfNeeded, ReactDatePicker, filesize, countryFlagIcons, reactRemoveScroll) {
|
|
4
4
|
"use strict";
|
|
5
5
|
var jsxRuntime = { exports: {} };
|
|
6
6
|
var reactJsxRuntime_production_min = {};
|
|
@@ -7803,20 +7803,262 @@
|
|
|
7803
7803
|
type: icon
|
|
7804
7804
|
}) : icon;
|
|
7805
7805
|
};
|
|
7806
|
-
var
|
|
7807
|
-
var
|
|
7808
|
-
|
|
7809
|
-
|
|
7806
|
+
var DEFAULT_OFFSET = 6;
|
|
7807
|
+
var useStyles$U = createThemedStyles("WithPopup", {
|
|
7808
|
+
trigger: {
|
|
7809
|
+
width: "fit-content",
|
|
7810
|
+
cursor: "pointer"
|
|
7811
|
+
},
|
|
7812
|
+
disabled: {
|
|
7813
|
+
cursor: "default"
|
|
7814
|
+
},
|
|
7815
|
+
popup: {
|
|
7816
|
+
zIndex: 5,
|
|
7817
|
+
outline: "none"
|
|
7818
|
+
},
|
|
7819
|
+
animationEnd: {},
|
|
7820
|
+
animationStart: {},
|
|
7821
|
+
"dropdown-initial": {
|
|
7822
|
+
extend: "animationEnd"
|
|
7823
|
+
},
|
|
7824
|
+
"dropdown-open": {
|
|
7825
|
+
extend: "animationStart"
|
|
7826
|
+
},
|
|
7827
|
+
"dropdown-close": {
|
|
7828
|
+
visibility: "hidden",
|
|
7829
|
+
extend: "animationEnd"
|
|
7830
|
+
},
|
|
7831
|
+
"dropdown-unmounted": {
|
|
7832
|
+
extend: "animationEnd"
|
|
7833
|
+
}
|
|
7834
|
+
});
|
|
7835
|
+
function _array_like_to_array$n(arr, len) {
|
|
7836
|
+
if (len == null || len > arr.length)
|
|
7837
|
+
len = arr.length;
|
|
7838
|
+
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
7839
|
+
arr2[i] = arr[i];
|
|
7840
|
+
return arr2;
|
|
7841
|
+
}
|
|
7842
|
+
function _array_with_holes$n(arr) {
|
|
7843
|
+
if (Array.isArray(arr))
|
|
7844
|
+
return arr;
|
|
7845
|
+
}
|
|
7846
|
+
function _array_without_holes$7(arr) {
|
|
7847
|
+
if (Array.isArray(arr))
|
|
7848
|
+
return _array_like_to_array$n(arr);
|
|
7849
|
+
}
|
|
7850
|
+
function _define_property$_(obj, key, value) {
|
|
7851
|
+
if (key in obj) {
|
|
7852
|
+
Object.defineProperty(obj, key, {
|
|
7853
|
+
value,
|
|
7854
|
+
enumerable: true,
|
|
7855
|
+
configurable: true,
|
|
7856
|
+
writable: true
|
|
7857
|
+
});
|
|
7858
|
+
} else {
|
|
7859
|
+
obj[key] = value;
|
|
7860
|
+
}
|
|
7861
|
+
return obj;
|
|
7862
|
+
}
|
|
7863
|
+
function _iterable_to_array$7(iter) {
|
|
7864
|
+
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
7865
|
+
return Array.from(iter);
|
|
7866
|
+
}
|
|
7867
|
+
function _iterable_to_array_limit$n(arr, i) {
|
|
7868
|
+
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
7869
|
+
if (_i == null)
|
|
7870
|
+
return;
|
|
7871
|
+
var _arr = [];
|
|
7872
|
+
var _n = true;
|
|
7873
|
+
var _d = false;
|
|
7874
|
+
var _s, _e;
|
|
7875
|
+
try {
|
|
7876
|
+
for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
|
|
7877
|
+
_arr.push(_s.value);
|
|
7878
|
+
if (i && _arr.length === i)
|
|
7879
|
+
break;
|
|
7880
|
+
}
|
|
7881
|
+
} catch (err) {
|
|
7882
|
+
_d = true;
|
|
7883
|
+
_e = err;
|
|
7884
|
+
} finally {
|
|
7885
|
+
try {
|
|
7886
|
+
if (!_n && _i["return"] != null)
|
|
7887
|
+
_i["return"]();
|
|
7888
|
+
} finally {
|
|
7889
|
+
if (_d)
|
|
7890
|
+
throw _e;
|
|
7891
|
+
}
|
|
7892
|
+
}
|
|
7893
|
+
return _arr;
|
|
7894
|
+
}
|
|
7895
|
+
function _non_iterable_rest$n() {
|
|
7896
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
7897
|
+
}
|
|
7898
|
+
function _non_iterable_spread$7() {
|
|
7899
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
7900
|
+
}
|
|
7901
|
+
function _object_spread$Y(target) {
|
|
7902
|
+
for (var i = 1; i < arguments.length; i++) {
|
|
7903
|
+
var source = arguments[i] != null ? arguments[i] : {};
|
|
7904
|
+
var ownKeys2 = Object.keys(source);
|
|
7905
|
+
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
7906
|
+
ownKeys2 = ownKeys2.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
7907
|
+
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
7908
|
+
}));
|
|
7909
|
+
}
|
|
7910
|
+
ownKeys2.forEach(function(key) {
|
|
7911
|
+
_define_property$_(target, key, source[key]);
|
|
7912
|
+
});
|
|
7913
|
+
}
|
|
7914
|
+
return target;
|
|
7915
|
+
}
|
|
7916
|
+
function ownKeys$P(object, enumerableOnly) {
|
|
7917
|
+
var keys2 = Object.keys(object);
|
|
7918
|
+
if (Object.getOwnPropertySymbols) {
|
|
7919
|
+
var symbols = Object.getOwnPropertySymbols(object);
|
|
7920
|
+
if (enumerableOnly) {
|
|
7921
|
+
symbols = symbols.filter(function(sym) {
|
|
7922
|
+
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
7923
|
+
});
|
|
7924
|
+
}
|
|
7925
|
+
keys2.push.apply(keys2, symbols);
|
|
7926
|
+
}
|
|
7927
|
+
return keys2;
|
|
7928
|
+
}
|
|
7929
|
+
function _object_spread_props$P(target, source) {
|
|
7930
|
+
source = source != null ? source : {};
|
|
7931
|
+
if (Object.getOwnPropertyDescriptors) {
|
|
7932
|
+
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
7933
|
+
} else {
|
|
7934
|
+
ownKeys$P(Object(source)).forEach(function(key) {
|
|
7935
|
+
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
7936
|
+
});
|
|
7937
|
+
}
|
|
7938
|
+
return target;
|
|
7939
|
+
}
|
|
7940
|
+
function _sliced_to_array$n(arr, i) {
|
|
7941
|
+
return _array_with_holes$n(arr) || _iterable_to_array_limit$n(arr, i) || _unsupported_iterable_to_array$n(arr, i) || _non_iterable_rest$n();
|
|
7942
|
+
}
|
|
7943
|
+
function _to_consumable_array$7(arr) {
|
|
7944
|
+
return _array_without_holes$7(arr) || _iterable_to_array$7(arr) || _unsupported_iterable_to_array$n(arr) || _non_iterable_spread$7();
|
|
7945
|
+
}
|
|
7946
|
+
function _unsupported_iterable_to_array$n(o, minLen) {
|
|
7947
|
+
if (!o)
|
|
7948
|
+
return;
|
|
7949
|
+
if (typeof o === "string")
|
|
7950
|
+
return _array_like_to_array$n(o, minLen);
|
|
7951
|
+
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
7952
|
+
if (n === "Object" && o.constructor)
|
|
7953
|
+
n = o.constructor.name;
|
|
7954
|
+
if (n === "Map" || n === "Set")
|
|
7955
|
+
return Array.from(n);
|
|
7956
|
+
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
7957
|
+
return _array_like_to_array$n(o, minLen);
|
|
7958
|
+
}
|
|
7959
|
+
var WithPopup = function(param) {
|
|
7960
|
+
var trigger = param.trigger, children = param.children, _param_middlewares = param.middlewares, middlewares = _param_middlewares === void 0 ? [] : _param_middlewares, _param_eventType = param.eventType, eventType = _param_eventType === void 0 ? "click" : _param_eventType, _param_placement = param.placement, placement = _param_placement === void 0 ? eventType === "click" ? "bottom-end" : "top" : _param_placement, _param_hoverDelay = param.hoverDelay, hoverDelay = _param_hoverDelay === void 0 ? 0 : _param_hoverDelay, _param_popupOffset = param.popupOffset, popupOffset = _param_popupOffset === void 0 ? DEFAULT_OFFSET : _param_popupOffset, _param_shouldHideOnScroll = param.shouldHideOnScroll, shouldHideOnScroll = _param_shouldHideOnScroll === void 0 ? false : _param_shouldHideOnScroll, _param_shouldRenderInBody = param.shouldRenderInBody, shouldRenderInBody = _param_shouldRenderInBody === void 0 ? true : _param_shouldRenderInBody, _param_canBeFlipped = param.canBeFlipped, canBeFlipped = _param_canBeFlipped === void 0 ? true : _param_canBeFlipped, _param_isTriggerWrapped = param.isTriggerWrapped, isTriggerWrapped = _param_isTriggerWrapped === void 0 ? eventType === "hover" : _param_isTriggerWrapped, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, tweakStyles = param.tweakStyles, data = param.data, testId = param.testId, onToggle = param.onToggle;
|
|
7961
|
+
var classes = useStyles$U({
|
|
7962
|
+
theme: tweakStyles
|
|
7963
|
+
});
|
|
7964
|
+
var _useState = _sliced_to_array$n(React.useState(false), 2), isOpen = _useState[0], setIsOpen = _useState[1];
|
|
7965
|
+
var handleToggle = function(isActive, event) {
|
|
7966
|
+
event === null || event === void 0 ? void 0 : event.stopPropagation();
|
|
7967
|
+
if (!isDisabled) {
|
|
7968
|
+
onToggle === null || onToggle === void 0 ? void 0 : onToggle(isActive, event);
|
|
7969
|
+
setIsOpen(isActive);
|
|
7970
|
+
}
|
|
7971
|
+
};
|
|
7972
|
+
var handleClose = function(event) {
|
|
7973
|
+
handleToggle(false, event);
|
|
7974
|
+
};
|
|
7975
|
+
var _useFloating = react.useFloating({
|
|
7976
|
+
open: isOpen,
|
|
7977
|
+
middleware: [
|
|
7978
|
+
react.offset(popupOffset)
|
|
7979
|
+
].concat(_to_consumable_array$7(canBeFlipped ? [
|
|
7980
|
+
react.flip()
|
|
7981
|
+
] : []), _to_consumable_array$7(middlewares)),
|
|
7982
|
+
whileElementsMounted: react.autoUpdate,
|
|
7983
|
+
placement,
|
|
7984
|
+
onOpenChange: handleToggle
|
|
7985
|
+
}), refs = _useFloating.refs, floatingStyles = _useFloating.floatingStyles, context = _useFloating.context;
|
|
7986
|
+
var hover = react.useHover(context, {
|
|
7987
|
+
enabled: eventType === "hover",
|
|
7988
|
+
delay: typeof hoverDelay === "number" ? {
|
|
7989
|
+
open: hoverDelay,
|
|
7990
|
+
close: 0
|
|
7991
|
+
} : hoverDelay,
|
|
7992
|
+
handleClose: react.safePolygon()
|
|
7993
|
+
});
|
|
7994
|
+
var focus = react.useFocus(context, {
|
|
7995
|
+
enabled: eventType === "hover"
|
|
7996
|
+
});
|
|
7997
|
+
var click = react.useClick(context, {
|
|
7998
|
+
enabled: eventType === "click"
|
|
7999
|
+
});
|
|
8000
|
+
var dismiss = react.useDismiss(context, {
|
|
8001
|
+
enabled: eventType === "click",
|
|
8002
|
+
ancestorScroll: shouldHideOnScroll
|
|
8003
|
+
});
|
|
8004
|
+
var _useInteractions = react.useInteractions([
|
|
8005
|
+
hover,
|
|
8006
|
+
click,
|
|
8007
|
+
focus,
|
|
8008
|
+
dismiss
|
|
8009
|
+
]), getFloatingProps = _useInteractions.getFloatingProps, getReferenceProps = _useInteractions.getReferenceProps;
|
|
8010
|
+
var _useTransitionStatus = react.useTransitionStatus(context, {
|
|
8011
|
+
duration: {
|
|
8012
|
+
close: 500
|
|
8013
|
+
}
|
|
8014
|
+
}), isMounted = _useTransitionStatus.isMounted, status = _useTransitionStatus.status;
|
|
8015
|
+
var referenceProps = getReferenceProps({
|
|
8016
|
+
ref: refs.setReference
|
|
8017
|
+
});
|
|
8018
|
+
var triggerElement = trueReactPlatformHelpers.applyAction(trigger, _object_spread$Y({
|
|
8019
|
+
isActive: isOpen,
|
|
8020
|
+
isDisabled
|
|
8021
|
+
}, !isTriggerWrapped ? referenceProps : void 0));
|
|
8022
|
+
return /* @__PURE__ */ jsxs(Fragment, {
|
|
8023
|
+
children: [
|
|
8024
|
+
isTriggerWrapped ? /* @__PURE__ */ jsx("div", _object_spread_props$P(_object_spread$Y({
|
|
8025
|
+
className: clsx(classes.trigger, _define_property$_({}, classes.disabled, isDisabled))
|
|
8026
|
+
}, referenceProps, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
8027
|
+
children: triggerElement
|
|
8028
|
+
})) : triggerElement,
|
|
8029
|
+
isMounted && /* @__PURE__ */ jsx(react.FloatingPortal, {
|
|
8030
|
+
root: !shouldRenderInBody ? refs.reference.current : void 0,
|
|
8031
|
+
children: /* @__PURE__ */ jsx("div", _object_spread_props$P(_object_spread$Y({
|
|
8032
|
+
style: floatingStyles,
|
|
8033
|
+
className: classes.popup,
|
|
8034
|
+
ref: refs.setFloating
|
|
8035
|
+
}, getFloatingProps()), {
|
|
8036
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
8037
|
+
className: classes["dropdown-".concat(status)],
|
|
8038
|
+
children: trueReactPlatformHelpers.isFunction(children) ? children({
|
|
8039
|
+
onClose: handleClose
|
|
8040
|
+
}) : children
|
|
8041
|
+
})
|
|
8042
|
+
}))
|
|
8043
|
+
})
|
|
8044
|
+
]
|
|
8045
|
+
});
|
|
8046
|
+
};
|
|
8047
|
+
var ITEM_HORIZONTAL_PADDING = 16;
|
|
8048
|
+
var ICON_SIZE$1 = 20;
|
|
8049
|
+
var ICON_GAP = 12;
|
|
8050
|
+
var useStyles$T = createThemedStyles("ListItem", {
|
|
7810
8051
|
root: {
|
|
7811
8052
|
display: "flex",
|
|
7812
8053
|
alignItems: "center",
|
|
8054
|
+
gap: ICON_GAP,
|
|
7813
8055
|
boxSizing: "border-box",
|
|
7814
8056
|
fontSize: 16,
|
|
7815
8057
|
whiteSpace: "nowrap",
|
|
7816
8058
|
minHeight: 40,
|
|
7817
8059
|
padding: [
|
|
7818
8060
|
0,
|
|
7819
|
-
ITEM_HORIZONTAL_PADDING
|
|
8061
|
+
ITEM_HORIZONTAL_PADDING
|
|
7820
8062
|
],
|
|
7821
8063
|
transition: animations.defaultTransition,
|
|
7822
8064
|
transitionProperty: "background-color",
|
|
@@ -7824,6 +8066,7 @@
|
|
|
7824
8066
|
},
|
|
7825
8067
|
default: {},
|
|
7826
8068
|
destructive: {},
|
|
8069
|
+
focused: {},
|
|
7827
8070
|
disabledItem: {
|
|
7828
8071
|
cursor: "default"
|
|
7829
8072
|
},
|
|
@@ -7832,17 +8075,18 @@
|
|
|
7832
8075
|
backgroundColor: colors.BORDER_LIGHT
|
|
7833
8076
|
},
|
|
7834
8077
|
withIconGap: {
|
|
7835
|
-
paddingLeft: ITEM_HORIZONTAL_PADDING
|
|
8078
|
+
paddingLeft: ITEM_HORIZONTAL_PADDING + ICON_SIZE$1 + ICON_GAP
|
|
7836
8079
|
},
|
|
7837
8080
|
icon: {
|
|
7838
|
-
width: ICON_SIZE$
|
|
7839
|
-
height: ICON_SIZE$
|
|
7840
|
-
marginRight: ICON_GAP$1,
|
|
8081
|
+
width: ICON_SIZE$1,
|
|
8082
|
+
height: ICON_SIZE$1,
|
|
7841
8083
|
flexShrink: 0
|
|
7842
8084
|
},
|
|
7843
|
-
content: {
|
|
8085
|
+
content: {
|
|
8086
|
+
flexGrow: 1
|
|
8087
|
+
}
|
|
7844
8088
|
});
|
|
7845
|
-
function _define_property$
|
|
8089
|
+
function _define_property$Z(obj, key, value) {
|
|
7846
8090
|
if (key in obj) {
|
|
7847
8091
|
Object.defineProperty(obj, key, {
|
|
7848
8092
|
value,
|
|
@@ -7855,7 +8099,7 @@
|
|
|
7855
8099
|
}
|
|
7856
8100
|
return obj;
|
|
7857
8101
|
}
|
|
7858
|
-
function _object_spread$
|
|
8102
|
+
function _object_spread$X(target) {
|
|
7859
8103
|
for (var i = 1; i < arguments.length; i++) {
|
|
7860
8104
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
7861
8105
|
var ownKeys2 = Object.keys(source);
|
|
@@ -7865,12 +8109,12 @@
|
|
|
7865
8109
|
}));
|
|
7866
8110
|
}
|
|
7867
8111
|
ownKeys2.forEach(function(key) {
|
|
7868
|
-
_define_property$
|
|
8112
|
+
_define_property$Z(target, key, source[key]);
|
|
7869
8113
|
});
|
|
7870
8114
|
}
|
|
7871
8115
|
return target;
|
|
7872
8116
|
}
|
|
7873
|
-
function ownKeys$
|
|
8117
|
+
function ownKeys$O(object, enumerableOnly) {
|
|
7874
8118
|
var keys2 = Object.keys(object);
|
|
7875
8119
|
if (Object.getOwnPropertySymbols) {
|
|
7876
8120
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -7883,31 +8127,31 @@
|
|
|
7883
8127
|
}
|
|
7884
8128
|
return keys2;
|
|
7885
8129
|
}
|
|
7886
|
-
function _object_spread_props$
|
|
8130
|
+
function _object_spread_props$O(target, source) {
|
|
7887
8131
|
source = source != null ? source : {};
|
|
7888
8132
|
if (Object.getOwnPropertyDescriptors) {
|
|
7889
8133
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
7890
8134
|
} else {
|
|
7891
|
-
ownKeys$
|
|
8135
|
+
ownKeys$O(Object(source)).forEach(function(key) {
|
|
7892
8136
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
7893
8137
|
});
|
|
7894
8138
|
}
|
|
7895
8139
|
return target;
|
|
7896
8140
|
}
|
|
7897
8141
|
var ListItem = function(param) {
|
|
7898
|
-
var
|
|
7899
|
-
var classes = useStyles$
|
|
8142
|
+
var icon = param.icon, item = param.item, nestedItems = param.nestedItems, isDisabled = param.disabled, isFocused = param.isFocused, shouldDrawSpacerAbove = param.shouldDrawSpacerAbove, shouldDrawSpacerBelow = param.shouldDrawSpacerBelow, testId = param.testId, tweakStyles = param.tweakStyles, _param_view = param.view, view = _param_view === void 0 ? "default" : _param_view, withIconGap = param.withIconGap, data = param.data, onClick = param.onClick;
|
|
8143
|
+
var classes = useStyles$T({
|
|
7900
8144
|
theme: tweakStyles
|
|
7901
8145
|
});
|
|
7902
8146
|
var _obj2;
|
|
7903
|
-
return /* @__PURE__ */ jsxs(
|
|
8147
|
+
return /* @__PURE__ */ jsxs(Fragment, {
|
|
7904
8148
|
children: [
|
|
7905
8149
|
shouldDrawSpacerAbove && /* @__PURE__ */ jsx("div", {
|
|
7906
8150
|
className: classes.spacer
|
|
7907
8151
|
}),
|
|
7908
|
-
/* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
7909
|
-
className: clsx(classes.root, classes[view], (_obj2 = {}, _define_property$
|
|
7910
|
-
}, trueReactPlatformHelpers.addClickHandler(onClick, !isDisabled), trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(_object_spread_props$
|
|
8152
|
+
/* @__PURE__ */ jsxs("div", _object_spread_props$O(_object_spread$X({
|
|
8153
|
+
className: clsx(classes.root, classes[view], (_obj2 = {}, _define_property$Z(_obj2, classes.disabledItem, isDisabled), _define_property$Z(_obj2, classes.withIconGap, withIconGap), _define_property$Z(_obj2, classes.focused, isFocused), _obj2))
|
|
8154
|
+
}, trueReactPlatformHelpers.addClickHandler(onClick, !isDisabled), trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(_object_spread_props$O(_object_spread$X({}, data), {
|
|
7911
8155
|
disabled: isDisabled ? true : void 0
|
|
7912
8156
|
}))), {
|
|
7913
8157
|
children: [
|
|
@@ -7918,6 +8162,12 @@
|
|
|
7918
8162
|
/* @__PURE__ */ jsx("span", {
|
|
7919
8163
|
className: classes.content,
|
|
7920
8164
|
children: item
|
|
8165
|
+
}),
|
|
8166
|
+
trueReactPlatformHelpers.isArrayNotEmpty(nestedItems) && /* @__PURE__ */ jsx("span", {
|
|
8167
|
+
className: classes.icon,
|
|
8168
|
+
children: /* @__PURE__ */ jsx(Icon, {
|
|
8169
|
+
type: "chevron-right"
|
|
8170
|
+
})
|
|
7921
8171
|
})
|
|
7922
8172
|
]
|
|
7923
8173
|
})),
|
|
@@ -7927,10 +8177,7 @@
|
|
|
7927
8177
|
]
|
|
7928
8178
|
});
|
|
7929
8179
|
};
|
|
7930
|
-
var
|
|
7931
|
-
var ICON_SIZE$1 = 20;
|
|
7932
|
-
var ICON_GAP = 12;
|
|
7933
|
-
var useStyles$T = createThemedStyles("List", {
|
|
8180
|
+
var useStyles$S = createThemedStyles("List", {
|
|
7934
8181
|
root: {
|
|
7935
8182
|
minWidth: 180,
|
|
7936
8183
|
backgroundColor: colors.CLASSIC_WHITE,
|
|
@@ -7941,40 +8188,16 @@
|
|
|
7941
8188
|
listStyle: "none",
|
|
7942
8189
|
margin: 0
|
|
7943
8190
|
},
|
|
7944
|
-
|
|
7945
|
-
|
|
7946
|
-
|
|
7947
|
-
boxSizing: "border-box",
|
|
7948
|
-
fontSize: 16,
|
|
7949
|
-
whiteSpace: "nowrap",
|
|
7950
|
-
minHeight: 40,
|
|
7951
|
-
padding: [
|
|
7952
|
-
0,
|
|
7953
|
-
ITEM_HORIZONTAL_PADDING
|
|
7954
|
-
],
|
|
7955
|
-
transition: animations.defaultTransition,
|
|
7956
|
-
transitionProperty: "background-color",
|
|
7957
|
-
cursor: "pointer"
|
|
7958
|
-
},
|
|
7959
|
-
disabledItem: {
|
|
7960
|
-
cursor: "default"
|
|
7961
|
-
},
|
|
7962
|
-
spacer: {
|
|
7963
|
-
height: 1,
|
|
7964
|
-
backgroundColor: colors.BORDER_LIGHT
|
|
7965
|
-
},
|
|
7966
|
-
withIconGap: {
|
|
7967
|
-
paddingLeft: ITEM_HORIZONTAL_PADDING + ICON_SIZE$1 + ICON_GAP
|
|
7968
|
-
},
|
|
7969
|
-
icon: {
|
|
7970
|
-
width: ICON_SIZE$1,
|
|
7971
|
-
height: ICON_SIZE$1,
|
|
7972
|
-
marginRight: ICON_GAP,
|
|
7973
|
-
flexShrink: 0
|
|
7974
|
-
},
|
|
7975
|
-
content: {}
|
|
8191
|
+
nestedItems: {
|
|
8192
|
+
paddingLeft: 4
|
|
8193
|
+
}
|
|
7976
8194
|
});
|
|
7977
|
-
|
|
8195
|
+
var withPopupStyles = {
|
|
8196
|
+
trigger: {
|
|
8197
|
+
width: "100%"
|
|
8198
|
+
}
|
|
8199
|
+
};
|
|
8200
|
+
function _define_property$Y(obj, key, value) {
|
|
7978
8201
|
if (key in obj) {
|
|
7979
8202
|
Object.defineProperty(obj, key, {
|
|
7980
8203
|
value,
|
|
@@ -7987,7 +8210,7 @@
|
|
|
7987
8210
|
}
|
|
7988
8211
|
return obj;
|
|
7989
8212
|
}
|
|
7990
|
-
function _object_spread$
|
|
8213
|
+
function _object_spread$W(target) {
|
|
7991
8214
|
for (var i = 1; i < arguments.length; i++) {
|
|
7992
8215
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
7993
8216
|
var ownKeys2 = Object.keys(source);
|
|
@@ -7997,12 +8220,12 @@
|
|
|
7997
8220
|
}));
|
|
7998
8221
|
}
|
|
7999
8222
|
ownKeys2.forEach(function(key) {
|
|
8000
|
-
_define_property$
|
|
8223
|
+
_define_property$Y(target, key, source[key]);
|
|
8001
8224
|
});
|
|
8002
8225
|
}
|
|
8003
8226
|
return target;
|
|
8004
8227
|
}
|
|
8005
|
-
function ownKeys$
|
|
8228
|
+
function ownKeys$N(object, enumerableOnly) {
|
|
8006
8229
|
var keys2 = Object.keys(object);
|
|
8007
8230
|
if (Object.getOwnPropertySymbols) {
|
|
8008
8231
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -8015,12 +8238,12 @@
|
|
|
8015
8238
|
}
|
|
8016
8239
|
return keys2;
|
|
8017
8240
|
}
|
|
8018
|
-
function _object_spread_props$
|
|
8241
|
+
function _object_spread_props$N(target, source) {
|
|
8019
8242
|
source = source != null ? source : {};
|
|
8020
8243
|
if (Object.getOwnPropertyDescriptors) {
|
|
8021
8244
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
8022
8245
|
} else {
|
|
8023
|
-
ownKeys$
|
|
8246
|
+
ownKeys$N(Object(source)).forEach(function(key) {
|
|
8024
8247
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
8025
8248
|
});
|
|
8026
8249
|
}
|
|
@@ -8028,29 +8251,50 @@
|
|
|
8028
8251
|
}
|
|
8029
8252
|
var List = function(param) {
|
|
8030
8253
|
var items = param.items, testId = param.testId, data = param.data, tweakStyles = param.tweakStyles, onClick = param.onClick;
|
|
8031
|
-
var classes = useStyles$
|
|
8254
|
+
var classes = useStyles$S({
|
|
8032
8255
|
theme: tweakStyles
|
|
8033
8256
|
});
|
|
8034
8257
|
var handleItemClick = function(event, item) {
|
|
8035
8258
|
item.onClick(event);
|
|
8036
8259
|
onClick === null || onClick === void 0 ? void 0 : onClick(event);
|
|
8037
8260
|
};
|
|
8038
|
-
return /* @__PURE__ */ jsx("div", _object_spread_props$
|
|
8261
|
+
return /* @__PURE__ */ jsx("div", _object_spread_props$N(_object_spread$W({
|
|
8039
8262
|
className: classes.root
|
|
8040
8263
|
}, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
8041
8264
|
children: items.map(function(item, i) {
|
|
8042
|
-
|
|
8043
|
-
testId: trueReactPlatformHelpers.getTestId(testId, "item-".concat(i))
|
|
8265
|
+
var itemProps = _object_spread_props$N(_object_spread$W({
|
|
8266
|
+
testId: trueReactPlatformHelpers.getTestId(item.testId, "item-".concat(i))
|
|
8044
8267
|
}, item), {
|
|
8045
8268
|
onClick: function(event) {
|
|
8046
8269
|
return handleItemClick(event, item);
|
|
8047
8270
|
}
|
|
8048
|
-
})
|
|
8271
|
+
});
|
|
8272
|
+
return /* @__PURE__ */ jsx(React.Fragment, {
|
|
8273
|
+
children: trueReactPlatformHelpers.isArrayNotEmpty(item.nestedItems) ? /* @__PURE__ */ jsx(WithPopup, {
|
|
8274
|
+
eventType: "hover",
|
|
8275
|
+
tweakStyles: withPopupStyles,
|
|
8276
|
+
placement: "right-start",
|
|
8277
|
+
popupOffset: 0,
|
|
8278
|
+
shouldRenderInBody: false,
|
|
8279
|
+
trigger: function(param2) {
|
|
8280
|
+
var isActive = param2.isActive;
|
|
8281
|
+
return /* @__PURE__ */ jsx(ListItem, _object_spread_props$N(_object_spread$W({}, itemProps), {
|
|
8282
|
+
isFocused: isActive
|
|
8283
|
+
}));
|
|
8284
|
+
},
|
|
8285
|
+
children: /* @__PURE__ */ jsx("div", {
|
|
8286
|
+
className: classes.nestedItems,
|
|
8287
|
+
children: /* @__PURE__ */ jsx(List, {
|
|
8288
|
+
items: item.nestedItems
|
|
8289
|
+
})
|
|
8290
|
+
})
|
|
8291
|
+
}) : /* @__PURE__ */ jsx(ListItem, _object_spread$W({}, itemProps))
|
|
8292
|
+
}, i);
|
|
8049
8293
|
})
|
|
8050
8294
|
}));
|
|
8051
8295
|
};
|
|
8052
8296
|
var ANIMATION_TIMEOUT = 150;
|
|
8053
|
-
function _define_property$
|
|
8297
|
+
function _define_property$X(obj, key, value) {
|
|
8054
8298
|
if (key in obj) {
|
|
8055
8299
|
Object.defineProperty(obj, key, {
|
|
8056
8300
|
value,
|
|
@@ -8063,7 +8307,7 @@
|
|
|
8063
8307
|
}
|
|
8064
8308
|
return obj;
|
|
8065
8309
|
}
|
|
8066
|
-
function _object_spread$
|
|
8310
|
+
function _object_spread$V(target) {
|
|
8067
8311
|
for (var i = 1; i < arguments.length; i++) {
|
|
8068
8312
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
8069
8313
|
var ownKeys2 = Object.keys(source);
|
|
@@ -8073,12 +8317,12 @@
|
|
|
8073
8317
|
}));
|
|
8074
8318
|
}
|
|
8075
8319
|
ownKeys2.forEach(function(key) {
|
|
8076
|
-
_define_property$
|
|
8320
|
+
_define_property$X(target, key, source[key]);
|
|
8077
8321
|
});
|
|
8078
8322
|
}
|
|
8079
8323
|
return target;
|
|
8080
8324
|
}
|
|
8081
|
-
var useStyles$
|
|
8325
|
+
var useStyles$R = createThemedStyles("AccountInfo", _object_spread$V({
|
|
8082
8326
|
root: {
|
|
8083
8327
|
display: "flex"
|
|
8084
8328
|
},
|
|
@@ -8121,18 +8365,18 @@
|
|
|
8121
8365
|
height: 32
|
|
8122
8366
|
}
|
|
8123
8367
|
}, animations.slideUp));
|
|
8124
|
-
function _array_like_to_array$
|
|
8368
|
+
function _array_like_to_array$m(arr, len) {
|
|
8125
8369
|
if (len == null || len > arr.length)
|
|
8126
8370
|
len = arr.length;
|
|
8127
8371
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
8128
8372
|
arr2[i] = arr[i];
|
|
8129
8373
|
return arr2;
|
|
8130
8374
|
}
|
|
8131
|
-
function _array_with_holes$
|
|
8375
|
+
function _array_with_holes$m(arr) {
|
|
8132
8376
|
if (Array.isArray(arr))
|
|
8133
8377
|
return arr;
|
|
8134
8378
|
}
|
|
8135
|
-
function _define_property$
|
|
8379
|
+
function _define_property$W(obj, key, value) {
|
|
8136
8380
|
if (key in obj) {
|
|
8137
8381
|
Object.defineProperty(obj, key, {
|
|
8138
8382
|
value,
|
|
@@ -8145,7 +8389,7 @@
|
|
|
8145
8389
|
}
|
|
8146
8390
|
return obj;
|
|
8147
8391
|
}
|
|
8148
|
-
function _iterable_to_array_limit$
|
|
8392
|
+
function _iterable_to_array_limit$m(arr, i) {
|
|
8149
8393
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
8150
8394
|
if (_i == null)
|
|
8151
8395
|
return;
|
|
@@ -8173,10 +8417,10 @@
|
|
|
8173
8417
|
}
|
|
8174
8418
|
return _arr;
|
|
8175
8419
|
}
|
|
8176
|
-
function _non_iterable_rest$
|
|
8420
|
+
function _non_iterable_rest$m() {
|
|
8177
8421
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
8178
8422
|
}
|
|
8179
|
-
function _object_spread$
|
|
8423
|
+
function _object_spread$U(target) {
|
|
8180
8424
|
for (var i = 1; i < arguments.length; i++) {
|
|
8181
8425
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
8182
8426
|
var ownKeys2 = Object.keys(source);
|
|
@@ -8186,12 +8430,12 @@
|
|
|
8186
8430
|
}));
|
|
8187
8431
|
}
|
|
8188
8432
|
ownKeys2.forEach(function(key) {
|
|
8189
|
-
_define_property$
|
|
8433
|
+
_define_property$W(target, key, source[key]);
|
|
8190
8434
|
});
|
|
8191
8435
|
}
|
|
8192
8436
|
return target;
|
|
8193
8437
|
}
|
|
8194
|
-
function ownKeys$
|
|
8438
|
+
function ownKeys$M(object, enumerableOnly) {
|
|
8195
8439
|
var keys2 = Object.keys(object);
|
|
8196
8440
|
if (Object.getOwnPropertySymbols) {
|
|
8197
8441
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -8204,36 +8448,36 @@
|
|
|
8204
8448
|
}
|
|
8205
8449
|
return keys2;
|
|
8206
8450
|
}
|
|
8207
|
-
function _object_spread_props$
|
|
8451
|
+
function _object_spread_props$M(target, source) {
|
|
8208
8452
|
source = source != null ? source : {};
|
|
8209
8453
|
if (Object.getOwnPropertyDescriptors) {
|
|
8210
8454
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
8211
8455
|
} else {
|
|
8212
|
-
ownKeys$
|
|
8456
|
+
ownKeys$M(Object(source)).forEach(function(key) {
|
|
8213
8457
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
8214
8458
|
});
|
|
8215
8459
|
}
|
|
8216
8460
|
return target;
|
|
8217
8461
|
}
|
|
8218
|
-
function _sliced_to_array$
|
|
8219
|
-
return _array_with_holes$
|
|
8462
|
+
function _sliced_to_array$m(arr, i) {
|
|
8463
|
+
return _array_with_holes$m(arr) || _iterable_to_array_limit$m(arr, i) || _unsupported_iterable_to_array$m(arr, i) || _non_iterable_rest$m();
|
|
8220
8464
|
}
|
|
8221
|
-
function _unsupported_iterable_to_array$
|
|
8465
|
+
function _unsupported_iterable_to_array$m(o, minLen) {
|
|
8222
8466
|
if (!o)
|
|
8223
8467
|
return;
|
|
8224
8468
|
if (typeof o === "string")
|
|
8225
|
-
return _array_like_to_array$
|
|
8469
|
+
return _array_like_to_array$m(o, minLen);
|
|
8226
8470
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
8227
8471
|
if (n === "Object" && o.constructor)
|
|
8228
8472
|
n = o.constructor.name;
|
|
8229
8473
|
if (n === "Map" || n === "Set")
|
|
8230
8474
|
return Array.from(n);
|
|
8231
8475
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
8232
|
-
return _array_like_to_array$
|
|
8476
|
+
return _array_like_to_array$m(o, minLen);
|
|
8233
8477
|
}
|
|
8234
8478
|
var AccountInfo = function(param) {
|
|
8235
8479
|
var data = param.data, testId = param.testId, avatar = param.avatar, tweakStyles = param.tweakStyles, accountName = param.accountName, options = param.options;
|
|
8236
|
-
var classes = useStyles$
|
|
8480
|
+
var classes = useStyles$R({
|
|
8237
8481
|
theme: tweakStyles
|
|
8238
8482
|
});
|
|
8239
8483
|
var tweakListStyles = useTweakStyles({
|
|
@@ -8243,7 +8487,7 @@
|
|
|
8243
8487
|
});
|
|
8244
8488
|
var nameRef = React.useRef(null);
|
|
8245
8489
|
var dropdownRef = React.useRef(null);
|
|
8246
|
-
var _useState = _sliced_to_array$
|
|
8490
|
+
var _useState = _sliced_to_array$m(React.useState(false), 2), isMenuOpen = _useState[0], setIsMenuOpen = _useState[1];
|
|
8247
8491
|
var toggleMenu = function(event) {
|
|
8248
8492
|
event.stopPropagation();
|
|
8249
8493
|
setIsMenuOpen(function(v) {
|
|
@@ -8253,7 +8497,7 @@
|
|
|
8253
8497
|
useOnClickOutsideWithRef(dropdownRef, function() {
|
|
8254
8498
|
return setIsMenuOpen(false);
|
|
8255
8499
|
}, nameRef);
|
|
8256
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
8500
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$M(_object_spread$U({
|
|
8257
8501
|
className: classes.root
|
|
8258
8502
|
}, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
8259
8503
|
children: [
|
|
@@ -8303,7 +8547,7 @@
|
|
|
8303
8547
|
]
|
|
8304
8548
|
}));
|
|
8305
8549
|
};
|
|
8306
|
-
var useStyles$
|
|
8550
|
+
var useStyles$Q = createThemedStyles("AddButton", {
|
|
8307
8551
|
root: {
|
|
8308
8552
|
display: "flex",
|
|
8309
8553
|
alignItems: "center",
|
|
@@ -8329,7 +8573,7 @@
|
|
|
8329
8573
|
width: "100%"
|
|
8330
8574
|
}
|
|
8331
8575
|
});
|
|
8332
|
-
function _define_property$
|
|
8576
|
+
function _define_property$V(obj, key, value) {
|
|
8333
8577
|
if (key in obj) {
|
|
8334
8578
|
Object.defineProperty(obj, key, {
|
|
8335
8579
|
value,
|
|
@@ -8342,7 +8586,7 @@
|
|
|
8342
8586
|
}
|
|
8343
8587
|
return obj;
|
|
8344
8588
|
}
|
|
8345
|
-
function _object_spread$
|
|
8589
|
+
function _object_spread$T(target) {
|
|
8346
8590
|
for (var i = 1; i < arguments.length; i++) {
|
|
8347
8591
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
8348
8592
|
var ownKeys2 = Object.keys(source);
|
|
@@ -8352,12 +8596,12 @@
|
|
|
8352
8596
|
}));
|
|
8353
8597
|
}
|
|
8354
8598
|
ownKeys2.forEach(function(key) {
|
|
8355
|
-
_define_property$
|
|
8599
|
+
_define_property$V(target, key, source[key]);
|
|
8356
8600
|
});
|
|
8357
8601
|
}
|
|
8358
8602
|
return target;
|
|
8359
8603
|
}
|
|
8360
|
-
function ownKeys$
|
|
8604
|
+
function ownKeys$L(object, enumerableOnly) {
|
|
8361
8605
|
var keys2 = Object.keys(object);
|
|
8362
8606
|
if (Object.getOwnPropertySymbols) {
|
|
8363
8607
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -8370,12 +8614,12 @@
|
|
|
8370
8614
|
}
|
|
8371
8615
|
return keys2;
|
|
8372
8616
|
}
|
|
8373
|
-
function _object_spread_props$
|
|
8617
|
+
function _object_spread_props$L(target, source) {
|
|
8374
8618
|
source = source != null ? source : {};
|
|
8375
8619
|
if (Object.getOwnPropertyDescriptors) {
|
|
8376
8620
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
8377
8621
|
} else {
|
|
8378
|
-
ownKeys$
|
|
8622
|
+
ownKeys$L(Object(source)).forEach(function(key) {
|
|
8379
8623
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
8380
8624
|
});
|
|
8381
8625
|
}
|
|
@@ -8383,10 +8627,10 @@
|
|
|
8383
8627
|
}
|
|
8384
8628
|
var AddButton = function(param) {
|
|
8385
8629
|
var text = param.text, _param_type = param.type, type = _param_type === void 0 ? "button" : _param_type, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, onClick = param.onClick, _param_isFullWidth = param.isFullWidth, isFullWidth = _param_isFullWidth === void 0 ? false : _param_isFullWidth, data = param.data, testId = param.testId, tweakStyles = param.tweakStyles;
|
|
8386
|
-
var classes = useStyles$
|
|
8630
|
+
var classes = useStyles$Q({
|
|
8387
8631
|
theme: tweakStyles
|
|
8388
8632
|
});
|
|
8389
|
-
return /* @__PURE__ */ jsxs("button", _object_spread_props$
|
|
8633
|
+
return /* @__PURE__ */ jsxs("button", _object_spread_props$L(_object_spread$T({
|
|
8390
8634
|
type,
|
|
8391
8635
|
className: clsx(classes.root, isDisabled && classes.disabled, isFullWidth && classes.fullWidth),
|
|
8392
8636
|
onClick: !isDisabled ? onClick : void 0,
|
|
@@ -8405,7 +8649,7 @@
|
|
|
8405
8649
|
]
|
|
8406
8650
|
}));
|
|
8407
8651
|
};
|
|
8408
|
-
var useStyles$
|
|
8652
|
+
var useStyles$P = createThemedStyles("DotsPreloader", {
|
|
8409
8653
|
root: {
|
|
8410
8654
|
display: "flex",
|
|
8411
8655
|
gap: 4,
|
|
@@ -8451,7 +8695,7 @@
|
|
|
8451
8695
|
});
|
|
8452
8696
|
var DotsPreloader = function(param) {
|
|
8453
8697
|
var tweakStyles = param.tweakStyles;
|
|
8454
|
-
var classes = useStyles$
|
|
8698
|
+
var classes = useStyles$P({
|
|
8455
8699
|
theme: tweakStyles
|
|
8456
8700
|
});
|
|
8457
8701
|
return /* @__PURE__ */ jsx("div", {
|
|
@@ -8517,7 +8761,7 @@
|
|
|
8517
8761
|
]
|
|
8518
8762
|
});
|
|
8519
8763
|
};
|
|
8520
|
-
var useStyles$
|
|
8764
|
+
var useStyles$O = createThemedStyles("SvgPreloader", {
|
|
8521
8765
|
root: {
|
|
8522
8766
|
display: "flex",
|
|
8523
8767
|
width: "100%",
|
|
@@ -8527,7 +8771,7 @@
|
|
|
8527
8771
|
var SvgPreloader = function(param) {
|
|
8528
8772
|
var _param_type = param.type, type = _param_type === void 0 ? "default" : _param_type, tweakStyles = param.tweakStyles;
|
|
8529
8773
|
var _theme_preloaders;
|
|
8530
|
-
var classes = useStyles$
|
|
8774
|
+
var classes = useStyles$O({
|
|
8531
8775
|
theme: tweakStyles
|
|
8532
8776
|
});
|
|
8533
8777
|
var theme = React.useContext(ThemeContext).theme;
|
|
@@ -8541,7 +8785,7 @@
|
|
|
8541
8785
|
}
|
|
8542
8786
|
}) : /* @__PURE__ */ jsx(PreloaderIcon, {});
|
|
8543
8787
|
};
|
|
8544
|
-
var useStyles$
|
|
8788
|
+
var useStyles$N = createThemedStyles("ThemedPreloader", {
|
|
8545
8789
|
root: {
|
|
8546
8790
|
display: "flex"
|
|
8547
8791
|
},
|
|
@@ -8552,7 +8796,7 @@
|
|
|
8552
8796
|
color: "currentColor"
|
|
8553
8797
|
}
|
|
8554
8798
|
});
|
|
8555
|
-
function _define_property$
|
|
8799
|
+
function _define_property$U(obj, key, value) {
|
|
8556
8800
|
if (key in obj) {
|
|
8557
8801
|
Object.defineProperty(obj, key, {
|
|
8558
8802
|
value,
|
|
@@ -8565,7 +8809,7 @@
|
|
|
8565
8809
|
}
|
|
8566
8810
|
return obj;
|
|
8567
8811
|
}
|
|
8568
|
-
function _object_spread$
|
|
8812
|
+
function _object_spread$S(target) {
|
|
8569
8813
|
for (var i = 1; i < arguments.length; i++) {
|
|
8570
8814
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
8571
8815
|
var ownKeys2 = Object.keys(source);
|
|
@@ -8575,12 +8819,12 @@
|
|
|
8575
8819
|
}));
|
|
8576
8820
|
}
|
|
8577
8821
|
ownKeys2.forEach(function(key) {
|
|
8578
|
-
_define_property$
|
|
8822
|
+
_define_property$U(target, key, source[key]);
|
|
8579
8823
|
});
|
|
8580
8824
|
}
|
|
8581
8825
|
return target;
|
|
8582
8826
|
}
|
|
8583
|
-
function ownKeys$
|
|
8827
|
+
function ownKeys$K(object, enumerableOnly) {
|
|
8584
8828
|
var keys2 = Object.keys(object);
|
|
8585
8829
|
if (Object.getOwnPropertySymbols) {
|
|
8586
8830
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -8593,12 +8837,12 @@
|
|
|
8593
8837
|
}
|
|
8594
8838
|
return keys2;
|
|
8595
8839
|
}
|
|
8596
|
-
function _object_spread_props$
|
|
8840
|
+
function _object_spread_props$K(target, source) {
|
|
8597
8841
|
source = source != null ? source : {};
|
|
8598
8842
|
if (Object.getOwnPropertyDescriptors) {
|
|
8599
8843
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
8600
8844
|
} else {
|
|
8601
|
-
ownKeys$
|
|
8845
|
+
ownKeys$K(Object(source)).forEach(function(key) {
|
|
8602
8846
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
8603
8847
|
});
|
|
8604
8848
|
}
|
|
@@ -8606,7 +8850,7 @@
|
|
|
8606
8850
|
}
|
|
8607
8851
|
var ThemedPreloader = function(param) {
|
|
8608
8852
|
var _param_type = param.type, type = _param_type === void 0 ? "default" : _param_type, _param_useCurrentColor = param.useCurrentColor, useCurrentColor = _param_useCurrentColor === void 0 ? false : _param_useCurrentColor, data = param.data, testId = param.testId, tweakStyles = param.tweakStyles;
|
|
8609
|
-
var classes = useStyles$
|
|
8853
|
+
var classes = useStyles$N({
|
|
8610
8854
|
theme: tweakStyles
|
|
8611
8855
|
});
|
|
8612
8856
|
var tweakDotsPreloaderStyles = useTweakStyles({
|
|
@@ -8619,8 +8863,8 @@
|
|
|
8619
8863
|
className: "tweakSvgPreloader",
|
|
8620
8864
|
currentComponentName: "ThemedPreloader"
|
|
8621
8865
|
});
|
|
8622
|
-
return /* @__PURE__ */ jsx("div", _object_spread_props$
|
|
8623
|
-
className: clsx(classes.root, classes[type], _define_property$
|
|
8866
|
+
return /* @__PURE__ */ jsx("div", _object_spread_props$K(_object_spread$S({
|
|
8867
|
+
className: clsx(classes.root, classes[type], _define_property$U({}, classes.currentColor, useCurrentColor))
|
|
8624
8868
|
}, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
8625
8869
|
children: type === "dots" ? /* @__PURE__ */ jsx(DotsPreloader, {
|
|
8626
8870
|
tweakStyles: tweakDotsPreloaderStyles
|
|
@@ -8630,7 +8874,7 @@
|
|
|
8630
8874
|
})
|
|
8631
8875
|
}));
|
|
8632
8876
|
};
|
|
8633
|
-
var useStyles$
|
|
8877
|
+
var useStyles$M = createThemedStyles("Button", {
|
|
8634
8878
|
root: {
|
|
8635
8879
|
display: "flex",
|
|
8636
8880
|
justifyContent: "center",
|
|
@@ -8801,7 +9045,7 @@
|
|
|
8801
9045
|
var getPreloaderStyles = function(size) {
|
|
8802
9046
|
return size === "s" || size === "m" ? dotsPreloaderStyles : void 0;
|
|
8803
9047
|
};
|
|
8804
|
-
function _define_property$
|
|
9048
|
+
function _define_property$T(obj, key, value) {
|
|
8805
9049
|
if (key in obj) {
|
|
8806
9050
|
Object.defineProperty(obj, key, {
|
|
8807
9051
|
value,
|
|
@@ -8814,7 +9058,7 @@
|
|
|
8814
9058
|
}
|
|
8815
9059
|
return obj;
|
|
8816
9060
|
}
|
|
8817
|
-
function _object_spread$
|
|
9061
|
+
function _object_spread$R(target) {
|
|
8818
9062
|
for (var i = 1; i < arguments.length; i++) {
|
|
8819
9063
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
8820
9064
|
var ownKeys2 = Object.keys(source);
|
|
@@ -8824,12 +9068,12 @@
|
|
|
8824
9068
|
}));
|
|
8825
9069
|
}
|
|
8826
9070
|
ownKeys2.forEach(function(key) {
|
|
8827
|
-
_define_property$
|
|
9071
|
+
_define_property$T(target, key, source[key]);
|
|
8828
9072
|
});
|
|
8829
9073
|
}
|
|
8830
9074
|
return target;
|
|
8831
9075
|
}
|
|
8832
|
-
function ownKeys$
|
|
9076
|
+
function ownKeys$J(object, enumerableOnly) {
|
|
8833
9077
|
var keys2 = Object.keys(object);
|
|
8834
9078
|
if (Object.getOwnPropertySymbols) {
|
|
8835
9079
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -8842,12 +9086,12 @@
|
|
|
8842
9086
|
}
|
|
8843
9087
|
return keys2;
|
|
8844
9088
|
}
|
|
8845
|
-
function _object_spread_props$
|
|
9089
|
+
function _object_spread_props$J(target, source) {
|
|
8846
9090
|
source = source != null ? source : {};
|
|
8847
9091
|
if (Object.getOwnPropertyDescriptors) {
|
|
8848
9092
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
8849
9093
|
} else {
|
|
8850
|
-
ownKeys$
|
|
9094
|
+
ownKeys$J(Object(source)).forEach(function(key) {
|
|
8851
9095
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
8852
9096
|
});
|
|
8853
9097
|
}
|
|
@@ -8904,7 +9148,7 @@
|
|
|
8904
9148
|
"iconPosition",
|
|
8905
9149
|
"preloaderType"
|
|
8906
9150
|
]);
|
|
8907
|
-
var classes = useStyles$
|
|
9151
|
+
var classes = useStyles$M({
|
|
8908
9152
|
theme: tweakStyles
|
|
8909
9153
|
});
|
|
8910
9154
|
var tweakPreloaderStyles = useTweakStyles({
|
|
@@ -8917,16 +9161,16 @@
|
|
|
8917
9161
|
var hasChildren = trueReactPlatformHelpers.isReactNodeNotEmpty(children);
|
|
8918
9162
|
var hasNoAction = isDisabled || isLoading;
|
|
8919
9163
|
var _obj2, _obj1;
|
|
8920
|
-
return /* @__PURE__ */ jsxs("button", _object_spread_props$
|
|
9164
|
+
return /* @__PURE__ */ jsxs("button", _object_spread_props$J(_object_spread$R({
|
|
8921
9165
|
ref,
|
|
8922
9166
|
type,
|
|
8923
|
-
className: clsx(classes.root, classes[size], classes[view], (_obj2 = {}, _define_property$
|
|
9167
|
+
className: clsx(classes.root, classes[size], classes[view], (_obj2 = {}, _define_property$T(_obj2, classes.disabled, isDisabled), _define_property$T(_obj2, classes.fullWidth, isFullWidth), _define_property$T(_obj2, classes.inline, isInline), _define_property$T(_obj2, classes.active, isActive), _define_property$T(_obj2, classes.loading, isLoading), _define_property$T(_obj2, classes.onlyIcon, hasIcon && !hasChildren), _obj2)),
|
|
8924
9168
|
tabIndex: shouldSkipTabNavigation ? -1 : void 0,
|
|
8925
9169
|
disabled: hasNoAction
|
|
8926
9170
|
}, interactions, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
8927
9171
|
children: [
|
|
8928
9172
|
/* @__PURE__ */ jsxs("span", {
|
|
8929
|
-
className: clsx(classes.content, (_obj1 = {}, _define_property$
|
|
9173
|
+
className: clsx(classes.content, (_obj1 = {}, _define_property$T(_obj1, classes.iconFromRight, hasChildren && hasIcon && iconPosition === "right"), _define_property$T(_obj1, classes.iconFromLeft, hasChildren && hasIcon && iconPosition === "left"), _obj1)),
|
|
8930
9174
|
children: [
|
|
8931
9175
|
hasIcon && /* @__PURE__ */ jsx("span", {
|
|
8932
9176
|
className: classes.icon,
|
|
@@ -8949,7 +9193,7 @@
|
|
|
8949
9193
|
]
|
|
8950
9194
|
}));
|
|
8951
9195
|
});
|
|
8952
|
-
var useStyles$
|
|
9196
|
+
var useStyles$L = createThemedStyles("Checkbox", {
|
|
8953
9197
|
root: {
|
|
8954
9198
|
cursor: "pointer",
|
|
8955
9199
|
display: "flex",
|
|
@@ -8987,7 +9231,7 @@
|
|
|
8987
9231
|
flexDirection: "row-reverse"
|
|
8988
9232
|
}
|
|
8989
9233
|
});
|
|
8990
|
-
function _define_property$
|
|
9234
|
+
function _define_property$S(obj, key, value) {
|
|
8991
9235
|
if (key in obj) {
|
|
8992
9236
|
Object.defineProperty(obj, key, {
|
|
8993
9237
|
value,
|
|
@@ -9000,7 +9244,7 @@
|
|
|
9000
9244
|
}
|
|
9001
9245
|
return obj;
|
|
9002
9246
|
}
|
|
9003
|
-
function _object_spread$
|
|
9247
|
+
function _object_spread$Q(target) {
|
|
9004
9248
|
for (var i = 1; i < arguments.length; i++) {
|
|
9005
9249
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
9006
9250
|
var ownKeys2 = Object.keys(source);
|
|
@@ -9010,12 +9254,12 @@
|
|
|
9010
9254
|
}));
|
|
9011
9255
|
}
|
|
9012
9256
|
ownKeys2.forEach(function(key) {
|
|
9013
|
-
_define_property$
|
|
9257
|
+
_define_property$S(target, key, source[key]);
|
|
9014
9258
|
});
|
|
9015
9259
|
}
|
|
9016
9260
|
return target;
|
|
9017
9261
|
}
|
|
9018
|
-
function ownKeys$
|
|
9262
|
+
function ownKeys$I(object, enumerableOnly) {
|
|
9019
9263
|
var keys2 = Object.keys(object);
|
|
9020
9264
|
if (Object.getOwnPropertySymbols) {
|
|
9021
9265
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -9028,12 +9272,12 @@
|
|
|
9028
9272
|
}
|
|
9029
9273
|
return keys2;
|
|
9030
9274
|
}
|
|
9031
|
-
function _object_spread_props$
|
|
9275
|
+
function _object_spread_props$I(target, source) {
|
|
9032
9276
|
source = source != null ? source : {};
|
|
9033
9277
|
if (Object.getOwnPropertyDescriptors) {
|
|
9034
9278
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
9035
9279
|
} else {
|
|
9036
|
-
ownKeys$
|
|
9280
|
+
ownKeys$I(Object(source)).forEach(function(key) {
|
|
9037
9281
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
9038
9282
|
});
|
|
9039
9283
|
}
|
|
@@ -9041,7 +9285,7 @@
|
|
|
9041
9285
|
}
|
|
9042
9286
|
function Checkbox(param) {
|
|
9043
9287
|
var value = param.value, children = param.children, _param_isChecked = param.isChecked, isChecked = _param_isChecked === void 0 ? false : _param_isChecked, _param_isSemiChecked = param.isSemiChecked, isSemiChecked = _param_isSemiChecked === void 0 ? false : _param_isSemiChecked, _param_isInvalid = param.isInvalid, isInvalid = _param_isInvalid === void 0 ? false : _param_isInvalid, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, _param_isReadonly = param.isReadonly, isReadonly = _param_isReadonly === void 0 ? false : _param_isReadonly, _param_labelPosition = param.labelPosition, labelPosition = _param_labelPosition === void 0 ? "right" : _param_labelPosition, data = param.data, testId = param.testId, tweakStyles = param.tweakStyles, onSelect = param.onSelect;
|
|
9044
|
-
var classes = useStyles$
|
|
9288
|
+
var classes = useStyles$L({
|
|
9045
9289
|
theme: tweakStyles
|
|
9046
9290
|
});
|
|
9047
9291
|
var hasAction = !isDisabled && !isReadonly;
|
|
@@ -9053,11 +9297,11 @@
|
|
|
9053
9297
|
}, event);
|
|
9054
9298
|
};
|
|
9055
9299
|
var _obj2;
|
|
9056
|
-
return /* @__PURE__ */ jsxs("label", _object_spread_props$
|
|
9057
|
-
className: clsx(classes.root, (_obj2 = {}, _define_property$
|
|
9300
|
+
return /* @__PURE__ */ jsxs("label", _object_spread_props$I(_object_spread$Q({
|
|
9301
|
+
className: clsx(classes.root, (_obj2 = {}, _define_property$S(_obj2, classes.checked, isSelected), _define_property$S(_obj2, classes.invalid, isInvalid), _define_property$S(_obj2, classes.disabled, isDisabled), _define_property$S(_obj2, classes.labelPositionLeft, labelPosition === "left"), _obj2))
|
|
9058
9302
|
}, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
9059
9303
|
children: [
|
|
9060
|
-
/* @__PURE__ */ jsx("input", _object_spread$
|
|
9304
|
+
/* @__PURE__ */ jsx("input", _object_spread$Q({
|
|
9061
9305
|
className: classes.input,
|
|
9062
9306
|
type: "checkbox",
|
|
9063
9307
|
checked: isSelected,
|
|
@@ -9080,7 +9324,7 @@
|
|
|
9080
9324
|
]
|
|
9081
9325
|
}));
|
|
9082
9326
|
}
|
|
9083
|
-
var useStyles$
|
|
9327
|
+
var useStyles$K = createThemedStyles("CloseButton", {
|
|
9084
9328
|
root: {
|
|
9085
9329
|
width: 40,
|
|
9086
9330
|
height: 40,
|
|
@@ -9106,7 +9350,7 @@
|
|
|
9106
9350
|
}
|
|
9107
9351
|
}
|
|
9108
9352
|
});
|
|
9109
|
-
function _define_property$
|
|
9353
|
+
function _define_property$R(obj, key, value) {
|
|
9110
9354
|
if (key in obj) {
|
|
9111
9355
|
Object.defineProperty(obj, key, {
|
|
9112
9356
|
value,
|
|
@@ -9119,7 +9363,7 @@
|
|
|
9119
9363
|
}
|
|
9120
9364
|
return obj;
|
|
9121
9365
|
}
|
|
9122
|
-
function _object_spread$
|
|
9366
|
+
function _object_spread$P(target) {
|
|
9123
9367
|
for (var i = 1; i < arguments.length; i++) {
|
|
9124
9368
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
9125
9369
|
var ownKeys2 = Object.keys(source);
|
|
@@ -9129,12 +9373,12 @@
|
|
|
9129
9373
|
}));
|
|
9130
9374
|
}
|
|
9131
9375
|
ownKeys2.forEach(function(key) {
|
|
9132
|
-
_define_property$
|
|
9376
|
+
_define_property$R(target, key, source[key]);
|
|
9133
9377
|
});
|
|
9134
9378
|
}
|
|
9135
9379
|
return target;
|
|
9136
9380
|
}
|
|
9137
|
-
function ownKeys$
|
|
9381
|
+
function ownKeys$H(object, enumerableOnly) {
|
|
9138
9382
|
var keys2 = Object.keys(object);
|
|
9139
9383
|
if (Object.getOwnPropertySymbols) {
|
|
9140
9384
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -9147,12 +9391,12 @@
|
|
|
9147
9391
|
}
|
|
9148
9392
|
return keys2;
|
|
9149
9393
|
}
|
|
9150
|
-
function _object_spread_props$
|
|
9394
|
+
function _object_spread_props$H(target, source) {
|
|
9151
9395
|
source = source != null ? source : {};
|
|
9152
9396
|
if (Object.getOwnPropertyDescriptors) {
|
|
9153
9397
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
9154
9398
|
} else {
|
|
9155
|
-
ownKeys$
|
|
9399
|
+
ownKeys$H(Object(source)).forEach(function(key) {
|
|
9156
9400
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
9157
9401
|
});
|
|
9158
9402
|
}
|
|
@@ -9160,10 +9404,10 @@
|
|
|
9160
9404
|
}
|
|
9161
9405
|
var CloseButton = function(param) {
|
|
9162
9406
|
var tweakStyles = param.tweakStyles, testId = param.testId, data = param.data, _param_iconType = param.iconType, iconType = _param_iconType === void 0 ? "close" : _param_iconType, onClose = param.onClose;
|
|
9163
|
-
var classes = useStyles$
|
|
9407
|
+
var classes = useStyles$K({
|
|
9164
9408
|
theme: tweakStyles
|
|
9165
9409
|
});
|
|
9166
|
-
return /* @__PURE__ */ jsx("button", _object_spread_props$
|
|
9410
|
+
return /* @__PURE__ */ jsx("button", _object_spread_props$H(_object_spread$P({
|
|
9167
9411
|
type: "button",
|
|
9168
9412
|
className: classes.root,
|
|
9169
9413
|
onClick: onClose
|
|
@@ -9173,7 +9417,7 @@
|
|
|
9173
9417
|
})
|
|
9174
9418
|
}));
|
|
9175
9419
|
};
|
|
9176
|
-
var useStyles$
|
|
9420
|
+
var useStyles$J = createThemedStyles({
|
|
9177
9421
|
root: {
|
|
9178
9422
|
display: "flex",
|
|
9179
9423
|
flexWrap: "wrap"
|
|
@@ -9207,18 +9451,18 @@
|
|
|
9207
9451
|
]
|
|
9208
9452
|
}
|
|
9209
9453
|
});
|
|
9210
|
-
function _array_like_to_array$
|
|
9454
|
+
function _array_like_to_array$l(arr, len) {
|
|
9211
9455
|
if (len == null || len > arr.length)
|
|
9212
9456
|
len = arr.length;
|
|
9213
9457
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
9214
9458
|
arr2[i] = arr[i];
|
|
9215
9459
|
return arr2;
|
|
9216
9460
|
}
|
|
9217
|
-
function _array_with_holes$
|
|
9461
|
+
function _array_with_holes$l(arr) {
|
|
9218
9462
|
if (Array.isArray(arr))
|
|
9219
9463
|
return arr;
|
|
9220
9464
|
}
|
|
9221
|
-
function _iterable_to_array_limit$
|
|
9465
|
+
function _iterable_to_array_limit$l(arr, i) {
|
|
9222
9466
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
9223
9467
|
if (_i == null)
|
|
9224
9468
|
return;
|
|
@@ -9246,33 +9490,33 @@
|
|
|
9246
9490
|
}
|
|
9247
9491
|
return _arr;
|
|
9248
9492
|
}
|
|
9249
|
-
function _non_iterable_rest$
|
|
9493
|
+
function _non_iterable_rest$l() {
|
|
9250
9494
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
9251
9495
|
}
|
|
9252
|
-
function _sliced_to_array$
|
|
9253
|
-
return _array_with_holes$
|
|
9496
|
+
function _sliced_to_array$l(arr, i) {
|
|
9497
|
+
return _array_with_holes$l(arr) || _iterable_to_array_limit$l(arr, i) || _unsupported_iterable_to_array$l(arr, i) || _non_iterable_rest$l();
|
|
9254
9498
|
}
|
|
9255
|
-
function _unsupported_iterable_to_array$
|
|
9499
|
+
function _unsupported_iterable_to_array$l(o, minLen) {
|
|
9256
9500
|
if (!o)
|
|
9257
9501
|
return;
|
|
9258
9502
|
if (typeof o === "string")
|
|
9259
|
-
return _array_like_to_array$
|
|
9503
|
+
return _array_like_to_array$l(o, minLen);
|
|
9260
9504
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
9261
9505
|
if (n === "Object" && o.constructor)
|
|
9262
9506
|
n = o.constructor.name;
|
|
9263
9507
|
if (n === "Map" || n === "Set")
|
|
9264
9508
|
return Array.from(n);
|
|
9265
9509
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
9266
|
-
return _array_like_to_array$
|
|
9510
|
+
return _array_like_to_array$l(o, minLen);
|
|
9267
9511
|
}
|
|
9268
9512
|
var Colors = function() {
|
|
9269
|
-
var classes = useStyles$
|
|
9513
|
+
var classes = useStyles$J();
|
|
9270
9514
|
var theme = React.useContext(ThemeContext).theme;
|
|
9271
9515
|
var _theme_colors = theme.colors, colors2 = _theme_colors === void 0 ? {} : _theme_colors;
|
|
9272
9516
|
return /* @__PURE__ */ jsx("div", {
|
|
9273
9517
|
className: classes.root,
|
|
9274
9518
|
children: Object.entries(colors2).map(function(param) {
|
|
9275
|
-
var _param = _sliced_to_array$
|
|
9519
|
+
var _param = _sliced_to_array$l(param, 2), colorName = _param[0], color = _param[1];
|
|
9276
9520
|
var name = colorName.split("_").join(" ").toLowerCase();
|
|
9277
9521
|
return /* @__PURE__ */ jsxs("div", {
|
|
9278
9522
|
className: classes.colorCard,
|
|
@@ -9296,7 +9540,7 @@
|
|
|
9296
9540
|
})
|
|
9297
9541
|
});
|
|
9298
9542
|
};
|
|
9299
|
-
var useStyles$
|
|
9543
|
+
var useStyles$I = createThemedStyles("CssBaseline", {
|
|
9300
9544
|
"@global html, body": {
|
|
9301
9545
|
fontFamily: "Arial, sans-serif",
|
|
9302
9546
|
color: colors.FONT_MAIN,
|
|
@@ -9305,7 +9549,7 @@
|
|
|
9305
9549
|
},
|
|
9306
9550
|
root: {}
|
|
9307
9551
|
});
|
|
9308
|
-
function _define_property$
|
|
9552
|
+
function _define_property$Q(obj, key, value) {
|
|
9309
9553
|
if (key in obj) {
|
|
9310
9554
|
Object.defineProperty(obj, key, {
|
|
9311
9555
|
value,
|
|
@@ -9318,7 +9562,7 @@
|
|
|
9318
9562
|
}
|
|
9319
9563
|
return obj;
|
|
9320
9564
|
}
|
|
9321
|
-
function _object_spread$
|
|
9565
|
+
function _object_spread$O(target) {
|
|
9322
9566
|
for (var i = 1; i < arguments.length; i++) {
|
|
9323
9567
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
9324
9568
|
var ownKeys2 = Object.keys(source);
|
|
@@ -9328,24 +9572,24 @@
|
|
|
9328
9572
|
}));
|
|
9329
9573
|
}
|
|
9330
9574
|
ownKeys2.forEach(function(key) {
|
|
9331
|
-
_define_property$
|
|
9575
|
+
_define_property$Q(target, key, source[key]);
|
|
9332
9576
|
});
|
|
9333
9577
|
}
|
|
9334
9578
|
return target;
|
|
9335
9579
|
}
|
|
9336
9580
|
var CssBaseline = function(param) {
|
|
9337
9581
|
var data = param.data, testId = param.testId, tweakStyles = param.tweakStyles;
|
|
9338
|
-
var classes = useStyles$
|
|
9582
|
+
var classes = useStyles$I({
|
|
9339
9583
|
theme: tweakStyles
|
|
9340
9584
|
});
|
|
9341
|
-
return /* @__PURE__ */ jsx("div", _object_spread$
|
|
9585
|
+
return /* @__PURE__ */ jsx("div", _object_spread$O({
|
|
9342
9586
|
className: classes.root
|
|
9343
9587
|
}, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)));
|
|
9344
9588
|
};
|
|
9345
9589
|
var DEFAULT_SIZE = 6;
|
|
9346
9590
|
var PADDING_X$1 = 12;
|
|
9347
9591
|
var AUTOSIZE_MAX_WIDTH = 480;
|
|
9348
|
-
var useStyles$
|
|
9592
|
+
var useStyles$H = createThemedStyles("Input", {
|
|
9349
9593
|
root: {
|
|
9350
9594
|
width: "100%",
|
|
9351
9595
|
boxSizing: "border-box",
|
|
@@ -9619,14 +9863,14 @@
|
|
|
9619
9863
|
loading: {},
|
|
9620
9864
|
withUnits: {}
|
|
9621
9865
|
});
|
|
9622
|
-
function _array_like_to_array$
|
|
9866
|
+
function _array_like_to_array$k(arr, len) {
|
|
9623
9867
|
if (len == null || len > arr.length)
|
|
9624
9868
|
len = arr.length;
|
|
9625
9869
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
9626
9870
|
arr2[i] = arr[i];
|
|
9627
9871
|
return arr2;
|
|
9628
9872
|
}
|
|
9629
|
-
function _array_with_holes$
|
|
9873
|
+
function _array_with_holes$k(arr) {
|
|
9630
9874
|
if (Array.isArray(arr))
|
|
9631
9875
|
return arr;
|
|
9632
9876
|
}
|
|
@@ -9659,7 +9903,7 @@
|
|
|
9659
9903
|
});
|
|
9660
9904
|
};
|
|
9661
9905
|
}
|
|
9662
|
-
function _define_property$
|
|
9906
|
+
function _define_property$P(obj, key, value) {
|
|
9663
9907
|
if (key in obj) {
|
|
9664
9908
|
Object.defineProperty(obj, key, {
|
|
9665
9909
|
value,
|
|
@@ -9672,7 +9916,7 @@
|
|
|
9672
9916
|
}
|
|
9673
9917
|
return obj;
|
|
9674
9918
|
}
|
|
9675
|
-
function _iterable_to_array_limit$
|
|
9919
|
+
function _iterable_to_array_limit$k(arr, i) {
|
|
9676
9920
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
9677
9921
|
if (_i == null)
|
|
9678
9922
|
return;
|
|
@@ -9700,10 +9944,10 @@
|
|
|
9700
9944
|
}
|
|
9701
9945
|
return _arr;
|
|
9702
9946
|
}
|
|
9703
|
-
function _non_iterable_rest$
|
|
9947
|
+
function _non_iterable_rest$k() {
|
|
9704
9948
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
9705
9949
|
}
|
|
9706
|
-
function _object_spread$
|
|
9950
|
+
function _object_spread$N(target) {
|
|
9707
9951
|
for (var i = 1; i < arguments.length; i++) {
|
|
9708
9952
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
9709
9953
|
var ownKeys2 = Object.keys(source);
|
|
@@ -9713,12 +9957,12 @@
|
|
|
9713
9957
|
}));
|
|
9714
9958
|
}
|
|
9715
9959
|
ownKeys2.forEach(function(key) {
|
|
9716
|
-
_define_property$
|
|
9960
|
+
_define_property$P(target, key, source[key]);
|
|
9717
9961
|
});
|
|
9718
9962
|
}
|
|
9719
9963
|
return target;
|
|
9720
9964
|
}
|
|
9721
|
-
function ownKeys$
|
|
9965
|
+
function ownKeys$G(object, enumerableOnly) {
|
|
9722
9966
|
var keys2 = Object.keys(object);
|
|
9723
9967
|
if (Object.getOwnPropertySymbols) {
|
|
9724
9968
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -9731,12 +9975,12 @@
|
|
|
9731
9975
|
}
|
|
9732
9976
|
return keys2;
|
|
9733
9977
|
}
|
|
9734
|
-
function _object_spread_props$
|
|
9978
|
+
function _object_spread_props$G(target, source) {
|
|
9735
9979
|
source = source != null ? source : {};
|
|
9736
9980
|
if (Object.getOwnPropertyDescriptors) {
|
|
9737
9981
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
9738
9982
|
} else {
|
|
9739
|
-
ownKeys$
|
|
9983
|
+
ownKeys$G(Object(source)).forEach(function(key) {
|
|
9740
9984
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
9741
9985
|
});
|
|
9742
9986
|
}
|
|
@@ -9774,21 +10018,21 @@
|
|
|
9774
10018
|
}
|
|
9775
10019
|
return target;
|
|
9776
10020
|
}
|
|
9777
|
-
function _sliced_to_array$
|
|
9778
|
-
return _array_with_holes$
|
|
10021
|
+
function _sliced_to_array$k(arr, i) {
|
|
10022
|
+
return _array_with_holes$k(arr) || _iterable_to_array_limit$k(arr, i) || _unsupported_iterable_to_array$k(arr, i) || _non_iterable_rest$k();
|
|
9779
10023
|
}
|
|
9780
|
-
function _unsupported_iterable_to_array$
|
|
10024
|
+
function _unsupported_iterable_to_array$k(o, minLen) {
|
|
9781
10025
|
if (!o)
|
|
9782
10026
|
return;
|
|
9783
10027
|
if (typeof o === "string")
|
|
9784
|
-
return _array_like_to_array$
|
|
10028
|
+
return _array_like_to_array$k(o, minLen);
|
|
9785
10029
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
9786
10030
|
if (n === "Object" && o.constructor)
|
|
9787
10031
|
n = o.constructor.name;
|
|
9788
10032
|
if (n === "Map" || n === "Set")
|
|
9789
10033
|
return Array.from(n);
|
|
9790
10034
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
9791
|
-
return _array_like_to_array$
|
|
10035
|
+
return _array_like_to_array$k(o, minLen);
|
|
9792
10036
|
}
|
|
9793
10037
|
function _ts_generator$5(thisArg, body) {
|
|
9794
10038
|
var f, y, t, g, _ = {
|
|
@@ -9930,7 +10174,7 @@
|
|
|
9930
10174
|
"shouldAlwaysShowPlaceholder",
|
|
9931
10175
|
"beforeMaskedStateChange"
|
|
9932
10176
|
]);
|
|
9933
|
-
var classes = useStyles$
|
|
10177
|
+
var classes = useStyles$H({
|
|
9934
10178
|
theme: tweakStyles
|
|
9935
10179
|
});
|
|
9936
10180
|
var tweakPreloaderStyles = useTweakStyles({
|
|
@@ -9938,7 +10182,7 @@
|
|
|
9938
10182
|
className: "tweakPreloader",
|
|
9939
10183
|
currentComponentName: "Input"
|
|
9940
10184
|
});
|
|
9941
|
-
var _useState = _sliced_to_array$
|
|
10185
|
+
var _useState = _sliced_to_array$k(React.useState(false), 2), isFocused = _useState[0], setFocused = _useState[1];
|
|
9942
10186
|
var inputRef = React.useRef(null);
|
|
9943
10187
|
var handleChange = function(event) {
|
|
9944
10188
|
onChange(event.currentTarget.value, event);
|
|
@@ -9981,11 +10225,12 @@
|
|
|
9981
10225
|
var hasValue = value !== void 0 && value !== "";
|
|
9982
10226
|
var hasUnits = units !== void 0 && units !== "";
|
|
9983
10227
|
var hasLabel = trueReactPlatformHelpers.isReactNodeNotEmpty(label);
|
|
9984
|
-
var
|
|
10228
|
+
var isLabelActive = hasFocus && !isReadonly || hasValue || shouldAlwaysShowPlaceholder;
|
|
10229
|
+
var hasPlaceholder = (!hasLabel || isLabelActive) && trueReactPlatformHelpers.isStringNotEmpty(placeholder);
|
|
9985
10230
|
var shouldShowUnits = (hasValue || isFocused && !hasPlaceholder) && hasUnits;
|
|
9986
10231
|
var _obj2;
|
|
9987
|
-
var props = _object_spread_props$
|
|
9988
|
-
className: clsx(classes.input, (_obj2 = {}, _define_property$
|
|
10232
|
+
var props = _object_spread_props$G(_object_spread$N({}, inputProps, trueReactPlatformHelpers.addDataTestId(testId)), {
|
|
10233
|
+
className: clsx(classes.input, (_obj2 = {}, _define_property$P(_obj2, classes.withFloatingLabel, hasFloatingLabel && hasLabel), _define_property$P(_obj2, classes.withIcons, hasControls), _define_property$P(_obj2, classes.withControls, hasControls), _define_property$P(_obj2, classes.withUnits, shouldShowUnits), _define_property$P(_obj2, classes.floatingLabelWithoutPadding, hasFloatingLabel && hasLabel && border === "bottom"), _obj2)),
|
|
9989
10234
|
onFocus: handleFocus,
|
|
9990
10235
|
onBlur: handleBlur,
|
|
9991
10236
|
onChange: handleChange,
|
|
@@ -10001,14 +10246,14 @@
|
|
|
10001
10246
|
return /* @__PURE__ */ jsxs("div", {
|
|
10002
10247
|
className: classes.root,
|
|
10003
10248
|
children: [
|
|
10004
|
-
/* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
10005
|
-
className: clsx(classes.inputWrapper, (_obj1 = {}, _define_property$
|
|
10249
|
+
/* @__PURE__ */ jsxs("div", _object_spread_props$G(_object_spread$N({
|
|
10250
|
+
className: clsx(classes.inputWrapper, (_obj1 = {}, _define_property$P(_obj1, classes.required, isRequired && !hasRequiredLabel), _define_property$P(_obj1, classes.invalid, isInvalid), _define_property$P(_obj1, classes.focused, hasFocus), _define_property$P(_obj1, classes.disabled, isDisabled), _define_property$P(_obj1, classes.autosize, isAutoSizeable), _obj1), inlineStyle !== void 0 && classes[inlineStyle], border !== void 0 && classes["border-".concat(border)]),
|
|
10006
10251
|
"data-value": isAutoSizeable ? value : void 0
|
|
10007
10252
|
}, addDataAttributes(data)), {
|
|
10008
10253
|
children: [
|
|
10009
|
-
mask === void 0 ? /* @__PURE__ */ jsx("input", _object_spread$
|
|
10254
|
+
mask === void 0 ? /* @__PURE__ */ jsx("input", _object_spread$N({
|
|
10010
10255
|
ref: ref !== null && ref !== void 0 ? ref : inputRef
|
|
10011
|
-
}, props)) : /* @__PURE__ */ jsx(InputMask, _object_spread$
|
|
10256
|
+
}, props)) : /* @__PURE__ */ jsx(InputMask, _object_spread$N({
|
|
10012
10257
|
ref: ref !== null && ref !== void 0 ? ref : inputRef,
|
|
10013
10258
|
mask,
|
|
10014
10259
|
maskPlaceholder,
|
|
@@ -10016,12 +10261,12 @@
|
|
|
10016
10261
|
beforeMaskedStateChange
|
|
10017
10262
|
}, props)),
|
|
10018
10263
|
hasLabel && /* @__PURE__ */ jsx("span", {
|
|
10019
|
-
className: clsx(classes.label, (_obj22 = {}, _define_property$
|
|
10020
|
-
_define_property$
|
|
10264
|
+
className: clsx(classes.label, (_obj22 = {}, _define_property$P(_obj22, classes.invalidLabel, isInvalid), _define_property$P(_obj22, classes.requiredLabel, hasRequiredLabel && !isRequired), _define_property$P(_obj22, classes.activeLabel, isLabelActive), _define_property$P(_obj22, classes.floating, hasFloatingLabel), // Обсуждаемо, сделал так, потому что не хочется создавать новую пропсу, на каждый чих в стилях
|
|
10265
|
+
_define_property$P(_obj22, classes.floatingWithoutPadding, hasFloatingLabel && border === "bottom"), _obj22)),
|
|
10021
10266
|
children: label
|
|
10022
10267
|
}),
|
|
10023
10268
|
shouldShowUnits && /* @__PURE__ */ jsxs("div", {
|
|
10024
|
-
className: clsx(classes.unitsWrapper, _define_property$
|
|
10269
|
+
className: clsx(classes.unitsWrapper, _define_property$P({}, classes.withFloatingLabel, hasFloatingLabel && hasLabel)),
|
|
10025
10270
|
children: [
|
|
10026
10271
|
/* @__PURE__ */ jsx("span", {
|
|
10027
10272
|
className: classes.fakeValue,
|
|
@@ -10053,7 +10298,7 @@
|
|
|
10053
10298
|
})
|
|
10054
10299
|
}),
|
|
10055
10300
|
trueReactPlatformHelpers.isReactNodeNotEmpty(iconType) && /* @__PURE__ */ jsx("div", {
|
|
10056
|
-
className: clsx(classes.inputIcon, _define_property$
|
|
10301
|
+
className: clsx(classes.inputIcon, _define_property$P({}, classes.activeIcon, !isDisabled && onIconClick !== void 0)),
|
|
10057
10302
|
onClick: !isDisabled ? onIconClick : void 0,
|
|
10058
10303
|
children: renderIcon(iconType)
|
|
10059
10304
|
})
|
|
@@ -10074,7 +10319,7 @@
|
|
|
10074
10319
|
});
|
|
10075
10320
|
var EMPTY_DATE_INPUT_VALUE = "__.__.____";
|
|
10076
10321
|
var EMPTY_DATE_RANGE_INPUT_VALUE = "".concat(EMPTY_DATE_INPUT_VALUE, " - ").concat(EMPTY_DATE_INPUT_VALUE);
|
|
10077
|
-
var useStyles$
|
|
10322
|
+
var useStyles$G = createThemedStyles("DateInput", {
|
|
10078
10323
|
root: {
|
|
10079
10324
|
width: "100%",
|
|
10080
10325
|
height: "100%",
|
|
@@ -10082,7 +10327,7 @@
|
|
|
10082
10327
|
position: "relative"
|
|
10083
10328
|
}
|
|
10084
10329
|
});
|
|
10085
|
-
function _define_property$
|
|
10330
|
+
function _define_property$O(obj, key, value) {
|
|
10086
10331
|
if (key in obj) {
|
|
10087
10332
|
Object.defineProperty(obj, key, {
|
|
10088
10333
|
value,
|
|
@@ -10095,7 +10340,7 @@
|
|
|
10095
10340
|
}
|
|
10096
10341
|
return obj;
|
|
10097
10342
|
}
|
|
10098
|
-
function _object_spread$
|
|
10343
|
+
function _object_spread$M(target) {
|
|
10099
10344
|
for (var i = 1; i < arguments.length; i++) {
|
|
10100
10345
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
10101
10346
|
var ownKeys2 = Object.keys(source);
|
|
@@ -10105,12 +10350,12 @@
|
|
|
10105
10350
|
}));
|
|
10106
10351
|
}
|
|
10107
10352
|
ownKeys2.forEach(function(key) {
|
|
10108
|
-
_define_property$
|
|
10353
|
+
_define_property$O(target, key, source[key]);
|
|
10109
10354
|
});
|
|
10110
10355
|
}
|
|
10111
10356
|
return target;
|
|
10112
10357
|
}
|
|
10113
|
-
function ownKeys$
|
|
10358
|
+
function ownKeys$F(object, enumerableOnly) {
|
|
10114
10359
|
var keys2 = Object.keys(object);
|
|
10115
10360
|
if (Object.getOwnPropertySymbols) {
|
|
10116
10361
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -10123,12 +10368,12 @@
|
|
|
10123
10368
|
}
|
|
10124
10369
|
return keys2;
|
|
10125
10370
|
}
|
|
10126
|
-
function _object_spread_props$
|
|
10371
|
+
function _object_spread_props$F(target, source) {
|
|
10127
10372
|
source = source != null ? source : {};
|
|
10128
10373
|
if (Object.getOwnPropertyDescriptors) {
|
|
10129
10374
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
10130
10375
|
} else {
|
|
10131
|
-
ownKeys$
|
|
10376
|
+
ownKeys$F(Object(source)).forEach(function(key) {
|
|
10132
10377
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
10133
10378
|
});
|
|
10134
10379
|
}
|
|
@@ -10180,7 +10425,7 @@
|
|
|
10180
10425
|
"onClick",
|
|
10181
10426
|
"onChange"
|
|
10182
10427
|
]);
|
|
10183
|
-
var classes = useStyles$
|
|
10428
|
+
var classes = useStyles$G({
|
|
10184
10429
|
theme: tweakStyles
|
|
10185
10430
|
});
|
|
10186
10431
|
var tweakInputStyles = useTweakStyles({
|
|
@@ -10207,11 +10452,11 @@
|
|
|
10207
10452
|
}
|
|
10208
10453
|
onChange === null || onChange === void 0 ? void 0 : onChange(event, value);
|
|
10209
10454
|
};
|
|
10210
|
-
return /* @__PURE__ */ jsx("div", _object_spread_props$
|
|
10455
|
+
return /* @__PURE__ */ jsx("div", _object_spread_props$F(_object_spread$M({
|
|
10211
10456
|
className: clsx(classes.root, className),
|
|
10212
10457
|
onClick
|
|
10213
10458
|
}, addDataAttributes(data)), {
|
|
10214
|
-
children: /* @__PURE__ */ jsx(Input, _object_spread_props$
|
|
10459
|
+
children: /* @__PURE__ */ jsx(Input, _object_spread_props$F(_object_spread$M({}, inputProps), {
|
|
10215
10460
|
ref,
|
|
10216
10461
|
value: isRange ? "".concat(startDate).concat(endDate) : date,
|
|
10217
10462
|
mask: mask !== null && mask !== void 0 ? mask : isRange ? "99.99.9999 - 99.99.9999" : "99.99.9999",
|
|
@@ -10224,7 +10469,7 @@
|
|
|
10224
10469
|
});
|
|
10225
10470
|
const reactDatepicker = "";
|
|
10226
10471
|
var LEFT_PADDING = 44;
|
|
10227
|
-
var useStyles$
|
|
10472
|
+
var useStyles$F = createThemedStyles("SearchInput", {
|
|
10228
10473
|
root: {
|
|
10229
10474
|
position: "relative"
|
|
10230
10475
|
},
|
|
@@ -10261,7 +10506,7 @@
|
|
|
10261
10506
|
fontSize: 14
|
|
10262
10507
|
}
|
|
10263
10508
|
};
|
|
10264
|
-
function _define_property$
|
|
10509
|
+
function _define_property$N(obj, key, value) {
|
|
10265
10510
|
if (key in obj) {
|
|
10266
10511
|
Object.defineProperty(obj, key, {
|
|
10267
10512
|
value,
|
|
@@ -10274,7 +10519,7 @@
|
|
|
10274
10519
|
}
|
|
10275
10520
|
return obj;
|
|
10276
10521
|
}
|
|
10277
|
-
function _object_spread$
|
|
10522
|
+
function _object_spread$L(target) {
|
|
10278
10523
|
for (var i = 1; i < arguments.length; i++) {
|
|
10279
10524
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
10280
10525
|
var ownKeys2 = Object.keys(source);
|
|
@@ -10284,12 +10529,12 @@
|
|
|
10284
10529
|
}));
|
|
10285
10530
|
}
|
|
10286
10531
|
ownKeys2.forEach(function(key) {
|
|
10287
|
-
_define_property$
|
|
10532
|
+
_define_property$N(target, key, source[key]);
|
|
10288
10533
|
});
|
|
10289
10534
|
}
|
|
10290
10535
|
return target;
|
|
10291
10536
|
}
|
|
10292
|
-
function ownKeys$
|
|
10537
|
+
function ownKeys$E(object, enumerableOnly) {
|
|
10293
10538
|
var keys2 = Object.keys(object);
|
|
10294
10539
|
if (Object.getOwnPropertySymbols) {
|
|
10295
10540
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -10302,12 +10547,12 @@
|
|
|
10302
10547
|
}
|
|
10303
10548
|
return keys2;
|
|
10304
10549
|
}
|
|
10305
|
-
function _object_spread_props$
|
|
10550
|
+
function _object_spread_props$E(target, source) {
|
|
10306
10551
|
source = source != null ? source : {};
|
|
10307
10552
|
if (Object.getOwnPropertyDescriptors) {
|
|
10308
10553
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
10309
10554
|
} else {
|
|
10310
|
-
ownKeys$
|
|
10555
|
+
ownKeys$E(Object(source)).forEach(function(key) {
|
|
10311
10556
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
10312
10557
|
});
|
|
10313
10558
|
}
|
|
@@ -10352,7 +10597,7 @@
|
|
|
10352
10597
|
"testId",
|
|
10353
10598
|
"data"
|
|
10354
10599
|
]);
|
|
10355
|
-
var classes = useStyles$
|
|
10600
|
+
var classes = useStyles$F({
|
|
10356
10601
|
theme: tweakStyles
|
|
10357
10602
|
});
|
|
10358
10603
|
var tweakInputStyles = useTweakStyles({
|
|
@@ -10361,7 +10606,7 @@
|
|
|
10361
10606
|
className: "tweakInput",
|
|
10362
10607
|
currentComponentName: "SearchInput"
|
|
10363
10608
|
});
|
|
10364
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
10609
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$E(_object_spread$L({
|
|
10365
10610
|
className: classes.root
|
|
10366
10611
|
}, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
10367
10612
|
children: [
|
|
@@ -10371,7 +10616,7 @@
|
|
|
10371
10616
|
type: "search"
|
|
10372
10617
|
})
|
|
10373
10618
|
}),
|
|
10374
|
-
/* @__PURE__ */ jsx(Input, _object_spread$
|
|
10619
|
+
/* @__PURE__ */ jsx(Input, _object_spread$L({
|
|
10375
10620
|
isClearable,
|
|
10376
10621
|
isActive: props.value !== "" && props.value !== void 0,
|
|
10377
10622
|
testId: trueReactPlatformHelpers.getTestId(testId, "input"),
|
|
@@ -10419,7 +10664,7 @@
|
|
|
10419
10664
|
_defineProperties(Constructor, staticProps);
|
|
10420
10665
|
return Constructor;
|
|
10421
10666
|
}
|
|
10422
|
-
function _define_property$
|
|
10667
|
+
function _define_property$M(obj, key, value) {
|
|
10423
10668
|
if (key in obj) {
|
|
10424
10669
|
Object.defineProperty(obj, key, {
|
|
10425
10670
|
value,
|
|
@@ -10452,7 +10697,7 @@
|
|
|
10452
10697
|
if (superClass)
|
|
10453
10698
|
_set_prototype_of(subClass, superClass);
|
|
10454
10699
|
}
|
|
10455
|
-
function _object_spread$
|
|
10700
|
+
function _object_spread$K(target) {
|
|
10456
10701
|
for (var i = 1; i < arguments.length; i++) {
|
|
10457
10702
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
10458
10703
|
var ownKeys2 = Object.keys(source);
|
|
@@ -10462,7 +10707,7 @@
|
|
|
10462
10707
|
}));
|
|
10463
10708
|
}
|
|
10464
10709
|
ownKeys2.forEach(function(key) {
|
|
10465
|
-
_define_property$
|
|
10710
|
+
_define_property$M(target, key, source[key]);
|
|
10466
10711
|
});
|
|
10467
10712
|
}
|
|
10468
10713
|
return target;
|
|
@@ -10551,8 +10796,8 @@
|
|
|
10551
10796
|
_class_call_check(this, ScrollIntoViewIfNeeded2);
|
|
10552
10797
|
var _this;
|
|
10553
10798
|
_this = _super.apply(this, arguments);
|
|
10554
|
-
_define_property$
|
|
10555
|
-
_define_property$
|
|
10799
|
+
_define_property$M(_assert_this_initialized(_this), "node", React.createRef());
|
|
10800
|
+
_define_property$M(_assert_this_initialized(_this), "handleScrollIntoViewIfNeeded", function() {
|
|
10556
10801
|
var options = _this.props.options;
|
|
10557
10802
|
var _this_node = _this.node, node = _this_node.current;
|
|
10558
10803
|
if (node) {
|
|
@@ -10594,7 +10839,7 @@
|
|
|
10594
10839
|
"children",
|
|
10595
10840
|
"options"
|
|
10596
10841
|
]);
|
|
10597
|
-
return React.createElement(elementType !== null && elementType !== void 0 ? elementType : ScrollIntoViewIfNeededDefaultElementType, _object_spread$
|
|
10842
|
+
return React.createElement(elementType !== null && elementType !== void 0 ? elementType : ScrollIntoViewIfNeededDefaultElementType, _object_spread$K({
|
|
10598
10843
|
ref: this.node
|
|
10599
10844
|
}, wrapperProps), children);
|
|
10600
10845
|
}
|
|
@@ -10602,10 +10847,10 @@
|
|
|
10602
10847
|
]);
|
|
10603
10848
|
return ScrollIntoViewIfNeeded2;
|
|
10604
10849
|
}(React.PureComponent);
|
|
10605
|
-
_define_property$
|
|
10850
|
+
_define_property$M(ScrollIntoViewIfNeeded, "defaultProps", ScrollIntoViewIfNeededDefaultProps);
|
|
10606
10851
|
var DEFAULT_OPTION_INDEX = -2;
|
|
10607
10852
|
var ALL_OPTION_INDEX = -1;
|
|
10608
|
-
function _define_property$
|
|
10853
|
+
function _define_property$L(obj, key, value) {
|
|
10609
10854
|
if (key in obj) {
|
|
10610
10855
|
Object.defineProperty(obj, key, {
|
|
10611
10856
|
value,
|
|
@@ -10618,7 +10863,7 @@
|
|
|
10618
10863
|
}
|
|
10619
10864
|
return obj;
|
|
10620
10865
|
}
|
|
10621
|
-
function _object_spread$
|
|
10866
|
+
function _object_spread$J(target) {
|
|
10622
10867
|
for (var i = 1; i < arguments.length; i++) {
|
|
10623
10868
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
10624
10869
|
var ownKeys2 = Object.keys(source);
|
|
@@ -10628,7 +10873,7 @@
|
|
|
10628
10873
|
}));
|
|
10629
10874
|
}
|
|
10630
10875
|
ownKeys2.forEach(function(key) {
|
|
10631
|
-
_define_property$
|
|
10876
|
+
_define_property$L(target, key, source[key]);
|
|
10632
10877
|
});
|
|
10633
10878
|
}
|
|
10634
10879
|
return target;
|
|
@@ -10639,7 +10884,7 @@
|
|
|
10639
10884
|
10,
|
|
10640
10885
|
20
|
|
10641
10886
|
];
|
|
10642
|
-
var useStyles$
|
|
10887
|
+
var useStyles$E = createThemedStyles("SelectList", {
|
|
10643
10888
|
root: {
|
|
10644
10889
|
borderRadius: dimensions.BORDER_RADIUS_SMALL,
|
|
10645
10890
|
boxShadow: "0 13px 74px -27px rgba(0, 0, 0, 0.11)",
|
|
@@ -10659,7 +10904,7 @@
|
|
|
10659
10904
|
},
|
|
10660
10905
|
listHeader: {},
|
|
10661
10906
|
listFooter: {},
|
|
10662
|
-
list: _object_spread$
|
|
10907
|
+
list: _object_spread$J({
|
|
10663
10908
|
height: "100%",
|
|
10664
10909
|
maxHeight: ROW_HEIGHT$1 * 6,
|
|
10665
10910
|
cursor: "pointer",
|
|
@@ -10702,7 +10947,7 @@
|
|
|
10702
10947
|
display: "none"
|
|
10703
10948
|
}
|
|
10704
10949
|
};
|
|
10705
|
-
function _define_property$
|
|
10950
|
+
function _define_property$K(obj, key, value) {
|
|
10706
10951
|
if (key in obj) {
|
|
10707
10952
|
Object.defineProperty(obj, key, {
|
|
10708
10953
|
value,
|
|
@@ -10715,7 +10960,7 @@
|
|
|
10715
10960
|
}
|
|
10716
10961
|
return obj;
|
|
10717
10962
|
}
|
|
10718
|
-
function _object_spread$
|
|
10963
|
+
function _object_spread$I(target) {
|
|
10719
10964
|
for (var i = 1; i < arguments.length; i++) {
|
|
10720
10965
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
10721
10966
|
var ownKeys2 = Object.keys(source);
|
|
@@ -10725,12 +10970,12 @@
|
|
|
10725
10970
|
}));
|
|
10726
10971
|
}
|
|
10727
10972
|
ownKeys2.forEach(function(key) {
|
|
10728
|
-
_define_property$
|
|
10973
|
+
_define_property$K(target, key, source[key]);
|
|
10729
10974
|
});
|
|
10730
10975
|
}
|
|
10731
10976
|
return target;
|
|
10732
10977
|
}
|
|
10733
|
-
function ownKeys$
|
|
10978
|
+
function ownKeys$D(object, enumerableOnly) {
|
|
10734
10979
|
var keys2 = Object.keys(object);
|
|
10735
10980
|
if (Object.getOwnPropertySymbols) {
|
|
10736
10981
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -10743,12 +10988,12 @@
|
|
|
10743
10988
|
}
|
|
10744
10989
|
return keys2;
|
|
10745
10990
|
}
|
|
10746
|
-
function _object_spread_props$
|
|
10991
|
+
function _object_spread_props$D(target, source) {
|
|
10747
10992
|
source = source != null ? source : {};
|
|
10748
10993
|
if (Object.getOwnPropertyDescriptors) {
|
|
10749
10994
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
10750
10995
|
} else {
|
|
10751
|
-
ownKeys$
|
|
10996
|
+
ownKeys$D(Object(source)).forEach(function(key) {
|
|
10752
10997
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
10753
10998
|
});
|
|
10754
10999
|
}
|
|
@@ -10768,12 +11013,12 @@
|
|
|
10768
11013
|
children
|
|
10769
11014
|
});
|
|
10770
11015
|
var _obj2;
|
|
10771
|
-
return /* @__PURE__ */ jsx(ScrollIntoViewIfNeeded, _object_spread_props$
|
|
11016
|
+
return /* @__PURE__ */ jsx(ScrollIntoViewIfNeeded, _object_spread_props$D(_object_spread$I({
|
|
10772
11017
|
active: isFocused,
|
|
10773
11018
|
options: {
|
|
10774
11019
|
block: "nearest"
|
|
10775
11020
|
},
|
|
10776
|
-
className: clsx(classes.cell, (_obj2 = {}, _define_property$
|
|
11021
|
+
className: clsx(classes.cell, (_obj2 = {}, _define_property$K(_obj2, classes.cellWithCheckbox, isMultiSelect), _define_property$K(_obj2, classes.focused, isFocused), _define_property$K(_obj2, classes.active, isActive && !isMultiSelect), _define_property$K(_obj2, classes.disabled, isDisabled), _obj2))
|
|
10777
11022
|
}, addDataAttributes({
|
|
10778
11023
|
disabled: isDisabled,
|
|
10779
11024
|
active: isActive,
|
|
@@ -10785,7 +11030,7 @@
|
|
|
10785
11030
|
children: isMultiSelect ? multiSelectContent : children
|
|
10786
11031
|
}));
|
|
10787
11032
|
};
|
|
10788
|
-
function _define_property$
|
|
11033
|
+
function _define_property$J(obj, key, value) {
|
|
10789
11034
|
if (key in obj) {
|
|
10790
11035
|
Object.defineProperty(obj, key, {
|
|
10791
11036
|
value,
|
|
@@ -10798,7 +11043,7 @@
|
|
|
10798
11043
|
}
|
|
10799
11044
|
return obj;
|
|
10800
11045
|
}
|
|
10801
|
-
function _object_spread$
|
|
11046
|
+
function _object_spread$H(target) {
|
|
10802
11047
|
for (var i = 1; i < arguments.length; i++) {
|
|
10803
11048
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
10804
11049
|
var ownKeys2 = Object.keys(source);
|
|
@@ -10808,12 +11053,12 @@
|
|
|
10808
11053
|
}));
|
|
10809
11054
|
}
|
|
10810
11055
|
ownKeys2.forEach(function(key) {
|
|
10811
|
-
_define_property$
|
|
11056
|
+
_define_property$J(target, key, source[key]);
|
|
10812
11057
|
});
|
|
10813
11058
|
}
|
|
10814
11059
|
return target;
|
|
10815
11060
|
}
|
|
10816
|
-
function ownKeys$
|
|
11061
|
+
function ownKeys$C(object, enumerableOnly) {
|
|
10817
11062
|
var keys2 = Object.keys(object);
|
|
10818
11063
|
if (Object.getOwnPropertySymbols) {
|
|
10819
11064
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -10826,12 +11071,12 @@
|
|
|
10826
11071
|
}
|
|
10827
11072
|
return keys2;
|
|
10828
11073
|
}
|
|
10829
|
-
function _object_spread_props$
|
|
11074
|
+
function _object_spread_props$C(target, source) {
|
|
10830
11075
|
source = source != null ? source : {};
|
|
10831
11076
|
if (Object.getOwnPropertyDescriptors) {
|
|
10832
11077
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
10833
11078
|
} else {
|
|
10834
|
-
ownKeys$
|
|
11079
|
+
ownKeys$C(Object(source)).forEach(function(key) {
|
|
10835
11080
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
10836
11081
|
});
|
|
10837
11082
|
}
|
|
@@ -10839,7 +11084,7 @@
|
|
|
10839
11084
|
}
|
|
10840
11085
|
function SelectList(param) {
|
|
10841
11086
|
var options = param.options, focusedIndex = param.focusedIndex, activeValue = param.activeValue, defaultOptionLabel = param.defaultOptionLabel, _param_noMatchesLabel = param.noMatchesLabel, noMatchesLabel = _param_noMatchesLabel === void 0 ? "Совпадений не найдено" : _param_noMatchesLabel, isLoading = param.isLoading, _param_loadingLabel = param.loadingLabel, loadingLabel = _param_loadingLabel === void 0 ? "Загрузка..." : _param_loadingLabel, tweakStyles = param.tweakStyles, testId = param.testId, _param_shouldScrollToList = param.shouldScrollToList, shouldScrollToList = _param_shouldScrollToList === void 0 ? true : _param_shouldScrollToList, areAllOptionsSelected = param.areAllOptionsSelected, customListHeader = param.customListHeader, customListFooter = param.customListFooter, isMultiSelect = param.isMultiSelect, isOptionDisabled = param.isOptionDisabled, allOptionsLabel = param.allOptionsLabel, onOptionSelect = param.onOptionSelect, onToggleCheckbox = param.onToggleCheckbox, convertValueToString = param.convertValueToString, _param_convertValueToReactNode = param.convertValueToReactNode, convertValueToReactNode = _param_convertValueToReactNode === void 0 ? convertValueToString : _param_convertValueToReactNode, convertValueToId = param.convertValueToId;
|
|
10842
|
-
var classes = useStyles$
|
|
11087
|
+
var classes = useStyles$E({
|
|
10843
11088
|
theme: tweakStyles
|
|
10844
11089
|
});
|
|
10845
11090
|
var isHeaderNotEmpty = trueReactPlatformHelpers.isReactNodeNotEmpty(customListHeader);
|
|
@@ -10868,13 +11113,13 @@
|
|
|
10868
11113
|
var _obj2;
|
|
10869
11114
|
return /* @__PURE__ */ jsxs(ScrollIntoViewIfNeeded, {
|
|
10870
11115
|
active: shouldScrollToList && !isMultiSelect,
|
|
10871
|
-
className: clsx(classes.root, (_obj2 = {}, _define_property$
|
|
11116
|
+
className: clsx(classes.root, (_obj2 = {}, _define_property$J(_obj2, classes.withListHeader, isHeaderNotEmpty), _define_property$J(_obj2, classes.withListFooter, isFooterNotEmpty), _obj2)),
|
|
10872
11117
|
children: [
|
|
10873
11118
|
isHeaderNotEmpty && /* @__PURE__ */ jsx("div", {
|
|
10874
11119
|
className: classes.listHeader,
|
|
10875
11120
|
children: customListHeader
|
|
10876
11121
|
}),
|
|
10877
|
-
/* @__PURE__ */ jsx("div", _object_spread_props$
|
|
11122
|
+
/* @__PURE__ */ jsx("div", _object_spread_props$C(_object_spread$H({
|
|
10878
11123
|
className: classes.list
|
|
10879
11124
|
}, trueReactPlatformHelpers.addDataTestId(testId)), {
|
|
10880
11125
|
children: isLoading ? /* @__PURE__ */ jsx("div", {
|
|
@@ -10950,7 +11195,7 @@
|
|
|
10950
11195
|
return trueReactPlatformHelpers.isNotEmpty(value === null || value === void 0 ? void 0 : value.id) ? String(value.id) : convertValueToString(value);
|
|
10951
11196
|
};
|
|
10952
11197
|
};
|
|
10953
|
-
var useStyles$
|
|
11198
|
+
var useStyles$D = createThemedStyles("Select", {
|
|
10954
11199
|
root: {
|
|
10955
11200
|
width: "100%",
|
|
10956
11201
|
position: "relative",
|
|
@@ -11056,20 +11301,20 @@
|
|
|
11056
11301
|
}
|
|
11057
11302
|
}
|
|
11058
11303
|
};
|
|
11059
|
-
function _array_like_to_array$
|
|
11304
|
+
function _array_like_to_array$j(arr, len) {
|
|
11060
11305
|
if (len == null || len > arr.length)
|
|
11061
11306
|
len = arr.length;
|
|
11062
11307
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
11063
11308
|
arr2[i] = arr[i];
|
|
11064
11309
|
return arr2;
|
|
11065
11310
|
}
|
|
11066
|
-
function _array_with_holes$
|
|
11311
|
+
function _array_with_holes$j(arr) {
|
|
11067
11312
|
if (Array.isArray(arr))
|
|
11068
11313
|
return arr;
|
|
11069
11314
|
}
|
|
11070
|
-
function _array_without_holes$
|
|
11315
|
+
function _array_without_holes$6(arr) {
|
|
11071
11316
|
if (Array.isArray(arr))
|
|
11072
|
-
return _array_like_to_array$
|
|
11317
|
+
return _array_like_to_array$j(arr);
|
|
11073
11318
|
}
|
|
11074
11319
|
function asyncGeneratorStep$4(gen, resolve, reject, _next, _throw, key, arg) {
|
|
11075
11320
|
try {
|
|
@@ -11100,7 +11345,7 @@
|
|
|
11100
11345
|
});
|
|
11101
11346
|
};
|
|
11102
11347
|
}
|
|
11103
|
-
function _define_property$
|
|
11348
|
+
function _define_property$I(obj, key, value) {
|
|
11104
11349
|
if (key in obj) {
|
|
11105
11350
|
Object.defineProperty(obj, key, {
|
|
11106
11351
|
value,
|
|
@@ -11113,11 +11358,11 @@
|
|
|
11113
11358
|
}
|
|
11114
11359
|
return obj;
|
|
11115
11360
|
}
|
|
11116
|
-
function _iterable_to_array$
|
|
11361
|
+
function _iterable_to_array$6(iter) {
|
|
11117
11362
|
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
11118
11363
|
return Array.from(iter);
|
|
11119
11364
|
}
|
|
11120
|
-
function _iterable_to_array_limit$
|
|
11365
|
+
function _iterable_to_array_limit$j(arr, i) {
|
|
11121
11366
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
11122
11367
|
if (_i == null)
|
|
11123
11368
|
return;
|
|
@@ -11145,13 +11390,13 @@
|
|
|
11145
11390
|
}
|
|
11146
11391
|
return _arr;
|
|
11147
11392
|
}
|
|
11148
|
-
function _non_iterable_rest$
|
|
11393
|
+
function _non_iterable_rest$j() {
|
|
11149
11394
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
11150
11395
|
}
|
|
11151
|
-
function _non_iterable_spread$
|
|
11396
|
+
function _non_iterable_spread$6() {
|
|
11152
11397
|
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
11153
11398
|
}
|
|
11154
|
-
function _object_spread$
|
|
11399
|
+
function _object_spread$G(target) {
|
|
11155
11400
|
for (var i = 1; i < arguments.length; i++) {
|
|
11156
11401
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
11157
11402
|
var ownKeys2 = Object.keys(source);
|
|
@@ -11161,12 +11406,12 @@
|
|
|
11161
11406
|
}));
|
|
11162
11407
|
}
|
|
11163
11408
|
ownKeys2.forEach(function(key) {
|
|
11164
|
-
_define_property$
|
|
11409
|
+
_define_property$I(target, key, source[key]);
|
|
11165
11410
|
});
|
|
11166
11411
|
}
|
|
11167
11412
|
return target;
|
|
11168
11413
|
}
|
|
11169
|
-
function ownKeys$
|
|
11414
|
+
function ownKeys$B(object, enumerableOnly) {
|
|
11170
11415
|
var keys2 = Object.keys(object);
|
|
11171
11416
|
if (Object.getOwnPropertySymbols) {
|
|
11172
11417
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -11179,12 +11424,12 @@
|
|
|
11179
11424
|
}
|
|
11180
11425
|
return keys2;
|
|
11181
11426
|
}
|
|
11182
|
-
function _object_spread_props$
|
|
11427
|
+
function _object_spread_props$B(target, source) {
|
|
11183
11428
|
source = source != null ? source : {};
|
|
11184
11429
|
if (Object.getOwnPropertyDescriptors) {
|
|
11185
11430
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
11186
11431
|
} else {
|
|
11187
|
-
ownKeys$
|
|
11432
|
+
ownKeys$B(Object(source)).forEach(function(key) {
|
|
11188
11433
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
11189
11434
|
});
|
|
11190
11435
|
}
|
|
@@ -11222,24 +11467,24 @@
|
|
|
11222
11467
|
}
|
|
11223
11468
|
return target;
|
|
11224
11469
|
}
|
|
11225
|
-
function _sliced_to_array$
|
|
11226
|
-
return _array_with_holes$
|
|
11470
|
+
function _sliced_to_array$j(arr, i) {
|
|
11471
|
+
return _array_with_holes$j(arr) || _iterable_to_array_limit$j(arr, i) || _unsupported_iterable_to_array$j(arr, i) || _non_iterable_rest$j();
|
|
11227
11472
|
}
|
|
11228
|
-
function _to_consumable_array$
|
|
11229
|
-
return _array_without_holes$
|
|
11473
|
+
function _to_consumable_array$6(arr) {
|
|
11474
|
+
return _array_without_holes$6(arr) || _iterable_to_array$6(arr) || _unsupported_iterable_to_array$j(arr) || _non_iterable_spread$6();
|
|
11230
11475
|
}
|
|
11231
|
-
function _unsupported_iterable_to_array$
|
|
11476
|
+
function _unsupported_iterable_to_array$j(o, minLen) {
|
|
11232
11477
|
if (!o)
|
|
11233
11478
|
return;
|
|
11234
11479
|
if (typeof o === "string")
|
|
11235
|
-
return _array_like_to_array$
|
|
11480
|
+
return _array_like_to_array$j(o, minLen);
|
|
11236
11481
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
11237
11482
|
if (n === "Object" && o.constructor)
|
|
11238
11483
|
n = o.constructor.name;
|
|
11239
11484
|
if (n === "Map" || n === "Set")
|
|
11240
11485
|
return Array.from(n);
|
|
11241
11486
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
11242
|
-
return _array_like_to_array$
|
|
11487
|
+
return _array_like_to_array$j(o, minLen);
|
|
11243
11488
|
}
|
|
11244
11489
|
function _ts_generator$4(thisArg, body) {
|
|
11245
11490
|
var f, y, t, g, _ = {
|
|
@@ -11379,7 +11624,7 @@
|
|
|
11379
11624
|
"convertValueToReactNode",
|
|
11380
11625
|
"optionsFilter"
|
|
11381
11626
|
]);
|
|
11382
|
-
var classes = useStyles$
|
|
11627
|
+
var classes = useStyles$D({
|
|
11383
11628
|
theme: tweakStyles
|
|
11384
11629
|
});
|
|
11385
11630
|
var _ref = searchInput !== null && searchInput !== void 0 ? searchInput : {}, tmp = _ref.shouldRenderInList, shouldRenderSearchInputInList = tmp === void 0 ? false : tmp, searchInputProps = _object_without_properties$b(_ref, [
|
|
@@ -11408,12 +11653,12 @@
|
|
|
11408
11653
|
currentComponentName: "Select"
|
|
11409
11654
|
});
|
|
11410
11655
|
var isMounted = useIsMounted();
|
|
11411
|
-
var _useState = _sliced_to_array$
|
|
11412
|
-
var _useState1 = _sliced_to_array$
|
|
11656
|
+
var _useState = _sliced_to_array$j(React.useState(false), 2), isListOpen = _useState[0], setIsListOpen = _useState[1];
|
|
11657
|
+
var _useState1 = _sliced_to_array$j(React.useState(false), 2), areOptionsLoading = _useState1[0], setAreOptionsLoading = _useState1[1];
|
|
11413
11658
|
var hasDefaultOption = trueReactPlatformHelpers.isReactNodeNotEmpty(defaultOptionLabel);
|
|
11414
|
-
var _useState2 = _sliced_to_array$
|
|
11415
|
-
var _useState3 = _sliced_to_array$
|
|
11416
|
-
var _useState4 = _sliced_to_array$
|
|
11659
|
+
var _useState2 = _sliced_to_array$j(React.useState(DEFAULT_OPTION_INDEX), 2), focusedListCellIndex = _useState2[0], setFocusedListCellIndex = _useState2[1];
|
|
11660
|
+
var _useState3 = _sliced_to_array$j(React.useState(""), 2), searchValue = _useState3[0], setSearchValue = _useState3[1];
|
|
11661
|
+
var _useState4 = _sliced_to_array$j(React.useState(true), 2), shouldShowDefaultOption = _useState4[0], setShouldShowDefaultOption = _useState4[1];
|
|
11417
11662
|
var root2 = React.useRef(null);
|
|
11418
11663
|
var inputWrapper = React.useRef(null);
|
|
11419
11664
|
var list = React.useRef(null);
|
|
@@ -11566,7 +11811,7 @@
|
|
|
11566
11811
|
var option = filteredOptions[index];
|
|
11567
11812
|
handleChange(isSelected ? (
|
|
11568
11813
|
// Добавляем
|
|
11569
|
-
_to_consumable_array$
|
|
11814
|
+
_to_consumable_array$6(value !== null && value !== void 0 ? value : []).concat([
|
|
11570
11815
|
option
|
|
11571
11816
|
])
|
|
11572
11817
|
) : (
|
|
@@ -11744,7 +11989,7 @@
|
|
|
11744
11989
|
}, [
|
|
11745
11990
|
isOpen
|
|
11746
11991
|
]);
|
|
11747
|
-
var searchInputEl = hasSearchInputInList && /* @__PURE__ */ jsx(SearchInput, _object_spread$
|
|
11992
|
+
var searchInputEl = hasSearchInputInList && /* @__PURE__ */ jsx(SearchInput, _object_spread$G({
|
|
11748
11993
|
value: searchValue,
|
|
11749
11994
|
onChange: handleInputChange,
|
|
11750
11995
|
tweakStyles: tweakSearchInputStyles,
|
|
@@ -11757,8 +12002,8 @@
|
|
|
11757
12002
|
]
|
|
11758
12003
|
});
|
|
11759
12004
|
var _obj2;
|
|
11760
|
-
var listEl = /* @__PURE__ */ jsx("div", _object_spread_props$
|
|
11761
|
-
className: clsx(classes.listWrapper, (_obj2 = {}, _define_property$
|
|
12005
|
+
var listEl = /* @__PURE__ */ jsx("div", _object_spread_props$B(_object_spread$G({
|
|
12006
|
+
className: clsx(classes.listWrapper, (_obj2 = {}, _define_property$I(_obj2, classes.withoutPopper, !shouldUsePopper), _define_property$I(_obj2, classes.listWrapperInBody, shouldRenderInBody), _obj2)),
|
|
11762
12007
|
ref: list,
|
|
11763
12008
|
style: popperData === null || popperData === void 0 ? void 0 : popperData.styles.popper,
|
|
11764
12009
|
tabIndex: 0,
|
|
@@ -11814,7 +12059,7 @@
|
|
|
11814
12059
|
onClick: isDisabled ? void 0 : handleOnClick,
|
|
11815
12060
|
ref: inputWrapper,
|
|
11816
12061
|
children: [
|
|
11817
|
-
/* @__PURE__ */ jsx(Input, _object_spread$
|
|
12062
|
+
/* @__PURE__ */ jsx(Input, _object_spread$G({
|
|
11818
12063
|
value: searchValue !== "" && !shouldRenderSearchInputInList ? searchValue : showedStringValue,
|
|
11819
12064
|
onChange: handleInputChange,
|
|
11820
12065
|
isActive: isListOpen,
|
|
@@ -11851,7 +12096,7 @@
|
|
|
11851
12096
|
}
|
|
11852
12097
|
var SELECT_PADDING_LEFT = 12;
|
|
11853
12098
|
var SELECT_PADDING_RIGHT = 24;
|
|
11854
|
-
var useStyles$
|
|
12099
|
+
var useStyles$C = createThemedStyles("DatePickerHeader", {
|
|
11855
12100
|
btn: {
|
|
11856
12101
|
width: 36,
|
|
11857
12102
|
height: 36,
|
|
@@ -11920,7 +12165,7 @@
|
|
|
11920
12165
|
};
|
|
11921
12166
|
var DatePickerHeader = function(param) {
|
|
11922
12167
|
var date = param.date, _param_months = param.months, months = _param_months === void 0 ? [] : _param_months, tweakStyles = param.tweakStyles, prevMonthButtonDisabled = param.prevMonthButtonDisabled, nextMonthButtonDisabled = param.nextMonthButtonDisabled, changeYear = param.changeYear, changeMonth = param.changeMonth, decreaseMonth = param.decreaseMonth, increaseMonth = param.increaseMonth;
|
|
11923
|
-
var classes = useStyles$
|
|
12168
|
+
var classes = useStyles$C({
|
|
11924
12169
|
theme: tweakStyles
|
|
11925
12170
|
});
|
|
11926
12171
|
var tweakSelectStyles = useTweakStyles({
|
|
@@ -12029,7 +12274,7 @@
|
|
|
12029
12274
|
var areDatesEquals = function(date1, date2) {
|
|
12030
12275
|
return trueReactPlatformHelpers.isEmpty(date1) && trueReactPlatformHelpers.isEmpty(date2) || trueReactPlatformHelpers.isNotEmpty(date1) && trueReactPlatformHelpers.isNotEmpty(date2) && dateFns.isSameDay(date1, date2);
|
|
12031
12276
|
};
|
|
12032
|
-
var useStyles$
|
|
12277
|
+
var useStyles$B = createThemedStyles("DatePicker", {
|
|
12033
12278
|
root: {
|
|
12034
12279
|
width: "100%",
|
|
12035
12280
|
height: "100%"
|
|
@@ -12052,18 +12297,18 @@
|
|
|
12052
12297
|
}
|
|
12053
12298
|
}
|
|
12054
12299
|
});
|
|
12055
|
-
function _array_like_to_array$
|
|
12300
|
+
function _array_like_to_array$i(arr, len) {
|
|
12056
12301
|
if (len == null || len > arr.length)
|
|
12057
12302
|
len = arr.length;
|
|
12058
12303
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
12059
12304
|
arr2[i] = arr[i];
|
|
12060
12305
|
return arr2;
|
|
12061
12306
|
}
|
|
12062
|
-
function _array_with_holes$
|
|
12307
|
+
function _array_with_holes$i(arr) {
|
|
12063
12308
|
if (Array.isArray(arr))
|
|
12064
12309
|
return arr;
|
|
12065
12310
|
}
|
|
12066
|
-
function _define_property$
|
|
12311
|
+
function _define_property$H(obj, key, value) {
|
|
12067
12312
|
if (key in obj) {
|
|
12068
12313
|
Object.defineProperty(obj, key, {
|
|
12069
12314
|
value,
|
|
@@ -12076,7 +12321,7 @@
|
|
|
12076
12321
|
}
|
|
12077
12322
|
return obj;
|
|
12078
12323
|
}
|
|
12079
|
-
function _iterable_to_array_limit$
|
|
12324
|
+
function _iterable_to_array_limit$i(arr, i) {
|
|
12080
12325
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
12081
12326
|
if (_i == null)
|
|
12082
12327
|
return;
|
|
@@ -12104,10 +12349,10 @@
|
|
|
12104
12349
|
}
|
|
12105
12350
|
return _arr;
|
|
12106
12351
|
}
|
|
12107
|
-
function _non_iterable_rest$
|
|
12352
|
+
function _non_iterable_rest$i() {
|
|
12108
12353
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
12109
12354
|
}
|
|
12110
|
-
function _object_spread$
|
|
12355
|
+
function _object_spread$F(target) {
|
|
12111
12356
|
for (var i = 1; i < arguments.length; i++) {
|
|
12112
12357
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
12113
12358
|
var ownKeys2 = Object.keys(source);
|
|
@@ -12117,12 +12362,12 @@
|
|
|
12117
12362
|
}));
|
|
12118
12363
|
}
|
|
12119
12364
|
ownKeys2.forEach(function(key) {
|
|
12120
|
-
_define_property$
|
|
12365
|
+
_define_property$H(target, key, source[key]);
|
|
12121
12366
|
});
|
|
12122
12367
|
}
|
|
12123
12368
|
return target;
|
|
12124
12369
|
}
|
|
12125
|
-
function ownKeys$
|
|
12370
|
+
function ownKeys$A(object, enumerableOnly) {
|
|
12126
12371
|
var keys2 = Object.keys(object);
|
|
12127
12372
|
if (Object.getOwnPropertySymbols) {
|
|
12128
12373
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -12135,12 +12380,12 @@
|
|
|
12135
12380
|
}
|
|
12136
12381
|
return keys2;
|
|
12137
12382
|
}
|
|
12138
|
-
function _object_spread_props$
|
|
12383
|
+
function _object_spread_props$A(target, source) {
|
|
12139
12384
|
source = source != null ? source : {};
|
|
12140
12385
|
if (Object.getOwnPropertyDescriptors) {
|
|
12141
12386
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
12142
12387
|
} else {
|
|
12143
|
-
ownKeys$
|
|
12388
|
+
ownKeys$A(Object(source)).forEach(function(key) {
|
|
12144
12389
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
12145
12390
|
});
|
|
12146
12391
|
}
|
|
@@ -12178,21 +12423,21 @@
|
|
|
12178
12423
|
}
|
|
12179
12424
|
return target;
|
|
12180
12425
|
}
|
|
12181
|
-
function _sliced_to_array$
|
|
12182
|
-
return _array_with_holes$
|
|
12426
|
+
function _sliced_to_array$i(arr, i) {
|
|
12427
|
+
return _array_with_holes$i(arr) || _iterable_to_array_limit$i(arr, i) || _unsupported_iterable_to_array$i(arr, i) || _non_iterable_rest$i();
|
|
12183
12428
|
}
|
|
12184
|
-
function _unsupported_iterable_to_array$
|
|
12429
|
+
function _unsupported_iterable_to_array$i(o, minLen) {
|
|
12185
12430
|
if (!o)
|
|
12186
12431
|
return;
|
|
12187
12432
|
if (typeof o === "string")
|
|
12188
|
-
return _array_like_to_array$
|
|
12433
|
+
return _array_like_to_array$i(o, minLen);
|
|
12189
12434
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
12190
12435
|
if (n === "Object" && o.constructor)
|
|
12191
12436
|
n = o.constructor.name;
|
|
12192
12437
|
if (n === "Map" || n === "Set")
|
|
12193
12438
|
return Array.from(n);
|
|
12194
12439
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
12195
|
-
return _array_like_to_array$
|
|
12440
|
+
return _array_like_to_array$i(o, minLen);
|
|
12196
12441
|
}
|
|
12197
12442
|
var DatePicker = /* @__PURE__ */ React.forwardRef(function(_param, ref) {
|
|
12198
12443
|
var data = _param.data, _param_selectedDate = _param.selectedDate, selectedDate = _param_selectedDate === void 0 ? null : _param_selectedDate, minDate = _param.minDate, maxDate = _param.maxDate, _param_endDate = _param.endDate, endDate = _param_endDate === void 0 ? null : _param_endDate, _param_startDate = _param.startDate, startDate = _param_startDate === void 0 ? null : _param_startDate, locale2 = _param.locale, months = _param.months, _param_calendarStartDay = _param.calendarStartDay, calendarStartDay = _param_calendarStartDay === void 0 ? 1 : _param_calendarStartDay, _param_dateFormat = _param.dateFormat, dateFormat = _param_dateFormat === void 0 ? DEFAULT_DATE_FORMAT$2 : _param_dateFormat, monthsShown = _param.monthsShown, placeholder = _param.placeholder, _param_isRange = _param.isRange, isRange = _param_isRange === void 0 ? false : _param_isRange, _param_isInline = _param.isInline, isInline = _param_isInline === void 0 ? false : _param_isInline, isDisabled = _param.isDisabled, isClearable = _param.isClearable, strictParsing = _param.strictParsing, fixedHeight = _param.fixedHeight, excludeScrollbar = _param.excludeScrollbar, focusSelectedMonth = _param.focusSelectedMonth, disabledKeyboardNavigation = _param.disabledKeyboardNavigation, _param_shouldRenderPopperInBody = _param.shouldRenderPopperInBody, shouldRenderPopperInBody = _param_shouldRenderPopperInBody === void 0 ? false : _param_shouldRenderPopperInBody, _param_allowSameDay = _param.allowSameDay, allowSameDay = _param_allowSameDay === void 0 ? false : _param_allowSameDay, shouldCloseOnSelect = _param.shouldCloseOnSelect, showPreviousMonths = _param.showPreviousMonths, preventOpenOnFocus = _param.preventOpenOnFocus, popperModifiers = _param.popperModifiers, popperPlacement = _param.popperPlacement, todayButton = _param.todayButton, highlightDates = _param.highlightDates, calendarContainer = _param.calendarContainer, dayClassName = _param.dayClassName, tmp = _param.customInput, CustomInput = tmp === void 0 ? DateInput : tmp, customInputRef = _param.customInputRef, renderCustomHeader = _param.renderCustomHeader, filterDate = _param.filterDate, onYearChange = _param.onYearChange, onMonthChange = _param.onMonthChange, onCalendarOpen = _param.onCalendarOpen, onCalendarClose = _param.onCalendarClose, onChangeDate = _param.onChangeDate, onChangeRange = _param.onChangeRange, onBlur = _param.onBlur, onFocus = _param.onFocus, onKeyDown = _param.onKeyDown, tweakStyles = _param.tweakStyles, inputProps = _object_without_properties$a(_param, [
|
|
@@ -12243,7 +12488,7 @@
|
|
|
12243
12488
|
"onKeyDown",
|
|
12244
12489
|
"tweakStyles"
|
|
12245
12490
|
]);
|
|
12246
|
-
var classes = useStyles$
|
|
12491
|
+
var classes = useStyles$B({
|
|
12247
12492
|
theme: tweakStyles
|
|
12248
12493
|
});
|
|
12249
12494
|
var tweakDateInputStyles = useTweakStyles({
|
|
@@ -12259,14 +12504,14 @@
|
|
|
12259
12504
|
}, [
|
|
12260
12505
|
dateFormat
|
|
12261
12506
|
]), formatDate = _useMemo.formatDate, parseDateValue = _useMemo.parseDateValue;
|
|
12262
|
-
var _useState = _sliced_to_array$
|
|
12263
|
-
var _useState1 = _sliced_to_array$
|
|
12264
|
-
var _useState2 = _sliced_to_array$
|
|
12265
|
-
var _useState3 = _sliced_to_array$
|
|
12266
|
-
var _useState4 = _sliced_to_array$
|
|
12267
|
-
var _useState5 = _sliced_to_array$
|
|
12507
|
+
var _useState = _sliced_to_array$i(React.useState(false), 2), isOpen = _useState[0], setIsOpen = _useState[1];
|
|
12508
|
+
var _useState1 = _sliced_to_array$i(React.useState(formatDate(selectedDate)), 2), dateValue = _useState1[0], setDateValue = _useState1[1];
|
|
12509
|
+
var _useState2 = _sliced_to_array$i(React.useState(startDate), 2), start2 = _useState2[0], setStart = _useState2[1];
|
|
12510
|
+
var _useState3 = _sliced_to_array$i(React.useState(formatDate(startDate)), 2), startDateValue = _useState3[0], setStartDateValue = _useState3[1];
|
|
12511
|
+
var _useState4 = _sliced_to_array$i(React.useState(endDate), 2), end2 = _useState4[0], setEnd = _useState4[1];
|
|
12512
|
+
var _useState5 = _sliced_to_array$i(React.useState(formatDate(endDate)), 2), endDateValue = _useState5[0], setEndDateValue = _useState5[1];
|
|
12268
12513
|
var hasDateInputValue = isRange ? trueReactPlatformHelpers.isStringNotEmpty(startDateValue) || trueReactPlatformHelpers.isStringNotEmpty(endDateValue) : trueReactPlatformHelpers.isStringNotEmpty(dateValue);
|
|
12269
|
-
var dateInputProps = _object_spread$
|
|
12514
|
+
var dateInputProps = _object_spread$F(_object_spread_props$A(_object_spread$F({}, inputProps), {
|
|
12270
12515
|
isRange,
|
|
12271
12516
|
isDisabled,
|
|
12272
12517
|
isClearable,
|
|
@@ -12364,10 +12609,10 @@
|
|
|
12364
12609
|
startDate,
|
|
12365
12610
|
endDate
|
|
12366
12611
|
]);
|
|
12367
|
-
return /* @__PURE__ */ jsx("div", _object_spread_props$
|
|
12612
|
+
return /* @__PURE__ */ jsx("div", _object_spread_props$A(_object_spread$F({
|
|
12368
12613
|
className: classes.root
|
|
12369
12614
|
}, addDataAttributes(data)), {
|
|
12370
|
-
children: /* @__PURE__ */ jsx(DatePickerComponent, _object_spread$
|
|
12615
|
+
children: /* @__PURE__ */ jsx(DatePickerComponent, _object_spread$F({
|
|
12371
12616
|
ref,
|
|
12372
12617
|
minDate,
|
|
12373
12618
|
maxDate,
|
|
@@ -12398,9 +12643,9 @@
|
|
|
12398
12643
|
preventOpenOnFocus,
|
|
12399
12644
|
shouldCloseOnSelect,
|
|
12400
12645
|
customInputRef,
|
|
12401
|
-
customInput: /* @__PURE__ */ jsx(CustomInput, _object_spread$
|
|
12646
|
+
customInput: /* @__PURE__ */ jsx(CustomInput, _object_spread$F({}, dateInputProps)),
|
|
12402
12647
|
renderCustomHeader: renderCustomHeader !== null && renderCustomHeader !== void 0 ? renderCustomHeader : function(baseProps) {
|
|
12403
|
-
return /* @__PURE__ */ jsx(DatePickerHeader, _object_spread_props$
|
|
12648
|
+
return /* @__PURE__ */ jsx(DatePickerHeader, _object_spread_props$A(_object_spread$F({}, baseProps), {
|
|
12404
12649
|
months
|
|
12405
12650
|
}));
|
|
12406
12651
|
},
|
|
@@ -12438,7 +12683,7 @@
|
|
|
12438
12683
|
}));
|
|
12439
12684
|
});
|
|
12440
12685
|
var LINK_REGEXP = /(http(s?):\/\/(.*))(\s?)/;
|
|
12441
|
-
var useStyles$
|
|
12686
|
+
var useStyles$A = createThemedStyles("Description", {
|
|
12442
12687
|
root: {},
|
|
12443
12688
|
button: {
|
|
12444
12689
|
cursor: "pointer",
|
|
@@ -12468,18 +12713,18 @@
|
|
|
12468
12713
|
}
|
|
12469
12714
|
}
|
|
12470
12715
|
});
|
|
12471
|
-
function _array_like_to_array$
|
|
12716
|
+
function _array_like_to_array$h(arr, len) {
|
|
12472
12717
|
if (len == null || len > arr.length)
|
|
12473
12718
|
len = arr.length;
|
|
12474
12719
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
12475
12720
|
arr2[i] = arr[i];
|
|
12476
12721
|
return arr2;
|
|
12477
12722
|
}
|
|
12478
|
-
function _array_with_holes$
|
|
12723
|
+
function _array_with_holes$h(arr) {
|
|
12479
12724
|
if (Array.isArray(arr))
|
|
12480
12725
|
return arr;
|
|
12481
12726
|
}
|
|
12482
|
-
function _define_property$
|
|
12727
|
+
function _define_property$G(obj, key, value) {
|
|
12483
12728
|
if (key in obj) {
|
|
12484
12729
|
Object.defineProperty(obj, key, {
|
|
12485
12730
|
value,
|
|
@@ -12492,7 +12737,7 @@
|
|
|
12492
12737
|
}
|
|
12493
12738
|
return obj;
|
|
12494
12739
|
}
|
|
12495
|
-
function _iterable_to_array_limit$
|
|
12740
|
+
function _iterable_to_array_limit$h(arr, i) {
|
|
12496
12741
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
12497
12742
|
if (_i == null)
|
|
12498
12743
|
return;
|
|
@@ -12520,10 +12765,10 @@
|
|
|
12520
12765
|
}
|
|
12521
12766
|
return _arr;
|
|
12522
12767
|
}
|
|
12523
|
-
function _non_iterable_rest$
|
|
12768
|
+
function _non_iterable_rest$h() {
|
|
12524
12769
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
12525
12770
|
}
|
|
12526
|
-
function _object_spread$
|
|
12771
|
+
function _object_spread$E(target) {
|
|
12527
12772
|
for (var i = 1; i < arguments.length; i++) {
|
|
12528
12773
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
12529
12774
|
var ownKeys2 = Object.keys(source);
|
|
@@ -12533,12 +12778,12 @@
|
|
|
12533
12778
|
}));
|
|
12534
12779
|
}
|
|
12535
12780
|
ownKeys2.forEach(function(key) {
|
|
12536
|
-
_define_property$
|
|
12781
|
+
_define_property$G(target, key, source[key]);
|
|
12537
12782
|
});
|
|
12538
12783
|
}
|
|
12539
12784
|
return target;
|
|
12540
12785
|
}
|
|
12541
|
-
function ownKeys$
|
|
12786
|
+
function ownKeys$z(object, enumerableOnly) {
|
|
12542
12787
|
var keys2 = Object.keys(object);
|
|
12543
12788
|
if (Object.getOwnPropertySymbols) {
|
|
12544
12789
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -12551,45 +12796,45 @@
|
|
|
12551
12796
|
}
|
|
12552
12797
|
return keys2;
|
|
12553
12798
|
}
|
|
12554
|
-
function _object_spread_props$
|
|
12799
|
+
function _object_spread_props$z(target, source) {
|
|
12555
12800
|
source = source != null ? source : {};
|
|
12556
12801
|
if (Object.getOwnPropertyDescriptors) {
|
|
12557
12802
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
12558
12803
|
} else {
|
|
12559
|
-
ownKeys$
|
|
12804
|
+
ownKeys$z(Object(source)).forEach(function(key) {
|
|
12560
12805
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
12561
12806
|
});
|
|
12562
12807
|
}
|
|
12563
12808
|
return target;
|
|
12564
12809
|
}
|
|
12565
|
-
function _sliced_to_array$
|
|
12566
|
-
return _array_with_holes$
|
|
12810
|
+
function _sliced_to_array$h(arr, i) {
|
|
12811
|
+
return _array_with_holes$h(arr) || _iterable_to_array_limit$h(arr, i) || _unsupported_iterable_to_array$h(arr, i) || _non_iterable_rest$h();
|
|
12567
12812
|
}
|
|
12568
|
-
function _unsupported_iterable_to_array$
|
|
12813
|
+
function _unsupported_iterable_to_array$h(o, minLen) {
|
|
12569
12814
|
if (!o)
|
|
12570
12815
|
return;
|
|
12571
12816
|
if (typeof o === "string")
|
|
12572
|
-
return _array_like_to_array$
|
|
12817
|
+
return _array_like_to_array$h(o, minLen);
|
|
12573
12818
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
12574
12819
|
if (n === "Object" && o.constructor)
|
|
12575
12820
|
n = o.constructor.name;
|
|
12576
12821
|
if (n === "Map" || n === "Set")
|
|
12577
12822
|
return Array.from(n);
|
|
12578
12823
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
12579
|
-
return _array_like_to_array$
|
|
12824
|
+
return _array_like_to_array$h(o, minLen);
|
|
12580
12825
|
}
|
|
12581
12826
|
var Description = function(param) {
|
|
12582
12827
|
var text = param.text, moreTitle = param.moreTitle, lessTitle = param.lessTitle, _param_truncateIndex = param.truncateIndex, truncateIndex = _param_truncateIndex === void 0 ? 150 : _param_truncateIndex, _param_isAlwaysOpen = param.isAlwaysOpen, isAlwaysOpen = _param_isAlwaysOpen === void 0 ? true : _param_isAlwaysOpen, testId = param.testId, data = param.data, tweakStyles = param.tweakStyles;
|
|
12583
|
-
var classes = useStyles$
|
|
12828
|
+
var classes = useStyles$A({
|
|
12584
12829
|
theme: tweakStyles
|
|
12585
12830
|
});
|
|
12586
12831
|
var isTooShort = text.length < truncateIndex;
|
|
12587
|
-
var _useState = _sliced_to_array$
|
|
12832
|
+
var _useState = _sliced_to_array$h(React.useState(isAlwaysOpen), 2), isOpen = _useState[0], setIsOpen = _useState[1];
|
|
12588
12833
|
var link = text.match(LINK_REGEXP);
|
|
12589
12834
|
var linkText = link && link[0];
|
|
12590
12835
|
var textWithNoLink = text.replace(LINK_REGEXP, "");
|
|
12591
12836
|
var shortText = text.slice(0, text.slice(0, truncateIndex).lastIndexOf(" "));
|
|
12592
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
12837
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$z(_object_spread$E({
|
|
12593
12838
|
className: classes.root
|
|
12594
12839
|
}, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
12595
12840
|
children: [
|
|
@@ -12628,7 +12873,7 @@
|
|
|
12628
12873
|
event.preventDefault();
|
|
12629
12874
|
event.stopPropagation();
|
|
12630
12875
|
};
|
|
12631
|
-
var useStyles$
|
|
12876
|
+
var useStyles$z = createThemedStyles("FileInput", {
|
|
12632
12877
|
root: {
|
|
12633
12878
|
display: "flex",
|
|
12634
12879
|
flexDirection: "column",
|
|
@@ -12696,22 +12941,22 @@
|
|
|
12696
12941
|
rowGap: 12
|
|
12697
12942
|
}
|
|
12698
12943
|
});
|
|
12699
|
-
function _array_like_to_array$
|
|
12944
|
+
function _array_like_to_array$g(arr, len) {
|
|
12700
12945
|
if (len == null || len > arr.length)
|
|
12701
12946
|
len = arr.length;
|
|
12702
12947
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
12703
12948
|
arr2[i] = arr[i];
|
|
12704
12949
|
return arr2;
|
|
12705
12950
|
}
|
|
12706
|
-
function _array_with_holes$
|
|
12951
|
+
function _array_with_holes$g(arr) {
|
|
12707
12952
|
if (Array.isArray(arr))
|
|
12708
12953
|
return arr;
|
|
12709
12954
|
}
|
|
12710
|
-
function _array_without_holes$
|
|
12955
|
+
function _array_without_holes$5(arr) {
|
|
12711
12956
|
if (Array.isArray(arr))
|
|
12712
|
-
return _array_like_to_array$
|
|
12957
|
+
return _array_like_to_array$g(arr);
|
|
12713
12958
|
}
|
|
12714
|
-
function _define_property$
|
|
12959
|
+
function _define_property$F(obj, key, value) {
|
|
12715
12960
|
if (key in obj) {
|
|
12716
12961
|
Object.defineProperty(obj, key, {
|
|
12717
12962
|
value,
|
|
@@ -12724,11 +12969,11 @@
|
|
|
12724
12969
|
}
|
|
12725
12970
|
return obj;
|
|
12726
12971
|
}
|
|
12727
|
-
function _iterable_to_array$
|
|
12972
|
+
function _iterable_to_array$5(iter) {
|
|
12728
12973
|
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
12729
12974
|
return Array.from(iter);
|
|
12730
12975
|
}
|
|
12731
|
-
function _iterable_to_array_limit$
|
|
12976
|
+
function _iterable_to_array_limit$g(arr, i) {
|
|
12732
12977
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
12733
12978
|
if (_i == null)
|
|
12734
12979
|
return;
|
|
@@ -12756,13 +13001,13 @@
|
|
|
12756
13001
|
}
|
|
12757
13002
|
return _arr;
|
|
12758
13003
|
}
|
|
12759
|
-
function _non_iterable_rest$
|
|
13004
|
+
function _non_iterable_rest$g() {
|
|
12760
13005
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
12761
13006
|
}
|
|
12762
|
-
function _non_iterable_spread$
|
|
13007
|
+
function _non_iterable_spread$5() {
|
|
12763
13008
|
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
12764
13009
|
}
|
|
12765
|
-
function _object_spread$
|
|
13010
|
+
function _object_spread$D(target) {
|
|
12766
13011
|
for (var i = 1; i < arguments.length; i++) {
|
|
12767
13012
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
12768
13013
|
var ownKeys2 = Object.keys(source);
|
|
@@ -12772,12 +13017,12 @@
|
|
|
12772
13017
|
}));
|
|
12773
13018
|
}
|
|
12774
13019
|
ownKeys2.forEach(function(key) {
|
|
12775
|
-
_define_property$
|
|
13020
|
+
_define_property$F(target, key, source[key]);
|
|
12776
13021
|
});
|
|
12777
13022
|
}
|
|
12778
13023
|
return target;
|
|
12779
13024
|
}
|
|
12780
|
-
function ownKeys$
|
|
13025
|
+
function ownKeys$y(object, enumerableOnly) {
|
|
12781
13026
|
var keys2 = Object.keys(object);
|
|
12782
13027
|
if (Object.getOwnPropertySymbols) {
|
|
12783
13028
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -12790,47 +13035,47 @@
|
|
|
12790
13035
|
}
|
|
12791
13036
|
return keys2;
|
|
12792
13037
|
}
|
|
12793
|
-
function _object_spread_props$
|
|
13038
|
+
function _object_spread_props$y(target, source) {
|
|
12794
13039
|
source = source != null ? source : {};
|
|
12795
13040
|
if (Object.getOwnPropertyDescriptors) {
|
|
12796
13041
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
12797
13042
|
} else {
|
|
12798
|
-
ownKeys$
|
|
13043
|
+
ownKeys$y(Object(source)).forEach(function(key) {
|
|
12799
13044
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
12800
13045
|
});
|
|
12801
13046
|
}
|
|
12802
13047
|
return target;
|
|
12803
13048
|
}
|
|
12804
|
-
function _sliced_to_array$
|
|
12805
|
-
return _array_with_holes$
|
|
13049
|
+
function _sliced_to_array$g(arr, i) {
|
|
13050
|
+
return _array_with_holes$g(arr) || _iterable_to_array_limit$g(arr, i) || _unsupported_iterable_to_array$g(arr, i) || _non_iterable_rest$g();
|
|
12806
13051
|
}
|
|
12807
|
-
function _to_consumable_array$
|
|
12808
|
-
return _array_without_holes$
|
|
13052
|
+
function _to_consumable_array$5(arr) {
|
|
13053
|
+
return _array_without_holes$5(arr) || _iterable_to_array$5(arr) || _unsupported_iterable_to_array$g(arr) || _non_iterable_spread$5();
|
|
12809
13054
|
}
|
|
12810
|
-
function _unsupported_iterable_to_array$
|
|
13055
|
+
function _unsupported_iterable_to_array$g(o, minLen) {
|
|
12811
13056
|
if (!o)
|
|
12812
13057
|
return;
|
|
12813
13058
|
if (typeof o === "string")
|
|
12814
|
-
return _array_like_to_array$
|
|
13059
|
+
return _array_like_to_array$g(o, minLen);
|
|
12815
13060
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
12816
13061
|
if (n === "Object" && o.constructor)
|
|
12817
13062
|
n = o.constructor.name;
|
|
12818
13063
|
if (n === "Map" || n === "Set")
|
|
12819
13064
|
return Array.from(n);
|
|
12820
13065
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
12821
|
-
return _array_like_to_array$
|
|
13066
|
+
return _array_like_to_array$g(o, minLen);
|
|
12822
13067
|
}
|
|
12823
13068
|
var FileInput = /* @__PURE__ */ React.forwardRef(function(param, ref) {
|
|
12824
13069
|
var fileList = param.fileList, label = param.label, text = param.text, description = param.description, _param_isDragAndDropDisabled = param.isDragAndDropDisabled, isDragAndDropDisabled = _param_isDragAndDropDisabled === void 0 ? false : _param_isDragAndDropDisabled, _param_isRequired = param.isRequired, isRequired = _param_isRequired === void 0 ? false : _param_isRequired, _param_isReadOnly = param.isReadOnly, isReadOnly = _param_isReadOnly === void 0 ? false : _param_isReadOnly, _param_isMultipleDisabled = param.isMultipleDisabled, isMultipleDisabled = _param_isMultipleDisabled === void 0 ? false : _param_isMultipleDisabled, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, _param_isActive = param.isActive, isActive = _param_isActive === void 0 ? false : _param_isActive, accept = param.accept, onAdd = param.onAdd, testId = param.testId, tweakStyles = param.tweakStyles, data = param.data;
|
|
12825
|
-
var classes = useStyles$
|
|
13070
|
+
var classes = useStyles$z({
|
|
12826
13071
|
theme: tweakStyles
|
|
12827
13072
|
});
|
|
12828
|
-
var _useState = _sliced_to_array$
|
|
13073
|
+
var _useState = _sliced_to_array$g(React.useState(false), 2), isDragOver = _useState[0], setIsDragOver = _useState[1];
|
|
12829
13074
|
var handleAdd = function(files) {
|
|
12830
13075
|
if (isDisabled || trueReactPlatformHelpers.isEmpty(files) || (files === null || files === void 0 ? void 0 : files.length) === 0) {
|
|
12831
13076
|
return;
|
|
12832
13077
|
}
|
|
12833
|
-
onAdd === null || onAdd === void 0 ? void 0 : onAdd(_to_consumable_array$
|
|
13078
|
+
onAdd === null || onAdd === void 0 ? void 0 : onAdd(_to_consumable_array$5(files));
|
|
12834
13079
|
};
|
|
12835
13080
|
var handleDragStart = function(event) {
|
|
12836
13081
|
blockEvent(event);
|
|
@@ -12854,16 +13099,16 @@
|
|
|
12854
13099
|
onDrop: handleDrop
|
|
12855
13100
|
} : void 0;
|
|
12856
13101
|
var _obj2;
|
|
12857
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
13102
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$y(_object_spread$D({
|
|
12858
13103
|
className: classes.root
|
|
12859
13104
|
}, addDataAttributes(data), trueReactPlatformHelpers.addDataTestId(testId)), {
|
|
12860
13105
|
children: [
|
|
12861
13106
|
trueReactPlatformHelpers.isReactNodeNotEmpty(label) && /* @__PURE__ */ jsx("div", {
|
|
12862
|
-
className: clsx(classes.label, _define_property$
|
|
13107
|
+
className: clsx(classes.label, _define_property$F({}, classes.requiredLabel, isRequired)),
|
|
12863
13108
|
children: label
|
|
12864
13109
|
}),
|
|
12865
|
-
!isReadOnly && /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
12866
|
-
className: clsx(classes.inputWrapper, (_obj2 = {}, _define_property$
|
|
13110
|
+
!isReadOnly && /* @__PURE__ */ jsxs("div", _object_spread_props$y(_object_spread$D({
|
|
13111
|
+
className: clsx(classes.inputWrapper, (_obj2 = {}, _define_property$F(_obj2, classes.dragged, isDragOver), _define_property$F(_obj2, classes.disabled, isDisabled), _define_property$F(_obj2, classes.active, isActive), _obj2))
|
|
12867
13112
|
}, dndHandlers), {
|
|
12868
13113
|
children: [
|
|
12869
13114
|
trueReactPlatformHelpers.isReactNodeNotEmpty(text) && /* @__PURE__ */ jsx("div", {
|
|
@@ -12872,7 +13117,7 @@
|
|
|
12872
13117
|
}),
|
|
12873
13118
|
/* @__PURE__ */ jsx("label", {
|
|
12874
13119
|
className: classes.inputLabel,
|
|
12875
|
-
children: /* @__PURE__ */ jsx("input", _object_spread$
|
|
13120
|
+
children: /* @__PURE__ */ jsx("input", _object_spread$D({
|
|
12876
13121
|
ref,
|
|
12877
13122
|
type: "file",
|
|
12878
13123
|
value: "",
|
|
@@ -12899,7 +13144,7 @@
|
|
|
12899
13144
|
var BUTTON_SIZE_S = 24;
|
|
12900
13145
|
var BUTTON_SIZE_M = 32;
|
|
12901
13146
|
var ICON_SIZE = 20;
|
|
12902
|
-
var useStyles$
|
|
13147
|
+
var useStyles$y = createThemedStyles("IconButton", {
|
|
12903
13148
|
root: {
|
|
12904
13149
|
display: "flex",
|
|
12905
13150
|
justifyContent: "center",
|
|
@@ -12961,7 +13206,7 @@
|
|
|
12961
13206
|
height: BUTTON_SIZE_M
|
|
12962
13207
|
}
|
|
12963
13208
|
});
|
|
12964
|
-
function _define_property$
|
|
13209
|
+
function _define_property$E(obj, key, value) {
|
|
12965
13210
|
if (key in obj) {
|
|
12966
13211
|
Object.defineProperty(obj, key, {
|
|
12967
13212
|
value,
|
|
@@ -12974,7 +13219,7 @@
|
|
|
12974
13219
|
}
|
|
12975
13220
|
return obj;
|
|
12976
13221
|
}
|
|
12977
|
-
function _object_spread$
|
|
13222
|
+
function _object_spread$C(target) {
|
|
12978
13223
|
for (var i = 1; i < arguments.length; i++) {
|
|
12979
13224
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
12980
13225
|
var ownKeys2 = Object.keys(source);
|
|
@@ -12984,12 +13229,12 @@
|
|
|
12984
13229
|
}));
|
|
12985
13230
|
}
|
|
12986
13231
|
ownKeys2.forEach(function(key) {
|
|
12987
|
-
_define_property$
|
|
13232
|
+
_define_property$E(target, key, source[key]);
|
|
12988
13233
|
});
|
|
12989
13234
|
}
|
|
12990
13235
|
return target;
|
|
12991
13236
|
}
|
|
12992
|
-
function ownKeys$
|
|
13237
|
+
function ownKeys$x(object, enumerableOnly) {
|
|
12993
13238
|
var keys2 = Object.keys(object);
|
|
12994
13239
|
if (Object.getOwnPropertySymbols) {
|
|
12995
13240
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -13002,12 +13247,12 @@
|
|
|
13002
13247
|
}
|
|
13003
13248
|
return keys2;
|
|
13004
13249
|
}
|
|
13005
|
-
function _object_spread_props$
|
|
13250
|
+
function _object_spread_props$x(target, source) {
|
|
13006
13251
|
source = source != null ? source : {};
|
|
13007
13252
|
if (Object.getOwnPropertyDescriptors) {
|
|
13008
13253
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
13009
13254
|
} else {
|
|
13010
|
-
ownKeys$
|
|
13255
|
+
ownKeys$x(Object(source)).forEach(function(key) {
|
|
13011
13256
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
13012
13257
|
});
|
|
13013
13258
|
}
|
|
@@ -13059,14 +13304,14 @@
|
|
|
13059
13304
|
"data",
|
|
13060
13305
|
"onClick"
|
|
13061
13306
|
]);
|
|
13062
|
-
var classes = useStyles$
|
|
13307
|
+
var classes = useStyles$y({
|
|
13063
13308
|
theme: tweakStyles
|
|
13064
13309
|
});
|
|
13065
13310
|
var hasNoAction = isDisabled || isLoading;
|
|
13066
13311
|
var _obj2;
|
|
13067
|
-
return /* @__PURE__ */ jsx("button", _object_spread_props$
|
|
13312
|
+
return /* @__PURE__ */ jsx("button", _object_spread_props$x(_object_spread$C({
|
|
13068
13313
|
ref,
|
|
13069
|
-
className: clsx(classes.root, classes[view], classes[size], (_obj2 = {}, _define_property$
|
|
13314
|
+
className: clsx(classes.root, classes[view], classes[size], (_obj2 = {}, _define_property$E(_obj2, classes.disabled, isDisabled), _define_property$E(_obj2, classes.active, isActive), _define_property$E(_obj2, classes.loading, isLoading), _obj2)),
|
|
13070
13315
|
type,
|
|
13071
13316
|
disabled: isDisabled,
|
|
13072
13317
|
onClick: hasNoAction ? void 0 : onClick
|
|
@@ -13083,7 +13328,7 @@
|
|
|
13083
13328
|
})
|
|
13084
13329
|
}));
|
|
13085
13330
|
});
|
|
13086
|
-
var useStyles$
|
|
13331
|
+
var useStyles$x = createThemedStyles("Tooltip", {
|
|
13087
13332
|
root: {
|
|
13088
13333
|
display: "inline-block",
|
|
13089
13334
|
boxSizing: "border-box"
|
|
@@ -13125,7 +13370,7 @@
|
|
|
13125
13370
|
}
|
|
13126
13371
|
}
|
|
13127
13372
|
});
|
|
13128
|
-
function _define_property$
|
|
13373
|
+
function _define_property$D(obj, key, value) {
|
|
13129
13374
|
if (key in obj) {
|
|
13130
13375
|
Object.defineProperty(obj, key, {
|
|
13131
13376
|
value,
|
|
@@ -13138,7 +13383,7 @@
|
|
|
13138
13383
|
}
|
|
13139
13384
|
return obj;
|
|
13140
13385
|
}
|
|
13141
|
-
function _object_spread$
|
|
13386
|
+
function _object_spread$B(target) {
|
|
13142
13387
|
for (var i = 1; i < arguments.length; i++) {
|
|
13143
13388
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
13144
13389
|
var ownKeys2 = Object.keys(source);
|
|
@@ -13148,12 +13393,12 @@
|
|
|
13148
13393
|
}));
|
|
13149
13394
|
}
|
|
13150
13395
|
ownKeys2.forEach(function(key) {
|
|
13151
|
-
_define_property$
|
|
13396
|
+
_define_property$D(target, key, source[key]);
|
|
13152
13397
|
});
|
|
13153
13398
|
}
|
|
13154
13399
|
return target;
|
|
13155
13400
|
}
|
|
13156
|
-
function ownKeys$
|
|
13401
|
+
function ownKeys$w(object, enumerableOnly) {
|
|
13157
13402
|
var keys2 = Object.keys(object);
|
|
13158
13403
|
if (Object.getOwnPropertySymbols) {
|
|
13159
13404
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -13166,12 +13411,12 @@
|
|
|
13166
13411
|
}
|
|
13167
13412
|
return keys2;
|
|
13168
13413
|
}
|
|
13169
|
-
function _object_spread_props$
|
|
13414
|
+
function _object_spread_props$w(target, source) {
|
|
13170
13415
|
source = source != null ? source : {};
|
|
13171
13416
|
if (Object.getOwnPropertyDescriptors) {
|
|
13172
13417
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
13173
13418
|
} else {
|
|
13174
|
-
ownKeys$
|
|
13419
|
+
ownKeys$w(Object(source)).forEach(function(key) {
|
|
13175
13420
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
13176
13421
|
});
|
|
13177
13422
|
}
|
|
@@ -13179,16 +13424,16 @@
|
|
|
13179
13424
|
}
|
|
13180
13425
|
var Tooltip = function(param) {
|
|
13181
13426
|
var text = param.text, _param_view = param.view, view = _param_view === void 0 ? "tooltip" : _param_view, _param_type = param.type, type = _param_type === void 0 ? "info" : _param_type, data = param.data, testId = param.testId, tweakStyles = param.tweakStyles;
|
|
13182
|
-
var classes = useStyles$
|
|
13427
|
+
var classes = useStyles$x({
|
|
13183
13428
|
theme: tweakStyles
|
|
13184
13429
|
});
|
|
13185
|
-
return /* @__PURE__ */ jsx("div", _object_spread_props$
|
|
13430
|
+
return /* @__PURE__ */ jsx("div", _object_spread_props$w(_object_spread$B({
|
|
13186
13431
|
className: clsx(classes.root, classes[view], classes[type])
|
|
13187
13432
|
}, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
13188
13433
|
children: text
|
|
13189
13434
|
}));
|
|
13190
13435
|
};
|
|
13191
|
-
var useStyles$
|
|
13436
|
+
var useStyles$w = createThemedStyles("TextWithTooltip", {
|
|
13192
13437
|
root: {
|
|
13193
13438
|
position: "relative"
|
|
13194
13439
|
},
|
|
@@ -13199,22 +13444,22 @@
|
|
|
13199
13444
|
cursor: "pointer"
|
|
13200
13445
|
}
|
|
13201
13446
|
});
|
|
13202
|
-
function _array_like_to_array$
|
|
13447
|
+
function _array_like_to_array$f(arr, len) {
|
|
13203
13448
|
if (len == null || len > arr.length)
|
|
13204
13449
|
len = arr.length;
|
|
13205
13450
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
13206
13451
|
arr2[i] = arr[i];
|
|
13207
13452
|
return arr2;
|
|
13208
13453
|
}
|
|
13209
|
-
function _array_with_holes$
|
|
13454
|
+
function _array_with_holes$f(arr) {
|
|
13210
13455
|
if (Array.isArray(arr))
|
|
13211
13456
|
return arr;
|
|
13212
13457
|
}
|
|
13213
|
-
function _array_without_holes$
|
|
13458
|
+
function _array_without_holes$4(arr) {
|
|
13214
13459
|
if (Array.isArray(arr))
|
|
13215
|
-
return _array_like_to_array$
|
|
13460
|
+
return _array_like_to_array$f(arr);
|
|
13216
13461
|
}
|
|
13217
|
-
function _define_property$
|
|
13462
|
+
function _define_property$C(obj, key, value) {
|
|
13218
13463
|
if (key in obj) {
|
|
13219
13464
|
Object.defineProperty(obj, key, {
|
|
13220
13465
|
value,
|
|
@@ -13227,11 +13472,11 @@
|
|
|
13227
13472
|
}
|
|
13228
13473
|
return obj;
|
|
13229
13474
|
}
|
|
13230
|
-
function _iterable_to_array$
|
|
13475
|
+
function _iterable_to_array$4(iter) {
|
|
13231
13476
|
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
13232
13477
|
return Array.from(iter);
|
|
13233
13478
|
}
|
|
13234
|
-
function _iterable_to_array_limit$
|
|
13479
|
+
function _iterable_to_array_limit$f(arr, i) {
|
|
13235
13480
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
13236
13481
|
if (_i == null)
|
|
13237
13482
|
return;
|
|
@@ -13259,13 +13504,13 @@
|
|
|
13259
13504
|
}
|
|
13260
13505
|
return _arr;
|
|
13261
13506
|
}
|
|
13262
|
-
function _non_iterable_rest$
|
|
13507
|
+
function _non_iterable_rest$f() {
|
|
13263
13508
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
13264
13509
|
}
|
|
13265
|
-
function _non_iterable_spread$
|
|
13510
|
+
function _non_iterable_spread$4() {
|
|
13266
13511
|
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
13267
13512
|
}
|
|
13268
|
-
function _object_spread$
|
|
13513
|
+
function _object_spread$A(target) {
|
|
13269
13514
|
for (var i = 1; i < arguments.length; i++) {
|
|
13270
13515
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
13271
13516
|
var ownKeys2 = Object.keys(source);
|
|
@@ -13275,12 +13520,12 @@
|
|
|
13275
13520
|
}));
|
|
13276
13521
|
}
|
|
13277
13522
|
ownKeys2.forEach(function(key) {
|
|
13278
|
-
_define_property$
|
|
13523
|
+
_define_property$C(target, key, source[key]);
|
|
13279
13524
|
});
|
|
13280
13525
|
}
|
|
13281
13526
|
return target;
|
|
13282
13527
|
}
|
|
13283
|
-
function ownKeys$
|
|
13528
|
+
function ownKeys$v(object, enumerableOnly) {
|
|
13284
13529
|
var keys2 = Object.keys(object);
|
|
13285
13530
|
if (Object.getOwnPropertySymbols) {
|
|
13286
13531
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -13293,39 +13538,39 @@
|
|
|
13293
13538
|
}
|
|
13294
13539
|
return keys2;
|
|
13295
13540
|
}
|
|
13296
|
-
function _object_spread_props$
|
|
13541
|
+
function _object_spread_props$v(target, source) {
|
|
13297
13542
|
source = source != null ? source : {};
|
|
13298
13543
|
if (Object.getOwnPropertyDescriptors) {
|
|
13299
13544
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
13300
13545
|
} else {
|
|
13301
|
-
ownKeys$
|
|
13546
|
+
ownKeys$v(Object(source)).forEach(function(key) {
|
|
13302
13547
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
13303
13548
|
});
|
|
13304
13549
|
}
|
|
13305
13550
|
return target;
|
|
13306
13551
|
}
|
|
13307
|
-
function _sliced_to_array$
|
|
13308
|
-
return _array_with_holes$
|
|
13552
|
+
function _sliced_to_array$f(arr, i) {
|
|
13553
|
+
return _array_with_holes$f(arr) || _iterable_to_array_limit$f(arr, i) || _unsupported_iterable_to_array$f(arr, i) || _non_iterable_rest$f();
|
|
13309
13554
|
}
|
|
13310
|
-
function _to_consumable_array$
|
|
13311
|
-
return _array_without_holes$
|
|
13555
|
+
function _to_consumable_array$4(arr) {
|
|
13556
|
+
return _array_without_holes$4(arr) || _iterable_to_array$4(arr) || _unsupported_iterable_to_array$f(arr) || _non_iterable_spread$4();
|
|
13312
13557
|
}
|
|
13313
|
-
function _unsupported_iterable_to_array$
|
|
13558
|
+
function _unsupported_iterable_to_array$f(o, minLen) {
|
|
13314
13559
|
if (!o)
|
|
13315
13560
|
return;
|
|
13316
13561
|
if (typeof o === "string")
|
|
13317
|
-
return _array_like_to_array$
|
|
13562
|
+
return _array_like_to_array$f(o, minLen);
|
|
13318
13563
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
13319
13564
|
if (n === "Object" && o.constructor)
|
|
13320
13565
|
n = o.constructor.name;
|
|
13321
13566
|
if (n === "Map" || n === "Set")
|
|
13322
13567
|
return Array.from(n);
|
|
13323
13568
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
13324
|
-
return _array_like_to_array$
|
|
13569
|
+
return _array_like_to_array$f(o, minLen);
|
|
13325
13570
|
}
|
|
13326
13571
|
var TextWithTooltip = function(param) {
|
|
13327
13572
|
var children = param.children, tooltipText = param.tooltipText, _param_tooltipPosition = param.tooltipPosition, tooltipPosition = _param_tooltipPosition === void 0 ? "top" : _param_tooltipPosition, _param_tooltipView = param.tooltipView, tooltipView = _param_tooltipView === void 0 ? "tooltip" : _param_tooltipView, _param_tooltipType = param.tooltipType, tooltipType = _param_tooltipType === void 0 ? "info" : _param_tooltipType, _param_tooltipModifiers = param.tooltipModifiers, tooltipModifiers = _param_tooltipModifiers === void 0 ? [] : _param_tooltipModifiers, tooltipOffsetOptions = param.tooltipOffsetOptions, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, _param_shouldRenderInBody = param.shouldRenderInBody, shouldRenderInBody = _param_shouldRenderInBody === void 0 ? true : _param_shouldRenderInBody, _param_mouseEventType = param.mouseEventType, mouseEventType = _param_mouseEventType === void 0 ? "hover" : _param_mouseEventType, hoverDelay = param.hoverDelay, testId = param.testId, data = param.data, tweakStyles = param.tweakStyles;
|
|
13328
|
-
var classes = useStyles$
|
|
13573
|
+
var classes = useStyles$w({
|
|
13329
13574
|
theme: tweakStyles
|
|
13330
13575
|
});
|
|
13331
13576
|
var tweakTooltipStyles = useTweakStyles({
|
|
@@ -13333,8 +13578,8 @@
|
|
|
13333
13578
|
className: "tweakTooltip",
|
|
13334
13579
|
currentComponentName: "TextWithTooltip"
|
|
13335
13580
|
});
|
|
13336
|
-
var _useState = _sliced_to_array$
|
|
13337
|
-
var _useState1 = _sliced_to_array$
|
|
13581
|
+
var _useState = _sliced_to_array$f(React.useState(false), 2), isTooltipVisible = _useState[0], setIsTooltipVisible = _useState[1];
|
|
13582
|
+
var _useState1 = _sliced_to_array$f(React.useState(), 2), tooltipTimeout = _useState1[0], setTooltipTimeout = _useState1[1];
|
|
13338
13583
|
var root2 = React.useRef(null);
|
|
13339
13584
|
var tooltip = React.useRef(null);
|
|
13340
13585
|
var hasDelay = hoverDelay !== void 0;
|
|
@@ -13365,14 +13610,14 @@
|
|
|
13365
13610
|
modifiers: [
|
|
13366
13611
|
{
|
|
13367
13612
|
name: "offset",
|
|
13368
|
-
options: _object_spread$
|
|
13613
|
+
options: _object_spread$A({
|
|
13369
13614
|
offset: [
|
|
13370
13615
|
0,
|
|
13371
13616
|
6
|
|
13372
13617
|
]
|
|
13373
13618
|
}, tooltipOffsetOptions)
|
|
13374
13619
|
}
|
|
13375
|
-
].concat(_to_consumable_array$
|
|
13620
|
+
].concat(_to_consumable_array$4(tooltipModifiers))
|
|
13376
13621
|
}), popperStyles = _usePopper.styles, attributes = _usePopper.attributes;
|
|
13377
13622
|
useOnClickOutsideWithRef(tooltip, function() {
|
|
13378
13623
|
if (mouseEventType === "click") {
|
|
@@ -13388,14 +13633,14 @@
|
|
|
13388
13633
|
onMouseLeave: handleMouseLeave
|
|
13389
13634
|
};
|
|
13390
13635
|
var shouldShowTooltip = tooltipText !== void 0 && tooltipText !== null && !isDisabled;
|
|
13391
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
13636
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$v(_object_spread$A({
|
|
13392
13637
|
className: clsx(classes.root, mouseEventType === "click" && shouldShowTooltip && classes.clickable)
|
|
13393
13638
|
}, shouldShowTooltip ? props : void 0, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
13394
13639
|
ref: root2,
|
|
13395
13640
|
children: [
|
|
13396
13641
|
shouldShowTooltip && /* @__PURE__ */ jsx(reactOverlays.Portal, {
|
|
13397
13642
|
container: shouldRenderInBody ? document.body : root2.current,
|
|
13398
|
-
children: /* @__PURE__ */ jsx("div", _object_spread_props$
|
|
13643
|
+
children: /* @__PURE__ */ jsx("div", _object_spread_props$v(_object_spread$A({
|
|
13399
13644
|
className: classes.tooltip,
|
|
13400
13645
|
style: popperStyles.popper
|
|
13401
13646
|
}, attributes.popper), {
|
|
@@ -13412,7 +13657,7 @@
|
|
|
13412
13657
|
]
|
|
13413
13658
|
}));
|
|
13414
13659
|
};
|
|
13415
|
-
function _define_property$
|
|
13660
|
+
function _define_property$B(obj, key, value) {
|
|
13416
13661
|
if (key in obj) {
|
|
13417
13662
|
Object.defineProperty(obj, key, {
|
|
13418
13663
|
value,
|
|
@@ -13427,7 +13672,7 @@
|
|
|
13427
13672
|
}
|
|
13428
13673
|
var FILE_ICON_DEFAULT = "file-other";
|
|
13429
13674
|
var _obj;
|
|
13430
|
-
var iconTypeMap = (_obj = {}, _define_property$
|
|
13675
|
+
var iconTypeMap = (_obj = {}, _define_property$B(_obj, mimeTypes.xls, "file-excel"), _define_property$B(_obj, mimeTypes.xlsx, "file-excel"), _define_property$B(_obj, mimeTypes.jpeg, "file-image"), _define_property$B(_obj, mimeTypes.png, "file-image"), _define_property$B(_obj, mimeTypes.pdf, "file-pdf"), _define_property$B(_obj, mimeTypes.doc, "file-word"), _define_property$B(_obj, mimeTypes.docx, "file-word"), _define_property$B(_obj, mimeTypes.xml, "file-xml"), _define_property$B(_obj, mimeTypes.zip, "file-zip"), _obj);
|
|
13431
13676
|
var getFileExtensionByFilename = function(fileName) {
|
|
13432
13677
|
var splitFileName = fileName.split(".");
|
|
13433
13678
|
return splitFileName.length > 1 ? splitFileName.pop() : void 0;
|
|
@@ -13447,7 +13692,7 @@
|
|
|
13447
13692
|
}
|
|
13448
13693
|
return FILE_ICON_DEFAULT;
|
|
13449
13694
|
};
|
|
13450
|
-
var useStyles$
|
|
13695
|
+
var useStyles$v = createThemedStyles("FileItem", {
|
|
13451
13696
|
root: {
|
|
13452
13697
|
display: "flex",
|
|
13453
13698
|
flexDirection: "column",
|
|
@@ -13543,7 +13788,7 @@
|
|
|
13543
13788
|
}
|
|
13544
13789
|
}
|
|
13545
13790
|
};
|
|
13546
|
-
function _define_property$
|
|
13791
|
+
function _define_property$A(obj, key, value) {
|
|
13547
13792
|
if (key in obj) {
|
|
13548
13793
|
Object.defineProperty(obj, key, {
|
|
13549
13794
|
value,
|
|
@@ -13556,7 +13801,7 @@
|
|
|
13556
13801
|
}
|
|
13557
13802
|
return obj;
|
|
13558
13803
|
}
|
|
13559
|
-
function _object_spread$
|
|
13804
|
+
function _object_spread$z(target) {
|
|
13560
13805
|
for (var i = 1; i < arguments.length; i++) {
|
|
13561
13806
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
13562
13807
|
var ownKeys2 = Object.keys(source);
|
|
@@ -13566,12 +13811,12 @@
|
|
|
13566
13811
|
}));
|
|
13567
13812
|
}
|
|
13568
13813
|
ownKeys2.forEach(function(key) {
|
|
13569
|
-
_define_property$
|
|
13814
|
+
_define_property$A(target, key, source[key]);
|
|
13570
13815
|
});
|
|
13571
13816
|
}
|
|
13572
13817
|
return target;
|
|
13573
13818
|
}
|
|
13574
|
-
function ownKeys$
|
|
13819
|
+
function ownKeys$u(object, enumerableOnly) {
|
|
13575
13820
|
var keys2 = Object.keys(object);
|
|
13576
13821
|
if (Object.getOwnPropertySymbols) {
|
|
13577
13822
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -13584,12 +13829,12 @@
|
|
|
13584
13829
|
}
|
|
13585
13830
|
return keys2;
|
|
13586
13831
|
}
|
|
13587
|
-
function _object_spread_props$
|
|
13832
|
+
function _object_spread_props$u(target, source) {
|
|
13588
13833
|
source = source != null ? source : {};
|
|
13589
13834
|
if (Object.getOwnPropertyDescriptors) {
|
|
13590
13835
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
13591
13836
|
} else {
|
|
13592
|
-
ownKeys$
|
|
13837
|
+
ownKeys$u(Object(source)).forEach(function(key) {
|
|
13593
13838
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
13594
13839
|
});
|
|
13595
13840
|
}
|
|
@@ -13597,7 +13842,7 @@
|
|
|
13597
13842
|
}
|
|
13598
13843
|
var FileItem = function(param) {
|
|
13599
13844
|
var fileInfo = param.fileInfo, _param_icon = param.icon, icon = _param_icon === void 0 ? getFileIcon(fileInfo) : _param_icon, metadata = param.metadata, actions = param.actions, error = param.error, info = param.info, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, _param_areActionsDisabled = param.areActionsDisabled, areActionsDisabled = _param_areActionsDisabled === void 0 ? false : _param_areActionsDisabled, _param_isLoading = param.isLoading, isLoading = _param_isLoading === void 0 ? false : _param_isLoading, _param_shouldShowSize = param.shouldShowSize, shouldShowSize = _param_shouldShowSize === void 0 ? false : _param_shouldShowSize, _param_itemSize = param.itemSize, itemSize = _param_itemSize === void 0 ? "m" : _param_itemSize, _param_preloaderType = param.preloaderType, preloaderType = _param_preloaderType === void 0 ? "default" : _param_preloaderType, _param_removeIcon = param.removeIcon, removeIcon = _param_removeIcon === void 0 ? "trash-can" : _param_removeIcon, onRemove = param.onRemove, onClick = param.onClick, testId = param.testId, data = param.data, tweakStyles = param.tweakStyles;
|
|
13600
|
-
var classes = useStyles$
|
|
13845
|
+
var classes = useStyles$v({
|
|
13601
13846
|
theme: tweakStyles
|
|
13602
13847
|
});
|
|
13603
13848
|
var tweakIconButtonStyles = useTweakStyles({
|
|
@@ -13629,8 +13874,8 @@
|
|
|
13629
13874
|
return /* @__PURE__ */ jsxs("div", {
|
|
13630
13875
|
className: classes.root,
|
|
13631
13876
|
children: [
|
|
13632
|
-
/* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
13633
|
-
className: clsx(classes.fileItemWrapper, classes[itemSize], _define_property$
|
|
13877
|
+
/* @__PURE__ */ jsxs("div", _object_spread_props$u(_object_spread$z({
|
|
13878
|
+
className: clsx(classes.fileItemWrapper, classes[itemSize], _define_property$A({}, classes.disabled, isDisabled))
|
|
13634
13879
|
}, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data), trueReactPlatformHelpers.addClickHandler(handleClick, !isDisabled)), {
|
|
13635
13880
|
children: [
|
|
13636
13881
|
/* @__PURE__ */ jsx("div", {
|
|
@@ -13871,14 +14116,14 @@
|
|
|
13871
14116
|
var negativePart = "(\\-)?";
|
|
13872
14117
|
return "^".concat(canBeNegative ? negativePart : "").concat(basePart).concat(canBeFloat ? floatPart : "", "$");
|
|
13873
14118
|
};
|
|
13874
|
-
function _array_like_to_array$
|
|
14119
|
+
function _array_like_to_array$e(arr, len) {
|
|
13875
14120
|
if (len == null || len > arr.length)
|
|
13876
14121
|
len = arr.length;
|
|
13877
14122
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
13878
14123
|
arr2[i] = arr[i];
|
|
13879
14124
|
return arr2;
|
|
13880
14125
|
}
|
|
13881
|
-
function _array_with_holes$
|
|
14126
|
+
function _array_with_holes$e(arr) {
|
|
13882
14127
|
if (Array.isArray(arr))
|
|
13883
14128
|
return arr;
|
|
13884
14129
|
}
|
|
@@ -13911,7 +14156,7 @@
|
|
|
13911
14156
|
});
|
|
13912
14157
|
};
|
|
13913
14158
|
}
|
|
13914
|
-
function _define_property$
|
|
14159
|
+
function _define_property$z(obj, key, value) {
|
|
13915
14160
|
if (key in obj) {
|
|
13916
14161
|
Object.defineProperty(obj, key, {
|
|
13917
14162
|
value,
|
|
@@ -13924,7 +14169,7 @@
|
|
|
13924
14169
|
}
|
|
13925
14170
|
return obj;
|
|
13926
14171
|
}
|
|
13927
|
-
function _iterable_to_array_limit$
|
|
14172
|
+
function _iterable_to_array_limit$e(arr, i) {
|
|
13928
14173
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
13929
14174
|
if (_i == null)
|
|
13930
14175
|
return;
|
|
@@ -13952,10 +14197,10 @@
|
|
|
13952
14197
|
}
|
|
13953
14198
|
return _arr;
|
|
13954
14199
|
}
|
|
13955
|
-
function _non_iterable_rest$
|
|
14200
|
+
function _non_iterable_rest$e() {
|
|
13956
14201
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
13957
14202
|
}
|
|
13958
|
-
function _object_spread$
|
|
14203
|
+
function _object_spread$y(target) {
|
|
13959
14204
|
for (var i = 1; i < arguments.length; i++) {
|
|
13960
14205
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
13961
14206
|
var ownKeys2 = Object.keys(source);
|
|
@@ -13965,7 +14210,7 @@
|
|
|
13965
14210
|
}));
|
|
13966
14211
|
}
|
|
13967
14212
|
ownKeys2.forEach(function(key) {
|
|
13968
|
-
_define_property$
|
|
14213
|
+
_define_property$z(target, key, source[key]);
|
|
13969
14214
|
});
|
|
13970
14215
|
}
|
|
13971
14216
|
return target;
|
|
@@ -14002,21 +14247,21 @@
|
|
|
14002
14247
|
}
|
|
14003
14248
|
return target;
|
|
14004
14249
|
}
|
|
14005
|
-
function _sliced_to_array$
|
|
14006
|
-
return _array_with_holes$
|
|
14250
|
+
function _sliced_to_array$e(arr, i) {
|
|
14251
|
+
return _array_with_holes$e(arr) || _iterable_to_array_limit$e(arr, i) || _unsupported_iterable_to_array$e(arr, i) || _non_iterable_rest$e();
|
|
14007
14252
|
}
|
|
14008
|
-
function _unsupported_iterable_to_array$
|
|
14253
|
+
function _unsupported_iterable_to_array$e(o, minLen) {
|
|
14009
14254
|
if (!o)
|
|
14010
14255
|
return;
|
|
14011
14256
|
if (typeof o === "string")
|
|
14012
|
-
return _array_like_to_array$
|
|
14257
|
+
return _array_like_to_array$e(o, minLen);
|
|
14013
14258
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
14014
14259
|
if (n === "Object" && o.constructor)
|
|
14015
14260
|
n = o.constructor.name;
|
|
14016
14261
|
if (n === "Map" || n === "Set")
|
|
14017
14262
|
return Array.from(n);
|
|
14018
14263
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
14019
|
-
return _array_like_to_array$
|
|
14264
|
+
return _array_like_to_array$e(o, minLen);
|
|
14020
14265
|
}
|
|
14021
14266
|
function _ts_generator$3(thisArg, body) {
|
|
14022
14267
|
var f, y, t, g, _ = {
|
|
@@ -14133,10 +14378,10 @@
|
|
|
14133
14378
|
"min",
|
|
14134
14379
|
"max"
|
|
14135
14380
|
]);
|
|
14136
|
-
var _useState = _sliced_to_array$
|
|
14381
|
+
var _useState = _sliced_to_array$e(React.useState(function() {
|
|
14137
14382
|
return formatNumberWithDefault(value, defaultValue);
|
|
14138
14383
|
}), 2), showedValue = _useState[0], setShowedValue = _useState[1];
|
|
14139
|
-
var _useState1 = _sliced_to_array$
|
|
14384
|
+
var _useState1 = _sliced_to_array$e(React.useState(false), 2), isDeleteForwardAction = _useState1[0], setIsDeleteForwardAction = _useState1[1];
|
|
14140
14385
|
var handleKeyDown = function(event) {
|
|
14141
14386
|
setIsDeleteForwardAction(event.key === "Delete");
|
|
14142
14387
|
};
|
|
@@ -14224,7 +14469,7 @@
|
|
|
14224
14469
|
}, [
|
|
14225
14470
|
value
|
|
14226
14471
|
]);
|
|
14227
|
-
return /* @__PURE__ */ jsx(Input, _object_spread$
|
|
14472
|
+
return /* @__PURE__ */ jsx(Input, _object_spread$y({
|
|
14228
14473
|
value: showedValue,
|
|
14229
14474
|
onChange: handleChange,
|
|
14230
14475
|
onBlur: handleBlur,
|
|
@@ -14502,7 +14747,7 @@
|
|
|
14502
14747
|
return baseClone(value, CLONE_DEEP_FLAG | CLONE_SYMBOLS_FLAG);
|
|
14503
14748
|
}
|
|
14504
14749
|
var FILTER_HEIGHT = 36;
|
|
14505
|
-
var useStyles$
|
|
14750
|
+
var useStyles$u = createThemedStyles("FiltersPane", {
|
|
14506
14751
|
root: {
|
|
14507
14752
|
display: "flex",
|
|
14508
14753
|
flexWrap: "wrap",
|
|
@@ -14568,7 +14813,7 @@
|
|
|
14568
14813
|
}
|
|
14569
14814
|
}
|
|
14570
14815
|
};
|
|
14571
|
-
var useStyles$
|
|
14816
|
+
var useStyles$t = createThemedStyles("FilterInterval", {
|
|
14572
14817
|
root: {
|
|
14573
14818
|
padding: 8,
|
|
14574
14819
|
background: colors.CLASSIC_WHITE
|
|
@@ -14611,7 +14856,7 @@
|
|
|
14611
14856
|
}
|
|
14612
14857
|
};
|
|
14613
14858
|
var clearButtonStyles$3 = cloneDeep(innerTextButtonStyles);
|
|
14614
|
-
function _define_property$
|
|
14859
|
+
function _define_property$y(obj, key, value) {
|
|
14615
14860
|
if (key in obj) {
|
|
14616
14861
|
Object.defineProperty(obj, key, {
|
|
14617
14862
|
value,
|
|
@@ -14624,7 +14869,7 @@
|
|
|
14624
14869
|
}
|
|
14625
14870
|
return obj;
|
|
14626
14871
|
}
|
|
14627
|
-
function _object_spread$
|
|
14872
|
+
function _object_spread$x(target) {
|
|
14628
14873
|
for (var i = 1; i < arguments.length; i++) {
|
|
14629
14874
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
14630
14875
|
var ownKeys2 = Object.keys(source);
|
|
@@ -14634,12 +14879,12 @@
|
|
|
14634
14879
|
}));
|
|
14635
14880
|
}
|
|
14636
14881
|
ownKeys2.forEach(function(key) {
|
|
14637
|
-
_define_property$
|
|
14882
|
+
_define_property$y(target, key, source[key]);
|
|
14638
14883
|
});
|
|
14639
14884
|
}
|
|
14640
14885
|
return target;
|
|
14641
14886
|
}
|
|
14642
|
-
function ownKeys$
|
|
14887
|
+
function ownKeys$t(object, enumerableOnly) {
|
|
14643
14888
|
var keys2 = Object.keys(object);
|
|
14644
14889
|
if (Object.getOwnPropertySymbols) {
|
|
14645
14890
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -14652,12 +14897,12 @@
|
|
|
14652
14897
|
}
|
|
14653
14898
|
return keys2;
|
|
14654
14899
|
}
|
|
14655
|
-
function _object_spread_props$
|
|
14900
|
+
function _object_spread_props$t(target, source) {
|
|
14656
14901
|
source = source != null ? source : {};
|
|
14657
14902
|
if (Object.getOwnPropertyDescriptors) {
|
|
14658
14903
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
14659
14904
|
} else {
|
|
14660
|
-
ownKeys$
|
|
14905
|
+
ownKeys$t(Object(source)).forEach(function(key) {
|
|
14661
14906
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
14662
14907
|
});
|
|
14663
14908
|
}
|
|
@@ -14665,7 +14910,7 @@
|
|
|
14665
14910
|
}
|
|
14666
14911
|
var FilterInterval = function(param) {
|
|
14667
14912
|
var data = param.data, tweakStyles = param.tweakStyles, value = param.value, labelName = param.labelName, withFieldNameInLabel = param.withFieldNameInLabel, localeKey = param.localeKey, locale2 = param.locale, canBeFloat = param.canBeFloat, onChange = param.onChange, fromInput = param.fromInput, toInput = param.toInput, testId = param.testId;
|
|
14668
|
-
var classes = useStyles$
|
|
14913
|
+
var classes = useStyles$t({
|
|
14669
14914
|
theme: tweakStyles
|
|
14670
14915
|
});
|
|
14671
14916
|
var translates = React.useMemo(function() {
|
|
@@ -14709,7 +14954,7 @@
|
|
|
14709
14954
|
className: "tweakClearButton",
|
|
14710
14955
|
currentComponentName: "FilterInterval"
|
|
14711
14956
|
});
|
|
14712
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
14957
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$t(_object_spread$x({
|
|
14713
14958
|
className: classes.root
|
|
14714
14959
|
}, addDataAttributes(data)), {
|
|
14715
14960
|
children: [
|
|
@@ -14806,7 +15051,7 @@
|
|
|
14806
15051
|
var key = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : DEFAULT_LOCALE, custom = arguments.length > 1 ? arguments[1] : void 0, custom2 = arguments.length > 2 ? arguments[2] : void 0;
|
|
14807
15052
|
return merge$1({}, MultiSelectLocales[key], custom, custom2);
|
|
14808
15053
|
};
|
|
14809
|
-
function _define_property$
|
|
15054
|
+
function _define_property$x(obj, key, value) {
|
|
14810
15055
|
if (key in obj) {
|
|
14811
15056
|
Object.defineProperty(obj, key, {
|
|
14812
15057
|
value,
|
|
@@ -14819,7 +15064,7 @@
|
|
|
14819
15064
|
}
|
|
14820
15065
|
return obj;
|
|
14821
15066
|
}
|
|
14822
|
-
function _object_spread$
|
|
15067
|
+
function _object_spread$w(target) {
|
|
14823
15068
|
for (var i = 1; i < arguments.length; i++) {
|
|
14824
15069
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
14825
15070
|
var ownKeys2 = Object.keys(source);
|
|
@@ -14829,19 +15074,19 @@
|
|
|
14829
15074
|
}));
|
|
14830
15075
|
}
|
|
14831
15076
|
ownKeys2.forEach(function(key) {
|
|
14832
|
-
_define_property$
|
|
15077
|
+
_define_property$x(target, key, source[key]);
|
|
14833
15078
|
});
|
|
14834
15079
|
}
|
|
14835
15080
|
return target;
|
|
14836
15081
|
}
|
|
14837
15082
|
var ITEM_HEIGHT$1 = 40;
|
|
14838
15083
|
var TOP_GAP = 12;
|
|
14839
|
-
var useStyles$
|
|
15084
|
+
var useStyles$s = createThemedStyles("MultiSelectList", {
|
|
14840
15085
|
root: {
|
|
14841
15086
|
width: 220,
|
|
14842
15087
|
background: colors.CLASSIC_WHITE
|
|
14843
15088
|
},
|
|
14844
|
-
list: _object_spread$
|
|
15089
|
+
list: _object_spread$w({
|
|
14845
15090
|
paddingTop: TOP_GAP,
|
|
14846
15091
|
maxHeight: ITEM_HEIGHT$1 * 5 + TOP_GAP,
|
|
14847
15092
|
overscrollBehavior: "contain"
|
|
@@ -14954,20 +15199,20 @@
|
|
|
14954
15199
|
}
|
|
14955
15200
|
}
|
|
14956
15201
|
};
|
|
14957
|
-
function _array_like_to_array$
|
|
15202
|
+
function _array_like_to_array$d(arr, len) {
|
|
14958
15203
|
if (len == null || len > arr.length)
|
|
14959
15204
|
len = arr.length;
|
|
14960
15205
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
14961
15206
|
arr2[i] = arr[i];
|
|
14962
15207
|
return arr2;
|
|
14963
15208
|
}
|
|
14964
|
-
function _array_with_holes$
|
|
15209
|
+
function _array_with_holes$d(arr) {
|
|
14965
15210
|
if (Array.isArray(arr))
|
|
14966
15211
|
return arr;
|
|
14967
15212
|
}
|
|
14968
|
-
function _array_without_holes$
|
|
15213
|
+
function _array_without_holes$3(arr) {
|
|
14969
15214
|
if (Array.isArray(arr))
|
|
14970
|
-
return _array_like_to_array$
|
|
15215
|
+
return _array_like_to_array$d(arr);
|
|
14971
15216
|
}
|
|
14972
15217
|
function asyncGeneratorStep$2(gen, resolve, reject, _next, _throw, key, arg) {
|
|
14973
15218
|
try {
|
|
@@ -14998,7 +15243,7 @@
|
|
|
14998
15243
|
});
|
|
14999
15244
|
};
|
|
15000
15245
|
}
|
|
15001
|
-
function _define_property$
|
|
15246
|
+
function _define_property$w(obj, key, value) {
|
|
15002
15247
|
if (key in obj) {
|
|
15003
15248
|
Object.defineProperty(obj, key, {
|
|
15004
15249
|
value,
|
|
@@ -15011,11 +15256,11 @@
|
|
|
15011
15256
|
}
|
|
15012
15257
|
return obj;
|
|
15013
15258
|
}
|
|
15014
|
-
function _iterable_to_array$
|
|
15259
|
+
function _iterable_to_array$3(iter) {
|
|
15015
15260
|
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
15016
15261
|
return Array.from(iter);
|
|
15017
15262
|
}
|
|
15018
|
-
function _iterable_to_array_limit$
|
|
15263
|
+
function _iterable_to_array_limit$d(arr, i) {
|
|
15019
15264
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
15020
15265
|
if (_i == null)
|
|
15021
15266
|
return;
|
|
@@ -15043,13 +15288,13 @@
|
|
|
15043
15288
|
}
|
|
15044
15289
|
return _arr;
|
|
15045
15290
|
}
|
|
15046
|
-
function _non_iterable_rest$
|
|
15291
|
+
function _non_iterable_rest$d() {
|
|
15047
15292
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
15048
15293
|
}
|
|
15049
|
-
function _non_iterable_spread$
|
|
15294
|
+
function _non_iterable_spread$3() {
|
|
15050
15295
|
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
15051
15296
|
}
|
|
15052
|
-
function _object_spread$
|
|
15297
|
+
function _object_spread$v(target) {
|
|
15053
15298
|
for (var i = 1; i < arguments.length; i++) {
|
|
15054
15299
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
15055
15300
|
var ownKeys2 = Object.keys(source);
|
|
@@ -15059,12 +15304,12 @@
|
|
|
15059
15304
|
}));
|
|
15060
15305
|
}
|
|
15061
15306
|
ownKeys2.forEach(function(key) {
|
|
15062
|
-
_define_property$
|
|
15307
|
+
_define_property$w(target, key, source[key]);
|
|
15063
15308
|
});
|
|
15064
15309
|
}
|
|
15065
15310
|
return target;
|
|
15066
15311
|
}
|
|
15067
|
-
function ownKeys$
|
|
15312
|
+
function ownKeys$s(object, enumerableOnly) {
|
|
15068
15313
|
var keys2 = Object.keys(object);
|
|
15069
15314
|
if (Object.getOwnPropertySymbols) {
|
|
15070
15315
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -15077,35 +15322,35 @@
|
|
|
15077
15322
|
}
|
|
15078
15323
|
return keys2;
|
|
15079
15324
|
}
|
|
15080
|
-
function _object_spread_props$
|
|
15325
|
+
function _object_spread_props$s(target, source) {
|
|
15081
15326
|
source = source != null ? source : {};
|
|
15082
15327
|
if (Object.getOwnPropertyDescriptors) {
|
|
15083
15328
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
15084
15329
|
} else {
|
|
15085
|
-
ownKeys$
|
|
15330
|
+
ownKeys$s(Object(source)).forEach(function(key) {
|
|
15086
15331
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
15087
15332
|
});
|
|
15088
15333
|
}
|
|
15089
15334
|
return target;
|
|
15090
15335
|
}
|
|
15091
|
-
function _sliced_to_array$
|
|
15092
|
-
return _array_with_holes$
|
|
15336
|
+
function _sliced_to_array$d(arr, i) {
|
|
15337
|
+
return _array_with_holes$d(arr) || _iterable_to_array_limit$d(arr, i) || _unsupported_iterable_to_array$d(arr, i) || _non_iterable_rest$d();
|
|
15093
15338
|
}
|
|
15094
|
-
function _to_consumable_array$
|
|
15095
|
-
return _array_without_holes$
|
|
15339
|
+
function _to_consumable_array$3(arr) {
|
|
15340
|
+
return _array_without_holes$3(arr) || _iterable_to_array$3(arr) || _unsupported_iterable_to_array$d(arr) || _non_iterable_spread$3();
|
|
15096
15341
|
}
|
|
15097
|
-
function _unsupported_iterable_to_array$
|
|
15342
|
+
function _unsupported_iterable_to_array$d(o, minLen) {
|
|
15098
15343
|
if (!o)
|
|
15099
15344
|
return;
|
|
15100
15345
|
if (typeof o === "string")
|
|
15101
|
-
return _array_like_to_array$
|
|
15346
|
+
return _array_like_to_array$d(o, minLen);
|
|
15102
15347
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
15103
15348
|
if (n === "Object" && o.constructor)
|
|
15104
15349
|
n = o.constructor.name;
|
|
15105
15350
|
if (n === "Map" || n === "Set")
|
|
15106
15351
|
return Array.from(n);
|
|
15107
15352
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
15108
|
-
return _array_like_to_array$
|
|
15353
|
+
return _array_like_to_array$d(o, minLen);
|
|
15109
15354
|
}
|
|
15110
15355
|
function _ts_generator$2(thisArg, body) {
|
|
15111
15356
|
var f, y, t, g, _ = {
|
|
@@ -15212,7 +15457,7 @@
|
|
|
15212
15457
|
function MultiSelectList(param) {
|
|
15213
15458
|
var value = param.value, tweakStyles = param.tweakStyles, data = param.data, _param_isSearchEnabled = param.isSearchEnabled, isSearchEnabled = _param_isSearchEnabled === void 0 ? false : _param_isSearchEnabled, _param_localeKey = param.localeKey, localeKey = _param_localeKey === void 0 ? DEFAULT_LOCALE : _param_localeKey, _param_locale = param.locale, locale2 = _param_locale === void 0 ? MultiSelectLocales[localeKey] : _param_locale, onChange = param.onChange, onClose = param.onClose, options = param.options, fetchOptions = param.fetchOptions, _param_isGroupingEnabled = param.isGroupingEnabled, isGroupingEnabled = _param_isGroupingEnabled === void 0 ? isSearchEnabled : _param_isGroupingEnabled, _param_getValueView = param.getValueView, getValueView = _param_getValueView === void 0 ? defaultConvertFunction : _param_getValueView, _param_getValueId = param.getValueId, getValueId = _param_getValueId === void 0 ? defaultConvertFunction : _param_getValueId, _param_getValueString = param.getValueString, getValueString = _param_getValueString === void 0 ? defaultConvertFunction : _param_getValueString, _param_checkboxPosition = param.checkboxPosition, checkboxPosition = _param_checkboxPosition === void 0 ? "left" : _param_checkboxPosition, pageSize = param.pageSize, searchMaxLength = param.searchMaxLength, testId = param.testId;
|
|
15214
15459
|
var isMounted = useIsMounted();
|
|
15215
|
-
var classes = useStyles$
|
|
15460
|
+
var classes = useStyles$s({
|
|
15216
15461
|
theme: tweakStyles
|
|
15217
15462
|
});
|
|
15218
15463
|
var tweakCheckboxStyles = useTweakStyles({
|
|
@@ -15233,13 +15478,13 @@
|
|
|
15233
15478
|
className: "tweakClearButton",
|
|
15234
15479
|
currentComponentName: "MultiSelectList"
|
|
15235
15480
|
});
|
|
15236
|
-
var _useState = _sliced_to_array$
|
|
15237
|
-
var _useState1 = _sliced_to_array$
|
|
15238
|
-
var _useState2 = _sliced_to_array$
|
|
15239
|
-
var _useState3 = _sliced_to_array$
|
|
15240
|
-
var _useState4 = _sliced_to_array$
|
|
15241
|
-
var _useState5 = _sliced_to_array$
|
|
15242
|
-
var _useState6 = _sliced_to_array$
|
|
15481
|
+
var _useState = _sliced_to_array$d(React.useState(0), 2), keyCursorOn = _useState[0], setKeyCursorOn = _useState[1];
|
|
15482
|
+
var _useState1 = _sliced_to_array$d(React.useState(""), 2), searchValue = _useState1[0], setSearchValue = _useState1[1];
|
|
15483
|
+
var _useState2 = _sliced_to_array$d(React.useState([]), 2), allOptions = _useState2[0], setAllOptions = _useState2[1];
|
|
15484
|
+
var _useState3 = _sliced_to_array$d(React.useState(false), 2), isLoading = _useState3[0], setIsLoading = _useState3[1];
|
|
15485
|
+
var _useState4 = _sliced_to_array$d(React.useState(false), 2), isLoadingOptionsOnScroll = _useState4[0], setLoadingOptionsOnScroll = _useState4[1];
|
|
15486
|
+
var _useState5 = _sliced_to_array$d(React.useState(0), 2), activePage = _useState5[0], setActivePage = _useState5[1];
|
|
15487
|
+
var _useState6 = _sliced_to_array$d(React.useState(false), 2), isMaxPage = _useState6[0], setIsMaxPage = _useState6[1];
|
|
15243
15488
|
var observer = React.useRef();
|
|
15244
15489
|
var chosenValues = value === null || value === void 0 ? void 0 : value.include;
|
|
15245
15490
|
var translates = React.useMemo(function() {
|
|
@@ -15352,7 +15597,7 @@
|
|
|
15352
15597
|
var checkboxValue = param2.value, isSelected = param2.isSelected;
|
|
15353
15598
|
if (trueReactPlatformHelpers.isNotEmpty(checkboxValue)) {
|
|
15354
15599
|
var _chosenValues_filter;
|
|
15355
|
-
handleSelectValue(isSelected ? _to_consumable_array$
|
|
15600
|
+
handleSelectValue(isSelected ? _to_consumable_array$3(chosenValues !== null && chosenValues !== void 0 ? chosenValues : []).concat([
|
|
15356
15601
|
checkboxValue
|
|
15357
15602
|
]) : (_chosenValues_filter = chosenValues === null || chosenValues === void 0 ? void 0 : chosenValues.filter(function(v) {
|
|
15358
15603
|
return getValueId(v) !== getValueId(checkboxValue);
|
|
@@ -15384,14 +15629,14 @@
|
|
|
15384
15629
|
if (value !== void 0) {
|
|
15385
15630
|
if (keyCursorOn < value.include.length) {
|
|
15386
15631
|
var _value_include_filter;
|
|
15387
|
-
onChange(_object_spread_props$
|
|
15632
|
+
onChange(_object_spread_props$s(_object_spread$v({}, value), {
|
|
15388
15633
|
include: (_value_include_filter = value.include.filter(function(val) {
|
|
15389
15634
|
return getValueId(val) !== getValueId(value.include[keyCursorOn]);
|
|
15390
15635
|
})) !== null && _value_include_filter !== void 0 ? _value_include_filter : []
|
|
15391
15636
|
}));
|
|
15392
15637
|
} else {
|
|
15393
|
-
onChange(_object_spread_props$
|
|
15394
|
-
include: _to_consumable_array$
|
|
15638
|
+
onChange(_object_spread_props$s(_object_spread$v({}, value), {
|
|
15639
|
+
include: _to_consumable_array$3(value.include).concat([
|
|
15395
15640
|
unchosenOptions[keyCursorOn - value.include.length]
|
|
15396
15641
|
])
|
|
15397
15642
|
}));
|
|
@@ -15439,7 +15684,7 @@
|
|
|
15439
15684
|
if (isMounted()) {
|
|
15440
15685
|
if (response.length > 0) {
|
|
15441
15686
|
setAllOptions(function(prevState) {
|
|
15442
|
-
return _to_consumable_array$
|
|
15687
|
+
return _to_consumable_array$3(prevState).concat(_to_consumable_array$3(response));
|
|
15443
15688
|
});
|
|
15444
15689
|
}
|
|
15445
15690
|
if (response.length === 0 || pageSize !== void 0 && response.length < pageSize) {
|
|
@@ -15589,7 +15834,7 @@
|
|
|
15589
15834
|
var shouldShowAllOptionsLabel = hasSelectedOptionsGroup && (trueReactPlatformHelpers.isArrayNotEmpty(unchosenOptions) || !trueReactPlatformHelpers.isArrayNotEmpty(allOptions));
|
|
15590
15835
|
var shouldShowPreloader = isLoading || isLoadingOptionsOnScroll;
|
|
15591
15836
|
var shouldShowOptionsList = !isLoading && (trueReactPlatformHelpers.isArrayNotEmpty(allOptions) || trueReactPlatformHelpers.isArrayNotEmpty(chosenValues));
|
|
15592
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
15837
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$s(_object_spread$v({
|
|
15593
15838
|
className: classes.root
|
|
15594
15839
|
}, addDataAttributes(data)), {
|
|
15595
15840
|
children: [
|
|
@@ -15693,7 +15938,7 @@
|
|
|
15693
15938
|
]
|
|
15694
15939
|
}));
|
|
15695
15940
|
}
|
|
15696
|
-
function _define_property$
|
|
15941
|
+
function _define_property$v(obj, key, value) {
|
|
15697
15942
|
if (key in obj) {
|
|
15698
15943
|
Object.defineProperty(obj, key, {
|
|
15699
15944
|
value,
|
|
@@ -15706,7 +15951,7 @@
|
|
|
15706
15951
|
}
|
|
15707
15952
|
return obj;
|
|
15708
15953
|
}
|
|
15709
|
-
function _object_spread$
|
|
15954
|
+
function _object_spread$u(target) {
|
|
15710
15955
|
for (var i = 1; i < arguments.length; i++) {
|
|
15711
15956
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
15712
15957
|
var ownKeys2 = Object.keys(source);
|
|
@@ -15716,15 +15961,15 @@
|
|
|
15716
15961
|
}));
|
|
15717
15962
|
}
|
|
15718
15963
|
ownKeys2.forEach(function(key) {
|
|
15719
|
-
_define_property$
|
|
15964
|
+
_define_property$v(target, key, source[key]);
|
|
15720
15965
|
});
|
|
15721
15966
|
}
|
|
15722
15967
|
return target;
|
|
15723
15968
|
}
|
|
15724
15969
|
function FilterMultiSelect(props) {
|
|
15725
|
-
return /* @__PURE__ */ jsx(MultiSelectList, _object_spread$
|
|
15970
|
+
return /* @__PURE__ */ jsx(MultiSelectList, _object_spread$u({}, props));
|
|
15726
15971
|
}
|
|
15727
|
-
function _define_property$
|
|
15972
|
+
function _define_property$u(obj, key, value) {
|
|
15728
15973
|
if (key in obj) {
|
|
15729
15974
|
Object.defineProperty(obj, key, {
|
|
15730
15975
|
value,
|
|
@@ -15737,7 +15982,7 @@
|
|
|
15737
15982
|
}
|
|
15738
15983
|
return obj;
|
|
15739
15984
|
}
|
|
15740
|
-
function _object_spread$
|
|
15985
|
+
function _object_spread$t(target) {
|
|
15741
15986
|
for (var i = 1; i < arguments.length; i++) {
|
|
15742
15987
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
15743
15988
|
var ownKeys2 = Object.keys(source);
|
|
@@ -15747,19 +15992,19 @@
|
|
|
15747
15992
|
}));
|
|
15748
15993
|
}
|
|
15749
15994
|
ownKeys2.forEach(function(key) {
|
|
15750
|
-
_define_property$
|
|
15995
|
+
_define_property$u(target, key, source[key]);
|
|
15751
15996
|
});
|
|
15752
15997
|
}
|
|
15753
15998
|
return target;
|
|
15754
15999
|
}
|
|
15755
16000
|
var ITEM_HEIGHT = 40;
|
|
15756
16001
|
var LIST_GAP = 12;
|
|
15757
|
-
var useStyles$
|
|
16002
|
+
var useStyles$r = createThemedStyles("FilterSelect", {
|
|
15758
16003
|
root: {
|
|
15759
16004
|
width: 220,
|
|
15760
16005
|
background: colors.CLASSIC_WHITE
|
|
15761
16006
|
},
|
|
15762
|
-
list: _object_spread$
|
|
16007
|
+
list: _object_spread$t({
|
|
15763
16008
|
paddingTop: LIST_GAP,
|
|
15764
16009
|
padding: [
|
|
15765
16010
|
LIST_GAP,
|
|
@@ -15888,20 +16133,20 @@
|
|
|
15888
16133
|
}
|
|
15889
16134
|
};
|
|
15890
16135
|
var clearButtonStyles$1 = cloneDeep(innerTextButtonStyles);
|
|
15891
|
-
function _array_like_to_array$
|
|
16136
|
+
function _array_like_to_array$c(arr, len) {
|
|
15892
16137
|
if (len == null || len > arr.length)
|
|
15893
16138
|
len = arr.length;
|
|
15894
16139
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
15895
16140
|
arr2[i] = arr[i];
|
|
15896
16141
|
return arr2;
|
|
15897
16142
|
}
|
|
15898
|
-
function _array_with_holes$
|
|
16143
|
+
function _array_with_holes$c(arr) {
|
|
15899
16144
|
if (Array.isArray(arr))
|
|
15900
16145
|
return arr;
|
|
15901
16146
|
}
|
|
15902
|
-
function _array_without_holes$
|
|
16147
|
+
function _array_without_holes$2(arr) {
|
|
15903
16148
|
if (Array.isArray(arr))
|
|
15904
|
-
return _array_like_to_array$
|
|
16149
|
+
return _array_like_to_array$c(arr);
|
|
15905
16150
|
}
|
|
15906
16151
|
function asyncGeneratorStep$1(gen, resolve, reject, _next, _throw, key, arg) {
|
|
15907
16152
|
try {
|
|
@@ -15932,7 +16177,7 @@
|
|
|
15932
16177
|
});
|
|
15933
16178
|
};
|
|
15934
16179
|
}
|
|
15935
|
-
function _define_property$
|
|
16180
|
+
function _define_property$t(obj, key, value) {
|
|
15936
16181
|
if (key in obj) {
|
|
15937
16182
|
Object.defineProperty(obj, key, {
|
|
15938
16183
|
value,
|
|
@@ -15945,11 +16190,11 @@
|
|
|
15945
16190
|
}
|
|
15946
16191
|
return obj;
|
|
15947
16192
|
}
|
|
15948
|
-
function _iterable_to_array$
|
|
16193
|
+
function _iterable_to_array$2(iter) {
|
|
15949
16194
|
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
15950
16195
|
return Array.from(iter);
|
|
15951
16196
|
}
|
|
15952
|
-
function _iterable_to_array_limit$
|
|
16197
|
+
function _iterable_to_array_limit$c(arr, i) {
|
|
15953
16198
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
15954
16199
|
if (_i == null)
|
|
15955
16200
|
return;
|
|
@@ -15977,13 +16222,13 @@
|
|
|
15977
16222
|
}
|
|
15978
16223
|
return _arr;
|
|
15979
16224
|
}
|
|
15980
|
-
function _non_iterable_rest$
|
|
16225
|
+
function _non_iterable_rest$c() {
|
|
15981
16226
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
15982
16227
|
}
|
|
15983
|
-
function _non_iterable_spread$
|
|
16228
|
+
function _non_iterable_spread$2() {
|
|
15984
16229
|
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
15985
16230
|
}
|
|
15986
|
-
function _object_spread$
|
|
16231
|
+
function _object_spread$s(target) {
|
|
15987
16232
|
for (var i = 1; i < arguments.length; i++) {
|
|
15988
16233
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
15989
16234
|
var ownKeys2 = Object.keys(source);
|
|
@@ -15993,12 +16238,12 @@
|
|
|
15993
16238
|
}));
|
|
15994
16239
|
}
|
|
15995
16240
|
ownKeys2.forEach(function(key) {
|
|
15996
|
-
_define_property$
|
|
16241
|
+
_define_property$t(target, key, source[key]);
|
|
15997
16242
|
});
|
|
15998
16243
|
}
|
|
15999
16244
|
return target;
|
|
16000
16245
|
}
|
|
16001
|
-
function ownKeys$
|
|
16246
|
+
function ownKeys$r(object, enumerableOnly) {
|
|
16002
16247
|
var keys2 = Object.keys(object);
|
|
16003
16248
|
if (Object.getOwnPropertySymbols) {
|
|
16004
16249
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -16011,35 +16256,35 @@
|
|
|
16011
16256
|
}
|
|
16012
16257
|
return keys2;
|
|
16013
16258
|
}
|
|
16014
|
-
function _object_spread_props$
|
|
16259
|
+
function _object_spread_props$r(target, source) {
|
|
16015
16260
|
source = source != null ? source : {};
|
|
16016
16261
|
if (Object.getOwnPropertyDescriptors) {
|
|
16017
16262
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
16018
16263
|
} else {
|
|
16019
|
-
ownKeys$
|
|
16264
|
+
ownKeys$r(Object(source)).forEach(function(key) {
|
|
16020
16265
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
16021
16266
|
});
|
|
16022
16267
|
}
|
|
16023
16268
|
return target;
|
|
16024
16269
|
}
|
|
16025
|
-
function _sliced_to_array$
|
|
16026
|
-
return _array_with_holes$
|
|
16270
|
+
function _sliced_to_array$c(arr, i) {
|
|
16271
|
+
return _array_with_holes$c(arr) || _iterable_to_array_limit$c(arr, i) || _unsupported_iterable_to_array$c(arr, i) || _non_iterable_rest$c();
|
|
16027
16272
|
}
|
|
16028
|
-
function _to_consumable_array$
|
|
16029
|
-
return _array_without_holes$
|
|
16273
|
+
function _to_consumable_array$2(arr) {
|
|
16274
|
+
return _array_without_holes$2(arr) || _iterable_to_array$2(arr) || _unsupported_iterable_to_array$c(arr) || _non_iterable_spread$2();
|
|
16030
16275
|
}
|
|
16031
|
-
function _unsupported_iterable_to_array$
|
|
16276
|
+
function _unsupported_iterable_to_array$c(o, minLen) {
|
|
16032
16277
|
if (!o)
|
|
16033
16278
|
return;
|
|
16034
16279
|
if (typeof o === "string")
|
|
16035
|
-
return _array_like_to_array$
|
|
16280
|
+
return _array_like_to_array$c(o, minLen);
|
|
16036
16281
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
16037
16282
|
if (n === "Object" && o.constructor)
|
|
16038
16283
|
n = o.constructor.name;
|
|
16039
16284
|
if (n === "Map" || n === "Set")
|
|
16040
16285
|
return Array.from(n);
|
|
16041
16286
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
16042
|
-
return _array_like_to_array$
|
|
16287
|
+
return _array_like_to_array$c(o, minLen);
|
|
16043
16288
|
}
|
|
16044
16289
|
function _ts_generator$1(thisArg, body) {
|
|
16045
16290
|
var f, y, t, g, _ = {
|
|
@@ -16145,7 +16390,7 @@
|
|
|
16145
16390
|
}
|
|
16146
16391
|
function FilterSelect(param) {
|
|
16147
16392
|
var data = param.data, tweakStyles = param.tweakStyles, value = param.value, _param_isSearchEnabled = param.isSearchEnabled, isSearchEnabled = _param_isSearchEnabled === void 0 ? false : _param_isSearchEnabled, _param_isGroupingEnabled = param.isGroupingEnabled, isGroupingEnabled = _param_isGroupingEnabled === void 0 ? false : _param_isGroupingEnabled, localeKey = param.localeKey, locale2 = param.locale, onChange = param.onChange, onClose = param.onClose, options = param.options, fetchOptions = param.fetchOptions, footer = param.footer, _param_getValueView = param.getValueView, getValueView = _param_getValueView === void 0 ? defaultConvertFunction$1 : _param_getValueView, _param_getValueId = param.getValueId, getValueId = _param_getValueId === void 0 ? defaultConvertFunction$1 : _param_getValueId, _param_getValueString = param.getValueString, getValueString = _param_getValueString === void 0 ? defaultConvertFunction$1 : _param_getValueString, _param_hasClearButton = param.hasClearButton, hasClearButton = _param_hasClearButton === void 0 ? true : _param_hasClearButton, testId = param.testId;
|
|
16148
|
-
var classes = useStyles$
|
|
16393
|
+
var classes = useStyles$r({
|
|
16149
16394
|
theme: tweakStyles
|
|
16150
16395
|
});
|
|
16151
16396
|
var tweakSearchInputStyles = useTweakStyles({
|
|
@@ -16168,12 +16413,12 @@
|
|
|
16168
16413
|
locale2
|
|
16169
16414
|
]);
|
|
16170
16415
|
var observer = React.useRef();
|
|
16171
|
-
var _useState = _sliced_to_array$
|
|
16172
|
-
var _useState1 = _sliced_to_array$
|
|
16173
|
-
var _useState2 = _sliced_to_array$
|
|
16174
|
-
var _useState3 = _sliced_to_array$
|
|
16175
|
-
var _useState4 = _sliced_to_array$
|
|
16176
|
-
var _useState5 = _sliced_to_array$
|
|
16416
|
+
var _useState = _sliced_to_array$c(React.useState(""), 2), searchValue = _useState[0], setSearchValue = _useState[1];
|
|
16417
|
+
var _useState1 = _sliced_to_array$c(React.useState([]), 2), allOptions = _useState1[0], setAllOptions = _useState1[1];
|
|
16418
|
+
var _useState2 = _sliced_to_array$c(React.useState(0), 2), activePage = _useState2[0], setActivePage = _useState2[1];
|
|
16419
|
+
var _useState3 = _sliced_to_array$c(React.useState(false), 2), isMaxPage = _useState3[0], setIsMaxPage = _useState3[1];
|
|
16420
|
+
var _useState4 = _sliced_to_array$c(React.useState(false), 2), isLoading = _useState4[0], setIsLoading = _useState4[1];
|
|
16421
|
+
var _useState5 = _sliced_to_array$c(React.useState(false), 2), isLoadingOptionsOnScroll = _useState5[0], setLoadingOptionsOnScroll = _useState5[1];
|
|
16177
16422
|
var shouldShowPreloader = isLoading || isLoadingOptionsOnScroll;
|
|
16178
16423
|
var hasFooter = trueReactPlatformHelpers.isReactNodeNotEmpty(footer);
|
|
16179
16424
|
var handleSearchInputChange = React.useCallback(function() {
|
|
@@ -16289,7 +16534,7 @@
|
|
|
16289
16534
|
if (isMounted()) {
|
|
16290
16535
|
if (response.length > 0) {
|
|
16291
16536
|
setAllOptions(function(prevState) {
|
|
16292
|
-
return _to_consumable_array$
|
|
16537
|
+
return _to_consumable_array$2(prevState).concat(_to_consumable_array$2(response));
|
|
16293
16538
|
});
|
|
16294
16539
|
} else {
|
|
16295
16540
|
setIsMaxPage(true);
|
|
@@ -16420,7 +16665,7 @@
|
|
|
16420
16665
|
}();
|
|
16421
16666
|
doFetchOptions();
|
|
16422
16667
|
}, []);
|
|
16423
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
16668
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$r(_object_spread$s({
|
|
16424
16669
|
className: classes.root
|
|
16425
16670
|
}, addDataAttributes(data)), {
|
|
16426
16671
|
children: [
|
|
@@ -16520,7 +16765,7 @@
|
|
|
16520
16765
|
children: translates.nothingFound
|
|
16521
16766
|
}),
|
|
16522
16767
|
(hasClearButton || hasFooter) && /* @__PURE__ */ jsxs("div", {
|
|
16523
|
-
className: clsx(classes.panel, _define_property$
|
|
16768
|
+
className: clsx(classes.panel, _define_property$t({}, classes.panelWithFooter, hasFooter)),
|
|
16524
16769
|
children: [
|
|
16525
16770
|
hasFooter && /* @__PURE__ */ jsx("div", {
|
|
16526
16771
|
className: classes.footer,
|
|
@@ -17633,7 +17878,7 @@
|
|
|
17633
17878
|
}
|
|
17634
17879
|
};
|
|
17635
17880
|
const ru = locale;
|
|
17636
|
-
var useStyles$
|
|
17881
|
+
var useStyles$q = createThemedStyles("FilterWithDates", {
|
|
17637
17882
|
root: {
|
|
17638
17883
|
background: colors.CLASSIC_WHITE,
|
|
17639
17884
|
position: "relative",
|
|
@@ -17689,18 +17934,18 @@
|
|
|
17689
17934
|
marginLeft: END_PICKER_LEFT_MARGIN
|
|
17690
17935
|
}
|
|
17691
17936
|
};
|
|
17692
|
-
function _array_like_to_array$
|
|
17937
|
+
function _array_like_to_array$b(arr, len) {
|
|
17693
17938
|
if (len == null || len > arr.length)
|
|
17694
17939
|
len = arr.length;
|
|
17695
17940
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
17696
17941
|
arr2[i] = arr[i];
|
|
17697
17942
|
return arr2;
|
|
17698
17943
|
}
|
|
17699
|
-
function _array_with_holes$
|
|
17944
|
+
function _array_with_holes$b(arr) {
|
|
17700
17945
|
if (Array.isArray(arr))
|
|
17701
17946
|
return arr;
|
|
17702
17947
|
}
|
|
17703
|
-
function _define_property$
|
|
17948
|
+
function _define_property$s(obj, key, value) {
|
|
17704
17949
|
if (key in obj) {
|
|
17705
17950
|
Object.defineProperty(obj, key, {
|
|
17706
17951
|
value,
|
|
@@ -17713,7 +17958,7 @@
|
|
|
17713
17958
|
}
|
|
17714
17959
|
return obj;
|
|
17715
17960
|
}
|
|
17716
|
-
function _iterable_to_array_limit$
|
|
17961
|
+
function _iterable_to_array_limit$b(arr, i) {
|
|
17717
17962
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
17718
17963
|
if (_i == null)
|
|
17719
17964
|
return;
|
|
@@ -17741,10 +17986,10 @@
|
|
|
17741
17986
|
}
|
|
17742
17987
|
return _arr;
|
|
17743
17988
|
}
|
|
17744
|
-
function _non_iterable_rest$
|
|
17989
|
+
function _non_iterable_rest$b() {
|
|
17745
17990
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
17746
17991
|
}
|
|
17747
|
-
function _object_spread$
|
|
17992
|
+
function _object_spread$r(target) {
|
|
17748
17993
|
for (var i = 1; i < arguments.length; i++) {
|
|
17749
17994
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
17750
17995
|
var ownKeys2 = Object.keys(source);
|
|
@@ -17754,12 +17999,12 @@
|
|
|
17754
17999
|
}));
|
|
17755
18000
|
}
|
|
17756
18001
|
ownKeys2.forEach(function(key) {
|
|
17757
|
-
_define_property$
|
|
18002
|
+
_define_property$s(target, key, source[key]);
|
|
17758
18003
|
});
|
|
17759
18004
|
}
|
|
17760
18005
|
return target;
|
|
17761
18006
|
}
|
|
17762
|
-
function ownKeys$
|
|
18007
|
+
function ownKeys$q(object, enumerableOnly) {
|
|
17763
18008
|
var keys2 = Object.keys(object);
|
|
17764
18009
|
if (Object.getOwnPropertySymbols) {
|
|
17765
18010
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -17772,36 +18017,36 @@
|
|
|
17772
18017
|
}
|
|
17773
18018
|
return keys2;
|
|
17774
18019
|
}
|
|
17775
|
-
function _object_spread_props$
|
|
18020
|
+
function _object_spread_props$q(target, source) {
|
|
17776
18021
|
source = source != null ? source : {};
|
|
17777
18022
|
if (Object.getOwnPropertyDescriptors) {
|
|
17778
18023
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
17779
18024
|
} else {
|
|
17780
|
-
ownKeys$
|
|
18025
|
+
ownKeys$q(Object(source)).forEach(function(key) {
|
|
17781
18026
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
17782
18027
|
});
|
|
17783
18028
|
}
|
|
17784
18029
|
return target;
|
|
17785
18030
|
}
|
|
17786
|
-
function _sliced_to_array$
|
|
17787
|
-
return _array_with_holes$
|
|
18031
|
+
function _sliced_to_array$b(arr, i) {
|
|
18032
|
+
return _array_with_holes$b(arr) || _iterable_to_array_limit$b(arr, i) || _unsupported_iterable_to_array$b(arr, i) || _non_iterable_rest$b();
|
|
17788
18033
|
}
|
|
17789
|
-
function _unsupported_iterable_to_array$
|
|
18034
|
+
function _unsupported_iterable_to_array$b(o, minLen) {
|
|
17790
18035
|
if (!o)
|
|
17791
18036
|
return;
|
|
17792
18037
|
if (typeof o === "string")
|
|
17793
|
-
return _array_like_to_array$
|
|
18038
|
+
return _array_like_to_array$b(o, minLen);
|
|
17794
18039
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
17795
18040
|
if (n === "Object" && o.constructor)
|
|
17796
18041
|
n = o.constructor.name;
|
|
17797
18042
|
if (n === "Map" || n === "Set")
|
|
17798
18043
|
return Array.from(n);
|
|
17799
18044
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
17800
|
-
return _array_like_to_array$
|
|
18045
|
+
return _array_like_to_array$b(o, minLen);
|
|
17801
18046
|
}
|
|
17802
18047
|
var FilterWithDates = function(param) {
|
|
17803
18048
|
var value = param.value, onChange = param.onChange, localeKey = param.localeKey, locale2 = param.locale, onStartBtnSubmit = param.onStartBtnSubmit, onEndBtnSubmit = param.onEndBtnSubmit, data = param.data, tweakStyles = param.tweakStyles, testId = param.testId, _param_startPickerProps = param.startPickerProps, startPickerProps = _param_startPickerProps === void 0 ? DEFAULT_PICKER_PROPS : _param_startPickerProps, _param_endPickerProps = param.endPickerProps, endPickerProps = _param_endPickerProps === void 0 ? DEFAULT_PICKER_PROPS : _param_endPickerProps, _param_isClearable = param.isClearable, isClearable = _param_isClearable === void 0 ? true : _param_isClearable;
|
|
17804
|
-
var classes = useStyles$
|
|
18049
|
+
var classes = useStyles$q({
|
|
17805
18050
|
theme: tweakStyles
|
|
17806
18051
|
});
|
|
17807
18052
|
var tweakClearButtonStyles = useTweakStyles({
|
|
@@ -17829,8 +18074,8 @@
|
|
|
17829
18074
|
className: "tweakEndDatePicker",
|
|
17830
18075
|
currentComponentName: "FilterWithDates"
|
|
17831
18076
|
});
|
|
17832
|
-
var _useState = _sliced_to_array$
|
|
17833
|
-
var _useState1 = _sliced_to_array$
|
|
18077
|
+
var _useState = _sliced_to_array$b(React.useState(false), 2), isOpenFrom = _useState[0], setOpenFrom = _useState[1];
|
|
18078
|
+
var _useState1 = _sliced_to_array$b(React.useState(false), 2), isOpenTo = _useState1[0], setOpenTo = _useState1[1];
|
|
17834
18079
|
var ref = React.useRef(null);
|
|
17835
18080
|
var dateLocale = localeKey === "ru" ? ru : enUS;
|
|
17836
18081
|
var translates = React.useMemo(function() {
|
|
@@ -17888,7 +18133,7 @@
|
|
|
17888
18133
|
}
|
|
17889
18134
|
};
|
|
17890
18135
|
var _ref;
|
|
17891
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
18136
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$q(_object_spread$r({
|
|
17892
18137
|
className: classes.root
|
|
17893
18138
|
}, addDataAttributes(data)), {
|
|
17894
18139
|
children: [
|
|
@@ -17897,7 +18142,7 @@
|
|
|
17897
18142
|
children: [
|
|
17898
18143
|
/* @__PURE__ */ jsx("div", {
|
|
17899
18144
|
className: classes.containerItem,
|
|
17900
|
-
children: /* @__PURE__ */ jsx(DatePicker, _object_spread$
|
|
18145
|
+
children: /* @__PURE__ */ jsx(DatePicker, _object_spread$r({
|
|
17901
18146
|
selectedDate: value === null || value === void 0 ? void 0 : value.from,
|
|
17902
18147
|
maxDate: value === null || value === void 0 ? void 0 : value.to,
|
|
17903
18148
|
label: translates.from,
|
|
@@ -17912,7 +18157,7 @@
|
|
|
17912
18157
|
}),
|
|
17913
18158
|
/* @__PURE__ */ jsx("div", {
|
|
17914
18159
|
className: classes.containerItem,
|
|
17915
|
-
children: /* @__PURE__ */ jsx(DatePicker, _object_spread$
|
|
18160
|
+
children: /* @__PURE__ */ jsx(DatePicker, _object_spread$r({
|
|
17916
18161
|
selectedDate: value === null || value === void 0 ? void 0 : value.to,
|
|
17917
18162
|
label: translates.to,
|
|
17918
18163
|
months: translates.months,
|
|
@@ -17968,7 +18213,7 @@
|
|
|
17968
18213
|
]
|
|
17969
18214
|
}));
|
|
17970
18215
|
};
|
|
17971
|
-
var useStyles$
|
|
18216
|
+
var useStyles$p = createThemedStyles("FilterWithPeriod", {
|
|
17972
18217
|
root: {},
|
|
17973
18218
|
main: {},
|
|
17974
18219
|
picker: {}
|
|
@@ -17978,22 +18223,22 @@
|
|
|
17978
18223
|
maxHeight: "auto"
|
|
17979
18224
|
}
|
|
17980
18225
|
};
|
|
17981
|
-
function _array_like_to_array$
|
|
18226
|
+
function _array_like_to_array$a(arr, len) {
|
|
17982
18227
|
if (len == null || len > arr.length)
|
|
17983
18228
|
len = arr.length;
|
|
17984
18229
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
17985
18230
|
arr2[i] = arr[i];
|
|
17986
18231
|
return arr2;
|
|
17987
18232
|
}
|
|
17988
|
-
function _array_with_holes$
|
|
18233
|
+
function _array_with_holes$a(arr) {
|
|
17989
18234
|
if (Array.isArray(arr))
|
|
17990
18235
|
return arr;
|
|
17991
18236
|
}
|
|
17992
|
-
function _array_without_holes$
|
|
18237
|
+
function _array_without_holes$1(arr) {
|
|
17993
18238
|
if (Array.isArray(arr))
|
|
17994
|
-
return _array_like_to_array$
|
|
18239
|
+
return _array_like_to_array$a(arr);
|
|
17995
18240
|
}
|
|
17996
|
-
function _define_property$
|
|
18241
|
+
function _define_property$r(obj, key, value) {
|
|
17997
18242
|
if (key in obj) {
|
|
17998
18243
|
Object.defineProperty(obj, key, {
|
|
17999
18244
|
value,
|
|
@@ -18006,11 +18251,11 @@
|
|
|
18006
18251
|
}
|
|
18007
18252
|
return obj;
|
|
18008
18253
|
}
|
|
18009
|
-
function _iterable_to_array$
|
|
18254
|
+
function _iterable_to_array$1(iter) {
|
|
18010
18255
|
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
18011
18256
|
return Array.from(iter);
|
|
18012
18257
|
}
|
|
18013
|
-
function _iterable_to_array_limit$
|
|
18258
|
+
function _iterable_to_array_limit$a(arr, i) {
|
|
18014
18259
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
18015
18260
|
if (_i == null)
|
|
18016
18261
|
return;
|
|
@@ -18038,13 +18283,13 @@
|
|
|
18038
18283
|
}
|
|
18039
18284
|
return _arr;
|
|
18040
18285
|
}
|
|
18041
|
-
function _non_iterable_rest$
|
|
18286
|
+
function _non_iterable_rest$a() {
|
|
18042
18287
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
18043
18288
|
}
|
|
18044
|
-
function _non_iterable_spread$
|
|
18289
|
+
function _non_iterable_spread$1() {
|
|
18045
18290
|
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
18046
18291
|
}
|
|
18047
|
-
function _object_spread$
|
|
18292
|
+
function _object_spread$q(target) {
|
|
18048
18293
|
for (var i = 1; i < arguments.length; i++) {
|
|
18049
18294
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
18050
18295
|
var ownKeys2 = Object.keys(source);
|
|
@@ -18054,12 +18299,12 @@
|
|
|
18054
18299
|
}));
|
|
18055
18300
|
}
|
|
18056
18301
|
ownKeys2.forEach(function(key) {
|
|
18057
|
-
_define_property$
|
|
18302
|
+
_define_property$r(target, key, source[key]);
|
|
18058
18303
|
});
|
|
18059
18304
|
}
|
|
18060
18305
|
return target;
|
|
18061
18306
|
}
|
|
18062
|
-
function ownKeys$
|
|
18307
|
+
function ownKeys$p(object, enumerableOnly) {
|
|
18063
18308
|
var keys2 = Object.keys(object);
|
|
18064
18309
|
if (Object.getOwnPropertySymbols) {
|
|
18065
18310
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -18072,39 +18317,39 @@
|
|
|
18072
18317
|
}
|
|
18073
18318
|
return keys2;
|
|
18074
18319
|
}
|
|
18075
|
-
function _object_spread_props$
|
|
18320
|
+
function _object_spread_props$p(target, source) {
|
|
18076
18321
|
source = source != null ? source : {};
|
|
18077
18322
|
if (Object.getOwnPropertyDescriptors) {
|
|
18078
18323
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
18079
18324
|
} else {
|
|
18080
|
-
ownKeys$
|
|
18325
|
+
ownKeys$p(Object(source)).forEach(function(key) {
|
|
18081
18326
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
18082
18327
|
});
|
|
18083
18328
|
}
|
|
18084
18329
|
return target;
|
|
18085
18330
|
}
|
|
18086
|
-
function _sliced_to_array$
|
|
18087
|
-
return _array_with_holes$
|
|
18331
|
+
function _sliced_to_array$a(arr, i) {
|
|
18332
|
+
return _array_with_holes$a(arr) || _iterable_to_array_limit$a(arr, i) || _unsupported_iterable_to_array$a(arr, i) || _non_iterable_rest$a();
|
|
18088
18333
|
}
|
|
18089
|
-
function _to_consumable_array$
|
|
18090
|
-
return _array_without_holes$
|
|
18334
|
+
function _to_consumable_array$1(arr) {
|
|
18335
|
+
return _array_without_holes$1(arr) || _iterable_to_array$1(arr) || _unsupported_iterable_to_array$a(arr) || _non_iterable_spread$1();
|
|
18091
18336
|
}
|
|
18092
|
-
function _unsupported_iterable_to_array$
|
|
18337
|
+
function _unsupported_iterable_to_array$a(o, minLen) {
|
|
18093
18338
|
if (!o)
|
|
18094
18339
|
return;
|
|
18095
18340
|
if (typeof o === "string")
|
|
18096
|
-
return _array_like_to_array$
|
|
18341
|
+
return _array_like_to_array$a(o, minLen);
|
|
18097
18342
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
18098
18343
|
if (n === "Object" && o.constructor)
|
|
18099
18344
|
n = o.constructor.name;
|
|
18100
18345
|
if (n === "Map" || n === "Set")
|
|
18101
18346
|
return Array.from(n);
|
|
18102
18347
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
18103
|
-
return _array_like_to_array$
|
|
18348
|
+
return _array_like_to_array$a(o, minLen);
|
|
18104
18349
|
}
|
|
18105
18350
|
var FilterWithPeriod = function(param) {
|
|
18106
18351
|
var value = param.value, localeKey = param.localeKey, locale2 = param.locale, onChange = param.onChange, onClose = param.onClose, periods = param.periods, tweakStyles = param.tweakStyles, testId = param.testId;
|
|
18107
|
-
var classes = useStyles$
|
|
18352
|
+
var classes = useStyles$p({
|
|
18108
18353
|
theme: tweakStyles
|
|
18109
18354
|
});
|
|
18110
18355
|
var translates = React.useMemo(function() {
|
|
@@ -18113,11 +18358,11 @@
|
|
|
18113
18358
|
localeKey,
|
|
18114
18359
|
locale2
|
|
18115
18360
|
]);
|
|
18116
|
-
var _useState = _sliced_to_array$
|
|
18117
|
-
var _useState1 = _sliced_to_array$
|
|
18118
|
-
var _useState2 = _sliced_to_array$
|
|
18361
|
+
var _useState = _sliced_to_array$a(React.useState((value === null || value === void 0 ? void 0 : value.periodType) !== "CUSTOM"), 2), isPeriodPickerShown = _useState[0], setIsPeriodPickerShown = _useState[1];
|
|
18362
|
+
var _useState1 = _sliced_to_array$a(React.useState((value === null || value === void 0 ? void 0 : value.periodType) === "CUSTOM"), 2), isDatePickerShown = _useState1[0], setIsDatePickerShown = _useState1[1];
|
|
18363
|
+
var _useState2 = _sliced_to_array$a(React.useState(value), 2), period = _useState2[0], setPeriod = _useState2[1];
|
|
18119
18364
|
var periodGetters = React.useMemo(function() {
|
|
18120
|
-
var result = _object_spread$
|
|
18365
|
+
var result = _object_spread$q({}, PERIODS_GETTERS);
|
|
18121
18366
|
periods === null || periods === void 0 ? void 0 : periods.forEach(function(p) {
|
|
18122
18367
|
if (Array.isArray(p)) {
|
|
18123
18368
|
result[p[0]] = p[1];
|
|
@@ -18129,7 +18374,7 @@
|
|
|
18129
18374
|
]);
|
|
18130
18375
|
var periodsList = React.useMemo(function() {
|
|
18131
18376
|
if (periods === void 0) {
|
|
18132
|
-
return _to_consumable_array$
|
|
18377
|
+
return _to_consumable_array$1(PERIODS);
|
|
18133
18378
|
}
|
|
18134
18379
|
return periods.map(function(p) {
|
|
18135
18380
|
return Array.isArray(p) ? p[0] : p;
|
|
@@ -18163,7 +18408,7 @@
|
|
|
18163
18408
|
if (onClose !== void 0) {
|
|
18164
18409
|
onClose();
|
|
18165
18410
|
}
|
|
18166
|
-
onChange(_object_spread_props$
|
|
18411
|
+
onChange(_object_spread_props$p(_object_spread$q({}, p), {
|
|
18167
18412
|
label: getPeriodTranslate(periodType)
|
|
18168
18413
|
}));
|
|
18169
18414
|
}
|
|
@@ -18183,7 +18428,7 @@
|
|
|
18183
18428
|
};
|
|
18184
18429
|
var handleCustomDateChange = function(val) {
|
|
18185
18430
|
if (val.from || val.to) {
|
|
18186
|
-
onChange(_object_spread_props$
|
|
18431
|
+
onChange(_object_spread_props$p(_object_spread$q({}, val), {
|
|
18187
18432
|
periodType: "CUSTOM"
|
|
18188
18433
|
}));
|
|
18189
18434
|
} else {
|
|
@@ -18255,7 +18500,7 @@
|
|
|
18255
18500
|
]
|
|
18256
18501
|
});
|
|
18257
18502
|
};
|
|
18258
|
-
function _define_property$
|
|
18503
|
+
function _define_property$q(obj, key, value) {
|
|
18259
18504
|
if (key in obj) {
|
|
18260
18505
|
Object.defineProperty(obj, key, {
|
|
18261
18506
|
value,
|
|
@@ -18268,7 +18513,7 @@
|
|
|
18268
18513
|
}
|
|
18269
18514
|
return obj;
|
|
18270
18515
|
}
|
|
18271
|
-
function _object_spread$
|
|
18516
|
+
function _object_spread$p(target) {
|
|
18272
18517
|
for (var i = 1; i < arguments.length; i++) {
|
|
18273
18518
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
18274
18519
|
var ownKeys2 = Object.keys(source);
|
|
@@ -18278,12 +18523,12 @@
|
|
|
18278
18523
|
}));
|
|
18279
18524
|
}
|
|
18280
18525
|
ownKeys2.forEach(function(key) {
|
|
18281
|
-
_define_property$
|
|
18526
|
+
_define_property$q(target, key, source[key]);
|
|
18282
18527
|
});
|
|
18283
18528
|
}
|
|
18284
18529
|
return target;
|
|
18285
18530
|
}
|
|
18286
|
-
function ownKeys$
|
|
18531
|
+
function ownKeys$o(object, enumerableOnly) {
|
|
18287
18532
|
var keys2 = Object.keys(object);
|
|
18288
18533
|
if (Object.getOwnPropertySymbols) {
|
|
18289
18534
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -18296,12 +18541,12 @@
|
|
|
18296
18541
|
}
|
|
18297
18542
|
return keys2;
|
|
18298
18543
|
}
|
|
18299
|
-
function _object_spread_props$
|
|
18544
|
+
function _object_spread_props$o(target, source) {
|
|
18300
18545
|
source = source != null ? source : {};
|
|
18301
18546
|
if (Object.getOwnPropertyDescriptors) {
|
|
18302
18547
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
18303
18548
|
} else {
|
|
18304
|
-
ownKeys$
|
|
18549
|
+
ownKeys$o(Object(source)).forEach(function(key) {
|
|
18305
18550
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
18306
18551
|
});
|
|
18307
18552
|
}
|
|
@@ -18319,7 +18564,7 @@
|
|
|
18319
18564
|
filter.locale
|
|
18320
18565
|
]);
|
|
18321
18566
|
if (filter.type === "select") {
|
|
18322
|
-
return /* @__PURE__ */ jsx(FilterSelect, _object_spread$
|
|
18567
|
+
return /* @__PURE__ */ jsx(FilterSelect, _object_spread$p({
|
|
18323
18568
|
value,
|
|
18324
18569
|
onChange,
|
|
18325
18570
|
onClose,
|
|
@@ -18329,8 +18574,8 @@
|
|
|
18329
18574
|
}, filter));
|
|
18330
18575
|
}
|
|
18331
18576
|
if (filter.type === "dateRange") {
|
|
18332
|
-
return /* @__PURE__ */ jsx(FilterWithPeriod, _object_spread$
|
|
18333
|
-
value: _object_spread$
|
|
18577
|
+
return /* @__PURE__ */ jsx(FilterWithPeriod, _object_spread$p({
|
|
18578
|
+
value: _object_spread$p({}, value),
|
|
18334
18579
|
onChange,
|
|
18335
18580
|
onClose,
|
|
18336
18581
|
localeKey: translatesLocaleKey,
|
|
@@ -18343,10 +18588,10 @@
|
|
|
18343
18588
|
style: {
|
|
18344
18589
|
width: 320
|
|
18345
18590
|
},
|
|
18346
|
-
children: /* @__PURE__ */ jsx(FilterWithDates, _object_spread$
|
|
18591
|
+
children: /* @__PURE__ */ jsx(FilterWithDates, _object_spread$p({
|
|
18347
18592
|
value,
|
|
18348
18593
|
onChange: function(v) {
|
|
18349
|
-
return onChange(_object_spread_props$
|
|
18594
|
+
return onChange(_object_spread_props$o(_object_spread$p({}, v), {
|
|
18350
18595
|
periodType: "CUSTOM"
|
|
18351
18596
|
}));
|
|
18352
18597
|
},
|
|
@@ -18360,7 +18605,7 @@
|
|
|
18360
18605
|
});
|
|
18361
18606
|
}
|
|
18362
18607
|
if (filter.type === "multiSelect") {
|
|
18363
|
-
return /* @__PURE__ */ jsx(FilterMultiSelect, _object_spread$
|
|
18608
|
+
return /* @__PURE__ */ jsx(FilterMultiSelect, _object_spread$p({
|
|
18364
18609
|
value,
|
|
18365
18610
|
onChange,
|
|
18366
18611
|
onClose,
|
|
@@ -18370,7 +18615,7 @@
|
|
|
18370
18615
|
}, filter));
|
|
18371
18616
|
}
|
|
18372
18617
|
if (filter.type === "interval") {
|
|
18373
|
-
return /* @__PURE__ */ jsx(FilterInterval, _object_spread$
|
|
18618
|
+
return /* @__PURE__ */ jsx(FilterInterval, _object_spread$p({
|
|
18374
18619
|
value,
|
|
18375
18620
|
onChange,
|
|
18376
18621
|
localeKey: translatesLocaleKey,
|
|
@@ -18384,14 +18629,14 @@
|
|
|
18384
18629
|
}
|
|
18385
18630
|
if (filter.type === "custom" && filter.component) {
|
|
18386
18631
|
var Component = filter.component;
|
|
18387
|
-
return /* @__PURE__ */ jsx(Component, _object_spread_props$
|
|
18632
|
+
return /* @__PURE__ */ jsx(Component, _object_spread_props$o(_object_spread$p({}, props), {
|
|
18388
18633
|
filter
|
|
18389
18634
|
}));
|
|
18390
18635
|
}
|
|
18391
18636
|
console.warn("%cДля фильтра ".concat(filter.name, " не задан тип или component"), "background: red; color: black");
|
|
18392
18637
|
return null;
|
|
18393
18638
|
}
|
|
18394
|
-
var useStyles$
|
|
18639
|
+
var useStyles$o = createThemedStyles("FiltersPaneSearch", {
|
|
18395
18640
|
root: {
|
|
18396
18641
|
display: "flex",
|
|
18397
18642
|
position: "relative",
|
|
@@ -18489,18 +18734,18 @@
|
|
|
18489
18734
|
width: "100%"
|
|
18490
18735
|
}
|
|
18491
18736
|
};
|
|
18492
|
-
function _array_like_to_array$
|
|
18737
|
+
function _array_like_to_array$9(arr, len) {
|
|
18493
18738
|
if (len == null || len > arr.length)
|
|
18494
18739
|
len = arr.length;
|
|
18495
18740
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
18496
18741
|
arr2[i] = arr[i];
|
|
18497
18742
|
return arr2;
|
|
18498
18743
|
}
|
|
18499
|
-
function _array_with_holes$
|
|
18744
|
+
function _array_with_holes$9(arr) {
|
|
18500
18745
|
if (Array.isArray(arr))
|
|
18501
18746
|
return arr;
|
|
18502
18747
|
}
|
|
18503
|
-
function _define_property$
|
|
18748
|
+
function _define_property$p(obj, key, value) {
|
|
18504
18749
|
if (key in obj) {
|
|
18505
18750
|
Object.defineProperty(obj, key, {
|
|
18506
18751
|
value,
|
|
@@ -18513,7 +18758,7 @@
|
|
|
18513
18758
|
}
|
|
18514
18759
|
return obj;
|
|
18515
18760
|
}
|
|
18516
|
-
function _iterable_to_array_limit$
|
|
18761
|
+
function _iterable_to_array_limit$9(arr, i) {
|
|
18517
18762
|
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
18518
18763
|
if (_i == null)
|
|
18519
18764
|
return;
|
|
@@ -18541,10 +18786,10 @@
|
|
|
18541
18786
|
}
|
|
18542
18787
|
return _arr;
|
|
18543
18788
|
}
|
|
18544
|
-
function _non_iterable_rest$
|
|
18789
|
+
function _non_iterable_rest$9() {
|
|
18545
18790
|
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
18546
18791
|
}
|
|
18547
|
-
function _object_spread$
|
|
18792
|
+
function _object_spread$o(target) {
|
|
18548
18793
|
for (var i = 1; i < arguments.length; i++) {
|
|
18549
18794
|
var source = arguments[i] != null ? arguments[i] : {};
|
|
18550
18795
|
var ownKeys2 = Object.keys(source);
|
|
@@ -18554,12 +18799,12 @@
|
|
|
18554
18799
|
}));
|
|
18555
18800
|
}
|
|
18556
18801
|
ownKeys2.forEach(function(key) {
|
|
18557
|
-
_define_property$
|
|
18802
|
+
_define_property$p(target, key, source[key]);
|
|
18558
18803
|
});
|
|
18559
18804
|
}
|
|
18560
18805
|
return target;
|
|
18561
18806
|
}
|
|
18562
|
-
function ownKeys$
|
|
18807
|
+
function ownKeys$n(object, enumerableOnly) {
|
|
18563
18808
|
var keys2 = Object.keys(object);
|
|
18564
18809
|
if (Object.getOwnPropertySymbols) {
|
|
18565
18810
|
var symbols = Object.getOwnPropertySymbols(object);
|
|
@@ -18572,36 +18817,36 @@
|
|
|
18572
18817
|
}
|
|
18573
18818
|
return keys2;
|
|
18574
18819
|
}
|
|
18575
|
-
function _object_spread_props$
|
|
18820
|
+
function _object_spread_props$n(target, source) {
|
|
18576
18821
|
source = source != null ? source : {};
|
|
18577
18822
|
if (Object.getOwnPropertyDescriptors) {
|
|
18578
18823
|
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
18579
18824
|
} else {
|
|
18580
|
-
ownKeys$
|
|
18825
|
+
ownKeys$n(Object(source)).forEach(function(key) {
|
|
18581
18826
|
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
18582
18827
|
});
|
|
18583
18828
|
}
|
|
18584
18829
|
return target;
|
|
18585
18830
|
}
|
|
18586
|
-
function _sliced_to_array$
|
|
18587
|
-
return _array_with_holes$
|
|
18831
|
+
function _sliced_to_array$9(arr, i) {
|
|
18832
|
+
return _array_with_holes$9(arr) || _iterable_to_array_limit$9(arr, i) || _unsupported_iterable_to_array$9(arr, i) || _non_iterable_rest$9();
|
|
18588
18833
|
}
|
|
18589
|
-
function _unsupported_iterable_to_array$
|
|
18834
|
+
function _unsupported_iterable_to_array$9(o, minLen) {
|
|
18590
18835
|
if (!o)
|
|
18591
18836
|
return;
|
|
18592
18837
|
if (typeof o === "string")
|
|
18593
|
-
return _array_like_to_array$
|
|
18838
|
+
return _array_like_to_array$9(o, minLen);
|
|
18594
18839
|
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
18595
18840
|
if (n === "Object" && o.constructor)
|
|
18596
18841
|
n = o.constructor.name;
|
|
18597
18842
|
if (n === "Map" || n === "Set")
|
|
18598
18843
|
return Array.from(n);
|
|
18599
18844
|
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
18600
|
-
return _array_like_to_array$
|
|
18845
|
+
return _array_like_to_array$9(o, minLen);
|
|
18601
18846
|
}
|
|
18602
18847
|
function FiltersPaneSearch(param) {
|
|
18603
18848
|
var value = param.value, _param_fields = param.fields, fields = _param_fields === void 0 ? [] : _param_fields, field = param.field, onChange = param.onChange, localeKey = param.localeKey, locale2 = param.locale, getValueId = param.getValueId, getValueView = param.getValueView, getValueString = param.getValueString, hasClearSelectButton = param.hasClearSelectButton, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, _param_isSelectSearchEnabled = param.isSelectSearchEnabled, isSelectSearchEnabled = _param_isSelectSearchEnabled === void 0 ? true : _param_isSelectSearchEnabled, _param_isAutoSizeable = param.isAutoSizeable, isAutoSizeable = _param_isAutoSizeable === void 0 ? true : _param_isAutoSizeable, maxLength = param.maxLength, data = param.data, tweakStyles = param.tweakStyles, testId = param.testId;
|
|
18604
|
-
var classes = useStyles$
|
|
18849
|
+
var classes = useStyles$o({
|
|
18605
18850
|
theme: tweakStyles
|
|
18606
18851
|
});
|
|
18607
18852
|
var tweakSearchInputStyles = useTweakStyles({
|
|
@@ -18616,8 +18861,8 @@
|
|
|
18616
18861
|
className: "tweakSelect",
|
|
18617
18862
|
currentComponentName: "FiltersPaneSearch"
|
|
18618
18863
|
});
|
|
18619
|
-
var _useState = _sliced_to_array$
|
|
18620
|
-
var _useState1 = _sliced_to_array$
|
|
18864
|
+
var _useState = _sliced_to_array$9(React.useState(false), 2), isInputFocused = _useState[0], setIsInputFocused = _useState[1];
|
|
18865
|
+
var _useState1 = _sliced_to_array$9(React.useState(false), 2), isOpen = _useState1[0], setIsOpen = _useState1[1];
|
|
18621
18866
|
var refRoot = React.useRef(null);
|
|
18622
18867
|
var translates = React.useMemo(function() {
|
|
18623
18868
|
return getLocale$1(localeKey, locale2);
|
|
@@ -18647,8 +18892,8 @@
|
|
|
18647
18892
|
field
|
|
18648
18893
|
]);
|
|
18649
18894
|
var _obj2;
|
|
18650
|
-
return /* @__PURE__ */ jsxs("div", _object_spread_props$
|
|
18651
|
-
className: clsx(classes.root, (_obj2 = {}, _define_property$
|
|
18895
|
+
return /* @__PURE__ */ jsxs("div", _object_spread_props$n(_object_spread$o({
|
|
18896
|
+
className: clsx(classes.root, (_obj2 = {}, _define_property$p(_obj2, classes.focused, isInputFocused), _define_property$p(_obj2, classes.disabled, isDisabled), _obj2)),
|
|
18652
18897
|
ref: refRoot,
|
|
18653
18898
|
"data-testid": testId
|
|
18654
18899
|
}, addDataAttributes(data)), {
|
|
@@ -18713,7 +18958,7 @@
|
|
|
18713
18958
|
]
|
|
18714
18959
|
}));
|
|
18715
18960
|
}
|
|
18716
|
-
var useStyles$
|
|
18961
|
+
var useStyles$n = createThemedStyles("FilterValueView", {
|
|
18717
18962
|
text: {
|
|
18718
18963
|
overflow: "hidden",
|
|
18719
18964
|
textOverflow: "ellipsis",
|
|
@@ -18732,7 +18977,7 @@
|
|
|
18732
18977
|
}
|
|
18733
18978
|
function FilterValueView(param) {
|
|
18734
18979
|
var locale2 = param.locale, localeKey = param.localeKey, filter = param.filter, value = param.value, tweakStyles = param.tweakStyles;
|
|
18735
|
-
var classes = useStyles$
|
|
18980
|
+
var classes = useStyles$n({
|
|
18736
18981
|
theme: tweakStyles
|
|
18737
18982
|
});
|
|
18738
18983
|
var _filter_localeKey;
|
|
@@ -18883,247 +19128,6 @@
|
|
|
18883
19128
|
children: displayValue(value)
|
|
18884
19129
|
});
|
|
18885
19130
|
}
|
|
18886
|
-
var DEFAULT_OFFSET = 6;
|
|
18887
|
-
var useStyles$n = createThemedStyles("WithPopup", {
|
|
18888
|
-
trigger: {
|
|
18889
|
-
width: "fit-content",
|
|
18890
|
-
cursor: "pointer"
|
|
18891
|
-
},
|
|
18892
|
-
disabled: {
|
|
18893
|
-
cursor: "default"
|
|
18894
|
-
},
|
|
18895
|
-
popup: {
|
|
18896
|
-
zIndex: 5,
|
|
18897
|
-
outline: "none"
|
|
18898
|
-
},
|
|
18899
|
-
animationEnd: {},
|
|
18900
|
-
animationStart: {},
|
|
18901
|
-
"dropdown-initial": {
|
|
18902
|
-
extend: "animationEnd"
|
|
18903
|
-
},
|
|
18904
|
-
"dropdown-open": {
|
|
18905
|
-
extend: "animationStart"
|
|
18906
|
-
},
|
|
18907
|
-
"dropdown-close": {
|
|
18908
|
-
visibility: "hidden",
|
|
18909
|
-
extend: "animationEnd"
|
|
18910
|
-
},
|
|
18911
|
-
"dropdown-unmounted": {
|
|
18912
|
-
extend: "animationEnd"
|
|
18913
|
-
}
|
|
18914
|
-
});
|
|
18915
|
-
function _array_like_to_array$9(arr, len) {
|
|
18916
|
-
if (len == null || len > arr.length)
|
|
18917
|
-
len = arr.length;
|
|
18918
|
-
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
18919
|
-
arr2[i] = arr[i];
|
|
18920
|
-
return arr2;
|
|
18921
|
-
}
|
|
18922
|
-
function _array_with_holes$9(arr) {
|
|
18923
|
-
if (Array.isArray(arr))
|
|
18924
|
-
return arr;
|
|
18925
|
-
}
|
|
18926
|
-
function _array_without_holes$1(arr) {
|
|
18927
|
-
if (Array.isArray(arr))
|
|
18928
|
-
return _array_like_to_array$9(arr);
|
|
18929
|
-
}
|
|
18930
|
-
function _define_property$p(obj, key, value) {
|
|
18931
|
-
if (key in obj) {
|
|
18932
|
-
Object.defineProperty(obj, key, {
|
|
18933
|
-
value,
|
|
18934
|
-
enumerable: true,
|
|
18935
|
-
configurable: true,
|
|
18936
|
-
writable: true
|
|
18937
|
-
});
|
|
18938
|
-
} else {
|
|
18939
|
-
obj[key] = value;
|
|
18940
|
-
}
|
|
18941
|
-
return obj;
|
|
18942
|
-
}
|
|
18943
|
-
function _iterable_to_array$1(iter) {
|
|
18944
|
-
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null)
|
|
18945
|
-
return Array.from(iter);
|
|
18946
|
-
}
|
|
18947
|
-
function _iterable_to_array_limit$9(arr, i) {
|
|
18948
|
-
var _i = arr == null ? null : typeof Symbol !== "undefined" && arr[Symbol.iterator] || arr["@@iterator"];
|
|
18949
|
-
if (_i == null)
|
|
18950
|
-
return;
|
|
18951
|
-
var _arr = [];
|
|
18952
|
-
var _n = true;
|
|
18953
|
-
var _d = false;
|
|
18954
|
-
var _s, _e;
|
|
18955
|
-
try {
|
|
18956
|
-
for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
|
|
18957
|
-
_arr.push(_s.value);
|
|
18958
|
-
if (i && _arr.length === i)
|
|
18959
|
-
break;
|
|
18960
|
-
}
|
|
18961
|
-
} catch (err) {
|
|
18962
|
-
_d = true;
|
|
18963
|
-
_e = err;
|
|
18964
|
-
} finally {
|
|
18965
|
-
try {
|
|
18966
|
-
if (!_n && _i["return"] != null)
|
|
18967
|
-
_i["return"]();
|
|
18968
|
-
} finally {
|
|
18969
|
-
if (_d)
|
|
18970
|
-
throw _e;
|
|
18971
|
-
}
|
|
18972
|
-
}
|
|
18973
|
-
return _arr;
|
|
18974
|
-
}
|
|
18975
|
-
function _non_iterable_rest$9() {
|
|
18976
|
-
throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
18977
|
-
}
|
|
18978
|
-
function _non_iterable_spread$1() {
|
|
18979
|
-
throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
18980
|
-
}
|
|
18981
|
-
function _object_spread$o(target) {
|
|
18982
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
18983
|
-
var source = arguments[i] != null ? arguments[i] : {};
|
|
18984
|
-
var ownKeys2 = Object.keys(source);
|
|
18985
|
-
if (typeof Object.getOwnPropertySymbols === "function") {
|
|
18986
|
-
ownKeys2 = ownKeys2.concat(Object.getOwnPropertySymbols(source).filter(function(sym) {
|
|
18987
|
-
return Object.getOwnPropertyDescriptor(source, sym).enumerable;
|
|
18988
|
-
}));
|
|
18989
|
-
}
|
|
18990
|
-
ownKeys2.forEach(function(key) {
|
|
18991
|
-
_define_property$p(target, key, source[key]);
|
|
18992
|
-
});
|
|
18993
|
-
}
|
|
18994
|
-
return target;
|
|
18995
|
-
}
|
|
18996
|
-
function ownKeys$n(object, enumerableOnly) {
|
|
18997
|
-
var keys2 = Object.keys(object);
|
|
18998
|
-
if (Object.getOwnPropertySymbols) {
|
|
18999
|
-
var symbols = Object.getOwnPropertySymbols(object);
|
|
19000
|
-
if (enumerableOnly) {
|
|
19001
|
-
symbols = symbols.filter(function(sym) {
|
|
19002
|
-
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
19003
|
-
});
|
|
19004
|
-
}
|
|
19005
|
-
keys2.push.apply(keys2, symbols);
|
|
19006
|
-
}
|
|
19007
|
-
return keys2;
|
|
19008
|
-
}
|
|
19009
|
-
function _object_spread_props$n(target, source) {
|
|
19010
|
-
source = source != null ? source : {};
|
|
19011
|
-
if (Object.getOwnPropertyDescriptors) {
|
|
19012
|
-
Object.defineProperties(target, Object.getOwnPropertyDescriptors(source));
|
|
19013
|
-
} else {
|
|
19014
|
-
ownKeys$n(Object(source)).forEach(function(key) {
|
|
19015
|
-
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
19016
|
-
});
|
|
19017
|
-
}
|
|
19018
|
-
return target;
|
|
19019
|
-
}
|
|
19020
|
-
function _sliced_to_array$9(arr, i) {
|
|
19021
|
-
return _array_with_holes$9(arr) || _iterable_to_array_limit$9(arr, i) || _unsupported_iterable_to_array$9(arr, i) || _non_iterable_rest$9();
|
|
19022
|
-
}
|
|
19023
|
-
function _to_consumable_array$1(arr) {
|
|
19024
|
-
return _array_without_holes$1(arr) || _iterable_to_array$1(arr) || _unsupported_iterable_to_array$9(arr) || _non_iterable_spread$1();
|
|
19025
|
-
}
|
|
19026
|
-
function _unsupported_iterable_to_array$9(o, minLen) {
|
|
19027
|
-
if (!o)
|
|
19028
|
-
return;
|
|
19029
|
-
if (typeof o === "string")
|
|
19030
|
-
return _array_like_to_array$9(o, minLen);
|
|
19031
|
-
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
19032
|
-
if (n === "Object" && o.constructor)
|
|
19033
|
-
n = o.constructor.name;
|
|
19034
|
-
if (n === "Map" || n === "Set")
|
|
19035
|
-
return Array.from(n);
|
|
19036
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))
|
|
19037
|
-
return _array_like_to_array$9(o, minLen);
|
|
19038
|
-
}
|
|
19039
|
-
var WithPopup = function(param) {
|
|
19040
|
-
var trigger = param.trigger, children = param.children, _param_middlewares = param.middlewares, middlewares = _param_middlewares === void 0 ? [] : _param_middlewares, _param_eventType = param.eventType, eventType = _param_eventType === void 0 ? "click" : _param_eventType, _param_placement = param.placement, placement = _param_placement === void 0 ? eventType === "click" ? "bottom-end" : "top" : _param_placement, _param_hoverDelay = param.hoverDelay, hoverDelay = _param_hoverDelay === void 0 ? 0 : _param_hoverDelay, _param_popupOffset = param.popupOffset, popupOffset = _param_popupOffset === void 0 ? DEFAULT_OFFSET : _param_popupOffset, _param_shouldHideOnScroll = param.shouldHideOnScroll, shouldHideOnScroll = _param_shouldHideOnScroll === void 0 ? false : _param_shouldHideOnScroll, _param_shouldRenderInBody = param.shouldRenderInBody, shouldRenderInBody = _param_shouldRenderInBody === void 0 ? true : _param_shouldRenderInBody, _param_canBeFlipped = param.canBeFlipped, canBeFlipped = _param_canBeFlipped === void 0 ? true : _param_canBeFlipped, _param_isTriggerWrapped = param.isTriggerWrapped, isTriggerWrapped = _param_isTriggerWrapped === void 0 ? eventType === "hover" : _param_isTriggerWrapped, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, tweakStyles = param.tweakStyles, data = param.data, testId = param.testId, onToggle = param.onToggle;
|
|
19041
|
-
var classes = useStyles$n({
|
|
19042
|
-
theme: tweakStyles
|
|
19043
|
-
});
|
|
19044
|
-
var _useState = _sliced_to_array$9(React.useState(false), 2), isOpen = _useState[0], setIsOpen = _useState[1];
|
|
19045
|
-
var handleToggle = function(isActive, event) {
|
|
19046
|
-
event === null || event === void 0 ? void 0 : event.stopPropagation();
|
|
19047
|
-
if (!isDisabled) {
|
|
19048
|
-
onToggle === null || onToggle === void 0 ? void 0 : onToggle(isActive, event);
|
|
19049
|
-
setIsOpen(isActive);
|
|
19050
|
-
}
|
|
19051
|
-
};
|
|
19052
|
-
var handleClose = function(event) {
|
|
19053
|
-
handleToggle(false, event);
|
|
19054
|
-
};
|
|
19055
|
-
var _useFloating = react.useFloating({
|
|
19056
|
-
open: isOpen,
|
|
19057
|
-
middleware: [
|
|
19058
|
-
react.offset(popupOffset)
|
|
19059
|
-
].concat(_to_consumable_array$1(canBeFlipped ? [
|
|
19060
|
-
react.flip()
|
|
19061
|
-
] : []), _to_consumable_array$1(middlewares)),
|
|
19062
|
-
whileElementsMounted: react.autoUpdate,
|
|
19063
|
-
placement,
|
|
19064
|
-
onOpenChange: handleToggle
|
|
19065
|
-
}), refs = _useFloating.refs, floatingStyles = _useFloating.floatingStyles, context = _useFloating.context;
|
|
19066
|
-
var hover = react.useHover(context, {
|
|
19067
|
-
enabled: eventType === "hover",
|
|
19068
|
-
delay: typeof hoverDelay === "number" ? {
|
|
19069
|
-
open: hoverDelay,
|
|
19070
|
-
close: 0
|
|
19071
|
-
} : hoverDelay,
|
|
19072
|
-
handleClose: react.safePolygon()
|
|
19073
|
-
});
|
|
19074
|
-
var focus = react.useFocus(context, {
|
|
19075
|
-
enabled: eventType === "hover"
|
|
19076
|
-
});
|
|
19077
|
-
var click = react.useClick(context, {
|
|
19078
|
-
enabled: eventType === "click"
|
|
19079
|
-
});
|
|
19080
|
-
var dismiss = react.useDismiss(context, {
|
|
19081
|
-
enabled: eventType === "click",
|
|
19082
|
-
ancestorScroll: shouldHideOnScroll
|
|
19083
|
-
});
|
|
19084
|
-
var _useInteractions = react.useInteractions([
|
|
19085
|
-
hover,
|
|
19086
|
-
click,
|
|
19087
|
-
focus,
|
|
19088
|
-
dismiss
|
|
19089
|
-
]), getFloatingProps = _useInteractions.getFloatingProps, getReferenceProps = _useInteractions.getReferenceProps;
|
|
19090
|
-
var _useTransitionStatus = react.useTransitionStatus(context, {
|
|
19091
|
-
duration: {
|
|
19092
|
-
close: 500
|
|
19093
|
-
}
|
|
19094
|
-
}), isMounted = _useTransitionStatus.isMounted, status = _useTransitionStatus.status;
|
|
19095
|
-
var referenceProps = getReferenceProps({
|
|
19096
|
-
ref: refs.setReference
|
|
19097
|
-
});
|
|
19098
|
-
var triggerElement = trueReactPlatformHelpers.applyAction(trigger, _object_spread$o({
|
|
19099
|
-
isActive: isOpen,
|
|
19100
|
-
isDisabled
|
|
19101
|
-
}, !isTriggerWrapped ? referenceProps : void 0));
|
|
19102
|
-
return /* @__PURE__ */ jsxs(Fragment, {
|
|
19103
|
-
children: [
|
|
19104
|
-
isTriggerWrapped ? /* @__PURE__ */ jsx("div", _object_spread_props$n(_object_spread$o({
|
|
19105
|
-
className: clsx(classes.trigger, _define_property$p({}, classes.disabled, isDisabled))
|
|
19106
|
-
}, referenceProps, trueReactPlatformHelpers.addDataTestId(testId), addDataAttributes(data)), {
|
|
19107
|
-
children: triggerElement
|
|
19108
|
-
})) : triggerElement,
|
|
19109
|
-
isMounted && /* @__PURE__ */ jsx(react.FloatingPortal, {
|
|
19110
|
-
root: !shouldRenderInBody ? refs.reference.current : void 0,
|
|
19111
|
-
children: /* @__PURE__ */ jsx("div", _object_spread_props$n(_object_spread$o({
|
|
19112
|
-
style: floatingStyles,
|
|
19113
|
-
className: classes.popup,
|
|
19114
|
-
ref: refs.setFloating
|
|
19115
|
-
}, getFloatingProps()), {
|
|
19116
|
-
children: /* @__PURE__ */ jsx("div", {
|
|
19117
|
-
className: classes["dropdown-".concat(status)],
|
|
19118
|
-
children: trueReactPlatformHelpers.isFunction(children) ? children({
|
|
19119
|
-
onClose: handleClose
|
|
19120
|
-
}) : children
|
|
19121
|
-
})
|
|
19122
|
-
}))
|
|
19123
|
-
})
|
|
19124
|
-
]
|
|
19125
|
-
});
|
|
19126
|
-
};
|
|
19127
19131
|
var isContentNotEmpty = function(value) {
|
|
19128
19132
|
if (Array.isArray(value)) {
|
|
19129
19133
|
return value.some(isContentNotEmpty);
|
|
@@ -19419,7 +19423,7 @@
|
|
|
19419
19423
|
}
|
|
19420
19424
|
function FiltersPane(param) {
|
|
19421
19425
|
var data = param.data, tweakStyles = param.tweakStyles, filtersConfig = param.filtersConfig, enabledFilters = param.enabledFilters, _param_values = param.values, values = _param_values === void 0 ? {} : _param_values, localeKey = param.localeKey, locale2 = param.locale, search = param.search, _param_isDisabled = param.isDisabled, isDisabled = _param_isDisabled === void 0 ? false : _param_isDisabled, _param_hasClearButton = param.hasClearButton, hasClearButton = _param_hasClearButton === void 0 ? true : _param_hasClearButton, testId = param.testId, onChangeFilters = param.onChangeFilters, onSettingsButtonClick = param.onSettingsButtonClick, onClear = param.onClear;
|
|
19422
|
-
var classes = useStyles$
|
|
19426
|
+
var classes = useStyles$u({
|
|
19423
19427
|
theme: tweakStyles
|
|
19424
19428
|
});
|
|
19425
19429
|
var tweakClearButtonStyles = useTweakStyles({
|