@consta/uikit 3.17.2 → 3.18.1

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 (588) hide show
  1. package/Attach/package.json +1 -1
  2. package/Attachment/package.json +1 -1
  3. package/Avatar/package.json +1 -1
  4. package/Badge/package.json +1 -1
  5. package/BasicSelectDeprecated/package.json +1 -1
  6. package/Breadcrumbs/package.json +1 -1
  7. package/BreadcrumbsCanary/package.json +1 -1
  8. package/Button/package.json +1 -1
  9. package/CHANGELOG.md +45 -41
  10. package/Calendar/package.json +1 -1
  11. package/Card/package.json +1 -1
  12. package/Checkbox/package.json +1 -1
  13. package/CheckboxGroup/package.json +1 -1
  14. package/ChoiceGroup/package.json +1 -1
  15. package/Collapse/package.json +1 -1
  16. package/CollapseGroup/package.json +1 -1
  17. package/Combobox/package.json +1 -1
  18. package/ComboboxDeprecated/package.json +1 -1
  19. package/ContextMenu/package.json +1 -1
  20. package/ContextMenuCanary/es.js +1 -0
  21. package/ContextMenuCanary/index.d.ts +1 -0
  22. package/ContextMenuCanary/index.js +4 -0
  23. package/ContextMenuCanary/package.json +9 -0
  24. package/DatePickerCanary/package.json +1 -1
  25. package/DateTimeCanary/package.json +1 -1
  26. package/DragNDropField/package.json +1 -1
  27. package/EventInterceptor/package.json +1 -1
  28. package/FieldCaption/package.json +1 -1
  29. package/FieldLabel/package.json +1 -1
  30. package/File/package.json +1 -1
  31. package/FileField/package.json +1 -1
  32. package/FileIcon/package.json +1 -1
  33. package/FileIconAvi/package.json +1 -1
  34. package/FileIconBmp/package.json +1 -1
  35. package/FileIconCsv/package.json +1 -1
  36. package/FileIconDoc/package.json +1 -1
  37. package/FileIconExe/package.json +1 -1
  38. package/FileIconGif/package.json +1 -1
  39. package/FileIconJpg/package.json +1 -1
  40. package/FileIconJson/package.json +1 -1
  41. package/FileIconLoading/package.json +1 -1
  42. package/FileIconMov/package.json +1 -1
  43. package/FileIconMp3/package.json +1 -1
  44. package/FileIconMp4/package.json +1 -1
  45. package/FileIconPdf/package.json +1 -1
  46. package/FileIconPng/package.json +1 -1
  47. package/FileIconPtt/package.json +1 -1
  48. package/FileIconRar/package.json +1 -1
  49. package/FileIconRtf/package.json +1 -1
  50. package/FileIconTiff/package.json +1 -1
  51. package/FileIconTxt/package.json +1 -1
  52. package/FileIconUndefined/package.json +1 -1
  53. package/FileIconWav/package.json +1 -1
  54. package/FileIconXls/package.json +1 -1
  55. package/FileIconZip/package.json +1 -1
  56. package/Grid/package.json +1 -1
  57. package/Header/package.json +1 -1
  58. package/Icon/package.json +1 -1
  59. package/IconAdd/package.json +1 -1
  60. package/IconAddToComparison/package.json +1 -1
  61. package/IconAlert/package.json +1 -1
  62. package/IconAlignBlocksLeft/package.json +1 -1
  63. package/IconAlignBlocksRight/package.json +1 -1
  64. package/IconAlignCenter/package.json +1 -1
  65. package/IconAlignJustify/package.json +1 -1
  66. package/IconAlignLeft/package.json +1 -1
  67. package/IconAlignRight/package.json +1 -1
  68. package/IconAllDone/package.json +1 -1
  69. package/IconArrowDown/package.json +1 -1
  70. package/IconArrowLeft/package.json +1 -1
  71. package/IconArrowRight/package.json +1 -1
  72. package/IconArrowUp/package.json +1 -1
  73. package/IconArtBrush/package.json +1 -1
  74. package/IconAttach/package.json +1 -1
  75. package/IconBackward/package.json +1 -1
  76. package/IconBag/package.json +1 -1
  77. package/IconBarrier/package.json +1 -1
  78. package/IconBento/package.json +1 -1
  79. package/IconBold/package.json +1 -1
  80. package/IconBook/package.json +1 -1
  81. package/IconBookmarkFilled/package.json +1 -1
  82. package/IconBookmarkStroked/package.json +1 -1
  83. package/IconCalculator/package.json +1 -1
  84. package/IconCalendar/package.json +1 -1
  85. package/IconCamera/package.json +1 -1
  86. package/IconCancel/package.json +1 -1
  87. package/IconCards/package.json +1 -1
  88. package/IconChat/package.json +1 -1
  89. package/IconCheck/package.json +1 -1
  90. package/IconClose/package.json +1 -1
  91. package/IconCollapse/package.json +1 -1
  92. package/IconColorFill/package.json +1 -1
  93. package/IconColorText/package.json +1 -1
  94. package/IconColumns/package.json +1 -1
  95. package/IconComment/package.json +1 -1
  96. package/IconConnection/package.json +1 -1
  97. package/IconCopy/package.json +1 -1
  98. package/IconCrown/package.json +1 -1
  99. package/IconCursorMouse/package.json +1 -1
  100. package/IconDataNull/package.json +1 -1
  101. package/IconDiamond/package.json +1 -1
  102. package/IconDinosaur/package.json +1 -1
  103. package/IconDisconnection/package.json +1 -1
  104. package/IconDocAdd/package.json +1 -1
  105. package/IconDocBlank/package.json +1 -1
  106. package/IconDocDelete/package.json +1 -1
  107. package/IconDocExport/package.json +1 -1
  108. package/IconDocFilled/package.json +1 -1
  109. package/IconDown/package.json +1 -1
  110. package/IconDownload/package.json +1 -1
  111. package/IconDrag/package.json +1 -1
  112. package/IconDraggable/package.json +1 -1
  113. package/IconDrillingRig/package.json +1 -1
  114. package/IconDrop/package.json +1 -1
  115. package/IconEdit/package.json +1 -1
  116. package/IconExit/package.json +1 -1
  117. package/IconExpand/package.json +1 -1
  118. package/IconEye/package.json +1 -1
  119. package/IconEyeClose/package.json +1 -1
  120. package/IconFacebook/es.js +1 -0
  121. package/IconFacebook/index.d.ts +1 -0
  122. package/IconFacebook/index.js +4 -0
  123. package/IconFacebook/package.json +9 -0
  124. package/IconFavorite/package.json +1 -1
  125. package/IconFilter/package.json +1 -1
  126. package/IconFitToDefault/package.json +1 -1
  127. package/IconFlagFilled/package.json +1 -1
  128. package/IconFlagStroked/package.json +1 -1
  129. package/IconFolders/package.json +1 -1
  130. package/IconForward/package.json +1 -1
  131. package/IconFunnel/package.json +1 -1
  132. package/IconGas/package.json +1 -1
  133. package/IconGeo/package.json +1 -1
  134. package/IconGrouping/package.json +1 -1
  135. package/IconHamburger/package.json +1 -1
  136. package/IconHand/package.json +1 -1
  137. package/IconHealth/package.json +1 -1
  138. package/IconHome/package.json +1 -1
  139. package/IconInComparison/package.json +1 -1
  140. package/IconInfo/package.json +1 -1
  141. package/IconInstagram/es.js +1 -0
  142. package/IconInstagram/index.d.ts +1 -0
  143. package/IconInstagram/index.js +4 -0
  144. package/IconInstagram/package.json +9 -0
  145. package/IconIntroduction/package.json +1 -1
  146. package/IconIpad/package.json +1 -1
  147. package/IconItalic/package.json +1 -1
  148. package/IconKebab/package.json +1 -1
  149. package/IconLaptop/package.json +1 -1
  150. package/IconLayers/package.json +1 -1
  151. package/IconLeaf/package.json +1 -1
  152. package/IconLightningBolt/package.json +1 -1
  153. package/IconLineAndBarChart/package.json +1 -1
  154. package/IconLink/package.json +1 -1
  155. package/IconList/package.json +1 -1
  156. package/IconListNumbered/package.json +1 -1
  157. package/IconLock/package.json +1 -1
  158. package/IconLogicalElement/package.json +1 -1
  159. package/IconMBU/package.json +1 -1
  160. package/IconMGRP/package.json +1 -1
  161. package/IconMLSP/package.json +1 -1
  162. package/IconMMP/package.json +1 -1
  163. package/IconMail/package.json +1 -1
  164. package/IconMap/package.json +1 -1
  165. package/IconMaxHeight/package.json +1 -1
  166. package/IconMaxWidth/package.json +1 -1
  167. package/IconMeatball/package.json +1 -1
  168. package/IconMic/package.json +1 -1
  169. package/IconMolecules/package.json +1 -1
  170. package/IconMoon/package.json +1 -1
  171. package/IconNodeEnd/package.json +1 -1
  172. package/IconNodeStart/package.json +1 -1
  173. package/IconNodeStep/package.json +1 -1
  174. package/IconNodes/package.json +1 -1
  175. package/IconOpenInNew/package.json +1 -1
  176. package/IconOperators/package.json +1 -1
  177. package/IconPanelBottom/package.json +1 -1
  178. package/IconPanelLeft/package.json +1 -1
  179. package/IconPanelRight/package.json +1 -1
  180. package/IconPanelTop/package.json +1 -1
  181. package/IconPaste/package.json +1 -1
  182. package/IconPause/package.json +1 -1
  183. package/IconPhone/package.json +1 -1
  184. package/IconPhoto/package.json +1 -1
  185. package/IconPicture/package.json +1 -1
  186. package/IconPlay/package.json +1 -1
  187. package/IconPressure/package.json +1 -1
  188. package/IconPriceLabel/package.json +1 -1
  189. package/IconProcessing/package.json +1 -1
  190. package/IconQuestion/package.json +1 -1
  191. package/IconQuote/package.json +1 -1
  192. package/IconRUO/package.json +1 -1
  193. package/IconRUS/package.json +1 -1
  194. package/IconRecord/package.json +1 -1
  195. package/IconRemove/package.json +1 -1
  196. package/IconRemoveFromComparison/package.json +1 -1
  197. package/IconReply/package.json +1 -1
  198. package/IconResize/package.json +1 -1
  199. package/IconRestart/package.json +1 -1
  200. package/IconRevert/package.json +1 -1
  201. package/IconRing/package.json +1 -1
  202. package/IconRouble/package.json +1 -1
  203. package/IconRuler/package.json +1 -1
  204. package/IconSave/package.json +1 -1
  205. package/IconScreen/package.json +1 -1
  206. package/IconSearch/package.json +1 -1
  207. package/IconSelect/package.json +1 -1
  208. package/IconSelectOpen/package.json +1 -1
  209. package/IconSendMessage/package.json +1 -1
  210. package/IconSettings/package.json +1 -1
  211. package/IconShape/package.json +1 -1
  212. package/IconShuffle/package.json +1 -1
  213. package/IconSmile/package.json +1 -1
  214. package/IconSortDown/package.json +1 -1
  215. package/IconSortDownCenter/package.json +1 -1
  216. package/IconSortUp/package.json +1 -1
  217. package/IconSortUpCenter/package.json +1 -1
  218. package/IconStop/package.json +1 -1
  219. package/IconStorage/package.json +1 -1
  220. package/IconStrikethrough/package.json +1 -1
  221. package/IconSun/package.json +1 -1
  222. package/IconTable/package.json +1 -1
  223. package/IconTable2/package.json +1 -1
  224. package/IconTarget/package.json +1 -1
  225. package/IconTeam/package.json +1 -1
  226. package/IconTechResponse/package.json +1 -1
  227. package/IconTest/package.json +1 -1
  228. package/IconThumbUp/package.json +1 -1
  229. package/IconTie/package.json +1 -1
  230. package/IconTop/package.json +1 -1
  231. package/IconTrash/package.json +1 -1
  232. package/IconType/package.json +1 -1
  233. package/IconUnderline/package.json +1 -1
  234. package/IconUnlock/package.json +1 -1
  235. package/IconUnsort/package.json +1 -1
  236. package/IconUnsortCenter/package.json +1 -1
  237. package/IconUpload/package.json +1 -1
  238. package/IconUser/package.json +1 -1
  239. package/IconVZD/package.json +1 -1
  240. package/IconVideo/package.json +1 -1
  241. package/IconVkontakte/es.js +1 -0
  242. package/IconVkontakte/index.d.ts +1 -0
  243. package/IconVkontakte/index.js +4 -0
  244. package/IconVkontakte/package.json +9 -0
  245. package/IconWarning/package.json +1 -1
  246. package/IconWatch/package.json +1 -1
  247. package/IconWideScreen/package.json +1 -1
  248. package/IconWorld/package.json +1 -1
  249. package/IconWrench/package.json +1 -1
  250. package/IconYandexDzen/es.js +1 -0
  251. package/IconYandexDzen/index.d.ts +1 -0
  252. package/IconYandexDzen/index.js +4 -0
  253. package/IconYandexDzen/package.json +9 -0
  254. package/IconYoutube/es.js +1 -0
  255. package/IconYoutube/index.d.ts +1 -0
  256. package/IconYoutube/index.js +4 -0
  257. package/IconYoutube/package.json +9 -0
  258. package/Informer/package.json +1 -1
  259. package/LayoutCanary/package.json +1 -1
  260. package/Loader/package.json +1 -1
  261. package/MixCard/package.json +1 -1
  262. package/MixFocus/package.json +1 -1
  263. package/MixPopoverAnimate/package.json +1 -1
  264. package/MixPopoverArrow/es.js +1 -0
  265. package/MixPopoverArrow/index.d.ts +1 -0
  266. package/MixPopoverArrow/index.js +4 -0
  267. package/MixPopoverArrow/package.json +9 -0
  268. package/MixSpace/package.json +1 -1
  269. package/MixVisuallyHidden/package.json +1 -1
  270. package/Modal/package.json +1 -1
  271. package/MultiComboboxDeprecated/package.json +1 -1
  272. package/Pagination/package.json +1 -1
  273. package/Popover/package.json +1 -1
  274. package/PortalWithTheme/package.json +1 -1
  275. package/ProgressSpin/package.json +1 -1
  276. package/ProgressStepBarCanary/package.json +1 -1
  277. package/Radio/package.json +1 -1
  278. package/RadioGroup/package.json +1 -1
  279. package/Responses/package.json +1 -1
  280. package/Responses403/package.json +1 -1
  281. package/Responses404/package.json +1 -1
  282. package/Responses500/package.json +1 -1
  283. package/Responses503/package.json +1 -1
  284. package/ResponsesConnectionError/package.json +1 -1
  285. package/ResponsesDeleted/package.json +1 -1
  286. package/ResponsesEmptyBox/package.json +1 -1
  287. package/ResponsesEmptyPockets/package.json +1 -1
  288. package/ResponsesExit/package.json +1 -1
  289. package/ResponsesImage/package.json +1 -1
  290. package/ResponsesImage403/package.json +1 -1
  291. package/ResponsesImage404/package.json +1 -1
  292. package/ResponsesImage500/package.json +1 -1
  293. package/ResponsesImage503/package.json +1 -1
  294. package/ResponsesImageConnectionError/package.json +1 -1
  295. package/ResponsesImageDeleted/package.json +1 -1
  296. package/ResponsesImageEmptyBox/package.json +1 -1
  297. package/ResponsesImageEmptyPockets/package.json +1 -1
  298. package/ResponsesImageNothingFound/package.json +1 -1
  299. package/ResponsesImageSuccess/package.json +1 -1
  300. package/ResponsesNothingFound/package.json +1 -1
  301. package/ResponsesSuccess/package.json +1 -1
  302. package/Select/package.json +1 -1
  303. package/Sidebar/package.json +1 -1
  304. package/Skeleton/package.json +1 -1
  305. package/SliderCanary/package.json +1 -1
  306. package/SnackBar/package.json +1 -1
  307. package/Steps/package.json +1 -1
  308. package/Switch/package.json +1 -1
  309. package/SwitchGroup/package.json +1 -1
  310. package/Table/package.json +1 -1
  311. package/Tabs/package.json +1 -1
  312. package/Tag/package.json +1 -1
  313. package/TagBase/package.json +1 -1
  314. package/Text/package.json +1 -1
  315. package/TextField/package.json +1 -1
  316. package/Theme/package.json +1 -1
  317. package/ThemeToggler/package.json +1 -1
  318. package/Timer/package.json +1 -1
  319. package/Tooltip/package.json +1 -1
  320. package/User/package.json +1 -1
  321. package/UserSelect/package.json +1 -1
  322. package/UserSelectDeprecated/package.json +1 -1
  323. package/__internal__/cjs-src/components/Calendar/Calendar.d.ts +1 -0
  324. package/__internal__/cjs-src/components/Calendar/Calendar.js +8 -4
  325. package/__internal__/cjs-src/components/Card/Card.d.ts +1 -0
  326. package/__internal__/cjs-src/components/Card/Card.js +8 -4
  327. package/__internal__/cjs-src/components/Checkbox/Checkbox.d.ts +2 -0
  328. package/__internal__/cjs-src/components/Checkbox/Checkbox.js +2 -2
  329. package/__internal__/cjs-src/components/Collapse/Collapse.d.ts +1 -0
  330. package/__internal__/cjs-src/components/Collapse/Collapse.js +8 -4
  331. package/__internal__/cjs-src/components/Combobox/Combobox.d.ts +1 -0
  332. package/__internal__/cjs-src/components/Combobox/Combobox.js +11 -4
  333. package/__internal__/cjs-src/components/Combobox/helpers.d.ts +5 -0
  334. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenu.css +18 -0
  335. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuCanary.d.ts +5 -0
  336. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuCanary.js +32 -0
  337. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuItem/ContextMenuItem.css +74 -0
  338. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuItem/ContextMenuItem.d.ts +3 -0
  339. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuItem/ContextMenuItem.js +45 -0
  340. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuLevel/ContextMenuLevel.css +73 -0
  341. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuLevel/ContextMenuLevel.d.ts +4 -0
  342. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuLevel/ContextMenuLevel.js +102 -0
  343. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuLevels/ContextMenuLevels.d.ts +2 -0
  344. package/__internal__/cjs-src/components/ContextMenuCanary/ContextMenuLevels/ContextMenuLevels.js +73 -0
  345. package/__internal__/cjs-src/components/ContextMenuCanary/helper.d.ts +95 -0
  346. package/__internal__/cjs-src/components/ContextMenuCanary/helper.js +119 -0
  347. package/__internal__/cjs-src/components/ContextMenuCanary/types.d.ts +141 -0
  348. package/__internal__/cjs-src/components/ContextMenuCanary/types.js +14 -0
  349. package/__internal__/cjs-src/components/DatePickerCanary/DatePickerCanary.d.ts +1 -0
  350. package/__internal__/cjs-src/components/DatePickerCanary/DatePickerCanary.js +7 -3
  351. package/__internal__/cjs-src/components/DateTimeCanary/DateTimeCanary.d.ts +1 -0
  352. package/__internal__/cjs-src/components/DateTimeCanary/DateTimeCanary.js +7 -3
  353. package/__internal__/cjs-src/components/DragNDropField/DragNDropField.d.ts +1 -0
  354. package/__internal__/cjs-src/components/DragNDropField/DragNDropField.js +8 -5
  355. package/__internal__/cjs-src/components/EventInterceptor/EventInterceptor.d.ts +2 -2
  356. package/__internal__/cjs-src/components/EventInterceptor/eventInterceptorMap.d.ts +2 -81
  357. package/__internal__/cjs-src/components/EventInterceptor/propsHandlers/useCheckboxEventsHandler.d.ts +2 -0
  358. package/__internal__/cjs-src/components/EventInterceptor/types.d.ts +1 -0
  359. package/__internal__/cjs-src/components/EventInterceptor/types.js +2 -0
  360. package/__internal__/cjs-src/components/EventInterceptor/usePropsHandler.d.ts +2 -2
  361. package/__internal__/cjs-src/components/FileField/FileField.d.ts +1 -0
  362. package/__internal__/cjs-src/components/FileField/FileField.js +8 -4
  363. package/__internal__/cjs-src/components/Pagination/Pagination.d.ts +1 -0
  364. package/__internal__/cjs-src/components/Pagination/Pagination.js +9 -6
  365. package/__internal__/cjs-src/components/ProgressStepBarCanary/ProgressStepBarCanary.d.ts +1 -0
  366. package/__internal__/cjs-src/components/ProgressStepBarCanary/ProgressStepBarCanary.js +5 -3
  367. package/__internal__/cjs-src/components/ProgressStepBarCanary/ProgressStepBarItem/ProgressStepBarItem.js +2 -2
  368. package/__internal__/cjs-src/components/Radio/Radio.d.ts +3 -0
  369. package/__internal__/cjs-src/components/Radio/Radio.js +9 -5
  370. package/__internal__/cjs-src/components/Select/Select.js +2 -2
  371. package/__internal__/cjs-src/components/Select/helpers.d.ts +2 -0
  372. package/__internal__/cjs-src/components/SelectComponents/SelectDropdown/SelectDropdown.css +0 -52
  373. package/__internal__/cjs-src/components/SelectComponents/SelectDropdown/SelectDropdown.d.ts +1 -0
  374. package/__internal__/cjs-src/components/SelectComponents/SelectDropdown/SelectDropdown.js +27 -18
  375. package/__internal__/cjs-src/components/SelectComponents/SelectLoader/SelectLoader.css +53 -0
  376. package/__internal__/cjs-src/components/SelectComponents/SelectLoader/SelectLoader.d.ts +9 -0
  377. package/__internal__/cjs-src/components/SelectComponents/SelectLoader/SelectLoader.js +15 -0
  378. package/__internal__/cjs-src/components/Sidebar/Sidebar.css +5 -0
  379. package/__internal__/cjs-src/components/Sidebar/Sidebar.js +1 -1
  380. package/__internal__/cjs-src/components/SliderCanary/SliderCanary.d.ts +1 -0
  381. package/__internal__/cjs-src/components/SliderCanary/SliderCanary.js +9 -7
  382. package/__internal__/cjs-src/components/Switch/Switch.d.ts +1 -0
  383. package/__internal__/cjs-src/components/Switch/Switch.js +8 -4
  384. package/__internal__/cjs-src/components/Table/FilterTooltip/TableFilterTooltip.js +10 -4
  385. package/__internal__/cjs-src/components/Tabs/MoreItems/TabsMoreItems.css +1 -1
  386. package/__internal__/cjs-src/components/Tabs/MoreItems/TabsMoreItems.js +33 -27
  387. package/__internal__/cjs-src/components/Tag/Tag.d.ts +1 -0
  388. package/__internal__/cjs-src/components/Tag/Tag.js +8 -4
  389. package/__internal__/cjs-src/components/ThemeToggler/ThemeToggler.d.ts +4 -30
  390. package/__internal__/cjs-src/components/ThemeToggler/ThemeToggler.js +26 -37
  391. package/__internal__/cjs-src/components/ThemeToggler/helpers.d.ts +274 -0
  392. package/__internal__/cjs-src/components/ThemeToggler/helpers.js +27 -0
  393. package/__internal__/cjs-src/components/ThemeToggler/types.d.ts +45 -0
  394. package/__internal__/cjs-src/components/ThemeToggler/types.js +5 -0
  395. package/__internal__/cjs-src/components/Tooltip/Tooltip.css +1 -88
  396. package/__internal__/cjs-src/components/Tooltip/Tooltip.js +3 -2
  397. package/__internal__/cjs-src/components/UserSelect/UserSelect.d.ts +1 -0
  398. package/__internal__/cjs-src/components/UserSelect/UserSelect.js +5 -3
  399. package/__internal__/cjs-src/components/UserSelect/helpers.d.ts +2 -0
  400. package/__internal__/cjs-src/icons/IconFacebook/IconFacebook.d.ts +5 -0
  401. package/__internal__/cjs-src/icons/IconFacebook/IconFacebook.js +13 -0
  402. package/__internal__/cjs-src/icons/IconFacebook/IconFacebook_size_m.d.ts +3 -0
  403. package/__internal__/cjs-src/icons/IconFacebook/IconFacebook_size_m.js +9 -0
  404. package/__internal__/cjs-src/icons/IconFacebook/IconFacebook_size_m.svg +5 -0
  405. package/__internal__/cjs-src/icons/IconFacebook/IconFacebook_size_s.d.ts +3 -0
  406. package/__internal__/cjs-src/icons/IconFacebook/IconFacebook_size_s.js +9 -0
  407. package/__internal__/cjs-src/icons/IconFacebook/IconFacebook_size_s.svg +5 -0
  408. package/__internal__/cjs-src/icons/IconInstagram/IconInstagram.d.ts +5 -0
  409. package/__internal__/cjs-src/icons/IconInstagram/IconInstagram.js +13 -0
  410. package/__internal__/cjs-src/icons/IconInstagram/IconInstagram_size_m.d.ts +3 -0
  411. package/__internal__/cjs-src/icons/IconInstagram/IconInstagram_size_m.js +9 -0
  412. package/__internal__/cjs-src/icons/IconInstagram/IconInstagram_size_m.svg +7 -0
  413. package/__internal__/cjs-src/icons/IconInstagram/IconInstagram_size_s.d.ts +3 -0
  414. package/__internal__/cjs-src/icons/IconInstagram/IconInstagram_size_s.js +9 -0
  415. package/__internal__/cjs-src/icons/IconInstagram/IconInstagram_size_s.svg +7 -0
  416. package/__internal__/cjs-src/icons/IconVkontakte/IconVkontakte.d.ts +5 -0
  417. package/__internal__/cjs-src/icons/IconVkontakte/IconVkontakte.js +13 -0
  418. package/__internal__/cjs-src/icons/IconVkontakte/IconVkontakte_size_m.d.ts +3 -0
  419. package/__internal__/cjs-src/icons/IconVkontakte/IconVkontakte_size_m.js +9 -0
  420. package/__internal__/cjs-src/icons/IconVkontakte/IconVkontakte_size_m.svg +5 -0
  421. package/__internal__/cjs-src/icons/IconVkontakte/IconVkontakte_size_s.d.ts +3 -0
  422. package/__internal__/cjs-src/icons/IconVkontakte/IconVkontakte_size_s.js +9 -0
  423. package/__internal__/cjs-src/icons/IconVkontakte/IconVkontakte_size_s.svg +5 -0
  424. package/__internal__/cjs-src/icons/IconYandexDzen/IconYandexDzen.d.ts +5 -0
  425. package/__internal__/cjs-src/icons/IconYandexDzen/IconYandexDzen.js +13 -0
  426. package/__internal__/cjs-src/icons/IconYandexDzen/IconYandexDzen_size_m.d.ts +3 -0
  427. package/__internal__/cjs-src/icons/IconYandexDzen/IconYandexDzen_size_m.js +9 -0
  428. package/__internal__/cjs-src/icons/IconYandexDzen/IconYandexDzen_size_m.svg +7 -0
  429. package/__internal__/cjs-src/icons/IconYandexDzen/IconYandexDzen_size_s.d.ts +3 -0
  430. package/__internal__/cjs-src/icons/IconYandexDzen/IconYandexDzen_size_s.js +9 -0
  431. package/__internal__/cjs-src/icons/IconYandexDzen/IconYandexDzen_size_s.svg +7 -0
  432. package/__internal__/cjs-src/icons/IconYoutube/IconYoutube.d.ts +5 -0
  433. package/__internal__/cjs-src/icons/IconYoutube/IconYoutube.js +13 -0
  434. package/__internal__/cjs-src/icons/IconYoutube/IconYoutube_size_m.d.ts +3 -0
  435. package/__internal__/cjs-src/icons/IconYoutube/IconYoutube_size_m.js +9 -0
  436. package/__internal__/cjs-src/icons/IconYoutube/IconYoutube_size_m.svg +5 -0
  437. package/__internal__/cjs-src/icons/IconYoutube/IconYoutube_size_s.d.ts +3 -0
  438. package/__internal__/cjs-src/icons/IconYoutube/IconYoutube_size_s.js +9 -0
  439. package/__internal__/cjs-src/icons/IconYoutube/IconYoutube_size_s.svg +5 -0
  440. package/__internal__/cjs-src/mixs/MixPopoverArrow/MixPopoverArrow.css +88 -0
  441. package/__internal__/cjs-src/mixs/MixPopoverArrow/MixPopoverArrow.d.ts +8 -0
  442. package/__internal__/cjs-src/mixs/MixPopoverArrow/MixPopoverArrow.js +6 -0
  443. package/__internal__/src/components/Calendar/Calendar.d.ts +1 -0
  444. package/__internal__/src/components/Calendar/Calendar.js +7 -3
  445. package/__internal__/src/components/Card/Card.d.ts +1 -0
  446. package/__internal__/src/components/Card/Card.js +7 -3
  447. package/__internal__/src/components/Checkbox/Checkbox.d.ts +2 -0
  448. package/__internal__/src/components/Checkbox/Checkbox.js +2 -2
  449. package/__internal__/src/components/Collapse/Collapse.d.ts +1 -0
  450. package/__internal__/src/components/Collapse/Collapse.js +7 -3
  451. package/__internal__/src/components/Combobox/Combobox.d.ts +1 -0
  452. package/__internal__/src/components/Combobox/Combobox.js +10 -3
  453. package/__internal__/src/components/Combobox/helpers.d.ts +5 -0
  454. package/__internal__/src/components/ContextMenuCanary/ContextMenu.css +18 -0
  455. package/__internal__/src/components/ContextMenuCanary/ContextMenuCanary.d.ts +5 -0
  456. package/__internal__/src/components/ContextMenuCanary/ContextMenuCanary.js +29 -0
  457. package/__internal__/src/components/ContextMenuCanary/ContextMenuItem/ContextMenuItem.css +74 -0
  458. package/__internal__/src/components/ContextMenuCanary/ContextMenuItem/ContextMenuItem.d.ts +3 -0
  459. package/__internal__/src/components/ContextMenuCanary/ContextMenuItem/ContextMenuItem.js +42 -0
  460. package/__internal__/src/components/ContextMenuCanary/ContextMenuLevel/ContextMenuLevel.css +73 -0
  461. package/__internal__/src/components/ContextMenuCanary/ContextMenuLevel/ContextMenuLevel.d.ts +4 -0
  462. package/__internal__/src/components/ContextMenuCanary/ContextMenuLevel/ContextMenuLevel.js +99 -0
  463. package/__internal__/src/components/ContextMenuCanary/ContextMenuLevels/ContextMenuLevels.d.ts +2 -0
  464. package/__internal__/src/components/ContextMenuCanary/ContextMenuLevels/ContextMenuLevels.js +70 -0
  465. package/__internal__/src/components/ContextMenuCanary/helper.d.ts +95 -0
  466. package/__internal__/src/components/ContextMenuCanary/helper.js +115 -0
  467. package/__internal__/src/components/ContextMenuCanary/types.d.ts +141 -0
  468. package/__internal__/src/components/ContextMenuCanary/types.js +11 -0
  469. package/__internal__/src/components/DatePickerCanary/DatePickerCanary.d.ts +1 -0
  470. package/__internal__/src/components/DatePickerCanary/DatePickerCanary.js +7 -3
  471. package/__internal__/src/components/DateTimeCanary/DateTimeCanary.d.ts +1 -0
  472. package/__internal__/src/components/DateTimeCanary/DateTimeCanary.js +7 -3
  473. package/__internal__/src/components/DragNDropField/DragNDropField.d.ts +1 -0
  474. package/__internal__/src/components/DragNDropField/DragNDropField.js +7 -4
  475. package/__internal__/src/components/EventInterceptor/EventInterceptor.d.ts +2 -2
  476. package/__internal__/src/components/EventInterceptor/eventInterceptorMap.d.ts +2 -81
  477. package/__internal__/src/components/EventInterceptor/propsHandlers/useCheckboxEventsHandler.d.ts +2 -0
  478. package/__internal__/src/components/EventInterceptor/types.d.ts +1 -0
  479. package/__internal__/src/components/EventInterceptor/types.js +0 -0
  480. package/__internal__/src/components/EventInterceptor/usePropsHandler.d.ts +2 -2
  481. package/__internal__/src/components/FileField/FileField.d.ts +1 -0
  482. package/__internal__/src/components/FileField/FileField.js +7 -3
  483. package/__internal__/src/components/Pagination/Pagination.d.ts +1 -0
  484. package/__internal__/src/components/Pagination/Pagination.js +8 -5
  485. package/__internal__/src/components/ProgressStepBarCanary/ProgressStepBarCanary.d.ts +1 -0
  486. package/__internal__/src/components/ProgressStepBarCanary/ProgressStepBarCanary.js +4 -2
  487. package/__internal__/src/components/ProgressStepBarCanary/ProgressStepBarItem/ProgressStepBarItem.js +2 -2
  488. package/__internal__/src/components/Radio/Radio.d.ts +3 -0
  489. package/__internal__/src/components/Radio/Radio.js +8 -4
  490. package/__internal__/src/components/Select/Select.js +2 -2
  491. package/__internal__/src/components/Select/helpers.d.ts +2 -0
  492. package/__internal__/src/components/SelectComponents/SelectDropdown/SelectDropdown.css +0 -52
  493. package/__internal__/src/components/SelectComponents/SelectDropdown/SelectDropdown.d.ts +1 -0
  494. package/__internal__/src/components/SelectComponents/SelectDropdown/SelectDropdown.js +30 -21
  495. package/__internal__/src/components/SelectComponents/SelectLoader/SelectLoader.css +53 -0
  496. package/__internal__/src/components/SelectComponents/SelectLoader/SelectLoader.d.ts +9 -0
  497. package/__internal__/src/components/SelectComponents/SelectLoader/SelectLoader.js +11 -0
  498. package/__internal__/src/components/Sidebar/Sidebar.css +5 -0
  499. package/__internal__/src/components/Sidebar/Sidebar.js +1 -1
  500. package/__internal__/src/components/SliderCanary/SliderCanary.d.ts +1 -0
  501. package/__internal__/src/components/SliderCanary/SliderCanary.js +8 -6
  502. package/__internal__/src/components/Switch/Switch.d.ts +1 -0
  503. package/__internal__/src/components/Switch/Switch.js +7 -3
  504. package/__internal__/src/components/Table/FilterTooltip/TableFilterTooltip.js +10 -4
  505. package/__internal__/src/components/Tabs/MoreItems/TabsMoreItems.css +1 -1
  506. package/__internal__/src/components/Tabs/MoreItems/TabsMoreItems.js +33 -27
  507. package/__internal__/src/components/Tag/Tag.d.ts +1 -0
  508. package/__internal__/src/components/Tag/Tag.js +7 -3
  509. package/__internal__/src/components/ThemeToggler/ThemeToggler.d.ts +4 -30
  510. package/__internal__/src/components/ThemeToggler/ThemeToggler.js +24 -35
  511. package/__internal__/src/components/ThemeToggler/helpers.d.ts +274 -0
  512. package/__internal__/src/components/ThemeToggler/helpers.js +23 -0
  513. package/__internal__/src/components/ThemeToggler/types.d.ts +45 -0
  514. package/__internal__/src/components/ThemeToggler/types.js +2 -0
  515. package/__internal__/src/components/Tooltip/Tooltip.css +1 -88
  516. package/__internal__/src/components/Tooltip/Tooltip.js +3 -2
  517. package/__internal__/src/components/UserSelect/UserSelect.d.ts +1 -0
  518. package/__internal__/src/components/UserSelect/UserSelect.js +4 -2
  519. package/__internal__/src/components/UserSelect/helpers.d.ts +2 -0
  520. package/__internal__/src/icons/IconFacebook/IconFacebook.d.ts +5 -0
  521. package/__internal__/src/icons/IconFacebook/IconFacebook.js +9 -0
  522. package/__internal__/src/icons/IconFacebook/IconFacebook_size_m.d.ts +3 -0
  523. package/__internal__/src/icons/IconFacebook/IconFacebook_size_m.js +7 -0
  524. package/__internal__/src/icons/IconFacebook/IconFacebook_size_m.svg +5 -0
  525. package/__internal__/src/icons/IconFacebook/IconFacebook_size_s.d.ts +3 -0
  526. package/__internal__/src/icons/IconFacebook/IconFacebook_size_s.js +7 -0
  527. package/__internal__/src/icons/IconFacebook/IconFacebook_size_s.svg +5 -0
  528. package/__internal__/src/icons/IconInstagram/IconInstagram.d.ts +5 -0
  529. package/__internal__/src/icons/IconInstagram/IconInstagram.js +9 -0
  530. package/__internal__/src/icons/IconInstagram/IconInstagram_size_m.d.ts +3 -0
  531. package/__internal__/src/icons/IconInstagram/IconInstagram_size_m.js +7 -0
  532. package/__internal__/src/icons/IconInstagram/IconInstagram_size_m.svg +7 -0
  533. package/__internal__/src/icons/IconInstagram/IconInstagram_size_s.d.ts +3 -0
  534. package/__internal__/src/icons/IconInstagram/IconInstagram_size_s.js +7 -0
  535. package/__internal__/src/icons/IconInstagram/IconInstagram_size_s.svg +7 -0
  536. package/__internal__/src/icons/IconVkontakte/IconVkontakte.d.ts +5 -0
  537. package/__internal__/src/icons/IconVkontakte/IconVkontakte.js +9 -0
  538. package/__internal__/src/icons/IconVkontakte/IconVkontakte_size_m.d.ts +3 -0
  539. package/__internal__/src/icons/IconVkontakte/IconVkontakte_size_m.js +7 -0
  540. package/__internal__/src/icons/IconVkontakte/IconVkontakte_size_m.svg +5 -0
  541. package/__internal__/src/icons/IconVkontakte/IconVkontakte_size_s.d.ts +3 -0
  542. package/__internal__/src/icons/IconVkontakte/IconVkontakte_size_s.js +7 -0
  543. package/__internal__/src/icons/IconVkontakte/IconVkontakte_size_s.svg +5 -0
  544. package/__internal__/src/icons/IconYandexDzen/IconYandexDzen.d.ts +5 -0
  545. package/__internal__/src/icons/IconYandexDzen/IconYandexDzen.js +9 -0
  546. package/__internal__/src/icons/IconYandexDzen/IconYandexDzen_size_m.d.ts +3 -0
  547. package/__internal__/src/icons/IconYandexDzen/IconYandexDzen_size_m.js +7 -0
  548. package/__internal__/src/icons/IconYandexDzen/IconYandexDzen_size_m.svg +7 -0
  549. package/__internal__/src/icons/IconYandexDzen/IconYandexDzen_size_s.d.ts +3 -0
  550. package/__internal__/src/icons/IconYandexDzen/IconYandexDzen_size_s.js +7 -0
  551. package/__internal__/src/icons/IconYandexDzen/IconYandexDzen_size_s.svg +7 -0
  552. package/__internal__/src/icons/IconYoutube/IconYoutube.d.ts +5 -0
  553. package/__internal__/src/icons/IconYoutube/IconYoutube.js +9 -0
  554. package/__internal__/src/icons/IconYoutube/IconYoutube_size_m.d.ts +3 -0
  555. package/__internal__/src/icons/IconYoutube/IconYoutube_size_m.js +7 -0
  556. package/__internal__/src/icons/IconYoutube/IconYoutube_size_m.svg +5 -0
  557. package/__internal__/src/icons/IconYoutube/IconYoutube_size_s.d.ts +3 -0
  558. package/__internal__/src/icons/IconYoutube/IconYoutube_size_s.js +7 -0
  559. package/__internal__/src/icons/IconYoutube/IconYoutube_size_s.svg +5 -0
  560. package/__internal__/src/mixs/MixPopoverArrow/MixPopoverArrow.css +88 -0
  561. package/__internal__/src/mixs/MixPopoverArrow/MixPopoverArrow.d.ts +8 -0
  562. package/__internal__/src/mixs/MixPopoverArrow/MixPopoverArrow.js +3 -0
  563. package/createIcon/package.json +1 -1
  564. package/createResponsesImage/package.json +1 -1
  565. package/package.json +8 -1
  566. package/useBreakpoints/package.json +1 -1
  567. package/useChoiceGroup/package.json +1 -1
  568. package/useChoiceGroupIndexed/package.json +1 -1
  569. package/useClickOutside/package.json +1 -1
  570. package/useComponentSize/package.json +1 -1
  571. package/useDebounce/package.json +1 -1
  572. package/useFlag/package.json +1 -1
  573. package/useForkRef/package.json +1 -1
  574. package/useGlobalKeys/package.json +1 -1
  575. package/useHideElementsInLine/package.json +1 -1
  576. package/useKeys/package.json +1 -1
  577. package/useMutableRef/package.json +1 -1
  578. package/useOverflow/package.json +1 -1
  579. package/usePrevious/package.json +1 -1
  580. package/useRefs/package.json +1 -1
  581. package/useResizeObserved/package.json +1 -1
  582. package/useScrollElements/package.json +1 -1
  583. package/useScrollPosition/package.json +1 -1
  584. package/useSelect/package.json +1 -1
  585. package/useSortSteps/package.json +1 -1
  586. package/useThemeVars/package.json +1 -1
  587. package/useTimer/package.json +1 -1
  588. package/withTooltip/package.json +1 -1
