@itcase/ui 1.8.123 → 1.8.125

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.
Files changed (246) hide show
  1. package/dist/Avatar_cjs_AwXEUY8j.js +161 -0
  2. package/dist/Avatar_es_BtlaCRc5.js +157 -0
  3. package/dist/{Button_cjs_Ce97psFT.js → Button_cjs_C34BU1BK.js} +46 -34
  4. package/dist/{Button_es_CZss7cXh.js → Button_es_DnlzLBUT.js} +46 -34
  5. package/dist/ChipsGroup_cjs_DfAKN5CA.js +344 -0
  6. package/dist/{ChipsGroup_es_ayPPUwQ7.js → ChipsGroup_es_DBKY2UyF.js} +48 -35
  7. package/dist/DatePicker_cjs_DfbeIL2m.js +182 -0
  8. package/dist/DatePicker_es_BIJNx427.js +178 -0
  9. package/dist/Divider_cjs_DrmV2ezS.js +105 -0
  10. package/dist/Divider_es_BiYozVBS.js +101 -0
  11. package/dist/DropdownItem_cjs_vHuzXW9M.js +211 -0
  12. package/dist/DropdownItem_es_DVHWWgnU.js +206 -0
  13. package/dist/Group_cjs_DmfeUcFI.js +59 -0
  14. package/dist/Group_es_BU5k8f5S.js +55 -0
  15. package/dist/{Icon_cjs_Cz6IyOkb.js → Icon_cjs_BVLGzj7Y.js} +170 -157
  16. package/dist/{Icon_es_BrwLifge.js → Icon_es_DkVkzTha.js} +170 -157
  17. package/dist/Image_cjs_BUM81t4Y.js +28 -0
  18. package/dist/Image_es_C-IjVkKX.js +26 -0
  19. package/dist/{Input_cjs_DRPK_RHK.js → Input_cjs_DDi5JVAV.js} +27 -19
  20. package/dist/{Input_es_Cv5nEb_n.js → Input_es_BnCXATnh.js} +27 -19
  21. package/dist/{Label_cjs_DMoaOoHi.js → Label_cjs_DwAmukik.js} +45 -33
  22. package/dist/{Label_es_SULlg9bL.js → Label_es_B2kcstsG.js} +45 -33
  23. package/dist/{Link_cjs_C5UsZUiF.js → Link_cjs_qKXVfU8e.js} +43 -30
  24. package/dist/{Link_es_XiqbdwLp.js → Link_es_P2b6ya7P.js} +43 -30
  25. package/dist/Loader_cjs_DIDsIq3J.js +143 -0
  26. package/dist/Loader_es_CmSggwbR.js +139 -0
  27. package/dist/Overlay_cjs_tGA2fU43.js +42 -0
  28. package/dist/Overlay_es_BS7OTFoy.js +38 -0
  29. package/dist/{Scrollbar_cjs_DcKOfcNp.js → Scrollbar_cjs_Cp-7v2Mt.js} +1 -1
  30. package/dist/{Scrollbar_es_CThJeCLF.js → Scrollbar_es_CcMgNvGi.js} +1 -1
  31. package/dist/Text_cjs_BDTjOTVB.js +69 -0
  32. package/dist/Text_es_CnymlElo.js +65 -0
  33. package/dist/cjs/components/Accordion.js +37 -34
  34. package/dist/cjs/components/Avatar.js +5 -6
  35. package/dist/cjs/components/AvatarStack/stories/__mock__.js +1 -1
  36. package/dist/cjs/components/AvatarStack.js +17 -16
  37. package/dist/cjs/components/Badge.js +3 -4
  38. package/dist/cjs/components/Breadcrumbs/stories/__mock__.js +1 -1
  39. package/dist/cjs/components/Breadcrumbs.js +27 -23
  40. package/dist/cjs/components/Button.js +5 -6
  41. package/dist/cjs/components/Cell/stories/__mock__.js +1 -1
  42. package/dist/cjs/components/Cell.js +28 -25
  43. package/dist/cjs/components/Checkbox.js +33 -26
  44. package/dist/cjs/components/Checkmark.js +28 -23
  45. package/dist/cjs/components/Chips/stories/__mock__.js +1 -1
  46. package/dist/cjs/components/Chips.js +4 -5
  47. package/dist/cjs/components/Choice/stories/__mock__.js +2 -2
  48. package/dist/cjs/components/Choice.js +46 -40
  49. package/dist/cjs/components/Code.js +34 -26
  50. package/dist/cjs/components/CookiesWarning.js +23 -23
  51. package/dist/cjs/components/Dadata.js +14 -9
  52. package/dist/cjs/components/DatePeriod.js +32 -30
  53. package/dist/cjs/components/DatePicker.js +8 -9
  54. package/dist/cjs/components/Divider.js +1 -2
  55. package/dist/cjs/components/Dot.js +5 -6
  56. package/dist/cjs/components/Drawer.js +23 -21
  57. package/dist/cjs/components/Dropdown/stories/__mock__.js +6 -6
  58. package/dist/cjs/components/Dropdown.js +5 -6
  59. package/dist/cjs/components/Flex.js +11 -12
  60. package/dist/cjs/components/Grid.js +15 -16
  61. package/dist/cjs/components/Group.js +1 -2
  62. package/dist/cjs/components/HTMLContent.js +5 -6
  63. package/dist/cjs/components/HeroTitle.js +17 -16
  64. package/dist/cjs/components/Icon.js +3 -4
  65. package/dist/cjs/components/Image.js +1 -2
  66. package/dist/cjs/components/Input.js +1 -2
  67. package/dist/cjs/components/InputPassword.js +34 -26
  68. package/dist/cjs/components/Label.js +4 -5
  69. package/dist/cjs/components/Link.js +1 -2
  70. package/dist/cjs/components/List.js +39 -28
  71. package/dist/cjs/components/Loader.js +2 -3
  72. package/dist/cjs/components/Logo.js +10 -11
  73. package/dist/cjs/components/MenuItem.js +36 -33
  74. package/dist/cjs/components/Modal.js +40 -38
  75. package/dist/cjs/components/ModalSheetBottom.js +17 -18
  76. package/dist/cjs/components/Notification/stories/__mock__.js +1 -1
  77. package/dist/cjs/components/Notification.js +31 -24
  78. package/dist/cjs/components/Overlay.js +1 -2
  79. package/dist/cjs/components/Pagination.js +43 -41
  80. package/dist/cjs/components/Radio.js +34 -26
  81. package/dist/cjs/components/RangeSlider.js +8 -9
  82. package/dist/cjs/components/Response/img.js +1 -1
  83. package/dist/cjs/components/Response.js +45 -34
  84. package/dist/cjs/components/SVGContent.js +6 -7
  85. package/dist/cjs/components/ScrollOnDrag/stories/__mock__.js +2 -2
  86. package/dist/cjs/components/ScrollOnDrag.js +7 -8
  87. package/dist/cjs/components/ScrollToView.js +8 -9
  88. package/dist/cjs/components/Scrollbar/stories/__mock__.js +1 -1
  89. package/dist/cjs/components/Scrollbar.js +1 -1
  90. package/dist/cjs/components/Search.js +39 -31
  91. package/dist/cjs/components/Segmented/stories/__mock__.js +23 -10
  92. package/dist/cjs/components/Segmented.js +46 -41
  93. package/dist/cjs/components/Select.js +118 -113
  94. package/dist/cjs/components/Swiper/stories/__mock__.js +3 -3
  95. package/dist/cjs/components/Swiper.js +27 -29
  96. package/dist/cjs/components/Switch.js +33 -26
  97. package/dist/cjs/components/Tab/stories/__mock__.js +1 -1
  98. package/dist/cjs/components/Tab.js +33 -29
  99. package/dist/cjs/components/Text.js +1 -2
  100. package/dist/cjs/components/Textarea.js +26 -18
  101. package/dist/cjs/components/Tile.js +21 -17
  102. package/dist/cjs/components/Title.js +3 -4
  103. package/dist/cjs/components/Tooltip.js +3 -4
  104. package/dist/cjs/components/Video/stories/__mocks__.js +1 -1
  105. package/dist/cjs/components/Video.js +3 -4
  106. package/dist/cjs/components/Warning.js +26 -20
  107. package/dist/cjs/context/Notifications.js +38 -42
  108. package/dist/cjs/context/UIContext.js +19 -17
  109. package/dist/cjs/context/UrlAssetPrefix.js +3 -3
  110. package/dist/cjs/hoc/urlWithAssetPrefix.js +13 -16
  111. package/dist/cjs/hooks/useActiveClasses/useActiveClasses.helpers.js +13 -40
  112. package/dist/cjs/hooks/useActiveClasses/useActiveClasses.interface.js +1 -1
  113. package/dist/cjs/hooks/useActiveClasses/useActiveClasses.js +25 -29
  114. package/dist/cjs/hooks/useAppearanceConfig/useAppearanceConfig.js +13 -15
  115. package/dist/cjs/hooks/useAppearanceConfig.js +0 -1
  116. package/dist/cjs/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js +21 -28
  117. package/dist/cjs/hooks/useDevicePropsGenerator.js +0 -1
  118. package/dist/cjs/hooks/useDeviceTargetClass.js +0 -1
  119. package/dist/cjs/hooks/useStyles/styleAttributes.js +1 -1
  120. package/dist/cjs/hooks/useStyles/useStyles.js +0 -1
  121. package/dist/cjs/hooks/useStyles.js +0 -1
  122. package/dist/cjs/hooks/useViewportFix.js +5 -5
  123. package/dist/cjs/hooks.js +1 -1
  124. package/dist/cjs/utils/setViewportProperty.js +3 -3
  125. package/dist/components/Accordion.js +37 -34
  126. package/dist/components/Avatar.js +5 -6
  127. package/dist/components/AvatarStack/stories/__mock__.js +1 -1
  128. package/dist/components/AvatarStack.js +17 -16
  129. package/dist/components/Badge.js +3 -4
  130. package/dist/components/Breadcrumbs/stories/__mock__.js +1 -1
  131. package/dist/components/Breadcrumbs.js +27 -23
  132. package/dist/components/Button.js +5 -6
  133. package/dist/components/Cell/stories/__mock__.js +1 -1
  134. package/dist/components/Cell.js +28 -25
  135. package/dist/components/Checkbox.js +33 -26
  136. package/dist/components/Checkmark.js +28 -23
  137. package/dist/components/Chips/stories/__mock__.js +1 -1
  138. package/dist/components/Chips.js +4 -5
  139. package/dist/components/Choice/stories/__mock__.js +2 -2
  140. package/dist/components/Choice.js +46 -40
  141. package/dist/components/Code.js +34 -26
  142. package/dist/components/CookiesWarning.js +23 -23
  143. package/dist/components/Dadata.js +14 -9
  144. package/dist/components/DatePeriod.js +32 -30
  145. package/dist/components/DatePicker.js +8 -9
  146. package/dist/components/Divider.js +1 -2
  147. package/dist/components/Dot.js +5 -6
  148. package/dist/components/Drawer.js +23 -21
  149. package/dist/components/Dropdown/stories/__mock__.js +6 -6
  150. package/dist/components/Dropdown.js +5 -6
  151. package/dist/components/Flex.js +11 -12
  152. package/dist/components/Grid.js +15 -16
  153. package/dist/components/Group.js +1 -2
  154. package/dist/components/HTMLContent.js +5 -6
  155. package/dist/components/HeroTitle.js +17 -16
  156. package/dist/components/Icon.js +3 -4
  157. package/dist/components/Image.js +1 -2
  158. package/dist/components/Input.js +1 -2
  159. package/dist/components/InputPassword.js +34 -26
  160. package/dist/components/Label.js +4 -5
  161. package/dist/components/Link.js +1 -2
  162. package/dist/components/List.js +39 -28
  163. package/dist/components/Loader.js +2 -3
  164. package/dist/components/Logo.js +10 -11
  165. package/dist/components/MenuItem.js +36 -33
  166. package/dist/components/Modal.js +40 -38
  167. package/dist/components/ModalSheetBottom.js +17 -18
  168. package/dist/components/Notification/stories/__mock__.js +1 -1
  169. package/dist/components/Notification.js +31 -24
  170. package/dist/components/Overlay.js +1 -2
  171. package/dist/components/Pagination.js +43 -41
  172. package/dist/components/Radio.js +34 -26
  173. package/dist/components/RangeSlider.js +8 -9
  174. package/dist/components/Response/img.js +1 -1
  175. package/dist/components/Response.js +45 -34
  176. package/dist/components/SVGContent.js +6 -7
  177. package/dist/components/ScrollOnDrag/stories/__mock__.js +2 -2
  178. package/dist/components/ScrollOnDrag.js +7 -8
  179. package/dist/components/ScrollToView.js +8 -9
  180. package/dist/components/Scrollbar/stories/__mock__.js +1 -1
  181. package/dist/components/Scrollbar.js +1 -1
  182. package/dist/components/Search.js +39 -31
  183. package/dist/components/Segmented/stories/__mock__.js +23 -10
  184. package/dist/components/Segmented.js +46 -41
  185. package/dist/components/Select.js +118 -113
  186. package/dist/components/Swiper/stories/__mock__.js +3 -3
  187. package/dist/components/Swiper.js +27 -29
  188. package/dist/components/Switch.js +33 -26
  189. package/dist/components/Tab/stories/__mock__.js +1 -1
  190. package/dist/components/Tab.js +33 -29
  191. package/dist/components/Text.js +1 -2
  192. package/dist/components/Textarea.js +26 -18
  193. package/dist/components/Tile.js +21 -17
  194. package/dist/components/Title.js +3 -4
  195. package/dist/components/Tooltip.js +3 -4
  196. package/dist/components/Video/stories/__mocks__.js +1 -1
  197. package/dist/components/Video.js +3 -4
  198. package/dist/components/Warning.js +26 -20
  199. package/dist/context/Notifications.js +38 -42
  200. package/dist/context/UIContext.js +19 -17
  201. package/dist/context/UrlAssetPrefix.js +3 -3
  202. package/dist/css/components/Tile/Tile.css +3 -3
  203. package/dist/hoc/urlWithAssetPrefix.js +13 -16
  204. package/dist/hooks/useActiveClasses/useActiveClasses.helpers.js +13 -40
  205. package/dist/hooks/useActiveClasses/useActiveClasses.interface.js +1 -1
  206. package/dist/hooks/useActiveClasses/useActiveClasses.js +25 -29
  207. package/dist/hooks/useAppearanceConfig/useAppearanceConfig.js +13 -15
  208. package/dist/hooks/useAppearanceConfig.js +0 -1
  209. package/dist/hooks/useDevicePropsGenerator/useDevicePropsGenerator.js +21 -28
  210. package/dist/hooks/useDevicePropsGenerator.js +0 -1
  211. package/dist/hooks/useDeviceTargetClass.js +0 -1
  212. package/dist/hooks/useStyles/styleAttributes.js +1 -1
  213. package/dist/hooks/useStyles/useStyles.js +0 -1
  214. package/dist/hooks/useStyles.js +0 -1
  215. package/dist/hooks/useViewportFix.js +5 -5
  216. package/dist/hooks.js +1 -1
  217. package/dist/types/components/Button/Button.appearance.d.ts +232 -232
  218. package/dist/types/components/Button/Button.d.ts +4 -4
  219. package/dist/types/components/Button/Button.interface.d.ts +5 -5
  220. package/dist/types/components/Pagination/Pagination.d.ts +1 -1
  221. package/dist/types/components/Select/SelectContainer.d.ts +1 -1
  222. package/dist/types/components/Text/Text.appearance.d.ts +58 -58
  223. package/dist/types/components/Text/Text.interface.d.ts +1 -1
  224. package/dist/utils/setViewportProperty.js +3 -3
  225. package/package.json +3 -3
  226. package/dist/Avatar_cjs_CLJnKU39.js +0 -157
  227. package/dist/Avatar_es_BgN-fbOj.js +0 -153
  228. package/dist/ChipsGroup_cjs_C8L3ZeD_.js +0 -331
  229. package/dist/DatePicker_cjs_BzEtDAb8.js +0 -183
  230. package/dist/DatePicker_es_DRyCMO0I.js +0 -179
  231. package/dist/Divider_cjs_DUYtmwn2.js +0 -97
  232. package/dist/Divider_es_CCLBFIx6.js +0 -93
  233. package/dist/DropdownItem_cjs_Bhss6lyM.js +0 -207
  234. package/dist/DropdownItem_es_BXl6lPJx.js +0 -202
  235. package/dist/Group_cjs_CsJ6ICKK.js +0 -59
  236. package/dist/Group_es_DRqIIM9m.js +0 -55
  237. package/dist/Image_cjs_DRhhc66R.js +0 -29
  238. package/dist/Image_es_BpMidmve.js +0 -27
  239. package/dist/Loader_cjs_D3lnxPlI.js +0 -132
  240. package/dist/Loader_es_BUSqFrCd.js +0 -128
  241. package/dist/Overlay_cjs_CcfJYN5o.js +0 -41
  242. package/dist/Overlay_es_DF3DAdxS.js +0 -37
  243. package/dist/Text_cjs_0EINiUq4.js +0 -68
  244. package/dist/Text_es_CwV9rjFD.js +0 -64
  245. package/dist/tslib.es6_cjs_CCZ3TN_7.js +0 -59
  246. package/dist/tslib.es6_es_Bwu1Cn-t.js +0 -56
