@moysklad/uikit 28.1.0 → 30.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (372) hide show
  1. package/README.md +3 -0
  2. package/dist/colorVariables.css +10 -0
  3. package/dist/components/AutoComplete/AutoComplete.d.ts +4 -2
  4. package/dist/components/AutoComplete/AutoComplete.js +45 -31
  5. package/dist/components/Badge/Badge.js +2 -3
  6. package/dist/components/Badge/Badge_module.css +2 -3
  7. package/dist/components/BottomSheet/BottomSheet.js +2 -2
  8. package/dist/components/Breadcrumbs/BreadcrumbItem.d.ts +5 -3
  9. package/dist/components/Breadcrumbs/BreadcrumbItem.js +39 -8
  10. package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +4 -1
  11. package/dist/components/Breadcrumbs/Breadcrumbs.js +10 -6
  12. package/dist/components/Button/Button.d.ts +1 -0
  13. package/dist/components/Button/Button.js +2 -2
  14. package/dist/components/Button/Button.module.js +1 -0
  15. package/dist/components/Button/Button_module.css +4 -0
  16. package/dist/components/Carousel/Carousel.js +5 -4
  17. package/dist/components/Checkbox/Checkbox.d.ts +1 -1
  18. package/dist/components/Chip/Chip.helpers.js +5 -2
  19. package/dist/components/Chip/Chip.js +9 -3
  20. package/dist/components/Chip/Chip.legacy_module.css +2 -2
  21. package/dist/components/Chip/Chip.types.d.ts +10 -4
  22. package/dist/components/Chip/Chip_module.css +5 -5
  23. package/dist/components/Chip/components/ChipLabel.d.ts +3 -1
  24. package/dist/components/Chip/components/ChipLabel.js +4 -2
  25. package/dist/components/Chip/components/ChipMainButton.d.ts +3 -4
  26. package/dist/components/Chip/components/ChipMainButton.js +2 -1
  27. package/dist/components/Chip/components/ChipRoot.d.ts +3 -2
  28. package/dist/components/Chip/components/ChipRoot.js +2 -1
  29. package/dist/components/Dropdown/Dropdown.d.ts +2 -0
  30. package/dist/components/Dropdown/Dropdown.js +7 -4
  31. package/dist/components/Dropdown/hooks/usePosition.d.ts +2 -1
  32. package/dist/components/Dropdown/hooks/usePosition.js +3 -3
  33. package/dist/components/EditableTitle/EditableTitle.js +1 -1
  34. package/dist/components/FieldLabel/FieldLabel.constants.d.ts +1 -0
  35. package/dist/components/FieldLabel/FieldLabel.constants.js +5 -0
  36. package/dist/components/FieldLabel/FieldLabel.d.ts +17 -0
  37. package/dist/components/FieldLabel/FieldLabel.js +76 -0
  38. package/dist/components/FieldLabel/FieldLabel.module.js +11 -0
  39. package/dist/components/FieldLabel/FieldLabel_module.css +42 -0
  40. package/dist/components/FieldLabel/components/HelpButton.d.ts +8 -0
  41. package/dist/components/FieldLabel/components/HelpButton.js +15 -0
  42. package/dist/components/FieldLabel/components/HelpButton.module.js +5 -0
  43. package/dist/components/FieldLabel/components/HelpButton_module.css +8 -0
  44. package/dist/components/FieldLabel/components/index.d.ts +1 -0
  45. package/dist/components/FieldLabel/components/index.js +1 -0
  46. package/dist/components/FileUploader/FileUploader.helpers.d.ts +1 -0
  47. package/dist/components/FileUploader/FileUploader.helpers.js +4 -1
  48. package/dist/components/FileUploader/FileUploader.js +3 -1
  49. package/dist/components/FileUploader/FileUploader.types.d.ts +1 -0
  50. package/dist/components/FileUploader/components/FileUploaderPreview/FileUploaderPreview.js +4 -4
  51. package/dist/components/Help/Help.d.ts +12 -5
  52. package/dist/components/Help/Help.js +22 -7
  53. package/dist/components/Help/Help.module.js +6 -2
  54. package/dist/components/Help/Help_module.css +36 -8
  55. package/dist/components/Hint/Hint.js +4 -5
  56. package/dist/components/Hint/Hint.module.js +2 -3
  57. package/dist/components/Hint/Hint_module.css +0 -9
  58. package/dist/components/Info/Info.d.ts +1 -4
  59. package/dist/components/Info/Info.js +27 -4
  60. package/dist/components/Info/Info.module.js +4 -1
  61. package/dist/components/Info/Info_module.css +21 -0
  62. package/dist/components/Input/Input.d.ts +10 -0
  63. package/dist/components/Input/Input.js +93 -42
  64. package/dist/components/Input/Input.module.js +19 -3
  65. package/dist/components/Input/Input_module.css +156 -19
  66. package/dist/components/Input/components/InfoBlock.d.ts +12 -0
  67. package/dist/components/Input/components/InfoBlock.js +29 -0
  68. package/dist/components/InputClear/InputClear.d.ts +5 -2
  69. package/dist/components/InputClear/InputClear.js +10 -4
  70. package/dist/components/InputClear/InputClear.module.js +3 -1
  71. package/dist/components/InputClear/InputClear_module.css +23 -10
  72. package/dist/components/InputUnit/InputUnit.d.ts +3 -0
  73. package/dist/components/InputUnit/InputUnit.js +42 -32
  74. package/dist/components/InputUnit/InputUnit.module.js +6 -1
  75. package/dist/components/InputUnit/InputUnit_module.css +27 -29
  76. package/dist/components/InputUnit/SelectUnit/SelectUnit.d.ts +1 -1
  77. package/dist/components/InputUnit/SelectUnit/SelectUnit.js +1 -4
  78. package/dist/components/InputUnit/SelectUnit/SelectUnit.module.js +1 -0
  79. package/dist/components/InputUnit/SelectUnit/SelectUnitVisible.d.ts +1 -1
  80. package/dist/components/InputUnit/SelectUnit/SelectUnitVisible.js +7 -2
  81. package/dist/components/InputUnit/SelectUnit/SelectUnit_module.css +29 -37
  82. package/dist/components/InputUnit/SelectUnit/type.d.ts +1 -0
  83. package/dist/components/InputUnit/Unit/Unit.js +1 -2
  84. package/dist/components/InputUnit/Unit/Unit_module.css +1 -0
  85. package/dist/components/Label/Label.d.ts +1 -0
  86. package/dist/components/LabelValue/LabelValue.js +18 -52
  87. package/dist/components/LabelValue/LabelValue.module.js +0 -3
  88. package/dist/components/LabelValue/LabelValue_module.css +0 -17
  89. package/dist/components/LabelValueCheckbox/LabelValueCheckbox.d.ts +10 -0
  90. package/dist/components/LabelValueCheckbox/LabelValueCheckbox.js +22 -0
  91. package/dist/components/LabelValueCheckbox/LabelValueCheckbox.module.js +5 -0
  92. package/dist/components/LabelValueCheckbox/LabelValueCheckbox_module.css +5 -0
  93. package/dist/components/LabelValueSelect/Input/Input_module.css +1 -3
  94. package/dist/components/MentionsTextfield/MentionsTextfield.d.ts +1 -1
  95. package/dist/components/MentionsTextfield/MentionsTextfield.js +41 -25
  96. package/dist/components/MentionsTextfield/OptionForStory/OptionForStory.d.ts +7 -0
  97. package/dist/components/MentionsTextfield/OptionForStory/OptionForStory.js +27 -0
  98. package/dist/components/MentionsTextfield/OptionForStory/OptionForStory.module.js +8 -0
  99. package/dist/components/MentionsTextfield/OptionForStory/OptionForStory_module.css +25 -0
  100. package/dist/components/MentionsTextfield/OptionForStory/index.d.ts +1 -0
  101. package/dist/components/MentionsTextfield/OptionForStory/index.js +1 -0
  102. package/dist/components/Multiselect/DropdownContent/MultiselectDropdownContent.js +5 -4
  103. package/dist/components/Multiselect/Input/Input_module.css +1 -3
  104. package/dist/components/Multiselect/Multiselect.d.ts +4 -0
  105. package/dist/components/Select/Combobox/Combobox_module.css +2 -6
  106. package/dist/components/Select/DropDownWithColors/DropDownWithColors.d.ts +1 -0
  107. package/dist/components/Select/DropDownWithColors/DropDownWithColors.js +2 -1
  108. package/dist/components/Select/DropdownActionsContainer/DropdownActionsContainer.d.ts +3 -0
  109. package/dist/components/Select/DropdownActionsContainer/DropdownActionsContainer.js +17 -0
  110. package/dist/components/Select/DropdownActionsContainer/DropdownActionsContainer.module.js +6 -0
  111. package/dist/components/Select/DropdownActionsContainer/DropdownActionsContainer_module.css +12 -0
  112. package/dist/components/Select/OptionsList/OptionsList.d.ts +2 -1
  113. package/dist/components/Select/OptionsList/OptionsList.js +3 -2
  114. package/dist/components/Select/OptionsList/OptionsList_module.css +4 -0
  115. package/dist/components/Select/Select.d.ts +8 -2
  116. package/dist/components/Select/Select.js +29 -34
  117. package/dist/components/Select/Select.module.js +1 -2
  118. package/dist/components/Select/Select_module.css +2 -14
  119. package/dist/components/Select/ShortVariant/ShortVariant.d.ts +5 -1
  120. package/dist/components/Select/ShortVariant/ShortVariant.js +5 -4
  121. package/dist/components/Select/ShortVariant/ShortVariant.module.js +1 -0
  122. package/dist/components/Select/ShortVariant/ShortVariant_module.css +5 -1
  123. package/dist/components/Select/types.d.ts +1 -0
  124. package/dist/components/Select/useDropdownPadding.d.ts +5 -0
  125. package/dist/components/Select/useDropdownPadding.js +22 -0
  126. package/dist/components/Textfield/Textfield.d.ts +18 -2
  127. package/dist/components/Textfield/Textfield.js +37 -13
  128. package/dist/components/Textfield/Textfield.module.js +2 -1
  129. package/dist/components/Textfield/Textfield_module.css +95 -23
  130. package/dist/components/Textfield/components/ActionButton/ActionButton.d.ts +9 -0
  131. package/dist/components/Textfield/components/ActionButton/ActionButton.js +12 -0
  132. package/dist/components/Textfield/components/ActionButton/ActionButton.module.js +9 -0
  133. package/dist/components/Textfield/components/ActionButton/ActionButton_module.css +54 -0
  134. package/dist/components/Textfield/components/ActionButton/index.d.ts +1 -0
  135. package/dist/components/Textfield/components/ActionButton/index.js +1 -0
  136. package/dist/components/Textfield/components/Container/Container.js +6 -3
  137. package/dist/components/Textfield/components/Counter/Counter.d.ts +3 -1
  138. package/dist/components/Textfield/components/Counter/Counter.js +5 -3
  139. package/dist/components/Textfield/components/Info/Info.d.ts +3 -1
  140. package/dist/components/Textfield/components/Info/Info.js +9 -4
  141. package/dist/components/Textfield/components/InnerContainer/InnerContainer.d.ts +3 -6
  142. package/dist/components/Textfield/components/InnerContainer/InnerContainer.js +2 -8
  143. package/dist/components/Textfield/components/InputContainer/InputContainer.d.ts +14 -3
  144. package/dist/components/Textfield/components/InputContainer/InputContainer.js +74 -5
  145. package/dist/components/Textfield/components/InputContainer/InputContainer.module.js +7 -1
  146. package/dist/components/Textfield/components/InputContainer/InputContainer_module.css +36 -7
  147. package/dist/components/Textfield/components/Label/Label.d.ts +2 -0
  148. package/dist/components/Textfield/components/Label/Label.js +11 -5
  149. package/dist/components/Textfield/components/Label/Label_module.css +1 -1
  150. package/dist/components/Textfield/components/ResizeHandle/ResizeHandle.d.ts +10 -0
  151. package/dist/components/Textfield/components/ResizeHandle/ResizeHandle.js +50 -0
  152. package/dist/components/Textfield/components/ResizeHandle/ResizeHandle.module.js +7 -0
  153. package/dist/components/Textfield/components/ResizeHandle/ResizeHandle_module.css +21 -0
  154. package/dist/components/Textfield/components/ResizeHandle/index.d.ts +1 -0
  155. package/dist/components/Textfield/components/ResizeHandle/index.js +1 -0
  156. package/dist/components/Textfield/consts/index.d.ts +2 -0
  157. package/dist/components/Textfield/consts/index.js +3 -0
  158. package/dist/components/Textfield/types/index.d.ts +12 -0
  159. package/dist/components/Textfield/types/index.js +5 -0
  160. package/dist/components/Textfield/utils/index.d.ts +3 -0
  161. package/dist/components/Textfield/utils/index.js +8 -0
  162. package/dist/components/Tooltip/Tooltip.d.ts +4 -1
  163. package/dist/components/Tooltip/Tooltip.js +9 -9
  164. package/dist/components/Tooltip/Tooltip.module.js +3 -1
  165. package/dist/components/Tooltip/Tooltip_module.css +13 -3
  166. package/dist/components/Tooltip/{consts.d.ts → constants/ArrowAlign.d.ts} +0 -2
  167. package/dist/components/Tooltip/constants/TooltipBodyColor.d.ts +4 -0
  168. package/dist/components/Tooltip/constants/TooltipBodyColor.js +5 -0
  169. package/dist/components/Tooltip/constants/index.d.ts +2 -0
  170. package/dist/components/Tooltip/constants/index.js +2 -0
  171. package/dist/components/Tooltip/hooks.d.ts +2 -2
  172. package/dist/components/Tooltip/hooks.js +1 -1
  173. package/dist/components/Tooltip/types.d.ts +4 -0
  174. package/dist/components/Tooltip/types.js +0 -0
  175. package/dist/components/ViewersStack/ViewersStack.d.ts +13 -0
  176. package/dist/components/ViewersStack/ViewersStack.js +77 -0
  177. package/dist/components/ViewersStack/ViewersStack.module.js +7 -0
  178. package/dist/components/ViewersStack/ViewersStack_module.css +18 -0
  179. package/dist/components/ViewersStack/components/Avatar/Avatar.d.ts +13 -0
  180. package/dist/components/ViewersStack/components/Avatar/Avatar.js +35 -0
  181. package/dist/components/ViewersStack/components/Avatar/Avatar.module.js +13 -0
  182. package/dist/components/ViewersStack/components/Avatar/Avatar_module.css +45 -0
  183. package/dist/components/ViewersStack/components/Counter/Counter.d.ts +9 -0
  184. package/dist/components/ViewersStack/components/Counter/Counter.js +27 -0
  185. package/dist/components/ViewersStack/components/Counter/Counter.module.js +5 -0
  186. package/dist/components/ViewersStack/components/Counter/Counter_module.css +20 -0
  187. package/dist/components/ViewersStack/components/ViewersTooltip/ViewersTooltip.d.ts +15 -0
  188. package/dist/components/ViewersStack/components/ViewersTooltip/ViewersTooltip.js +41 -0
  189. package/dist/components/ViewersStack/components/ViewersTooltip/ViewersTooltip.module.js +6 -0
  190. package/dist/components/ViewersStack/components/ViewersTooltip/ViewersTooltip_module.css +14 -0
  191. package/dist/components/ViewersStack/components/ViewersTooltipOverlayItem/ViewersTooltipOverlayItem.d.ts +6 -0
  192. package/dist/components/ViewersStack/components/ViewersTooltipOverlayItem/ViewersTooltipOverlayItem.js +53 -0
  193. package/dist/components/ViewersStack/components/ViewersTooltipOverlayItem/ViewersTooltipOverlayItem.module.js +7 -0
  194. package/dist/components/ViewersStack/components/ViewersTooltipOverlayItem/ViewersTooltipOverlayItem_module.css +18 -0
  195. package/dist/components/ViewersStack/components/common.module.js +7 -0
  196. package/dist/components/ViewersStack/components/common_module.css +27 -0
  197. package/dist/components/ViewersStack/types.d.ts +22 -0
  198. package/dist/components/ViewersStack/types.js +17 -0
  199. package/dist/components/ViewersStack/utils.d.ts +3 -0
  200. package/dist/components/ViewersStack/utils.js +17 -0
  201. package/dist/components/{EditableTitle → _shared/HintWithSkip}/HintWithSkip.d.ts +1 -1
  202. package/dist/components/{EditableTitle → _shared/HintWithSkip}/HintWithSkip.js +1 -1
  203. package/dist/data-grid/Table/Table.d.ts +14 -22
  204. package/dist/data-grid/Table/Table.js +99 -61
  205. package/dist/data-grid/Table/Table.module.js +2 -0
  206. package/dist/data-grid/Table/Table_module.css +23 -0
  207. package/dist/data-grid/Table/components/Body/Body.d.ts +10 -14
  208. package/dist/data-grid/Table/components/Body/Body.js +11 -47
  209. package/dist/data-grid/Table/components/DraggableRow/DraggableRow.js +1 -1
  210. package/dist/data-grid/Table/components/Footer/Footer.module.js +0 -1
  211. package/dist/data-grid/Table/components/Footer/FooterContent.d.ts +9 -0
  212. package/dist/data-grid/Table/components/Footer/{Footer.js → FooterContent.js} +4 -5
  213. package/dist/data-grid/Table/components/Footer/Footer_module.css +0 -5
  214. package/dist/data-grid/Table/components/Header/Header.module.js +0 -1
  215. package/dist/data-grid/Table/components/Header/HeaderCell.js +3 -1
  216. package/dist/data-grid/Table/components/Header/HeaderContent.d.ts +1 -0
  217. package/dist/data-grid/Table/components/Header/{Header.js → HeaderContent.js} +8 -6
  218. package/dist/data-grid/Table/components/Header/Header_module.css +0 -15
  219. package/dist/data-grid/Table/components/Row/Row.d.ts +13 -0
  220. package/dist/data-grid/Table/components/Row/Row.js +40 -0
  221. package/dist/data-grid/Table/components/Row/Row.module.js +14 -0
  222. package/dist/data-grid/Table/components/{TableRow/TableRow_module.css → Row/Row_module.css} +7 -7
  223. package/dist/data-grid/Table/components/SubRows/SubRows.d.ts +5 -4
  224. package/dist/data-grid/Table/components/SubRows/SubRows.js +3 -3
  225. package/dist/data-grid/Table/components/TableCell/TableCell.js +2 -0
  226. package/dist/data-grid/Table/components/TableDragOverlay/TableDragOverlay.d.ts +5 -6
  227. package/dist/data-grid/Table/components/TableDragOverlay/TableDragOverlay.js +2 -2
  228. package/dist/data-grid/Table/components/TableRow/TableRow.d.ts +6 -14
  229. package/dist/data-grid/Table/components/TableRow/TableRow.js +34 -25
  230. package/dist/data-grid/Table/components/VirtualTable/VirtualTable.d.ts +10 -0
  231. package/dist/data-grid/Table/components/VirtualTable/VirtualTable.js +78 -0
  232. package/dist/data-grid/Table/components/VirtualTable/VirtualTableRow.d.ts +11 -0
  233. package/dist/data-grid/Table/components/VirtualTable/VirtualTableRow.js +18 -0
  234. package/dist/data-grid/Table/components/index.d.ts +3 -3
  235. package/dist/data-grid/Table/components/index.js +2 -2
  236. package/dist/data-grid/Table/constants.d.ts +2 -0
  237. package/dist/data-grid/Table/constants.js +3 -1
  238. package/dist/data-grid/Table/hooks/index.d.ts +1 -0
  239. package/dist/data-grid/Table/hooks/index.js +1 -0
  240. package/dist/data-grid/Table/hooks/useRowContext.d.ts +16 -0
  241. package/dist/data-grid/Table/hooks/useRowContext.js +44 -0
  242. package/dist/data-grid/Table/hooks/useTableContext.d.ts +7 -2
  243. package/dist/data-grid/Table/hooks/useTableContext.js +12 -2
  244. package/dist/data-grid/Table/index.d.ts +2 -2
  245. package/dist/data-grid/Table/types.d.ts +8 -1
  246. package/dist/data-grid/Table/types.js +5 -0
  247. package/dist/data-grid/Table/utils/compareColumnIds.d.ts +1 -0
  248. package/dist/data-grid/Table/utils/compareColumnIds.js +6 -0
  249. package/dist/data-grid/Table/utils/getColumnWidthStyles.d.ts +5 -0
  250. package/dist/data-grid/Table/utils/getColumnWidthStyles.js +4 -1
  251. package/dist/data-grid/Table/utils/getTableColumnIds.d.ts +3 -0
  252. package/dist/data-grid/Table/utils/getTableColumnIds.js +5 -0
  253. package/dist/data-grid/Table/utils/index.d.ts +2 -0
  254. package/dist/data-grid/Table/utils/index.js +2 -0
  255. package/dist/data-grid/Table/utils/withDnD.js +1 -1
  256. package/dist/data-grid/base/DropdownItem/DropdownItem.d.ts +3 -3
  257. package/dist/data-grid/base/DropdownItem/DropdownItem.js +3 -2
  258. package/dist/data-grid/base/OverflowHint/OverflowHint.d.ts +1 -0
  259. package/dist/data-grid/base/OverflowHint/OverflowHint.js +5 -3
  260. package/dist/data-grid/base/OverflowHint/utils.d.ts +1 -0
  261. package/dist/data-grid/base/OverflowHint/utils.js +7 -0
  262. package/dist/data-grid/cells/AutoCompleteCell/AutoCompleteCell.js +3 -4
  263. package/dist/data-grid/cells/DecimalCell/DecimalCell_module.css +1 -1
  264. package/dist/data-grid/cells/FileCell/FileCell_module.css +1 -1
  265. package/dist/data-grid/cells/ImageCell/ImageCell.d.ts +1 -0
  266. package/dist/data-grid/cells/ImageCell/ImageCell.js +5 -2
  267. package/dist/data-grid/cells/IndexCheckboxDndCell/IndexCheckboxDndCell.d.ts +7 -2
  268. package/dist/data-grid/cells/IndexCheckboxDndCell/IndexCheckboxDndCell.js +6 -4
  269. package/dist/data-grid/cells/InputCell/InputCell.js +3 -4
  270. package/dist/data-grid/cells/IntegerCell/IntegerCell_module.css +1 -1
  271. package/dist/data-grid/cells/LinkCell/LinkCell_module.css +1 -1
  272. package/dist/data-grid/cells/NameCell/NameCell.js +3 -0
  273. package/dist/data-grid/cells/NameCell/NameCell_module.css +2 -2
  274. package/dist/data-grid/cells/NumberInputCell/NumberInputCell.js +19 -17
  275. package/dist/data-grid/cells/SelectCell/SelectCell.js +3 -4
  276. package/dist/data-grid/cells/TextCell/TextCell_module.css +1 -1
  277. package/dist/data-grid/cells/ToggleCell/ToggleCell_module.css +1 -1
  278. package/dist/data-grid/cells/components/EditableCellWrapper/EditableCellWrapper.d.ts +3 -0
  279. package/dist/data-grid/cells/components/EditableCellWrapper/EditableCellWrapper.js +9 -0
  280. package/dist/data-grid/cells/components/EditableCellWrapper/EditableCellWrapper.module.js +5 -0
  281. package/dist/data-grid/cells/{NumberInputCell/NumberInputCell_module.css → components/EditableCellWrapper/EditableCellWrapper_module.css} +2 -2
  282. package/dist/data-grid/cells/components/EditableCellWrapper/index.d.ts +1 -0
  283. package/dist/data-grid/cells/components/EditableCellWrapper/index.js +1 -0
  284. package/dist/data-grid/cells/components/RowActionsMenu/RowActionsMenu.d.ts +4 -3
  285. package/dist/data-grid/cells/components/RowActionsMenu/RowActionsMenu.js +13 -13
  286. package/dist/data-grid/cells/components/TableInput/TableInput.js +19 -3
  287. package/dist/data-grid/cells/components/TableInput/TableInput_module.css +1 -1
  288. package/dist/data-grid/cells/components/TableNumberInput/TableNumberInput.d.ts +4 -3
  289. package/dist/data-grid/cells/components/TableNumberInput/TableNumberInput.js +44 -55
  290. package/dist/data-grid/cells/components/TableSelect/ActionButton/ActionButton.d.ts +4 -1
  291. package/dist/data-grid/cells/components/TableSelect/ActionButton/ActionButton.js +4 -3
  292. package/dist/data-grid/cells/components/TableSelect/TableSelect.d.ts +15 -10
  293. package/dist/data-grid/cells/components/TableSelect/TableSelect.js +11 -7
  294. package/dist/data-grid/cells/components/index.d.ts +1 -0
  295. package/dist/data-grid/cells/components/index.js +1 -0
  296. package/dist/data-grid/cells/index.d.ts +1 -1
  297. package/dist/data-grid/cells/index.js +1 -1
  298. package/dist/data-grid/headers/PlainTextHeader.js +3 -2
  299. package/dist/data-grid/headers/components/Dropdown/DropdownArrowBtn/DropdownArrowBtn.js +5 -1
  300. package/dist/data-grid/headers/components/Dropdown/Option/Option.d.ts +1 -1
  301. package/dist/data-grid/headers/components/Dropdown/Option/Option.js +2 -2
  302. package/dist/data-grid/headers/components/Dropdown/Option/Option_module.css +10 -2
  303. package/dist/data-grid/headers/components/HeaderBuilder/HeaderBuilder.d.ts +13 -3
  304. package/dist/data-grid/headers/components/HeaderBuilder/HeaderBuilder.js +64 -83
  305. package/dist/data-grid/headers/components/HeaderBuilder/HeaderBuilder.module.js +2 -1
  306. package/dist/data-grid/headers/components/HeaderBuilder/HeaderBuilder_module.css +21 -0
  307. package/dist/data-grid/headers/components/HeaderSortGroups/components/SortByOption/SortByOption.js +7 -15
  308. package/dist/data-grid/headers/components/HideColumn/HideColumn.js +8 -13
  309. package/dist/data-grid/headers/components/ResetFilter/ResetFilter.js +7 -10
  310. package/dist/data-grid/headers/components/ResetFilter/ResetFilter.module.js +0 -1
  311. package/dist/data-grid/headers/components/ResetFilter/ResetFilter_module.css +1 -21
  312. package/dist/data-grid/headers/components/index.d.ts +1 -1
  313. package/dist/data-grid/headers/index.d.ts +1 -1
  314. package/dist/data-grid/headers/types/types.d.ts +1 -0
  315. package/dist/data-grid/types/index.d.ts +1 -0
  316. package/dist/data-grid/utils/isOverflowed.js +21 -1
  317. package/dist/hooks/useDebounceCallback/useDebounceCallback.d.ts +2 -0
  318. package/dist/hooks/useDebounceCallback/useDebounceCallback.js +21 -0
  319. package/dist/hooks/useDismissOnFocusOutside/index.d.ts +2 -1
  320. package/dist/hooks/useDismissOnFocusOutside/index.js +4 -3
  321. package/dist/hooks/useDismissOnOutsideClick/index.d.ts +2 -1
  322. package/dist/hooks/useDismissOnOutsideClick/index.js +4 -3
  323. package/dist/hooks/useTextField/useTextField.d.ts +4 -5
  324. package/dist/hooks/useTextField/useTextField.js +6 -24
  325. package/dist/hooks/useUnmount/useUnmount.d.ts +1 -0
  326. package/dist/hooks/useUnmount/useUnmount.js +9 -0
  327. package/dist/icon/components/MyApps12Icon.d.ts +8 -0
  328. package/dist/icon/components/MyApps12Icon.js +18 -0
  329. package/dist/icon/components/MyApps16Icon.d.ts +8 -0
  330. package/dist/icon/components/MyApps16Icon.js +17 -0
  331. package/dist/icon/components/MyApps20Icon.d.ts +8 -0
  332. package/dist/icon/components/MyApps20Icon.js +18 -0
  333. package/dist/icon/components/Smile12Icon.d.ts +8 -0
  334. package/dist/icon/components/Smile12Icon.js +17 -0
  335. package/dist/icon/components/Smile16Icon.d.ts +8 -0
  336. package/dist/icon/components/Smile16Icon.js +16 -0
  337. package/dist/icon/components/Smile20Icon.d.ts +8 -0
  338. package/dist/icon/components/Smile20Icon.js +17 -0
  339. package/dist/icon/index.d.ts +6 -0
  340. package/dist/icon/index.js +6 -0
  341. package/dist/index.d.ts +4 -4
  342. package/dist/index.js +3 -1
  343. package/dist/utils/debounce/debounce.d.ts +10 -0
  344. package/dist/utils/debounce/debounce.js +73 -0
  345. package/dist/utils/isRecordEqual/isRecordEqual.d.ts +1 -0
  346. package/dist/utils/isRecordEqual/isRecordEqual.js +9 -0
  347. package/dist/utils/utils.d.ts +2 -0
  348. package/dist/utils/utils.js +2 -0
  349. package/package.json +22 -3
  350. package/dist/components/LabelValue/HelpButton/HelpButton.module.js +0 -8
  351. package/dist/components/LabelValue/HelpButton/HelpButton_module.css +0 -44
  352. package/dist/components/LabelValue/HelpButton/index.d.ts +0 -8
  353. package/dist/components/LabelValue/HelpButton/index.js +0 -36
  354. package/dist/components/Textfield/components/ClearIcon/ClearIcon.d.ts +0 -6
  355. package/dist/components/Textfield/components/ClearIcon/ClearIcon.js +0 -13
  356. package/dist/components/Textfield/components/ClearIcon/ClearIcon.module.js +0 -6
  357. package/dist/components/Textfield/components/ClearIcon/ClearIcon_module.css +0 -11
  358. package/dist/data-grid/Table/components/Footer/Footer.d.ts +0 -9
  359. package/dist/data-grid/Table/components/Header/Header.d.ts +0 -8
  360. package/dist/data-grid/Table/components/TableRow/TableRow.module.js +0 -14
  361. package/dist/data-grid/cells/AutoCompleteCell/AutoCompleteCell.module.js +0 -5
  362. package/dist/data-grid/cells/AutoCompleteCell/AutoCompleteCell_module.css +0 -8
  363. package/dist/data-grid/cells/InputCell/InputCell.module.js +0 -5
  364. package/dist/data-grid/cells/InputCell/InputCell_module.css +0 -8
  365. package/dist/data-grid/cells/NumberInputCell/NumberInputCell.module.js +0 -5
  366. package/dist/data-grid/cells/SelectCell/SelectCell.module.js +0 -8
  367. package/dist/data-grid/cells/SelectCell/SelectCell_module.css +0 -33
  368. package/dist/data-grid/headers/components/HeaderSortGroups/components/SortByOption/SortByOption.module.js +0 -7
  369. package/dist/data-grid/headers/components/HeaderSortGroups/components/SortByOption/SortByOption_module.css +0 -22
  370. package/dist/data-grid/headers/components/HideColumn/HideColumn.module.js +0 -6
  371. package/dist/data-grid/headers/components/HideColumn/HideColumn_module.css +0 -20
  372. /package/dist/components/Tooltip/{consts.js → constants/ArrowAlign.js} +0 -0