@@ -1,81 +1,2 @@
1
- /// <reference types="react" />
2
- export declare const eventInterceptorMap: {
3
- readonly Button: <T extends import("../Button/Button").Props>(props: T, handler: import("./EventInterceptor").EventInterceptorHandler, ref: import("react").RefObject<HTMLElement>) => T;
4
- readonly Checkbox: <P extends {
5
- checked: boolean | undefined;
6
- size?: "m" | "l" | undefined;
7
- view?: "ghost" | "primary" | undefined;
8
- align?: "center" | "top" | undefined;
9
- disabled?: boolean | undefined;
10
- intermediate?: boolean | undefined;
11
- label?: string | undefined;
12
- onChange?: import("../Checkbox/Checkbox").CheckboxPropOnChange | undefined;
13
- name?: string | undefined;
14
- onFocus?: ((event: import("react").FocusEvent<HTMLInputElement>) => void) | undefined;
15
- onBlur?: ((event: import("react").FocusEvent<HTMLInputElement>) => void) | undefined;
16
- autoFocus?: boolean | undefined;
17
- readOnly?: boolean | undefined;
18
- required?: boolean | undefined;
19
- step?: string | number | undefined;
20
- tabIndex?: number | undefined;
21
- inputRef?: ((instance: HTMLInputElement | null) => void) | import("react").RefObject<HTMLInputElement> | null | undefined;
22
- children?: undefined;
23
- } & Pick<import("react").HTMLAttributes<HTMLLabelElement>, "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & import("react").RefAttributes<HTMLLabelElement>>(props: P, handler: import("./EventInterceptor").EventInterceptorHandler, ref: import("react").RefObject<HTMLLabelElement>) => P;
24
- readonly Select: <PROPS extends import("../Select/helpers").SelectProps<import("../Select/helpers").DefaultItem, import("../Select/helpers").DefaultGroup>>(props: PROPS, handler: import("./EventInterceptor").EventInterceptorHandler, ref: import("react").RefObject<HTMLDivElement | null>) => PROPS;
25
- readonly SnackBar: <P_1 extends import("../SnackBar/types").SnackBarProps<import("../SnackBar/types").SnackBarItemDefault>>(props: P_1, handler: import("./EventInterceptor").EventInterceptorHandler) => P_1;
26
- readonly TextField: <P_2 extends {
27
- className?: string | undefined;
28
- value?: string | null | undefined;
29
- cols?: number | undefined;
30
- onChange?: import("../TextField/helpers").TextFieldPropOnChange | undefined;
31
- id?: string | number | undefined;
32
- name?: string | undefined;
33
- type?: string | undefined;
34
- disabled?: boolean | undefined;
35
- maxLength?: number | undefined;
36
- size?: "xs" | "s" | "m" | "l" | undefined;
37
- view?: "default" | "clear" | undefined;
38
- form?: "default" | "round" | "brick" | "brickRound" | "roundBrick" | "brickDefault" | "defaultBrick" | "clearRound" | "roundClear" | "clearDefault" | "defaultClear" | "brickClear" | "clearBrick" | "clearClear" | undefined;
39
- state?: "alert" | "success" | "warning" | undefined;
40
- status?: "alert" | "success" | "warning" | undefined;
41
- width?: "default" | "full" | undefined;
42
- onFocus?: ((event: import("react").FocusEvent<HTMLElement>) => void) | undefined;
43
- onBlur?: ((event: import("react").FocusEvent<HTMLElement>) => void) | undefined;
44
- autoFocus?: boolean | undefined;
45
- placeholder?: string | undefined;
46
- leftSide?: string | import("react").FC<import("../../utils/types/PropsWithHTMLAttributes").PropsWithHTMLAttributesAndRef<{
47
- view?: "link" | "alert" | "brand" | "ghost" | "primary" | "secondary" | "success" | "warning" | "disabled" | undefined;
48
- size?: "xs" | "s" | "m" | undefined;
49
- }, HTMLSpanElement>> | undefined;
50
- rightSide?: string | import("react").FC<import("../../utils/types/PropsWithHTMLAttributes").PropsWithHTMLAttributesAndRef<{
51
- view?: "link" | "alert" | "brand" | "ghost" | "primary" | "secondary" | "success" | "warning" | "disabled" | undefined;
52
- size?: "xs" | "s" | "m" | undefined;
53
- }, HTMLSpanElement>> | undefined;
54
- withClearButton?: boolean | undefined;
55
- autoComplete?: "on" | "off" | "tel" | "url" | "email" | "name" | "honorific-prefix" | "given-name" | "additional-name" | "family-name" | "honorific-suffix" | "nickname" | "username" | "new-password" | "current-password" | "one-time-code" | "organization-title" | "organization" | "street-address" | "address-line1" | "address-line2" | "address-line3" | "address-level1" | "address-level2" | "address-level3" | "address-level4" | "country" | "country-name" | "postal-code" | "cc-name" | "cc-given-name" | "cc-additional-name" | "cc-family-name" | "cc-number" | "cc-exp" | "cc-exp-month" | "cc-exp-year" | "cc-csc" | "cc-type" | "transaction-currency" | "transaction-amount" | "language" | "bday" | "bday-day" | "bday-month" | "bday-year" | "sex" | "tel-country-code" | "tel-national" | "tel-area-code" | "tel-local" | "tel-extension" | "impp" | "photo" | undefined;
56
- max?: string | number | undefined;
57
- min?: string | number | undefined;
58
- readOnly?: boolean | undefined;
59
- required?: boolean | undefined;
60
- step?: string | number | number[] | undefined;
61
- tabIndex?: number | undefined;
62
- inputContainerRef?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
63
- inputRef?: ((instance: HTMLInputElement | HTMLTextAreaElement | null) => void) | import("react").RefObject<HTMLInputElement | HTMLTextAreaElement> | null | undefined;
64
- ariaLabel?: string | undefined;
65
- iconSize?: "xs" | "s" | "m" | undefined;
66
- children?: undefined;
67
- label?: string | undefined;
68
- caption?: string | undefined;
69
- labelPosition?: "left" | "top" | undefined;
70
- focused?: boolean | undefined;
71
- } & Pick<import("react").HTMLAttributes<HTMLDivElement>, "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "lang" | "slot" | "spellCheck" | "style" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & {
72
- rows?: undefined;
73
- minRows?: undefined;
74
- maxRows?: undefined;
75
- } & {
76
- rightSide?: string | import("react").FC<import("../../utils/types/PropsWithHTMLAttributes").PropsWithHTMLAttributesAndRef<{
77
- view?: "link" | "alert" | "brand" | "ghost" | "primary" | "secondary" | "success" | "warning" | "disabled" | undefined;
78
- size?: "xs" | "s" | "m" | undefined;
79
- }, HTMLSpanElement>> | undefined;
80
- } & import("react").RefAttributes<HTMLElement>>(props: P_2, handler: import("./EventInterceptor").EventInterceptorHandler, ref: import("react").RefObject<HTMLDivElement>) => P_2;
81
- };
1
+ import { EventInterceptorComponentName } from './types';
2
+ export declare const eventInterceptorMap: Partial<Record<EventInterceptorComponentName, ((...args: any[]) => any) | undefined>>;
@@ -19,4 +19,6 @@ export declare const useCheckboxEventsHandler: <P extends {
19
19
  tabIndex?: number | undefined;
20
20
  inputRef?: ((instance: HTMLInputElement | null) => void) | React.RefObject<HTMLInputElement> | null | undefined;
21
21
  children?: undefined;
22
+ for?: string | undefined;
23
+ inputId?: string | undefined;
22
24
  } & Pick<React.HTMLAttributes<HTMLLabelElement>, "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "className" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLLabelElement>>(props: P, handler: EventInterceptorHandler, ref: React.RefObject<HTMLLabelElement>) => P;
