@epam/uui 5.2.0 → 5.3.0-rc.1
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/assets/styles/effects.scss +1 -1
- package/assets/styles/typography.scss +38 -35
- package/components/buttons/Button.d.ts +14 -0
- package/components/buttons/Button.d.ts.map +1 -0
- package/components/buttons/IconButton.d.ts +1 -1
- package/components/buttons/LinkButton.d.ts.map +1 -1
- package/components/buttons/TabButton.d.ts +2 -1
- package/components/buttons/TabButton.d.ts.map +1 -1
- package/components/buttons/index.d.ts +1 -1
- package/components/buttons/index.d.ts.map +1 -1
- package/components/datePickers/DatePickerBody.d.ts +1 -2
- package/components/datePickers/DatePickerBody.d.ts.map +1 -1
- package/components/dnd/DropMarker.d.ts.map +1 -1
- package/components/inputs/Checkbox.d.ts.map +1 -1
- package/components/inputs/Slider.d.ts +6 -0
- package/components/inputs/Slider.d.ts.map +1 -0
- package/components/inputs/index.d.ts +1 -0
- package/components/inputs/index.d.ts.map +1 -1
- package/components/layout/Accordion.d.ts.map +1 -1
- package/components/layout/FlexItems/FlexRow.d.ts +1 -0
- package/components/layout/FlexItems/FlexRow.d.ts.map +1 -1
- package/components/layout/FlexItems/Panel.d.ts +1 -0
- package/components/layout/FlexItems/Panel.d.ts.map +1 -1
- package/components/navigation/MainMenu/Burger/Burger.d.ts.map +1 -1
- package/components/navigation/MainMenu/Burger/BurgerButton.d.ts.map +1 -1
- package/components/navigation/MainMenu/Burger/BurgerGroupHeader.d.ts.map +1 -1
- package/components/navigation/MainMenu/Burger/BurgerSearch.d.ts.map +1 -1
- package/components/navigation/MainMenu/MainMenu.d.ts.map +1 -1
- package/components/navigation/MainMenu/MainMenuIcon.d.ts +1 -1
- package/components/navigation/MainMenu/MainMenuIcon.d.ts.map +1 -1
- package/components/overlays/Alert.d.ts +5 -5
- package/components/overlays/Alert.d.ts.map +1 -1
- package/components/overlays/DropdownContainer.d.ts.map +1 -1
- package/components/overlays/DropdownMenu.d.ts.map +1 -1
- package/components/overlays/Modals.d.ts.map +1 -1
- package/components/overlays/Tooltip.d.ts +1 -1
- package/components/pickers/DataPickerBody.d.ts.map +1 -1
- package/components/pickers/PickerInput.d.ts.map +1 -1
- package/components/tables/DataTable.d.ts +1 -0
- package/components/tables/DataTable.d.ts.map +1 -1
- package/components/tables/DataTableCell.d.ts +1 -0
- package/components/tables/DataTableCell.d.ts.map +1 -1
- package/components/tables/DataTableHeaderCell.d.ts +1 -0
- package/components/tables/DataTableHeaderCell.d.ts.map +1 -1
- package/components/tables/DataTableHeaderRow.d.ts +1 -0
- package/components/tables/DataTableHeaderRow.d.ts.map +1 -1
- package/components/tables/DataTableRow.d.ts +1 -0
- package/components/tables/DataTableRow.d.ts.map +1 -1
- package/components/tables/columnsConfigurationModal/PinIconButton.d.ts.map +1 -1
- package/components/types.d.ts +4 -6
- package/components/types.d.ts.map +1 -1
- package/components/typography/RichTextView.d.ts.map +1 -1
- package/components/typography/Text.d.ts +4 -2
- package/components/typography/Text.d.ts.map +1 -1
- package/components/widgets/Badge.d.ts +4 -2
- package/components/widgets/Badge.d.ts.map +1 -1
- package/components/widgets/CountIndicator.d.ts +8 -0
- package/components/widgets/CountIndicator.d.ts.map +1 -0
- package/components/widgets/ProgressBar.d.ts.map +1 -1
- package/components/widgets/StatusIndicator.d.ts +15 -0
- package/components/widgets/StatusIndicator.d.ts.map +1 -0
- package/components/widgets/Tag.d.ts +2 -1
- package/components/widgets/Tag.d.ts.map +1 -1
- package/components/widgets/index.d.ts +2 -0
- package/components/widgets/index.d.ts.map +1 -1
- package/index.d.ts +1 -0
- package/index.d.ts.map +1 -1
- package/index.esm.js +1565 -1454
- package/index.esm.js.map +1 -1
- package/index.js +1570 -1455
- package/index.js.map +1 -1
- package/package.json +5 -5
- package/stats.html +1 -1
- package/styles.css +9360 -3726
- package/styles.css.map +1 -1
- package/components/buttons/Button/Button.d.ts +0 -13
- package/components/buttons/Button/Button.d.ts.map +0 -1
- package/components/buttons/Button/index.d.ts +0 -2
- package/components/buttons/Button/index.d.ts.map +0 -1
package/index.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
+
var React = require('react');
|
|
3
4
|
var uuiComponents = require('@epam/uui-components');
|
|
4
5
|
var uuiCore = require('@epam/uui-core');
|
|
5
|
-
var
|
|
6
|
+
var cx = require('classnames');
|
|
6
7
|
var dayjs = require('dayjs');
|
|
7
8
|
var customParseFormat = require('dayjs/plugin/customParseFormat.js');
|
|
8
9
|
var updateLocale = require('dayjs/plugin/updateLocale.js');
|
|
9
|
-
var cx = require('classnames');
|
|
10
10
|
var localeData = require('dayjs/plugin/localeData');
|
|
11
|
-
var isoWeek = require('dayjs/plugin/isoWeek.js');
|
|
12
11
|
var sortBy = require('lodash.sortby');
|
|
12
|
+
var isoWeek = require('dayjs/plugin/isoWeek.js');
|
|
13
13
|
var FocusLock = require('react-focus-lock');
|
|
14
14
|
|
|
15
15
|
function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
|
|
@@ -32,15 +32,15 @@ function _interopNamespace(e) {
|
|
|
32
32
|
return Object.freeze(n);
|
|
33
33
|
}
|
|
34
34
|
|
|
35
|
-
var uuiComponents__namespace = /*#__PURE__*/_interopNamespace(uuiComponents);
|
|
36
35
|
var React__namespace = /*#__PURE__*/_interopNamespace(React);
|
|
36
|
+
var uuiComponents__namespace = /*#__PURE__*/_interopNamespace(uuiComponents);
|
|
37
|
+
var cx__default = /*#__PURE__*/_interopDefault(cx);
|
|
37
38
|
var dayjs__default = /*#__PURE__*/_interopDefault(dayjs);
|
|
38
39
|
var customParseFormat__default = /*#__PURE__*/_interopDefault(customParseFormat);
|
|
39
40
|
var updateLocale__default = /*#__PURE__*/_interopDefault(updateLocale);
|
|
40
|
-
var cx__default = /*#__PURE__*/_interopDefault(cx);
|
|
41
41
|
var localeData__default = /*#__PURE__*/_interopDefault(localeData);
|
|
42
|
-
var isoWeek__default = /*#__PURE__*/_interopDefault(isoWeek);
|
|
43
42
|
var sortBy__default = /*#__PURE__*/_interopDefault(sortBy);
|
|
43
|
+
var isoWeek__default = /*#__PURE__*/_interopDefault(isoWeek);
|
|
44
44
|
var FocusLock__default = /*#__PURE__*/_interopDefault(FocusLock);
|
|
45
45
|
|
|
46
46
|
var _path$1d;
|
|
@@ -602,36 +602,275 @@ const systemIcons = {
|
|
|
602
602
|
},
|
|
603
603
|
};
|
|
604
604
|
|
|
605
|
-
var
|
|
605
|
+
var css$1n = {"root":"_3yrNYH"};
|
|
606
|
+
|
|
607
|
+
const AvatarStack = uuiCore.withMods(uuiComponents.AvatarStack, () => [css$1n.root]);
|
|
608
|
+
|
|
609
|
+
var css$1m = {"root":"Luqjzj","size-24":"hqp2yC","size-18":"CWtD1X","size-12":"gP-GDE","size24":"hqp2yC","size18":"CWtD1X","size12":"gP-GDE"};
|
|
610
|
+
|
|
611
|
+
const CountIndicator = React.forwardRef((props, ref) => {
|
|
612
|
+
return (React__namespace.default.createElement("div", { ref: ref, className: cx__default.default([
|
|
613
|
+
css$1m.root,
|
|
614
|
+
'uui-count_indicator',
|
|
615
|
+
css$1m[`size-${props.size || 24}`],
|
|
616
|
+
props.color && `uui-color-${props.color}`,
|
|
617
|
+
props.cx,
|
|
618
|
+
]) }, props.caption));
|
|
619
|
+
});
|
|
620
|
+
|
|
621
|
+
var css$1l = {"uui-typography":"qKdfCX","hero-header":"_28cSe9","promo-header":"_9k-ESQ","uui-critical":"WEGK2o","uui-success":"I4jQ-0","uui-warning":"qcFmm4","uui-typography-size-12":"Kvo9tH","uui-typography-size-14":"R6ydKu","uui-typography-size-16":"dOdj4s","root":"-OXwOB","size-18":"Br3o3X","size-24":"JQue1N","size-30":"IEANf-","size-36":"kpAN3K","size-42":"cvz6B5","size-48":"mAmFTX","uuiTypography":"qKdfCX","heroHeader":"_28cSe9","promoHeader":"_9k-ESQ","uuiCritical":"WEGK2o","uuiSuccess":"I4jQ-0","uuiWarning":"qcFmm4","uuiTypographySize12":"Kvo9tH","uuiTypographySize14":"R6ydKu","uuiTypographySize16":"dOdj4s","size18":"Br3o3X","size24":"JQue1N","size30":"IEANf-","size36":"kpAN3K","size42":"cvz6B5","size48":"mAmFTX"};
|
|
622
|
+
|
|
623
|
+
const defaultSize$b = '36';
|
|
624
|
+
const mapSize$1 = {
|
|
625
|
+
48: '48',
|
|
626
|
+
42: '48',
|
|
627
|
+
36: '36',
|
|
628
|
+
30: '30',
|
|
629
|
+
24: '30',
|
|
630
|
+
18: '18',
|
|
631
|
+
};
|
|
632
|
+
function applyBadgeMods(mods) {
|
|
633
|
+
return [
|
|
634
|
+
'uui-badge',
|
|
635
|
+
css$1l.root,
|
|
636
|
+
css$1l['size-' + (mods.size || defaultSize$b)],
|
|
637
|
+
`uui-fill-${mods.fill || 'solid'}`,
|
|
638
|
+
mods.color && `uui-color-${mods.color}`,
|
|
639
|
+
mods.indicator && 'uui-indicator',
|
|
640
|
+
];
|
|
641
|
+
}
|
|
642
|
+
const mapCountIndicatorSizes$1 = {
|
|
643
|
+
18: '12',
|
|
644
|
+
24: '18',
|
|
645
|
+
30: '18',
|
|
646
|
+
36: '18',
|
|
647
|
+
42: '24',
|
|
648
|
+
48: '24',
|
|
649
|
+
};
|
|
650
|
+
const Badge = uuiCore.withMods(uuiComponents.Button, applyBadgeMods, (props) => {
|
|
651
|
+
if (process.env.NODE_ENV !== "production") {
|
|
652
|
+
uuiCore.devLogger.warnAboutDeprecatedPropValue({
|
|
653
|
+
component: 'Badge',
|
|
654
|
+
propName: 'size',
|
|
655
|
+
propValue: props.size,
|
|
656
|
+
propValueUseInstead: '42',
|
|
657
|
+
condition: () => ['48'].indexOf(props.size) !== -1,
|
|
658
|
+
});
|
|
659
|
+
}
|
|
660
|
+
return {
|
|
661
|
+
dropdownIcon: systemIcons[(props.size && mapSize$1[props.size]) || defaultSize$b].foldingArrow,
|
|
662
|
+
clearIcon: systemIcons[(props.size && mapSize$1[props.size]) || defaultSize$b].clear,
|
|
663
|
+
countPosition: 'left',
|
|
664
|
+
countIndicator: (countIndicatorProps) => (React__namespace.default.createElement(CountIndicator, Object.assign({}, countIndicatorProps, { color: null, size: mapCountIndicatorSizes$1[props.size || defaultSize$b] }))),
|
|
665
|
+
indicator: props.indicator || false,
|
|
666
|
+
};
|
|
667
|
+
});
|
|
668
|
+
|
|
669
|
+
var css$1k = {"uui-typography":"SLTHmI","hero-header":"nP3Scp","promo-header":"_5mHlmJ","uui-critical":"jzZYi0","uui-success":"uxmDHo","uui-warning":"G8DOto","uui-typography-size-12":"ggPO3-","uui-typography-size-14":"iI144g","uui-typography-size-16":"hDxksW","root":"duaqU8","size-18":"DLx6dT","size-24":"REDfgX","size-30":"rvZnC-","size-36":"oAipv0","size-42":"MaSU-p","size-48":"paNCBJ","uuiTypography":"SLTHmI","heroHeader":"nP3Scp","promoHeader":"_5mHlmJ","uuiCritical":"jzZYi0","uuiSuccess":"uxmDHo","uuiWarning":"G8DOto","uuiTypographySize12":"ggPO3-","uuiTypographySize14":"iI144g","uuiTypographySize16":"hDxksW","size18":"DLx6dT","size24":"REDfgX","size30":"rvZnC-","size36":"oAipv0","size42":"MaSU-p","size48":"paNCBJ"};
|
|
670
|
+
|
|
671
|
+
const defaultSize$a = '36';
|
|
672
|
+
const mapSize = {
|
|
673
|
+
48: '48',
|
|
674
|
+
42: '48',
|
|
675
|
+
36: '36',
|
|
676
|
+
30: '30',
|
|
677
|
+
24: '30',
|
|
678
|
+
18: '18',
|
|
679
|
+
};
|
|
680
|
+
const mapCountIndicatorSizes = {
|
|
681
|
+
18: '12',
|
|
682
|
+
24: '18',
|
|
683
|
+
30: '18',
|
|
684
|
+
36: '18',
|
|
685
|
+
42: '24',
|
|
686
|
+
48: '24',
|
|
687
|
+
};
|
|
688
|
+
function applyTagMods(mods) {
|
|
689
|
+
return [
|
|
690
|
+
css$1k['size-' + (mods.size || defaultSize$a)],
|
|
691
|
+
css$1k.root,
|
|
692
|
+
'uui-color-neutral',
|
|
693
|
+
'uui-tag',
|
|
694
|
+
];
|
|
695
|
+
}
|
|
696
|
+
const Tag = uuiCore.withMods(uuiComponents.Button, applyTagMods, (props) => ({
|
|
697
|
+
dropdownIcon: systemIcons[mapSize[props.size] || defaultSize$a].foldingArrow,
|
|
698
|
+
clearIcon: systemIcons[mapSize[props.size] || defaultSize$a].clear,
|
|
699
|
+
countIndicator: (countIndicatorProps) => (React__namespace.default.createElement(CountIndicator, Object.assign({}, countIndicatorProps, { color: "white", size: mapCountIndicatorSizes[props.size || defaultSize$a] }))),
|
|
700
|
+
}));
|
|
701
|
+
|
|
702
|
+
var css$1j = {"root":"gVFB-y","uui-spinner":"OQNRYv","uuiSpinner":"OQNRYv"};
|
|
703
|
+
|
|
704
|
+
function applySpinnerMods() {
|
|
705
|
+
return [css$1j.root, 'uui-spinner'];
|
|
706
|
+
}
|
|
707
|
+
const Spinner = uuiCore.withMods(uuiComponents.Spinner, applySpinnerMods);
|
|
708
|
+
|
|
709
|
+
var css$1i = {"root":"NOi-AT","spacer":"dNxuOX","mode-ghost":"iG7OeE","size-24":"bHqhVZ","size-30":"rU9f5C","navigation-size-24":"_-3q0oi","navigation-size-30":"QNZHCb","modeGhost":"iG7OeE","size24":"bHqhVZ","size30":"rU9f5C","navigationSize24":"_-3q0oi","navigationSize30":"QNZHCb"};
|
|
710
|
+
|
|
711
|
+
var _path$M;
|
|
712
|
+
function _extends$O() { _extends$O = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$O.apply(this, arguments); }
|
|
713
|
+
var SvgNavigationChevronLeft12 = function SvgNavigationChevronLeft12(props, ref) {
|
|
714
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$O({
|
|
715
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
716
|
+
width: 12,
|
|
717
|
+
height: 12,
|
|
718
|
+
viewBox: "0 0 12 12",
|
|
719
|
+
ref: ref
|
|
720
|
+
}, props), _path$M || (_path$M = /*#__PURE__*/React__namespace.createElement("path", {
|
|
721
|
+
fillRule: "evenodd",
|
|
722
|
+
d: "M7.705 3.705 7 3 4 6l3 3 .705-.705L5.415 6l2.29-2.295z",
|
|
723
|
+
clipRule: "evenodd"
|
|
724
|
+
})));
|
|
725
|
+
};
|
|
726
|
+
var ForwardRef$O = /*#__PURE__*/React.forwardRef(SvgNavigationChevronLeft12);
|
|
727
|
+
|
|
728
|
+
var _path$L;
|
|
729
|
+
function _extends$N() { _extends$N = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$N.apply(this, arguments); }
|
|
730
|
+
var SvgNavigationChevronRight12 = function SvgNavigationChevronRight12(props, ref) {
|
|
731
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$N({
|
|
732
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
733
|
+
width: 12,
|
|
734
|
+
height: 12,
|
|
735
|
+
viewBox: "0 0 12 12",
|
|
736
|
+
ref: ref
|
|
737
|
+
}, props), _path$L || (_path$L = /*#__PURE__*/React__namespace.createElement("path", {
|
|
738
|
+
fillRule: "evenodd",
|
|
739
|
+
d: "m5 3-.705.705L6.585 6l-2.29 2.295L5 9l3-3-3-3z",
|
|
740
|
+
clipRule: "evenodd"
|
|
741
|
+
})));
|
|
742
|
+
};
|
|
743
|
+
var ForwardRef$N = /*#__PURE__*/React.forwardRef(SvgNavigationChevronRight12);
|
|
744
|
+
|
|
745
|
+
var _path$K;
|
|
746
|
+
function _extends$M() { _extends$M = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$M.apply(this, arguments); }
|
|
747
|
+
var SvgNavigationChevronLeft18 = function SvgNavigationChevronLeft18(props, ref) {
|
|
748
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$M({
|
|
749
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
750
|
+
width: 18,
|
|
751
|
+
height: 18,
|
|
752
|
+
viewBox: "0 0 18 18",
|
|
753
|
+
ref: ref
|
|
754
|
+
}, props), _path$K || (_path$K = /*#__PURE__*/React__namespace.createElement("path", {
|
|
755
|
+
fillRule: "evenodd",
|
|
756
|
+
d: "M11.557 5.558 10.5 4.5 6 9l4.5 4.5 1.057-1.057L8.123 9l3.434-3.442z",
|
|
757
|
+
clipRule: "evenodd"
|
|
758
|
+
})));
|
|
759
|
+
};
|
|
760
|
+
var ForwardRef$M = /*#__PURE__*/React.forwardRef(SvgNavigationChevronLeft18);
|
|
761
|
+
|
|
762
|
+
var _path$J;
|
|
763
|
+
function _extends$L() { _extends$L = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$L.apply(this, arguments); }
|
|
764
|
+
var SvgNavigationChevronRight18 = function SvgNavigationChevronRight18(props, ref) {
|
|
765
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$L({
|
|
766
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
767
|
+
width: 18,
|
|
768
|
+
height: 18,
|
|
769
|
+
viewBox: "0 0 18 18",
|
|
770
|
+
ref: ref
|
|
771
|
+
}, props), _path$J || (_path$J = /*#__PURE__*/React__namespace.createElement("path", {
|
|
772
|
+
fillRule: "evenodd",
|
|
773
|
+
d: "M7.5 4.5 6.442 5.558 9.877 9l-3.435 3.443L7.5 13.5 12 9 7.5 4.5z",
|
|
774
|
+
clipRule: "evenodd"
|
|
775
|
+
})));
|
|
776
|
+
};
|
|
777
|
+
var ForwardRef$L = /*#__PURE__*/React.forwardRef(SvgNavigationChevronRight18);
|
|
778
|
+
|
|
779
|
+
function Paginator(props) {
|
|
780
|
+
const renderPaginator = (params) => {
|
|
781
|
+
var _a, _b;
|
|
782
|
+
return (React__namespace.default.createElement("nav", Object.assign({ role: "navigation", className: cx__default.default(css$1i.root, 'uui-paginator') }, params.rawProps),
|
|
783
|
+
React__namespace.default.createElement(Button, { cx: css$1i[`navigation-size-${(_a = params.size) !== null && _a !== void 0 ? _a : '30'}`], size: params.size, icon: params.size === '30' ? ForwardRef$M : ForwardRef$O, onClick: params.goToPrev, isDisabled: params.isFirst, fill: "outline", color: "secondary" }),
|
|
784
|
+
params.pages.map((page, index) => {
|
|
785
|
+
var _a, _b;
|
|
786
|
+
if (page.type === 'spacer') {
|
|
787
|
+
return (React__namespace.default.createElement(Button, { cx: cx__default.default(css$1i[`size-${(_a = params.size) !== null && _a !== void 0 ? _a : '30'}`], css$1i.spacer), size: params.size, key: `${index}_spacer`, caption: "...", fill: "ghost", color: "secondary", tabIndex: -1 }));
|
|
788
|
+
}
|
|
789
|
+
else {
|
|
790
|
+
return (React__namespace.default.createElement(Button, { cx: cx__default.default(css$1i[`size-${(_b = params.size) !== null && _b !== void 0 ? _b : '30'}`], css$1i[`mode-${!page.isActive && 'ghost'}`]), size: params.size, key: page.pageNumber, caption: page.pageNumber, onClick: () => { var _a; return (_a = page.onClick) === null || _a === void 0 ? void 0 : _a.call(page); }, rawProps: { 'aria-current': page.isActive }, fill: (page.isActive && 'outline') || 'ghost', color: "primary" }));
|
|
791
|
+
}
|
|
792
|
+
}),
|
|
793
|
+
React__namespace.default.createElement(Button, { cx: css$1i[`navigation-size-${(_b = params.size) !== null && _b !== void 0 ? _b : '30'}`], size: params.size, icon: params.size === '30' ? ForwardRef$L : ForwardRef$N, onClick: params.goToNext, isDisabled: params.isLast, fill: "outline", color: "secondary" })));
|
|
794
|
+
};
|
|
795
|
+
return React__namespace.default.createElement(uuiComponents.Paginator, Object.assign({}, props, { render: renderPaginator }));
|
|
796
|
+
}
|
|
797
|
+
|
|
798
|
+
var css$1h = {"root":"k-MwpF","bar":"cVuIlF","progressBar-indeterminate":"Jb0M7h","size-12":"i5H6RI","size-18":"ykaiPn","size-24":"Z4bAzW","progressBarIndeterminate":"Jb0M7h","size12":"i5H6RI","size18":"ykaiPn","size24":"Z4bAzW"};
|
|
799
|
+
|
|
800
|
+
const IndeterminateBar = React__namespace.forwardRef((props, ref) => {
|
|
801
|
+
return (React__namespace.createElement("div", { ref: ref, className: cx__default.default('uui-indeterminate_bar', props.cx, css$1h.root, css$1h[`size-${props.size || 12}`]) },
|
|
802
|
+
React__namespace.createElement("div", { className: cx__default.default(css$1h.bar) })));
|
|
803
|
+
});
|
|
804
|
+
|
|
805
|
+
var css$1g = {"root":"_1zljNJ","striped":"_3Oc66t","animate-stripes":"AzaLeg","size-12":"AYDPkB","size-18":"gozExq","size-24":"pe8pQp","animateStripes":"AzaLeg","size12":"AYDPkB","size18":"gozExq","size24":"pe8pQp"};
|
|
806
|
+
|
|
807
|
+
const defaultSize$9 = '12';
|
|
808
|
+
function applyProgressBarMods(mods) {
|
|
809
|
+
const size = mods.size || defaultSize$9;
|
|
810
|
+
return [
|
|
811
|
+
css$1g.root,
|
|
812
|
+
css$1g[`size-${size}`],
|
|
813
|
+
mods.striped && css$1g.striped,
|
|
814
|
+
];
|
|
815
|
+
}
|
|
816
|
+
const ProgressBar = uuiCore.withMods(uuiComponents.ProgressBar, applyProgressBarMods, (props) => ({
|
|
817
|
+
hideLabel: props.hideLabel || props.striped,
|
|
818
|
+
}));
|
|
819
|
+
|
|
820
|
+
var css$1f = {"root":"_5xOU14"};
|
|
821
|
+
|
|
822
|
+
const IndicatorBar = React__namespace.forwardRef((props, ref) => {
|
|
823
|
+
const { progress } = props;
|
|
824
|
+
return progress || progress === 0 ? (React__namespace.createElement(ProgressBar, { ref: ref, progress: progress, cx: cx__default.default(css$1f.root, props.cx), hideLabel: true })) : (React__namespace.createElement(IndeterminateBar, { ref: ref, cx: cx__default.default(css$1f.root, props.cx) }));
|
|
825
|
+
});
|
|
826
|
+
|
|
827
|
+
var css$1e = {"root":"GSVC1S","size-12":"uYbavj","size-18":"kU-W4y","size-24":"n47c-p","size12":"uYbavj","size18":"kU-W4y","size24":"n47c-p"};
|
|
828
|
+
|
|
829
|
+
const StatusIndicator = React.forwardRef((props, ref) => {
|
|
830
|
+
return (React__namespace.default.createElement("div", { ref: ref, className: cx__default.default([
|
|
831
|
+
css$1e.root,
|
|
832
|
+
css$1e[`size-${props.size || 24}`],
|
|
833
|
+
'uui-status_indicator',
|
|
834
|
+
`uui-color-${props.color || 'neutral'}`,
|
|
835
|
+
`uui-fill-${props.fill || 'solid'}`,
|
|
836
|
+
props.cx,
|
|
837
|
+
]) },
|
|
838
|
+
React__namespace.default.createElement("div", { className: "uui-status_indicator_dot" }),
|
|
839
|
+
React__namespace.default.createElement("p", { className: "uui-status_indicator_caption" }, props.caption)));
|
|
840
|
+
});
|
|
841
|
+
|
|
842
|
+
var css$1d = {"uui-typography":"cXfXyf","hero-header":"zjzfnQ","promo-header":"uSCJT2","uui-critical":"A20pNH","uui-success":"YmMKmU","uui-warning":"Jipexj","uui-typography-size-12":"rkDzYE","uui-typography-size-14":"LWHKtv","uui-typography-size-16":"kpQMMv","root":"j-Bm7f","size-18":"gs-Msa","size-24":"f95UdQ","size-30":"aqqftl","size-36":"MVEaV8","size-42":"tHcyPL","size-48":"jPboMx","uuiTypography":"cXfXyf","heroHeader":"zjzfnQ","promoHeader":"uSCJT2","uuiCritical":"A20pNH","uuiSuccess":"YmMKmU","uuiWarning":"Jipexj","uuiTypographySize12":"rkDzYE","uuiTypographySize14":"LWHKtv","uuiTypographySize16":"kpQMMv","size18":"gs-Msa","size24":"f95UdQ","size30":"aqqftl","size36":"MVEaV8","size42":"tHcyPL","size48":"jPboMx"};
|
|
606
843
|
|
|
607
844
|
const allButtonColors = [
|
|
608
|
-
'accent', 'primary', 'secondary', '
|
|
845
|
+
'accent', 'primary', 'critical', 'secondary', 'neutral',
|
|
609
846
|
];
|
|
610
|
-
const defaultSize$
|
|
847
|
+
const defaultSize$8 = '36';
|
|
611
848
|
function applyButtonMods(mods) {
|
|
612
849
|
return [
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
850
|
+
css$1d.root,
|
|
851
|
+
'uui-button',
|
|
852
|
+
`uui-fill-${mods.fill || 'solid'}`,
|
|
853
|
+
`uui-color-${mods.color || 'primary'}`,
|
|
854
|
+
css$1d[`size-${mods.size || defaultSize$8}`],
|
|
617
855
|
];
|
|
618
856
|
}
|
|
619
|
-
const Button = uuiCore.withMods(
|
|
620
|
-
dropdownIcon: systemIcons[props.size || defaultSize$
|
|
621
|
-
clearIcon: systemIcons[props.size || defaultSize$
|
|
857
|
+
const Button = uuiCore.withMods(uuiComponents.Button, applyButtonMods, (props) => ({
|
|
858
|
+
dropdownIcon: systemIcons[props.size || defaultSize$8].foldingArrow,
|
|
859
|
+
clearIcon: systemIcons[props.size || defaultSize$8].clear,
|
|
860
|
+
countIndicator: (countIndicatorProps) => React__namespace.default.createElement(CountIndicator, Object.assign({}, countIndicatorProps, { color: "white" })),
|
|
622
861
|
}));
|
|
623
862
|
|
|
624
|
-
var css$
|
|
863
|
+
var css$1c = {"root":"MfCqIL"};
|
|
625
864
|
|
|
626
865
|
const allIconColors = [
|
|
627
|
-
'info', 'success', 'warning', 'error', 'secondary', '
|
|
866
|
+
'info', 'success', 'warning', 'error', 'secondary', 'neutral',
|
|
628
867
|
];
|
|
629
868
|
function applyIconButtonMods(mods) {
|
|
630
|
-
return [`
|
|
869
|
+
return ['uui-icon_button', `uui-color-${mods.color || 'neutral'}`, css$1c.root];
|
|
631
870
|
}
|
|
632
871
|
const IconButton = uuiCore.withMods(uuiComponents.IconButton, applyIconButtonMods);
|
|
633
872
|
|
|
634
|
-
var css$
|
|
873
|
+
var css$1b = {"root":"_97b6xl","size-18":"bobENg","size-24":"GSss5o","size-30":"jixH8P","size-36":"_28Kg5s","size-42":"-RyIBL","size-48":"yJ78sb","size18":"bobENg","size24":"GSss5o","size30":"jixH8P","size36":"_28Kg5s","size42":"-RyIBL","size48":"yJ78sb"};
|
|
635
874
|
|
|
636
875
|
function getIconClass(props) {
|
|
637
876
|
const classList = {
|
|
@@ -650,45 +889,46 @@ function getIconClass(props) {
|
|
|
650
889
|
return [classList['has-left-icon'] ? 'uui-has-left-icon' : 'uui-no-left-icon', classList['has-right-icon'] ? 'uui-has-right-icon' : 'uui-no-right-icon'];
|
|
651
890
|
}
|
|
652
891
|
|
|
653
|
-
const defaultSize$
|
|
892
|
+
const defaultSize$7 = '36';
|
|
654
893
|
const allLinkButtonColors = ['primary', 'secondary', 'contrast'];
|
|
655
894
|
function applyLinkButtonMods(mods) {
|
|
656
895
|
return [
|
|
657
|
-
|
|
658
|
-
css$
|
|
896
|
+
'uui-link_button',
|
|
897
|
+
css$1b.root,
|
|
898
|
+
css$1b['size-' + (mods.size || defaultSize$7)],
|
|
659
899
|
...getIconClass(mods),
|
|
660
|
-
`
|
|
900
|
+
`uui-color-${mods.color || 'primary'}`,
|
|
661
901
|
];
|
|
662
902
|
}
|
|
663
903
|
const LinkButton = uuiCore.withMods(uuiComponents.Button, applyLinkButtonMods, (props) => ({
|
|
664
|
-
dropdownIcon: systemIcons[props.size || defaultSize$
|
|
665
|
-
clearIcon: systemIcons[props.size || defaultSize$
|
|
904
|
+
dropdownIcon: systemIcons[props.size || defaultSize$7].foldingArrow,
|
|
905
|
+
clearIcon: systemIcons[props.size || defaultSize$7].clear,
|
|
666
906
|
}));
|
|
667
907
|
|
|
668
|
-
var css$
|
|
908
|
+
var css$1a = {"uui-typography":"tZEox0","hero-header":"hj-7-y","promo-header":"dl2f3x","uui-critical":"_2Zxdu3","uui-success":"PR9bWG","uui-warning":"aNA5ug","uui-typography-size-12":"YihI9r","uui-typography-size-14":"FEjTsi","uui-typography-size-16":"m45-bW","root":"bPVRhU","withNotify":"a5k8wB","size-36":"CKA3pD","size-48":"x7Tnbl","size-60":"M8F7KE","uuiTypography":"tZEox0","heroHeader":"hj-7-y","promoHeader":"dl2f3x","uuiCritical":"_2Zxdu3","uuiSuccess":"PR9bWG","uuiWarning":"aNA5ug","uuiTypographySize12":"YihI9r","uuiTypographySize14":"FEjTsi","uuiTypographySize16":"m45-bW","size36":"CKA3pD","size48":"x7Tnbl","size60":"M8F7KE"};
|
|
669
909
|
|
|
670
910
|
function applyTabButtonMods(mods) {
|
|
671
911
|
return [
|
|
672
|
-
css$
|
|
673
|
-
'
|
|
674
|
-
css$
|
|
675
|
-
mods.withNotify && css$
|
|
912
|
+
css$1a.root,
|
|
913
|
+
'uui-tab-button',
|
|
914
|
+
css$1a['size-' + (mods.size || '48')],
|
|
915
|
+
mods.withNotify && css$1a.withNotify,
|
|
676
916
|
...getIconClass(mods),
|
|
677
917
|
];
|
|
678
918
|
}
|
|
679
|
-
const TabButton = uuiCore.withMods(uuiComponents.Button, applyTabButtonMods, (props) => (Object.assign(Object.assign({ dropdownIcon: systemIcons['36'].foldingArrow, clearIcon: systemIcons['36'].clear
|
|
919
|
+
const TabButton = uuiCore.withMods(uuiComponents.Button, applyTabButtonMods, (props) => (Object.assign(Object.assign({ dropdownIcon: systemIcons['36'].foldingArrow, clearIcon: systemIcons['36'].clear }, props), { rawProps: Object.assign({ role: 'tab' }, props.rawProps), countIndicator: (countIndicatorProps) => (React__namespace.default.createElement(CountIndicator, Object.assign({}, countIndicatorProps, { color: props.isLinkActive ? 'info' : 'neutral', size: "18" }))) })));
|
|
680
920
|
|
|
681
|
-
var css$
|
|
921
|
+
var css$19 = {"uui-typography":"i6pq-e","hero-header":"CkLeId","promo-header":"gOXAii","uui-critical":"_4IsaOF","uui-success":"_37-jsb","uui-warning":"dzv9dX","uui-typography-size-12":"nJIR6e","uui-typography-size-14":"Cj5mzm","uui-typography-size-16":"txaPS-","root":"ipnm9s","uuiTypography":"i6pq-e","heroHeader":"CkLeId","promoHeader":"gOXAii","uuiCritical":"_4IsaOF","uuiSuccess":"_37-jsb","uuiWarning":"dzv9dX","uuiTypographySize12":"nJIR6e","uuiTypographySize14":"Cj5mzm","uuiTypographySize16":"txaPS-"};
|
|
682
922
|
|
|
683
923
|
function applyVerticalTabButtonMods() {
|
|
684
|
-
return [css$
|
|
924
|
+
return [css$19.root];
|
|
685
925
|
}
|
|
686
926
|
const VerticalTabButton = uuiCore.withMods(TabButton, applyVerticalTabButtonMods);
|
|
687
927
|
|
|
688
|
-
const
|
|
928
|
+
const allButtonFills = [
|
|
689
929
|
'solid', 'outline', 'ghost', 'none',
|
|
690
930
|
];
|
|
691
|
-
const allFillStyles =
|
|
931
|
+
const allFillStyles = allButtonFills;
|
|
692
932
|
const allSizes = [
|
|
693
933
|
'24', '30', '36', '42', '48',
|
|
694
934
|
];
|
|
@@ -698,11 +938,8 @@ const allRowSizes = [
|
|
|
698
938
|
const allSemanticColors = [
|
|
699
939
|
'info', 'success', 'warning', 'error',
|
|
700
940
|
];
|
|
701
|
-
const allButtonSemanticColors = [
|
|
702
|
-
'accent', 'primary', 'secondary', 'negative',
|
|
703
|
-
];
|
|
704
941
|
const allEpamBadgeSemanticColors = [
|
|
705
|
-
'info', 'success', 'warning', '
|
|
942
|
+
'info', 'success', 'warning', 'critical', 'neutral',
|
|
706
943
|
];
|
|
707
944
|
const allTextSizes = [
|
|
708
945
|
'18', '24', '30', '36', '48',
|
|
@@ -717,89 +954,92 @@ exports.EditMode = void 0;
|
|
|
717
954
|
EditMode["INLINE"] = "inline";
|
|
718
955
|
})(exports.EditMode || (exports.EditMode = {}));
|
|
719
956
|
|
|
720
|
-
var _path$
|
|
721
|
-
function _extends$
|
|
957
|
+
var _path$I;
|
|
958
|
+
function _extends$K() { _extends$K = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$K.apply(this, arguments); }
|
|
722
959
|
var SvgCheck12 = function SvgCheck12(props, ref) {
|
|
723
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
960
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$K({
|
|
724
961
|
width: 12,
|
|
725
962
|
height: 12,
|
|
726
963
|
viewBox: "0 0 12 12",
|
|
727
964
|
xmlns: "http://www.w3.org/2000/svg",
|
|
728
965
|
ref: ref
|
|
729
|
-
}, props), _path$
|
|
966
|
+
}, props), _path$I || (_path$I = /*#__PURE__*/React__namespace.createElement("path", {
|
|
730
967
|
fillRule: "evenodd",
|
|
731
968
|
d: "M9.491 3.449 10.51 4.55 5.663 9.024 2.487 6.047l1.026-1.094L5.67 6.975z"
|
|
732
969
|
})));
|
|
733
970
|
};
|
|
734
|
-
var ForwardRef$
|
|
971
|
+
var ForwardRef$K = /*#__PURE__*/React.forwardRef(SvgCheck12);
|
|
735
972
|
|
|
736
|
-
var _path$
|
|
737
|
-
function _extends$
|
|
973
|
+
var _path$H;
|
|
974
|
+
function _extends$J() { _extends$J = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$J.apply(this, arguments); }
|
|
738
975
|
var SvgCheck18 = function SvgCheck18(props, ref) {
|
|
739
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
976
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$J({
|
|
740
977
|
width: 18,
|
|
741
978
|
height: 18,
|
|
742
979
|
viewBox: "0 0 18 18",
|
|
743
980
|
xmlns: "http://www.w3.org/2000/svg",
|
|
744
981
|
ref: ref
|
|
745
|
-
}, props), _path$
|
|
982
|
+
}, props), _path$H || (_path$H = /*#__PURE__*/React__namespace.createElement("path", {
|
|
746
983
|
fillRule: "evenodd",
|
|
747
984
|
d: "m14.247 4.341 1.506 1.318-7.704 8.804-4.756-4.756 1.414-1.414 3.244 3.243z"
|
|
748
985
|
})));
|
|
749
986
|
};
|
|
750
|
-
var ForwardRef$
|
|
987
|
+
var ForwardRef$J = /*#__PURE__*/React.forwardRef(SvgCheck18);
|
|
751
988
|
|
|
752
|
-
var _path$
|
|
753
|
-
function _extends$
|
|
989
|
+
var _path$G;
|
|
990
|
+
function _extends$I() { _extends$I = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$I.apply(this, arguments); }
|
|
754
991
|
var SvgPartlySelect12 = function SvgPartlySelect12(props, ref) {
|
|
755
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
992
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$I({
|
|
756
993
|
width: 12,
|
|
757
994
|
height: 12,
|
|
758
995
|
viewBox: "0 0 12 12",
|
|
759
996
|
xmlns: "http://www.w3.org/2000/svg",
|
|
760
997
|
ref: ref
|
|
761
|
-
}, props), _path$
|
|
998
|
+
}, props), _path$G || (_path$G = /*#__PURE__*/React__namespace.createElement("path", {
|
|
762
999
|
fillRule: "evenodd",
|
|
763
1000
|
d: "M9 5v2H3V5z"
|
|
764
1001
|
})));
|
|
765
1002
|
};
|
|
766
|
-
var ForwardRef$
|
|
1003
|
+
var ForwardRef$I = /*#__PURE__*/React.forwardRef(SvgPartlySelect12);
|
|
767
1004
|
|
|
768
|
-
var _path$
|
|
769
|
-
function _extends$
|
|
1005
|
+
var _path$F;
|
|
1006
|
+
function _extends$H() { _extends$H = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$H.apply(this, arguments); }
|
|
770
1007
|
var SvgPartlySelect18 = function SvgPartlySelect18(props, ref) {
|
|
771
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1008
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$H({
|
|
772
1009
|
width: 18,
|
|
773
1010
|
height: 18,
|
|
774
1011
|
viewBox: "0 0 18 18",
|
|
775
1012
|
xmlns: "http://www.w3.org/2000/svg",
|
|
776
1013
|
ref: ref
|
|
777
|
-
}, props), _path$
|
|
1014
|
+
}, props), _path$F || (_path$F = /*#__PURE__*/React__namespace.createElement("path", {
|
|
778
1015
|
fillRule: "evenodd",
|
|
779
1016
|
d: "M14 8v2H4V8z"
|
|
780
1017
|
})));
|
|
781
1018
|
};
|
|
782
|
-
var ForwardRef$
|
|
1019
|
+
var ForwardRef$H = /*#__PURE__*/React.forwardRef(SvgPartlySelect18);
|
|
783
1020
|
|
|
784
|
-
var css$
|
|
1021
|
+
var css$18 = {"uui-typography":"Mg45YS","hero-header":"KJDGUT","promo-header":"E2nOBY","uui-critical":"v5N25b","uui-success":"K5fqX9","uui-warning":"Y9k65L","uui-typography-size-12":"zKHwhO","uui-typography-size-14":"b5Kw3K","uui-typography-size-16":"xLHkib","root":"y-s0Dd","size-18":"QDd8hm","size-12":"-TzHMf","mode-cell":"Sp-K-n","uuiTypography":"Mg45YS","heroHeader":"KJDGUT","promoHeader":"E2nOBY","uuiCritical":"v5N25b","uuiSuccess":"K5fqX9","uuiWarning":"Y9k65L","uuiTypographySize12":"zKHwhO","uuiTypographySize14":"b5Kw3K","uuiTypographySize16":"xLHkib","size18":"QDd8hm","size12":"-TzHMf","modeCell":"Sp-K-n"};
|
|
785
1022
|
|
|
786
1023
|
function applyCheckboxMods(mods) {
|
|
787
1024
|
return [
|
|
788
|
-
css$
|
|
1025
|
+
css$18.root,
|
|
1026
|
+
css$18['size-' + (mods.size || '18')],
|
|
1027
|
+
css$18['mode-' + (mods.mode || 'form')],
|
|
1028
|
+
'uui-color-primary',
|
|
789
1029
|
];
|
|
790
1030
|
}
|
|
791
1031
|
const applyUUICheckboxProps = (props) => ({
|
|
792
|
-
icon: props.size === '12' ? ForwardRef$
|
|
793
|
-
indeterminateIcon: props.size === '12' ? ForwardRef$
|
|
1032
|
+
icon: props.size === '12' ? ForwardRef$K : ForwardRef$J,
|
|
1033
|
+
indeterminateIcon: props.size === '12' ? ForwardRef$I : ForwardRef$H,
|
|
794
1034
|
});
|
|
795
1035
|
const Checkbox = uuiCore.withMods(uuiComponents__namespace.Checkbox, applyCheckboxMods, applyUUICheckboxProps);
|
|
796
1036
|
|
|
797
|
-
var css$
|
|
1037
|
+
var css$17 = {"uui-typography":"zooAAk","hero-header":"qNwiT2","promo-header":"NioGFN","uui-critical":"dV5OWt","uui-success":"oYEFLn","uui-warning":"gAYURJ","uui-typography-size-12":"KyIR1A","uui-typography-size-14":"htC76H","uui-typography-size-16":"Dgodbd","root":"sTrlfp","size-18":"PwLpfK","size-12":"NN-8sx","uuiTypography":"zooAAk","heroHeader":"qNwiT2","promoHeader":"NioGFN","uuiCritical":"dV5OWt","uuiSuccess":"oYEFLn","uuiWarning":"gAYURJ","uuiTypographySize12":"KyIR1A","uuiTypographySize14":"htC76H","uuiTypographySize16":"Dgodbd","size18":"PwLpfK","size12":"NN-8sx"};
|
|
798
1038
|
|
|
799
1039
|
var _circle;
|
|
800
|
-
function _extends$
|
|
1040
|
+
function _extends$G() { _extends$G = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$G.apply(this, arguments); }
|
|
801
1041
|
var SvgRadioPoint = function SvgRadioPoint(props, ref) {
|
|
802
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1042
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$G({
|
|
803
1043
|
width: 18,
|
|
804
1044
|
height: 18,
|
|
805
1045
|
viewBox: "0 0 18 18",
|
|
@@ -811,18 +1051,18 @@ var SvgRadioPoint = function SvgRadioPoint(props, ref) {
|
|
|
811
1051
|
r: 6
|
|
812
1052
|
})));
|
|
813
1053
|
};
|
|
814
|
-
var ForwardRef$
|
|
1054
|
+
var ForwardRef$G = /*#__PURE__*/React.forwardRef(SvgRadioPoint);
|
|
815
1055
|
|
|
816
1056
|
function applyRadioInputMods(mods) {
|
|
817
|
-
return [css$
|
|
1057
|
+
return [css$17.root, css$17['size-' + (mods.size || '18')], 'uui-color-primary'];
|
|
818
1058
|
}
|
|
819
|
-
const RadioInput = uuiCore.withMods(uuiComponents.RadioInput, applyRadioInputMods, () => ({ icon: ForwardRef$
|
|
1059
|
+
const RadioInput = uuiCore.withMods(uuiComponents.RadioInput, applyRadioInputMods, () => ({ icon: ForwardRef$G }));
|
|
820
1060
|
|
|
821
|
-
var css$
|
|
1061
|
+
var css$16 = {"root":"TpZL4g","size-12":"nPz9EM","size-18":"_2MXQIy","size-24":"lgiXar","size12":"nPz9EM","size18":"_2MXQIy","size24":"lgiXar"};
|
|
822
1062
|
|
|
823
1063
|
function applySwitchMods(mods) {
|
|
824
1064
|
return [
|
|
825
|
-
|
|
1065
|
+
css$16.root, css$16['size-' + (mods.size || '18')], 'uui-color-primary',
|
|
826
1066
|
];
|
|
827
1067
|
}
|
|
828
1068
|
const Switch = uuiCore.withMods(uuiComponents__namespace.Switch, applySwitchMods);
|
|
@@ -871,27 +1111,27 @@ typeof SuppressedError === "function" ? SuppressedError : function (error, suppr
|
|
|
871
1111
|
return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
|
|
872
1112
|
};
|
|
873
1113
|
|
|
874
|
-
var textInputCss = {"
|
|
1114
|
+
var textInputCss = {"uui-typography":"wKSDEr","hero-header":"CRLjy5","promo-header":"GwjwwV","uui-critical":"oO63xI","uui-success":"Cd3IBr","uui-warning":"dpNmTt","uui-typography-size-12":"_4E9hWO","uui-typography-size-14":"-dERdY","uui-typography-size-16":"wcflJo","root":"PW1w5J","mode-form":"GbkRWY","mode-inline":"_517VoZ","mode-cell":"d0Tuxx","size-24":"_5EUT3t","size-30":"NLpCIH","size-36":"vbwnuz","size-42":"hobixB","size-48":"mTTCip","uuiTypography":"wKSDEr","heroHeader":"CRLjy5","promoHeader":"GwjwwV","uuiCritical":"oO63xI","uuiSuccess":"Cd3IBr","uuiWarning":"dpNmTt","uuiTypographySize12":"_4E9hWO","uuiTypographySize14":"-dERdY","uuiTypographySize16":"wcflJo","modeForm":"GbkRWY","modeInline":"_517VoZ","modeCell":"d0Tuxx","size24":"_5EUT3t","size30":"NLpCIH","size36":"vbwnuz","size42":"hobixB","size48":"mTTCip"};
|
|
875
1115
|
|
|
876
|
-
const defaultSize$
|
|
1116
|
+
const defaultSize$6 = '36';
|
|
877
1117
|
const defaultMode$5 = exports.EditMode.FORM;
|
|
878
1118
|
function applyTextInputMods(mods) {
|
|
879
1119
|
return [
|
|
880
1120
|
textInputCss.root,
|
|
881
|
-
textInputCss['size-' + (mods.size || defaultSize$
|
|
1121
|
+
textInputCss['size-' + (mods.size || defaultSize$6)],
|
|
882
1122
|
textInputCss['mode-' + (mods.mode || defaultMode$5)],
|
|
883
1123
|
];
|
|
884
1124
|
}
|
|
885
1125
|
const TextInput = uuiCore.withMods(uuiComponents.TextInput, applyTextInputMods, (props) => ({
|
|
886
|
-
acceptIcon: systemIcons[props.size || defaultSize$
|
|
887
|
-
cancelIcon: systemIcons[props.size || defaultSize$
|
|
888
|
-
dropdownIcon: systemIcons[props.size || defaultSize$
|
|
1126
|
+
acceptIcon: systemIcons[props.size || defaultSize$6].accept,
|
|
1127
|
+
cancelIcon: systemIcons[props.size || defaultSize$6].clear,
|
|
1128
|
+
dropdownIcon: systemIcons[props.size || defaultSize$6].foldingArrow,
|
|
889
1129
|
}));
|
|
890
1130
|
const SearchInput = React__namespace.default.forwardRef((props, ref) => {
|
|
891
1131
|
// analytics events are sending in IEditableDebouncer, so we need to avoid sending events in TextInput
|
|
892
1132
|
const textInputProps = __rest(props, []);
|
|
893
1133
|
delete textInputProps.getValueChangeAnalyticsEvent;
|
|
894
|
-
return (React__namespace.default.createElement(uuiCore.IEditableDebouncer, Object.assign({}, props, { render: (iEditable) => (React__namespace.default.createElement(TextInput, Object.assign({ icon: systemIcons[props.size || defaultSize$
|
|
1134
|
+
return (React__namespace.default.createElement(uuiCore.IEditableDebouncer, Object.assign({}, props, { render: (iEditable) => (React__namespace.default.createElement(TextInput, Object.assign({ icon: systemIcons[props.size || defaultSize$6].search, onCancel: !!props.value
|
|
895
1135
|
// In a lot of places, it is required to check if a clicked element is a part of some other element.
|
|
896
1136
|
// Usually, those are global click event handlers. To allow that logic to work correctly, it is necessary
|
|
897
1137
|
// to execute the `disappearing` of the cross (setState execution) after the event will pass through all the handlers.
|
|
@@ -900,41 +1140,41 @@ const SearchInput = React__namespace.default.forwardRef((props, ref) => {
|
|
|
900
1140
|
: undefined, type: "search", inputMode: "search", ref: ref }, textInputProps, iEditable))) })));
|
|
901
1141
|
});
|
|
902
1142
|
|
|
903
|
-
var css$
|
|
1143
|
+
var css$15 = {"root":"pud-3w"};
|
|
904
1144
|
|
|
905
|
-
const ControlGroup = uuiCore.withMods(uuiComponents.ControlGroup, () => [css$
|
|
1145
|
+
const ControlGroup = uuiCore.withMods(uuiComponents.ControlGroup, () => [css$15.root]);
|
|
906
1146
|
|
|
907
1147
|
function MultiSwitchComponent(props, ref) {
|
|
908
|
-
return (React__namespace.createElement(ControlGroup, { ref: ref, rawProps: Object.assign(Object.assign({}, props.rawProps), { role: 'tablist' }) }, props.items.map((item, index) => (React__namespace.createElement(Button, Object.assign({}, props, item, { isDisabled: props.isDisabled, key: index + '-' + item.id, onClick: () => props.onValueChange(item.id),
|
|
1148
|
+
return (React__namespace.createElement(ControlGroup, { ref: ref, rawProps: Object.assign(Object.assign({}, props.rawProps), { role: 'tablist' }) }, props.items.map((item, index) => (React__namespace.createElement(Button, Object.assign({}, props, item, { isDisabled: props.isDisabled, key: index + '-' + item.id, onClick: () => props.onValueChange(item.id), fill: props.value === item.id ? 'solid' : 'outline', color: props.color === 'secondary' && props.value === item.id ? 'primary' : props.color || 'primary', size: props.size, rawProps: { 'aria-current': props.value === item.id, role: 'tab' } }))))));
|
|
909
1149
|
}
|
|
910
1150
|
const MultiSwitch = React__namespace.forwardRef(MultiSwitchComponent);
|
|
911
1151
|
|
|
912
|
-
var css$
|
|
1152
|
+
var css$14 = {"uui-typography":"Y--vnV","hero-header":"crBUoh","promo-header":"laf--p","uui-critical":"c-pYk0","uui-success":"-UPuxw","uui-warning":"qqUTRa","uui-typography-size-12":"_4HZnEj","uui-typography-size-14":"OaO9nN","uui-typography-size-16":"lcQcNn","root":"_73qIvK","size-24":"KfRyeG","size-30":"LK4vyc","size-36":"_2j6CAc","size-42":"WxpuNH","size-48":"L2rWy3","mode-form":"stfG4E","mode-cell":"_5V-5jI","uuiTypography":"Y--vnV","heroHeader":"crBUoh","promoHeader":"laf--p","uuiCritical":"c-pYk0","uuiSuccess":"-UPuxw","uuiWarning":"qqUTRa","uuiTypographySize12":"_4HZnEj","uuiTypographySize14":"OaO9nN","uuiTypographySize16":"lcQcNn","size24":"KfRyeG","size30":"LK4vyc","size36":"_2j6CAc","size42":"WxpuNH","size48":"L2rWy3","modeForm":"stfG4E","modeCell":"_5V-5jI"};
|
|
913
1153
|
|
|
914
|
-
const defaultSize$
|
|
1154
|
+
const defaultSize$5 = '36';
|
|
915
1155
|
const defaultMode$4 = exports.EditMode.FORM;
|
|
916
1156
|
function applyNumericInputMods(mods) {
|
|
917
1157
|
return [
|
|
918
|
-
textInputCss.root, css$
|
|
1158
|
+
textInputCss.root, css$14.root, css$14['size-' + (mods.size || defaultSize$5)], textInputCss['size-' + (mods.size || defaultSize$5)], textInputCss['mode-' + (mods.mode || defaultMode$4)],
|
|
919
1159
|
];
|
|
920
1160
|
}
|
|
921
1161
|
const NumericInput = uuiCore.withMods(uuiComponents.NumericInput, applyNumericInputMods, (props) => {
|
|
922
1162
|
var _a, _b;
|
|
923
1163
|
return ({
|
|
924
|
-
upIcon: systemIcons[props.size || defaultSize$
|
|
925
|
-
downIcon: systemIcons[props.size || defaultSize$
|
|
1164
|
+
upIcon: systemIcons[props.size || defaultSize$5].foldingArrow,
|
|
1165
|
+
downIcon: systemIcons[props.size || defaultSize$5].foldingArrow,
|
|
926
1166
|
align: (_a = props.align) !== null && _a !== void 0 ? _a : (props.mode === 'cell' ? 'right' : 'left'),
|
|
927
1167
|
disableArrows: (_b = props.disableArrows) !== null && _b !== void 0 ? _b : props.mode === 'cell',
|
|
928
1168
|
});
|
|
929
1169
|
});
|
|
930
1170
|
|
|
931
|
-
var css$
|
|
1171
|
+
var css$13 = {"uui-typography":"EzJpt1","hero-header":"WtxTZ7","promo-header":"goLCPT","uui-critical":"aWoVpE","uui-success":"fnapwX","uui-warning":"tacqlh","uui-typography-size-12":"_2yeqgu","uui-typography-size-14":"JZeT65","uui-typography-size-16":"Of568E","root":"s1awNl","mode-form":"KjBQEi","mode-cell":"xM18WA","mode-inline":"yixNK2","size-24":"hx0hBi","size-30":"_6Ry-pN","size-36":"qnIlPr","size-42":"_5v4J70","size-48":"ohC0J-","uuiTypography":"EzJpt1","heroHeader":"WtxTZ7","promoHeader":"goLCPT","uuiCritical":"aWoVpE","uuiSuccess":"fnapwX","uuiWarning":"tacqlh","uuiTypographySize12":"_2yeqgu","uuiTypographySize14":"JZeT65","uuiTypographySize16":"Of568E","modeForm":"KjBQEi","modeCell":"xM18WA","modeInline":"yixNK2","size24":"hx0hBi","size30":"_6Ry-pN","size36":"qnIlPr","size42":"_5v4J70","size48":"ohC0J-"};
|
|
932
1172
|
|
|
933
|
-
const defaultSize$
|
|
1173
|
+
const defaultSize$4 = '36';
|
|
934
1174
|
const defaultMode$3 = exports.EditMode.FORM;
|
|
935
1175
|
function applyTextAreaMods(mods) {
|
|
936
1176
|
return [
|
|
937
|
-
css$
|
|
1177
|
+
css$13.root, css$13['size-' + (mods.size || defaultSize$4)], css$13['mode-' + (mods.mode || defaultMode$3)],
|
|
938
1178
|
];
|
|
939
1179
|
}
|
|
940
1180
|
const TextArea = uuiCore.withMods(uuiComponents.TextArea, applyTextAreaMods, (props) => ({
|
|
@@ -942,18 +1182,20 @@ const TextArea = uuiCore.withMods(uuiComponents.TextArea, applyTextAreaMods, (pr
|
|
|
942
1182
|
maxLength: props.mode === exports.EditMode.CELL ? undefined : props.maxLength,
|
|
943
1183
|
}));
|
|
944
1184
|
|
|
945
|
-
var css$
|
|
1185
|
+
var css$12 = {"root":"zOegt3"};
|
|
946
1186
|
|
|
947
1187
|
function applyDropdownContainerMods(mods) {
|
|
948
1188
|
return [
|
|
949
|
-
css$
|
|
1189
|
+
css$12.root,
|
|
1190
|
+
mods.vPadding && `vPadding-${mods.vPadding}`,
|
|
1191
|
+
mods.padding && `padding-${mods.padding}`,
|
|
950
1192
|
];
|
|
951
1193
|
}
|
|
952
1194
|
const DropdownContainer = uuiCore.withMods(uuiComponents__namespace.DropdownContainer, applyDropdownContainerMods);
|
|
953
1195
|
|
|
954
|
-
var css$
|
|
1196
|
+
var css$11 = {"root":"bVj5a8","icon":"-B-Fzs","date-input":"RPoQmy","dateInput":"RPoQmy"};
|
|
955
1197
|
|
|
956
|
-
const TimePickerBody = uuiCore.withMods(uuiComponents.TimePickerBody, () => [css$
|
|
1198
|
+
const TimePickerBody = uuiCore.withMods(uuiComponents.TimePickerBody, () => [css$11.root], () => ({ addIcon: ForwardRef$1b, subtractIcon: ForwardRef$1b }));
|
|
957
1199
|
|
|
958
1200
|
dayjs__default.default.extend(customParseFormat__default.default);
|
|
959
1201
|
const defaultMode$2 = exports.EditMode.FORM;
|
|
@@ -973,7 +1215,7 @@ class TimePicker extends uuiComponents.BaseTimePicker {
|
|
|
973
1215
|
});
|
|
974
1216
|
}
|
|
975
1217
|
}
|
|
976
|
-
return (React__namespace.default.createElement(TextInput, Object.assign({}, props, { onClick: null, size: this.props.size || '36', isDisabled: this.props.isDisabled, isReadonly: this.props.isReadonly, isInvalid: this.props.isInvalid, cx: [css$
|
|
1218
|
+
return (React__namespace.default.createElement(TextInput, Object.assign({}, props, { onClick: null, size: this.props.size || '36', isDisabled: this.props.isDisabled, isReadonly: this.props.isReadonly, isInvalid: this.props.isInvalid, cx: [css$11.root, css$11.dateInput, this.props.inputCx], value: this.state.value, onValueChange: this.handleInputChange, onCancel: this.onClear, onFocus: this.handleFocus, onBlur: this.handleBlur, isDropdown: false, placeholder: this.props.placeholder ? this.props.placeholder : this.getFormat(), mode: this.props.mode || defaultMode$2, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.input })));
|
|
977
1219
|
};
|
|
978
1220
|
this.renderBody = (props) => {
|
|
979
1221
|
var _a;
|
|
@@ -983,50 +1225,23 @@ class TimePicker extends uuiComponents.BaseTimePicker {
|
|
|
983
1225
|
}
|
|
984
1226
|
}
|
|
985
1227
|
|
|
986
|
-
var css$
|
|
1228
|
+
var css$10 = {"root":"HtayTa"};
|
|
987
1229
|
|
|
988
1230
|
function applyInputAddonMods() {
|
|
989
1231
|
return [
|
|
990
|
-
css$
|
|
1232
|
+
css$10.root,
|
|
991
1233
|
];
|
|
992
1234
|
}
|
|
993
1235
|
const InputAddon = uuiCore.withMods(uuiComponents.InputAddon, applyInputAddonMods);
|
|
994
1236
|
|
|
995
|
-
var css
|
|
1237
|
+
var css$$ = {"root":"i6Is7L"};
|
|
996
1238
|
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
1002
|
-
width: 18,
|
|
1003
|
-
height: 18,
|
|
1004
|
-
viewBox: "0 0 18 18",
|
|
1005
|
-
ref: ref
|
|
1006
|
-
}, props), _path$I || (_path$I = /*#__PURE__*/React__namespace.createElement("path", {
|
|
1007
|
-
fillRule: "evenodd",
|
|
1008
|
-
d: "M11.557 5.558 10.5 4.5 6 9l4.5 4.5 1.057-1.057L8.123 9l3.434-3.442z",
|
|
1009
|
-
clipRule: "evenodd"
|
|
1010
|
-
})));
|
|
1011
|
-
};
|
|
1012
|
-
var ForwardRef$J = /*#__PURE__*/React.forwardRef(SvgNavigationChevronLeft18);
|
|
1239
|
+
function applySliderMods() {
|
|
1240
|
+
return [css$$.root];
|
|
1241
|
+
}
|
|
1242
|
+
const Slider = uuiCore.withMods(uuiComponents.Slider, applySliderMods);
|
|
1013
1243
|
|
|
1014
|
-
var
|
|
1015
|
-
function _extends$I() { _extends$I = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$I.apply(this, arguments); }
|
|
1016
|
-
var SvgNavigationChevronRight18 = function SvgNavigationChevronRight18(props, ref) {
|
|
1017
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$I({
|
|
1018
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
1019
|
-
width: 18,
|
|
1020
|
-
height: 18,
|
|
1021
|
-
viewBox: "0 0 18 18",
|
|
1022
|
-
ref: ref
|
|
1023
|
-
}, props), _path$H || (_path$H = /*#__PURE__*/React__namespace.createElement("path", {
|
|
1024
|
-
fillRule: "evenodd",
|
|
1025
|
-
d: "M7.5 4.5 6.442 5.558 9.877 9l-3.435 3.443L7.5 13.5 12 9 7.5 4.5z",
|
|
1026
|
-
clipRule: "evenodd"
|
|
1027
|
-
})));
|
|
1028
|
-
};
|
|
1029
|
-
var ForwardRef$I = /*#__PURE__*/React.forwardRef(SvgNavigationChevronRight18);
|
|
1244
|
+
var css$_ = {"container":"hHnkCY"};
|
|
1030
1245
|
|
|
1031
1246
|
dayjs__default.default.extend(localeData__default.default);
|
|
1032
1247
|
const uuiHeader = {
|
|
@@ -1101,20 +1316,22 @@ function DatePickerHeader(props) {
|
|
|
1101
1316
|
var _a, _b, _c;
|
|
1102
1317
|
return `${((_a = props.value) === null || _a === void 0 ? void 0 : _a.view) !== 'MONTH_SELECTION' ? dayjs__default.default.months()[(_b = props.value) === null || _b === void 0 ? void 0 : _b.displayedDate.month()] : ''} ${(_c = props.value) === null || _c === void 0 ? void 0 : _c.displayedDate.year()}`;
|
|
1103
1318
|
}, [(_a = props.value) === null || _a === void 0 ? void 0 : _a.view, (_b = props.value) === null || _b === void 0 ? void 0 : _b.displayedDate]);
|
|
1104
|
-
return (React__namespace.createElement("div", { className: cx__default.default(css$
|
|
1319
|
+
return (React__namespace.createElement("div", { className: cx__default.default(css$_.container, uuiHeader.container, props.cx) },
|
|
1105
1320
|
React__namespace.createElement("header", { className: uuiHeader.header },
|
|
1106
|
-
React__namespace.createElement(Button, { icon: ForwardRef$
|
|
1107
|
-
React__namespace.createElement(Button, { caption: title,
|
|
1108
|
-
React__namespace.createElement(Button, { icon: ForwardRef$
|
|
1321
|
+
React__namespace.createElement(Button, { icon: props.navIconLeft || ForwardRef$M, color: "secondary", fill: "ghost", cx: uuiHeader.navIconLeft, onClick: () => onLeftNavigationArrow() }),
|
|
1322
|
+
React__namespace.createElement(Button, { caption: title, fill: "ghost", cx: uuiHeader.navTitle, onClick: () => onCaptionClick(props.value.view) }),
|
|
1323
|
+
React__namespace.createElement(Button, { icon: props.navIconRight || ForwardRef$L, color: "secondary", fill: "ghost", cx: uuiHeader.navIconRight, onClick: () => onRightNavigationArrow() }))));
|
|
1109
1324
|
}
|
|
1110
1325
|
|
|
1111
|
-
var css$
|
|
1326
|
+
var css$Z = {"uui-typography":"_0luRPY","hero-header":"I8ShoX","promo-header":"X5AHbP","uui-critical":"vvJeNC","uui-success":"UJOPvv","uui-warning":"TEvB8J","uui-typography-size-12":"LWivlJ","uui-typography-size-14":"Q1gxlm","uui-typography-size-16":"u4J1pZ","root":"eBu0Yg","uuiTypography":"_0luRPY","heroHeader":"I8ShoX","promoHeader":"X5AHbP","uuiCritical":"vvJeNC","uuiSuccess":"UJOPvv","uuiWarning":"TEvB8J","uuiTypographySize12":"LWivlJ","uuiTypographySize14":"Q1gxlm","uuiTypographySize16":"u4J1pZ"};
|
|
1112
1327
|
|
|
1113
1328
|
function applyDateSelectionMods() {
|
|
1114
|
-
return [css$
|
|
1329
|
+
return [css$Z.root];
|
|
1115
1330
|
}
|
|
1116
1331
|
const Calendar = uuiCore.withMods(uuiComponents.Calendar, applyDateSelectionMods);
|
|
1117
1332
|
|
|
1333
|
+
var css$Y = {"uui-typography":"eeqC4H","hero-header":"vCQzFG","promo-header":"_99L26i","uui-critical":"bKEb7B","uui-success":"pu8a1h","uui-warning":"z0tDwz","uui-typography-size-12":"rGgewF","uui-typography-size-14":"sdIhjS","uui-typography-size-16":"_2pjxtH","root":"UNeGQl","uuiTypography":"eeqC4H","heroHeader":"vCQzFG","promoHeader":"_99L26i","uuiCritical":"bKEb7B","uuiSuccess":"pu8a1h","uuiWarning":"z0tDwz","uuiTypographySize12":"rGgewF","uuiTypographySize14":"sdIhjS","uuiTypographySize16":"_2pjxtH"};
|
|
1334
|
+
|
|
1118
1335
|
dayjs__default.default.extend(updateLocale__default.default);
|
|
1119
1336
|
const uuiDatePickerBody = {
|
|
1120
1337
|
wrapper: 'uui-datepickerBody-wrapper',
|
|
@@ -1140,8 +1357,8 @@ class DatePickerBody extends uuiComponents.DatePickerBodyBase {
|
|
|
1140
1357
|
return (React__namespace.createElement(Calendar, { value: dayjs__default.default(this.props.value.selectedDate), onValueChange: this.onDayClick, displayedDate: this.props.value.displayedDate, filter: this.props.filter, getDayCX: this.props.getDayCX, renderDay: this.props.renderDay, isHoliday: this.props.isHoliday }));
|
|
1141
1358
|
}
|
|
1142
1359
|
};
|
|
1143
|
-
this.
|
|
1144
|
-
return (React__namespace.createElement("div", { className: uuiCore.cx(uuiDatePickerBody.wrapper, this.props.cx) },
|
|
1360
|
+
this.renderBody = () => {
|
|
1361
|
+
return (React__namespace.createElement("div", { className: uuiCore.cx(css$Y.root, uuiDatePickerBody.wrapper, this.props.cx) },
|
|
1145
1362
|
React__namespace.createElement(DatePickerHeader, { value: this.props.value, onValueChange: (newValue) => this.props.setDisplayedDateAndView(newValue.displayedDate, newValue.view) }),
|
|
1146
1363
|
this.getView()));
|
|
1147
1364
|
};
|
|
@@ -1150,106 +1367,106 @@ class DatePickerBody extends uuiComponents.DatePickerBodyBase {
|
|
|
1150
1367
|
}
|
|
1151
1368
|
}
|
|
1152
1369
|
|
|
1153
|
-
var _path$
|
|
1154
|
-
function _extends$
|
|
1370
|
+
var _path$E;
|
|
1371
|
+
function _extends$F() { _extends$F = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$F.apply(this, arguments); }
|
|
1155
1372
|
var SvgNotificationCheckCircleFill24 = function SvgNotificationCheckCircleFill24(props, ref) {
|
|
1156
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1373
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$F({
|
|
1157
1374
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1158
1375
|
width: 24,
|
|
1159
1376
|
height: 24,
|
|
1160
1377
|
viewBox: "0 0 24 24",
|
|
1161
1378
|
ref: ref
|
|
1162
|
-
}, props), _path$
|
|
1379
|
+
}, props), _path$E || (_path$E = /*#__PURE__*/React__namespace.createElement("path", {
|
|
1163
1380
|
fillRule: "evenodd",
|
|
1164
1381
|
d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm-2 15-5-5 1.41-1.41L10 14.17l7.59-7.59L19 8l-9 9z"
|
|
1165
1382
|
})));
|
|
1166
1383
|
};
|
|
1167
|
-
var ForwardRef$
|
|
1384
|
+
var ForwardRef$F = /*#__PURE__*/React.forwardRef(SvgNotificationCheckCircleFill24);
|
|
1168
1385
|
|
|
1169
|
-
var _path$
|
|
1170
|
-
function _extends$
|
|
1386
|
+
var _path$D;
|
|
1387
|
+
function _extends$E() { _extends$E = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$E.apply(this, arguments); }
|
|
1171
1388
|
var SvgNotificationWarningFill24 = function SvgNotificationWarningFill24(props, ref) {
|
|
1172
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1389
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$E({
|
|
1173
1390
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1174
1391
|
width: 24,
|
|
1175
1392
|
height: 24,
|
|
1176
1393
|
viewBox: "0 0 24 24",
|
|
1177
1394
|
ref: ref
|
|
1178
|
-
}, props), _path$
|
|
1395
|
+
}, props), _path$D || (_path$D = /*#__PURE__*/React__namespace.createElement("path", {
|
|
1179
1396
|
fillRule: "evenodd",
|
|
1180
1397
|
d: "M1 21h22L12 2 1 21zm12-3h-2v-2h2v2zm0-4h-2v-4h2v4z"
|
|
1181
1398
|
})));
|
|
1182
1399
|
};
|
|
1183
|
-
var ForwardRef$
|
|
1400
|
+
var ForwardRef$E = /*#__PURE__*/React.forwardRef(SvgNotificationWarningFill24);
|
|
1184
1401
|
|
|
1185
|
-
var _path$
|
|
1186
|
-
function _extends$
|
|
1402
|
+
var _path$C;
|
|
1403
|
+
function _extends$D() { _extends$D = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$D.apply(this, arguments); }
|
|
1187
1404
|
var SvgNotificationErrorFill24 = function SvgNotificationErrorFill24(props, ref) {
|
|
1188
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1405
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$D({
|
|
1189
1406
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1190
1407
|
width: 24,
|
|
1191
1408
|
height: 24,
|
|
1192
1409
|
viewBox: "0 0 24 24",
|
|
1193
1410
|
ref: ref
|
|
1194
|
-
}, props), _path$
|
|
1411
|
+
}, props), _path$C || (_path$C = /*#__PURE__*/React__namespace.createElement("path", {
|
|
1195
1412
|
fillRule: "evenodd",
|
|
1196
1413
|
d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"
|
|
1197
1414
|
})));
|
|
1198
1415
|
};
|
|
1199
|
-
var ForwardRef$
|
|
1416
|
+
var ForwardRef$D = /*#__PURE__*/React.forwardRef(SvgNotificationErrorFill24);
|
|
1200
1417
|
|
|
1201
|
-
var _path$
|
|
1202
|
-
function _extends$
|
|
1418
|
+
var _path$B;
|
|
1419
|
+
function _extends$C() { _extends$C = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$C.apply(this, arguments); }
|
|
1203
1420
|
var SvgNotificationHelpFill24 = function SvgNotificationHelpFill24(props, ref) {
|
|
1204
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1421
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$C({
|
|
1205
1422
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1206
1423
|
width: 24,
|
|
1207
1424
|
height: 24,
|
|
1208
1425
|
viewBox: "0 0 24 24",
|
|
1209
1426
|
ref: ref
|
|
1210
|
-
}, props), _path$
|
|
1427
|
+
}, props), _path$B || (_path$B = /*#__PURE__*/React__namespace.createElement("path", {
|
|
1211
1428
|
fillRule: "evenodd",
|
|
1212
1429
|
d: "M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 17h-2v-2h2v2zm2.07-7.75-.9.92C13.45 12.9 13 13.5 13 15h-2v-.5c0-1.1.45-2.1 1.17-2.83l1.24-1.26c.37-.36.59-.86.59-1.41 0-1.1-.9-2-2-2s-2 .9-2 2H8c0-2.21 1.79-4 4-4s4 1.79 4 4c0 .88-.36 1.68-.93 2.25z"
|
|
1213
1430
|
})));
|
|
1214
1431
|
};
|
|
1215
|
-
var ForwardRef$
|
|
1432
|
+
var ForwardRef$C = /*#__PURE__*/React.forwardRef(SvgNotificationHelpFill24);
|
|
1216
1433
|
|
|
1217
|
-
var _path$
|
|
1218
|
-
function _extends$
|
|
1434
|
+
var _path$A;
|
|
1435
|
+
function _extends$B() { _extends$B = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$B.apply(this, arguments); }
|
|
1219
1436
|
var SvgNavigationClose24$1 = function SvgNavigationClose24(props, ref) {
|
|
1220
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1437
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$B({
|
|
1221
1438
|
xmlns: "http://www.w3.org/2000/svg",
|
|
1222
1439
|
width: 24,
|
|
1223
1440
|
height: 24,
|
|
1224
1441
|
viewBox: "0 0 24 24",
|
|
1225
1442
|
ref: ref
|
|
1226
|
-
}, props), _path$
|
|
1443
|
+
}, props), _path$A || (_path$A = /*#__PURE__*/React__namespace.createElement("path", {
|
|
1227
1444
|
fillRule: "evenodd",
|
|
1228
1445
|
d: "M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"
|
|
1229
1446
|
})));
|
|
1230
1447
|
};
|
|
1231
|
-
var ForwardRef$
|
|
1448
|
+
var ForwardRef$B = /*#__PURE__*/React.forwardRef(SvgNavigationClose24$1);
|
|
1232
1449
|
|
|
1233
|
-
var css$
|
|
1450
|
+
var css$X = {"root":"KoUIMl","icon-wrapper":"-GbN7J","alert-wrapper":"Ej-McX","size-48":"SfSn1o","size-36":"GCLvIP","action-wrapper":"OV2c3-","action-icon":"nC1q5A","action-link":"fKsbUr","close-icon":"u2pb-R","main-path":"fP1cmr","content":"_6040CY","iconWrapper":"-GbN7J","alertWrapper":"Ej-McX","size48":"SfSn1o","size36":"GCLvIP","actionWrapper":"OV2c3-","actionIcon":"nC1q5A","actionLink":"fKsbUr","closeIcon":"u2pb-R","mainPath":"fP1cmr"};
|
|
1234
1451
|
|
|
1235
|
-
const Alert = React__namespace.forwardRef((props, ref) => (React__namespace.createElement("div", Object.assign({ role: "alert", ref: ref, className: cx__default.default(css$
|
|
1236
|
-
React__namespace.createElement("div", { className: css$
|
|
1237
|
-
props.icon && (React__namespace.createElement("div", { className: css$
|
|
1238
|
-
React__namespace.createElement(uuiComponents.IconContainer, { icon: props.icon, cx: css$
|
|
1239
|
-
React__namespace.createElement("div", { className: css$
|
|
1452
|
+
const Alert = React__namespace.forwardRef((props, ref) => (React__namespace.createElement("div", Object.assign({ role: "alert", ref: ref, className: cx__default.default('uui-alert', css$X.root, css$X.alertWrapper, props.color && `uui-color-${props.color}`, props.cx, (props.size === '36' ? css$X.size36 : css$X.size48)) }, props.rawProps),
|
|
1453
|
+
React__namespace.createElement("div", { className: css$X.mainPath },
|
|
1454
|
+
props.icon && (React__namespace.createElement("div", { className: css$X.iconWrapper },
|
|
1455
|
+
React__namespace.createElement(uuiComponents.IconContainer, { icon: props.icon, cx: css$X.actionIcon }))),
|
|
1456
|
+
React__namespace.createElement("div", { className: css$X.content },
|
|
1240
1457
|
props.children,
|
|
1241
|
-
props.actions && (React__namespace.createElement("div", { className: css$
|
|
1242
|
-
props.onClose && React__namespace.createElement(IconButton, { icon: ForwardRef$
|
|
1243
|
-
const WarningAlert = React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, Object.assign({ icon: ForwardRef$
|
|
1244
|
-
const SuccessAlert = React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, Object.assign({ icon: ForwardRef$
|
|
1245
|
-
const HintAlert = React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, Object.assign({ icon: ForwardRef$
|
|
1246
|
-
const ErrorAlert = React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, Object.assign({ icon: ForwardRef$
|
|
1458
|
+
props.actions && (React__namespace.createElement("div", { className: css$X.actionWrapper }, props.actions.map((action) => (React__namespace.createElement(LinkButton, { caption: action.name, onClick: action.action, key: action.name, cx: css$X.actionLink, size: (props === null || props === void 0 ? void 0 : props.size) === '36' ? '24' : '30' })))))),
|
|
1459
|
+
props.onClose && React__namespace.createElement(IconButton, { icon: ForwardRef$B, color: "neutral", onClick: props.onClose, cx: css$X.closeIcon })))));
|
|
1460
|
+
const WarningAlert = React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, Object.assign({ icon: ForwardRef$E, color: "warning", ref: ref }, props)));
|
|
1461
|
+
const SuccessAlert = React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, Object.assign({ icon: ForwardRef$F, color: "success", ref: ref }, props)));
|
|
1462
|
+
const HintAlert = React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, Object.assign({ icon: ForwardRef$C, color: "info", ref: ref }, props)));
|
|
1463
|
+
const ErrorAlert = React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, Object.assign({ icon: ForwardRef$D, color: "error", ref: ref }, props)));
|
|
1247
1464
|
|
|
1248
1465
|
function Dropdown(props) {
|
|
1249
1466
|
return React__namespace.createElement(uuiComponents.Dropdown, Object.assign({}, props));
|
|
1250
1467
|
}
|
|
1251
1468
|
|
|
1252
|
-
var css$
|
|
1469
|
+
var css$W = {"uui-typography":"xg9nMp","hero-header":"_96hWwf","promo-header":"_0kcJUW","uui-critical":"iEdwhf","uui-success":"S-2FvP","uui-warning":"YGcauS","uui-typography-size-12":"MjJSkJ","uui-typography-size-14":"ITj0AB","uui-typography-size-16":"JYHFwV","root":"SYbzu8","bodyRoot":"uIUDhI","submenuRootItem":"rCRRoE","iconAfter":"w9-S58","iconCheck":"tSMiP7","splitterRoot":"_2QPbMc","splitter":"SveQBA","headerRoot":"_11IGTt","itemRoot":"_5Rhd10","icon":"_20OJGT","link":"_2i8eJn","indent":"SXcXyx","uuiTypography":"xg9nMp","heroHeader":"_96hWwf","promoHeader":"_0kcJUW","uuiCritical":"iEdwhf","uuiSuccess":"S-2FvP","uuiWarning":"YGcauS","uuiTypographySize12":"MjJSkJ","uuiTypographySize14":"ITj0AB","uuiTypographySize16":"JYHFwV"};
|
|
1253
1470
|
|
|
1254
1471
|
const icons = systemIcons['36'];
|
|
1255
1472
|
exports.IDropdownControlKeys = void 0;
|
|
@@ -1284,9 +1501,9 @@ function DropdownMenuContainer(props) {
|
|
|
1284
1501
|
props.onClose();
|
|
1285
1502
|
}
|
|
1286
1503
|
};
|
|
1287
|
-
return (React__namespace.default.createElement(DropdownContainer, Object.assign({}, props, { rawProps: Object.assign(Object.assign({}, props.rawProps), { role: 'menu' }), ref: menuRef, lockProps: { onKeyDown: handleArrowKeys } })));
|
|
1504
|
+
return (React__namespace.default.createElement(DropdownContainer, Object.assign({}, props, { rawProps: Object.assign(Object.assign({}, props.rawProps), { role: 'menu' }), ref: menuRef, lockProps: { onKeyDown: handleArrowKeys }, cx: css$W.root })));
|
|
1288
1505
|
}
|
|
1289
|
-
const DropdownMenuBody = uuiCore.withMods(DropdownMenuContainer, () => [css$
|
|
1506
|
+
const DropdownMenuBody = uuiCore.withMods(DropdownMenuContainer, () => [css$W.bodyRoot], (props) => {
|
|
1290
1507
|
const dropdownRawProps = props.minWidth ? Object.assign(Object.assign({}, props.rawProps), { style: { minWidth: `${props.minWidth}px` } }) : null;
|
|
1291
1508
|
return (Object.assign(Object.assign({ closeOnKey: exports.IDropdownControlKeys.ESCAPE }, props), { rawProps: dropdownRawProps || props.rawProps }));
|
|
1292
1509
|
});
|
|
@@ -1310,32 +1527,32 @@ const DropdownMenuButton = React__namespace.default.forwardRef((props, ref) => {
|
|
|
1310
1527
|
const getMenuButtonContent = () => {
|
|
1311
1528
|
const isIconBefore = Boolean(icon && iconPosition !== 'right');
|
|
1312
1529
|
const isIconAfter = Boolean(icon && iconPosition === 'right');
|
|
1313
|
-
const iconElement = (React__namespace.default.createElement(IconButton, { icon: icon, color: isActive ? 'info' : '
|
|
1530
|
+
const iconElement = (React__namespace.default.createElement(IconButton, { icon: icon, color: isActive ? 'info' : 'neutral', onClick: onIconClick, isDisabled: isDisabled, cx: uuiCore.cx(css$W.root, css$W.icon, iconPosition === 'right' ? css$W.iconAfter : css$W.iconBefore) }));
|
|
1314
1531
|
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
1315
1532
|
isIconBefore && iconElement,
|
|
1316
|
-
React__namespace.default.createElement(uuiComponents.Text, { cx: props.indent && css$
|
|
1533
|
+
React__namespace.default.createElement(uuiComponents.Text, { cx: props.indent && css$W.indent }, caption),
|
|
1317
1534
|
isIconAfter && (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
1318
1535
|
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
1319
1536
|
iconElement))));
|
|
1320
1537
|
};
|
|
1321
1538
|
const isAnchor = Boolean(link || href);
|
|
1322
|
-
const itemClassNames = uuiCore.cx(props.cx, css$
|
|
1323
|
-
return isAnchor ? (React__namespace.default.createElement(uuiComponents.Anchor, { cx: uuiCore.cx(css$
|
|
1539
|
+
const itemClassNames = uuiCore.cx(css$W.root, props.cx, css$W.itemRoot, isDisabled && uuiCore.uuiMod.disabled, isActive && uuiCore.uuiMod.active, isOpen && uuiCore.uuiMod.opened);
|
|
1540
|
+
return isAnchor ? (React__namespace.default.createElement(uuiComponents.Anchor, { cx: uuiCore.cx(css$W.link, itemClassNames), link: link, href: href, rawProps: { role: 'menuitem', tabIndex: isDisabled ? -1 : 0 }, onClick: handleClick, isDisabled: isDisabled, forwardedRef: ref, target: target }, getMenuButtonContent())) : (React__namespace.default.createElement(uuiComponents.FlexRow, { rawProps: {
|
|
1324
1541
|
tabIndex: isDisabled ? -1 : 0,
|
|
1325
1542
|
role: 'menuitem',
|
|
1326
1543
|
onKeyDown: isDisabled ? null : handleOpenDropdown,
|
|
1327
1544
|
}, cx: itemClassNames, onClick: handleClick, ref: ref },
|
|
1328
1545
|
getMenuButtonContent(),
|
|
1329
|
-
isSelected && React__namespace.default.createElement(uuiComponents.IconContainer, { icon: icons.accept, cx: css$
|
|
1546
|
+
isSelected && React__namespace.default.createElement(uuiComponents.IconContainer, { icon: icons.accept, cx: uuiCore.cx(css$W.root, css$W.selectedCheckmark) })));
|
|
1330
1547
|
});
|
|
1331
1548
|
DropdownMenuButton.displayName = 'DropdownMenuButton';
|
|
1332
1549
|
function DropdownMenuSplitter(props) {
|
|
1333
|
-
return (React__namespace.default.createElement("div", { className: uuiCore.cx(props.cx, css$
|
|
1334
|
-
React__namespace.default.createElement("hr", { className: css$
|
|
1550
|
+
return (React__namespace.default.createElement("div", { className: uuiCore.cx(css$W.root, props.cx, css$W.splitterRoot) },
|
|
1551
|
+
React__namespace.default.createElement("hr", { className: css$W.splitter })));
|
|
1335
1552
|
}
|
|
1336
1553
|
function DropdownMenuHeader(props) {
|
|
1337
|
-
return (React__namespace.default.createElement("div", { className: uuiCore.cx(props.cx, css$
|
|
1338
|
-
React__namespace.default.createElement("span", { className: css$
|
|
1554
|
+
return (React__namespace.default.createElement("div", { className: uuiCore.cx('uui-dropdown-menu-header', css$W.root, props.cx, css$W.headerRoot) },
|
|
1555
|
+
React__namespace.default.createElement("span", { className: css$W.header }, props.caption)));
|
|
1339
1556
|
}
|
|
1340
1557
|
function DropdownSubMenu(props) {
|
|
1341
1558
|
const subMenuModifiers = [
|
|
@@ -1355,7 +1572,7 @@ function DropdownSubMenu(props) {
|
|
|
1355
1572
|
];
|
|
1356
1573
|
return (React__namespace.default.createElement(uuiComponents.Dropdown, { openOnHover: props.openOnHover || true, closeOnMouseLeave: "boundary", openDelay: 400, closeDelay: 400, placement: "right-start", modifiers: subMenuModifiers, renderBody: (dropdownProps) => React__namespace.default.createElement(DropdownMenuBody, Object.assign({ closeOnKey: exports.IDropdownControlKeys.LEFT_ARROW }, props, dropdownProps)), renderTarget: (_a) => {
|
|
1357
1574
|
var { toggleDropdownOpening } = _a, targetProps = __rest(_a, ["toggleDropdownOpening"]);
|
|
1358
|
-
return (React__namespace.default.createElement(DropdownMenuButton, Object.assign({ cx: uuiCore.cx(css$
|
|
1575
|
+
return (React__namespace.default.createElement(DropdownMenuButton, Object.assign({ cx: uuiCore.cx(css$W.root, css$W.submenuRootItem), icon: icons.foldingArrow, iconPosition: "right", isDropdown: true, toggleDropdownOpening: toggleDropdownOpening }, props, targetProps)));
|
|
1359
1576
|
} }));
|
|
1360
1577
|
}
|
|
1361
1578
|
function DropdownMenuSwitchButton(props) {
|
|
@@ -1372,116 +1589,41 @@ function DropdownMenuSwitchButton(props) {
|
|
|
1372
1589
|
onHandleValueChange(!isSelected);
|
|
1373
1590
|
}
|
|
1374
1591
|
};
|
|
1375
|
-
return (React__namespace.default.createElement(uuiComponents.FlexRow, { cx: uuiCore.cx(props.cx, css$
|
|
1376
|
-
icon && React__namespace.default.createElement(uuiComponents.IconContainer, { icon: icon, cx: css$
|
|
1592
|
+
return (React__namespace.default.createElement(uuiComponents.FlexRow, { cx: uuiCore.cx(props.cx, css$W.itemRoot, isDisabled && uuiCore.uuiMod.disabled), onClick: () => onHandleValueChange(!isSelected), rawProps: { role: 'menuitem', onKeyDown: handleKeySelect, tabIndex: isDisabled ? -1 : 0 } },
|
|
1593
|
+
icon && React__namespace.default.createElement(uuiComponents.IconContainer, { icon: icon, cx: css$W.iconBefore }),
|
|
1377
1594
|
React__namespace.default.createElement(uuiComponents.Text, null, caption),
|
|
1378
1595
|
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
1379
1596
|
React__namespace.default.createElement(Switch, { value: isSelected, tabIndex: -1, onValueChange: onHandleValueChange })));
|
|
1380
1597
|
}
|
|
1381
1598
|
|
|
1382
|
-
var css$
|
|
1599
|
+
var css$V = {"uui-typography":"CT49Rd","hero-header":"-ZNcvB","promo-header":"Cwjxo7","uui-critical":"_7RXfQT","uui-success":"k-2Tmz","uui-warning":"xDQHuU","uui-typography-size-12":"PxiFGn","uui-typography-size-14":"gXBmbX","uui-typography-size-16":"d32yiv","root":"TlEJ7m","border-bottom":"Gh-MGX","top-shadow":"X75T31","size-24":"_1n8gIg","size-30":"_93CcAr","size-36":"-GI1W4","size-42":"lUC9BM","size-48":"-DT3-t","padding-6":"_6LwJ99","padding-12":"BRVp5n","padding-18":"ffCcFg","padding-24":"_3AYFIW","margin-24":"UfQBLo","margin-12":"H-nGTD","vPadding-12":"_33ExSh","vPadding-18":"_1PxwKl","vPadding-24":"_6vZMan","vPadding-36":"_4my7K4","vPadding-48":"pH0Win","spacing-6":"LYJnCe","spacing-12":"gZHl6d","spacing-18":"_0e8-3f","uuiTypography":"CT49Rd","heroHeader":"-ZNcvB","promoHeader":"Cwjxo7","uuiCritical":"_7RXfQT","uuiSuccess":"k-2Tmz","uuiWarning":"xDQHuU","uuiTypographySize12":"PxiFGn","uuiTypographySize14":"gXBmbX","uuiTypographySize16":"d32yiv","borderBottom":"Gh-MGX","topShadow":"X75T31","size24":"_1n8gIg","size30":"_93CcAr","size36":"-GI1W4","size42":"lUC9BM","size48":"-DT3-t","padding6":"_6LwJ99","padding12":"BRVp5n","padding18":"ffCcFg","padding24":"_3AYFIW","margin24":"UfQBLo","margin12":"H-nGTD","vPadding12":"_33ExSh","vPadding18":"_1PxwKl","vPadding24":"_6vZMan","vPadding36":"_4my7K4","vPadding48":"pH0Win","spacing6":"LYJnCe","spacing12":"gZHl6d","spacing18":"_0e8-3f"};
|
|
1383
1600
|
|
|
1384
|
-
const FlexCell = uuiCore.withMods(uuiComponents.FlexCell, () => [css$
|
|
1601
|
+
const FlexCell = uuiCore.withMods(uuiComponents.FlexCell, () => [css$V.flexCell]);
|
|
1385
1602
|
|
|
1386
1603
|
const FlexRow = uuiCore.withMods(uuiComponents.FlexRow, (props) => {
|
|
1387
1604
|
return [
|
|
1388
|
-
css$
|
|
1605
|
+
css$V.root,
|
|
1606
|
+
props.size !== null && css$V['size-' + (props.size || '36')],
|
|
1607
|
+
props.padding && css$V['padding-' + props.padding],
|
|
1608
|
+
props.vPadding && css$V['vPadding-' + props.vPadding],
|
|
1609
|
+
props.margin && css$V['margin-' + props.margin],
|
|
1610
|
+
props.topShadow && css$V.topShadow,
|
|
1611
|
+
props.borderBottom && css$V.borderBottom,
|
|
1612
|
+
props.spacing && css$V['spacing-' + props.spacing],
|
|
1613
|
+
props.background && `uui-color-${props.background}`,
|
|
1389
1614
|
];
|
|
1390
1615
|
});
|
|
1391
1616
|
|
|
1392
|
-
var css$
|
|
1617
|
+
var css$U = {"root":"_32-Uew","margin-24":"_95gsaC","padding-12":"FLdnqO","padding-24":"i5o6xC","shadow":"s3lSwL","margin24":"_95gsaC","padding12":"FLdnqO","padding24":"i5o6xC"};
|
|
1393
1618
|
|
|
1394
1619
|
const Panel = uuiCore.withMods(uuiComponents.VPanel, (props) => [
|
|
1395
|
-
'uui-panel',
|
|
1620
|
+
'uui-panel',
|
|
1621
|
+
css$U.root,
|
|
1622
|
+
props.shadow && css$U.shadow,
|
|
1623
|
+
props.margin && css$U['margin-' + props.margin],
|
|
1624
|
+
props.background && `uui-color-${props.background}`,
|
|
1396
1625
|
]);
|
|
1397
1626
|
|
|
1398
|
-
var css$$ = {"root":"D2QmF6"};
|
|
1399
|
-
|
|
1400
|
-
var css$_ = {"line-height-12":"Ls4HSs","line-height-18":"IBzWgI","line-height-24":"E2psIP","line-height-30":"_69eN-B","font-size-10":"_3Ox-cx","font-size-12":"ITyelp","font-size-14":"A7poa3","font-size-16":"kbczvD","font-size-18":"lz-0g5","font-size-24":"Uj-Yc6","v-padding-2":"yGrGJG","v-padding-3":"au3aEU","v-padding-5":"otrYJH","v-padding-6":"F9Lafv","v-padding-8":"REDQUM","v-padding-9":"hnnLS1","v-padding-11":"EIoA7G","v-padding-12":"uuRb9A","v-padding-14":"HnDGtX","v-padding-15":"L72KdE","v-padding-17":"kTiUaB","v-padding-18":"ge3TKQ","v-padding-23":"APGFcJ","v-padding-24":"_1sG0ba","lineHeight12":"Ls4HSs","lineHeight18":"IBzWgI","lineHeight24":"E2psIP","lineHeight30":"_69eN-B","fontSize10":"_3Ox-cx","fontSize12":"ITyelp","fontSize14":"A7poa3","fontSize16":"kbczvD","fontSize18":"lz-0g5","fontSize24":"Uj-Yc6","vPadding2":"yGrGJG","vPadding3":"au3aEU","vPadding5":"otrYJH","vPadding6":"F9Lafv","vPadding8":"REDQUM","vPadding9":"hnnLS1","vPadding11":"EIoA7G","vPadding12":"uuRb9A","vPadding14":"HnDGtX","vPadding15":"L72KdE","vPadding17":"kTiUaB","vPadding18":"ge3TKQ","vPadding23":"APGFcJ","vPadding24":"_1sG0ba"};
|
|
1401
|
-
|
|
1402
|
-
const defaultTextSettings = {
|
|
1403
|
-
18: { lineHeight: 12, fontSize: 10 },
|
|
1404
|
-
24: { lineHeight: 18, fontSize: 12 },
|
|
1405
|
-
30: { lineHeight: 18, fontSize: 14 },
|
|
1406
|
-
36: { lineHeight: 18, fontSize: 14 },
|
|
1407
|
-
42: { lineHeight: 24, fontSize: 16 },
|
|
1408
|
-
48: { lineHeight: 24, fontSize: 16 },
|
|
1409
|
-
60: { lineHeight: 30, fontSize: 24 },
|
|
1410
|
-
};
|
|
1411
|
-
function getTextClasses(props, border) {
|
|
1412
|
-
if (props.size === 'none') {
|
|
1413
|
-
return [css$_['line-height-' + props.lineHeight], css$_['font-size-' + props.fontSize]];
|
|
1414
|
-
}
|
|
1415
|
-
const setting = {
|
|
1416
|
-
size: props.size,
|
|
1417
|
-
lineHeight: props.lineHeight || defaultTextSettings[props.size].lineHeight,
|
|
1418
|
-
fontSize: props.fontSize || defaultTextSettings[props.size].fontSize,
|
|
1419
|
-
};
|
|
1420
|
-
const vPadding = (+setting.size - +setting.lineHeight - (border ? 2 : 0)) / 2;
|
|
1421
|
-
return [
|
|
1422
|
-
css$_['line-height-' + setting.lineHeight], css$_['font-size-' + setting.fontSize], css$_['v-padding-' + vPadding],
|
|
1423
|
-
];
|
|
1424
|
-
}
|
|
1425
|
-
|
|
1426
|
-
function applyTextMods(mods) {
|
|
1427
|
-
const textClasses = getTextClasses({
|
|
1428
|
-
size: mods.size || '36',
|
|
1429
|
-
lineHeight: mods.lineHeight,
|
|
1430
|
-
fontSize: mods.fontSize,
|
|
1431
|
-
}, false);
|
|
1432
|
-
return [
|
|
1433
|
-
`uui-font-${mods.font || 'regular'}`,
|
|
1434
|
-
`uui-text-${mods.color || 'primary'}`,
|
|
1435
|
-
css$$.root,
|
|
1436
|
-
].concat(textClasses);
|
|
1437
|
-
}
|
|
1438
|
-
const Text = uuiCore.withMods(uuiComponents.Text, applyTextMods);
|
|
1439
|
-
|
|
1440
|
-
var css$Z = {"container":"_5gNYlx","loading-word":"_1wEsVw","animated-loading":"P-Cskh","skeleton_loading":"MS-uNo","loadingWord":"_1wEsVw","animatedLoading":"P-Cskh","skeletonLoading":"MS-uNo"};
|
|
1441
|
-
|
|
1442
|
-
const TextPlaceholder = (props) => {
|
|
1443
|
-
const pattern = ' ';
|
|
1444
|
-
const text = React__namespace.useMemo(() => {
|
|
1445
|
-
const words = [];
|
|
1446
|
-
for (let i = 0; i < (props.wordsCount || 1); i++) {
|
|
1447
|
-
const lengthWord = Math.floor(Math.random() * 10 + 8);
|
|
1448
|
-
words.push(pattern.repeat(lengthWord));
|
|
1449
|
-
}
|
|
1450
|
-
return words;
|
|
1451
|
-
}, [props.wordsCount]);
|
|
1452
|
-
return (React__namespace.createElement("div", Object.assign({ "aria-busy": true, className: css$Z.container }, props.rawProps), text.map((it, index) => (React__namespace.createElement("span", { key: index, className: cx__default.default([
|
|
1453
|
-
props.cx, css$Z.loadingWord, !props.isNotAnimated && css$Z.animatedLoading,
|
|
1454
|
-
]), dangerouslySetInnerHTML: { __html: it } })))));
|
|
1455
|
-
};
|
|
1456
|
-
|
|
1457
|
-
var style = {"typography-16":"VsECio","typography-14":"_2eIIED","typography-12":"Rp8Q1e","typography-uui":"wQ5LA6","typography16":"VsECio","typography14":"_2eIIED","typography12":"Rp8Q1e","typographyUui":"wQ5LA6"};
|
|
1458
|
-
|
|
1459
|
-
const RichTextView = uuiCore.withMods(uuiComponents__namespace.RichTextView, (mods) => [style.typographyUui, style['typography-' + (mods.size || '14')]]);
|
|
1460
|
-
|
|
1461
|
-
var css$Y = {"modal-blocker":"YU0A8K","animateModalBlocker":"_4yQzYl","modal":"YTQxCZ","modal-footer":"V-m7u0","border-top":"CLfKji","modal-header":"RtBELJ","modalBlocker":"YU0A8K","modalFooter":"V-m7u0","borderTop":"CLfKji","modalHeader":"RtBELJ"};
|
|
1462
|
-
|
|
1463
|
-
const ModalBlocker = uuiCore.withMods(uuiComponents.ModalBlocker, () => [css$Y.modalBlocker]);
|
|
1464
|
-
const ModalWindow = uuiCore.withMods(uuiComponents.ModalWindow, () => [css$Y.modal], (props) => ({
|
|
1465
|
-
style: Object.assign(Object.assign({}, props.style), { width: `${props.width || 420}px`, height: props.height ? `${props.height}px` : 'auto' }),
|
|
1466
|
-
}));
|
|
1467
|
-
class ModalHeader extends React__namespace.Component {
|
|
1468
|
-
render() {
|
|
1469
|
-
return (React__namespace.createElement(FlexRow, { padding: this.props.padding || '24', vPadding: "12", borderBottom: this.props.borderBottom, cx: [css$Y.modalHeader, this.props.cx], spacing: "12", rawProps: this.props.rawProps },
|
|
1470
|
-
this.props.title && (React__namespace.createElement(Text, { size: "48", fontSize: "18", font: "semibold" }, this.props.title)),
|
|
1471
|
-
this.props.children,
|
|
1472
|
-
this.props.onClose && React__namespace.createElement(uuiComponents.FlexSpacer, null),
|
|
1473
|
-
this.props.onClose && (React__namespace.createElement(FlexCell, { shrink: 0, width: "auto" },
|
|
1474
|
-
React__namespace.createElement(IconButton, { rawProps: { 'aria-label': 'Close modal' }, icon: ForwardRef$D, onClick: this.props.onClose })))));
|
|
1475
|
-
}
|
|
1476
|
-
}
|
|
1477
|
-
class ModalFooter extends React__namespace.Component {
|
|
1478
|
-
render() {
|
|
1479
|
-
return (React__namespace.createElement(FlexRow, { spacing: this.props.spacing || '12', cx: [
|
|
1480
|
-
css$Y.modalFooter, this.props.borderTop && css$Y.borderTop, this.props.cx,
|
|
1481
|
-
], padding: this.props.padding || '24', vPadding: this.props.vPadding || '24', rawProps: this.props.rawProps }, this.props.children));
|
|
1482
|
-
}
|
|
1483
|
-
}
|
|
1484
|
-
|
|
1485
1627
|
const i18n = Object.assign(Object.assign({}, uuiCore.i18n), { dataPickerBody: {
|
|
1486
1628
|
searchPlaceholder: 'Search',
|
|
1487
1629
|
noRecordsMessage: 'No records found',
|
|
@@ -1571,94 +1713,43 @@ const i18n = Object.assign(Object.assign({}, uuiCore.i18n), { dataPickerBody: {
|
|
|
1571
1713
|
fileSizeProgress: ' of ',
|
|
1572
1714
|
} });
|
|
1573
1715
|
|
|
1574
|
-
var
|
|
1575
|
-
function _extends$C() { _extends$C = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$C.apply(this, arguments); }
|
|
1576
|
-
var SvgCross = function SvgCross(props, ref) {
|
|
1577
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$C({
|
|
1578
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
1579
|
-
width: 24,
|
|
1580
|
-
height: 24,
|
|
1581
|
-
viewBox: "0 0 24 24",
|
|
1582
|
-
ref: ref
|
|
1583
|
-
}, props), _path$B || (_path$B = /*#__PURE__*/React__namespace.createElement("path", {
|
|
1584
|
-
fillRule: "evenodd",
|
|
1585
|
-
d: "M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"
|
|
1586
|
-
})));
|
|
1587
|
-
};
|
|
1588
|
-
var ForwardRef$C = /*#__PURE__*/React.forwardRef(SvgCross);
|
|
1589
|
-
|
|
1590
|
-
var css$X = {"root":"ckp29D","icon-wrapper":"eZpjQi","action-wrapper":"_1tB2Lc","action-link":"_8HPQbt","close-icon":"v8tBmL","main-path":"gjuq3-","content":"I3GXxj","clear-button":"quKLh7","close-wrapper":"V441Cr","iconWrapper":"eZpjQi","actionWrapper":"_1tB2Lc","actionLink":"_8HPQbt","closeIcon":"v8tBmL","mainPath":"gjuq3-","clearButton":"quKLh7","closeWrapper":"V441Cr"};
|
|
1591
|
-
|
|
1592
|
-
const NotificationCard = React__namespace.default.forwardRef((props, ref) => {
|
|
1593
|
-
const notificationCardNode = React__namespace.default.useRef(null);
|
|
1594
|
-
React__namespace.default.useImperativeHandle(ref, () => notificationCardNode.current, [notificationCardNode.current]);
|
|
1595
|
-
React__namespace.default.useLayoutEffect(() => {
|
|
1596
|
-
var _a, _b;
|
|
1597
|
-
(_a = notificationCardNode.current) === null || _a === void 0 ? void 0 : _a.addEventListener('mouseenter', props.clearTimer);
|
|
1598
|
-
(_b = notificationCardNode.current) === null || _b === void 0 ? void 0 : _b.addEventListener('mouseleave', props.refreshTimer);
|
|
1599
|
-
return () => {
|
|
1600
|
-
var _a, _b;
|
|
1601
|
-
(_a = notificationCardNode.current) === null || _a === void 0 ? void 0 : _a.removeEventListener('mouseenter', props.clearTimer);
|
|
1602
|
-
(_b = notificationCardNode.current) === null || _b === void 0 ? void 0 : _b.removeEventListener('mouseleave', props.refreshTimer);
|
|
1603
|
-
};
|
|
1604
|
-
}, []);
|
|
1605
|
-
return (React__namespace.default.createElement("div", Object.assign({ role: "alert", className: cx__default.default(props.color && `notification-card-${props.color}`, css$X.root, props.cx), ref: notificationCardNode }, props.rawProps),
|
|
1606
|
-
React__namespace.default.createElement("div", { className: css$X.mainPath },
|
|
1607
|
-
props.icon && (React__namespace.default.createElement("div", { className: css$X.iconWrapper },
|
|
1608
|
-
React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, cx: css$X.actionIcon }))),
|
|
1609
|
-
React__namespace.default.createElement("div", { className: css$X.content },
|
|
1610
|
-
props.children,
|
|
1611
|
-
props.actions && (React__namespace.default.createElement("div", { className: css$X.actionWrapper }, props.actions.map((action) => (React__namespace.default.createElement(LinkButton, { caption: action.name, onClick: action.action, key: action.name, cx: css$X.actionLink, size: "36", rawProps: action.rawProps })))))),
|
|
1612
|
-
props.onClose && (React__namespace.default.createElement("div", { className: css$X.closeWrapper },
|
|
1613
|
-
React__namespace.default.createElement(IconButton, { icon: ForwardRef$C, color: "default", onClick: props.onClose, cx: css$X.closeIcon }))))));
|
|
1614
|
-
});
|
|
1615
|
-
const WarningNotification = React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, Object.assign({ icon: ForwardRef$G, color: "warning" }, props, { ref: ref, cx: props.cx }))));
|
|
1616
|
-
const SuccessNotification = React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, Object.assign({ icon: ForwardRef$H, color: "success" }, props, { ref: ref, cx: props.cx }))));
|
|
1617
|
-
const HintNotification = React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, Object.assign({ icon: ForwardRef$E, color: "info" }, props, { ref: ref, cx: props.cx }))));
|
|
1618
|
-
const ErrorNotification = React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, Object.assign({ icon: ForwardRef$F, color: "error" }, props, { ref: ref, cx: props.cx }))));
|
|
1619
|
-
class ClearNotification extends React__namespace.default.Component {
|
|
1620
|
-
render() {
|
|
1621
|
-
return (React__namespace.default.createElement("div", { className: cx__default.default(css$X.notificationWrapper, css$X.clearButton) },
|
|
1622
|
-
React__namespace.default.createElement(LinkButton, { caption: i18n.notificationCard.closeAllNotificationsButton, onClick: () => this.context.uuiNotifications.clearAll() })));
|
|
1623
|
-
}
|
|
1624
|
-
}
|
|
1625
|
-
ClearNotification.contextType = uuiCore.UuiContext;
|
|
1626
|
-
|
|
1627
|
-
var css$W = {"root":"hWqffz"};
|
|
1716
|
+
var css$T = {"root":"uL4Zop","mode-block":"fHfMwg","mode-inline":"M840Mb","padding-0":"hvVkTe","padding-6":"Y56-BO","padding-12":"vmrApN","padding-18":"r6bYdT","modeBlock":"fHfMwg","modeInline":"M840Mb","padding0":"hvVkTe","padding6":"Y56-BO","padding12":"vmrApN","padding18":"r6bYdT"};
|
|
1628
1717
|
|
|
1629
|
-
function
|
|
1718
|
+
function applyAccordionMods(mods) {
|
|
1630
1719
|
return [
|
|
1631
|
-
|
|
1632
|
-
css$
|
|
1720
|
+
css$T.root,
|
|
1721
|
+
css$T['mode-' + (mods.mode || 'block')],
|
|
1722
|
+
mods.padding && css$T['padding-' + mods.padding],
|
|
1633
1723
|
];
|
|
1634
1724
|
}
|
|
1635
|
-
const
|
|
1725
|
+
const Accordion = uuiCore.withMods(uuiComponents__namespace.Accordion, applyAccordionMods, (mods) => ({
|
|
1726
|
+
dropdownIcon: mods.dropdownIcon !== null && systemIcons[mods.mode === 'block' ? '60' : '30'].foldingArrow,
|
|
1727
|
+
}));
|
|
1636
1728
|
|
|
1637
|
-
var css$
|
|
1729
|
+
var css$S = {"root":"m4EfMA"};
|
|
1638
1730
|
|
|
1639
|
-
function
|
|
1731
|
+
function applyTooltipMods(mods) {
|
|
1640
1732
|
return [
|
|
1641
|
-
css$
|
|
1733
|
+
css$S.root,
|
|
1734
|
+
`uui-color-${mods.color || 'contrast'}`,
|
|
1642
1735
|
];
|
|
1643
1736
|
}
|
|
1644
|
-
const
|
|
1645
|
-
dropdownIcon: mods.dropdownIcon !== null && systemIcons[mods.mode === 'block' ? '60' : '30'].foldingArrow,
|
|
1646
|
-
}));
|
|
1737
|
+
const Tooltip = uuiCore.withMods(uuiComponents.Tooltip, applyTooltipMods);
|
|
1647
1738
|
|
|
1648
|
-
var css$
|
|
1739
|
+
var css$R = {"uui-typography":"z30Eta","hero-header":"pwPy8w","promo-header":"I-YWoW","uui-critical":"a0AA-W","uui-success":"qIjcnW","uui-warning":"ut821y","uui-typography-size-12":"vpAauN","uui-typography-size-14":"eQLpI5","uui-typography-size-16":"N8vxM4","root":"g0LiYK","size-24":"TNPZC7","size-30":"_1caQ71","size-36":"WmnLiw","size-42":"uBsRyR","size-48":"s2QHnu","uuiTypography":"z30Eta","heroHeader":"pwPy8w","promoHeader":"I-YWoW","uuiCritical":"a0AA-W","uuiSuccess":"qIjcnW","uuiWarning":"ut821y","uuiTypographySize12":"vpAauN","uuiTypographySize14":"eQLpI5","uuiTypographySize16":"N8vxM4","size24":"TNPZC7","size30":"_1caQ71","size36":"WmnLiw","size42":"uBsRyR","size48":"s2QHnu"};
|
|
1649
1740
|
|
|
1650
|
-
const defaultSize$
|
|
1741
|
+
const defaultSize$3 = '36';
|
|
1651
1742
|
function applyLabeledInputMods(mods) {
|
|
1652
|
-
return [css$
|
|
1743
|
+
return [css$R.root, css$R['size-' + (mods.size || defaultSize$3)]];
|
|
1653
1744
|
}
|
|
1654
1745
|
const LabeledInput = uuiCore.withMods(uuiComponents__namespace.LabeledInput, applyLabeledInputMods, (props) => ({
|
|
1655
1746
|
Tooltip,
|
|
1656
|
-
infoIcon: systemIcons[props.size || defaultSize$
|
|
1747
|
+
infoIcon: systemIcons[props.size || defaultSize$3].help,
|
|
1657
1748
|
}));
|
|
1658
1749
|
|
|
1659
|
-
var css$
|
|
1750
|
+
var css$Q = {"root":"dIlo2N"};
|
|
1660
1751
|
|
|
1661
|
-
const RadioGroup = uuiCore.withMods(uuiComponents.RadioGroup, () => [css$
|
|
1752
|
+
const RadioGroup = uuiCore.withMods(uuiComponents.RadioGroup, () => [css$Q.root], () => ({ RadioInput }));
|
|
1662
1753
|
|
|
1663
1754
|
function applyScrollBarsMods() {
|
|
1664
1755
|
return [
|
|
@@ -1667,18 +1758,11 @@ function applyScrollBarsMods() {
|
|
|
1667
1758
|
}
|
|
1668
1759
|
const ScrollBars = uuiCore.withMods(uuiComponents.ScrollBars, applyScrollBarsMods);
|
|
1669
1760
|
|
|
1670
|
-
var css$
|
|
1671
|
-
|
|
1672
|
-
var css$R = {"root":"AWyU2E"};
|
|
1761
|
+
var css$P = {"scroll-container":"_70WgCw","list-container":"kOfI6U","scrollContainer":"_70WgCw","listContainer":"kOfI6U"};
|
|
1673
1762
|
|
|
1674
|
-
var css$
|
|
1763
|
+
var css$O = {"root":"PpN-hM"};
|
|
1675
1764
|
|
|
1676
|
-
|
|
1677
|
-
return [css$Q.root];
|
|
1678
|
-
}
|
|
1679
|
-
const Spinner = uuiCore.withMods(uuiComponents.Spinner, applySpinnerMods);
|
|
1680
|
-
|
|
1681
|
-
const Blocker = uuiCore.withMods(uuiComponents.Blocker, () => [css$R.root], (cmpProps) => ({ renderSpinner: cmpProps.renderSpinner || (() => React__namespace.default.createElement(Spinner, null)) }));
|
|
1765
|
+
const Blocker = uuiCore.withMods(uuiComponents.Blocker, () => [css$O.root], (cmpProps) => ({ renderSpinner: cmpProps.renderSpinner || (() => React__namespace.default.createElement(Spinner, null)) }));
|
|
1682
1766
|
|
|
1683
1767
|
const VirtualList = React__namespace.forwardRef((props, ref) => {
|
|
1684
1768
|
const { listContainerRef, offsetY, handleScroll, estimatedHeight, scrollContainerRef, } = uuiCore.useVirtualList({
|
|
@@ -1694,7 +1778,7 @@ const VirtualList = React__namespace.forwardRef((props, ref) => {
|
|
|
1694
1778
|
var _a;
|
|
1695
1779
|
return ((_a = props.renderRows) === null || _a === void 0 ? void 0 : _a.call(props, {
|
|
1696
1780
|
listContainerRef, estimatedHeight, offsetY, scrollShadows,
|
|
1697
|
-
})) || (React__namespace.createElement("div", { className: css$
|
|
1781
|
+
})) || (React__namespace.createElement("div", { className: css$P.listContainer, style: { minHeight: `${estimatedHeight}px` } },
|
|
1698
1782
|
React__namespace.createElement("div", { ref: listContainerRef, role: props.role, style: { marginTop: offsetY } }, props.rows)));
|
|
1699
1783
|
};
|
|
1700
1784
|
const scrollBarsRef = React__namespace.useCallback((scrollbars) => {
|
|
@@ -1703,7 +1787,7 @@ const VirtualList = React__namespace.forwardRef((props, ref) => {
|
|
|
1703
1787
|
return;
|
|
1704
1788
|
scrollContainerRef.current = scrollbars.container.firstChild;
|
|
1705
1789
|
}, []);
|
|
1706
|
-
return (React__namespace.createElement(ScrollBars, { cx: uuiCore.cx(css$
|
|
1790
|
+
return (React__namespace.createElement(ScrollBars, { cx: uuiCore.cx(css$P.scrollContainer, props.cx, {
|
|
1707
1791
|
[uuiCore.uuiMarkers.scrolledLeft]: scrollShadows.horizontalLeft,
|
|
1708
1792
|
[uuiCore.uuiMarkers.scrolledRight]: scrollShadows.horizontalRight,
|
|
1709
1793
|
[uuiCore.uuiMarkers.scrolledTop]: scrollShadows.verticalTop,
|
|
@@ -1717,383 +1801,123 @@ const VirtualListView = React__namespace.forwardRef((props, ref) => {
|
|
|
1717
1801
|
});
|
|
1718
1802
|
VirtualList.displayName = 'VirtualList';
|
|
1719
1803
|
|
|
1720
|
-
var css$
|
|
1804
|
+
var css$N = {"root":"HXfot5"};
|
|
1721
1805
|
|
|
1722
|
-
const CheckboxGroup = uuiCore.withMods(uuiComponents.CheckboxGroup, () => [css$
|
|
1806
|
+
const CheckboxGroup = uuiCore.withMods(uuiComponents.CheckboxGroup, () => [css$N.root], () => ({ CheckboxInput: Checkbox }));
|
|
1723
1807
|
|
|
1724
|
-
|
|
1725
|
-
render() {
|
|
1726
|
-
let bodyContent;
|
|
1727
|
-
if (this.props.bodyContent) {
|
|
1728
|
-
bodyContent = React__namespace.createElement(Panel, { margin: "24" }, this.props.bodyContent);
|
|
1729
|
-
}
|
|
1730
|
-
return (React__namespace.createElement(ModalBlocker, Object.assign({}, this.props),
|
|
1731
|
-
React__namespace.createElement(ModalWindow, { width: 420 },
|
|
1732
|
-
React__namespace.createElement(ModalHeader, { borderBottom: true, title: this.props.caption, onClose: () => this.props.abort() }),
|
|
1733
|
-
React__namespace.createElement(ScrollBars, null, bodyContent),
|
|
1734
|
-
React__namespace.createElement(ModalFooter, null,
|
|
1735
|
-
React__namespace.createElement(uuiComponents.FlexSpacer, null),
|
|
1736
|
-
this.props.hideCancelButton || (React__namespace.createElement(Button, { caption: i18n.form.modals.discardButton, onClick: () => this.props.success(false), mode: "outline", color: "secondary" })),
|
|
1737
|
-
React__namespace.createElement(Button, { caption: i18n.form.modals.saveButton, onClick: () => this.props.success(true), color: "accent" })))));
|
|
1738
|
-
}
|
|
1739
|
-
}
|
|
1808
|
+
var css$M = {"uui-typography":"jvNJJ7","hero-header":"kMGHdo","promo-header":"aUjgFc","uui-critical":"vU-3R7","uui-success":"EbJkac","uui-warning":"RtA-SD","uui-typography-size-12":"GpSQGK","uui-typography-size-14":"-b63hs","uui-typography-size-16":"TyRmMJ","body":"foxUv2","modal":"VZJlys","search-wrapper":"mK3hAW","checkbox":"_1a-rbP","no-found-size-24":"sl-Rqz","no-found-size-30":"XzM9uV","no-found-size-36":"hbfq6E","no-found-size-42":"W-u4M4","uuiTypography":"jvNJJ7","heroHeader":"kMGHdo","promoHeader":"aUjgFc","uuiCritical":"vU-3R7","uuiSuccess":"EbJkac","uuiWarning":"RtA-SD","uuiTypographySize12":"GpSQGK","uuiTypographySize14":"-b63hs","uuiTypographySize16":"TyRmMJ","searchWrapper":"mK3hAW","noFoundSize24":"sl-Rqz","noFoundSize30":"XzM9uV","noFoundSize36":"hbfq6E","noFoundSize42":"W-u4M4"};
|
|
1740
1809
|
|
|
1741
|
-
|
|
1742
|
-
class DatePicker extends uuiComponents.BaseDatePicker {
|
|
1810
|
+
class DataPickerBody extends uuiComponents.PickerBodyBase {
|
|
1743
1811
|
constructor() {
|
|
1744
1812
|
super(...arguments);
|
|
1745
|
-
this.
|
|
1746
|
-
|
|
1747
|
-
if (process.env.NODE_ENV !== "production") {
|
|
1748
|
-
if (this.props.size === '48') {
|
|
1749
|
-
uuiCore.devLogger.warnAboutDeprecatedPropValue({
|
|
1750
|
-
component: 'DatePicker',
|
|
1751
|
-
propName: 'size',
|
|
1752
|
-
propValue: this.props.size,
|
|
1753
|
-
propValueUseInstead: '42',
|
|
1754
|
-
condition: () => ['48'].indexOf(this.props.size) !== -1,
|
|
1755
|
-
});
|
|
1756
|
-
}
|
|
1757
|
-
}
|
|
1758
|
-
return (React__namespace.default.createElement(TextInput, Object.assign({}, props, { onClick: null, isDropdown: false, cx: uuiCore.cx(this.props.inputCx, this.state.isOpen && uuiCore.uuiMod.focus), icon: this.props.mode !== exports.EditMode.CELL && systemIcons[this.props.size || '36'].calendar, iconPosition: this.props.iconPosition || 'left', placeholder: this.props.placeholder ? this.props.placeholder : this.getFormat(), size: this.props.size || '36', value: this.state.inputValue, onValueChange: this.handleInputChange, onCancel: this.props.disableClear || !this.state.inputValue ? undefined : this.handleCancel, isInvalid: this.props.isInvalid, isDisabled: this.props.isDisabled, isReadonly: this.props.isReadonly, tabIndex: this.props.isReadonly || this.props.isDisabled ? -1 : 0, onFocus: this.handleFocus, onBlur: this.handleBlur, mode: this.props.mode || defaultMode$1, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.input })));
|
|
1759
|
-
};
|
|
1813
|
+
this.lens = uuiCore.Lens.onEditableComponent(this);
|
|
1814
|
+
this.searchLens = this.lens.prop('search');
|
|
1760
1815
|
}
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1816
|
+
renderNotFound() {
|
|
1817
|
+
if (this.props.renderNotFound) {
|
|
1818
|
+
return this.props.renderNotFound();
|
|
1819
|
+
}
|
|
1820
|
+
return (React__namespace.default.createElement(uuiComponents.FlexCell, { cx: css$M[`no-found-size-${this.props.searchSize || 36}`], grow: 1, textAlign: "center" },
|
|
1821
|
+
React__namespace.default.createElement(Text, { size: this.props.searchSize || '36' }, i18n.dataPickerBody.noRecordsMessage)));
|
|
1822
|
+
}
|
|
1823
|
+
render() {
|
|
1824
|
+
const searchSize = uuiCore.isMobile() ? '48' : this.props.searchSize || '36';
|
|
1825
|
+
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
1826
|
+
this.showSearch() && (React__namespace.default.createElement("div", { key: "search", className: css$M.searchWrapper },
|
|
1827
|
+
React__namespace.default.createElement(uuiComponents.FlexCell, { grow: 1 },
|
|
1828
|
+
React__namespace.default.createElement(SearchInput, Object.assign({ ref: this.searchRef, placeholder: i18n.dataPickerBody.searchPlaceholder }, this.searchLens.toProps(), { onKeyDown: this.searchKeyDown, size: searchSize, debounceDelay: this.props.searchDebounceDelay }))))),
|
|
1829
|
+
React__namespace.default.createElement(FlexRow, { key: "body", cx: uuiCore.cx(css$M.body, css$M[this.props.editMode], css$M[this.props.selectionMode]), rawProps: { style: { maxHeight: this.props.maxHeight } } }, this.props.rowsCount > 0 ? (React__namespace.default.createElement(VirtualList, Object.assign({}, this.lens.toProps(), { rows: this.props.rows, rawProps: this.props.rawProps, rowsCount: this.props.rowsCount, isLoading: this.props.isReloading }))) : (this.renderNotFound()))));
|
|
1766
1830
|
}
|
|
1767
1831
|
}
|
|
1768
1832
|
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1833
|
+
const switchSizes = {
|
|
1834
|
+
24: '12',
|
|
1835
|
+
36: '18',
|
|
1836
|
+
42: '24',
|
|
1837
|
+
48: '24',
|
|
1838
|
+
};
|
|
1839
|
+
function DataPickerFooterImpl(props) {
|
|
1840
|
+
const { clearSelection, view, showSelected, selectionMode, } = props;
|
|
1841
|
+
const size = uuiCore.isMobile() ? '48' : props.size || '36';
|
|
1842
|
+
const switchSize = switchSizes[size];
|
|
1843
|
+
const hasSelection = view.getSelectedRowsCount() > 0;
|
|
1844
|
+
const isSinglePicker = selectionMode === 'single';
|
|
1845
|
+
const clearAllText = i18n.pickerInput.clearSelectionButton;
|
|
1846
|
+
const clearSingleText = i18n.pickerInput.clearSelectionButtonSingle;
|
|
1847
|
+
const selectAllText = i18n.pickerInput.selectAllButton;
|
|
1848
|
+
// show always for multi picker and for single only in case if search not disabled.
|
|
1849
|
+
const shouldShowFooter = isSinglePicker ? !props.disableClear : true;
|
|
1850
|
+
return shouldShowFooter && (React__namespace.default.createElement(FlexRow, { padding: "12" },
|
|
1851
|
+
!isSinglePicker && (React__namespace.default.createElement(Switch, { size: switchSize, value: showSelected.value, isDisabled: !hasSelection, onValueChange: showSelected.onValueChange, label: i18n.pickerInput.showOnlySelectedLabel })),
|
|
1852
|
+
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
1853
|
+
React__namespace.default.createElement(FlexCell, { width: "auto", alignSelf: "center" },
|
|
1854
|
+
view.selectAll && (React__namespace.default.createElement(LinkButton, { size: size, caption: hasSelection ? clearAllText : selectAllText, onClick: hasSelection ? clearSelection : () => view.selectAll.onValueChange(true), rawProps: {
|
|
1855
|
+
'aria-label': hasSelection ? clearAllText : selectAllText,
|
|
1856
|
+
} })),
|
|
1857
|
+
!view.selectAll && (React__namespace.default.createElement(LinkButton, { isDisabled: !hasSelection, size: size, caption: isSinglePicker ? clearSingleText : clearAllText, onClick: clearSelection, rawProps: {
|
|
1858
|
+
'aria-label': isSinglePicker ? clearSingleText : clearAllText,
|
|
1859
|
+
} })))));
|
|
1773
1860
|
}
|
|
1774
|
-
const
|
|
1861
|
+
const DataPickerFooter = React__namespace.default.memo(DataPickerFooterImpl);
|
|
1775
1862
|
|
|
1776
|
-
var css$
|
|
1863
|
+
var css$L = {"header":"WhkoHA","close":"vxTh3-"};
|
|
1777
1864
|
|
|
1778
|
-
|
|
1779
|
-
function
|
|
1780
|
-
let days = [];
|
|
1781
|
-
const dayOfLastWeekInPrevMonth = displayedDate.subtract(1, 'month').endOf('month').day();
|
|
1782
|
-
days = days.concat(new Array(dayOfLastWeekInPrevMonth).fill(undefined));
|
|
1783
|
-
// get days of current month
|
|
1784
|
-
days = days.concat(new Array(displayedDate.endOf('month').date()).fill(undefined));
|
|
1785
|
-
return uuiCore.arrayToMatrix(days, 7).length;
|
|
1786
|
-
}
|
|
1787
|
-
const uuiRangeDatePickerBody = {
|
|
1788
|
-
inRange: 'uui-range-datepicker-in-range',
|
|
1789
|
-
firstDayInRangeWrapper: 'uui-range-datepicker-first-day-in-range-wrapper',
|
|
1790
|
-
lastDayInRangeWrapper: 'uui-range-datepicker-last-day-in-range-wrapper',
|
|
1791
|
-
separator: 'uui-range-datepicker-separator',
|
|
1792
|
-
};
|
|
1793
|
-
const rangeDatePickerPresets = {
|
|
1794
|
-
today: {
|
|
1795
|
-
name: 'Today',
|
|
1796
|
-
getRange: () => ({ from: dayjs__default.default().toString(), to: undefined, order: 1 }),
|
|
1797
|
-
},
|
|
1798
|
-
thisWeek: {
|
|
1799
|
-
name: 'This Week',
|
|
1800
|
-
getRange: () => ({ from: dayjs__default.default().startOf('isoWeek').toString(), to: dayjs__default.default().endOf('isoWeek').toString(), order: 2 }),
|
|
1801
|
-
},
|
|
1802
|
-
lastWeek: {
|
|
1803
|
-
name: 'Last Week',
|
|
1804
|
-
getRange: () => ({ from: dayjs__default.default().startOf('isoWeek').subtract(1, 'week').toString(), to: dayjs__default.default().endOf('isoWeek').subtract(1, 'week').toString(), order: 3 }),
|
|
1805
|
-
},
|
|
1806
|
-
thisMonth: {
|
|
1807
|
-
name: 'This Month',
|
|
1808
|
-
getRange: () => ({ from: dayjs__default.default().startOf('month').toString(), to: dayjs__default.default().endOf('month').toString(), order: 4 }),
|
|
1809
|
-
},
|
|
1810
|
-
lastMonth: {
|
|
1811
|
-
name: 'Last Month',
|
|
1812
|
-
getRange: () => ({ from: dayjs__default.default().startOf('month').subtract(1, 'month').toString(), to: dayjs__default.default().subtract(1, 'month').endOf('month').toString(), order: 5 }),
|
|
1813
|
-
},
|
|
1814
|
-
last3Month: {
|
|
1815
|
-
name: 'Last 3 Months',
|
|
1816
|
-
getRange: () => ({ from: dayjs__default.default().startOf('month').subtract(3, 'month').toString(), to: dayjs__default.default().subtract(1, 'month').endOf('month').toString(), order: 5 }),
|
|
1817
|
-
},
|
|
1818
|
-
thisYear: {
|
|
1819
|
-
name: 'This Year',
|
|
1820
|
-
getRange: () => ({ from: dayjs__default.default().startOf('year').toString(), to: dayjs__default.default().endOf('year').toString(), order: 7 }),
|
|
1821
|
-
},
|
|
1822
|
-
lastYear: {
|
|
1823
|
-
name: 'Last Year',
|
|
1824
|
-
getRange: () => ({ from: dayjs__default.default().startOf('year').subtract(1, 'year').toString(), to: dayjs__default.default().subtract(1, 'year').endOf('year').toString(), order: 8 }),
|
|
1825
|
-
},
|
|
1826
|
-
};
|
|
1827
|
-
class RangeDatePickerBody extends React__namespace.Component {
|
|
1828
|
-
constructor() {
|
|
1829
|
-
super(...arguments);
|
|
1830
|
-
this.state = {
|
|
1831
|
-
activePart: null,
|
|
1832
|
-
};
|
|
1833
|
-
this.getDayCX = (day) => {
|
|
1834
|
-
var _a, _b;
|
|
1835
|
-
const dayValue = day.valueOf();
|
|
1836
|
-
const fromValue = ((_a = this.props.value) === null || _a === void 0 ? void 0 : _a.selectedDate.from) ? dayjs__default.default(this.props.value.selectedDate.from).valueOf() : null;
|
|
1837
|
-
const toValue = ((_b = this.props.value) === null || _b === void 0 ? void 0 : _b.selectedDate.to) ? dayjs__default.default(this.props.value.selectedDate.to).valueOf() : null;
|
|
1838
|
-
const inRange = dayValue >= fromValue && dayValue <= toValue && fromValue !== toValue && fromValue && toValue;
|
|
1839
|
-
const isFirst = dayValue === fromValue;
|
|
1840
|
-
const isLast = dayValue === toValue;
|
|
1841
|
-
return [
|
|
1842
|
-
inRange && uuiRangeDatePickerBody.inRange,
|
|
1843
|
-
isFirst && uuiRangeDatePickerBody.firstDayInRangeWrapper,
|
|
1844
|
-
!inRange && isFirst && uuiRangeDatePickerBody.lastDayInRangeWrapper,
|
|
1845
|
-
isLast && uuiRangeDatePickerBody.lastDayInRangeWrapper,
|
|
1846
|
-
!inRange && isLast && uuiRangeDatePickerBody.firstDayInRangeWrapper,
|
|
1847
|
-
(dayValue === fromValue || dayValue === toValue) && uuiComponents.uuiDaySelection.selectedDay,
|
|
1848
|
-
];
|
|
1849
|
-
};
|
|
1850
|
-
this.getFromValue = () => {
|
|
1851
|
-
var _a;
|
|
1852
|
-
return Object.assign(Object.assign({}, this.props.value), { view: this.state.activePart === 'from' ? this.props.value.view : 'DAY_SELECTION', selectedDate: (_a = this.props.value) === null || _a === void 0 ? void 0 : _a.selectedDate.from });
|
|
1853
|
-
};
|
|
1854
|
-
this.getToValue = () => {
|
|
1855
|
-
if (!this.props.value)
|
|
1856
|
-
return;
|
|
1857
|
-
return Object.assign(Object.assign({}, this.props.value), { view: this.state.activePart === 'to' ? this.props.value.view : 'DAY_SELECTION', displayedDate: this.props.value.displayedDate.add(1, 'month'), selectedDate: this.props.value.selectedDate.to });
|
|
1858
|
-
};
|
|
1859
|
-
this.renderPresets = () => {
|
|
1860
|
-
return (React__namespace.createElement(React__namespace.Fragment, null,
|
|
1861
|
-
React__namespace.createElement("div", { className: uuiRangeDatePickerBody.separator }),
|
|
1862
|
-
React__namespace.createElement(CalendarPresets, { forwardedRef: this.props.forwardedRef, onPresetSet: (presetVal) => {
|
|
1863
|
-
this.props.onValueChange({
|
|
1864
|
-
view: 'DAY_SELECTION',
|
|
1865
|
-
selectedDate: { from: dayjs__default.default(presetVal.from).format(uuiComponents.valueFormat), to: dayjs__default.default(presetVal.to).format(uuiComponents.valueFormat) },
|
|
1866
|
-
displayedDate: dayjs__default.default(presetVal.from),
|
|
1867
|
-
});
|
|
1868
|
-
this.props.changeIsOpen(false);
|
|
1869
|
-
}, presets: this.props.presets })));
|
|
1870
|
-
};
|
|
1871
|
-
this.renderDatePicker = () => {
|
|
1872
|
-
var _a, _b;
|
|
1873
|
-
return (React__namespace.createElement(FlexRow, { cx: [((_a = this.props.value) === null || _a === void 0 ? void 0 : _a.view) === 'DAY_SELECTION' && css$N.daySelection, css$N.container], alignItems: "top" },
|
|
1874
|
-
React__namespace.createElement(FlexCell, { width: "auto" },
|
|
1875
|
-
React__namespace.createElement(FlexRow, null,
|
|
1876
|
-
React__namespace.createElement(FlexRow, { cx: css$N.bodesWrapper, alignItems: "top" },
|
|
1877
|
-
React__namespace.createElement(DatePickerBody, { cx: uuiCore.cx(css$N.fromPicker), setSelectedDate: (nv) => this.setSelectedDate(nv), value: this.getFromValue(), setDisplayedDateAndView: (displayedDate, view) => this.setDisplayedDateAndView(displayedDate, view, 'from'), getDayCX: this.getDayCX, filter: this.props.filter, renderDay: this.props.renderDay, isHoliday: this.props.isHoliday }),
|
|
1878
|
-
React__namespace.createElement(DatePickerBody, { cx: uuiCore.cx(css$N.toPicker), setSelectedDate: (nv) => this.setSelectedDate(nv), value: this.getToValue(), setDisplayedDateAndView: (displayedDate, view) => this.setDisplayedDateAndView(displayedDate, view, 'to'), getDayCX: this.getDayCX, filter: this.props.filter, renderDay: this.props.renderDay, isHoliday: this.props.isHoliday }),
|
|
1879
|
-
((_b = this.props.value) === null || _b === void 0 ? void 0 : _b.view) !== 'DAY_SELECTION' && (React__namespace.createElement("div", { style: {
|
|
1880
|
-
left: this.state.activePart === 'from' && '50%',
|
|
1881
|
-
right: this.state.activePart === 'to' && '50%',
|
|
1882
|
-
}, className: css$N.blocker }))),
|
|
1883
|
-
this.props.presets && this.renderPresets()),
|
|
1884
|
-
this.props.renderFooter && this.props.renderFooter())));
|
|
1885
|
-
};
|
|
1886
|
-
}
|
|
1887
|
-
getRange(selectedDate) {
|
|
1888
|
-
const newRange = { from: null, to: null };
|
|
1889
|
-
const currentRange = this.props.value.selectedDate;
|
|
1890
|
-
if (!this.props.filter || this.props.filter(dayjs__default.default(selectedDate))) {
|
|
1891
|
-
if (this.props.focusPart === 'from') {
|
|
1892
|
-
if (dayjs__default.default(selectedDate).valueOf() <= dayjs__default.default(currentRange.to).valueOf()) {
|
|
1893
|
-
newRange.from = selectedDate;
|
|
1894
|
-
newRange.to = currentRange.to;
|
|
1895
|
-
}
|
|
1896
|
-
else {
|
|
1897
|
-
newRange.from = selectedDate;
|
|
1898
|
-
newRange.to = null;
|
|
1899
|
-
}
|
|
1900
|
-
}
|
|
1901
|
-
if (this.props.focusPart === 'to') {
|
|
1902
|
-
if (!currentRange.from) {
|
|
1903
|
-
newRange.to = selectedDate;
|
|
1904
|
-
}
|
|
1905
|
-
else if (dayjs__default.default(selectedDate).valueOf() >= dayjs__default.default(currentRange.from).valueOf()) {
|
|
1906
|
-
newRange.from = currentRange.from;
|
|
1907
|
-
newRange.to = selectedDate;
|
|
1908
|
-
}
|
|
1909
|
-
else {
|
|
1910
|
-
newRange.from = selectedDate;
|
|
1911
|
-
newRange.to = null;
|
|
1912
|
-
}
|
|
1913
|
-
}
|
|
1914
|
-
}
|
|
1915
|
-
return newRange;
|
|
1916
|
-
}
|
|
1917
|
-
setSelectedDate(selectedDate) {
|
|
1918
|
-
const range = this.getRange(selectedDate);
|
|
1919
|
-
this.props.onValueChange(Object.assign(Object.assign({}, this.props.value), { selectedDate: range }));
|
|
1920
|
-
if (range.from && range.to && this.props.focusPart === 'to') {
|
|
1921
|
-
this.props.changeIsOpen(false);
|
|
1922
|
-
}
|
|
1923
|
-
}
|
|
1924
|
-
setDisplayedDateAndView(displayedDate, view, part) {
|
|
1925
|
-
this.setState({ activePart: part });
|
|
1926
|
-
this.props.onValueChange({
|
|
1927
|
-
selectedDate: this.props.value.selectedDate,
|
|
1928
|
-
displayedDate: part === 'from' ? displayedDate : displayedDate.subtract(1, 'month'),
|
|
1929
|
-
view: view,
|
|
1930
|
-
});
|
|
1931
|
-
}
|
|
1932
|
-
render() {
|
|
1933
|
-
return (React__namespace.createElement("div", Object.assign({ className: uuiCore.cx(css$N.root, uuiComponents.uuiDatePickerBodyBase.container, this.props.cx) }, this.props.rawProps), this.renderDatePicker()));
|
|
1934
|
-
}
|
|
1935
|
-
}
|
|
1936
|
-
|
|
1937
|
-
var css$M = {"dropdown-container":"x29HGv","container":"kgxL2j","button-group":"_2d9yok","date-input":"MKQEAM","size-24":"TUXmbv","size-30":"_2J4SvE","size-36":"Ht-9e5","size-42":"xrGhbF","size-48":"gwdkyo","date-input-group":"Lrfa50","separator":"iUtFnB","mode-form":"_2fnsML","mode-cell":"HIrZd5","dropdownContainer":"x29HGv","buttonGroup":"_2d9yok","dateInput":"MKQEAM","size24":"TUXmbv","size30":"_2J4SvE","size36":"Ht-9e5","size42":"xrGhbF","size48":"gwdkyo","dateInputGroup":"Lrfa50","modeForm":"_2fnsML","modeCell":"HIrZd5"};
|
|
1938
|
-
|
|
1939
|
-
const defaultValue = { from: null, to: null };
|
|
1940
|
-
class RangeDatePicker extends uuiComponents.BaseRangeDatePicker {
|
|
1941
|
-
constructor() {
|
|
1942
|
-
super(...arguments);
|
|
1943
|
-
this.renderInput = (props) => {
|
|
1944
|
-
var _a, _b;
|
|
1945
|
-
if (process.env.NODE_ENV !== "production") {
|
|
1946
|
-
if (this.props.size === '48') {
|
|
1947
|
-
uuiCore.devLogger.warnAboutDeprecatedPropValue({
|
|
1948
|
-
component: 'RangeDatePicker',
|
|
1949
|
-
propName: 'size',
|
|
1950
|
-
propValue: this.props.size,
|
|
1951
|
-
propValueUseInstead: '42',
|
|
1952
|
-
condition: () => ['48'].indexOf(this.props.size) !== -1,
|
|
1953
|
-
});
|
|
1954
|
-
}
|
|
1955
|
-
}
|
|
1956
|
-
return (React__namespace.createElement("div", { className: cx__default.default(this.props.inputCx, css$M.dateInputGroup, this.props.isDisabled && uuiCore.uuiMod.disabled, this.props.isReadonly && uuiCore.uuiMod.readonly, this.props.isInvalid && uuiCore.uuiMod.invalid, this.state.inFocus && uuiCore.uuiMod.focus), onClick: !this.props.isDisabled && props.onClick, onBlur: this.handleWrapperBlur, ref: props.ref },
|
|
1957
|
-
React__namespace.createElement(TextInput, { icon: systemIcons[this.props.size || '36'].calendar, cx: cx__default.default(css$M.dateInput, css$M['size-' + (this.props.size || 36)], this.state.inFocus === 'from' && uuiCore.uuiMod.focus), size: this.props.size || '36', placeholder: this.props.getPlaceholder ? this.props.getPlaceholder('from') : i18n.rangeDatePicker.pickerPlaceholderFrom, value: this.state.inputValue.from, onValueChange: this.getChangeHandler('from'), isInvalid: this.props.isInvalid, isDisabled: this.props.isDisabled, isReadonly: this.props.isReadonly, onFocus: (event) => this.handleFocus(event, 'from'), onBlur: (event) => this.handleBlur(event, 'from'), isDropdown: false, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.from }),
|
|
1958
|
-
React__namespace.createElement("div", { className: css$M.separator }),
|
|
1959
|
-
React__namespace.createElement(TextInput, { cx: cx__default.default(css$M.dateInput, css$M['size-' + (this.props.size || 36)], this.state.inFocus === 'to' && uuiCore.uuiMod.focus), placeholder: this.props.getPlaceholder ? this.props.getPlaceholder('to') : i18n.rangeDatePicker.pickerPlaceholderTo, size: this.props.size || '36', value: this.state.inputValue.to, onCancel: this.props.disableClear ? null : this.state.inputValue.from && this.state.inputValue.to && this.handleCancel, onValueChange: this.getChangeHandler('to'), isInvalid: this.props.isInvalid, isDisabled: this.props.isDisabled, isReadonly: this.props.isReadonly, onFocus: (e) => this.handleFocus(e, 'to'), onBlur: (e) => this.handleBlur(e, 'to'), isDropdown: false, rawProps: (_b = this.props.rawProps) === null || _b === void 0 ? void 0 : _b.to })));
|
|
1960
|
-
};
|
|
1961
|
-
}
|
|
1962
|
-
renderBody(props) {
|
|
1963
|
-
var _a;
|
|
1964
|
-
return (React__namespace.createElement(DropdownContainer, Object.assign({}, props, { cx: cx__default.default(css$M.dropdownContainer), focusLock: false }),
|
|
1965
|
-
React__namespace.createElement(FlexRow, null,
|
|
1966
|
-
React__namespace.createElement(RangeDatePickerBody, { cx: cx__default.default(this.props.bodyCx), value: this.getValue(), onValueChange: this.onRangeChange, filter: this.props.filter, changeIsOpen: this.toggleOpening, presets: this.props.presets, focusPart: this.state.inFocus, renderDay: this.props.renderDay, renderFooter: this.props.renderFooter && (() => this.props.renderFooter(this.props.value || defaultValue)), isHoliday: this.props.isHoliday, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.body }))));
|
|
1967
|
-
}
|
|
1968
|
-
}
|
|
1969
|
-
|
|
1970
|
-
var css$L = {"blocker":"M6FfCs","marker":"be8R-0","top":"SuOJrb","bottom":"zgQz-C","left":"Nj7BUc","right":"W7EplK","inside":"tt5qdK"};
|
|
1971
|
-
|
|
1972
|
-
function DropMarker(props) {
|
|
1973
|
-
return props.isDndInProgress
|
|
1974
|
-
? (React__namespace.createElement(React__namespace.Fragment, null,
|
|
1975
|
-
props.enableBlocker && React__namespace.createElement("div", { className: css$L.blocker }),
|
|
1976
|
-
React__namespace.createElement("div", { className: cx__default.default([
|
|
1977
|
-
css$L.marker,
|
|
1978
|
-
css$L[props.position],
|
|
1979
|
-
props === null || props === void 0 ? void 0 : props.cx,
|
|
1980
|
-
]) })))
|
|
1981
|
-
: null;
|
|
1982
|
-
}
|
|
1983
|
-
|
|
1984
|
-
var css$K = {"body":"ZDIze9","modal":"_41-9cx","search-wrapper":"vs-1wQ","checkbox":"_5cYKlo","no-found-size-24":"_4MBmZA","no-found-size-30":"_686oeG","no-found-size-36":"VqtnaS","no-found-size-42":"W5ASPu","searchWrapper":"vs-1wQ","noFoundSize24":"_4MBmZA","noFoundSize30":"_686oeG","noFoundSize36":"VqtnaS","noFoundSize42":"W5ASPu"};
|
|
1985
|
-
|
|
1986
|
-
class DataPickerBody extends uuiComponents.PickerBodyBase {
|
|
1987
|
-
constructor() {
|
|
1988
|
-
super(...arguments);
|
|
1989
|
-
this.lens = uuiCore.Lens.onEditableComponent(this);
|
|
1990
|
-
this.searchLens = this.lens.prop('search');
|
|
1991
|
-
}
|
|
1992
|
-
renderNotFound() {
|
|
1993
|
-
if (this.props.renderNotFound) {
|
|
1994
|
-
return this.props.renderNotFound();
|
|
1995
|
-
}
|
|
1996
|
-
return (React__namespace.default.createElement(uuiComponents.FlexCell, { cx: css$K[`no-found-size-${this.props.searchSize || 36}`], grow: 1, textAlign: "center" },
|
|
1997
|
-
React__namespace.default.createElement(Text, { size: this.props.searchSize || '36' }, i18n.dataPickerBody.noRecordsMessage)));
|
|
1998
|
-
}
|
|
1999
|
-
render() {
|
|
2000
|
-
const searchSize = uuiCore.isMobile() ? '48' : this.props.searchSize || '36';
|
|
2001
|
-
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
2002
|
-
this.showSearch() && (React__namespace.default.createElement("div", { key: "search", className: css$K.searchWrapper },
|
|
2003
|
-
React__namespace.default.createElement(uuiComponents.FlexCell, { grow: 1 },
|
|
2004
|
-
React__namespace.default.createElement(SearchInput, Object.assign({ ref: this.searchRef, placeholder: i18n.dataPickerBody.searchPlaceholder }, this.searchLens.toProps(), { onKeyDown: this.searchKeyDown, size: searchSize }))))),
|
|
2005
|
-
React__namespace.default.createElement(FlexRow, { key: "body", cx: uuiCore.cx(css$K.body, css$K[this.props.editMode], css$K[this.props.selectionMode]), rawProps: { style: { maxHeight: this.props.maxHeight } } }, this.props.rowsCount > 0 ? (React__namespace.default.createElement(VirtualList, Object.assign({}, this.lens.toProps(), { rows: this.props.rows, rawProps: this.props.rawProps, rowsCount: this.props.rowsCount, isLoading: this.props.isReloading }))) : (this.renderNotFound()))));
|
|
2006
|
-
}
|
|
2007
|
-
}
|
|
2008
|
-
|
|
2009
|
-
const switchSizes = {
|
|
2010
|
-
24: '12',
|
|
2011
|
-
36: '18',
|
|
2012
|
-
42: '24',
|
|
2013
|
-
48: '24',
|
|
2014
|
-
};
|
|
2015
|
-
function DataPickerFooterImpl(props) {
|
|
2016
|
-
const { clearSelection, view, showSelected, selectionMode, } = props;
|
|
2017
|
-
const size = uuiCore.isMobile() ? '48' : props.size || '36';
|
|
2018
|
-
const switchSize = switchSizes[size];
|
|
2019
|
-
const hasSelection = view.getSelectedRowsCount() > 0;
|
|
2020
|
-
const isSinglePicker = selectionMode === 'single';
|
|
2021
|
-
const clearAllText = i18n.pickerInput.clearSelectionButton;
|
|
2022
|
-
const clearSingleText = i18n.pickerInput.clearSelectionButtonSingle;
|
|
2023
|
-
const selectAllText = i18n.pickerInput.selectAllButton;
|
|
2024
|
-
// show always for multi picker and for single only in case if search not disabled.
|
|
2025
|
-
const shouldShowFooter = isSinglePicker ? !props.disableClear : true;
|
|
2026
|
-
return shouldShowFooter && (React__namespace.default.createElement(FlexRow, { padding: "12" },
|
|
2027
|
-
!isSinglePicker && (React__namespace.default.createElement(Switch, { size: switchSize, value: showSelected.value, isDisabled: !hasSelection, onValueChange: showSelected.onValueChange, label: i18n.pickerInput.showOnlySelectedLabel })),
|
|
2028
|
-
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
2029
|
-
React__namespace.default.createElement(FlexCell, { width: "auto", alignSelf: "center" },
|
|
2030
|
-
view.selectAll && (React__namespace.default.createElement(LinkButton, { size: size, caption: hasSelection ? clearAllText : selectAllText, onClick: hasSelection ? clearSelection : () => view.selectAll.onValueChange(true), rawProps: {
|
|
2031
|
-
'aria-label': hasSelection ? clearAllText : selectAllText,
|
|
2032
|
-
} })),
|
|
2033
|
-
!view.selectAll && (React__namespace.default.createElement(LinkButton, { isDisabled: !hasSelection, size: size, caption: isSinglePicker ? clearSingleText : clearAllText, onClick: clearSelection, rawProps: {
|
|
2034
|
-
'aria-label': isSinglePicker ? clearSingleText : clearAllText,
|
|
2035
|
-
} })))));
|
|
2036
|
-
}
|
|
2037
|
-
const DataPickerFooter = React__namespace.default.memo(DataPickerFooterImpl);
|
|
2038
|
-
|
|
2039
|
-
var css$J = {"header":"hKec5G","close":"h1cM0x"};
|
|
2040
|
-
|
|
2041
|
-
var _path$A;
|
|
2042
|
-
function _extends$B() { _extends$B = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$B.apply(this, arguments); }
|
|
1865
|
+
var _path$z;
|
|
1866
|
+
function _extends$A() { _extends$A = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$A.apply(this, arguments); }
|
|
2043
1867
|
var SvgNavigationClose24 = function SvgNavigationClose24(props, ref) {
|
|
2044
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1868
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$A({
|
|
2045
1869
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2046
1870
|
width: 24,
|
|
2047
1871
|
height: 24,
|
|
2048
1872
|
viewBox: "0 0 24 24",
|
|
2049
1873
|
ref: ref
|
|
2050
|
-
}, props), _path$
|
|
1874
|
+
}, props), _path$z || (_path$z = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2051
1875
|
fillRule: "evenodd",
|
|
2052
1876
|
d: "M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12 19 6.41z",
|
|
2053
1877
|
clipRule: "evenodd"
|
|
2054
1878
|
})));
|
|
2055
1879
|
};
|
|
2056
|
-
var ForwardRef$
|
|
1880
|
+
var ForwardRef$A = /*#__PURE__*/React.forwardRef(SvgNavigationClose24);
|
|
2057
1881
|
|
|
2058
1882
|
const DataPickerHeaderImpl = (props) => {
|
|
2059
1883
|
const title = props.title && typeof props.title === 'string' ? props.title.charAt(0).toUpperCase() + props.title.slice(1) : '';
|
|
2060
|
-
return (React__namespace.default.createElement(FlexRow, { alignItems: "center", borderBottom: true, cx: css$
|
|
1884
|
+
return (React__namespace.default.createElement(FlexRow, { alignItems: "center", borderBottom: true, cx: css$L.header },
|
|
2061
1885
|
React__namespace.default.createElement(Text, { size: "48", font: "semibold" }, title),
|
|
2062
|
-
React__namespace.default.createElement(IconButton, { icon: ForwardRef$
|
|
1886
|
+
React__namespace.default.createElement(IconButton, { icon: ForwardRef$A, onClick: () => { var _a; return (_a = props.close) === null || _a === void 0 ? void 0 : _a.call(props); }, cx: css$L.close })));
|
|
2063
1887
|
};
|
|
2064
1888
|
const DataPickerHeader = React__namespace.default.memo(DataPickerHeaderImpl);
|
|
2065
1889
|
|
|
2066
|
-
var _path$
|
|
2067
|
-
function _extends$
|
|
1890
|
+
var _path$y;
|
|
1891
|
+
function _extends$z() { _extends$z = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$z.apply(this, arguments); }
|
|
2068
1892
|
var SvgNavigationChevronDown18 = function SvgNavigationChevronDown18(props, ref) {
|
|
2069
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1893
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$z({
|
|
2070
1894
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2071
1895
|
width: 18,
|
|
2072
1896
|
height: 18,
|
|
2073
1897
|
viewBox: "0 0 18 18",
|
|
2074
1898
|
ref: ref
|
|
2075
|
-
}, props), _path$
|
|
1899
|
+
}, props), _path$y || (_path$y = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2076
1900
|
fillRule: "evenodd",
|
|
2077
1901
|
d: "M12.443 6.442 9 9.877 5.558 6.442 4.5 7.5 9 12l4.5-4.5-1.057-1.058z",
|
|
2078
1902
|
clipRule: "evenodd"
|
|
2079
1903
|
})));
|
|
2080
1904
|
};
|
|
2081
|
-
var ForwardRef$
|
|
1905
|
+
var ForwardRef$z = /*#__PURE__*/React.forwardRef(SvgNavigationChevronDown18);
|
|
2082
1906
|
|
|
2083
|
-
var css$
|
|
1907
|
+
var css$K = {"cell":"XjKrco","wrapper":"fTv4i7","align-widgets-top":"Ua1KJp","size-24":"oaM8FD","folding-arrow":"XoVrS-","size-30":"_7lfYSn","size-36":"ncM7pi","size-42":"ejNwNI","size-48":"q2glX4","size-60":"_18hWmy","align-widgets-center":"YwpBtM","padding-12":"J-bkXf","padding-24":"J8TYbq","padding-left-12":"_66I3se","padding-left-24":"go51jF","padding-right-24":"sDDRt-","drag-handle":"GVCO-l","checkbox":"YqT4UL","indent":"xehW3c","folding-arrow-12":"RXOLW3","folding-arrow-18":"EZh2YO","icon-container":"EkMUaZ","loading-cell":"TEqXBn","alignWidgetsTop":"Ua1KJp","size24":"oaM8FD","foldingArrow":"XoVrS-","size30":"_7lfYSn","size36":"ncM7pi","size42":"ejNwNI","size48":"q2glX4","size60":"_18hWmy","alignWidgetsCenter":"YwpBtM","padding12":"J-bkXf","padding24":"J8TYbq","paddingLeft12":"_66I3se","paddingLeft24":"go51jF","paddingRight24":"sDDRt-","dragHandle":"GVCO-l","foldingArrow12":"RXOLW3","foldingArrow18":"EZh2YO","iconContainer":"EkMUaZ","loadingCell":"TEqXBn"};
|
|
2084
1908
|
|
|
2085
1909
|
function DataTableRowAddons(props) {
|
|
2086
1910
|
var _a, _b;
|
|
2087
1911
|
const row = props.rowProps;
|
|
2088
1912
|
const additionalItemSize = +props.size < 30 ? '12' : '18';
|
|
2089
1913
|
return (React__namespace.createElement(React__namespace.Fragment, null,
|
|
2090
|
-
((_a = row.dnd) === null || _a === void 0 ? void 0 : _a.srcData) && React__namespace.createElement(uuiComponents.DragHandle, { key: "dh", cx: css$
|
|
2091
|
-
((_b = row === null || row === void 0 ? void 0 : row.checkbox) === null || _b === void 0 ? void 0 : _b.isVisible) && (React__namespace.createElement(Checkbox, { key: "cb", cx: css$
|
|
2092
|
-
row.indent > 0 && (React__namespace.createElement("div", { key: "fold", className: css$
|
|
1914
|
+
((_a = row.dnd) === null || _a === void 0 ? void 0 : _a.srcData) && React__namespace.createElement(uuiComponents.DragHandle, { key: "dh", cx: css$K.dragHandle }),
|
|
1915
|
+
((_b = row === null || row === void 0 ? void 0 : row.checkbox) === null || _b === void 0 ? void 0 : _b.isVisible) && (React__namespace.createElement(Checkbox, { key: "cb", cx: css$K.checkbox, tabIndex: props.tabIndex, size: additionalItemSize, value: row.isChecked, indeterminate: !row.isChecked && row.isChildrenChecked, onValueChange: () => { var _a; return (_a = row.onCheck) === null || _a === void 0 ? void 0 : _a.call(row, row); }, isDisabled: row.checkbox.isDisabled, isInvalid: row.checkbox.isInvalid })),
|
|
1916
|
+
row.indent > 0 && (React__namespace.createElement("div", { key: "fold", className: css$K.indent, style: { marginLeft: (row.indent - 1) * 24 } }, row.isFoldable && (React__namespace.createElement(uuiComponents.IconContainer, { rawProps: {
|
|
2093
1917
|
'aria-label': row.isFolded ? 'Unfold' : 'Fold',
|
|
2094
1918
|
role: 'button',
|
|
2095
|
-
}, key: "icon", icon: ForwardRef$
|
|
2096
|
-
css$
|
|
1919
|
+
}, key: "icon", icon: ForwardRef$z, cx: [
|
|
1920
|
+
css$K.foldingArrow, css$K[`folding-arrow-${additionalItemSize}`], uuiCore.uuiMarkers.clickable, css$K.iconContainer,
|
|
2097
1921
|
], rotate: row.isFolded ? '90ccw' : '0', onClick: () => row.onFold(row) }))))));
|
|
2098
1922
|
}
|
|
2099
1923
|
function DataTableCell(props) {
|
|
@@ -2104,76 +1928,77 @@ function DataTableCell(props) {
|
|
|
2104
1928
|
props.renderPlaceholder = props.renderPlaceholder
|
|
2105
1929
|
|| (() => (
|
|
2106
1930
|
// remove `css.loadingCell` after` removing `margin: 0 3px 3px 0` from `TextPlaceholder` `loadingWord` class styles.
|
|
2107
|
-
React__namespace.createElement(Text, { key: "t", size: props.size !== '60' ? props.size : '48', cx: css$
|
|
1931
|
+
React__namespace.createElement(Text, { key: "t", size: props.size !== '60' ? props.size : '48', cx: css$K.loadingCell },
|
|
2108
1932
|
React__namespace.createElement(TextPlaceholder, null))));
|
|
2109
1933
|
props.renderUnknown = props.renderUnknown
|
|
2110
1934
|
|| (() => (React__namespace.createElement(Text, { key: "t", size: props.size !== '60' ? props.size : '48' }, "Unknown")));
|
|
2111
1935
|
props.renderTooltip = (tooltipProps) => React__namespace.createElement(Tooltip, Object.assign({ color: "critical" }, tooltipProps));
|
|
2112
1936
|
const isEditable = !!props.onValueChange;
|
|
2113
1937
|
props.cx = [
|
|
1938
|
+
'uui-dt-vars',
|
|
2114
1939
|
'data-table-cell',
|
|
2115
1940
|
props.cx,
|
|
2116
|
-
css$
|
|
2117
|
-
css$
|
|
2118
|
-
css$
|
|
2119
|
-
props.isFirstColumn && css$
|
|
2120
|
-
props.isLastColumn && css$
|
|
2121
|
-
css$
|
|
1941
|
+
css$K.cell,
|
|
1942
|
+
css$K['size-' + (props.size || '36')],
|
|
1943
|
+
css$K[`padding-${props.padding || (isEditable && !props.rowProps.isLoading && '0') || '12'}`],
|
|
1944
|
+
props.isFirstColumn && css$K[`padding-left-${props.padding || (isEditable && !props.rowProps.isLoading && '12') || '24'}`],
|
|
1945
|
+
props.isLastColumn && css$K['padding-right-24'],
|
|
1946
|
+
css$K[`align-widgets-${props.alignActions || 'top'}`],
|
|
2122
1947
|
(props.border || isEditable) && 'uui-dt-vertical-cell-border',
|
|
2123
1948
|
];
|
|
2124
1949
|
return React__namespace.createElement(uuiComponents.DataTableCell, Object.assign({}, props));
|
|
2125
1950
|
}
|
|
2126
1951
|
|
|
2127
|
-
var _path$
|
|
2128
|
-
function _extends$
|
|
1952
|
+
var _path$x;
|
|
1953
|
+
function _extends$y() { _extends$y = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$y.apply(this, arguments); }
|
|
2129
1954
|
var SvgNotificationDone24 = function SvgNotificationDone24(props, ref) {
|
|
2130
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1955
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$y({
|
|
2131
1956
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2132
1957
|
width: 24,
|
|
2133
1958
|
height: 24,
|
|
2134
1959
|
viewBox: "0 0 24 24",
|
|
2135
1960
|
ref: ref
|
|
2136
|
-
}, props), _path$
|
|
1961
|
+
}, props), _path$x || (_path$x = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2137
1962
|
fillRule: "evenodd",
|
|
2138
1963
|
d: "m9.727 16.075-4.295-4.388L4 13.149 9.727 19 22 6.463 20.568 5 9.728 16.075z",
|
|
2139
1964
|
clipRule: "evenodd"
|
|
2140
1965
|
})));
|
|
2141
1966
|
};
|
|
2142
|
-
var ForwardRef$
|
|
1967
|
+
var ForwardRef$y = /*#__PURE__*/React.forwardRef(SvgNotificationDone24);
|
|
2143
1968
|
|
|
2144
|
-
var _path$
|
|
2145
|
-
function _extends$
|
|
1969
|
+
var _path$w;
|
|
1970
|
+
function _extends$x() { _extends$x = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$x.apply(this, arguments); }
|
|
2146
1971
|
var SvgNotificationDone18 = function SvgNotificationDone18(props, ref) {
|
|
2147
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1972
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$x({
|
|
2148
1973
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2149
1974
|
width: 18,
|
|
2150
1975
|
height: 18,
|
|
2151
1976
|
viewBox: "0 0 18 18",
|
|
2152
1977
|
ref: ref
|
|
2153
|
-
}, props), _path$
|
|
1978
|
+
}, props), _path$w || (_path$w = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2154
1979
|
fillRule: "evenodd",
|
|
2155
1980
|
d: "M7.136 11.91 4.034 8.776 3 9.821 7.136 14 16 5.045 14.966 4l-7.83 7.91z",
|
|
2156
1981
|
clipRule: "evenodd"
|
|
2157
1982
|
})));
|
|
2158
1983
|
};
|
|
2159
|
-
var ForwardRef$
|
|
1984
|
+
var ForwardRef$x = /*#__PURE__*/React.forwardRef(SvgNotificationDone18);
|
|
2160
1985
|
|
|
2161
|
-
var _path$
|
|
2162
|
-
function _extends$
|
|
1986
|
+
var _path$v;
|
|
1987
|
+
function _extends$w() { _extends$w = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$w.apply(this, arguments); }
|
|
2163
1988
|
var SvgNotificationDone12 = function SvgNotificationDone12(props, ref) {
|
|
2164
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
1989
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$w({
|
|
2165
1990
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2166
1991
|
width: 12,
|
|
2167
1992
|
height: 12,
|
|
2168
1993
|
viewBox: "0 0 12 12",
|
|
2169
1994
|
ref: ref
|
|
2170
|
-
}, props), _path$
|
|
1995
|
+
}, props), _path$v || (_path$v = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2171
1996
|
d: "M11 3.6 9.462 2 4.846 6.8 2.538 4.4 1 6l3.846 4L11 3.6z"
|
|
2172
1997
|
})));
|
|
2173
1998
|
};
|
|
2174
|
-
var ForwardRef$
|
|
1999
|
+
var ForwardRef$w = /*#__PURE__*/React.forwardRef(SvgNotificationDone12);
|
|
2175
2000
|
|
|
2176
|
-
var css$
|
|
2001
|
+
var css$J = {"uui-typography":"_9USLHN","hero-header":"HQQKB1","promo-header":"KLpsnv","uui-critical":"kMPKxG","uui-success":"_5Y097w","uui-warning":"Upl3Py","uui-typography-size-12":"_8cdfCK","uui-typography-size-14":"OGtg6C","uui-typography-size-16":"nJ2Iyi","render-item":"VD-DSQ","icon-wrapper":"R6bUgT","picker-row":"AtJLzs","icon-default":"D65yTW","icon-primary":"dPb8DH","uuiTypography":"_9USLHN","heroHeader":"HQQKB1","promoHeader":"KLpsnv","uuiCritical":"kMPKxG","uuiSuccess":"_5Y097w","uuiWarning":"Upl3Py","uuiTypographySize12":"_8cdfCK","uuiTypographySize14":"OGtg6C","uuiTypographySize16":"nJ2Iyi","renderItem":"VD-DSQ","iconWrapper":"R6bUgT","pickerRow":"AtJLzs","iconDefault":"D65yTW","iconPrimary":"dPb8DH"};
|
|
2177
2002
|
|
|
2178
2003
|
class DataPickerRow extends React__namespace.Component {
|
|
2179
2004
|
constructor() {
|
|
@@ -2181,26 +2006,26 @@ class DataPickerRow extends React__namespace.Component {
|
|
|
2181
2006
|
this.getIcon = (size) => {
|
|
2182
2007
|
switch (size) {
|
|
2183
2008
|
case '24':
|
|
2184
|
-
return ForwardRef$
|
|
2009
|
+
return ForwardRef$w;
|
|
2185
2010
|
case '30':
|
|
2186
|
-
return ForwardRef$
|
|
2011
|
+
return ForwardRef$x;
|
|
2187
2012
|
case '36':
|
|
2188
|
-
return ForwardRef$
|
|
2013
|
+
return ForwardRef$x;
|
|
2189
2014
|
case '42':
|
|
2190
|
-
return ForwardRef$z;
|
|
2191
|
-
default:
|
|
2192
2015
|
return ForwardRef$y;
|
|
2016
|
+
default:
|
|
2017
|
+
return ForwardRef$x;
|
|
2193
2018
|
}
|
|
2194
2019
|
};
|
|
2195
2020
|
this.column = {
|
|
2196
2021
|
key: 'name',
|
|
2197
2022
|
grow: 1,
|
|
2198
2023
|
width: 0,
|
|
2199
|
-
render: (item, rowProps) => (React__namespace.createElement("div", { key: rowProps.id, className: css$
|
|
2024
|
+
render: (item, rowProps) => (React__namespace.createElement("div", { key: rowProps.id, className: css$J.renderItem },
|
|
2200
2025
|
this.props.renderItem(item, rowProps),
|
|
2201
2026
|
React__namespace.createElement(uuiComponents.FlexSpacer, null),
|
|
2202
|
-
(rowProps.isChildrenSelected || rowProps.isSelected) && (React__namespace.createElement("div", { className: css$
|
|
2203
|
-
React__namespace.createElement(uuiComponents.IconContainer, { icon: this.getIcon(this.props.size), cx: rowProps.isChildrenSelected ? css$
|
|
2027
|
+
(rowProps.isChildrenSelected || rowProps.isSelected) && (React__namespace.createElement("div", { className: css$J.iconWrapper },
|
|
2028
|
+
React__namespace.createElement(uuiComponents.IconContainer, { icon: this.getIcon(this.props.size), cx: rowProps.isChildrenSelected ? css$J.iconDefault : css$J.iconPrimary, rawProps: { 'aria-label': rowProps.isChildrenSelected
|
|
2204
2029
|
? 'Child is selected'
|
|
2205
2030
|
: 'Selected' } }))))),
|
|
2206
2031
|
};
|
|
@@ -2209,31 +2034,31 @@ class DataPickerRow extends React__namespace.Component {
|
|
|
2209
2034
|
};
|
|
2210
2035
|
}
|
|
2211
2036
|
render() {
|
|
2212
|
-
return React__namespace.createElement(uuiComponents.DataPickerRow, Object.assign({}, this.props, { cx: [css$
|
|
2037
|
+
return React__namespace.createElement(uuiComponents.DataPickerRow, Object.assign({}, this.props, { cx: [css$J.pickerRow, this.props.cx], renderContent: this.renderContent }));
|
|
2213
2038
|
}
|
|
2214
2039
|
}
|
|
2215
2040
|
|
|
2216
|
-
var css$
|
|
2041
|
+
var css$I = {"uui-typography":"wBIRv7","hero-header":"qX9SAF","promo-header":"xL5Iwl","uui-critical":"Bud3KW","uui-success":"RtZgKb","uui-warning":"p6nIhk","uui-typography-size-12":"Y71xBT","uui-typography-size-14":"AXsDfo","uui-typography-size-16":"p8yJZf","done":"l3-I6q","container":"NfVfF3","uuiTypography":"wBIRv7","heroHeader":"qX9SAF","promoHeader":"xL5Iwl","uuiCritical":"Bud3KW","uuiSuccess":"RtZgKb","uuiWarning":"p6nIhk","uuiTypographySize12":"Y71xBT","uuiTypographySize14":"AXsDfo","uuiTypographySize16":"p8yJZf"};
|
|
2217
2042
|
|
|
2218
2043
|
const MobileDropdownWrapper = (props) => {
|
|
2219
2044
|
const isMobileView = uuiCore.isMobile();
|
|
2220
|
-
return (React__namespace.default.createElement(DropdownContainer, Object.assign({}, props, { cx: [css$
|
|
2045
|
+
return (React__namespace.default.createElement(DropdownContainer, Object.assign({}, props, { cx: [css$I.container, props.cx], rawProps: props.rawProps, onKeyDown: props.onKeyDown, focusLock: props.focusLock, width: props.width }),
|
|
2221
2046
|
isMobileView && React__namespace.default.createElement(DataPickerHeader, { title: props.title, close: props.onClose }),
|
|
2222
2047
|
props.children,
|
|
2223
|
-
isMobileView && React__namespace.default.createElement(LinkButton, { caption: i18n.pickerInput.doneButton, onClick: () => { var _a; return (_a = props.onClose) === null || _a === void 0 ? void 0 : _a.call(props); }, cx: css$
|
|
2048
|
+
isMobileView && React__namespace.default.createElement(LinkButton, { caption: i18n.pickerInput.doneButton, onClick: () => { var _a; return (_a = props.onClose) === null || _a === void 0 ? void 0 : _a.call(props); }, cx: css$I.done, size: "48" })));
|
|
2224
2049
|
};
|
|
2225
2050
|
|
|
2226
|
-
var _path$
|
|
2227
|
-
function _extends$
|
|
2051
|
+
var _path$u, _path2$1;
|
|
2052
|
+
function _extends$v() { _extends$v = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$v.apply(this, arguments); }
|
|
2228
2053
|
var SvgSearchWithBackground = function SvgSearchWithBackground(props, ref) {
|
|
2229
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
2054
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$v({
|
|
2230
2055
|
width: 66,
|
|
2231
2056
|
height: 67,
|
|
2232
2057
|
viewBox: "0 0 66 67",
|
|
2233
2058
|
fill: "none",
|
|
2234
2059
|
xmlns: "http://www.w3.org/2000/svg",
|
|
2235
2060
|
ref: ref
|
|
2236
|
-
}, props), _path$
|
|
2061
|
+
}, props), _path$u || (_path$u = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2237
2062
|
d: "M0 33.5C0 15.275 14.775.5 33 .5s33 14.775 33 33-14.775 33-33 33-33-14.775-33-33Z",
|
|
2238
2063
|
fill: "#EBEDF5"
|
|
2239
2064
|
})), _path2$1 || (_path2$1 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
@@ -2243,9 +2068,9 @@ var SvgSearchWithBackground = function SvgSearchWithBackground(props, ref) {
|
|
|
2243
2068
|
fill: "#6C6F80"
|
|
2244
2069
|
})));
|
|
2245
2070
|
};
|
|
2246
|
-
var ForwardRef$
|
|
2071
|
+
var ForwardRef$v = /*#__PURE__*/React.forwardRef(SvgSearchWithBackground);
|
|
2247
2072
|
|
|
2248
|
-
var css$
|
|
2073
|
+
var css$H = {"uui-typography":"kikt-y","hero-header":"QE0qYA","promo-header":"pHvbg7","uui-critical":"nkebDQ","uui-success":"ZRp5C9","uui-warning":"ixY1Gr","uui-typography-size-12":"W56-Hv","uui-typography-size-14":"KRn-P8","uui-typography-size-16":"dzDbJr","sub-header-wrapper":"YHZG-y","switch":"EmiVQm","no-found-modal-container":"aLCdse","no-found-modal-container-icon":"SPYiPv","no-found-modal-container-text":"SnJlH-","uuiTypography":"kikt-y","heroHeader":"QE0qYA","promoHeader":"pHvbg7","uuiCritical":"nkebDQ","uuiSuccess":"ZRp5C9","uuiWarning":"ixY1Gr","uuiTypographySize12":"W56-Hv","uuiTypographySize14":"KRn-P8","uuiTypographySize16":"dzDbJr","subHeaderWrapper":"YHZG-y","$switch$":"EmiVQm","noFoundModalContainer":"aLCdse","noFoundModalContainerIcon":"SPYiPv","noFoundModalContainerText":"SnJlH-"};
|
|
2249
2074
|
|
|
2250
2075
|
function PickerModal(props) {
|
|
2251
2076
|
const { view, selection, dataSourceStateLens, showSelectedLens, dataSourceState, getDataSourceState, getName, clearSelection, getRows, getListProps, getFooterProps, isSingleSelect, handleDataSourceValueChange, } = uuiComponents.usePickerModal(props);
|
|
@@ -2257,174 +2082,47 @@ function PickerModal(props) {
|
|
|
2257
2082
|
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
2258
2083
|
view.selectAll && (React__namespace.default.createElement(LinkButton, { caption: hasSelection ? i18n.pickerModal.clearAllButton : i18n.pickerModal.selectAllButton, onClick: hasSelection ? () => clearSelection() : () => view.selectAll.onValueChange(true) })),
|
|
2259
2084
|
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
2260
|
-
React__namespace.default.createElement(Button, {
|
|
2085
|
+
React__namespace.default.createElement(Button, { fill: "outline", color: "secondary", caption: i18n.pickerModal.cancelButton, onClick: () => props.abort() }),
|
|
2261
2086
|
React__namespace.default.createElement(Button, { color: "accent", caption: i18n.pickerModal.selectButton, onClick: () => props.success(selection) })));
|
|
2262
2087
|
};
|
|
2263
2088
|
const renderNotFound = () => {
|
|
2264
|
-
return props.renderNotFound ? (props.renderNotFound({ search: dataSourceState.search, onClose: () => props.success(null) })) : (React__namespace.default.createElement("div", { className: css$
|
|
2265
|
-
React__namespace.default.createElement(uuiComponents.IconContainer, { cx: css$
|
|
2266
|
-
React__namespace.default.createElement(Text, { cx: css$
|
|
2267
|
-
React__namespace.default.createElement(Text, { cx: css$
|
|
2089
|
+
return props.renderNotFound ? (props.renderNotFound({ search: dataSourceState.search, onClose: () => props.success(null) })) : (React__namespace.default.createElement("div", { className: css$H.noFoundModalContainer },
|
|
2090
|
+
React__namespace.default.createElement(uuiComponents.IconContainer, { cx: css$H.noFoundModalContainerIcon, icon: ForwardRef$v }),
|
|
2091
|
+
React__namespace.default.createElement(Text, { cx: css$H.noFoundModalContainerText, font: "semibold", fontSize: "16", lineHeight: "24", color: "primary", size: "36" }, i18n.dataPickerBody.noRecordsMessage),
|
|
2092
|
+
React__namespace.default.createElement(Text, { cx: css$H.noFoundModalContainerText, fontSize: "12", lineHeight: "18", font: "regular", color: "primary", size: "36" }, i18n.dataPickerBody.noRecordsSubTitle)));
|
|
2268
2093
|
};
|
|
2269
2094
|
const dataRows = getRows();
|
|
2270
2095
|
const rows = dataRows.map((row) => renderRow(row));
|
|
2271
2096
|
return (React__namespace.default.createElement(ModalBlocker, Object.assign({}, props),
|
|
2272
2097
|
React__namespace.default.createElement(ModalWindow, { width: 600, height: 700 },
|
|
2273
2098
|
React__namespace.default.createElement(ModalHeader, { title: props.caption || i18n.pickerModal.headerTitle, onClose: () => props.abort() }),
|
|
2274
|
-
React__namespace.default.createElement(FlexCell, { cx: css$
|
|
2099
|
+
React__namespace.default.createElement(FlexCell, { cx: css$H.subHeaderWrapper },
|
|
2275
2100
|
React__namespace.default.createElement(FlexRow, { vPadding: "24" },
|
|
2276
2101
|
React__namespace.default.createElement(SearchInput, Object.assign({}, dataSourceStateLens.prop('search').toProps(), { onKeyDown: (e) => uuiComponents.handleDataSourceKeyboard({
|
|
2277
2102
|
value: getDataSourceState(),
|
|
2278
2103
|
onValueChange: handleDataSourceValueChange,
|
|
2279
2104
|
listView: view,
|
|
2280
2105
|
rows: dataRows,
|
|
2281
|
-
|
|
2106
|
+
searchPosition: 'body',
|
|
2282
2107
|
}, e), autoFocus: true, placeholder: i18n.pickerModal.searchPlaceholder }))),
|
|
2283
|
-
!isSingleSelect() && (React__namespace.default.createElement(Switch, Object.assign({ cx: css$
|
|
2108
|
+
!isSingleSelect() && (React__namespace.default.createElement(Switch, Object.assign({ cx: css$H.switch, size: "18" }, showSelectedLens.toProps(), { isDisabled: view.getSelectedRowsCount() < 1, label: "Show only selected" }))),
|
|
2284
2109
|
props.renderFilter && React__namespace.default.createElement(FlexCell, { grow: 2 }, props.renderFilter(dataSourceStateLens.prop('filter').toProps()))),
|
|
2285
2110
|
React__namespace.default.createElement(DataPickerBody, Object.assign({}, getListProps(), { value: getDataSourceState(), onValueChange: handleDataSourceValueChange, search: dataSourceStateLens.prop('search').toProps(), showSearch: false, rows: rows, renderNotFound: renderNotFound, editMode: "modal" })),
|
|
2286
2111
|
React__namespace.default.createElement(ModalFooter, { padding: "24", vPadding: "24" }, props.renderFooter ? props.renderFooter(getFooterProps()) : renderFooter()))));
|
|
2287
2112
|
}
|
|
2288
2113
|
|
|
2289
|
-
var css$E = {"root":"wpTgsJ"};
|
|
2290
|
-
|
|
2291
|
-
const AvatarStack = uuiCore.withMods(uuiComponents.AvatarStack, () => [css$E.root]);
|
|
2292
|
-
|
|
2293
|
-
var css$D = {"root":"g2GaTF","size-18":"lFB9qZ","fill-transparent":"l8aT0K","size-24":"LvDUJc","size-30":"eUWIJU","size-36":"IZKJg7","size-42":"E3BKCK","size-48":"go0UJ6","fill-solid":"_9MM4-l","fill-semitransparent":"WXI04I","size18":"lFB9qZ","fillTransparent":"l8aT0K","size24":"LvDUJc","size30":"eUWIJU","size36":"IZKJg7","size42":"E3BKCK","size48":"go0UJ6","fillSolid":"_9MM4-l","fillSemitransparent":"WXI04I"};
|
|
2294
|
-
|
|
2295
|
-
const defaultSize$5 = '36';
|
|
2296
|
-
const mapSize$1 = {
|
|
2297
|
-
48: '48',
|
|
2298
|
-
42: '48',
|
|
2299
|
-
36: '36',
|
|
2300
|
-
30: '30',
|
|
2301
|
-
24: '30',
|
|
2302
|
-
18: '18',
|
|
2303
|
-
};
|
|
2304
|
-
function applyBadgeMods(mods) {
|
|
2305
|
-
return [
|
|
2306
|
-
css$D.root, buttonCss.root, css$D['size-' + (mods.size || defaultSize$5)], css$D['fill-' + (mods.fill || 'solid')], mods.color && `badge-${mods.color}`,
|
|
2307
|
-
];
|
|
2308
|
-
}
|
|
2309
|
-
const Badge = uuiCore.withMods(uuiComponents.Button, applyBadgeMods, (props) => ({
|
|
2310
|
-
dropdownIcon: systemIcons[(props.size && mapSize$1[props.size]) || defaultSize$5].foldingArrow,
|
|
2311
|
-
clearIcon: systemIcons[(props.size && mapSize$1[props.size]) || defaultSize$5].clear,
|
|
2312
|
-
countPosition: 'left',
|
|
2313
|
-
}));
|
|
2314
|
-
|
|
2315
|
-
var css$C = {"root":"_1-I1ie","size-18":"_5CmAdj","size-24":"nWfM8C","size-30":"ChHfDN","size-36":"b3axBo","size-42":"_4K3Gli","size-48":"xWS4i7","size18":"_5CmAdj","size24":"nWfM8C","size30":"ChHfDN","size36":"b3axBo","size42":"_4K3Gli","size48":"xWS4i7"};
|
|
2316
|
-
|
|
2317
|
-
const defaultSize$4 = '36';
|
|
2318
|
-
const mapSize = {
|
|
2319
|
-
48: '48',
|
|
2320
|
-
42: '48',
|
|
2321
|
-
36: '36',
|
|
2322
|
-
30: '30',
|
|
2323
|
-
24: '30',
|
|
2324
|
-
18: '18',
|
|
2325
|
-
};
|
|
2326
|
-
function applyTagMods(mods) {
|
|
2327
|
-
return [css$C['size-' + (mods.size || defaultSize$4)], css$C.root];
|
|
2328
|
-
}
|
|
2329
|
-
const Tag = uuiCore.withMods(uuiComponents.Button, applyTagMods, (props) => ({
|
|
2330
|
-
dropdownIcon: systemIcons[mapSize[props.size] || defaultSize$4].foldingArrow,
|
|
2331
|
-
clearIcon: systemIcons[mapSize[props.size] || defaultSize$4].clear,
|
|
2332
|
-
}));
|
|
2333
|
-
|
|
2334
|
-
var css$B = {"root":"zHpSJK","spacer":"eFz-P4","mode-ghost":"_3dh7wo","size-24":"Rqjuvc","size-30":"As-OAc","navigation-size-24":"Rw9pt-","navigation-size-30":"-agfoU","modeGhost":"_3dh7wo","size24":"Rqjuvc","size30":"As-OAc","navigationSize24":"Rw9pt-","navigationSize30":"-agfoU"};
|
|
2335
|
-
|
|
2336
|
-
var _path$u;
|
|
2337
|
-
function _extends$v() { _extends$v = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$v.apply(this, arguments); }
|
|
2338
|
-
var SvgNavigationChevronLeft12 = function SvgNavigationChevronLeft12(props, ref) {
|
|
2339
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$v({
|
|
2340
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
2341
|
-
width: 12,
|
|
2342
|
-
height: 12,
|
|
2343
|
-
viewBox: "0 0 12 12",
|
|
2344
|
-
ref: ref
|
|
2345
|
-
}, props), _path$u || (_path$u = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2346
|
-
fillRule: "evenodd",
|
|
2347
|
-
d: "M7.705 3.705 7 3 4 6l3 3 .705-.705L5.415 6l2.29-2.295z",
|
|
2348
|
-
clipRule: "evenodd"
|
|
2349
|
-
})));
|
|
2350
|
-
};
|
|
2351
|
-
var ForwardRef$v = /*#__PURE__*/React.forwardRef(SvgNavigationChevronLeft12);
|
|
2352
|
-
|
|
2353
|
-
var _path$t;
|
|
2354
|
-
function _extends$u() { _extends$u = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$u.apply(this, arguments); }
|
|
2355
|
-
var SvgNavigationChevronRight12 = function SvgNavigationChevronRight12(props, ref) {
|
|
2356
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$u({
|
|
2357
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
2358
|
-
width: 12,
|
|
2359
|
-
height: 12,
|
|
2360
|
-
viewBox: "0 0 12 12",
|
|
2361
|
-
ref: ref
|
|
2362
|
-
}, props), _path$t || (_path$t = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2363
|
-
fillRule: "evenodd",
|
|
2364
|
-
d: "m5 3-.705.705L6.585 6l-2.29 2.295L5 9l3-3-3-3z",
|
|
2365
|
-
clipRule: "evenodd"
|
|
2366
|
-
})));
|
|
2367
|
-
};
|
|
2368
|
-
var ForwardRef$u = /*#__PURE__*/React.forwardRef(SvgNavigationChevronRight12);
|
|
2369
|
-
|
|
2370
|
-
function Paginator(props) {
|
|
2371
|
-
const renderPaginator = (params) => {
|
|
2372
|
-
var _a, _b;
|
|
2373
|
-
return (React__namespace.default.createElement("nav", Object.assign({ role: "navigation", className: css$B.root }, params.rawProps),
|
|
2374
|
-
React__namespace.default.createElement(Button, { cx: css$B[`navigation-size-${(_a = params.size) !== null && _a !== void 0 ? _a : '30'}`], size: params.size, icon: params.size === '30' ? ForwardRef$J : ForwardRef$v, onClick: params.goToPrev, isDisabled: params.isFirst, mode: "outline", color: "secondary" }),
|
|
2375
|
-
params.pages.map((page, index) => {
|
|
2376
|
-
var _a, _b;
|
|
2377
|
-
if (page.type === 'spacer') {
|
|
2378
|
-
return (React__namespace.default.createElement(Button, { cx: cx__default.default(css$B[`size-${(_a = params.size) !== null && _a !== void 0 ? _a : '30'}`], css$B.spacer), size: params.size, key: `${index}_spacer`, caption: "...", mode: "ghost", color: "secondary", tabIndex: -1 }));
|
|
2379
|
-
}
|
|
2380
|
-
else {
|
|
2381
|
-
return (React__namespace.default.createElement(Button, { cx: cx__default.default(css$B[`size-${(_b = params.size) !== null && _b !== void 0 ? _b : '30'}`], css$B[`mode-${!page.isActive && 'ghost'}`]), size: params.size, key: page.pageNumber, caption: page.pageNumber, onClick: () => { var _a; return (_a = page.onClick) === null || _a === void 0 ? void 0 : _a.call(page); }, rawProps: { 'aria-current': page.isActive }, mode: (page.isActive && 'outline') || 'ghost', color: "primary" }));
|
|
2382
|
-
}
|
|
2383
|
-
}),
|
|
2384
|
-
React__namespace.default.createElement(Button, { cx: css$B[`navigation-size-${(_b = params.size) !== null && _b !== void 0 ? _b : '30'}`], size: params.size, icon: params.size === '30' ? ForwardRef$I : ForwardRef$u, onClick: params.goToNext, isDisabled: params.isLast, mode: "outline", color: "secondary" })));
|
|
2385
|
-
};
|
|
2386
|
-
return React__namespace.default.createElement(uuiComponents.Paginator, Object.assign({}, props, { render: renderPaginator }));
|
|
2387
|
-
}
|
|
2388
|
-
|
|
2389
|
-
var css$A = {"root":"J1Q-ET","bar":"Hrr-CY","progressBar-indeterminate":"I6Mhye","size-12":"_0LaF1B","size-18":"wXkA4a","size-24":"gMexWL","progressBarIndeterminate":"I6Mhye","size12":"_0LaF1B","size18":"wXkA4a","size24":"gMexWL"};
|
|
2390
|
-
|
|
2391
|
-
const IndeterminateBar = React__namespace.forwardRef((props, ref) => {
|
|
2392
|
-
return (React__namespace.createElement("div", { ref: ref, className: cx__default.default(props.cx, css$A.root, css$A[`size-${props.size || 12}`]) },
|
|
2393
|
-
React__namespace.createElement("div", { className: cx__default.default(css$A.bar) })));
|
|
2394
|
-
});
|
|
2395
|
-
|
|
2396
|
-
var css$z = {"root":"Ygyvyo","striped":"cYG-rF","animate-stripes":"Rb6nNv","size-12":"K9B4DN","size-18":"_4jfOKa","size-24":"PbHM1I","animateStripes":"Rb6nNv","size12":"K9B4DN","size18":"_4jfOKa","size24":"PbHM1I"};
|
|
2397
|
-
|
|
2398
|
-
const defaultSize$3 = '12';
|
|
2399
|
-
function applyProgressBarMods(mods) {
|
|
2400
|
-
const size = mods.size || defaultSize$3;
|
|
2401
|
-
return [
|
|
2402
|
-
css$z.root, css$z[`size-${size}`], mods.striped && css$z.striped,
|
|
2403
|
-
];
|
|
2404
|
-
}
|
|
2405
|
-
const ProgressBar = uuiCore.withMods(uuiComponents.ProgressBar, applyProgressBarMods, (props) => ({
|
|
2406
|
-
hideLabel: props.hideLabel || props.striped,
|
|
2407
|
-
}));
|
|
2408
|
-
|
|
2409
|
-
var css$y = {"root":"V5ZqTD"};
|
|
2410
|
-
|
|
2411
|
-
const IndicatorBar = React__namespace.forwardRef((props, ref) => {
|
|
2412
|
-
const { progress } = props;
|
|
2413
|
-
return progress || progress === 0 ? (React__namespace.createElement(ProgressBar, { ref: ref, progress: progress, cx: cx__default.default(css$y.root, props.cx), hideLabel: true })) : (React__namespace.createElement(IndeterminateBar, { ref: ref, cx: cx__default.default(css$y.root, props.cx) }));
|
|
2414
|
-
});
|
|
2415
|
-
|
|
2416
2114
|
const MAX_ITEMS = 100;
|
|
2417
2115
|
const getMaxItems = (maxItems) => maxItems || maxItems === 0 ? maxItems : MAX_ITEMS;
|
|
2418
2116
|
|
|
2419
|
-
var css$
|
|
2117
|
+
var css$G = {"uui-typography":"sQQj5s","hero-header":"_9aaey-","promo-header":"p5LCtM","uui-critical":"rMCuRU","uui-success":"mDpbWl","uui-warning":"Rw3xv0","uui-typography-size-12":"B4XeiI","uui-typography-size-14":"P4YlEH","uui-typography-size-16":"bGt7Jr","root":"E8pxGp","mode-form":"DCnwtL","mode-cell":"ueQo1o","mode-inline":"v11GFl","size-24":"_6rvzHn","size-30":"dZ-gOp","size-36":"_7mUcLE","size-42":"w5NzhK","size-48":"b8FGFE","uuiTypography":"sQQj5s","heroHeader":"_9aaey-","promoHeader":"p5LCtM","uuiCritical":"rMCuRU","uuiSuccess":"mDpbWl","uuiWarning":"Rw3xv0","uuiTypographySize12":"B4XeiI","uuiTypographySize14":"P4YlEH","uuiTypographySize16":"bGt7Jr","modeForm":"DCnwtL","modeCell":"ueQo1o","modeInline":"v11GFl","size24":"_6rvzHn","size30":"dZ-gOp","size36":"_7mUcLE","size42":"w5NzhK","size48":"b8FGFE"};
|
|
2420
2118
|
|
|
2421
2119
|
const defaultSize$2 = '36';
|
|
2422
|
-
const defaultMode = exports.EditMode.FORM;
|
|
2120
|
+
const defaultMode$1 = exports.EditMode.FORM;
|
|
2423
2121
|
function applyPickerTogglerMods(mods) {
|
|
2424
2122
|
return [
|
|
2425
|
-
css$
|
|
2426
|
-
css$
|
|
2427
|
-
css$
|
|
2123
|
+
css$G.root,
|
|
2124
|
+
css$G['size-' + (mods.size || defaultSize$2)],
|
|
2125
|
+
css$G['mode-' + (mods.mode || defaultMode$1)],
|
|
2428
2126
|
];
|
|
2429
2127
|
}
|
|
2430
2128
|
function PickerTogglerComponent(props, ref) {
|
|
@@ -2466,9 +2164,9 @@ function PickerTogglerComponent(props, ref) {
|
|
|
2466
2164
|
}
|
|
2467
2165
|
const PickerToggler = React__namespace.forwardRef(PickerTogglerComponent);
|
|
2468
2166
|
|
|
2469
|
-
var css$
|
|
2167
|
+
var css$F = {"root":"_2dUS8A","multiline":"_1trv6u","vertical-padding-24":"_9Yv2rg","vertical-padding-30":"jZ-3-7","vertical-padding-36":"AtJGWQ","vertical-padding-42":"ARLKMU","vertical-padding-48":"Q-cTho","text":"V3-iwn","verticalPadding24":"_9Yv2rg","verticalPadding30":"jZ-3-7","verticalPadding36":"AtJGWQ","verticalPadding42":"ARLKMU","verticalPadding48":"Q-cTho"};
|
|
2470
2168
|
|
|
2471
|
-
var css$
|
|
2169
|
+
var css$E = {"highlighted-text":"O1m5aV","highlightedText":"O1m5aV"};
|
|
2472
2170
|
|
|
2473
2171
|
const mergeHighlightRanges = (ranges) => {
|
|
2474
2172
|
const mergedRanges = [];
|
|
@@ -2522,7 +2220,7 @@ const getHighlightRanges = (str, search) => {
|
|
|
2522
2220
|
};
|
|
2523
2221
|
const getDecoratedText = (str, ranges) => ranges.map((range, index) => {
|
|
2524
2222
|
const rangeStr = str.substring(range.from, range.to);
|
|
2525
|
-
return (React__namespace.default.createElement("span", Object.assign({ key: `${rangeStr}-${index}` }, (range.isHighlighted ? { className: css$
|
|
2223
|
+
return (React__namespace.default.createElement("span", Object.assign({ key: `${rangeStr}-${index}` }, (range.isHighlighted ? { className: css$E.highlightedText } : {})), rangeStr));
|
|
2526
2224
|
});
|
|
2527
2225
|
const getHighlightedSearchMatches = (str, search) => {
|
|
2528
2226
|
if (!search || !str) {
|
|
@@ -2551,20 +2249,20 @@ class PickerItem extends React__namespace.Component {
|
|
|
2551
2249
|
const { search } = (_a = this.props.dataSourceState) !== null && _a !== void 0 ? _a : {};
|
|
2552
2250
|
const title = highlightSearchMatches ? getHighlightedSearchMatches(this.props.title, search) : this.props.title;
|
|
2553
2251
|
const subtitle = highlightSearchMatches ? getHighlightedSearchMatches(this.props.subtitle, search) : this.props.subtitle;
|
|
2554
|
-
return (React__namespace.createElement(FlexCell, { width: "auto", cx: [css$
|
|
2555
|
-
React__namespace.createElement(FlexRow, { size: itemSize, cx: isMultiline && [css$
|
|
2252
|
+
return (React__namespace.createElement(FlexCell, { width: "auto", cx: [css$F.root, cx] },
|
|
2253
|
+
React__namespace.createElement(FlexRow, { size: itemSize, cx: isMultiline && [css$F.multiline, css$F[`vertical-padding-${itemSize}`]], spacing: "12" },
|
|
2556
2254
|
avatarUrl && React__namespace.createElement(uuiComponents.Avatar, { isLoading: isLoading, img: avatarUrl, size: this.getAvatarSize(itemSize, isMultiline).toString() }),
|
|
2557
2255
|
icon && React__namespace.createElement(uuiComponents.IconContainer, { icon: icon }),
|
|
2558
2256
|
React__namespace.createElement(FlexCell, { width: "auto" },
|
|
2559
|
-
title && (React__namespace.createElement(Text, { size: itemSize, cx: css$
|
|
2560
|
-
subtitle && (React__namespace.createElement(Text, { size: itemSize, color: isDisabled ? 'disabled' : 'secondary', cx: css$
|
|
2257
|
+
title && (React__namespace.createElement(Text, { size: itemSize, cx: css$F.text, color: isDisabled ? 'disabled' : 'primary' }, isLoading ? React__namespace.createElement(TextPlaceholder, { wordsCount: 2 }) : title)),
|
|
2258
|
+
subtitle && (React__namespace.createElement(Text, { size: itemSize, color: isDisabled ? 'disabled' : 'secondary', cx: css$F.text }, isLoading ? React__namespace.createElement(TextPlaceholder, { wordsCount: 2 }) : subtitle))))));
|
|
2561
2259
|
}
|
|
2562
2260
|
}
|
|
2563
2261
|
PickerItem.defaultProps = {
|
|
2564
2262
|
highlightSearchMatches: true,
|
|
2565
2263
|
};
|
|
2566
2264
|
|
|
2567
|
-
var css$
|
|
2265
|
+
var css$D = {"uui-typography":"fF8ZwP","hero-header":"_9b-bPp","promo-header":"-cvRcr","uui-critical":"fHlDEe","uui-success":"Dg92tJ","uui-warning":"qhpAAB","uui-typography-size-12":"v-FDRt","uui-typography-size-14":"EUJkES","uui-typography-size-16":"aFs07c","root":"fLKY6A","panel":"p4QNcg","footer-wrapper":"gFO-FS","footer-size-24":"r6XsSu","footer-size-30":"xZzEB2","footer-size-36":"zhjyXq","footer-size-42":"EsxpXL","footer-size-48":"Koxf6N","uuiTypography":"fF8ZwP","heroHeader":"_9b-bPp","promoHeader":"-cvRcr","uuiCritical":"fHlDEe","uuiSuccess":"Dg92tJ","uuiWarning":"qhpAAB","uuiTypographySize12":"v-FDRt","uuiTypographySize14":"EUJkES","uuiTypographySize16":"aFs07c","footerWrapper":"gFO-FS","footerSize24":"r6XsSu","footerSize30":"xZzEB2","footerSize36":"zhjyXq","footerSize42":"EsxpXL","footerSize48":"Koxf6N"};
|
|
2568
2266
|
|
|
2569
2267
|
const pickerHeight$1 = 300;
|
|
2570
2268
|
const pickerWidth = 360;
|
|
@@ -2579,7 +2277,7 @@ function PickerInput(_a) {
|
|
|
2579
2277
|
})
|
|
2580
2278
|
.catch(() => { });
|
|
2581
2279
|
};
|
|
2582
|
-
const { context, popperModifiers, getName, getPlaceholder, handleSelectionValueChange, getTogglerProps, getRows, handleTogglerSearchChange, toggleBodyOpening, dataSourceState, getFooterProps, getPickerBodyProps, getListProps, shouldShowBody, getSearchPosition, } = uuiComponents.usePickerInput(Object.assign(Object.assign({}, props), { toggleModalOpening }));
|
|
2280
|
+
const { context, popperModifiers, getName, getPlaceholder, handleSelectionValueChange, getTogglerProps, getRows, handleTogglerSearchChange, toggleBodyOpening, dataSourceState, getFooterProps, getPickerBodyProps, getListProps, shouldShowBody, getSearchPosition, handlePickerInputKeyboard, } = uuiComponents.usePickerInput(Object.assign(Object.assign({}, props), { toggleModalOpening }));
|
|
2583
2281
|
const getTogglerMods = () => {
|
|
2584
2282
|
return {
|
|
2585
2283
|
size: props.size,
|
|
@@ -2588,7 +2286,7 @@ function PickerInput(_a) {
|
|
|
2588
2286
|
};
|
|
2589
2287
|
const renderTarget = (targetProps) => {
|
|
2590
2288
|
const renderTargetFn = props.renderToggler || ((props) => React__namespace.default.createElement(PickerToggler, Object.assign({}, props)));
|
|
2591
|
-
return (React__namespace.default.createElement(uuiCore.IEditableDebouncer, { value: targetProps.value, onValueChange: handleTogglerSearchChange, render: (editableProps) => renderTargetFn(Object.assign(Object.assign(Object.assign({}, getTogglerMods()), targetProps), editableProps)) }));
|
|
2289
|
+
return (React__namespace.default.createElement(uuiCore.IEditableDebouncer, { value: targetProps.value, onValueChange: handleTogglerSearchChange, debounceDelay: props.searchDebounceDelay, render: (editableProps) => renderTargetFn(Object.assign(Object.assign(Object.assign(Object.assign({}, getTogglerMods()), targetProps), editableProps), { onKeyDown: (e) => handlePickerInputKeyboard(rows, e, editableProps.value) })) }));
|
|
2592
2290
|
};
|
|
2593
2291
|
const renderFooter = () => {
|
|
2594
2292
|
const footerProps = getFooterProps();
|
|
@@ -2610,7 +2308,7 @@ function PickerInput(_a) {
|
|
|
2610
2308
|
const renderedDataRows = rows.map((row) => renderRow(row, dataSourceState));
|
|
2611
2309
|
const bodyHeight = uuiCore.isMobile() ? document.documentElement.clientHeight : props.dropdownHeight || pickerHeight$1;
|
|
2612
2310
|
const minBodyWidth = props.minBodyWidth || pickerWidth;
|
|
2613
|
-
return (React__namespace.default.createElement(MobileDropdownWrapper, { title: props.entityName, onClose: () => toggleBodyOpening(false), cx: [css$
|
|
2311
|
+
return (React__namespace.default.createElement(MobileDropdownWrapper, { title: props.entityName, onClose: () => toggleBodyOpening(false), cx: [css$D.panel, css$D.root, props.bodyCx], onKeyDown: bodyProps.onKeyDown, width: bodyProps.togglerWidth > minBodyWidth ? bodyProps.togglerWidth : minBodyWidth, focusLock: getSearchPosition() === 'body' },
|
|
2614
2312
|
React__namespace.default.createElement(DataPickerBody, Object.assign({}, bodyProps, { rows: renderedDataRows, maxHeight: bodyHeight, searchSize: props.size, editMode: "dropdown", selectionMode: props.selectionMode, renderNotFound: props.renderNotFound
|
|
2615
2313
|
? () => props.renderNotFound({
|
|
2616
2314
|
search: dataSourceState.search,
|
|
@@ -2621,12 +2319,12 @@ function PickerInput(_a) {
|
|
|
2621
2319
|
};
|
|
2622
2320
|
const rows = getRows();
|
|
2623
2321
|
return (React__namespace.default.createElement(Dropdown, { renderTarget: (dropdownProps) => {
|
|
2624
|
-
const targetProps = getTogglerProps(
|
|
2322
|
+
const targetProps = getTogglerProps();
|
|
2625
2323
|
return renderTarget(Object.assign(Object.assign({}, dropdownProps), targetProps));
|
|
2626
2324
|
}, renderBody: (bodyProps) => renderBody(Object.assign(Object.assign(Object.assign({}, bodyProps), getPickerBodyProps(rows)), getListProps()), rows), value: shouldShowBody(), onValueChange: !props.isDisabled && toggleBodyOpening, placement: props.dropdownPlacement, modifiers: popperModifiers, closeBodyOnTogglerHidden: !uuiCore.isMobile(), portalTarget: props.portalTarget }));
|
|
2627
2325
|
}
|
|
2628
2326
|
|
|
2629
|
-
var css$
|
|
2327
|
+
var css$C = {"row":"xMWN54"};
|
|
2630
2328
|
|
|
2631
2329
|
function PickerListItem(props) {
|
|
2632
2330
|
var _a;
|
|
@@ -2644,7 +2342,7 @@ function PickerListItem(props) {
|
|
|
2644
2342
|
else {
|
|
2645
2343
|
component = (React__namespace.default.createElement(RadioInput, { label: label, value: props.isSelected, isDisabled: props.isLoading || !props.isSelectable || props.isDisabled, onValueChange: () => props.onSelect(props) }));
|
|
2646
2344
|
}
|
|
2647
|
-
return (React__namespace.default.createElement("div", Object.assign({ role: "option", "aria-selected": props.isSelectable ? props.isSelected : undefined, "aria-busy": props.isLoading, "aria-posinset": props.index + 1 }, (((_a = props.checkbox) === null || _a === void 0 ? void 0 : _a.isVisible) && { 'aria-checked': props.isChecked }), { className: css$
|
|
2345
|
+
return (React__namespace.default.createElement("div", Object.assign({ role: "option", "aria-selected": props.isSelectable ? props.isSelected : undefined, "aria-busy": props.isLoading, "aria-posinset": props.index + 1 }, (((_a = props.checkbox) === null || _a === void 0 ? void 0 : _a.isVisible) && { 'aria-checked': props.isChecked }), { className: css$C.row }), component));
|
|
2648
2346
|
}
|
|
2649
2347
|
|
|
2650
2348
|
function PickerList(props) {
|
|
@@ -2680,304 +2378,111 @@ function PickerList(props) {
|
|
|
2680
2378
|
}, selectedRows)));
|
|
2681
2379
|
}
|
|
2682
2380
|
|
|
2683
|
-
var css$
|
|
2381
|
+
var css$B = {"uui-typography":"qotcmM","hero-header":"VPm67t","promo-header":"s7R73G","uui-critical":"_1CW-Ns","uui-success":"NxHJe2","uui-warning":"iRc28A","uui-typography-size-12":"Lfdlhf","uui-typography-size-14":"sb5Rbb","uui-typography-size-16":"_1zblT9","root":"BNm03Q","title-wrapper":"_9-IJUP","title":"Qg0AZQ","text-wrapper":"wuDR7n","selection":"YLD2Hy","postfix":"y8s5tw","selected":"RNA4BW","uuiTypography":"qotcmM","heroHeader":"VPm67t","promoHeader":"s7R73G","uuiCritical":"_1CW-Ns","uuiSuccess":"NxHJe2","uuiWarning":"iRc28A","uuiTypographySize12":"Lfdlhf","uuiTypographySize14":"sb5Rbb","uuiTypographySize16":"_1zblT9","titleWrapper":"_9-IJUP","textWrapper":"wuDR7n"};
|
|
2684
2382
|
|
|
2685
|
-
|
|
2686
|
-
|
|
2687
|
-
const
|
|
2688
|
-
|
|
2689
|
-
|
|
2690
|
-
|
|
2691
|
-
|
|
2692
|
-
|
|
2693
|
-
|
|
2694
|
-
|
|
2695
|
-
|
|
2696
|
-
|
|
2697
|
-
|
|
2383
|
+
const defaultSize = '36';
|
|
2384
|
+
const FilterPanelItemToggler = React__namespace.forwardRef((props, ref) => {
|
|
2385
|
+
const togglerPickerOpened = (e) => {
|
|
2386
|
+
var _a;
|
|
2387
|
+
if (props.isDisabled)
|
|
2388
|
+
return;
|
|
2389
|
+
e.preventDefault();
|
|
2390
|
+
(_a = props.onClick) === null || _a === void 0 ? void 0 : _a.call(props);
|
|
2391
|
+
};
|
|
2392
|
+
const onKeyDownHandler = (e) => {
|
|
2393
|
+
if (props.isDisabled)
|
|
2394
|
+
return;
|
|
2395
|
+
if (e.key === 'Enter' && !props.isOpen) {
|
|
2396
|
+
e.preventDefault();
|
|
2397
|
+
props.toggleDropdownOpening(true);
|
|
2398
|
+
}
|
|
2399
|
+
if (e.key === 'Escape' && props.isOpen) {
|
|
2400
|
+
e.preventDefault();
|
|
2401
|
+
props.toggleDropdownOpening(false);
|
|
2402
|
+
}
|
|
2403
|
+
};
|
|
2404
|
+
const getTitle = props.predicateName ? `${props.title} ${props.predicateName}` : `${props.title}${props.selection ? ':' : ''}`;
|
|
2405
|
+
const getSelectionText = () => props.selection.map((i, index) => (React__namespace.createElement(React__namespace.Fragment, { key: `${i}${index}` },
|
|
2406
|
+
React__namespace.createElement(Text, { color: "brand", size: props.size, cx: css$B.selection }, i),
|
|
2407
|
+
(props.postfix || index !== props.selection.length - 1) && React__namespace.createElement("span", null, ",\u00A0"))));
|
|
2408
|
+
return (React__namespace.createElement(uuiComponents.FlexRow, Object.assign({}, props, { rawProps: {
|
|
2409
|
+
style: { maxWidth: `${props.maxWidth ? props.maxWidth + 'px' : 'auto'}` },
|
|
2410
|
+
role: 'button',
|
|
2411
|
+
tabIndex: props.isDisabled ? -1 : 0,
|
|
2412
|
+
onKeyDown: onKeyDownHandler,
|
|
2413
|
+
}, cx: cx__default.default(css$B.root, uuiCore.uuiElement.inputBox, uuiCore.uuiMarkers.clickable, props.isOpen && uuiCore.uuiMod.opened, ['size-' + (props.size || defaultSize)], props.cx), onClick: togglerPickerOpened, ref: ref }),
|
|
2414
|
+
React__namespace.createElement(uuiComponents.FlexRow, { cx: css$B.titleWrapper },
|
|
2415
|
+
React__namespace.createElement(Text, { size: props.size, cx: css$B.title }, getTitle),
|
|
2416
|
+
props.selection && (React__namespace.createElement("div", { className: css$B.textWrapper },
|
|
2417
|
+
getSelectionText(),
|
|
2418
|
+
props.postfix && (React__namespace.createElement(Text, { color: "brand", size: props.size, cx: css$B.postfix }, props.postfix))))),
|
|
2419
|
+
!props.isDisabled && React__namespace.createElement(uuiComponents.IconContainer, { icon: systemIcons[props.size || defaultSize].foldingArrow, flipY: props.isOpen, cx: "uui-icon-dropdown" })));
|
|
2420
|
+
});
|
|
2698
2421
|
|
|
2699
|
-
|
|
2422
|
+
const pickerHeight = 300;
|
|
2423
|
+
function FilterPickerBody(props) {
|
|
2424
|
+
const shouldShowBody = () => props.isOpen;
|
|
2425
|
+
const { getName, isSingleSelect, getRows, dataSourceState, getFooterProps, getPickerBodyProps, getListProps, handleDataSourceValueChange, } = uuiComponents.usePickerInput(Object.assign(Object.assign({}, props), { shouldShowBody }));
|
|
2426
|
+
const renderItem = (item, rowProps) => {
|
|
2427
|
+
return React__namespace.createElement(PickerItem, Object.assign({ title: getName(item), size: "36" }, rowProps));
|
|
2428
|
+
};
|
|
2429
|
+
const onSelect = (row) => {
|
|
2430
|
+
props.onClose();
|
|
2431
|
+
handleDataSourceValueChange(Object.assign(Object.assign({}, dataSourceState), { search: '', selectedId: row.id }));
|
|
2432
|
+
};
|
|
2433
|
+
const renderRow = (rowProps) => {
|
|
2434
|
+
if (rowProps.isSelectable && isSingleSelect() && props.editMode !== 'modal') {
|
|
2435
|
+
rowProps.onSelect = onSelect;
|
|
2436
|
+
}
|
|
2437
|
+
return props.renderRow ? (props.renderRow(rowProps, dataSourceState)) : (React__namespace.createElement(DataPickerRow, Object.assign({}, rowProps, { key: rowProps.rowKey, borderBottom: "none", size: "36", padding: "12", renderItem: renderItem })));
|
|
2438
|
+
};
|
|
2439
|
+
const renderFooter = () => {
|
|
2440
|
+
return React__namespace.createElement(DataPickerFooter, Object.assign({}, getFooterProps(), { size: "36" }));
|
|
2441
|
+
};
|
|
2442
|
+
const renderBody = (bodyProps, rows) => {
|
|
2443
|
+
const renderedDataRows = rows.map((props) => renderRow(props));
|
|
2444
|
+
const maxHeight = uuiCore.isMobile() ? document.documentElement.clientHeight : props.dropdownHeight || pickerHeight;
|
|
2445
|
+
return (React__namespace.createElement(React__namespace.Fragment, null,
|
|
2446
|
+
React__namespace.createElement(DataPickerBody, Object.assign({}, bodyProps, { selectionMode: props.selectionMode, rows: renderedDataRows, maxHeight: maxHeight, searchSize: "36", editMode: "dropdown", showSearch: true })),
|
|
2447
|
+
renderFooter()));
|
|
2448
|
+
};
|
|
2449
|
+
const rows = getRows();
|
|
2450
|
+
return renderBody(Object.assign(Object.assign({}, getPickerBodyProps(rows)), getListProps()), rows);
|
|
2451
|
+
}
|
|
2700
2452
|
|
|
2701
|
-
|
|
2702
|
-
|
|
2703
|
-
|
|
2704
|
-
|
|
2705
|
-
|
|
2706
|
-
|
|
2707
|
-
|
|
2708
|
-
|
|
2709
|
-
|
|
2710
|
-
|
|
2711
|
-
|
|
2712
|
-
|
|
2713
|
-
|
|
2714
|
-
|
|
2715
|
-
};
|
|
2716
|
-
|
|
2453
|
+
class FilterDatePickerBody extends uuiComponents.BaseDatePicker {
|
|
2454
|
+
constructor() {
|
|
2455
|
+
super(...arguments);
|
|
2456
|
+
this.state = Object.assign(Object.assign({}, super.getValue()), { isOpen: false, inputValue: null });
|
|
2457
|
+
this.renderInput = () => {
|
|
2458
|
+
return null;
|
|
2459
|
+
};
|
|
2460
|
+
this.onToggleHandler = (val) => {
|
|
2461
|
+
this.onToggle(val);
|
|
2462
|
+
this.props.onClose();
|
|
2463
|
+
};
|
|
2464
|
+
this.handleCancel = () => {
|
|
2465
|
+
this.handleValueChange(undefined);
|
|
2466
|
+
this.setState({ inputValue: null, selectedDate: null });
|
|
2467
|
+
};
|
|
2468
|
+
}
|
|
2469
|
+
renderBody() {
|
|
2470
|
+
var _a;
|
|
2471
|
+
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
2472
|
+
React__namespace.default.createElement(FlexRow, { borderBottom: true },
|
|
2473
|
+
React__namespace.default.createElement(DatePickerBody, { filter: this.props.filter, value: this.getValue(), setSelectedDate: this.setSelectedDate, setDisplayedDateAndView: this.setDisplayedDateAndView, changeIsOpen: this.onToggleHandler, renderDay: this.props.renderDay, isHoliday: this.props.isHoliday, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.body })),
|
|
2474
|
+
React__namespace.default.createElement(FlexCell, { alignSelf: "stretch" },
|
|
2475
|
+
React__namespace.default.createElement(FlexRow, { padding: "24", vPadding: "12" },
|
|
2476
|
+
React__namespace.default.createElement(Text, null, this.state.selectedDate ? dayjs__default.default(this.state.selectedDate).format('MMM DD, YYYY') : ''),
|
|
2477
|
+
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
2478
|
+
React__namespace.default.createElement(LinkButton, { isDisabled: !this.state.selectedDate, caption: i18n.filterToolbar.datePicker.clearCaption, onClick: this.handleCancel })))));
|
|
2479
|
+
}
|
|
2480
|
+
render() {
|
|
2481
|
+
return this.renderBody();
|
|
2482
|
+
}
|
|
2483
|
+
}
|
|
2717
2484
|
|
|
2718
|
-
var
|
|
2719
|
-
function _extends$s() { _extends$s = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$s.apply(this, arguments); }
|
|
2720
|
-
var SvgTableSortDesc18 = function SvgTableSortDesc18(props, ref) {
|
|
2721
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$s({
|
|
2722
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
2723
|
-
width: 18,
|
|
2724
|
-
height: 18,
|
|
2725
|
-
viewBox: "0 0 18 18",
|
|
2726
|
-
ref: ref
|
|
2727
|
-
}, props), _path$r || (_path$r = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2728
|
-
fillRule: "evenodd",
|
|
2729
|
-
d: "M10 12V2H8v10H5l4 4 4-4h-3z",
|
|
2730
|
-
clipRule: "evenodd"
|
|
2731
|
-
})));
|
|
2732
|
-
};
|
|
2733
|
-
var ForwardRef$s = /*#__PURE__*/React.forwardRef(SvgTableSortDesc18);
|
|
2734
|
-
|
|
2735
|
-
const SortingPanelImpl = ({ sortDirection, onSort }) => {
|
|
2736
|
-
const sortAsc = React.useCallback(() => onSort(sortDirection === 'asc' ? undefined : 'asc'), [onSort]);
|
|
2737
|
-
const sortDesc = React.useCallback(() => onSort(sortDirection === 'desc' ? undefined : 'desc'), [onSort]);
|
|
2738
|
-
return (React__namespace.default.createElement(FlexCell, { cx: css$r.sortingPanelContainer },
|
|
2739
|
-
React__namespace.default.createElement(DropdownMenuButton, { isActive: sortDirection === 'asc', caption: i18n.pickerFilterHeader.sortAscending, icon: ForwardRef$t, onClick: sortAsc }),
|
|
2740
|
-
React__namespace.default.createElement(DropdownMenuButton, { isActive: sortDirection === 'desc', caption: i18n.pickerFilterHeader.sortDescending, icon: ForwardRef$s, onClick: sortDesc })));
|
|
2741
|
-
};
|
|
2742
|
-
const SortingPanel = React__namespace.default.memo(SortingPanelImpl);
|
|
2743
|
-
|
|
2744
|
-
const ColumnHeaderDropdownImpl = (props) => {
|
|
2745
|
-
const popperModifiers = React.useMemo(() => [
|
|
2746
|
-
{
|
|
2747
|
-
name: 'offset',
|
|
2748
|
-
options: { offset: [0, 1] },
|
|
2749
|
-
}, uuiCore.mobilePopperModifier,
|
|
2750
|
-
], []);
|
|
2751
|
-
const closeDropdown = React.useCallback(() => props.onOpenChange(false), [props.onOpenChange]);
|
|
2752
|
-
return (React__namespace.default.createElement(uuiComponents.Dropdown, { renderTarget: props.renderTarget, renderBody: (dropdownProps) => (React__namespace.default.createElement(MobileDropdownWrapper, { width: 360, title: props.title, onClose: closeDropdown },
|
|
2753
|
-
props.isSortable && React__namespace.default.createElement(SortingPanel, { sortDirection: props.sortDirection, onSort: props.onSort }),
|
|
2754
|
-
props.renderFilter(dropdownProps))), modifiers: popperModifiers, value: props.isOpen, onValueChange: props.onOpenChange }));
|
|
2755
|
-
};
|
|
2756
|
-
const ColumnHeaderDropdown = React__namespace.default.memo(ColumnHeaderDropdownImpl);
|
|
2757
|
-
|
|
2758
|
-
var css$q = {"cell":"tLAaeS","sort-icon":"fmuW6X","dropdown-icon":"_2XBE01","infoIcon":"g-SEdD","resizable":"fvxO4N","size-24":"vpt9Co","size-30":"t5WPTX","size-36":"Ha-8JD","size-42":"nI5chi","size-48":"k-8FVR","padding-left-24":"_2IORP8","padding-right-24":"eR2pIk","caption":"hXSvxS","checkbox":"WIQOhV","icon":"z-bjKK","icon-cell":"EjVWiZ","align-right":"jUnOzp","align-center":"YB-A2i","tooltip-wrapper":"hqa-dZ","cell-tooltip":"IE01Fr","upper-case":"lVsgvo","font-size-14":"cGKeij","resize-mark":"Zh231g","draggable":"klkXBa","ghost":"I0IT-7","is-dragged-out":"-x9U0X","dnd-marker-left":"Uwa2ke","dnd-marker-right":"L-Z1CZ","cell-tooltip-wrapper":"i721RA","cell-tooltip-text":"WRfPs-","sortIcon":"fmuW6X","dropdownIcon":"_2XBE01","size24":"vpt9Co","size30":"t5WPTX","size36":"Ha-8JD","size42":"nI5chi","size48":"k-8FVR","paddingLeft24":"_2IORP8","paddingRight24":"eR2pIk","iconCell":"EjVWiZ","alignRight":"jUnOzp","alignCenter":"YB-A2i","tooltipWrapper":"hqa-dZ","cellTooltip":"IE01Fr","upperCase":"lVsgvo","fontSize14":"cGKeij","resizeMark":"Zh231g","isDraggedOut":"-x9U0X","dndMarkerLeft":"Uwa2ke","dndMarkerRight":"L-Z1CZ","cellTooltipWrapper":"i721RA","cellTooltipText":"WRfPs-"};
|
|
2759
|
-
|
|
2760
|
-
var _path$q;
|
|
2761
|
-
function _extends$r() { _extends$r = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$r.apply(this, arguments); }
|
|
2762
|
-
var SvgTableSwap18 = function SvgTableSwap18(props, ref) {
|
|
2763
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$r({
|
|
2764
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
2765
|
-
width: 18,
|
|
2766
|
-
height: 18,
|
|
2767
|
-
viewBox: "0 0 18 18",
|
|
2768
|
-
ref: ref
|
|
2769
|
-
}, props), _path$q || (_path$q = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2770
|
-
fillRule: "evenodd",
|
|
2771
|
-
d: "M6 1 2 5h3v7h2V5h3L6 1zm7 12V6h-2v7H8l4 4 4-4h-3z",
|
|
2772
|
-
clipRule: "evenodd"
|
|
2773
|
-
})));
|
|
2774
|
-
};
|
|
2775
|
-
var ForwardRef$r = /*#__PURE__*/React.forwardRef(SvgTableSwap18);
|
|
2776
|
-
|
|
2777
|
-
var _path$p;
|
|
2778
|
-
function _extends$q() { _extends$q = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$q.apply(this, arguments); }
|
|
2779
|
-
var SvgContentFiltration18 = function SvgContentFiltration18(props, ref) {
|
|
2780
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$q({
|
|
2781
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
2782
|
-
width: 18,
|
|
2783
|
-
height: 18,
|
|
2784
|
-
viewBox: "0 0 18 18",
|
|
2785
|
-
ref: ref
|
|
2786
|
-
}, props), _path$p || (_path$p = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2787
|
-
fillRule: "evenodd",
|
|
2788
|
-
d: "m8 14 2 2v-5H8v3zM2 3v2h14V3H2zm6 8h2l6-6H2l6 6z",
|
|
2789
|
-
clipRule: "evenodd"
|
|
2790
|
-
})));
|
|
2791
|
-
};
|
|
2792
|
-
var ForwardRef$q = /*#__PURE__*/React.forwardRef(SvgContentFiltration18);
|
|
2793
|
-
|
|
2794
|
-
var _path$o;
|
|
2795
|
-
function _extends$p() { _extends$p = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$p.apply(this, arguments); }
|
|
2796
|
-
var SvgNavigationChevronUp18 = function SvgNavigationChevronUp18(props, ref) {
|
|
2797
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$p({
|
|
2798
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
2799
|
-
width: 18,
|
|
2800
|
-
height: 18,
|
|
2801
|
-
viewBox: "0 0 18 18",
|
|
2802
|
-
ref: ref
|
|
2803
|
-
}, props), _path$o || (_path$o = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2804
|
-
fillRule: "evenodd",
|
|
2805
|
-
d: "m9 6-4.5 4.5 1.058 1.057L9 8.123l3.443 3.434L13.5 10.5 9 6z",
|
|
2806
|
-
clipRule: "evenodd"
|
|
2807
|
-
})));
|
|
2808
|
-
};
|
|
2809
|
-
var ForwardRef$p = /*#__PURE__*/React.forwardRef(SvgNavigationChevronUp18);
|
|
2810
|
-
|
|
2811
|
-
class DataTableHeaderCell extends React__namespace.Component {
|
|
2812
|
-
constructor() {
|
|
2813
|
-
super(...arguments);
|
|
2814
|
-
this.state = {
|
|
2815
|
-
isDropdownOpen: null,
|
|
2816
|
-
};
|
|
2817
|
-
this.getTextStyle = () => {
|
|
2818
|
-
if (this.props.textCase === 'upper')
|
|
2819
|
-
return css$q.upperCase;
|
|
2820
|
-
return css$q['font-size-14'];
|
|
2821
|
-
};
|
|
2822
|
-
this.getTooltipContent = () => (React__namespace.createElement("div", { className: css$q.cellTooltipWrapper },
|
|
2823
|
-
React__namespace.createElement(Text, { fontSize: "14", color: "contrast", font: "semibold", cx: css$q.cellTooltipText }, this.props.column.caption),
|
|
2824
|
-
this.props.column.info && React__namespace.createElement(Text, { fontSize: "12", color: "contrast", cx: css$q.cellTooltipText }, this.props.column.info)));
|
|
2825
|
-
this.getColumnCaption = () => {
|
|
2826
|
-
return (React__namespace.createElement("div", { className: css$q.tooltipWrapper },
|
|
2827
|
-
React__namespace.createElement("div", { className: uuiCore.cx(css$q.iconCell, css$q['align-' + this.props.column.textAlign], uuiCore.uuiDataTableHeaderCell.uuiTableHeaderCaptionWrapper) },
|
|
2828
|
-
React__namespace.createElement(Tooltip, { placement: "top", color: "contrast", renderContent: this.getTooltipContent, cx: css$q.cellTooltip, openDelay: 600 },
|
|
2829
|
-
React__namespace.createElement(Text, { key: "text", lineHeight: "30", fontSize: "14", size: "30", cx: uuiCore.cx(css$q.caption, this.getTextStyle(), uuiCore.uuiDataTableHeaderCell.uuiTableHeaderCaption) }, this.props.column.caption)),
|
|
2830
|
-
this.props.column.isSortable && (!this.props.column.renderFilter || this.props.sortDirection) && (React__namespace.createElement(IconButton, { key: "sort", cx: uuiCore.cx(css$q.icon, css$q.sortIcon, this.props.sortDirection && css$q.sortIconActive, uuiCore.uuiDataTableHeaderCell.uuiTableHeaderSortIcon), color: this.props.sortDirection ? 'default' : 'secondary', icon: this.props.sortDirection === 'desc' ? ForwardRef$s : this.props.sortDirection === 'asc' ? ForwardRef$t : ForwardRef$r })),
|
|
2831
|
-
this.props.isFilterActive && (React__namespace.createElement(IconButton, { key: "filter", cx: uuiCore.cx(css$q.icon, !this.props.sortDirection && css$q.filterIcon, uuiCore.uuiDataTableHeaderCell.uuiTableHeaderFilterIcon), color: "default", icon: ForwardRef$q })),
|
|
2832
|
-
this.props.column.renderFilter && (React__namespace.createElement(IconButton, { key: "dropdown", cx: uuiCore.cx(css$q.icon, css$q.dropdownIcon, uuiCore.uuiDataTableHeaderCell.uuiTableHeaderDropdownIcon), color: "secondary", icon: this.state.isDropdownOpen ? ForwardRef$p : ForwardRef$A })))));
|
|
2833
|
-
};
|
|
2834
|
-
this.renderHeaderCheckbox = () => this.props.selectAll
|
|
2835
|
-
&& this.props.isFirstColumn && (React__namespace.createElement(Checkbox, Object.assign({ size: +this.props.size < 36 ? '12' : '18' }, this.props.selectAll, { cx: uuiCore.cx(css$q.checkbox, uuiCore.uuiDataTableHeaderCell.uuiTableHeaderCheckbox) })));
|
|
2836
|
-
this.renderResizeMark = (props) => React__namespace.createElement("div", { onMouseDown: props.onResizeStart, className: uuiCore.cx(css$q.resizeMark, uuiCore.uuiMarkers.draggable) });
|
|
2837
|
-
this.renderCellContent = (props, dropdownProps) => (React__namespace.createElement(FlexCell, Object.assign({}, this.props.column, { minWidth: this.props.column.width, ref: (ref) => {
|
|
2838
|
-
var _a;
|
|
2839
|
-
props.ref(ref);
|
|
2840
|
-
(_a = dropdownProps === null || dropdownProps === void 0 ? void 0 : dropdownProps.ref) === null || _a === void 0 ? void 0 : _a.call(dropdownProps, ref);
|
|
2841
|
-
}, cx: uuiCore.cx(uuiCore.uuiDataTableHeaderCell.uuiTableHeaderCell, (this.props.column.isSortable || this.props.isDropdown) && uuiCore.uuiMarkers.clickable, css$q.cell, css$q['size-' + (this.props.size || '36')], this.props.isFirstColumn && css$q['padding-left-24'], this.props.isLastColumn && css$q['padding-right-24'], this.props.column.cx, this.props.allowColumnsResizing && css$q.resizable, props.isDraggable && css$q.draggable, props.isDragGhost && css$q.ghost, props.isDraggedOut && css$q.isDraggedOut, props.isDndInProgress && css$q['dnd-marker-' + props.position]), onClick: !this.props.column.renderFilter ? props.toggleSort : dropdownProps === null || dropdownProps === void 0 ? void 0 : dropdownProps.onClick, rawProps: Object.assign({ role: 'columnheader', 'aria-sort': this.props.sortDirection === 'asc' ? 'ascending' : this.props.sortDirection ? 'descending' : 'none' }, props.eventHandlers) }),
|
|
2842
|
-
this.renderHeaderCheckbox(),
|
|
2843
|
-
this.getColumnCaption(),
|
|
2844
|
-
this.props.allowColumnsResizing && this.renderResizeMark(props)));
|
|
2845
|
-
this.renderCellWithFilter = (props) => (React__namespace.createElement(ColumnHeaderDropdown, { isOpen: this.state.isDropdownOpen, isSortable: this.props.column.isSortable, renderTarget: (dropdownProps) => this.renderCellContent(props, dropdownProps), renderFilter: this.props.renderFilter, onSort: this.props.onSort, sortDirection: this.props.sortDirection, onOpenChange: (isDropdownOpen) => this.setState({ isDropdownOpen }), title: this.props.column.caption }));
|
|
2846
|
-
}
|
|
2847
|
-
render() {
|
|
2848
|
-
return React__namespace.createElement(uuiComponents.DataTableHeaderCell, Object.assign({}, this.props, { renderCellContent: this.props.column.renderFilter ? this.renderCellWithFilter : this.renderCellContent }));
|
|
2849
|
-
}
|
|
2850
|
-
}
|
|
2851
|
-
|
|
2852
|
-
var css$p = {"header-cell":"csxPiM","config-icon":"B23ddJ","headerCell":"csxPiM","configIcon":"B23ddJ"};
|
|
2853
|
-
|
|
2854
|
-
var _path$n;
|
|
2855
|
-
function _extends$o() { _extends$o = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$o.apply(this, arguments); }
|
|
2856
|
-
var SvgActionSettings18 = function SvgActionSettings18(props, ref) {
|
|
2857
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$o({
|
|
2858
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
2859
|
-
width: 18,
|
|
2860
|
-
height: 18,
|
|
2861
|
-
viewBox: "0 0 18 18",
|
|
2862
|
-
ref: ref
|
|
2863
|
-
}, props), _path$n || (_path$n = /*#__PURE__*/React__namespace.createElement("path", {
|
|
2864
|
-
fillRule: "evenodd",
|
|
2865
|
-
d: "M3 9.093a6.083 6.083 0 0 1 0-.186L1.55 7.271a1 1 0 0 1-.118-1.163l1.28-2.216a1 1 0 0 1 1.066-.48l2.14.439a3.81 3.81 0 0 1 .163-.094l.691-2.073A1 1 0 0 1 7.721 1h2.558a1 1 0 0 1 .949.684l.69 2.073c.056.03.11.061.163.094l2.141-.439a1 1 0 0 1 1.067.48l1.279 2.216a1 1 0 0 1-.118 1.163L15 8.907a5.72 5.72 0 0 1 0 .186l1.45 1.636a1 1 0 0 1 .118 1.163l-1.28 2.216a1 1 0 0 1-1.066.48l-2.14-.438a6.215 6.215 0 0 1-.163.093l-.691 2.073a1 1 0 0 1-.949.684H7.721a1 1 0 0 1-.949-.684l-.69-2.073a6.105 6.105 0 0 1-.163-.094l-2.141.439a1 1 0 0 1-1.067-.48l-1.279-2.216a1 1 0 0 1 .118-1.163L3 9.093zM9 12a3 3 0 1 0 0-6 3 3 0 0 0 0 6z",
|
|
2866
|
-
clipRule: "evenodd"
|
|
2867
|
-
})));
|
|
2868
|
-
};
|
|
2869
|
-
var ForwardRef$o = /*#__PURE__*/React.forwardRef(SvgActionSettings18);
|
|
2870
|
-
|
|
2871
|
-
const DataTableHeaderRow = uuiCore.withMods(uuiComponents.DataTableHeaderRow, () => [css$p.root], (mods) => ({
|
|
2872
|
-
renderCell: (props) => React__namespace.createElement(DataTableHeaderCell, Object.assign({}, props, { size: mods.size, textCase: mods.textCase || 'normal', key: props.column.key })),
|
|
2873
|
-
renderConfigButton: () => React__namespace.createElement(IconButton, { key: "configuration", onClick: mods.onConfigButtonClick, cx: css$p.configIcon, color: "default", icon: ForwardRef$o }),
|
|
2874
|
-
}));
|
|
2875
|
-
|
|
2876
|
-
var css$o = {"root":"I6CA0x","title-wrapper":"vf-OAE","title":"zDg-E-","text-wrapper":"_4iPQBD","selection":"RN11B2","postfix":"XTLeTq","selected":"_1-TViP","titleWrapper":"vf-OAE","textWrapper":"_4iPQBD"};
|
|
2877
|
-
|
|
2878
|
-
const defaultSize = '36';
|
|
2879
|
-
const FilterPanelItemToggler = React__namespace.forwardRef((props, ref) => {
|
|
2880
|
-
const togglerPickerOpened = (e) => {
|
|
2881
|
-
var _a;
|
|
2882
|
-
if (props.isDisabled)
|
|
2883
|
-
return;
|
|
2884
|
-
e.preventDefault();
|
|
2885
|
-
(_a = props.onClick) === null || _a === void 0 ? void 0 : _a.call(props);
|
|
2886
|
-
};
|
|
2887
|
-
const onKeyDownHandler = (e) => {
|
|
2888
|
-
if (props.isDisabled)
|
|
2889
|
-
return;
|
|
2890
|
-
if (e.key === 'Enter' && !props.isOpen) {
|
|
2891
|
-
e.preventDefault();
|
|
2892
|
-
props.toggleDropdownOpening(true);
|
|
2893
|
-
}
|
|
2894
|
-
if (e.key === 'Escape' && props.isOpen) {
|
|
2895
|
-
e.preventDefault();
|
|
2896
|
-
props.toggleDropdownOpening(false);
|
|
2897
|
-
}
|
|
2898
|
-
};
|
|
2899
|
-
const getTitle = props.predicateName ? `${props.title} ${props.predicateName}` : `${props.title}${props.selection ? ':' : ''}`;
|
|
2900
|
-
const getSelectionText = () => props.selection.map((i, index) => (React__namespace.createElement(React__namespace.Fragment, { key: `${i}${index}` },
|
|
2901
|
-
React__namespace.createElement(Text, { color: "brand", size: props.size, cx: css$o.selection }, i),
|
|
2902
|
-
(props.postfix || index !== props.selection.length - 1) && React__namespace.createElement("span", null, ",\u00A0"))));
|
|
2903
|
-
return (React__namespace.createElement(uuiComponents.FlexRow, Object.assign({}, props, { rawProps: {
|
|
2904
|
-
style: { maxWidth: `${props.maxWidth ? props.maxWidth + 'px' : 'auto'}` },
|
|
2905
|
-
role: 'button',
|
|
2906
|
-
tabIndex: props.isDisabled ? -1 : 0,
|
|
2907
|
-
onKeyDown: onKeyDownHandler,
|
|
2908
|
-
}, cx: cx__default.default(css$o.root, uuiCore.uuiElement.inputBox, uuiCore.uuiMarkers.clickable, props.isOpen && uuiCore.uuiMod.opened, ['size-' + (props.size || defaultSize)], props.cx), onClick: togglerPickerOpened, ref: ref }),
|
|
2909
|
-
React__namespace.createElement(uuiComponents.FlexRow, { cx: css$o.titleWrapper },
|
|
2910
|
-
React__namespace.createElement(Text, { size: props.size, cx: css$o.title }, getTitle),
|
|
2911
|
-
props.selection && (React__namespace.createElement("div", { className: css$o.textWrapper },
|
|
2912
|
-
getSelectionText(),
|
|
2913
|
-
props.postfix && (React__namespace.createElement(Text, { color: "brand", size: props.size, cx: css$o.postfix }, props.postfix))))),
|
|
2914
|
-
!props.isDisabled && React__namespace.createElement(uuiComponents.IconContainer, { icon: systemIcons[props.size || defaultSize].foldingArrow, flipY: props.isOpen, cx: "uui-icon-dropdown" })));
|
|
2915
|
-
});
|
|
2916
|
-
|
|
2917
|
-
const pickerHeight = 300;
|
|
2918
|
-
function FilterPickerBody(props) {
|
|
2919
|
-
const shouldShowBody = () => props.isOpen;
|
|
2920
|
-
const { getName, isSingleSelect, getRows, dataSourceState, getFooterProps, getPickerBodyProps, getListProps, handleDataSourceValueChange, } = uuiComponents.usePickerInput(Object.assign(Object.assign({}, props), { shouldShowBody }));
|
|
2921
|
-
const renderItem = (item, rowProps) => {
|
|
2922
|
-
return React__namespace.createElement(PickerItem, Object.assign({ title: getName(item), size: "36" }, rowProps));
|
|
2923
|
-
};
|
|
2924
|
-
const onSelect = (row) => {
|
|
2925
|
-
props.onClose();
|
|
2926
|
-
handleDataSourceValueChange(Object.assign(Object.assign({}, dataSourceState), { search: '', selectedId: row.id }));
|
|
2927
|
-
};
|
|
2928
|
-
const renderRow = (rowProps) => {
|
|
2929
|
-
if (rowProps.isSelectable && isSingleSelect() && props.editMode !== 'modal') {
|
|
2930
|
-
rowProps.onSelect = onSelect;
|
|
2931
|
-
}
|
|
2932
|
-
return props.renderRow ? (props.renderRow(rowProps, dataSourceState)) : (React__namespace.createElement(DataPickerRow, Object.assign({}, rowProps, { key: rowProps.rowKey, borderBottom: "none", size: "36", padding: "12", renderItem: renderItem })));
|
|
2933
|
-
};
|
|
2934
|
-
const renderFooter = () => {
|
|
2935
|
-
return React__namespace.createElement(DataPickerFooter, Object.assign({}, getFooterProps(), { size: "36" }));
|
|
2936
|
-
};
|
|
2937
|
-
const renderBody = (bodyProps, rows) => {
|
|
2938
|
-
const renderedDataRows = rows.map((props) => renderRow(props));
|
|
2939
|
-
const maxHeight = uuiCore.isMobile() ? document.documentElement.clientHeight : props.dropdownHeight || pickerHeight;
|
|
2940
|
-
return (React__namespace.createElement(React__namespace.Fragment, null,
|
|
2941
|
-
React__namespace.createElement(DataPickerBody, Object.assign({}, bodyProps, { selectionMode: props.selectionMode, rows: renderedDataRows, maxHeight: maxHeight, searchSize: "36", editMode: "dropdown", showSearch: true })),
|
|
2942
|
-
renderFooter()));
|
|
2943
|
-
};
|
|
2944
|
-
const rows = getRows();
|
|
2945
|
-
return renderBody(Object.assign(Object.assign({}, getPickerBodyProps(rows)), getListProps()), rows);
|
|
2946
|
-
}
|
|
2947
|
-
|
|
2948
|
-
class FilterDatePickerBody extends uuiComponents.BaseDatePicker {
|
|
2949
|
-
constructor() {
|
|
2950
|
-
super(...arguments);
|
|
2951
|
-
this.state = Object.assign(Object.assign({}, super.getValue()), { isOpen: false, inputValue: null });
|
|
2952
|
-
this.renderInput = () => {
|
|
2953
|
-
return null;
|
|
2954
|
-
};
|
|
2955
|
-
this.onToggleHandler = (val) => {
|
|
2956
|
-
this.onToggle(val);
|
|
2957
|
-
this.props.onClose();
|
|
2958
|
-
};
|
|
2959
|
-
this.handleCancel = () => {
|
|
2960
|
-
this.handleValueChange(undefined);
|
|
2961
|
-
this.setState({ inputValue: null, selectedDate: null });
|
|
2962
|
-
};
|
|
2963
|
-
}
|
|
2964
|
-
renderBody() {
|
|
2965
|
-
var _a;
|
|
2966
|
-
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
2967
|
-
React__namespace.default.createElement(FlexRow, { borderBottom: true },
|
|
2968
|
-
React__namespace.default.createElement(DatePickerBody, { filter: this.props.filter, value: this.getValue(), setSelectedDate: this.setSelectedDate, setDisplayedDateAndView: this.setDisplayedDateAndView, changeIsOpen: this.onToggleHandler, renderDay: this.props.renderDay, isHoliday: this.props.isHoliday, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.body })),
|
|
2969
|
-
React__namespace.default.createElement(FlexCell, { alignSelf: "stretch" },
|
|
2970
|
-
React__namespace.default.createElement(FlexRow, { padding: "24", vPadding: "12" },
|
|
2971
|
-
React__namespace.default.createElement(Text, null, this.state.selectedDate ? dayjs__default.default(this.state.selectedDate).format('MMM DD, YYYY') : ''),
|
|
2972
|
-
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
2973
|
-
React__namespace.default.createElement(LinkButton, { isDisabled: !this.state.selectedDate, caption: i18n.filterToolbar.datePicker.clearCaption, onClick: this.handleCancel })))));
|
|
2974
|
-
}
|
|
2975
|
-
render() {
|
|
2976
|
-
return this.renderBody();
|
|
2977
|
-
}
|
|
2978
|
-
}
|
|
2979
|
-
|
|
2980
|
-
var css$n = {"date-input":"oXyvT9","size-24":"aYiI4h","size-30":"nUhMQv","size-36":"_8nzaPk","size-42":"Gn6Pm1","size-48":"zNamhc","date-input-group":"_6tNooK","separator":"MJxVBQ","mode-form":"qJ464i","mode-cell":"k4jEGI","dateInput":"oXyvT9","size24":"aYiI4h","size30":"nUhMQv","size36":"_8nzaPk","size42":"Gn6Pm1","size48":"zNamhc","dateInputGroup":"_6tNooK","modeForm":"qJ464i","modeCell":"k4jEGI"};
|
|
2485
|
+
var css$A = {"uui-typography":"nq8HVJ","hero-header":"-JlEiH","promo-header":"lGb28G","uui-critical":"mNMMdo","uui-success":"jiMme-","uui-warning":"wsN6bm","uui-typography-size-12":"US-CEK","uui-typography-size-14":"_884cdM","uui-typography-size-16":"Wlq7qT","date-input":"OnE5M6","size-24":"Kim8pZ","size-30":"KP0jS9","size-36":"BN14qX","size-42":"eQT5mR","size-48":"_22soQP","date-input-group":"lBgfjb","separator":"yqG3nJ","mode-form":"yjK-uf","mode-cell":"Hu7bpx","uuiTypography":"nq8HVJ","heroHeader":"-JlEiH","promoHeader":"lGb28G","uuiCritical":"mNMMdo","uuiSuccess":"jiMme-","uuiWarning":"wsN6bm","uuiTypographySize12":"US-CEK","uuiTypographySize14":"_884cdM","uuiTypographySize16":"Wlq7qT","dateInput":"OnE5M6","size24":"Kim8pZ","size30":"KP0jS9","size36":"BN14qX","size42":"eQT5mR","size48":"_22soQP","dateInputGroup":"lBgfjb","modeForm":"yjK-uf","modeCell":"Hu7bpx"};
|
|
2981
2486
|
|
|
2982
2487
|
class FilterRangeDatePickerBody extends uuiComponents.BaseRangeDatePicker {
|
|
2983
2488
|
constructor() {
|
|
@@ -2997,10 +2502,10 @@ class FilterRangeDatePickerBody extends uuiComponents.BaseRangeDatePicker {
|
|
|
2997
2502
|
React__namespace.createElement(RangeDatePickerBody, { value: this.getValue(), onValueChange: this.onRangeChange, filter: this.props.filter, focusPart: this.state.inFocus, changeIsOpen: this.changeIsOpen, presets: this.props.presets })),
|
|
2998
2503
|
React__namespace.createElement(FlexCell, { alignSelf: "stretch" },
|
|
2999
2504
|
React__namespace.createElement(FlexRow, { padding: "24", vPadding: "12" },
|
|
3000
|
-
React__namespace.createElement("div", { className: cx__default.default(css$
|
|
3001
|
-
React__namespace.createElement(TextInput, { icon: systemIcons['30'].calendar, cx: cx__default.default(css$
|
|
3002
|
-
React__namespace.createElement("div", { className: css$
|
|
3003
|
-
React__namespace.createElement(TextInput, { cx: cx__default.default(css$
|
|
2505
|
+
React__namespace.createElement("div", { className: cx__default.default(css$A.dateInputGroup, this.state.inFocus && uuiCore.uuiMod.focus) },
|
|
2506
|
+
React__namespace.createElement(TextInput, { icon: systemIcons['30'].calendar, cx: cx__default.default(css$A.dateInput, css$A['size-30'], this.state.inFocus === 'from' && uuiCore.uuiMod.focus), size: "30", placeholder: i18n.rangeDatePicker.pickerPlaceholderFrom, value: this.state.inputValue.from, onValueChange: this.getChangeHandler('from'), onFocus: (event) => this.handleFocus(event, 'from'), onBlur: (event) => this.handleBlur(event, 'from') }),
|
|
2507
|
+
React__namespace.createElement("div", { className: css$A.separator }),
|
|
2508
|
+
React__namespace.createElement(TextInput, { cx: cx__default.default(css$A.dateInput, css$A['size-30'], this.state.inFocus === 'to' && uuiCore.uuiMod.focus), placeholder: i18n.rangeDatePicker.pickerPlaceholderTo, size: "30", value: this.state.inputValue.to, onCancel: this.state.inputValue.from && this.state.inputValue.to && this.handleCancel, onValueChange: this.getChangeHandler('to'), onFocus: (event) => this.handleFocus(event, 'to'), onBlur: (event) => this.handleBlur(event, 'to') })),
|
|
3004
2509
|
React__namespace.createElement(uuiComponents.FlexSpacer, null),
|
|
3005
2510
|
React__namespace.createElement(LinkButton, { isDisabled: !this.state.inputValue.from && !this.state.inputValue.to, caption: i18n.pickerModal.clearAllButton, onClick: this.handleCancel })))));
|
|
3006
2511
|
}
|
|
@@ -3009,7 +2514,7 @@ class FilterRangeDatePickerBody extends uuiComponents.BaseRangeDatePicker {
|
|
|
3009
2514
|
}
|
|
3010
2515
|
}
|
|
3011
2516
|
|
|
3012
|
-
var css$
|
|
2517
|
+
var css$z = {"container":"ZwHvOp"};
|
|
3013
2518
|
|
|
3014
2519
|
function FilterNumericBody(props) {
|
|
3015
2520
|
var _a, _b;
|
|
@@ -3053,7 +2558,7 @@ function FilterNumericBody(props) {
|
|
|
3053
2558
|
if (isInRangePredicate) {
|
|
3054
2559
|
const value = props.value;
|
|
3055
2560
|
return (React__namespace.default.createElement("div", null,
|
|
3056
|
-
React__namespace.default.createElement(FlexRow, { padding: "12", alignItems: "center", spacing: "12", borderBottom: true, cx: css$
|
|
2561
|
+
React__namespace.default.createElement(FlexRow, { padding: "12", alignItems: "center", spacing: "12", borderBottom: true, cx: css$z.container },
|
|
3057
2562
|
React__namespace.default.createElement(FlexCell, { width: "100%" },
|
|
3058
2563
|
React__namespace.default.createElement(NumericInput, { value: (_a = value === null || value === void 0 ? void 0 : value.from) !== null && _a !== void 0 ? _a : null, onValueChange: rangeValueHandler('from'), size: "36", placeholder: "Min", formatOptions: { maximumFractionDigits: 2 } })),
|
|
3059
2564
|
React__namespace.default.createElement(FlexCell, { width: "100%" },
|
|
@@ -3061,7 +2566,7 @@ function FilterNumericBody(props) {
|
|
|
3061
2566
|
renderFooter()));
|
|
3062
2567
|
}
|
|
3063
2568
|
return (React__namespace.default.createElement("div", null,
|
|
3064
|
-
React__namespace.default.createElement(FlexRow, { padding: "12", alignItems: "center", borderBottom: true, cx: css$
|
|
2569
|
+
React__namespace.default.createElement(FlexRow, { padding: "12", alignItems: "center", borderBottom: true, cx: css$z.container },
|
|
3065
2570
|
React__namespace.default.createElement(FlexCell, { width: 130 },
|
|
3066
2571
|
React__namespace.default.createElement(NumericInput, { value: typeof props.value === 'number' ? props.value : null, onValueChange: props.onValueChange, size: "36", placeholder: "Enter a number", formatOptions: { maximumFractionDigits: 2 } }))),
|
|
3067
2572
|
renderFooter()));
|
|
@@ -3084,23 +2589,23 @@ function FilterItemBody(props) {
|
|
|
3084
2589
|
}
|
|
3085
2590
|
}
|
|
3086
2591
|
|
|
3087
|
-
var _path$
|
|
3088
|
-
function _extends$
|
|
2592
|
+
var _path$t;
|
|
2593
|
+
function _extends$u() { _extends$u = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$u.apply(this, arguments); }
|
|
3089
2594
|
var SvgActionDeleteforever12 = function SvgActionDeleteforever12(props, ref) {
|
|
3090
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
2595
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$u({
|
|
3091
2596
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3092
2597
|
width: 12,
|
|
3093
2598
|
height: 12,
|
|
3094
2599
|
viewBox: "0 0 18 18",
|
|
3095
2600
|
ref: ref
|
|
3096
|
-
}, props), _path$
|
|
2601
|
+
}, props), _path$t || (_path$t = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3097
2602
|
fillRule: "evenodd",
|
|
3098
2603
|
d: "M14 6v8a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6h10zm-3-4 1 1h3v2H3V3h3l1-1h4zm-.24 12.1L9 12.36 7.24 14.1l-1.16-1.16 1.74-1.76-1.78-1.8 1.2-1.18L9 10l1.76-1.8 1.18 1.18-1.76 1.8 1.76 1.76-1.18 1.16z"
|
|
3099
2604
|
})));
|
|
3100
2605
|
};
|
|
3101
|
-
var ForwardRef$
|
|
2606
|
+
var ForwardRef$u = /*#__PURE__*/React.forwardRef(SvgActionDeleteforever12);
|
|
3102
2607
|
|
|
3103
|
-
var css$
|
|
2608
|
+
var css$y = {"uui-typography":"_-3QkAU","hero-header":"_35Pjn1","promo-header":"F5S-XN","uui-critical":"tm4WKM","uui-success":"H--XFr","uui-warning":"oe-YSy","uui-typography-size-12":"WSAbn5","uui-typography-size-14":"l-b9d0","uui-typography-size-16":"KxYOB5","root":"w1uOAy","header":"ZCXggF","removeButton":"IZ2zz3","with-search":"Cwt8av","uuiTypography":"_-3QkAU","heroHeader":"_35Pjn1","promoHeader":"F5S-XN","uuiCritical":"tm4WKM","uuiSuccess":"H--XFr","uuiWarning":"oe-YSy","uuiTypographySize12":"WSAbn5","uuiTypographySize14":"l-b9d0","uuiTypographySize16":"KxYOB5","withSearch":"Cwt8av"};
|
|
3104
2609
|
|
|
3105
2610
|
function FiltersToolbarItemImpl(props) {
|
|
3106
2611
|
const { maxCount = 2 } = props;
|
|
@@ -3176,13 +2681,13 @@ function FiltersToolbarItemImpl(props) {
|
|
|
3176
2681
|
};
|
|
3177
2682
|
const renderHeader = (hideTitle) => {
|
|
3178
2683
|
var _a;
|
|
3179
|
-
return (React__namespace.default.createElement("div", { className: cx__default.default(css$
|
|
2684
|
+
return (React__namespace.default.createElement("div", { className: cx__default.default(css$y.header, isPickersType && ((_a = props.showSearch) !== null && _a !== void 0 ? _a : css$y.withSearch)) },
|
|
3180
2685
|
props.predicates ? (React__namespace.default.createElement(MultiSwitch, { items: props.predicates.map((i) => ({ id: i.predicate, caption: i.name })), value: predicate, onValueChange: changePredicate, size: "24" })) : (!hideTitle && (React__namespace.default.createElement(Text, { color: "secondary", size: "24", fontSize: "14" }, props.title))),
|
|
3181
|
-
!(props === null || props === void 0 ? void 0 : props.isAlwaysVisible) && (React__namespace.default.createElement(LinkButton, { cx: css$
|
|
2686
|
+
!(props === null || props === void 0 ? void 0 : props.isAlwaysVisible) && (React__namespace.default.createElement(LinkButton, { cx: css$y.removeButton, caption: i18n.filterToolbar.datePicker.removeCaption, onClick: removeOnclickHandler, size: "24", icon: ForwardRef$u }))));
|
|
3182
2687
|
};
|
|
3183
2688
|
const renderBody = (dropdownProps) => {
|
|
3184
2689
|
const hideHeaderTitle = isPickersType && isMobileScreen;
|
|
3185
|
-
return isPickersType ? (React__namespace.default.createElement(MobileDropdownWrapper, Object.assign({}, dropdownProps, { title: props.title, width: 360, onClose: () => isOpenChange(false) }),
|
|
2690
|
+
return isPickersType ? (React__namespace.default.createElement(MobileDropdownWrapper, Object.assign({}, dropdownProps, { cx: css$y.root, title: props.title, width: 360, onClose: () => isOpenChange(false) }),
|
|
3186
2691
|
renderHeader(hideHeaderTitle),
|
|
3187
2692
|
React__namespace.default.createElement(FilterItemBody, Object.assign({}, props, dropdownProps, { selectedPredicate: predicate, value: getValue(), onValueChange: onValueChange })))) : (React__namespace.default.createElement(DropdownContainer, Object.assign({}, dropdownProps),
|
|
3188
2693
|
renderHeader(hideHeaderTitle),
|
|
@@ -3265,20 +2770,20 @@ function FiltersToolbarItemImpl(props) {
|
|
|
3265
2770
|
}
|
|
3266
2771
|
const FiltersPanelItem = React__namespace.default.memo(FiltersToolbarItemImpl);
|
|
3267
2772
|
|
|
3268
|
-
var _path$
|
|
3269
|
-
function _extends$
|
|
2773
|
+
var _path$s;
|
|
2774
|
+
function _extends$t() { _extends$t = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$t.apply(this, arguments); }
|
|
3270
2775
|
var SvgActionAdd18 = function SvgActionAdd18(props, ref) {
|
|
3271
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
2776
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$t({
|
|
3272
2777
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3273
2778
|
width: 18,
|
|
3274
2779
|
height: 18,
|
|
3275
2780
|
viewBox: "0 0 18 18",
|
|
3276
2781
|
ref: ref
|
|
3277
|
-
}, props), _path$
|
|
2782
|
+
}, props), _path$s || (_path$s = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3278
2783
|
d: "M10 2H8v6H2v2h6v6h2v-6h6V8h-6V2z"
|
|
3279
2784
|
})));
|
|
3280
2785
|
};
|
|
3281
|
-
var ForwardRef$
|
|
2786
|
+
var ForwardRef$t = /*#__PURE__*/React.forwardRef(SvgActionAdd18);
|
|
3282
2787
|
|
|
3283
2788
|
const normalizeFilterWithPredicates = (filter) => {
|
|
3284
2789
|
if (!filter) {
|
|
@@ -3369,7 +2874,7 @@ function FiltersToolbarImpl(props) {
|
|
|
3369
2874
|
}, [filters, tableState.filtersConfig]);
|
|
3370
2875
|
const renderAddFilterToggler = React.useCallback((togglerProps) => {
|
|
3371
2876
|
var _a;
|
|
3372
|
-
return (React__namespace.default.createElement(Button, { size: (_a = props.size) !== null && _a !== void 0 ? _a : '36', onClick: togglerProps.onClick, ref: togglerProps.ref, caption: i18n.filterToolbar.addCaption, icon: ForwardRef$
|
|
2877
|
+
return (React__namespace.default.createElement(Button, { size: (_a = props.size) !== null && _a !== void 0 ? _a : '36', onClick: togglerProps.onClick, ref: togglerProps.ref, caption: i18n.filterToolbar.addCaption, icon: ForwardRef$t, iconPosition: "left", fill: "ghost", color: "primary" }));
|
|
3373
2878
|
}, []);
|
|
3374
2879
|
const getRowOptions = React.useCallback((item) => ({
|
|
3375
2880
|
isDisabled: item.isAlwaysVisible,
|
|
@@ -3396,143 +2901,143 @@ function FiltersToolbarImpl(props) {
|
|
|
3396
2901
|
}
|
|
3397
2902
|
const FiltersPanel = React__namespace.default.memo(FiltersToolbarImpl);
|
|
3398
2903
|
|
|
3399
|
-
var css$
|
|
2904
|
+
var css$x = {"divider":"iXP7pj","dropdownDeleteIcon":"_1E2e-U","presetsWrapper":"Qpmoqm","addPresetContainer":"mkB-13","dropContainer":"Wt42Az"};
|
|
3400
2905
|
|
|
3401
|
-
var css$
|
|
2906
|
+
var css$w = {"preset-dropdown-panel":"rilFzG","delete-row":"A-VvvW","delete-button":"z6Lm8U","targetOpen":"jDWIkr","presetDropdownPanel":"rilFzG","deleteRow":"A-VvvW","deleteButton":"z6Lm8U"};
|
|
3402
2907
|
|
|
3403
|
-
var _path$
|
|
3404
|
-
function _extends$
|
|
2908
|
+
var _path$r;
|
|
2909
|
+
function _extends$s() { _extends$s = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$s.apply(this, arguments); }
|
|
3405
2910
|
var SvgNavigationMoreVert18 = function SvgNavigationMoreVert18(props, ref) {
|
|
3406
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
2911
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$s({
|
|
3407
2912
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3408
2913
|
width: 18,
|
|
3409
2914
|
height: 18,
|
|
3410
2915
|
viewBox: "0 0 18 18",
|
|
3411
2916
|
ref: ref
|
|
3412
|
-
}, props), _path$
|
|
2917
|
+
}, props), _path$r || (_path$r = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3413
2918
|
fillRule: "evenodd",
|
|
3414
2919
|
d: "M9 6c.825 0 1.5-.675 1.5-1.5S9.825 3 9 3s-1.5.675-1.5 1.5S8.175 6 9 6zm0 1.5c-.825 0-1.5.675-1.5 1.5s.675 1.5 1.5 1.5 1.5-.675 1.5-1.5S9.825 7.5 9 7.5zM9 12c-.825 0-1.5.675-1.5 1.5S8.175 15 9 15s1.5-.675 1.5-1.5S9.825 12 9 12z",
|
|
3415
2920
|
clipRule: "evenodd"
|
|
3416
2921
|
})));
|
|
3417
2922
|
};
|
|
3418
|
-
var ForwardRef$
|
|
2923
|
+
var ForwardRef$s = /*#__PURE__*/React.forwardRef(SvgNavigationMoreVert18);
|
|
3419
2924
|
|
|
3420
|
-
var _path$
|
|
3421
|
-
function _extends$
|
|
2925
|
+
var _path$q;
|
|
2926
|
+
function _extends$r() { _extends$r = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$r.apply(this, arguments); }
|
|
3422
2927
|
var SvgActionUpdate18 = function SvgActionUpdate18(props, ref) {
|
|
3423
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
2928
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$r({
|
|
3424
2929
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3425
2930
|
width: 18,
|
|
3426
2931
|
height: 18,
|
|
3427
2932
|
viewBox: "0 0 18 18",
|
|
3428
2933
|
ref: ref
|
|
3429
|
-
}, props), _path$
|
|
2934
|
+
}, props), _path$q || (_path$q = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3430
2935
|
fillRule: "evenodd",
|
|
3431
2936
|
d: "M8.007 2A7.004 7.004 0 0 0 1 9a7.004 7.004 0 0 0 11.732 5.16l-1.497-1.347A4.999 4.999 0 0 1 3 9c0-2.763 2.237-5 5-5 2.762 0 5 2.237 5 5h2c0-3.864-3.129-7-6.993-7zM11 9l3 3 3-3h-6z",
|
|
3432
2937
|
clipRule: "evenodd"
|
|
3433
2938
|
})));
|
|
3434
2939
|
};
|
|
3435
|
-
var ForwardRef$
|
|
2940
|
+
var ForwardRef$r = /*#__PURE__*/React.forwardRef(SvgActionUpdate18);
|
|
3436
2941
|
|
|
3437
|
-
var _path$
|
|
3438
|
-
function _extends$
|
|
2942
|
+
var _path$p;
|
|
2943
|
+
function _extends$q() { _extends$q = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$q.apply(this, arguments); }
|
|
3439
2944
|
var SvgSaveOutline18 = function SvgSaveOutline18(props, ref) {
|
|
3440
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
2945
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$q({
|
|
3441
2946
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3442
2947
|
width: 18,
|
|
3443
2948
|
height: 18,
|
|
3444
2949
|
viewBox: "0 0 18 18",
|
|
3445
2950
|
ref: ref
|
|
3446
|
-
}, props), _path$
|
|
2951
|
+
}, props), _path$p || (_path$p = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3447
2952
|
d: "M12.75 2.25h-9a1.5 1.5 0 0 0-1.5 1.5v10.5a1.5 1.5 0 0 0 1.5 1.5h10.5c.825 0 1.5-.675 1.5-1.5v-9l-3-3zm1.5 12H3.75V3.75h8.377l2.123 2.122v8.378zM9 9a2.247 2.247 0 0 0-2.25 2.25A2.247 2.247 0 0 0 9 13.5a2.247 2.247 0 0 0 2.25-2.25A2.247 2.247 0 0 0 9 9zM4.5 4.5h6.75v3H4.5v-3z"
|
|
3448
2953
|
})));
|
|
3449
2954
|
};
|
|
3450
|
-
var ForwardRef$
|
|
2955
|
+
var ForwardRef$q = /*#__PURE__*/React.forwardRef(SvgSaveOutline18);
|
|
3451
2956
|
|
|
3452
|
-
var _path$
|
|
3453
|
-
function _extends$
|
|
2957
|
+
var _path$o;
|
|
2958
|
+
function _extends$p() { _extends$p = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$p.apply(this, arguments); }
|
|
3454
2959
|
var SvgContentEditUndo18 = function SvgContentEditUndo18(props, ref) {
|
|
3455
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
2960
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$p({
|
|
3456
2961
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3457
2962
|
width: 18,
|
|
3458
2963
|
height: 18,
|
|
3459
2964
|
viewBox: "0 0 18 18",
|
|
3460
2965
|
ref: ref
|
|
3461
|
-
}, props), _path$
|
|
2966
|
+
}, props), _path$o || (_path$o = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3462
2967
|
fillRule: "evenodd",
|
|
3463
2968
|
d: "M9.375 6A7.848 7.848 0 0 0 4.2 7.95l-2.7-2.7V12h6.75L5.535 9.285a5.965 5.965 0 0 1 3.84-1.41 6.009 6.009 0 0 1 5.7 4.125l1.777-.585C15.81 8.273 12.862 6 9.375 6z",
|
|
3464
2969
|
clipRule: "evenodd"
|
|
3465
2970
|
})));
|
|
3466
2971
|
};
|
|
3467
|
-
var ForwardRef$
|
|
2972
|
+
var ForwardRef$p = /*#__PURE__*/React.forwardRef(SvgContentEditUndo18);
|
|
3468
2973
|
|
|
3469
|
-
var _path$
|
|
3470
|
-
function _extends$
|
|
2974
|
+
var _path$n;
|
|
2975
|
+
function _extends$o() { _extends$o = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$o.apply(this, arguments); }
|
|
3471
2976
|
var SvgActionCopyContent18 = function SvgActionCopyContent18(props, ref) {
|
|
3472
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
2977
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$o({
|
|
3473
2978
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3474
2979
|
width: 18,
|
|
3475
2980
|
height: 18,
|
|
3476
2981
|
viewBox: "0 0 18 18",
|
|
3477
2982
|
ref: ref
|
|
3478
|
-
}, props), _path$
|
|
2983
|
+
}, props), _path$n || (_path$n = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3479
2984
|
fillRule: "evenodd",
|
|
3480
2985
|
d: "M3 1h8v2H3v8H1V3a2 2 0 0 1 2-2zm2 6a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V7zm10 8H7V7h8v8z",
|
|
3481
2986
|
clipRule: "evenodd"
|
|
3482
2987
|
})));
|
|
3483
2988
|
};
|
|
3484
|
-
var ForwardRef$
|
|
2989
|
+
var ForwardRef$o = /*#__PURE__*/React.forwardRef(SvgActionCopyContent18);
|
|
3485
2990
|
|
|
3486
|
-
var _path$
|
|
3487
|
-
function _extends$
|
|
2991
|
+
var _path$m;
|
|
2992
|
+
function _extends$n() { _extends$n = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$n.apply(this, arguments); }
|
|
3488
2993
|
var SvgContentEdit18 = function SvgContentEdit18(props, ref) {
|
|
3489
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
2994
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$n({
|
|
3490
2995
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3491
2996
|
width: 18,
|
|
3492
2997
|
height: 18,
|
|
3493
2998
|
viewBox: "0 0 18 18",
|
|
3494
2999
|
ref: ref
|
|
3495
|
-
}, props), _path$
|
|
3000
|
+
}, props), _path$m || (_path$m = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3496
3001
|
fillRule: "evenodd",
|
|
3497
3002
|
d: "M2.25 12.94v2.812h2.813l8.294-8.295-2.812-2.813L2.25 12.94zm13.283-7.658a.747.747 0 0 0 0-1.058L13.777 2.47a.747.747 0 0 0-1.058 0l-1.373 1.373 2.813 2.812 1.373-1.372z",
|
|
3498
3003
|
clipRule: "evenodd"
|
|
3499
3004
|
})));
|
|
3500
3005
|
};
|
|
3501
|
-
var ForwardRef$
|
|
3006
|
+
var ForwardRef$n = /*#__PURE__*/React.forwardRef(SvgContentEdit18);
|
|
3502
3007
|
|
|
3503
|
-
var _path$
|
|
3504
|
-
function _extends$
|
|
3008
|
+
var _path$l;
|
|
3009
|
+
function _extends$m() { _extends$m = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$m.apply(this, arguments); }
|
|
3505
3010
|
var SvgContentLink18 = function SvgContentLink18(props, ref) {
|
|
3506
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
3011
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$m({
|
|
3507
3012
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3508
3013
|
width: 18,
|
|
3509
3014
|
height: 18,
|
|
3510
3015
|
viewBox: "0 0 18 18",
|
|
3511
3016
|
ref: ref
|
|
3512
|
-
}, props), _path$
|
|
3017
|
+
}, props), _path$l || (_path$l = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3513
3018
|
fillRule: "evenodd",
|
|
3514
3019
|
d: "M7.943 10.057a.73.73 0 0 1 0 1.066.756.756 0 0 1-1.065 0 3.753 3.753 0 0 1 0-5.303l2.655-2.655a3.753 3.753 0 0 1 5.302 0 3.753 3.753 0 0 1 0 5.302l-1.118 1.118a5.18 5.18 0 0 0-.3-1.815l.353-.36a2.236 2.236 0 0 0 0-3.18 2.236 2.236 0 0 0-3.18 0L7.943 6.877a2.236 2.236 0 0 0 0 3.18zm2.114-3.18a.756.756 0 0 1 1.066 0 3.753 3.753 0 0 1 0 5.303l-2.655 2.655a3.753 3.753 0 0 1-5.303 0 3.753 3.753 0 0 1 0-5.303l1.118-1.117a5.25 5.25 0 0 0 .3 1.823l-.353.352a2.236 2.236 0 0 0 0 3.18 2.236 2.236 0 0 0 3.18 0l2.647-2.647a2.236 2.236 0 0 0 0-3.18.73.73 0 0 1 0-1.066z",
|
|
3515
3020
|
clipRule: "evenodd"
|
|
3516
3021
|
})));
|
|
3517
3022
|
};
|
|
3518
|
-
var ForwardRef$
|
|
3023
|
+
var ForwardRef$m = /*#__PURE__*/React.forwardRef(SvgContentLink18);
|
|
3519
3024
|
|
|
3520
|
-
var _path$
|
|
3521
|
-
function _extends$
|
|
3025
|
+
var _path$k;
|
|
3026
|
+
function _extends$l() { _extends$l = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$l.apply(this, arguments); }
|
|
3522
3027
|
var SvgActionDeleteforever18 = function SvgActionDeleteforever18(props, ref) {
|
|
3523
|
-
return /*#__PURE__*/React__namespace.createElement("svg", _extends$
|
|
3028
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$l({
|
|
3524
3029
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3525
3030
|
width: 18,
|
|
3526
3031
|
height: 18,
|
|
3527
3032
|
viewBox: "0 0 18 18",
|
|
3528
3033
|
ref: ref
|
|
3529
|
-
}, props), _path$
|
|
3034
|
+
}, props), _path$k || (_path$k = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3530
3035
|
fillRule: "evenodd",
|
|
3531
3036
|
d: "M7 2h4l1 1h3v2H3V3h3l1-1zM4 6h10v8a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6zm6.76 8.1L9 12.36 7.24 14.1l-1.16-1.16 1.74-1.76-1.78-1.8 1.2-1.18L9 10l1.76-1.8 1.18 1.18-1.76 1.8 1.76 1.76-1.18 1.16z",
|
|
3532
3037
|
clipRule: "evenodd"
|
|
3533
3038
|
})));
|
|
3534
3039
|
};
|
|
3535
|
-
var ForwardRef$
|
|
3040
|
+
var ForwardRef$l = /*#__PURE__*/React.forwardRef(SvgActionDeleteforever18);
|
|
3536
3041
|
|
|
3537
3042
|
function PresetActionsDropdown(props) {
|
|
3538
3043
|
const { uuiNotifications } = uuiCore.useUuiContext();
|
|
@@ -3569,30 +3074,30 @@ function PresetActionsDropdown(props) {
|
|
|
3569
3074
|
]);
|
|
3570
3075
|
const renderBody = () => {
|
|
3571
3076
|
const isReadonlyPreset = props.preset.isReadonly;
|
|
3572
|
-
return (React__namespace.default.createElement(Panel, { shadow: true, cx: css$
|
|
3077
|
+
return (React__namespace.default.createElement(Panel, { background: "surface", shadow: true, cx: css$w.presetDropdownPanel },
|
|
3573
3078
|
props.activePresetId === props.preset.id && props.hasPresetChanged(props.preset) && (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
3574
3079
|
!isReadonlyPreset && (React__namespace.default.createElement(FlexRow, { key: `${props.preset.id}-save-in-current` },
|
|
3575
|
-
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$
|
|
3080
|
+
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$r, caption: "Save in current", onClick: saveInCurrentHandler }))),
|
|
3576
3081
|
React__namespace.default.createElement(FlexRow, { key: `${props.preset.id}-save-as-new` },
|
|
3577
|
-
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$
|
|
3082
|
+
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$q, caption: "Save as new", onClick: props.addPreset })),
|
|
3578
3083
|
React__namespace.default.createElement(FlexRow, { key: `${props.preset.id}-discard`, borderBottom: true },
|
|
3579
|
-
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$
|
|
3084
|
+
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$p, caption: "Discard all changes", onClick: discardAllChangesHandler })))),
|
|
3580
3085
|
props.preset.id === props.activePresetId && !isReadonlyPreset && (React__namespace.default.createElement(FlexRow, { key: `${props.preset.id}-rename` },
|
|
3581
|
-
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$
|
|
3086
|
+
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$n, caption: "Rename", onClick: props.renamePreset }))),
|
|
3582
3087
|
React__namespace.default.createElement(FlexRow, { key: `${props.preset.id}-duplicate` },
|
|
3583
|
-
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$
|
|
3088
|
+
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$o, caption: "Duplicate", onClick: duplicateHandler })),
|
|
3584
3089
|
React__namespace.default.createElement(FlexRow, { borderBottom: true, key: `${props.preset.id}-copyLink` },
|
|
3585
|
-
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$
|
|
3586
|
-
!isReadonlyPreset && (React__namespace.default.createElement(FlexRow, { key: `${props.preset.id}-delete`, cx: css$
|
|
3587
|
-
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$
|
|
3090
|
+
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$m, caption: "Copy Link", onClick: copyUrlToClipboard })),
|
|
3091
|
+
!isReadonlyPreset && (React__namespace.default.createElement(FlexRow, { key: `${props.preset.id}-delete`, cx: css$w.deleteRow },
|
|
3092
|
+
React__namespace.default.createElement(DropdownMenuButton, { icon: ForwardRef$l, caption: "Delete", cx: css$w.deleteButton, onClick: deleteHandler })))));
|
|
3588
3093
|
};
|
|
3589
3094
|
const renderTarget = React.useCallback((dropdownProps) => {
|
|
3590
|
-
return (React__namespace.default.createElement(IconButton, Object.assign({ cx: dropdownProps.isOpen && css$
|
|
3095
|
+
return (React__namespace.default.createElement(IconButton, Object.assign({ cx: dropdownProps.isOpen && css$w.targetOpen, color: props.preset.id === props.activePresetId ? 'info' : 'neutral' }, dropdownProps, { icon: ForwardRef$s })));
|
|
3591
3096
|
}, []);
|
|
3592
3097
|
return (React__namespace.default.createElement(Dropdown, { renderBody: renderBody, renderTarget: renderTarget, placement: "bottom-end", modifiers: [{ name: 'offset', options: { offset: [0, 22] } }] }));
|
|
3593
3098
|
}
|
|
3594
3099
|
|
|
3595
|
-
var css$
|
|
3100
|
+
var css$v = {"preset-input-cell":"i2cLCZ","preset-input":"Qoz6fA","presetInputCell":"i2cLCZ","presetInput":"Qoz6fA"};
|
|
3596
3101
|
|
|
3597
3102
|
function PresetInput(props) {
|
|
3598
3103
|
var _a;
|
|
@@ -3613,34 +3118,703 @@ function PresetInput(props) {
|
|
|
3613
3118
|
}
|
|
3614
3119
|
props.onCancel();
|
|
3615
3120
|
}, [presetCaption.length, props.onCancel]);
|
|
3616
|
-
return (React__namespace.default.createElement(FlexCell, { cx: css$
|
|
3617
|
-
React__namespace.default.createElement(TextInput, { cx: css$
|
|
3121
|
+
return (React__namespace.default.createElement(FlexCell, { cx: css$v.presetInputCell, minWidth: 180 },
|
|
3122
|
+
React__namespace.default.createElement(TextInput, { cx: css$v.presetInput, onValueChange: setPresetCaption, value: presetCaption, onCancel: cancelActionHandler, onAccept: acceptActionHandler, onBlur: newPresetOnBlurHandler, autoFocus: true, maxLength: 50 })));
|
|
3123
|
+
}
|
|
3124
|
+
|
|
3125
|
+
var css$u = {"preset":"iEgtuN","activePreset":"-icK7o"};
|
|
3126
|
+
|
|
3127
|
+
function Preset(props) {
|
|
3128
|
+
const [isRenamePreset, setIsRenamePreset] = React.useState(false);
|
|
3129
|
+
const choosePresetHandler = React.useCallback(() => props.choosePreset(props.preset), [props]);
|
|
3130
|
+
const cancelRenamePreset = React.useCallback(() => {
|
|
3131
|
+
setIsRenamePreset(() => false);
|
|
3132
|
+
}, []);
|
|
3133
|
+
const setPresetForRename = React.useCallback(() => {
|
|
3134
|
+
if (!isRenamePreset) {
|
|
3135
|
+
setIsRenamePreset(() => true);
|
|
3136
|
+
}
|
|
3137
|
+
}, []);
|
|
3138
|
+
const handlePresetRename = React.useCallback((name) => {
|
|
3139
|
+
const newPreset = Object.assign(Object.assign({}, props.preset), { name: name });
|
|
3140
|
+
return props.updatePreset(newPreset);
|
|
3141
|
+
}, [props.preset]);
|
|
3142
|
+
const isPresetActive = props.activePresetId === props.preset.id;
|
|
3143
|
+
return (React__namespace.default.createElement(FlexCell, { key: props.preset.id, alignSelf: "center", width: "auto" }, isRenamePreset ? (React__namespace.default.createElement(PresetInput, { onCancel: cancelRenamePreset, onSuccess: handlePresetRename, preset: props.preset })) : (React__namespace.default.createElement(TabButton, { caption: props.preset.name, onClick: !isPresetActive && choosePresetHandler, cx: [css$u.preset, isPresetActive && css$u.activePreset], size: "60", withNotify: isPresetActive && props.hasPresetChanged(props.preset), icon: () => React__namespace.default.createElement(PresetActionsDropdown, Object.assign({ renamePreset: setPresetForRename }, props)), iconPosition: "right", isLinkActive: isPresetActive }))));
|
|
3144
|
+
}
|
|
3145
|
+
|
|
3146
|
+
var _path$j;
|
|
3147
|
+
function _extends$k() { _extends$k = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$k.apply(this, arguments); }
|
|
3148
|
+
var SvgContentPlusBold18 = function SvgContentPlusBold18(props, ref) {
|
|
3149
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$k({
|
|
3150
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3151
|
+
width: 18,
|
|
3152
|
+
height: 18,
|
|
3153
|
+
viewBox: "0 0 18 18",
|
|
3154
|
+
ref: ref
|
|
3155
|
+
}, props), _path$j || (_path$j = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3156
|
+
d: "M10.5 3h-3v4.5H3v3h4.5V15h3v-4.5H15v-3h-4.5V3z"
|
|
3157
|
+
})));
|
|
3158
|
+
};
|
|
3159
|
+
var ForwardRef$k = /*#__PURE__*/React.forwardRef(SvgContentPlusBold18);
|
|
3160
|
+
|
|
3161
|
+
function PresetsPanel(props) {
|
|
3162
|
+
const [isAddingPreset, setIsAddingPreset] = React.useState(false);
|
|
3163
|
+
const setAddingPreset = React.useCallback(() => {
|
|
3164
|
+
setIsAddingPreset(true);
|
|
3165
|
+
}, []);
|
|
3166
|
+
const cancelAddingPreset = React.useCallback(() => {
|
|
3167
|
+
setIsAddingPreset(false);
|
|
3168
|
+
}, []);
|
|
3169
|
+
const presetApi = __rest(props, ["presets"]);
|
|
3170
|
+
const renderPreset = (preset) => {
|
|
3171
|
+
return React__namespace.default.createElement(Preset, Object.assign({ key: preset.id, preset: preset, addPreset: setAddingPreset }, presetApi));
|
|
3172
|
+
};
|
|
3173
|
+
const renderAddPresetButton = React.useCallback(() => {
|
|
3174
|
+
return (React__namespace.default.createElement("div", { key: "addingPresetBlock", className: css$x.addPresetContainer }, !isAddingPreset ? (React__namespace.default.createElement(Button, { size: "36", onClick: setAddingPreset, caption: i18n.presetPanel.addCaption, icon: ForwardRef$k, iconPosition: "left", fill: "ghost", color: "primary" })) : (React__namespace.default.createElement(PresetInput, { onCancel: cancelAddingPreset, onSuccess: props.createNewPreset }))));
|
|
3175
|
+
}, [isAddingPreset]);
|
|
3176
|
+
const onPresetDropdownSelect = (preset) => {
|
|
3177
|
+
props.choosePreset(preset.preset);
|
|
3178
|
+
};
|
|
3179
|
+
const renderMoreButtonDropdown = (item, hiddenItems) => {
|
|
3180
|
+
return (React__namespace.default.createElement(Dropdown, { key: "more", renderTarget: (props) => (React__namespace.default.createElement(FlexRow, null,
|
|
3181
|
+
React__namespace.default.createElement("div", { className: css$x.divider }),
|
|
3182
|
+
React__namespace.default.createElement(Button, Object.assign({ fill: "ghost", color: "secondary", caption: `${(hiddenItems === null || hiddenItems === void 0 ? void 0 : hiddenItems.length) || ''} more` }, props)))), renderBody: (propsBody) => (React__namespace.default.createElement(DropdownContainer, Object.assign({ cx: uuiCore.cx(css$x.dropContainer), width: 230 }, propsBody),
|
|
3183
|
+
React__namespace.default.createElement(uuiComponents.ScrollBars, null, hiddenItems.map((hiddenItem) => (React__namespace.default.createElement(DropdownMenuButton, { key: hiddenItem.preset.id, onClick: () => onPresetDropdownSelect(hiddenItem), caption: hiddenItem.preset.name, icon: !hiddenItem.preset.isReadonly && ForwardRef$l, iconPosition: "right", cx: css$x.dropdownDeleteIcon, onIconClick: !hiddenItem.preset.isReadonly && (() => props.deletePreset(hiddenItem.preset)) })))))) }));
|
|
3184
|
+
};
|
|
3185
|
+
const getPresetPriority = (preset, index) => {
|
|
3186
|
+
return preset.id === props.activePresetId ? 100499 : 1000 - index;
|
|
3187
|
+
};
|
|
3188
|
+
const getPanelItems = () => {
|
|
3189
|
+
return [
|
|
3190
|
+
...sortBy__default.default(props.presets, (i) => i.order).map((preset, index) => ({
|
|
3191
|
+
id: preset.id.toString(),
|
|
3192
|
+
render: () => renderPreset(preset),
|
|
3193
|
+
priority: getPresetPriority(preset, index),
|
|
3194
|
+
preset: preset,
|
|
3195
|
+
})), {
|
|
3196
|
+
id: 'collapsedContainer', render: renderMoreButtonDropdown, priority: 100501, collapsedContainer: true,
|
|
3197
|
+
}, { id: 'addPreset', render: renderAddPresetButton, priority: 100501 },
|
|
3198
|
+
];
|
|
3199
|
+
};
|
|
3200
|
+
return (React__namespace.default.createElement(FlexCell, { grow: 1, minWidth: 310, rawProps: props.rawProps },
|
|
3201
|
+
React__namespace.default.createElement(FlexRow, { size: null, spacing: "12", cx: css$x.presetsWrapper },
|
|
3202
|
+
React__namespace.default.createElement(uuiComponents.AdaptivePanel, { items: getPanelItems() }))));
|
|
3203
|
+
}
|
|
3204
|
+
|
|
3205
|
+
const defaultPredicates = {
|
|
3206
|
+
numeric: [
|
|
3207
|
+
{ predicate: 'eq', name: '=', isDefault: true }, { predicate: 'neq', name: '≠' }, { predicate: 'lte', name: '≤' }, { predicate: 'gte', name: '≥' }, { predicate: 'inRange', name: 'In Range' },
|
|
3208
|
+
],
|
|
3209
|
+
multiPicker: [{ predicate: 'in', name: 'is', isDefault: true }, { predicate: 'nin', name: 'is not' }],
|
|
3210
|
+
rangeDatePicker: [{ predicate: 'inRange', name: 'In Range', isDefault: true }, { predicate: 'notInRange', name: 'Not in Range' }],
|
|
3211
|
+
};
|
|
3212
|
+
|
|
3213
|
+
const useColumnsWithFilters = (initialColumns, filters) => {
|
|
3214
|
+
const makeFilterRenderCallback = React.useCallback((key) => function (filterLens, dropdownProps) {
|
|
3215
|
+
const filter = filters.find((f) => f.columnKey === key);
|
|
3216
|
+
if (!filter)
|
|
3217
|
+
return null;
|
|
3218
|
+
const props = filterLens.prop(filter.field).toProps();
|
|
3219
|
+
return React__namespace.default.createElement(FilterItemBody, Object.assign({}, props, filter, dropdownProps));
|
|
3220
|
+
}, [filters]);
|
|
3221
|
+
const columns = React.useMemo(() => {
|
|
3222
|
+
if (filters) {
|
|
3223
|
+
const filterKeys = filters.map((f) => f.columnKey);
|
|
3224
|
+
const newColumns = (initialColumns.map((column) => {
|
|
3225
|
+
if (filterKeys.includes(column.key)) {
|
|
3226
|
+
return Object.assign(Object.assign({}, column), { renderFilter: makeFilterRenderCallback(column.key) });
|
|
3227
|
+
}
|
|
3228
|
+
else {
|
|
3229
|
+
return column;
|
|
3230
|
+
}
|
|
3231
|
+
}));
|
|
3232
|
+
return newColumns;
|
|
3233
|
+
}
|
|
3234
|
+
return initialColumns;
|
|
3235
|
+
}, [filters, initialColumns]);
|
|
3236
|
+
return columns;
|
|
3237
|
+
};
|
|
3238
|
+
|
|
3239
|
+
var css$t = {"line-height-12":"F6DzEg","line-height-18":"oyyqMR","line-height-24":"T0kOKr","line-height-30":"m6D9LL","font-size-10":"R34zuo","font-size-12":"cjNcwJ","font-size-14":"FeLlUx","font-size-16":"v-qPMi","font-size-18":"lHGTXJ","font-size-24":"yg1IyN","v-padding-2":"eUcf38","v-padding-3":"FoNV2-","v-padding-5":"FDfbov","v-padding-6":"l3AH2k","v-padding-8":"FUzQED","v-padding-9":"Frukj2","v-padding-11":"J-0fi2","v-padding-12":"zB2bEU","v-padding-14":"FgRxca","v-padding-15":"_3cHZb9","v-padding-17":"xeP2KJ","v-padding-18":"R1lerS","v-padding-23":"RvCm6l","v-padding-24":"lGKH-o","lineHeight12":"F6DzEg","lineHeight18":"oyyqMR","lineHeight24":"T0kOKr","lineHeight30":"m6D9LL","fontSize10":"R34zuo","fontSize12":"cjNcwJ","fontSize14":"FeLlUx","fontSize16":"v-qPMi","fontSize18":"lHGTXJ","fontSize24":"yg1IyN","vPadding2":"eUcf38","vPadding3":"FoNV2-","vPadding5":"FDfbov","vPadding6":"l3AH2k","vPadding8":"FUzQED","vPadding9":"Frukj2","vPadding11":"J-0fi2","vPadding12":"zB2bEU","vPadding14":"FgRxca","vPadding15":"_3cHZb9","vPadding17":"xeP2KJ","vPadding18":"R1lerS","vPadding23":"RvCm6l","vPadding24":"lGKH-o"};
|
|
3240
|
+
|
|
3241
|
+
const defaultTextSettings = {
|
|
3242
|
+
18: { lineHeight: 12, fontSize: 10 },
|
|
3243
|
+
24: { lineHeight: 18, fontSize: 12 },
|
|
3244
|
+
30: { lineHeight: 18, fontSize: 14 },
|
|
3245
|
+
36: { lineHeight: 18, fontSize: 14 },
|
|
3246
|
+
42: { lineHeight: 24, fontSize: 16 },
|
|
3247
|
+
48: { lineHeight: 24, fontSize: 16 },
|
|
3248
|
+
60: { lineHeight: 30, fontSize: 24 },
|
|
3249
|
+
};
|
|
3250
|
+
function getTextClasses(props, border) {
|
|
3251
|
+
if (props.size === 'none') {
|
|
3252
|
+
return [css$t['line-height-' + props.lineHeight], css$t['font-size-' + props.fontSize]];
|
|
3253
|
+
}
|
|
3254
|
+
const setting = {
|
|
3255
|
+
size: props.size,
|
|
3256
|
+
lineHeight: props.lineHeight || defaultTextSettings[props.size].lineHeight,
|
|
3257
|
+
fontSize: props.fontSize || defaultTextSettings[props.size].fontSize,
|
|
3258
|
+
};
|
|
3259
|
+
const vPadding = (+setting.size - +setting.lineHeight - (border ? 2 : 0)) / 2;
|
|
3260
|
+
return [
|
|
3261
|
+
css$t['line-height-' + setting.lineHeight], css$t['font-size-' + setting.fontSize], css$t['v-padding-' + vPadding],
|
|
3262
|
+
];
|
|
3263
|
+
}
|
|
3264
|
+
|
|
3265
|
+
var css$s = {"root":"_7BkxsH"};
|
|
3266
|
+
|
|
3267
|
+
const allTextColors = ['info', 'warning', 'error', 'success', 'brand', 'primary', 'secondary', 'disabled', 'contrast', 'white'];
|
|
3268
|
+
function applyTextMods(mods) {
|
|
3269
|
+
const textClasses = getTextClasses({
|
|
3270
|
+
size: mods.size || '36',
|
|
3271
|
+
lineHeight: mods.lineHeight,
|
|
3272
|
+
fontSize: mods.fontSize,
|
|
3273
|
+
}, false);
|
|
3274
|
+
return [
|
|
3275
|
+
css$s.root,
|
|
3276
|
+
'uui-text',
|
|
3277
|
+
`uui-font-${mods.font || 'regular'}`,
|
|
3278
|
+
`uui-color-${mods.color || 'primary'}`,
|
|
3279
|
+
'uui-typography',
|
|
3280
|
+
].concat(textClasses);
|
|
3281
|
+
}
|
|
3282
|
+
const Text = uuiCore.withMods(uuiComponents.Text, applyTextMods);
|
|
3283
|
+
|
|
3284
|
+
var css$r = {"root":"lzyNyI","loading-word":"BO3Hd0","animated-loading":"U2s9HK","skeleton_loading":"_1LyLbb","loadingWord":"BO3Hd0","animatedLoading":"U2s9HK","skeletonLoading":"_1LyLbb"};
|
|
3285
|
+
|
|
3286
|
+
const TextPlaceholder = (props) => {
|
|
3287
|
+
const pattern = ' ';
|
|
3288
|
+
const text = React__namespace.useMemo(() => {
|
|
3289
|
+
const words = [];
|
|
3290
|
+
for (let i = 0; i < (props.wordsCount || 1); i++) {
|
|
3291
|
+
const lengthWord = Math.floor(Math.random() * 10 + 8);
|
|
3292
|
+
words.push(pattern.repeat(lengthWord));
|
|
3293
|
+
}
|
|
3294
|
+
return words;
|
|
3295
|
+
}, [props.wordsCount]);
|
|
3296
|
+
return (React__namespace.createElement("div", Object.assign({ "aria-busy": true, className: css$r.root }, props.rawProps), text.map((it, index) => (React__namespace.createElement("span", { key: index, className: cx__default.default([
|
|
3297
|
+
props.cx, css$r.loadingWord, !props.isNotAnimated && css$r.animatedLoading,
|
|
3298
|
+
]), dangerouslySetInnerHTML: { __html: it } })))));
|
|
3299
|
+
};
|
|
3300
|
+
|
|
3301
|
+
const RichTextView = uuiCore.withMods(uuiComponents__namespace.RichTextView, (mods) => ['uui-typography', `uui-typography-${mods.size || '14'}`]);
|
|
3302
|
+
|
|
3303
|
+
var css$q = {"uui-typography":"s9JRZi","hero-header":"oD1hEz","promo-header":"ILNK4P","uui-critical":"GjsqYy","uui-success":"yHlmkp","uui-warning":"EoRjKL","uui-typography-size-12":"noq76D","uui-typography-size-14":"ShEQtL","uui-typography-size-16":"qugEHx","root":"ru-q-l","modal-blocker":"hoZlV4","animateModalBlocker":"JO6GO5","modal":"NEv2ZA","modal-footer":"opRfev","border-top":"F-lEan","modal-header":"qDHKrs","uuiTypography":"s9JRZi","heroHeader":"oD1hEz","promoHeader":"ILNK4P","uuiCritical":"GjsqYy","uuiSuccess":"yHlmkp","uuiWarning":"EoRjKL","uuiTypographySize12":"noq76D","uuiTypographySize14":"ShEQtL","uuiTypographySize16":"qugEHx","modalBlocker":"hoZlV4","modalFooter":"opRfev","borderTop":"F-lEan","modalHeader":"qDHKrs"};
|
|
3304
|
+
|
|
3305
|
+
const ModalBlocker = uuiCore.withMods(uuiComponents.ModalBlocker, () => [css$q.modalBlocker]);
|
|
3306
|
+
const ModalWindow = uuiCore.withMods(uuiComponents.ModalWindow, () => [css$q.root, css$q.modal], (props) => ({
|
|
3307
|
+
style: Object.assign(Object.assign({}, props.style), { width: `${props.width || 420}px`, height: props.height ? `${props.height}px` : 'auto' }),
|
|
3308
|
+
}));
|
|
3309
|
+
class ModalHeader extends React__namespace.Component {
|
|
3310
|
+
render() {
|
|
3311
|
+
return (React__namespace.createElement(FlexRow, { padding: this.props.padding || '24', vPadding: "12", borderBottom: this.props.borderBottom, cx: [css$q.root, css$q.modalHeader, this.props.cx], spacing: "12", rawProps: this.props.rawProps },
|
|
3312
|
+
this.props.title && (React__namespace.createElement(Text, { size: "48", fontSize: "18", font: "semibold" }, this.props.title)),
|
|
3313
|
+
this.props.children,
|
|
3314
|
+
this.props.onClose && React__namespace.createElement(uuiComponents.FlexSpacer, null),
|
|
3315
|
+
this.props.onClose && (React__namespace.createElement(FlexCell, { shrink: 0, width: "auto" },
|
|
3316
|
+
React__namespace.createElement(IconButton, { rawProps: { 'aria-label': 'Close modal' }, icon: ForwardRef$B, onClick: this.props.onClose })))));
|
|
3317
|
+
}
|
|
3318
|
+
}
|
|
3319
|
+
class ModalFooter extends React__namespace.Component {
|
|
3320
|
+
render() {
|
|
3321
|
+
return (React__namespace.createElement(FlexRow, { spacing: this.props.spacing || '12', cx: [
|
|
3322
|
+
css$q.root,
|
|
3323
|
+
css$q.modalFooter,
|
|
3324
|
+
this.props.borderTop && css$q.borderTop,
|
|
3325
|
+
this.props.cx,
|
|
3326
|
+
], padding: this.props.padding || '24', vPadding: this.props.vPadding || '24', rawProps: this.props.rawProps }, this.props.children));
|
|
3327
|
+
}
|
|
3328
|
+
}
|
|
3329
|
+
|
|
3330
|
+
var _path$i;
|
|
3331
|
+
function _extends$j() { _extends$j = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$j.apply(this, arguments); }
|
|
3332
|
+
var SvgCross = function SvgCross(props, ref) {
|
|
3333
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$j({
|
|
3334
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3335
|
+
width: 24,
|
|
3336
|
+
height: 24,
|
|
3337
|
+
viewBox: "0 0 24 24",
|
|
3338
|
+
ref: ref
|
|
3339
|
+
}, props), _path$i || (_path$i = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3340
|
+
fillRule: "evenodd",
|
|
3341
|
+
d: "M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"
|
|
3342
|
+
})));
|
|
3343
|
+
};
|
|
3344
|
+
var ForwardRef$j = /*#__PURE__*/React.forwardRef(SvgCross);
|
|
3345
|
+
|
|
3346
|
+
var css$p = {"uui-typography":"q6NfQ0","hero-header":"R30pwx","promo-header":"_1B-M3h","uui-critical":"v6t145","uui-success":"knH0tP","uui-warning":"VHUwhL","uui-typography-size-12":"_6svGWr","uui-typography-size-14":"A-NBUo","uui-typography-size-16":"Uza-pT","root":"DslK6e","icon-wrapper":"FI9e4-","action-wrapper":"WtuWmc","action-link":"KeamRH","close-icon":"tgWnQV","main-path":"UZlj7m","content":"IHjzKa","clear-button":"SjmoUk","close-wrapper":"ItriLv","uuiTypography":"q6NfQ0","heroHeader":"R30pwx","promoHeader":"_1B-M3h","uuiCritical":"v6t145","uuiSuccess":"knH0tP","uuiWarning":"VHUwhL","uuiTypographySize12":"_6svGWr","uuiTypographySize14":"A-NBUo","uuiTypographySize16":"Uza-pT","iconWrapper":"FI9e4-","actionWrapper":"WtuWmc","actionLink":"KeamRH","closeIcon":"tgWnQV","mainPath":"UZlj7m","clearButton":"SjmoUk","closeWrapper":"ItriLv"};
|
|
3347
|
+
|
|
3348
|
+
const NotificationCard = React__namespace.default.forwardRef((props, ref) => {
|
|
3349
|
+
const notificationCardNode = React__namespace.default.useRef(null);
|
|
3350
|
+
React__namespace.default.useImperativeHandle(ref, () => notificationCardNode.current, [notificationCardNode.current]);
|
|
3351
|
+
React__namespace.default.useLayoutEffect(() => {
|
|
3352
|
+
var _a, _b;
|
|
3353
|
+
(_a = notificationCardNode.current) === null || _a === void 0 ? void 0 : _a.addEventListener('mouseenter', props.clearTimer);
|
|
3354
|
+
(_b = notificationCardNode.current) === null || _b === void 0 ? void 0 : _b.addEventListener('mouseleave', props.refreshTimer);
|
|
3355
|
+
return () => {
|
|
3356
|
+
var _a, _b;
|
|
3357
|
+
(_a = notificationCardNode.current) === null || _a === void 0 ? void 0 : _a.removeEventListener('mouseenter', props.clearTimer);
|
|
3358
|
+
(_b = notificationCardNode.current) === null || _b === void 0 ? void 0 : _b.removeEventListener('mouseleave', props.refreshTimer);
|
|
3359
|
+
};
|
|
3360
|
+
}, []);
|
|
3361
|
+
return (React__namespace.default.createElement("div", Object.assign({ role: "alert", className: cx__default.default('uui-notification_card', props.color && `uui-color-${props.color}`, css$p.root, props.cx), ref: notificationCardNode }, props.rawProps),
|
|
3362
|
+
React__namespace.default.createElement("div", { className: css$p.mainPath },
|
|
3363
|
+
props.icon && (React__namespace.default.createElement("div", { className: css$p.iconWrapper },
|
|
3364
|
+
React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, cx: css$p.actionIcon }))),
|
|
3365
|
+
React__namespace.default.createElement("div", { className: css$p.content },
|
|
3366
|
+
props.children,
|
|
3367
|
+
props.actions && (React__namespace.default.createElement("div", { className: css$p.actionWrapper }, props.actions.map((action) => (React__namespace.default.createElement(LinkButton, { caption: action.name, onClick: action.action, key: action.name, cx: css$p.actionLink, size: "36", rawProps: action.rawProps })))))),
|
|
3368
|
+
props.onClose && (React__namespace.default.createElement("div", { className: css$p.closeWrapper },
|
|
3369
|
+
React__namespace.default.createElement(IconButton, { icon: ForwardRef$j, color: "neutral", onClick: props.onClose, cx: css$p.closeIcon }))))));
|
|
3370
|
+
});
|
|
3371
|
+
const WarningNotification = React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, Object.assign({ icon: ForwardRef$E, color: "warning" }, props, { ref: ref, cx: props.cx }))));
|
|
3372
|
+
const SuccessNotification = React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, Object.assign({ icon: ForwardRef$F, color: "success" }, props, { ref: ref, cx: props.cx }))));
|
|
3373
|
+
const HintNotification = React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, Object.assign({ icon: ForwardRef$C, color: "info" }, props, { ref: ref, cx: props.cx }))));
|
|
3374
|
+
const ErrorNotification = React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, Object.assign({ icon: ForwardRef$D, color: "error" }, props, { ref: ref, cx: props.cx }))));
|
|
3375
|
+
class ClearNotification extends React__namespace.default.Component {
|
|
3376
|
+
render() {
|
|
3377
|
+
return (React__namespace.default.createElement("div", { className: cx__default.default(css$p.notificationWrapper, css$p.clearButton) },
|
|
3378
|
+
React__namespace.default.createElement(LinkButton, { caption: i18n.notificationCard.closeAllNotificationsButton, onClick: () => this.context.uuiNotifications.clearAll() })));
|
|
3379
|
+
}
|
|
3618
3380
|
}
|
|
3381
|
+
ClearNotification.contextType = uuiCore.UuiContext;
|
|
3382
|
+
|
|
3383
|
+
class ConfirmationModal extends React__namespace.Component {
|
|
3384
|
+
render() {
|
|
3385
|
+
let bodyContent;
|
|
3386
|
+
if (this.props.bodyContent) {
|
|
3387
|
+
bodyContent = React__namespace.createElement(Panel, { background: "surface", margin: "24" }, this.props.bodyContent);
|
|
3388
|
+
}
|
|
3389
|
+
return (React__namespace.createElement(ModalBlocker, Object.assign({}, this.props),
|
|
3390
|
+
React__namespace.createElement(ModalWindow, { width: 420 },
|
|
3391
|
+
React__namespace.createElement(ModalHeader, { borderBottom: true, title: this.props.caption, onClose: () => this.props.abort() }),
|
|
3392
|
+
React__namespace.createElement(ScrollBars, null, bodyContent),
|
|
3393
|
+
React__namespace.createElement(ModalFooter, null,
|
|
3394
|
+
React__namespace.createElement(uuiComponents.FlexSpacer, null),
|
|
3395
|
+
this.props.hideCancelButton || (React__namespace.createElement(Button, { caption: i18n.form.modals.discardButton, onClick: () => this.props.success(false), fill: "outline", color: "secondary" })),
|
|
3396
|
+
React__namespace.createElement(Button, { caption: i18n.form.modals.saveButton, onClick: () => this.props.success(true), color: "accent" })))));
|
|
3397
|
+
}
|
|
3398
|
+
}
|
|
3399
|
+
|
|
3400
|
+
const defaultMode = exports.EditMode.FORM;
|
|
3401
|
+
class DatePicker extends uuiComponents.BaseDatePicker {
|
|
3402
|
+
constructor() {
|
|
3403
|
+
super(...arguments);
|
|
3404
|
+
this.renderInput = (props) => {
|
|
3405
|
+
var _a;
|
|
3406
|
+
if (process.env.NODE_ENV !== "production") {
|
|
3407
|
+
if (this.props.size === '48') {
|
|
3408
|
+
uuiCore.devLogger.warnAboutDeprecatedPropValue({
|
|
3409
|
+
component: 'DatePicker',
|
|
3410
|
+
propName: 'size',
|
|
3411
|
+
propValue: this.props.size,
|
|
3412
|
+
propValueUseInstead: '42',
|
|
3413
|
+
condition: () => ['48'].indexOf(this.props.size) !== -1,
|
|
3414
|
+
});
|
|
3415
|
+
}
|
|
3416
|
+
}
|
|
3417
|
+
return (React__namespace.default.createElement(TextInput, Object.assign({}, props, { onClick: null, isDropdown: false, cx: uuiCore.cx(this.props.inputCx, this.state.isOpen && uuiCore.uuiMod.focus), icon: this.props.mode !== exports.EditMode.CELL && systemIcons[this.props.size || '36'].calendar, iconPosition: this.props.iconPosition || 'left', placeholder: this.props.placeholder ? this.props.placeholder : this.getFormat(), size: this.props.size || '36', value: this.state.inputValue, onValueChange: this.handleInputChange, onCancel: this.props.disableClear || !this.state.inputValue ? undefined : this.handleCancel, isInvalid: this.props.isInvalid, isDisabled: this.props.isDisabled, isReadonly: this.props.isReadonly, tabIndex: this.props.isReadonly || this.props.isDisabled ? -1 : 0, onFocus: this.handleFocus, onBlur: this.handleBlur, mode: this.props.mode || defaultMode, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.input })));
|
|
3418
|
+
};
|
|
3419
|
+
}
|
|
3420
|
+
renderBody(props) {
|
|
3421
|
+
var _a, _b, _c;
|
|
3422
|
+
return (React__namespace.default.createElement(DropdownContainer, Object.assign({}, props, { focusLock: false }),
|
|
3423
|
+
React__namespace.default.createElement(DatePickerBody, { cx: uuiCore.cx(this.props.bodyCx), filter: this.props.filter, value: this.getValue(), setSelectedDate: this.setSelectedDate, setDisplayedDateAndView: this.setDisplayedDateAndView, changeIsOpen: this.onToggle, renderDay: this.props.renderDay, isHoliday: this.props.isHoliday, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.body }), (_c = (_b = this.props).renderFooter) === null || _c === void 0 ? void 0 :
|
|
3424
|
+
_c.call(_b)));
|
|
3425
|
+
}
|
|
3426
|
+
}
|
|
3427
|
+
|
|
3428
|
+
var css$o = {"uui-typography":"cmyYUq","hero-header":"XD2Lnr","promo-header":"rAU9RV","uui-critical":"SN-nbq","uui-success":"-lxNp1","uui-warning":"mGza-n","uui-typography-size-12":"_4ktGBT","uui-typography-size-14":"TR7S7Y","uui-typography-size-16":"rFGjYq","root":"fwZgDA","uuiTypography":"cmyYUq","heroHeader":"XD2Lnr","promoHeader":"rAU9RV","uuiCritical":"SN-nbq","uuiSuccess":"-lxNp1","uuiWarning":"mGza-n","uuiTypographySize12":"_4ktGBT","uuiTypographySize14":"TR7S7Y","uuiTypographySize16":"rFGjYq"};
|
|
3429
|
+
|
|
3430
|
+
function applyCalendarPresetsMods() {
|
|
3431
|
+
return [css$o.root];
|
|
3432
|
+
}
|
|
3433
|
+
const CalendarPresets = uuiCore.withMods(uuiComponents.CalendarPresets, applyCalendarPresetsMods, () => ({}));
|
|
3434
|
+
|
|
3435
|
+
var css$n = {"uui-typography":"MsL1jX","hero-header":"oRs3KW","promo-header":"Llb9mG","uui-critical":"FX8dEU","uui-success":"_4wS15D","uui-warning":"_4XKWle","uui-typography-size-12":"lLZgGK","uui-typography-size-14":"RD6Dtj","uui-typography-size-16":"OyoFet","root":"fI3Pfl","container":"_1l-DYR","day-selection":"UGLsuF","from-picker":"aVMvjD","to-picker":"_0pSvSV","bodes-wrapper":"CbyPVT","blocker":"uv9Awt","uuiTypography":"MsL1jX","heroHeader":"oRs3KW","promoHeader":"Llb9mG","uuiCritical":"FX8dEU","uuiSuccess":"_4wS15D","uuiWarning":"_4XKWle","uuiTypographySize12":"lLZgGK","uuiTypographySize14":"RD6Dtj","uuiTypographySize16":"OyoFet","daySelection":"UGLsuF","fromPicker":"aVMvjD","toPicker":"_0pSvSV","bodesWrapper":"CbyPVT"};
|
|
3436
|
+
|
|
3437
|
+
dayjs__default.default.extend(isoWeek__default.default);
|
|
3438
|
+
function weekCount(displayedDate) {
|
|
3439
|
+
let days = [];
|
|
3440
|
+
const dayOfLastWeekInPrevMonth = displayedDate.subtract(1, 'month').endOf('month').day();
|
|
3441
|
+
days = days.concat(new Array(dayOfLastWeekInPrevMonth).fill(undefined));
|
|
3442
|
+
// get days of current month
|
|
3443
|
+
days = days.concat(new Array(displayedDate.endOf('month').date()).fill(undefined));
|
|
3444
|
+
return uuiCore.arrayToMatrix(days, 7).length;
|
|
3445
|
+
}
|
|
3446
|
+
const uuiRangeDatePickerBody = {
|
|
3447
|
+
inRange: 'uui-range-datepicker-in-range',
|
|
3448
|
+
firstDayInRangeWrapper: 'uui-range-datepicker-first-day-in-range-wrapper',
|
|
3449
|
+
lastDayInRangeWrapper: 'uui-range-datepicker-last-day-in-range-wrapper',
|
|
3450
|
+
separator: 'uui-range-datepicker-separator',
|
|
3451
|
+
};
|
|
3452
|
+
const rangeDatePickerPresets = {
|
|
3453
|
+
today: {
|
|
3454
|
+
name: 'Today',
|
|
3455
|
+
getRange: () => ({ from: dayjs__default.default().toString(), to: undefined, order: 1 }),
|
|
3456
|
+
},
|
|
3457
|
+
thisWeek: {
|
|
3458
|
+
name: 'This Week',
|
|
3459
|
+
getRange: () => ({ from: dayjs__default.default().startOf('isoWeek').toString(), to: dayjs__default.default().endOf('isoWeek').toString(), order: 2 }),
|
|
3460
|
+
},
|
|
3461
|
+
lastWeek: {
|
|
3462
|
+
name: 'Last Week',
|
|
3463
|
+
getRange: () => ({ from: dayjs__default.default().startOf('isoWeek').subtract(1, 'week').toString(), to: dayjs__default.default().endOf('isoWeek').subtract(1, 'week').toString(), order: 3 }),
|
|
3464
|
+
},
|
|
3465
|
+
thisMonth: {
|
|
3466
|
+
name: 'This Month',
|
|
3467
|
+
getRange: () => ({ from: dayjs__default.default().startOf('month').toString(), to: dayjs__default.default().endOf('month').toString(), order: 4 }),
|
|
3468
|
+
},
|
|
3469
|
+
lastMonth: {
|
|
3470
|
+
name: 'Last Month',
|
|
3471
|
+
getRange: () => ({ from: dayjs__default.default().startOf('month').subtract(1, 'month').toString(), to: dayjs__default.default().subtract(1, 'month').endOf('month').toString(), order: 5 }),
|
|
3472
|
+
},
|
|
3473
|
+
last3Month: {
|
|
3474
|
+
name: 'Last 3 Months',
|
|
3475
|
+
getRange: () => ({ from: dayjs__default.default().startOf('month').subtract(3, 'month').toString(), to: dayjs__default.default().subtract(1, 'month').endOf('month').toString(), order: 5 }),
|
|
3476
|
+
},
|
|
3477
|
+
thisYear: {
|
|
3478
|
+
name: 'This Year',
|
|
3479
|
+
getRange: () => ({ from: dayjs__default.default().startOf('year').toString(), to: dayjs__default.default().endOf('year').toString(), order: 7 }),
|
|
3480
|
+
},
|
|
3481
|
+
lastYear: {
|
|
3482
|
+
name: 'Last Year',
|
|
3483
|
+
getRange: () => ({ from: dayjs__default.default().startOf('year').subtract(1, 'year').toString(), to: dayjs__default.default().subtract(1, 'year').endOf('year').toString(), order: 8 }),
|
|
3484
|
+
},
|
|
3485
|
+
};
|
|
3486
|
+
class RangeDatePickerBody extends React__namespace.Component {
|
|
3487
|
+
constructor() {
|
|
3488
|
+
super(...arguments);
|
|
3489
|
+
this.state = {
|
|
3490
|
+
activePart: null,
|
|
3491
|
+
};
|
|
3492
|
+
this.getDayCX = (day) => {
|
|
3493
|
+
var _a, _b;
|
|
3494
|
+
const dayValue = day.valueOf();
|
|
3495
|
+
const fromValue = ((_a = this.props.value) === null || _a === void 0 ? void 0 : _a.selectedDate.from) ? dayjs__default.default(this.props.value.selectedDate.from).valueOf() : null;
|
|
3496
|
+
const toValue = ((_b = this.props.value) === null || _b === void 0 ? void 0 : _b.selectedDate.to) ? dayjs__default.default(this.props.value.selectedDate.to).valueOf() : null;
|
|
3497
|
+
const inRange = dayValue >= fromValue && dayValue <= toValue && fromValue !== toValue && fromValue && toValue;
|
|
3498
|
+
const isFirst = dayValue === fromValue;
|
|
3499
|
+
const isLast = dayValue === toValue;
|
|
3500
|
+
return [
|
|
3501
|
+
inRange && uuiRangeDatePickerBody.inRange,
|
|
3502
|
+
isFirst && uuiRangeDatePickerBody.firstDayInRangeWrapper,
|
|
3503
|
+
!inRange && isFirst && uuiRangeDatePickerBody.lastDayInRangeWrapper,
|
|
3504
|
+
isLast && uuiRangeDatePickerBody.lastDayInRangeWrapper,
|
|
3505
|
+
!inRange && isLast && uuiRangeDatePickerBody.firstDayInRangeWrapper,
|
|
3506
|
+
(dayValue === fromValue || dayValue === toValue) && uuiComponents.uuiDaySelection.selectedDay,
|
|
3507
|
+
];
|
|
3508
|
+
};
|
|
3509
|
+
this.getFromValue = () => {
|
|
3510
|
+
var _a;
|
|
3511
|
+
return Object.assign(Object.assign({}, this.props.value), { view: this.state.activePart === 'from' ? this.props.value.view : 'DAY_SELECTION', selectedDate: (_a = this.props.value) === null || _a === void 0 ? void 0 : _a.selectedDate.from });
|
|
3512
|
+
};
|
|
3513
|
+
this.getToValue = () => {
|
|
3514
|
+
if (!this.props.value)
|
|
3515
|
+
return;
|
|
3516
|
+
return Object.assign(Object.assign({}, this.props.value), { view: this.state.activePart === 'to' ? this.props.value.view : 'DAY_SELECTION', displayedDate: this.props.value.displayedDate.add(1, 'month'), selectedDate: this.props.value.selectedDate.to });
|
|
3517
|
+
};
|
|
3518
|
+
this.renderPresets = () => {
|
|
3519
|
+
return (React__namespace.createElement(React__namespace.Fragment, null,
|
|
3520
|
+
React__namespace.createElement("div", { className: uuiRangeDatePickerBody.separator }),
|
|
3521
|
+
React__namespace.createElement(CalendarPresets, { forwardedRef: this.props.forwardedRef, onPresetSet: (presetVal) => {
|
|
3522
|
+
this.props.onValueChange({
|
|
3523
|
+
view: 'DAY_SELECTION',
|
|
3524
|
+
selectedDate: { from: dayjs__default.default(presetVal.from).format(uuiComponents.valueFormat), to: dayjs__default.default(presetVal.to).format(uuiComponents.valueFormat) },
|
|
3525
|
+
displayedDate: dayjs__default.default(presetVal.from),
|
|
3526
|
+
});
|
|
3527
|
+
this.props.changeIsOpen(false);
|
|
3528
|
+
}, presets: this.props.presets })));
|
|
3529
|
+
};
|
|
3530
|
+
this.renderDatePicker = () => {
|
|
3531
|
+
var _a, _b;
|
|
3532
|
+
return (React__namespace.createElement(FlexRow, { cx: [((_a = this.props.value) === null || _a === void 0 ? void 0 : _a.view) === 'DAY_SELECTION' && css$n.daySelection, css$n.container], alignItems: "top" },
|
|
3533
|
+
React__namespace.createElement(FlexCell, { width: "auto" },
|
|
3534
|
+
React__namespace.createElement(FlexRow, null,
|
|
3535
|
+
React__namespace.createElement(FlexRow, { cx: css$n.bodesWrapper, alignItems: "top" },
|
|
3536
|
+
React__namespace.createElement(DatePickerBody, { cx: uuiCore.cx(css$n.fromPicker), setSelectedDate: (nv) => this.setSelectedDate(nv), value: this.getFromValue(), setDisplayedDateAndView: (displayedDate, view) => this.setDisplayedDateAndView(displayedDate, view, 'from'), getDayCX: this.getDayCX, filter: this.props.filter, renderDay: this.props.renderDay, isHoliday: this.props.isHoliday }),
|
|
3537
|
+
React__namespace.createElement(DatePickerBody, { cx: uuiCore.cx(css$n.toPicker), setSelectedDate: (nv) => this.setSelectedDate(nv), value: this.getToValue(), setDisplayedDateAndView: (displayedDate, view) => this.setDisplayedDateAndView(displayedDate, view, 'to'), getDayCX: this.getDayCX, filter: this.props.filter, renderDay: this.props.renderDay, isHoliday: this.props.isHoliday }),
|
|
3538
|
+
((_b = this.props.value) === null || _b === void 0 ? void 0 : _b.view) !== 'DAY_SELECTION' && (React__namespace.createElement("div", { style: {
|
|
3539
|
+
left: this.state.activePart === 'from' && '50%',
|
|
3540
|
+
right: this.state.activePart === 'to' && '50%',
|
|
3541
|
+
}, className: css$n.blocker }))),
|
|
3542
|
+
this.props.presets && this.renderPresets()),
|
|
3543
|
+
this.props.renderFooter && this.props.renderFooter())));
|
|
3544
|
+
};
|
|
3545
|
+
}
|
|
3546
|
+
getRange(selectedDate) {
|
|
3547
|
+
const newRange = { from: null, to: null };
|
|
3548
|
+
const currentRange = this.props.value.selectedDate;
|
|
3549
|
+
if (!this.props.filter || this.props.filter(dayjs__default.default(selectedDate))) {
|
|
3550
|
+
if (this.props.focusPart === 'from') {
|
|
3551
|
+
if (dayjs__default.default(selectedDate).valueOf() <= dayjs__default.default(currentRange.to).valueOf()) {
|
|
3552
|
+
newRange.from = selectedDate;
|
|
3553
|
+
newRange.to = currentRange.to;
|
|
3554
|
+
}
|
|
3555
|
+
else {
|
|
3556
|
+
newRange.from = selectedDate;
|
|
3557
|
+
newRange.to = null;
|
|
3558
|
+
}
|
|
3559
|
+
}
|
|
3560
|
+
if (this.props.focusPart === 'to') {
|
|
3561
|
+
if (!currentRange.from) {
|
|
3562
|
+
newRange.to = selectedDate;
|
|
3563
|
+
}
|
|
3564
|
+
else if (dayjs__default.default(selectedDate).valueOf() >= dayjs__default.default(currentRange.from).valueOf()) {
|
|
3565
|
+
newRange.from = currentRange.from;
|
|
3566
|
+
newRange.to = selectedDate;
|
|
3567
|
+
}
|
|
3568
|
+
else {
|
|
3569
|
+
newRange.from = selectedDate;
|
|
3570
|
+
newRange.to = null;
|
|
3571
|
+
}
|
|
3572
|
+
}
|
|
3573
|
+
}
|
|
3574
|
+
return newRange;
|
|
3575
|
+
}
|
|
3576
|
+
setSelectedDate(selectedDate) {
|
|
3577
|
+
const range = this.getRange(selectedDate);
|
|
3578
|
+
this.props.onValueChange(Object.assign(Object.assign({}, this.props.value), { selectedDate: range }));
|
|
3579
|
+
if (range.from && range.to && this.props.focusPart === 'to') {
|
|
3580
|
+
this.props.changeIsOpen(false);
|
|
3581
|
+
}
|
|
3582
|
+
}
|
|
3583
|
+
setDisplayedDateAndView(displayedDate, view, part) {
|
|
3584
|
+
this.setState({ activePart: part });
|
|
3585
|
+
this.props.onValueChange({
|
|
3586
|
+
selectedDate: this.props.value.selectedDate,
|
|
3587
|
+
displayedDate: part === 'from' ? displayedDate : displayedDate.subtract(1, 'month'),
|
|
3588
|
+
view: view,
|
|
3589
|
+
});
|
|
3590
|
+
}
|
|
3591
|
+
render() {
|
|
3592
|
+
return (React__namespace.createElement("div", Object.assign({ className: uuiCore.cx(css$n.root, uuiComponents.uuiDatePickerBodyBase.container, this.props.cx) }, this.props.rawProps), this.renderDatePicker()));
|
|
3593
|
+
}
|
|
3594
|
+
}
|
|
3595
|
+
|
|
3596
|
+
var css$m = {"uui-typography":"enP0Cu","hero-header":"CT36Eg","promo-header":"jduQns","uui-critical":"_0IKd4B","uui-success":"BmjzdB","uui-warning":"gl4w2P","uui-typography-size-12":"ErDlAZ","uui-typography-size-14":"WxZvXh","uui-typography-size-16":"_8AHOcE","dropdown-container":"BoyMPe","date-input":"B1GGdM","size-24":"PFj06b","size-30":"ml9Nfj","size-36":"MA2E8c","size-42":"c-62ZO","size-48":"j8NkyE","date-input-group":"_62pONb","separator":"gEjJ8b","mode-form":"cFcYXw","mode-cell":"_2KDLNQ","uuiTypography":"enP0Cu","heroHeader":"CT36Eg","promoHeader":"jduQns","uuiCritical":"_0IKd4B","uuiSuccess":"BmjzdB","uuiWarning":"gl4w2P","uuiTypographySize12":"ErDlAZ","uuiTypographySize14":"WxZvXh","uuiTypographySize16":"_8AHOcE","dropdownContainer":"BoyMPe","dateInput":"B1GGdM","size24":"PFj06b","size30":"ml9Nfj","size36":"MA2E8c","size42":"c-62ZO","size48":"j8NkyE","dateInputGroup":"_62pONb","modeForm":"cFcYXw","modeCell":"_2KDLNQ"};
|
|
3597
|
+
|
|
3598
|
+
const defaultValue = { from: null, to: null };
|
|
3599
|
+
class RangeDatePicker extends uuiComponents.BaseRangeDatePicker {
|
|
3600
|
+
constructor() {
|
|
3601
|
+
super(...arguments);
|
|
3602
|
+
this.renderInput = (props) => {
|
|
3603
|
+
var _a, _b;
|
|
3604
|
+
if (process.env.NODE_ENV !== "production") {
|
|
3605
|
+
if (this.props.size === '48') {
|
|
3606
|
+
uuiCore.devLogger.warnAboutDeprecatedPropValue({
|
|
3607
|
+
component: 'RangeDatePicker',
|
|
3608
|
+
propName: 'size',
|
|
3609
|
+
propValue: this.props.size,
|
|
3610
|
+
propValueUseInstead: '42',
|
|
3611
|
+
condition: () => ['48'].indexOf(this.props.size) !== -1,
|
|
3612
|
+
});
|
|
3613
|
+
}
|
|
3614
|
+
}
|
|
3615
|
+
return (React__namespace.createElement("div", { className: cx__default.default(this.props.inputCx, css$m.dateInputGroup, this.props.isDisabled && uuiCore.uuiMod.disabled, this.props.isReadonly && uuiCore.uuiMod.readonly, this.props.isInvalid && uuiCore.uuiMod.invalid, this.state.inFocus && uuiCore.uuiMod.focus), onClick: !this.props.isDisabled && props.onClick, onBlur: this.handleWrapperBlur, ref: props.ref },
|
|
3616
|
+
React__namespace.createElement(TextInput, { icon: systemIcons[this.props.size || '36'].calendar, cx: cx__default.default(css$m.dateInput, css$m['size-' + (this.props.size || 36)], this.state.inFocus === 'from' && uuiCore.uuiMod.focus), size: this.props.size || '36', placeholder: this.props.getPlaceholder ? this.props.getPlaceholder('from') : i18n.rangeDatePicker.pickerPlaceholderFrom, value: this.state.inputValue.from, onValueChange: this.getChangeHandler('from'), isInvalid: this.props.isInvalid, isDisabled: this.props.isDisabled, isReadonly: this.props.isReadonly, onFocus: (event) => this.handleFocus(event, 'from'), onBlur: (event) => this.handleBlur(event, 'from'), isDropdown: false, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.from }),
|
|
3617
|
+
React__namespace.createElement("div", { className: css$m.separator }),
|
|
3618
|
+
React__namespace.createElement(TextInput, { cx: cx__default.default(css$m.dateInput, css$m['size-' + (this.props.size || 36)], this.state.inFocus === 'to' && uuiCore.uuiMod.focus), placeholder: this.props.getPlaceholder ? this.props.getPlaceholder('to') : i18n.rangeDatePicker.pickerPlaceholderTo, size: this.props.size || '36', value: this.state.inputValue.to, onCancel: this.props.disableClear ? null : this.state.inputValue.from && this.state.inputValue.to && this.handleCancel, onValueChange: this.getChangeHandler('to'), isInvalid: this.props.isInvalid, isDisabled: this.props.isDisabled, isReadonly: this.props.isReadonly, onFocus: (e) => this.handleFocus(e, 'to'), onBlur: (e) => this.handleBlur(e, 'to'), isDropdown: false, rawProps: (_b = this.props.rawProps) === null || _b === void 0 ? void 0 : _b.to })));
|
|
3619
|
+
};
|
|
3620
|
+
}
|
|
3621
|
+
renderBody(props) {
|
|
3622
|
+
var _a;
|
|
3623
|
+
return (React__namespace.createElement(DropdownContainer, Object.assign({}, props, { cx: cx__default.default(css$m.dropdownContainer), focusLock: false }),
|
|
3624
|
+
React__namespace.createElement(FlexRow, null,
|
|
3625
|
+
React__namespace.createElement(RangeDatePickerBody, { cx: cx__default.default(this.props.bodyCx), value: this.getValue(), onValueChange: this.onRangeChange, filter: this.props.filter, changeIsOpen: this.toggleOpening, presets: this.props.presets, focusPart: this.state.inFocus, renderDay: this.props.renderDay, renderFooter: this.props.renderFooter && (() => this.props.renderFooter(this.props.value || defaultValue)), isHoliday: this.props.isHoliday, rawProps: (_a = this.props.rawProps) === null || _a === void 0 ? void 0 : _a.body }))));
|
|
3626
|
+
}
|
|
3627
|
+
}
|
|
3628
|
+
|
|
3629
|
+
var css$l = {"root":"_3p1pGk","blocker":"w74-e3","marker":"_5CuHoQ","top":"yfvdhy","bottom":"pBeRuf","left":"kjzxkZ","right":"N63-QQ","inside":"BE8g8-"};
|
|
3630
|
+
|
|
3631
|
+
function DropMarker(props) {
|
|
3632
|
+
return props.isDndInProgress
|
|
3633
|
+
? (React__namespace.createElement(React__namespace.Fragment, null,
|
|
3634
|
+
props.enableBlocker && React__namespace.createElement("div", { className: css$l.blocker }),
|
|
3635
|
+
React__namespace.createElement("div", { className: cx__default.default([
|
|
3636
|
+
css$l.root,
|
|
3637
|
+
css$l.marker,
|
|
3638
|
+
css$l[props.position],
|
|
3639
|
+
props === null || props === void 0 ? void 0 : props.cx,
|
|
3640
|
+
]) })))
|
|
3641
|
+
: null;
|
|
3642
|
+
}
|
|
3643
|
+
|
|
3644
|
+
var css$k = {"uui-typography":"-h6Hna","hero-header":"iEd6Y5","promo-header":"_36ljoJ","uui-critical":"_9L-kcw","uui-success":"wIowgP","uui-warning":"_0QwH9R","uui-typography-size-12":"tAA0m4","uui-typography-size-14":"e98mVu","uui-typography-size-16":"K1qkJB","root":"_8fEVsn","size-24":"teJnoy","size-30":"i6nx0c","size-36":"XbBtbP","size-48":"s70bhL","size-60":"-IibNH","uuiTypography":"-h6Hna","heroHeader":"iEd6Y5","promoHeader":"_36ljoJ","uuiCritical":"_9L-kcw","uuiSuccess":"wIowgP","uuiWarning":"_0QwH9R","uuiTypographySize12":"tAA0m4","uuiTypographySize14":"e98mVu","uuiTypographySize16":"K1qkJB","size24":"teJnoy","size30":"i6nx0c","size36":"XbBtbP","size48":"s70bhL","size60":"-IibNH"};
|
|
3645
|
+
|
|
3646
|
+
// Here we define a single instance of the renderCell function to make DataTableRow#shouldComponentUpdate work.
|
|
3647
|
+
// As we need our mods to style the cell properly, we extract them from DataTableCellProps.rowProps, which is a hack, but it's reliable enough.
|
|
3648
|
+
const renderCell = (props) => {
|
|
3649
|
+
const mods = props.rowProps;
|
|
3650
|
+
return React__namespace.createElement(DataTableCell, Object.assign({ size: mods.size }, props));
|
|
3651
|
+
};
|
|
3652
|
+
const renderDropMarkers = (props) => React__namespace.createElement(DropMarker, Object.assign({}, props, { enableBlocker: true }));
|
|
3653
|
+
const propsMods = { renderCell, renderDropMarkers };
|
|
3654
|
+
const DataTableRow = uuiCore.withMods(uuiComponents.DataTableRow, ({ borderBottom = true, size }) => {
|
|
3655
|
+
return [
|
|
3656
|
+
css$k.root, 'uui-dt-vars', borderBottom && 'uui-dt-row-border', css$k['size-' + (size || '36')],
|
|
3657
|
+
];
|
|
3658
|
+
}, () => propsMods);
|
|
3659
|
+
|
|
3660
|
+
var css$j = {"uui-typography":"ufHP0i","hero-header":"DP1cuv","promo-header":"OLk4Zj","uui-critical":"BQIiXc","uui-success":"Pfc3VS","uui-warning":"tfNe1I","uui-typography-size-12":"vVDxew","uui-typography-size-14":"aqr7aT","uui-typography-size-16":"_4KI3PY","sorting-panel-container":"l-7WbX","sort-active":"u-4ib4","uuiTypography":"ufHP0i","heroHeader":"DP1cuv","promoHeader":"OLk4Zj","uuiCritical":"BQIiXc","uuiSuccess":"Pfc3VS","uuiWarning":"tfNe1I","uuiTypographySize12":"vVDxew","uuiTypographySize14":"aqr7aT","uuiTypographySize16":"_4KI3PY","sortingPanelContainer":"l-7WbX","sortActive":"u-4ib4"};
|
|
3661
|
+
|
|
3662
|
+
var _path$h;
|
|
3663
|
+
function _extends$i() { _extends$i = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$i.apply(this, arguments); }
|
|
3664
|
+
var SvgTableSortAsc18 = function SvgTableSortAsc18(props, ref) {
|
|
3665
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$i({
|
|
3666
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3667
|
+
width: 18,
|
|
3668
|
+
height: 18,
|
|
3669
|
+
viewBox: "0 0 18 18",
|
|
3670
|
+
ref: ref
|
|
3671
|
+
}, props), _path$h || (_path$h = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3672
|
+
fillRule: "evenodd",
|
|
3673
|
+
d: "M10 6v10H8V6H5l4-4 4 4h-3z",
|
|
3674
|
+
clipRule: "evenodd"
|
|
3675
|
+
})));
|
|
3676
|
+
};
|
|
3677
|
+
var ForwardRef$i = /*#__PURE__*/React.forwardRef(SvgTableSortAsc18);
|
|
3678
|
+
|
|
3679
|
+
var _path$g;
|
|
3680
|
+
function _extends$h() { _extends$h = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$h.apply(this, arguments); }
|
|
3681
|
+
var SvgTableSortDesc18 = function SvgTableSortDesc18(props, ref) {
|
|
3682
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$h({
|
|
3683
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3684
|
+
width: 18,
|
|
3685
|
+
height: 18,
|
|
3686
|
+
viewBox: "0 0 18 18",
|
|
3687
|
+
ref: ref
|
|
3688
|
+
}, props), _path$g || (_path$g = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3689
|
+
fillRule: "evenodd",
|
|
3690
|
+
d: "M10 12V2H8v10H5l4 4 4-4h-3z",
|
|
3691
|
+
clipRule: "evenodd"
|
|
3692
|
+
})));
|
|
3693
|
+
};
|
|
3694
|
+
var ForwardRef$h = /*#__PURE__*/React.forwardRef(SvgTableSortDesc18);
|
|
3695
|
+
|
|
3696
|
+
const SortingPanelImpl = ({ sortDirection, onSort }) => {
|
|
3697
|
+
const sortAsc = React.useCallback(() => onSort(sortDirection === 'asc' ? undefined : 'asc'), [onSort]);
|
|
3698
|
+
const sortDesc = React.useCallback(() => onSort(sortDirection === 'desc' ? undefined : 'desc'), [onSort]);
|
|
3699
|
+
return (React__namespace.default.createElement(FlexCell, { cx: css$j.sortingPanelContainer },
|
|
3700
|
+
React__namespace.default.createElement(DropdownMenuButton, { isActive: sortDirection === 'asc', caption: i18n.pickerFilterHeader.sortAscending, icon: ForwardRef$i, onClick: sortAsc }),
|
|
3701
|
+
React__namespace.default.createElement(DropdownMenuButton, { isActive: sortDirection === 'desc', caption: i18n.pickerFilterHeader.sortDescending, icon: ForwardRef$h, onClick: sortDesc })));
|
|
3702
|
+
};
|
|
3703
|
+
const SortingPanel = React__namespace.default.memo(SortingPanelImpl);
|
|
3704
|
+
|
|
3705
|
+
const ColumnHeaderDropdownImpl = (props) => {
|
|
3706
|
+
const popperModifiers = React.useMemo(() => [
|
|
3707
|
+
{
|
|
3708
|
+
name: 'offset',
|
|
3709
|
+
options: { offset: [0, 1] },
|
|
3710
|
+
}, uuiCore.mobilePopperModifier,
|
|
3711
|
+
], []);
|
|
3712
|
+
const closeDropdown = React.useCallback(() => props.onOpenChange(false), [props.onOpenChange]);
|
|
3713
|
+
return (React__namespace.default.createElement(uuiComponents.Dropdown, { renderTarget: props.renderTarget, renderBody: (dropdownProps) => (React__namespace.default.createElement(MobileDropdownWrapper, { width: 280, title: props.title, onClose: closeDropdown },
|
|
3714
|
+
props.isSortable && React__namespace.default.createElement(SortingPanel, { sortDirection: props.sortDirection, onSort: props.onSort }),
|
|
3715
|
+
props.renderFilter(dropdownProps))), modifiers: popperModifiers, value: props.isOpen, onValueChange: props.onOpenChange }));
|
|
3716
|
+
};
|
|
3717
|
+
const ColumnHeaderDropdown = React__namespace.default.memo(ColumnHeaderDropdownImpl);
|
|
3718
|
+
|
|
3719
|
+
var css$i = {"uui-typography":"h9Elw1","hero-header":"KuX3vz","promo-header":"XChwxb","uui-critical":"IDZokF","uui-success":"UF-AwT","uui-warning":"PoSu5h","uui-typography-size-12":"zK0gQN","uui-typography-size-14":"_82INF7","uui-typography-size-16":"YngUrS","cell":"_-5iF8R","sort-icon":"CyYdV3","dropdown-icon":"Mq-Zhu","infoIcon":"YBVXK0","resizable":"w2rhDv","size-24":"jb9MMP","size-30":"lzFws9","size-36":"doj-5E","size-42":"FBCuvZ","size-48":"Pk-wsu","padding-left-24":"_7l09qi","padding-right-24":"zuMbo0","caption":"ptt-nB","checkbox":"CrPhzZ","icon":"dhzdx-","icon-cell":"CG26Hu","align-right":"nawuBl","align-center":"G27nhA","tooltip-wrapper":"YrRtRq","cell-tooltip":"OSwCmB","upper-case":"euPtPs","font-size-14":"KJM13X","resize-mark":"CJhltt","draggable":"WeRhp1","ghost":"MGoNSs","is-dragged-out":"shKdYt","dnd-marker-left":"ygvd8C","dnd-marker-right":"VEr0Hf","cell-tooltip-wrapper":"NvWccK","cell-tooltip-text":"_8MIDUh","uuiTypography":"h9Elw1","heroHeader":"KuX3vz","promoHeader":"XChwxb","uuiCritical":"IDZokF","uuiSuccess":"UF-AwT","uuiWarning":"PoSu5h","uuiTypographySize12":"zK0gQN","uuiTypographySize14":"_82INF7","uuiTypographySize16":"YngUrS","sortIcon":"CyYdV3","dropdownIcon":"Mq-Zhu","size24":"jb9MMP","size30":"lzFws9","size36":"doj-5E","size42":"FBCuvZ","size48":"Pk-wsu","paddingLeft24":"_7l09qi","paddingRight24":"zuMbo0","iconCell":"CG26Hu","alignRight":"nawuBl","alignCenter":"G27nhA","tooltipWrapper":"YrRtRq","cellTooltip":"OSwCmB","upperCase":"euPtPs","fontSize14":"KJM13X","resizeMark":"CJhltt","isDraggedOut":"shKdYt","dndMarkerLeft":"ygvd8C","dndMarkerRight":"VEr0Hf","cellTooltipWrapper":"NvWccK","cellTooltipText":"_8MIDUh"};
|
|
3720
|
+
|
|
3721
|
+
var _path$f;
|
|
3722
|
+
function _extends$g() { _extends$g = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$g.apply(this, arguments); }
|
|
3723
|
+
var SvgTableSwap18 = function SvgTableSwap18(props, ref) {
|
|
3724
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$g({
|
|
3725
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3726
|
+
width: 18,
|
|
3727
|
+
height: 18,
|
|
3728
|
+
viewBox: "0 0 18 18",
|
|
3729
|
+
ref: ref
|
|
3730
|
+
}, props), _path$f || (_path$f = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3731
|
+
fillRule: "evenodd",
|
|
3732
|
+
d: "M6 1 2 5h3v7h2V5h3L6 1zm7 12V6h-2v7H8l4 4 4-4h-3z",
|
|
3733
|
+
clipRule: "evenodd"
|
|
3734
|
+
})));
|
|
3735
|
+
};
|
|
3736
|
+
var ForwardRef$g = /*#__PURE__*/React.forwardRef(SvgTableSwap18);
|
|
3619
3737
|
|
|
3620
|
-
var
|
|
3738
|
+
var _path$e;
|
|
3739
|
+
function _extends$f() { _extends$f = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$f.apply(this, arguments); }
|
|
3740
|
+
var SvgContentFiltration18 = function SvgContentFiltration18(props, ref) {
|
|
3741
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$f({
|
|
3742
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3743
|
+
width: 18,
|
|
3744
|
+
height: 18,
|
|
3745
|
+
viewBox: "0 0 18 18",
|
|
3746
|
+
ref: ref
|
|
3747
|
+
}, props), _path$e || (_path$e = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3748
|
+
fillRule: "evenodd",
|
|
3749
|
+
d: "m8 14 2 2v-5H8v3zM2 3v2h14V3H2zm6 8h2l6-6H2l6 6z",
|
|
3750
|
+
clipRule: "evenodd"
|
|
3751
|
+
})));
|
|
3752
|
+
};
|
|
3753
|
+
var ForwardRef$f = /*#__PURE__*/React.forwardRef(SvgContentFiltration18);
|
|
3621
3754
|
|
|
3622
|
-
|
|
3623
|
-
|
|
3624
|
-
|
|
3625
|
-
|
|
3626
|
-
|
|
3627
|
-
|
|
3628
|
-
|
|
3629
|
-
|
|
3630
|
-
|
|
3631
|
-
|
|
3632
|
-
|
|
3633
|
-
|
|
3634
|
-
|
|
3635
|
-
|
|
3636
|
-
|
|
3637
|
-
|
|
3638
|
-
|
|
3755
|
+
var _path$d;
|
|
3756
|
+
function _extends$e() { _extends$e = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$e.apply(this, arguments); }
|
|
3757
|
+
var SvgNavigationChevronUp18 = function SvgNavigationChevronUp18(props, ref) {
|
|
3758
|
+
return /*#__PURE__*/React__namespace.createElement("svg", _extends$e({
|
|
3759
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
3760
|
+
width: 18,
|
|
3761
|
+
height: 18,
|
|
3762
|
+
viewBox: "0 0 18 18",
|
|
3763
|
+
ref: ref
|
|
3764
|
+
}, props), _path$d || (_path$d = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3765
|
+
fillRule: "evenodd",
|
|
3766
|
+
d: "m9 6-4.5 4.5 1.058 1.057L9 8.123l3.443 3.434L13.5 10.5 9 6z",
|
|
3767
|
+
clipRule: "evenodd"
|
|
3768
|
+
})));
|
|
3769
|
+
};
|
|
3770
|
+
var ForwardRef$e = /*#__PURE__*/React.forwardRef(SvgNavigationChevronUp18);
|
|
3771
|
+
|
|
3772
|
+
class DataTableHeaderCell extends React__namespace.Component {
|
|
3773
|
+
constructor() {
|
|
3774
|
+
super(...arguments);
|
|
3775
|
+
this.state = {
|
|
3776
|
+
isDropdownOpen: null,
|
|
3777
|
+
};
|
|
3778
|
+
this.getTextStyle = () => {
|
|
3779
|
+
if (this.props.textCase === 'upper')
|
|
3780
|
+
return css$i.upperCase;
|
|
3781
|
+
return css$i['font-size-14'];
|
|
3782
|
+
};
|
|
3783
|
+
this.getTooltipContent = () => (React__namespace.createElement("div", { className: css$i.cellTooltipWrapper },
|
|
3784
|
+
React__namespace.createElement(Text, { fontSize: "14", color: "contrast", font: "semibold", cx: css$i.cellTooltipText }, this.props.column.caption),
|
|
3785
|
+
this.props.column.info && React__namespace.createElement(Text, { fontSize: "12", color: "contrast", cx: css$i.cellTooltipText }, this.props.column.info)));
|
|
3786
|
+
this.getColumnCaption = () => {
|
|
3787
|
+
return (React__namespace.createElement("div", { className: css$i.tooltipWrapper },
|
|
3788
|
+
React__namespace.createElement("div", { className: uuiCore.cx(css$i.iconCell, css$i['align-' + this.props.column.textAlign], uuiCore.uuiDataTableHeaderCell.uuiTableHeaderCaptionWrapper) },
|
|
3789
|
+
React__namespace.createElement(Tooltip, { placement: "top", color: "contrast", renderContent: this.getTooltipContent, cx: css$i.cellTooltip, openDelay: 600 },
|
|
3790
|
+
React__namespace.createElement(Text, { key: "text", lineHeight: "30", fontSize: "14", size: "30", cx: uuiCore.cx(css$i.caption, this.getTextStyle(), uuiCore.uuiDataTableHeaderCell.uuiTableHeaderCaption) }, this.props.column.caption)),
|
|
3791
|
+
this.props.column.isSortable && (!this.props.column.renderFilter || this.props.sortDirection) && (React__namespace.createElement(IconButton, { key: "sort", cx: uuiCore.cx(css$i.icon, css$i.sortIcon, this.props.sortDirection && css$i.sortIconActive, uuiCore.uuiDataTableHeaderCell.uuiTableHeaderSortIcon), color: this.props.sortDirection ? 'neutral' : 'secondary', icon: this.props.sortDirection === 'desc' ? ForwardRef$h : this.props.sortDirection === 'asc' ? ForwardRef$i : ForwardRef$g })),
|
|
3792
|
+
this.props.isFilterActive && (React__namespace.createElement(IconButton, { key: "filter", cx: uuiCore.cx(css$i.icon, !this.props.sortDirection && css$i.filterIcon, uuiCore.uuiDataTableHeaderCell.uuiTableHeaderFilterIcon), color: "neutral", icon: ForwardRef$f })),
|
|
3793
|
+
this.props.column.renderFilter && (React__namespace.createElement(IconButton, { key: "dropdown", cx: uuiCore.cx(css$i.icon, css$i.dropdownIcon, uuiCore.uuiDataTableHeaderCell.uuiTableHeaderDropdownIcon), color: "secondary", icon: this.state.isDropdownOpen ? ForwardRef$e : ForwardRef$z })))));
|
|
3794
|
+
};
|
|
3795
|
+
this.renderHeaderCheckbox = () => this.props.selectAll
|
|
3796
|
+
&& this.props.isFirstColumn && (React__namespace.createElement(Checkbox, Object.assign({ size: +this.props.size < 36 ? '12' : '18' }, this.props.selectAll, { cx: uuiCore.cx(css$i.checkbox, uuiCore.uuiDataTableHeaderCell.uuiTableHeaderCheckbox) })));
|
|
3797
|
+
this.renderResizeMark = (props) => React__namespace.createElement("div", { onMouseDown: props.onResizeStart, className: uuiCore.cx(css$i.resizeMark, uuiCore.uuiMarkers.draggable) });
|
|
3798
|
+
this.renderCellContent = (props, dropdownProps) => (React__namespace.createElement(FlexCell, Object.assign({}, this.props.column, { minWidth: this.props.column.width, ref: (ref) => {
|
|
3799
|
+
var _a;
|
|
3800
|
+
props.ref(ref);
|
|
3801
|
+
(_a = dropdownProps === null || dropdownProps === void 0 ? void 0 : dropdownProps.ref) === null || _a === void 0 ? void 0 : _a.call(dropdownProps, ref);
|
|
3802
|
+
}, cx: uuiCore.cx(uuiCore.uuiDataTableHeaderCell.uuiTableHeaderCell, (this.props.column.isSortable || this.props.isDropdown) && uuiCore.uuiMarkers.clickable, css$i.cell, css$i['size-' + (this.props.size || '36')], this.props.isFirstColumn && css$i['padding-left-24'], this.props.isLastColumn && css$i['padding-right-24'], this.props.column.cx, this.props.allowColumnsResizing && css$i.resizable, props.isDraggable && css$i.draggable, props.isDragGhost && css$i.ghost, props.isDraggedOut && css$i.isDraggedOut, props.isDndInProgress && css$i['dnd-marker-' + props.position]), onClick: !this.props.column.renderFilter ? props.toggleSort : dropdownProps === null || dropdownProps === void 0 ? void 0 : dropdownProps.onClick, rawProps: Object.assign({ role: 'columnheader', 'aria-sort': this.props.sortDirection === 'asc' ? 'ascending' : this.props.sortDirection ? 'descending' : 'none' }, props.eventHandlers) }),
|
|
3803
|
+
this.renderHeaderCheckbox(),
|
|
3804
|
+
this.getColumnCaption(),
|
|
3805
|
+
this.props.allowColumnsResizing && this.renderResizeMark(props)));
|
|
3806
|
+
this.renderCellWithFilter = (props) => (React__namespace.createElement(ColumnHeaderDropdown, { isOpen: this.state.isDropdownOpen, isSortable: this.props.column.isSortable, renderTarget: (dropdownProps) => this.renderCellContent(props, dropdownProps), renderFilter: this.props.renderFilter, onSort: this.props.onSort, sortDirection: this.props.sortDirection, onOpenChange: (isDropdownOpen) => this.setState({ isDropdownOpen }), title: this.props.column.caption }));
|
|
3807
|
+
}
|
|
3808
|
+
render() {
|
|
3809
|
+
return React__namespace.createElement(uuiComponents.DataTableHeaderCell, Object.assign({}, this.props, { cx: "uui-dt-vars", renderCellContent: this.props.column.renderFilter ? this.renderCellWithFilter : this.renderCellContent }));
|
|
3810
|
+
}
|
|
3639
3811
|
}
|
|
3640
3812
|
|
|
3813
|
+
var css$h = {"uui-typography":"GyYgOR","hero-header":"a0rlKR","promo-header":"VtFMPm","uui-critical":"dRm-EC","uui-success":"qpwJS-","uui-warning":"ommFd7","uui-typography-size-12":"wYL07A","uui-typography-size-14":"g1BgKe","uui-typography-size-16":"AX5qk6","header-cell":"PRi7vN","config-icon":"Sit3CV","uuiTypography":"GyYgOR","heroHeader":"a0rlKR","promoHeader":"VtFMPm","uuiCritical":"dRm-EC","uuiSuccess":"qpwJS-","uuiWarning":"ommFd7","uuiTypographySize12":"wYL07A","uuiTypographySize14":"g1BgKe","uuiTypographySize16":"AX5qk6","headerCell":"PRi7vN","configIcon":"Sit3CV"};
|
|
3814
|
+
|
|
3641
3815
|
var _path$c;
|
|
3642
3816
|
function _extends$d() { _extends$d = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$d.apply(this, arguments); }
|
|
3643
|
-
var
|
|
3817
|
+
var SvgActionSettings18 = function SvgActionSettings18(props, ref) {
|
|
3644
3818
|
return /*#__PURE__*/React__namespace.createElement("svg", _extends$d({
|
|
3645
3819
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3646
3820
|
width: 18,
|
|
@@ -3648,90 +3822,19 @@ var SvgContentPlusBold18 = function SvgContentPlusBold18(props, ref) {
|
|
|
3648
3822
|
viewBox: "0 0 18 18",
|
|
3649
3823
|
ref: ref
|
|
3650
3824
|
}, props), _path$c || (_path$c = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3651
|
-
|
|
3825
|
+
fillRule: "evenodd",
|
|
3826
|
+
d: "M3 9.093a6.083 6.083 0 0 1 0-.186L1.55 7.271a1 1 0 0 1-.118-1.163l1.28-2.216a1 1 0 0 1 1.066-.48l2.14.439a3.81 3.81 0 0 1 .163-.094l.691-2.073A1 1 0 0 1 7.721 1h2.558a1 1 0 0 1 .949.684l.69 2.073c.056.03.11.061.163.094l2.141-.439a1 1 0 0 1 1.067.48l1.279 2.216a1 1 0 0 1-.118 1.163L15 8.907a5.72 5.72 0 0 1 0 .186l1.45 1.636a1 1 0 0 1 .118 1.163l-1.28 2.216a1 1 0 0 1-1.066.48l-2.14-.438a6.215 6.215 0 0 1-.163.093l-.691 2.073a1 1 0 0 1-.949.684H7.721a1 1 0 0 1-.949-.684l-.69-2.073a6.105 6.105 0 0 1-.163-.094l-2.141.439a1 1 0 0 1-1.067-.48l-1.279-2.216a1 1 0 0 1 .118-1.163L3 9.093zM9 12a3 3 0 1 0 0-6 3 3 0 0 0 0 6z",
|
|
3827
|
+
clipRule: "evenodd"
|
|
3652
3828
|
})));
|
|
3653
3829
|
};
|
|
3654
|
-
var ForwardRef$d = /*#__PURE__*/React.forwardRef(
|
|
3655
|
-
|
|
3656
|
-
function PresetsPanel(props) {
|
|
3657
|
-
const [isAddingPreset, setIsAddingPreset] = React.useState(false);
|
|
3658
|
-
const setAddingPreset = React.useCallback(() => {
|
|
3659
|
-
setIsAddingPreset(true);
|
|
3660
|
-
}, []);
|
|
3661
|
-
const cancelAddingPreset = React.useCallback(() => {
|
|
3662
|
-
setIsAddingPreset(false);
|
|
3663
|
-
}, []);
|
|
3664
|
-
const presetApi = __rest(props, ["presets"]);
|
|
3665
|
-
const renderPreset = (preset) => {
|
|
3666
|
-
return React__namespace.default.createElement(Preset, Object.assign({ key: preset.id, preset: preset, addPreset: setAddingPreset }, presetApi));
|
|
3667
|
-
};
|
|
3668
|
-
const renderAddPresetButton = React.useCallback(() => {
|
|
3669
|
-
return (React__namespace.default.createElement("div", { key: "addingPresetBlock", className: css$k.addPresetContainer }, !isAddingPreset ? (React__namespace.default.createElement(Button, { size: "36", onClick: setAddingPreset, caption: i18n.presetPanel.addCaption, icon: ForwardRef$d, iconPosition: "left", mode: "ghost", color: "primary" })) : (React__namespace.default.createElement(PresetInput, { onCancel: cancelAddingPreset, onSuccess: props.createNewPreset }))));
|
|
3670
|
-
}, [isAddingPreset]);
|
|
3671
|
-
const onPresetDropdownSelect = (preset) => {
|
|
3672
|
-
props.choosePreset(preset.preset);
|
|
3673
|
-
};
|
|
3674
|
-
const renderMoreButtonDropdown = (item, hiddenItems) => {
|
|
3675
|
-
return (React__namespace.default.createElement(Dropdown, { key: "more", renderTarget: (props) => (React__namespace.default.createElement(FlexRow, null,
|
|
3676
|
-
React__namespace.default.createElement("div", { className: css$k.divider }),
|
|
3677
|
-
React__namespace.default.createElement(Button, Object.assign({ mode: "ghost", color: "secondary", caption: `${(hiddenItems === null || hiddenItems === void 0 ? void 0 : hiddenItems.length) || ''} more` }, props)))), renderBody: (propsBody) => (React__namespace.default.createElement(DropdownContainer, Object.assign({ cx: uuiCore.cx(css$k.dropContainer), width: 230 }, propsBody),
|
|
3678
|
-
React__namespace.default.createElement(uuiComponents.ScrollBars, null, hiddenItems.map((hiddenItem) => (React__namespace.default.createElement(DropdownMenuButton, { key: hiddenItem.preset.id, onClick: () => onPresetDropdownSelect(hiddenItem), caption: hiddenItem.preset.name, icon: !hiddenItem.preset.isReadonly && ForwardRef$e, iconPosition: "right", cx: css$k.dropdownDeleteIcon, onIconClick: !hiddenItem.preset.isReadonly && (() => props.deletePreset(hiddenItem.preset)) })))))) }));
|
|
3679
|
-
};
|
|
3680
|
-
const getPresetPriority = (preset, index) => {
|
|
3681
|
-
return preset.id === props.activePresetId ? 100499 : 1000 - index;
|
|
3682
|
-
};
|
|
3683
|
-
const getPanelItems = () => {
|
|
3684
|
-
return [
|
|
3685
|
-
...sortBy__default.default(props.presets, (i) => i.order).map((preset, index) => ({
|
|
3686
|
-
id: preset.id.toString(),
|
|
3687
|
-
render: () => renderPreset(preset),
|
|
3688
|
-
priority: getPresetPriority(preset, index),
|
|
3689
|
-
preset: preset,
|
|
3690
|
-
})), {
|
|
3691
|
-
id: 'collapsedContainer', render: renderMoreButtonDropdown, priority: 100501, collapsedContainer: true,
|
|
3692
|
-
}, { id: 'addPreset', render: renderAddPresetButton, priority: 100501 },
|
|
3693
|
-
];
|
|
3694
|
-
};
|
|
3695
|
-
return (React__namespace.default.createElement(FlexCell, { grow: 1, minWidth: 310, rawProps: props.rawProps },
|
|
3696
|
-
React__namespace.default.createElement(FlexRow, { size: null, spacing: "12", cx: css$k.presetsWrapper },
|
|
3697
|
-
React__namespace.default.createElement(uuiComponents.AdaptivePanel, { items: getPanelItems() }))));
|
|
3698
|
-
}
|
|
3699
|
-
|
|
3700
|
-
const defaultPredicates = {
|
|
3701
|
-
numeric: [
|
|
3702
|
-
{ predicate: 'eq', name: '=', isDefault: true }, { predicate: 'neq', name: '≠' }, { predicate: 'lte', name: '≤' }, { predicate: 'gte', name: '≥' }, { predicate: 'inRange', name: 'In Range' },
|
|
3703
|
-
],
|
|
3704
|
-
multiPicker: [{ predicate: 'in', name: 'is', isDefault: true }, { predicate: 'nin', name: 'is not' }],
|
|
3705
|
-
rangeDatePicker: [{ predicate: 'inRange', name: 'In Range', isDefault: true }, { predicate: 'notInRange', name: 'Not in Range' }],
|
|
3706
|
-
};
|
|
3830
|
+
var ForwardRef$d = /*#__PURE__*/React.forwardRef(SvgActionSettings18);
|
|
3707
3831
|
|
|
3708
|
-
const
|
|
3709
|
-
|
|
3710
|
-
|
|
3711
|
-
|
|
3712
|
-
return null;
|
|
3713
|
-
const props = filterLens.prop(filter.field).toProps();
|
|
3714
|
-
return React__namespace.default.createElement(FilterItemBody, Object.assign({}, props, filter, dropdownProps));
|
|
3715
|
-
}, [filters]);
|
|
3716
|
-
const columns = React.useMemo(() => {
|
|
3717
|
-
if (filters) {
|
|
3718
|
-
const filterKeys = filters.map((f) => f.columnKey);
|
|
3719
|
-
const newColumns = (initialColumns.map((column) => {
|
|
3720
|
-
if (filterKeys.includes(column.key)) {
|
|
3721
|
-
return Object.assign(Object.assign({}, column), { renderFilter: makeFilterRenderCallback(column.key) });
|
|
3722
|
-
}
|
|
3723
|
-
else {
|
|
3724
|
-
return column;
|
|
3725
|
-
}
|
|
3726
|
-
}));
|
|
3727
|
-
return newColumns;
|
|
3728
|
-
}
|
|
3729
|
-
return initialColumns;
|
|
3730
|
-
}, [filters, initialColumns]);
|
|
3731
|
-
return columns;
|
|
3732
|
-
};
|
|
3832
|
+
const DataTableHeaderRow = uuiCore.withMods(uuiComponents.DataTableHeaderRow, () => [css$h.root, 'uui-dt-vars'], (mods) => ({
|
|
3833
|
+
renderCell: (props) => React__namespace.createElement(DataTableHeaderCell, Object.assign({}, props, { size: mods.size, textCase: mods.textCase || 'normal', key: props.column.key })),
|
|
3834
|
+
renderConfigButton: () => React__namespace.createElement(IconButton, { key: "configuration", onClick: mods.onConfigButtonClick, cx: css$h.configIcon, color: "neutral", icon: ForwardRef$d }),
|
|
3835
|
+
}));
|
|
3733
3836
|
|
|
3734
|
-
var styles$1 = {"main-panel":"
|
|
3837
|
+
var styles$1 = {"uui-typography":"mGcPRL","hero-header":"_0tTnvI","promo-header":"zMfQI9","uui-critical":"Ufx76A","uui-success":"WGremY","uui-warning":"OKzFYQ","uui-typography-size-12":"_1qSwW6","uui-typography-size-14":"vomjZ2","uui-typography-size-16":"KzVCy9","main-panel":"W4GF6R","group-title":"-jJY9r","group-title-text":"_0-dioj","group-title-badge":"uuBGSI","group-items":"qPCb-i","no-data":"_21fZHd","h-divider":"Kh4uZw","search-area":"rYoths","uuiTypography":"mGcPRL","heroHeader":"_0tTnvI","promoHeader":"zMfQI9","uuiCritical":"Ufx76A","uuiSuccess":"WGremY","uuiWarning":"OKzFYQ","uuiTypographySize12":"_1qSwW6","uuiTypographySize14":"vomjZ2","uuiTypographySize16":"KzVCy9","mainPanel":"W4GF6R","groupTitle":"-jJY9r","groupTitleText":"_0-dioj","groupTitleBadge":"uuBGSI","groupItems":"qPCb-i","noData":"_21fZHd","hDivider":"Kh4uZw","searchArea":"rYoths"};
|
|
3735
3838
|
|
|
3736
3839
|
var _path$b;
|
|
3737
3840
|
function _extends$c() { _extends$c = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$c.apply(this, arguments); }
|
|
@@ -3810,7 +3913,7 @@ function PinIconButton(props) {
|
|
|
3810
3913
|
React__namespace.createElement(IconButton, { icon: pinIcon, onClick: pinClickHandler, isDisabled: isPinnedAlways, color: isPinned ? 'info' : undefined }))));
|
|
3811
3914
|
}
|
|
3812
3915
|
|
|
3813
|
-
var styles = {"row-wrapper":"
|
|
3916
|
+
var styles = {"uui-typography":"p47L2W","hero-header":"DkRK5G","promo-header":"J5uzxQ","uui-critical":"Xvyn6B","uui-success":"S6scUE","uui-warning":"kgKMQH","uui-typography-size-12":"gYpBYm","uui-typography-size-14":"TN423q","uui-typography-size-16":"h9SEig","row-wrapper":"uBtvlk","not-pinned":"B7uAxr","pin-icon-button":"-b-VeG","checkbox":"_3leOUg","drag-handle":"L5QEYr","dnd-disabled":"CbmLsv","uuiTypography":"p47L2W","heroHeader":"DkRK5G","promoHeader":"J5uzxQ","uuiCritical":"Xvyn6B","uuiSuccess":"S6scUE","uuiWarning":"kgKMQH","uuiTypographySize12":"gYpBYm","uuiTypographySize14":"TN423q","uuiTypographySize16":"h9SEig","rowWrapper":"uBtvlk","notPinned":"B7uAxr","pinIconButton":"-b-VeG","dragHandle":"L5QEYr","dndDisabled":"CbmLsv"};
|
|
3814
3917
|
|
|
3815
3918
|
const ColumnRow = React__namespace.memo(function ColumnRow(props) {
|
|
3816
3919
|
const { column } = props;
|
|
@@ -3836,7 +3939,7 @@ const ColumnRow = React__namespace.memo(function ColumnRow(props) {
|
|
|
3836
3939
|
|
|
3837
3940
|
const renderGroupTitle = (title, amount) => (React__namespace.createElement(FlexRow, { size: "24", padding: "24", spacing: "6", cx: styles$1.groupTitle },
|
|
3838
3941
|
React__namespace.createElement(Text, { cx: styles$1.groupTitleText, font: "semibold", lineHeight: "24", fontSize: "14" }, title),
|
|
3839
|
-
React__namespace.createElement(Badge, { cx: styles$1.groupTitleBadge, caption: amount, color: "
|
|
3942
|
+
React__namespace.createElement(Badge, { cx: styles$1.groupTitleBadge, caption: amount, color: "neutral", size: "18" })));
|
|
3840
3943
|
function ColumnsConfigurationModal(props) {
|
|
3841
3944
|
const i18n$1 = i18n.tables.columnsConfigurationModal;
|
|
3842
3945
|
const { columns, columnsConfig: initialColumnsConfig, defaultConfig } = props, modalProps = __rest(props, ["columns", "columnsConfig", "defaultConfig"]);
|
|
@@ -3878,10 +3981,10 @@ function ColumnsConfigurationModal(props) {
|
|
|
3878
3981
|
React__namespace.createElement(ModalHeader, { title: i18n$1.configureColumnsTitle, onClose: close }),
|
|
3879
3982
|
React__namespace.createElement(FlexRow, { padding: "24", borderBottom: true, spacing: "12", cx: styles$1.searchArea },
|
|
3880
3983
|
React__namespace.createElement(SearchInput, { size: "30", value: searchValue, onValueChange: setSearchValue, placeholder: i18n$1.searchPlaceholder }),
|
|
3881
|
-
React__namespace.createElement(Dropdown, { closeOnTargetClick: true, renderBody: () => (React__namespace.createElement(Panel, { shadow: true },
|
|
3984
|
+
React__namespace.createElement(Dropdown, { closeOnTargetClick: true, renderBody: () => (React__namespace.createElement(Panel, { background: "surface", shadow: true },
|
|
3882
3985
|
React__namespace.createElement(DropdownMenuButton, { caption: i18n$1.clearAllButton, onClick: uncheckAll }),
|
|
3883
|
-
React__namespace.createElement(DropdownMenuButton, { caption: i18n$1.selectAllButton, onClick: checkAll }))), renderTarget: (props) => React__namespace.createElement(Button, Object.assign({}, props, {
|
|
3884
|
-
React__namespace.createElement(Panel, { cx: styles$1.mainPanel },
|
|
3986
|
+
React__namespace.createElement(DropdownMenuButton, { caption: i18n$1.selectAllButton, onClick: checkAll }))), renderTarget: (props) => React__namespace.createElement(Button, Object.assign({}, props, { fill: "none", icon: ForwardRef$s, size: "30", color: "secondary", isDropdown: false })) })),
|
|
3987
|
+
React__namespace.createElement(Panel, { background: "surface", cx: styles$1.mainPanel },
|
|
3885
3988
|
React__namespace.createElement(ScrollBars, null,
|
|
3886
3989
|
renderVisible(),
|
|
3887
3990
|
renderHidden(),
|
|
@@ -3889,12 +3992,67 @@ function ColumnsConfigurationModal(props) {
|
|
|
3889
3992
|
React__namespace.createElement(Text, { fontSize: "24", lineHeight: "30", color: "primary", font: "semibold" }, i18n$1.noResultsFound.text),
|
|
3890
3993
|
React__namespace.createElement(Text, { fontSize: "16", lineHeight: "24", font: "regular", color: "primary" }, i18n$1.noResultsFound.subText))))),
|
|
3891
3994
|
React__namespace.createElement(ModalFooter, { borderTop: true },
|
|
3892
|
-
React__namespace.createElement(LinkButton, { icon: ForwardRef$
|
|
3995
|
+
React__namespace.createElement(LinkButton, { icon: ForwardRef$r, caption: i18n$1.resetToDefaultButton, onClick: reset }),
|
|
3893
3996
|
React__namespace.createElement(uuiComponents.FlexSpacer, null),
|
|
3894
|
-
React__namespace.createElement(Button, {
|
|
3997
|
+
React__namespace.createElement(Button, { fill: "none", color: "secondary", caption: i18n$1.cancelButton, onClick: close }),
|
|
3895
3998
|
noVisibleColumns ? (React__namespace.createElement(Tooltip, { content: i18n$1.enableAtLeastOneColumnMessage, placement: "top-end", color: "critical" }, applyButton)) : (applyButton)))));
|
|
3896
3999
|
}
|
|
3897
4000
|
|
|
4001
|
+
var css$g = {"listContainer":"FOVXfC","header":"jY4gLS","group":"_6ZENDn","stickyHeader":"kYkDln"};
|
|
4002
|
+
|
|
4003
|
+
const getChildrenAndRest = (row, rows) => {
|
|
4004
|
+
const firstNotChildIndex = rows.findIndex((other) => other.depth < row.depth || (row.depth === other.depth && other.isPinned));
|
|
4005
|
+
if (firstNotChildIndex === -1) {
|
|
4006
|
+
return [rows, []];
|
|
4007
|
+
}
|
|
4008
|
+
if (firstNotChildIndex === 0) {
|
|
4009
|
+
return [[], rows];
|
|
4010
|
+
}
|
|
4011
|
+
const children = rows.slice(0, firstNotChildIndex);
|
|
4012
|
+
const rest = rows.slice(firstNotChildIndex, rows.length);
|
|
4013
|
+
return [children, rest];
|
|
4014
|
+
};
|
|
4015
|
+
|
|
4016
|
+
function DataRowsGroup({ row, childRows, renderRow, top = 1, }) {
|
|
4017
|
+
var _a, _b;
|
|
4018
|
+
const rowRef = React.useRef();
|
|
4019
|
+
const childrenPinnedTop = row.isPinned ? (top + ((_b = (_a = rowRef.current) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0)) : top;
|
|
4020
|
+
return (React__namespace.default.createElement("div", { className: css$g.group, key: row.rowKey },
|
|
4021
|
+
React__namespace.default.createElement("div", { className: row.isPinned ? css$g.stickyHeader : css$g.header,
|
|
4022
|
+
// Gaps between pinned parents should be removed by -1 from top height.
|
|
4023
|
+
// Otherwise, sometimes top value is rounded top.
|
|
4024
|
+
style: { zIndex: row.depth + 10, top: top - 1 }, ref: rowRef }, renderRow(row)),
|
|
4025
|
+
childRows.length > 0 && (React__namespace.default.createElement("div", null,
|
|
4026
|
+
React__namespace.default.createElement(DataRowsGroups, { rows: childRows, renderRow: renderRow, top: childrenPinnedTop })))));
|
|
4027
|
+
}
|
|
4028
|
+
const renderRows = (rows, renderRow, top) => {
|
|
4029
|
+
if (!rows.length)
|
|
4030
|
+
return [];
|
|
4031
|
+
const [row, ...rest] = rows;
|
|
4032
|
+
if (!rest.length) {
|
|
4033
|
+
return [renderRow(row)];
|
|
4034
|
+
}
|
|
4035
|
+
const [next] = rest;
|
|
4036
|
+
if (next.depth <= row.depth && !row.isPinned) {
|
|
4037
|
+
return [renderRow(row)].concat(renderRows(rest, renderRow, top));
|
|
4038
|
+
}
|
|
4039
|
+
const [children, otherRows] = getChildrenAndRest(row, rest);
|
|
4040
|
+
const group = (React__namespace.default.createElement(DataRowsGroup, { row: row, childRows: children, renderRow: renderRow, top: top, key: row.rowKey }));
|
|
4041
|
+
return [group].concat(renderRows(otherRows, renderRow, top));
|
|
4042
|
+
};
|
|
4043
|
+
function DataRowsGroups({ rows, renderRow, top = 1, }) {
|
|
4044
|
+
const rowsWithGroups = renderRows(rows, renderRow, top);
|
|
4045
|
+
// eslint-disable-next-line react/jsx-no-useless-fragment
|
|
4046
|
+
return (React__namespace.default.createElement(React__namespace.default.Fragment, null, rowsWithGroups));
|
|
4047
|
+
}
|
|
4048
|
+
|
|
4049
|
+
function DataRowsContainer({ estimatedHeight, listContainerRef, offsetY, rows, renderRow, headerRef, }) {
|
|
4050
|
+
var _a;
|
|
4051
|
+
return (React__namespace.default.createElement("div", { className: css$g.listContainer, style: { minHeight: `${estimatedHeight}px` } },
|
|
4052
|
+
React__namespace.default.createElement("div", { ref: listContainerRef, role: "rowgroup", style: { marginTop: offsetY } },
|
|
4053
|
+
React__namespace.default.createElement(DataRowsGroups, { rows: rows, renderRow: renderRow, top: (_a = headerRef === null || headerRef === void 0 ? void 0 : headerRef.current) === null || _a === void 0 ? void 0 : _a.clientHeight }))));
|
|
4054
|
+
}
|
|
4055
|
+
|
|
3898
4056
|
var _path$8, _path2, _path3, _path4, _path5, _path6, _g$1, _path7, _path8, _path9, _path10, _path11, _path12, _path13, _path14, _path15, _path16, _path17, _path18, _path19, _path20, _path21, _path22, _path23, _path24, _defs;
|
|
3899
4057
|
function _extends$9() { _extends$9 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$9.apply(this, arguments); }
|
|
3900
4058
|
var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
@@ -3906,7 +4064,7 @@ var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
|
3906
4064
|
xmlns: "http://www.w3.org/2000/svg",
|
|
3907
4065
|
ref: ref
|
|
3908
4066
|
}, props), /*#__PURE__*/React__namespace.createElement("g", {
|
|
3909
|
-
clipPath: "url(#
|
|
4067
|
+
clipPath: "url(#odmwhp5hbu3kk9s64_a)"
|
|
3910
4068
|
}, _path$8 || (_path$8 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
3911
4069
|
d: "M150.585 1.535C49.483-11.495 27.481 61.805 45.725 97.481c10.581 20.69-39.64 70.792 17.744 81.468 27.538 5.123 36-13.341 62.433-10.655 35.4 3.6 148.167-4.73 88.349-78.915-31.713-39.335 1.026-79.506-63.666-87.844Z",
|
|
3912
4070
|
fill: "#F5F6FA"
|
|
@@ -3927,7 +4085,7 @@ var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
|
3927
4085
|
d: "M86.786 22.982c-2.55 0-4.965 2.07-4.965 4.552V120.6c0 2.484 2.4 4.572 4.965 4.572h88.101c2.582 0 4.986-2.089 4.986-4.572V27.534c0-2.464-2.418-4.552-4.986-4.552h-88.1Zm-5.793 4.552c0-3.022 2.874-5.38 5.793-5.38h88.101c2.935 0 5.814 2.374 5.814 5.38V120.6c0 3.021-2.86 5.4-5.814 5.4h-88.1c-2.94 0-5.794-2.381-5.794-5.4V27.534Z",
|
|
3928
4086
|
fill: "#1D1E26"
|
|
3929
4087
|
})), /*#__PURE__*/React__namespace.createElement("mask", {
|
|
3930
|
-
id: "
|
|
4088
|
+
id: "odmwhpailrok4upek_b",
|
|
3931
4089
|
style: {
|
|
3932
4090
|
maskType: "alpha"
|
|
3933
4091
|
},
|
|
@@ -3940,7 +4098,7 @@ var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
|
3940
4098
|
d: "M174.887 125.586h-88.1c-2.752 0-5.38-2.234-5.38-4.986V27.534c0-2.752 2.644-4.966 5.38-4.966h88.1c2.752 0 5.4 2.23 5.4 4.966V120.6c0 2.752-2.632 4.986-5.4 4.986Z",
|
|
3941
4099
|
fill: "#9BDEFF"
|
|
3942
4100
|
}))), _g$1 || (_g$1 = /*#__PURE__*/React__namespace.createElement("g", {
|
|
3943
|
-
mask: "url(#
|
|
4101
|
+
mask: "url(#odmwhpailrok4upek_b)",
|
|
3944
4102
|
fillRule: "evenodd",
|
|
3945
4103
|
clipRule: "evenodd"
|
|
3946
4104
|
}, /*#__PURE__*/React__namespace.createElement("path", {
|
|
@@ -4026,7 +4184,7 @@ var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
|
4026
4184
|
d: "M24.73 96.184a.414.414 0 0 1 .581.06l48.646 59.751a.413.413 0 1 1-.642.523L24.67 96.766a.414.414 0 0 1 .06-.582Z",
|
|
4027
4185
|
fill: "#fff"
|
|
4028
4186
|
}))), _defs || (_defs = /*#__PURE__*/React__namespace.createElement("defs", null, /*#__PURE__*/React__namespace.createElement("clipPath", {
|
|
4029
|
-
id: "
|
|
4187
|
+
id: "odmwhp5hbu3kk9s64_a"
|
|
4030
4188
|
}, /*#__PURE__*/React__namespace.createElement("path", {
|
|
4031
4189
|
fill: "#fff",
|
|
4032
4190
|
transform: "translate(.552)",
|
|
@@ -4035,62 +4193,7 @@ var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
|
4035
4193
|
};
|
|
4036
4194
|
var ForwardRef$9 = /*#__PURE__*/React.forwardRef(SvgEmptyTable);
|
|
4037
4195
|
|
|
4038
|
-
var css$
|
|
4039
|
-
|
|
4040
|
-
var css$f = {"listContainer":"iDegmz","header":"vfZjHc","group":"_95hELF","stickyHeader":"_1qQ29Z"};
|
|
4041
|
-
|
|
4042
|
-
const getChildrenAndRest = (row, rows) => {
|
|
4043
|
-
const firstNotChildIndex = rows.findIndex((other) => other.depth < row.depth || (row.depth === other.depth && other.isPinned));
|
|
4044
|
-
if (firstNotChildIndex === -1) {
|
|
4045
|
-
return [rows, []];
|
|
4046
|
-
}
|
|
4047
|
-
if (firstNotChildIndex === 0) {
|
|
4048
|
-
return [[], rows];
|
|
4049
|
-
}
|
|
4050
|
-
const children = rows.slice(0, firstNotChildIndex);
|
|
4051
|
-
const rest = rows.slice(firstNotChildIndex, rows.length);
|
|
4052
|
-
return [children, rest];
|
|
4053
|
-
};
|
|
4054
|
-
|
|
4055
|
-
function DataRowsGroup({ row, childRows, renderRow, top = 1, }) {
|
|
4056
|
-
var _a, _b;
|
|
4057
|
-
const rowRef = React.useRef();
|
|
4058
|
-
const childrenPinnedTop = row.isPinned ? (top + ((_b = (_a = rowRef.current) === null || _a === void 0 ? void 0 : _a.clientHeight) !== null && _b !== void 0 ? _b : 0)) : top;
|
|
4059
|
-
return (React__namespace.default.createElement("div", { className: css$f.group, key: row.rowKey },
|
|
4060
|
-
React__namespace.default.createElement("div", { className: row.isPinned ? css$f.stickyHeader : css$f.header,
|
|
4061
|
-
// Gaps between pinned parents should be removed by -1 from top height.
|
|
4062
|
-
// Otherwise, sometimes top value is rounded top.
|
|
4063
|
-
style: { zIndex: row.depth + 10, top: top - 1 }, ref: rowRef }, renderRow(row)),
|
|
4064
|
-
childRows.length > 0 && (React__namespace.default.createElement("div", null,
|
|
4065
|
-
React__namespace.default.createElement(DataRowsGroups, { rows: childRows, renderRow: renderRow, top: childrenPinnedTop })))));
|
|
4066
|
-
}
|
|
4067
|
-
const renderRows = (rows, renderRow, top) => {
|
|
4068
|
-
if (!rows.length)
|
|
4069
|
-
return [];
|
|
4070
|
-
const [row, ...rest] = rows;
|
|
4071
|
-
if (!rest.length) {
|
|
4072
|
-
return [renderRow(row)];
|
|
4073
|
-
}
|
|
4074
|
-
const [next] = rest;
|
|
4075
|
-
if (next.depth <= row.depth && !row.isPinned) {
|
|
4076
|
-
return [renderRow(row)].concat(renderRows(rest, renderRow, top));
|
|
4077
|
-
}
|
|
4078
|
-
const [children, otherRows] = getChildrenAndRest(row, rest);
|
|
4079
|
-
const group = (React__namespace.default.createElement(DataRowsGroup, { row: row, childRows: children, renderRow: renderRow, top: top, key: row.rowKey }));
|
|
4080
|
-
return [group].concat(renderRows(otherRows, renderRow, top));
|
|
4081
|
-
};
|
|
4082
|
-
function DataRowsGroups({ rows, renderRow, top = 1, }) {
|
|
4083
|
-
const rowsWithGroups = renderRows(rows, renderRow, top);
|
|
4084
|
-
// eslint-disable-next-line react/jsx-no-useless-fragment
|
|
4085
|
-
return (React__namespace.default.createElement(React__namespace.default.Fragment, null, rowsWithGroups));
|
|
4086
|
-
}
|
|
4087
|
-
|
|
4088
|
-
function DataRowsContainer({ estimatedHeight, listContainerRef, offsetY, rows, renderRow, headerRef, }) {
|
|
4089
|
-
var _a;
|
|
4090
|
-
return (React__namespace.default.createElement("div", { className: css$f.listContainer, style: { minHeight: `${estimatedHeight}px` } },
|
|
4091
|
-
React__namespace.default.createElement("div", { ref: listContainerRef, role: "rowgroup", style: { marginTop: offsetY } },
|
|
4092
|
-
React__namespace.default.createElement(DataRowsGroups, { rows: rows, renderRow: renderRow, top: (_a = headerRef === null || headerRef === void 0 ? void 0 : headerRef.current) === null || _a === void 0 ? void 0 : _a.clientHeight }))));
|
|
4093
|
-
}
|
|
4196
|
+
var css$f = {"sticky-header":"hlhppN","table":"RPXZnT","no-results":"sE1nCw","no-results-icon":"bUTvMm","no-results-title":"AagxzJ","stickyHeader":"hlhppN","noResults":"sE1nCw","noResultsIcon":"bUTvMm","noResultsTitle":"AagxzJ"};
|
|
4094
4197
|
|
|
4095
4198
|
function DataTable(props) {
|
|
4096
4199
|
var _a;
|
|
@@ -4099,15 +4202,15 @@ function DataTable(props) {
|
|
|
4099
4202
|
const columnsWithFilters = useColumnsWithFilters(props.columns, props.filters);
|
|
4100
4203
|
const { columns, config, defaultConfig } = uuiCore.useColumnsConfig(columnsWithFilters, (_a = props.value) === null || _a === void 0 ? void 0 : _a.columnsConfig);
|
|
4101
4204
|
const defaultRenderRow = React__namespace.useCallback((rowProps) => {
|
|
4102
|
-
return React__namespace.createElement(DataTableRow, Object.assign({ key: rowProps.rowKey, size: props.size, borderBottom: props.border }, rowProps, { cx: css$
|
|
4205
|
+
return React__namespace.createElement(DataTableRow, Object.assign({ key: rowProps.rowKey, size: props.size, borderBottom: props.border }, rowProps, { cx: css$f.cell }));
|
|
4103
4206
|
}, []);
|
|
4104
4207
|
const renderRow = (row) => { var _a; return ((_a = props.renderRow) !== null && _a !== void 0 ? _a : defaultRenderRow)(Object.assign(Object.assign({}, row), { columns })); };
|
|
4105
4208
|
const rows = props.getRows();
|
|
4106
4209
|
const renderNoResultsBlock = React__namespace.useCallback(() => {
|
|
4107
4210
|
var _a;
|
|
4108
|
-
return (React__namespace.createElement("div", { className: css$
|
|
4109
|
-
React__namespace.createElement(uuiComponents.IconContainer, { cx: css$
|
|
4110
|
-
React__namespace.createElement(Text, { cx: css$
|
|
4211
|
+
return (React__namespace.createElement("div", { className: css$f.noResults }, props.renderNoResultsBlock ? ((_a = props.renderNoResultsBlock) === null || _a === void 0 ? void 0 : _a.call(props)) : (React__namespace.createElement(React__namespace.Fragment, null,
|
|
4212
|
+
React__namespace.createElement(uuiComponents.IconContainer, { cx: css$f.noResultsIcon, icon: ForwardRef$9 }),
|
|
4213
|
+
React__namespace.createElement(Text, { cx: css$f.noResultsTitle, fontSize: "24", lineHeight: "30", color: "primary", font: "semibold" }, i18n.tables.noResultsBlock.title),
|
|
4111
4214
|
React__namespace.createElement(Text, { fontSize: "16", lineHeight: "24", font: "regular", color: "primary" }, i18n.tables.noResultsBlock.message)))));
|
|
4112
4215
|
}, [props.renderNoResultsBlock]);
|
|
4113
4216
|
const onConfigurationButtonClick = React__namespace.useCallback(() => {
|
|
@@ -4124,7 +4227,7 @@ function DataTable(props) {
|
|
|
4124
4227
|
props.columns, config, defaultConfig, props.value, props.onValueChange, props.renderColumnsConfigurationModal,
|
|
4125
4228
|
]);
|
|
4126
4229
|
const renderRowsContainer = React__namespace.useCallback(({ listContainerRef, estimatedHeight, offsetY, scrollShadows }) => (React__namespace.createElement(React__namespace.Fragment, null,
|
|
4127
|
-
React__namespace.createElement("div", { className: css$
|
|
4230
|
+
React__namespace.createElement("div", { className: css$f.stickyHeader, ref: headerRef },
|
|
4128
4231
|
React__namespace.createElement(DataTableHeaderRow, { columns: columns, onConfigButtonClick: props.showColumnsConfig && onConfigurationButtonClick, selectAll: props.selectAll, size: props.size, textCase: props.headerTextCase, allowColumnsReordering: props.allowColumnsReordering, allowColumnsResizing: props.allowColumnsResizing, value: Object.assign(Object.assign({}, props.value), { columnsConfig: config }), onValueChange: props.onValueChange }),
|
|
4129
4232
|
React__namespace.createElement("div", { className: uuiCore.cx(uuiCore.uuiScrollShadows.top, {
|
|
4130
4233
|
[uuiCore.uuiScrollShadows.topVisible]: scrollShadows.verticalTop,
|
|
@@ -4133,16 +4236,16 @@ function DataTable(props) {
|
|
|
4133
4236
|
props, columns, rows, renderNoResultsBlock, onConfigurationButtonClick,
|
|
4134
4237
|
]);
|
|
4135
4238
|
return (React__namespace.createElement(uuiComponents.DataTableSelectionProvider, { onCopy: props.onCopy, rows: rows, columns: columns },
|
|
4136
|
-
React__namespace.createElement(VirtualList, { value: props.value, onValueChange: props.onValueChange, onScroll: props.onScroll, rowsCount: props.rowsCount, renderRows: renderRowsContainer, cx: uuiCore.cx(css$
|
|
4239
|
+
React__namespace.createElement(VirtualList, { value: props.value, onValueChange: props.onValueChange, onScroll: props.onScroll, rowsCount: props.rowsCount, renderRows: renderRowsContainer, cx: uuiCore.cx(css$f.table, 'uui-dt-vars'), isLoading: props.isReloading, rowsSelector: "[role=row]", rawProps: {
|
|
4137
4240
|
role: 'table',
|
|
4138
4241
|
'aria-colcount': columns.length,
|
|
4139
4242
|
'aria-rowcount': props.rowsCount,
|
|
4140
4243
|
} })));
|
|
4141
4244
|
}
|
|
4142
4245
|
|
|
4143
|
-
var css$e = {"root":"
|
|
4246
|
+
var css$e = {"root":"_1yPo2o"};
|
|
4144
4247
|
|
|
4145
|
-
var css$d = {"root":"
|
|
4248
|
+
var css$d = {"root":"OLnur1","burger-content":"_8VuLkA","burgerContent":"_8VuLkA"};
|
|
4146
4249
|
|
|
4147
4250
|
var _path$7;
|
|
4148
4251
|
function _extends$8() { _extends$8 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$8.apply(this, arguments); }
|
|
@@ -4175,7 +4278,7 @@ var SvgBurgerClose = function SvgBurgerClose(props, ref) {
|
|
|
4175
4278
|
var ForwardRef$7 = /*#__PURE__*/React.forwardRef(SvgBurgerClose);
|
|
4176
4279
|
|
|
4177
4280
|
function applyBurgerMods() {
|
|
4178
|
-
return [css$d.root];
|
|
4281
|
+
return [cx__default.default(css$d.root, 'uui-burger')];
|
|
4179
4282
|
}
|
|
4180
4283
|
const Burger = uuiCore.withMods(uuiComponents.Burger, applyBurgerMods, () => ({
|
|
4181
4284
|
burgerIcon: ForwardRef$8,
|
|
@@ -4209,10 +4312,15 @@ var SvgTriangle = function SvgTriangle(props, ref) {
|
|
|
4209
4312
|
};
|
|
4210
4313
|
var ForwardRef$6 = /*#__PURE__*/React.forwardRef(SvgTriangle);
|
|
4211
4314
|
|
|
4212
|
-
var css$c = {"
|
|
4315
|
+
var css$c = {"uui-typography":"_9nDrBA","hero-header":"AdmOtD","promo-header":"fIBW6u","uui-critical":"f4TjuB","uui-success":"KfJVyP","uui-warning":"_7PQIay","uui-typography-size-12":"ADIB-G","uui-typography-size-14":"_0mtKhX","uui-typography-size-16":"Wg4Enz","root":"gNrdBT","button-primary":"HVTHMg","button-secondary":"TKb7Ru","hasIcon":"t-PgwR","dropdown":"fYU033","uuiTypography":"_9nDrBA","heroHeader":"AdmOtD","promoHeader":"fIBW6u","uuiCritical":"f4TjuB","uuiSuccess":"KfJVyP","uuiWarning":"_7PQIay","uuiTypographySize12":"ADIB-G","uuiTypographySize14":"_0mtKhX","uuiTypographySize16":"Wg4Enz","buttonPrimary":"HVTHMg","buttonSecondary":"TKb7Ru"};
|
|
4213
4316
|
|
|
4214
4317
|
const BurgerButton = uuiCore.withMods(uuiComponents.Button, (props) => [
|
|
4215
|
-
css$c.root,
|
|
4318
|
+
css$c.root,
|
|
4319
|
+
'uui-main_menu-burger-button',
|
|
4320
|
+
css$c['button-' + (props.type || 'primary')],
|
|
4321
|
+
css$c['indent-' + (props.indentLevel || 0)],
|
|
4322
|
+
props.isDropdown && css$c.dropdown,
|
|
4323
|
+
props.icon && css$c.hasIcon,
|
|
4216
4324
|
], () => ({ dropdownIcon: ForwardRef$6, dropdownIconPosition: 'left', role: 'menuitem' }));
|
|
4217
4325
|
|
|
4218
4326
|
function _extends$5() { _extends$5 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$5.apply(this, arguments); }
|
|
@@ -4261,21 +4369,21 @@ var SvgMenuInputCancel = function SvgMenuInputCancel(props, ref) {
|
|
|
4261
4369
|
};
|
|
4262
4370
|
var ForwardRef$5 = /*#__PURE__*/React.forwardRef(SvgMenuInputCancel);
|
|
4263
4371
|
|
|
4264
|
-
var css$b = {"search-input":"
|
|
4372
|
+
var css$b = {"search-input":"-X1-6-","searchInput":"-X1-6-"};
|
|
4265
4373
|
|
|
4266
4374
|
function BurgerSearch(props) {
|
|
4267
|
-
return (React__namespace.createElement(uuiComponents.TextInput, { cx: css$b.searchInput, iconPosition: "left", icon: ForwardRef$15, placeholder: props.placeholder, value: props.value, onValueChange: props.onValueChange, onCancel: props.onCancel, cancelIcon: props.value && ForwardRef$5 }));
|
|
4375
|
+
return (React__namespace.createElement(uuiComponents.TextInput, { cx: cx__default.default(css$b.searchInput, 'uui-main_menu-burger-search'), iconPosition: "left", icon: ForwardRef$15, placeholder: props.placeholder, value: props.value, onValueChange: props.onValueChange, onCancel: props.onCancel, cancelIcon: props.value && ForwardRef$5 }));
|
|
4268
4376
|
}
|
|
4269
4377
|
|
|
4270
|
-
var css$a = {"group-header":"
|
|
4378
|
+
var css$a = {"root":"VqX1NV","group-header":"McYOuP","group-name":"Fbn2Xi","line":"-kKLpQ","groupHeader":"McYOuP","groupName":"Fbn2Xi"};
|
|
4271
4379
|
|
|
4272
4380
|
function BurgerGroupHeader(props) {
|
|
4273
|
-
return (React__namespace.createElement("div", { className: css$a.groupHeader },
|
|
4381
|
+
return (React__namespace.createElement("div", { className: cx__default.default(css$a.root, css$a.groupHeader, 'uui-burger-group-header') },
|
|
4274
4382
|
React__namespace.createElement("hr", { className: css$a.line }),
|
|
4275
4383
|
React__namespace.createElement("span", { className: css$a.groupName }, props.caption)));
|
|
4276
4384
|
}
|
|
4277
4385
|
|
|
4278
|
-
var css$9 = {"root":"
|
|
4386
|
+
var css$9 = {"uui-typography":"_1t-jlM","hero-header":"Pzq43P","promo-header":"TPVQgX","uui-critical":"wyV3hN","uui-success":"n4gnxJ","uui-warning":"rTW6fv","uui-typography-size-12":"DWdabN","uui-typography-size-14":"YLfBE0","uui-typography-size-16":"tID7RS","root":"SjJkLt","type-primary":"x9Lllu","type-secondary":"mEepFc","uuiTypography":"_1t-jlM","heroHeader":"Pzq43P","promoHeader":"TPVQgX","uuiCritical":"wyV3hN","uuiSuccess":"n4gnxJ","uuiWarning":"rTW6fv","uuiTypographySize12":"DWdabN","uuiTypographySize14":"YLfBE0","uuiTypographySize16":"tID7RS","typePrimary":"x9Lllu","typeSecondary":"mEepFc"};
|
|
4279
4387
|
|
|
4280
4388
|
var _path$4;
|
|
4281
4389
|
function _extends$4() { _extends$4 = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends$4.apply(this, arguments); }
|
|
@@ -4295,7 +4403,7 @@ var ForwardRef$4 = /*#__PURE__*/React.forwardRef(SvgChevronDown24);
|
|
|
4295
4403
|
|
|
4296
4404
|
const MainMenuButton = uuiCore.withMods(uuiComponents.Button, (mods) => [css$9.root, css$9['type-' + (mods.type || 'primary')]], () => ({ dropdownIcon: ForwardRef$4, role: 'menuitem' }));
|
|
4297
4405
|
|
|
4298
|
-
var css$8 = {"dropdown-body":"
|
|
4406
|
+
var css$8 = {"dropdown-body":"DwcTAn","dropdownBody":"DwcTAn"};
|
|
4299
4407
|
|
|
4300
4408
|
class MainMenuDropdown extends React__namespace.Component {
|
|
4301
4409
|
render() {
|
|
@@ -4306,7 +4414,7 @@ class MainMenuDropdown extends React__namespace.Component {
|
|
|
4306
4414
|
}
|
|
4307
4415
|
};
|
|
4308
4416
|
return (React__namespace.createElement(FocusLock__default.default, { returnFocus: true, persistentFocus: true, lockProps: { onKeyDown: handleEscape } },
|
|
4309
|
-
React__namespace.createElement("div", { className: cx__default.default(css$8.dropdownBody) }, this.props.renderBody
|
|
4417
|
+
React__namespace.createElement("div", { className: cx__default.default(css$8.dropdownBody, 'uui-main_menu-dropdown') }, this.props.renderBody
|
|
4310
4418
|
? this.props.renderBody(Object.assign({}, props))
|
|
4311
4419
|
: React__namespace.Children.map(this.props.children, (item) => {
|
|
4312
4420
|
if (!item)
|
|
@@ -4323,7 +4431,10 @@ class MainMenuDropdown extends React__namespace.Component {
|
|
|
4323
4431
|
}
|
|
4324
4432
|
|
|
4325
4433
|
function applyMainMenuMods() {
|
|
4326
|
-
return [
|
|
4434
|
+
return [
|
|
4435
|
+
css$e.root,
|
|
4436
|
+
'uui-main_menu',
|
|
4437
|
+
];
|
|
4327
4438
|
}
|
|
4328
4439
|
const MainMenu = uuiCore.withMods(uuiComponents__namespace.MainMenu, applyMainMenuMods, () => ({
|
|
4329
4440
|
Burger,
|
|
@@ -4346,12 +4457,12 @@ var SvgGlobalMenu = function SvgGlobalMenu(props, ref) {
|
|
|
4346
4457
|
};
|
|
4347
4458
|
var ForwardRef$3 = /*#__PURE__*/React.forwardRef(SvgGlobalMenu);
|
|
4348
4459
|
|
|
4349
|
-
var css$7 = {"global-menu-btn":"
|
|
4460
|
+
var css$7 = {"global-menu-btn":"pU-sAx","globalMenuIcon":"_77b19J","globalMenuBtn":"pU-sAx"};
|
|
4350
4461
|
|
|
4351
4462
|
const GlobalMenu = React__namespace.forwardRef((props, ref) => (React__namespace.createElement("button", Object.assign({ ref: ref, id: "global_menu_toggle", className: cx__default.default(css$7.globalMenuBtn, props.cx) }, props.rawProps),
|
|
4352
4463
|
React__namespace.createElement(uuiComponents.IconContainer, { icon: ForwardRef$3, cx: css$7.globalMenuIcon }))));
|
|
4353
4464
|
|
|
4354
|
-
var css$6 = {"container":"
|
|
4465
|
+
var css$6 = {"container":"WE-ZXQ","open":"HCqEOg"};
|
|
4355
4466
|
|
|
4356
4467
|
const MainMenuAvatar = React__namespace.forwardRef((props, ref) => (React__namespace.createElement("button", { ref: ref, className: cx__default.default(css$6.container, props.isDropdown && css$6.dropdown, props.isOpen && css$6.open, props.onClick && uuiCore.uuiMarkers.clickable, props.cx), onClick: props.onClick },
|
|
4357
4468
|
React__namespace.createElement(uuiComponents.Avatar, { size: "36", img: props.avatarUrl }),
|
|
@@ -4359,18 +4470,18 @@ const MainMenuAvatar = React__namespace.forwardRef((props, ref) => (React__names
|
|
|
4359
4470
|
props.isDropdown && (React__namespace.createElement("div", null,
|
|
4360
4471
|
React__namespace.createElement(uuiComponents.IconContainer, { icon: ForwardRef$1b, flipY: props.isOpen }))))));
|
|
4361
4472
|
|
|
4362
|
-
var css$5 = {"search-input":"
|
|
4473
|
+
var css$5 = {"search-input":"TTfdSh","searchInput":"TTfdSh"};
|
|
4363
4474
|
|
|
4364
4475
|
const MainMenuSearch = React__namespace.forwardRef((props, ref) => (React__namespace.createElement(uuiCore.IEditableDebouncer, Object.assign({}, props, { render: (iEditable) => {
|
|
4365
4476
|
var _a;
|
|
4366
4477
|
return (React__namespace.createElement(uuiComponents.TextInput, Object.assign({ iconPosition: "left", icon: ForwardRef$15, cancelIcon: ((_a = props.value) === null || _a === void 0 ? void 0 : _a.length) > 0 && ForwardRef$5 }, props, iEditable, { ref: ref, cx: uuiCore.cx(css$5.searchInput, props.cx) }, props.rawProps)));
|
|
4367
4478
|
} }))));
|
|
4368
4479
|
|
|
4369
|
-
var css$4 = {"container":"
|
|
4480
|
+
var css$4 = {"container":"_3T-pU8"};
|
|
4370
4481
|
|
|
4371
4482
|
const MainMenuIcon = React__namespace.forwardRef((props, ref) => (React__namespace.createElement(IconButton, Object.assign({ ref: ref, icon: props.icon, cx: uuiCore.cx(props.cx, css$4.container) }, props))));
|
|
4372
4483
|
|
|
4373
|
-
var css$3 = {"root":"
|
|
4484
|
+
var css$3 = {"root":"BnT69q"};
|
|
4374
4485
|
|
|
4375
4486
|
const Anchor = uuiCore.withMods(uuiComponents.Anchor, () => [css$3.root]);
|
|
4376
4487
|
|
|
@@ -4427,7 +4538,7 @@ var SvgShape = function SvgShape(props, ref) {
|
|
|
4427
4538
|
};
|
|
4428
4539
|
var ForwardRef$2 = /*#__PURE__*/React.forwardRef(SvgShape);
|
|
4429
4540
|
|
|
4430
|
-
var css$2 = {"root":"
|
|
4541
|
+
var css$2 = {"root":"_4lCJfq","drop-start":"AdLMQG","drop-over":"c2S0tc","link":"ojDuyS","drop-area":"UkObUB","icon-blue":"UA6kfJ","dropStart":"AdLMQG","dropOver":"c2S0tc","dropArea":"UkObUB","iconBlue":"UA6kfJ"};
|
|
4431
4542
|
|
|
4432
4543
|
class DropSpot extends React__namespace.Component {
|
|
4433
4544
|
constructor() {
|
|
@@ -4451,9 +4562,9 @@ class DropSpot extends React__namespace.Component {
|
|
|
4451
4562
|
}
|
|
4452
4563
|
}
|
|
4453
4564
|
|
|
4454
|
-
var css$1 = {"
|
|
4565
|
+
var css$1 = {"root":"_0Z9l9a","file-name":"mdbjDt","default-color":"Cdz4p1","doc-color":"_8t7qMj","xls-color":"I9oEud","pdf-color":"dv4UPH","movie-color":"aFiMoC","img-color":"HiIP6f","mov-color":"_0Vblnc","error-block":"VLVhhv","icons-block":"J5VDRn","fileName":"mdbjDt","defaultColor":"Cdz4p1","docColor":"_8t7qMj","xlsColor":"I9oEud","pdfColor":"dv4UPH","movieColor":"aFiMoC","imgColor":"HiIP6f","movColor":"_0Vblnc","errorBlock":"VLVhhv","iconsBlock":"J5VDRn"};
|
|
4455
4566
|
|
|
4456
|
-
var css = {"root":"
|
|
4567
|
+
var css = {"root":"plKduu"};
|
|
4457
4568
|
|
|
4458
4569
|
const SvgCircleProgress = React__namespace.forwardRef((props, ref) => {
|
|
4459
4570
|
const outsetRadius = props.size / 2 - 1;
|
|
@@ -4522,7 +4633,7 @@ const FileCard = React__namespace.forwardRef((props, ref) => {
|
|
|
4522
4633
|
case 'mp4':
|
|
4523
4634
|
case 'wmw':
|
|
4524
4635
|
case 'mkv':
|
|
4525
|
-
return React__namespace.createElement(uuiComponents.IconContainer, { size: 24, icon: fileIcons.videoIcon, cx: css$1.
|
|
4636
|
+
return React__namespace.createElement(uuiComponents.IconContainer, { size: 24, icon: fileIcons.videoIcon, cx: css$1.movColor });
|
|
4526
4637
|
case 'csv':
|
|
4527
4638
|
case 'xml':
|
|
4528
4639
|
return React__namespace.createElement(uuiComponents.IconContainer, { size: 24, icon: fileIcons.tableIcon, cx: css$1.defaultColor });
|
|
@@ -4561,8 +4672,8 @@ const FileCard = React__namespace.forwardRef((props, ref) => {
|
|
|
4561
4672
|
progress && progress < 100 && abortXHR();
|
|
4562
4673
|
onClick();
|
|
4563
4674
|
};
|
|
4564
|
-
return (React__namespace.createElement(FlexCell, { ref: ref, cx: uuiCore.cx(css$1.
|
|
4565
|
-
React__namespace.createElement(FlexRow, {
|
|
4675
|
+
return (React__namespace.createElement(FlexCell, { ref: ref, cx: uuiCore.cx(css$1.root, 'uui-file_card', (isLoading || (error === null || error === void 0 ? void 0 : error.isError)) && uuiCore.uuiMod.loading, componentCx, (error === null || error === void 0 ? void 0 : error.isError) && uuiCore.uuiMod.error), minWidth: width, width: !width ? '100%' : undefined },
|
|
4676
|
+
React__namespace.createElement(FlexRow, { size: "36", alignItems: "top", spacing: "6" },
|
|
4566
4677
|
fileExtension && getIcon(fileExtension),
|
|
4567
4678
|
React__namespace.createElement(FlexCell, { width: "100%" },
|
|
4568
4679
|
React__namespace.createElement(Text, { size: "18", fontSize: "14", lineHeight: "18", color: progress < 100 ? 'secondary' : 'primary', cx: css$1.fileName }, fileName),
|
|
@@ -4603,6 +4714,7 @@ exports.ColumnHeaderDropdown = ColumnHeaderDropdown;
|
|
|
4603
4714
|
exports.ColumnsConfigurationModal = ColumnsConfigurationModal;
|
|
4604
4715
|
exports.ConfirmationModal = ConfirmationModal;
|
|
4605
4716
|
exports.ControlGroup = ControlGroup;
|
|
4717
|
+
exports.CountIndicator = CountIndicator;
|
|
4606
4718
|
exports.DataPickerBody = DataPickerBody;
|
|
4607
4719
|
exports.DataPickerFooter = DataPickerFooter;
|
|
4608
4720
|
exports.DataPickerHeader = DataPickerHeader;
|
|
@@ -4673,7 +4785,9 @@ exports.RangeDatePickerBody = RangeDatePickerBody;
|
|
|
4673
4785
|
exports.RichTextView = RichTextView;
|
|
4674
4786
|
exports.ScrollBars = ScrollBars;
|
|
4675
4787
|
exports.SearchInput = SearchInput;
|
|
4788
|
+
exports.Slider = Slider;
|
|
4676
4789
|
exports.Spinner = Spinner;
|
|
4790
|
+
exports.StatusIndicator = StatusIndicator;
|
|
4677
4791
|
exports.SuccessAlert = SuccessAlert;
|
|
4678
4792
|
exports.SuccessNotification = SuccessNotification;
|
|
4679
4793
|
exports.SvgCircleProgress = SvgCircleProgress;
|
|
@@ -4691,8 +4805,7 @@ exports.VirtualList = VirtualList;
|
|
|
4691
4805
|
exports.WarningAlert = WarningAlert;
|
|
4692
4806
|
exports.WarningNotification = WarningNotification;
|
|
4693
4807
|
exports.allButtonColors = allButtonColors;
|
|
4694
|
-
exports.
|
|
4695
|
-
exports.allButtonSemanticColors = allButtonSemanticColors;
|
|
4808
|
+
exports.allButtonFills = allButtonFills;
|
|
4696
4809
|
exports.allEpamBadgeSemanticColors = allEpamBadgeSemanticColors;
|
|
4697
4810
|
exports.allFillStyles = allFillStyles;
|
|
4698
4811
|
exports.allFontStyles = allFontStyles;
|
|
@@ -4701,6 +4814,7 @@ exports.allLinkButtonColors = allLinkButtonColors;
|
|
|
4701
4814
|
exports.allRowSizes = allRowSizes;
|
|
4702
4815
|
exports.allSemanticColors = allSemanticColors;
|
|
4703
4816
|
exports.allSizes = allSizes;
|
|
4817
|
+
exports.allTextColors = allTextColors;
|
|
4704
4818
|
exports.allTextSizes = allTextSizes;
|
|
4705
4819
|
exports.applyBadgeMods = applyBadgeMods;
|
|
4706
4820
|
exports.applyButtonMods = applyButtonMods;
|
|
@@ -4709,6 +4823,7 @@ exports.applyDateSelectionMods = applyDateSelectionMods;
|
|
|
4709
4823
|
exports.applyInputAddonMods = applyInputAddonMods;
|
|
4710
4824
|
exports.applyNumericInputMods = applyNumericInputMods;
|
|
4711
4825
|
exports.applyProgressBarMods = applyProgressBarMods;
|
|
4826
|
+
exports.applySliderMods = applySliderMods;
|
|
4712
4827
|
exports.applySpinnerMods = applySpinnerMods;
|
|
4713
4828
|
exports.applySwitchMods = applySwitchMods;
|
|
4714
4829
|
exports.applyTagMods = applyTagMods;
|