package/README.md CHANGED
@@ -75,6 +75,7 @@ ReactDOM.render(
75
75
  - EditableTitle
76
76
  - EmptyState
77
77
  - EmptyStateLarge
78
+ - FieldLabel
78
79
  - FieldRow
79
80
  - FileUploader
80
81
  - H1
@@ -93,6 +94,7 @@ ReactDOM.render(
93
94
  - InputUnit
94
95
  - Label
95
96
  - LabelValue
97
+ - LabelValueCheckbox
96
98
  - LabelValueDate
97
99
  - LabelValueInput
98
100
  - LabelValueSelect
@@ -125,4 +127,5 @@ ReactDOM.render(
125
127
  - Tooltip
126
128
  - Typography
127
129
  - VerticalTab
130
+ - ViewersStack
128
131
  - VStack
@@ -77,6 +77,7 @@
77
77
  --button-secondary-disabled: var(--light-grey-100);
78
78
  --border-normal: var(--light-grey-400);
79
79
  --border-hover: var(--dark-grey-grey-800);
80
+ --border-focused: var(--dark-grey-dark-900);
80
81
  --border-disable: var(--light-grey-200);
81
82
  --border-accent: var(--product-blue-700);
82
83
  --border-critical: var(--colorful-red-600);
@@ -170,6 +171,15 @@
170
171
  --status-black-01-bg: #c5c7cc;
171
172
  }
172
173
  }
174
+
175
+ @layer viewers-stack {
176
+ :root {
177
+ --viewers-stack-green: #bae86b;
178
+ --viewers-stack-yellow: #ffcc71;
179
+ --viewers-stack-pink: #ffcad0;
180
+ --viewers-stack-violet: #b9aaff;
181
+ }
182
+ }
173
183
  }