@@ -0,0 +1 @@
1
+ export declare type EventInterceptorComponentName = 'Attachment' | 'Avatar' | 'Badge' | 'Breadcrumbs' | 'Button' | 'Calendar' | 'Card' | 'Checkbox' | 'CheckboxGroup' | 'ChoiceGroup' | 'Collapse' | 'CollapseGroup' | 'Combobox' | 'ContextMenu' | 'DatePicker' | 'DateTime' | 'DragNDropField' | 'File' | 'FileField' | 'Grid' | 'Header' | 'Informer' | 'Layout' | 'Loader' | 'Modal' | 'Pagination' | 'Popover' | 'ProgressSpin' | 'ProgressStepBar' | 'Radio' | 'RadioGroup' | 'Select' | 'Sidebar' | 'Skeleton' | 'Slider' | 'SnackBar' | 'Steps' | 'Switch' | 'SwitchGroup' | 'Table' | 'Tabs' | 'Tag' | 'TagBase' | 'Text' | 'TextField' | 'ThemeToggler' | 'Timer' | 'Tooltip' | 'User' | 'UserSelect';
@@ -1,3 +1,3 @@
1
1
  import React from 'react';
2
- import { EventInterceptorMapKeys } from './EventInterceptor';
3
- export declare const usePropsHandler: <PROPS extends {}>(componentName: EventInterceptorMapKeys, props: PROPS, ref?: ((instance: HTMLElement | null) => void) | React.RefObject<HTMLElement> | null | undefined) => PROPS;
2
+ import { EventInterceptorComponentName } from './types';
3
+ export declare const usePropsHandler: <PROPS extends {}>(componentName: EventInterceptorComponentName, props: PROPS, ref?: ((instance: HTMLElement | null) => void) | React.RefObject<HTMLElement> | null | undefined) => PROPS;
@@ -12,6 +12,7 @@ export declare type FileFieldProps = PropsWithJsxAttributes<{
12
12
  children?: RenderFn | React.ReactNode;
13
13
  inputRef?: React.Ref<HTMLInputElement>;
14
14
  }, 'input'>;
