@epam/uui 6.2.0-alpha.2 → 6.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/components/buttons/LinkButton.d.ts +2 -2
- package/components/buttons/LinkButton.d.ts.map +1 -1
- package/components/buttons/TabButton.d.ts +2 -2
- package/components/buttons/TabButton.d.ts.map +1 -1
- package/components/buttons/VerticalTabButton.d.ts +61 -4
- package/components/buttons/VerticalTabButton.d.ts.map +1 -1
- package/components/fileUpload/FileCard.d.ts.map +1 -1
- package/components/filters/FilterPickerBody.d.ts.map +1 -1
- package/components/filters/PresetPanel/Preset.d.ts +1 -0
- package/components/filters/PresetPanel/Preset.d.ts.map +1 -1
- package/components/filters/PresetPanel/PresetActionsDropdown.d.ts +1 -0
- package/components/filters/PresetPanel/PresetActionsDropdown.d.ts.map +1 -1
- package/components/filters/PresetPanel/PresetsPanel.d.ts +2 -0
- package/components/filters/PresetPanel/PresetsPanel.d.ts.map +1 -1
- package/components/inputs/timePicker/TimePickerBody.d.ts.map +1 -1
- package/components/layout/ScrollBars.d.ts +80 -3
- package/components/layout/ScrollBars.d.ts.map +1 -1
- package/components/layout/Tabs.d.ts +19 -0
- package/components/layout/Tabs.d.ts.map +1 -0
- package/components/layout/Tree.d.ts +41 -0
- package/components/layout/Tree.d.ts.map +1 -0
- package/components/layout/VirtualList.d.ts +3 -10
- package/components/layout/VirtualList.d.ts.map +1 -1
- package/components/layout/index.d.ts +2 -0
- package/components/layout/index.d.ts.map +1 -1
- package/components/navigation/MainMenu/Burger/BurgerButton.d.ts +5 -5
- package/components/navigation/MainMenu/Burger/BurgerButton.d.ts.map +1 -1
- package/components/navigation/MainMenu/MainMenuButton.d.ts +3 -3
- package/components/navigation/MainMenu/MainMenuButton.d.ts.map +1 -1
- package/components/navigation/MainMenu/MainMenuDropdown.d.ts +2 -4
- package/components/navigation/MainMenu/MainMenuDropdown.d.ts.map +1 -1
- package/components/navigation/index.d.ts +1 -0
- package/components/navigation/index.d.ts.map +1 -1
- package/components/overlays/DropdownMenu.d.ts.map +1 -1
- package/components/pickers/DataPickerBody.d.ts.map +1 -1
- package/components/pickers/PickerItem.d.ts.map +1 -1
- package/components/tables/DataTable.d.ts.map +1 -1
- package/components/tables/columnsConfigurationModal/ColumnRow.d.ts.map +1 -1
- package/components/tables/columnsConfigurationModal/ColumnsConfigurationModal.d.ts +2 -1
- package/components/tables/columnsConfigurationModal/ColumnsConfigurationModal.d.ts.map +1 -1
- package/components/tables/columnsConfigurationModal/PinIconButton.d.ts.map +1 -1
- package/components/typography/Text.d.ts +11 -5
- package/components/typography/Text.d.ts.map +1 -1
- package/index.esm.js +733 -464
- package/index.esm.js.map +1 -1
- package/index.js +738 -459
- package/index.js.map +1 -1
- package/package.json +7 -5
- package/settings.d.ts +16 -1
- package/settings.d.ts.map +1 -1
- package/stats.html +19 -1
- package/styles.css +3131 -2952
- package/styles.css.map +1 -1
package/index.js
CHANGED
|
@@ -14,6 +14,8 @@ var updateLocale = require('dayjs/plugin/updateLocale.js');
|
|
|
14
14
|
var objectSupport = require('dayjs/plugin/objectSupport');
|
|
15
15
|
var customParseFormat = require('dayjs/plugin/customParseFormat.js');
|
|
16
16
|
var isoWeek = require('dayjs/plugin/isoWeek.js');
|
|
17
|
+
var overlayscrollbarsReact = require('overlayscrollbars-react');
|
|
18
|
+
require('overlayscrollbars/styles/overlayscrollbars.css');
|
|
17
19
|
var isEqual = require('react-fast-compare');
|
|
18
20
|
var FocusLock = require('react-focus-lock');
|
|
19
21
|
|
|
@@ -154,7 +156,9 @@ var SvgNotificationInfoOutline = function SvgNotificationInfoOutline(props, ref)
|
|
|
154
156
|
viewBox: "0 0 24 24",
|
|
155
157
|
ref: ref
|
|
156
158
|
}, props), _path$K || (_path$K = /*#__PURE__*/React__namespace.createElement("path", {
|
|
157
|
-
|
|
159
|
+
fillRule: "evenodd",
|
|
160
|
+
d: "M11 17h2v-6h-2v6zm1-15C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8zM11 9h2V7h-2v2z",
|
|
161
|
+
clipRule: "evenodd"
|
|
158
162
|
})));
|
|
159
163
|
};
|
|
160
164
|
var ForwardRef$K = /*#__PURE__*/React.forwardRef(SvgNotificationInfoOutline);
|
|
@@ -169,7 +173,9 @@ var SvgNotificationInfoFill = function SvgNotificationInfoFill(props, ref) {
|
|
|
169
173
|
viewBox: "0 0 24 24",
|
|
170
174
|
ref: ref
|
|
171
175
|
}, props), _path$J || (_path$J = /*#__PURE__*/React__namespace.createElement("path", {
|
|
172
|
-
|
|
176
|
+
fillRule: "evenodd",
|
|
177
|
+
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-6h2v6zm0-8h-2V7h2v2z",
|
|
178
|
+
clipRule: "evenodd"
|
|
173
179
|
})));
|
|
174
180
|
};
|
|
175
181
|
var ForwardRef$J = /*#__PURE__*/React.forwardRef(SvgNotificationInfoFill);
|
|
@@ -185,7 +191,7 @@ var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
|
185
191
|
xmlns: "http://www.w3.org/2000/svg",
|
|
186
192
|
ref: ref
|
|
187
193
|
}, props), /*#__PURE__*/React__namespace.createElement("g", {
|
|
188
|
-
clipPath: "url(#
|
|
194
|
+
clipPath: "url(#0smlushu6n1uhrbtq_a)"
|
|
189
195
|
}, _path$I || (_path$I = /*#__PURE__*/React__namespace.createElement("path", {
|
|
190
196
|
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",
|
|
191
197
|
fill: "#F5F6FA"
|
|
@@ -206,7 +212,7 @@ var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
|
206
212
|
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",
|
|
207
213
|
fill: "#1D1E26"
|
|
208
214
|
})), /*#__PURE__*/React__namespace.createElement("mask", {
|
|
209
|
-
id: "
|
|
215
|
+
id: "0smlusms3cqehnlrc_b",
|
|
210
216
|
style: {
|
|
211
217
|
maskType: "alpha"
|
|
212
218
|
},
|
|
@@ -219,7 +225,7 @@ var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
|
219
225
|
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",
|
|
220
226
|
fill: "#9BDEFF"
|
|
221
227
|
}))), _g || (_g = /*#__PURE__*/React__namespace.createElement("g", {
|
|
222
|
-
mask: "url(#
|
|
228
|
+
mask: "url(#0smlusms3cqehnlrc_b)",
|
|
223
229
|
fillRule: "evenodd",
|
|
224
230
|
clipRule: "evenodd"
|
|
225
231
|
}, /*#__PURE__*/React__namespace.createElement("path", {
|
|
@@ -305,7 +311,7 @@ var SvgEmptyTable = function SvgEmptyTable(props, ref) {
|
|
|
305
311
|
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",
|
|
306
312
|
fill: "#fff"
|
|
307
313
|
}))), _defs || (_defs = /*#__PURE__*/React__namespace.createElement("defs", null, /*#__PURE__*/React__namespace.createElement("clipPath", {
|
|
308
|
-
id: "
|
|
314
|
+
id: "0smlushu6n1uhrbtq_a"
|
|
309
315
|
}, /*#__PURE__*/React__namespace.createElement("path", {
|
|
310
316
|
fill: "#fff",
|
|
311
317
|
transform: "translate(.552)",
|
|
@@ -793,7 +799,7 @@ var SvgFileFileExcelFill = function SvgFileFileExcelFill(props, ref) {
|
|
|
793
799
|
ref: ref
|
|
794
800
|
}, props), _path$d || (_path$d = /*#__PURE__*/React__namespace.createElement("path", {
|
|
795
801
|
fillRule: "evenodd",
|
|
796
|
-
d: "M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8l-6-
|
|
802
|
+
d: "M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8l-6-6zm2 16-1.5 1.5L12 17l-2.5 2.5L8 18l2.5-2.5L8 13l1.5-1.5L12 14l2.5-2.5L16 13l-2.5 2.5L16 18zm-3-9V3.5L18.5 9H13z",
|
|
797
803
|
clipRule: "evenodd"
|
|
798
804
|
})));
|
|
799
805
|
};
|
|
@@ -843,10 +849,10 @@ var SvgFileFileVideoFill = function SvgFileFileVideoFill(props, ref) {
|
|
|
843
849
|
viewBox: "0 0 24 24",
|
|
844
850
|
ref: ref
|
|
845
851
|
}, props), _path$a || (_path$a = /*#__PURE__*/React__namespace.createElement("path", {
|
|
846
|
-
d: "
|
|
852
|
+
d: "m14 15-5 3v-6l5 3z"
|
|
847
853
|
})), _path2$1 || (_path2$1 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
848
854
|
fillRule: "evenodd",
|
|
849
|
-
d: "M4 4c0-1.11.89-2 2-2h8l6 6v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V4zm9-.5V9h5.5L13 3.5zM8
|
|
855
|
+
d: "M4 4c0-1.11.89-2 2-2h8l6 6v12a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V4zm9-.5V9h5.5L13 3.5zM8 10v10l8-5-8-5z",
|
|
850
856
|
clipRule: "evenodd"
|
|
851
857
|
})));
|
|
852
858
|
};
|
|
@@ -863,7 +869,7 @@ var SvgFileFileTableFill = function SvgFileFileTableFill(props, ref) {
|
|
|
863
869
|
ref: ref
|
|
864
870
|
}, props), _path$9 || (_path$9 = /*#__PURE__*/React__namespace.createElement("path", {
|
|
865
871
|
fillRule: "evenodd",
|
|
866
|
-
d: "M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8l-6-
|
|
872
|
+
d: "M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8l-6-6zM9 19H6v-2h3v2zm0-3H6v-2h3v2zm0-3H6v-2h3v2zm4 6h-3v-2h3v2zm0-3h-3v-2h3v2zm0-3h-3v-2h3v2zm0-4V3.5L18.5 9H13z",
|
|
867
873
|
clipRule: "evenodd"
|
|
868
874
|
})));
|
|
869
875
|
};
|
|
@@ -956,14 +962,14 @@ var SvgSearchWithBackground = function SvgSearchWithBackground(props, ref) {
|
|
|
956
962
|
};
|
|
957
963
|
var ForwardRef$4 = /*#__PURE__*/React.forwardRef(SvgSearchWithBackground);
|
|
958
964
|
|
|
959
|
-
var css$1w = {"root":"
|
|
965
|
+
var css$1w = {"root":"K-RXLg","uui-spinner":"lgr1QK","uuiSpinner":"lgr1QK"};
|
|
960
966
|
|
|
961
967
|
function applySpinnerMods() {
|
|
962
968
|
return [css$1w.root, 'uui-spinner'];
|
|
963
969
|
}
|
|
964
970
|
const Spinner = /* @__PURE__ */uuiCore.withMods(uuiComponents.Spinner, applySpinnerMods);
|
|
965
971
|
|
|
966
|
-
var css$1v = {"root":"
|
|
972
|
+
var css$1v = {"root":"_4rwDuz","loading-word":"edKoQm","loadingWord":"edKoQm","animated-loading":"cJ2aht","animatedLoading":"cJ2aht","skeleton_loading":"i1s8WI","skeletonLoading":"i1s8WI"};
|
|
967
973
|
|
|
968
974
|
const TextPlaceholder = (props) => {
|
|
969
975
|
const pattern = ' ';
|
|
@@ -980,7 +986,7 @@ const TextPlaceholder = (props) => {
|
|
|
980
986
|
]), dangerouslySetInnerHTML: { __html: it } })))));
|
|
981
987
|
};
|
|
982
988
|
|
|
983
|
-
var css$1u = {"root":"-
|
|
989
|
+
var css$1u = {"root":"TKV-RQ","line-height":"p0-b-4","lineHeight":"p0-b-4","font-size":"O36flr","fontSize":"O36flr"};
|
|
984
990
|
|
|
985
991
|
function applyTextMods(mods) {
|
|
986
992
|
return [
|
|
@@ -1007,7 +1013,7 @@ const Text = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.Text, appl
|
|
|
1007
1013
|
};
|
|
1008
1014
|
});
|
|
1009
1015
|
|
|
1010
|
-
var css$1t = {"root":"
|
|
1016
|
+
var css$1t = {"root":"_7GVMYK"};
|
|
1011
1017
|
|
|
1012
1018
|
const Blocker = /* @__PURE__ */uuiCore.withMods(uuiComponents.Blocker, () => [css$1t.root], () => ({ renderSpinner: settings.blocker.renderSpinner }));
|
|
1013
1019
|
|
|
@@ -1418,6 +1424,22 @@ const tabButtonSettings = {
|
|
|
1418
1424
|
},
|
|
1419
1425
|
},
|
|
1420
1426
|
};
|
|
1427
|
+
const verticalTabButtonSettings = {
|
|
1428
|
+
icons: {
|
|
1429
|
+
clearIcon: ForwardRef$Q,
|
|
1430
|
+
foldingIcon: ForwardRef$P,
|
|
1431
|
+
dropdownIcon: ForwardRef$P,
|
|
1432
|
+
},
|
|
1433
|
+
sizes: {
|
|
1434
|
+
default: '48',
|
|
1435
|
+
countIndicatorMap: {
|
|
1436
|
+
30: '18',
|
|
1437
|
+
36: '18',
|
|
1438
|
+
48: '18',
|
|
1439
|
+
},
|
|
1440
|
+
},
|
|
1441
|
+
weight: 'semibold',
|
|
1442
|
+
};
|
|
1421
1443
|
const tagSettings = {
|
|
1422
1444
|
icons: {
|
|
1423
1445
|
clearIcon: ForwardRef$Q,
|
|
@@ -1489,13 +1511,14 @@ const settings = {
|
|
|
1489
1511
|
statusIndicator: statusIndicatorSettings,
|
|
1490
1512
|
switch: switchSettings,
|
|
1491
1513
|
tabButton: tabButtonSettings,
|
|
1514
|
+
verticalTabButton: verticalTabButtonSettings,
|
|
1492
1515
|
tag: tagSettings,
|
|
1493
1516
|
text: textSettings,
|
|
1494
1517
|
textArea: textAreaSettings,
|
|
1495
1518
|
textInput: textInputSettings,
|
|
1496
1519
|
};
|
|
1497
1520
|
|
|
1498
|
-
var css$1s = {"root":"
|
|
1521
|
+
var css$1s = {"root":"_4vzV11"};
|
|
1499
1522
|
|
|
1500
1523
|
function applyButtonMods(mods) {
|
|
1501
1524
|
return [
|
|
@@ -1513,7 +1536,7 @@ const Button = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.Button,
|
|
|
1513
1536
|
};
|
|
1514
1537
|
});
|
|
1515
1538
|
|
|
1516
|
-
var css$1r = {"root":"
|
|
1539
|
+
var css$1r = {"root":"v0XflL"};
|
|
1517
1540
|
|
|
1518
1541
|
function applyIconButtonMods(props) {
|
|
1519
1542
|
return ['uui-icon_button', `uui-color-${props.color || 'neutral'}`, css$1r.root];
|
|
@@ -1550,7 +1573,7 @@ function getIconClass(props) {
|
|
|
1550
1573
|
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'];
|
|
1551
1574
|
}
|
|
1552
1575
|
|
|
1553
|
-
var css$1q = {"root":"
|
|
1576
|
+
var css$1q = {"root":"_-2astL"};
|
|
1554
1577
|
|
|
1555
1578
|
const DEFAULT_COLOR = 'primary';
|
|
1556
1579
|
const LinkButton = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
@@ -1580,7 +1603,7 @@ const LinkButton = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
|
1580
1603
|
props.isDropdown && (React__namespace.createElement(uuiComponents.IconContainer, { icon: DropdownIcon, flipY: props.isOpen }))));
|
|
1581
1604
|
});
|
|
1582
1605
|
|
|
1583
|
-
var css$1p = {"root":"
|
|
1606
|
+
var css$1p = {"root":"gaW5AH"};
|
|
1584
1607
|
|
|
1585
1608
|
const CountIndicator = /* @__PURE__ */React.forwardRef((props, ref) => {
|
|
1586
1609
|
return (React__namespace.default.createElement("div", { ref: ref, className: cx__default.default([
|
|
@@ -1592,10 +1615,18 @@ const CountIndicator = /* @__PURE__ */React.forwardRef((props, ref) => {
|
|
|
1592
1615
|
]) }, props.caption));
|
|
1593
1616
|
});
|
|
1594
1617
|
|
|
1595
|
-
var css$1o = {"root":"
|
|
1618
|
+
var css$1o = {"root":"tdsef-","withNotify":"leQOnM"};
|
|
1596
1619
|
|
|
1597
|
-
const TabButton = /* @__PURE__ */React__namespace.default.forwardRef((props,
|
|
1620
|
+
const TabButton = /* @__PURE__ */React__namespace.default.forwardRef((props, refExternal) => {
|
|
1621
|
+
const refLocal = React__namespace.default.useRef(null);
|
|
1622
|
+
const ref = refExternal ?? refLocal;
|
|
1623
|
+
const { isActive } = uuiCore.useIsActive({
|
|
1624
|
+
isLinkActive: props.isLinkActive,
|
|
1625
|
+
link: props.link,
|
|
1626
|
+
isActive: props.isActive,
|
|
1627
|
+
});
|
|
1598
1628
|
const styles = [
|
|
1629
|
+
isActive && uuiCore.uuiMod.active,
|
|
1599
1630
|
css$1o.root,
|
|
1600
1631
|
'uui-tab-button',
|
|
1601
1632
|
`uui-size-${props.size || settings.tabButton.sizes.default}`,
|
|
@@ -1604,11 +1635,22 @@ const TabButton = /* @__PURE__ */React__namespace.default.forwardRef((props, ref
|
|
|
1604
1635
|
];
|
|
1605
1636
|
const DropdownIcon = props.dropdownIcon ? props.dropdownIcon : settings.tabButton.icons.dropdownIcon;
|
|
1606
1637
|
const ClearIcon = props.clearIcon ? props.clearIcon : settings.tabButton.icons.clearIcon;
|
|
1638
|
+
const handleOnKeyDown = (event) => {
|
|
1639
|
+
props.rawProps?.onKeyDown?.(event);
|
|
1640
|
+
const isLink = (props.link !== undefined
|
|
1641
|
+
|| props.href !== undefined);
|
|
1642
|
+
if (isLink
|
|
1643
|
+
&& event.code === 'Space'
|
|
1644
|
+
&& typeof ref != 'function') {
|
|
1645
|
+
ref.current?.click();
|
|
1646
|
+
}
|
|
1647
|
+
};
|
|
1607
1648
|
return (React__namespace.default.createElement(uuiComponents.Clickable, { ...props, rawProps: {
|
|
1608
1649
|
role: 'tab',
|
|
1609
1650
|
'aria-haspopup': props.isDropdown,
|
|
1610
1651
|
'aria-expanded': props.isOpen,
|
|
1611
1652
|
...props.rawProps,
|
|
1653
|
+
onKeyDown: handleOnKeyDown,
|
|
1612
1654
|
}, cx: styles, ref: ref },
|
|
1613
1655
|
props.icon && props.iconPosition !== 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
1614
1656
|
(props.caption || props.withNotify) && (React__namespace.default.createElement("div", { className: uuiCore.cx(uuiCore.uuiElement.caption) },
|
|
@@ -1620,18 +1662,134 @@ const TabButton = /* @__PURE__ */React__namespace.default.forwardRef((props, ref
|
|
|
1620
1662
|
props.onClear && !props.isDisabled && (React__namespace.default.createElement(uuiComponents.IconContainer, { cx: uuiCore.uuiMarkers.clickable, icon: ClearIcon, onClick: props.onClear }))));
|
|
1621
1663
|
});
|
|
1622
1664
|
|
|
1623
|
-
var css$1n = {"root":"
|
|
1665
|
+
var css$1n = {"root":"_8OICE6","noLeftPadding":"_8PKs0G","foldingArea":"_78wvG5","onlyFoldable":"LNaxgt","captionWrapper":"GWojew","withNotify":"mzjjIs"};
|
|
1666
|
+
|
|
1667
|
+
var css$1m = {"root":"_-5F5VL"};
|
|
1668
|
+
|
|
1669
|
+
const AvatarStack = /* @__PURE__ */uuiCore.withMods(uuiComponents.AvatarStack, () => [css$1m.root]);
|
|
1670
|
+
|
|
1671
|
+
var css$1l = {"root":"ZynZU0"};
|
|
1672
|
+
|
|
1673
|
+
const DEFAULT_FILL = 'solid';
|
|
1674
|
+
function applyBadgeMods(mods) {
|
|
1675
|
+
return [
|
|
1676
|
+
'uui-badge',
|
|
1677
|
+
css$1l.root,
|
|
1678
|
+
`uui-size-${mods.size || settings.badge.sizes.default}`,
|
|
1679
|
+
`uui-fill-${mods.fill || DEFAULT_FILL}`,
|
|
1680
|
+
`uui-color-${mods.color || 'info'}`,
|
|
1681
|
+
];
|
|
1682
|
+
}
|
|
1683
|
+
const Badge = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => {
|
|
1684
|
+
const styles = [applyBadgeMods(props), props.cx];
|
|
1685
|
+
const DropdownIcon = props.dropdownIcon ? props.dropdownIcon : settings.badge.icons.dropdownIcon;
|
|
1686
|
+
return (React__namespace.default.createElement(uuiComponents.Clickable, { ...props, rawProps: {
|
|
1687
|
+
'aria-haspopup': props.isDropdown,
|
|
1688
|
+
'aria-expanded': props.isOpen,
|
|
1689
|
+
...props.rawProps,
|
|
1690
|
+
}, cx: styles, ref: ref },
|
|
1691
|
+
(props.indicator && props.fill === 'outline') && (React__namespace.default.createElement("div", { className: "uui-indicator" })),
|
|
1692
|
+
props.icon && props.iconPosition !== 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
1693
|
+
props.caption && (React__namespace.default.createElement("div", { className: uuiCore.uuiElement.caption }, props.caption)),
|
|
1694
|
+
props.count !== undefined && props.count !== null && (React__namespace.default.createElement(CountIndicator, { key: "count-indicator", color: null, size: settings.badge.sizes.countIndicatorMap[props.size || settings.badge.sizes.default], caption: props.count })),
|
|
1695
|
+
props.icon && props.iconPosition === 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
1696
|
+
props.isDropdown && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: DropdownIcon, flipY: props.isOpen }))));
|
|
1697
|
+
});
|
|
1698
|
+
|
|
1699
|
+
var css$1k = {"root":"ADBnKS"};
|
|
1700
|
+
|
|
1701
|
+
function applyTagMods(props) {
|
|
1702
|
+
return [
|
|
1703
|
+
css$1k.root,
|
|
1704
|
+
`uui-size-${props.size || settings.tag.sizes.default}`,
|
|
1705
|
+
`uui-color-${props.color || 'neutral'}`,
|
|
1706
|
+
`uui-fill-${props.fill || 'solid'}`,
|
|
1707
|
+
'uui-tag',
|
|
1708
|
+
];
|
|
1709
|
+
}
|
|
1710
|
+
const Tag = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => {
|
|
1711
|
+
const styles = [applyTagMods(props), props.cx];
|
|
1712
|
+
const ClearIcon = props.clearIcon ? props.clearIcon : settings.tag.icons.clearIcon;
|
|
1713
|
+
const DropdownIcon = props.dropdownIcon ? props.dropdownIcon : settings.tag.icons.dropdownIcon;
|
|
1714
|
+
return (React__namespace.default.createElement(uuiComponents.Clickable, { ...props, rawProps: {
|
|
1715
|
+
'aria-haspopup': props.isDropdown,
|
|
1716
|
+
'aria-expanded': props.isOpen,
|
|
1717
|
+
...props.rawProps,
|
|
1718
|
+
}, cx: styles, ref: ref },
|
|
1719
|
+
props.icon && props.iconPosition !== 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
1720
|
+
props.caption && (React__namespace.default.createElement("div", { className: uuiCore.uuiElement.caption }, props.caption)),
|
|
1721
|
+
props.count !== undefined && props.count !== null && (React__namespace.default.createElement(CountIndicator, { color: (!props.color || props.color === 'neutral') ? 'white' : props.color, size: settings.tag.sizes.countIndicatorMap[(props.size || settings.tag.sizes.default)], caption: props.count })),
|
|
1722
|
+
props.icon && props.iconPosition === 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
1723
|
+
props.isDropdown && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: DropdownIcon, flipY: props.isOpen })),
|
|
1724
|
+
props.onClear && !props.isDisabled && (React__namespace.default.createElement(uuiComponents.IconContainer, { cx: uuiCore.uuiMarkers.clickable, icon: ClearIcon, onClick: props.onClear }))));
|
|
1725
|
+
});
|
|
1726
|
+
|
|
1727
|
+
var css$1j = {"root":"R3lgQz","page":"GavL40","spacer":"XKiV-t","mode-ghost":"Y9cxeS","modeGhost":"Y9cxeS"};
|
|
1624
1728
|
|
|
1625
|
-
function
|
|
1626
|
-
|
|
1729
|
+
function Paginator(props) {
|
|
1730
|
+
const renderPaginator = (params) => (React__namespace.default.createElement("nav", { role: "navigation", className: cx__default.default(css$1j.root, 'uui-paginator', `uui-size-${props.size || settings.paginator.sizes.default}`), ...params.rawProps },
|
|
1731
|
+
React__namespace.default.createElement(Button, { size: props.size || settings.paginator.sizes.default, icon: settings.paginator.icons.leftArrowIcon, onClick: params.goToPrev, isDisabled: params.isFirst || props.isDisabled, fill: "outline", color: "secondary" }),
|
|
1732
|
+
params.pages.map((page, index) => {
|
|
1733
|
+
if (page.type === 'spacer') {
|
|
1734
|
+
return (React__namespace.default.createElement(Button, { cx: cx__default.default(css$1j.spacer, css$1j.page), size: props.size || settings.paginator.sizes.default, key: `${index}_spacer`, caption: "...", fill: "ghost", color: "secondary", tabIndex: -1, isDisabled: props.isDisabled }));
|
|
1735
|
+
}
|
|
1736
|
+
else {
|
|
1737
|
+
return (React__namespace.default.createElement(Button, { cx: cx__default.default(css$1j[`mode-${!page.isActive && 'ghost'}`], css$1j.page), size: props.size || settings.paginator.sizes.default, key: page.pageNumber, caption: page.pageNumber, onClick: () => page.onClick?.(), rawProps: { 'aria-current': page.isActive }, fill: (page.isActive && 'outline') || 'ghost', color: "primary", isDisabled: props.isDisabled }));
|
|
1738
|
+
}
|
|
1739
|
+
}),
|
|
1740
|
+
React__namespace.default.createElement(Button, { size: props.size || settings.paginator.sizes.default, icon: settings.paginator.icons.rightArrowIcon, onClick: params.goToNext, isDisabled: params.isLast || props.isDisabled, fill: "outline", color: "secondary" })));
|
|
1741
|
+
return React__namespace.default.createElement(uuiComponents.Paginator, { ...props, render: renderPaginator });
|
|
1627
1742
|
}
|
|
1628
|
-
const VerticalTabButton = /* @__PURE__ */uuiCore.withMods(TabButton, applyVerticalTabButtonMods);
|
|
1629
1743
|
|
|
1630
|
-
var css$
|
|
1744
|
+
var css$1i = {"root":"kXKWWk","progress-bar":"oQtg3Z","progressBar":"oQtg3Z","progressBar-indeterminate":"gteY2b","progressBarIndeterminate":"gteY2b","size-12":"F2scht","size12":"F2scht","size-18":"_6kAsZW","size18":"_6kAsZW","size-24":"O6EcRI","size24":"O6EcRI"};
|
|
1745
|
+
|
|
1746
|
+
const IndeterminateBar = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
1747
|
+
return (React__namespace.createElement("div", { ref: ref, className: cx__default.default('uui-indeterminate_bar', props.cx, css$1i.root, css$1i[`size-${props.size || 12}`]) },
|
|
1748
|
+
React__namespace.createElement("div", { className: cx__default.default(css$1i.progressBar) })));
|
|
1749
|
+
});
|
|
1750
|
+
|
|
1751
|
+
var css$1h = {"root":"UKvE7P","striped":"VbxMEC","animate-stripes":"AVth0h","animateStripes":"AVth0h","size-12":"AIiYu8","size12":"AIiYu8","size-18":"RAgKy4","size18":"RAgKy4","size-24":"bdwz8S","size24":"bdwz8S"};
|
|
1752
|
+
|
|
1753
|
+
const DEFAULT_SIZE = '12';
|
|
1754
|
+
function applyProgressBarMods(mods) {
|
|
1755
|
+
const size = mods.size || DEFAULT_SIZE;
|
|
1756
|
+
return [
|
|
1757
|
+
css$1h.root,
|
|
1758
|
+
css$1h[`size-${size}`],
|
|
1759
|
+
mods.striped && css$1h.striped,
|
|
1760
|
+
];
|
|
1761
|
+
}
|
|
1762
|
+
const ProgressBar = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.ProgressBar, applyProgressBarMods, (props) => ({
|
|
1763
|
+
hideLabel: props.hideLabel || props.striped,
|
|
1764
|
+
}));
|
|
1765
|
+
|
|
1766
|
+
var css$1g = {"root":"wAZFgx"};
|
|
1767
|
+
|
|
1768
|
+
const IndicatorBar = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
1769
|
+
const { progress } = props;
|
|
1770
|
+
return progress || progress === 0 ? (React__namespace.createElement(ProgressBar, { ref: ref, progress: progress, cx: cx__default.default(css$1g.root, props.cx), hideLabel: true })) : (React__namespace.createElement(IndeterminateBar, { ref: ref, cx: cx__default.default(css$1g.root, props.cx) }));
|
|
1771
|
+
});
|
|
1772
|
+
|
|
1773
|
+
var css$1f = {"root":"_3rssqT"};
|
|
1774
|
+
|
|
1775
|
+
const StatusIndicator = /* @__PURE__ */React.forwardRef((props, ref) => {
|
|
1776
|
+
return (React__namespace.default.createElement("div", { ref: ref, className: cx__default.default([
|
|
1777
|
+
css$1f.root,
|
|
1778
|
+
`uui-size-${props.size || settings.statusIndicator.sizes.default}`,
|
|
1779
|
+
'uui-status_indicator',
|
|
1780
|
+
`uui-color-${props.color || 'neutral'}`,
|
|
1781
|
+
`uui-fill-${props.fill || 'solid'}`,
|
|
1782
|
+
props.cx,
|
|
1783
|
+
]) },
|
|
1784
|
+
React__namespace.default.createElement("div", { className: "uui-status_indicator-dot" }),
|
|
1785
|
+
React__namespace.default.createElement("p", { className: "uui-status_indicator-caption" }, props.caption)));
|
|
1786
|
+
});
|
|
1787
|
+
|
|
1788
|
+
var css$1e = {"root":"gaSdU1"};
|
|
1631
1789
|
|
|
1632
1790
|
function applyCheckboxMods(mods) {
|
|
1633
1791
|
return [
|
|
1634
|
-
css$
|
|
1792
|
+
css$1e.root,
|
|
1635
1793
|
`uui-size-${mods.size || settings.checkbox.sizes.default}`,
|
|
1636
1794
|
'uui-control-mode-' + (mods.mode || 'form'),
|
|
1637
1795
|
'uui-color-primary',
|
|
@@ -1645,11 +1803,11 @@ const applyUUICheckboxProps = (props) => {
|
|
|
1645
1803
|
};
|
|
1646
1804
|
const Checkbox = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.Checkbox, applyCheckboxMods, applyUUICheckboxProps);
|
|
1647
1805
|
|
|
1648
|
-
var css$
|
|
1806
|
+
var css$1d = {"root":"M28xhG"};
|
|
1649
1807
|
|
|
1650
1808
|
function applyRadioInputMods(mods) {
|
|
1651
1809
|
return [
|
|
1652
|
-
css$
|
|
1810
|
+
css$1d.root,
|
|
1653
1811
|
`uui-size-${mods.size || settings.radioInput.sizes.default}`,
|
|
1654
1812
|
'uui-radio-input-container',
|
|
1655
1813
|
'uui-color-primary',
|
|
@@ -1657,11 +1815,11 @@ function applyRadioInputMods(mods) {
|
|
|
1657
1815
|
}
|
|
1658
1816
|
const RadioInput = /* @__PURE__ */uuiCore.withMods(uuiComponents.RadioInput, applyRadioInputMods, (props) => ({ icon: props.icon ? props.icon : settings.radioInput.icons.dotIcon }));
|
|
1659
1817
|
|
|
1660
|
-
var css$
|
|
1818
|
+
var css$1c = {"root":"tBweim"};
|
|
1661
1819
|
|
|
1662
1820
|
function applySwitchMods(mods) {
|
|
1663
1821
|
return [
|
|
1664
|
-
css$
|
|
1822
|
+
css$1c.root,
|
|
1665
1823
|
`uui-size-${mods.size || settings.switch.sizes.default}`,
|
|
1666
1824
|
'uui-color-primary',
|
|
1667
1825
|
];
|
|
@@ -1681,7 +1839,7 @@ var EditMode;
|
|
|
1681
1839
|
EditMode["INLINE"] = "inline";
|
|
1682
1840
|
})(EditMode || (EditMode = {}));
|
|
1683
1841
|
|
|
1684
|
-
var textInputCss = {"root":"
|
|
1842
|
+
var textInputCss = {"root":"_9pM85m"};
|
|
1685
1843
|
|
|
1686
1844
|
const DEFAULT_MODE$3 = EditMode.FORM;
|
|
1687
1845
|
function applyTextInputMods(mods) {
|
|
@@ -1706,9 +1864,9 @@ const SearchInput = /* @__PURE__ */React__namespace.default.forwardRef((props, r
|
|
|
1706
1864
|
} }));
|
|
1707
1865
|
});
|
|
1708
1866
|
|
|
1709
|
-
var css$
|
|
1867
|
+
var css$1b = {"root":"BO21Fj"};
|
|
1710
1868
|
|
|
1711
|
-
const ControlGroup = /* @__PURE__ */uuiCore.withMods(uuiComponents.ControlGroup, () => [css$
|
|
1869
|
+
const ControlGroup = /* @__PURE__ */uuiCore.withMods(uuiComponents.ControlGroup, () => [css$1b.root, 'uui-control-group']);
|
|
1712
1870
|
|
|
1713
1871
|
function MultiSwitchComponent(props, ref) {
|
|
1714
1872
|
return (React__namespace.createElement(ControlGroup, { ref: ref, rawProps: {
|
|
@@ -1722,13 +1880,13 @@ function MultiSwitchComponent(props, ref) {
|
|
|
1722
1880
|
}
|
|
1723
1881
|
const MultiSwitch = /* @__PURE__ */React__namespace.forwardRef(MultiSwitchComponent);
|
|
1724
1882
|
|
|
1725
|
-
var css$
|
|
1883
|
+
var css$1a = {"root":"PgOwFa"};
|
|
1726
1884
|
|
|
1727
1885
|
const DEFAULT_MODE$2 = EditMode.FORM;
|
|
1728
1886
|
function applyNumericInputMods(mods) {
|
|
1729
1887
|
return [
|
|
1730
1888
|
textInputCss.root,
|
|
1731
|
-
css$
|
|
1889
|
+
css$1a.root,
|
|
1732
1890
|
`uui-size-${mods.size || settings.numericInput.sizes.default}`,
|
|
1733
1891
|
'uui-control-mode-' + (mods.mode || DEFAULT_MODE$2),
|
|
1734
1892
|
];
|
|
@@ -1742,12 +1900,12 @@ const NumericInput = /* @__PURE__ */uuiCore.withMods(uuiComponents.NumericInput,
|
|
|
1742
1900
|
};
|
|
1743
1901
|
});
|
|
1744
1902
|
|
|
1745
|
-
var css$
|
|
1903
|
+
var css$19 = {"root":"LzQnoU"};
|
|
1746
1904
|
|
|
1747
1905
|
const DEFAULT_MODE$1 = EditMode.FORM;
|
|
1748
1906
|
function applyTextAreaMods(mods) {
|
|
1749
1907
|
return [
|
|
1750
|
-
css$
|
|
1908
|
+
css$19.root,
|
|
1751
1909
|
'uui-textarea',
|
|
1752
1910
|
'uui-size-' + (mods.size || settings.textArea.sizes.default),
|
|
1753
1911
|
'uui-control-mode-' + (mods.mode || DEFAULT_MODE$1),
|
|
@@ -1783,18 +1941,18 @@ function TREE_SHAKEABLE_INIT$1() {
|
|
|
1783
1941
|
};
|
|
1784
1942
|
}
|
|
1785
1943
|
|
|
1786
|
-
var css$
|
|
1944
|
+
var css$18 = {"root":"oQ2OvB"};
|
|
1787
1945
|
|
|
1788
1946
|
function applyDropdownContainerMods(mods) {
|
|
1789
1947
|
return [
|
|
1790
|
-
css$
|
|
1948
|
+
css$18.root,
|
|
1791
1949
|
mods.vPadding && `vPadding-${mods.vPadding}`,
|
|
1792
1950
|
mods.padding && `padding-${mods.padding}`,
|
|
1793
1951
|
];
|
|
1794
1952
|
}
|
|
1795
1953
|
const DropdownContainer = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.DropdownContainer, applyDropdownContainerMods);
|
|
1796
1954
|
|
|
1797
|
-
var css$
|
|
1955
|
+
var css$17 = {"root":"iQONol","timepicker-input":"BnXlx8","timepickerInput":"BnXlx8","ltr-always":"UQJvrt","ltrAlways":"UQJvrt"};
|
|
1798
1956
|
|
|
1799
1957
|
const uuiTimePicker = {
|
|
1800
1958
|
container: 'uui-timepicker-container',
|
|
@@ -1833,17 +1991,17 @@ function TimePickerBody(props) {
|
|
|
1833
1991
|
const minutesToSubtract = value.minute() % minutesStep === 0 ? minutesStep : value.minute() % minutesStep;
|
|
1834
1992
|
onMinutesChange(value.subtract(minutesToSubtract, 'm').minute());
|
|
1835
1993
|
};
|
|
1836
|
-
return (React__namespace.createElement("div", { className: uuiCore.cx(css$
|
|
1837
|
-
React__namespace.createElement("div", { className: css$
|
|
1994
|
+
return (React__namespace.createElement("div", { className: uuiCore.cx(css$17.root, uuiTimePicker.container, props.cx), ref: props.forwardedRef, ...props.rawProps },
|
|
1995
|
+
React__namespace.createElement("div", { className: css$17.ltrAlways },
|
|
1838
1996
|
React__namespace.createElement("div", { className: uuiTimePicker.elementContainer },
|
|
1839
1997
|
React__namespace.createElement(uuiComponents.IconContainer, { size: 18, rawProps: { 'aria-label': 'Increment hours' }, cx: uuiTimePicker.iconUp, icon: ForwardRef$P, onClick: () => onHoursChange(uuiDayjs.dayjs().set(props.value).add(1, 'h').hour()) }),
|
|
1840
1998
|
React__namespace.createElement(uuiComponents.NumericInput, { cx: uuiTimePicker.input, onValueChange: onHoursChange, value: +(uuiDayjs.dayjs()
|
|
1841
1999
|
.set(props.value)
|
|
1842
|
-
.format(MAX_HOURS === FORMAT_12H ? 'hh' : 'HH')), min: MIN_HOURS, max: MAX_HOURS }),
|
|
2000
|
+
.format(MAX_HOURS === FORMAT_12H ? 'hh' : 'HH')), isReadonly: true, min: MIN_HOURS, max: MAX_HOURS }),
|
|
1843
2001
|
React__namespace.createElement(uuiComponents.IconContainer, { size: 18, rawProps: { 'aria-label': 'Decrement hours' }, cx: uuiTimePicker.iconDown, icon: ForwardRef$P, onClick: () => onHoursChange(uuiDayjs.dayjs().set(props.value).subtract(1, 'h').hour()) })),
|
|
1844
2002
|
React__namespace.createElement("div", { className: uuiTimePicker.elementContainer },
|
|
1845
2003
|
React__namespace.createElement(uuiComponents.IconContainer, { size: 18, rawProps: { 'aria-label': 'Increment minutes' }, cx: uuiTimePicker.iconUp, icon: ForwardRef$P, onClick: handleMinutesUpClick }),
|
|
1846
|
-
React__namespace.createElement(uuiComponents.NumericInput, { cx: uuiTimePicker.input, onValueChange: onMinutesChange, value: +uuiDayjs.dayjs().set(props.value).format('m'), min: MIN_MINUTES, max: MAX_MINUTES }),
|
|
2004
|
+
React__namespace.createElement(uuiComponents.NumericInput, { cx: uuiTimePicker.input, onValueChange: onMinutesChange, value: +uuiDayjs.dayjs().set(props.value).format('m'), isReadonly: true, min: MIN_MINUTES, max: MAX_MINUTES }),
|
|
1847
2005
|
React__namespace.createElement(uuiComponents.IconContainer, { size: 18, rawProps: { 'aria-label': 'Decrement minutes' }, cx: uuiTimePicker.iconDown, icon: ForwardRef$P, onClick: handleMinutesDownClick }))),
|
|
1848
2006
|
MAX_HOURS === FORMAT_12H && (React__namespace.createElement("div", { className: uuiTimePicker.elementContainer },
|
|
1849
2007
|
React__namespace.createElement(uuiComponents.IconContainer, { size: 18, cx: uuiTimePicker.iconUp, icon: ForwardRef$P, onClick: onTimeTypeChange }),
|
|
@@ -1977,7 +2135,7 @@ function TimePickerComponent(props, ref) {
|
|
|
1977
2135
|
state.value && state.inputValue && saveTime(state.value);
|
|
1978
2136
|
};
|
|
1979
2137
|
const renderInput = (inputProps) => {
|
|
1980
|
-
return (React__namespace.default.createElement(TextInput, { ...inputProps, onClick: null, size: props.size, isDisabled: props.isDisabled, isReadonly: props.isReadonly, isInvalid: props.isInvalid, cx: [css$
|
|
2138
|
+
return (React__namespace.default.createElement(TextInput, { ...inputProps, onClick: null, size: props.size, isDisabled: props.isDisabled, isReadonly: props.isReadonly, isInvalid: props.isInvalid, cx: [css$17.root, css$17.timepickerInput, props.inputCx], value: state.inputValue, onValueChange: handleInputChange, onCancel: !props.disableClear && onClear, onFocus: handleFocus, onBlur: handleBlur, isDropdown: false, placeholder: props.placeholder ? props.placeholder : getFormat(), mode: props.mode || DEFAULT_MODE, rawProps: props.rawProps?.input }));
|
|
1981
2139
|
};
|
|
1982
2140
|
const renderBody = (bodyProps) => {
|
|
1983
2141
|
const { forwardedRef, onValueChange, ...timePickerBodyProps } = props;
|
|
@@ -1988,37 +2146,37 @@ function TimePickerComponent(props, ref) {
|
|
|
1988
2146
|
}
|
|
1989
2147
|
const TimePicker = /* @__PURE__ */React__namespace.default.forwardRef(TimePickerComponent);
|
|
1990
2148
|
|
|
1991
|
-
var css$
|
|
2149
|
+
var css$16 = {"root":"y9iBid"};
|
|
1992
2150
|
|
|
1993
2151
|
function applyInputAddonMods() {
|
|
1994
2152
|
return [
|
|
1995
|
-
css$
|
|
2153
|
+
css$16.root,
|
|
1996
2154
|
];
|
|
1997
2155
|
}
|
|
1998
2156
|
const InputAddon = /* @__PURE__ */uuiCore.withMods(uuiComponents.InputAddon, applyInputAddonMods);
|
|
1999
2157
|
|
|
2000
|
-
var css$
|
|
2158
|
+
var css$15 = {"root":"iyMhGP"};
|
|
2001
2159
|
|
|
2002
2160
|
function applySliderMods() {
|
|
2003
|
-
return [css$
|
|
2161
|
+
return [css$15.root, 'uui-color-neutral'];
|
|
2004
2162
|
}
|
|
2005
2163
|
const Slider = /* @__PURE__ */uuiCore.withMods(uuiComponents.Slider, applySliderMods);
|
|
2006
2164
|
|
|
2007
|
-
var css$
|
|
2165
|
+
var css$14 = {"root":"kJkPM0"};
|
|
2008
2166
|
|
|
2009
2167
|
function applyTooltipMods(mods) {
|
|
2010
2168
|
return [
|
|
2011
|
-
css$
|
|
2169
|
+
css$14.root,
|
|
2012
2170
|
`uui-color-${mods.color || 'inverted'}`,
|
|
2013
2171
|
];
|
|
2014
2172
|
}
|
|
2015
2173
|
const Tooltip = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.Tooltip, applyTooltipMods);
|
|
2016
2174
|
|
|
2017
|
-
var css$
|
|
2175
|
+
var css$13 = {"root":"gnsYhI","tooltip":"fjucPA"};
|
|
2018
2176
|
|
|
2019
2177
|
function applyRatingMods(mods) {
|
|
2020
2178
|
return [
|
|
2021
|
-
css$
|
|
2179
|
+
css$13.root,
|
|
2022
2180
|
`uui-size-${mods.size || settings.rating.sizes.default}`,
|
|
2023
2181
|
];
|
|
2024
2182
|
}
|
|
@@ -2028,17 +2186,94 @@ const Rating = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.Rating,
|
|
|
2028
2186
|
Tooltip,
|
|
2029
2187
|
}));
|
|
2030
2188
|
|
|
2031
|
-
var css$
|
|
2189
|
+
var css$12 = {"drag-handle-wrapper":"Wu725P","dragHandleWrapper":"Wu725P","with-indent":"fPa6fV","withIndent":"fPa6fV","drag-handle":"z1C-Pm","dragHandle":"z1C-Pm","icon-container":"_98if5G","iconContainer":"_98if5G"};
|
|
2032
2190
|
|
|
2033
|
-
|
|
2034
|
-
|
|
2035
|
-
|
|
2036
|
-
|
|
2037
|
-
|
|
2038
|
-
|
|
2191
|
+
function DataRowAddons(props) {
|
|
2192
|
+
const row = props.rowProps;
|
|
2193
|
+
const getIndent = () => {
|
|
2194
|
+
return (row.indent - 1) * settings.dataTable.sizes.body.indentUnitMap[props.size || settings.dataTable.sizes.body.row];
|
|
2195
|
+
};
|
|
2196
|
+
const getWidth = () => {
|
|
2197
|
+
return settings.dataTable.sizes.body.indentWidthMap[props.size || settings.dataTable.sizes.body.row];
|
|
2198
|
+
};
|
|
2199
|
+
const renderDragHandle = () => {
|
|
2200
|
+
if (props.renderDragHandle) {
|
|
2201
|
+
return props.renderDragHandle({ rowProps: props.rowProps, eventHandlers: props.eventHandlers });
|
|
2202
|
+
}
|
|
2203
|
+
return (React__namespace.default.createElement("div", { key: "dh", className: cx__default.default(css$12.dragHandleWrapper, row.indent > 0 && css$12.withIndent), style: { width: row.indent > 0 ? (getIndent() + getWidth()) : 0 }, ...props.eventHandlers },
|
|
2204
|
+
React__namespace.default.createElement(uuiComponents.DragHandle, { cx: css$12.dragHandle })));
|
|
2205
|
+
};
|
|
2206
|
+
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
2207
|
+
row.dnd?.srcData && renderDragHandle(),
|
|
2208
|
+
row?.checkbox?.isVisible && (React__namespace.default.createElement(Checkbox, { key: "cb", cx: "uui-dr_addons-checkbox", tabIndex: props.tabIndex, size: settings.dataTable.sizes.body.checkboxMap[props.size], value: row.isChecked, indeterminate: !row.isChecked && row.isChildrenChecked, onValueChange: () => row.onCheck?.(row), isDisabled: row.checkbox.isDisabled, isInvalid: row.checkbox.isInvalid })),
|
|
2209
|
+
row.indent > 0 && (React__namespace.default.createElement("div", { key: "fold", className: cx__default.default('uui-dr_addons-indent', `uui-size-${props.size || settings.dataTable.sizes.body.row}`), style: { marginInlineStart: getIndent(), width: getWidth() } }, row.isFoldable && (React__namespace.default.createElement(uuiComponents.IconContainer, { rawProps: {
|
|
2210
|
+
'aria-label': row.isFolded ? 'Unfold' : 'Fold',
|
|
2211
|
+
role: 'button',
|
|
2212
|
+
}, key: "icon", icon: settings.dataTable.icons.body.foldingIcon, cx: [
|
|
2213
|
+
uuiCore.uuiElement.foldingArrow, uuiCore.uuiMarkers.clickable, css$12.iconContainer,
|
|
2214
|
+
], rotate: row.isFolded ? '90ccw' : '0', onClick: () => row.onFold(row), size: settings.dataTable.sizes.body.iconMap[props.size || settings.dataTable.sizes.body.row] }))))));
|
|
2215
|
+
}
|
|
2216
|
+
|
|
2217
|
+
function VerticalTabButtonComponent(props, ref) {
|
|
2218
|
+
const { isActive } = uuiCore.useIsActive({
|
|
2219
|
+
isLinkActive: props.isLinkActive,
|
|
2220
|
+
link: props.link,
|
|
2221
|
+
isActive: props.isActive,
|
|
2222
|
+
});
|
|
2223
|
+
const styles = [
|
|
2224
|
+
css$1n.root,
|
|
2225
|
+
'uui-vertical-tab-button',
|
|
2226
|
+
`uui-size-${props.size || settings.verticalTabButton.sizes.default}`,
|
|
2227
|
+
isActive && uuiCore.uuiMod.active,
|
|
2228
|
+
props.indent > 0 && css$1n.noLeftPadding,
|
|
2229
|
+
!props.onClick && props.onFold && css$1n.onlyFoldable,
|
|
2230
|
+
...getIconClass(props),
|
|
2231
|
+
props.cx,
|
|
2232
|
+
];
|
|
2233
|
+
if (props.count !== undefined && props.count !== null) {
|
|
2234
|
+
uuiCore.devLogger.warn('VerticalTabButton: count prop is deprecated. Use renderAddons prop instead.');
|
|
2235
|
+
}
|
|
2236
|
+
if (props.onClear !== undefined && props.onClear !== null) {
|
|
2237
|
+
uuiCore.devLogger.warn('VerticalTabButton: onClear prop is deprecated. Use renderAddons prop instead.');
|
|
2238
|
+
}
|
|
2239
|
+
if (props.clearIcon !== undefined && props.clearIcon !== null) {
|
|
2240
|
+
uuiCore.devLogger.warn('VerticalTabButton: clearIcon prop is deprecated. Use renderAddons prop instead.');
|
|
2241
|
+
}
|
|
2242
|
+
const DropdownIcon = props.dropdownIcon ? props.dropdownIcon : settings.verticalTabButton.icons.dropdownIcon;
|
|
2243
|
+
const ClearIcon = props.clearIcon ? props.clearIcon : settings.verticalTabButton.icons.clearIcon;
|
|
2244
|
+
return (React__namespace.default.createElement(uuiComponents.Clickable, { ...props, onClick: props.onClick || props.onFold, rawProps: {
|
|
2245
|
+
role: 'tab',
|
|
2246
|
+
...props.rawProps,
|
|
2247
|
+
}, cx: styles, ref: ref },
|
|
2248
|
+
props.indent > 0 && (React__namespace.default.createElement("div", { key: "fold", className: uuiCore.cx(css$1n.foldingArea, props.onFold && uuiCore.uuiMarkers.clickable), style: { '--uui-folding-indent': `${props.indent - 1}` }, onClick: props.onFold }, props.isFoldable && (React__namespace.default.createElement(uuiComponents.IconContainer, { rawProps: {
|
|
2249
|
+
'aria-label': props.isFolded ? 'Unfold' : 'Fold',
|
|
2250
|
+
role: 'button',
|
|
2251
|
+
}, key: "icon", icon: settings.verticalTabButton.icons.foldingIcon, cx: [
|
|
2252
|
+
uuiCore.uuiElement.foldingArrow, css$1n.iconContainer,
|
|
2253
|
+
], rotate: props.isFolded ? '90ccw' : '0', size: settings.dataTable.sizes.body.iconMap[props.size || settings.dataTable.sizes.body.row] })))),
|
|
2254
|
+
props.icon && props.iconPosition !== 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
2255
|
+
(props.caption || props.withNotify) && (React__namespace.default.createElement("div", { className: css$1n.captionWrapper },
|
|
2256
|
+
props.caption && React__namespace.default.createElement("div", { className: uuiCore.cx(uuiCore.uuiElement.caption, `uui-vertical-tab-button-weight-${props.weight || settings.verticalTabButton.weight}`) }, props.caption),
|
|
2257
|
+
props.withNotify && React__namespace.default.createElement("div", { className: css$1n.withNotify }))),
|
|
2258
|
+
props.icon && props.iconPosition === 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
2259
|
+
props.count !== undefined && props.count !== null && (React__namespace.default.createElement(CountIndicator, { color: "neutral", size: settings.verticalTabButton.sizes.countIndicatorMap[props.size || settings.verticalTabButton.sizes.default], caption: props.count })),
|
|
2260
|
+
props.isDropdown && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: DropdownIcon, flipY: props.isOpen })),
|
|
2261
|
+
props.onClear && !props.isDisabled && (React__namespace.default.createElement(uuiComponents.IconContainer, { cx: uuiCore.uuiMarkers.clickable, icon: ClearIcon, onClick: props.onClear })),
|
|
2262
|
+
props.renderAddons && props.renderAddons()));
|
|
2263
|
+
}
|
|
2264
|
+
const VerticalTabButton = /* @__PURE__ */React__namespace.default.forwardRef(VerticalTabButtonComponent);
|
|
2265
|
+
|
|
2266
|
+
var css$11 = {"root":"y-aBPX","main-path":"ZeqG-n","mainPath":"ZeqG-n","content-wrapper":"_8-VGbx","contentWrapper":"_8-VGbx","content":"f1Bo97","action-wrapper":"yHHIyH","actionWrapper":"yHHIyH","icon-wrapper":"_-3xjG7","iconWrapper":"_-3xjG7","icon":"py2Lun","close-icon":"UW5usS","closeIcon":"UW5usS"};
|
|
2267
|
+
|
|
2268
|
+
const Alert = /* @__PURE__ */React__namespace.forwardRef((props, ref) => (React__namespace.createElement("div", { role: "alert", ref: ref, className: cx__default.default('uui-alert', css$11.root, props.color && `uui-color-${props.color}`, props.cx, `uui-size-${props.size || settings.alert.sizes.default}`), ...props.rawProps },
|
|
2269
|
+
React__namespace.createElement("div", { className: css$11.mainPath },
|
|
2270
|
+
React__namespace.createElement("div", { className: css$11.contentWrapper },
|
|
2271
|
+
props.icon && (React__namespace.createElement("div", { className: css$11.iconWrapper },
|
|
2272
|
+
React__namespace.createElement(uuiComponents.IconContainer, { icon: props.icon, cx: css$11.icon }))),
|
|
2273
|
+
React__namespace.createElement("div", { className: css$11.content },
|
|
2039
2274
|
props.children,
|
|
2040
|
-
props.actions && (React__namespace.createElement("div", { className: css$
|
|
2041
|
-
props.onClose && React__namespace.createElement(IconButton, { icon: settings.alert.icons.closeIcon, color: "neutral", onClick: props.onClose, cx: css$
|
|
2275
|
+
props.actions && (React__namespace.createElement("div", { className: css$11.actionWrapper }, props.actions.map((action) => (React__namespace.createElement(LinkButton, { caption: action.name, onClick: action.action, key: action.name, cx: css$11.actionLink, size: settings.alert.sizes.actionMap[props.size || settings.alert.sizes.default] }))))))),
|
|
2276
|
+
props.onClose && React__namespace.createElement(IconButton, { icon: settings.alert.icons.closeIcon, color: "neutral", onClick: props.onClose, cx: css$11.closeIcon })))));
|
|
2042
2277
|
const WarningAlert = /* @__PURE__ */React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, { icon: settings.alert.icons.warningIcon, color: "warning", ref: ref, ...props }));
|
|
2043
2278
|
const SuccessAlert = /* @__PURE__ */React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, { icon: settings.alert.icons.successIcon, color: "success", ref: ref, ...props }));
|
|
2044
2279
|
const HintAlert = /* @__PURE__ */React__namespace.forwardRef((props, ref) => React__namespace.createElement(Alert, { icon: settings.alert.icons.infoIcon, color: "info", ref: ref, ...props }));
|
|
@@ -2046,7 +2281,7 @@ const ErrorAlert = /* @__PURE__ */React__namespace.forwardRef((props, ref) => Re
|
|
|
2046
2281
|
|
|
2047
2282
|
const Dropdown = /* @__PURE__ */uuiCore.withMods(uuiComponents.Dropdown);
|
|
2048
2283
|
|
|
2049
|
-
var css$
|
|
2284
|
+
var css$10 = {"submenu-root-item-rtl":"kt6hNc","submenuRootItemRtl":"kt6hNc","icon-after":"cvuxMu","iconAfter":"cvuxMu","submenu-root-item":"jSfVoe","submenuRootItem":"jSfVoe","icon-check":"_772w3N","iconCheck":"_772w3N","splitter-root":"RanNVV","splitterRoot":"RanNVV","splitter":"tZAbt0","header-root":"HG1K4L","headerRoot":"HG1K4L","item-root":"_1sqOxa","itemRoot":"_1sqOxa","icon":"MunWuB","link":"u02ZhT","indent":"TvnwQu","selected-mark":"_3xfn0R","selectedMark":"_3xfn0R"};
|
|
2050
2285
|
|
|
2051
2286
|
exports.IDropdownControlKeys = void 0;
|
|
2052
2287
|
(function (IDropdownControlKeys) {
|
|
@@ -2060,25 +2295,34 @@ exports.IDropdownControlKeys = void 0;
|
|
|
2060
2295
|
function DropdownMenuContainer(props) {
|
|
2061
2296
|
const menuRef = React.useRef(null);
|
|
2062
2297
|
const [currentlyFocused, setFocused] = React.useState(0);
|
|
2063
|
-
const
|
|
2298
|
+
const getMenuItems = () => {
|
|
2299
|
+
if (!menuRef.current)
|
|
2300
|
+
return [];
|
|
2301
|
+
return Array.from(menuRef.current.querySelectorAll(`[role="menuitem"]:not(.${uuiCore.uuiMod.disabled})`));
|
|
2302
|
+
};
|
|
2064
2303
|
const changeFocus = (nextFocusedIndex) => {
|
|
2065
|
-
|
|
2304
|
+
const menuItems = getMenuItems();
|
|
2305
|
+
if (menuItems.length > 0 && nextFocusedIndex >= 0 && nextFocusedIndex < menuItems.length) {
|
|
2066
2306
|
setFocused(nextFocusedIndex);
|
|
2067
|
-
menuItems[nextFocusedIndex]
|
|
2307
|
+
const targetItem = menuItems[nextFocusedIndex];
|
|
2308
|
+
targetItem.focus();
|
|
2068
2309
|
}
|
|
2069
2310
|
};
|
|
2070
2311
|
const handleArrowKeys = (e) => {
|
|
2312
|
+
const menuItems = getMenuItems();
|
|
2071
2313
|
const lastMenuItemsIndex = menuItems.length - 1;
|
|
2072
2314
|
if (e.key === exports.IDropdownControlKeys.UP_ARROW) {
|
|
2073
2315
|
changeFocus(currentlyFocused > 0 ? currentlyFocused - 1 : lastMenuItemsIndex);
|
|
2316
|
+
e.stopPropagation(); // TODO: need improvement to track event only for current overlay
|
|
2074
2317
|
e.preventDefault();
|
|
2075
2318
|
}
|
|
2076
2319
|
else if (e.key === exports.IDropdownControlKeys.DOWN_ARROW) {
|
|
2077
2320
|
changeFocus(currentlyFocused < lastMenuItemsIndex ? currentlyFocused + 1 : 0);
|
|
2321
|
+
e.stopPropagation(); // TODO: need improvement to track event only for current overlay
|
|
2078
2322
|
e.preventDefault();
|
|
2079
2323
|
}
|
|
2080
2324
|
else if (e.key === props.closeOnKey && props.onClose) {
|
|
2081
|
-
e.stopPropagation();
|
|
2325
|
+
e.stopPropagation(); // TODO: need improvement to track event only for current overlay
|
|
2082
2326
|
props.onClose();
|
|
2083
2327
|
}
|
|
2084
2328
|
};
|
|
@@ -2111,29 +2355,29 @@ const DropdownMenuButton = /* @__PURE__ */React__namespace.default.forwardRef((p
|
|
|
2111
2355
|
const getMenuButtonContent = () => {
|
|
2112
2356
|
const isIconBefore = Boolean(icon && iconPosition !== 'right');
|
|
2113
2357
|
const isIconAfter = Boolean(icon && iconPosition === 'right');
|
|
2114
|
-
const iconElement = (React__namespace.default.createElement(IconButton, { icon: icon, color: isActive ? 'primary' : 'neutral', onClick: onIconClick, isDisabled: isDisabled, cx: uuiCore.cx(css$
|
|
2358
|
+
const iconElement = (React__namespace.default.createElement(IconButton, { icon: icon, color: isActive ? 'primary' : 'neutral', onClick: onIconClick, isDisabled: isDisabled, cx: uuiCore.cx(css$10.icon, iconPosition === 'right' ? css$10.iconAfter : css$10.iconBefore) }));
|
|
2115
2359
|
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
2116
2360
|
isIconBefore && iconElement,
|
|
2117
|
-
React__namespace.default.createElement(uuiComponents.Text, { cx: props.indent && css$
|
|
2361
|
+
React__namespace.default.createElement(uuiComponents.Text, { cx: props.indent && css$10.indent }, caption),
|
|
2118
2362
|
isIconAfter && (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
2119
2363
|
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
2120
2364
|
iconElement))));
|
|
2121
2365
|
};
|
|
2122
2366
|
const isAnchor = Boolean(link || href);
|
|
2123
|
-
const itemClassNames = uuiCore.cx(props.cx, css$
|
|
2124
|
-
return isAnchor ? (React__namespace.default.createElement(uuiComponents.Anchor, { cx: uuiCore.cx(css$
|
|
2367
|
+
const itemClassNames = uuiCore.cx(props.cx, css$10.itemRoot, isDisabled && uuiCore.uuiMod.disabled, isActive && uuiCore.uuiMod.active, isOpen && uuiCore.uuiMod.opened, (!isDisabled && onClick) && uuiCore.uuiMarkers.clickable);
|
|
2368
|
+
return isAnchor ? (React__namespace.default.createElement(uuiComponents.Anchor, { cx: uuiCore.cx(css$10.link, itemClassNames), link: link, href: href, rawProps: { role: 'menuitem', tabIndex: isDisabled ? -1 : 0 }, onClick: handleClick, isDisabled: isDisabled, target: target }, getMenuButtonContent())) : (React__namespace.default.createElement("div", { tabIndex: isDisabled ? -1 : 0, role: "menuitem", onKeyDown: isDisabled ? null : handleOpenDropdown, className: itemClassNames, onClick: handleClick, ref: ref },
|
|
2125
2369
|
getMenuButtonContent(),
|
|
2126
2370
|
isSelected && (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
2127
2371
|
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
2128
|
-
React__namespace.default.createElement(uuiComponents.IconContainer, { icon: settings.dropdownMenu.icons.acceptIcon, cx: css$
|
|
2372
|
+
React__namespace.default.createElement(uuiComponents.IconContainer, { icon: settings.dropdownMenu.icons.acceptIcon, cx: css$10.selectedMark })))));
|
|
2129
2373
|
});
|
|
2130
2374
|
function DropdownMenuSplitter(props) {
|
|
2131
|
-
return (React__namespace.default.createElement("div", { className: uuiCore.cx(props.cx, css$
|
|
2132
|
-
React__namespace.default.createElement("hr", { className: css$
|
|
2375
|
+
return (React__namespace.default.createElement("div", { className: uuiCore.cx(props.cx, css$10.splitterRoot) },
|
|
2376
|
+
React__namespace.default.createElement("hr", { className: css$10.splitter })));
|
|
2133
2377
|
}
|
|
2134
2378
|
function DropdownMenuHeader(props) {
|
|
2135
|
-
return (React__namespace.default.createElement("div", { className: uuiCore.cx('uui-dropdown-menu-header', props.cx, css$
|
|
2136
|
-
React__namespace.default.createElement("span", { className: css$
|
|
2379
|
+
return (React__namespace.default.createElement("div", { className: uuiCore.cx('uui-dropdown-menu-header', props.cx, css$10.headerRoot) },
|
|
2380
|
+
React__namespace.default.createElement("span", { className: css$10.header }, props.caption)));
|
|
2137
2381
|
}
|
|
2138
2382
|
function DropdownSubMenu(props) {
|
|
2139
2383
|
const subMenuMiddleware = [
|
|
@@ -2148,7 +2392,7 @@ function DropdownSubMenu(props) {
|
|
|
2148
2392
|
}),
|
|
2149
2393
|
];
|
|
2150
2394
|
const isRtl = uuiCore.getDir() === 'rtl';
|
|
2151
|
-
return (React__namespace.default.createElement(uuiComponents.Dropdown, { openOnHover: props.openOnHover || true, closeOnMouseLeave: "boundary", openDelay: 400, closeDelay: 400, placement: isRtl ? 'left-start' : 'right-start', middleware: subMenuMiddleware, renderBody: (dropdownProps) => !props.isDisabled && (React__namespace.default.createElement(DropdownMenuBody, { closeOnKey: exports.IDropdownControlKeys.LEFT_ARROW, ...props, ...dropdownProps })), renderTarget: ({ toggleDropdownOpening, ...targetProps }) => (React__namespace.default.createElement(DropdownMenuButton, { cx: uuiCore.cx(isRtl ? css$
|
|
2395
|
+
return (React__namespace.default.createElement(uuiComponents.Dropdown, { openOnHover: props.openOnHover || true, closeOnMouseLeave: "boundary", openDelay: 400, closeDelay: 400, placement: isRtl ? 'left-start' : 'right-start', middleware: subMenuMiddleware, renderBody: (dropdownProps) => !props.isDisabled && (React__namespace.default.createElement(DropdownMenuBody, { closeOnKey: exports.IDropdownControlKeys.LEFT_ARROW, ...props, ...dropdownProps })), renderTarget: ({ toggleDropdownOpening, ...targetProps }) => (React__namespace.default.createElement(DropdownMenuButton, { cx: uuiCore.cx(isRtl ? css$10.submenuRootItemRtl : css$10.submenuRootItem), icon: settings.dropdownMenu.icons.dropdownIcon, iconPosition: "right", isDropdown: true, toggleDropdownOpening: toggleDropdownOpening, ...props, ...targetProps })) }));
|
|
2152
2396
|
}
|
|
2153
2397
|
function DropdownMenuSwitchButton(props) {
|
|
2154
2398
|
const context = React.useContext(uuiCore.UuiContext);
|
|
@@ -2164,29 +2408,29 @@ function DropdownMenuSwitchButton(props) {
|
|
|
2164
2408
|
onHandleValueChange(!isSelected);
|
|
2165
2409
|
}
|
|
2166
2410
|
};
|
|
2167
|
-
return (React__namespace.default.createElement("div", { className: uuiCore.cx(props.cx, css$
|
|
2168
|
-
icon && React__namespace.default.createElement(uuiComponents.IconContainer, { icon: icon, cx: css$
|
|
2411
|
+
return (React__namespace.default.createElement("div", { className: uuiCore.cx(props.cx, css$10.itemRoot, isDisabled && uuiCore.uuiMod.disabled, (!isDisabled || onValueChange) && uuiCore.uuiMarkers.clickable), onClick: () => onHandleValueChange(!isSelected), role: "menuitem", onKeyDown: handleKeySelect, tabIndex: isDisabled ? -1 : 0 },
|
|
2412
|
+
icon && React__namespace.default.createElement(uuiComponents.IconContainer, { icon: icon, cx: css$10.iconBefore }),
|
|
2169
2413
|
React__namespace.default.createElement(uuiComponents.Text, null, caption),
|
|
2170
2414
|
React__namespace.default.createElement(uuiComponents.FlexSpacer, null),
|
|
2171
2415
|
React__namespace.default.createElement(Switch, { value: isSelected, tabIndex: -1, onValueChange: onHandleValueChange })));
|
|
2172
2416
|
}
|
|
2173
2417
|
|
|
2174
|
-
var css
|
|
2418
|
+
var css$$ = {"root":"_9Q8qyL","mode-block":"b-q2--","modeBlock":"b-q2--","mode-inline":"DUGgXF","modeInline":"DUGgXF","padding-0":"ha8phR","padding0":"ha8phR","padding-6":"bb3J-V","padding6":"bb3J-V","padding-12":"yZwuXj","padding12":"yZwuXj","padding-18":"MSxLsx","padding18":"MSxLsx"};
|
|
2175
2419
|
|
|
2176
2420
|
function applyAccordionMods(mods) {
|
|
2177
2421
|
return [
|
|
2178
|
-
css
|
|
2179
|
-
css
|
|
2180
|
-
mods.padding && css
|
|
2422
|
+
css$$.root,
|
|
2423
|
+
css$$[`mode-${mods.mode || 'block'}`],
|
|
2424
|
+
mods.padding && css$$['padding-' + mods.padding],
|
|
2181
2425
|
];
|
|
2182
2426
|
}
|
|
2183
2427
|
const Accordion = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.Accordion, applyAccordionMods, (mods) => ({
|
|
2184
2428
|
dropdownIcon: mods.dropdownIcon !== null && settings.accordion.icons.dropdownIcon,
|
|
2185
2429
|
}));
|
|
2186
2430
|
|
|
2187
|
-
var css$
|
|
2431
|
+
var css$_ = {"root":"g8kTts","align-items":"_4mcqOz","alignItems":"_4mcqOz","justify-content":"eR4yds","justifyContent":"eR4yds","border-top":"_1NoDBx","borderTop":"_1NoDBx","border-bottom":"jY6yPS","borderBottom":"jY6yPS","top-shadow":"CJfy2S","topShadow":"CJfy2S","padding":"ehk42B","margin":"w4BZ8M","vPadding":"_4x13-2","column-gap":"GQiae9","columnGap":"GQiae9","row-gap":"AElaKQ","rowGap":"AElaKQ","spacing":"kxVjhK"};
|
|
2188
2432
|
|
|
2189
|
-
const FlexCell = /* @__PURE__ */uuiCore.withMods(uuiComponents.FlexCell, () => [css$
|
|
2433
|
+
const FlexCell = /* @__PURE__ */uuiCore.withMods(uuiComponents.FlexCell, () => [css$_.flexCell]);
|
|
2190
2434
|
|
|
2191
2435
|
const FlexRow = /* @__PURE__ */React.forwardRef((props, ref) => {
|
|
2192
2436
|
if (process.env.NODE_ENV !== "production") {
|
|
@@ -2195,22 +2439,22 @@ const FlexRow = /* @__PURE__ */React.forwardRef((props, ref) => {
|
|
|
2195
2439
|
}
|
|
2196
2440
|
}
|
|
2197
2441
|
const classNames = uuiCore.cx([
|
|
2198
|
-
css$
|
|
2442
|
+
css$_.root,
|
|
2199
2443
|
'uui-flex-row',
|
|
2200
2444
|
props.onClick && uuiCore.uuiMarkers.clickable,
|
|
2201
2445
|
props.cx,
|
|
2202
2446
|
props.size !== null && 'uui-size-' + (props.size || settings.flexRow.sizes.default),
|
|
2203
|
-
props.alignItems && css$
|
|
2204
|
-
props.justifyContent && css$
|
|
2205
|
-
props.padding && css$
|
|
2206
|
-
props.vPadding && css$
|
|
2207
|
-
props.margin && css$
|
|
2208
|
-
props.topShadow && css$
|
|
2209
|
-
props.borderBottom && css$
|
|
2210
|
-
props.borderTop && css$
|
|
2211
|
-
props.columnGap && css$
|
|
2212
|
-
props.rowGap && css$
|
|
2213
|
-
props.spacing && css$
|
|
2447
|
+
props.alignItems && css$_.alignItems,
|
|
2448
|
+
props.justifyContent && css$_.justifyContent,
|
|
2449
|
+
props.padding && css$_.padding,
|
|
2450
|
+
props.vPadding && css$_.vPadding,
|
|
2451
|
+
props.margin && css$_.margin,
|
|
2452
|
+
props.topShadow && css$_.topShadow,
|
|
2453
|
+
props.borderBottom && css$_.borderBottom,
|
|
2454
|
+
props.borderTop && css$_.borderTop,
|
|
2455
|
+
props.columnGap && css$_.columnGap,
|
|
2456
|
+
props.rowGap && css$_.rowGap,
|
|
2457
|
+
props.spacing && css$_.spacing,
|
|
2214
2458
|
props.background && `uui-flex-row-bg-${props.background}`,
|
|
2215
2459
|
]);
|
|
2216
2460
|
let alignItemsValue = props.alignItems;
|
|
@@ -2236,22 +2480,22 @@ const FlexRow = /* @__PURE__ */React.forwardRef((props, ref) => {
|
|
|
2236
2480
|
} }, props.children));
|
|
2237
2481
|
});
|
|
2238
2482
|
|
|
2239
|
-
var css$
|
|
2483
|
+
var css$Z = {"root":"GlIDeG","margin-24":"nLBcez","margin24":"nLBcez","padding-12":"vYUQl6","padding12":"vYUQl6","padding-24":"BQ0pCZ","padding24":"BQ0pCZ","shadow":"Yl-WgY","uui-surface-main":"nI0dBJ","uuiSurfaceMain":"nI0dBJ"};
|
|
2240
2484
|
|
|
2241
2485
|
const Panel = /* @__PURE__ */uuiCore.withMods(uuiComponents.VPanel, (props) => [
|
|
2242
2486
|
'uui-panel',
|
|
2243
|
-
css$
|
|
2244
|
-
props.shadow && css$
|
|
2245
|
-
props.margin && css$
|
|
2246
|
-
props.background && css$
|
|
2487
|
+
css$Z.root,
|
|
2488
|
+
props.shadow && css$Z.shadow,
|
|
2489
|
+
props.margin && css$Z['margin-' + props.margin],
|
|
2490
|
+
props.background && css$Z[`uui-${props.background}`],
|
|
2247
2491
|
]);
|
|
2248
2492
|
|
|
2249
|
-
var css$
|
|
2493
|
+
var css$Y = {"root":"Xdx8Hf"};
|
|
2250
2494
|
|
|
2251
2495
|
function applyLabeledInputMods(mods) {
|
|
2252
2496
|
return [
|
|
2253
2497
|
'uui-labeled-input',
|
|
2254
|
-
css$
|
|
2498
|
+
css$Y.root,
|
|
2255
2499
|
'uui-size-' + (mods.size || settings.labeledInput.sizes.default),
|
|
2256
2500
|
];
|
|
2257
2501
|
}
|
|
@@ -2263,7 +2507,7 @@ function applyLabeledInputProps(props) {
|
|
|
2263
2507
|
}
|
|
2264
2508
|
const LabeledInput = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.LabeledInput, applyLabeledInputMods, applyLabeledInputProps);
|
|
2265
2509
|
|
|
2266
|
-
var css$
|
|
2510
|
+
var css$X = {"root":"FALrI9"};
|
|
2267
2511
|
|
|
2268
2512
|
function RadioGroup(props) {
|
|
2269
2513
|
const direction = props.direction || 'vertical';
|
|
@@ -2272,24 +2516,85 @@ function RadioGroup(props) {
|
|
|
2272
2516
|
props.onValueChange(newVal);
|
|
2273
2517
|
}
|
|
2274
2518
|
};
|
|
2275
|
-
return (React__namespace.createElement("fieldset", { ref: props.forwardedRef, className: uuiCore.cx(css$
|
|
2519
|
+
return (React__namespace.createElement("fieldset", { ref: props.forwardedRef, className: uuiCore.cx(css$X.root, uuiCore.directionMode[direction], props.cx), onFocus: props.onFocus, onBlur: props.onBlur, ...props.rawProps }, props.items.map((i) => {
|
|
2276
2520
|
const { id, name, renderName, ...restItemProps } = i;
|
|
2277
2521
|
return (React__namespace.createElement(RadioInput, { name: props.name, renderLabel: i.renderName ? i.renderName : () => i.name, value: props.value === i.id, onValueChange: () => handleChange(i.id), isDisabled: props.isDisabled || i.isDisabled, isReadonly: props.isReadonly, isInvalid: props.isInvalid, isRequired: props.isRequired, key: i.id.toString(), size: props.size || i.size, ...restItemProps }));
|
|
2278
2522
|
})));
|
|
2279
2523
|
}
|
|
2280
2524
|
|
|
2281
|
-
var css$
|
|
2282
|
-
|
|
2283
|
-
|
|
2284
|
-
|
|
2285
|
-
|
|
2286
|
-
];
|
|
2287
|
-
|
|
2288
|
-
|
|
2525
|
+
var css$W = {"root":"c7Scrj","viewport":"NCvV-L"};
|
|
2526
|
+
|
|
2527
|
+
var uuiScrollbars;
|
|
2528
|
+
(function (uuiScrollbars) {
|
|
2529
|
+
uuiScrollbars["uuiShadowTop"] = "uui-shadow-top";
|
|
2530
|
+
uuiScrollbars["uuiShadowBottom"] = "uui-shadow-bottom";
|
|
2531
|
+
uuiScrollbars["uuiLineTop"] = "uui-line-top";
|
|
2532
|
+
uuiScrollbars["uuiLineBottom"] = "uui-line-bottom";
|
|
2533
|
+
})(uuiScrollbars || (uuiScrollbars = {}));
|
|
2534
|
+
const ScrollBars = /* @__PURE__ */React.forwardRef((props, ref) => {
|
|
2535
|
+
const { cx: outerCx, children, overflowTopEffect = 'none', overflowBottomEffect = 'none', onScroll, autoHide = 'never', autoHideDelay, rawProps, ...rest } = props;
|
|
2536
|
+
const [shadowElements, setShadowElements] = React.useState({
|
|
2537
|
+
host: null,
|
|
2538
|
+
viewport: null,
|
|
2539
|
+
});
|
|
2540
|
+
const hostRef = React.useRef(null);
|
|
2541
|
+
const viewportRef = React.useRef(null);
|
|
2542
|
+
const containerRef = React.useRef(null);
|
|
2543
|
+
const [initialize, osInstance] = overlayscrollbarsReact.useOverlayScrollbars({
|
|
2544
|
+
options: {
|
|
2545
|
+
scrollbars: {
|
|
2546
|
+
theme: 'uui-scroll-bars',
|
|
2547
|
+
autoHide: autoHide,
|
|
2548
|
+
autoHideDelay: typeof autoHideDelay === 'number' ? autoHideDelay : undefined,
|
|
2549
|
+
},
|
|
2550
|
+
},
|
|
2551
|
+
events: {
|
|
2552
|
+
scroll: (_inst, ev) => {
|
|
2553
|
+
onScroll?.(ev);
|
|
2554
|
+
},
|
|
2555
|
+
},
|
|
2556
|
+
});
|
|
2557
|
+
React.useEffect(() => {
|
|
2558
|
+
const host = hostRef.current;
|
|
2559
|
+
const vp = viewportRef.current;
|
|
2560
|
+
if (!host || !vp)
|
|
2561
|
+
return;
|
|
2562
|
+
initialize({
|
|
2563
|
+
target: host,
|
|
2564
|
+
elements: {
|
|
2565
|
+
viewport: vp,
|
|
2566
|
+
content: vp,
|
|
2567
|
+
},
|
|
2568
|
+
});
|
|
2569
|
+
return () => {
|
|
2570
|
+
osInstance()?.destroy();
|
|
2571
|
+
};
|
|
2572
|
+
}, [initialize, osInstance]);
|
|
2573
|
+
React.useEffect(() => {
|
|
2574
|
+
const instance = osInstance();
|
|
2575
|
+
if (!instance)
|
|
2576
|
+
return;
|
|
2577
|
+
const elements = instance.elements();
|
|
2578
|
+
setShadowElements({
|
|
2579
|
+
host: elements.host,
|
|
2580
|
+
viewport: elements.viewport,
|
|
2581
|
+
});
|
|
2582
|
+
}, [osInstance]);
|
|
2583
|
+
uuiCore.useScrollShadows(shadowElements.host, shadowElements.viewport);
|
|
2584
|
+
React.useImperativeHandle(ref, () => {
|
|
2585
|
+
return {
|
|
2586
|
+
container: containerRef.current,
|
|
2587
|
+
view: viewportRef.current,
|
|
2588
|
+
};
|
|
2589
|
+
}, []);
|
|
2590
|
+
return (React__namespace.default.createElement("div", { ref: hostRef, className: cx__default.default(css$W.root, outerCx, 'uui-scroll-bars', overflowTopEffect === 'shadow' && uuiScrollbars.uuiShadowTop, overflowBottomEffect === 'shadow' && uuiScrollbars.uuiShadowBottom, overflowTopEffect === 'line' && uuiScrollbars.uuiLineTop, overflowBottomEffect === 'line' && uuiScrollbars.uuiLineBottom), ...rest, "data-overlayscrollbars-initialize": "" },
|
|
2591
|
+
React__namespace.default.createElement("div", { className: css$W.viewport, "data-overlayscrollbars-contents": "", ref: (node) => { viewportRef.current = node; }, ...rawProps }, children)));
|
|
2592
|
+
});
|
|
2593
|
+
ScrollBars.displayName = 'ScrollBars';
|
|
2289
2594
|
|
|
2290
|
-
var css$
|
|
2595
|
+
var css$V = {"scroll-container":"T6hPfH","scrollContainer":"T6hPfH","list-container":"ZPmhUI","listContainer":"ZPmhUI"};
|
|
2291
2596
|
|
|
2292
|
-
const VirtualList = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
2597
|
+
const VirtualList = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => {
|
|
2293
2598
|
const { listContainerRef, offsetY, handleScroll, estimatedHeight, scrollContainerRef, } = uuiCore.useVirtualList({
|
|
2294
2599
|
value: props.value,
|
|
2295
2600
|
onValueChange: props.onValueChange,
|
|
@@ -2297,41 +2602,50 @@ const VirtualList = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
|
2297
2602
|
rowsCount: props.rowsCount,
|
|
2298
2603
|
rowsSelector: props.rowsSelector,
|
|
2299
2604
|
});
|
|
2300
|
-
React__namespace.useImperativeHandle(ref, () => scrollContainerRef.current, [scrollContainerRef.current]);
|
|
2301
|
-
const scrollShadows = uuiCore.useScrollShadows({ root: scrollContainerRef.current });
|
|
2605
|
+
React__namespace.default.useImperativeHandle(ref, () => scrollContainerRef.current, [scrollContainerRef.current]);
|
|
2302
2606
|
const renderRows = () => props.renderRows?.({
|
|
2303
|
-
listContainerRef, estimatedHeight, offsetY,
|
|
2304
|
-
}) || (React__namespace.createElement("div", { className: css$
|
|
2305
|
-
React__namespace.createElement("div", { ref: listContainerRef, role: props.role, style: { marginTop: offsetY } }, props.rows)));
|
|
2306
|
-
const
|
|
2307
|
-
|
|
2308
|
-
if (!scrollbars?.container?.firstChild)
|
|
2607
|
+
listContainerRef, estimatedHeight, offsetY,
|
|
2608
|
+
}) || (React__namespace.default.createElement("div", { className: css$V.listContainer, style: { minHeight: `${estimatedHeight}px` } },
|
|
2609
|
+
React__namespace.default.createElement("div", { ref: listContainerRef, role: props.role, style: { marginTop: offsetY } }, props.rows)));
|
|
2610
|
+
const scrollBarsRef = React__namespace.default.useCallback((scrollbars) => {
|
|
2611
|
+
if (!scrollbars?.view)
|
|
2309
2612
|
return;
|
|
2310
|
-
scrollContainerRef.current = scrollbars.
|
|
2613
|
+
scrollContainerRef.current = scrollbars.view;
|
|
2311
2614
|
}, []);
|
|
2312
|
-
return (React__namespace.createElement(ScrollBars, { cx: uuiCore.cx(css$
|
|
2313
|
-
|
|
2314
|
-
|
|
2315
|
-
[uuiCore.uuiMarkers.scrolledTop]: scrollShadows.verticalTop,
|
|
2316
|
-
[uuiCore.uuiMarkers.scrolledBottom]: scrollShadows.verticalBottom,
|
|
2317
|
-
}), onScroll: handleScroll, renderView: renderView, ref: scrollBarsRef }, renderRows()));
|
|
2318
|
-
});
|
|
2319
|
-
const VirtualListView = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
2320
|
-
return (React__namespace.createElement(React__namespace.Fragment, null,
|
|
2321
|
-
React__namespace.createElement("div", { ...props.rawProps, style: {
|
|
2322
|
-
...props.style,
|
|
2323
|
-
position: 'relative',
|
|
2324
|
-
flex: '1 1 auto',
|
|
2325
|
-
display: 'flex',
|
|
2326
|
-
flexDirection: 'column',
|
|
2327
|
-
overflow: props.isLoading ? 'hidden' : 'scroll',
|
|
2328
|
-
marginRight: props.isLoading ? 0 : props.style.marginRight,
|
|
2329
|
-
marginBottom: props.isLoading ? 0 : props.style.marginBottom,
|
|
2330
|
-
}, ref: ref }, props.children),
|
|
2331
|
-
props.renderBlocker ? props.renderBlocker({ isLoading: props.isLoading }) : React__namespace.createElement(Blocker, { isEnabled: props.isLoading })));
|
|
2615
|
+
return (React__namespace.default.createElement(ScrollBars, { cx: uuiCore.cx(css$V.scrollContainer, props.cx), onScroll: handleScroll, ref: scrollBarsRef, rawProps: props.rawProps, overflowTopEffect: props.overflowTopEffect, overflowBottomEffect: props.overflowBottomEffect },
|
|
2616
|
+
renderRows(),
|
|
2617
|
+
React__namespace.default.createElement(Blocker, { isEnabled: props.isLoading })));
|
|
2332
2618
|
});
|
|
2333
2619
|
|
|
2334
|
-
|
|
2620
|
+
const RichTextView = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.RichTextView, (mods) => ['uui-typography', `uui-typography-size-${mods.size || settings.richTextView.sizes.default}`]);
|
|
2621
|
+
|
|
2622
|
+
function TreeRowRenderer(props) {
|
|
2623
|
+
const { row, size } = props;
|
|
2624
|
+
const handleClick = React__namespace.useCallback(() => {
|
|
2625
|
+
const cb = row.onClick || row.onSelect;
|
|
2626
|
+
if (cb && !row.isDisabled) {
|
|
2627
|
+
cb(row);
|
|
2628
|
+
}
|
|
2629
|
+
}, [row]);
|
|
2630
|
+
const handleFold = React__namespace.useCallback(() => row.onFold && row.onFold(row), [row]);
|
|
2631
|
+
const renderAddons = React__namespace.useCallback(() => props.renderAddons && props.renderAddons(row), [props.renderAddons, row]);
|
|
2632
|
+
const isActive = row.isSelected;
|
|
2633
|
+
const getCaption = React__namespace.useCallback((value) => {
|
|
2634
|
+
return props.getCaption(value);
|
|
2635
|
+
}, [props.getCaption]);
|
|
2636
|
+
return (React__namespace.createElement(VerticalTabButton, { ...row, isActive: isActive, caption: row.isLoading ? React__namespace.createElement(TextPlaceholder, null) : getCaption(row.value), size: size, onClick: (row.onClick || row.onSelect) ? handleClick : undefined, link: row.link, onFold: row.onFold ? handleFold : undefined, weight: (row.isChildrenSelected || row.isSelected || isActive) ? 'semibold' : 'regular', renderAddons: renderAddons }));
|
|
2637
|
+
}
|
|
2638
|
+
const MemoizedTreeRowRenderer = /* @__PURE__ */React__namespace.memo(TreeRowRenderer);
|
|
2639
|
+
function Tree(props) {
|
|
2640
|
+
const { view, renderRow, size = '36', cx: propsCx, value, onValueChange, } = props;
|
|
2641
|
+
const rows = view.getVisibleRows();
|
|
2642
|
+
const rowsCount = view.getListProps().rowsCount ?? rows.length;
|
|
2643
|
+
const renderRowFunction = renderRow || (({ key, ...row }) => (React__namespace.createElement(MemoizedTreeRowRenderer, { key: key, row: row, size: size, getCaption: props.getCaption, renderAddons: props.renderAddons })));
|
|
2644
|
+
const renderedRows = React.useMemo(() => rows.map((row) => renderRowFunction(row)), [rows, renderRowFunction, size]);
|
|
2645
|
+
return (React__namespace.createElement(VirtualList, { value: value, onValueChange: onValueChange, rowsCount: rowsCount, rows: renderedRows, cx: uuiCore.cx(propsCx), role: "tree" }));
|
|
2646
|
+
}
|
|
2647
|
+
|
|
2648
|
+
var css$U = {"root":"U6Epqp"};
|
|
2335
2649
|
|
|
2336
2650
|
function CheckboxGroup(props) {
|
|
2337
2651
|
const currentValue = props.value || [];
|
|
@@ -2347,16 +2661,96 @@ function CheckboxGroup(props) {
|
|
|
2347
2661
|
}
|
|
2348
2662
|
props.onValueChange(newSelection);
|
|
2349
2663
|
};
|
|
2350
|
-
return (React__namespace.createElement("fieldset", { ref: props.forwardedRef, className: uuiCore.cx(css$
|
|
2664
|
+
return (React__namespace.createElement("fieldset", { ref: props.forwardedRef, className: uuiCore.cx(css$U.root, uuiCore.directionMode[direction], props.cx), ...props.rawProps }, props.items.map((i) => {
|
|
2351
2665
|
const { id, name, renderName, ...restItemProps } = i;
|
|
2352
2666
|
return (React__namespace.createElement(Checkbox, { renderLabel: i.renderName ? i.renderName : () => i.name, value: currentValue.indexOf(i.id) !== -1, onValueChange: (selected) => handleChange(selected, i.id), isDisabled: props.isDisabled, isReadonly: props.isReadonly, isInvalid: props.isInvalid, isRequired: props.isRequired, key: i.id.toString(), size: props.size || i.size, ...restItemProps }));
|
|
2353
2667
|
})));
|
|
2354
2668
|
}
|
|
2355
2669
|
|
|
2356
|
-
|
|
2670
|
+
const Tabs = /* @__PURE__ */React.forwardRef((props, ref) => {
|
|
2671
|
+
const { items, value, onValueChange, borderBottom = true, rawProps, ...otherProps } = props;
|
|
2672
|
+
if (items.length === 0) {
|
|
2673
|
+
return null;
|
|
2674
|
+
}
|
|
2675
|
+
const tabLastIndex = items.length - 1;
|
|
2676
|
+
const getTabCurrentIndex = (tabIdCurrent) => {
|
|
2677
|
+
return items.findIndex((tabProps) => {
|
|
2678
|
+
return tabProps.id === tabIdCurrent;
|
|
2679
|
+
});
|
|
2680
|
+
};
|
|
2681
|
+
const moveToTabWithIndex = (tabIndex) => {
|
|
2682
|
+
/*
|
|
2683
|
+
`id`-s provided in `items` are assigned to the tabs.
|
|
2684
|
+
Unless users manually broke this connection,
|
|
2685
|
+
the index calculation will be correct,
|
|
2686
|
+
and the tab element will be present in the DOM.
|
|
2687
|
+
*/
|
|
2688
|
+
const tab = items.at(tabIndex);
|
|
2689
|
+
const tabElement = document.getElementById(tab.id);
|
|
2690
|
+
tabElement.focus();
|
|
2691
|
+
};
|
|
2692
|
+
const moveToPreviousTab = (tabIdCurrent) => {
|
|
2693
|
+
const tabCurrentIndex = getTabCurrentIndex(tabIdCurrent);
|
|
2694
|
+
const tabIndexNext = tabCurrentIndex === 0 ? tabLastIndex : tabCurrentIndex - 1;
|
|
2695
|
+
moveToTabWithIndex(tabIndexNext);
|
|
2696
|
+
};
|
|
2697
|
+
const moveToNextTab = (tabIdCurrent) => {
|
|
2698
|
+
const tabCurrentIndex = getTabCurrentIndex(tabIdCurrent);
|
|
2699
|
+
const tabIndexNext = tabCurrentIndex === tabLastIndex ? 0 : tabCurrentIndex + 1;
|
|
2700
|
+
moveToTabWithIndex(tabIndexNext);
|
|
2701
|
+
};
|
|
2702
|
+
const onKeyDown = (event) => {
|
|
2703
|
+
const focusedTabIdCurrent = event.target.id;
|
|
2704
|
+
// https://www.w3.org/WAI/ARIA/apg/patterns/tabs/#keyboardinteraction
|
|
2705
|
+
switch (event.code) {
|
|
2706
|
+
case 'ArrowLeft': {
|
|
2707
|
+
moveToPreviousTab(focusedTabIdCurrent);
|
|
2708
|
+
break;
|
|
2709
|
+
}
|
|
2710
|
+
case 'ArrowRight': {
|
|
2711
|
+
moveToNextTab(focusedTabIdCurrent);
|
|
2712
|
+
break;
|
|
2713
|
+
}
|
|
2714
|
+
case 'Home': {
|
|
2715
|
+
moveToTabWithIndex(0);
|
|
2716
|
+
break;
|
|
2717
|
+
}
|
|
2718
|
+
case 'End': {
|
|
2719
|
+
moveToTabWithIndex(tabLastIndex);
|
|
2720
|
+
break;
|
|
2721
|
+
}
|
|
2722
|
+
}
|
|
2723
|
+
};
|
|
2724
|
+
return (React__namespace.default.createElement(FlexRow, { ref: ref, borderBottom: borderBottom, rawProps: {
|
|
2725
|
+
role: 'tablist',
|
|
2726
|
+
'aria-orientation': 'horizontal',
|
|
2727
|
+
...rawProps,
|
|
2728
|
+
}, ...otherProps }, items.map((tabProps) => {
|
|
2729
|
+
const { id } = tabProps;
|
|
2730
|
+
const handleOnClick = () => {
|
|
2731
|
+
onValueChange(id);
|
|
2732
|
+
tabProps.onClick?.();
|
|
2733
|
+
};
|
|
2734
|
+
const handleOnKeyDown = (event) => {
|
|
2735
|
+
onKeyDown(event);
|
|
2736
|
+
tabProps.rawProps?.onKeyDown?.(event);
|
|
2737
|
+
};
|
|
2738
|
+
const isActive = id === value;
|
|
2739
|
+
const tabIndex = isActive ? undefined : -1;
|
|
2740
|
+
return (React__namespace.default.createElement(TabButton, { key: id, isActive: isActive, tabIndex: tabIndex, ...tabProps, onClick: handleOnClick, rawProps: {
|
|
2741
|
+
id,
|
|
2742
|
+
'aria-selected': isActive,
|
|
2743
|
+
...tabProps.rawProps,
|
|
2744
|
+
onKeyDown: handleOnKeyDown,
|
|
2745
|
+
} }));
|
|
2746
|
+
})));
|
|
2747
|
+
});
|
|
2748
|
+
Tabs.displayName = 'Tabs';
|
|
2749
|
+
|
|
2750
|
+
var css$T = {"root":"U78jff","modal-blocker":"rLHfoX","modalBlocker":"rLHfoX","animateModalBlocker":"N6T2OU","modal":"nQ1ZUh","modal-footer":"eDVe9r","modalFooter":"eDVe9r","border-top":"FXWMEf","borderTop":"FXWMEf","modal-header":"tb7hiH","modalHeader":"tb7hiH","border-bottom":"_3cGnEZ","borderBottom":"_3cGnEZ"};
|
|
2357
2751
|
|
|
2358
|
-
const ModalBlocker = /* @__PURE__ */uuiCore.withMods(uuiComponents.ModalBlocker, () => [css$
|
|
2359
|
-
const ModalWindow = /* @__PURE__ */uuiCore.withMods(uuiComponents.ModalWindow, () => [css$
|
|
2752
|
+
const ModalBlocker = /* @__PURE__ */uuiCore.withMods(uuiComponents.ModalBlocker, () => [css$T.modalBlocker]);
|
|
2753
|
+
const ModalWindow = /* @__PURE__ */uuiCore.withMods(uuiComponents.ModalWindow, () => [css$T.root, css$T.modal], (props) => {
|
|
2360
2754
|
const width = props.width;
|
|
2361
2755
|
const height = props.height || 'auto';
|
|
2362
2756
|
const maxHeight = uuiCore.isMobile() ? 'var(--uui-modals-mobile-max-height)' : (props.maxHeight || 'var(--uui-modals-max-height)');
|
|
@@ -2370,7 +2764,7 @@ const ModalWindow = /* @__PURE__ */uuiCore.withMods(uuiComponents.ModalWindow, (
|
|
|
2370
2764
|
};
|
|
2371
2765
|
});
|
|
2372
2766
|
function ModalHeader(props) {
|
|
2373
|
-
return (React__namespace.default.createElement("div", { className: cx__default.default(css$
|
|
2767
|
+
return (React__namespace.default.createElement("div", { className: cx__default.default(css$T.root, css$T.modalHeader, 'uui-modal-header', props.borderBottom && css$T.borderBottom, props.cx), ...props.rawProps, style: {
|
|
2374
2768
|
...props.rawProps?.style,
|
|
2375
2769
|
} },
|
|
2376
2770
|
props.title && (React__namespace.default.createElement("div", { className: cx__default.default('uui-modal-title', 'uui-typography') }, props.title)),
|
|
@@ -2380,7 +2774,7 @@ function ModalHeader(props) {
|
|
|
2380
2774
|
React__namespace.default.createElement(IconButton, { rawProps: { 'aria-label': 'Close modal' }, icon: settings.modal.icons.closeIcon, onClick: props.onClose })))));
|
|
2381
2775
|
}
|
|
2382
2776
|
function ModalFooter(props) {
|
|
2383
|
-
return (React__namespace.default.createElement("div", { className: cx__default.default(css$
|
|
2777
|
+
return (React__namespace.default.createElement("div", { className: cx__default.default(css$T.root, css$T.modalFooter, 'uui-modal-footer', props.borderTop && css$T.borderTop, props.cx), ...props.rawProps, style: {
|
|
2384
2778
|
...props.rawProps?.style,
|
|
2385
2779
|
} }, props.children));
|
|
2386
2780
|
}
|
|
@@ -2545,7 +2939,7 @@ const TREE_SHAKEABLE_INIT = () => ({
|
|
|
2545
2939
|
});
|
|
2546
2940
|
const i18n = /* @__PURE__ */TREE_SHAKEABLE_INIT();
|
|
2547
2941
|
|
|
2548
|
-
var css
|
|
2942
|
+
var css$S = {"root":"wD5M43","icon-wrapper":"ytSieg","iconWrapper":"ytSieg","action-wrapper":"jUW4oa","actionWrapper":"jUW4oa","close-icon":"Y9JY19","closeIcon":"Y9JY19","main-path":"ZGabYW","mainPath":"ZGabYW","content":"vkuP49","close-wrapper":"JQicTB","closeWrapper":"JQicTB","clear-notifications":"QjUgBA","clearNotifications":"QjUgBA"};
|
|
2549
2943
|
|
|
2550
2944
|
const NotificationCard = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => {
|
|
2551
2945
|
const notificationCardNode = React__namespace.default.useRef(null);
|
|
@@ -2558,15 +2952,15 @@ const NotificationCard = /* @__PURE__ */React__namespace.default.forwardRef((pro
|
|
|
2558
2952
|
notificationCardNode.current?.removeEventListener('mouseleave', props.refreshTimer);
|
|
2559
2953
|
};
|
|
2560
2954
|
}, []);
|
|
2561
|
-
return (React__namespace.default.createElement("div", { role: "alert", className: cx__default.default('uui-notification_card', props.color && `uui-color-${props.color}`, css
|
|
2562
|
-
React__namespace.default.createElement("div", { className: css
|
|
2563
|
-
props.icon && (React__namespace.default.createElement("div", { className: css
|
|
2955
|
+
return (React__namespace.default.createElement("div", { role: "alert", className: cx__default.default('uui-notification_card', props.color && `uui-color-${props.color}`, css$S.root, props.cx), ref: notificationCardNode, ...props.rawProps },
|
|
2956
|
+
React__namespace.default.createElement("div", { className: css$S.mainPath },
|
|
2957
|
+
props.icon && (React__namespace.default.createElement("div", { className: css$S.iconWrapper },
|
|
2564
2958
|
React__namespace.default.createElement(uuiComponents.IconContainer, { size: settings.notificationCard.sizes.icon, icon: props.icon }))),
|
|
2565
|
-
React__namespace.default.createElement("div", { className: css
|
|
2959
|
+
React__namespace.default.createElement("div", { className: css$S.content },
|
|
2566
2960
|
props.children,
|
|
2567
|
-
props.actions && (React__namespace.default.createElement("div", { className: css
|
|
2568
|
-
props.onClose && (React__namespace.default.createElement("div", { className: cx__default.default(css
|
|
2569
|
-
React__namespace.default.createElement(IconButton, { icon: settings.notificationCard.icons.closeIcon, color: "neutral", onClick: props.onClose, cx: css
|
|
2961
|
+
props.actions && (React__namespace.default.createElement("div", { className: css$S.actionWrapper }, props.actions.map((action) => (React__namespace.default.createElement(LinkButton, { key: action.name, caption: action.name, onClick: action.action, cx: css$S.actionLink, size: settings.notificationCard.sizes.action, rawProps: action.rawProps })))))),
|
|
2962
|
+
props.onClose && (React__namespace.default.createElement("div", { className: cx__default.default(css$S.closeWrapper, 'uui-notification_card-close_icon') },
|
|
2963
|
+
React__namespace.default.createElement(IconButton, { icon: settings.notificationCard.icons.closeIcon, color: "neutral", onClick: props.onClose, cx: css$S.closeIcon }))))));
|
|
2570
2964
|
});
|
|
2571
2965
|
const WarningNotification = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, { icon: settings.notificationCard.icons.warningIcon, color: "warning", ...props, ref: ref, cx: props.cx })));
|
|
2572
2966
|
const SuccessNotification = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, { icon: settings.notificationCard.icons.successIcon, color: "success", ...props, ref: ref, cx: props.cx })));
|
|
@@ -2574,11 +2968,11 @@ const HintNotification = /* @__PURE__ */React__namespace.default.forwardRef((pro
|
|
|
2574
2968
|
const ErrorNotification = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => (React__namespace.default.createElement(NotificationCard, { icon: settings.notificationCard.icons.errorIcon, color: "error", ...props, ref: ref, cx: props.cx })));
|
|
2575
2969
|
function ClearNotification() {
|
|
2576
2970
|
const uuiCtx = uuiCore.useUuiContext();
|
|
2577
|
-
return (React__namespace.default.createElement("div", { className: cx__default.default(css
|
|
2971
|
+
return (React__namespace.default.createElement("div", { className: cx__default.default(css$S.clearNotifications, 'uui-clear-notifications') },
|
|
2578
2972
|
React__namespace.default.createElement(LinkButton, { caption: i18n.notificationCard.closeAllNotificationsButton, onClick: () => uuiCtx.uuiNotifications.clearAll() })));
|
|
2579
2973
|
}
|
|
2580
2974
|
|
|
2581
|
-
var css$
|
|
2975
|
+
var css$R = {"footer":"lZut3N"};
|
|
2582
2976
|
|
|
2583
2977
|
class ConfirmationModal extends React__namespace.Component {
|
|
2584
2978
|
render() {
|
|
@@ -2590,7 +2984,7 @@ class ConfirmationModal extends React__namespace.Component {
|
|
|
2590
2984
|
React__namespace.createElement(ModalWindow, { width: 420 },
|
|
2591
2985
|
React__namespace.createElement(ModalHeader, { borderBottom: true, title: this.props.caption, onClose: () => this.props.abort() }),
|
|
2592
2986
|
React__namespace.createElement(ScrollBars, null, bodyContent),
|
|
2593
|
-
React__namespace.createElement(ModalFooter, { cx: css$
|
|
2987
|
+
React__namespace.createElement(ModalFooter, { cx: css$R.footer },
|
|
2594
2988
|
this.props.hideCancelButton || (React__namespace.createElement(Button, { caption: i18n.form.modals.discardButton, onClick: () => this.props.success(false), fill: "outline", color: "secondary" })),
|
|
2595
2989
|
React__namespace.createElement(Button, { caption: i18n.form.modals.saveButton, onClick: () => this.props.success(true), color: "primary" })))));
|
|
2596
2990
|
}
|
|
@@ -2620,7 +3014,7 @@ function useReliableForceUpdate() {
|
|
|
2620
3014
|
return red[1];
|
|
2621
3015
|
}
|
|
2622
3016
|
|
|
2623
|
-
var css$
|
|
3017
|
+
var css$Q = {"root":"jmhVru","container":"tWIJrl"};
|
|
2624
3018
|
|
|
2625
3019
|
const defaultFormat = 'MMM D, YYYY';
|
|
2626
3020
|
const valueFormat = 'YYYY-MM-DD';
|
|
@@ -2831,21 +3225,21 @@ function DatePickerHeader({ navIconLeft, navIconRight, value: { month, view }, o
|
|
|
2831
3225
|
}, [view, month]);
|
|
2832
3226
|
const disablePrev = view === 'YEAR_SELECTION' && !isYearWithinSoberRange(getPrevYearsList(month));
|
|
2833
3227
|
const disableNext = view === 'YEAR_SELECTION' && !isYearWithinSoberRange(getNextYearsList(month));
|
|
2834
|
-
return (React__namespace.createElement("div", { className: cx__default.default(css$
|
|
3228
|
+
return (React__namespace.createElement("div", { className: cx__default.default(css$Q.root, uuiHeader.container, cx__default.default) },
|
|
2835
3229
|
React__namespace.createElement("header", { className: uuiHeader.headerNav },
|
|
2836
3230
|
React__namespace.createElement(Button, { icon: navIconLeft || settings.datePicker.icons.body.prevIcon, color: "secondary", fill: "ghost", cx: uuiHeader.navIconLeft, onClick: !isDisabled && (() => onLeftNavigationArrow()), isDisabled: disablePrev }),
|
|
2837
3231
|
React__namespace.createElement(Button, { caption: title, fill: "ghost", cx: uuiHeader.navTitle, onClick: !isDisabled && (() => onCaptionClick(view)) }),
|
|
2838
3232
|
React__namespace.createElement(Button, { icon: navIconRight || settings.datePicker.icons.body.nextIcon, color: "secondary", fill: "ghost", cx: uuiHeader.navIconRight, onClick: !isDisabled && (() => onRightNavigationArrow()), isDisabled: disableNext }))));
|
|
2839
3233
|
}
|
|
2840
3234
|
|
|
2841
|
-
var css$
|
|
3235
|
+
var css$P = {"root":"_0q9Ttf"};
|
|
2842
3236
|
|
|
2843
3237
|
function applyDateSelectionMods() {
|
|
2844
|
-
return [css$
|
|
3238
|
+
return [css$P.root, `uui-size-${settings.datePicker.sizes.body}`];
|
|
2845
3239
|
}
|
|
2846
3240
|
const Calendar = /* @__PURE__ */uuiCore.withMods(uuiComponents.Calendar, applyDateSelectionMods);
|
|
2847
3241
|
|
|
2848
|
-
var css$
|
|
3242
|
+
var css$O = {"root":"-PXc4J"};
|
|
2849
3243
|
|
|
2850
3244
|
const uuiDatePickerBody = {
|
|
2851
3245
|
wrapper: 'uui-datepicker-body-wrapper',
|
|
@@ -2889,7 +3283,7 @@ function StatelessDatePickerBodyComp({ renderDay, isHoliday, cx: classes, filter
|
|
|
2889
3283
|
}
|
|
2890
3284
|
};
|
|
2891
3285
|
return (React__namespace.default.createElement("div", { ref: ref, className: uuiCore.cx(uuiDatePickerBodyBase.container, `uui-size-${settings.datePicker.sizes.body}`, classes), ...rawProps },
|
|
2892
|
-
React__namespace.default.createElement("div", { className: uuiCore.cx(css$
|
|
3286
|
+
React__namespace.default.createElement("div", { className: uuiCore.cx(css$O.root, uuiDatePickerBody.wrapper) },
|
|
2893
3287
|
React__namespace.default.createElement(DatePickerHeader, { value: {
|
|
2894
3288
|
view,
|
|
2895
3289
|
month,
|
|
@@ -2966,7 +3360,7 @@ function DatePickerComponent(props, ref) {
|
|
|
2966
3360
|
}
|
|
2967
3361
|
const DatePicker = /* @__PURE__ */React__namespace.default.forwardRef(DatePickerComponent);
|
|
2968
3362
|
|
|
2969
|
-
var css$
|
|
3363
|
+
var css$N = {"date-input":"_4SswK5","dateInput":"_4SswK5","root":"M8dEUC","separator":"tXEJ4C"};
|
|
2970
3364
|
|
|
2971
3365
|
const RangeDatePickerInput = /* @__PURE__ */React.forwardRef(({ isDisabled, isInvalid, isReadonly, size, disableClear, rawProps, value, inFocus, format, onValueChange, onFocusInput, onBlurInput, onClick, getPlaceholder, filter, onKeyDown, preventEmptyFromDate, preventEmptyToDate, id, cx: classes, }, ref) => {
|
|
2972
3366
|
const [inputValue, setInputValue] = React.useState(toCustomDateRangeFormat(value, format));
|
|
@@ -3031,13 +3425,13 @@ const RangeDatePickerInput = /* @__PURE__ */React.forwardRef(({ isDisabled, isIn
|
|
|
3031
3425
|
const clearAllowed = !disableClear && !(preventEmptyFromDate && preventEmptyToDate) && inputValue.from && inputValue.to;
|
|
3032
3426
|
return (
|
|
3033
3427
|
// eslint-disable-next-line jsx-a11y/no-static-element-interactions
|
|
3034
|
-
React__namespace.default.createElement("div", { ref: ref, className: uuiCore.cx(`uui-size-${size || settings.rangeDatePicker.sizes.default}`, 'uui-range-date-picker', classes, css$
|
|
3035
|
-
React__namespace.default.createElement(TextInput, { icon: settings.rangeDatePicker.icons.input.calendarIcon, cx: uuiCore.cx(css$
|
|
3036
|
-
React__namespace.default.createElement("div", { className: css$
|
|
3037
|
-
React__namespace.default.createElement(TextInput, { cx: uuiCore.cx(css$
|
|
3428
|
+
React__namespace.default.createElement("div", { ref: ref, className: uuiCore.cx(`uui-size-${size || settings.rangeDatePicker.sizes.default}`, 'uui-range-date-picker', classes, css$N.root, isDisabled && uuiCore.uuiMod.disabled, isReadonly && uuiCore.uuiMod.readonly, isInvalid && uuiCore.uuiMod.invalid, inFocus && uuiCore.uuiMod.focus), onKeyDown: onKeyDown },
|
|
3429
|
+
React__namespace.default.createElement(TextInput, { icon: settings.rangeDatePicker.icons.input.calendarIcon, cx: uuiCore.cx(css$N.dateInput, inFocus === 'from' && uuiCore.uuiMod.focus), size: size || settings.rangeDatePicker.sizes.default, placeholder: getPlaceholder ? getPlaceholder('from') : i18n.rangeDatePicker.pickerPlaceholderFrom, value: inputValue.from || undefined, onValueChange: (v) => onInputChange(v || '', 'from'), onFocus: (event) => handleFocus(event, 'from'), onBlur: (event) => handleBlur(event, 'from'), isInvalid: isInvalid, isDisabled: isDisabled, isReadonly: isReadonly, isDropdown: false, rawProps: rawProps?.from, onClick: onClick, onKeyDown: onInputKeyDown, id: id }),
|
|
3430
|
+
React__namespace.default.createElement("div", { className: css$N.separator }),
|
|
3431
|
+
React__namespace.default.createElement(TextInput, { cx: uuiCore.cx(css$N.dateInput, inFocus === 'to' && uuiCore.uuiMod.focus), placeholder: getPlaceholder ? getPlaceholder('to') : i18n.rangeDatePicker.pickerPlaceholderTo, size: size || settings.rangeDatePicker.sizes.default, value: inputValue.to || undefined, onCancel: clearAllowed ? onClear : undefined, onValueChange: (v) => onInputChange(v || '', 'to'), onFocus: (e) => handleFocus(e, 'to'), onBlur: (e) => handleBlur(e, 'to'), isInvalid: isInvalid, isDisabled: isDisabled, isReadonly: isReadonly, isDropdown: false, rawProps: rawProps?.to, onClick: onClick, onKeyDown: onInputKeyDown })));
|
|
3038
3432
|
});
|
|
3039
3433
|
|
|
3040
|
-
var css$
|
|
3434
|
+
var css$M = {"root":"ctWOZN"};
|
|
3041
3435
|
|
|
3042
3436
|
const uuiPresets = {
|
|
3043
3437
|
container: 'uui-presets-container',
|
|
@@ -3052,12 +3446,12 @@ const getPresets = (presets) => {
|
|
|
3052
3446
|
})).sort((a, b) => a.order - b.order);
|
|
3053
3447
|
};
|
|
3054
3448
|
function CalendarPresets(props) {
|
|
3055
|
-
return (React__namespace.createElement("div", { ref: props.forwardedRef, className: uuiCore.cx(uuiPresets.container, css$
|
|
3449
|
+
return (React__namespace.createElement("div", { ref: props.forwardedRef, className: uuiCore.cx(uuiPresets.container, css$M.root, props.cx), ...props.rawProps },
|
|
3056
3450
|
React__namespace.createElement("div", { className: uuiPresets.header }, "Presets"),
|
|
3057
3451
|
getPresets(props.presets).map((item) => (React__namespace.createElement(LinkButton, { key: item.key, caption: item.name, onClick: () => props.onPresetSet(item), size: settings.rangeDatePicker.sizes.preset })))));
|
|
3058
3452
|
}
|
|
3059
3453
|
|
|
3060
|
-
var css$
|
|
3454
|
+
var css$L = {"root":"ad8s-W","container":"uHvbmV","day-selection":"J9FAqZ","daySelection":"J9FAqZ","from-picker":"ncvxX5","fromPicker":"ncvxX5","to-picker":"OcG7s4","toPicker":"OcG7s4","bodes-wrapper":"zzbJ9q","bodesWrapper":"zzbJ9q","blocker":"yfsvJ5"};
|
|
3061
3455
|
|
|
3062
3456
|
const uuiRangeDatePickerBody = {
|
|
3063
3457
|
inRange: 'uui-range-datepicker-in-range',
|
|
@@ -3070,7 +3464,7 @@ const rangeDatePickerPresets = {
|
|
|
3070
3464
|
name: 'Today',
|
|
3071
3465
|
getRange: () => ({
|
|
3072
3466
|
from: uuiDayjs.dayjs().toString(),
|
|
3073
|
-
to:
|
|
3467
|
+
to: uuiDayjs.dayjs().toString(),
|
|
3074
3468
|
order: 1,
|
|
3075
3469
|
}),
|
|
3076
3470
|
},
|
|
@@ -3111,7 +3505,7 @@ const rangeDatePickerPresets = {
|
|
|
3111
3505
|
getRange: () => ({
|
|
3112
3506
|
from: uuiDayjs.dayjs().startOf('month').subtract(3, 'month').toString(),
|
|
3113
3507
|
to: uuiDayjs.dayjs().subtract(1, 'month').endOf('month').toString(),
|
|
3114
|
-
order:
|
|
3508
|
+
order: 6,
|
|
3115
3509
|
}),
|
|
3116
3510
|
},
|
|
3117
3511
|
thisYear: {
|
|
@@ -3196,8 +3590,8 @@ function RangeDatePickerBodyComp(props, ref) {
|
|
|
3196
3590
|
props.onValueChange({
|
|
3197
3591
|
inFocus: props.value.inFocus,
|
|
3198
3592
|
selectedDate: {
|
|
3199
|
-
from: uuiDayjs.dayjs(presetVal.from).format(valueFormat),
|
|
3200
|
-
to: uuiDayjs.dayjs(presetVal.to).format(valueFormat),
|
|
3593
|
+
from: presetVal.from ? uuiDayjs.dayjs(presetVal.from).format(valueFormat) : undefined,
|
|
3594
|
+
to: presetVal.to ? uuiDayjs.dayjs(presetVal.to).format(valueFormat) : undefined,
|
|
3201
3595
|
},
|
|
3202
3596
|
});
|
|
3203
3597
|
}, presets: presets })));
|
|
@@ -3210,18 +3604,18 @@ function RangeDatePickerBodyComp(props, ref) {
|
|
|
3210
3604
|
setMonth(monthToSet);
|
|
3211
3605
|
}
|
|
3212
3606
|
}, [selectedDate]);
|
|
3213
|
-
return (React__namespace.default.createElement("div", { ref: ref, className: cx__default.default(css$
|
|
3214
|
-
React__namespace.default.createElement(FlexRow, { cx: [view === 'DAY_SELECTION' && css$
|
|
3607
|
+
return (React__namespace.default.createElement("div", { ref: ref, className: cx__default.default(css$L.root, uuiDatePickerBodyBase.container, props.cx), ...props.rawProps, "aria-multiselectable": "true" },
|
|
3608
|
+
React__namespace.default.createElement(FlexRow, { cx: [view === 'DAY_SELECTION' && css$L.daySelection, css$L.container], alignItems: "top" },
|
|
3215
3609
|
React__namespace.default.createElement(FlexCell, { width: "auto" },
|
|
3216
3610
|
React__namespace.default.createElement(FlexRow, null,
|
|
3217
|
-
React__namespace.default.createElement(FlexRow, { cx: css$
|
|
3218
|
-
React__namespace.default.createElement(StatelessDatePickerBody, { key: "date-picker-body-left", cx: cx__default.default(css$
|
|
3611
|
+
React__namespace.default.createElement(FlexRow, { cx: css$L.bodesWrapper, alignItems: "top" },
|
|
3612
|
+
React__namespace.default.createElement(StatelessDatePickerBody, { key: "date-picker-body-left", cx: cx__default.default(css$L.fromPicker), ...from, onValueChange: (v) => onBodyValueChange(v), onMonthChange: (m) => {
|
|
3219
3613
|
setMonth(m);
|
|
3220
3614
|
}, onViewChange: (v) => {
|
|
3221
3615
|
setView(v);
|
|
3222
3616
|
setDisabledPanel(v !== 'DAY_SELECTION' ? 'right' : null);
|
|
3223
3617
|
}, filter: props.filter, isHoliday: props.isHoliday, renderDay: props.renderDay || renderDay, isDisabled: disabledPanel === 'left' }),
|
|
3224
|
-
React__namespace.default.createElement(StatelessDatePickerBody, { key: "date-picker-body-right", cx: cx__default.default(css$
|
|
3618
|
+
React__namespace.default.createElement(StatelessDatePickerBody, { key: "date-picker-body-right", cx: cx__default.default(css$L.toPicker), ...to, onValueChange: (v) => onBodyValueChange(v), onMonthChange: (m) => {
|
|
3225
3619
|
setMonth(m.subtract(1, 'month'));
|
|
3226
3620
|
}, onViewChange: (v) => {
|
|
3227
3621
|
setView(v);
|
|
@@ -3230,7 +3624,7 @@ function RangeDatePickerBodyComp(props, ref) {
|
|
|
3230
3624
|
view !== 'DAY_SELECTION' && (React__namespace.default.createElement("div", { style: {
|
|
3231
3625
|
left: disabledPanel === 'right' ? '50%' : undefined,
|
|
3232
3626
|
right: disabledPanel === 'left' ? '50%' : undefined,
|
|
3233
|
-
}, className: css$
|
|
3627
|
+
}, className: css$L.blocker }))),
|
|
3234
3628
|
props.presets && renderPresets(props.presets)),
|
|
3235
3629
|
props.renderFooter && props.renderFooter()))));
|
|
3236
3630
|
}
|
|
@@ -3259,7 +3653,7 @@ const getDayState = (day, selectedDate) => {
|
|
|
3259
3653
|
};
|
|
3260
3654
|
};
|
|
3261
3655
|
|
|
3262
|
-
var css$
|
|
3656
|
+
var css$K = {"dropdown-container":"mRcXPu","dropdownContainer":"mRcXPu"};
|
|
3263
3657
|
|
|
3264
3658
|
function RangeDatePickerComponent(props, ref) {
|
|
3265
3659
|
const { value: _value, format = defaultFormat, size = settings.rangeDatePicker.sizes.default } = props;
|
|
@@ -3303,7 +3697,7 @@ function RangeDatePickerComponent(props, ref) {
|
|
|
3303
3697
|
}
|
|
3304
3698
|
};
|
|
3305
3699
|
const renderBody = (renderProps) => {
|
|
3306
|
-
return (React__namespace.default.createElement(DropdownContainer, { ...renderProps, cx: cx__default.default(css$
|
|
3700
|
+
return (React__namespace.default.createElement(DropdownContainer, { ...renderProps, cx: cx__default.default(css$K.dropdownContainer), shards: [targetRef], returnFocus: true },
|
|
3307
3701
|
React__namespace.default.createElement(FlexRow, null,
|
|
3308
3702
|
React__namespace.default.createElement(RangeDatePickerBody, { cx: cx__default.default(props.bodyCx), value: {
|
|
3309
3703
|
selectedDate: _value,
|
|
@@ -3327,175 +3721,24 @@ function RangeDatePickerComponent(props, ref) {
|
|
|
3327
3721
|
}
|
|
3328
3722
|
const RangeDatePicker = /* @__PURE__ */React__namespace.default.forwardRef(RangeDatePickerComponent);
|
|
3329
3723
|
|
|
3330
|
-
var css$
|
|
3724
|
+
var css$J = {"root":"WSj09H","blocker":"_0iNUa9","marker":"_0CRQIv","top":"lB62dD","bottom":"HKii4S","left":"w8wOC3","right":"wcwV-y","inside":"aYGwmC"};
|
|
3331
3725
|
|
|
3332
3726
|
function DropMarker(props) {
|
|
3333
3727
|
return props.isDndInProgress
|
|
3334
3728
|
? (React__namespace.createElement(React__namespace.Fragment, null,
|
|
3335
|
-
props.enableBlocker && React__namespace.createElement("div", { className: css$
|
|
3729
|
+
props.enableBlocker && React__namespace.createElement("div", { className: css$J.blocker }),
|
|
3336
3730
|
React__namespace.createElement("div", { className: cx__default.default([
|
|
3337
|
-
css$
|
|
3338
|
-
css$
|
|
3339
|
-
css$
|
|
3731
|
+
css$J.root,
|
|
3732
|
+
css$J.marker,
|
|
3733
|
+
css$J[props.position],
|
|
3340
3734
|
props?.cx,
|
|
3341
3735
|
]) })))
|
|
3342
3736
|
: null;
|
|
3343
3737
|
}
|
|
3344
3738
|
|
|
3345
|
-
|
|
3346
|
-
|
|
3347
|
-
var css$R = {"search-wrapper":"cV-MZn","searchWrapper":"cV-MZn","no-data":"Y5kqHg","noData":"Y5kqHg"};
|
|
3348
|
-
|
|
3349
|
-
var css$Q = {"picker-row":"_1xhV55","pickerRow":"_1xhV55","align-widgets-top":"p5XSxH","alignWidgetsTop":"p5XSxH","row-content":"dlHw-8","rowContent":"dlHw-8","align-widgets-center":"OyAt2X","alignWidgetsCenter":"OyAt2X","icon-container":"_08h-iq","iconContainer":"_08h-iq","content-wrapper":"fVienB","contentWrapper":"fVienB","icon-wrapper":"_94m5Ka","iconWrapper":"_94m5Ka","icon-default":"VfnBoS","iconDefault":"VfnBoS","selected-mark":"jDp6J-","selectedMark":"jDp6J-"};
|
|
3350
|
-
|
|
3351
|
-
var css$P = {"root":"_86NRQl"};
|
|
3352
|
-
|
|
3353
|
-
const AvatarStack = /* @__PURE__ */uuiCore.withMods(uuiComponents.AvatarStack, () => [css$P.root]);
|
|
3354
|
-
|
|
3355
|
-
var css$O = {"root":"_4qT-dg"};
|
|
3356
|
-
|
|
3357
|
-
const DEFAULT_FILL = 'solid';
|
|
3358
|
-
function applyBadgeMods(mods) {
|
|
3359
|
-
return [
|
|
3360
|
-
'uui-badge',
|
|
3361
|
-
css$O.root,
|
|
3362
|
-
`uui-size-${mods.size || settings.badge.sizes.default}`,
|
|
3363
|
-
`uui-fill-${mods.fill || DEFAULT_FILL}`,
|
|
3364
|
-
`uui-color-${mods.color || 'info'}`,
|
|
3365
|
-
];
|
|
3366
|
-
}
|
|
3367
|
-
const Badge = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => {
|
|
3368
|
-
const styles = [applyBadgeMods(props), props.cx];
|
|
3369
|
-
const DropdownIcon = props.dropdownIcon ? props.dropdownIcon : settings.badge.icons.dropdownIcon;
|
|
3370
|
-
return (React__namespace.default.createElement(uuiComponents.Clickable, { ...props, rawProps: {
|
|
3371
|
-
'aria-haspopup': props.isDropdown,
|
|
3372
|
-
'aria-expanded': props.isOpen,
|
|
3373
|
-
...props.rawProps,
|
|
3374
|
-
}, cx: styles, ref: ref },
|
|
3375
|
-
(props.indicator && props.fill === 'outline') && (React__namespace.default.createElement("div", { className: "uui-indicator" })),
|
|
3376
|
-
props.icon && props.iconPosition !== 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
3377
|
-
props.caption && (React__namespace.default.createElement("div", { className: uuiCore.uuiElement.caption }, props.caption)),
|
|
3378
|
-
props.count !== undefined && props.count !== null && (React__namespace.default.createElement(CountIndicator, { key: "count-indicator", color: null, size: settings.badge.sizes.countIndicatorMap[props.size || settings.badge.sizes.default], caption: props.count })),
|
|
3379
|
-
props.icon && props.iconPosition === 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
3380
|
-
props.isDropdown && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: DropdownIcon, flipY: props.isOpen }))));
|
|
3381
|
-
});
|
|
3382
|
-
|
|
3383
|
-
var css$N = {"root":"LNHyR-"};
|
|
3739
|
+
var css$I = {"search-wrapper":"LI6Ne8","searchWrapper":"LI6Ne8","no-data":"GZfFGS","noData":"GZfFGS"};
|
|
3384
3740
|
|
|
3385
|
-
|
|
3386
|
-
return [
|
|
3387
|
-
css$N.root,
|
|
3388
|
-
`uui-size-${props.size || settings.tag.sizes.default}`,
|
|
3389
|
-
`uui-color-${props.color || 'neutral'}`,
|
|
3390
|
-
`uui-fill-${props.fill || 'solid'}`,
|
|
3391
|
-
'uui-tag',
|
|
3392
|
-
];
|
|
3393
|
-
}
|
|
3394
|
-
const Tag = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => {
|
|
3395
|
-
const styles = [applyTagMods(props), props.cx];
|
|
3396
|
-
const ClearIcon = props.clearIcon ? props.clearIcon : settings.tag.icons.clearIcon;
|
|
3397
|
-
const DropdownIcon = props.dropdownIcon ? props.dropdownIcon : settings.tag.icons.dropdownIcon;
|
|
3398
|
-
return (React__namespace.default.createElement(uuiComponents.Clickable, { ...props, rawProps: {
|
|
3399
|
-
'aria-haspopup': props.isDropdown,
|
|
3400
|
-
'aria-expanded': props.isOpen,
|
|
3401
|
-
...props.rawProps,
|
|
3402
|
-
}, cx: styles, ref: ref },
|
|
3403
|
-
props.icon && props.iconPosition !== 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
3404
|
-
props.caption && (React__namespace.default.createElement("div", { className: uuiCore.uuiElement.caption }, props.caption)),
|
|
3405
|
-
props.count !== undefined && props.count !== null && (React__namespace.default.createElement(CountIndicator, { color: (!props.color || props.color === 'neutral') ? 'white' : props.color, size: settings.tag.sizes.countIndicatorMap[(props.size || settings.tag.sizes.default)], caption: props.count })),
|
|
3406
|
-
props.icon && props.iconPosition === 'right' && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: !props.isDisabled ? props.onIconClick : undefined })),
|
|
3407
|
-
props.isDropdown && (React__namespace.default.createElement(uuiComponents.IconContainer, { icon: DropdownIcon, flipY: props.isOpen })),
|
|
3408
|
-
props.onClear && !props.isDisabled && (React__namespace.default.createElement(uuiComponents.IconContainer, { cx: uuiCore.uuiMarkers.clickable, icon: ClearIcon, onClick: props.onClear }))));
|
|
3409
|
-
});
|
|
3410
|
-
|
|
3411
|
-
var css$M = {"root":"FKoLYk","page":"-Ra7SI","spacer":"Oi9A1x","mode-ghost":"TpZYzP","modeGhost":"TpZYzP"};
|
|
3412
|
-
|
|
3413
|
-
function Paginator(props) {
|
|
3414
|
-
const renderPaginator = (params) => (React__namespace.default.createElement("nav", { role: "navigation", className: cx__default.default(css$M.root, 'uui-paginator', `uui-size-${props.size || settings.paginator.sizes.default}`), ...params.rawProps },
|
|
3415
|
-
React__namespace.default.createElement(Button, { size: props.size || settings.paginator.sizes.default, icon: settings.paginator.icons.leftArrowIcon, onClick: params.goToPrev, isDisabled: params.isFirst || props.isDisabled, fill: "outline", color: "secondary" }),
|
|
3416
|
-
params.pages.map((page, index) => {
|
|
3417
|
-
if (page.type === 'spacer') {
|
|
3418
|
-
return (React__namespace.default.createElement(Button, { cx: cx__default.default(css$M.spacer, css$M.page), size: props.size || settings.paginator.sizes.default, key: `${index}_spacer`, caption: "...", fill: "ghost", color: "secondary", tabIndex: -1, isDisabled: props.isDisabled }));
|
|
3419
|
-
}
|
|
3420
|
-
else {
|
|
3421
|
-
return (React__namespace.default.createElement(Button, { cx: cx__default.default(css$M[`mode-${!page.isActive && 'ghost'}`], css$M.page), size: props.size || settings.paginator.sizes.default, key: page.pageNumber, caption: page.pageNumber, onClick: () => page.onClick?.(), rawProps: { 'aria-current': page.isActive }, fill: (page.isActive && 'outline') || 'ghost', color: "primary", isDisabled: props.isDisabled }));
|
|
3422
|
-
}
|
|
3423
|
-
}),
|
|
3424
|
-
React__namespace.default.createElement(Button, { size: props.size || settings.paginator.sizes.default, icon: settings.paginator.icons.rightArrowIcon, onClick: params.goToNext, isDisabled: params.isLast || props.isDisabled, fill: "outline", color: "secondary" })));
|
|
3425
|
-
return React__namespace.default.createElement(uuiComponents.Paginator, { ...props, render: renderPaginator });
|
|
3426
|
-
}
|
|
3427
|
-
|
|
3428
|
-
var css$L = {"root":"O49G0H","progress-bar":"oX3pvS","progressBar":"oX3pvS","progressBar-indeterminate":"QKuEjD","progressBarIndeterminate":"QKuEjD","size-12":"S-U8PS","size12":"S-U8PS","size-18":"QqQq--","size18":"QqQq--","size-24":"QZ9aGj","size24":"QZ9aGj"};
|
|
3429
|
-
|
|
3430
|
-
const IndeterminateBar = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
3431
|
-
return (React__namespace.createElement("div", { ref: ref, className: cx__default.default('uui-indeterminate_bar', props.cx, css$L.root, css$L[`size-${props.size || 12}`]) },
|
|
3432
|
-
React__namespace.createElement("div", { className: cx__default.default(css$L.progressBar) })));
|
|
3433
|
-
});
|
|
3434
|
-
|
|
3435
|
-
var css$K = {"root":"REaQX3","striped":"W0h6gP","animate-stripes":"_5I3FMZ","animateStripes":"_5I3FMZ","size-12":"qEKAxJ","size12":"qEKAxJ","size-18":"n5uxU0","size18":"n5uxU0","size-24":"rHeOEd","size24":"rHeOEd"};
|
|
3436
|
-
|
|
3437
|
-
const DEFAULT_SIZE = '12';
|
|
3438
|
-
function applyProgressBarMods(mods) {
|
|
3439
|
-
const size = mods.size || DEFAULT_SIZE;
|
|
3440
|
-
return [
|
|
3441
|
-
css$K.root,
|
|
3442
|
-
css$K[`size-${size}`],
|
|
3443
|
-
mods.striped && css$K.striped,
|
|
3444
|
-
];
|
|
3445
|
-
}
|
|
3446
|
-
const ProgressBar = /* @__PURE__ */uuiCore.withMods(uuiComponents__namespace.ProgressBar, applyProgressBarMods, (props) => ({
|
|
3447
|
-
hideLabel: props.hideLabel || props.striped,
|
|
3448
|
-
}));
|
|
3449
|
-
|
|
3450
|
-
var css$J = {"root":"_0sp5PJ"};
|
|
3451
|
-
|
|
3452
|
-
const IndicatorBar = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
3453
|
-
const { progress } = props;
|
|
3454
|
-
return progress || progress === 0 ? (React__namespace.createElement(ProgressBar, { ref: ref, progress: progress, cx: cx__default.default(css$J.root, props.cx), hideLabel: true })) : (React__namespace.createElement(IndeterminateBar, { ref: ref, cx: cx__default.default(css$J.root, props.cx) }));
|
|
3455
|
-
});
|
|
3456
|
-
|
|
3457
|
-
var css$I = {"root":"_9sFjB5"};
|
|
3458
|
-
|
|
3459
|
-
const StatusIndicator = /* @__PURE__ */React.forwardRef((props, ref) => {
|
|
3460
|
-
return (React__namespace.default.createElement("div", { ref: ref, className: cx__default.default([
|
|
3461
|
-
css$I.root,
|
|
3462
|
-
`uui-size-${props.size || settings.statusIndicator.sizes.default}`,
|
|
3463
|
-
'uui-status_indicator',
|
|
3464
|
-
`uui-color-${props.color || 'neutral'}`,
|
|
3465
|
-
`uui-fill-${props.fill || 'solid'}`,
|
|
3466
|
-
props.cx,
|
|
3467
|
-
]) },
|
|
3468
|
-
React__namespace.default.createElement("div", { className: "uui-status_indicator-dot" }),
|
|
3469
|
-
React__namespace.default.createElement("p", { className: "uui-status_indicator-caption" }, props.caption)));
|
|
3470
|
-
});
|
|
3471
|
-
|
|
3472
|
-
var css$H = {"drag-handle-wrapper":"m60Juc","dragHandleWrapper":"m60Juc","with-indent":"INTgRy","withIndent":"INTgRy","drag-handle":"waOWlA","dragHandle":"waOWlA","icon-container":"J0-rxs","iconContainer":"J0-rxs"};
|
|
3473
|
-
|
|
3474
|
-
function DataRowAddons(props) {
|
|
3475
|
-
const row = props.rowProps;
|
|
3476
|
-
const getIndent = () => {
|
|
3477
|
-
return (row.indent - 1) * settings.dataTable.sizes.body.indentUnitMap[props.size || settings.dataTable.sizes.body.row];
|
|
3478
|
-
};
|
|
3479
|
-
const getWidth = () => {
|
|
3480
|
-
return settings.dataTable.sizes.body.indentWidthMap[props.size || settings.dataTable.sizes.body.row];
|
|
3481
|
-
};
|
|
3482
|
-
const renderDragHandle = () => {
|
|
3483
|
-
if (props.renderDragHandle) {
|
|
3484
|
-
return props.renderDragHandle({ rowProps: props.rowProps, eventHandlers: props.eventHandlers });
|
|
3485
|
-
}
|
|
3486
|
-
return (React__namespace.default.createElement("div", { key: "dh", className: cx__default.default(css$H.dragHandleWrapper, row.indent > 0 && css$H.withIndent), style: { width: row.indent > 0 ? (getIndent() + getWidth()) : 0 }, ...props.eventHandlers },
|
|
3487
|
-
React__namespace.default.createElement(uuiComponents.DragHandle, { cx: css$H.dragHandle })));
|
|
3488
|
-
};
|
|
3489
|
-
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
3490
|
-
row.dnd?.srcData && renderDragHandle(),
|
|
3491
|
-
row?.checkbox?.isVisible && (React__namespace.default.createElement(Checkbox, { key: "cb", cx: "uui-dr_addons-checkbox", tabIndex: props.tabIndex, size: settings.dataTable.sizes.body.checkboxMap[props.size], value: row.isChecked, indeterminate: !row.isChecked && row.isChildrenChecked, onValueChange: () => row.onCheck?.(row), isDisabled: row.checkbox.isDisabled, isInvalid: row.checkbox.isInvalid })),
|
|
3492
|
-
row.indent > 0 && (React__namespace.default.createElement("div", { key: "fold", className: cx__default.default('uui-dr_addons-indent', `uui-size-${props.size || settings.dataTable.sizes.body.row}`), style: { marginInlineStart: getIndent(), width: getWidth() } }, row.isFoldable && (React__namespace.default.createElement(uuiComponents.IconContainer, { rawProps: {
|
|
3493
|
-
'aria-label': row.isFolded ? 'Unfold' : 'Fold',
|
|
3494
|
-
role: 'button',
|
|
3495
|
-
}, key: "icon", icon: settings.dataTable.icons.body.foldingIcon, cx: [
|
|
3496
|
-
uuiCore.uuiElement.foldingArrow, uuiCore.uuiMarkers.clickable, css$H.iconContainer,
|
|
3497
|
-
], rotate: row.isFolded ? '90ccw' : '0', onClick: () => row.onFold(row), size: settings.dataTable.sizes.body.iconMap[props.size || settings.dataTable.sizes.body.row] }))))));
|
|
3498
|
-
}
|
|
3741
|
+
var css$H = {"picker-row":"_6cp1MK","pickerRow":"_6cp1MK","align-widgets-top":"faIUYo","alignWidgetsTop":"faIUYo","row-content":"zctZK0","rowContent":"zctZK0","align-widgets-center":"_1Kvir6","alignWidgetsCenter":"_1Kvir6","icon-container":"zs82EY","iconContainer":"zs82EY","content-wrapper":"FwKXt3","contentWrapper":"FwKXt3","icon-wrapper":"_3I1JBQ","iconWrapper":"_3I1JBQ","icon-default":"_2-bWe-","iconDefault":"_2-bWe-","selected-mark":"ybARsV","selectedMark":"ybARsV"};
|
|
3499
3742
|
|
|
3500
3743
|
const mergeHighlightRanges = (ranges) => {
|
|
3501
3744
|
const mergedRanges = [];
|
|
@@ -3562,7 +3805,7 @@ const getHighlightedSearchMatches = (str, search) => {
|
|
|
3562
3805
|
return getDecoratedText(str, ranges);
|
|
3563
3806
|
};
|
|
3564
3807
|
|
|
3565
|
-
var css$G = {"root":"
|
|
3808
|
+
var css$G = {"root":"H7CF2p","column-gap":"_36BmDK","columnGap":"_36BmDK","title":"eWUnIT","subtitle":"Gz0osj","disabled":"IxLjh4","multiline":"rEm-xY"};
|
|
3566
3809
|
|
|
3567
3810
|
function PickerItem(props) {
|
|
3568
3811
|
const { highlightSearchMatches = true, size, avatarUrl, isLoading, isDisabled, icon, } = props;
|
|
@@ -3570,14 +3813,13 @@ function PickerItem(props) {
|
|
|
3570
3813
|
const isMultiline = !!(props.title && props.subtitle);
|
|
3571
3814
|
const { search } = props.dataSourceState ?? {};
|
|
3572
3815
|
const title = highlightSearchMatches ? getHighlightedSearchMatches(props.title, search) : props.title;
|
|
3573
|
-
const subtitle = highlightSearchMatches ? getHighlightedSearchMatches(props.subtitle, search) : props.subtitle;
|
|
3574
3816
|
return (React__namespace.createElement(FlexCell, { width: "auto", cx: [css$G.root, 'uui-picker_input-item', 'uui-typography', props.cx] },
|
|
3575
3817
|
React__namespace.createElement(FlexRow, { size: itemSize, cx: [isMultiline && css$G.multiline, css$G.columnGap], rawProps: { style: { '--uui-picker_item-vertical-padding': `${settings.pickerInput.sizes.body.itemVerticalPaddingMap[itemSize]}px` } } },
|
|
3576
3818
|
avatarUrl && (React__namespace.createElement(uuiComponents.Avatar, { isLoading: isLoading, img: avatarUrl, size: getAvatarSize(itemSize, isMultiline) })),
|
|
3577
3819
|
icon && React__namespace.createElement(uuiComponents.IconContainer, { icon: icon }),
|
|
3578
3820
|
React__namespace.createElement(FlexCell, { width: "auto" },
|
|
3579
3821
|
title && (React__namespace.createElement("div", { className: cx__default.default(css$G.title, isDisabled && css$G.disabled, `uui-size-${itemSize}`) }, title)),
|
|
3580
|
-
subtitle && (React__namespace.createElement("div", { className: cx__default.default(css$G.subtitle, isDisabled && css$G.disabled, `uui-size-${itemSize}`) }, subtitle))))));
|
|
3822
|
+
props.subtitle && (React__namespace.createElement("div", { className: cx__default.default(css$G.subtitle, isDisabled && css$G.disabled, `uui-size-${itemSize}`) }, props.subtitle))))));
|
|
3581
3823
|
}
|
|
3582
3824
|
function getAvatarSize(size, isMultiline) {
|
|
3583
3825
|
return settings.pickerInput.sizes.body[isMultiline ? 'itemAvatarMultilineMap' : 'itemAvatarMap'][size];
|
|
@@ -3625,19 +3867,19 @@ function DataPickerRow(props) {
|
|
|
3625
3867
|
content = (React__namespace.createElement(React__namespace.Fragment, null,
|
|
3626
3868
|
renderRowItem(props.value, props),
|
|
3627
3869
|
React__namespace.createElement(uuiComponents.FlexSpacer, null),
|
|
3628
|
-
(props.isChildrenSelected || props.isSelected) && (React__namespace.createElement("div", { className: uuiCore.cx(css$
|
|
3629
|
-
React__namespace.createElement(uuiComponents.IconContainer, { size: settings.pickerInput.sizes.body.selectIconMap[props.size], icon: SelectIcon, cx: props.isChildrenSelected ? css$
|
|
3870
|
+
(props.isChildrenSelected || props.isSelected) && (React__namespace.createElement("div", { className: uuiCore.cx(css$H.iconWrapper, 'uui-picker_input-row-select_icon', uuiCore.uuiMod.selected) },
|
|
3871
|
+
React__namespace.createElement(uuiComponents.IconContainer, { size: settings.pickerInput.sizes.body.selectIconMap[props.size], icon: SelectIcon, cx: props.isChildrenSelected ? css$H.iconDefault : css$H.selectedMark, rawProps: { 'aria-label': props.isChildrenSelected
|
|
3630
3872
|
? 'Child is selected'
|
|
3631
3873
|
: 'Selected' } })))));
|
|
3632
3874
|
}
|
|
3633
|
-
return (React__namespace.createElement(FlexCell, { grow: 1, width: 0, minWidth: 0, cx: css$
|
|
3875
|
+
return (React__namespace.createElement(FlexCell, { grow: 1, width: 0, minWidth: 0, cx: css$H.rowContent },
|
|
3634
3876
|
React__namespace.createElement(DataRowAddons, { size: props.size, rowProps: props, tabIndex: -1 }),
|
|
3635
|
-
React__namespace.createElement("div", { className: css$
|
|
3877
|
+
React__namespace.createElement("div", { className: css$H.contentWrapper }, content)));
|
|
3636
3878
|
};
|
|
3637
3879
|
const clickHandler = props.onClick || props.onSelect || props.onFold || props.onCheck;
|
|
3638
3880
|
return (
|
|
3639
3881
|
// eslint-disable-next-line jsx-a11y/click-events-have-key-events
|
|
3640
|
-
React__namespace.createElement("div", { onClick: clickHandler && ((e) => !uuiCore.isEventTargetInsideClickable(e) && clickHandler(props)), role: "option", "aria-busy": props.isLoading, "aria-posinset": props.index + 1, "aria-checked": props.checkbox?.isVisible ? props.isChecked : null, "aria-selected": props.isSelectable ? props.isSelected : null, ref: rowNode, className: uuiCore.cx(css$
|
|
3882
|
+
React__namespace.createElement("div", { onClick: clickHandler && ((e) => !uuiCore.isEventTargetInsideClickable(e) && clickHandler(props)), role: "option", "aria-busy": props.isLoading, "aria-posinset": props.index + 1, "aria-checked": props.checkbox?.isVisible ? props.isChecked : null, "aria-selected": props.isSelectable ? props.isSelected : null, ref: rowNode, className: uuiCore.cx(css$H.pickerRow, 'uui-picker_input-row', `uui-size-${props.size || settings.pickerInput.sizes.body.row}`, css$H[`align-widgets-${props.alignActions || 'top'}`], clickHandler && props.isFocused && uuiCore.uuiMod.focus, clickHandler && uuiCore.uuiMarkers.clickable, props.cx), style: props.padding && {
|
|
3641
3883
|
'--uui-data_picker-horizontal-padding': `${props.padding}px`,
|
|
3642
3884
|
}, ...props.rawProps }, renderContent()));
|
|
3643
3885
|
}
|
|
@@ -3665,7 +3907,7 @@ function DataPickerBody({ highlightSearchMatches = true, ...props }) {
|
|
|
3665
3907
|
});
|
|
3666
3908
|
}
|
|
3667
3909
|
if (props.minCharsToSearch && search.length < props.minCharsToSearch) {
|
|
3668
|
-
return (React__namespace.default.createElement(uuiComponents.FlexCell, { cx: css$
|
|
3910
|
+
return (React__namespace.default.createElement(uuiComponents.FlexCell, { cx: css$I.noData, grow: 1, textAlign: "center" },
|
|
3669
3911
|
React__namespace.default.createElement(Text, { size: props.searchSize }, i18n.dataPickerBody.typeSearchToLoadMessage)));
|
|
3670
3912
|
}
|
|
3671
3913
|
if (props.rows.length === 0) {
|
|
@@ -3678,7 +3920,7 @@ function DataPickerBody({ highlightSearchMatches = true, ...props }) {
|
|
|
3678
3920
|
search: search,
|
|
3679
3921
|
});
|
|
3680
3922
|
}
|
|
3681
|
-
return (React__namespace.default.createElement(uuiComponents.FlexCell, { cx: css$
|
|
3923
|
+
return (React__namespace.default.createElement(uuiComponents.FlexCell, { cx: css$I.noData, grow: 1, textAlign: "center" },
|
|
3682
3924
|
React__namespace.default.createElement(Text, { size: props.searchSize }, i18n.dataPickerBody.noRecordsMessage)));
|
|
3683
3925
|
}
|
|
3684
3926
|
};
|
|
@@ -3697,7 +3939,7 @@ function DataPickerBody({ highlightSearchMatches = true, ...props }) {
|
|
|
3697
3939
|
: settings.pickerInput.sizes.body.getSearchSize({ pickerSize: props.searchSize });
|
|
3698
3940
|
const renderedDataRows = React.useMemo(() => props.rows.map((row) => renderRow(row, props.value)), [props.rows, props.value]);
|
|
3699
3941
|
return (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
3700
|
-
showSearch && (React__namespace.default.createElement("div", { key: "search", className: uuiCore.cx(css$
|
|
3942
|
+
showSearch && (React__namespace.default.createElement("div", { key: "search", className: uuiCore.cx(css$I.searchWrapper, 'uui-picker_input-body-search') },
|
|
3701
3943
|
React__namespace.default.createElement(uuiComponents.FlexCell, { grow: 1 },
|
|
3702
3944
|
React__namespace.default.createElement(FocusLock.MoveFocusInside, null,
|
|
3703
3945
|
React__namespace.default.createElement(SearchInput, { placeholder: i18n.dataPickerBody.searchPlaceholder, value: props.value.search, onValueChange: (newVal) => props.onValueChange({ ...props.value, search: newVal }), onKeyDown: searchKeyDown, size: searchSize, debounceDelay: props.searchDebounceDelay, rawProps: { dir: 'auto' } }))))),
|
|
@@ -3709,7 +3951,7 @@ function DataPickerBody({ highlightSearchMatches = true, ...props }) {
|
|
|
3709
3951
|
'aria-orientation': 'vertical',
|
|
3710
3952
|
tabIndex: -1,
|
|
3711
3953
|
...props.rawProps,
|
|
3712
|
-
}, rowsCount: props.rowsCount, isLoading: props.isReloading, renderBlocker: settings.pickerInput.renderBlocker })))));
|
|
3954
|
+
}, rowsCount: props.rowsCount, isLoading: props.isReloading, renderBlocker: settings.pickerInput.renderBlocker, overflowTopEffect: showSearch ? 'line' : 'none', overflowBottomEffect: "line" })))));
|
|
3713
3955
|
}
|
|
3714
3956
|
|
|
3715
3957
|
function DataPickerFooterImpl(props) {
|
|
@@ -3736,7 +3978,7 @@ function DataPickerFooterImpl(props) {
|
|
|
3736
3978
|
}
|
|
3737
3979
|
const DataPickerFooter = /* @__PURE__ */React__namespace.default.memo(DataPickerFooterImpl);
|
|
3738
3980
|
|
|
3739
|
-
var css$F = {"header":"
|
|
3981
|
+
var css$F = {"header":"SS-3Uh","title":"jIxoPH","close":"CTpj87"};
|
|
3740
3982
|
|
|
3741
3983
|
const DataPickerMobileHeaderImpl = (props) => {
|
|
3742
3984
|
const title = props.title && typeof props.title === 'string' ? props.title.charAt(0).toUpperCase() + props.title.slice(1) : '';
|
|
@@ -3746,7 +3988,7 @@ const DataPickerMobileHeaderImpl = (props) => {
|
|
|
3746
3988
|
};
|
|
3747
3989
|
const DataPickerMobileHeader = /* @__PURE__ */React__namespace.default.memo(DataPickerMobileHeaderImpl);
|
|
3748
3990
|
|
|
3749
|
-
var css$E = {"done":"
|
|
3991
|
+
var css$E = {"done":"ozLT3k","container":"ghCR8W"};
|
|
3750
3992
|
|
|
3751
3993
|
const PickerBodyMobileView = (props) => {
|
|
3752
3994
|
const isMobileView = uuiCore.isMobile();
|
|
@@ -3758,7 +4000,7 @@ const PickerBodyMobileView = (props) => {
|
|
|
3758
4000
|
isMobileView && (React__namespace.default.createElement(LinkButton, { caption: i18n.pickerInput.doneButton, onClick: () => props.onClose?.(), cx: css$E.done, size: settings.pickerInput.sizes.body.mobileFooterLinkButton }))));
|
|
3759
4001
|
};
|
|
3760
4002
|
|
|
3761
|
-
var css$D = {"sub-header-wrapper":"
|
|
4003
|
+
var css$D = {"sub-header-wrapper":"q7O-lH","subHeaderWrapper":"q7O-lH","switch":"oc7wMg","no-found-modal-container":"gQCW-D","noFoundModalContainer":"gQCW-D","no-found-modal-container-icon":"Yd-1du","noFoundModalContainerIcon":"Yd-1du","no-found-modal-container-text":"GcZVa2","noFoundModalContainerText":"GcZVa2","body":"dzqHRB"};
|
|
3762
4004
|
|
|
3763
4005
|
function PickerModal(props) {
|
|
3764
4006
|
const { view, selection, dataSourceStateLens, dataSourceState, getName, clearSelection, getRows, getListProps, getFooterProps, isSingleSelect, handleDataSourceValueChange, } = uuiComponents.usePickerModal(props);
|
|
@@ -3804,7 +4046,7 @@ function PickerModal(props) {
|
|
|
3804
4046
|
React__namespace.default.createElement(ModalFooter, null, props.renderFooter ? props.renderFooter(getFooterProps()) : renderFooter()))));
|
|
3805
4047
|
}
|
|
3806
4048
|
|
|
3807
|
-
var css$C = {"tooltip":"
|
|
4049
|
+
var css$C = {"tooltip":"MF9jqp"};
|
|
3808
4050
|
|
|
3809
4051
|
const PickerTogglerTag = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
3810
4052
|
const tagProps = {
|
|
@@ -3823,7 +4065,7 @@ const PickerTogglerTag = /* @__PURE__ */React__namespace.forwardRef((props, ref)
|
|
|
3823
4065
|
}
|
|
3824
4066
|
});
|
|
3825
4067
|
|
|
3826
|
-
var css$B = {"root":"
|
|
4068
|
+
var css$B = {"root":"uRM0DJ"};
|
|
3827
4069
|
|
|
3828
4070
|
const defaultMode = EditMode.FORM;
|
|
3829
4071
|
function applyPickerTogglerMods(mods) {
|
|
@@ -3905,7 +4147,7 @@ function PickerInputComponent(props, ref) {
|
|
|
3905
4147
|
}
|
|
3906
4148
|
const PickerInput = /* @__PURE__ */React__namespace.default.forwardRef(PickerInputComponent);
|
|
3907
4149
|
|
|
3908
|
-
var css$A = {"row":"
|
|
4150
|
+
var css$A = {"row":"_2u3Ayo"};
|
|
3909
4151
|
|
|
3910
4152
|
function PickerListRow(props) {
|
|
3911
4153
|
let label;
|
|
@@ -3925,7 +4167,7 @@ function PickerListRow(props) {
|
|
|
3925
4167
|
return (React__namespace.default.createElement("div", { role: "option", "aria-selected": props.isSelectable ? props.isSelected : undefined, "aria-busy": props.isLoading, "aria-posinset": props.index + 1, ...(props.checkbox?.isVisible && { 'aria-checked': props.isChecked }), className: css$A.row }, component));
|
|
3926
4168
|
}
|
|
3927
4169
|
|
|
3928
|
-
var css$z = {"root":"
|
|
4170
|
+
var css$z = {"root":"oktYdH"};
|
|
3929
4171
|
|
|
3930
4172
|
function PickerList(props) {
|
|
3931
4173
|
const { context, view, onlySelectedView, getName, getEntityName, appendLastSelected, getSelectedIdsArray, buildRowsList, getMaxDefaultItems, getModalTogglerCaption, } = uuiComponents.usePickerList(props);
|
|
@@ -3960,7 +4202,7 @@ function PickerList(props) {
|
|
|
3960
4202
|
}, selectedRows)));
|
|
3961
4203
|
}
|
|
3962
4204
|
|
|
3963
|
-
var css$y = {"root":"
|
|
4205
|
+
var css$y = {"root":"NGjEfX","wrapper":"WmJNRA","align-widgets-top":"_2Nav-w","alignWidgetsTop":"_2Nav-w","align-widgets-center":"IqMJZ7","alignWidgetsCenter":"IqMJZ7"};
|
|
3964
4206
|
|
|
3965
4207
|
function DataTableCell(initialProps) {
|
|
3966
4208
|
const props = { ...initialProps };
|
|
@@ -4010,7 +4252,7 @@ function DataTableCell(initialProps) {
|
|
|
4010
4252
|
return React__namespace.createElement(uuiComponents.DataTableCell, { ...props });
|
|
4011
4253
|
}
|
|
4012
4254
|
|
|
4013
|
-
var css$x = {"root":"
|
|
4255
|
+
var css$x = {"root":"_3B0xu-"};
|
|
4014
4256
|
|
|
4015
4257
|
// Here we define a single instance of the renderCell function to make DataTableRow#shouldComponentUpdate work.
|
|
4016
4258
|
// 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.
|
|
@@ -4026,7 +4268,7 @@ const DataTableRow = /* @__PURE__ */uuiCore.withMods(uuiComponents.DataTableRow,
|
|
|
4026
4268
|
];
|
|
4027
4269
|
}, () => propsMods);
|
|
4028
4270
|
|
|
4029
|
-
var css$w = {"sorting-panel-container":"
|
|
4271
|
+
var css$w = {"sorting-panel-container":"Wk4TKo","sortingPanelContainer":"Wk4TKo"};
|
|
4030
4272
|
|
|
4031
4273
|
const SortingPanelImpl = ({ sortDirection, onSort }) => {
|
|
4032
4274
|
const sortAsc = React.useCallback(() => onSort(sortDirection === 'asc' ? undefined : 'asc'), [onSort]);
|
|
@@ -4046,7 +4288,7 @@ const ColumnHeaderDropdownImpl = (props) => {
|
|
|
4046
4288
|
};
|
|
4047
4289
|
const ColumnHeaderDropdown = /* @__PURE__ */React__namespace.default.memo(ColumnHeaderDropdownImpl);
|
|
4048
4290
|
|
|
4049
|
-
var css$v = {"root":"
|
|
4291
|
+
var css$v = {"root":"pbCilY","caption-wrapper":"kKrvyf","captionWrapper":"kKrvyf","sort-icon":"_0HCjfB","sortIcon":"_0HCjfB","dropdown-icon":"_1xdL9q","dropdownIcon":"_1xdL9q","infoIcon":"_529USl","align-right":"b53Phw","alignRight":"b53Phw","align-center":"cFihLb","alignCenter":"cFihLb","caption":"YXQOCU","truncate":"jg83S5","upper-case":"_0Rhbef","upperCase":"_0Rhbef","checkbox":"h5VwzM","icon":"Y6tqhg","fold-all-icon":"tCfaP0","foldAllIcon":"tCfaP0","cell-tooltip":"LnPuCz","cellTooltip":"LnPuCz","resizing-marker":"zJ848M","resizingMarker":"zJ848M","pinned-right":"oOPyKQ","pinnedRight":"oOPyKQ","draggable":"XyGdEU","ghost":"Y2mK0K","is-dragged-out":"s3pOC2","isDraggedOut":"s3pOC2","dnd-marker-left":"VQ7F9l","dndMarkerLeft":"VQ7F9l","dnd-marker-right":"_4czKk1","dndMarkerRight":"_4czKk1","cell-tooltip-wrapper":"G672hm","cellTooltipWrapper":"G672hm","cell-tooltip-text":"t9G04e","cellTooltipText":"t9G04e","tooltip-caption":"Z2xriK","tooltipCaption":"Z2xriK","tooltip-info":"-uPuyj","tooltipInfo":"-uPuyj"};
|
|
4050
4292
|
|
|
4051
4293
|
class DataTableHeaderCell extends React__namespace.Component {
|
|
4052
4294
|
constructor() {
|
|
@@ -4140,7 +4382,7 @@ class DataTableHeaderCell extends React__namespace.Component {
|
|
|
4140
4382
|
}
|
|
4141
4383
|
}
|
|
4142
4384
|
|
|
4143
|
-
var css$u = {"root":"
|
|
4385
|
+
var css$u = {"root":"GJA-jl","caption-wrapper":"JeQsdh","captionWrapper":"JeQsdh","align-center":"-AI1-m","alignCenter":"-AI1-m","caption":"_7p-MQZ","truncate":"NbBQc6","upper-case":"sBGMS-","upperCase":"sBGMS-","group-cell-tooltip":"Y9xwZN","groupCellTooltip":"Y9xwZN","group-cell-tooltip-wrapper":"y62P49","groupCellTooltipWrapper":"y62P49","group-cell-tooltip-text":"KV5V7M","groupCellTooltipText":"KV5V7M","tooltip-caption":"Cc9PMG","tooltipCaption":"Cc9PMG","tooltip-info":"pmBFBy","tooltipInfo":"pmBFBy"};
|
|
4144
4386
|
|
|
4145
4387
|
class DataTableHeaderGroupCell extends React__namespace.Component {
|
|
4146
4388
|
constructor() {
|
|
@@ -4180,7 +4422,7 @@ class DataTableHeaderGroupCell extends React__namespace.Component {
|
|
|
4180
4422
|
}
|
|
4181
4423
|
}
|
|
4182
4424
|
|
|
4183
|
-
var css$t = {"root":"
|
|
4425
|
+
var css$t = {"root":"bELrvr"};
|
|
4184
4426
|
|
|
4185
4427
|
const DataTableHeaderRow = /* @__PURE__ */uuiCore.withMods(uuiComponents.DataTableHeaderRow, () => [css$t.root, 'uui-dt-vars'], (mods) => ({
|
|
4186
4428
|
renderCell: (props) => (React__namespace.createElement(DataTableHeaderCell, { ...props, size: mods.size, textCase: mods.textCase || 'normal', key: props.column.key, columnsGap: mods.columnsGap })),
|
|
@@ -4276,7 +4518,7 @@ const UUI_FILTERS_PANEL_ITEM_TOGGLER_SELECTION = 'uui-filters-panel-item-toggler
|
|
|
4276
4518
|
const UUI_FILTERS_PANEL_ITEM_TOGGLER_POSTFIX = 'uui-filters-panel-item-toggler-postfix';
|
|
4277
4519
|
const UUI_FILTERS_PANEL_BODY_FOOTER = 'uui-filters-panel-item-footer';
|
|
4278
4520
|
|
|
4279
|
-
var css$s = {"body":"
|
|
4521
|
+
var css$s = {"body":"YjsM2k","header":"ZBEDAy","title":"LinM-7","removeButton":"S7llfQ","with-search":"_5DFEet","withSearch":"_5DFEet"};
|
|
4280
4522
|
|
|
4281
4523
|
function FilterColumnBody(props) {
|
|
4282
4524
|
const [predicate, setPredicate] = React.useState(getDefaultPredicate(props.predicates, props.value));
|
|
@@ -4337,7 +4579,7 @@ const useColumnsWithFilters = (initialColumns, filters) => {
|
|
|
4337
4579
|
return columns;
|
|
4338
4580
|
};
|
|
4339
4581
|
|
|
4340
|
-
var css$r = {"unpin-icon":"
|
|
4582
|
+
var css$r = {"unpin-icon":"YQzsHo","unpinIcon":"YQzsHo","pin-toggler-icon":"AH6-nx","pinTogglerIcon":"AH6-nx"};
|
|
4341
4583
|
|
|
4342
4584
|
function PinIconButton(props) {
|
|
4343
4585
|
const i18nLocal = i18n.tables.columnsConfigurationModal;
|
|
@@ -4350,14 +4592,23 @@ function PinIconButton(props) {
|
|
|
4350
4592
|
const iconTooltip = isPinnedAlways ? i18nLocal.lockedColumnPinButton : i18nLocal.unPinColumnButton;
|
|
4351
4593
|
const unpinClickHandler = isPinnedAlways ? undefined : () => onTogglePin(undefined);
|
|
4352
4594
|
pinUnpinNode = (React__namespace.createElement(Tooltip, { content: iconTooltip, placement: "bottom", color: "inverted" },
|
|
4353
|
-
React__namespace.createElement(IconButton, { cx: uuiCore.cx(!isPinnedAlways && css$r.unpinIcon, css$r.pinTogglerIcon), icon: unpinIcon, onClick: unpinClickHandler, isDisabled: isPinnedAlways, color: "primary"
|
|
4595
|
+
React__namespace.createElement(IconButton, { cx: uuiCore.cx(!isPinnedAlways && css$r.unpinIcon, css$r.pinTogglerIcon), icon: unpinIcon, onClick: unpinClickHandler, isDisabled: isPinnedAlways, color: "primary", rawProps: {
|
|
4596
|
+
'aria-description': iconTooltip,
|
|
4597
|
+
'aria-label': 'Unpin Button',
|
|
4598
|
+
} })));
|
|
4354
4599
|
}
|
|
4355
4600
|
else {
|
|
4356
4601
|
pinUnpinNode = (React__namespace.createElement(React__namespace.Fragment, null,
|
|
4357
4602
|
React__namespace.createElement(Tooltip, { content: i18nLocal.pinColumnToTheLeftButton, placement: "bottom", color: "inverted" },
|
|
4358
|
-
React__namespace.createElement(IconButton, { cx: css$r.pinTogglerIcon, icon: settings.dataTable.icons.columnsConfigurationModal.pinLeftIcon, onClick: () => onTogglePin('left'), isDisabled: isPinnedAlways
|
|
4603
|
+
React__namespace.createElement(IconButton, { cx: css$r.pinTogglerIcon, icon: settings.dataTable.icons.columnsConfigurationModal.pinLeftIcon, onClick: () => onTogglePin('left'), isDisabled: isPinnedAlways, rawProps: {
|
|
4604
|
+
'aria-description': i18nLocal.pinColumnToTheLeftButton,
|
|
4605
|
+
'aria-label': 'Pin left button',
|
|
4606
|
+
} })),
|
|
4359
4607
|
React__namespace.createElement(Tooltip, { content: i18nLocal.pinColumnToTheRightButton, placement: "bottom", color: "inverted" },
|
|
4360
|
-
React__namespace.createElement(IconButton, { cx: css$r.pinTogglerIcon, icon: settings.dataTable.icons.columnsConfigurationModal.pinRightIcon, onClick: () => onTogglePin('right'), isDisabled: isPinnedAlways
|
|
4608
|
+
React__namespace.createElement(IconButton, { cx: css$r.pinTogglerIcon, icon: settings.dataTable.icons.columnsConfigurationModal.pinRightIcon, onClick: () => onTogglePin('right'), isDisabled: isPinnedAlways, rawProps: {
|
|
4609
|
+
'aria-description': i18nLocal.pinColumnToTheRightButton,
|
|
4610
|
+
'aria-label': 'Pin right button',
|
|
4611
|
+
} }))));
|
|
4361
4612
|
}
|
|
4362
4613
|
return pinUnpinNode;
|
|
4363
4614
|
}
|
|
@@ -4379,22 +4630,33 @@ function getUnpinIcon(params) {
|
|
|
4379
4630
|
}
|
|
4380
4631
|
}
|
|
4381
4632
|
|
|
4382
|
-
var css$q = {"row-wrapper":"
|
|
4633
|
+
var css$q = {"row-wrapper":"zJslkk","rowWrapper":"zJslkk","pin-icon-button":"iwmnEY","pinIconButton":"iwmnEY","not-pinned":"_-5k19-","notPinned":"_-5k19-","checkbox":"QRyN6c","drag-handle":"Syw6Ub","dragHandle":"Syw6Ub","dnd-disabled":"qhrR-D","dndDisabled":"qhrR-D"};
|
|
4383
4634
|
|
|
4384
4635
|
const ColumnRow = /* @__PURE__ */React__namespace.memo(function ColumnRow(props) {
|
|
4385
4636
|
const { column } = props;
|
|
4386
|
-
const { toggleVisibility, togglePin, onCanAcceptDrop, onDrop, columnConfig, isDndAllowed, isPinnedAlways, } = column;
|
|
4637
|
+
const { toggleVisibility, togglePin, onCanAcceptDrop, onDrop, columnConfig, isDndAllowed, isPinnedAlways, columnGroup, } = column;
|
|
4387
4638
|
const { isVisible, fix } = columnConfig;
|
|
4388
4639
|
const pinPosition = fix || (isPinnedAlways ? 'left' : undefined);
|
|
4389
4640
|
const isPinned = !!pinPosition;
|
|
4390
4641
|
const data = { column, columnConfig };
|
|
4642
|
+
const getColumnCaption = () => {
|
|
4643
|
+
if (props.renderItem) {
|
|
4644
|
+
return props.renderItem(props.column);
|
|
4645
|
+
}
|
|
4646
|
+
if (column.group) {
|
|
4647
|
+
return `${column.caption}/${columnGroup.caption}`;
|
|
4648
|
+
}
|
|
4649
|
+
else {
|
|
4650
|
+
return column.caption;
|
|
4651
|
+
}
|
|
4652
|
+
};
|
|
4391
4653
|
const renderContent = (dndActorParams) => {
|
|
4392
4654
|
const wrapperClasses = uuiCore.cx(css$q.rowWrapper, !isPinned && css$q.notPinned, dndActorParams.isDragGhost && uuiCore.uuiDndState.dragGhost, 'uui-dt-columns-config-row');
|
|
4393
4655
|
const { onTouchStart, onPointerDown, ...restEventHandlers } = dndActorParams.eventHandlers;
|
|
4394
4656
|
const { ref, ...dndActorPropsWithoutRef } = dndActorParams;
|
|
4395
4657
|
return (React__namespace.createElement(FlexRow, { size: settings.dataTable.sizes.columnsConfigurationModal.columnRow, cx: wrapperClasses, ref: dndActorParams.ref, rawProps: { ...restEventHandlers }, alignItems: "top" },
|
|
4396
4658
|
React__namespace.createElement(uuiComponents.DragHandle, { dragHandleIcon: settings.dataTable.icons.columnsConfigurationModal.dragIndicator, rawProps: { onTouchStart, onPointerDown }, isDisabled: !isDndAllowed, cx: uuiCore.cx(css$q.dragHandle, !isDndAllowed && css$q.dndDisabled) }),
|
|
4397
|
-
React__namespace.createElement(Checkbox, { key: column.key, label:
|
|
4659
|
+
React__namespace.createElement(Checkbox, { key: column.key, label: getColumnCaption(), value: isVisible, onValueChange: toggleVisibility, isReadonly: column.isAlwaysVisible || column.isLocked, cx: css$q.checkbox }),
|
|
4398
4660
|
React__namespace.createElement(FlexRow, { size: null, cx: css$q.pinIconButton },
|
|
4399
4661
|
React__namespace.createElement(PinIconButton, { pinPosition: pinPosition, canUnpin: !isPinnedAlways, onTogglePin: togglePin })),
|
|
4400
4662
|
React__namespace.createElement(DropMarker, { ...dndActorPropsWithoutRef })));
|
|
@@ -4402,7 +4664,7 @@ const ColumnRow = /* @__PURE__ */React__namespace.memo(function ColumnRow(props)
|
|
|
4402
4664
|
return (React__namespace.createElement(uuiCore.DndActor, { key: column.key, srcData: isDndAllowed && data, dstData: data, canAcceptDrop: onCanAcceptDrop, onDrop: onDrop, render: renderContent }));
|
|
4403
4665
|
});
|
|
4404
4666
|
|
|
4405
|
-
var css$p = {"root":"
|
|
4667
|
+
var css$p = {"root":"s0VYId","main-panel":"FWKGJW","mainPanel":"FWKGJW","group":"z9ehud","group-title":"ETOdas","groupTitle":"ETOdas","group-items":"rMfxth","groupItems":"rMfxth","no-data":"Gc6okj","noData":"Gc6okj","no-data-title":"i-WLSZ","noDataTitle":"i-WLSZ","no-data-sub-title":"cn2Twl","noDataSubTitle":"cn2Twl","h-divider":"aqcTmP","hDivider":"aqcTmP","search-area":"pupJ7S","searchArea":"pupJ7S","subgroup-accordion":"lnVqMP","subgroupAccordion":"lnVqMP","subgroup":"SDPOOg","subgroup-title":"cABfd-","subgroupTitle":"cABfd-"};
|
|
4406
4668
|
|
|
4407
4669
|
const renderGroupTitle = (title, amount) => (React__namespace.createElement(FlexRow, { cx: css$p.group },
|
|
4408
4670
|
React__namespace.createElement(Text, { size: "none", cx: css$p.groupTitle }, title),
|
|
@@ -4416,6 +4678,7 @@ function ColumnsConfigurationModal(props) {
|
|
|
4416
4678
|
columns,
|
|
4417
4679
|
defaultConfig,
|
|
4418
4680
|
getSearchFields: props.getSearchFields,
|
|
4681
|
+
columnGroups: props.columnGroups,
|
|
4419
4682
|
});
|
|
4420
4683
|
const apply = React.useCallback(() => modalProps.success(columnsConfig), [columnsConfig, modalProps]);
|
|
4421
4684
|
const close = React.useCallback(() => modalProps.abort(), [modalProps]);
|
|
@@ -4504,7 +4767,7 @@ const getChildrenAndRest = (row, rows) => {
|
|
|
4504
4767
|
return [children, rest];
|
|
4505
4768
|
};
|
|
4506
4769
|
|
|
4507
|
-
var css$o = {"listContainer":"
|
|
4770
|
+
var css$o = {"listContainer":"SP3tYM","header":"mnh-cy","group":"mlBqW2","stickyHeader":"_84AjX2"};
|
|
4508
4771
|
|
|
4509
4772
|
function DataRowsGroup({ row, childRows, renderRow, top = 1, }) {
|
|
4510
4773
|
const rowRef = React.useRef(undefined);
|
|
@@ -4544,7 +4807,7 @@ function DataRowsContainer({ estimatedHeight, listContainerRef, offsetY, rows, r
|
|
|
4544
4807
|
React__namespace.default.createElement(DataRowsGroups, { rows: rows, renderRow: renderRow, top: headerRef?.current?.clientHeight }))));
|
|
4545
4808
|
}
|
|
4546
4809
|
|
|
4547
|
-
var css$n = {"root":"
|
|
4810
|
+
var css$n = {"root":"BpqeXM","sticky-header":"MTHa5T","stickyHeader":"MTHa5T","no-results":"fJzFwb","noResults":"fJzFwb","icon":"_5d-97G","title":"lP2BFV"};
|
|
4548
4811
|
|
|
4549
4812
|
function DataTable(props) {
|
|
4550
4813
|
const { uuiModals } = uuiCore.useUuiContext();
|
|
@@ -4568,7 +4831,7 @@ function DataTable(props) {
|
|
|
4568
4831
|
.show((modalProps) => {
|
|
4569
4832
|
return (props.renderColumnsConfigurationModal
|
|
4570
4833
|
? props.renderColumnsConfigurationModal({ ...configProps, ...modalProps })
|
|
4571
|
-
: (React__namespace.createElement(ColumnsConfigurationModal, { ...modalProps, columns: props.columns, columnsConfig: config, defaultConfig: defaultConfig })));
|
|
4834
|
+
: (React__namespace.createElement(ColumnsConfigurationModal, { ...modalProps, columns: props.columns, columnGroups: props.columnGroups, columnsConfig: config, defaultConfig: defaultConfig })));
|
|
4572
4835
|
})
|
|
4573
4836
|
.then((columnsConfig) => props.onValueChange({ ...props.value, columnsConfig }))
|
|
4574
4837
|
.catch(() => null);
|
|
@@ -4577,11 +4840,8 @@ function DataTable(props) {
|
|
|
4577
4840
|
]);
|
|
4578
4841
|
const renderTableBody = React__namespace.useCallback((params) => (React__namespace.createElement(React__namespace.Fragment, null,
|
|
4579
4842
|
React__namespace.createElement("div", { className: uuiCore.cx(css$n.stickyHeader, 'uui-dt-sticky_header'), ref: headerRef },
|
|
4580
|
-
React__namespace.createElement(DataTableHeaderRow, { columns: columns, columnGroups: props.columnGroups, onConfigButtonClick: props.showColumnsConfig && onConfigurationButtonClick, selectAll: props.selectAll, size: props.headerSize || settings.dataTable.sizes.header.row, textCase: props.headerTextCase, allowColumnsReordering: props.allowColumnsReordering, allowColumnsResizing: props.allowColumnsResizing, showFoldAll: props.showFoldAll, value: { ...props.value, columnsConfig: config }, onValueChange: props.onValueChange, columnsGap: props.columnsGap }),
|
|
4581
|
-
|
|
4582
|
-
[uuiCore.uuiScrollShadows.topVisible]: params?.scrollShadows?.verticalTop,
|
|
4583
|
-
}) })),
|
|
4584
|
-
props.exactRowsCount !== 0 ? (React__namespace.createElement(DataRowsContainer, { headerRef: headerRef, listContainerRef: params?.listContainerRef, estimatedHeight: params?.estimatedHeight, offsetY: params?.offsetY, scrollShadows: params?.scrollShadows, renderRow: renderRow, rows: rows })) : (renderNoResultsBlock?.()))), [
|
|
4843
|
+
React__namespace.createElement(DataTableHeaderRow, { columns: columns, columnGroups: props.columnGroups, onConfigButtonClick: props.showColumnsConfig && onConfigurationButtonClick, selectAll: props.selectAll, size: props.headerSize || settings.dataTable.sizes.header.row, textCase: props.headerTextCase, allowColumnsReordering: props.allowColumnsReordering, allowColumnsResizing: props.allowColumnsResizing, showFoldAll: props.showFoldAll, value: { ...props.value, columnsConfig: config }, onValueChange: props.onValueChange, columnsGap: props.columnsGap, cx: uuiCore.uuiScrollShadows.top })),
|
|
4844
|
+
props.exactRowsCount !== 0 ? (React__namespace.createElement(DataRowsContainer, { headerRef: headerRef, listContainerRef: params?.listContainerRef, estimatedHeight: params?.estimatedHeight, offsetY: params?.offsetY, renderRow: renderRow, rows: rows })) : (renderNoResultsBlock?.()))), [
|
|
4585
4845
|
props, columns, rows, renderNoResultsBlock, onConfigurationButtonClick,
|
|
4586
4846
|
]);
|
|
4587
4847
|
const classes = uuiCore.cx(css$n.root, props.cx, 'uui-dt-vars', 'uui-data_table');
|
|
@@ -4596,7 +4856,7 @@ function DataTable(props) {
|
|
|
4596
4856
|
: (React__namespace.createElement(VirtualList, { value: props.value, onValueChange: props.onValueChange, onScroll: props.onScroll, rowsCount: props.rowsCount, renderRows: renderTableBody, cx: classes, isLoading: props.isReloading, rowsSelector: "[role=row]", rawProps: rawProps })))));
|
|
4597
4857
|
}
|
|
4598
4858
|
|
|
4599
|
-
var css$m = {"root":"
|
|
4859
|
+
var css$m = {"root":"Ahu0CP","title-wrapper":"_6ZWgQL","titleWrapper":"_6ZWgQL","title":"_4VrmKX","text-wrapper":"z8ZI0b","textWrapper":"z8ZI0b","selection":"aLbA9r","postfix":"i3vFJn","selected":"_3edSVh"};
|
|
4600
4860
|
|
|
4601
4861
|
const FilterPanelItemToggler = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
4602
4862
|
const togglerPickerOpened = (e) => {
|
|
@@ -4677,6 +4937,7 @@ function FilterPickerBody({ highlightSearchMatches = true, ...restProps }) {
|
|
|
4677
4937
|
selectionMode: props.selectionMode,
|
|
4678
4938
|
selection: props.value,
|
|
4679
4939
|
search: dataSourceState.search,
|
|
4940
|
+
disableClear: props.disableClear,
|
|
4680
4941
|
};
|
|
4681
4942
|
return props.renderFooter
|
|
4682
4943
|
? props.renderFooter(footerProps)
|
|
@@ -4820,7 +5081,7 @@ function FilterRangeDatePickerBody(props) {
|
|
|
4820
5081
|
renderFooter()));
|
|
4821
5082
|
}
|
|
4822
5083
|
|
|
4823
|
-
var css$l = {"container":"
|
|
5084
|
+
var css$l = {"container":"_-1Uhqp"};
|
|
4824
5085
|
|
|
4825
5086
|
function FilterNumericBody(props) {
|
|
4826
5087
|
const isInRangePredicate = props?.selectedPredicate === 'inRange' || props?.selectedPredicate === 'notInRange';
|
|
@@ -5131,14 +5392,24 @@ function FiltersToolbarImpl(props) {
|
|
|
5131
5392
|
}
|
|
5132
5393
|
const FiltersPanel = /* @__PURE__ */React__namespace.default.memo(FiltersToolbarImpl);
|
|
5133
5394
|
|
|
5134
|
-
var css$k = {"delete-button":"
|
|
5395
|
+
var css$k = {"delete-button":"TkUdma","deleteButton":"TkUdma","tab-button":"V1sZHz","tabButton":"V1sZHz","targetOpen":"_0-IIaY"};
|
|
5135
5396
|
|
|
5136
5397
|
function PresetActionsDropdown(props) {
|
|
5137
5398
|
const { uuiNotifications } = uuiCore.useUuiContext();
|
|
5399
|
+
const successNotificationHandler = React.useCallback((text) => {
|
|
5400
|
+
uuiNotifications
|
|
5401
|
+
.show((props) => (React__namespace.default.createElement(SuccessNotification, { ...props },
|
|
5402
|
+
React__namespace.default.createElement("div", { className: "uui-presets-panel-notification-text" }, text))), { duration: 3 })
|
|
5403
|
+
.catch(() => null);
|
|
5404
|
+
}, []);
|
|
5138
5405
|
const copyUrlToClipboard = React.useCallback(async () => {
|
|
5139
|
-
|
|
5406
|
+
const isPresetChanged = props.activePresetId === props.preset.id && props.hasPresetChanged(props.preset);
|
|
5407
|
+
const preset = isPresetChanged ? { ...props.preset, ...props.tableState } : props.preset;
|
|
5408
|
+
const link = props.getPresetLink(preset);
|
|
5409
|
+
await navigator.clipboard.writeText(link);
|
|
5140
5410
|
successNotificationHandler('Link copied!');
|
|
5141
|
-
}, []);
|
|
5411
|
+
}, [props.activePresetId, props.preset, props.hasPresetChanged, props.getPresetLink, props.tableState]);
|
|
5412
|
+
const onCopyLink = props.onCopyLink ? props.onCopyLink : copyUrlToClipboard;
|
|
5142
5413
|
const saveInCurrent = React.useCallback(async (preset) => {
|
|
5143
5414
|
const newPreset = {
|
|
5144
5415
|
...preset,
|
|
@@ -5153,12 +5424,6 @@ function PresetActionsDropdown(props) {
|
|
|
5153
5424
|
}, [
|
|
5154
5425
|
props.tableState.filter, props.tableState.columnsConfig, props.tableState.filtersConfig,
|
|
5155
5426
|
]);
|
|
5156
|
-
const successNotificationHandler = React.useCallback((text) => {
|
|
5157
|
-
uuiNotifications
|
|
5158
|
-
.show((props) => (React__namespace.default.createElement(SuccessNotification, { ...props },
|
|
5159
|
-
React__namespace.default.createElement("div", { className: "uui-presets-panel-notification-text" }, text))), { duration: 3 })
|
|
5160
|
-
.catch(() => null);
|
|
5161
|
-
}, []);
|
|
5162
5427
|
const saveInCurrentHandler = React.useCallback(() => {
|
|
5163
5428
|
saveInCurrent(props.preset);
|
|
5164
5429
|
}, [props.preset]);
|
|
@@ -5186,8 +5451,8 @@ function PresetActionsDropdown(props) {
|
|
|
5186
5451
|
React__namespace.default.createElement(DropdownMenuButton, { key: `${props.preset.id}-discard`, icon: settings.presetsPanel.icons.discardChangesIcon, caption: "Discard all changes", onClick: () => { dropdownProps.onClose(); discardAllChangesHandler(); } }),
|
|
5187
5452
|
React__namespace.default.createElement(DropdownMenuSplitter, { key: "discard-splitter" }))),
|
|
5188
5453
|
isRenameAvailable && (React__namespace.default.createElement(DropdownMenuButton, { key: `${props.preset.id}-rename`, icon: settings.presetsPanel.icons.renameIcon, caption: "Rename", onClick: props.renamePreset })),
|
|
5189
|
-
React__namespace.default.createElement(DropdownMenuButton, { key: `${props.preset.id}-duplicate`, icon: settings.presetsPanel.icons.copyIcon, caption: "Duplicate", onClick: () => { dropdownProps.onClose(); duplicateHandler(); } }),
|
|
5190
|
-
React__namespace.default.createElement(DropdownMenuButton, { key: `${props.preset.id}-copyLink`, icon: settings.presetsPanel.icons.copyLinkIcon, caption: "Copy Link", onClick:
|
|
5454
|
+
!isPresetChanged && (React__namespace.default.createElement(DropdownMenuButton, { key: `${props.preset.id}-duplicate`, icon: settings.presetsPanel.icons.copyIcon, caption: "Duplicate", onClick: () => { dropdownProps.onClose(); duplicateHandler(); } })),
|
|
5455
|
+
props.onCopyLink !== null && (React__namespace.default.createElement(DropdownMenuButton, { key: `${props.preset.id}-copyLink`, icon: settings.presetsPanel.icons.copyLinkIcon, caption: "Copy Link", onClick: onCopyLink })),
|
|
5191
5456
|
!isReadonlyPreset && (React__namespace.default.createElement(React__namespace.default.Fragment, null,
|
|
5192
5457
|
React__namespace.default.createElement(DropdownMenuSplitter, { key: "delete-splitter" }),
|
|
5193
5458
|
React__namespace.default.createElement(DropdownMenuButton, { icon: settings.presetsPanel.icons.deleteIcon, caption: "Delete", cx: css$k.deleteButton, onClick: deleteHandler })))));
|
|
@@ -5203,7 +5468,7 @@ const UUI_PRESETS_PANEL_MORE_BUTTON = 'uui-presets-panel-more-button';
|
|
|
5203
5468
|
const UUI_PRESETS_PANEL_INPUT = 'uui-presets-panel-input';
|
|
5204
5469
|
const UUI_PRESETS_PANEL_PRESET = 'uui-presets-panel-preset';
|
|
5205
5470
|
|
|
5206
|
-
var css$j = {"preset-input-cell":"
|
|
5471
|
+
var css$j = {"preset-input-cell":"xCehzP","presetInputCell":"xCehzP","preset-input":"tt5F9a","presetInput":"tt5F9a"};
|
|
5207
5472
|
|
|
5208
5473
|
function PresetInput(props) {
|
|
5209
5474
|
const [presetCaption, setPresetCaption] = React.useState(props.preset?.name || '');
|
|
@@ -5230,7 +5495,7 @@ function PresetInput(props) {
|
|
|
5230
5495
|
React__namespace.default.createElement(TextInput, { cx: css$j.presetInput, onValueChange: setPresetCaption, value: presetCaption, onCancel: cancelActionHandler, onAccept: acceptActionHandler, onBlur: newPresetOnBlurHandler, autoFocus: true, maxLength: 50, isReadonly: readonly })));
|
|
5231
5496
|
}
|
|
5232
5497
|
|
|
5233
|
-
var css$i = {"preset":"
|
|
5498
|
+
var css$i = {"preset":"J1q077","activePreset":"C7QNjX"};
|
|
5234
5499
|
|
|
5235
5500
|
function Preset(props) {
|
|
5236
5501
|
const [isRenamePreset, setIsRenamePreset] = React.useState(false);
|
|
@@ -5252,10 +5517,10 @@ function Preset(props) {
|
|
|
5252
5517
|
}, [props.preset]);
|
|
5253
5518
|
const isPresetActive = props.activePresetId === props.preset.id;
|
|
5254
5519
|
const PresetActionsDropdownComponent = React.useCallback(() => React__namespace.default.createElement(PresetActionsDropdown, { renamePreset: setPresetForRename, ...props }), [props.preset, props.tableState, props.activePresetId]);
|
|
5255
|
-
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$i.preset, isPresetActive && css$i.activePreset, UUI_PRESETS_PANEL_PRESET], size: settings.presetsPanel.sizes.tabButton, withNotify: isPresetActive && props.hasPresetChanged(props.preset), icon: PresetActionsDropdownComponent, iconPosition: "right",
|
|
5520
|
+
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$i.preset, isPresetActive && css$i.activePreset, UUI_PRESETS_PANEL_PRESET], size: settings.presetsPanel.sizes.tabButton, withNotify: isPresetActive && props.hasPresetChanged(props.preset), icon: PresetActionsDropdownComponent, iconPosition: "right", isActive: isPresetActive }))));
|
|
5256
5521
|
}
|
|
5257
5522
|
|
|
5258
|
-
var css$h = {"divider":"
|
|
5523
|
+
var css$h = {"divider":"vekOdI","dropdownDeleteIcon":"i7naC6","presetsWrapper":"lkHUKJ","addPresetContainer":"_485nR3","dropContainer":"qIMA-g"};
|
|
5259
5524
|
|
|
5260
5525
|
function PresetsPanel(props) {
|
|
5261
5526
|
const [isAddingPreset, setIsAddingPreset] = React.useState(false);
|
|
@@ -5304,9 +5569,9 @@ function PresetsPanel(props) {
|
|
|
5304
5569
|
React__namespace.default.createElement(uuiComponents.AdaptivePanel, { items: getPanelItems() }))));
|
|
5305
5570
|
}
|
|
5306
5571
|
|
|
5307
|
-
var css$g = {"root":"
|
|
5572
|
+
var css$g = {"root":"_5KnibK"};
|
|
5308
5573
|
|
|
5309
|
-
var css$f = {"root":"
|
|
5574
|
+
var css$f = {"root":"m1kbC6","burger-content":"S1Y8ec","burgerContent":"S1Y8ec"};
|
|
5310
5575
|
|
|
5311
5576
|
var _path$3;
|
|
5312
5577
|
function _extends$3() { return _extends$3 = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends$3.apply(null, arguments); }
|
|
@@ -5349,24 +5614,38 @@ var SvgNavigationArrowDownOutline = function SvgNavigationArrowDownOutline(props
|
|
|
5349
5614
|
};
|
|
5350
5615
|
var ForwardRef$2 = /*#__PURE__*/React.forwardRef(SvgNavigationArrowDownOutline);
|
|
5351
5616
|
|
|
5352
|
-
var css$e = {"root":"
|
|
5617
|
+
var css$e = {"root":"dtUWWh","button-primary":"-Mis7-","buttonPrimary":"-Mis7-","button-secondary":"ylTyFw","buttonSecondary":"ylTyFw","hasIcon":"LOevly","dropdown":"_9xeNwU"};
|
|
5353
5618
|
|
|
5354
|
-
|
|
5355
|
-
|
|
5356
|
-
|
|
5357
|
-
|
|
5358
|
-
|
|
5359
|
-
|
|
5360
|
-
|
|
5361
|
-
|
|
5619
|
+
function applyBurgerButtonMods(props) {
|
|
5620
|
+
return [
|
|
5621
|
+
css$e.root,
|
|
5622
|
+
'uui-main_menu-burger-button',
|
|
5623
|
+
css$e['button-' + (props.type || 'primary')],
|
|
5624
|
+
css$e['indent-' + (props.indentLevel || 0)],
|
|
5625
|
+
props.isActive && uuiCore.uuiMod.active,
|
|
5626
|
+
props.isDropdown && css$e.dropdown,
|
|
5627
|
+
props.icon && css$e.hasIcon,
|
|
5628
|
+
];
|
|
5629
|
+
}
|
|
5630
|
+
const BurgerButton = /* @__PURE__ */React__namespace.default.forwardRef((props, ref) => {
|
|
5631
|
+
const { isActive } = uuiCore.useIsActive({
|
|
5632
|
+
isLinkActive: props.isLinkActive,
|
|
5633
|
+
link: props.link,
|
|
5634
|
+
isActive: props.isActive,
|
|
5635
|
+
});
|
|
5636
|
+
return (React__namespace.default.createElement(uuiComponents.Button, { ...props, ref: ref, cx: applyBurgerButtonMods({ ...props, isActive }), rawProps: {
|
|
5637
|
+
...props.rawProps,
|
|
5638
|
+
role: 'menuitem',
|
|
5639
|
+
}, dropdownIcon: ForwardRef$2 }));
|
|
5640
|
+
});
|
|
5362
5641
|
|
|
5363
|
-
var css$d = {"search-input":"
|
|
5642
|
+
var css$d = {"search-input":"vYVtSz","searchInput":"vYVtSz"};
|
|
5364
5643
|
|
|
5365
5644
|
function BurgerSearch(props) {
|
|
5366
5645
|
return (React__namespace.createElement(uuiComponents.TextInput, { cx: cx__default.default(css$d.searchInput, 'uui-main_menu-burger-search'), iconPosition: "left", icon: ForwardRef$M, placeholder: props.placeholder, value: props.value, onValueChange: props.onValueChange, onCancel: props.onCancel, cancelIcon: props.value && ForwardRef$Q }));
|
|
5367
5646
|
}
|
|
5368
5647
|
|
|
5369
|
-
var css$c = {"root":"
|
|
5648
|
+
var css$c = {"root":"KuPp6c","group-header":"uJKceF","groupHeader":"uJKceF","group-name":"jgiWdd","groupName":"jgiWdd","line":"vu919g"};
|
|
5370
5649
|
|
|
5371
5650
|
function BurgerGroupHeader(props) {
|
|
5372
5651
|
return (React__namespace.createElement("div", { className: cx__default.default(css$c.root, css$c.groupHeader, 'uui-burger-group-header') },
|
|
@@ -5374,19 +5653,25 @@ function BurgerGroupHeader(props) {
|
|
|
5374
5653
|
React__namespace.createElement("span", { className: css$c.groupName }, props.caption)));
|
|
5375
5654
|
}
|
|
5376
5655
|
|
|
5377
|
-
var css$b = {"root":"
|
|
5656
|
+
var css$b = {"root":"PLtwlE","type-primary":"xVnypL","typePrimary":"xVnypL","type-secondary":"-YJtZ8","typeSecondary":"-YJtZ8"};
|
|
5378
5657
|
|
|
5379
5658
|
const MainMenuButton = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
5380
5659
|
const { type, ...clickableProps } = props;
|
|
5660
|
+
const { isActive } = uuiCore.useIsActive({
|
|
5661
|
+
isLinkActive: props.isLinkActive,
|
|
5662
|
+
link: props.link,
|
|
5663
|
+
isActive: props.isActive,
|
|
5664
|
+
});
|
|
5381
5665
|
return (React__namespace.createElement(uuiComponents.Clickable, { ...clickableProps, rawProps: {
|
|
5382
5666
|
'aria-expanded': props.isOpen,
|
|
5383
|
-
'aria-current':
|
|
5667
|
+
'aria-current': isActive
|
|
5384
5668
|
? 'page'
|
|
5385
5669
|
: undefined,
|
|
5386
5670
|
...props.rawProps,
|
|
5387
5671
|
}, cx: [
|
|
5388
5672
|
css$b.root,
|
|
5389
5673
|
css$b['type-' + (type || 'primary')],
|
|
5674
|
+
isActive && uuiCore.uuiMod.active,
|
|
5390
5675
|
props.cx,
|
|
5391
5676
|
], ref: ref },
|
|
5392
5677
|
props.icon && props.iconPosition !== 'right' && (React__namespace.createElement(uuiComponents.IconContainer, { icon: props.icon, onClick: props.onIconClick })),
|
|
@@ -5396,34 +5681,18 @@ const MainMenuButton = /* @__PURE__ */React__namespace.forwardRef((props, ref) =
|
|
|
5396
5681
|
props.isDropdown && (React__namespace.createElement(uuiComponents.IconContainer, { icon: ForwardRef$P, flipY: props.isOpen }))));
|
|
5397
5682
|
});
|
|
5398
5683
|
|
|
5399
|
-
var css$a = {"dropdown-body":"
|
|
5684
|
+
var css$a = {"dropdown-body":"pI0ItD","dropdownBody":"pI0ItD"};
|
|
5400
5685
|
|
|
5401
|
-
|
|
5402
|
-
|
|
5403
|
-
|
|
5404
|
-
|
|
5405
|
-
|
|
5406
|
-
|
|
5407
|
-
|
|
5408
|
-
|
|
5409
|
-
|
|
5410
|
-
|
|
5411
|
-
? this.props.renderBody({ ...props })
|
|
5412
|
-
: React__namespace.Children.map(this.props.children, (item) => {
|
|
5413
|
-
if (!item)
|
|
5414
|
-
return item;
|
|
5415
|
-
return React__namespace.createElement(item.type, {
|
|
5416
|
-
...item.props,
|
|
5417
|
-
onClick: item.props.onClick
|
|
5418
|
-
? () => {
|
|
5419
|
-
item.props.onClick();
|
|
5420
|
-
props.onClose();
|
|
5421
|
-
}
|
|
5422
|
-
: null,
|
|
5423
|
-
});
|
|
5424
|
-
}))));
|
|
5425
|
-
}, placement: "bottom-start" }));
|
|
5426
|
-
}
|
|
5686
|
+
function MainMenuDropdown(props) {
|
|
5687
|
+
const handleEscape = (e, onClose, isOpen) => {
|
|
5688
|
+
if (e.key === 'Escape' && isOpen) {
|
|
5689
|
+
onClose();
|
|
5690
|
+
}
|
|
5691
|
+
};
|
|
5692
|
+
return (React__namespace.default.createElement(uuiComponents.Dropdown, { renderTarget: (dropdownProps) => (React__namespace.default.createElement(MainMenuButton, { caption: props.caption, ...dropdownProps, rawProps: props.rawProps, isActive: props.isActive, isDropdown: true })), renderBody: (dropdownBodyProps) => (React__namespace.default.createElement(FocusLock__default.default, { returnFocus: true, persistentFocus: true, lockProps: {
|
|
5693
|
+
onKeyDown: (e) => handleEscape(e, dropdownBodyProps.onClose, dropdownBodyProps.isOpen),
|
|
5694
|
+
} },
|
|
5695
|
+
React__namespace.default.createElement("div", { className: cx__default.default(css$a.dropdownBody, 'uui-main_menu-dropdown', props.cx) }, props.renderBody({ ...dropdownBodyProps })))), placement: "bottom-start" }));
|
|
5427
5696
|
}
|
|
5428
5697
|
|
|
5429
5698
|
function applyMainMenuMods() {
|
|
@@ -5455,12 +5724,12 @@ var SvgNavigationGlobalMenuOutlineOutline = function SvgNavigationGlobalMenuOutl
|
|
|
5455
5724
|
};
|
|
5456
5725
|
var ForwardRef$1 = /*#__PURE__*/React.forwardRef(SvgNavigationGlobalMenuOutlineOutline);
|
|
5457
5726
|
|
|
5458
|
-
var css$9 = {"global-menu-btn":"
|
|
5727
|
+
var css$9 = {"global-menu-btn":"Rcf6o8","globalMenuBtn":"Rcf6o8","global-menu-icon":"-KObp5","globalMenuIcon":"-KObp5"};
|
|
5459
5728
|
|
|
5460
5729
|
const GlobalMenu = /* @__PURE__ */React__namespace.forwardRef((props, ref) => (React__namespace.createElement("button", { ref: ref, id: "global_menu_toggle", className: cx__default.default(css$9.globalMenuBtn, props.cx), ...props.rawProps },
|
|
5461
5730
|
React__namespace.createElement(uuiComponents.IconContainer, { size: 36, icon: ForwardRef$1, cx: css$9.globalMenuIcon }))));
|
|
5462
5731
|
|
|
5463
|
-
var css$8 = {"container":"
|
|
5732
|
+
var css$8 = {"container":"w9ZVai","open":"u8-Udc","folding-arrow":"_7iFuL1","foldingArrow":"_7iFuL1"};
|
|
5464
5733
|
|
|
5465
5734
|
const MainMenuAvatar = /* @__PURE__ */React__namespace.forwardRef((props, ref) => (React__namespace.createElement("button", { ref: ref, className: cx__default.default(css$8.container, props.isDropdown && css$8.dropdown, props.isOpen && css$8.open, props.onClick && uuiCore.uuiMarkers.clickable, props.cx), onClick: props.onClick, ...props.rawProps },
|
|
5466
5735
|
React__namespace.createElement(uuiComponents.Avatar, { size: "36", img: props.avatarUrl }),
|
|
@@ -5468,15 +5737,15 @@ const MainMenuAvatar = /* @__PURE__ */React__namespace.forwardRef((props, ref) =
|
|
|
5468
5737
|
props.isDropdown && (React__namespace.createElement("div", null,
|
|
5469
5738
|
React__namespace.createElement(uuiComponents.IconContainer, { size: 18, icon: ForwardRef$P, flipY: props.isOpen, cx: css$8.foldingArrow }))))));
|
|
5470
5739
|
|
|
5471
|
-
var css$7 = {"search-input":"
|
|
5740
|
+
var css$7 = {"search-input":"_2vTcli","searchInput":"_2vTcli"};
|
|
5472
5741
|
|
|
5473
5742
|
const MainMenuSearch = /* @__PURE__ */React__namespace.forwardRef((props, ref) => (React__namespace.createElement(uuiCore.IEditableDebouncer, { ...props, render: (iEditable) => (React__namespace.createElement(uuiComponents.TextInput, { iconPosition: "left", icon: ForwardRef$M, cancelIcon: props.value?.length > 0 && ForwardRef$Q, ...props, ...iEditable, ref: ref, cx: uuiCore.cx(css$7.searchInput, props.cx), ...props.rawProps })) })));
|
|
5474
5743
|
|
|
5475
|
-
var css$6 = {"container":"
|
|
5744
|
+
var css$6 = {"container":"wsFTHn"};
|
|
5476
5745
|
|
|
5477
5746
|
const MainMenuIcon = /* @__PURE__ */React__namespace.forwardRef((props, ref) => (React__namespace.createElement(IconButton, { ref: ref, icon: props.icon, cx: uuiCore.cx(props.cx, css$6.container), ...props })));
|
|
5478
5747
|
|
|
5479
|
-
var css$5 = {"root":"
|
|
5748
|
+
var css$5 = {"root":"pn9hTw"};
|
|
5480
5749
|
|
|
5481
5750
|
const Anchor = /* @__PURE__ */uuiCore.withMods(uuiComponents.Anchor, () => [css$5.root]);
|
|
5482
5751
|
|
|
@@ -5534,7 +5803,7 @@ var SvgFileCloudUploadFill = function SvgFileCloudUploadFill(props, ref) {
|
|
|
5534
5803
|
};
|
|
5535
5804
|
var ForwardRef = /*#__PURE__*/React.forwardRef(SvgFileCloudUploadFill);
|
|
5536
5805
|
|
|
5537
|
-
var css$4 = {"root":"
|
|
5806
|
+
var css$4 = {"root":"_9KpK9K","drop-start":"c4tGeC","dropStart":"c4tGeC","drop-over":"xQ6lFt","dropOver":"xQ6lFt","link":"vMDLUG","drop-area":"YOmTpi","dropArea":"YOmTpi","drop-caption":"tGfwB3","dropCaption":"tGfwB3","icon-blue":"zD4Egz","iconBlue":"zD4Egz"};
|
|
5538
5807
|
|
|
5539
5808
|
function DropSpot(props) {
|
|
5540
5809
|
const getInfoText = typeof props.infoText === 'string'
|
|
@@ -5552,7 +5821,7 @@ function DropSpot(props) {
|
|
|
5552
5821
|
return React__namespace.createElement(uuiComponents.DropSpot, { render: renderAttachmentArea, onFilesDropped: props.onUploadFiles });
|
|
5553
5822
|
}
|
|
5554
5823
|
|
|
5555
|
-
var css$3 = {"root":"
|
|
5824
|
+
var css$3 = {"root":"huTrTa"};
|
|
5556
5825
|
|
|
5557
5826
|
const SvgCircleProgress = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
5558
5827
|
const outsetRadius = props.size / 2 - 1;
|
|
@@ -5563,7 +5832,7 @@ const SvgCircleProgress = /* @__PURE__ */React__namespace.forwardRef((props, ref
|
|
|
5563
5832
|
React__namespace.createElement("circle", { strokeWidth: 1, fill: "transparent", r: outsetRadius, cx: props.size / 2, cy: props.size / 2 })));
|
|
5564
5833
|
});
|
|
5565
5834
|
|
|
5566
|
-
var css$2 = {"root":"
|
|
5835
|
+
var css$2 = {"root":"pafLq4","file-name":"_80Ljt2","fileName":"_80Ljt2","default-color":"zJLWmG","defaultColor":"zJLWmG","doc-color":"-XBxir","docColor":"-XBxir","xls-color":"F2M9WF","xlsColor":"F2M9WF","pdf-color":"h64wle","pdfColor":"h64wle","movie-color":"PWzEHg","movieColor":"PWzEHg","img-color":"_8oFOIz","imgColor":"_8oFOIz","mov-color":"Kg0e4J","movColor":"Kg0e4J","error-block":"IKpfhS","errorBlock":"IKpfhS","icons-block":"_6oidLn","iconsBlock":"_6oidLn"};
|
|
5567
5836
|
|
|
5568
5837
|
const FileCard = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
5569
5838
|
const [isLoadingShow, setIsLoadingShow] = React__namespace.useState(true);
|
|
@@ -5618,7 +5887,7 @@ const FileCard = /* @__PURE__ */React__namespace.forwardRef((props, ref) => {
|
|
|
5618
5887
|
setIsLoadingShow(() => false);
|
|
5619
5888
|
};
|
|
5620
5889
|
const renderErrorContent = () => (React__namespace.createElement(Tooltip, { content: file.error.message, placement: "bottom-start" },
|
|
5621
|
-
React__namespace.createElement("div", { className: css$2.errorBlock },
|
|
5890
|
+
React__namespace.createElement("div", { className: css$2.errorBlock, "aria-description": file.error.message, "aria-label": "File Upload Error" },
|
|
5622
5891
|
React__namespace.createElement(uuiComponents.IconContainer, { icon: settings.fileCard.icons.errorIcon, size: 12 }),
|
|
5623
5892
|
i18n.fileCard.failedUploadErrorMessage)));
|
|
5624
5893
|
const renderSuccessfulContent = () => (React__namespace.createElement(Text, { size: "none", fontSize: "14", lineHeight: "18", color: "tertiary" },
|
|
@@ -5682,7 +5951,7 @@ const getErrorPageConfig = () => ({
|
|
|
5682
5951
|
},
|
|
5683
5952
|
});
|
|
5684
5953
|
|
|
5685
|
-
var css$1 = {"container":"
|
|
5954
|
+
var css$1 = {"container":"R-B39Y"};
|
|
5686
5955
|
|
|
5687
5956
|
const ErrorPage = (props) => {
|
|
5688
5957
|
const isMobileScreen = uuiCore.isMobile();
|
|
@@ -5694,7 +5963,7 @@ const ErrorPage = (props) => {
|
|
|
5694
5963
|
props?.supportLink && React__namespace.default.createElement("div", { className: "uui-error-support-link" }, props?.supportLink))));
|
|
5695
5964
|
};
|
|
5696
5965
|
|
|
5697
|
-
var css = {"recovery-spinner":"
|
|
5966
|
+
var css = {"recovery-spinner":"_4uFmj3","recoverySpinner":"_4uFmj3","recovery-message":"QQYg-5","recoveryMessage":"QQYg-5","modal-blocker":"_8uCqcK","modalBlocker":"_8uCqcK","modalFadeIn":"nSSJ-5"};
|
|
5698
5967
|
|
|
5699
5968
|
function ErrorHandler(props) {
|
|
5700
5969
|
const { uuiNotifications, uuiModals, uuiApi } = uuiCore.useUuiContext();
|
|
@@ -5761,6 +6030,14 @@ Object.defineProperty(exports, "IconContainer", {
|
|
|
5761
6030
|
enumerable: true,
|
|
5762
6031
|
get: function () { return uuiComponents.IconContainer; }
|
|
5763
6032
|
});
|
|
6033
|
+
Object.defineProperty(exports, "MainMenuCustomElement", {
|
|
6034
|
+
enumerable: true,
|
|
6035
|
+
get: function () { return uuiComponents.MainMenuCustomElement; }
|
|
6036
|
+
});
|
|
6037
|
+
Object.defineProperty(exports, "MainMenuLogo", {
|
|
6038
|
+
enumerable: true,
|
|
6039
|
+
get: function () { return uuiComponents.MainMenuLogo; }
|
|
6040
|
+
});
|
|
5764
6041
|
exports.Accordion = Accordion;
|
|
5765
6042
|
exports.Alert = Alert;
|
|
5766
6043
|
exports.Anchor = Anchor;
|
|
@@ -5870,6 +6147,7 @@ exports.SuccessNotification = SuccessNotification;
|
|
|
5870
6147
|
exports.SvgCircleProgress = SvgCircleProgress;
|
|
5871
6148
|
exports.Switch = Switch;
|
|
5872
6149
|
exports.TabButton = TabButton;
|
|
6150
|
+
exports.Tabs = Tabs;
|
|
5873
6151
|
exports.Tag = Tag;
|
|
5874
6152
|
exports.Text = Text;
|
|
5875
6153
|
exports.TextArea = TextArea;
|
|
@@ -5879,6 +6157,7 @@ exports.TimePicker = TimePicker;
|
|
|
5879
6157
|
exports.TimePickerBody = TimePickerBody;
|
|
5880
6158
|
exports.TimePickerComponent = TimePickerComponent;
|
|
5881
6159
|
exports.Tooltip = Tooltip;
|
|
6160
|
+
exports.Tree = Tree;
|
|
5882
6161
|
exports.VerticalTabButton = VerticalTabButton;
|
|
5883
6162
|
exports.VirtualList = VirtualList;
|
|
5884
6163
|
exports.WarningAlert = WarningAlert;
|