174
184
  }
175
185
 
@@ -1,6 +1,6 @@
1
1
  import { type ReactNode } from 'react';
2
2
  import type { IHasTabIndex, IHasTestId } from '../../common/types';
3
- import type { ISelectOption } from '../Select/types';
3
+ import type { IRenderActionsOptions, ISelectOption } from '../Select/types';
4
4
  import type { IRenderDropdownContentOptions, RenderInputOptions } from './type';
5
5
  export interface AutoCompleteProps<T, R> extends IHasTestId, IHasTabIndex {
6
6
  /** @deprecated задается через компонент в renderInput **/
@@ -25,8 +25,10 @@ export interface AutoCompleteProps<T, R> extends IHasTestId, IHasTabIndex {
25
25
  renderInput: ({ inputId, ref, onOpen, onClose, onChange, }: RenderInputOptions<R>) => ReactNode;
26
26
  renderDropdownContent?: (options: IRenderDropdownContentOptions<T>) => ReactNode;
27
27
  helpComponent?: ReactNode;
28
+ renderDropdownActions?: (options: IRenderActionsOptions) => ReactNode;
29
+ maxDropdownHeight?: number;
28
30
  }
29
31
  export declare const AutoComplete: {
30
- <T, R extends HTMLElement>({ testId, className, optionClassName, dropdownClassName, label, info, required, error, warning, disabled, dropdownZIndex, offsetY, offsetX, options, onSelectOption, renderInput, renderDropdownContent, helpComponent, id, }: AutoCompleteProps<T, R>): import("react/jsx-runtime").JSX.Element;
32
+ <T, R extends HTMLElement>({ testId, className, optionClassName, dropdownClassName, label, info, required, error, warning, disabled, dropdownZIndex, offsetY, offsetX, options, onSelectOption, renderInput, renderDropdownContent, helpComponent, id, renderDropdownActions, maxDropdownHeight, }: AutoCompleteProps<T, R>): import("react/jsx-runtime").JSX.Element;
31
33
  displayName: string;
32
34
  };
@@ -8,8 +8,10 @@ import { Info } from "../Info/Info.js";
8
8
  import { Label } from "../Label/Label.js";
9
9
  import { OptionsList } from "../Select/OptionsList/OptionsList.js";
10
10
  import { useId } from "../../hooks/useId/index.js";
11
+ import { DropdownActionsContainer } from "../Select/DropdownActionsContainer/DropdownActionsContainer.js";
12
+ import { useDropdownPadding } from "../Select/useDropdownPadding.js";
11
13
  import AutoComplete_module from "./AutoComplete.module.js";
12
- const AutoComplete = ({ testId, className, optionClassName, dropdownClassName, label, info, required, error, warning, disabled, dropdownZIndex, offsetY = 0, offsetX = 0, options, onSelectOption, renderInput, renderDropdownContent, helpComponent, id })=>{
14
+ const AutoComplete = ({ testId, className, optionClassName, dropdownClassName, label, info, required, error, warning, disabled, dropdownZIndex, offsetY = 0, offsetX = 0, options, onSelectOption, renderInput, renderDropdownContent, helpComponent, id, renderDropdownActions, maxDropdownHeight })=>{
13
15
  const [cursor, setCursor] = useState(null);
14
16
  const inputId = useId(id);
15
17
  const { open, triggerRef, handleClose, handleOpen, triggerAriaProps: baseTriggerAriaProps, dropdownAriaProps } = useDropdown({
@@ -27,6 +29,7 @@ const AutoComplete = ({ testId, className, optionClassName, dropdownClassName, l
27
29
  open,
28
30
  options
29
31
  ]);
32
+ const { scrollPaddings, dropdownActionsContainerRefCb } = useDropdownPadding();
30
33
  useEffect(()=>{
31
34
  const triggerElement = triggerRef.current;
32
35
  if (!triggerElement) return;
@@ -38,15 +41,6 @@ const AutoComplete = ({ testId, className, optionClassName, dropdownClassName, l
38
41
  listboxTriggerAriaProps,
39
42
  triggerRef
40
43
  ]);
41
- const getDropdownStyle = ()=>{
42
- const triggerWidth = triggerRef.current?.getBoundingClientRect()?.width ?? 0;
43
- if (renderDropdownContent) return {
44
- minWidth: triggerWidth
45
- };
46
- return {
47
- width: triggerWidth
48
- };
49
- };
50
44
  const handleSelect = useCallback((option)=>{
51
45
  if (!option) return;
52
46
  onSelectOption?.(option);
@@ -56,6 +50,17 @@ const AutoComplete = ({ testId, className, optionClassName, dropdownClassName, l
56
50
  handleClose,
57
51
  onSelectOption
58
52
  ]);
53
+ const getDropdownStyle = ()=>{
54
+ const triggerWidth = triggerRef.current?.getBoundingClientRect()?.width ?? 0;
55
+ if (renderDropdownContent) return {
56
+ minWidth: triggerWidth,
57
+ ...scrollPaddings
58
+ };
59
+ return {
60
+ width: triggerWidth,
61
+ ...scrollPaddings
62
+ };
63
+ };
59
64
  const handleMouseDown = useCallback((e, option)=>{
60
65
  e.preventDefault();
61
66
  e.stopPropagation();
@@ -101,7 +106,7 @@ const AutoComplete = ({ testId, className, optionClassName, dropdownClassName, l
101
106
  warning: warning,
102
107
  disabled: disabled
103
108
  }),
104
- options && /*#__PURE__*/ jsx(Dropdown, {
109
+ options && /*#__PURE__*/ jsxs(Dropdown, {
105
110
  ...dropdownAriaProps,
106
111
  open: open,
107
112
  triggerRef: triggerRef,
@@ -112,26 +117,35 @@ const AutoComplete = ({ testId, className, optionClassName, dropdownClassName, l
112
117
  className: dropdownClassName,
113
118
  style: getDropdownStyle(),
114
119
  onClose: handleClose,
115
- children: renderDropdownContent ? renderDropdownContent({
116
- cursor,
117
- testId,
118
- listboxId,
119
- options,
120
- onSelect: handleSelect,
121
- onMouseDown: handleMouseDown,
122
- onSetCursor: setCursor
123
- }) : /*#__PURE__*/ jsx(OptionsList, {
124
- listboxId: listboxId,
125
- skipSelectOnTab: true,
126
- items: options,
127
- optionClassName: optionClassName,
128
- onSelect: handleSelect,
129
- onMouseDown: handleMouseDown,
130
- testId: testId,
131
- searchable: false,
132
- cursor: cursor,
133
- onSetCursor: setCursor
134
- })
120
+ maxHeight: maxDropdownHeight,
121
+ children: [
122
+ renderDropdownContent ? renderDropdownContent({
123
+ cursor,
124
+ testId,
125
+ listboxId,
126
+ options,
127
+ onSelect: handleSelect,
128
+ onMouseDown: handleMouseDown,
129
+ onSetCursor: setCursor
130
+ }) : /*#__PURE__*/ jsx(OptionsList, {
131
+ listboxId: listboxId,
132
+ skipSelectOnTab: true,
133
+ items: options,
134
+ optionClassName: optionClassName,
135
+ onSelect: handleSelect,
136
+ onMouseDown: handleMouseDown,
137
+ testId: testId,
138
+ searchable: false,
139
+ cursor: cursor,
140
+ onSetCursor: setCursor
141
+ }),
142
+ renderDropdownActions && /*#__PURE__*/ jsx(DropdownActionsContainer, {
143
+ ref: dropdownActionsContainerRefCb,
144
+ children: renderDropdownActions({
145
+ closeDropdown: handleClose
146
+ })
147
+ })
148
+ ]
135
149
  })
136
150
  ]
137
151
  });
@@ -1,11 +1,10 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { useState } from "react";
3
3
  import { cn } from "../../common/css/cn.js";
4
- import { Help } from "../Help/Help.js";
4
+ import { Help, HelpSize } from "../Help/Help.js";
5
5
  import { Hint } from "../Hint/Hint.js";
6
6
  import { Text, TextColor } from "../Text/Text.js";
7
7
  import { Placement } from "../Tooltip/Tooltip.js";
8
- import { Support12Icon } from "../../icon/index.js";
9
8
  import Badge_module from "./Badge.module.js";
10
9
  const badgeColors = {
11
10
  green: 'green',
@@ -54,7 +53,7 @@ const Badge = ({ icon, label, labelClassName, help, className, variant, hintPlac
54
53
  help && /*#__PURE__*/ jsx(Help, {
55
54
  testId: "badge-help",
56
55
  className: Badge_module.help,
57
- icon: /*#__PURE__*/ jsx(Support12Icon, {}),
56
+ size: HelpSize.S,
58
57
  popup: /*#__PURE__*/ jsx(Text.Body, {
59
58
  children: help
60
59
  }),
@@ -7,8 +7,8 @@
7
7
  padding: 0 8px;
8
8
  }
9
9
 
10
- .badge-gtxv4j .help-eK4Uwn svg path[stroke], .badge-gtxv4j .help-eK4Uwn:hover svg path[stroke] {
11
- stroke: currentColor;
10
+ .help-eK4Uwn:not(:hover, :active, :focus-visible, [data-visible="true"]) {
11
+ color: inherit;
12
12
  }
13
13
 
14
14
  .content-CwHzRb {
@@ -16,7 +16,6 @@
16
16
  align-items: center;
17
17
  gap: 4px;
18
18
  display: flex;
19
- overflow: hidden;
20
19
  }
21
20
 
22
21
  .content-CwHzRb > svg {
@@ -3,12 +3,12 @@ import { memo, useCallback, useEffect, useId, useRef, useState } from "react";
3
3
  import { createPortal } from "react-dom";
4
4
  import { useLatestValue } from "@dnd-kit/utilities";
5
5
  import { AnimatePresence, motion, useDragControls } from "framer-motion";
6
- import lodash_debounce from "lodash.debounce";
7
6
  import { cn } from "../../common/index.js";
8
7
  import { useSheetContext } from "./BottomSheetContextProvider.js";
9
8
  import { Text } from "../Text/Text.js";
10
9
  import { useMediaQuery } from "../../hooks/index.js";
11
10
  import { RemoveCloseIcon16Icon, Support20Icon } from "../../icon/index.js";
11
+ import { debounce } from "../../utils/debounce/debounce.js";
12
12
  import { TRANSITION } from "./BottomSheet.constants.js";
13
13
  import { BottomSheetBody } from "./BottomSheetBody.js";
14
14
  import BottomSheet_module from "./BottomSheet.module.js";
@@ -125,7 +125,7 @@ const BottomSheet = /*#__PURE__*/ memo(({ testId = 'bottomSheet', isOpen, onClos
125
125
  'TEXTAREA'
126
126
  ].includes(element.tagName);
127
127
  };
128
- const scrollIntoActive = lodash_debounce(()=>{
128
+ const scrollIntoActive = debounce(()=>{
129
129
  if (!editableInFocus()) return;
130
130
  document.activeElement?.scrollIntoView({
131
131
  block: 'nearest',
@@ -1,5 +1,7 @@
1
1
  import { type HTMLAttributes } from 'react';
2
2
  import { type TextAtomProps } from '../Text/Text.atom';
3
- type BreadcrumbItemProps = Omit<TextAtomProps, 'variant'> & HTMLAttributes<HTMLSpanElement>;
4
- export declare const BreadcrumbItem: import("react").MemoExoticComponent<({ className, onClick, ...otherProps }: BreadcrumbItemProps) => import("react/jsx-runtime").JSX.Element>;
5
- export {};
3
+ export type BreadcrumbItemProps = Omit<TextAtomProps, 'variant'> & HTMLAttributes<HTMLSpanElement> & {
4
+ charLimitThreshold?: number;
5
+ hintZIndex?: number;
6
+ };
7
+ export declare const BreadcrumbItem: import("react").MemoExoticComponent<({ className, onClick, charLimitThreshold, hintZIndex, children, ...restProps }: BreadcrumbItemProps) => import("react/jsx-runtime").JSX.Element>;
@@ -1,14 +1,45 @@
1
1
  import { jsx } from "react/jsx-runtime";
2
- import { memo } from "react";
2
+ import { memo, useMemo, useRef, useState } from "react";
3
3
  import { cn } from "../../common/css/cn.js";
4
- import { TextVariant } from "../Text/Text.js";
4
+ import { HintWithSkip } from "../_shared/HintWithSkip/HintWithSkip.js";
5
+ import { Text, TextColor, TextVariant } from "../Text/Text.js";
5
6
  import { TextAtom } from "../Text/Text.atom.js";
7
+ import { Placement } from "../Tooltip/Tooltip.js";
6
8
  import Breadcrumbs_module from "./Breadcrumbs.module.js";
7
- const BreadcrumbItem = /*#__PURE__*/ memo(({ className, onClick, ...otherProps })=>/*#__PURE__*/ jsx(TextAtom, {
8
- variant: TextVariant.caption,
9
- className: cn(Breadcrumbs_module.item, className, onClick && Breadcrumbs_module.hasClick),
10
- onClick: onClick,
11
- ...otherProps
12
- }));
9
+ const HINT_SHOW_DELAY_SECONDS = 0.3;
10
+ const BreadcrumbItem = /*#__PURE__*/ memo(({ className, onClick, charLimitThreshold, hintZIndex, children, ...restProps })=>{
11
+ const textElementRef = useRef(null);
12
+ const [isTextOverflow, setIsTextOverflow] = useState(false);
13
+ const value = useMemo(()=>{
14
+ const textValue = children;
15
+ const isOverflow = 'number' == typeof charLimitThreshold && charLimitThreshold > 0 && textValue.length - charLimitThreshold > 1;
16
+ setIsTextOverflow(isOverflow);
17
+ if (isOverflow) return `${textValue.substring(0, charLimitThreshold)}...`;
18
+ return textValue;
19
+ }, [
20
+ children,
21
+ charLimitThreshold
22
+ ]);
23
+ return /*#__PURE__*/ jsx(HintWithSkip, {
24
+ testId: restProps.testId,
25
+ overlay: /*#__PURE__*/ jsx(Text.Body, {
26
+ colorToken: TextColor.invert,
27
+ children: children
28
+ }),
29
+ skip: !isTextOverflow,
30
+ placement: Placement.BOTTOM,
31
+ zIndex: hintZIndex,
32
+ mouseEnterDelay: HINT_SHOW_DELAY_SECONDS,
33
+ mouseLeaveDelay: 0,
34
+ children: /*#__PURE__*/ jsx(TextAtom, {
35
+ ref: textElementRef,
36
+ variant: TextVariant.caption,
37
+ className: cn(Breadcrumbs_module.item, className, onClick && Breadcrumbs_module.hasClick),
38
+ onClick: onClick,
39
+ ...restProps,
40
+ children: value
41
+ })
42
+ });
43
+ });
13
44
  BreadcrumbItem.displayName = 'BreadcrumbItem';
14
45
  export { BreadcrumbItem };
@@ -1,7 +1,10 @@
1
1
  import { type FC, type HTMLAttributes } from 'react';
2
2
  import { type IHasTestId } from '../../common/types';
3
3
  import { BreadcrumbItem } from './BreadcrumbItem';
4
- export type IBreadcrumbsProps = HTMLAttributes<HTMLDivElement> & IHasTestId;
4
+ export type IBreadcrumbsProps = HTMLAttributes<HTMLDivElement> & IHasTestId & {
5
+ charLimitThreshold?: number;
6
+ hintZIndex?: number;
7
+ };
5
8
  export declare const Breadcrumbs: FC<IBreadcrumbsProps> & {
6
9
  Item: typeof BreadcrumbItem;
7
10
  };
@@ -1,26 +1,30 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
- import { Children, isValidElement } from "react";
2
+ import { Children, cloneElement, isValidElement } from "react";
3
3
  import { cn } from "../../common/css/cn.js";
4
4
  import { Right12Icon } from "../../icon/index.js";
5
5
  import { BreadcrumbItem } from "./BreadcrumbItem.js";
6
6
  import Breadcrumbs_module from "./Breadcrumbs.module.js";
7
- const renderBreadcrumbItems = (children)=>{
7
+ const CHAR_LIMIT_THRESHOLD = 40;
8
+ const renderBreadcrumbItems = (children, charLimitThreshold, hintZIndex)=>{
8
9
  const childrenArray = Children.toArray(children);
9
10
  const lastIndex = childrenArray.length - 1;
10
11
  return childrenArray.filter(isValidElement).map((child, idx)=>/*#__PURE__*/ jsxs("div", {
11
12
  className: Breadcrumbs_module.itemContainer,
12
13
  children: [
13
- child,
14
+ /*#__PURE__*/ cloneElement(child, {
15
+ charLimitThreshold,
16
+ hintZIndex
17
+ }),
14
18
  idx !== lastIndex && /*#__PURE__*/ jsx(Right12Icon, {})
15
19
  ]
16
20
  }, idx));
17
21
  };
18
- const Breadcrumbs = ({ children, className, testId, ...otherProps })=>{
19
- const items = renderBreadcrumbItems(children);
22
+ const Breadcrumbs = ({ children, className, testId, charLimitThreshold = CHAR_LIMIT_THRESHOLD, hintZIndex = 1, ...restProps })=>{
23
+ const items = renderBreadcrumbItems(children, charLimitThreshold, hintZIndex);
20
24
  return /*#__PURE__*/ jsx("div", {
21
25
  className: cn(Breadcrumbs_module.container, className),
22
26
  "data-test-id": testId,
23
- ...otherProps,
27
+ ...restProps,
24
28
  children: items
25
29
  });
26
30
  };
@@ -28,5 +28,6 @@ export interface IButtonProps extends PropsWithChildren<ButtonHTMLAttributes<HTM
28
28
  isIconButton?: boolean;
29
29
  stretch?: boolean;
30
30
  withHorisontalPadding?: boolean;
31
+ noPadding?: boolean;
31
32
  }
32
33
  export declare const Button: import("react").ForwardRefExoticComponent<IButtonProps & import("react").RefAttributes<HTMLButtonElement>>;
@@ -34,9 +34,9 @@ const getFilledColorClass = (color)=>{
34
34
  return Button_module.filledGrey;
35
35
  }
36
36
  };
37
- const Button = /*#__PURE__*/ forwardRef(({ testId, type = 'button', variant = ButtonVariants.PRIMARY, color, disabled, className: classNameProp, children, size = ButtonSize.L, isLoading = false, onClick, isIconButton = false, stretch = false, withHorisontalPadding = false, ...rest }, ref)=>{
37
+ const Button = /*#__PURE__*/ forwardRef(({ testId, type = 'button', variant = ButtonVariants.PRIMARY, color, disabled, className: classNameProp, children, size = ButtonSize.L, isLoading = false, onClick, isIconButton = false, stretch = false, withHorisontalPadding = false, noPadding = false, ...rest }, ref)=>{
38
38
  const LoaderIcon = LoaderBySizeMap[size];
39
- const className = cn(Button_module.button, Button_module[variant], Button_module[size], variant === ButtonVariants.FILLED && getFilledColorClass(color), isLoading ? Button_module.isLoading : '', isIconButton && Button_module.iconButton, stretch && Button_module.stretch, classNameProp, withHorisontalPadding && Button_module.withHorisontalPadding);
39
+ const className = cn(Button_module.button, Button_module[variant], Button_module[size], variant === ButtonVariants.FILLED && getFilledColorClass(color), variant === ButtonVariants.FRAMELESS && noPadding && Button_module.noPadding, isLoading ? Button_module.isLoading : '', isIconButton && Button_module.iconButton, stretch && Button_module.stretch, classNameProp, withHorisontalPadding && Button_module.withHorisontalPadding);
40
40
  const handleClick = (e)=>{
41
41
  if (isLoading || disabled) return;
42
42
  onClick?.(e);
@@ -14,6 +14,7 @@ const Button_module = {
14
14
  additional: "additional-Ftulks",
15
15
  frameless: "frameless-gZ67sX",
16
16
  withHorisontalPadding: "withHorisontalPadding-DDBSv8",
17
+ noPadding: "noPadding-Ja7zyG",
17
18
  secondary: "secondary-bjc5zI",
18
19
  filled: "filled-WTubUm",
19
20
  filledGrey: "filledGrey-cyhUUI",
@@ -235,6 +235,10 @@
235
235
  padding-right: 12px;
236
236
  }
237
237
 
238
+ .noPadding-Ja7zyG {
239
+ padding: 0;
240
+ }
241
+
238
242
  .secondary-bjc5zI {
239
243
  --cb-button-color: var(--text-primary, #091739);
240
244
  --cb-button-background: var(--button-secondary-normal, #fff);
@@ -22,15 +22,16 @@ const Carousel = ({ isVisible, sources, onClose, startIndex = 0, testId, portalE
22
22
  startIndex
23
23
  ]);
24
24
  const sourcesLength = sources.length;
25
- const withToolbar = sourcesLength > 1;
26
25
  const handleClickPrev = ()=>setCurrentIndex((index)=>0 === index ? sourcesLength - 1 : index - 1);
27
26
  const handleClickNext = ()=>setCurrentIndex((index)=>(index + 1) % sourcesLength);
28
27
  const handleClose = ()=>{
29
28
  onClose();
30
29
  };
30
+ const isToolbarVisible = sourcesLength > 1;
31
+ const isArrowNavigationEnabled = isVisible && isToolbarVisible;
31
32
  useKeyDownListener('Escape', handleClose, isVisible);
32
- useKeyDownListener('ArrowLeft', handleClickPrev, isVisible);
33
- useKeyDownListener('ArrowRight', handleClickNext, isVisible);
33
+ useKeyDownListener('ArrowLeft', handleClickPrev, isArrowNavigationEnabled);
34
+ useKeyDownListener('ArrowRight', handleClickNext, isArrowNavigationEnabled);
34
35
  useTabNavigation(ref, isVisible);
35
36
  if (!isVisible || 0 === sourcesLength) return null;
36
37
  const label = toolbarLabel ? toolbarLabel(currentIndex, sources.length) : `${currentIndex + 1} из ${sources.length}`;
@@ -75,7 +76,7 @@ const Carousel = ({ isVisible, sources, onClose, startIndex = 0, testId, portalE
75
76
  ]
76
77
  })
77
78
  }),
78
- withToolbar && /*#__PURE__*/ jsx(Toolbar, {
79
+ isToolbarVisible && /*#__PURE__*/ jsx(Toolbar, {
79
80
  label: label,
80
81
  onPrevClick: handleClickPrev,
81
82
  onNextClick: handleClickNext,
@@ -1,5 +1,5 @@
1
1
  export type { CheckboxProps } from './Checkbox.types';
2
- export declare const Checkbox: import("react").ForwardRefExoticComponent<Omit<import("react").InputHTMLAttributes<HTMLInputElement>, "onChange" | "children" | "onClick" | "type"> & import("../Indicator/Indicator.types").IndicatorProps & import("../..").IHasTestId & import("../..").IHasTabIndex & {
2
+ export declare const Checkbox: import("react").ForwardRefExoticComponent<Omit<import("react").InputHTMLAttributes<HTMLInputElement>, "children" | "onChange" | "onClick" | "type"> & import("../Indicator/Indicator.types").IndicatorProps & import("../..").IHasTestId & import("../..").IHasTabIndex & {
3
3
  className?: string;
4
4
  label?: string;
5
5
  children?: import("react").ReactNode;
@@ -157,10 +157,10 @@ const resolveProps = (props)=>{
157
157
  legacy
158
158
  };
159
159
  }
160
- const { variant = 'regular', size = 'regular', disabled = false, label, leadingIcon, onPress, selected, onSelectedChange, trailingIcon, trailingIconBehavior, onTrailingIconClick, trailingIconHint, indicatorMode, count, novelty, clearable, onClear, clearIconHint, constrainWidth, maxWidthPx, hintZIndex } = props;
160
+ const { variant = 'regular', size = 'regular', disabled = false, label, labelColorToken, className, leadingIcon, tabIndex, onPress, selected, onSelectedChange, trailingIcon, trailingIconBehavior, onTrailingIconClick, trailingIconHint, indicatorMode, count, novelty, clearable, onClear, clearIconHint, constrainWidth, maxWidthPx, hintZIndex } = props;
161
161
  const clickHandler = (e)=>{
162
162
  onPress?.(e);
163
- onSelectedChange(!selected);
163
+ onSelectedChange?.(!selected);
164
164
  };
165
165
  const indicators = resolveIndicators({
166
166
  size,
@@ -193,7 +193,10 @@ const resolveProps = (props)=>{
193
193
  disabled,
194
194
  selected,
195
195
  label,
196
+ labelColorToken,
197
+ className,
196
198
  leadingIcon,
199
+ tabIndex,
197
200
  trailing,
198
201
  indicators,
199
202
  clear,
@@ -128,7 +128,7 @@ const Chip = /*#__PURE__*/ forwardRef((props, ref)=>{
128
128
  ]
129
129
  });
130
130
  }
131
- const { variant, size, disabled, selected, clickHandler, label, leadingIcon, trailing, indicators, clear, textBehavior, hintZIndex } = resolved;
131
+ const { variant, size, disabled, selected, clickHandler, label, labelColorToken, className, leadingIcon, tabIndex, trailing, indicators, clear, textBehavior, hintZIndex } = resolved;
132
132
  const isCompact = 'compact' === size;
133
133
  const isTrailingButton = 'button' === trailing.mode;
134
134
  const isClearButton = 'button' === clear.mode;
@@ -163,7 +163,8 @@ const Chip = /*#__PURE__*/ forwardRef((props, ref)=>{
163
163
  disabled,
164
164
  hasLeading,
165
165
  hasTrailing,
166
- constrainWidth: textBehavior.constrainWidth
166
+ constrainWidth: textBehavior.constrainWidth,
167
+ className
167
168
  });
168
169
  const wrapperStyle = getConstrainedStyle(textBehavior);
169
170
  const mainButtonClassName = isTrailingButton ? Chip_module.chipButton : cn(Chip_module.chipButton, leadingIcon && Chip_module.hasLeading);
@@ -179,10 +180,12 @@ const Chip = /*#__PURE__*/ forwardRef((props, ref)=>{
179
180
  onClick: clickHandler,
180
181
  className: mainButtonClassName,
181
182
  disabled: disabled,
183
+ tabIndex: tabIndex,
182
184
  children: [
183
185
  leadingIconNode,
184
186
  /*#__PURE__*/ jsx(ChipLabel, {
185
187
  label: label,
188
+ colorToken: labelColorToken,
186
189
  isCompact: isCompact,
187
190
  textBehavior: textBehavior,
188
191
  hintZIndex: hintZIndex
@@ -220,7 +223,8 @@ const Chip = /*#__PURE__*/ forwardRef((props, ref)=>{
220
223
  isCompact,
221
224
  hasLeading,
222
225
  hasTrailing,
223
- constrainWidth: textBehavior.constrainWidth
226
+ constrainWidth: textBehavior.constrainWidth,
227
+ className
224
228
  });
225
229
  const rootStyle = getConstrainedStyle(textBehavior);
226
230
  return /*#__PURE__*/ jsxs(ChipRoot, {
@@ -231,10 +235,12 @@ const Chip = /*#__PURE__*/ forwardRef((props, ref)=>{
231
235
  disabled: disabled,
232
236
  onClick: clickHandler,
233
237
  buttonRef: ref,
238
+ tabIndex: tabIndex,
234
239
  children: [
235
240
  leadingIconNode,
236
241
  /*#__PURE__*/ jsx(ChipLabel, {
237
242
  label: label,
243
+ colorToken: labelColorToken,
238
244
  isCompact: isCompact,
239
245
  textBehavior: textBehavior,
240
246
  hintZIndex: hintZIndex
@@ -17,7 +17,7 @@
17
17
  }
18
18
 
19
19
  .chip-sfyie1:focus-visible {
20
- box-shadow: inset 0 0 0 1px var(--elements-hover, #091739);
20
+ box-shadow: inset 0 0 0 1px var(--border-focused, #091739);
21
21
  background-color: var(--elements-chips-normal, #f1f4f9);
22
22
  }
23
23
 
@@ -47,7 +47,7 @@
47
47
  }
48
48
 
49
49
  .active-uGgP1c:focus-visible {
50
- box-shadow: inset 0 0 0 1px var(--elements-hover, #091739);
50
+ box-shadow: inset 0 0 0 1px var(--border-focused, #091739);
51
51
  background-color: var(--elements-chips-normal-current, #dff0fe);
52
52
  }
53
53
 
@@ -1,5 +1,6 @@
1
1
  import type { ButtonHTMLAttributes, HTMLAttributes, MouseEvent, ReactElement, ReactNode } from 'react';
2
- import type { IHasTestId, ValueOf } from '../../common/types';
2
+ import type { IHasTabIndex, IHasTestId, ValueOf } from '../../common/types';
3
+ import type { TextColorToken } from '../Text/Text';
3
4
  /**
4
5
  * Этот тип сейчас необходим для поддержки legacy-поведения.
5
6
  * Все они уже фактически используются.
@@ -73,10 +74,12 @@ type ChipAppearanceProps = {
73
74
  };
74
75
  type ChipNewSelectionProps = {
75
76
  selected: boolean;
76
- onSelectedChange: (nextSelected: boolean) => void;
77
+ onSelectedChange?: (nextSelected: boolean) => void;
77
78
  };
78
- type ChipNewContentProps = {
79
+ type ChipNewContentProps = IHasTabIndex & {
79
80
  label: string;
81
+ labelColorToken?: TextColorToken;
82
+ className?: string;
80
83
  leadingIcon?: ReactNode;
81
84
  };
82
85
  type ChipClearProps = {
@@ -169,6 +172,7 @@ export interface ChipLegacyProps extends ChipButtonLegacyCompatProps {
169
172
  onSelectedChange?: never;
170
173
  onPress?: never;
171
174
  label?: never;
175
+ labelColorToken?: never;
172
176
  leadingIcon?: never;
173
177
  trailingIcon?: never;
174
178
  trailingIconBehavior?: never;
@@ -259,9 +263,11 @@ export type ChipTextBehaviorResolved = {
259
263
  export type Resolved = (ResolvedBase & {
260
264
  mode: 'legacy';
261
265
  legacy: LegacyResolved;
262
- }) | (ResolvedBase & {
266
+ }) | (ResolvedBase & IHasTabIndex & {
263
267
  mode: 'new';
264
268
  label: string;
269
+ labelColorToken?: TextColorToken;
270
+ className?: string;
265
271
  leadingIcon?: ReactNode;
266
272
  trailing: ResolvedTrailing;
267
273
  indicators: ResolvedIndicators;
@@ -12,7 +12,7 @@
12
12
  }
13
13
 
14
14
  .chip-m4AltR:focus-visible {
15
- box-shadow: inset 0 0 0 1px var(--elements-hover, #091739);
15
+ box-shadow: inset 0 0 0 1px var(--border-focused, #091739);
16
16
  }
17
17
 
18
18
  .chip-m4AltR:disabled {
@@ -126,7 +126,7 @@
126
126
  }
127
127
 
128
128
  .wrapper-BRrIHY:has(.chipButton-_9Yan_:focus-visible) {
129
- box-shadow: inset 0 0 0 1px var(--elements-hover, #091739);
129
+ box-shadow: inset 0 0 0 1px var(--border-focused, #091739);
130
130
  }
131
131
 
132
132
  .chipButton-_9Yan_ {
@@ -143,7 +143,7 @@
143
143
  }
144
144
 
145
145
  .chipButton-_9Yan_:focus-visible {
146
- box-shadow: inset 0 0 0 1px var(--elements-hover, #091739);
146
+ box-shadow: inset 0 0 0 1px var(--border-focused, #091739);
147
147
  }
148
148
 
149
149
  .trailingButton-D8uCaI {
@@ -163,7 +163,7 @@
163
163
  }
164
164
 
165
165
  .trailingButton-D8uCaI:focus-visible {
166
- box-shadow: inset 0 0 0 1px var(--elements-hover, #091739);
166
+ box-shadow: inset 0 0 0 1px var(--border-focused, #091739);
167
167
  }
168
168
 
169
169
  .clearButton-fN81yO {
@@ -183,7 +183,7 @@
183
183
  }
184
184
 
185
185
  .clearButton-fN81yO:focus-visible {
186
- box-shadow: inset 0 0 0 1px var(--elements-hover, #091739);
186
+ box-shadow: inset 0 0 0 1px var(--border-focused, #091739);
187
187
  }
188
188
 
189
189
  .rightActions-f8Q4y9 {
@@ -1,9 +1,11 @@
1
+ import { type TextColorToken } from '../../Text/Text';
1
2
  import type { ChipTextBehaviorResolved } from '../Chip.types';
2
3
  type ChipLabelProps = {
3
4
  label: string;
5
+ colorToken?: TextColorToken;
4
6
  isCompact: boolean;
5
7
  textBehavior: ChipTextBehaviorResolved;
6
8
  hintZIndex?: number;
7
9
  };
8
- export declare const ChipLabel: ({ label, isCompact, textBehavior, hintZIndex, }: ChipLabelProps) => import("react/jsx-runtime").JSX.Element;
10
+ export declare const ChipLabel: ({ label, colorToken, isCompact, textBehavior, hintZIndex, }: ChipLabelProps) => import("react/jsx-runtime").JSX.Element;
9
11
  export {};