15
+ export declare const COMPONENT_NAME: "FileField";
15
16
  export declare const cnFileField: import("@bem-react/classname").ClassNameFormatter;
16
17
  export declare const FileField: React.FC<FileFieldProps>;
17
18
  export {};
@@ -1,16 +1,20 @@
1
1
  import { __assign, __rest } from "tslib";
2
2
  import './FileField.css';
3
- import React from 'react';
3
+ import React, { useRef } from 'react';
4
+ import { useForkRef } from '../../hooks/useForkRef/useForkRef';
4
5
  import { cnMixVisuallyHidden } from '../../mixs/MixVisuallyHidden/MixVisuallyHidden';
5
6
  import { cn } from '../../utils/bem';
7
+ import { usePropsHandler } from '../EventInterceptor/usePropsHandler';
8
+ export var COMPONENT_NAME = 'FileField';
6
9
  function isRenderFn(fn) {
7
10
  return fn.call !== undefined;
8
11
  }
9
12
  export var cnFileField = cn('FileField');
10
13
  export var FileField = function (props) {
11
- var className = props.className, children = props.children, id = props.id, inputRef = props.inputRef, _a = props["aria-label"], ariaLabel = _a === void 0 ? 'File input' : _a, inputProps = __rest(props, ["className", "children", "id", "inputRef", 'aria-label']);
14
+ var fileFieldRef = useRef(null);
15
+ var _a = usePropsHandler(COMPONENT_NAME, props, fileFieldRef), className = _a.className, children = _a.children, id = _a.id, inputRef = _a.inputRef, _b = _a["aria-label"], ariaLabel = _b === void 0 ? 'File input' : _b, inputProps = __rest(_a, ["className", "children", "id", "inputRef", 'aria-label']);
12
16
  var content = isRenderFn(children) ? children({ role: 'button', as: 'span' }) : children;
13
17
  return (React.createElement("label", { htmlFor: id, className: cnFileField(null, [className]) },
14
- React.createElement("input", __assign({}, inputProps, { className: cnFileField('Input', [cnMixVisuallyHidden()]), id: id, type: "file", "aria-label": ariaLabel, ref: inputRef })),
18
+ React.createElement("input", __assign({}, inputProps, { className: cnFileField('Input', [cnMixVisuallyHidden()]), id: id, type: "file", "aria-label": ariaLabel, ref: useForkRef([inputRef, fileFieldRef]) })),
15
19
  content));
16
20
  };