@@ -3,8 +3,7 @@ import React from 'react';
3
3
  import clsx from 'clsx';
4
4
  import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
5
5
  import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
6
- import { T as Text } from '../Text_es_CwV9rjFD.js';
7
- import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
6
+ import { T as Text } from '../Text_es_CnymlElo.js';
8
7
  import 'lodash/camelCase';
9
8
  import 'lodash/castArray';
10
9
  import 'lodash/upperFirst';
@@ -20,7 +19,7 @@ import '../hooks/useStyles/styleAttributes.js';
20
19
  import '../hooks/useStyles/useStyles.js';
21
20
  import 'lodash/maxBy';
22
21
 
23
- var switchAppearanceDefault = {
22
+ const switchAppearanceDefault = {
24
23
  defaultPrimary: {
25
24
  fill: 'surfaceTertiary',
26
25
  fillActive: 'successTertiary',
@@ -31,7 +30,7 @@ var switchAppearanceDefault = {
31
30
  },
32
31
  };
33
32
 
34
- var switchAppearanceDisabled = {
33
+ const switchAppearanceDisabled = {
35
34
  disabledPrimary: {
36
35
  fill: 'surfaceDisabled',
37
36
  fillActive: 'surfaceDisabled',
@@ -42,7 +41,7 @@ var switchAppearanceDisabled = {
42
41
  },
43
42
  };
44
43
 
45
- var switchAppearanceError = {
44
+ const switchAppearanceError = {
46
45
  errorPrimary: {
47
46
  fill: 'errorPrimary',
48
47
  fillActive: 'errorSecondary',
@@ -53,7 +52,7 @@ var switchAppearanceError = {
53
52
  },
54
53
  };
55
54
 
56
- var switchAppearanceRequire = {
55
+ const switchAppearanceRequire = {
57
56
  requirePrimary: {
58
57
  fill: 'warningPrimary',
59
58
  fillActive: 'warningSecondary',
@@ -64,7 +63,7 @@ var switchAppearanceRequire = {
64
63
  },
65
64
  };
66
65
 
67
- var switchAppearanceSize = {
66
+ const switchAppearanceSize = {
68
67
  sizeL: {
69
68
  size: 'l',
70
69
  titleTextSize: 'l',
@@ -82,7 +81,7 @@ var switchAppearanceSize = {
82
81
  },
83
82
  };
84
83
 
85
- var switchAppearanceStyle = {
84
+ const switchAppearanceStyle = {
86
85
  solid: {
87
86
  borderColor: 'none',
88
87
  },
@@ -98,7 +97,7 @@ var switchAppearanceStyle = {
98
97
  },
99
98
  };
100
99
 
101
- var switchAppearanceSuccess = {
100
+ const switchAppearanceSuccess = {
102
101
  successPrimary: {
103
102
  fill: 'successPrimary',
104
103
  fillActive: 'successPrimary',
@@ -109,32 +108,40 @@ var switchAppearanceSuccess = {
109
108
  },
110
109
  };
111
110
 
112
- var switchAppearance = __assign(__assign(__assign(__assign(__assign(__assign(__assign({}, switchAppearanceSize), switchAppearanceDisabled), switchAppearanceRequire), switchAppearanceStyle), switchAppearanceError), switchAppearanceDefault), switchAppearanceSuccess);
111
+ const switchAppearance = {
112
+ ...switchAppearanceSize,
113
+ ...switchAppearanceDisabled,
114
+ ...switchAppearanceRequire,
115
+ ...switchAppearanceStyle,
116
+ ...switchAppearanceError,
117
+ ...switchAppearanceDefault,
118
+ ...switchAppearanceSuccess,
119
+ };
113
120
 
114
- var switchConfig = {
121
+ const switchConfig = {
115
122
  appearance: switchAppearance,
116
- setAppearance: function (appearanceConfig) {
123
+ setAppearance: (appearanceConfig) => {
117
124
  switchConfig.appearance = appearanceConfig;
118
125
  },
119
126
  };
120
- var Switch = React.forwardRef(function Switch(props, ref) {
121
- var id = props.id, className = props.className, appearance = props.appearance, _a = props.align, align = _a === void 0 ? 'left' : _a, title = props.title, desc = props.desc, isDisabled = props.isDisabled, isActive = props.isActive, onChange = props.onChange;
122
- var appearanceConfig = useAppearanceConfig(appearance, switchConfig, isDisabled);
123
- var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
124
- var size = propsGenerator.size, fillActiveClass = propsGenerator.fillActiveClass, fillActiveHoverClass = propsGenerator.fillActiveHoverClass, fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, fillToggleActiveClass = propsGenerator.fillToggleActiveClass, fillToggleActiveHoverClass = propsGenerator.fillToggleActiveHoverClass, fillToggleClass = propsGenerator.fillToggleClass, fillToggleHoverClass = propsGenerator.fillToggleHoverClass, titleTextColor = propsGenerator.titleTextColor, titleTextSize = propsGenerator.titleTextSize, descTextColor = propsGenerator.descTextColor, descTextSize = propsGenerator.descTextSize;
125
- return (jsxs("div", { className: clsx('switch', className, align && "switch_align_".concat(align), size && "switch_size_".concat(size)), children: [jsxs("div", { className: "switch__wrapper", children: [title && (jsx(Text, { className: clsx('switch__title'), size: titleTextSize, textColor: titleTextColor, children: title })), desc && (jsx(Text, { className: clsx('switch__desc'), size: descTextSize, textColor: descTextColor, children: desc }))] }), jsxs("div", { className: 'switch__item', children: [jsx("input", { id: id, className: "switch__checkbox", type: "checkbox",
127
+ const Switch = React.forwardRef(function Switch(props, ref) {
128
+ const { id, className, appearance, align = 'left', title, desc, isDisabled, isActive, onChange, } = props;
129
+ const appearanceConfig = useAppearanceConfig(appearance, switchConfig, isDisabled);
130
+ const propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
131
+ const { size, fillActiveClass, fillActiveHoverClass, fillClass, fillHoverClass, fillToggleActiveClass, fillToggleActiveHoverClass, fillToggleClass, fillToggleHoverClass, titleTextColor, titleTextSize, descTextColor, descTextSize, } = propsGenerator;
132
+ return (jsxs("div", { className: clsx('switch', className, align && `switch_align_${align}`, size && `switch_size_${size}`), children: [jsxs("div", { className: "switch__wrapper", children: [title && (jsx(Text, { className: clsx('switch__title'), size: titleTextSize, textColor: titleTextColor, children: title })), desc && (jsx(Text, { className: clsx('switch__desc'), size: descTextSize, textColor: descTextColor, children: desc }))] }), jsxs("div", { className: 'switch__item', children: [jsx("input", { id: id, className: "switch__checkbox", type: "checkbox",
126
133
  // @ts-expect-error
127
134
  ref: ref, disabled: isDisabled && 'disabled', checked: isActive && 'checked', onChange: onChange }), jsx("div", { className: clsx('switch__bg', !isActive
128
- ? fillClass && "fill_".concat(fillClass)
129
- : fillActiveClass && "fill_active_".concat(fillActiveClass), !isActive
130
- ? fillHoverClass && "fill_hover_".concat(fillHoverClass)
135
+ ? fillClass && `fill_${fillClass}`
136
+ : fillActiveClass && `fill_active_${fillActiveClass}`, !isActive
137
+ ? fillHoverClass && `fill_hover_${fillHoverClass}`
131
138
  : fillActiveHoverClass &&
132
- "fill_active_hover_".concat(fillActiveHoverClass)), children: "\u00A0" }), jsx("div", { className: clsx('switch__toggle', !isActive
133
- ? fillToggleClass && "fill_".concat(fillToggleClass)
134
- : fillToggleActiveClass && "fill_active_".concat(fillToggleActiveClass), !isActive
135
- ? fillToggleHoverClass && "fill_hover_".concat(fillToggleHoverClass)
139
+ `fill_active_hover_${fillActiveHoverClass}`), children: "\u00A0" }), jsx("div", { className: clsx('switch__toggle', !isActive
140
+ ? fillToggleClass && `fill_${fillToggleClass}`
141
+ : fillToggleActiveClass && `fill_active_${fillToggleActiveClass}`, !isActive
142
+ ? fillToggleHoverClass && `fill_hover_${fillToggleHoverClass}`
136
143
  : fillToggleActiveHoverClass &&
137
- "fill_active_hover_".concat(fillToggleActiveHoverClass)), children: "\u00A0" })] })] }));
144
+ `fill_active_hover_${fillToggleActiveHoverClass}`), children: "\u00A0" })] })] }));
138
145
  });
139
146
 
140
147
  export { Switch, switchAppearance, switchConfig };
@@ -1,6 +1,6 @@
1
1
  import { icons16 } from '@itcase/icons/default';
2
2
 
3
- var tabListMock = {
3
+ const tabListMock = {
4
4
  tabList: [
5
5
  { key: 1, label: 'Tab 1', isActive: true },
6
6
  { key: 2, label: 'Tab 2', isActive: false },
@@ -5,11 +5,10 @@ import { useActiveClasses } from '../hooks/useActiveClasses/useActiveClasses.js'
5
5
  import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
6
6
  import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
7
7
  import { useStyles } from '../hooks/useStyles/useStyles.js';
8
- import { B as Badge, I as Icon } from '../Icon_es_BrwLifge.js';
9
- import { D as Divider } from '../Divider_es_CCLBFIx6.js';
10
- import { L as Link } from '../Link_es_XiqbdwLp.js';
11
- import { T as Text } from '../Text_es_CwV9rjFD.js';
12
- import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
8
+ import { B as Badge, I as Icon } from '../Icon_es_DkVkzTha.js';
9
+ import { D as Divider } from '../Divider_es_BiYozVBS.js';
10
+ import { L as Link } from '../Link_es_P2b6ya7P.js';
11
+ import { T as Text } from '../Text_es_CnymlElo.js';
13
12
  import '../hooks/useActiveClasses/useActiveClasses.helpers.js';
14
13
  import 'lodash/camelCase';
15
14
  import 'lodash/castArray';
@@ -28,7 +27,7 @@ import 'react-inlinesvg';
28
27
  import '../hoc/urlWithAssetPrefix.js';
29
28
  import '../context/UrlAssetPrefix.js';
30
29
 
31
- var tabAppearanceError = {
30
+ const tabAppearanceError = {
32
31
  errorPrimary: {
33
32
  fill: 'errorPrimary',
34
33
  fillDisabled: 'errorDisabled',
@@ -41,7 +40,7 @@ var tabAppearanceError = {
41
40
  },
42
41
  };
43
42
 
44
- var tabAppearanceSize = {
43
+ const tabAppearanceSize = {
45
44
  sizeXXL: {
46
45
  size: 'xxl',
47
46
  labelTextSize: 's',
@@ -85,7 +84,7 @@ var tabAppearanceSize = {
85
84
  },
86
85
  };
87
86
 
88
- var tabAppearanceStyle = {
87
+ const tabAppearanceStyle = {
89
88
  solid: {
90
89
  borderColor: 'none',
91
90
  borderColorActive: 'none',
@@ -101,7 +100,7 @@ var tabAppearanceStyle = {
101
100
  },
102
101
  };
103
102
 
104
- var tabAppearanceSuccess = {
103
+ const tabAppearanceSuccess = {
105
104
  successPrimary: {
106
105
  fill: 'successPrimary',
107
106
  fillDisabled: 'successDisabled',
@@ -114,7 +113,7 @@ var tabAppearanceSuccess = {
114
113
  },
115
114
  };
116
115
 
117
- var tabAppearanceSurface = {
116
+ const tabAppearanceSurface = {
118
117
  surfacePrimary: {
119
118
  fill: 'surfacePrimary',
120
119
  fillActive: 'surfacePrimary',
@@ -178,7 +177,7 @@ var tabAppearanceSurface = {
178
177
  },
179
178
  };
180
179
 
181
- var tabAppearanceWarning = {
180
+ const tabAppearanceWarning = {
182
181
  warningPrimary: {
183
182
  fill: 'warningPrimary',
184
183
  fillDisabled: 'warningDisabled',
@@ -191,38 +190,43 @@ var tabAppearanceWarning = {
191
190
  },
192
191
  };
193
192
 
194
- var tabAppearance = __assign(__assign(__assign(__assign(__assign(__assign({}, tabAppearanceWarning), tabAppearanceError), tabAppearanceSuccess), tabAppearanceSurface), tabAppearanceSize), tabAppearanceStyle);
193
+ const tabAppearance = {
194
+ ...tabAppearanceWarning,
195
+ ...tabAppearanceError,
196
+ ...tabAppearanceSuccess,
197
+ ...tabAppearanceSurface,
198
+ ...tabAppearanceSize,
199
+ ...tabAppearanceStyle,
200
+ };
195
201
 
196
- var tabConfig = {
202
+ const tabConfig = {
197
203
  appearance: tabAppearance,
198
- setAppearance: function (appearanceConfig) {
204
+ setAppearance: (appearanceConfig) => {
199
205
  tabConfig.appearance = appearanceConfig;
200
206
  },
201
207
  };
202
208
  function Tab(props) {
203
- var appearance = props.appearance, className = props.className, dataTestId = props.dataTestId, dataTour = props.dataTour, label = props.label, badgeValue = props.badgeValue, href = props.href, link = props.link, rel = props.rel, target = props.target, before = props.before, after = props.after, _a = props.isActive, isActive = _a === void 0 ? false : _a, _b = props.isDisabled, isDisabled = _b === void 0 ? false : _b, isSkeleton = props.isSkeleton, onClick = props.onClick, onMouseEnter = props.onMouseEnter, children = props.children;
204
- var appearanceConfig = useAppearanceConfig(appearance, tabConfig, isDisabled);
205
- var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
206
- var rootClasses = useActiveClasses({
209
+ const { appearance, className, dataTestId, dataTour, label, badgeValue, href, link, rel, target, before, after, isActive = false, isDisabled = false, isSkeleton, onClick, onMouseEnter, children, } = props;
210
+ const appearanceConfig = useAppearanceConfig(appearance, tabConfig, isDisabled);
211
+ const propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
212
+ const { rootClasses } = useActiveClasses({
207
213
  propsGenerator: propsGenerator,
208
214
  isActive: isActive,
209
215
  isDisabled: isDisabled,
210
- }).rootClasses;
211
- var justifyContentClass = propsGenerator.justifyContentClass, alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, labelTextAlign = propsGenerator.labelTextAlign, labelTextColor = propsGenerator.labelTextColor, labelTextColorActive = propsGenerator.labelTextColorActive, labelTextColorActiveHover = propsGenerator.labelTextColorActiveHover, labelTextColorHover = propsGenerator.labelTextColorHover, labelTextSize = propsGenerator.labelTextSize, labelTextStyle = propsGenerator.labelTextStyle, labelTextWeight = propsGenerator.labelTextWeight, labelTextWrap = propsGenerator.labelTextWrap, badgeAppearance = propsGenerator.badgeAppearance, badgeAppearanceSize = propsGenerator.badgeAppearanceSize, badgeShape = propsGenerator.badgeShape, badgeSize = propsGenerator.badgeSize, badgeTextColor = propsGenerator.badgeTextColor, badgeTextSize = propsGenerator.badgeTextSize, dividerFill = propsGenerator.dividerFill, dividerFillActive = propsGenerator.dividerFillActive, dividerFillActiveHover = propsGenerator.dividerFillActiveHover, dividerFillDisabled = propsGenerator.dividerFillDisabled, dividerFillHover = propsGenerator.dividerFillHover, dividerSize = propsGenerator.dividerSize, icon = propsGenerator.icon, iconFill = propsGenerator.iconFill, iconFillIcon = propsGenerator.iconFillIcon, iconFillSize = propsGenerator.iconFillSize, iconShape = propsGenerator.iconShape, iconSize = propsGenerator.iconSize, iconSrc = propsGenerator.iconSrc, linkFill = propsGenerator.linkFill, shapeClass = propsGenerator.shapeClass, shapeStrengthClass = propsGenerator.shapeStrengthClass, sizeClass = propsGenerator.sizeClass, widthClass = propsGenerator.widthClass;
216
+ });
217
+ const { justifyContentClass, alignClass, labelTextAlign, labelTextColor, labelTextColorActive, labelTextColorActiveHover, labelTextColorHover, labelTextSize, labelTextStyle, labelTextWeight, labelTextWrap, badgeAppearance, badgeAppearanceSize, badgeShape, badgeSize, badgeTextColor, badgeTextSize, dividerFill, dividerFillActive, dividerFillActiveHover, dividerFillDisabled, dividerFillHover, dividerSize, icon, iconFill, iconFillIcon, iconFillSize, iconShape, iconSize, iconSrc, linkFill, shapeClass, shapeStrengthClass, sizeClass, widthClass, } = propsGenerator;
212
218
  // @ts-expect-error
213
- var tab = useStyles(props).styles;
214
- console.log(badgeAppearance);
215
- console.log(badgeAppearanceSize);
216
- return (jsx("div", { className: clsx('tab', className, rootClasses, isActive && 'tab_state_active', isDisabled && 'tab_state_disabled', sizeClass && "tab_size_".concat(sizeClass), shapeClass && "shape_".concat(shapeClass), shapeStrengthClass && "shape-strength_".concat(shapeStrengthClass), widthClass && "width_".concat(widthClass), justifyContentClass && "tab_justify-content_".concat(justifyContentClass), isSkeleton && "tab_skeleton", onClick && 'cursor_type_pointer'), "data-test-id": dataTestId && "".concat(dataTestId, "Tab"), "data-tour": dataTour, style: tab, onClick: onClick, onMouseEnter: onMouseEnter, children: jsxs(Link, { className: clsx('tab__link', alignDirectionClass && "align_".concat(alignDirectionClass), alignClass && "align_".concat(alignClass), !isDisabled && 'cursor_type_pointer'), fill: linkFill, href: link || href, rel: rel, target: target, children: [before, children || (jsxs(React.Fragment, { children: [jsxs("div", { className: "tab__wrapper", children: [label && (jsx(Text, { className: "tab__label", size: labelTextSize, textAlign: labelTextAlign, textColor: labelTextColor, textColorActive: labelTextColorActive, textColorHover: labelTextColorHover, textColorHoverActive: labelTextColorActiveHover, textStyle: labelTextStyle, textWeight: labelTextWeight, textWrap: labelTextWrap, isActive: isActive, isDisabled: isDisabled, children: label })), Boolean(badgeValue) && (jsx(Badge, { appearance: "".concat(badgeAppearance, " ").concat(badgeAppearanceSize), size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), (icon || iconSrc) && (jsx(Icon, { className: clsx('tab__icon_after'), fill: iconFill, fillSize: iconFillSize, iconFill: iconFillIcon, iconSize: iconSize, imageSrc: iconSrc, shape: iconShape, SvgImage: icon }))] }), jsx(Divider, { className: clsx('tab__divider'), width: "fill", direction: "horizontal", size: dividerSize, fill: dividerFill, fillActive: dividerFillActive, fillActiveHover: dividerFillActiveHover, fillDisabled: dividerFillDisabled, fillHover: dividerFillHover, zIndex: "1", isActive: isActive, isDisabled: isDisabled })] })), after] }) }));
219
+ const { styles: tab } = useStyles(props);
220
+ return (jsx("div", { className: clsx('tab', className, rootClasses, isActive && 'tab_state_active', isDisabled && 'tab_state_disabled', sizeClass && `tab_size_${sizeClass}`, shapeClass && `shape_${shapeClass}`, shapeStrengthClass && `shape-strength_${shapeStrengthClass}`, widthClass && `width_${widthClass}`, justifyContentClass && `tab_justify-content_${justifyContentClass}`, isSkeleton && `tab_skeleton`, onClick && 'cursor_type_pointer'), "data-test-id": dataTestId && `${dataTestId}Tab`, "data-tour": dataTour, style: tab, onClick: onClick, onMouseEnter: onMouseEnter, children: jsxs(Link, { className: clsx('tab__link', !isDisabled && 'cursor_type_pointer'), fill: linkFill, href: link || href, rel: rel, target: target, children: [before, children || (jsxs(React.Fragment, { children: [jsxs("div", { className: clsx('tab__wrapper', alignClass && `align_${alignClass}`), children: [label && (jsx(Text, { className: "tab__label", size: labelTextSize, textAlign: labelTextAlign, textColor: labelTextColor, textColorActive: labelTextColorActive, textColorHover: labelTextColorHover, textColorHoverActive: labelTextColorActiveHover, textStyle: labelTextStyle, textWeight: labelTextWeight, textWrap: labelTextWrap, isActive: isActive, isDisabled: isDisabled, children: label })), Boolean(badgeValue) && (jsx(Badge, { appearance: `${badgeAppearance} ${badgeAppearanceSize}`, size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), (icon || iconSrc) && (jsx(Icon, { className: clsx('tab__icon_after'), fill: iconFill, fillSize: iconFillSize, iconFill: iconFillIcon, iconSize: iconSize, imageSrc: iconSrc, shape: iconShape, SvgImage: icon }))] }), jsx(Divider, { className: clsx('tab__divider'), width: "fill", direction: "horizontal", size: dividerSize, fill: dividerFill, fillActive: dividerFillActive, fillActiveHover: dividerFillActiveHover, fillDisabled: dividerFillDisabled, fillHover: dividerFillHover, zIndex: "1", isActive: isActive, isDisabled: isDisabled })] })), after] }) }));
217
221
  }
218
222
 
219
223
  function TabGroup(props) {
220
- var dataTestId = props.dataTestId, dataTour = props.dataTour, className = props.className, horizontalScroll = props.horizontalScroll, style = props.style, tabAppearance = props.tabAppearance, tabList = props.tabList, children = props.children;
221
- var propsGenerator = useDevicePropsGenerator(props);
222
- var directionClass = propsGenerator.directionClass, alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, fillClass = propsGenerator.fillClass, borderColorClass = propsGenerator.borderColorClass, borderTypeClass = propsGenerator.borderTypeClass, borderWidthClass = propsGenerator.borderWidthClass, widthClass = propsGenerator.widthClass, wrapClass = propsGenerator.wrapClass;
224
+ const { dataTestId, dataTour, className, horizontalScroll, style, tabAppearance, tabList, children, } = props;
225
+ const propsGenerator = useDevicePropsGenerator(props);
226
+ const { directionClass, alignClass, alignDirectionClass, fillClass, borderColorClass, borderTypeClass, borderWidthClass, widthClass, wrapClass, } = propsGenerator;
223
227
  // @ts-expect-error
224
- var _a = useStyles(props), groupStyles = _a.styles, groupWrapperStyles = _a.wrapper;
225
- return (jsx("div", { className: clsx(className, 'tab-group', 'group', widthClass && "width_".concat(widthClass), alignDirectionClass && "align_".concat(alignDirectionClass), directionClass && "group_direction_".concat(directionClass), alignClass && "align_".concat(alignClass), fillClass && "fill_".concat(fillClass), horizontalScroll && 'group_type_horizontal_scroll', wrapClass && "group_wrap_".concat(wrapClass), borderColorClass && "border-color_".concat(borderColorClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass)), "data-test-id": dataTestId, "data-tour": dataTour, style: Object.assign({}, groupStyles, style), children: horizontalScroll ? (jsxs("div", { className: "tab-group__wrapper", style: groupWrapperStyles, children: [tabList === null || tabList === void 0 ? void 0 : tabList.map(function (item) { return (jsx(Tab, { appearance: tabAppearance, label: item.label, isActive: item.isActive }, item.key)); }), children] })) : (jsxs(React.Fragment, { children: [tabList === null || tabList === void 0 ? void 0 : tabList.map(function (item) { return (jsx(Tab, { appearance: tabAppearance, label: item.label, badgeValue: item.badgeValue, icon: item.icon, iconSrc: item.icon, isActive: item.isActive }, item.key)); }), children] })) }));
228
+ const { styles: groupStyles, wrapper: groupWrapperStyles } = useStyles(props);
229
+ return (jsx("div", { className: clsx(className, 'tab-group', 'group', widthClass && `width_${widthClass}`, alignDirectionClass && `align_${alignDirectionClass}`, directionClass && `group_direction_${directionClass}`, alignClass && `align_${alignClass}`, fillClass && `fill_${fillClass}`, horizontalScroll && 'group_type_horizontal_scroll', wrapClass && `group_wrap_${wrapClass}`, borderColorClass && `border-color_${borderColorClass}`, borderWidthClass && `border-width_${borderWidthClass}`, borderTypeClass && `border_type_${borderTypeClass}`), "data-test-id": dataTestId, "data-tour": dataTour, style: Object.assign({}, groupStyles, style), children: horizontalScroll ? (jsxs("div", { className: "tab-group__wrapper", style: groupWrapperStyles, children: [tabList?.map((item) => (jsx(Tab, { appearance: tabAppearance, label: item.label, isActive: item.isActive }, item.key))), children] })) : (jsxs(React.Fragment, { children: [tabList?.map((item) => (jsx(Tab, { appearance: tabAppearance, label: item.label, badgeValue: item.badgeValue, icon: item.icon, iconSrc: item.icon, isActive: item.isActive }, item.key))), children] })) }));
226
230
  }
227
231
 
228
232
  export { Tab, TabGroup, tabAppearance, tabConfig };
@@ -1,8 +1,7 @@
1
- export { T as Text, a as textAppearance, t as textConfig } from '../Text_es_CwV9rjFD.js';
1
+ export { T as Text, a as textAppearance, t as textConfig } from '../Text_es_CnymlElo.js';
2
2
  import 'react/jsx-runtime';
3
3
  import 'clsx';
4
4
  import '../hooks/useAppearanceConfig/useAppearanceConfig.js';
5
- import '../tslib.es6_es_Bwu1Cn-t.js';
6
5
  import 'react';
7
6
  import '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
8
7
  import 'lodash/camelCase';
@@ -2,7 +2,6 @@ import { jsx } from 'react/jsx-runtime';
2
2
  import clsx from 'clsx';
3
3
  import { useAppearanceConfig } from '../hooks/useAppearanceConfig/useAppearanceConfig.js';
4
4
  import { useDevicePropsGenerator } from '../hooks/useDevicePropsGenerator/useDevicePropsGenerator.js';
5
- import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
6
5
  import 'react';
7
6
  import 'lodash/camelCase';
8
7
  import 'lodash/castArray';
@@ -17,7 +16,7 @@ import '../utils/setViewportProperty.js';
17
16
  import '../hooks.js';
18
17
  import '../hooks/useStyles/styleAttributes.js';
19
18
 
20
- var textareaAppearanceDefault = {
19
+ const textareaAppearanceDefault = {
21
20
  defaultPrimary: {
22
21
  fill: 'surfaceSecondary',
23
22
  fillHover: 'surfaceTertiary',
@@ -54,7 +53,7 @@ var textareaAppearanceDefault = {
54
53
  },
55
54
  };
56
55
 
57
- var textareaAppearanceDisabled = {
56
+ const textareaAppearanceDisabled = {
58
57
  disabledPrimary: {
59
58
  fill: 'surfaceDisabled',
60
59
  borderColor: 'errorBorderQuaternary',
@@ -74,7 +73,7 @@ var textareaAppearanceDisabled = {
74
73
  },
75
74
  };
76
75
 
77
- var textareaAppearanceError = {
76
+ const textareaAppearanceError = {
78
77
  errorPrimary: {
79
78
  fill: 'errorTertiary',
80
79
  borderColor: 'errorBorderQuaternary',
@@ -94,7 +93,7 @@ var textareaAppearanceError = {
94
93
  },
95
94
  };
96
95
 
97
- var textareaAppearanceRequire = {
96
+ const textareaAppearanceRequire = {
98
97
  requirePrimary: {
99
98
  fill: 'warningTertiary',
100
99
  borderColor: 'warningBorderQuaternary',
@@ -114,7 +113,7 @@ var textareaAppearanceRequire = {
114
113
  },
115
114
  };
116
115
 
117
- var textareaAppearanceShape = {
116
+ const textareaAppearanceShape = {
118
117
  circular: {
119
118
  shape: 'circular',
120
119
  },
@@ -139,7 +138,7 @@ var textareaAppearanceShape = {
139
138
  },
140
139
  };
141
140
 
142
- var textareaAppearanceSize = {
141
+ const textareaAppearanceSize = {
143
142
  sizeXXL: {
144
143
  size: 'xxl',
145
144
  textSize: 'l',
@@ -170,7 +169,7 @@ var textareaAppearanceSize = {
170
169
  },
171
170
  };
172
171
 
173
- var textareaAppearanceStyle = {
172
+ const textareaAppearanceStyle = {
174
173
  solid: {
175
174
  borderColor: 'none',
176
175
  borderColorHover: 'none',
@@ -186,7 +185,7 @@ var textareaAppearanceStyle = {
186
185
  },
187
186
  };
188
187
 
189
- var textareaAppearanceSuccess = {
188
+ const textareaAppearanceSuccess = {
190
189
  successPrimary: {
191
190
  fill: 'successTertiary',
192
191
  fillHover: 'successTertiary',
@@ -207,21 +206,30 @@ var textareaAppearanceSuccess = {
207
206
  },
208
207
  };
209
208
 
210
- var textareaAppearance = __assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, textareaAppearanceDefault), textareaAppearanceShape), textareaAppearanceError), textareaAppearanceSuccess), textareaAppearanceRequire), textareaAppearanceDisabled), textareaAppearanceSize), textareaAppearanceStyle);
209
+ const textareaAppearance = {
210
+ ...textareaAppearanceDefault,
211
+ ...textareaAppearanceShape,
212
+ ...textareaAppearanceError,
213
+ ...textareaAppearanceSuccess,
214
+ ...textareaAppearanceRequire,
215
+ ...textareaAppearanceDisabled,
216
+ ...textareaAppearanceSize,
217
+ ...textareaAppearanceStyle,
218
+ };
211
219
 
212
- var textareaConfig = {
220
+ const textareaConfig = {
213
221
  appearance: textareaAppearance,
214
- setAppearance: function (appearanceConfig) {
222
+ setAppearance: (appearanceConfig) => {
215
223
  textareaConfig.appearance = appearanceConfig;
216
224
  },
217
225
  };
218
226
  function Textarea(props) {
219
- var id = props.id, className = props.className, appearance = props.appearance, isDisabled = props.isDisabled, placeholder = props.placeholder, value = props.value, onBlur = props.onBlur, onChange = props.onChange, onFocus = props.onFocus, onKeyDown = props.onKeyDown;
220
- var appearanceConfig = useAppearanceConfig(appearance, textareaConfig, isDisabled);
221
- var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
222
- var fillClass = propsGenerator.fillClass, fillHoverClass = propsGenerator.fillHoverClass, borderColorClass = propsGenerator.borderColorClass, borderHoverClass = propsGenerator.borderHoverClass, borderWidthClass = propsGenerator.borderWidthClass, textColorClass = propsGenerator.textColorClass, textSizeClass = propsGenerator.textSizeClass, textWeightClass = propsGenerator.textWeightClass, caretClass = propsGenerator.caretClass, placeholderTextColorClass = propsGenerator.placeholderTextColorClass, shapeClass = propsGenerator.shapeClass, shapeStrengthClass = propsGenerator.shapeStrengthClass, sizeClass = propsGenerator.sizeClass, widthClass = propsGenerator.widthClass;
223
- return (jsx("div", { className: clsx('textarea', className, sizeClass && "textarea_size_".concat(sizeClass)), children: jsx("textarea", { id: id, className: clsx('textarea__input', (textSizeClass || textColorClass || textWeightClass) && 'text', caretClass && "caret-color_".concat(caretClass), fillClass && "fill_".concat(fillClass), fillHoverClass && "fill_hover_".concat(fillHoverClass), borderColorClass && "border-color_".concat(borderColorClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderHoverClass && "border-color_hover_".concat(borderHoverClass), shapeClass && "shape_".concat(shapeClass), shapeStrengthClass && "shape-strength_".concat(shapeStrengthClass), placeholderTextColorClass &&
224
- "placeholder-text-color_".concat(placeholderTextColorClass), textSizeClass && "text_size_".concat(textSizeClass), textColorClass && "text-color_".concat(textColorClass), textWeightClass && "text-weight_".concat(textWeightClass), widthClass && "width_".concat(widthClass)), disabled: isDisabled && 'disabled', placeholder: placeholder, value: value, onBlur: onBlur, onChange: onChange, onFocus: onFocus, onKeyDown: onKeyDown }) }));
227
+ const { id, className, appearance, isDisabled, placeholder, value, onBlur, onChange, onFocus, onKeyDown, } = props;
228
+ const appearanceConfig = useAppearanceConfig(appearance, textareaConfig, isDisabled);
229
+ const propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
230
+ const { fillClass, fillHoverClass, borderColorClass, borderHoverClass, borderWidthClass, textColorClass, textSizeClass, textWeightClass, caretClass, placeholderTextColorClass, shapeClass, shapeStrengthClass, sizeClass, widthClass, } = propsGenerator;
231
+ return (jsx("div", { className: clsx('textarea', className, sizeClass && `textarea_size_${sizeClass}`), children: jsx("textarea", { id: id, className: clsx('textarea__input', (textSizeClass || textColorClass || textWeightClass) && 'text', caretClass && `caret-color_${caretClass}`, fillClass && `fill_${fillClass}`, fillHoverClass && `fill_hover_${fillHoverClass}`, borderColorClass && `border-color_${borderColorClass}`, borderWidthClass && `border-width_${borderWidthClass}`, borderHoverClass && `border-color_hover_${borderHoverClass}`, shapeClass && `shape_${shapeClass}`, shapeStrengthClass && `shape-strength_${shapeStrengthClass}`, placeholderTextColorClass &&
232
+ `placeholder-text-color_${placeholderTextColorClass}`, textSizeClass && `text_size_${textSizeClass}`, textColorClass && `text-color_${textColorClass}`, textWeightClass && `text-weight_${textWeightClass}`, widthClass && `width_${widthClass}`), disabled: isDisabled && 'disabled', placeholder: placeholder, value: value, onBlur: onBlur, onChange: onChange, onFocus: onFocus, onKeyDown: onKeyDown }) }));
225
233
  }
226
234
 
227
235
  export { Textarea, textareaAppearance, textareaConfig };
@@ -3,9 +3,8 @@ import clsx from 'clsx';
3
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 { b as Title, B as Badge, I as Icon } from '../Icon_es_BrwLifge.js';
7
- import { T as Text } from '../Text_es_CwV9rjFD.js';
8
- import { _ as __assign } from '../tslib.es6_es_Bwu1Cn-t.js';
6
+ import { b as Title, B as Badge, I as Icon } from '../Icon_es_DkVkzTha.js';
7
+ import { T as Text } from '../Text_es_CnymlElo.js';
9
8
  import 'react';
10
9
  import 'lodash/camelCase';
11
10
  import 'lodash/castArray';
@@ -23,9 +22,9 @@ import 'lodash/maxBy';
23
22
  import 'react-inlinesvg';
24
23
  import '../hoc/urlWithAssetPrefix.js';
25
24
  import '../context/UrlAssetPrefix.js';
26
- import '../Link_es_XiqbdwLp.js';
25
+ import '../Link_es_P2b6ya7P.js';
27
26
 
28
- var tileAppearanceShape = {
27
+ const tileAppearanceShape = {
29
28
  circular: {
30
29
  shape: 'circular',
31
30
  },
@@ -50,7 +49,7 @@ var tileAppearanceShape = {
50
49
  },
51
50
  };
52
51
 
53
- var tileAppearanceSize = {
52
+ const tileAppearanceSize = {
54
53
  sizeXL: {
55
54
  size: 'xl',
56
55
  titleTextSize: 'h4',
@@ -101,7 +100,7 @@ var tileAppearanceSize = {
101
100
  },
102
101
  };
103
102
 
104
- var tileAppearanceStyle = {
103
+ const tileAppearanceStyle = {
105
104
  solid: {
106
105
  borderColor: 'none',
107
106
  },
@@ -115,7 +114,7 @@ var tileAppearanceStyle = {
115
114
  },
116
115
  };
117
116
 
118
- var tileAppearanceSurface = {
117
+ const tileAppearanceSurface = {
119
118
  surfacePrimary: {
120
119
  fill: 'surfacePrimary',
121
120
  titleTextColor: 'surfaceTextPrimary',
@@ -150,22 +149,27 @@ var tileAppearanceSurface = {
150
149
  },
151
150
  };
152
151
 
153
- var tileAppearance = __assign(__assign(__assign(__assign({}, tileAppearanceShape), tileAppearanceSize), tileAppearanceStyle), tileAppearanceSurface);
152
+ const tileAppearance = {
153
+ ...tileAppearanceShape,
154
+ ...tileAppearanceSize,
155
+ ...tileAppearanceStyle,
156
+ ...tileAppearanceSurface,
157
+ };
154
158
 
155
- var tileConfig = {
159
+ const tileConfig = {
156
160
  appearance: tileAppearance,
157
- setAppearance: function (appearanceConfig) {
161
+ setAppearance: (appearanceConfig) => {
158
162
  tileConfig.appearance = appearanceConfig;
159
163
  },
160
164
  };
161
165
  function Tile(props) {
162
- var className = props.className, type = props.type, appearance = props.appearance, title = props.title, desc = props.desc, badgeValue = props.badgeValue, before = props.before, after = props.after, isSkeleton = props.isSkeleton, onClick = props.onClick, children = props.children;
163
- var appearanceConfig = useAppearanceConfig(appearance, tileConfig);
164
- var propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
165
- var dataTestId = propsGenerator.dataTestId, dataTour = propsGenerator.dataTour, directionClass = propsGenerator.directionClass, alignClass = propsGenerator.alignClass, alignDirectionClass = propsGenerator.alignDirectionClass, 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, 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, shapeStrengthClass = propsGenerator.shapeStrengthClass, sizeClass = propsGenerator.sizeClass, widthClass = propsGenerator.widthClass;
166
+ const { className, type, appearance, title, desc, badgeValue, before, after, isSkeleton, onClick, children, } = props;
167
+ const appearanceConfig = useAppearanceConfig(appearance, tileConfig);
168
+ const propsGenerator = useDevicePropsGenerator(props, appearanceConfig);
169
+ const { dataTestId, dataTour, directionClass, alignClass, alignDirectionClass, fillClass, titleTextAlign, titleTextColor, titleTextSize, titleTextWeight, titleTextWrap, descTextColor, descTextSize, descTextWrap, borderColorClass, borderColorHoverClass, borderTypeClass, borderWidthClass, badgeAppearance, badgeAppearanceSize, badgeShape, badgeSize, badgeTextColor, badgeTextSize, icon, iconAppearance, iconFill, iconFillIcon, iconFillSize, iconShape, iconSize, iconSrc, shapeClass, shapeStrengthClass, sizeClass, widthClass, } = propsGenerator;
166
170
  // @ts-expect-error
167
- var tileStyles = useStyles(props).styles;
168
- return (jsx("div", { className: clsx('tile', className, fillClass && "fill_".concat(fillClass), shapeClass && "shape_".concat(shapeClass), shapeStrengthClass && "shape-strength_".concat(shapeStrengthClass), alignClass && "align_".concat(alignClass), directionClass && "direction_".concat(directionClass), borderColorClass && "border-color_".concat(borderColorClass), borderColorHoverClass && "border-color_hover_".concat(borderColorHoverClass), borderWidthClass && "border-width_".concat(borderWidthClass), borderTypeClass && "border_type_".concat(borderTypeClass), sizeClass && "tile_size_".concat(sizeClass), type && "tile_type_".concat(type), badgeValue && "tile_state_badge", widthClass && "width_".concat(widthClass), isSkeleton && "tile_skeleton"), "data-test-id": dataTestId, "data-tour": dataTour, style: tileStyles, onClick: onClick, children: jsxs("div", { className: clsx('tile__wrapper', alignClass, alignDirectionClass), children: [before, jsxs("div", { className: "tile__header", children: [jsxs("div", { className: "tile__header-inner", children: [title && (jsx(Title, { className: "tile__title", size: titleTextSize, textAlign: titleTextAlign, textColor: titleTextColor, textWeight: titleTextWeight, textWrap: titleTextWrap, children: title })), desc && (jsx(Text, { className: "tile__text", size: descTextSize, textColor: descTextColor, textWrap: descTextWrap, children: desc }))] }), jsxs("div", { className: "tile__header-actions", children: [badgeValue && (jsx(Badge, { className: "tile__badge", appearance: "".concat(badgeAppearance, " ").concat(badgeAppearanceSize), size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), (icon || iconSrc) && (jsx(Icon, { className: "tile__icon", appearance: iconAppearance, fill: iconFill, fillSize: iconFillSize, iconFill: iconFillIcon, iconSize: iconSize, imageSrc: iconSrc, shape: iconShape, SvgImage: icon }))] })] }), children, after] }) }));
171
+ const { styles: tileStyles } = useStyles(props);
172
+ return (jsx("div", { className: clsx('tile', className, fillClass && `fill_${fillClass}`, shapeClass && `shape_${shapeClass}`, shapeStrengthClass && `shape-strength_${shapeStrengthClass}`, alignClass && `align_${alignClass}`, directionClass && `direction_${directionClass}`, borderColorClass && `border-color_${borderColorClass}`, borderColorHoverClass && `border-color_hover_${borderColorHoverClass}`, borderWidthClass && `border-width_${borderWidthClass}`, borderTypeClass && `border_type_${borderTypeClass}`, sizeClass && `tile_size_${sizeClass}`, type && `tile_type_${type}`, badgeValue && `tile_state_badge`, widthClass && `width_${widthClass}`, isSkeleton && `tile_skeleton`), "data-test-id": dataTestId, "data-tour": dataTour, style: tileStyles, onClick: onClick, children: jsxs("div", { className: clsx('tile__wrapper', alignClass, alignDirectionClass), children: [before, jsxs("div", { className: "tile__header", children: [jsxs("div", { className: "tile__header-inner", children: [title && (jsx(Title, { className: "tile__title", size: titleTextSize, textAlign: titleTextAlign, textColor: titleTextColor, textWeight: titleTextWeight, textWrap: titleTextWrap, children: title })), desc && (jsx(Text, { className: "tile__text", size: descTextSize, textColor: descTextColor, textWrap: descTextWrap, children: desc }))] }), jsxs("div", { className: "tile__header-actions", children: [badgeValue && (jsx(Badge, { className: "tile__badge", appearance: `${badgeAppearance} ${badgeAppearanceSize}`, size: badgeSize, textColor: badgeTextColor, textSize: badgeTextSize, shape: badgeShape, value: badgeValue })), (icon || iconSrc) && (jsx(Icon, { className: "tile__icon", appearance: iconAppearance, fill: iconFill, fillSize: iconFillSize, iconFill: iconFillIcon, iconSize: iconSize, imageSrc: iconSrc, shape: iconShape, SvgImage: icon }))] })] }), children, after] }) }));
169
173
  }
170
174
 
171
175
  export { Tile, tileAppearance, tileConfig };
@@ -1,5 +1,4 @@
1
- export { b as Title, d as titleAppearance, c as titleConfig } from '../Icon_es_BrwLifge.js';
2
- import '../tslib.es6_es_Bwu1Cn-t.js';
1
+ export { b as Title, d as titleAppearance, c as titleConfig } from '../Icon_es_DkVkzTha.js';
3
2
  import 'react/jsx-runtime';
4
3
  import 'react';
5
4
  import 'clsx';
@@ -22,5 +21,5 @@ import '../hooks.js';
22
21
  import '../hooks/useStyles/styleAttributes.js';
23
22
  import '../hooks/useStyles/useStyles.js';
24
23
  import 'lodash/maxBy';
25
- import '../Link_es_XiqbdwLp.js';
26
- import '../Text_es_CwV9rjFD.js';
24
+ import '../Link_es_P2b6ya7P.js';
25
+ import '../Text_es_CnymlElo.js';
@@ -1,5 +1,4 @@
1
- export { T as Tooltip, a as tooltipAppearance, t as tooltipConfig } from '../Icon_es_BrwLifge.js';
2
- import '../tslib.es6_es_Bwu1Cn-t.js';
1
+ export { T as Tooltip, a as tooltipAppearance, t as tooltipConfig } from '../Icon_es_DkVkzTha.js';
3
2
  import 'react/jsx-runtime';
4
3
  import 'react';
5
4
  import 'clsx';
@@ -22,5 +21,5 @@ import '../hooks.js';
22
21
  import '../hooks/useStyles/styleAttributes.js';
23
22
  import '../hooks/useStyles/useStyles.js';
24
23
  import 'lodash/maxBy';
25
- import '../Link_es_XiqbdwLp.js';
26
- import '../Text_es_CwV9rjFD.js';
24
+ import '../Link_es_P2b6ya7P.js';
25
+ import '../Text_es_CnymlElo.js';
@@ -1,4 +1,4 @@
1
- var videoMock = {
1
+ const videoMock = {
2
2
  mp4: 'https://www.w3schools.com/html/mov_bbb.mp4',
3
3
  ogv: 'https://upload.wikimedia.org/wikipedia/commons/7/79/Big_Buck_Bunny_small.ogv',
4
4
  poster: '../avatar/Man.png',
@@ -6,7 +6,6 @@ import 'lodash/camelCase';
6
6
  import 'lodash/maxBy';
7
7
  import 'lodash/upperFirst';
8
8
  import '../context/Notifications.js';
9
- import '../tslib.es6_es_Bwu1Cn-t.js';
10
9
  import 'uuid';
11
10
  import '@itcase/common';
12
11
  import '../context/UIContext.js';
@@ -17,9 +16,9 @@ import '../hooks.js';
17
16
  import '../hooks/useStyles/styleAttributes.js';
18
17
 
19
18
  function Video(props) {
20
- var id = props.id, className = props.className, position = props.position, mp4 = props.mp4, ogv = props.ogv, poster = props.poster, webm = props.webm, children = props.children;
21
- var videoStyles = useStyles(props).styles;
22
- return (jsxs("div", { id: id, className: clsx('video', className, poster && "video_poster", position && "video_position_".concat(position)), style: videoStyles, children: [jsxs("video", { className: "video__wrapper", autoPlay: true, loop: true, muted: true, playsInline: false, poster: poster, children: [webm && jsx("source", { type: "video/webm", src: webm, codecs: "vp8, vorbis" }), ogv && jsx("source", { type: "video/ogg", src: ogv, codecs: "theora, vorbis" }), mp4 && (jsx("source", { type: "video/mp4", src: mp4, codecs: "avc1.42E01E, mp4a.40.2" }))] }), children] }));
19
+ const { id, className, position, mp4, ogv, poster, webm, children } = props;
20
+ const { styles: videoStyles } = useStyles(props);
21
+ return (jsxs("div", { id: id, className: clsx('video', className, poster && `video_poster`, position && `video_position_${position}`), style: videoStyles, children: [jsxs("video", { className: "video__wrapper", autoPlay: true, loop: true, muted: true, playsInline: false, poster: poster, children: [webm && jsx("source", { type: "video/webm", src: webm, codecs: "vp8, vorbis" }), ogv && jsx("source", { type: "video/ogg", src: ogv, codecs: "theora, vorbis" }), mp4 && (jsx("source", { type: "video/mp4", src: mp4, codecs: "avc1.42E01E, mp4a.40.2" }))] }), children] }));
23
22
  }
24
23
 
25
24
  export { Video };