@itcase/ui 1.8.21 → 1.8.22
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_CiQ14ufF.js → Avatar_cjs_DSXs1Yrg.js} +2 -21
- package/dist/{Avatar_es_No9vSqji.js → Avatar_es_DByUaJL6.js} +2 -21
- package/dist/{Button_cjs_CnStmeGt.js → Button_cjs_CukkOE-v.js} +5 -4
- package/dist/{Button_es_BV1bepl1.js → Button_es_DXcCJuNX.js} +5 -4
- package/dist/{ChipsGroup_cjs_CL00pWKy.js → ChipsGroup_cjs_9wrMZrzL.js} +1 -1
- package/dist/{ChipsGroup_es_Ciln2otW.js → ChipsGroup_es_CjGZ-ulT.js} +1 -1
- package/dist/{DatePicker_cjs_DGgkpGbI.js → DatePicker_cjs_BriuTQqj.js} +3 -3
- package/dist/{DatePicker_es_BIOyGm22.js → DatePicker_es_DzY_fVii.js} +3 -3
- package/dist/{DropdownItem_cjs_DT-zspEr.js → DropdownItem_cjs_DY61IdLK.js} +1 -1
- package/dist/{DropdownItem_es_BJLFqVuH.js → DropdownItem_es_D8mY9vFZ.js} +1 -1
- package/dist/{Label_cjs_Cqcf6ffp.js → Label_cjs_CnwET26s.js} +11 -3
- package/dist/{Label_es_CeNdA70T.js → Label_es_Dc18d1gY.js} +11 -3
- package/dist/{Link_cjs_BlXrJ15R.js → Link_cjs_DbRGq2Yk.js} +9 -9
- package/dist/{Link_es_CyJn7NFb.js → Link_es_DxtZLeKY.js} +9 -9
- package/dist/{Tooltip_cjs_Cq5kuaIK.js → Tooltip_cjs_PkuRdzzy.js} +3 -3
- package/dist/{Tooltip_es_D0PSqI2c.js → Tooltip_es_BaGfb-qC.js} +3 -3
- package/dist/cjs/components/Accordion.js +2 -2
- package/dist/cjs/components/Avatar.js +3 -3
- package/dist/cjs/components/AvatarStack.js +5 -5
- package/dist/cjs/components/Badge.js +2 -2
- package/dist/cjs/components/Breadcrumbs.js +3 -3
- package/dist/cjs/components/Button.js +3 -3
- package/dist/cjs/components/Cell.js +15 -149
- package/dist/cjs/components/Chips.js +3 -3
- package/dist/cjs/components/Choice.js +2 -2
- package/dist/cjs/components/Code.js +2 -8
- package/dist/cjs/components/CookiesWarning.js +3 -3
- package/dist/cjs/components/DatePeriod.js +6 -6
- package/dist/cjs/components/DatePicker.js +5 -5
- package/dist/cjs/components/Dropdown.js +3 -3
- package/dist/cjs/components/Icon.js +2 -2
- package/dist/cjs/components/InputPassword.js +71 -129
- package/dist/cjs/components/Label.js +3 -3
- package/dist/cjs/components/Link.js +1 -1
- package/dist/cjs/components/List.js +1 -1
- package/dist/cjs/components/Logo.js +1 -1
- package/dist/cjs/components/MenuItem.js +29 -9
- package/dist/cjs/components/Modal.js +2 -2
- package/dist/cjs/components/Pagination.js +3 -3
- package/dist/cjs/components/Response/img.js +33 -0
- package/dist/cjs/components/Response.js +81 -213
- package/dist/cjs/components/Search.js +2 -2
- package/dist/cjs/components/Select.js +2 -2
- package/dist/cjs/components/Swiper.js +2 -2
- package/dist/cjs/components/Tab.js +2 -2
- package/dist/cjs/components/Tile.js +10 -172
- package/dist/cjs/components/Title.js +2 -2
- package/dist/cjs/components/Tooltip.js +2 -2
- package/dist/components/Accordion.js +2 -2
- package/dist/components/Avatar.js +3 -3
- package/dist/components/AvatarStack.js +5 -5
- package/dist/components/Badge.js +2 -2
- package/dist/components/Breadcrumbs.js +3 -3
- package/dist/components/Button.js +3 -3
- package/dist/components/Cell.js +15 -149
- package/dist/components/Chips.js +3 -3
- package/dist/components/Choice.js +2 -2
- package/dist/components/Code.js +2 -8
- package/dist/components/CookiesWarning.js +3 -3
- package/dist/components/DatePeriod.js +6 -6
- package/dist/components/DatePicker.js +5 -5
- package/dist/components/Dropdown.js +3 -3
- package/dist/components/Icon.js +2 -2
- package/dist/components/InputPassword.js +71 -129
- package/dist/components/Label.js +3 -3
- package/dist/components/Link.js +1 -1
- package/dist/components/List.js +1 -1
- package/dist/components/Logo.js +1 -1
- package/dist/components/MenuItem.js +29 -9
- package/dist/components/Modal.js +2 -2
- package/dist/components/Pagination.js +3 -3
- package/dist/components/Response/img.js +31 -0
- package/dist/components/Response.js +81 -213
- package/dist/components/Search.js +2 -2
- package/dist/components/Select.js +2 -2
- package/dist/components/Swiper.js +2 -2
- package/dist/components/Tab.js +2 -2
- package/dist/components/Tile.js +10 -172
- package/dist/components/Title.js +2 -2
- package/dist/components/Tooltip.js +2 -2
- package/dist/css/components/AvatarStack/AvatarStack.css +2 -15
- package/dist/css/components/Code/Code.css +3 -6
- package/dist/css/components/Label/Label.css +4 -4
- package/dist/css/components/MenuItem/MenuItem.css +19 -43
- package/dist/css/components/Response/Response.css +6 -3
- package/dist/css/components/Tab/Tab.css +14 -31
- package/dist/css/components/Tile/Tile.css +7 -5
- package/dist/css/styles/svg-color/svg_fill.css +5 -5
- package/dist/stories/Plsyground.mdx +0 -1
- package/dist/stories/index.stories.js +5 -8
- package/dist/types/components/Avatar/appearance/avatarAccent.d.ts +0 -4
- package/dist/types/components/Avatar/appearance/avatarDanger.d.ts +0 -1
- package/dist/types/components/Avatar/appearance/avatarInfo.d.ts +0 -4
- package/dist/types/components/Avatar/appearance/avatarPrimary.d.ts +0 -1
- package/dist/types/components/Avatar/appearance/avatarSecondary.d.ts +0 -1
- package/dist/types/components/Avatar/appearance/avatarSuccess.d.ts +1 -3
- package/dist/types/components/Avatar/appearance/avatarSurface.d.ts +0 -6
- package/dist/types/components/Button/appearance/buttonAccent.d.ts +1 -0
- package/dist/types/components/Cell/appearance/cellSize.d.ts +8 -44
- package/dist/types/components/Code/appearance/codeSize.d.ts +2 -8
- package/dist/types/components/{Response/appearance/responseDisabled.d.ts → InputPassword/appearance/inputPasswordDefault.d.ts} +9 -5
- package/dist/types/components/InputPassword/appearance/inputPasswordError.d.ts +15 -6
- package/dist/types/components/InputPassword/appearance/inputPasswordSize.d.ts +7 -7
- package/dist/types/components/InputPassword/appearance/inputPasswordSuccess.d.ts +15 -6
- package/dist/types/components/Label/appearance/labelAccent.d.ts +7 -0
- package/dist/types/components/Label/appearance/labelSize.d.ts +1 -0
- package/dist/types/components/Link/Link.interface.d.ts +1 -1
- package/dist/types/components/MenuItem/appearance/menuItemSize.d.ts +1 -0
- package/dist/types/components/MenuItem/appearance/menuItemSurface.d.ts +4 -2
- package/dist/types/components/Response/appearance/responceConfirm.d.ts +13 -0
- package/dist/types/components/Response/appearance/responceFail.d.ts +13 -0
- package/dist/types/components/Response/appearance/responceNothingFound.d.ts +13 -0
- package/dist/types/components/Response/appearance/responceRefresh.d.ts +13 -0
- package/dist/types/components/Response/appearance/responseError.d.ts +6 -4
- package/dist/types/components/Response/appearance/responseSuccess.d.ts +6 -4
- package/dist/types/components/Response/appearance/responseUnableLoadData.d.ts +13 -0
- package/dist/types/components/Response/appearance/responseWarning.d.ts +6 -4
- package/dist/types/components/Response/img/index.d.ts +12 -0
- package/dist/types/components/Tile/appearance/tileSize.d.ts +0 -8
- package/dist/types/components/Tile/appearance/tileSurface.d.ts +0 -1
- package/package.json +1 -1
- package/dist/cjs/components/InputMask.js +0 -65
- package/dist/cjs/components/Panel.js +0 -44
- package/dist/components/InputMask.js +0 -62
- package/dist/components/Panel.js +0 -41
- package/dist/css/components/InputMask/InputMask.css +0 -77
- package/dist/css/components/Panel/Panel.css +0 -107
- package/dist/stories/Accordion.mdx +0 -11
- package/dist/stories/AccordionItem.mdx +0 -15
- package/dist/stories/Breadcrumbs.mdx +0 -15
- package/dist/stories/BreadcrumbsItem.mdx +0 -17
- package/dist/stories/Dot.mdx +0 -19
- package/dist/stories/Drawer.mdx +0 -11
- package/dist/stories/Dropdown.mdx +0 -12
- package/dist/stories/DropdownItem.mdx +0 -19
- package/dist/stories/Image.mdx +0 -15
- package/dist/stories/Input.mdx +0 -31
- package/dist/stories/InputPassword.mdx +0 -15
- package/dist/stories/Label.mdx +0 -11
- package/dist/stories/ListItem.mdx +0 -11
- package/dist/stories/Logo.mdx +0 -24
- package/dist/stories/MenuItem.mdx +0 -15
- package/dist/stories/Modal.mdx +0 -15
- package/dist/stories/Notification.mdx +0 -23
- package/dist/stories/Radio.mdx +0 -28
- package/dist/stories/Response.mdx +0 -11
- package/dist/stories/SearchInput.mdx +0 -19
- package/dist/stories/Switch.mdx +0 -23
- package/dist/stories/Tab.mdx +0 -27
- package/dist/stories/Text.mdx +0 -35
- package/dist/types/components/Cell/appearance/cellAccent.d.ts +0 -21
- package/dist/types/components/Cell/appearance/cellDanger.d.ts +0 -7
- package/dist/types/components/Cell/appearance/cellError.d.ts +0 -11
- package/dist/types/components/Cell/appearance/cellInfo.d.ts +0 -21
- package/dist/types/components/Cell/appearance/cellPrimary.d.ts +0 -8
- package/dist/types/components/Cell/appearance/cellSecondary.d.ts +0 -8
- package/dist/types/components/Cell/appearance/cellSuccess.d.ts +0 -11
- package/dist/types/components/Cell/appearance/cellWarning.d.ts +0 -11
- package/dist/types/components/InputMask/InputMask.d.ts +0 -5
- package/dist/types/components/InputMask/InputMask.interface.d.ts +0 -54
- package/dist/types/components/InputMask/index.d.ts +0 -1
- package/dist/types/components/InputPassword/appearance/inputPasswordAccent.d.ts +0 -20
- package/dist/types/components/InputPassword/appearance/inputPasswordDanger.d.ts +0 -7
- package/dist/types/components/InputPassword/appearance/inputPasswordInfo.d.ts +0 -21
- package/dist/types/components/InputPassword/appearance/inputPasswordPrimary.d.ts +0 -8
- package/dist/types/components/InputPassword/appearance/inputPasswordSecondary.d.ts +0 -8
- package/dist/types/components/InputPassword/appearance/inputPasswordSurface.d.ts +0 -25
- package/dist/types/components/InputPassword/appearance/inputPasswordWarning.d.ts +0 -11
- package/dist/types/components/Panel/Panel.d.ts +0 -5
- package/dist/types/components/Panel/Panel.interface.d.ts +0 -58
- package/dist/types/components/Panel/index.d.ts +0 -1
- package/dist/types/components/Response/appearance/responseAccent.d.ts +0 -20
- package/dist/types/components/Response/appearance/responseDanger.d.ts +0 -7
- package/dist/types/components/Response/appearance/responseInfo.d.ts +0 -21
- package/dist/types/components/Response/appearance/responsePrimary.d.ts +0 -8
- package/dist/types/components/Response/appearance/responseRequire.d.ts +0 -20
- package/dist/types/components/Response/appearance/responseSecondary.d.ts +0 -8
- package/dist/types/components/Response/appearance/responseSize.d.ts +0 -59
- package/dist/types/components/Response/appearance/responseStyle.d.ts +0 -16
- package/dist/types/components/Response/appearance/responseSurface.d.ts +0 -25
- package/dist/types/components/Tile/appearance/tileAccent.d.ts +0 -20
- package/dist/types/components/Tile/appearance/tileDanger.d.ts +0 -7
- package/dist/types/components/Tile/appearance/tileDisabled.d.ts +0 -20
- package/dist/types/components/Tile/appearance/tileError.d.ts +0 -11
- package/dist/types/components/Tile/appearance/tileInfo.d.ts +0 -21
- package/dist/types/components/Tile/appearance/tilePrimary.d.ts +0 -8
- package/dist/types/components/Tile/appearance/tileRequire.d.ts +0 -20
- package/dist/types/components/Tile/appearance/tileSecondary.d.ts +0 -8
- package/dist/types/components/Tile/appearance/tileStyle.d.ts +0 -16
- package/dist/types/components/Tile/appearance/tileSuccess.d.ts +0 -11
- package/dist/types/components/Tile/appearance/tileWarning.d.ts +0 -11
|
@@ -5,33 +5,28 @@ var jsxRuntime = require('react/jsx-runtime');
|
|
|
5
5
|
var React = require('react');
|
|
6
6
|
var clsx = require('clsx');
|
|
7
7
|
var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
8
|
-
var Tooltip = require('./
|
|
8
|
+
var Tooltip = require('./Tooltip_cjs_PkuRdzzy.js');
|
|
9
9
|
var Image = require('./Image_cjs_CCWqbNn4.js');
|
|
10
10
|
var Text = require('./Text_cjs_DPhKj3wf.js');
|
|
11
11
|
|
|
12
12
|
var avatarAppearanceAccent = {
|
|
13
13
|
accent: {
|
|
14
14
|
fill: 'accentPrimary',
|
|
15
|
-
fillHover: 'accentPrimaryHover',
|
|
16
15
|
},
|
|
17
16
|
accentPrimary: {
|
|
18
17
|
fill: 'accentPrimary',
|
|
19
|
-
fillHover: 'accentPrimaryHover',
|
|
20
18
|
borderColor: 'accentBorderPrimary',
|
|
21
19
|
},
|
|
22
20
|
accentSecondary: {
|
|
23
21
|
fill: 'accentPrimary',
|
|
24
|
-
fillHover: 'accentPrimaryHover',
|
|
25
22
|
borderColor: 'accentBorderPrimary',
|
|
26
23
|
textColor: 'accentTextSecondary',
|
|
27
|
-
textColorHover: 'accentTextSecondary',
|
|
28
24
|
},
|
|
29
25
|
};
|
|
30
26
|
|
|
31
27
|
var avatarAppearanceDanger = {
|
|
32
28
|
danger: {
|
|
33
29
|
fill: 'dangerPrimary',
|
|
34
|
-
fillHover: 'dangerPrimaryHover',
|
|
35
30
|
},
|
|
36
31
|
};
|
|
37
32
|
|
|
@@ -47,24 +42,19 @@ var avatarAppearanceError = {
|
|
|
47
42
|
var avatarAppearanceInfo = {
|
|
48
43
|
info: {
|
|
49
44
|
fill: 'accentPrimary',
|
|
50
|
-
fillHover: 'accentPrimaryHover',
|
|
51
45
|
borderColor: 'accentBorderPrimary',
|
|
52
46
|
textColor: 'accentTextPrimary',
|
|
53
|
-
textColorHover: 'accentTextPrimary',
|
|
54
47
|
},
|
|
55
48
|
infoSecondary: {
|
|
56
49
|
fill: 'accentPrimary',
|
|
57
|
-
fillHover: 'accentPrimaryHover',
|
|
58
50
|
borderColor: 'accentBorderPrimary',
|
|
59
51
|
textColor: 'accentTextSecondary',
|
|
60
|
-
textColorHover: 'accentTextSecondary',
|
|
61
52
|
},
|
|
62
53
|
};
|
|
63
54
|
|
|
64
55
|
var avatarAppearancePrimary = {
|
|
65
56
|
primary: {
|
|
66
57
|
fill: 'primaryPrimary',
|
|
67
|
-
fillHover: 'primaryPrimaryHover',
|
|
68
58
|
textColor: 'primaryTextPrimary',
|
|
69
59
|
},
|
|
70
60
|
};
|
|
@@ -72,7 +62,6 @@ var avatarAppearancePrimary = {
|
|
|
72
62
|
var avatarAppearanceSecondary = {
|
|
73
63
|
secondary: {
|
|
74
64
|
fill: 'secondaryPrimary',
|
|
75
|
-
fillHover: 'secondaryPrimaryHover',
|
|
76
65
|
textColor: 'secondaryTextPrimary',
|
|
77
66
|
},
|
|
78
67
|
};
|
|
@@ -171,33 +160,25 @@ var avatarAppearanceStyle = {
|
|
|
171
160
|
var avatarAppearanceSuccess = {
|
|
172
161
|
success: {
|
|
173
162
|
fill: 'successPrimary',
|
|
174
|
-
|
|
175
|
-
textColorPropsColor: 'successTextSecondary',
|
|
176
|
-
textColorPropsColorHover: 'successTextSecondary',
|
|
163
|
+
textColor: 'successTextSecondary',
|
|
177
164
|
},
|
|
178
165
|
};
|
|
179
166
|
|
|
180
167
|
var avatarAppearanceSurface = {
|
|
181
168
|
surfacePrimary: {
|
|
182
169
|
fill: 'surfacePrimary',
|
|
183
|
-
fillHover: 'surfacePrimaryHover',
|
|
184
170
|
textColor: 'surfaceTextPrimary',
|
|
185
171
|
},
|
|
186
172
|
surfaceQuaternary: {
|
|
187
173
|
fill: 'surfaceQuaternary',
|
|
188
|
-
fillHover: 'surfaceQuaternaryHover',
|
|
189
174
|
textColor: 'surfaceTextPrimary',
|
|
190
175
|
},
|
|
191
176
|
surfaceSecondary: {
|
|
192
177
|
fill: 'surfaceSecondary',
|
|
193
|
-
fillHover: 'surfaceSecondaryHover',
|
|
194
178
|
textColor: 'surfaceTextPrimary',
|
|
195
|
-
loaderFill: 'surfaceSecondary',
|
|
196
|
-
loaderItemFill: 'surfaceItemPrimary',
|
|
197
179
|
},
|
|
198
180
|
surfaceTertiary: {
|
|
199
181
|
fill: 'surfaceTertiary',
|
|
200
|
-
fillHover: 'surfaceTertiaryHover',
|
|
201
182
|
textColor: 'surfaceTextPrimary',
|
|
202
183
|
},
|
|
203
184
|
};
|
|
@@ -3,33 +3,28 @@ import { jsx, jsxs } from 'react/jsx-runtime';
|
|
|
3
3
|
import { useMemo } from 'react';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
5
|
import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
6
|
-
import { I as Icon } from './
|
|
6
|
+
import { I as Icon } from './Tooltip_es_BaGfb-qC.js';
|
|
7
7
|
import { I as Image } from './Image_es_DZUVp0FS.js';
|
|
8
8
|
import { T as Text } from './Text_es_BRb3qqKM.js';
|
|
9
9
|
|
|
10
10
|
var avatarAppearanceAccent = {
|
|
11
11
|
accent: {
|
|
12
12
|
fill: 'accentPrimary',
|
|
13
|
-
fillHover: 'accentPrimaryHover',
|
|
14
13
|
},
|
|
15
14
|
accentPrimary: {
|
|
16
15
|
fill: 'accentPrimary',
|
|
17
|
-
fillHover: 'accentPrimaryHover',
|
|
18
16
|
borderColor: 'accentBorderPrimary',
|
|
19
17
|
},
|
|
20
18
|
accentSecondary: {
|
|
21
19
|
fill: 'accentPrimary',
|
|
22
|
-
fillHover: 'accentPrimaryHover',
|
|
23
20
|
borderColor: 'accentBorderPrimary',
|
|
24
21
|
textColor: 'accentTextSecondary',
|
|
25
|
-
textColorHover: 'accentTextSecondary',
|
|
26
22
|
},
|
|
27
23
|
};
|
|
28
24
|
|
|
29
25
|
var avatarAppearanceDanger = {
|
|
30
26
|
danger: {
|
|
31
27
|
fill: 'dangerPrimary',
|
|
32
|
-
fillHover: 'dangerPrimaryHover',
|
|
33
28
|
},
|
|
34
29
|
};
|
|
35
30
|
|
|
@@ -45,24 +40,19 @@ var avatarAppearanceError = {
|
|
|
45
40
|
var avatarAppearanceInfo = {
|
|
46
41
|
info: {
|
|
47
42
|
fill: 'accentPrimary',
|
|
48
|
-
fillHover: 'accentPrimaryHover',
|
|
49
43
|
borderColor: 'accentBorderPrimary',
|
|
50
44
|
textColor: 'accentTextPrimary',
|
|
51
|
-
textColorHover: 'accentTextPrimary',
|
|
52
45
|
},
|
|
53
46
|
infoSecondary: {
|
|
54
47
|
fill: 'accentPrimary',
|
|
55
|
-
fillHover: 'accentPrimaryHover',
|
|
56
48
|
borderColor: 'accentBorderPrimary',
|
|
57
49
|
textColor: 'accentTextSecondary',
|
|
58
|
-
textColorHover: 'accentTextSecondary',
|
|
59
50
|
},
|
|
60
51
|
};
|
|
61
52
|
|
|
62
53
|
var avatarAppearancePrimary = {
|
|
63
54
|
primary: {
|
|
64
55
|
fill: 'primaryPrimary',
|
|
65
|
-
fillHover: 'primaryPrimaryHover',
|
|
66
56
|
textColor: 'primaryTextPrimary',
|
|
67
57
|
},
|
|
68
58
|
};
|
|
@@ -70,7 +60,6 @@ var avatarAppearancePrimary = {
|
|
|
70
60
|
var avatarAppearanceSecondary = {
|
|
71
61
|
secondary: {
|
|
72
62
|
fill: 'secondaryPrimary',
|
|
73
|
-
fillHover: 'secondaryPrimaryHover',
|
|
74
63
|
textColor: 'secondaryTextPrimary',
|
|
75
64
|
},
|
|
76
65
|
};
|
|
@@ -169,33 +158,25 @@ var avatarAppearanceStyle = {
|
|
|
169
158
|
var avatarAppearanceSuccess = {
|
|
170
159
|
success: {
|
|
171
160
|
fill: 'successPrimary',
|
|
172
|
-
|
|
173
|
-
textColorPropsColor: 'successTextSecondary',
|
|
174
|
-
textColorPropsColorHover: 'successTextSecondary',
|
|
161
|
+
textColor: 'successTextSecondary',
|
|
175
162
|
},
|
|
176
163
|
};
|
|
177
164
|
|
|
178
165
|
var avatarAppearanceSurface = {
|
|
179
166
|
surfacePrimary: {
|
|
180
167
|
fill: 'surfacePrimary',
|
|
181
|
-
fillHover: 'surfacePrimaryHover',
|
|
182
168
|
textColor: 'surfaceTextPrimary',
|
|
183
169
|
},
|
|
184
170
|
surfaceQuaternary: {
|
|
185
171
|
fill: 'surfaceQuaternary',
|
|
186
|
-
fillHover: 'surfaceQuaternaryHover',
|
|
187
172
|
textColor: 'surfaceTextPrimary',
|
|
188
173
|
},
|
|
189
174
|
surfaceSecondary: {
|
|
190
175
|
fill: 'surfaceSecondary',
|
|
191
|
-
fillHover: 'surfaceSecondaryHover',
|
|
192
176
|
textColor: 'surfaceTextPrimary',
|
|
193
|
-
loaderFill: 'surfaceSecondary',
|
|
194
|
-
loaderItemFill: 'surfaceItemPrimary',
|
|
195
177
|
},
|
|
196
178
|
surfaceTertiary: {
|
|
197
179
|
fill: 'surfaceTertiary',
|
|
198
|
-
fillHover: 'surfaceTertiaryHover',
|
|
199
180
|
textColor: 'surfaceTextPrimary',
|
|
200
181
|
},
|
|
201
182
|
};
|
|
@@ -4,8 +4,8 @@ var tslib_es6 = require('./tslib.es6_cjs_CCZ3TN_7.js');
|
|
|
4
4
|
var jsxRuntime = require('react/jsx-runtime');
|
|
5
5
|
var React = require('react');
|
|
6
6
|
var clsx = require('clsx');
|
|
7
|
-
var Tooltip = require('./
|
|
8
|
-
var Link = require('./
|
|
7
|
+
var Tooltip = require('./Tooltip_cjs_PkuRdzzy.js');
|
|
8
|
+
var Link = require('./Link_cjs_DbRGq2Yk.js');
|
|
9
9
|
var Loader = require('./Loader_cjs_3VRzFLI2.js');
|
|
10
10
|
var Text = require('./Text_cjs_DPhKj3wf.js');
|
|
11
11
|
var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
@@ -20,6 +20,7 @@ var buttonAppearanceAccent = {
|
|
|
20
20
|
borderColor: 'accentBorderPrimary',
|
|
21
21
|
iconAfterFillIcon: 'accentItemPrimary',
|
|
22
22
|
iconBeforeFillIcon: 'accentItemPrimary',
|
|
23
|
+
iconFillIcon: 'accentItemPrimary',
|
|
23
24
|
loaderFill: 'accentPrimary',
|
|
24
25
|
loaderItemFill: 'accentItemPrimary',
|
|
25
26
|
},
|
|
@@ -42,7 +43,7 @@ var buttonAppearanceAccent = {
|
|
|
42
43
|
borderColor: 'accentBorderPrimary',
|
|
43
44
|
loaderFill: 'accentPrimary',
|
|
44
45
|
loaderItemFill: 'accentItemPrimary',
|
|
45
|
-
}
|
|
46
|
+
},
|
|
46
47
|
};
|
|
47
48
|
|
|
48
49
|
var buttonAppearanceDanger = {
|
|
@@ -274,7 +275,7 @@ var Button = React.forwardRef(function Button(props, ref) {
|
|
|
274
275
|
? 'button_type_icon'
|
|
275
276
|
: '', borderWidthClass && "border-width_".concat(borderWidthClass), borderColorClass && "border-color_".concat(borderColorClass), borderTypeClass && "border_type_".concat(borderTypeClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), shapeClass && "shape_".concat(shapeClass), shapeStrengthClass
|
|
276
277
|
? "shape-strength_".concat(shapeStrengthClass)
|
|
277
|
-
: shapeClass === 'rounded' && 'shape-strength_default', sizeClass && "button_size_".concat(sizeClass), widthClass && "button_width_".concat(widthClass), elevationClass && "elevation_".concat(elevationClass), onClick && 'cursor_type_pointer', isDisabled && 'cursor_type_default', Badge && 'button_type_badge', isLoading && 'button_state_loading', isSkeleton && "button_skeleton"), type: htmlType, disabled: isDisabled, "data-testid": dataTestId && "".concat(dataTestId, "Button"), "data-tour": dataTour,
|
|
278
|
+
: shapeClass === 'rounded' && 'shape-strength_default', sizeClass && "button_size_".concat(sizeClass), widthClass && "button_width_".concat(widthClass), elevationClass && "elevation_".concat(elevationClass), onClick && 'cursor_type_pointer', isDisabled && 'cursor_type_default', Badge && 'button_type_badge', isLoading && 'button_state_loading', isSkeleton && "button_skeleton"), type: htmlType, disabled: isDisabled, "data-testid": dataTestId && "".concat(dataTestId, "Button"), "data-tour": dataTour, href: link || href, LinkComponent: "button", rel: rel, style: buttonStyles, target: target, onClick: onClick, onMouseDown: onMouseDown, children: jsxRuntime.jsxs("div", { className: "button__wrapper", ref: ref, children: [isLoading && (jsxRuntime.jsx(Loader.Loader, { className: clsx(className, 'button__loader', loaderShapeClass), type: loadertype, fill: loaderFill, itemFill: loaderItemFill })), before, (iconBefore || iconBeforeSrc) && (jsxRuntime.jsx(Tooltip.Icon, { className: "button__icon_before", size: iconBeforeSize, fill: iconBeforeFill, fillSize: iconBeforeFillSize, iconFill: iconBeforeFillIcon, imageSrc: iconBeforeSrc, shape: iconBeforeShape, SvgImage: iconBefore })), (icon || iconSrc) && (jsxRuntime.jsx(Tooltip.Icon, { className: "button__icon", size: iconSize, fill: iconFill, fillSize: iconFillSize, iconFill: iconFillIcon, imageSrc: iconSrc, shape: iconShape, SvgImage: icon })), (children || label) && (jsxRuntime.jsx(Text.Text, { className: "button__label", width: labelTextWidth, size: labelTextSize, textColor: labelTextColor, textColorHover: labelTextColorHover, textTruncate: labelTextTruncate, textWeight: labelTextWeight, textWrap: labelTextWrap, style: labelStyles, children: children || label })), (iconAfter || iconAfterSrc) && (jsxRuntime.jsx(Tooltip.Icon, { className: "button__icon_after", size: iconAfterSize, fill: iconAfterFill, fillSize: iconAfterFillSize, iconFill: iconAfterFillIcon, imageSrc: iconAfterSrc, shape: iconAfterShape, SvgImage: iconAfter })), Badge, after] }) }));
|
|
278
279
|
});
|
|
279
280
|
|
|
280
281
|
exports.Button = Button;
|
|
@@ -2,8 +2,8 @@ import { _ as __assign } from './tslib.es6_es_Bwu1Cn-t.js';
|
|
|
2
2
|
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import clsx from 'clsx';
|
|
5
|
-
import { I as Icon } from './
|
|
6
|
-
import { a as LinkWrapper } from './
|
|
5
|
+
import { I as Icon } from './Tooltip_es_BaGfb-qC.js';
|
|
6
|
+
import { a as LinkWrapper } from './Link_es_DxtZLeKY.js';
|
|
7
7
|
import { L as Loader } from './Loader_es_DEYowVdU.js';
|
|
8
8
|
import { T as Text } from './Text_es_BRb3qqKM.js';
|
|
9
9
|
import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
@@ -18,6 +18,7 @@ var buttonAppearanceAccent = {
|
|
|
18
18
|
borderColor: 'accentBorderPrimary',
|
|
19
19
|
iconAfterFillIcon: 'accentItemPrimary',
|
|
20
20
|
iconBeforeFillIcon: 'accentItemPrimary',
|
|
21
|
+
iconFillIcon: 'accentItemPrimary',
|
|
21
22
|
loaderFill: 'accentPrimary',
|
|
22
23
|
loaderItemFill: 'accentItemPrimary',
|
|
23
24
|
},
|
|
@@ -40,7 +41,7 @@ var buttonAppearanceAccent = {
|
|
|
40
41
|
borderColor: 'accentBorderPrimary',
|
|
41
42
|
loaderFill: 'accentPrimary',
|
|
42
43
|
loaderItemFill: 'accentItemPrimary',
|
|
43
|
-
}
|
|
44
|
+
},
|
|
44
45
|
};
|
|
45
46
|
|
|
46
47
|
var buttonAppearanceDanger = {
|
|
@@ -272,7 +273,7 @@ var Button = React.forwardRef(function Button(props, ref) {
|
|
|
272
273
|
? 'button_type_icon'
|
|
273
274
|
: '', borderWidthClass && "border-width_".concat(borderWidthClass), borderColorClass && "border-color_".concat(borderColorClass), borderTypeClass && "border_type_".concat(borderTypeClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), shapeClass && "shape_".concat(shapeClass), shapeStrengthClass
|
|
274
275
|
? "shape-strength_".concat(shapeStrengthClass)
|
|
275
|
-
: shapeClass === 'rounded' && 'shape-strength_default', sizeClass && "button_size_".concat(sizeClass), widthClass && "button_width_".concat(widthClass), elevationClass && "elevation_".concat(elevationClass), onClick && 'cursor_type_pointer', isDisabled && 'cursor_type_default', Badge && 'button_type_badge', isLoading && 'button_state_loading', isSkeleton && "button_skeleton"), type: htmlType, disabled: isDisabled, "data-testid": dataTestId && "".concat(dataTestId, "Button"), "data-tour": dataTour,
|
|
276
|
+
: shapeClass === 'rounded' && 'shape-strength_default', sizeClass && "button_size_".concat(sizeClass), widthClass && "button_width_".concat(widthClass), elevationClass && "elevation_".concat(elevationClass), onClick && 'cursor_type_pointer', isDisabled && 'cursor_type_default', Badge && 'button_type_badge', isLoading && 'button_state_loading', isSkeleton && "button_skeleton"), type: htmlType, disabled: isDisabled, "data-testid": dataTestId && "".concat(dataTestId, "Button"), "data-tour": dataTour, href: link || href, LinkComponent: "button", rel: rel, style: buttonStyles, target: target, onClick: onClick, onMouseDown: onMouseDown, children: jsxs("div", { className: "button__wrapper", ref: ref, children: [isLoading && (jsx(Loader, { className: clsx(className, 'button__loader', loaderShapeClass), type: loadertype, fill: loaderFill, itemFill: loaderItemFill })), before, (iconBefore || iconBeforeSrc) && (jsx(Icon, { className: "button__icon_before", size: iconBeforeSize, fill: iconBeforeFill, fillSize: iconBeforeFillSize, iconFill: iconBeforeFillIcon, imageSrc: iconBeforeSrc, shape: iconBeforeShape, SvgImage: iconBefore })), (icon || iconSrc) && (jsx(Icon, { className: "button__icon", size: iconSize, fill: iconFill, fillSize: iconFillSize, iconFill: iconFillIcon, imageSrc: iconSrc, shape: iconShape, SvgImage: icon })), (children || label) && (jsx(Text, { className: "button__label", width: labelTextWidth, size: labelTextSize, textColor: labelTextColor, textColorHover: labelTextColorHover, textTruncate: labelTextTruncate, textWeight: labelTextWeight, textWrap: labelTextWrap, style: labelStyles, children: children || label })), (iconAfter || iconAfterSrc) && (jsx(Icon, { className: "button__icon_after", size: iconAfterSize, fill: iconAfterFill, fillSize: iconAfterFillSize, iconFill: iconAfterFillIcon, imageSrc: iconAfterSrc, shape: iconAfterShape, SvgImage: iconAfter })), Badge, after] }) }));
|
|
276
277
|
});
|
|
277
278
|
|
|
278
279
|
export { Button as B, buttonAppearance as a, buttonConfig as b };
|
|
@@ -6,7 +6,7 @@ var React = require('react');
|
|
|
6
6
|
var clsx = require('clsx');
|
|
7
7
|
var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
8
8
|
var useStyles = require('./cjs/hooks/useStyles/useStyles.js');
|
|
9
|
-
var Tooltip = require('./
|
|
9
|
+
var Tooltip = require('./Tooltip_cjs_PkuRdzzy.js');
|
|
10
10
|
var Text = require('./Text_cjs_DPhKj3wf.js');
|
|
11
11
|
|
|
12
12
|
var chipsAppearanceAccent = {
|
|
@@ -4,7 +4,7 @@ import { useMemo } from 'react';
|
|
|
4
4
|
import clsx from 'clsx';
|
|
5
5
|
import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
6
6
|
import { useStyles } from './hooks/useStyles/useStyles.js';
|
|
7
|
-
import { I as Icon, B as Badge } from './
|
|
7
|
+
import { I as Icon, B as Badge } from './Tooltip_es_BaGfb-qC.js';
|
|
8
8
|
import { T as Text } from './Text_es_BRb3qqKM.js';
|
|
9
9
|
|
|
10
10
|
var chipsAppearanceAccent = {
|
|
@@ -8,10 +8,10 @@ var locale = require('date-fns/locale');
|
|
|
8
8
|
var DatePicker = require('react-datepicker');
|
|
9
9
|
var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
10
10
|
var useStyles = require('./cjs/hooks/useStyles/useStyles.js');
|
|
11
|
-
var Button = require('./
|
|
12
|
-
var Tooltip = require('./
|
|
11
|
+
var Button = require('./Button_cjs_CukkOE-v.js');
|
|
12
|
+
var Tooltip = require('./Tooltip_cjs_PkuRdzzy.js');
|
|
13
13
|
var Input = require('./Input_cjs_BAVggtkk.js');
|
|
14
|
-
var Label = require('./
|
|
14
|
+
var Label = require('./Label_cjs_CnwET26s.js');
|
|
15
15
|
var Text = require('./Text_cjs_DPhKj3wf.js');
|
|
16
16
|
var _default = require('@itcase/icons/default');
|
|
17
17
|
|
|
@@ -6,10 +6,10 @@ import { ru } from 'date-fns/locale';
|
|
|
6
6
|
import DatePicker from 'react-datepicker';
|
|
7
7
|
import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
8
8
|
import { useStyles } from './hooks/useStyles/useStyles.js';
|
|
9
|
-
import { B as Button } from './
|
|
10
|
-
import { I as Icon } from './
|
|
9
|
+
import { B as Button } from './Button_es_DXcCJuNX.js';
|
|
10
|
+
import { I as Icon } from './Tooltip_es_BaGfb-qC.js';
|
|
11
11
|
import { I as Input } from './Input_es_CNduH28G.js';
|
|
12
|
-
import { L as Label } from './
|
|
12
|
+
import { L as Label } from './Label_es_Dc18d1gY.js';
|
|
13
13
|
import { T as Text } from './Text_es_BRb3qqKM.js';
|
|
14
14
|
import { icon14 } from '@itcase/icons/default';
|
|
15
15
|
|
|
@@ -7,7 +7,7 @@ var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDe
|
|
|
7
7
|
var useStyles = require('./cjs/hooks/useStyles/useStyles.js');
|
|
8
8
|
var tslib_es6 = require('./tslib.es6_cjs_CCZ3TN_7.js');
|
|
9
9
|
var Divider = require('./Divider_cjs_DzFVtGkF.js');
|
|
10
|
-
var Tooltip = require('./
|
|
10
|
+
var Tooltip = require('./Tooltip_cjs_PkuRdzzy.js');
|
|
11
11
|
var Text = require('./Text_cjs_DPhKj3wf.js');
|
|
12
12
|
|
|
13
13
|
function Dropdown(props) {
|
|
@@ -5,7 +5,7 @@ import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevi
|
|
|
5
5
|
import { useStyles } from './hooks/useStyles/useStyles.js';
|
|
6
6
|
import { _ as __assign } from './tslib.es6_es_Bwu1Cn-t.js';
|
|
7
7
|
import { D as Divider } from './Divider_es_BdU9qjKa.js';
|
|
8
|
-
import { I as Icon } from './
|
|
8
|
+
import { I as Icon } from './Tooltip_es_BaGfb-qC.js';
|
|
9
9
|
import { T as Text } from './Text_es_BRb3qqKM.js';
|
|
10
10
|
|
|
11
11
|
function Dropdown(props) {
|
|
@@ -6,8 +6,8 @@ var React = require('react');
|
|
|
6
6
|
var clsx = require('clsx');
|
|
7
7
|
var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js');
|
|
8
8
|
var useStyles = require('./cjs/hooks/useStyles/useStyles.js');
|
|
9
|
+
var Tooltip = require('./Tooltip_cjs_PkuRdzzy.js');
|
|
9
10
|
var Text = require('./Text_cjs_DPhKj3wf.js');
|
|
10
|
-
var Tooltip = require('./Tooltip_cjs_Cq5kuaIK.js');
|
|
11
11
|
|
|
12
12
|
var labelAppearanceAccent = {
|
|
13
13
|
accent: {
|
|
@@ -15,6 +15,13 @@ var labelAppearanceAccent = {
|
|
|
15
15
|
labelTextColor: 'accentTextPrimary',
|
|
16
16
|
labelTextColorHover: 'accentTextPrimary',
|
|
17
17
|
},
|
|
18
|
+
accentPrimary: {
|
|
19
|
+
fill: 'accentPrimary',
|
|
20
|
+
labelTextColor: 'accentTextPrimary',
|
|
21
|
+
labelTextColorHover: 'accentTextPrimary',
|
|
22
|
+
iconBeforeFillIcon: 'accentItemPrimary',
|
|
23
|
+
iconAfterFillIcon: 'accentItemPrimary'
|
|
24
|
+
},
|
|
18
25
|
accentTertiary: {
|
|
19
26
|
fill: 'accentTertiary',
|
|
20
27
|
labelTextColor: 'accentTextPrimary',
|
|
@@ -81,6 +88,7 @@ var labelAppearanceSecondary = {
|
|
|
81
88
|
|
|
82
89
|
var labelAppearanceSize = {
|
|
83
90
|
sizeXXL: {
|
|
91
|
+
size: 'xxl',
|
|
84
92
|
labelTextSize: 'xxl',
|
|
85
93
|
iconAfterFillSize: 24,
|
|
86
94
|
iconAfterSize: 24,
|
|
@@ -225,10 +233,10 @@ function Label(props) {
|
|
|
225
233
|
return (tslib_es6.__assign(tslib_es6.__assign({}, resultConfig), (_a = labelConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
226
234
|
}, {});
|
|
227
235
|
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
228
|
-
var alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, labelTextColor = propsGenerator.labelTextColor, labelTextColorHover = propsGenerator.labelTextColorHover, labelTextSize = propsGenerator.labelTextSize, labelTextWeight = propsGenerator.labelTextWeight, labelTextWrap = propsGenerator.labelTextWrap, borderColorClass = propsGenerator.borderColorClass, borderTypeClass = propsGenerator.borderTypeClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, tooltipAlignment = propsGenerator.tooltipAlignment, tooltipAppearance = propsGenerator.tooltipAppearance, tooltipArrowPosition = propsGenerator.tooltipArrowPosition, tooltipContent = propsGenerator.tooltipContent, tooltipText = propsGenerator.tooltipText, tooltipTextSize = propsGenerator.tooltipTextSize, tooltipTitle = propsGenerator.tooltipTitle, tooltipTitleSize = propsGenerator.tooltipTitleSize, widthClass = propsGenerator.widthClass, wrapClass = propsGenerator.wrapClass;
|
|
236
|
+
var alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, labelTextColor = propsGenerator.labelTextColor, labelTextColorHover = propsGenerator.labelTextColorHover, labelTextSize = propsGenerator.labelTextSize, labelTextWeight = propsGenerator.labelTextWeight, labelTextWrap = propsGenerator.labelTextWrap, borderColorClass = propsGenerator.borderColorClass, borderTypeClass = propsGenerator.borderTypeClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, iconAfter = propsGenerator.iconAfter, iconAfterFill = propsGenerator.iconAfterFill, iconAfterFillIcon = propsGenerator.iconAfterFillIcon, iconAfterFillSize = propsGenerator.iconAfterFillSize, iconAfterShape = propsGenerator.iconAfterShape, iconAfterSize = propsGenerator.iconAfterSize, iconAfterSrc = propsGenerator.iconAfterSrc; propsGenerator.iconBadgeAppearance; propsGenerator.iconBadgeShape; propsGenerator.iconBadgeSize; propsGenerator.iconBadgeTextColor; propsGenerator.iconBadgeTextSize; propsGenerator.iconBadgeValue; var iconBefore = propsGenerator.iconBefore, iconBeforeFill = propsGenerator.iconBeforeFill, iconBeforeFillIcon = propsGenerator.iconBeforeFillIcon, iconBeforeFillSize = propsGenerator.iconBeforeFillSize, iconBeforeShape = propsGenerator.iconBeforeShape, iconBeforeSize = propsGenerator.iconBeforeSize, iconBeforeSrc = propsGenerator.iconBeforeSrc, tooltipAlignment = propsGenerator.tooltipAlignment, tooltipAppearance = propsGenerator.tooltipAppearance, tooltipArrowPosition = propsGenerator.tooltipArrowPosition, tooltipContent = propsGenerator.tooltipContent, tooltipText = propsGenerator.tooltipText, tooltipTextSize = propsGenerator.tooltipTextSize, tooltipTitle = propsGenerator.tooltipTitle, tooltipTitleSize = propsGenerator.tooltipTitleSize, widthClass = propsGenerator.widthClass, wrapClass = propsGenerator.wrapClass;
|
|
229
237
|
// @ts-expect-error
|
|
230
238
|
var labelStyles = useStyles.useStyles(props).styles;
|
|
231
|
-
return (jsxRuntime.jsxs("div", { className: clsx(className, 'label', fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), shapeClass && "label_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderTypeClass && "border_type_".concat(borderTypeClass), sizeClass && "label_size_".concat(sizeClass), wrapClass && "'word-wrap_".concat(wrapClass), widthClass && "label_width_".concat(widthClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignClass && "align_".concat(alignClass), type && "label_type_".concat(type), mode && "label_mode_".concat(mode), isSkeleton && "label_skeleton", onClick && (cursor || 'cursor_type_pointer')), "data-tour": dataTour, style: labelStyles, onClick: onClick, onMouseEnter: onMouseEnterLabel, onMouseLeave: onMouseLeaveLabel, children: [before, jsxRuntime.jsxs("div", { className: "label__inner", children: [typeof label === 'string' ? (jsxRuntime.jsx(Text.Text, { className: "label__text", size: labelTextSize, textColor: labelTextColor, textColorHover: labelTextColorHover, textWeight: labelTextWeight, textWrap: labelTextWrap, children: label })) : (jsxRuntime.jsx("div", { className: "label__text", children: label })), children, showTooltip && (jsxRuntime.jsx(Tooltip.Tooltip, { className: "label__tooltip", appearance: tooltipAppearance, alignment: tooltipAlignment, title: tooltipTitle, titleSize: tooltipTitleSize, text: tooltipText, textSize: tooltipTextSize, arrowPosition: tooltipArrowPosition, ref: tooltipRef, children: tooltipContent }))] }), after] }));
|
|
239
|
+
return (jsxRuntime.jsxs("div", { className: clsx(className, 'label', fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), shapeClass && "label_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderTypeClass && "border_type_".concat(borderTypeClass), sizeClass && "label_size_".concat(sizeClass), wrapClass && "'word-wrap_".concat(wrapClass), widthClass && "label_width_".concat(widthClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignClass && "align_".concat(alignClass), type && "label_type_".concat(type), mode && "label_mode_".concat(mode), isSkeleton && "label_skeleton", onClick && (cursor || 'cursor_type_pointer')), "data-tour": dataTour, style: labelStyles, onClick: onClick, onMouseEnter: onMouseEnterLabel, onMouseLeave: onMouseLeaveLabel, children: [before, (iconBefore || iconBeforeSrc) && (jsxRuntime.jsx(Tooltip.Icon, { className: clsx('label__icon_before'), fill: iconBeforeFill, fillSize: iconBeforeFillSize, iconFill: iconBeforeFillIcon, iconSize: iconBeforeSize, imageSrc: iconBeforeSrc, shape: iconBeforeShape, SvgImage: iconBefore })), jsxRuntime.jsxs("div", { className: "label__inner", children: [typeof label === 'string' ? (jsxRuntime.jsx(Text.Text, { className: "label__text", size: labelTextSize, textColor: labelTextColor, textColorHover: labelTextColorHover, textWeight: labelTextWeight, textWrap: labelTextWrap, children: label })) : (jsxRuntime.jsx("div", { className: "label__text", children: label })), children, showTooltip && (jsxRuntime.jsx(Tooltip.Tooltip, { className: "label__tooltip", appearance: tooltipAppearance, alignment: tooltipAlignment, title: tooltipTitle, titleSize: tooltipTitleSize, text: tooltipText, textSize: tooltipTextSize, arrowPosition: tooltipArrowPosition, ref: tooltipRef, children: tooltipContent }))] }), (iconAfter || iconAfterSrc) && (jsxRuntime.jsx(Tooltip.Icon, { className: clsx('label__icon_after'), fill: iconAfterFill, fillSize: iconAfterFillSize, iconFill: iconAfterFillIcon, iconSize: iconAfterSize, imageSrc: iconAfterSrc, shape: iconAfterShape, SvgImage: iconAfter })), after] }));
|
|
232
240
|
}
|
|
233
241
|
|
|
234
242
|
exports.Label = Label;
|
|
@@ -4,8 +4,8 @@ import { useRef, useCallback } from 'react';
|
|
|
4
4
|
import clsx from 'clsx';
|
|
5
5
|
import { useDevicePropsGenerator } from './hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
|
|
6
6
|
import { useStyles } from './hooks/useStyles/useStyles.js';
|
|
7
|
+
import { I as Icon, T as Tooltip } from './Tooltip_es_BaGfb-qC.js';
|
|
7
8
|
import { T as Text } from './Text_es_BRb3qqKM.js';
|
|
8
|
-
import { T as Tooltip } from './Tooltip_es_D0PSqI2c.js';
|
|
9
9
|
|
|
10
10
|
var labelAppearanceAccent = {
|
|
11
11
|
accent: {
|
|
@@ -13,6 +13,13 @@ var labelAppearanceAccent = {
|
|
|
13
13
|
labelTextColor: 'accentTextPrimary',
|
|
14
14
|
labelTextColorHover: 'accentTextPrimary',
|
|
15
15
|
},
|
|
16
|
+
accentPrimary: {
|
|
17
|
+
fill: 'accentPrimary',
|
|
18
|
+
labelTextColor: 'accentTextPrimary',
|
|
19
|
+
labelTextColorHover: 'accentTextPrimary',
|
|
20
|
+
iconBeforeFillIcon: 'accentItemPrimary',
|
|
21
|
+
iconAfterFillIcon: 'accentItemPrimary'
|
|
22
|
+
},
|
|
16
23
|
accentTertiary: {
|
|
17
24
|
fill: 'accentTertiary',
|
|
18
25
|
labelTextColor: 'accentTextPrimary',
|
|
@@ -79,6 +86,7 @@ var labelAppearanceSecondary = {
|
|
|
79
86
|
|
|
80
87
|
var labelAppearanceSize = {
|
|
81
88
|
sizeXXL: {
|
|
89
|
+
size: 'xxl',
|
|
82
90
|
labelTextSize: 'xxl',
|
|
83
91
|
iconAfterFillSize: 24,
|
|
84
92
|
iconAfterSize: 24,
|
|
@@ -223,10 +231,10 @@ function Label(props) {
|
|
|
223
231
|
return (__assign(__assign({}, resultConfig), (_a = labelConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
224
232
|
}, {});
|
|
225
233
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
226
|
-
var alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, labelTextColor = propsGenerator.labelTextColor, labelTextColorHover = propsGenerator.labelTextColorHover, labelTextSize = propsGenerator.labelTextSize, labelTextWeight = propsGenerator.labelTextWeight, labelTextWrap = propsGenerator.labelTextWrap, borderColorClass = propsGenerator.borderColorClass, borderTypeClass = propsGenerator.borderTypeClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, tooltipAlignment = propsGenerator.tooltipAlignment, tooltipAppearance = propsGenerator.tooltipAppearance, tooltipArrowPosition = propsGenerator.tooltipArrowPosition, tooltipContent = propsGenerator.tooltipContent, tooltipText = propsGenerator.tooltipText, tooltipTextSize = propsGenerator.tooltipTextSize, tooltipTitle = propsGenerator.tooltipTitle, tooltipTitleSize = propsGenerator.tooltipTitleSize, widthClass = propsGenerator.widthClass, wrapClass = propsGenerator.wrapClass;
|
|
234
|
+
var alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, labelTextColor = propsGenerator.labelTextColor, labelTextColorHover = propsGenerator.labelTextColorHover, labelTextSize = propsGenerator.labelTextSize, labelTextWeight = propsGenerator.labelTextWeight, labelTextWrap = propsGenerator.labelTextWrap, borderColorClass = propsGenerator.borderColorClass, borderTypeClass = propsGenerator.borderTypeClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, iconAfter = propsGenerator.iconAfter, iconAfterFill = propsGenerator.iconAfterFill, iconAfterFillIcon = propsGenerator.iconAfterFillIcon, iconAfterFillSize = propsGenerator.iconAfterFillSize, iconAfterShape = propsGenerator.iconAfterShape, iconAfterSize = propsGenerator.iconAfterSize, iconAfterSrc = propsGenerator.iconAfterSrc; propsGenerator.iconBadgeAppearance; propsGenerator.iconBadgeShape; propsGenerator.iconBadgeSize; propsGenerator.iconBadgeTextColor; propsGenerator.iconBadgeTextSize; propsGenerator.iconBadgeValue; var iconBefore = propsGenerator.iconBefore, iconBeforeFill = propsGenerator.iconBeforeFill, iconBeforeFillIcon = propsGenerator.iconBeforeFillIcon, iconBeforeFillSize = propsGenerator.iconBeforeFillSize, iconBeforeShape = propsGenerator.iconBeforeShape, iconBeforeSize = propsGenerator.iconBeforeSize, iconBeforeSrc = propsGenerator.iconBeforeSrc, tooltipAlignment = propsGenerator.tooltipAlignment, tooltipAppearance = propsGenerator.tooltipAppearance, tooltipArrowPosition = propsGenerator.tooltipArrowPosition, tooltipContent = propsGenerator.tooltipContent, tooltipText = propsGenerator.tooltipText, tooltipTextSize = propsGenerator.tooltipTextSize, tooltipTitle = propsGenerator.tooltipTitle, tooltipTitleSize = propsGenerator.tooltipTitleSize, widthClass = propsGenerator.widthClass, wrapClass = propsGenerator.wrapClass;
|
|
227
235
|
// @ts-expect-error
|
|
228
236
|
var labelStyles = useStyles(props).styles;
|
|
229
|
-
return (jsxs("div", { className: clsx(className, 'label', fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), shapeClass && "label_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderTypeClass && "border_type_".concat(borderTypeClass), sizeClass && "label_size_".concat(sizeClass), wrapClass && "'word-wrap_".concat(wrapClass), widthClass && "label_width_".concat(widthClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignClass && "align_".concat(alignClass), type && "label_type_".concat(type), mode && "label_mode_".concat(mode), isSkeleton && "label_skeleton", onClick && (cursor || 'cursor_type_pointer')), "data-tour": dataTour, style: labelStyles, onClick: onClick, onMouseEnter: onMouseEnterLabel, onMouseLeave: onMouseLeaveLabel, children: [before, jsxs("div", { className: "label__inner", children: [typeof label === 'string' ? (jsx(Text, { className: "label__text", size: labelTextSize, textColor: labelTextColor, textColorHover: labelTextColorHover, textWeight: labelTextWeight, textWrap: labelTextWrap, children: label })) : (jsx("div", { className: "label__text", children: label })), children, showTooltip && (jsx(Tooltip, { className: "label__tooltip", appearance: tooltipAppearance, alignment: tooltipAlignment, title: tooltipTitle, titleSize: tooltipTitleSize, text: tooltipText, textSize: tooltipTextSize, arrowPosition: tooltipArrowPosition, ref: tooltipRef, children: tooltipContent }))] }), after] }));
|
|
237
|
+
return (jsxs("div", { className: clsx(className, 'label', fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), shapeClass && "label_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderTypeClass && "border_type_".concat(borderTypeClass), sizeClass && "label_size_".concat(sizeClass), wrapClass && "'word-wrap_".concat(wrapClass), widthClass && "label_width_".concat(widthClass), alignDirectionClass && "align_".concat(alignDirectionClass), alignClass && "align_".concat(alignClass), type && "label_type_".concat(type), mode && "label_mode_".concat(mode), isSkeleton && "label_skeleton", onClick && (cursor || 'cursor_type_pointer')), "data-tour": dataTour, style: labelStyles, onClick: onClick, onMouseEnter: onMouseEnterLabel, onMouseLeave: onMouseLeaveLabel, children: [before, (iconBefore || iconBeforeSrc) && (jsx(Icon, { className: clsx('label__icon_before'), fill: iconBeforeFill, fillSize: iconBeforeFillSize, iconFill: iconBeforeFillIcon, iconSize: iconBeforeSize, imageSrc: iconBeforeSrc, shape: iconBeforeShape, SvgImage: iconBefore })), jsxs("div", { className: "label__inner", children: [typeof label === 'string' ? (jsx(Text, { className: "label__text", size: labelTextSize, textColor: labelTextColor, textColorHover: labelTextColorHover, textWeight: labelTextWeight, textWrap: labelTextWrap, children: label })) : (jsx("div", { className: "label__text", children: label })), children, showTooltip && (jsx(Tooltip, { className: "label__tooltip", appearance: tooltipAppearance, alignment: tooltipAlignment, title: tooltipTitle, titleSize: tooltipTitleSize, text: tooltipText, textSize: tooltipTextSize, arrowPosition: tooltipArrowPosition, ref: tooltipRef, children: tooltipContent }))] }), (iconAfter || iconAfterSrc) && (jsx(Icon, { className: clsx('label__icon_after'), fill: iconAfterFill, fillSize: iconAfterFillSize, iconFill: iconAfterFillIcon, iconSize: iconAfterSize, imageSrc: iconAfterSrc, shape: iconAfterShape, SvgImage: iconAfter })), after] }));
|
|
230
238
|
}
|
|
231
239
|
|
|
232
240
|
export { Label as L, labelAppearance as a, labelConfig as l };
|
|
@@ -257,13 +257,13 @@ var linkConfig = {
|
|
|
257
257
|
},
|
|
258
258
|
};
|
|
259
259
|
function Link(props) {
|
|
260
|
-
var className = props.className, appearance = props.appearance, text = props.text, href = props.href, link = props.link, LinkComponent = props.LinkComponent, rel = props.rel, style = props.style, target = props.target,
|
|
260
|
+
var className = props.className, appearance = props.appearance, text = props.text, href = props.href, link = props.link, LinkComponent = props.LinkComponent, rel = props.rel, style = props.style, target = props.target, before = props.before, after = props.after, onClick = props.onClick, onMouseDown = props.onMouseDown, children = props.children;
|
|
261
261
|
var appearanceConfig = appearance === null || appearance === void 0 ? void 0 : appearance.split(' ').reduce(function (resultConfig, appearanceKey) {
|
|
262
262
|
var _a;
|
|
263
263
|
return (tslib_es6.__assign(tslib_es6.__assign({}, resultConfig), (_a = linkConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
264
264
|
}, {});
|
|
265
265
|
var propsGenerator = useDevicePropsGenerator.useDevicePropsGenerator(props, appearanceConfig);
|
|
266
|
-
var directionClass = propsGenerator.directionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, borderColorClass = propsGenerator.borderColorClass, borderColorHoverClass = propsGenerator.borderColorHoverClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, textColorClass = propsGenerator.textColorClass, textColorHoverClass = propsGenerator.textColorHoverClass, textGradientClass = propsGenerator.textGradientClass, textStyleClass = propsGenerator.textStyleClass, textWeightClass = propsGenerator.textWeightClass, heightClass = propsGenerator.heightClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, svgFillClass = propsGenerator.svgFillClass, svgFillHoverClass = propsGenerator.svgFillHoverClass, widthClass = propsGenerator.widthClass;
|
|
266
|
+
var directionClass = propsGenerator.directionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, borderColorClass = propsGenerator.borderColorClass, borderColorHoverClass = propsGenerator.borderColorHoverClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, textColorClass = propsGenerator.textColorClass, textColorHoverClass = propsGenerator.textColorHoverClass, textGradientClass = propsGenerator.textGradientClass, textStyleClass = propsGenerator.textStyleClass, textWeightClass = propsGenerator.textWeightClass, heightClass = propsGenerator.heightClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, svgFillClass = propsGenerator.svgFillClass, svgFillHoverClass = propsGenerator.svgFillHoverClass, _a = propsGenerator.underline, underline = _a === void 0 ? 'underline' : _a, widthClass = propsGenerator.widthClass;
|
|
267
267
|
// @ts-expect-error
|
|
268
268
|
var styles = useStyles.useStyles(props).styles;
|
|
269
269
|
return (jsxRuntime.jsxs(LinkWrapper, { className: clsx(className, 'link', widthClass && "width_".concat(widthClass), heightClass && "height_".concat(heightClass), directionClass && "link_direction_".concat(directionClass), sizeClass && "text_size_".concat(sizeClass), svgFillClass && "svg_fill_".concat(svgFillClass), svgFillHoverClass && "svg_fill_hover_".concat(svgFillHoverClass), underline && "link_underline_".concat(underline), 'text', (textColorClass ||
|
|
@@ -271,21 +271,21 @@ function Link(props) {
|
|
|
271
271
|
textGradientClass ||
|
|
272
272
|
textStyleClass ||
|
|
273
273
|
textWeightClass) &&
|
|
274
|
-
'text', textColorClass && "text-color_".concat(textColorClass), textColorHoverClass && "text-color_hover_".concat(textColorHoverClass), textGradientClass && "text-gradient_".concat(textGradientClass), textStyleClass && "text-style_".concat(textStyleClass), textWeightClass && "text-weight_".concat(textWeightClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), shapeClass && "link_shape_".concat(shapeClass)),
|
|
274
|
+
'text', textColorClass && "text-color_".concat(textColorClass), textColorHoverClass && "text-color_hover_".concat(textColorHoverClass), textGradientClass && "text-gradient_".concat(textGradientClass), textStyleClass && "text-style_".concat(textStyleClass), textWeightClass && "text-weight_".concat(textWeightClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), shapeClass && "link_shape_".concat(shapeClass)), href: href || link, LinkComponent: LinkComponent, rel: rel, style: Object.assign({}, styles, style), target: target, onClick: onClick, onMouseDown: onMouseDown, children: [before, children || text, after] }));
|
|
275
275
|
}
|
|
276
276
|
// Wrapper with "Link" by condition
|
|
277
277
|
function LinkWrapper(props) {
|
|
278
|
-
var
|
|
278
|
+
var href = props.href, LinkComponent = props.LinkComponent, rel = props.rel, target = props.target, children = props.children, otherProps = tslib_es6.__rest(props, ["href", "LinkComponent", "rel", "target", "children"]);
|
|
279
279
|
if (href) {
|
|
280
280
|
// If href passed, make link-wrapper
|
|
281
|
-
var
|
|
282
|
-
if (
|
|
283
|
-
return (jsxRuntime.jsx(
|
|
281
|
+
var Component = LinkComponent || linkConfig.LinkComponent;
|
|
282
|
+
if (Component) {
|
|
283
|
+
return (jsxRuntime.jsx(Component, tslib_es6.__assign({ href: href, rel: rel, target: target }, otherProps, { children: children })));
|
|
284
284
|
}
|
|
285
285
|
}
|
|
286
|
-
else if (
|
|
286
|
+
else if (LinkComponent) {
|
|
287
287
|
// If has default "Component" - render it
|
|
288
|
-
return jsxRuntime.jsx(
|
|
288
|
+
return jsxRuntime.jsx(LinkComponent, tslib_es6.__assign({}, otherProps, { children: children }));
|
|
289
289
|
}
|
|
290
290
|
// Return children and pass current props to
|
|
291
291
|
return React.Children.toArray(children)
|
|
@@ -255,13 +255,13 @@ var linkConfig = {
|
|
|
255
255
|
},
|
|
256
256
|
};
|
|
257
257
|
function Link(props) {
|
|
258
|
-
var className = props.className, appearance = props.appearance, text = props.text, href = props.href, link = props.link, LinkComponent = props.LinkComponent, rel = props.rel, style = props.style, target = props.target,
|
|
258
|
+
var className = props.className, appearance = props.appearance, text = props.text, href = props.href, link = props.link, LinkComponent = props.LinkComponent, rel = props.rel, style = props.style, target = props.target, before = props.before, after = props.after, onClick = props.onClick, onMouseDown = props.onMouseDown, children = props.children;
|
|
259
259
|
var appearanceConfig = appearance === null || appearance === void 0 ? void 0 : appearance.split(' ').reduce(function (resultConfig, appearanceKey) {
|
|
260
260
|
var _a;
|
|
261
261
|
return (__assign(__assign({}, resultConfig), (_a = linkConfig.appearance) === null || _a === void 0 ? void 0 : _a[appearanceKey]));
|
|
262
262
|
}, {});
|
|
263
263
|
var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
|
|
264
|
-
var directionClass = propsGenerator.directionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, borderColorClass = propsGenerator.borderColorClass, borderColorHoverClass = propsGenerator.borderColorHoverClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, textColorClass = propsGenerator.textColorClass, textColorHoverClass = propsGenerator.textColorHoverClass, textGradientClass = propsGenerator.textGradientClass, textStyleClass = propsGenerator.textStyleClass, textWeightClass = propsGenerator.textWeightClass, heightClass = propsGenerator.heightClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, svgFillClass = propsGenerator.svgFillClass, svgFillHoverClass = propsGenerator.svgFillHoverClass, widthClass = propsGenerator.widthClass;
|
|
264
|
+
var directionClass = propsGenerator.directionClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, borderColorClass = propsGenerator.borderColorClass, borderColorHoverClass = propsGenerator.borderColorHoverClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, textColorClass = propsGenerator.textColorClass, textColorHoverClass = propsGenerator.textColorHoverClass, textGradientClass = propsGenerator.textGradientClass, textStyleClass = propsGenerator.textStyleClass, textWeightClass = propsGenerator.textWeightClass, heightClass = propsGenerator.heightClass, shapeClass = propsGenerator.shapeClass, sizeClass = propsGenerator.sizeClass, svgFillClass = propsGenerator.svgFillClass, svgFillHoverClass = propsGenerator.svgFillHoverClass, _a = propsGenerator.underline, underline = _a === void 0 ? 'underline' : _a, widthClass = propsGenerator.widthClass;
|
|
265
265
|
// @ts-expect-error
|
|
266
266
|
var styles = useStyles(props).styles;
|
|
267
267
|
return (jsxs(LinkWrapper, { className: clsx(className, 'link', widthClass && "width_".concat(widthClass), heightClass && "height_".concat(heightClass), directionClass && "link_direction_".concat(directionClass), sizeClass && "text_size_".concat(sizeClass), svgFillClass && "svg_fill_".concat(svgFillClass), svgFillHoverClass && "svg_fill_hover_".concat(svgFillHoverClass), underline && "link_underline_".concat(underline), 'text', (textColorClass ||
|
|
@@ -269,21 +269,21 @@ function Link(props) {
|
|
|
269
269
|
textGradientClass ||
|
|
270
270
|
textStyleClass ||
|
|
271
271
|
textWeightClass) &&
|
|
272
|
-
'text', textColorClass && "text-color_".concat(textColorClass), textColorHoverClass && "text-color_hover_".concat(textColorHoverClass), textGradientClass && "text-gradient_".concat(textGradientClass), textStyleClass && "text-style_".concat(textStyleClass), textWeightClass && "text-weight_".concat(textWeightClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), shapeClass && "link_shape_".concat(shapeClass)),
|
|
272
|
+
'text', textColorClass && "text-color_".concat(textColorClass), textColorHoverClass && "text-color_hover_".concat(textColorHoverClass), textGradientClass && "text-gradient_".concat(textGradientClass), textStyleClass && "text-style_".concat(textStyleClass), textWeightClass && "text-weight_".concat(textWeightClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), shapeClass && "link_shape_".concat(shapeClass)), href: href || link, LinkComponent: LinkComponent, rel: rel, style: Object.assign({}, styles, style), target: target, onClick: onClick, onMouseDown: onMouseDown, children: [before, children || text, after] }));
|
|
273
273
|
}
|
|
274
274
|
// Wrapper with "Link" by condition
|
|
275
275
|
function LinkWrapper(props) {
|
|
276
|
-
var
|
|
276
|
+
var href = props.href, LinkComponent = props.LinkComponent, rel = props.rel, target = props.target, children = props.children, otherProps = __rest(props, ["href", "LinkComponent", "rel", "target", "children"]);
|
|
277
277
|
if (href) {
|
|
278
278
|
// If href passed, make link-wrapper
|
|
279
|
-
var
|
|
280
|
-
if (
|
|
281
|
-
return (jsx(
|
|
279
|
+
var Component = LinkComponent || linkConfig.LinkComponent;
|
|
280
|
+
if (Component) {
|
|
281
|
+
return (jsx(Component, __assign({ href: href, rel: rel, target: target }, otherProps, { children: children })));
|
|
282
282
|
}
|
|
283
283
|
}
|
|
284
|
-
else if (
|
|
284
|
+
else if (LinkComponent) {
|
|
285
285
|
// If has default "Component" - render it
|
|
286
|
-
return jsx(
|
|
286
|
+
return jsx(LinkComponent, __assign({}, otherProps, { children: children }));
|
|
287
287
|
}
|
|
288
288
|
// Return children and pass current props to
|
|
289
289
|
return React.Children.toArray(children)
|
|
@@ -8,7 +8,7 @@ var useDevicePropsGenerator = require('./cjs/hooks/useDevicePropsGenerator/useDe
|
|
|
8
8
|
var useStyles = require('./cjs/hooks/useStyles/useStyles.js');
|
|
9
9
|
var Text = require('./Text_cjs_DPhKj3wf.js');
|
|
10
10
|
var SVG = require('react-inlinesvg');
|
|
11
|
-
var Link = require('./
|
|
11
|
+
var Link = require('./Link_cjs_DbRGq2Yk.js');
|
|
12
12
|
|
|
13
13
|
var badgeAppearanceAccent = {
|
|
14
14
|
accent: {
|
|
@@ -511,7 +511,7 @@ var iconConfig = {
|
|
|
511
511
|
var Icon = React.forwardRef(function Icon(props, ref) {
|
|
512
512
|
// TODO: Tooltip doesn't work that anymore
|
|
513
513
|
// const [isTooltipVisible, setIsTooltipVisible] = useState(false)
|
|
514
|
-
var id = props.id, className = props.className, appearance = props.appearance,
|
|
514
|
+
var id = props.id, className = props.className, appearance = props.appearance, width = props.width, height = props.height, badgeClass = props.badgeClass, dataTour = props.dataTour, href = props.href, imageSrc = props.imageSrc, link = props.link, linkRel = props.linkRel, linkTarget = props.linkTarget, showTooltip = props.showTooltip, SvgImage = props.SvgImage, before = props.before, after = props.after, isActive = props.isActive, onClick = props.onClick, onMouseEnter = props.onMouseEnter, onMouseLeave = props.onMouseLeave;
|
|
515
515
|
var ImageComponent = React.useMemo(function () {
|
|
516
516
|
if (SvgImage) {
|
|
517
517
|
var sizes = {};
|
|
@@ -548,7 +548,7 @@ var Icon = React.forwardRef(function Icon(props, ref) {
|
|
|
548
548
|
: iconFillActiveClass && "icon_fill_active_".concat(iconFillActiveClass), !isActive
|
|
549
549
|
? iconFillHoverClass && "icon_fill_hover_".concat(iconFillHoverClass)
|
|
550
550
|
: iconFillActiveHoverClass &&
|
|
551
|
-
"icon_fill_active_hover_".concat(iconFillActiveHoverClass), iconFillDisabledClass && "icon_fill_disabled_".concat(iconFillDisabledClass), shapeClass && "icon_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), badgeValue && 'icon_with-badge', onClick && cursorClass && "cursor_".concat(cursorClass)), "data-tour": dataTour, ref: ref, style: iconStyles, onClick: onClick, onMouseEnter: onMouseEnter, onMouseLeave: onMouseLeave, children: [before, jsxRuntime.jsxs(Link.LinkWrapper, { className: clsx((link || href || onClick) && 'cursor_type_pointer', link || href ? 'icon__link' : 'icon__item', iconSizeClass && "icon_size_".concat(iconSizeClass)),
|
|
551
|
+
"icon_fill_active_hover_".concat(iconFillActiveHoverClass), iconFillDisabledClass && "icon_fill_disabled_".concat(iconFillDisabledClass), shapeClass && "icon_shape_".concat(shapeClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), badgeValue && 'icon_with-badge', onClick && cursorClass && "cursor_".concat(cursorClass)), "data-tour": dataTour, ref: ref, style: iconStyles, onClick: onClick, onMouseEnter: onMouseEnter, onMouseLeave: onMouseLeave, children: [before, jsxRuntime.jsxs(Link.LinkWrapper, { className: clsx((link || href || onClick) && 'cursor_type_pointer', link || href ? 'icon__link' : 'icon__item', iconSizeClass && "icon_size_".concat(iconSizeClass)), href: link || href, LinkComponent: "div", rel: linkRel, target: linkTarget, children: [ImageComponent, badgeValue && (jsxRuntime.jsx(Badge, { className: clsx(badgeClass, 'icon__badge'), appearance: badgeAppearance, size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), showTooltip && (jsxRuntime.jsx(Tooltip, { className: clsx(className, 'icon__tooltip', alignmentClass && "alignment_".concat(alignmentClass)), appearance: tooltipAppearance, title: tooltipTitle, titleSize: tooltipTitleSize, text: tooltipText, textSize: tooltipTextSize }))] }), after] }));
|
|
552
552
|
});
|
|
553
553
|
var removeFillStroke = function (code) {
|
|
554
554
|
return code
|