@@ -41,5 +41,6 @@ declare type Props = {
41
41
  position?: PaginationPropPosition;
42
42
  });
43
43
  declare type Pagination = (props: PropsWithHTMLAttributesAndRef<Props, HTMLDivElement>) => React.ReactElement | null;
44
+ export declare const COMPONENT_NAME: "Pagination";
44
45
  export declare const Pagination: Pagination;
45
46
  export {};
@@ -1,10 +1,11 @@
1
1
  import { __assign, __read, __rest, __spread } from "tslib";
2
2
  import './Pagination.css';
3
- import React from 'react';
3
+ import React, { useRef } from 'react';
4
4
  import { IconBackward } from '../../icons/IconBackward/IconBackward';
5
5
  import { IconForward } from '../../icons/IconForward/IconForward';
6
6
  import { cn } from '../../utils/bem';
7
7
  import { Button } from '../Button/Button';
8
+ import { usePropsHandler } from '../EventInterceptor/usePropsHandler';
8
9
  import { Text } from '../Text/Text';
9
10
  import { TextField } from '../TextField/TextField';
10
11
  import { getPaginationInfo } from './helpers';
@@ -18,8 +19,10 @@ export var paginationPositions = ['left', 'center', 'right'];
18
19
  export var paginationDefaultPosition = 'center';
19
20
  var getDefaultLabel = function (totalPages) { return "\u0438\u0437 " + totalPages; };
20
21
  export var cnPagination = cn('Pagination');
