@itcase/ui 1.8.43 → 1.8.44
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/{Avatar_cjs_BbeDJ-No.js → Avatar_cjs_Bp8wjwGw.js} +8 -10
- package/dist/{Avatar_es_B1Ao9Im_.js → Avatar_es_BIKf0hNV.js} +7 -9
- package/dist/{Button_cjs_Bzx1GdT5.js → Button_cjs_Chn18eOU.js} +104 -10
- package/dist/{Button_es_DhCLxWhq.js → Button_es_XnWb2XF3.js} +103 -9
- package/dist/{ChipsGroup_cjs_p99H-9a8.js → ChipsGroup_cjs_Deoz_rju.js} +9 -9
- package/dist/{ChipsGroup_es_CWq3TR_1.js → ChipsGroup_es_C1Qi_5A1.js} +8 -8
- package/dist/{DatePicker_cjs_Cq8vqj3E.js → DatePicker_cjs_B24qHiks.js} +13 -16
- package/dist/{DatePicker_es_DYs71cnU.js → DatePicker_es_BuC8mEcK.js} +10 -13
- package/dist/{Divider_cjs_BmCJj3TN.js → Divider_cjs_rxMMBfLC.js} +3 -5
- package/dist/{Divider_es_kY-30pft.js → Divider_es_CiRU0sTz.js} +3 -5
- package/dist/{DropdownItem_cjs_B1gGciTB.js → DropdownItem_cjs_DuqySfbd.js} +6 -8
- package/dist/{DropdownItem_es_JVT4f6Nb.js → DropdownItem_es_BBxfR35q.js} +5 -7
- package/dist/{Group_cjs_Cwt0gWk4.js → Group_cjs_CDLfU5D2.js} +5 -8
- package/dist/{Group_es_CYW2Hquh.js → Group_es_DSZxyI1e.js} +5 -8
- package/dist/{Tooltip_cjs_BBwH8sjA.js → Icon_cjs_DRZih-pc.js} +588 -599
- package/dist/{Tooltip_es_Y2aoFQW7.js → Icon_es_k9bHSLyL.js} +588 -599
- package/dist/{Input_cjs_CPmXkQGd.js → Input_cjs_BGLd0EQu.js} +3 -5
- package/dist/{Input_es_D9Y1Rj5Y.js → Input_es_D2mNCqiH.js} +3 -5
- package/dist/{Label_cjs_Mb8j2bLu.js → Label_cjs_D70CHJDE.js} +6 -8
- package/dist/{Label_es_CIDBUVgO.js → Label_es_HXrap3A4.js} +5 -7
- package/dist/{Link_cjs_DbRGq2Yk.js → Link_cjs_BqT6eVl6.js} +2 -4
- package/dist/{Link_es_DxtZLeKY.js → Link_es_BnUIX0QT.js} +2 -4
- package/dist/{Loader_cjs_Ca4i0sER.js → Loader_cjs_BShrE-Nb.js} +5 -7
- package/dist/{Loader_es_GYOr0UTX.js → Loader_es_BDb87cdb.js} +5 -7
- package/dist/{Overlay_cjs_CFOtnzDU.js → Overlay_cjs_BMrkRg7M.js} +3 -5
- package/dist/{Overlay_es_DczPjVL9.js → Overlay_es_D_izIIUB.js} +3 -5
- package/dist/{Text_cjs_C9fOm0nd.js → Text_cjs_BlNeIm_v.js} +5 -7
- package/dist/{Text_es_BfLRfj-5.js → Text_es_Ffjr5J1k.js} +5 -7
- package/dist/cjs/components/Accordion.js +7 -9
- package/dist/cjs/components/Avatar.js +9 -8
- package/dist/cjs/components/AvatarStack.js +8 -10
- package/dist/cjs/components/Badge.js +11 -10
- package/dist/cjs/components/Breadcrumbs.js +6 -8
- package/dist/cjs/components/Button.js +11 -10
- package/dist/cjs/components/Cell.js +8 -10
- package/dist/cjs/components/Checkbox.js +4 -6
- package/dist/cjs/components/Checkmark.js +3 -5
- package/dist/cjs/components/Chips.js +4 -4
- package/dist/cjs/components/Choice.js +9 -11
- package/dist/cjs/components/Code.js +3 -5
- package/dist/cjs/components/CookiesWarning.js +12 -14
- package/dist/cjs/components/Dadata.js +2 -1
- package/dist/cjs/components/DatePeriod.js +12 -15
- package/dist/cjs/components/DatePicker.js +9 -8
- package/dist/cjs/components/Divider.js +4 -3
- package/dist/cjs/components/Drawer.js +13 -15
- package/dist/cjs/components/Dropdown.js +6 -5
- package/dist/cjs/components/Group.js +3 -2
- package/dist/cjs/components/HeroTitle.js +7 -9
- package/dist/cjs/components/Icon.js +11 -10
- package/dist/cjs/components/Input.js +3 -2
- package/dist/cjs/components/InputPassword.js +9 -11
- package/dist/cjs/components/Label.js +6 -5
- package/dist/cjs/components/Link.js +2 -1
- package/dist/cjs/components/List.js +4 -6
- package/dist/cjs/components/Loader.js +5 -4
- package/dist/cjs/components/Logo.js +4 -6
- package/dist/cjs/components/MenuItem.js +31 -10
- package/dist/cjs/components/Modal.js +10 -12
- package/dist/cjs/components/Notification.js +7 -9
- package/dist/cjs/components/Overlay.js +4 -3
- package/dist/cjs/components/Pagination.js +10 -12
- package/dist/cjs/components/Radio.js +4 -6
- package/dist/cjs/components/Response.js +8 -10
- package/dist/cjs/components/Search.js +7 -9
- package/dist/cjs/components/Segmented.js +12 -14
- package/dist/cjs/components/Select.js +15 -22
- package/dist/cjs/components/Swiper.js +5 -4
- package/dist/cjs/components/Switch.js +4 -6
- package/dist/cjs/components/Tab.js +8 -10
- package/dist/cjs/components/Text.js +4 -3
- package/dist/cjs/components/Textarea.js +3 -5
- package/dist/cjs/components/Tile.js +7 -9
- package/dist/cjs/components/Title.js +11 -10
- package/dist/cjs/components/Tooltip.js +11 -10
- package/dist/cjs/components/Warning.js +168 -0
- package/dist/cjs/hooks/useAppearanceConfig/useAppearanceConfig.js +4 -6
- package/dist/components/Accordion.js +6 -8
- package/dist/components/Avatar.js +9 -8
- package/dist/components/AvatarStack.js +8 -10
- package/dist/components/Badge.js +8 -7
- package/dist/components/Breadcrumbs.js +5 -7
- package/dist/components/Button.js +11 -10
- package/dist/components/Cell.js +7 -9
- package/dist/components/Checkbox.js +4 -6
- package/dist/components/Checkmark.js +3 -5
- package/dist/components/Chips.js +4 -4
- package/dist/components/Choice.js +7 -9
- package/dist/components/Code.js +3 -5
- package/dist/components/CookiesWarning.js +12 -14
- package/dist/components/Dadata.js +2 -1
- package/dist/components/DatePeriod.js +12 -15
- package/dist/components/DatePicker.js +9 -8
- package/dist/components/Divider.js +4 -3
- package/dist/components/Drawer.js +12 -14
- package/dist/components/Dropdown.js +6 -5
- package/dist/components/Group.js +3 -2
- package/dist/components/HeroTitle.js +6 -8
- package/dist/components/Icon.js +8 -7
- package/dist/components/Input.js +3 -2
- package/dist/components/InputPassword.js +8 -10
- package/dist/components/Label.js +6 -5
- package/dist/components/Link.js +2 -1
- package/dist/components/List.js +4 -6
- package/dist/components/Loader.js +5 -4
- package/dist/components/Logo.js +4 -6
- package/dist/components/MenuItem.js +29 -8
- package/dist/components/Modal.js +9 -11
- package/dist/components/Notification.js +6 -8
- package/dist/components/Overlay.js +4 -3
- package/dist/components/Pagination.js +8 -10
- package/dist/components/Radio.js +4 -6
- package/dist/components/Response.js +8 -10
- package/dist/components/Search.js +5 -7
- package/dist/components/Segmented.js +10 -12
- package/dist/components/Select.js +11 -18
- package/dist/components/Swiper.js +4 -3
- package/dist/components/Switch.js +4 -6
- package/dist/components/Tab.js +7 -9
- package/dist/components/Text.js +4 -3
- package/dist/components/Textarea.js +3 -5
- package/dist/components/Tile.js +6 -8
- package/dist/components/Title.js +8 -7
- package/dist/components/Tooltip.js +8 -7
- package/dist/components/Warning.js +164 -0
- package/dist/css/components/MenuItem/MenuItem.css +2 -2
- package/dist/css/components/Warning/Warning.css +52 -0
- package/dist/hooks/useAppearanceConfig/useAppearanceConfig.js +4 -6
- package/dist/stories/Overview.mdx +6 -6
- package/dist/stories/Playground.mdx +5 -5
- package/dist/types/components/Button/appearance/buttonAccent.d.ts +11 -0
- package/dist/types/components/Button/appearance/buttonDanger.d.ts +11 -0
- package/dist/types/components/Button/appearance/buttonError.d.ts +11 -0
- package/dist/types/components/Button/appearance/buttonInfo.d.ts +11 -0
- package/dist/types/components/Button/appearance/buttonPrimary.d.ts +10 -0
- package/dist/types/components/Button/appearance/buttonSecondary.d.ts +10 -0
- package/dist/types/components/Button/appearance/buttonSuccess.d.ts +11 -0
- package/dist/types/components/Button/appearance/buttonSurface.d.ts +10 -0
- package/dist/types/components/Button/appearance/buttonWarning.d.ts +11 -0
- package/dist/types/components/CookiesWarning/CookiesWarning.d.ts +1 -0
- package/dist/types/components/MenuItem/appearance/menuItemAccent.d.ts +8 -0
- package/dist/types/components/MenuItem/appearance/menuItemError.d.ts +7 -0
- package/dist/types/components/MenuItem/appearance/menuItemSurface.d.ts +8 -0
- package/dist/types/components/Warning/Warning.appearance.d.ts +101 -0
- package/dist/types/components/Warning/Warning.d.ts +4 -0
- package/dist/types/components/Warning/Warning.interface.d.ts +41 -0
- package/dist/types/components/Warning/appearance/warningAccent.d.ts +23 -0
- package/dist/types/components/Warning/appearance/warningError.d.ts +23 -0
- package/dist/types/components/Warning/appearance/warningInfo.d.ts +23 -0
- package/dist/types/components/Warning/appearance/warningSize.d.ts +11 -0
- package/dist/types/components/Warning/appearance/warningStyle.d.ts +14 -0
- package/dist/types/components/Warning/appearance/warningWarning.d.ts +23 -0
- package/dist/types/components/Warning/index.d.ts +2 -0
- package/dist/types/hooks/useAppearanceConfig/useAppearanceConfig.d.ts +1 -3
- package/package.json +1 -1
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var tslib_es6 = require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
4
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
5
4
|
var clsx = require('clsx');
|
|
5
|
+
var useAppearanceConfig = require('../hooks/useAppearanceConfig/useAppearanceConfig.js');
|
|
6
6
|
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
7
7
|
var useStyles = require('../hooks/useStyles/useStyles.js');
|
|
8
|
-
var
|
|
9
|
-
var Text = require('../../
|
|
8
|
+
var Icon = require('../../Icon_cjs_DRZih-pc.js');
|
|
9
|
+
var Text = require('../../Text_cjs_BlNeIm_v.js');
|
|
10
|
+
var tslib_es6 = require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
10
11
|
require('react');
|
|
11
12
|
require('lodash/camelCase');
|
|
12
13
|
require('lodash/castArray');
|
|
@@ -23,7 +24,7 @@ require('../hooks/useStyles/styleAttributes.js');
|
|
|
23
24
|
require('react-inlinesvg');
|
|
24
25
|
require('../hoc/urlWithAssetPrefix.js');
|
|
25
26
|
require('../context/UrlAssetPrefix.js');
|
|
26
|
-
require('../../
|
|
27
|
+
require('../../Link_cjs_BqT6eVl6.js');
|
|
27
28
|
|
|
28
29
|
var tileAppearanceSize = {
|
|
29
30
|
sizeXL: {
|
|
@@ -137,15 +138,12 @@ var tileConfig = {
|
|
|
137
138
|
};
|
|
138
139
|
function Tile(props) {
|
|
139
140
|
var className = props.className, type = props.type, appearance = props.appearance, direction = props.direction, title = props.title, desc = props.desc, badgeValue = props.badgeValue, reverse = props.reverse, before = props.before, after = props.after, isSkeleton = props.isSkeleton, onClick = props.onClick, children = props.children;
|
|
140
|
-
var appearanceConfig =
|
|
141
|
-
var _a;
|
|
142
|
-
return (tslib_es6.__assign(tslib_es6.__assign({}, resultConfig), (_a = tileConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
143
|
-
}, {});
|
|
141
|
+
var appearanceConfig = useAppearanceConfig.useAppearanceConfig(appearance, tileConfig);
|
|
144
142
|
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
145
143
|
var alignClass = propsGenerator.alignClass, _a = propsGenerator.alignDirectionClass, alignDirectionClass = _a === void 0 ? 'vertical' : _a, fillClass = propsGenerator.fillClass, titleTextAlign = propsGenerator.titleTextAlign, titleTextColor = propsGenerator.titleTextColor, titleTextSize = propsGenerator.titleTextSize, titleTextWeight = propsGenerator.titleTextWeight, titleTextWrap = propsGenerator.titleTextWrap, descTextColor = propsGenerator.descTextColor, descTextSize = propsGenerator.descTextSize, descTextWrap = propsGenerator.descTextWrap, borderColorClass = propsGenerator.borderColorClass, borderColorHoverClass = propsGenerator.borderColorHoverClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, badgeAppearance = propsGenerator.badgeAppearance, badgeAppearanceSize = propsGenerator.badgeAppearanceSize, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, dataTestId = propsGenerator.dataTestId, dataTour = propsGenerator.dataTour, icon = propsGenerator.icon, iconAppearance = propsGenerator.iconAppearance, iconFill = propsGenerator.iconFill, iconFillIcon = propsGenerator.iconFillIcon, iconFillSize = propsGenerator.iconFillSize, iconShape = propsGenerator.iconShape, iconSize = propsGenerator.iconSize, iconSrc = propsGenerator.iconSrc, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass;
|
|
146
144
|
// @ts-expect-error
|
|
147
145
|
var tileStyles = useStyles.useStyles(props).styles;
|
|
148
|
-
return (jsxRuntime.jsx("div", { className: clsx('tile', className, fillClass && "fill_".concat(fillClass), shapeClass && "tile_shape_".concat(shapeClass), alignClass && "align_".concat(alignClass), alignDirectionClass && "align_".concat(alignDirectionClass), direction && "direction_".concat(direction), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), reverse && 'tile_reverse', sizeClass && "tile_size_".concat(sizeClass), type && "tile_type_".concat(type), badgeValue && "tile_state_badge", isSkeleton && "tile_skeleton"), "data-testid": dataTestId, "data-tour": dataTour, style: tileStyles, onClick: onClick, children: jsxRuntime.jsxs("div", { className: clsx('tile__wrapper', alignClass, alignDirectionClass), children: [before, jsxRuntime.jsxs("div", { className: "tile__header", children: [jsxRuntime.jsxs("div", { className: "tile__header-inner", children: [title && (jsxRuntime.jsx(
|
|
146
|
+
return (jsxRuntime.jsx("div", { className: clsx('tile', className, fillClass && "fill_".concat(fillClass), shapeClass && "tile_shape_".concat(shapeClass), alignClass && "align_".concat(alignClass), alignDirectionClass && "align_".concat(alignDirectionClass), direction && "direction_".concat(direction), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), reverse && 'tile_reverse', sizeClass && "tile_size_".concat(sizeClass), type && "tile_type_".concat(type), badgeValue && "tile_state_badge", isSkeleton && "tile_skeleton"), "data-testid": dataTestId, "data-tour": dataTour, style: tileStyles, onClick: onClick, children: jsxRuntime.jsxs("div", { className: clsx('tile__wrapper', alignClass, alignDirectionClass), children: [before, jsxRuntime.jsxs("div", { className: "tile__header", children: [jsxRuntime.jsxs("div", { className: "tile__header-inner", children: [title && (jsxRuntime.jsx(Icon.Title, { className: "tile__title", size: titleTextSize, textAlign: titleTextAlign, textColor: titleTextColor, textWeight: titleTextWeight, textWrap: titleTextWrap, children: title })), desc && (jsxRuntime.jsx(Text.Text, { className: "tile__text", size: descTextSize, textColor: descTextColor, textWrap: descTextWrap, children: desc }))] }), jsxRuntime.jsxs("div", { className: "tile__header-actions", children: [badgeValue && (jsxRuntime.jsx(Icon.Badge, { className: "tile__badge", appearance: "".concat(badgeAppearance, " ").concat(badgeAppearanceSize), size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), (icon || iconSrc) && (jsxRuntime.jsx(Icon.Icon, { className: clsx('tile__icon'), appearance: iconAppearance, fill: iconFill, fillSize: iconFillSize, iconFill: iconFillIcon, iconSize: iconSize, imageSrc: iconSrc, shape: iconShape, SvgImage: icon }))] })] }), children, after] }) }));
|
|
149
147
|
}
|
|
150
148
|
|
|
151
149
|
exports.Tile = Tile;
|
|
@@ -1,17 +1,21 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var Icon = require('../../Icon_cjs_DRZih-pc.js');
|
|
4
4
|
require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
5
5
|
require('react/jsx-runtime');
|
|
6
6
|
require('react');
|
|
7
7
|
require('clsx');
|
|
8
|
+
require('react-inlinesvg');
|
|
9
|
+
require('../hoc/urlWithAssetPrefix.js');
|
|
10
|
+
require('@itcase/common');
|
|
11
|
+
require('../context/UrlAssetPrefix.js');
|
|
12
|
+
require('../hooks/useAppearanceConfig/useAppearanceConfig.js');
|
|
8
13
|
require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
9
14
|
require('lodash/camelCase');
|
|
10
15
|
require('lodash/castArray');
|
|
11
16
|
require('lodash/upperFirst');
|
|
12
17
|
require('../context/Notifications.js');
|
|
13
18
|
require('uuid');
|
|
14
|
-
require('@itcase/common');
|
|
15
19
|
require('../context/UIContext.js');
|
|
16
20
|
require('../hooks/useMediaQueries/useMediaQueries.js');
|
|
17
21
|
require('react-responsive');
|
|
@@ -19,14 +23,11 @@ require('../utils/setViewportProperty.js');
|
|
|
19
23
|
require('../hooks/useStyles/useStyles.js');
|
|
20
24
|
require('lodash/maxBy');
|
|
21
25
|
require('../hooks/useStyles/styleAttributes.js');
|
|
22
|
-
require('../../
|
|
23
|
-
require('
|
|
24
|
-
require('../hoc/urlWithAssetPrefix.js');
|
|
25
|
-
require('../context/UrlAssetPrefix.js');
|
|
26
|
-
require('../../Link_cjs_DbRGq2Yk.js');
|
|
26
|
+
require('../../Link_cjs_BqT6eVl6.js');
|
|
27
|
+
require('../../Text_cjs_BlNeIm_v.js');
|
|
27
28
|
|
|
28
29
|
|
|
29
30
|
|
|
30
|
-
exports.Title =
|
|
31
|
-
exports.titleAppearance =
|
|
32
|
-
exports.titleConfig =
|
|
31
|
+
exports.Title = Icon.Title;
|
|
32
|
+
exports.titleAppearance = Icon.titleAppearance;
|
|
33
|
+
exports.titleConfig = Icon.titleConfig;
|
|
@@ -1,17 +1,21 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var Icon = require('../../Icon_cjs_DRZih-pc.js');
|
|
4
4
|
require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
5
5
|
require('react/jsx-runtime');
|
|
6
6
|
require('react');
|
|
7
7
|
require('clsx');
|
|
8
|
+
require('react-inlinesvg');
|
|
9
|
+
require('../hoc/urlWithAssetPrefix.js');
|
|
10
|
+
require('@itcase/common');
|
|
11
|
+
require('../context/UrlAssetPrefix.js');
|
|
12
|
+
require('../hooks/useAppearanceConfig/useAppearanceConfig.js');
|
|
8
13
|
require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
9
14
|
require('lodash/camelCase');
|
|
10
15
|
require('lodash/castArray');
|
|
11
16
|
require('lodash/upperFirst');
|
|
12
17
|
require('../context/Notifications.js');
|
|
13
18
|
require('uuid');
|
|
14
|
-
require('@itcase/common');
|
|
15
19
|
require('../context/UIContext.js');
|
|
16
20
|
require('../hooks/useMediaQueries/useMediaQueries.js');
|
|
17
21
|
require('react-responsive');
|
|
@@ -19,14 +23,11 @@ require('../utils/setViewportProperty.js');
|
|
|
19
23
|
require('../hooks/useStyles/useStyles.js');
|
|
20
24
|
require('lodash/maxBy');
|
|
21
25
|
require('../hooks/useStyles/styleAttributes.js');
|
|
22
|
-
require('../../
|
|
23
|
-
require('
|
|
24
|
-
require('../hoc/urlWithAssetPrefix.js');
|
|
25
|
-
require('../context/UrlAssetPrefix.js');
|
|
26
|
-
require('../../Link_cjs_DbRGq2Yk.js');
|
|
26
|
+
require('../../Link_cjs_BqT6eVl6.js');
|
|
27
|
+
require('../../Text_cjs_BlNeIm_v.js');
|
|
27
28
|
|
|
28
29
|
|
|
29
30
|
|
|
30
|
-
exports.Tooltip =
|
|
31
|
-
exports.tooltipAppearance =
|
|
32
|
-
exports.tooltipConfig =
|
|
31
|
+
exports.Tooltip = Icon.Tooltip;
|
|
32
|
+
exports.tooltipAppearance = Icon.tooltipAppearance;
|
|
33
|
+
exports.tooltipConfig = Icon.tooltipConfig;
|
|
@@ -0,0 +1,168 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
+
var React = require('react');
|
|
5
|
+
var clsx = require('clsx');
|
|
6
|
+
var Icon = require('../../Icon_cjs_DRZih-pc.js');
|
|
7
|
+
var Text = require('../../Text_cjs_BlNeIm_v.js');
|
|
8
|
+
var useAppearanceConfig = require('../hooks/useAppearanceConfig/useAppearanceConfig.js');
|
|
9
|
+
var useDevicePropsGenerator = require('../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
10
|
+
var useStyles = require('../hooks/useStyles/useStyles.js');
|
|
11
|
+
var tslib_es6 = require('../../tslib.es6_cjs_CCZ3TN_7.js');
|
|
12
|
+
var _default = require('@itcase/icons/default');
|
|
13
|
+
require('react-inlinesvg');
|
|
14
|
+
require('../hoc/urlWithAssetPrefix.js');
|
|
15
|
+
require('@itcase/common');
|
|
16
|
+
require('../context/UrlAssetPrefix.js');
|
|
17
|
+
require('../../Link_cjs_BqT6eVl6.js');
|
|
18
|
+
require('lodash/camelCase');
|
|
19
|
+
require('lodash/castArray');
|
|
20
|
+
require('lodash/upperFirst');
|
|
21
|
+
require('../context/Notifications.js');
|
|
22
|
+
require('uuid');
|
|
23
|
+
require('../context/UIContext.js');
|
|
24
|
+
require('../hooks/useMediaQueries/useMediaQueries.js');
|
|
25
|
+
require('react-responsive');
|
|
26
|
+
require('../utils/setViewportProperty.js');
|
|
27
|
+
require('lodash/maxBy');
|
|
28
|
+
require('../hooks/useStyles/styleAttributes.js');
|
|
29
|
+
|
|
30
|
+
var warningAppearanceAccent = {
|
|
31
|
+
accentMutedPrimary: {
|
|
32
|
+
fill: 'accentTertiary',
|
|
33
|
+
labelTextColor: 'accentTextQuaternary',
|
|
34
|
+
descriptionTextColor: 'accentTextQuaternary',
|
|
35
|
+
borderColor: 'accentBorderSecondary',
|
|
36
|
+
iconAfter: _default.icons16.Action.Close,
|
|
37
|
+
iconAfterFillIcon: 'accentItemQuaternary',
|
|
38
|
+
iconBefore: _default.icons16.Alert.Warning,
|
|
39
|
+
iconBeforeFillIcon: 'accentItemQuaternary',
|
|
40
|
+
},
|
|
41
|
+
accentPrimary: {
|
|
42
|
+
fill: 'accentPrimary',
|
|
43
|
+
labelTextColor: 'accentTextPrimary',
|
|
44
|
+
descriptionTextColor: 'accentTextPrimary',
|
|
45
|
+
borderColor: 'accentBorderQuaternary',
|
|
46
|
+
iconAfter: _default.icons16.Action.Close,
|
|
47
|
+
iconAfterFillIcon: 'accentItemPrimary',
|
|
48
|
+
iconBefore: _default.icons16.Alert.Warning,
|
|
49
|
+
iconBeforeFillIcon: 'accentItemPrimary',
|
|
50
|
+
},
|
|
51
|
+
};
|
|
52
|
+
|
|
53
|
+
var warningAppearanceError = {
|
|
54
|
+
errorMutedPrimary: {
|
|
55
|
+
fill: 'errorTertiary',
|
|
56
|
+
labelTextColor: 'errorTextQuaternary',
|
|
57
|
+
descriptionTextColor: 'errorTextQuaternary',
|
|
58
|
+
borderColor: 'errorBorderSecondary',
|
|
59
|
+
iconAfter: _default.icons16.Action.Close,
|
|
60
|
+
iconAfterFillIcon: 'errorItemQuaternary',
|
|
61
|
+
iconBefore: _default.icons16.Action.Block,
|
|
62
|
+
iconBeforeFillIcon: 'errorItemQuaternary',
|
|
63
|
+
},
|
|
64
|
+
errorPrimary: {
|
|
65
|
+
fill: 'errorPrimary',
|
|
66
|
+
labelTextColor: 'errorTextPrimary',
|
|
67
|
+
descriptionTextColor: 'errorTextPrimary',
|
|
68
|
+
borderColor: 'errorBorderQuaternary',
|
|
69
|
+
iconAfter: _default.icons16.Action.Close,
|
|
70
|
+
iconAfterFillIcon: 'errorItemPrimary',
|
|
71
|
+
iconBefore: _default.icons16.Action.Block,
|
|
72
|
+
iconBeforeFillIcon: 'errorItemPrimary',
|
|
73
|
+
},
|
|
74
|
+
};
|
|
75
|
+
|
|
76
|
+
var warningAppearanceInfo = {
|
|
77
|
+
infoMutedPrimary: {
|
|
78
|
+
fill: 'infoTertiary',
|
|
79
|
+
labelTextColor: 'infoTextSecondary',
|
|
80
|
+
descriptionTextColor: 'infoTextSecondary',
|
|
81
|
+
borderColor: 'infoBorderSecondary',
|
|
82
|
+
iconAfter: _default.icons16.Action.Close,
|
|
83
|
+
iconAfterFillIcon: 'infoItemQuaternary',
|
|
84
|
+
iconBefore: _default.icons16.Alert.Warning,
|
|
85
|
+
iconBeforeFillIcon: 'infoItemQuaternary',
|
|
86
|
+
},
|
|
87
|
+
infoPrimary: {
|
|
88
|
+
fill: 'infoPrimary',
|
|
89
|
+
labelTextColor: 'infoTextPrimary',
|
|
90
|
+
descriptionTextColor: 'infoTextPrimary',
|
|
91
|
+
borderColor: 'infoBorderSecondary',
|
|
92
|
+
iconAfter: _default.icons16.Action.Close,
|
|
93
|
+
iconAfterFillIcon: 'infoItemPrimary',
|
|
94
|
+
iconBefore: _default.icons16.Alert.Warning,
|
|
95
|
+
iconBeforeFillIcon: 'infoItemPrimary',
|
|
96
|
+
},
|
|
97
|
+
};
|
|
98
|
+
|
|
99
|
+
var warningAppearanceSize = {
|
|
100
|
+
sizeL: {
|
|
101
|
+
size: 'l',
|
|
102
|
+
labelTextSize: 's',
|
|
103
|
+
labelTextWeight: '600',
|
|
104
|
+
descriptionTextSize: 's',
|
|
105
|
+
iconAfterSize: '16',
|
|
106
|
+
iconBeforeSize: '16',
|
|
107
|
+
},
|
|
108
|
+
};
|
|
109
|
+
|
|
110
|
+
var warningAppearanceStyle = {
|
|
111
|
+
solid: {
|
|
112
|
+
borderColor: 'none',
|
|
113
|
+
},
|
|
114
|
+
outlined: {
|
|
115
|
+
fill: 'none',
|
|
116
|
+
},
|
|
117
|
+
full: {},
|
|
118
|
+
ghost: {
|
|
119
|
+
fill: 'none',
|
|
120
|
+
borderColor: 'none',
|
|
121
|
+
},
|
|
122
|
+
};
|
|
123
|
+
|
|
124
|
+
var warningAppearanceWarning = {
|
|
125
|
+
warningMutedPrimary: {
|
|
126
|
+
fill: 'warningTertiary',
|
|
127
|
+
labelTextColor: 'warningTextSecondary',
|
|
128
|
+
descriptionTextColor: 'warningTextSecondary',
|
|
129
|
+
borderColor: 'warningBorderSecondary',
|
|
130
|
+
iconAfter: _default.icons16.Action.Close,
|
|
131
|
+
iconAfterFillIcon: 'warningItemSecondary',
|
|
132
|
+
iconBefore: _default.icons16.Alert.WarningTriangle,
|
|
133
|
+
iconBeforeFillIcon: 'warningItemSecondary',
|
|
134
|
+
},
|
|
135
|
+
warningPrimary: {
|
|
136
|
+
fill: 'warningPrimary',
|
|
137
|
+
labelTextColor: 'warningTextPrimary',
|
|
138
|
+
descriptionTextColor: 'warningTextPrimary',
|
|
139
|
+
borderColor: 'warningBorderSecondary',
|
|
140
|
+
iconAfter: _default.icons16.Action.Close,
|
|
141
|
+
iconAfterFillIcon: 'warningItemPrimary',
|
|
142
|
+
iconBefore: _default.icons16.Alert.WarningTriangle,
|
|
143
|
+
iconBeforeFillIcon: 'warningItemPrimary',
|
|
144
|
+
},
|
|
145
|
+
};
|
|
146
|
+
|
|
147
|
+
var warningAppearance = tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign(tslib_es6.__assign({}, warningAppearanceAccent), warningAppearanceWarning), warningAppearanceError), warningAppearanceInfo), warningAppearanceStyle), warningAppearanceSize);
|
|
148
|
+
|
|
149
|
+
var warningConfig = {
|
|
150
|
+
appearance: warningAppearance,
|
|
151
|
+
setAppearance: function (appearanceConfig) {
|
|
152
|
+
warningConfig.appearance = appearanceConfig;
|
|
153
|
+
},
|
|
154
|
+
};
|
|
155
|
+
function Warning(props) {
|
|
156
|
+
var className = props.className, appearance = props.appearance, label = props.label, description = props.description, shape = props.shape, isSkeleton = props.isSkeleton;
|
|
157
|
+
var appearanceConfig = useAppearanceConfig.useAppearanceConfig(appearance, warningConfig);
|
|
158
|
+
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
159
|
+
var fillClass = propsGenerator.fillClass, labelTextColor = propsGenerator.labelTextColor, labelTextSize = propsGenerator.labelTextSize, labelTextWeight = propsGenerator.labelTextWeight, descriptionTextColor = propsGenerator.descriptionTextColor, descriptionTextSize = propsGenerator.descriptionTextSize, borderColorClass = propsGenerator.borderColorClass, iconAfter = propsGenerator.iconAfter, iconAfterFill = propsGenerator.iconAfterFill, iconAfterFillIcon = propsGenerator.iconAfterFillIcon, iconAfterSize = propsGenerator.iconAfterSize, iconAfterSrc = propsGenerator.iconAfterSrc, iconBefore = propsGenerator.iconBefore, iconBeforeFill = propsGenerator.iconBeforeFill, iconBeforeFillIcon = propsGenerator.iconBeforeFillIcon, iconBeforeSize = propsGenerator.iconBeforeSize, iconBeforeSrc = propsGenerator.iconBeforeSrc, sizeClass = propsGenerator.sizeClass;
|
|
160
|
+
// @ts-ignore
|
|
161
|
+
var warningStyles = useStyles.useStyles(props).styles;
|
|
162
|
+
var _a = React.useState(true), isVisible = _a[0], setIsVisible = _a[1];
|
|
163
|
+
return (jsxRuntime.jsx(React.Fragment, { children: isVisible && (jsxRuntime.jsxs("div", { className: clsx(className, 'warning', fillClass && "fill_".concat(fillClass), sizeClass && "warning_size_".concat(sizeClass), borderColorClass && "border-color_".concat(borderColorClass), shape && "warning_shape_".concat(shape), isSkeleton && "warning_skeleton"), style: warningStyles, children: [(iconBefore || iconBeforeSrc) && (jsxRuntime.jsx(Icon.Icon, { fill: iconBeforeFill, iconFill: iconBeforeFillIcon, iconSize: iconBeforeSize, imageSrc: iconBeforeSrc, SvgImage: iconBefore })), jsxRuntime.jsxs("div", { className: 'warning__content', children: [label && (jsxRuntime.jsx(Text.Text, { size: labelTextSize, textColor: labelTextColor, textWeight: labelTextWeight, children: label })), description && (jsxRuntime.jsx(Text.Text, { size: descriptionTextSize, textColor: descriptionTextColor, children: description }))] }), (iconAfter || iconAfterSrc) && (jsxRuntime.jsx(Icon.Icon, { fill: iconAfterFill, iconFill: iconAfterFillIcon, iconSize: iconAfterSize, imageSrc: iconAfterSrc, SvgImage: iconAfter, onClick: function () { return setIsVisible(false); } }))] })) }));
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
exports.Warning = Warning;
|
|
167
|
+
exports.warningAppearance = warningAppearance;
|
|
168
|
+
exports.warningConfig = warningConfig;
|
|
@@ -5,25 +5,23 @@ var React = require('react');
|
|
|
5
5
|
|
|
6
6
|
var useAppearanceConfig = function (appearance, componentConfig, isDisabled) {
|
|
7
7
|
var appearanceConfig = React.useMemo(function () {
|
|
8
|
-
var _a, _b;
|
|
8
|
+
var _a, _b, _c;
|
|
9
9
|
if (appearance) {
|
|
10
10
|
var appearanceProps = appearance.split(' ').reduce(function (resultConfig, appearanceKey) {
|
|
11
11
|
var _a;
|
|
12
12
|
return (tslib_es6.__assign(tslib_es6.__assign({}, resultConfig), (_a = componentConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
13
13
|
}, {});
|
|
14
14
|
if (isDisabled && ((_a = componentConfig === null || componentConfig === void 0 ? void 0 : componentConfig.appearance) === null || _a === void 0 ? void 0 : _a.disabled)) {
|
|
15
|
-
Object.assign(appearanceProps, componentConfig.appearance.disabled);
|
|
15
|
+
Object.assign(appearanceProps, (_b = componentConfig === null || componentConfig === void 0 ? void 0 : componentConfig.appearance) === null || _b === void 0 ? void 0 : _b.disabled);
|
|
16
16
|
}
|
|
17
17
|
return appearanceProps;
|
|
18
18
|
}
|
|
19
19
|
if (isDisabled) {
|
|
20
|
-
return (
|
|
20
|
+
return (_c = componentConfig === null || componentConfig === void 0 ? void 0 : componentConfig.appearance) === null || _c === void 0 ? void 0 : _c.disabled;
|
|
21
21
|
}
|
|
22
22
|
return {};
|
|
23
23
|
}, [appearance, componentConfig === null || componentConfig === void 0 ? void 0 : componentConfig.appearance, isDisabled]);
|
|
24
|
-
return
|
|
25
|
-
appearanceConfig: appearanceConfig,
|
|
26
|
-
};
|
|
24
|
+
return appearanceConfig;
|
|
27
25
|
};
|
|
28
26
|
|
|
29
27
|
exports.useAppearanceConfig = useAppearanceConfig;
|
|
@@ -5,9 +5,10 @@ import clsx from 'clsx';
|
|
|
5
5
|
import castArray from 'lodash/castArray';
|
|
6
6
|
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
7
7
|
import { useStyles } from '../hooks/useStyles/useStyles.js';
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
8
|
+
import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
9
|
+
import { B as Badge, I as Icon } from '../Icon_es_k9bHSLyL.js';
|
|
10
|
+
import { D as Divider } from '../Divider_es_CiRU0sTz.js';
|
|
11
|
+
import { T as Text } from '../Text_es_Ffjr5J1k.js';
|
|
11
12
|
import { icons16 } from '@itcase/icons/default';
|
|
12
13
|
import 'lodash/camelCase';
|
|
13
14
|
import 'lodash/upperFirst';
|
|
@@ -23,7 +24,7 @@ import '../hooks/useStyles/styleAttributes.js';
|
|
|
23
24
|
import 'react-inlinesvg';
|
|
24
25
|
import '../hoc/urlWithAssetPrefix.js';
|
|
25
26
|
import '../context/UrlAssetPrefix.js';
|
|
26
|
-
import '../
|
|
27
|
+
import '../Link_es_BnUIX0QT.js';
|
|
27
28
|
|
|
28
29
|
var accordionAppearanceSize = {
|
|
29
30
|
sizeXXL: {
|
|
@@ -146,10 +147,7 @@ function AccordionItem(props) {
|
|
|
146
147
|
};
|
|
147
148
|
onClick && onClick(thisItemData);
|
|
148
149
|
}, [id, title, content, isExpanded, onClick]);
|
|
149
|
-
var appearanceConfig = appearance
|
|
150
|
-
var _a;
|
|
151
|
-
return (__assign(__assign({}, resultConfig), (_a = accordionItemConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
152
|
-
}, {});
|
|
150
|
+
var appearanceConfig = useAppearanceConfig(appearance, accordionItemConfig);
|
|
153
151
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
154
152
|
var fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, titleBorderColorClass = propsGenerator.titleBorderColorClass, titleFillClass = propsGenerator.titleFillClass, titleFillHoverClass = propsGenerator.titleFillHoverClass, titleTextColor = propsGenerator.titleTextColor, titleTextSize = propsGenerator.titleTextSize, titleTextWeight = propsGenerator.titleTextWeight, titleWidthClass = propsGenerator.titleWidthClass, borderColorClass = propsGenerator.borderColorClass, badgeAppearance = propsGenerator.badgeAppearance, badgeAppearanceSize = propsGenerator.badgeAppearanceSize, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, badgeValue = propsGenerator.badgeValue, contentTextColor = propsGenerator.contentTextColor, contentTextSize = propsGenerator.contentTextSize, contentTextWeight = propsGenerator.contentTextWeight, dividerDirection = propsGenerator.dividerDirection, dividerFill = propsGenerator.dividerFill, dividerSize = propsGenerator.dividerSize, icon = propsGenerator.icon, iconFill = propsGenerator.iconFill, iconFillIcon = propsGenerator.iconFillIcon, iconFillSize = propsGenerator.iconFillSize, iconShape = propsGenerator.iconShape, iconSize = propsGenerator.iconSize, iconSrc = propsGenerator.iconSrc, shapeClass = propsGenerator.shapeClass, showDivider = propsGenerator.showDivider, sizeClass = propsGenerator.sizeClass, zeroGap = propsGenerator.zeroGap, zeroPadding = propsGenerator.zeroPadding;
|
|
155
153
|
// @ts-expect-error
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
export { A as Avatar, b as avatarAppearance, a as avatarConfig } from '../
|
|
2
|
-
import '../tslib.es6_es_Bwu1Cn-t.js';
|
|
1
|
+
export { A as Avatar, b as avatarAppearance, a as avatarConfig } from '../Avatar_es_BIKf0hNV.js';
|
|
3
2
|
import 'react/jsx-runtime';
|
|
4
3
|
import 'react';
|
|
5
4
|
import 'clsx';
|
|
5
|
+
import '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
6
|
+
import '../tslib.es6_es_Bwu1Cn-t.js';
|
|
6
7
|
import '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
7
8
|
import 'lodash/camelCase';
|
|
8
9
|
import 'lodash/castArray';
|
|
@@ -14,13 +15,13 @@ import '../context/UIContext.js';
|
|
|
14
15
|
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
15
16
|
import 'react-responsive';
|
|
16
17
|
import '../utils/setViewportProperty.js';
|
|
17
|
-
import '../
|
|
18
|
-
import '../hooks/useStyles/useStyles.js';
|
|
19
|
-
import 'lodash/maxBy';
|
|
20
|
-
import '../hooks/useStyles/styleAttributes.js';
|
|
21
|
-
import '../Text_es_BfLRfj-5.js';
|
|
18
|
+
import '../Icon_es_k9bHSLyL.js';
|
|
22
19
|
import 'react-inlinesvg';
|
|
23
20
|
import '../hoc/urlWithAssetPrefix.js';
|
|
24
21
|
import '../context/UrlAssetPrefix.js';
|
|
25
|
-
import '../
|
|
22
|
+
import '../hooks/useStyles/useStyles.js';
|
|
23
|
+
import 'lodash/maxBy';
|
|
24
|
+
import '../hooks/useStyles/styleAttributes.js';
|
|
25
|
+
import '../Link_es_BnUIX0QT.js';
|
|
26
|
+
import '../Text_es_Ffjr5J1k.js';
|
|
26
27
|
import '../Image_es_ChF-63wh.js';
|
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
2
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
3
2
|
import clsx from 'clsx';
|
|
3
|
+
import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
4
4
|
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
5
5
|
import { useStyles } from '../hooks/useStyles/useStyles.js';
|
|
6
|
-
import { A as Avatar } from '../
|
|
7
|
-
import { G as Group } from '../
|
|
8
|
-
import { T as Text } from '../
|
|
6
|
+
import { A as Avatar } from '../Avatar_es_BIKf0hNV.js';
|
|
7
|
+
import { G as Group } from '../Group_es_DSZxyI1e.js';
|
|
8
|
+
import { T as Text } from '../Text_es_Ffjr5J1k.js';
|
|
9
|
+
import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
9
10
|
import 'react';
|
|
10
11
|
import 'lodash/camelCase';
|
|
11
12
|
import 'lodash/castArray';
|
|
@@ -19,11 +20,11 @@ import 'react-responsive';
|
|
|
19
20
|
import '../utils/setViewportProperty.js';
|
|
20
21
|
import 'lodash/maxBy';
|
|
21
22
|
import '../hooks/useStyles/styleAttributes.js';
|
|
22
|
-
import '../
|
|
23
|
+
import '../Icon_es_k9bHSLyL.js';
|
|
23
24
|
import 'react-inlinesvg';
|
|
24
25
|
import '../hoc/urlWithAssetPrefix.js';
|
|
25
26
|
import '../context/UrlAssetPrefix.js';
|
|
26
|
-
import '../
|
|
27
|
+
import '../Link_es_BnUIX0QT.js';
|
|
27
28
|
import '../Image_es_ChF-63wh.js';
|
|
28
29
|
|
|
29
30
|
var avatarStackAppearanceSize = {
|
|
@@ -53,10 +54,7 @@ var avatarStackConfig = {
|
|
|
53
54
|
appearance: avatarStackAppearance};
|
|
54
55
|
function AvatarStack(props) {
|
|
55
56
|
var className = props.className, appearance = props.appearance, _a = props.direction, direction = _a === void 0 ? 'horizontal' : _a, avatarAppearance = props.avatarAppearance, avatarsList = props.avatarsList, _b = props.length, length = _b === void 0 ? 3 : _b, isSkeleton = props.isSkeleton;
|
|
56
|
-
var appearanceConfig = appearance
|
|
57
|
-
var _a;
|
|
58
|
-
return (__assign(__assign({}, resultConfig), (_a = avatarStackConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
59
|
-
}, {});
|
|
57
|
+
var appearanceConfig = useAppearanceConfig(appearance, avatarStackConfig);
|
|
60
58
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
61
59
|
// "size" is numeric
|
|
62
60
|
var size = propsGenerator.size;
|
package/dist/components/Badge.js
CHANGED
|
@@ -1,15 +1,19 @@
|
|
|
1
|
-
export { B as Badge, f as badgeAppearance, g as badgeConfig } from '../
|
|
1
|
+
export { B as Badge, f as badgeAppearance, g as badgeConfig } from '../Icon_es_k9bHSLyL.js';
|
|
2
2
|
import '../tslib.es6_es_Bwu1Cn-t.js';
|
|
3
3
|
import 'react/jsx-runtime';
|
|
4
4
|
import 'react';
|
|
5
5
|
import 'clsx';
|
|
6
|
+
import 'react-inlinesvg';
|
|
7
|
+
import '../hoc/urlWithAssetPrefix.js';
|
|
8
|
+
import '@itcase/common';
|
|
9
|
+
import '../context/UrlAssetPrefix.js';
|
|
10
|
+
import '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
6
11
|
import '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
7
12
|
import 'lodash/camelCase';
|
|
8
13
|
import 'lodash/castArray';
|
|
9
14
|
import 'lodash/upperFirst';
|
|
10
15
|
import '../context/Notifications.js';
|
|
11
16
|
import 'uuid';
|
|
12
|
-
import '@itcase/common';
|
|
13
17
|
import '../context/UIContext.js';
|
|
14
18
|
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
15
19
|
import 'react-responsive';
|
|
@@ -17,8 +21,5 @@ import '../utils/setViewportProperty.js';
|
|
|
17
21
|
import '../hooks/useStyles/useStyles.js';
|
|
18
22
|
import 'lodash/maxBy';
|
|
19
23
|
import '../hooks/useStyles/styleAttributes.js';
|
|
20
|
-
import '../
|
|
21
|
-
import '
|
|
22
|
-
import '../hoc/urlWithAssetPrefix.js';
|
|
23
|
-
import '../context/UrlAssetPrefix.js';
|
|
24
|
-
import '../Link_es_DxtZLeKY.js';
|
|
24
|
+
import '../Link_es_BnUIX0QT.js';
|
|
25
|
+
import '../Text_es_Ffjr5J1k.js';
|
|
@@ -3,10 +3,11 @@ import { useMemo } from 'react';
|
|
|
3
3
|
import clsx from 'clsx';
|
|
4
4
|
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
5
5
|
import { useStyles } from '../hooks/useStyles/useStyles.js';
|
|
6
|
+
import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
7
|
+
import { I as Icon } from '../Icon_es_k9bHSLyL.js';
|
|
8
|
+
import { a as LinkWrapper } from '../Link_es_BnUIX0QT.js';
|
|
9
|
+
import { T as Text } from '../Text_es_Ffjr5J1k.js';
|
|
6
10
|
import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
7
|
-
import { I as Icon } from '../Tooltip_es_Y2aoFQW7.js';
|
|
8
|
-
import { a as LinkWrapper } from '../Link_es_DxtZLeKY.js';
|
|
9
|
-
import { T as Text } from '../Text_es_BfLRfj-5.js';
|
|
10
11
|
import { icons12, icons14, icons16, icons20, icons24 } from '@itcase/icons/default';
|
|
11
12
|
import 'lodash/camelCase';
|
|
12
13
|
import 'lodash/castArray';
|
|
@@ -118,10 +119,7 @@ var breadcrumbsConfig = {
|
|
|
118
119
|
appearance: breadcrumbsAppearance};
|
|
119
120
|
function BreadcrumbsItem(props) {
|
|
120
121
|
var className = props.className, appearance = props.appearance, href = props.href, isActive = props.isActive, isSkeleton = props.isSkeleton, onClick = props.onClick, children = props.children;
|
|
121
|
-
var appearanceConfig = appearance
|
|
122
|
-
var _a;
|
|
123
|
-
return (__assign(__assign({}, resultConfig), (_a = breadcrumbsConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
124
|
-
}, {});
|
|
122
|
+
var appearanceConfig = useAppearanceConfig(appearance, breadcrumbsConfig);
|
|
125
123
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
126
124
|
var fillClass = propsGenerator.fillClass, labelTextColor = propsGenerator.labelTextColor, labelTextColorHover = propsGenerator.labelTextColorHover, labelTextSize = propsGenerator.labelTextSize, borderColorClass = propsGenerator.borderColorClass, text = propsGenerator.text, cursor = propsGenerator.cursor, icon = propsGenerator.icon, iconFill = propsGenerator.iconFill, iconFillIcon = propsGenerator.iconFillIcon, iconFillSize = propsGenerator.iconFillSize, iconShape = propsGenerator.iconShape, iconSize = propsGenerator.iconSize, iconSrc = propsGenerator.iconSrc, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, underlineClass = propsGenerator.underlineClass;
|
|
127
125
|
// @ts-expect-error
|
|
@@ -1,16 +1,20 @@
|
|
|
1
|
-
export { B as Button, a as buttonAppearance, b as buttonConfig } from '../
|
|
2
|
-
import '../tslib.es6_es_Bwu1Cn-t.js';
|
|
1
|
+
export { B as Button, a as buttonAppearance, b as buttonConfig } from '../Button_es_XnWb2XF3.js';
|
|
3
2
|
import 'react/jsx-runtime';
|
|
4
3
|
import 'react';
|
|
5
4
|
import 'clsx';
|
|
6
|
-
import '../
|
|
5
|
+
import '../Icon_es_k9bHSLyL.js';
|
|
6
|
+
import '../tslib.es6_es_Bwu1Cn-t.js';
|
|
7
|
+
import 'react-inlinesvg';
|
|
8
|
+
import '../hoc/urlWithAssetPrefix.js';
|
|
9
|
+
import '@itcase/common';
|
|
10
|
+
import '../context/UrlAssetPrefix.js';
|
|
11
|
+
import '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
7
12
|
import '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
8
13
|
import 'lodash/camelCase';
|
|
9
14
|
import 'lodash/castArray';
|
|
10
15
|
import 'lodash/upperFirst';
|
|
11
16
|
import '../context/Notifications.js';
|
|
12
17
|
import 'uuid';
|
|
13
|
-
import '@itcase/common';
|
|
14
18
|
import '../context/UIContext.js';
|
|
15
19
|
import '../hooks/useMediaQueries/useMediaQueries.js';
|
|
16
20
|
import 'react-responsive';
|
|
@@ -18,9 +22,6 @@ import '../utils/setViewportProperty.js';
|
|
|
18
22
|
import '../hooks/useStyles/useStyles.js';
|
|
19
23
|
import 'lodash/maxBy';
|
|
20
24
|
import '../hooks/useStyles/styleAttributes.js';
|
|
21
|
-
import '../
|
|
22
|
-
import '
|
|
23
|
-
import '../
|
|
24
|
-
import '../context/UrlAssetPrefix.js';
|
|
25
|
-
import '../Link_es_DxtZLeKY.js';
|
|
26
|
-
import '../Loader_es_GYOr0UTX.js';
|
|
25
|
+
import '../Link_es_BnUIX0QT.js';
|
|
26
|
+
import '../Text_es_Ffjr5J1k.js';
|
|
27
|
+
import '../Loader_es_BDb87cdb.js';
|
package/dist/components/Cell.js
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
|
-
import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
2
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
3
2
|
import clsx from 'clsx';
|
|
3
|
+
import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
4
4
|
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
5
5
|
import { useStyles } from '../hooks/useStyles/useStyles.js';
|
|
6
|
-
import { I as Icon } from '../
|
|
7
|
-
import { L as Label } from '../
|
|
8
|
-
import { T as Text } from '../
|
|
6
|
+
import { I as Icon } from '../Icon_es_k9bHSLyL.js';
|
|
7
|
+
import { L as Label } from '../Label_es_HXrap3A4.js';
|
|
8
|
+
import { T as Text } from '../Text_es_Ffjr5J1k.js';
|
|
9
|
+
import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
9
10
|
import 'react';
|
|
10
11
|
import 'lodash/camelCase';
|
|
11
12
|
import 'lodash/castArray';
|
|
@@ -22,7 +23,7 @@ import '../hooks/useStyles/styleAttributes.js';
|
|
|
22
23
|
import 'react-inlinesvg';
|
|
23
24
|
import '../hoc/urlWithAssetPrefix.js';
|
|
24
25
|
import '../context/UrlAssetPrefix.js';
|
|
25
|
-
import '../
|
|
26
|
+
import '../Link_es_BnUIX0QT.js';
|
|
26
27
|
|
|
27
28
|
var cellAppearanceSize = {
|
|
28
29
|
sizeXL: {
|
|
@@ -148,10 +149,7 @@ var cellConfig = {
|
|
|
148
149
|
};
|
|
149
150
|
function Cell(props) {
|
|
150
151
|
var className = props.className, appearance = props.appearance, title = props.title, titleIcon = props.titleIcon, titleLabel = props.titleLabel, titleTag = props.titleTag, showTitleLabel = props.showTitleLabel, showValueLabel = props.showValueLabel, value = props.value, valueIcon = props.valueIcon, valueTag = props.valueTag, before = props.before, after = props.after, isActive = props.isActive, isEqual = props.isEqual, onClick = props.onClick, onMouseEnter = props.onMouseEnter;
|
|
151
|
-
var appearanceConfig = appearance
|
|
152
|
-
var _a;
|
|
153
|
-
return (__assign(__assign({}, resultConfig), (_a = cellConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
154
|
-
}, {});
|
|
152
|
+
var appearanceConfig = useAppearanceConfig(appearance, cellConfig);
|
|
155
153
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
156
154
|
var directionClass = propsGenerator.directionClass, fillActiveClass = propsGenerator.fillActiveClass, fillActiveHoverClass = propsGenerator.fillActiveHoverClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, titleIconFill = propsGenerator.titleIconFill, titleIconFillHover = propsGenerator.titleIconFillHover, titleIconFillSize = propsGenerator.titleIconFillSize, titleIconItemFill = propsGenerator.titleIconItemFill, titleIconShape = propsGenerator.titleIconShape, titleIconSrc = propsGenerator.titleIconSrc, titleLabelAppearance = propsGenerator.titleLabelAppearance, titleLabelAppearanceSize = propsGenerator.titleLabelAppearanceSize, titleLabelShape = propsGenerator.titleLabelShape, titleLabelSize = propsGenerator.titleLabelSize, titleLabelTextSize = propsGenerator.titleLabelTextSize, titleTextColor = propsGenerator.titleTextColor, titleTextSize = propsGenerator.titleTextSize, titleTextTruncate = propsGenerator.titleTextTruncate, titleTextWeight = propsGenerator.titleTextWeight, titleTextWrap = propsGenerator.titleTextWrap, borderColorActiveClass = propsGenerator.borderColorActiveClass, borderColorActiveHoverClass = propsGenerator.borderColorActiveHoverClass, borderColorClass = propsGenerator.borderColorClass, borderColorHoverClass = propsGenerator.borderColorHoverClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, valueIconFill = propsGenerator.valueIconFill, valueIconFillHover = propsGenerator.valueIconFillHover, valueIconFillSize = propsGenerator.valueIconFillSize, valueIconItemFill = propsGenerator.valueIconItemFill, valueIconShape = propsGenerator.valueIconShape, valueIconSrc = propsGenerator.valueIconSrc, valueLabel = propsGenerator.valueLabel, valueLabelAppearance = propsGenerator.valueLabelAppearance, valueLabelAppearanceSize = propsGenerator.valueLabelAppearanceSize, valueLabelShape = propsGenerator.valueLabelShape, valueLabelSize = propsGenerator.valueLabelSize, valueLabelTextSize = propsGenerator.valueLabelTextSize, valueTextAlign = propsGenerator.valueTextAlign, valueTextColor = propsGenerator.valueTextColor, valueTextSize = propsGenerator.valueTextSize, valueTextTruncate = propsGenerator.valueTextTruncate, valueTextWeight = propsGenerator.valueTextWeight, valueTextWrap = propsGenerator.valueTextWrap, widthClass = propsGenerator.widthClass, zeroGap = propsGenerator.zeroGap, zeroPadding = propsGenerator.zeroPadding;
|
|
157
155
|
// @ts-expect-error
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
2
1
|
import { jsxs, jsx } from 'react/jsx-runtime';
|
|
3
2
|
import clsx from 'clsx';
|
|
3
|
+
import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
|
|
4
4
|
import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
5
|
-
import { T as Text } from '../
|
|
5
|
+
import { T as Text } from '../Text_es_Ffjr5J1k.js';
|
|
6
|
+
import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
|
|
6
7
|
import 'react';
|
|
7
8
|
import 'lodash/camelCase';
|
|
8
9
|
import 'lodash/castArray';
|
|
@@ -163,10 +164,7 @@ var checkboxConfig = {
|
|
|
163
164
|
};
|
|
164
165
|
function Checkbox(props) {
|
|
165
166
|
var id = props.id, className = props.className, appearance = props.appearance, label = props.label, desc = props.desc, disabled = props.disabled, checked = props.checked, indeterminate = props.indeterminate, _a = props.Tag, Tag = _a === void 0 ? 'label' : _a, value = props.value, before = props.before, after = props.after, isSkeleton = props.isSkeleton, onBlur = props.onBlur, onChange = props.onChange, onFocus = props.onFocus;
|
|
166
|
-
var appearanceConfig = appearance
|
|
167
|
-
var _a;
|
|
168
|
-
return (__assign(__assign({}, resultConfig), (_a = checkboxConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
169
|
-
}, {});
|
|
167
|
+
var appearanceConfig = useAppearanceConfig(appearance, checkboxConfig);
|
|
170
168
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
171
169
|
var fillCheckboxActiveClass = propsGenerator.fillCheckboxActiveClass, fillCheckboxActiveHoverClass = propsGenerator.fillCheckboxActiveHoverClass, fillCheckboxClass = propsGenerator.fillCheckboxClass, fillCheckboxHoverClass = propsGenerator.fillCheckboxHoverClass, fillCheckmarkClass = propsGenerator.fillCheckmarkClass, fillClass = propsGenerator.fillClass, labelTextColor = propsGenerator.labelTextColor, labelTextSize = propsGenerator.labelTextSize, labelTextWeight = propsGenerator.labelTextWeight, descTextColor = propsGenerator.descTextColor, descTextSize = propsGenerator.descTextSize, descTextWeight = propsGenerator.descTextWeight, borderColorCheckboxActiveClass = propsGenerator.borderColorCheckboxActiveClass, borderColorCheckboxActiveHoverClass = propsGenerator.borderColorCheckboxActiveHoverClass, borderColorCheckboxClass = propsGenerator.borderColorCheckboxClass, borderColorCheckboxHoverClass = propsGenerator.borderColorCheckboxHoverClass, checkboxShapeClass = propsGenerator.checkboxShapeClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, widthClass = propsGenerator.widthClass;
|
|
172
170
|
return (jsxs(Tag, { className: clsx(className, 'checkbox', fillClass && "fill_".concat(fillClass), sizeClass && "checkbox_size_".concat(sizeClass), shapeClass && "checkbox_shape_".concat(shapeClass), widthClass && "width_".concat(widthClass), isSkeleton && "checkbox_skeleton"), htmlFor: Tag === 'label' && id, children: [before, jsxs("div", { className: "checkbox__item", children: [jsx("input", { id: id, className: "checkbox__input", type: "checkbox", disabled: disabled, checked: checked, value: value, onBlur: onBlur, onChange: onChange, onFocus: onFocus }), jsx("div", { className: clsx('checkbox__state', !checked
|