@mmb-digital/ds-lilly 0.0.1-alpha.371 → 0.0.1-alpha.372
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/dist/ds-lilly.css +1 -1
- package/dist/ds-lilly.js +396 -352
- package/dist/types/src/components/Components/Button/Button.d.ts +2 -2
- package/dist/types/src/components/Components/Card/Card.d.ts +5 -3
- package/dist/types/src/components/Components/CompactButtons/CompactButtons.d.ts +2 -2
- package/dist/types/src/components/Components/Link/Link.d.ts +2 -2
- package/dist/types/src/components/Components/Pills/Pills.d.ts +2 -2
- package/dist/types/src/components/Components/Tooltip/Tooltip.d.ts +4 -1
- package/dist/types/src/components/Form/Autocomplete/Autocomplete.d.ts +1 -1
- package/dist/types/src/components/Form/Checkbox2/Checkbox2.d.ts +1 -1
- package/dist/types/src/components/Form/DatePicker/DatePicker.d.ts +1 -1
- package/dist/types/src/components/Form/FormField/FormField.d.ts +2 -2
- package/dist/types/src/components/Form/FormGroup/FormGroup.d.ts +1 -3
- package/dist/types/src/components/Form/FormGroup2/FormGroup2.d.ts +3 -3
- package/dist/types/src/components/Form/Input2/Input2.d.ts +1 -1
- package/dist/types/src/components/Form/MonthInput/MonthInput.d.ts +1 -1
- package/dist/types/src/components/Form/Radio2/Radio2.d.ts +1 -1
- package/dist/types/src/components/Form/Select2/Select2.d.ts +1 -1
- package/dist/types/src/components/Form/Slider/Slider.d.ts +2 -2
- package/dist/types/src/components/Form/Textarea2/Textarea2.d.ts +1 -1
- package/dist/types/src/components/Form/Toggle/Toggle.d.ts +3 -3
- package/dist/types/src/components/Navigation/Menu/_elements_/MenuItem.d.ts +5 -3
- package/dist/types/src/components/Navigation/Tabs/_elements_/TabListItem.d.ts +2 -1
- package/dist/types/src/hocs/index.d.ts +2 -0
- package/dist/types/src/hocs/withDisabledTooltip.d.ts +4 -0
- package/dist/types/src/index.d.ts +1 -0
- package/dist/types/src/types/common.d.ts +2 -2
- package/dist/types/src/utils/classBinder.d.ts +5 -0
- package/package.json +1 -1
package/dist/ds-lilly.js
CHANGED
|
@@ -11116,9 +11116,9 @@ var inRangeOfSector = function inRangeOfSector(_ref5, sector) {
|
|
|
11116
11116
|
* MIT License
|
|
11117
11117
|
*/
|
|
11118
11118
|
|
|
11119
|
-
var fingerprint = __webpack_require__(
|
|
11119
|
+
var fingerprint = __webpack_require__(901);
|
|
11120
11120
|
var pad = __webpack_require__(800);
|
|
11121
|
-
var getRandomValue = __webpack_require__(
|
|
11121
|
+
var getRandomValue = __webpack_require__(902);
|
|
11122
11122
|
|
|
11123
11123
|
var c = 0,
|
|
11124
11124
|
blockSize = 4,
|
|
@@ -64273,6 +64273,48 @@ webpackContext.id = 900;
|
|
|
64273
64273
|
/* 901 */
|
|
64274
64274
|
/***/ (function(module, exports, __webpack_require__) {
|
|
64275
64275
|
|
|
64276
|
+
var pad = __webpack_require__(800);
|
|
64277
|
+
|
|
64278
|
+
var env = typeof window === 'object' ? window : self;
|
|
64279
|
+
var globalCount = Object.keys(env).length;
|
|
64280
|
+
var mimeTypesLength = navigator.mimeTypes ? navigator.mimeTypes.length : 0;
|
|
64281
|
+
var clientId = pad((mimeTypesLength +
|
|
64282
|
+
navigator.userAgent.length).toString(36) +
|
|
64283
|
+
globalCount.toString(36), 4);
|
|
64284
|
+
|
|
64285
|
+
module.exports = function fingerprint () {
|
|
64286
|
+
return clientId;
|
|
64287
|
+
};
|
|
64288
|
+
|
|
64289
|
+
|
|
64290
|
+
/***/ }),
|
|
64291
|
+
/* 902 */
|
|
64292
|
+
/***/ (function(module, exports) {
|
|
64293
|
+
|
|
64294
|
+
|
|
64295
|
+
var getRandomValue;
|
|
64296
|
+
|
|
64297
|
+
var crypto = typeof window !== 'undefined' &&
|
|
64298
|
+
(window.crypto || window.msCrypto) ||
|
|
64299
|
+
typeof self !== 'undefined' &&
|
|
64300
|
+
self.crypto;
|
|
64301
|
+
|
|
64302
|
+
if (crypto) {
|
|
64303
|
+
var lim = Math.pow(2, 32) - 1;
|
|
64304
|
+
getRandomValue = function () {
|
|
64305
|
+
return Math.abs(crypto.getRandomValues(new Uint32Array(1))[0] / lim);
|
|
64306
|
+
};
|
|
64307
|
+
} else {
|
|
64308
|
+
getRandomValue = Math.random;
|
|
64309
|
+
}
|
|
64310
|
+
|
|
64311
|
+
module.exports = getRandomValue;
|
|
64312
|
+
|
|
64313
|
+
|
|
64314
|
+
/***/ }),
|
|
64315
|
+
/* 903 */
|
|
64316
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
64317
|
+
|
|
64276
64318
|
var map = {
|
|
64277
64319
|
"./": [
|
|
64278
64320
|
653,
|
|
@@ -68990,51 +69032,9 @@ function webpackAsyncContext(req) {
|
|
|
68990
69032
|
webpackAsyncContext.keys = function webpackAsyncContextKeys() {
|
|
68991
69033
|
return Object.keys(map);
|
|
68992
69034
|
};
|
|
68993
|
-
webpackAsyncContext.id =
|
|
69035
|
+
webpackAsyncContext.id = 903;
|
|
68994
69036
|
module.exports = webpackAsyncContext;
|
|
68995
69037
|
|
|
68996
|
-
/***/ }),
|
|
68997
|
-
/* 902 */
|
|
68998
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
68999
|
-
|
|
69000
|
-
var pad = __webpack_require__(800);
|
|
69001
|
-
|
|
69002
|
-
var env = typeof window === 'object' ? window : self;
|
|
69003
|
-
var globalCount = Object.keys(env).length;
|
|
69004
|
-
var mimeTypesLength = navigator.mimeTypes ? navigator.mimeTypes.length : 0;
|
|
69005
|
-
var clientId = pad((mimeTypesLength +
|
|
69006
|
-
navigator.userAgent.length).toString(36) +
|
|
69007
|
-
globalCount.toString(36), 4);
|
|
69008
|
-
|
|
69009
|
-
module.exports = function fingerprint () {
|
|
69010
|
-
return clientId;
|
|
69011
|
-
};
|
|
69012
|
-
|
|
69013
|
-
|
|
69014
|
-
/***/ }),
|
|
69015
|
-
/* 903 */
|
|
69016
|
-
/***/ (function(module, exports) {
|
|
69017
|
-
|
|
69018
|
-
|
|
69019
|
-
var getRandomValue;
|
|
69020
|
-
|
|
69021
|
-
var crypto = typeof window !== 'undefined' &&
|
|
69022
|
-
(window.crypto || window.msCrypto) ||
|
|
69023
|
-
typeof self !== 'undefined' &&
|
|
69024
|
-
self.crypto;
|
|
69025
|
-
|
|
69026
|
-
if (crypto) {
|
|
69027
|
-
var lim = Math.pow(2, 32) - 1;
|
|
69028
|
-
getRandomValue = function () {
|
|
69029
|
-
return Math.abs(crypto.getRandomValues(new Uint32Array(1))[0] / lim);
|
|
69030
|
-
};
|
|
69031
|
-
} else {
|
|
69032
|
-
getRandomValue = Math.random;
|
|
69033
|
-
}
|
|
69034
|
-
|
|
69035
|
-
module.exports = getRandomValue;
|
|
69036
|
-
|
|
69037
|
-
|
|
69038
69038
|
/***/ }),
|
|
69039
69039
|
/* 904 */
|
|
69040
69040
|
/***/ (function(module, exports, __webpack_require__) {
|
|
@@ -80153,6 +80153,7 @@ __webpack_require__.d(__webpack_exports__, "FormGroupContext", function() { retu
|
|
|
80153
80153
|
__webpack_require__.d(__webpack_exports__, "ModalContext", function() { return /* reexport */ contexts_ModalContext; });
|
|
80154
80154
|
__webpack_require__.d(__webpack_exports__, "Select2Context", function() { return /* reexport */ contexts_Select2Context; });
|
|
80155
80155
|
__webpack_require__.d(__webpack_exports__, "TabsContext", function() { return /* reexport */ contexts_TabsContext; });
|
|
80156
|
+
__webpack_require__.d(__webpack_exports__, "withDisabledTooltip", function() { return /* reexport */ hocs_withDisabledTooltip; });
|
|
80156
80157
|
__webpack_require__.d(__webpack_exports__, "Alert", function() { return /* reexport */ Alert; });
|
|
80157
80158
|
__webpack_require__.d(__webpack_exports__, "Avatar", function() { return /* reexport */ Avatar; });
|
|
80158
80159
|
__webpack_require__.d(__webpack_exports__, "Badge", function() { return /* reexport */ Badge; });
|
|
@@ -84294,248 +84295,6 @@ TabsContext.displayName = 'TabsContext';
|
|
|
84294
84295
|
|
|
84295
84296
|
|
|
84296
84297
|
|
|
84297
|
-
// EXTERNAL MODULE: ./node_modules/camelcase/index.js
|
|
84298
|
-
var camelcase = __webpack_require__(54);
|
|
84299
|
-
var camelcase_default = /*#__PURE__*/__webpack_require__.n(camelcase);
|
|
84300
|
-
|
|
84301
|
-
// CONCATENATED MODULE: ./src/components/Components/Icon/Icon.tsx
|
|
84302
|
-
var Icon_assign = (undefined && undefined.__assign) || function () {
|
|
84303
|
-
Icon_assign = Object.assign || function(t) {
|
|
84304
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
84305
|
-
s = arguments[i];
|
|
84306
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
84307
|
-
t[p] = s[p];
|
|
84308
|
-
}
|
|
84309
|
-
return t;
|
|
84310
|
-
};
|
|
84311
|
-
return Icon_assign.apply(this, arguments);
|
|
84312
|
-
};
|
|
84313
|
-
var __rest = (undefined && undefined.__rest) || function (s, e) {
|
|
84314
|
-
var t = {};
|
|
84315
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
84316
|
-
t[p] = s[p];
|
|
84317
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
84318
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
84319
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
84320
|
-
t[p[i]] = s[p[i]];
|
|
84321
|
-
}
|
|
84322
|
-
return t;
|
|
84323
|
-
};
|
|
84324
|
-
|
|
84325
|
-
|
|
84326
|
-
|
|
84327
|
-
var usedIconComponents = {};
|
|
84328
|
-
var Icon = function (_a) {
|
|
84329
|
-
var _b;
|
|
84330
|
-
var backgroundColor = _a.backgroundColor, color = _a.color, isLeft = _a.isLeft, isRight = _a.isRight, name = _a.name, size = _a.size, testId = _a.testId, theme = _a.theme, rest = __rest(_a, ["backgroundColor", "color", "isLeft", "isRight", "name", "size", "testId", "theme"]);
|
|
84331
|
-
var componentClassName = classBinder_cx('c-icon', (_b = {},
|
|
84332
|
-
_b["c-icon--" + size] = size,
|
|
84333
|
-
_b["c-icon--l"] = isLeft,
|
|
84334
|
-
_b["c-icon--rounded"] = backgroundColor,
|
|
84335
|
-
_b["c-icon--" + backgroundColor + "Color"] = backgroundColor,
|
|
84336
|
-
_b["c-icon--r"] = isRight,
|
|
84337
|
-
_b["c-icon--" + name] = name,
|
|
84338
|
-
_b), theme);
|
|
84339
|
-
var Component;
|
|
84340
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
84341
|
-
// @ts-ignore
|
|
84342
|
-
if (usedIconComponents[name]) {
|
|
84343
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
84344
|
-
// @ts-ignore
|
|
84345
|
-
Component = usedIconComponents[name];
|
|
84346
|
-
}
|
|
84347
|
-
else {
|
|
84348
|
-
Component = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["lazy"])(function () { return __webpack_require__(901)("./" + camelcase_default()(name, { pascalCase: true })); });
|
|
84349
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
84350
|
-
// @ts-ignore
|
|
84351
|
-
usedIconComponents[name] = Component;
|
|
84352
|
-
}
|
|
84353
|
-
var iconColor = color ? "var(--" + color + ")" : undefined;
|
|
84354
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["Suspense"], { fallback: external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { className: componentClassName }) },
|
|
84355
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { "aria-hidden": "true", className: componentClassName, "data-testid": testId, tabIndex: -1 },
|
|
84356
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Component, Icon_assign({ className: classBinder_cx('c-icon__icon'), color: iconColor }, rest)))));
|
|
84357
|
-
};
|
|
84358
|
-
|
|
84359
|
-
// CONCATENATED MODULE: ./src/components/Components/Button/Button.tsx
|
|
84360
|
-
var Button_assign = (undefined && undefined.__assign) || function () {
|
|
84361
|
-
Button_assign = Object.assign || function(t) {
|
|
84362
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
84363
|
-
s = arguments[i];
|
|
84364
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
84365
|
-
t[p] = s[p];
|
|
84366
|
-
}
|
|
84367
|
-
return t;
|
|
84368
|
-
};
|
|
84369
|
-
return Button_assign.apply(this, arguments);
|
|
84370
|
-
};
|
|
84371
|
-
var Button_rest = (undefined && undefined.__rest) || function (s, e) {
|
|
84372
|
-
var t = {};
|
|
84373
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
84374
|
-
t[p] = s[p];
|
|
84375
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
84376
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
84377
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
84378
|
-
t[p[i]] = s[p[i]];
|
|
84379
|
-
}
|
|
84380
|
-
return t;
|
|
84381
|
-
};
|
|
84382
|
-
|
|
84383
|
-
|
|
84384
|
-
|
|
84385
|
-
var Button = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["forwardRef"])(function (_a, ref) {
|
|
84386
|
-
var _b;
|
|
84387
|
-
var _c = _a.allowEventPropagation, allowEventPropagation = _c === void 0 ? false : _c, ariaLabel = _a.ariaLabel, children = _a.children, color = _a.color, _d = _a.elementType, elementType = _d === void 0 ? 'button' : _d, isBlock = _a.isBlock, isDisabled = _a.isDisabled, isLoading = _a.isLoading, isRounded = _a.isRounded, isSmall = _a.isSmall, linkDownloadTitle = _a.linkDownloadTitle, linkUrl = _a.linkUrl, onClick = _a.onClick, onlyIconName = _a.onlyIconName, _e = _a.testId, testId = _e === void 0 ? 'Button' : _e, theme = _a.theme, title = _a.title, _f = _a.type, type = _f === void 0 ? 'filled' : _f, rest = Button_rest(_a, ["allowEventPropagation", "ariaLabel", "children", "color", "elementType", "isBlock", "isDisabled", "isLoading", "isRounded", "isSmall", "linkDownloadTitle", "linkUrl", "onClick", "onlyIconName", "testId", "theme", "title", "type"]);
|
|
84388
|
-
var handleOnClick = function (event) {
|
|
84389
|
-
if (isDisabled || isLoading) {
|
|
84390
|
-
event.preventDefault();
|
|
84391
|
-
}
|
|
84392
|
-
else if (onClick) {
|
|
84393
|
-
onClick(event);
|
|
84394
|
-
}
|
|
84395
|
-
if (!allowEventPropagation) {
|
|
84396
|
-
event.stopPropagation();
|
|
84397
|
-
}
|
|
84398
|
-
};
|
|
84399
|
-
var Component = linkUrl ? 'a' : 'button';
|
|
84400
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Component
|
|
84401
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
84402
|
-
// @ts-ignore
|
|
84403
|
-
, Button_assign({
|
|
84404
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
84405
|
-
// @ts-ignore
|
|
84406
|
-
ref: ref, "aria-label": ariaLabel, className: classBinder_cx('c-btn', (_b = {
|
|
84407
|
-
'c-btn--block': isBlock,
|
|
84408
|
-
'c-btn--disabled': isDisabled,
|
|
84409
|
-
'c-btn--loading': isLoading,
|
|
84410
|
-
'c-btn--small': isSmall,
|
|
84411
|
-
'c-btn--rounded': isRounded
|
|
84412
|
-
},
|
|
84413
|
-
_b["c-btn--" + type] = type !== 'filled',
|
|
84414
|
-
_b["c-btn--" + color] = color,
|
|
84415
|
-
_b['c-btn--onlyIcon'] = onlyIconName,
|
|
84416
|
-
_b), theme), "data-testid": testId, disabled: isDisabled || isLoading, download: linkDownloadTitle, href: linkUrl, title: title, type: linkUrl ? undefined : elementType, onClick: handleOnClick }, rest),
|
|
84417
|
-
isLoading && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: "loading" }),
|
|
84418
|
-
onlyIconName ? (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["Fragment"], null,
|
|
84419
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: onlyIconName }),
|
|
84420
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { className: classBinder_cx('u-vHide') }, ariaLabel))) : (children)));
|
|
84421
|
-
});
|
|
84422
|
-
Button.displayName = 'forwardRef(Button)';
|
|
84423
|
-
|
|
84424
|
-
// CONCATENATED MODULE: ./src/components/Components/Alert/Alert.tsx
|
|
84425
|
-
|
|
84426
|
-
|
|
84427
|
-
|
|
84428
|
-
|
|
84429
|
-
var closeButtonColorByType = {
|
|
84430
|
-
error: 'red',
|
|
84431
|
-
warning: 'gold',
|
|
84432
|
-
info: undefined,
|
|
84433
|
-
success: 'green'
|
|
84434
|
-
};
|
|
84435
|
-
var Alert = function (_a) {
|
|
84436
|
-
var _b;
|
|
84437
|
-
var alertRef = _a.alertRef, children = _a.children, closeButtonAriaLabel = _a.closeButtonAriaLabel, iconBackgroundColor = _a.iconBackgroundColor, iconName = _a.iconName, isLarge = _a.isLarge, onClose = _a.onClose, testId = _a.testId, theme = _a.theme, title = _a.title, type = _a.type;
|
|
84438
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { ref: alertRef, className: classBinder_cx('c-alert', (_b = {}, _b["c-alert--" + type] = type, _b['c-alert--large'] = isLarge, _b), theme), "data-testid": testId, role: "alert" },
|
|
84439
|
-
iconName && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('c-alert__icon') },
|
|
84440
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { backgroundColor: iconBackgroundColor, name: iconName }))),
|
|
84441
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('c-alert__content') },
|
|
84442
|
-
title && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("strong", { className: classBinder_cx('c-alert__title') }, title),
|
|
84443
|
-
children && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('c-alert__text') }, children)),
|
|
84444
|
-
onClose && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Button, { isSmall: true, ariaLabel: closeButtonAriaLabel || '', color: type ? closeButtonColorByType[type] : undefined, onlyIconName: "close", theme: "c-alert__close", type: "transparent", onClick: onClose }))));
|
|
84445
|
-
};
|
|
84446
|
-
|
|
84447
|
-
// CONCATENATED MODULE: ./src/components/Components/Alert/index.ts
|
|
84448
|
-
|
|
84449
|
-
|
|
84450
|
-
// CONCATENATED MODULE: ./src/components/Components/Avatar/Avatar.tsx
|
|
84451
|
-
|
|
84452
|
-
|
|
84453
|
-
|
|
84454
|
-
var Avatar = function (_a) {
|
|
84455
|
-
var _b;
|
|
84456
|
-
var background = _a.background, border = _a.border, boxShadow = _a.boxShadow, iconName = _a.iconName, size = _a.size, testId = _a.testId, text = _a.text, theme = _a.theme;
|
|
84457
|
-
var componentClassName = classBinder_cx('c-avatar', (_b = {},
|
|
84458
|
-
_b["c-avatar--" + size] = size,
|
|
84459
|
-
_b["c-avatar--" + background + "Color"] = background,
|
|
84460
|
-
_b["c-avatar--" + border + "Border"] = border,
|
|
84461
|
-
_b['c-avatar--shadow'] = boxShadow,
|
|
84462
|
-
_b), theme);
|
|
84463
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: componentClassName, "data-testid": testId },
|
|
84464
|
-
text && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { "aria-hidden": "true", className: "c-avatar__text" }, text)),
|
|
84465
|
-
iconName && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: iconName })));
|
|
84466
|
-
};
|
|
84467
|
-
|
|
84468
|
-
// CONCATENATED MODULE: ./src/components/Components/Avatar/index.ts
|
|
84469
|
-
|
|
84470
|
-
|
|
84471
|
-
// CONCATENATED MODULE: ./src/components/Components/Badge/Badge.tsx
|
|
84472
|
-
|
|
84473
|
-
|
|
84474
|
-
var Badge = function (_a) {
|
|
84475
|
-
var ariaLabel = _a.ariaLabel, children = _a.children, _b = _a.count, count = _b === void 0 ? 0 : _b, _c = _a.isDotVisible, isDotVisible = _c === void 0 ? false : _c, _d = _a.maxCount, maxCount = _d === void 0 ? 99 : _d, testId = _a.testId, theme = _a.theme;
|
|
84476
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { "aria-label": ariaLabel, className: classBinder_cx('c-badge', theme), "data-testid": testId },
|
|
84477
|
-
children,
|
|
84478
|
-
(isDotVisible || count > 0) && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { className: classBinder_cx('c-badge__point', { 'c-badge__point--dot': isDotVisible }) }, count > 0 && !isDotVisible ? (count > maxCount ? maxCount + "+" : count) : null))));
|
|
84479
|
-
};
|
|
84480
|
-
|
|
84481
|
-
// CONCATENATED MODULE: ./src/components/Components/Badge/index.ts
|
|
84482
|
-
|
|
84483
|
-
|
|
84484
|
-
// CONCATENATED MODULE: ./src/components/Layout/Flex/Flex.tsx
|
|
84485
|
-
|
|
84486
|
-
|
|
84487
|
-
var Flex = function (_a) {
|
|
84488
|
-
var _b;
|
|
84489
|
-
var _c = _a.alignItems, alignItems = _c === void 0 ? 'baseline' : _c, children = _a.children, direction = _a.direction, isAlignItemsResponsive = _a.isAlignItemsResponsive, isDirectionResponsive = _a.isDirectionResponsive, justifyContent = _a.justifyContent, onClick = _a.onClick, testId = _a.testId, theme = _a.theme, _d = _a.wrap, wrap = _d === void 0 ? 'nowrap' : _d;
|
|
84490
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('c-flex', (_b = {},
|
|
84491
|
-
_b["c-flex--align-items--" + alignItems] = alignItems,
|
|
84492
|
-
_b["c-flex--align-items--responsive"] = isAlignItemsResponsive,
|
|
84493
|
-
_b["c-flex--direction--" + direction] = direction,
|
|
84494
|
-
_b['c-flex--direction--responsive'] = isDirectionResponsive,
|
|
84495
|
-
_b["c-flex--justify-content--" + justifyContent] = justifyContent,
|
|
84496
|
-
_b["c-flex--wrap--" + wrap] = wrap,
|
|
84497
|
-
_b), theme), "data-testid": testId, onClick: onClick }, children));
|
|
84498
|
-
};
|
|
84499
|
-
|
|
84500
|
-
// CONCATENATED MODULE: ./src/components/Components/Button/ButtonsGroup.tsx
|
|
84501
|
-
var ButtonsGroup_assign = (undefined && undefined.__assign) || function () {
|
|
84502
|
-
ButtonsGroup_assign = Object.assign || function(t) {
|
|
84503
|
-
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
84504
|
-
s = arguments[i];
|
|
84505
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
84506
|
-
t[p] = s[p];
|
|
84507
|
-
}
|
|
84508
|
-
return t;
|
|
84509
|
-
};
|
|
84510
|
-
return ButtonsGroup_assign.apply(this, arguments);
|
|
84511
|
-
};
|
|
84512
|
-
var ButtonsGroup_rest = (undefined && undefined.__rest) || function (s, e) {
|
|
84513
|
-
var t = {};
|
|
84514
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
84515
|
-
t[p] = s[p];
|
|
84516
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
84517
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
84518
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
84519
|
-
t[p[i]] = s[p[i]];
|
|
84520
|
-
}
|
|
84521
|
-
return t;
|
|
84522
|
-
};
|
|
84523
|
-
|
|
84524
|
-
|
|
84525
|
-
|
|
84526
|
-
var ButtonsGroup = function (_a) {
|
|
84527
|
-
var _b;
|
|
84528
|
-
var children = _a.children, isFlex = _a.isFlex, isSmall = _a.isSmall, testId = _a.testId, theme = _a.theme, flexProps = ButtonsGroup_rest(_a, ["children", "isFlex", "isSmall", "testId", "theme"]);
|
|
84529
|
-
var Component = isFlex ? Flex : 'div';
|
|
84530
|
-
var componentProps = isFlex ? {} : { 'data-testid': testId };
|
|
84531
|
-
var componentStyles = classBinder_cx('c-btnsGroup', (_b = {}, _b['c-btnsGroup--small'] = isSmall, _b), theme);
|
|
84532
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Component, ButtonsGroup_assign({}, flexProps, componentProps, { className: !isFlex ? componentStyles : undefined, theme: isFlex ? componentStyles : undefined }), children));
|
|
84533
|
-
};
|
|
84534
|
-
|
|
84535
|
-
// CONCATENATED MODULE: ./src/components/Components/Button/index.ts
|
|
84536
|
-
|
|
84537
|
-
|
|
84538
|
-
|
|
84539
84298
|
// EXTERNAL MODULE: ./node_modules/cuid/index.js
|
|
84540
84299
|
var cuid = __webpack_require__(19);
|
|
84541
84300
|
var cuid_default = /*#__PURE__*/__webpack_require__.n(cuid);
|
|
@@ -86999,24 +86758,285 @@ var Tooltip_assign = (undefined && undefined.__assign) || function () {
|
|
|
86999
86758
|
|
|
87000
86759
|
|
|
87001
86760
|
var Tooltip = function (_a) {
|
|
87002
|
-
var children = _a.children, content = _a.content, _b = _a.isArrowVisible, isArrowVisible = _b === void 0 ? true : _b, _c = _a.
|
|
86761
|
+
var children = _a.children, content = _a.content, _b = _a.isArrowVisible, isArrowVisible = _b === void 0 ? true : _b, _c = _a.isBold, isBold = _c === void 0 ? true : _c, _d = _a.isShownByDefault, isShownByDefault = _d === void 0 ? false : _d, _e = _a.isUpperCased, isUpperCased = _e === void 0 ? false : _e, _f = _a.onTooltipVisibilityChange, onTooltipVisibilityChange = _f === void 0 ? es_noop : _f, _g = _a.placement, placement = _g === void 0 ? 'top' : _g, testId = _a.testId, theme = _a.theme, _h = _a.trigger, trigger = _h === void 0 ? ['focus', 'hover'] : _h, _j = _a.type, type = _j === void 0 ? 'dark' : _j, _k = _a.verticalOffset, verticalOffset = _k === void 0 ? 6 : _k;
|
|
87003
86762
|
var identifier = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useMemo"])(function () { return "tooltip_" + cuid_default()(); }, []);
|
|
87004
86763
|
var handleVisibilityChange = function () { return onTooltipVisibilityChange(visible); };
|
|
87005
|
-
var
|
|
86764
|
+
var _l = usePopperTooltip({
|
|
87006
86765
|
defaultVisible: isShownByDefault,
|
|
87007
86766
|
placement: placement,
|
|
87008
86767
|
trigger: trigger,
|
|
87009
|
-
onVisibilityChange: handleVisibilityChange
|
|
87010
|
-
|
|
86768
|
+
onVisibilityChange: handleVisibilityChange,
|
|
86769
|
+
offset: [0, verticalOffset]
|
|
86770
|
+
}), getArrowProps = _l.getArrowProps, getTooltipProps = _l.getTooltipProps, setTooltipRef = _l.setTooltipRef, setTriggerRef = _l.setTriggerRef, visible = _l.visible;
|
|
87011
86771
|
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["Fragment"], null,
|
|
87012
86772
|
Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["cloneElement"])(children, { ref: setTriggerRef, tabIndex: 0, 'aria-describedBy': identifier }),
|
|
87013
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { "aria-hidden": visible, "aria-live": "polite", id: identifier, role: "tooltip", tabIndex: -1 }, visible && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", Tooltip_assign({ ref: setTooltipRef, "data-testid": testId }, getTooltipProps({
|
|
87014
|
-
className: classBinder_cx('c-tooltip', "c-tooltip--" + type, "c-tooltip--" + placement, { 'upper-case': isUpperCased }, theme)
|
|
86773
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { "aria-hidden": visible, "aria-live": "polite", className: "c-tooltip-wrapper", id: identifier, role: "tooltip", tabIndex: -1 }, visible && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", Tooltip_assign({ ref: setTooltipRef, "data-testid": testId }, getTooltipProps({
|
|
86774
|
+
className: classBinder_cx('c-tooltip', "c-tooltip--" + type, "c-tooltip--" + placement, { 'upper-case': isUpperCased, 'c-tooltip--bold': isBold }, theme)
|
|
87015
86775
|
})),
|
|
87016
86776
|
isArrowVisible && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", Tooltip_assign({}, getArrowProps({ className: 'c-tooltip-arrow', 'data-placement': placement })))),
|
|
87017
86777
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: "tooltip-body" }, content))))));
|
|
87018
86778
|
};
|
|
87019
86779
|
|
|
86780
|
+
// CONCATENATED MODULE: ./src/hocs/withDisabledTooltip.tsx
|
|
86781
|
+
|
|
86782
|
+
|
|
86783
|
+
var withDisabledTooltip = function (isDisabled, tooltipContent, verticalOffset) {
|
|
86784
|
+
return function withDisabledTooltipHoc(children) {
|
|
86785
|
+
if (isDisabled && tooltipContent) {
|
|
86786
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Tooltip, { content: tooltipContent, isBold: false, trigger: "hover", type: "grey", verticalOffset: verticalOffset }, children));
|
|
86787
|
+
}
|
|
86788
|
+
return children;
|
|
86789
|
+
};
|
|
86790
|
+
};
|
|
86791
|
+
/* harmony default export */ var hocs_withDisabledTooltip = (withDisabledTooltip);
|
|
86792
|
+
|
|
86793
|
+
// CONCATENATED MODULE: ./src/hocs/index.ts
|
|
86794
|
+
|
|
86795
|
+
|
|
86796
|
+
// EXTERNAL MODULE: ./node_modules/camelcase/index.js
|
|
86797
|
+
var camelcase = __webpack_require__(54);
|
|
86798
|
+
var camelcase_default = /*#__PURE__*/__webpack_require__.n(camelcase);
|
|
86799
|
+
|
|
86800
|
+
// CONCATENATED MODULE: ./src/components/Components/Icon/Icon.tsx
|
|
86801
|
+
var Icon_assign = (undefined && undefined.__assign) || function () {
|
|
86802
|
+
Icon_assign = Object.assign || function(t) {
|
|
86803
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
86804
|
+
s = arguments[i];
|
|
86805
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
86806
|
+
t[p] = s[p];
|
|
86807
|
+
}
|
|
86808
|
+
return t;
|
|
86809
|
+
};
|
|
86810
|
+
return Icon_assign.apply(this, arguments);
|
|
86811
|
+
};
|
|
86812
|
+
var __rest = (undefined && undefined.__rest) || function (s, e) {
|
|
86813
|
+
var t = {};
|
|
86814
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
86815
|
+
t[p] = s[p];
|
|
86816
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
86817
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
86818
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
86819
|
+
t[p[i]] = s[p[i]];
|
|
86820
|
+
}
|
|
86821
|
+
return t;
|
|
86822
|
+
};
|
|
86823
|
+
|
|
86824
|
+
|
|
86825
|
+
|
|
86826
|
+
var usedIconComponents = {};
|
|
86827
|
+
var Icon = function (_a) {
|
|
86828
|
+
var _b;
|
|
86829
|
+
var backgroundColor = _a.backgroundColor, color = _a.color, isLeft = _a.isLeft, isRight = _a.isRight, name = _a.name, size = _a.size, testId = _a.testId, theme = _a.theme, rest = __rest(_a, ["backgroundColor", "color", "isLeft", "isRight", "name", "size", "testId", "theme"]);
|
|
86830
|
+
var componentClassName = classBinder_cx('c-icon', (_b = {},
|
|
86831
|
+
_b["c-icon--" + size] = size,
|
|
86832
|
+
_b["c-icon--l"] = isLeft,
|
|
86833
|
+
_b["c-icon--rounded"] = backgroundColor,
|
|
86834
|
+
_b["c-icon--" + backgroundColor + "Color"] = backgroundColor,
|
|
86835
|
+
_b["c-icon--r"] = isRight,
|
|
86836
|
+
_b["c-icon--" + name] = name,
|
|
86837
|
+
_b), theme);
|
|
86838
|
+
var Component;
|
|
86839
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
86840
|
+
// @ts-ignore
|
|
86841
|
+
if (usedIconComponents[name]) {
|
|
86842
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
86843
|
+
// @ts-ignore
|
|
86844
|
+
Component = usedIconComponents[name];
|
|
86845
|
+
}
|
|
86846
|
+
else {
|
|
86847
|
+
Component = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["lazy"])(function () { return __webpack_require__(903)("./" + camelcase_default()(name, { pascalCase: true })); });
|
|
86848
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
86849
|
+
// @ts-ignore
|
|
86850
|
+
usedIconComponents[name] = Component;
|
|
86851
|
+
}
|
|
86852
|
+
var iconColor = color ? "var(--" + color + ")" : undefined;
|
|
86853
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["Suspense"], { fallback: external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { className: componentClassName }) },
|
|
86854
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { "aria-hidden": "true", className: componentClassName, "data-testid": testId, tabIndex: -1 },
|
|
86855
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Component, Icon_assign({ className: classBinder_cx('c-icon__icon'), color: iconColor }, rest)))));
|
|
86856
|
+
};
|
|
86857
|
+
|
|
86858
|
+
// CONCATENATED MODULE: ./src/components/Components/Button/Button.tsx
|
|
86859
|
+
var Button_assign = (undefined && undefined.__assign) || function () {
|
|
86860
|
+
Button_assign = Object.assign || function(t) {
|
|
86861
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
86862
|
+
s = arguments[i];
|
|
86863
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
86864
|
+
t[p] = s[p];
|
|
86865
|
+
}
|
|
86866
|
+
return t;
|
|
86867
|
+
};
|
|
86868
|
+
return Button_assign.apply(this, arguments);
|
|
86869
|
+
};
|
|
86870
|
+
var Button_rest = (undefined && undefined.__rest) || function (s, e) {
|
|
86871
|
+
var t = {};
|
|
86872
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
86873
|
+
t[p] = s[p];
|
|
86874
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
86875
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
86876
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
86877
|
+
t[p[i]] = s[p[i]];
|
|
86878
|
+
}
|
|
86879
|
+
return t;
|
|
86880
|
+
};
|
|
86881
|
+
|
|
86882
|
+
|
|
86883
|
+
|
|
86884
|
+
|
|
86885
|
+
var Button = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["forwardRef"])(function (_a, ref) {
|
|
86886
|
+
var _b;
|
|
86887
|
+
var _c = _a.allowEventPropagation, allowEventPropagation = _c === void 0 ? false : _c, ariaLabel = _a.ariaLabel, children = _a.children, color = _a.color, disabledTooltip = _a.disabledTooltip, _d = _a.elementType, elementType = _d === void 0 ? 'button' : _d, isBlock = _a.isBlock, isDisabled = _a.isDisabled, isLoading = _a.isLoading, isRounded = _a.isRounded, isSmall = _a.isSmall, linkDownloadTitle = _a.linkDownloadTitle, linkUrl = _a.linkUrl, onClick = _a.onClick, onlyIconName = _a.onlyIconName, _e = _a.testId, testId = _e === void 0 ? 'Button' : _e, theme = _a.theme, title = _a.title, _f = _a.type, type = _f === void 0 ? 'filled' : _f, rest = Button_rest(_a, ["allowEventPropagation", "ariaLabel", "children", "color", "disabledTooltip", "elementType", "isBlock", "isDisabled", "isLoading", "isRounded", "isSmall", "linkDownloadTitle", "linkUrl", "onClick", "onlyIconName", "testId", "theme", "title", "type"]);
|
|
86888
|
+
var handleOnClick = function (event) {
|
|
86889
|
+
if (isDisabled || isLoading) {
|
|
86890
|
+
event.preventDefault();
|
|
86891
|
+
}
|
|
86892
|
+
else if (onClick) {
|
|
86893
|
+
onClick(event);
|
|
86894
|
+
}
|
|
86895
|
+
if (!allowEventPropagation) {
|
|
86896
|
+
event.stopPropagation();
|
|
86897
|
+
}
|
|
86898
|
+
};
|
|
86899
|
+
var Component = linkUrl ? 'a' : 'button';
|
|
86900
|
+
var content = (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Component
|
|
86901
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
86902
|
+
// @ts-ignore
|
|
86903
|
+
, Button_assign({
|
|
86904
|
+
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
86905
|
+
// @ts-ignore
|
|
86906
|
+
ref: ref, "aria-disabled": isDisabled || isLoading, "aria-label": ariaLabel, className: classBinder_cx('c-btn', (_b = {
|
|
86907
|
+
'c-btn--block': isBlock,
|
|
86908
|
+
'c-btn--disabled': isDisabled,
|
|
86909
|
+
'c-btn--loading': isLoading,
|
|
86910
|
+
'c-btn--small': isSmall,
|
|
86911
|
+
'c-btn--rounded': isRounded
|
|
86912
|
+
},
|
|
86913
|
+
_b["c-btn--" + type] = type !== 'filled',
|
|
86914
|
+
_b["c-btn--" + color] = color,
|
|
86915
|
+
_b['c-btn--onlyIcon'] = onlyIconName,
|
|
86916
|
+
_b), theme), "data-testid": testId, disabled: (isDisabled || isLoading) && !disabledTooltip, download: linkDownloadTitle, href: linkUrl, title: title, type: linkUrl ? undefined : elementType, onClick: handleOnClick }, rest),
|
|
86917
|
+
isLoading && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: "loading" }),
|
|
86918
|
+
onlyIconName ? (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["Fragment"], null,
|
|
86919
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: onlyIconName }),
|
|
86920
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { className: classBinder_cx('u-vHide') }, ariaLabel))) : (children)));
|
|
86921
|
+
return hocs_withDisabledTooltip(isDisabled, disabledTooltip)(content) || external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["Fragment"], null);
|
|
86922
|
+
});
|
|
86923
|
+
Button.displayName = 'forwardRef(Button)';
|
|
86924
|
+
|
|
86925
|
+
// CONCATENATED MODULE: ./src/components/Components/Alert/Alert.tsx
|
|
86926
|
+
|
|
86927
|
+
|
|
86928
|
+
|
|
86929
|
+
|
|
86930
|
+
var closeButtonColorByType = {
|
|
86931
|
+
error: 'red',
|
|
86932
|
+
warning: 'gold',
|
|
86933
|
+
info: undefined,
|
|
86934
|
+
success: 'green'
|
|
86935
|
+
};
|
|
86936
|
+
var Alert = function (_a) {
|
|
86937
|
+
var _b;
|
|
86938
|
+
var alertRef = _a.alertRef, children = _a.children, closeButtonAriaLabel = _a.closeButtonAriaLabel, iconBackgroundColor = _a.iconBackgroundColor, iconName = _a.iconName, isLarge = _a.isLarge, onClose = _a.onClose, testId = _a.testId, theme = _a.theme, title = _a.title, type = _a.type;
|
|
86939
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { ref: alertRef, className: classBinder_cx('c-alert', (_b = {}, _b["c-alert--" + type] = type, _b['c-alert--large'] = isLarge, _b), theme), "data-testid": testId, role: "alert" },
|
|
86940
|
+
iconName && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('c-alert__icon') },
|
|
86941
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { backgroundColor: iconBackgroundColor, name: iconName }))),
|
|
86942
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('c-alert__content') },
|
|
86943
|
+
title && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("strong", { className: classBinder_cx('c-alert__title') }, title),
|
|
86944
|
+
children && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('c-alert__text') }, children)),
|
|
86945
|
+
onClose && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Button, { isSmall: true, ariaLabel: closeButtonAriaLabel || '', color: type ? closeButtonColorByType[type] : undefined, onlyIconName: "close", theme: "c-alert__close", type: "transparent", onClick: onClose }))));
|
|
86946
|
+
};
|
|
86947
|
+
|
|
86948
|
+
// CONCATENATED MODULE: ./src/components/Components/Alert/index.ts
|
|
86949
|
+
|
|
86950
|
+
|
|
86951
|
+
// CONCATENATED MODULE: ./src/components/Components/Avatar/Avatar.tsx
|
|
86952
|
+
|
|
86953
|
+
|
|
86954
|
+
|
|
86955
|
+
var Avatar = function (_a) {
|
|
86956
|
+
var _b;
|
|
86957
|
+
var background = _a.background, border = _a.border, boxShadow = _a.boxShadow, iconName = _a.iconName, size = _a.size, testId = _a.testId, text = _a.text, theme = _a.theme;
|
|
86958
|
+
var componentClassName = classBinder_cx('c-avatar', (_b = {},
|
|
86959
|
+
_b["c-avatar--" + size] = size,
|
|
86960
|
+
_b["c-avatar--" + background + "Color"] = background,
|
|
86961
|
+
_b["c-avatar--" + border + "Border"] = border,
|
|
86962
|
+
_b['c-avatar--shadow'] = boxShadow,
|
|
86963
|
+
_b), theme);
|
|
86964
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: componentClassName, "data-testid": testId },
|
|
86965
|
+
text && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { "aria-hidden": "true", className: "c-avatar__text" }, text)),
|
|
86966
|
+
iconName && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: iconName })));
|
|
86967
|
+
};
|
|
86968
|
+
|
|
86969
|
+
// CONCATENATED MODULE: ./src/components/Components/Avatar/index.ts
|
|
86970
|
+
|
|
86971
|
+
|
|
86972
|
+
// CONCATENATED MODULE: ./src/components/Components/Badge/Badge.tsx
|
|
86973
|
+
|
|
86974
|
+
|
|
86975
|
+
var Badge = function (_a) {
|
|
86976
|
+
var ariaLabel = _a.ariaLabel, children = _a.children, _b = _a.count, count = _b === void 0 ? 0 : _b, _c = _a.isDotVisible, isDotVisible = _c === void 0 ? false : _c, _d = _a.maxCount, maxCount = _d === void 0 ? 99 : _d, testId = _a.testId, theme = _a.theme;
|
|
86977
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { "aria-label": ariaLabel, className: classBinder_cx('c-badge', theme), "data-testid": testId },
|
|
86978
|
+
children,
|
|
86979
|
+
(isDotVisible || count > 0) && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { className: classBinder_cx('c-badge__point', { 'c-badge__point--dot': isDotVisible }) }, count > 0 && !isDotVisible ? (count > maxCount ? maxCount + "+" : count) : null))));
|
|
86980
|
+
};
|
|
86981
|
+
|
|
86982
|
+
// CONCATENATED MODULE: ./src/components/Components/Badge/index.ts
|
|
86983
|
+
|
|
86984
|
+
|
|
86985
|
+
// CONCATENATED MODULE: ./src/components/Layout/Flex/Flex.tsx
|
|
86986
|
+
|
|
86987
|
+
|
|
86988
|
+
var Flex = function (_a) {
|
|
86989
|
+
var _b;
|
|
86990
|
+
var _c = _a.alignItems, alignItems = _c === void 0 ? 'baseline' : _c, children = _a.children, direction = _a.direction, isAlignItemsResponsive = _a.isAlignItemsResponsive, isDirectionResponsive = _a.isDirectionResponsive, justifyContent = _a.justifyContent, onClick = _a.onClick, testId = _a.testId, theme = _a.theme, _d = _a.wrap, wrap = _d === void 0 ? 'nowrap' : _d;
|
|
86991
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('c-flex', (_b = {},
|
|
86992
|
+
_b["c-flex--align-items--" + alignItems] = alignItems,
|
|
86993
|
+
_b["c-flex--align-items--responsive"] = isAlignItemsResponsive,
|
|
86994
|
+
_b["c-flex--direction--" + direction] = direction,
|
|
86995
|
+
_b['c-flex--direction--responsive'] = isDirectionResponsive,
|
|
86996
|
+
_b["c-flex--justify-content--" + justifyContent] = justifyContent,
|
|
86997
|
+
_b["c-flex--wrap--" + wrap] = wrap,
|
|
86998
|
+
_b), theme), "data-testid": testId, onClick: onClick }, children));
|
|
86999
|
+
};
|
|
87000
|
+
|
|
87001
|
+
// CONCATENATED MODULE: ./src/components/Components/Button/ButtonsGroup.tsx
|
|
87002
|
+
var ButtonsGroup_assign = (undefined && undefined.__assign) || function () {
|
|
87003
|
+
ButtonsGroup_assign = Object.assign || function(t) {
|
|
87004
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
87005
|
+
s = arguments[i];
|
|
87006
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
87007
|
+
t[p] = s[p];
|
|
87008
|
+
}
|
|
87009
|
+
return t;
|
|
87010
|
+
};
|
|
87011
|
+
return ButtonsGroup_assign.apply(this, arguments);
|
|
87012
|
+
};
|
|
87013
|
+
var ButtonsGroup_rest = (undefined && undefined.__rest) || function (s, e) {
|
|
87014
|
+
var t = {};
|
|
87015
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
|
87016
|
+
t[p] = s[p];
|
|
87017
|
+
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
|
87018
|
+
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
|
87019
|
+
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
|
87020
|
+
t[p[i]] = s[p[i]];
|
|
87021
|
+
}
|
|
87022
|
+
return t;
|
|
87023
|
+
};
|
|
87024
|
+
|
|
87025
|
+
|
|
87026
|
+
|
|
87027
|
+
var ButtonsGroup = function (_a) {
|
|
87028
|
+
var _b;
|
|
87029
|
+
var children = _a.children, isFlex = _a.isFlex, isSmall = _a.isSmall, testId = _a.testId, theme = _a.theme, flexProps = ButtonsGroup_rest(_a, ["children", "isFlex", "isSmall", "testId", "theme"]);
|
|
87030
|
+
var Component = isFlex ? Flex : 'div';
|
|
87031
|
+
var componentProps = isFlex ? {} : { 'data-testid': testId };
|
|
87032
|
+
var componentStyles = classBinder_cx('c-btnsGroup', (_b = {}, _b['c-btnsGroup--small'] = isSmall, _b), theme);
|
|
87033
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Component, ButtonsGroup_assign({}, flexProps, componentProps, { className: !isFlex ? componentStyles : undefined, theme: isFlex ? componentStyles : undefined }), children));
|
|
87034
|
+
};
|
|
87035
|
+
|
|
87036
|
+
// CONCATENATED MODULE: ./src/components/Components/Button/index.ts
|
|
87037
|
+
|
|
87038
|
+
|
|
87039
|
+
|
|
87020
87040
|
// CONCATENATED MODULE: ./src/components/Components/ButtonTooltip/ButtonTooltip.tsx
|
|
87021
87041
|
var ButtonTooltip_assign = (undefined && undefined.__assign) || function () {
|
|
87022
87042
|
ButtonTooltip_assign = Object.assign || function(t) {
|
|
@@ -95988,9 +96008,10 @@ var CollapseHeader = function (_a) {
|
|
|
95988
96008
|
|
|
95989
96009
|
|
|
95990
96010
|
|
|
96011
|
+
|
|
95991
96012
|
var Card = function (_a) {
|
|
95992
96013
|
var _b;
|
|
95993
|
-
var allowEventPropagation = _a.allowEventPropagation, backgroundColor = _a.backgroundColor, borderColor = _a.borderColor, children = _a.children, _c = _a.hasCustomTrigger, hasCustomTrigger = _c === void 0 ? false : _c, collapseHeader = _a.header, iconBackgroundColor = _a.iconBackgroundColor, iconName = _a.iconName, isCollapsible = _a.isCollapsible, isIconAlignTop = _a.isIconAlignTop, isInteractive = _a.isInteractive, _d = _a.isOpen, isOpen = _d === void 0 ? false : _d, isSelected = _a.isSelected, onClick = _a.onClick, onToggle = _a.onToggle, shadowSize = _a.shadowSize, size = _a.size, testId = _a.testId, theme = _a.theme, _e = _a.withoutRole, withoutRole = _e === void 0 ? false : _e;
|
|
96014
|
+
var allowEventPropagation = _a.allowEventPropagation, backgroundColor = _a.backgroundColor, borderColor = _a.borderColor, children = _a.children, disabledTooltip = _a.disabledTooltip, _c = _a.hasCustomTrigger, hasCustomTrigger = _c === void 0 ? false : _c, collapseHeader = _a.header, iconBackgroundColor = _a.iconBackgroundColor, iconName = _a.iconName, isCollapsible = _a.isCollapsible, isDisabled = _a.isDisabled, isIconAlignTop = _a.isIconAlignTop, isInteractive = _a.isInteractive, _d = _a.isOpen, isOpen = _d === void 0 ? false : _d, isSelected = _a.isSelected, onClick = _a.onClick, onToggle = _a.onToggle, shadowSize = _a.shadowSize, size = _a.size, testId = _a.testId, theme = _a.theme, _e = _a.withoutRole, withoutRole = _e === void 0 ? false : _e;
|
|
95994
96015
|
var identification = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useMemo"])(function () { return "card_" + cuid_default()(); }, []);
|
|
95995
96016
|
var _f = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(isOpen), isOpened = _f[0], setIsOpened = _f[1];
|
|
95996
96017
|
var cardRef = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useRef"])(null);
|
|
@@ -96002,6 +96023,8 @@ var Card = function (_a) {
|
|
|
96002
96023
|
? "" + iconBackgroundColor.replace('Normal', 'Hover')
|
|
96003
96024
|
: "" + iconBackgroundColor);
|
|
96004
96025
|
var handleOnClick = function (event) {
|
|
96026
|
+
if (isDisabled)
|
|
96027
|
+
return;
|
|
96005
96028
|
if (isInteractive && onClick) {
|
|
96006
96029
|
onClick(event);
|
|
96007
96030
|
if (!allowEventPropagation) {
|
|
@@ -96032,24 +96055,24 @@ var Card = function (_a) {
|
|
|
96032
96055
|
var setRef = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useCallback"])(function (ref) {
|
|
96033
96056
|
cardRef.current = ref;
|
|
96034
96057
|
}, []);
|
|
96035
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(contexts_CardContext.Provider, { value: cardContext },
|
|
96036
|
-
|
|
96037
|
-
|
|
96038
|
-
|
|
96039
|
-
|
|
96040
|
-
|
|
96041
|
-
|
|
96042
|
-
|
|
96043
|
-
|
|
96044
|
-
|
|
96045
|
-
|
|
96046
|
-
|
|
96047
|
-
|
|
96048
|
-
|
|
96049
|
-
|
|
96050
|
-
|
|
96051
|
-
|
|
96052
|
-
|
|
96058
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(contexts_CardContext.Provider, { value: cardContext }, hocs_withDisabledTooltip(isDisabled, disabledTooltip)(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { ref: setRef, "aria-disabled": isDisabled, className: classBinder_cx('c-card', (_b = {
|
|
96059
|
+
'c-card--collapse--open': isCollapsible && isOpened,
|
|
96060
|
+
'c-card--collapse': isCollapsible,
|
|
96061
|
+
'c-card--interactive': isInteractive,
|
|
96062
|
+
'c-card--selected': isSelected,
|
|
96063
|
+
'c-card--disabled': isDisabled
|
|
96064
|
+
},
|
|
96065
|
+
_b["c-card--" + backgroundColor] = backgroundColor,
|
|
96066
|
+
_b["c-card--" + borderColor + "Border"] = borderColor,
|
|
96067
|
+
_b["c-card--" + shadowSize + "Shadow"] = shadowSize,
|
|
96068
|
+
_b["c-card--" + size] = size,
|
|
96069
|
+
_b), theme), "data-testid": testId, role: isInteractive && !withoutRole ? 'button' : undefined, tabIndex: (isInteractive || isCollapsible) && !withoutRole ? 0 : undefined, onClick: handleOnClick, onKeyDown: handleKeyDown },
|
|
96070
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(CollapseHeader, { header: collapseHeader ? collapseHeader : children, iconBackground: iconBackground, iconName: iconName, isCollapsible: isCollapsible, isIconAlignTop: isIconAlignTop, isInteractive: isInteractive, onToggle: handleOnToggle }),
|
|
96071
|
+
isCollapsible ? (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(AnimatePresence, { initial: false }, isOpened && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { "aria-labelledby": identification + "_header", className: classBinder_cx('c-card__content'), role: "region" },
|
|
96072
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(motion.div, { key: "content", animate: "open", exit: "collapsed", initial: "collapsed", transition: { duration: 0.6, ease: [0.04, 0.62, 0.23, 0.98] }, variants: {
|
|
96073
|
+
open: { opacity: 1, height: 'auto' },
|
|
96074
|
+
collapsed: { opacity: 0, height: 0 }
|
|
96075
|
+
} }, children))))) : (collapseHeader && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { "aria-labelledby": identification + "_header", className: classBinder_cx('c-card__content'), role: "region" }, children)))))));
|
|
96053
96076
|
};
|
|
96054
96077
|
|
|
96055
96078
|
// CONCATENATED MODULE: ./src/components/Components/Card/_elements_/CardCustomTrigger.tsx
|
|
@@ -96348,9 +96371,10 @@ var Link_rest = (undefined && undefined.__rest) || function (s, e) {
|
|
|
96348
96371
|
|
|
96349
96372
|
|
|
96350
96373
|
|
|
96374
|
+
|
|
96351
96375
|
var Link = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["forwardRef"])(function (_a, ref) {
|
|
96352
96376
|
var _b;
|
|
96353
|
-
var _c = _a.allowEventPropagation, allowEventPropagation = _c === void 0 ? false : _c, ariaLabel = _a.ariaLabel, children = _a.children, color = _a.color, isDisabled = _a.isDisabled, isLoading = _a.isLoading, isSmall = _a.isSmall, linkDownloadTitle = _a.linkDownloadTitle, linkUrl = _a.linkUrl, onClick = _a.onClick, _d = _a.testId, testId = _d === void 0 ? 'Link' : _d, theme = _a.theme, title = _a.title, rest = Link_rest(_a, ["allowEventPropagation", "ariaLabel", "children", "color", "isDisabled", "isLoading", "isSmall", "linkDownloadTitle", "linkUrl", "onClick", "testId", "theme", "title"]);
|
|
96377
|
+
var _c = _a.allowEventPropagation, allowEventPropagation = _c === void 0 ? false : _c, ariaLabel = _a.ariaLabel, children = _a.children, color = _a.color, disabledTooltip = _a.disabledTooltip, isDisabled = _a.isDisabled, isLoading = _a.isLoading, isSmall = _a.isSmall, linkDownloadTitle = _a.linkDownloadTitle, linkUrl = _a.linkUrl, onClick = _a.onClick, _d = _a.testId, testId = _d === void 0 ? 'Link' : _d, theme = _a.theme, title = _a.title, rest = Link_rest(_a, ["allowEventPropagation", "ariaLabel", "children", "color", "disabledTooltip", "isDisabled", "isLoading", "isSmall", "linkDownloadTitle", "linkUrl", "onClick", "testId", "theme", "title"]);
|
|
96354
96378
|
var handleOnClick = function (event) {
|
|
96355
96379
|
if (isDisabled || isLoading) {
|
|
96356
96380
|
event.preventDefault();
|
|
@@ -96363,7 +96387,7 @@ var Link = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_u
|
|
|
96363
96387
|
}
|
|
96364
96388
|
};
|
|
96365
96389
|
var Component = linkUrl ? 'a' : 'button';
|
|
96366
|
-
|
|
96390
|
+
var content = (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Component
|
|
96367
96391
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
96368
96392
|
// @ts-ignore
|
|
96369
96393
|
, Link_assign({
|
|
@@ -96378,6 +96402,7 @@ var Link = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_u
|
|
|
96378
96402
|
_b), theme), "data-testid": testId, disabled: isDisabled || isLoading, download: linkDownloadTitle, href: linkUrl, title: title, type: linkUrl ? undefined : 'button', onClick: handleOnClick }, rest),
|
|
96379
96403
|
isLoading && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: "loading" }),
|
|
96380
96404
|
children));
|
|
96405
|
+
return hocs_withDisabledTooltip(isDisabled, disabledTooltip)(content) || external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["Fragment"], null);
|
|
96381
96406
|
});
|
|
96382
96407
|
Link.displayName = 'forwardRef(Link)';
|
|
96383
96408
|
|
|
@@ -96647,6 +96672,7 @@ var useModal = function (disableCloseByOutsideClick, onHide, onShow) {
|
|
|
96647
96672
|
|
|
96648
96673
|
|
|
96649
96674
|
|
|
96675
|
+
|
|
96650
96676
|
var Pills = function (_a) {
|
|
96651
96677
|
var ariaLabel = _a.ariaLabel, _b = _a.initialPill, initialPill = _b === void 0 ? '' : _b, onChange = _a.onChange, pills = _a.pills, _c = _a.testId, testId = _c === void 0 ? 'Pills' : _c, theme = _a.theme;
|
|
96652
96678
|
var _d = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(''), activePill = _d[0], setActivePill = _d[1];
|
|
@@ -96666,12 +96692,12 @@ var Pills = function (_a) {
|
|
|
96666
96692
|
}, [initialPill]);
|
|
96667
96693
|
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("ul", { "aria-label": ariaLabel, className: classBinder_cx('c-pills__list', theme), "data-testid": testId }, pills.map(function (_a) {
|
|
96668
96694
|
var _b;
|
|
96669
|
-
var _c = _a.isDisabled, isDisabled = _c === void 0 ? false : _c, label = _a.label, value = _a.value;
|
|
96695
|
+
var disabledTooltip = _a.disabledTooltip, _c = _a.isDisabled, isDisabled = _c === void 0 ? false : _c, label = _a.label, value = _a.value;
|
|
96670
96696
|
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("li", { key: "pills-" + cuid_default()() + "-" + value, className: classBinder_cx('c-pills__listItem', (_b = {},
|
|
96671
96697
|
_b["c-pills__listItem--disabled"] = isDisabled,
|
|
96672
96698
|
_b["c-pills__listItem--selected"] = activePill === value,
|
|
96673
96699
|
_b)) },
|
|
96674
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(
|
|
96700
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Button, { disabledTooltip: disabledTooltip, isDisabled: isDisabled, theme: classBinder_cx('c-pills__listButton'), type: "transparent", onClick: handleOnClick(value, isDisabled) }, label)));
|
|
96675
96701
|
})));
|
|
96676
96702
|
};
|
|
96677
96703
|
|
|
@@ -97045,7 +97071,7 @@ var FormGroup_rest = (undefined && undefined.__rest) || function (s, e) {
|
|
|
97045
97071
|
|
|
97046
97072
|
|
|
97047
97073
|
var FormGroup = function (_a) {
|
|
97048
|
-
var children = _a.children, error = _a.error, _b = _a.hasError, hasError = _b === void 0 ? false : _b, _c = _a.hasLabel, hasLabel = _c === void 0 ? true : _c,
|
|
97074
|
+
var children = _a.children, error = _a.error, _b = _a.hasError, hasError = _b === void 0 ? false : _b, _c = _a.hasLabel, hasLabel = _c === void 0 ? true : _c, kind = _a.kind, theme = _a.theme, rest = FormGroup_rest(_a, ["children", "error", "hasError", "hasLabel", "kind", "theme"]);
|
|
97049
97075
|
var _d = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])({ isFilled: false, isFocused: false }), state = _d[0], setState = _d[1];
|
|
97050
97076
|
var handleFocus = function () { return setState(function (state) { return (!state.isFocused ? FormGroup_assign(FormGroup_assign({}, state), { isFocused: true }) : state); }); };
|
|
97051
97077
|
var handleBlur = function () { return setState(function (state) { return (state.isFocused ? FormGroup_assign(FormGroup_assign({}, state), { isFocused: false }) : state); }); };
|
|
@@ -97070,11 +97096,7 @@ var FormGroup = function (_a) {
|
|
|
97070
97096
|
'is-filled': isFilled,
|
|
97071
97097
|
'is-focused': isFocused,
|
|
97072
97098
|
'without-label': !hasLabel
|
|
97073
|
-
}, theme),
|
|
97074
|
-
// TODO: WTF?!
|
|
97075
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
97076
|
-
// @ts-ignore
|
|
97077
|
-
disabled: isDisabled }), children)));
|
|
97099
|
+
}, theme) }), children)));
|
|
97078
97100
|
};
|
|
97079
97101
|
|
|
97080
97102
|
// CONCATENATED MODULE: ./src/components/Form/FormText/FormText.tsx
|
|
@@ -97140,8 +97162,9 @@ var FormField_rest = (undefined && undefined.__rest) || function (s, e) {
|
|
|
97140
97162
|
|
|
97141
97163
|
|
|
97142
97164
|
|
|
97165
|
+
|
|
97143
97166
|
var FormField = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["forwardRef"])(function (_a, ref) {
|
|
97144
|
-
var afterControl = _a.afterControl, _b = _a.allowEventPropagation, allowEventPropagation = _b === void 0 ? false : _b, _c = _a.autoComplete, autoComplete = _c === void 0 ? 'off' : _c, beforeControl = _a.beforeControl, ControlComponent = _a.control, error = _a.error, hasAutoFocus = _a.hasAutoFocus, id = _a.id, disabled = _a.isDisabled, isLabelHidden = _a.isLabelHidden, isReadOnly = _a.isReadOnly, isRequired = _a.isRequired, kind = _a.kind, label = _a.label, labelProps = _a.labelProps, labelTooltip = _a.labelTooltip, legendText = _a.legendText, maxCharacters = _a.maxCharacters, maxLength = _a.maxLength, name = _a.name, onClick = _a.onClick, prefix = _a.prefix, suffix = _a.suffix, theme = _a.theme, tooltip = _a.tooltip, value = _a.value, rest = FormField_rest(_a, ["afterControl", "allowEventPropagation", "autoComplete", "beforeControl", "control", "error", "hasAutoFocus", "id", "isDisabled", "isLabelHidden", "isReadOnly", "isRequired", "kind", "label", "labelProps", "labelTooltip", "legendText", "maxCharacters", "maxLength", "name", "onClick", "prefix", "suffix", "theme", "tooltip", "value"]);
|
|
97167
|
+
var afterControl = _a.afterControl, _b = _a.allowEventPropagation, allowEventPropagation = _b === void 0 ? false : _b, _c = _a.autoComplete, autoComplete = _c === void 0 ? 'off' : _c, beforeControl = _a.beforeControl, ControlComponent = _a.control, disabledTooltip = _a.disabledTooltip, error = _a.error, hasAutoFocus = _a.hasAutoFocus, id = _a.id, disabled = _a.isDisabled, isLabelHidden = _a.isLabelHidden, isReadOnly = _a.isReadOnly, isRequired = _a.isRequired, kind = _a.kind, label = _a.label, labelProps = _a.labelProps, labelTooltip = _a.labelTooltip, legendText = _a.legendText, maxCharacters = _a.maxCharacters, maxLength = _a.maxLength, name = _a.name, onClick = _a.onClick, prefix = _a.prefix, suffix = _a.suffix, theme = _a.theme, tooltip = _a.tooltip, value = _a.value, rest = FormField_rest(_a, ["afterControl", "allowEventPropagation", "autoComplete", "beforeControl", "control", "disabledTooltip", "error", "hasAutoFocus", "id", "isDisabled", "isLabelHidden", "isReadOnly", "isRequired", "kind", "label", "labelProps", "labelTooltip", "legendText", "maxCharacters", "maxLength", "name", "onClick", "prefix", "suffix", "theme", "tooltip", "value"]);
|
|
97145
97168
|
var uniqueID = id || name;
|
|
97146
97169
|
var hasError = !!error;
|
|
97147
97170
|
var helpID = uniqueID + "-help";
|
|
@@ -97162,16 +97185,18 @@ var FormField = Object(external_root_React_commonjs2_react_commonjs_react_amd_re
|
|
|
97162
97185
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { backgroundColor: "info", name: "info", size: "small" })))))));
|
|
97163
97186
|
var WrappedControlComponent = (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Flex, { alignItems: "center" },
|
|
97164
97187
|
beforeControl && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: "before-control" }, beforeControl),
|
|
97165
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('control-wrapper') },
|
|
97188
|
+
hocs_withDisabledTooltip(disabled && !(isCheckbox || isRadio), disabledTooltip)(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('control-wrapper') },
|
|
97166
97189
|
prefix && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: "f-control__prefix" }, prefix),
|
|
97167
97190
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(ControlComponent, FormField_assign({}, ariaAttributes, rest, {
|
|
97168
97191
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
97169
97192
|
// @ts-ignore
|
|
97170
97193
|
ref: ref, autoComplete: autoComplete, disabled: disabled, hasAutoFocus: hasAutoFocus, id: uniqueID, maxLength: maxLength || maxCharacters, name: name, readOnly: isReadOnly, required: isRequired, spellCheck: "false", value: value, onClick: handleOnClick })),
|
|
97171
|
-
label &&
|
|
97172
|
-
|
|
97194
|
+
label &&
|
|
97195
|
+
(isCheckbox || isRadio) &&
|
|
97196
|
+
hocs_withDisabledTooltip(disabled, disabledTooltip)(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", null, LabelComponent)),
|
|
97197
|
+
suffix && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: "f-control__suffix" }, suffix))),
|
|
97173
97198
|
afterControl && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: "after-control" }, afterControl)));
|
|
97174
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(FormGroup, { error: error, hasError: hasError, hasLabel: Boolean(label) && !isLabelHidden,
|
|
97199
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(FormGroup, { error: error, hasError: hasError, hasLabel: Boolean(label) && !isLabelHidden, kind: kind, theme: classBinder_cx(suffix && 'has-suffix', prefix && 'has-prefix', {
|
|
97175
97200
|
'is-required': isRequired,
|
|
97176
97201
|
'is-disabled': disabled
|
|
97177
97202
|
}, theme) },
|
|
@@ -97550,11 +97575,13 @@ var Label2 = function (_a) {
|
|
|
97550
97575
|
|
|
97551
97576
|
|
|
97552
97577
|
|
|
97578
|
+
|
|
97553
97579
|
var FormGroup2 = function (_a) {
|
|
97554
|
-
var charCounter = _a.charCounter, children = _a.children, error = _a.error,
|
|
97580
|
+
var charCounter = _a.charCounter, children = _a.children, disabledTooltip = _a.disabledTooltip, _b = _a.disabledTooltipOffset, disabledTooltipOffset = _b === void 0 ? 6 : _b, error = _a.error, _c = _a.hasError, hasError = _c === void 0 ? false : _c, help = _a.help, isDisabled = _a.isDisabled, label = _a.label, labelTooltip = _a.labelTooltip, name = _a.name, theme = _a.theme;
|
|
97555
97581
|
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('f-group2', { 'f-group2--disabled': isDisabled, 'f-group2--error': hasError }, theme) },
|
|
97556
|
-
|
|
97557
|
-
|
|
97582
|
+
hocs_withDisabledTooltip(isDisabled, disabledTooltip, disabledTooltipOffset)(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("span", { className: "disabled-tooltip-wrapper" },
|
|
97583
|
+
label && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Label2, { htmlFor: name, identifier: name + "_label", labelTooltip: labelTooltip }, label)),
|
|
97584
|
+
children)),
|
|
97558
97585
|
charCounter && charCounter.max > 0 && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('f-controlCounter', { 'f-controlCounter--error': charCounter.length > charCounter.max }) }, (charCounter.length || 0) + " / " + charCounter.max)),
|
|
97559
97586
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { "aria-live": "assertive", className: "f-validationMsg f-validationMsg--invalid", id: name + "_errorMessage" }, error),
|
|
97560
97587
|
help && (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: "f-controlHelp", id: name + "_help" }, help))));
|
|
@@ -97659,7 +97686,7 @@ var Autocomplete_assign = (undefined && undefined.__assign) || function () {
|
|
|
97659
97686
|
|
|
97660
97687
|
var Autocomplete = function (_a) {
|
|
97661
97688
|
var _b, _c, _d;
|
|
97662
|
-
var dropdownTheme = _a.dropdownTheme, error = _a.error, _e = _a.hasAlwaysValue, hasAlwaysValue = _e === void 0 ? false : _e, _f = _a.hasFullWidthOptions, hasFullWidthOptions = _f === void 0 ? true : _f, help = _a.help, _g = _a.inputAutocomplete, inputAutocomplete = _g === void 0 ? false : _g, isCreatable = _a.isCreatable, isDisabled = _a.isDisabled, items = _a.items, label = _a.label, labelTooltip = _a.labelTooltip, messages = _a.messages, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, onCreate = _a.onCreate, placeholder = _a.placeholder, testId = _a.testId, theme = _a.theme, outterValue = _a.value;
|
|
97689
|
+
var disabledTooltip = _a.disabledTooltip, dropdownTheme = _a.dropdownTheme, error = _a.error, _e = _a.hasAlwaysValue, hasAlwaysValue = _e === void 0 ? false : _e, _f = _a.hasFullWidthOptions, hasFullWidthOptions = _f === void 0 ? true : _f, help = _a.help, _g = _a.inputAutocomplete, inputAutocomplete = _g === void 0 ? false : _g, isCreatable = _a.isCreatable, isDisabled = _a.isDisabled, items = _a.items, label = _a.label, labelTooltip = _a.labelTooltip, messages = _a.messages, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, onCreate = _a.onCreate, placeholder = _a.placeholder, testId = _a.testId, theme = _a.theme, outterValue = _a.value;
|
|
97663
97690
|
var isCategorised = !!((_b = items[0]) === null || _b === void 0 ? void 0 : _b.items);
|
|
97664
97691
|
var _h = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(false), isDropdownVisible = _h[0], setIsDropdownVisible = _h[1];
|
|
97665
97692
|
var _j = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(outterValue || ''), value = _j[0], setValue = _j[1];
|
|
@@ -97953,6 +97980,7 @@ var Autocomplete = function (_a) {
|
|
|
97953
97980
|
setValue: setValue
|
|
97954
97981
|
};
|
|
97955
97982
|
var fromGroupProps = {
|
|
97983
|
+
disabledTooltip: disabledTooltip,
|
|
97956
97984
|
error: error,
|
|
97957
97985
|
hasError: !!error,
|
|
97958
97986
|
help: help,
|
|
@@ -103400,7 +103428,7 @@ var Checkbox2_assign = (undefined && undefined.__assign) || function () {
|
|
|
103400
103428
|
|
|
103401
103429
|
|
|
103402
103430
|
var Checkbox2 = function (_a) {
|
|
103403
|
-
var _b = _a.allowEventPropagation, allowEventPropagation = _b === void 0 ? false : _b, error = _a.error, help = _a.help, isDisabled = _a.isDisabled, label = _a.label, name = _a.name, onChange = _a.onChange, testId = _a.testId, theme = _a.theme, _c = _a.value, defaultState = _c === void 0 ? false : _c;
|
|
103431
|
+
var _b = _a.allowEventPropagation, allowEventPropagation = _b === void 0 ? false : _b, disabledTooltip = _a.disabledTooltip, error = _a.error, help = _a.help, isDisabled = _a.isDisabled, label = _a.label, name = _a.name, onChange = _a.onChange, testId = _a.testId, theme = _a.theme, _c = _a.value, defaultState = _c === void 0 ? false : _c;
|
|
103404
103432
|
var _d = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(defaultState), isChecked = _d[0], setIsChecked = _d[1];
|
|
103405
103433
|
var handleOnChange = function (event) {
|
|
103406
103434
|
if (!isDisabled) {
|
|
@@ -103421,6 +103449,7 @@ var Checkbox2 = function (_a) {
|
|
|
103421
103449
|
};
|
|
103422
103450
|
var formGroupProps = {
|
|
103423
103451
|
error: error,
|
|
103452
|
+
disabledTooltip: disabledTooltip,
|
|
103424
103453
|
hasError: !!error,
|
|
103425
103454
|
help: help,
|
|
103426
103455
|
isDisabled: isDisabled,
|
|
@@ -103495,7 +103524,7 @@ var DatePicker_rest = (undefined && undefined.__rest) || function (s, e) {
|
|
|
103495
103524
|
|
|
103496
103525
|
var NATIVE_DATE_FORMAT = 'YYYY-MM-DD';
|
|
103497
103526
|
var DatePicker = function (_a) {
|
|
103498
|
-
var _b = _a.autoDetectNativeCalendar, autoDetectNativeCalendar = _b === void 0 ? true : _b, defaultValue = _a.defaultValue, _c = _a.isDisabled, isDisabled = _c === void 0 ? false : _c, _d = _a.language, language = _d === void 0 ? 'cs' : _d, onChange = _a.onChange, settings = _a.settings, theme = _a.theme, value = _a.value, props = DatePicker_rest(_a, ["autoDetectNativeCalendar", "defaultValue", "isDisabled", "language", "onChange", "settings", "theme", "value"]);
|
|
103527
|
+
var _b = _a.autoDetectNativeCalendar, autoDetectNativeCalendar = _b === void 0 ? true : _b, defaultValue = _a.defaultValue, disabledTooltip = _a.disabledTooltip, _c = _a.isDisabled, isDisabled = _c === void 0 ? false : _c, _d = _a.language, language = _d === void 0 ? 'cs' : _d, onChange = _a.onChange, settings = _a.settings, theme = _a.theme, value = _a.value, props = DatePicker_rest(_a, ["autoDetectNativeCalendar", "defaultValue", "disabledTooltip", "isDisabled", "language", "onChange", "settings", "theme", "value"]);
|
|
103499
103528
|
var hasNativeCalendar = autoDetectNativeCalendar && (react_device_detect_main["isMobile"] || react_device_detect_main["isTablet"]);
|
|
103500
103529
|
var parseAndFormatDate = function (date) {
|
|
103501
103530
|
if (!date) {
|
|
@@ -103556,7 +103585,7 @@ var DatePicker = function (_a) {
|
|
|
103556
103585
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
103557
103586
|
// @ts-ignore
|
|
103558
103587
|
onOpen: function () { var _a; return (_a = document.querySelector("[data-onopen=\"" + generatedId + "\"]")) === null || _a === void 0 ? void 0 : _a.blur(); } }, settings), render: function (_, ref) { return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { ref: ref },
|
|
103559
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(TextInput, DatePicker_assign({ "data-onopen": generatedId }, props, { isDisabled: isDisabled, suffix: !hasNativeCalendar ? external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: "calendar", size: "small" }) : undefined, type: hasNativeCalendar ? 'date' : 'text', value: typedValue,
|
|
103588
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(TextInput, DatePicker_assign({ "data-onopen": generatedId }, props, { disabledTooltip: disabledTooltip, isDisabled: isDisabled, suffix: !hasNativeCalendar ? external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: "calendar", size: "small" }) : undefined, type: hasNativeCalendar ? 'date' : 'text', value: typedValue,
|
|
103560
103589
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
103561
103590
|
// @ts-ignore
|
|
103562
103591
|
onChange: onInputChange })))); }, value: value, onChange: onDateChange }));
|
|
@@ -105204,13 +105233,16 @@ var Input2_assign = (undefined && undefined.__assign) || function () {
|
|
|
105204
105233
|
|
|
105205
105234
|
|
|
105206
105235
|
|
|
105236
|
+
var DISABLED_TOOLTIP_OFFSET = -6;
|
|
105207
105237
|
var Input2 = function (_a) {
|
|
105208
|
-
var _b = _a.allowEventPropagation, allowEventPropagation = _b === void 0 ? false : _b, _c = _a.allowLeadingZeros, allowLeadingZeros = _c === void 0 ? true : _c, _d = _a.allowNegative, allowNegative = _d === void 0 ? false : _d, autocomplete = _a.autocomplete, autofocus = _a.autofocus, _e = _a.decimalLimit, decimalLimit = _e === void 0 ? 0 : _e, _f = _a.decimalSeparator, decimalSeparator = _f === void 0 ? ',' : _f, error = _a.error, help = _a.help, inputMode = _a.inputMode, _g = _a.integerPlaces, integerPlaces = _g === void 0 ? 0 : _g, isDisabled = _a.isDisabled, label = _a.label, labelTooltip = _a.labelTooltip, maxCharCounter = _a.maxCharCounter, maxLength = _a.maxLength, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, onClick = _a.onClick, onFocus = _a.onFocus, onPaste = _a.onPaste, placeholder = _a.placeholder, prefix = _a.prefix, prefixIconName = _a.prefixIconName, _h = _a.showPassword, showPassword = _h === void 0 ? true : _h, showPasswordTooltip = _a.showPasswordTooltip, suffixIconName = _a.suffixIconName, testId = _a.testId, theme = _a.theme, _j = _a.thousandSeparator, thousandSeparator = _j === void 0 ? '' : _j, _k = _a.type, type = _k === void 0 ? 'text' : _k, unit = _a.unit, outerValue = _a.value;
|
|
105238
|
+
var _b = _a.allowEventPropagation, allowEventPropagation = _b === void 0 ? false : _b, _c = _a.allowLeadingZeros, allowLeadingZeros = _c === void 0 ? true : _c, _d = _a.allowNegative, allowNegative = _d === void 0 ? false : _d, autocomplete = _a.autocomplete, autofocus = _a.autofocus, _e = _a.decimalLimit, decimalLimit = _e === void 0 ? 0 : _e, _f = _a.decimalSeparator, decimalSeparator = _f === void 0 ? ',' : _f, disabledTooltip = _a.disabledTooltip, error = _a.error, help = _a.help, inputMode = _a.inputMode, _g = _a.integerPlaces, integerPlaces = _g === void 0 ? 0 : _g, isDisabled = _a.isDisabled, label = _a.label, labelTooltip = _a.labelTooltip, maxCharCounter = _a.maxCharCounter, maxLength = _a.maxLength, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, onClick = _a.onClick, onFocus = _a.onFocus, onPaste = _a.onPaste, placeholder = _a.placeholder, prefix = _a.prefix, prefixIconName = _a.prefixIconName, _h = _a.showPassword, showPassword = _h === void 0 ? true : _h, showPasswordTooltip = _a.showPasswordTooltip, suffixIconName = _a.suffixIconName, testId = _a.testId, theme = _a.theme, _j = _a.thousandSeparator, thousandSeparator = _j === void 0 ? '' : _j, _k = _a.type, type = _k === void 0 ? 'text' : _k, unit = _a.unit, outerValue = _a.value;
|
|
105209
105239
|
var minusCharacter = '-';
|
|
105210
105240
|
var _l = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(outerValue || ''), value = _l[0], setValue = _l[1];
|
|
105211
105241
|
var _m = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(false), isPasswordVisible = _m[0], setIsPasswordVisible = _m[1];
|
|
105212
105242
|
var numberRegex = new RegExp(/^-*\d*[,.]*\d*$/);
|
|
105213
105243
|
var formGroupProps = {
|
|
105244
|
+
disabledTooltip: disabledTooltip,
|
|
105245
|
+
disabledTooltipOffset: DISABLED_TOOLTIP_OFFSET,
|
|
105214
105246
|
error: error,
|
|
105215
105247
|
hasError: !!error,
|
|
105216
105248
|
help: help,
|
|
@@ -105632,7 +105664,7 @@ var MonthInput_assign = (undefined && undefined.__assign) || function () {
|
|
|
105632
105664
|
// @ts-ignore
|
|
105633
105665
|
|
|
105634
105666
|
var MonthInput = function (_a) {
|
|
105635
|
-
var ariaLabel = _a.ariaLabel, defaultValue = _a.defaultValue, _b = _a.isDisabled, isDisabled = _b === void 0 ? false : _b, _c = _a.language, language = _c === void 0 ? 'cs' : _c, onChange = _a.onChange, settings = _a.settings, theme = _a.theme, value = _a.value;
|
|
105667
|
+
var ariaLabel = _a.ariaLabel, defaultValue = _a.defaultValue, disabledTooltip = _a.disabledTooltip, _b = _a.isDisabled, isDisabled = _b === void 0 ? false : _b, _c = _a.language, language = _c === void 0 ? 'cs' : _c, onChange = _a.onChange, settings = _a.settings, theme = _a.theme, value = _a.value;
|
|
105636
105668
|
var parseAndFormatDate = function (date) {
|
|
105637
105669
|
if (!date) {
|
|
105638
105670
|
return undefined;
|
|
@@ -105665,7 +105697,7 @@ var MonthInput = function (_a) {
|
|
|
105665
105697
|
altFormat: 'F Y'
|
|
105666
105698
|
})
|
|
105667
105699
|
], disableMobile: true }, settings), render: function (_, ref) { return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { ref: ref },
|
|
105668
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Button, { allowEventPropagation: true, isSmall: true, ariaLabel: ariaLabel, isDisabled: isDisabled, type: "border" },
|
|
105700
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Button, { allowEventPropagation: true, isSmall: true, ariaLabel: ariaLabel, disabledTooltip: disabledTooltip, isDisabled: isDisabled, type: "border" },
|
|
105669
105701
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { isLeft: true, name: "calendar", size: "small" }), shownValue === null || shownValue === void 0 ? void 0 :
|
|
105670
105702
|
shownValue.toString()))); }, value: value, onChange: onDateChange }));
|
|
105671
105703
|
};
|
|
@@ -105896,7 +105928,7 @@ var Radio2_assign = (undefined && undefined.__assign) || function () {
|
|
|
105896
105928
|
|
|
105897
105929
|
var Radio2 = function (_a) {
|
|
105898
105930
|
var _b;
|
|
105899
|
-
var _c = _a.allowEventPropagation, allowEventPropagation = _c === void 0 ? false : _c, error = _a.error, help = _a.help, _d = _a.isDisabled, isDisabled = _d === void 0 ? false : _d, _e = _a.isInRow, isInRow = _e === void 0 ? false : _e, _f = _a.isTitleHidden, isTitleHidden = _f === void 0 ? false : _f, items = _a.items, label = _a.label, name = _a.name, onChange = _a.onChange, testId = _a.testId, theme = _a.theme, value = _a.value;
|
|
105931
|
+
var _c = _a.allowEventPropagation, allowEventPropagation = _c === void 0 ? false : _c, disabledTooltip = _a.disabledTooltip, error = _a.error, help = _a.help, _d = _a.isDisabled, isDisabled = _d === void 0 ? false : _d, _e = _a.isInRow, isInRow = _e === void 0 ? false : _e, _f = _a.isTitleHidden, isTitleHidden = _f === void 0 ? false : _f, items = _a.items, label = _a.label, name = _a.name, onChange = _a.onChange, testId = _a.testId, theme = _a.theme, value = _a.value;
|
|
105900
105932
|
var getCheckedIndex = function (value) { return items.findIndex(function (item) { return item.value === value; }); };
|
|
105901
105933
|
var _g = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(getCheckedIndex(value)), checked = _g[0], setChecked = _g[1];
|
|
105902
105934
|
var _h = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(false), isFocused = _h[0], setIsFocused = _h[1];
|
|
@@ -105960,6 +105992,7 @@ var Radio2 = function (_a) {
|
|
|
105960
105992
|
};
|
|
105961
105993
|
var formGroupProps = {
|
|
105962
105994
|
error: error,
|
|
105995
|
+
disabledTooltip: disabledTooltip,
|
|
105963
105996
|
hasError: !!error,
|
|
105964
105997
|
help: help,
|
|
105965
105998
|
isDisabled: isDisabled,
|
|
@@ -106101,7 +106134,7 @@ var Select2_spreadArray = (undefined && undefined.__spreadArray) || function (to
|
|
|
106101
106134
|
|
|
106102
106135
|
var Select2 = function (_a) {
|
|
106103
106136
|
var _b;
|
|
106104
|
-
var _c = _a.displayDetails, displayDetails = _c === void 0 ? false : _c, dropdownTheme = _a.dropdownTheme, emptyValueLabel = _a.emptyValueLabel, error = _a.error, _d = _a.hasFullWidthOptions, hasFullWidthOptions = _d === void 0 ? true : _d, help = _a.help, isDisabled = _a.isDisabled, items = _a.items, label = _a.label, labelTooltip = _a.labelTooltip, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, onFocus = _a.onFocus, placeholder = _a.placeholder, testId = _a.testId, theme = _a.theme, value = _a.value;
|
|
106137
|
+
var disabledTooltip = _a.disabledTooltip, _c = _a.displayDetails, displayDetails = _c === void 0 ? false : _c, dropdownTheme = _a.dropdownTheme, emptyValueLabel = _a.emptyValueLabel, error = _a.error, _d = _a.hasFullWidthOptions, hasFullWidthOptions = _d === void 0 ? true : _d, help = _a.help, isDisabled = _a.isDisabled, items = _a.items, label = _a.label, labelTooltip = _a.labelTooltip, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, onFocus = _a.onFocus, placeholder = _a.placeholder, testId = _a.testId, theme = _a.theme, value = _a.value;
|
|
106105
106138
|
var _e = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(false), isDropdownVisible = _e[0], setIsDropdownVisible = _e[1];
|
|
106106
106139
|
var _f = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(null), buttonValue = _f[0], setButtonValue = _f[1];
|
|
106107
106140
|
var _g = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(-1), currentItemPosition = _g[0], setCurrentItemPosition = _g[1];
|
|
@@ -106326,6 +106359,7 @@ var Select2 = function (_a) {
|
|
|
106326
106359
|
value: value
|
|
106327
106360
|
};
|
|
106328
106361
|
var fromGroupProps = {
|
|
106362
|
+
disabledTooltip: disabledTooltip,
|
|
106329
106363
|
error: error,
|
|
106330
106364
|
hasError: !!error,
|
|
106331
106365
|
help: help,
|
|
@@ -106383,6 +106417,7 @@ var Slider_extends = (undefined && undefined.__extends) || (function () {
|
|
|
106383
106417
|
/* eslint-disable @typescript-eslint/ban-ts-comment */
|
|
106384
106418
|
|
|
106385
106419
|
|
|
106420
|
+
|
|
106386
106421
|
var mouseUpdateEvents = ['mousemove'];
|
|
106387
106422
|
var mouseStopEvents = ['mouseup'];
|
|
106388
106423
|
var touchUpdateEvents = ['touchmove'];
|
|
@@ -106580,9 +106615,9 @@ var Slider_Slider = /** @class */ (function (_super) {
|
|
|
106580
106615
|
};
|
|
106581
106616
|
Slider.prototype.render = function () {
|
|
106582
106617
|
var _this = this;
|
|
106583
|
-
var _a = this.props, isDisabled = _a.isDisabled, max = _a.max, maxLabel = _a.maxLabel, min = _a.min, minLabel = _a.minLabel, testId = _a.testId, theme = _a.theme, value = _a.value;
|
|
106618
|
+
var _a = this.props, disabledTooltip = _a.disabledTooltip, isDisabled = _a.isDisabled, max = _a.max, maxLabel = _a.maxLabel, min = _a.min, minLabel = _a.minLabel, testId = _a.testId, theme = _a.theme, value = _a.value;
|
|
106584
106619
|
var _b = this.state, dragging = _b.dragging, percentage = _b.percentage;
|
|
106585
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('f-slider', { 'f-slider--dragging': dragging, 'f-slider--disabled': isDisabled }, theme), "data-testid": testId },
|
|
106620
|
+
return hocs_withDisabledTooltip(isDisabled, disabledTooltip)(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('f-slider', { 'f-slider--dragging': dragging, 'f-slider--disabled': isDisabled }, theme), "data-testid": testId },
|
|
106586
106621
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { ref: function (ref) {
|
|
106587
106622
|
_this.slider = ref;
|
|
106588
106623
|
}, "aria-valuemax": max, "aria-valuemin": min, "aria-valuenow": value, className: classBinder_cx('f-slider__drag'), role: "slider", tabIndex: isDisabled ? -1 : 0, onBlur: this.handleBlur, onFocus: this.handleFocus, onKeyDown: this.handleKeyDown, onKeyPress: this.handleKeyPress, onKeyUp: this.handleKeyUp, onMouseDown: this.handleMouseDown, onTouchStart: this.handleTouchStart },
|
|
@@ -106686,10 +106721,11 @@ var Textarea2_assign = (undefined && undefined.__assign) || function () {
|
|
|
106686
106721
|
|
|
106687
106722
|
|
|
106688
106723
|
var Textarea2 = function (_a) {
|
|
106689
|
-
var _b = _a.allowEventPropagation, allowEventPropagation = _b === void 0 ? false : _b, autofocus = _a.autofocus, children = _a.children, error = _a.error, height = _a.height, help = _a.help, isDisabled = _a.isDisabled, label = _a.label, labelTooltip = _a.labelTooltip, maxCharCounter = _a.maxCharCounter, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, onClick = _a.onClick, onFocus = _a.onFocus, onPaste = _a.onPaste, placeholder = _a.placeholder, testId = _a.testId, theme = _a.theme, outerValue = _a.value;
|
|
106724
|
+
var _b = _a.allowEventPropagation, allowEventPropagation = _b === void 0 ? false : _b, autofocus = _a.autofocus, children = _a.children, disabledTooltip = _a.disabledTooltip, error = _a.error, height = _a.height, help = _a.help, isDisabled = _a.isDisabled, label = _a.label, labelTooltip = _a.labelTooltip, maxCharCounter = _a.maxCharCounter, name = _a.name, onBlur = _a.onBlur, onChange = _a.onChange, onClick = _a.onClick, onFocus = _a.onFocus, onPaste = _a.onPaste, placeholder = _a.placeholder, testId = _a.testId, theme = _a.theme, outerValue = _a.value;
|
|
106690
106725
|
var _c = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(outerValue), value = _c[0], setValue = _c[1];
|
|
106691
106726
|
var formGroupProps = {
|
|
106692
106727
|
error: error,
|
|
106728
|
+
disabledTooltip: disabledTooltip,
|
|
106693
106729
|
hasError: !!error,
|
|
106694
106730
|
help: help,
|
|
106695
106731
|
isDisabled: isDisabled,
|
|
@@ -106730,8 +106766,9 @@ var Textarea2 = function (_a) {
|
|
|
106730
106766
|
|
|
106731
106767
|
|
|
106732
106768
|
|
|
106769
|
+
|
|
106733
106770
|
var Toggle = function (_a) {
|
|
106734
|
-
var children = _a.children, iconName = _a.iconName, _b = _a.isActive, isActive = _b === void 0 ? false : _b, _c = _a.isDisabled, isDisabled = _c === void 0 ? false : _c, _d = _a.isSecondary, isSecondary = _d === void 0 ? false : _d, name = _a.name, onChange = _a.onChange, _e = _a.testId, testId = _e === void 0 ? 'Toggle' : _e, theme = _a.theme;
|
|
106771
|
+
var children = _a.children, disabledTooltip = _a.disabledTooltip, iconName = _a.iconName, _b = _a.isActive, isActive = _b === void 0 ? false : _b, _c = _a.isDisabled, isDisabled = _c === void 0 ? false : _c, _d = _a.isSecondary, isSecondary = _d === void 0 ? false : _d, name = _a.name, onChange = _a.onChange, _e = _a.testId, testId = _e === void 0 ? 'Toggle' : _e, theme = _a.theme;
|
|
106735
106772
|
var _f = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useState"])(isActive), checked = _f[0], setChecked = _f[1];
|
|
106736
106773
|
var handleOnClick = function (event) {
|
|
106737
106774
|
onChange && onChange(!checked, event);
|
|
@@ -106740,7 +106777,7 @@ var Toggle = function (_a) {
|
|
|
106740
106777
|
Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useEffect"])(function () {
|
|
106741
106778
|
setChecked(isActive);
|
|
106742
106779
|
}, [isActive]);
|
|
106743
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('f-toggle', { 'f-toggle--active': checked }, { 'f-toggle--disabled': isDisabled }, { 'f-toggle--secondary': isSecondary }, theme), "data-testid": testId },
|
|
106780
|
+
return hocs_withDisabledTooltip(isDisabled, disabledTooltip)(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: classBinder_cx('f-toggle', { 'f-toggle--active': checked }, { 'f-toggle--disabled': isDisabled }, { 'f-toggle--secondary': isSecondary }, theme), "data-testid": testId },
|
|
106744
106781
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("button", { "aria-checked": checked, "aria-labelledby": name + "-label", className: classBinder_cx('f-toggle__toggler'), disabled: isDisabled, id: name, role: "switch", type: "button", onClick: function (e) { return handleOnClick(e); } },
|
|
106745
106782
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("div", { className: "f-toggle__indicator" }, iconName && external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: iconName, size: "small" }))),
|
|
106746
106783
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("label", { "aria-checked": checked, className: "f-toggle__text", htmlFor: name, id: name + "-label" }, children)));
|
|
@@ -110474,10 +110511,10 @@ var MobilePanelContent = function (_a) {
|
|
|
110474
110511
|
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
110475
110512
|
// @ts-ignore
|
|
110476
110513
|
if ((event === null || event === void 0 ? void 0 : event.target.scrollTop) > scrolledLimit) {
|
|
110477
|
-
setIsScrolled(true);
|
|
110514
|
+
setIsScrolled && setIsScrolled(true);
|
|
110478
110515
|
}
|
|
110479
110516
|
else {
|
|
110480
|
-
setIsScrolled(false);
|
|
110517
|
+
setIsScrolled && setIsScrolled(false);
|
|
110481
110518
|
}
|
|
110482
110519
|
};
|
|
110483
110520
|
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(motion.div, { className: "l-mobilePanel__body", "data-testid": testId, variants: Content_content, onScroll: handleScroll }, children));
|
|
@@ -110655,10 +110692,15 @@ var Menu = function (_a) {
|
|
|
110655
110692
|
|
|
110656
110693
|
|
|
110657
110694
|
|
|
110695
|
+
|
|
110658
110696
|
var MenuItem = function (_a) {
|
|
110659
110697
|
var _b;
|
|
110660
|
-
var ariaLabel = _a.ariaLabel, badgeCount = _a.badgeCount, badgeCountAriaLabel = _a.badgeCountAriaLabel, children = _a.children, childrenTheme = _a.childrenTheme, hasCustomContent = _a.hasCustomContent, hide = _a.hide, iconName = _a.iconName, isButton = _a.isButton, isIconRight = _a.isIconRight, isOpen = _a.isOpen, isSelected = _a.isSelected, liTheme = _a.liTheme, linkTo = _a.linkTo, onClick = _a.onClick, target = _a.target, _c = _a.testId, testId = _c === void 0 ? 'MenuItem' : _c, title = _a.title;
|
|
110698
|
+
var ariaLabel = _a.ariaLabel, badgeCount = _a.badgeCount, badgeCountAriaLabel = _a.badgeCountAriaLabel, children = _a.children, childrenTheme = _a.childrenTheme, disabledTooltip = _a.disabledTooltip, hasCustomContent = _a.hasCustomContent, hide = _a.hide, iconName = _a.iconName, isButton = _a.isButton, isDisabled = _a.isDisabled, isIconRight = _a.isIconRight, isOpen = _a.isOpen, isSelected = _a.isSelected, liTheme = _a.liTheme, linkTo = _a.linkTo, onClick = _a.onClick, target = _a.target, _c = _a.testId, testId = _c === void 0 ? 'MenuItem' : _c, title = _a.title;
|
|
110661
110699
|
var handleOnClick = function (e) {
|
|
110700
|
+
if (isDisabled) {
|
|
110701
|
+
e.preventDefault();
|
|
110702
|
+
return;
|
|
110703
|
+
}
|
|
110662
110704
|
if (linkTo === '#') {
|
|
110663
110705
|
e.preventDefault();
|
|
110664
110706
|
}
|
|
@@ -110667,13 +110709,14 @@ var MenuItem = function (_a) {
|
|
|
110667
110709
|
}
|
|
110668
110710
|
};
|
|
110669
110711
|
var Component = linkTo ? 'a' : 'button';
|
|
110670
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("li", { className: classBinder_cx('m-menu__item', (_b = {},
|
|
110712
|
+
return hocs_withDisabledTooltip(isDisabled, disabledTooltip)(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("li", { className: classBinder_cx('m-menu__item', (_b = {},
|
|
110671
110713
|
_b["m-menu__item--button"] = isButton,
|
|
110672
110714
|
_b["m-menu__item--selected"] = isSelected,
|
|
110673
110715
|
_b["m-menu__item--open"] = isOpen,
|
|
110674
110716
|
_b["m-menu__item--hidden"] = hide,
|
|
110717
|
+
_b["m-menu__item--disabled"] = isDisabled,
|
|
110675
110718
|
_b["u-hide--" + hide] = hide,
|
|
110676
|
-
_b), liTheme), "data-testid": testId }, hasCustomContent ? (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["Fragment"], null, children)) : (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Component, { "aria-label": ariaLabel, "aria-pressed": isSelected && !linkTo, className: classBinder_cx(isButton ? 'c-btn' : 'm-menu__link', childrenTheme), href: linkTo || undefined, target: target, title: title, type: !linkTo || isButton ? 'button' : undefined, onClick: handleOnClick },
|
|
110719
|
+
_b), liTheme), "data-testid": testId }, hasCustomContent ? (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["Fragment"], null, children)) : (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Component, { "aria-disabled": isDisabled, "aria-label": ariaLabel, "aria-pressed": isSelected && !linkTo, className: classBinder_cx(isButton ? 'c-btn' : 'm-menu__link', childrenTheme), href: linkTo || undefined, target: target, title: title, type: !linkTo || isButton ? 'button' : undefined, onClick: handleOnClick },
|
|
110677
110720
|
iconName &&
|
|
110678
110721
|
(badgeCount ? (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Badge, { ariaLabel: badgeCountAriaLabel, count: badgeCount, theme: "u-mr--xSmall" },
|
|
110679
110722
|
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: iconName, theme: classBinder_cx(isIconRight && 'c-icon--r') }))) : (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(Icon, { name: iconName, theme: classBinder_cx(isIconRight ? 'c-icon--r' : 'c-icon--l') }))),
|
|
@@ -110802,6 +110845,7 @@ var TabsBar_assign = (undefined && undefined.__assign) || function () {
|
|
|
110802
110845
|
|
|
110803
110846
|
|
|
110804
110847
|
|
|
110848
|
+
|
|
110805
110849
|
var TabsBar = function (_a) {
|
|
110806
110850
|
var closeTabsBarOnOutsideClick = _a.closeTabsBarOnOutsideClick, dropdownPlacement = _a.dropdownPlacement, moreLabel = _a.moreLabel;
|
|
110807
110851
|
var _b = Object(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_["useContext"])(contexts_TabsContext), activeItem = _b.activeItem, identification = _b.identification, setActiveItem = _b.setActiveItem, tabs = _b.tabs, tabsLimit = _b.tabsLimit;
|
|
@@ -110862,9 +110906,8 @@ var TabsBar = function (_a) {
|
|
|
110862
110906
|
var renderBasicTabs = function () {
|
|
110863
110907
|
return tabs.map(function (tab, index) {
|
|
110864
110908
|
if (tabsLimit === 0 || index + 1 < tabsLimit)
|
|
110865
|
-
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("li", { key: identification + "_tab_listItem-" + index, className: classBinder_cx('c-tabs__listItem', { 'is-active': activeItem === index }) },
|
|
110866
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(
|
|
110867
|
-
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(TabListItem, TabsBar_assign({}, tab)))));
|
|
110909
|
+
return (external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("li", { key: identification + "_tab_listItem-" + index, className: classBinder_cx('c-tabs__listItem', { 'is-active': activeItem === index }) }, hocs_withDisabledTooltip(tab.isDisabled, tab.disabledTooltip)(external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement("button", { "aria-controls": identification + "-tabcontent" + index, "aria-selected": activeItem === index, className: classBinder_cx('c-tabs__listButton', { 'is-disabled': tab.isDisabled }), id: identification + "-tab" + index, role: "tab", tabIndex: activeItem === index ? 0 : -1, type: "button", onClick: tab.isDisabled ? noop : handleOnClick(index) },
|
|
110910
|
+
external_root_React_commonjs2_react_commonjs_react_amd_react_umd_react_default.a.createElement(TabListItem, TabsBar_assign({}, tab))))));
|
|
110868
110911
|
});
|
|
110869
110912
|
};
|
|
110870
110913
|
var renderMoreTabs = function () {
|
|
@@ -111035,6 +111078,7 @@ customPolyfills();
|
|
|
111035
111078
|
|
|
111036
111079
|
|
|
111037
111080
|
|
|
111081
|
+
|
|
111038
111082
|
/***/ }),
|
|
111039
111083
|
/* 1044 */
|
|
111040
111084
|
/***/ (function(module, __webpack_exports__, __webpack_require__) {
|