22
+ export var COMPONENT_NAME = 'Pagination';
21
23
  export var Pagination = React.forwardRef(function (props, ref) {
22
- var _a = props.currentPage, currentPage = _a === void 0 ? 0 : _a, _b = props.totalPages, totalPages = _b === void 0 ? 0 : _b, onChange = props.onChange, _c = props.getLabel, getLabel = _c === void 0 ? getDefaultLabel(totalPages) : _c, _d = props.form, form = _d === void 0 ? paginationDefaultForm : _d, _e = props.size, size = _e === void 0 ? paginationDefaultSize : _e, _f = props.type, type = _f === void 0 ? paginationDefaultType : _f, _g = props.position, position = _g === void 0 ? paginationDefaultPosition : _g, _h = props.minified, minified = _h === void 0 ? false : _h, _j = props.hotkeys, hotkeys = _j === void 0 ? {
24
+ var paginationRef = useRef(null);
25
+ var _a = usePropsHandler(COMPONENT_NAME, props, paginationRef), _b = _a.currentPage, currentPage = _b === void 0 ? 0 : _b, _c = _a.totalPages, totalPages = _c === void 0 ? 0 : _c, onChange = _a.onChange, _d = _a.getLabel, getLabel = _d === void 0 ? getDefaultLabel(totalPages) : _d, _e = _a.form, form = _e === void 0 ? paginationDefaultForm : _e, _f = _a.size, size = _f === void 0 ? paginationDefaultSize : _f, _g = _a.type, type = _g === void 0 ? paginationDefaultType : _g, _h = _a.position, position = _h === void 0 ? paginationDefaultPosition : _h, _j = _a.minified, minified = _j === void 0 ? false : _j, _k = _a.hotkeys, hotkeys = _k === void 0 ? {
23
26
  nextPage: {
24
27
  label: 'Alt →',
25
28
  values: ['Alt', 'ArrowRight']
@@ -28,12 +31,12 @@ export var Pagination = React.forwardRef(function (props, ref) {
28
31
  label: '← Alt',
29
32
  values: ['Alt', 'ArrowLeft']
30
33
  }
31
- } : _j, _k = props.containerEventListener, containerEventListener = _k === void 0 ? window : _k, className = props.className, otherProps = __rest(props, ["currentPage", "totalPages", "onChange", "getLabel", "form", "size", "type", "position", "minified", "hotkeys", "containerEventListener", "className"]);
34
+ } : _k, _l = _a.containerEventListener, containerEventListener = _l === void 0 ? window : _l, className = _a.className, otherProps = __rest(_a, ["currentPage", "totalPages", "onChange", "getLabel", "form", "size", "type", "position", "minified", "hotkeys", "containerEventListener", "className"]);
32
35
  if (!totalPages)
33
36
  return null;
34
37
  var currPage = currentPage + 1;
35
- var _l = getPaginationInfo(currPage, totalPages), prevPage = _l.prevPage, nextPage = _l.nextPage, isStartDots = _l.isStartDots, isEndDots = _l.isEndDots, pages = _l.pages, isEmpty = _l.isEmpty;
36
- var _m = __read(React.useState([]), 2), keys = _m[0], setKeys = _m[1];
38
+ var _m = getPaginationInfo(currPage, totalPages), prevPage = _m.prevPage, nextPage = _m.nextPage, isStartDots = _m.isStartDots, isEndDots = _m.isEndDots, pages = _m.pages, isEmpty = _m.isEmpty;
39
+ var _o = __read(React.useState([]), 2), keys = _o[0], setKeys = _o[1];
37
40
  var changePage = function (page) {
38
41
  if (page && page !== currPage && onChange) {
39
42
  onChange(page - 1);
@@ -1,3 +1,4 @@
1
1
  import './ProgressStepBar.css';
2
2
  import { ProgressStepBarComponent } from './helpers';
3
+ export declare const COMPONENT_NAME: "ProgressStepBar";
3
4
  export declare const ProgressStepBar: ProgressStepBarComponent;
@@ -8,14 +8,16 @@ import { useScrollElements } from '../../hooks/useScrollElements/useScrollElemen
8
8
  import { IconArrowLeft } from '../../icons/IconArrowLeft/IconArrowLeft';
9
9
  import { IconArrowRight } from '../../icons/IconArrowRight/IconArrowRight';
10
10
  import { Button } from '../Button/Button';
11
+ import { usePropsHandler } from '../EventInterceptor/usePropsHandler';
11
12
  import { ProgressStepBarItem } from './ProgressStepBarItem/ProgressStepBarItem';
12
13
  import { ProgressStepBarLine } from './ProgressStepBarLine/ProgressStepBarLine';
13
14
  import { cnProgressStepBar, getItemPosition, getLineSize, propDirectionDefault, propSizeDefault, withDefaultGetters, } from './helpers';
15
+ export var COMPONENT_NAME = 'ProgressStepBar';
14
16
  function ProgressStepBarRender(props, ref) {
15
- var _a = withDefaultGetters(props), _b = _a.steps, steps = _b === void 0 ? [] : _b, _c = _a.direction, direction = _c === void 0 ? propDirectionDefault : _c, _d = _a.size, size = _d === void 0 ? propSizeDefault : _d, className = _a.className, activeStepIndex = _a.activeStepIndex, onItemClick = _a.onItemClick, getItemContent = _a.getItemContent, getItemLabel = _a.getItemLabel, getItemPoint = _a.getItemPoint, getItemProgress = _a.getItemProgress, getItemStatus = _a.getItemStatus, getItemTooltipContent = _a.getItemTooltipContent, getItemLineStatus = _a.getItemLineStatus, getItemOnClick = _a.getItemOnClick, style = _a.style, otherProps = __rest(_a, ["steps", "direction", "size", "className", "activeStepIndex", "onItemClick", "getItemContent", "getItemLabel", "getItemPoint", "getItemProgress", "getItemStatus", "getItemTooltipContent", "getItemLineStatus", "getItemOnClick", "style"]);
17
+ var containerRef = useRef(null);
18
+ var _a = usePropsHandler(COMPONENT_NAME, withDefaultGetters(props), containerRef), _b = _a.steps, steps = _b === void 0 ? [] : _b, _c = _a.direction, direction = _c === void 0 ? propDirectionDefault : _c, _d = _a.size, size = _d === void 0 ? propSizeDefault : _d, className = _a.className, activeStepIndex = _a.activeStepIndex, onItemClick = _a.onItemClick, getItemContent = _a.getItemContent, getItemLabel = _a.getItemLabel, getItemPoint = _a.getItemPoint, getItemProgress = _a.getItemProgress, getItemStatus = _a.getItemStatus, getItemTooltipContent = _a.getItemTooltipContent, getItemLineStatus = _a.getItemLineStatus, getItemOnClick = _a.getItemOnClick, style = _a.style, otherProps = __rest(_a, ["steps", "direction", "size", "className", "activeStepIndex", "onItemClick", "getItemContent", "getItemLabel", "getItemPoint", "getItemProgress", "getItemStatus", "getItemTooltipContent", "getItemLineStatus", "getItemOnClick", "style"]);
16
19
  var _e = __read(useState([]), 2), lines = _e[0], setLines = _e[1];
17
20
  var _f = __read(useState(activeStepIndex || 0), 2), visibleIndex = _f[0], setVisibleIndex = _f[1];
18
- var containerRef = useRef(null);
19
21
  var listRef = useRef(null);
20
22
  var _g = useComponentSize(containerRef), width = _g.width, height = _g.height;
21
23
  var _h = useScrollElements(steps), refs = _h.refs, scrollTo = _h.scrollTo;
@@ -33,7 +33,7 @@ var renderPointContent = function (point, size, progress) {
33
33
  return React.createElement(Icon, { size: "xs" });
34
34
  };
35
35
  export var ProgressStepBarItem = React.forwardRef(function (props, ref) {
36
- var content = props.content, tooltipContent = props.tooltipContent, label = props.label, point = props.point, status = props.status, progress = props.progress, direction = props.direction, size = props.size, pointRef = props.pointRef, onClick = props.onClick, _a = props.position, position = _a === void 0 ? propPositionDefault : _a, otherProps = __rest(props, ["content", "tooltipContent", "label", "point", "status", "progress", "direction", "size", "pointRef", "onClick", "position"]);
36
+ var content = props.content, tooltipContent = props.tooltipContent, label = props.label, point = props.point, status = props.status, progress = props.progress, direction = props.direction, size = props.size, pointRef = props.pointRef, onClick = props.onClick, _a = props.position, position = _a === void 0 ? propPositionDefault : _a, tooltipZIndex = props.tooltipZIndex, otherProps = __rest(props, ["content", "tooltipContent", "label", "point", "status", "progress", "direction", "size", "pointRef", "onClick", "position", "tooltipZIndex"]);
37
37
  var _b = __read(useFlag(), 2), isTooltipVisible = _b[0], _c = _b[1], setTooltipVisible = _c.on, setTooltipUnVisible = _c.off;
38
38
  var anchorRef = useRef(null);
39
39
  var pointProps = {
@@ -62,5 +62,5 @@ export var ProgressStepBarItem = React.forwardRef(function (props, ref) {
62
62
  (label || content) && (React.createElement("div", { className: cnProgressStepBarItem('Content', { bottomOffset: !!content }) },
63
63
  label && (React.createElement(Text, { className: cnProgressStepBarItem('Label'), ref: anchorRef, size: size, onMouseEnter: setTooltipVisible, onMouseLeave: setTooltipUnVisible, lineHeight: size === 's' ? 'xs' : size, view: "primary" }, label)),
64
64
  content))),
65
- tooltipContent && isTooltipVisible && (React.createElement(Tooltip, { anchorRef: label || content ? anchorRef : pointRef, className: cnProgressStepBarItem('Tooltip'), direction: direction === 'horizontal' ? 'downCenter' : 'leftUp', possibleDirections: direction === 'horizontal' ? possibleHorizontalDirections : possibleVerticalDirections }, tooltipContent))));
65
+ tooltipContent && isTooltipVisible && (React.createElement(Tooltip, { anchorRef: label || content ? anchorRef : pointRef, className: cnProgressStepBarItem('Tooltip'), direction: direction === 'horizontal' ? 'downCenter' : 'leftUp', style: { zIndex: tooltipZIndex }, possibleDirections: direction === 'horizontal' ? possibleHorizontalDirections : possibleVerticalDirections }, tooltipContent))));
66
66
  });
@@ -33,7 +33,10 @@ export declare type Props = {
33
33
  tabIndex?: number;
34
34
  inputRef?: React.Ref<HTMLInputElement>;
35
35
  children?: never;
36
+ for?: string;
37
+ inputId?: string;
36
38
  };
37
39
  export declare type RadioProps = PropsWithHTMLAttributes<Props, HTMLLabelElement>;
38
40
  export declare const cnRadio: import("@bem-react/classname").ClassNameFormatter;
41
+ export declare const COMPONENT_NAME: "Radio";
39
42
  export declare const Radio: React.ForwardRefExoticComponent<Props & Pick<React.HTMLAttributes<HTMLLabelElement>, "defaultChecked" | "defaultValue" | "suppressContentEditableWarning" | "suppressHydrationWarning" | "accessKey" | "contentEditable" | "contextMenu" | "dir" | "draggable" | "hidden" | "id" | "lang" | "placeholder" | "slot" | "spellCheck" | "style" | "title" | "translate" | "radioGroup" | "role" | "about" | "datatype" | "inlist" | "prefix" | "property" | "resource" | "typeof" | "vocab" | "autoCapitalize" | "autoCorrect" | "autoSave" | "color" | "itemProp" | "itemScope" | "itemType" | "itemID" | "itemRef" | "results" | "security" | "unselectable" | "inputMode" | "is" | "aria-activedescendant" | "aria-atomic" | "aria-autocomplete" | "aria-busy" | "aria-checked" | "aria-colcount" | "aria-colindex" | "aria-colspan" | "aria-controls" | "aria-current" | "aria-describedby" | "aria-details" | "aria-disabled" | "aria-dropeffect" | "aria-errormessage" | "aria-expanded" | "aria-flowto" | "aria-grabbed" | "aria-haspopup" | "aria-hidden" | "aria-invalid" | "aria-keyshortcuts" | "aria-label" | "aria-labelledby" | "aria-level" | "aria-live" | "aria-modal" | "aria-multiline" | "aria-multiselectable" | "aria-orientation" | "aria-owns" | "aria-placeholder" | "aria-posinset" | "aria-pressed" | "aria-readonly" | "aria-relevant" | "aria-required" | "aria-roledescription" | "aria-rowcount" | "aria-rowindex" | "aria-rowspan" | "aria-selected" | "aria-setsize" | "aria-sort" | "aria-valuemax" | "aria-valuemin" | "aria-valuenow" | "aria-valuetext" | "dangerouslySetInnerHTML" | "onCopy" | "onCopyCapture" | "onCut" | "onCutCapture" | "onPaste" | "onPasteCapture" | "onCompositionEnd" | "onCompositionEndCapture" | "onCompositionStart" | "onCompositionStartCapture" | "onCompositionUpdate" | "onCompositionUpdateCapture" | "onFocusCapture" | "onBlurCapture" | "onChangeCapture" | "onBeforeInput" | "onBeforeInputCapture" | "onInput" | "onInputCapture" | "onReset" | "onResetCapture" | "onSubmit" | "onSubmitCapture" | "onInvalid" | "onInvalidCapture" | "onLoad" | "onLoadCapture" | "onError" | "onErrorCapture" | "onKeyDown" | "onKeyDownCapture" | "onKeyPress" | "onKeyPressCapture" | "onKeyUp" | "onKeyUpCapture" | "onAbort" | "onAbortCapture" | "onCanPlay" | "onCanPlayCapture" | "onCanPlayThrough" | "onCanPlayThroughCapture" | "onDurationChange" | "onDurationChangeCapture" | "onEmptied" | "onEmptiedCapture" | "onEncrypted" | "onEncryptedCapture" | "onEnded" | "onEndedCapture" | "onLoadedData" | "onLoadedDataCapture" | "onLoadedMetadata" | "onLoadedMetadataCapture" | "onLoadStart" | "onLoadStartCapture" | "onPause" | "onPauseCapture" | "onPlay" | "onPlayCapture" | "onPlaying" | "onPlayingCapture" | "onProgress" | "onProgressCapture" | "onRateChange" | "onRateChangeCapture" | "onSeeked" | "onSeekedCapture" | "onSeeking" | "onSeekingCapture" | "onStalled" | "onStalledCapture" | "onSuspend" | "onSuspendCapture" | "onTimeUpdate" | "onTimeUpdateCapture" | "onVolumeChange" | "onVolumeChangeCapture" | "onWaiting" | "onWaitingCapture" | "onAuxClick" | "onAuxClickCapture" | "onClick" | "onClickCapture" | "onContextMenu" | "onContextMenuCapture" | "onDoubleClick" | "onDoubleClickCapture" | "onDrag" | "onDragCapture" | "onDragEnd" | "onDragEndCapture" | "onDragEnter" | "onDragEnterCapture" | "onDragExit" | "onDragExitCapture" | "onDragLeave" | "onDragLeaveCapture" | "onDragOver" | "onDragOverCapture" | "onDragStart" | "onDragStartCapture" | "onDrop" | "onDropCapture" | "onMouseDown" | "onMouseDownCapture" | "onMouseEnter" | "onMouseLeave" | "onMouseMove" | "onMouseMoveCapture" | "onMouseOut" | "onMouseOutCapture" | "onMouseOver" | "onMouseOverCapture" | "onMouseUp" | "onMouseUpCapture" | "onSelect" | "onSelectCapture" | "onTouchCancel" | "onTouchCancelCapture" | "onTouchEnd" | "onTouchEndCapture" | "onTouchMove" | "onTouchMoveCapture" | "onTouchStart" | "onTouchStartCapture" | "onPointerDown" | "onPointerDownCapture" | "onPointerMove" | "onPointerMoveCapture" | "onPointerUp" | "onPointerUpCapture" | "onPointerCancel" | "onPointerCancelCapture" | "onPointerEnter" | "onPointerEnterCapture" | "onPointerLeave" | "onPointerLeaveCapture" | "onPointerOver" | "onPointerOverCapture" | "onPointerOut" | "onPointerOutCapture" | "onGotPointerCapture" | "onGotPointerCaptureCapture" | "onLostPointerCapture" | "onLostPointerCaptureCapture" | "onScroll" | "onScrollCapture" | "onWheel" | "onWheelCapture" | "onAnimationStart" | "onAnimationStartCapture" | "onAnimationEnd" | "onAnimationEndCapture" | "onAnimationIteration" | "onAnimationIterationCapture" | "onTransitionEnd" | "onTransitionEndCapture"> & React.RefAttributes<HTMLLabelElement>>;
@@ -1,8 +1,10 @@
1
1
  import { __assign, __rest } from "tslib";
2
2
  import './Radio.css';
3
- import React from 'react';
3
+ import React, { useRef } from 'react';
4
+ import { useForkRef } from '../../hooks/useForkRef/useForkRef';
4
5
  import { cnMixFocus } from '../../mixs/MixFocus/MixFocus';
5
6
  import { cn } from '../../utils/bem';
7
+ import { usePropsHandler } from '../EventInterceptor/usePropsHandler';
6
8
  export var radioPropSize = ['m', 'l'];
7
9
  export var radioPropSizeDefault = radioPropSize[0];
8
10
  export var radioPropView = ['primary', 'ghost'];
@@ -10,14 +12,16 @@ export var radioPropViewDefault = radioPropView[0];
10
12
  export var radioPropAlign = ['center', 'top'];
11
13
  export var radioPropAlignDefault = radioPropAlign[0];
12
14
  export var cnRadio = cn('Radio');
15
+ export var COMPONENT_NAME = 'Radio';
13
16
  export var Radio = React.forwardRef(function (props, ref) {
14
- var _a = props.checked, checked = _a === void 0 ? false : _a, name = props.name, _b = props.size, size = _b === void 0 ? radioPropSizeDefault : _b, _c = props.view, view = _c === void 0 ? radioPropViewDefault : _c, _d = props.align, align = _d === void 0 ? radioPropAlignDefault : _d, disabled = props.disabled, className = props.className, label = props.label, onChange = props.onChange, onFocus = props.onFocus, onBlur = props.onBlur, readOnly = props.readOnly, required = props.required, step = props.step, tabIndex = props.tabIndex, inputRef = props.inputRef, otherProps = __rest(props, ["checked", "name", "size", "view", "align", "disabled", "className", "label", "onChange", "onFocus", "onBlur", "readOnly", "required", "step", "tabIndex", "inputRef"]);
17
+ var radioRef = useRef(null);
18
+ var _a = usePropsHandler(COMPONENT_NAME, props, radioRef), _b = _a.checked, checked = _b === void 0 ? false : _b, name = _a.name, _c = _a.size, size = _c === void 0 ? radioPropSizeDefault : _c, _d = _a.view, view = _d === void 0 ? radioPropViewDefault : _d, _e = _a.align, align = _e === void 0 ? radioPropAlignDefault : _e, disabled = _a.disabled, className = _a.className, label = _a.label, onChange = _a.onChange, onFocus = _a.onFocus, onBlur = _a.onBlur, readOnly = _a.readOnly, required = _a.required, step = _a.step, tabIndex = _a.tabIndex, inputId = _a.inputId, inputRef = _a.inputRef, otherProps = __rest(_a, ["checked", "name", "size", "view", "align", "disabled", "className", "label", "onChange", "onFocus", "onBlur", "readOnly", "required", "step", "tabIndex", "inputId", "inputRef"]);
15
19
  var handleChange = function (e) {
16
20
  if (onChange) {
17
21
  onChange({ e: e, checked: !checked });
18
22
  }
19
23
  };
20
- return (React.createElement("label", __assign({}, otherProps, { className: cnRadio({ size: size, view: view, disabled: disabled, align: align }, [className]), ref: ref }),
21
- React.createElement("input", { type: "radio", name: name, className: cnRadio('Input', [cnMixFocus()]), checked: checked, disabled: disabled, onChange: handleChange, onFocus: onFocus, onBlur: onBlur, readOnly: readOnly, required: required, step: step, tabIndex: tabIndex, ref: inputRef }),
24
+ return (React.createElement("label", __assign({}, otherProps, { className: cnRadio({ size: size, view: view, disabled: disabled, align: align }, [className]), ref: useForkRef([ref, radioRef]) }),
25
+ React.createElement("input", { type: "radio", name: name, className: cnRadio('Input', [cnMixFocus()]), checked: checked, disabled: disabled, onChange: handleChange, onFocus: onFocus, onBlur: onBlur, readOnly: readOnly, required: required, step: step, id: inputId, tabIndex: tabIndex, ref: inputRef }),
22
26
  label && React.createElement("span", { className: cnRadio('Label') }, label)));
23
27
  });
@@ -15,7 +15,7 @@ import { withDefaultGetters, } from './helpers';
15
15
  function SelectRender(props, ref) {
16
16
  var defaultDropdownRef = useRef(null);
17
17
  var controlRef = useRef(null);
18
- var _a = usePropsHandler(COMPONENT_NAME, withDefaultGetters(props), controlRef), placeholder = _a.placeholder, onBlur = _a.onBlur, onFocus = _a.onFocus, items = _a.items, onChange = _a.onChange, value = _a.value, required = _a.required, disabled = _a.disabled, ariaLabel = _a.ariaLabel, id = _a.id, _b = _a.dropdownRef, dropdownRef = _b === void 0 ? defaultDropdownRef : _b, _c = _a.form, form = _c === void 0 ? defaultPropForm : _c, _d = _a.view, view = _d === void 0 ? defaultPropView : _d, _e = _a.size, size = _e === void 0 ? defaultPropSize : _e, dropdownClassName = _a.dropdownClassName, name = _a.name, _f = _a.groups, groups = _f === void 0 ? [] : _f, getItemLabel = _a.getItemLabel, _g = _a.labelForEmptyItems, labelForEmptyItems = _g === void 0 ? defaultLabelForEmptyItems : _g, getItemKey = _a.getItemKey, getItemGroupKey = _a.getItemGroupKey, getItemDisabled = _a.getItemDisabled, getGroupKey = _a.getGroupKey, getGroupLabel = _a.getGroupLabel, renderItem = _a.renderItem, renderValueProp = _a.renderValue, inputRefProp = _a.inputRef, style = _a.style, restProps = __rest(_a, ["placeholder", "onBlur", "onFocus", "items", "onChange", "value", "required", "disabled", "ariaLabel", "id", "dropdownRef", "form", "view", "size", "dropdownClassName", "name", "groups", "getItemLabel", "labelForEmptyItems", "getItemKey", "getItemGroupKey", "getItemDisabled", "getGroupKey", "getGroupLabel", "renderItem", "renderValue", "inputRef", "style"]);
18
+ var _a = usePropsHandler(COMPONENT_NAME, withDefaultGetters(props), controlRef), placeholder = _a.placeholder, onBlur = _a.onBlur, onFocus = _a.onFocus, items = _a.items, onChange = _a.onChange, value = _a.value, required = _a.required, disabled = _a.disabled, ariaLabel = _a.ariaLabel, id = _a.id, _b = _a.dropdownRef, dropdownRef = _b === void 0 ? defaultDropdownRef : _b, _c = _a.form, form = _c === void 0 ? defaultPropForm : _c, _d = _a.view, view = _d === void 0 ? defaultPropView : _d, _e = _a.size, size = _e === void 0 ? defaultPropSize : _e, dropdownClassName = _a.dropdownClassName, name = _a.name, _f = _a.groups, groups = _f === void 0 ? [] : _f, getItemLabel = _a.getItemLabel, _g = _a.labelForEmptyItems, labelForEmptyItems = _g === void 0 ? defaultLabelForEmptyItems : _g, getItemKey = _a.getItemKey, getItemGroupKey = _a.getItemGroupKey, getItemDisabled = _a.getItemDisabled, getGroupKey = _a.getGroupKey, getGroupLabel = _a.getGroupLabel, renderItem = _a.renderItem, isLoading = _a.isLoading, renderValueProp = _a.renderValue, inputRefProp = _a.inputRef, style = _a.style, restProps = __rest(_a, ["placeholder", "onBlur", "onFocus", "items", "onChange", "value", "required", "disabled", "ariaLabel", "id", "dropdownRef", "form", "view", "size", "dropdownClassName", "name", "groups", "getItemLabel", "labelForEmptyItems", "getItemKey", "getItemGroupKey", "getItemDisabled", "getGroupKey", "getGroupLabel", "renderItem", "isLoading", "renderValue", "inputRef", "style"]);
19
19
  var _h = useSelect({
20
20
  items: items,
21
21
  groups: groups,
@@ -53,7 +53,7 @@ function SelectRender(props, ref) {
53
53
  React.createElement("span", { className: cnSelect('Indicators') },
54
54
  React.createElement("button", { type: "button", className: cnSelect('IndicatorsDropdown'), tabIndex: -1, onClick: handleToggleDropdown },
55
55
  React.createElement(IconSelect, { size: "xs", className: cnSelect('DropdownIndicatorIcon') })))),
56
- React.createElement(SelectDropdown, { isOpen: isOpen, size: size, controlRef: controlRef, getOptionProps: getOptionProps, dropdownRef: dropdownRef, form: dropdownForm, className: dropdownClassName, renderItem: renderItem || renderItemDefault, getGroupLabel: getGroupLabel, visibleItems: visibleItems, notFound: notFound, labelForEmptyItems: labelForEmptyItems, hasItems: hasItems, style: typeof (style === null || style === void 0 ? void 0 : style.zIndex) === 'number' ? { zIndex: style.zIndex + 1 } : undefined })));
56
+ React.createElement(SelectDropdown, { isOpen: isOpen, size: size, controlRef: controlRef, getOptionProps: getOptionProps, dropdownRef: dropdownRef, form: dropdownForm, className: dropdownClassName, renderItem: renderItem || renderItemDefault, getGroupLabel: getGroupLabel, visibleItems: visibleItems, notFound: notFound, isLoading: isLoading, labelForEmptyItems: labelForEmptyItems, hasItems: hasItems, style: typeof (style === null || style === void 0 ? void 0 : style.zIndex) === 'number' ? { zIndex: style.zIndex + 1 } : undefined })));
57
57
  }
58
58
  export var Select = forwardRef(SelectRender);
59
59
  export * from './helpers';
@@ -42,6 +42,7 @@ export declare type SelectProps<ITEM = DefaultItem, GROUP = DefaultGroup> = Prop
42
42
  dropdownRef?: React.RefObject<HTMLDivElement>;
43
43
  required?: boolean;
44
44
  name?: string;
45
+ isLoading?: boolean;
45
46
  labelForEmptyItems?: string;
46
47
  value?: PropValue<ITEM>;
47
48
  renderItem?: PropRenderItem<ITEM>;
@@ -102,6 +103,7 @@ export declare function withDefaultGetters<ITEM, GROUP>(props: SelectProps<ITEM,
102
103
  dropdownRef?: React.RefObject<HTMLDivElement> | undefined;
103
104
  required?: boolean | undefined;
104
105
  name?: string | undefined;
106
+ isLoading?: boolean | undefined;
105
107
  labelForEmptyItems?: string | undefined;
106
108
  value?: PropValue<ITEM>;
107
109
  renderItem?: PropRenderItem<ITEM> | undefined;
@@ -1,21 +1,15 @@
1
1
  .SelectDropdown {
2
- --transition-spase: var(--space-2xs);
3
- z-index: 9999;
4
2
  overflow: hidden;
5
3
  -webkit-box-sizing: border-box;
6
4
  box-sizing: border-box;
7
- width: 100%;
8
5
  min-width: 220px;
9
6
  margin: -1px 0 -1px;
10
7
  background: var(--color-bg-default);
11
8
  border: var(--control-border-width) solid var(--color-control-bg-border-default);
12
9
  outline: none;
13
- opacity: 0;
14
10
  -webkit-box-shadow: var(--shadow-layer);
15
11
  box-shadow: var(--shadow-layer);
16
12
  font-size: var(--font-size);
17
- -webkit-transform: translateY(var(--transition-spase));
18
- transform: translateY(var(--transition-spase));
19
13
  }
20
14
 
21
15
  .SelectDropdown_size_xs {
@@ -58,52 +52,6 @@
58
52
  border-radius: calc(var(--input-height) * 0.5);
59
53
  }
60
54
 
61
- .SelectDropdown_animate_appear,
62
- .SelectDropdown_animate_appearActive,
63
- .SelectDropdown_animate_appearDone,
64
- .SelectDropdown_animate_enter,
65
- .SelectDropdown_animate_enterActive,
66
- .SelectDropdown_animate_enterDone,
67
- .SelectDropdown_animate_exit,
68
- .SelectDropdown_animate_exitActive,
69
- .SelectDropdown_animate_exitDone {
70
- -webkit-transition: 0.2s ease;
71
- transition: 0.2s ease;
72
- -webkit-transition-property: opacity, -webkit-transform;
73
- transition-property: opacity, -webkit-transform;
74
- transition-property: opacity, transform;
75
- transition-property: opacity, transform, -webkit-transform;
76
- }
77
-
78
- .SelectDropdown_animate_appear,
79
- .SelectDropdown_animate_enter {
80
- opacity: 0;
81
- -webkit-transform: translateY(var(--transition-spase));
82
- transform: translateY(var(--transition-spase));
83
- }
84
-
85
- .SelectDropdown_animate_enterActive,
86
- .SelectDropdown_animate_appearActive,
87
- .SelectDropdown_animate_appearDone,
88
- .SelectDropdown_animate_enterDone {
89
- opacity: 1;
90
- -webkit-transform: translateY(0);
91
- transform: translateY(0);
92
- }
93
-
94
- .SelectDropdown_animate_exit {
95
- opacity: 1;
96
- -webkit-transform: translateY(0);
97
- transform: translateY(0);
98
- }
99
-
100
- .SelectDropdown_animate_exitActive,
101
- .SelectDropdown_animate_exitDone {
102
- opacity: 0;
103
- -webkit-transform: translateY(var(--transition-spase));
104
- transform: translateY(var(--transition-spase));
105
- }
106
-
107
55
  .SelectDropdown-LabelForNotFound,
108
56
  .SelectDropdown-LabelForEmptyItems {
109
57
  padding: 0 var(--space-xs);
@@ -13,6 +13,7 @@ declare type Props<ITEM, GROUP> = PropsWithJsxAttributes<{
13
13
  getOptionProps(props: OptionProps<ITEM>): GetOptionPropsResult;
14
14
  form: SelectDropdownPropForm;
15
15
  isOpen: boolean;
16
+ isLoading?: boolean;
16
17
  renderItem: (props: RenderItemProps<ITEM>) => JSX.Element | null;
17
18
  visibleItems: (OptionForCreate | {
18
19
  items: ITEM[];
@@ -1,37 +1,46 @@
1
- import { __assign, __rest } from "tslib";
1
+ import { __assign, __read, __rest } from "tslib";
2
2
  import './SelectDropdown.css';
3
- import React, { Fragment, useRef } from 'react';
4
- import { CSSTransition } from 'react-transition-group';
3
+ import React, { Fragment, useMemo, useRef, useState } from 'react';
4
+ import { Transition } from 'react-transition-group';
5
5
  import { isOptionForCreate, } from '../../../hooks/useSelect/useSelect';
6
+ import { animateTimeout, cnMixPopoverAnimate, } from '../../../mixs/MixPopoverAnimate/MixPopoverAnimate';
6
7
  import { cn } from '../../../utils/bem';
7
- import { cnForCssTransition } from '../../../utils/cnForCssTransition';
8
8
  import { fabricIndex } from '../../../utils/fabricIndex';
9
9
  import { Popover } from '../../Popover/Popover';
10
10
  import { Text } from '../../Text/Text';
11
11
  import { SelectCreateButton } from '../SelectCreateButton/SelectCreateButton';
12
12
  import { SelectGroupLabel } from '../SelectGroupLabel/SelectGroupLabel';
13
+ import { SelectLoader } from '../SelectLoader/SelectLoader';
13
14
  export var selectDropdownform = ['default', 'brick', 'round'];
14
15
  export var defaultSelectDropdownPropForm = selectDropdownform[0];
15
16
  var cnSelectDropdown = cn('SelectDropdown');
16
- var cnSelectDropdownCssTransition = cnForCssTransition(cnSelectDropdown);
17
17
  export var SelectDropdown = function (props) {
18
- var controlRef = props.controlRef, size = props.size, getOptionProps = props.getOptionProps, dropdownRef = props.dropdownRef, labelForCreate = props.labelForCreate, className = props.className, labelForNotFound = props.labelForNotFound, labelForEmptyItems = props.labelForEmptyItems, _a = props.hasItems, hasItems = _a === void 0 ? true : _a, form = props.form, isOpen = props.isOpen, renderItem = props.renderItem, visibleItems = props.visibleItems, getGroupLabel = props.getGroupLabel, notFound = props.notFound, otherProps = __rest(props, ["controlRef", "size", "getOptionProps", "dropdownRef", "labelForCreate", "className", "labelForNotFound", "labelForEmptyItems", "hasItems", "form", "isOpen", "renderItem", "visibleItems", "getGroupLabel", "notFound"]);
18
+ var controlRef = props.controlRef, size = props.size, getOptionProps = props.getOptionProps, dropdownRef = props.dropdownRef, labelForCreate = props.labelForCreate, className = props.className, labelForNotFound = props.labelForNotFound, labelForEmptyItems = props.labelForEmptyItems, _a = props.hasItems, hasItems = _a === void 0 ? true : _a, form = props.form, isOpen = props.isOpen, renderItem = props.renderItem, visibleItems = props.visibleItems, isLoading = props.isLoading, getGroupLabel = props.getGroupLabel, notFound = props.notFound, otherProps = __rest(props, ["controlRef", "size", "getOptionProps", "dropdownRef", "labelForCreate", "className", "labelForNotFound", "labelForEmptyItems", "hasItems", "form", "isOpen", "renderItem", "visibleItems", "isLoading", "getGroupLabel", "notFound"]);
19
19
  var getIndex = fabricIndex(-1);
20
+ var _b = __read(useState('downStartLeft'), 2), direction = _b[0], setDirection = _b[1];
20
21
  var indent = form === 'round' ? 'increased' : 'normal';
21
22
  var popoverRef = useRef(null);
22
- return (React.createElement(CSSTransition, { "in": isOpen, unmountOnExit: true, appear: true, nodeRef: popoverRef, classNames: cnSelectDropdownCssTransition, timeout: 200 },
23
- React.createElement(Popover, __assign({}, otherProps, { anchorRef: controlRef, direction: "downStartLeft", possibleDirections: ['downStartLeft', 'upStartLeft', 'downStartRight', 'upStartRight'], offset: 1, ref: popoverRef, role: "listbox", className: cnSelectDropdown({ form: form, size: size }, [className]), equalAnchorWidth: true }),
24
- React.createElement("div", { className: cnSelectDropdown('List', { size: size, form: form }), ref: dropdownRef },
25
- visibleItems.map(function (group) {
26
- if (isOptionForCreate(group)) {
27
- return (React.createElement(SelectCreateButton, __assign({ size: size, labelForCreate: labelForCreate, inputValue: group.label, indent: indent }, getOptionProps({ index: getIndex(), item: group }))));
28
- }
29
- return (React.createElement(Fragment, { key: group.key },
30
- group.group && getGroupLabel && (React.createElement(SelectGroupLabel, { label: getGroupLabel(group.group), size: size, indent: indent })),
31
- group.items.map(function (item, i) {
32
- return (React.createElement(Fragment, { key: group.key + "-" + i }, renderItem(__assign({ item: item }, getOptionProps({ index: getIndex(), item: item })))));
33
- })));
34
- }),
35
- notFound && labelForNotFound && (React.createElement(Text, { className: cnSelectDropdown('LabelForNotFound') }, labelForNotFound)),
36
- !hasItems && labelForEmptyItems && (React.createElement(Text, { className: cnSelectDropdown('LabelForEmptyItems') }, labelForEmptyItems))))));
23
+ var isListShowed = useMemo(function () {
24
+ return (visibleItems.filter(function (group) {
25
+ return isOptionForCreate(group) || (Array.isArray(group.items) && group.items.length > 0);
26
+ }).length > 0);
27
+ }, [visibleItems]);
28
+ return (React.createElement(Transition, { "in": isOpen, unmountOnExit: true, nodeRef: popoverRef, timeout: animateTimeout }, function (animate) { return (React.createElement(Popover, __assign({}, otherProps, { anchorRef: controlRef, direction: "downStartLeft", possibleDirections: ['downStartLeft', 'upStartLeft', 'downStartRight', 'upStartRight'], offset: "2xs", ref: popoverRef, role: "listbox", onSetDirection: setDirection, className: cnSelectDropdown({ form: form, size: size }, [
29
+ className,
30
+ cnMixPopoverAnimate({ direction: direction, animate: animate }),
31
+ ]), equalAnchorWidth: true }),
32
+ React.createElement("div", { className: cnSelectDropdown('List', { size: size, form: form }), ref: dropdownRef },
33
+ isLoading && React.createElement(SelectLoader, { mode: isListShowed ? 'blur' : 'empty' }),
34
+ visibleItems.map(function (group) {
35
+ if (isOptionForCreate(group)) {
36
+ return (React.createElement(SelectCreateButton, __assign({ size: size, labelForCreate: labelForCreate, inputValue: group.label, indent: indent }, getOptionProps({ index: getIndex(), item: group }))));
37
+ }
38
+ return (React.createElement(Fragment, { key: group.key },
39
+ group.group && getGroupLabel && (React.createElement(SelectGroupLabel, { label: getGroupLabel(group.group), size: size, indent: indent })),
40
+ group.items.map(function (item, i) {
41
+ return (React.createElement(Fragment, { key: group.key + "-" + i }, renderItem(__assign({ item: item }, getOptionProps({ index: getIndex(), item: item })))));
42
+ })));
43
+ }),
44
+ !isLoading && notFound && labelForNotFound && (React.createElement(Text, { className: cnSelectDropdown('LabelForNotFound') }, labelForNotFound)),
45
+ !isLoading && !hasItems && labelForEmptyItems && (React.createElement(Text, { className: cnSelectDropdown('LabelForEmptyItems') }, labelForEmptyItems))))); }));
37
46
  };