@salutejs/plasma-new-hope 0.174.0-canary.1497.11463811587.0 → 0.174.0-canary.1504.11477432639.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (641) hide show
  1. package/cjs/components/Accordion/ui/AccordionItem/AccordionItem.styles.js +0 -1
  2. package/cjs/components/Accordion/ui/AccordionItem/AccordionItem.styles.js.map +1 -1
  3. package/cjs/components/Attach/Attach.js +3 -4
  4. package/cjs/components/Attach/Attach.js.map +1 -1
  5. package/cjs/components/Attach/components/AttachButton/AttachButton.js +0 -1
  6. package/cjs/components/Attach/components/AttachButton/AttachButton.js.map +1 -1
  7. package/cjs/components/Attach/ui/Button/Button.styles.js +0 -1
  8. package/cjs/components/Attach/ui/Button/Button.styles.js.map +1 -1
  9. package/cjs/components/Attach/ui/Cell/Cell.styles.js +0 -2
  10. package/cjs/components/Attach/ui/Cell/Cell.styles.js.map +1 -1
  11. package/cjs/components/Attach/ui/IconButton/IconButton.styles.js +0 -1
  12. package/cjs/components/Attach/ui/IconButton/IconButton.styles.js.map +1 -1
  13. package/cjs/components/Attach/utils/getFileicon.js +3 -4
  14. package/cjs/components/Attach/utils/getFileicon.js.map +1 -1
  15. package/cjs/components/Attach/utils/index.js +0 -3
  16. package/cjs/components/Attach/utils/index.js.map +1 -1
  17. package/cjs/components/Autocomplete/Autocomplete.js +5 -6
  18. package/cjs/components/Autocomplete/Autocomplete.js.map +1 -1
  19. package/cjs/components/Autocomplete/Autocomplete.styles.js +2 -3
  20. package/cjs/components/Autocomplete/Autocomplete.styles.js.map +1 -1
  21. package/cjs/components/Autocomplete/ui/TextField/TextField.styles.js +1 -2
  22. package/cjs/components/Autocomplete/ui/TextField/TextField.styles.js.map +1 -1
  23. package/cjs/components/Avatar/Avatar.js +2 -3
  24. package/cjs/components/Avatar/Avatar.js.map +1 -1
  25. package/cjs/components/Breadcrumbs/Breadcrumbs.styles.js +2 -4
  26. package/cjs/components/Breadcrumbs/Breadcrumbs.styles.js.map +1 -1
  27. package/cjs/components/Button/Button.styles.js +0 -3
  28. package/cjs/components/Button/Button.styles.js.map +1 -1
  29. package/cjs/components/Calendar/CalendarBase/CalendarBase.js +5 -5
  30. package/cjs/components/Calendar/CalendarDouble/CalendarDouble.js +8 -8
  31. package/cjs/components/Calendar/hooks/useDays.js +2 -2
  32. package/cjs/components/Calendar/hooks/useKeyNavigation.js +1 -1
  33. package/cjs/components/Calendar/hooks/useMonths.js +2 -2
  34. package/cjs/components/Calendar/hooks/useQuarters.js +2 -2
  35. package/cjs/components/Calendar/hooks/useYears.js +2 -2
  36. package/cjs/components/Calendar/ui/CalendarDays/CalendarDays.js +4 -4
  37. package/cjs/components/Calendar/ui/CalendarHeader/CalendarHeader.js +5 -6
  38. package/cjs/components/Calendar/ui/CalendarHeader/CalendarHeader.js.map +1 -1
  39. package/cjs/components/Calendar/ui/CalendarHeader/CalendarHeader.styles.js +0 -1
  40. package/cjs/components/Calendar/ui/CalendarHeader/CalendarHeader.styles.js.map +1 -1
  41. package/cjs/components/Calendar/ui/CalendarMonths/CalendarMonths.js +4 -4
  42. package/cjs/components/Calendar/ui/CalendarQuarters/CalendarQuarters.js +4 -4
  43. package/cjs/components/Calendar/ui/CalendarYears/CalendarYears.js +4 -4
  44. package/cjs/components/Combobox/ComboboxNew/Combobox.js +11 -12
  45. package/cjs/components/Combobox/ComboboxNew/Combobox.js.map +1 -1
  46. package/cjs/components/Combobox/ComboboxNew/Combobox.styles.js +2 -4
  47. package/cjs/components/Combobox/ComboboxNew/Combobox.styles.js.map +1 -1
  48. package/cjs/components/Combobox/ComboboxNew/hooks/getPathMaps.js +0 -2
  49. package/cjs/components/Combobox/ComboboxNew/hooks/getPathMaps.js.map +1 -1
  50. package/cjs/components/Combobox/ComboboxNew/ui/Inner/Inner.js +1 -2
  51. package/cjs/components/Combobox/ComboboxNew/ui/Inner/Inner.js.map +1 -1
  52. package/cjs/components/Combobox/ComboboxNew/ui/Inner/ui/Item/Item.js +5 -6
  53. package/cjs/components/Combobox/ComboboxNew/ui/Inner/ui/Item/Item.js.map +1 -1
  54. package/cjs/components/Combobox/ComboboxNew/ui/Inner/ui/Item/Item.styles.js +1 -3
  55. package/cjs/components/Combobox/ComboboxNew/ui/Inner/ui/Item/Item.styles.js.map +1 -1
  56. package/cjs/components/Combobox/ComboboxNew/ui/Target/Target.styles.js +1 -2
  57. package/cjs/components/Combobox/ComboboxNew/ui/Target/Target.styles.js.map +1 -1
  58. package/cjs/components/Combobox/ComboboxOld/Combobox.css +14 -28
  59. package/cjs/components/Combobox/ComboboxOld/Combobox.js +4 -11
  60. package/cjs/components/Combobox/ComboboxOld/Combobox.js.map +1 -1
  61. package/cjs/components/Combobox/ComboboxOld/Combobox.styles.js +0 -1
  62. package/cjs/components/Combobox/ComboboxOld/Combobox.styles.js.map +1 -1
  63. package/cjs/components/Combobox/ComboboxOld/hooks/useFocusController.js +0 -1
  64. package/cjs/components/Combobox/ComboboxOld/hooks/useFocusController.js.map +1 -1
  65. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxChip/ComboboxChip.styles.js +1 -2
  66. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxChip/ComboboxChip.styles.js.map +1 -1
  67. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxDivider/ComboboxDivider.css +18 -32
  68. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxDivider/ComboboxDivider.js +1 -11
  69. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxDivider/ComboboxDivider.js.map +1 -1
  70. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxFooter/ComboboxFooter.css +18 -32
  71. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxFooter/ComboboxFooter.js +1 -11
  72. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxFooter/ComboboxFooter.js.map +1 -1
  73. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxGroup/ComboboxGroup.css +18 -32
  74. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxGroup/ComboboxGroup.js +1 -11
  75. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxGroup/ComboboxGroup.js.map +1 -1
  76. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxHeader/ComboboxHeader.css +18 -32
  77. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxHeader/ComboboxHeader.js +1 -11
  78. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxHeader/ComboboxHeader.js.map +1 -1
  79. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxItem/ComboboxItem.styles.js +0 -2
  80. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxItem/ComboboxItem.styles.js.map +1 -1
  81. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxTarget/ComboboxTarget.js +1 -1
  82. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxTarget/ComboboxTarget.styles.js +1 -2
  83. package/cjs/components/Combobox/ComboboxOld/ui/ComboboxTarget/ComboboxTarget.styles.js.map +1 -1
  84. package/cjs/components/DatePicker/DatePickerBase.styles.js +1 -7
  85. package/cjs/components/DatePicker/DatePickerBase.styles.js.map +1 -1
  86. package/cjs/components/DatePicker/RangeDate/RangeDate.js +1 -1
  87. package/cjs/components/DatePicker/RangeDate/RangeDate.styles.js +0 -1
  88. package/cjs/components/DatePicker/RangeDate/RangeDate.styles.js.map +1 -1
  89. package/cjs/components/DatePicker/RangeDate/RangeDatePopover/RangeDatePopover.js +1 -2
  90. package/cjs/components/DatePicker/RangeDate/RangeDatePopover/RangeDatePopover.js.map +1 -1
  91. package/cjs/components/DatePicker/RangeDate/RangeDatePopover/RangeDatePopover.styles.js +2 -5
  92. package/cjs/components/DatePicker/RangeDate/RangeDatePopover/RangeDatePopover.styles.js.map +1 -1
  93. package/cjs/components/DatePicker/SingleDate/SingleDate.styles.js +0 -1
  94. package/cjs/components/DatePicker/SingleDate/SingleDate.styles.js.map +1 -1
  95. package/cjs/components/Drawer/Drawer.js +5 -10
  96. package/cjs/components/Drawer/Drawer.js.map +1 -1
  97. package/cjs/components/Drawer/Drawer.styles.js +0 -4
  98. package/cjs/components/Drawer/Drawer.styles.js.map +1 -1
  99. package/cjs/components/Drawer/hooks/useDrawer.js +0 -4
  100. package/cjs/components/Drawer/hooks/useDrawer.js.map +1 -1
  101. package/cjs/components/Drawer/ui/DrawerContent/DrawerContent.js +0 -7
  102. package/cjs/components/Drawer/ui/DrawerContent/DrawerContent.js.map +1 -1
  103. package/cjs/components/Drawer/ui/DrawerFooter/DrawerFooter.js +0 -7
  104. package/cjs/components/Drawer/ui/DrawerFooter/DrawerFooter.js.map +1 -1
  105. package/cjs/components/Drawer/ui/DrawerHeader/DrawerHeader.js +0 -3
  106. package/cjs/components/Drawer/ui/DrawerHeader/DrawerHeader.js.map +1 -1
  107. package/cjs/components/Dropdown/Dropdown.css +16 -30
  108. package/cjs/components/Dropdown/Dropdown.js +38 -67
  109. package/cjs/components/Dropdown/Dropdown.js.map +1 -1
  110. package/cjs/components/Dropdown/Dropdown.styles.js +26 -14
  111. package/cjs/components/Dropdown/Dropdown.styles.js.map +1 -1
  112. package/cjs/components/Dropdown/Dropdown.styles_1tihqkp.css +3 -0
  113. package/cjs/components/Dropdown/Dropdown.tokens.js +1 -24
  114. package/cjs/components/Dropdown/Dropdown.tokens.js.map +1 -1
  115. package/cjs/components/Dropdown/ui/DropdownInner/DropdownInner.js +52 -25
  116. package/cjs/components/Dropdown/ui/DropdownInner/DropdownInner.js.map +1 -1
  117. package/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.css +6 -46
  118. package/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.js +19 -31
  119. package/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.js.map +1 -1
  120. package/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.styles.js +31 -27
  121. package/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.styles.js.map +1 -1
  122. package/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.styles_blclup.css +6 -0
  123. package/cjs/components/Dropdown/ui/DropdownItemOld/DropdownItem.styles.js +1 -3
  124. package/cjs/components/Dropdown/ui/DropdownItemOld/DropdownItem.styles.js.map +1 -1
  125. package/cjs/components/Dropdown/ui/DropdownItemOld/{DropdownItem.styles_1lyg81y.css → DropdownItem.styles_12e50g5.css} +1 -1
  126. package/cjs/components/Dropdown/ui/DropdownItemOld/DropdownItemOld.css +4 -4
  127. package/cjs/components/Dropdown/ui/DropdownOld/Dropdown.styles.js +0 -1
  128. package/cjs/components/Dropdown/ui/DropdownOld/Dropdown.styles.js.map +1 -1
  129. package/cjs/components/Dropdown/utils/index.js.map +1 -1
  130. package/cjs/components/Editable/Editable.js +3 -4
  131. package/cjs/components/Editable/Editable.js.map +1 -1
  132. package/cjs/components/Editable/utils/clearSelection.js +0 -2
  133. package/cjs/components/Editable/utils/clearSelection.js.map +1 -1
  134. package/cjs/components/Editable/utils/selectText.js +0 -2
  135. package/cjs/components/Editable/utils/selectText.js.map +1 -1
  136. package/cjs/components/EmptyState/EmptyState.styles.js +1 -2
  137. package/cjs/components/EmptyState/EmptyState.styles.js.map +1 -1
  138. package/cjs/components/IconButton/IconButton.js +1 -1
  139. package/cjs/components/IconButton/IconButton.styles.js +0 -8
  140. package/cjs/components/IconButton/IconButton.styles.js.map +1 -1
  141. package/cjs/components/Modal/Modal.js +6 -8
  142. package/cjs/components/Modal/Modal.js.map +1 -1
  143. package/cjs/components/Modal/hooks/useModal.js +0 -4
  144. package/cjs/components/Modal/hooks/useModal.js.map +1 -1
  145. package/cjs/components/Notification/Notification.styles.js +2 -3
  146. package/cjs/components/Notification/Notification.styles.js.map +1 -1
  147. package/cjs/components/Notification/NotificationsPortal.js +3 -4
  148. package/cjs/components/Notification/NotificationsPortal.js.map +1 -1
  149. package/cjs/components/Pagination/Pagination.css +13 -13
  150. package/cjs/components/Pagination/Pagination.styles.js +1 -2
  151. package/cjs/components/Pagination/Pagination.styles.js.map +1 -1
  152. package/cjs/components/Pagination/ui/PaginationSelectPerPage/PaginationSelectPerPage.css +13 -13
  153. package/cjs/components/Pagination/ui/PaginationSelectPerPage/PaginationSelectPerPage.styles.js +1 -2
  154. package/cjs/components/Pagination/ui/PaginationSelectPerPage/PaginationSelectPerPage.styles.js.map +1 -1
  155. package/cjs/components/Panel/ui/PanelHeader/PanelHeader.js +1 -2
  156. package/cjs/components/Panel/ui/PanelHeader/PanelHeader.js.map +1 -1
  157. package/cjs/components/Panel/ui/PanelHeader/PanelHeader.styles.js +1 -2
  158. package/cjs/components/Panel/ui/PanelHeader/PanelHeader.styles.js.map +1 -1
  159. package/cjs/components/Popover/Popover.js +1 -1
  160. package/cjs/components/Popup/Popup.js +2 -2
  161. package/cjs/components/Popup/PopupContext.js +1 -1
  162. package/cjs/components/Range/Range.styles.js +0 -1
  163. package/cjs/components/Range/Range.styles.js.map +1 -1
  164. package/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.js +4 -5
  165. package/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.js.map +1 -1
  166. package/cjs/components/Select/Select.css +13 -13
  167. package/cjs/components/Select/Select.js +11 -12
  168. package/cjs/components/Select/Select.js.map +1 -1
  169. package/cjs/components/Select/Select.styles.js +3 -6
  170. package/cjs/components/Select/Select.styles.js.map +1 -1
  171. package/cjs/components/Select/Select.styles_ei4ic3.css +5 -0
  172. package/cjs/components/Select/Select.tokens.js +17 -1
  173. package/cjs/components/Select/Select.tokens.js.map +1 -1
  174. package/cjs/components/Select/hooks/usePathMaps.js +0 -2
  175. package/cjs/components/Select/hooks/usePathMaps.js.map +1 -1
  176. package/cjs/components/Select/ui/Inner/Inner.css +13 -13
  177. package/cjs/components/Select/ui/Inner/Inner.js +1 -2
  178. package/cjs/components/Select/ui/Inner/Inner.js.map +1 -1
  179. package/cjs/components/Select/ui/Inner/ui/Item/Item.css +13 -13
  180. package/cjs/components/Select/ui/Inner/ui/Item/Item.js +4 -5
  181. package/cjs/components/Select/ui/Inner/ui/Item/Item.js.map +1 -1
  182. package/cjs/components/Select/ui/Inner/ui/Item/Item.styles.js +11 -12
  183. package/cjs/components/Select/ui/Inner/ui/Item/Item.styles.js.map +1 -1
  184. package/{es/components/Select/ui/Inner/ui/Item/Item.styles_baxa65.css → cjs/components/Select/ui/Inner/ui/Item/Item.styles_1gaxu1y.css} +2 -2
  185. package/cjs/components/Select/ui/Target/ui/Button/Button.js +1 -1
  186. package/cjs/components/Select/ui/Target/ui/Button/Button.styles.js +1 -3
  187. package/cjs/components/Select/ui/Target/ui/Button/Button.styles.js.map +1 -1
  188. package/cjs/components/Select/ui/Target/ui/Textfield/Textfield.js +2 -2
  189. package/cjs/components/Select/ui/Target/ui/Textfield/Textfield.styles.js +1 -4
  190. package/cjs/components/Select/ui/Target/ui/Textfield/Textfield.styles.js.map +1 -1
  191. package/cjs/components/Select/ui/Target/ui/Textfield/ui/Chip/Chip.styles.js +1 -2
  192. package/cjs/components/Select/ui/Target/ui/Textfield/ui/Chip/Chip.styles.js.map +1 -1
  193. package/cjs/components/Select/utils/getButtonLabel.js +0 -2
  194. package/cjs/components/Select/utils/getButtonLabel.js.map +1 -1
  195. package/cjs/components/Select/utils/getCorrectHeight.js.map +1 -1
  196. package/cjs/components/Sheet/Sheet.js +3 -3
  197. package/cjs/components/Skeleton/LineSkeleton/LineSkeleton.js +2 -4
  198. package/cjs/components/Skeleton/LineSkeleton/LineSkeleton.js.map +1 -1
  199. package/cjs/components/Skeleton/RectSkeleton/RectSkeleton.js +2 -4
  200. package/cjs/components/Skeleton/RectSkeleton/RectSkeleton.js.map +1 -1
  201. package/cjs/components/Slider/Slider.js +0 -8
  202. package/cjs/components/Slider/Slider.js.map +1 -1
  203. package/cjs/components/Slider/components/Double/Double.js +1 -2
  204. package/cjs/components/Slider/components/Double/Double.js.map +1 -1
  205. package/cjs/components/Slider/components/Double/Double.styles.js +0 -1
  206. package/cjs/components/Slider/components/Double/Double.styles.js.map +1 -1
  207. package/cjs/components/Slider/components/DoubleUncontrolled/DoubleUncontrolled.js +0 -3
  208. package/cjs/components/Slider/components/DoubleUncontrolled/DoubleUncontrolled.js.map +1 -1
  209. package/cjs/components/Slider/components/Single/Single.js +1 -2
  210. package/cjs/components/Slider/components/Single/Single.js.map +1 -1
  211. package/cjs/components/Slider/components/SliderBase/SliderBase.js +1 -1
  212. package/cjs/components/Steps/Steps.js +1 -1
  213. package/cjs/components/Steps/ui/StepItem/StepItem.styles.js +0 -1
  214. package/cjs/components/Steps/ui/StepItem/StepItem.styles.js.map +1 -1
  215. package/cjs/components/Tabs/ui/horizontal/HorizontalTabs/HorizontalTabs.js +2 -3
  216. package/cjs/components/Tabs/ui/horizontal/HorizontalTabs/HorizontalTabs.js.map +1 -1
  217. package/cjs/components/Tabs/ui/vertical/VerticalTabs/VerticalTabs.js +2 -3
  218. package/cjs/components/Tabs/ui/vertical/VerticalTabs/VerticalTabs.js.map +1 -1
  219. package/cjs/components/TextArea/TextArea.js +2 -2
  220. package/cjs/components/TextArea/TextArea.styles.js +2 -3
  221. package/cjs/components/TextArea/TextArea.styles.js.map +1 -1
  222. package/cjs/components/TextArea/ui/Hint/Hint.js +1 -2
  223. package/cjs/components/TextArea/ui/Hint/Hint.js.map +1 -1
  224. package/cjs/components/TextField/TextField.js +3 -3
  225. package/cjs/components/TextField/TextField.styles.js +1 -2
  226. package/cjs/components/TextField/TextField.styles.js.map +1 -1
  227. package/cjs/components/TextField/ui/Hint/Hint.js +1 -2
  228. package/cjs/components/TextField/ui/Hint/Hint.js.map +1 -1
  229. package/cjs/components/TextField/ui/TextFieldChip/TextFieldChip.styles.js +1 -2
  230. package/cjs/components/TextField/ui/TextFieldChip/TextFieldChip.styles.js.map +1 -1
  231. package/cjs/components/Toast/Toast.styles.js +1 -1
  232. package/cjs/components/Toast/ToastController.js +1 -1
  233. package/cjs/components/Toast/utils.js +1 -2
  234. package/cjs/components/Toast/utils.js.map +1 -1
  235. package/cjs/components/Toolbar/ui/ToolbarDivider/ToolbarDivider.js +1 -1
  236. package/cjs/components/Tooltip/Tooltip.js +2 -3
  237. package/cjs/components/Tooltip/Tooltip.js.map +1 -1
  238. package/cjs/engines/index.js +0 -2
  239. package/cjs/engines/index.js.map +1 -1
  240. package/cjs/hooks/useIsomorphicLayoutEffect.js +0 -1
  241. package/cjs/hooks/useIsomorphicLayoutEffect.js.map +1 -1
  242. package/cjs/hooks/useOutsideClick.js +1 -1
  243. package/cjs/hooks/useOutsideClick.js.map +1 -1
  244. package/cjs/index.css +26 -24
  245. package/cjs/index.js +48 -51
  246. package/cjs/index.js.map +1 -1
  247. package/cjs/utils/index.js +0 -5
  248. package/cjs/utils/index.js.map +1 -1
  249. package/emotion/cjs/components/Dropdown/Dropdown.js +37 -58
  250. package/emotion/cjs/components/Dropdown/Dropdown.styles.js +25 -9
  251. package/emotion/cjs/components/Dropdown/Dropdown.tokens.js +2 -36
  252. package/emotion/cjs/components/Dropdown/ui/DropdownInner/DropdownInner.js +51 -17
  253. package/emotion/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.js +18 -29
  254. package/emotion/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.styles.js +41 -21
  255. package/emotion/cjs/components/Dropdown/utils/index.js +1 -23
  256. package/emotion/cjs/components/Select/Select.styles.js +5 -5
  257. package/emotion/cjs/components/Select/Select.tokens.js +17 -1
  258. package/emotion/cjs/components/Select/ui/Inner/ui/Item/Item.styles.js +10 -10
  259. package/emotion/cjs/examples/plasma_b2c/components/Dropdown/Dropdown.config.js +5 -5
  260. package/emotion/cjs/examples/plasma_b2c/components/Dropdown/Dropdown.stories.tsx +5 -6
  261. package/emotion/cjs/examples/plasma_web/components/Dropdown/Dropdown.config.js +5 -5
  262. package/emotion/cjs/examples/plasma_web/components/Dropdown/Dropdown.stories.tsx +5 -6
  263. package/emotion/cjs/hooks/useOutsideClick.js +1 -1
  264. package/emotion/es/components/Dropdown/Dropdown.js +40 -60
  265. package/emotion/es/components/Dropdown/Dropdown.styles.js +25 -9
  266. package/emotion/es/components/Dropdown/Dropdown.tokens.js +1 -35
  267. package/emotion/es/components/Dropdown/ui/DropdownInner/DropdownInner.js +52 -18
  268. package/emotion/es/components/Dropdown/ui/DropdownItem/DropdownItem.js +20 -31
  269. package/emotion/es/components/Dropdown/ui/DropdownItem/DropdownItem.styles.js +42 -22
  270. package/emotion/es/components/Dropdown/utils/index.js +1 -4
  271. package/emotion/es/components/Select/Select.styles.js +5 -5
  272. package/emotion/es/components/Select/Select.tokens.js +17 -1
  273. package/emotion/es/components/Select/ui/Inner/ui/Item/Item.styles.js +10 -10
  274. package/emotion/es/examples/plasma_b2c/components/Dropdown/Dropdown.config.js +6 -6
  275. package/emotion/es/examples/plasma_b2c/components/Dropdown/Dropdown.stories.tsx +5 -6
  276. package/emotion/es/examples/plasma_web/components/Dropdown/Dropdown.config.js +6 -6
  277. package/emotion/es/examples/plasma_web/components/Dropdown/Dropdown.stories.tsx +5 -6
  278. package/emotion/es/hooks/useOutsideClick.js +1 -1
  279. package/emotion/package.json +2 -1
  280. package/es/components/Accordion/ui/AccordionItem/AccordionItem.styles.js +0 -1
  281. package/es/components/Accordion/ui/AccordionItem/AccordionItem.styles.js.map +1 -1
  282. package/es/components/Attach/Attach.js +3 -4
  283. package/es/components/Attach/Attach.js.map +1 -1
  284. package/es/components/Attach/components/AttachButton/AttachButton.js +0 -1
  285. package/es/components/Attach/components/AttachButton/AttachButton.js.map +1 -1
  286. package/es/components/Attach/ui/Button/Button.styles.js +0 -1
  287. package/es/components/Attach/ui/Button/Button.styles.js.map +1 -1
  288. package/es/components/Attach/ui/Cell/Cell.styles.js +0 -2
  289. package/es/components/Attach/ui/Cell/Cell.styles.js.map +1 -1
  290. package/es/components/Attach/ui/IconButton/IconButton.styles.js +0 -1
  291. package/es/components/Attach/ui/IconButton/IconButton.styles.js.map +1 -1
  292. package/es/components/Attach/utils/getFileicon.js +3 -4
  293. package/es/components/Attach/utils/getFileicon.js.map +1 -1
  294. package/es/components/Attach/utils/index.js +0 -3
  295. package/es/components/Attach/utils/index.js.map +1 -1
  296. package/es/components/Autocomplete/Autocomplete.js +5 -6
  297. package/es/components/Autocomplete/Autocomplete.js.map +1 -1
  298. package/es/components/Autocomplete/Autocomplete.styles.js +2 -3
  299. package/es/components/Autocomplete/Autocomplete.styles.js.map +1 -1
  300. package/es/components/Autocomplete/ui/TextField/TextField.styles.js +1 -2
  301. package/es/components/Autocomplete/ui/TextField/TextField.styles.js.map +1 -1
  302. package/es/components/Avatar/Avatar.js +2 -3
  303. package/es/components/Avatar/Avatar.js.map +1 -1
  304. package/es/components/Breadcrumbs/Breadcrumbs.styles.js +2 -4
  305. package/es/components/Breadcrumbs/Breadcrumbs.styles.js.map +1 -1
  306. package/es/components/Button/Button.styles.js +0 -3
  307. package/es/components/Button/Button.styles.js.map +1 -1
  308. package/es/components/Calendar/CalendarBase/CalendarBase.js +5 -5
  309. package/es/components/Calendar/CalendarDouble/CalendarDouble.js +8 -8
  310. package/es/components/Calendar/hooks/useDays.js +2 -2
  311. package/es/components/Calendar/hooks/useKeyNavigation.js +1 -1
  312. package/es/components/Calendar/hooks/useMonths.js +2 -2
  313. package/es/components/Calendar/hooks/useQuarters.js +2 -2
  314. package/es/components/Calendar/hooks/useYears.js +2 -2
  315. package/es/components/Calendar/ui/CalendarDays/CalendarDays.js +4 -4
  316. package/es/components/Calendar/ui/CalendarHeader/CalendarHeader.js +5 -6
  317. package/es/components/Calendar/ui/CalendarHeader/CalendarHeader.js.map +1 -1
  318. package/es/components/Calendar/ui/CalendarHeader/CalendarHeader.styles.js +0 -1
  319. package/es/components/Calendar/ui/CalendarHeader/CalendarHeader.styles.js.map +1 -1
  320. package/es/components/Calendar/ui/CalendarMonths/CalendarMonths.js +4 -4
  321. package/es/components/Calendar/ui/CalendarQuarters/CalendarQuarters.js +4 -4
  322. package/es/components/Calendar/ui/CalendarYears/CalendarYears.js +4 -4
  323. package/es/components/Combobox/ComboboxNew/Combobox.js +11 -12
  324. package/es/components/Combobox/ComboboxNew/Combobox.js.map +1 -1
  325. package/es/components/Combobox/ComboboxNew/Combobox.styles.js +2 -4
  326. package/es/components/Combobox/ComboboxNew/Combobox.styles.js.map +1 -1
  327. package/es/components/Combobox/ComboboxNew/hooks/getPathMaps.js +0 -2
  328. package/es/components/Combobox/ComboboxNew/hooks/getPathMaps.js.map +1 -1
  329. package/es/components/Combobox/ComboboxNew/ui/Inner/Inner.js +1 -2
  330. package/es/components/Combobox/ComboboxNew/ui/Inner/Inner.js.map +1 -1
  331. package/es/components/Combobox/ComboboxNew/ui/Inner/ui/Item/Item.js +5 -6
  332. package/es/components/Combobox/ComboboxNew/ui/Inner/ui/Item/Item.js.map +1 -1
  333. package/es/components/Combobox/ComboboxNew/ui/Inner/ui/Item/Item.styles.js +1 -3
  334. package/es/components/Combobox/ComboboxNew/ui/Inner/ui/Item/Item.styles.js.map +1 -1
  335. package/es/components/Combobox/ComboboxNew/ui/Target/Target.styles.js +1 -2
  336. package/es/components/Combobox/ComboboxNew/ui/Target/Target.styles.js.map +1 -1
  337. package/es/components/Combobox/ComboboxOld/Combobox.css +14 -28
  338. package/es/components/Combobox/ComboboxOld/Combobox.js +4 -11
  339. package/es/components/Combobox/ComboboxOld/Combobox.js.map +1 -1
  340. package/es/components/Combobox/ComboboxOld/Combobox.styles.js +0 -1
  341. package/es/components/Combobox/ComboboxOld/Combobox.styles.js.map +1 -1
  342. package/es/components/Combobox/ComboboxOld/hooks/useFocusController.js +0 -1
  343. package/es/components/Combobox/ComboboxOld/hooks/useFocusController.js.map +1 -1
  344. package/es/components/Combobox/ComboboxOld/ui/ComboboxChip/ComboboxChip.styles.js +1 -2
  345. package/es/components/Combobox/ComboboxOld/ui/ComboboxChip/ComboboxChip.styles.js.map +1 -1
  346. package/es/components/Combobox/ComboboxOld/ui/ComboboxDivider/ComboboxDivider.css +18 -32
  347. package/es/components/Combobox/ComboboxOld/ui/ComboboxDivider/ComboboxDivider.js +1 -11
  348. package/es/components/Combobox/ComboboxOld/ui/ComboboxDivider/ComboboxDivider.js.map +1 -1
  349. package/es/components/Combobox/ComboboxOld/ui/ComboboxFooter/ComboboxFooter.css +18 -32
  350. package/es/components/Combobox/ComboboxOld/ui/ComboboxFooter/ComboboxFooter.js +1 -11
  351. package/es/components/Combobox/ComboboxOld/ui/ComboboxFooter/ComboboxFooter.js.map +1 -1
  352. package/es/components/Combobox/ComboboxOld/ui/ComboboxGroup/ComboboxGroup.css +18 -32
  353. package/es/components/Combobox/ComboboxOld/ui/ComboboxGroup/ComboboxGroup.js +1 -11
  354. package/es/components/Combobox/ComboboxOld/ui/ComboboxGroup/ComboboxGroup.js.map +1 -1
  355. package/es/components/Combobox/ComboboxOld/ui/ComboboxHeader/ComboboxHeader.css +18 -32
  356. package/es/components/Combobox/ComboboxOld/ui/ComboboxHeader/ComboboxHeader.js +1 -11
  357. package/es/components/Combobox/ComboboxOld/ui/ComboboxHeader/ComboboxHeader.js.map +1 -1
  358. package/es/components/Combobox/ComboboxOld/ui/ComboboxItem/ComboboxItem.styles.js +0 -2
  359. package/es/components/Combobox/ComboboxOld/ui/ComboboxItem/ComboboxItem.styles.js.map +1 -1
  360. package/es/components/Combobox/ComboboxOld/ui/ComboboxTarget/ComboboxTarget.js +1 -1
  361. package/es/components/Combobox/ComboboxOld/ui/ComboboxTarget/ComboboxTarget.styles.js +1 -2
  362. package/es/components/Combobox/ComboboxOld/ui/ComboboxTarget/ComboboxTarget.styles.js.map +1 -1
  363. package/es/components/DatePicker/DatePickerBase.styles.js +1 -7
  364. package/es/components/DatePicker/DatePickerBase.styles.js.map +1 -1
  365. package/es/components/DatePicker/RangeDate/RangeDate.js +1 -1
  366. package/es/components/DatePicker/RangeDate/RangeDate.styles.js +0 -1
  367. package/es/components/DatePicker/RangeDate/RangeDate.styles.js.map +1 -1
  368. package/es/components/DatePicker/RangeDate/RangeDatePopover/RangeDatePopover.js +1 -2
  369. package/es/components/DatePicker/RangeDate/RangeDatePopover/RangeDatePopover.js.map +1 -1
  370. package/es/components/DatePicker/RangeDate/RangeDatePopover/RangeDatePopover.styles.js +2 -5
  371. package/es/components/DatePicker/RangeDate/RangeDatePopover/RangeDatePopover.styles.js.map +1 -1
  372. package/es/components/DatePicker/SingleDate/SingleDate.styles.js +0 -1
  373. package/es/components/DatePicker/SingleDate/SingleDate.styles.js.map +1 -1
  374. package/es/components/Drawer/Drawer.js +5 -10
  375. package/es/components/Drawer/Drawer.js.map +1 -1
  376. package/es/components/Drawer/Drawer.styles.js +0 -4
  377. package/es/components/Drawer/Drawer.styles.js.map +1 -1
  378. package/es/components/Drawer/hooks/useDrawer.js +0 -4
  379. package/es/components/Drawer/hooks/useDrawer.js.map +1 -1
  380. package/es/components/Drawer/ui/DrawerContent/DrawerContent.js +0 -7
  381. package/es/components/Drawer/ui/DrawerContent/DrawerContent.js.map +1 -1
  382. package/es/components/Drawer/ui/DrawerFooter/DrawerFooter.js +0 -7
  383. package/es/components/Drawer/ui/DrawerFooter/DrawerFooter.js.map +1 -1
  384. package/es/components/Drawer/ui/DrawerHeader/DrawerHeader.js +0 -3
  385. package/es/components/Drawer/ui/DrawerHeader/DrawerHeader.js.map +1 -1
  386. package/es/components/Dropdown/Dropdown.css +16 -30
  387. package/es/components/Dropdown/Dropdown.js +41 -69
  388. package/es/components/Dropdown/Dropdown.js.map +1 -1
  389. package/es/components/Dropdown/Dropdown.styles.js +26 -15
  390. package/es/components/Dropdown/Dropdown.styles.js.map +1 -1
  391. package/es/components/Dropdown/Dropdown.styles_1tihqkp.css +3 -0
  392. package/es/components/Dropdown/Dropdown.tokens.js +1 -24
  393. package/es/components/Dropdown/Dropdown.tokens.js.map +1 -1
  394. package/es/components/Dropdown/ui/DropdownInner/DropdownInner.js +52 -25
  395. package/es/components/Dropdown/ui/DropdownInner/DropdownInner.js.map +1 -1
  396. package/es/components/Dropdown/ui/DropdownItem/DropdownItem.css +6 -46
  397. package/es/components/Dropdown/ui/DropdownItem/DropdownItem.js +20 -32
  398. package/es/components/Dropdown/ui/DropdownItem/DropdownItem.js.map +1 -1
  399. package/es/components/Dropdown/ui/DropdownItem/DropdownItem.styles.js +29 -26
  400. package/es/components/Dropdown/ui/DropdownItem/DropdownItem.styles.js.map +1 -1
  401. package/es/components/Dropdown/ui/DropdownItem/DropdownItem.styles_blclup.css +6 -0
  402. package/es/components/Dropdown/ui/DropdownItemOld/DropdownItem.styles.js +1 -3
  403. package/es/components/Dropdown/ui/DropdownItemOld/DropdownItem.styles.js.map +1 -1
  404. package/es/components/Dropdown/ui/DropdownItemOld/{DropdownItem.styles_1lyg81y.css → DropdownItem.styles_12e50g5.css} +1 -1
  405. package/es/components/Dropdown/ui/DropdownItemOld/DropdownItemOld.css +4 -4
  406. package/es/components/Dropdown/ui/DropdownOld/Dropdown.styles.js +0 -1
  407. package/es/components/Dropdown/ui/DropdownOld/Dropdown.styles.js.map +1 -1
  408. package/es/components/Dropdown/utils/index.js.map +1 -1
  409. package/es/components/Editable/Editable.js +3 -4
  410. package/es/components/Editable/Editable.js.map +1 -1
  411. package/es/components/Editable/utils/clearSelection.js +0 -2
  412. package/es/components/Editable/utils/clearSelection.js.map +1 -1
  413. package/es/components/Editable/utils/selectText.js +0 -2
  414. package/es/components/Editable/utils/selectText.js.map +1 -1
  415. package/es/components/EmptyState/EmptyState.styles.js +1 -2
  416. package/es/components/EmptyState/EmptyState.styles.js.map +1 -1
  417. package/es/components/IconButton/IconButton.js +1 -1
  418. package/es/components/IconButton/IconButton.styles.js +0 -8
  419. package/es/components/IconButton/IconButton.styles.js.map +1 -1
  420. package/es/components/Modal/Modal.js +6 -8
  421. package/es/components/Modal/Modal.js.map +1 -1
  422. package/es/components/Modal/hooks/useModal.js +0 -4
  423. package/es/components/Modal/hooks/useModal.js.map +1 -1
  424. package/es/components/Notification/Notification.styles.js +2 -3
  425. package/es/components/Notification/Notification.styles.js.map +1 -1
  426. package/es/components/Notification/NotificationsPortal.js +3 -4
  427. package/es/components/Notification/NotificationsPortal.js.map +1 -1
  428. package/es/components/Pagination/Pagination.css +13 -13
  429. package/es/components/Pagination/Pagination.styles.js +1 -2
  430. package/es/components/Pagination/Pagination.styles.js.map +1 -1
  431. package/es/components/Pagination/ui/PaginationSelectPerPage/PaginationSelectPerPage.css +13 -13
  432. package/es/components/Pagination/ui/PaginationSelectPerPage/PaginationSelectPerPage.styles.js +1 -2
  433. package/es/components/Pagination/ui/PaginationSelectPerPage/PaginationSelectPerPage.styles.js.map +1 -1
  434. package/es/components/Panel/ui/PanelHeader/PanelHeader.js +1 -2
  435. package/es/components/Panel/ui/PanelHeader/PanelHeader.js.map +1 -1
  436. package/es/components/Panel/ui/PanelHeader/PanelHeader.styles.js +1 -2
  437. package/es/components/Panel/ui/PanelHeader/PanelHeader.styles.js.map +1 -1
  438. package/es/components/Popover/Popover.js +1 -1
  439. package/es/components/Popup/Popup.js +2 -2
  440. package/es/components/Popup/PopupContext.js +1 -1
  441. package/es/components/Range/Range.styles.js +0 -1
  442. package/es/components/Range/Range.styles.js.map +1 -1
  443. package/es/components/Segment/ui/SegmentGroup/SegmentGroup.js +4 -5
  444. package/es/components/Segment/ui/SegmentGroup/SegmentGroup.js.map +1 -1
  445. package/es/components/Select/Select.css +13 -13
  446. package/es/components/Select/Select.js +11 -12
  447. package/es/components/Select/Select.js.map +1 -1
  448. package/es/components/Select/Select.styles.js +3 -6
  449. package/es/components/Select/Select.styles.js.map +1 -1
  450. package/es/components/Select/Select.styles_ei4ic3.css +5 -0
  451. package/es/components/Select/Select.tokens.js +17 -1
  452. package/es/components/Select/Select.tokens.js.map +1 -1
  453. package/es/components/Select/hooks/usePathMaps.js +0 -2
  454. package/es/components/Select/hooks/usePathMaps.js.map +1 -1
  455. package/es/components/Select/ui/Inner/Inner.css +13 -13
  456. package/es/components/Select/ui/Inner/Inner.js +1 -2
  457. package/es/components/Select/ui/Inner/Inner.js.map +1 -1
  458. package/es/components/Select/ui/Inner/ui/Item/Item.css +13 -13
  459. package/es/components/Select/ui/Inner/ui/Item/Item.js +4 -5
  460. package/es/components/Select/ui/Inner/ui/Item/Item.js.map +1 -1
  461. package/es/components/Select/ui/Inner/ui/Item/Item.styles.js +11 -12
  462. package/es/components/Select/ui/Inner/ui/Item/Item.styles.js.map +1 -1
  463. package/{cjs/components/Select/ui/Inner/ui/Item/Item.styles_baxa65.css → es/components/Select/ui/Inner/ui/Item/Item.styles_1gaxu1y.css} +2 -2
  464. package/es/components/Select/ui/Target/ui/Button/Button.js +1 -1
  465. package/es/components/Select/ui/Target/ui/Button/Button.styles.js +1 -3
  466. package/es/components/Select/ui/Target/ui/Button/Button.styles.js.map +1 -1
  467. package/es/components/Select/ui/Target/ui/Textfield/Textfield.js +2 -2
  468. package/es/components/Select/ui/Target/ui/Textfield/Textfield.styles.js +1 -4
  469. package/es/components/Select/ui/Target/ui/Textfield/Textfield.styles.js.map +1 -1
  470. package/es/components/Select/ui/Target/ui/Textfield/ui/Chip/Chip.styles.js +1 -2
  471. package/es/components/Select/ui/Target/ui/Textfield/ui/Chip/Chip.styles.js.map +1 -1
  472. package/es/components/Select/utils/getButtonLabel.js +0 -2
  473. package/es/components/Select/utils/getButtonLabel.js.map +1 -1
  474. package/es/components/Select/utils/getCorrectHeight.js.map +1 -1
  475. package/es/components/Sheet/Sheet.js +3 -3
  476. package/es/components/Skeleton/LineSkeleton/LineSkeleton.js +2 -4
  477. package/es/components/Skeleton/LineSkeleton/LineSkeleton.js.map +1 -1
  478. package/es/components/Skeleton/RectSkeleton/RectSkeleton.js +2 -4
  479. package/es/components/Skeleton/RectSkeleton/RectSkeleton.js.map +1 -1
  480. package/es/components/Slider/Slider.js +0 -8
  481. package/es/components/Slider/Slider.js.map +1 -1
  482. package/es/components/Slider/components/Double/Double.js +1 -2
  483. package/es/components/Slider/components/Double/Double.js.map +1 -1
  484. package/es/components/Slider/components/Double/Double.styles.js +0 -1
  485. package/es/components/Slider/components/Double/Double.styles.js.map +1 -1
  486. package/es/components/Slider/components/DoubleUncontrolled/DoubleUncontrolled.js +0 -3
  487. package/es/components/Slider/components/DoubleUncontrolled/DoubleUncontrolled.js.map +1 -1
  488. package/es/components/Slider/components/Single/Single.js +1 -2
  489. package/es/components/Slider/components/Single/Single.js.map +1 -1
  490. package/es/components/Slider/components/SliderBase/SliderBase.js +1 -1
  491. package/es/components/Steps/Steps.js +1 -1
  492. package/es/components/Steps/ui/StepItem/StepItem.styles.js +0 -1
  493. package/es/components/Steps/ui/StepItem/StepItem.styles.js.map +1 -1
  494. package/es/components/Tabs/ui/horizontal/HorizontalTabs/HorizontalTabs.js +2 -3
  495. package/es/components/Tabs/ui/horizontal/HorizontalTabs/HorizontalTabs.js.map +1 -1
  496. package/es/components/Tabs/ui/vertical/VerticalTabs/VerticalTabs.js +2 -3
  497. package/es/components/Tabs/ui/vertical/VerticalTabs/VerticalTabs.js.map +1 -1
  498. package/es/components/TextArea/TextArea.js +2 -2
  499. package/es/components/TextArea/TextArea.styles.js +2 -3
  500. package/es/components/TextArea/TextArea.styles.js.map +1 -1
  501. package/es/components/TextArea/ui/Hint/Hint.js +1 -2
  502. package/es/components/TextArea/ui/Hint/Hint.js.map +1 -1
  503. package/es/components/TextField/TextField.js +3 -3
  504. package/es/components/TextField/TextField.styles.js +1 -2
  505. package/es/components/TextField/TextField.styles.js.map +1 -1
  506. package/es/components/TextField/ui/Hint/Hint.js +1 -2
  507. package/es/components/TextField/ui/Hint/Hint.js.map +1 -1
  508. package/es/components/TextField/ui/TextFieldChip/TextFieldChip.styles.js +1 -2
  509. package/es/components/TextField/ui/TextFieldChip/TextFieldChip.styles.js.map +1 -1
  510. package/es/components/Toast/Toast.styles.js +1 -1
  511. package/es/components/Toast/ToastController.js +1 -1
  512. package/es/components/Toast/utils.js +1 -2
  513. package/es/components/Toast/utils.js.map +1 -1
  514. package/es/components/Toolbar/ui/ToolbarDivider/ToolbarDivider.js +1 -1
  515. package/es/components/Tooltip/Tooltip.js +2 -3
  516. package/es/components/Tooltip/Tooltip.js.map +1 -1
  517. package/es/engines/index.js +0 -2
  518. package/es/engines/index.js.map +1 -1
  519. package/es/hooks/useIsomorphicLayoutEffect.js +0 -1
  520. package/es/hooks/useIsomorphicLayoutEffect.js.map +1 -1
  521. package/es/hooks/useOutsideClick.js +1 -1
  522. package/es/hooks/useOutsideClick.js.map +1 -1
  523. package/es/index.css +26 -24
  524. package/es/index.js +21 -24
  525. package/es/index.js.map +1 -1
  526. package/es/utils/index.js +0 -3
  527. package/es/utils/index.js.map +1 -1
  528. package/package.json +5 -2
  529. package/styled-components/cjs/components/Dropdown/Dropdown.js +37 -58
  530. package/styled-components/cjs/components/Dropdown/Dropdown.styles.js +15 -9
  531. package/styled-components/cjs/components/Dropdown/Dropdown.tokens.js +2 -36
  532. package/styled-components/cjs/components/Dropdown/ui/DropdownInner/DropdownInner.js +51 -17
  533. package/styled-components/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.js +18 -29
  534. package/styled-components/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.styles.js +19 -17
  535. package/styled-components/cjs/components/Dropdown/utils/index.js +1 -23
  536. package/styled-components/cjs/components/Select/Select.styles.js +2 -2
  537. package/styled-components/cjs/components/Select/Select.tokens.js +17 -1
  538. package/styled-components/cjs/components/Select/ui/Inner/ui/Item/Item.styles.js +3 -3
  539. package/styled-components/cjs/examples/plasma_b2c/components/Dropdown/Dropdown.config.js +5 -5
  540. package/styled-components/cjs/examples/plasma_b2c/components/Dropdown/Dropdown.stories.tsx +5 -6
  541. package/styled-components/cjs/examples/plasma_web/components/Dropdown/Dropdown.config.js +5 -5
  542. package/styled-components/cjs/examples/plasma_web/components/Dropdown/Dropdown.stories.tsx +5 -6
  543. package/styled-components/cjs/hooks/useOutsideClick.js +1 -1
  544. package/styled-components/es/components/Dropdown/Dropdown.js +40 -60
  545. package/styled-components/es/components/Dropdown/Dropdown.styles.js +15 -9
  546. package/styled-components/es/components/Dropdown/Dropdown.tokens.js +1 -35
  547. package/styled-components/es/components/Dropdown/ui/DropdownInner/DropdownInner.js +52 -18
  548. package/styled-components/es/components/Dropdown/ui/DropdownItem/DropdownItem.js +20 -31
  549. package/styled-components/es/components/Dropdown/ui/DropdownItem/DropdownItem.styles.js +20 -18
  550. package/styled-components/es/components/Dropdown/utils/index.js +1 -4
  551. package/styled-components/es/components/Select/Select.styles.js +2 -2
  552. package/styled-components/es/components/Select/Select.tokens.js +17 -1
  553. package/styled-components/es/components/Select/ui/Inner/ui/Item/Item.styles.js +3 -3
  554. package/styled-components/es/examples/plasma_b2c/components/Dropdown/Dropdown.config.js +6 -6
  555. package/styled-components/es/examples/plasma_b2c/components/Dropdown/Dropdown.stories.tsx +5 -6
  556. package/styled-components/es/examples/plasma_web/components/Dropdown/Dropdown.config.js +6 -6
  557. package/styled-components/es/examples/plasma_web/components/Dropdown/Dropdown.stories.tsx +5 -6
  558. package/styled-components/es/hooks/useOutsideClick.js +1 -1
  559. package/styled-components/package.json +2 -1
  560. package/types/components/Combobox/ComboboxOld/Combobox.types.d.ts +1 -2
  561. package/types/components/Combobox/ComboboxOld/Combobox.types.d.ts.map +1 -1
  562. package/types/components/Dropdown/Dropdown.d.ts +1 -2
  563. package/types/components/Dropdown/Dropdown.d.ts.map +1 -1
  564. package/types/components/Dropdown/Dropdown.styles.d.ts +6 -1
  565. package/types/components/Dropdown/Dropdown.styles.d.ts.map +1 -1
  566. package/types/components/Dropdown/Dropdown.tokens.d.ts +0 -25
  567. package/types/components/Dropdown/Dropdown.tokens.d.ts.map +1 -1
  568. package/types/components/Dropdown/Dropdown.types.d.ts +4 -30
  569. package/types/components/Dropdown/Dropdown.types.d.ts.map +1 -1
  570. package/types/components/Dropdown/index.d.ts +1 -1
  571. package/types/components/Dropdown/index.d.ts.map +1 -1
  572. package/types/components/Dropdown/ui/DropdownInner/DropdownInner.d.ts.map +1 -1
  573. package/types/components/Dropdown/ui/DropdownInner/DropdownInner.type.d.ts +12 -1
  574. package/types/components/Dropdown/ui/DropdownInner/DropdownInner.type.d.ts.map +1 -1
  575. package/types/components/Dropdown/ui/DropdownItem/DropdownItem.d.ts.map +1 -1
  576. package/types/components/Dropdown/ui/DropdownItem/DropdownItem.styles.d.ts +3 -32
  577. package/types/components/Dropdown/ui/DropdownItem/DropdownItem.styles.d.ts.map +1 -1
  578. package/types/components/Dropdown/ui/DropdownItem/DropdownItem.type.d.ts +14 -1
  579. package/types/components/Dropdown/ui/DropdownItem/DropdownItem.type.d.ts.map +1 -1
  580. package/types/components/Dropdown/utils/index.d.ts +0 -3
  581. package/types/components/Dropdown/utils/index.d.ts.map +1 -1
  582. package/types/components/Select/Select.tokens.d.ts +16 -0
  583. package/types/components/Select/Select.tokens.d.ts.map +1 -1
  584. package/types/components/Select/utils/getCorrectHeight.d.ts +2 -2
  585. package/types/components/Select/utils/getCorrectHeight.d.ts.map +1 -1
  586. package/types/examples/plasma_b2c/components/Dropdown/Dropdown.config.d.ts +3 -3
  587. package/types/examples/plasma_b2c/components/Dropdown/Dropdown.config.d.ts.map +1 -1
  588. package/types/examples/plasma_b2c/components/Dropdown/Dropdown.d.ts +4 -4
  589. package/types/examples/plasma_b2c/components/Dropdown/Dropdown.d.ts.map +1 -1
  590. package/types/examples/plasma_web/components/Dropdown/Dropdown.config.d.ts +3 -3
  591. package/types/examples/plasma_web/components/Dropdown/Dropdown.config.d.ts.map +1 -1
  592. package/types/examples/plasma_web/components/Dropdown/Dropdown.d.ts +4 -4
  593. package/types/examples/plasma_web/components/Dropdown/Dropdown.d.ts.map +1 -1
  594. package/types/hooks/useOutsideClick.d.ts +1 -1
  595. package/types/hooks/useOutsideClick.d.ts.map +1 -1
  596. package/cjs/components/Dropdown/Dropdown.styles_18f0qpm.css +0 -2
  597. package/cjs/components/Dropdown/FloatingPopover.js +0 -104
  598. package/cjs/components/Dropdown/FloatingPopover.js.map +0 -1
  599. package/cjs/components/Dropdown/ui/DropdownItem/DropdownItem.styles_17va0nk.css +0 -5
  600. package/cjs/components/Dropdown/utils/getItemByFocused.js +0 -13
  601. package/cjs/components/Dropdown/utils/getItemByFocused.js.map +0 -1
  602. package/cjs/components/Dropdown/utils/getItemId.js +0 -10
  603. package/cjs/components/Dropdown/utils/getItemId.js.map +0 -1
  604. package/cjs/components/Dropdown/utils/getPlacement.js +0 -16
  605. package/cjs/components/Dropdown/utils/getPlacement.js.map +0 -1
  606. package/cjs/components/Select/Select.styles_1nzals0.css +0 -5
  607. package/emotion/cjs/components/Dropdown/FloatingPopover.js +0 -109
  608. package/emotion/cjs/components/Dropdown/utils/getItemByFocused.js +0 -12
  609. package/emotion/cjs/components/Dropdown/utils/getItemId.js +0 -9
  610. package/emotion/cjs/components/Dropdown/utils/getPlacement.js +0 -15
  611. package/emotion/es/components/Dropdown/FloatingPopover.js +0 -102
  612. package/emotion/es/components/Dropdown/utils/getItemByFocused.js +0 -6
  613. package/emotion/es/components/Dropdown/utils/getItemId.js +0 -3
  614. package/emotion/es/components/Dropdown/utils/getPlacement.js +0 -9
  615. package/es/components/Dropdown/Dropdown.styles_18f0qpm.css +0 -2
  616. package/es/components/Dropdown/FloatingPopover.js +0 -100
  617. package/es/components/Dropdown/FloatingPopover.js.map +0 -1
  618. package/es/components/Dropdown/ui/DropdownItem/DropdownItem.styles_17va0nk.css +0 -5
  619. package/es/components/Dropdown/utils/getItemByFocused.js +0 -9
  620. package/es/components/Dropdown/utils/getItemByFocused.js.map +0 -1
  621. package/es/components/Dropdown/utils/getItemId.js +0 -6
  622. package/es/components/Dropdown/utils/getItemId.js.map +0 -1
  623. package/es/components/Dropdown/utils/getPlacement.js +0 -12
  624. package/es/components/Dropdown/utils/getPlacement.js.map +0 -1
  625. package/es/components/Select/Select.styles_1nzals0.css +0 -5
  626. package/styled-components/cjs/components/Dropdown/FloatingPopover.js +0 -109
  627. package/styled-components/cjs/components/Dropdown/utils/getItemByFocused.js +0 -12
  628. package/styled-components/cjs/components/Dropdown/utils/getItemId.js +0 -9
  629. package/styled-components/cjs/components/Dropdown/utils/getPlacement.js +0 -15
  630. package/styled-components/es/components/Dropdown/FloatingPopover.js +0 -102
  631. package/styled-components/es/components/Dropdown/utils/getItemByFocused.js +0 -6
  632. package/styled-components/es/components/Dropdown/utils/getItemId.js +0 -3
  633. package/styled-components/es/components/Dropdown/utils/getPlacement.js +0 -9
  634. package/types/components/Dropdown/FloatingPopover.d.ts +0 -5
  635. package/types/components/Dropdown/FloatingPopover.d.ts.map +0 -1
  636. package/types/components/Dropdown/utils/getItemByFocused.d.ts +0 -4
  637. package/types/components/Dropdown/utils/getItemByFocused.d.ts.map +0 -1
  638. package/types/components/Dropdown/utils/getItemId.d.ts +0 -2
  639. package/types/components/Dropdown/utils/getItemId.d.ts.map +0 -1
  640. package/types/components/Dropdown/utils/getPlacement.d.ts +0 -3
  641. package/types/components/Dropdown/utils/getPlacement.d.ts.map +0 -1
@@ -4,7 +4,6 @@ import './AccordionItem.styles_aus2x3.css';
4
4
  Object.defineProperty(exports, '__esModule', { value: true });
5
5
 
6
6
  var react = require('@linaria/react');
7
- require('react');
8
7
  var IconChevronDownFill = require('../../../_Icon/Icons/IconChevronDownFill.js');
9
8
  var IconMinus = require('../../../_Icon/Icons/IconMinus.js');
10
9
 
@@ -1 +1 @@
1
- {"version":3,"file":"AccordionItem.styles.js","sources":["../../../../../src/components/Accordion/ui/AccordionItem/AccordionItem.styles.ts"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { IconChevronDownFill, IconMinus } from '../../../_Icon';\nimport { classes, tokens } from '../../Accordion.tokens';\nimport { addFocus } from '../../../../mixins';\n\nexport const StyledAccordionItem = styled.div`\n background: var(${tokens.accordionItemBackground});\n border: var(${tokens.accordionItemBorder});\n border-bottom: var(${tokens.accordionItemBorderBottom});\n\n &:last-child {\n border-bottom: var(${tokens.accordionItemBorder});\n }\n\n &.${classes.accordionDisabled} {\n opacity: 0.4;\n cursor: not-allowed;\n }\n`;\n\nexport const StyledAccordionHeader = styled.button`\n width: 100%;\n border: none;\n padding: var(${tokens.accordionItemPadding});\n display: flex;\n gap: var(${tokens.accordionItemGap});\n justify-content: space-between;\n align-items: center;\n background: none;\n box-sizing: border-box;\n cursor: pointer;\n\n &:focus {\n outline: none;\n }\n\n ${addFocus({\n outlineOffset: '0.125rem',\n outlineSize: '0.125rem',\n outlineRadius: '0',\n outlineColor: `var(${tokens.accordionItemFocus})`,\n })}\n`;\n\nexport const StyledAccordionHeaderLeft = styled.div`\n display: flex;\n gap: var(${tokens.accordionItemGap});\n justify-content: space-between;\n align-items: center;\n`;\n\nexport const StyledAccordionContentRight = styled.div`\n transition: 0.2s;\n transform: rotate(90deg);\n\n &.${classes.accordionItemShowBody} {\n transition: 0.2s;\n transform: rotate(0deg);\n }\n`;\n\nexport const StyledAccordionContentLeft = styled.div`\n transition: 0.2s;\n display: flex;\n align-items: center;\n\n &.${classes.accordionItemShowBody} {\n transition: 0.2s;\n transform: rotate(180deg);\n }\n`;\n\nexport const StyledAccordionTitle = styled.div`\n color: var(${tokens.accordionItemTitleColor});\n font-family: var(${tokens.accordionItemTitleFontFamily});\n font-size: var(${tokens.accordionItemTitleFontSize});\n font-weight: var(${tokens.accordionItemTitleFontWeight});\n font-style: var(${tokens.accordionItemTitleFontStyle});\n letter-spacing: var(${tokens.accordionItemTitleLetterSpacing});\n line-height: var(${tokens.accordionItemTitleLineHeight});\n text-align: left;\n`;\n\nexport const StyledAccordionBodyAnimate = styled.div`\n display: grid;\n grid-template-rows: 0fr;\n transition: grid-template-rows 0.2s ease-out;\n overflow: hidden;\n\n &.${classes.accordionItemShowBody} {\n grid-template-rows: 1fr;\n padding-bottom: var(${tokens.accordionItemPaddingVertical});\n\n &.${classes.accordionPlusAnimationElement} {\n transition: 0.2s;\n transform: rotate(0deg);\n }\n }\n`;\n\nexport const StyledAccordionBody = styled.div`\n color: var(${tokens.accordionItemTextColor});\n font-family: var(${tokens.accordionItemTextFontFamily});\n font-size: var(${tokens.accordionItemTextFontSize});\n font-weight: var(${tokens.accordionItemTextFontWeight});\n font-style: var(${tokens.accordionItemTextFontStyle});\n letter-spacing: var(${tokens.accordionItemTextLetterSpacing});\n line-height: var(${tokens.accordionItemTextLineHeight});\n overflow: hidden;\n padding-right: var(${tokens.accordionItemPaddingHorizontal});\n padding-left: var(${tokens.accordionItemPaddingHorizontalLeft});\n text-align: left;\n`;\n\nexport const StyledArrow = styled(IconChevronDownFill)`\n pointer-events: none;\n user-select: none;\n color: var(${tokens.accordionItemIconColor});\n`;\n\nexport const StyledMinus = styled(IconMinus)`\n pointer-events: none;\n user-select: none;\n color: var(${tokens.accordionItemIconColor});\n display: flex;\n align-items: center;\n position: absolute;\n top: 0;\n left: 0;\n\n &.${classes.accordionPlusAnimationElement} {\n transition: 0.2s;\n transform: rotate(90deg);\n }\n\n &.${classes.accordionItemShowBody} {\n transition: 0.2s;\n transform: rotate(0deg);\n }\n`;\n\nexport const StyledPlus = styled.div`\n position: relative;\n height: 1rem;\n display: flex;\n align-items: center;\n justify-content: center;\n width: 1rem;\n`;\n"],"names":["StyledAccordionItem","styled","name","class","propsAsIs","StyledAccordionHeader","StyledAccordionHeaderLeft","StyledAccordionContentRight","StyledAccordionContentLeft","StyledAccordionTitle","StyledAccordionBodyAnimate","StyledAccordionBody","_exp31","IconChevronDownFill","StyledArrow","_exp33","IconMinus","StyledMinus","StyledPlus"],"mappings":";;;;;;;;;AAMO,IAAMA,mBAAmB,gBAAGC,YAAM,CAAA,KAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,qBAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAaxC,EAAA;AAEM,IAAMC,qBAAqB,gBAAGJ,YAAM,CAAA,QAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,uBAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAsB1C,EAAA;AAEM,IAAME,yBAAyB,gBAAGL,YAAM,CAAA,KAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,2BAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAK9C,EAAA;AAEM,IAAMG,2BAA2B,gBAAGN,YAAM,CAA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AAA,CAAA,CAAA;AAApC,IAAMC,WAAW,gBAAGhB,YAAM,CAAAc,MAAA,EAAA,CAAA,CAAA;AAAAb,EAAAA,IAAA,EAAA,aAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CAmBhC,EAAA;AAEM,IAAMc,UAAU,gBAAGjB,YAAM,CAAA,KAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,YAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAO/B;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"AccordionItem.styles.js","sources":["../../../../../src/components/Accordion/ui/AccordionItem/AccordionItem.styles.ts"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { IconChevronDownFill, IconMinus } from '../../../_Icon';\nimport { classes, tokens } from '../../Accordion.tokens';\nimport { addFocus } from '../../../../mixins';\n\nexport const StyledAccordionItem = styled.div`\n background: var(${tokens.accordionItemBackground});\n border: var(${tokens.accordionItemBorder});\n border-bottom: var(${tokens.accordionItemBorderBottom});\n\n &:last-child {\n border-bottom: var(${tokens.accordionItemBorder});\n }\n\n &.${classes.accordionDisabled} {\n opacity: 0.4;\n cursor: not-allowed;\n }\n`;\n\nexport const StyledAccordionHeader = styled.button`\n width: 100%;\n border: none;\n padding: var(${tokens.accordionItemPadding});\n display: flex;\n gap: var(${tokens.accordionItemGap});\n justify-content: space-between;\n align-items: center;\n background: none;\n box-sizing: border-box;\n cursor: pointer;\n\n &:focus {\n outline: none;\n }\n\n ${addFocus({\n outlineOffset: '0.125rem',\n outlineSize: '0.125rem',\n outlineRadius: '0',\n outlineColor: `var(${tokens.accordionItemFocus})`,\n })}\n`;\n\nexport const StyledAccordionHeaderLeft = styled.div`\n display: flex;\n gap: var(${tokens.accordionItemGap});\n justify-content: space-between;\n align-items: center;\n`;\n\nexport const StyledAccordionContentRight = styled.div`\n transition: 0.2s;\n transform: rotate(90deg);\n\n &.${classes.accordionItemShowBody} {\n transition: 0.2s;\n transform: rotate(0deg);\n }\n`;\n\nexport const StyledAccordionContentLeft = styled.div`\n transition: 0.2s;\n display: flex;\n align-items: center;\n\n &.${classes.accordionItemShowBody} {\n transition: 0.2s;\n transform: rotate(180deg);\n }\n`;\n\nexport const StyledAccordionTitle = styled.div`\n color: var(${tokens.accordionItemTitleColor});\n font-family: var(${tokens.accordionItemTitleFontFamily});\n font-size: var(${tokens.accordionItemTitleFontSize});\n font-weight: var(${tokens.accordionItemTitleFontWeight});\n font-style: var(${tokens.accordionItemTitleFontStyle});\n letter-spacing: var(${tokens.accordionItemTitleLetterSpacing});\n line-height: var(${tokens.accordionItemTitleLineHeight});\n text-align: left;\n`;\n\nexport const StyledAccordionBodyAnimate = styled.div`\n display: grid;\n grid-template-rows: 0fr;\n transition: grid-template-rows 0.2s ease-out;\n overflow: hidden;\n\n &.${classes.accordionItemShowBody} {\n grid-template-rows: 1fr;\n padding-bottom: var(${tokens.accordionItemPaddingVertical});\n\n &.${classes.accordionPlusAnimationElement} {\n transition: 0.2s;\n transform: rotate(0deg);\n }\n }\n`;\n\nexport const StyledAccordionBody = styled.div`\n color: var(${tokens.accordionItemTextColor});\n font-family: var(${tokens.accordionItemTextFontFamily});\n font-size: var(${tokens.accordionItemTextFontSize});\n font-weight: var(${tokens.accordionItemTextFontWeight});\n font-style: var(${tokens.accordionItemTextFontStyle});\n letter-spacing: var(${tokens.accordionItemTextLetterSpacing});\n line-height: var(${tokens.accordionItemTextLineHeight});\n overflow: hidden;\n padding-right: var(${tokens.accordionItemPaddingHorizontal});\n padding-left: var(${tokens.accordionItemPaddingHorizontalLeft});\n text-align: left;\n`;\n\nexport const StyledArrow = styled(IconChevronDownFill)`\n pointer-events: none;\n user-select: none;\n color: var(${tokens.accordionItemIconColor});\n`;\n\nexport const StyledMinus = styled(IconMinus)`\n pointer-events: none;\n user-select: none;\n color: var(${tokens.accordionItemIconColor});\n display: flex;\n align-items: center;\n position: absolute;\n top: 0;\n left: 0;\n\n &.${classes.accordionPlusAnimationElement} {\n transition: 0.2s;\n transform: rotate(90deg);\n }\n\n &.${classes.accordionItemShowBody} {\n transition: 0.2s;\n transform: rotate(0deg);\n }\n`;\n\nexport const StyledPlus = styled.div`\n position: relative;\n height: 1rem;\n display: flex;\n align-items: center;\n justify-content: center;\n width: 1rem;\n`;\n"],"names":["StyledAccordionItem","styled","name","class","propsAsIs","StyledAccordionHeader","StyledAccordionHeaderLeft","StyledAccordionContentRight","StyledAccordionContentLeft","StyledAccordionTitle","StyledAccordionBodyAnimate","StyledAccordionBody","_exp31","IconChevronDownFill","StyledArrow","_exp33","IconMinus","StyledMinus","StyledPlus"],"mappings":";;;;;;;;AAMO,IAAMA,mBAAmB,gBAAGC,YAAM,CAAA,KAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,qBAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAaxC,EAAA;AAEM,IAAMC,qBAAqB,gBAAGJ,YAAM,CAAA,QAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,uBAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAsB1C,EAAA;AAEM,IAAME,yBAAyB,gBAAGL,YAAM,CAAA,KAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,2BAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAK9C,EAAA;AAEM,IAAMG,2BAA2B,gBAAGN,YAAM,CAAA,KAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,6BAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAQhD,EAAA;AAEM,IAAMI,0BAA0B,gBAAGP,YAAM,CAAA,KAAA,CAAA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hC,EAAA;AAEM,IAAMc,UAAU,gBAAGjB,YAAM,CAAA,KAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,YAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAO/B;;;;;;;;;;;;;;"}
@@ -6,18 +6,17 @@ var _rollupPluginBabelHelpers = require('../../_virtual/_rollupPluginBabelHelper
6
6
  var React = require('react');
7
7
  var plasmaCore = require('@salutejs/plasma-core');
8
8
  var index = require('../../utils/index.js');
9
- require('@linaria/react');
10
- var IconCloseCircleOutline = require('../_Icon/Icons/IconCloseCircleOutline.js');
11
9
  var base$1 = require('./variations/_size/base.js');
12
10
  var base = require('./variations/_view/base.js');
13
11
  var Attach_styles = require('./Attach.styles.js');
14
- var Cell_styles = require('./ui/Cell/Cell.styles.js');
15
12
  var index$1 = require('./utils/index.js');
16
13
  var Attach_tokens = require('./Attach.tokens.js');
17
- var AttachButton = require('./components/AttachButton/AttachButton.js');
18
14
  var IconButton_styles = require('./ui/IconButton/IconButton.styles.js');
19
15
  var extractExtension = require('./utils/extractExtension.js');
20
16
  var addSeparator = require('./utils/addSeparator.js');
17
+ var AttachButton = require('./components/AttachButton/AttachButton.js');
18
+ var Cell_styles = require('./ui/Cell/Cell.styles.js');
19
+ var IconCloseCircleOutline = require('../_Icon/Icons/IconCloseCircleOutline.js');
21
20
  var getFileicon = require('./utils/getFileicon.js');
22
21
 
23
22
  var _IconCloseCircleOutli;
@@ -1 +1 @@
1
- {"version":3,"file":"Attach.js","sources":["../../../src/components/Attach/Attach.tsx"],"sourcesContent":["import React, { forwardRef, useEffect, useRef, useState } from 'react';\nimport type { ChangeEvent } from 'react';\nimport { useForkRef, useIsomorphicLayoutEffect } from '@salutejs/plasma-core';\n\nimport { RootProps } from '../../engines';\nimport { cx } from '../../utils';\nimport { IconCloseCircleOutline } from '../_Icon';\n\nimport { AttachProps } from './Attach.types';\nimport { base as sizeCSS } from './variations/_size/base';\nimport { base as viewCSS } from './variations/_view/base';\nimport { base, StyledHiddenInput, StyledHiddenInputHelper } from './Attach.styles';\nimport { StyledCell } from './ui/Cell/Cell';\nimport { extractExtension, getFileicon, addSeparator, separator } from './utils';\nimport { classes } from './Attach.tokens';\nimport { AttachButton } from './components/AttachButton';\nimport { StyledIconButtonCancel } from './ui/IconButton/IconButton.styles';\n\nexport const attachRoot = (Root: RootProps<HTMLDivElement, AttachProps>) =>\n forwardRef<HTMLDivElement, AttachProps>((props, outerRef) => {\n const {\n flow = 'auto',\n buttonType = 'button',\n hasAttachment = true,\n acceptedFileFormats,\n size,\n view,\n className,\n style,\n isLoading,\n disabled,\n id,\n name,\n onChange,\n onClear,\n ...rest\n } = props;\n\n const innerRef = useRef<HTMLDivElement>(null);\n const ref = useForkRef(outerRef, innerRef);\n\n const inputRef = useRef<HTMLInputElement | null>(null);\n const inputHelperRef = useRef<HTMLDivElement | null>(null);\n const cellRef = useRef<HTMLDivElement | null>(null);\n const buttonRef = useRef<HTMLButtonElement | null>(null);\n\n const emptyTextCellWidth = useRef<number | null>(null);\n\n const [filename, setFilename] = useState<string>('');\n const [truncatedFilename, setTruncatedFilename] = useState<string>('');\n\n const horizontalClass = flow === 'horizontal' ? classes.horizontal : undefined;\n const verticalClass = flow === 'vertical' ? classes.vertical : undefined;\n const autoClass = flow === 'auto' ? classes.auto : undefined;\n const cellHiddenClass = truncatedFilename.length === 0 ? classes.cellHidden : undefined;\n\n const accept = acceptedFileFormats?.join(',');\n const extension = extractExtension(filename);\n const cellContentLeft = getFileicon(extension, size);\n\n useEffect(() => {\n emptyTextCellWidth.current = cellRef.current?.offsetWidth || 0;\n }, []);\n\n useIsomorphicLayoutEffect(() => {\n if (\n !cellRef.current ||\n !cellRef.current.parentElement ||\n !inputHelperRef.current ||\n !inputHelperRef.current.textContent ||\n !emptyTextCellWidth.current ||\n !buttonRef.current\n ) {\n return;\n }\n\n const { offsetWidth: textWidth } = inputHelperRef.current;\n const { offsetWidth: buttonWidth } = buttonRef.current;\n const { width: parentWidth, left: parentLeft } = cellRef.current.parentElement.getBoundingClientRect();\n const { left: cellLeft } = cellRef.current.getBoundingClientRect();\n const leftDiff = cellLeft - parentLeft;\n let currentTextWidth = textWidth;\n\n if (\n currentTextWidth + emptyTextCellWidth.current + leftDiff <= parentWidth ||\n currentTextWidth + emptyTextCellWidth.current < buttonWidth\n ) {\n setTruncatedFilename(filename);\n return;\n }\n\n let currFilename = addSeparator(filename, separator);\n for (let i = currFilename.indexOf(separator) - 1; i > 0; i -= 1) {\n if (currentTextWidth + emptyTextCellWidth.current + leftDiff <= parentWidth) {\n break;\n }\n\n const left = currFilename.slice(0, i);\n const right = currFilename.slice(i + 1);\n const newFilename = `${left}${right}`;\n inputHelperRef.current.textContent = newFilename;\n currentTextWidth = inputHelperRef.current.offsetWidth;\n\n if (currentTextWidth + emptyTextCellWidth.current < buttonWidth) {\n break;\n }\n\n currFilename = newFilename;\n }\n\n inputHelperRef.current.textContent = filename;\n setTruncatedFilename(currFilename);\n });\n\n const handleClick = () => {\n if (!inputRef.current) {\n return;\n }\n\n inputRef.current.click();\n };\n\n const handleChange = (e: ChangeEvent<HTMLInputElement>) => {\n if (!e.target.files) {\n return;\n }\n\n if (onChange) {\n onChange(e);\n }\n\n setFilename(e.target.files[0].name);\n };\n\n const handleClear = () => {\n if (!inputRef.current) {\n return;\n }\n\n if (onClear) {\n onClear();\n }\n\n inputRef.current.value = '';\n setFilename('');\n setTruncatedFilename('');\n };\n\n return (\n <Root\n className={cx(horizontalClass, verticalClass, autoClass, className)}\n style={style}\n size={size}\n view={view}\n ref={ref}\n >\n <StyledHiddenInput\n ref={inputRef}\n accept={accept}\n type=\"file\"\n id={id}\n name={name}\n onChange={handleChange}\n />\n <StyledHiddenInputHelper ref={inputHelperRef}>{filename}</StyledHiddenInputHelper>\n\n <AttachButton\n buttonType={buttonType}\n view={view}\n size={size}\n onClick={handleClick}\n isLoading={isLoading}\n disabled={disabled}\n ref={buttonRef}\n {...rest}\n />\n {hasAttachment && (\n <StyledCell\n stretching=\"fixed\"\n className={cellHiddenClass}\n ref={cellRef}\n size={size}\n title={truncatedFilename}\n contentLeft={cellContentLeft}\n contentRight={\n <StyledIconButtonCancel view={view} size={size} onClick={handleClear}>\n <IconCloseCircleOutline size=\"xs\" color=\"inherit\" />\n </StyledIconButtonCancel>\n }\n />\n )}\n </Root>\n );\n });\n\nexport const attachConfig = {\n name: 'Attach',\n tag: 'div',\n layout: attachRoot,\n base,\n variations: {\n view: {\n css: viewCSS,\n },\n size: {\n css: sizeCSS,\n },\n },\n defaults: {\n view: 'default',\n size: 'm',\n },\n};\n"],"names":["attachRoot","Root","forwardRef","props","outerRef","_props$flow","flow","_props$buttonType","buttonType","_props$hasAttachment","hasAttachment","acceptedFileFormats","size","view","className","style","isLoading","disabled","id","name","onChange","onClear","rest","_objectWithoutProperties","_excluded","innerRef","useRef","ref","useForkRef","inputRef","inputHelperRef","cellRef","buttonRef","emptyTextCellWidth","_useState","useState","_useState2","_slicedToArray","filename","setFilename","_useState3","_useState4","truncatedFilename","setTruncatedFilename","horizontalClass","classes","horizontal","undefined","verticalClass","vertical","autoClass","auto","cellHiddenClass","length","cellHidden","accept","join","extension","extractExtension","cellContentLeft","getFileicon","useEffect","_cellRef$current","current","offsetWidth","useIsomorphicLayoutEffect","parentElement","textContent","textWidth","buttonWidth","_cellRef$current$pare","getBoundingClientRect","parentWidth","width","parentLeft","left","_cellRef$current$getB","cellLeft","leftDiff","currentTextWidth","currFilename","addSeparator","separator","i","indexOf","slice","right","newFilename","concat","handleClick","click","handleChange","e","target","files","handleClear","value","React","createElement","cx","StyledHiddenInput","type","StyledHiddenInputHelper","AttachButton","_extends","onClick","StyledCell","stretching","title","contentLeft","contentRight","StyledIconButtonCancel","_IconCloseCircleOutli","IconCloseCircleOutline","color","attachConfig","tag","layout","base","variations","css","viewCSS","sizeCSS","defaults"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;IAkBaA,UAAU,GAAG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AK;AAAC6F,QAAAA,OAAO,EAAEV,WAAAA;OAAYiB,EAAAA,qBAAA,KAAAA,qBAAA,gBACjEf,KAAA,CAAAC,aAAA,CAACe,6CAAsB,EAAA;AAACrG,QAAAA,IAAI,EAAC,IAAI;AAACsG,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAChC,CAAA;AAC3B,KACJ,CAEH,CAAC,CAAA;AAEf,GAAC,CAAC,CAAA;AAAA,EAAA;AAEC,IAAMC,YAAY,GAAG;AACxBhG,EAAAA,IAAI,EAAE,QAAQ;AACdiG,EAAAA,GAAG,EAAE,KAAK;AACVC,EAAAA,MAAM,EAAErH,UAAU;AAClBsH,EAAAA,IAAI,EAAJA,kBAAI;AACJC,EAAAA,UAAU,EAAE;AACR1G,IAAAA,IAAI,EAAE;AACF2G,MAAAA,GAAG,EAAEC,SAAAA;KACR;AACD7G,IAAAA,IAAI,EAAE;AACF4G,MAAAA,GAAG,EAAEE,WAAAA;AACT,KAAA;GACH;AACDC,EAAAA,QAAQ,EAAE;AACN9G,IAAAA,IAAI,EAAE,SAAS;AACfD,IAAAA,IAAI,EAAE,GAAA;AACV,GAAA;AACJ;;;;;"}
1
+ {"version":3,"file":"Attach.js","sources":["../../../src/components/Attach/Attach.tsx"],"sourcesContent":["import React, { forwardRef, useEffect, useRef, useState } from 'react';\nimport type { ChangeEvent } from 'react';\nimport { useForkRef, useIsomorphicLayoutEffect } from '@salutejs/plasma-core';\n\nimport { RootProps } from '../../engines';\nimport { cx } from '../../utils';\nimport { IconCloseCircleOutline } from '../_Icon';\n\nimport { AttachProps } from './Attach.types';\nimport { base as sizeCSS } from './variations/_size/base';\nimport { base as viewCSS } from './variations/_view/base';\nimport { base, StyledHiddenInput, StyledHiddenInputHelper } from './Attach.styles';\nimport { StyledCell } from './ui/Cell/Cell';\nimport { extractExtension, getFileicon, addSeparator, separator } from './utils';\nimport { classes } from './Attach.tokens';\nimport { AttachButton } from './components/AttachButton';\nimport { StyledIconButtonCancel } from './ui/IconButton/IconButton.styles';\n\nexport const attachRoot = (Root: RootProps<HTMLDivElement, AttachProps>) =>\n forwardRef<HTMLDivElement, AttachProps>((props, outerRef) => {\n const {\n flow = 'auto',\n buttonType = 'button',\n hasAttachment = true,\n acceptedFileFormats,\n size,\n view,\n className,\n style,\n isLoading,\n disabled,\n id,\n name,\n onChange,\n onClear,\n ...rest\n } = props;\n\n const innerRef = useRef<HTMLDivElement>(null);\n const ref = useForkRef(outerRef, innerRef);\n\n const inputRef = useRef<HTMLInputElement | null>(null);\n const inputHelperRef = useRef<HTMLDivElement | null>(null);\n const cellRef = useRef<HTMLDivElement | null>(null);\n const buttonRef = useRef<HTMLButtonElement | null>(null);\n\n const emptyTextCellWidth = useRef<number | null>(null);\n\n const [filename, setFilename] = useState<string>('');\n const [truncatedFilename, setTruncatedFilename] = useState<string>('');\n\n const horizontalClass = flow === 'horizontal' ? classes.horizontal : undefined;\n const verticalClass = flow === 'vertical' ? classes.vertical : undefined;\n const autoClass = flow === 'auto' ? classes.auto : undefined;\n const cellHiddenClass = truncatedFilename.length === 0 ? classes.cellHidden : undefined;\n\n const accept = acceptedFileFormats?.join(',');\n const extension = extractExtension(filename);\n const cellContentLeft = getFileicon(extension, size);\n\n useEffect(() => {\n emptyTextCellWidth.current = cellRef.current?.offsetWidth || 0;\n }, []);\n\n useIsomorphicLayoutEffect(() => {\n if (\n !cellRef.current ||\n !cellRef.current.parentElement ||\n !inputHelperRef.current ||\n !inputHelperRef.current.textContent ||\n !emptyTextCellWidth.current ||\n !buttonRef.current\n ) {\n return;\n }\n\n const { offsetWidth: textWidth } = inputHelperRef.current;\n const { offsetWidth: buttonWidth } = buttonRef.current;\n const { width: parentWidth, left: parentLeft } = cellRef.current.parentElement.getBoundingClientRect();\n const { left: cellLeft } = cellRef.current.getBoundingClientRect();\n const leftDiff = cellLeft - parentLeft;\n let currentTextWidth = textWidth;\n\n if (\n currentTextWidth + emptyTextCellWidth.current + leftDiff <= parentWidth ||\n currentTextWidth + emptyTextCellWidth.current < buttonWidth\n ) {\n setTruncatedFilename(filename);\n return;\n }\n\n let currFilename = addSeparator(filename, separator);\n for (let i = currFilename.indexOf(separator) - 1; i > 0; i -= 1) {\n if (currentTextWidth + emptyTextCellWidth.current + leftDiff <= parentWidth) {\n break;\n }\n\n const left = currFilename.slice(0, i);\n const right = currFilename.slice(i + 1);\n const newFilename = `${left}${right}`;\n inputHelperRef.current.textContent = newFilename;\n currentTextWidth = inputHelperRef.current.offsetWidth;\n\n if (currentTextWidth + emptyTextCellWidth.current < buttonWidth) {\n break;\n }\n\n currFilename = newFilename;\n }\n\n inputHelperRef.current.textContent = filename;\n setTruncatedFilename(currFilename);\n });\n\n const handleClick = () => {\n if (!inputRef.current) {\n return;\n }\n\n inputRef.current.click();\n };\n\n const handleChange = (e: ChangeEvent<HTMLInputElement>) => {\n if (!e.target.files) {\n return;\n }\n\n if (onChange) {\n onChange(e);\n }\n\n setFilename(e.target.files[0].name);\n };\n\n const handleClear = () => {\n if (!inputRef.current) {\n return;\n }\n\n if (onClear) {\n onClear();\n }\n\n inputRef.current.value = '';\n setFilename('');\n setTruncatedFilename('');\n };\n\n return (\n <Root\n className={cx(horizontalClass, verticalClass, autoClass, className)}\n style={style}\n size={size}\n view={view}\n ref={ref}\n >\n <StyledHiddenInput\n ref={inputRef}\n accept={accept}\n type=\"file\"\n id={id}\n name={name}\n onChange={handleChange}\n />\n <StyledHiddenInputHelper ref={inputHelperRef}>{filename}</StyledHiddenInputHelper>\n\n <AttachButton\n buttonType={buttonType}\n view={view}\n size={size}\n onClick={handleClick}\n isLoading={isLoading}\n disabled={disabled}\n ref={buttonRef}\n {...rest}\n />\n {hasAttachment && (\n <StyledCell\n stretching=\"fixed\"\n className={cellHiddenClass}\n ref={cellRef}\n size={size}\n title={truncatedFilename}\n contentLeft={cellContentLeft}\n contentRight={\n <StyledIconButtonCancel view={view} size={size} onClick={handleClear}>\n <IconCloseCircleOutline size=\"xs\" color=\"inherit\" />\n </StyledIconButtonCancel>\n }\n />\n )}\n </Root>\n );\n });\n\nexport const attachConfig = {\n name: 'Attach',\n tag: 'div',\n layout: attachRoot,\n base,\n variations: {\n view: {\n css: viewCSS,\n },\n size: {\n css: sizeCSS,\n },\n },\n defaults: {\n view: 'default',\n size: 'm',\n },\n};\n"],"names":["attachRoot","Root","forwardRef","props","outerRef","_props$flow","flow","_props$buttonType","buttonType","_props$hasAttachment","hasAttachment","acceptedFileFormats","size","view","className","style","isLoading","disabled","id","name","onChange","onClear","rest","_objectWithoutProperties","_excluded","innerRef","useRef","ref","useForkRef","inputRef","inputHelperRef","cellRef","buttonRef","emptyTextCellWidth","_useState","useState","_useState2","_slicedToArray","filename","setFilename","_useState3","_useState4","truncatedFilename","setTruncatedFilename","horizontalClass","classes","horizontal","undefined","verticalClass","vertical","autoClass","auto","cellHiddenClass","length","cellHidden","accept","join","extension","extractExtension","cellContentLeft","getFileicon","useEffect","_cellRef$current","current","offsetWidth","useIsomorphicLayoutEffect","parentElement","textContent","textWidth","buttonWidth","_cellRef$current$pare","getBoundingClientRect","parentWidth","width","parentLeft","left","_cellRef$current$getB","cellLeft","leftDiff","currentTextWidth","currFilename","addSeparator","separator","i","indexOf","slice","right","newFilename","concat","handleClick","click","handleChange","e","target","files","handleClear","value","React","createElement","cx","StyledHiddenInput","type","StyledHiddenInputHelper","AttachButton","_extends","onClick","StyledCell","stretching","title","contentLeft","contentRight","StyledIconButtonCancel","_IconCloseCircleOutli","IconCloseCircleOutline","color","attachConfig","tag","layout","base","variations","css","viewCSS","sizeCSS","defaults"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;IAkBaA,UAAU,GAAG,SAAbA,UAAUA,CAAIC,IAA4C,EAAA;AAAA,EAAA,oBACnEC,gBAAU,CAA8B,UAACC,KAAK,EAAEC,QAAQ,EAAK;AACzD,IAAA,IAAAC,WAAA,GAgBIF,KAAK,CAfLG,IAAI;AAAJA,MAAAA,IAAI,GAAAD,WAAA,KAAG,KAAA,CAAA,GA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ChC,CAAA;AAC3B,KACJ,CAEH,CAAC,CAAA;AAEf,GAAC,CAAC,CAAA;AAAA,EAAA;AAEC,IAAMC,YAAY,GAAG;AACxBhG,EAAAA,IAAI,EAAE,QAAQ;AACdiG,EAAAA,GAAG,EAAE,KAAK;AACVC,EAAAA,MAAM,EAAErH,UAAU;AAClBsH,EAAAA,IAAI,EAAJA,kBAAI;AACJC,EAAAA,UAAU,EAAE;AACR1G,IAAAA,IAAI,EAAE;AACF2G,MAAAA,GAAG,EAAEC,SAAAA;KACR;AACD7G,IAAAA,IAAI,EAAE;AACF4G,MAAAA,GAAG,EAAEE,WAAAA;AACT,KAAA;GACH;AACDC,EAAAA,QAAQ,EAAE;AACN9G,IAAAA,IAAI,EAAE,SAAS;AACfD,IAAAA,IAAI,EAAE,GAAA;AACV,GAAA;AACJ;;;;;"}
@@ -6,7 +6,6 @@ var _rollupPluginBabelHelpers = require('../../../../_virtual/_rollupPluginBabel
6
6
  var React = require('react');
7
7
  var IconButton_styles = require('../../ui/IconButton/IconButton.styles.js');
8
8
  var Button_styles = require('../../ui/Button/Button.styles.js');
9
- require('@linaria/react');
10
9
  var IconPlus = require('../../../_Icon/Icons/IconPlus.js');
11
10
 
12
11
  var _excluded = ["size", "icon"],
@@ -1 +1 @@
1
- {"version":3,"file":"AttachButton.js","sources":["../../../../../src/components/Attach/components/AttachButton/AttachButton.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\n\nimport { AttachButtonProps } from '../../Attach.types';\nimport { StyledIconButton } from '../../ui/IconButton/IconButton';\nimport { StyledButton } from '../../ui/Button/Button';\nimport { IconPlus } from '../../../_Icon';\n\nconst getDefaultIcon = (size?: string) => {\n let iconSize: 'xs' | 's' | 'm';\n switch (size) {\n case 'xs':\n iconSize = 'xs';\n break;\n case 's':\n iconSize = 's';\n break;\n default:\n iconSize = 'm';\n }\n return <IconPlus size={iconSize} color=\"inherit\" />;\n};\n\nexport const AttachButton = forwardRef<HTMLButtonElement, AttachButtonProps>((props, ref) => {\n if (props.buttonType === 'iconButton') {\n const { size, icon, ...rest } = props;\n\n return (\n <StyledIconButton ref={ref} {...rest}>\n {icon || getDefaultIcon(size)}\n </StyledIconButton>\n );\n }\n\n const { text = 'Загрузить файл', ...rest } = props;\n return <StyledButton ref={ref} text={text} {...rest} />;\n});\n"],"names":["getDefaultIcon","size","iconSize","React","createElement","IconPlus","color","AttachButton","forwardRef","props","ref","buttonType","icon","rest","_objectWithoutProperties","_excluded","StyledIconButton","_extends","_props$text","text","_excluded2","StyledButton"],"mappings":";;;;;;;;;;;;;AAOA,IAAMA,cAAc,GAAG,SAAjBA,cAAcA,CAAIC,IAAa,EAAK;AACtC,EAAA,IAAIC,QAA0B,CAAA;AAC9B,EAAA,QAAQD,IAAI;AACR,IAAA,KAAK,IAAI;AACLC,MAAAA,QAAQ,GAAG,IAAI,CAAA;AACf,MAAA,MAAA;AACJ,IAAA,KAAK,GAAG;AACJA,MAAAA,QAAQ,GAAG,GAAG,CAAA;AACd,MAAA,MAAA;AACJ,IAAA;AACIA,MAAAA,QAAQ,GAAG,GAAG,CAAA;AACtB,GAAA;AACA,EAAA,oBAAOC,KAAA,CAAAC,aAAA,CAACC,iBAAQ,EAAA;AAACJ,IAAAA,IAAI,EAAEC,QAAS;AAACI,IAAAA,KAAK,EAAC,SAAA;AAAS,GAAE,CAAC,CAAA;AACvD,CAAC,CAAA;AAEM,IAAMC,YAAY,gBAAGC,gBAAU,CAAuC,UAACC,KAAK,EAAEC,GAAG,EAAK;AACzF,EAAA,IAAID,KAAK,CAACE,UAAU,KAAK,YAAY,EAAE;AACnC,IAAA,IAAQV,IAAI,GAAoBQ,KAAK,CAA7BR,IAAI;MAAEW,IAAI,GAAcH,KAAK,CAAvBG,IAAI;AAAKC,MAAAA,KAAI,GAAAC,iDAAA,CAAKL,KAAK,EAAAM,SAAA,CAAA,CAAA;AAErC,IAAA,oBACIZ,KAAA,CAAAC,aAAA,CAACY,kCAAgB,EAAAC,iCAAA,CAAA;AAACP,MAAAA,GAAG,EAAEA,GAAAA;KAASG,EAAAA,KAAI,GAC/BD,IAAI,IAAIZ,cAAc,CAACC,IAAI,CACd,CAAC,CAAA;AAE3B,GAAA;AAEA,EAAA,IAAAiB,WAAA,GAA6CT,KAAK,CAA1CU,IAAI;AAAJA,IAAAA,IAAI,GAAAD,WAAA,KAAG,KAAA,CAAA,GAAA,gBAAgB,GAAAA,WAAA;AAAKL,IAAAA,IAAI,GAAAC,iDAAA,CAAKL,KAAK,EAAAW,UAAA,CAAA,CAAA;AAClD,EAAA,oBAAOjB,KAAA,CAAAC,aAAA,CAACiB,0BAAY,EAAAJ,iCAAA,CAAA;AAACP,IAAAA,GAAG,EAAEA,GAAI;AAACS,IAAAA,IAAI,EAAEA,IAAAA;GAAUN,EAAAA,IAAI,CAAG,CAAC,CAAA;AAC3D,CAAC;;;;"}
1
+ {"version":3,"file":"AttachButton.js","sources":["../../../../../src/components/Attach/components/AttachButton/AttachButton.tsx"],"sourcesContent":["import React, { forwardRef } from 'react';\n\nimport { AttachButtonProps } from '../../Attach.types';\nimport { StyledIconButton } from '../../ui/IconButton/IconButton';\nimport { StyledButton } from '../../ui/Button/Button';\nimport { IconPlus } from '../../../_Icon';\n\nconst getDefaultIcon = (size?: string) => {\n let iconSize: 'xs' | 's' | 'm';\n switch (size) {\n case 'xs':\n iconSize = 'xs';\n break;\n case 's':\n iconSize = 's';\n break;\n default:\n iconSize = 'm';\n }\n return <IconPlus size={iconSize} color=\"inherit\" />;\n};\n\nexport const AttachButton = forwardRef<HTMLButtonElement, AttachButtonProps>((props, ref) => {\n if (props.buttonType === 'iconButton') {\n const { size, icon, ...rest } = props;\n\n return (\n <StyledIconButton ref={ref} {...rest}>\n {icon || getDefaultIcon(size)}\n </StyledIconButton>\n );\n }\n\n const { text = 'Загрузить файл', ...rest } = props;\n return <StyledButton ref={ref} text={text} {...rest} />;\n});\n"],"names":["getDefaultIcon","size","iconSize","React","createElement","IconPlus","color","AttachButton","forwardRef","props","ref","buttonType","icon","rest","_objectWithoutProperties","_excluded","StyledIconButton","_extends","_props$text","text","_excluded2","StyledButton"],"mappings":";;;;;;;;;;;;AAOA,IAAMA,cAAc,GAAG,SAAjBA,cAAcA,CAAIC,IAAa,EAAK;AACtC,EAAA,IAAIC,QAA0B,CAAA;AAC9B,EAAA,QAAQD,IAAI;AACR,IAAA,KAAK,IAAI;AACLC,MAAAA,QAAQ,GAAG,IAAI,CAAA;AACf,MAAA,MAAA;AACJ,IAAA,KAAK,GAAG;AACJA,MAAAA,QAAQ,GAAG,GAAG,CAAA;AACd,MAAA,MAAA;AACJ,IAAA;AACIA,MAAAA,QAAQ,GAAG,GAAG,CAAA;AACtB,GAAA;AACA,EAAA,oBAAOC,KAAA,CAAAC,aAAA,CAACC,iBAAQ,EAAA;AAACJ,IAAAA,IAAI,EAAEC,QAAS;AAACI,IAAAA,KAAK,EAAC,SAAA;AAAS,GAAE,CAAC,CAAA;AACvD,CAAC,CAAA;AAEM,IAAMC,YAAY,gBAAGC,gBAAU,CAAuC,UAACC,KAAK,EAAEC,GAAG,EAAK;AACzF,EAAA,IAAID,KAAK,CAACE,UAAU,KAAK,YAAY,EAAE;AACnC,IAAA,IAAQV,IAAI,GAAoBQ,KAAK,CAA7BR,IAAI;MAAEW,IAAI,GAAcH,KAAK,CAAvBG,IAAI;AAAKC,MAAAA,KAAI,GAAAC,iDAAA,CAAKL,KAAK,EAAAM,SAAA,CAAA,CAAA;AAErC,IAAA,oBACIZ,KAAA,CAAAC,aAAA,CAACY,kCAAgB,EAAAC,iCAAA,CAAA;AAACP,MAAAA,GAAG,EAAEA,GAAAA;KAASG,EAAAA,KAAI,GAC/BD,IAAI,IAAIZ,cAAc,CAACC,IAAI,CACd,CAAC,CAAA;AAE3B,GAAA;AAEA,EAAA,IAAAiB,WAAA,GAA6CT,KAAK,CAA1CU,IAAI;AAAJA,IAAAA,IAAI,GAAAD,WAAA,KAAG,KAAA,CAAA,GAAA,gBAAgB,GAAAA,WAAA;AAAKL,IAAAA,IAAI,GAAAC,iDAAA,CAAKL,KAAK,EAAAW,UAAA,CAAA,CAAA;AAClD,EAAA,oBAAOjB,KAAA,CAAAC,aAAA,CAACiB,0BAAY,EAAAJ,iCAAA,CAAA;AAACP,IAAAA,GAAG,EAAEA,GAAI;AAACS,IAAAA,IAAI,EAAEA,IAAAA;GAAUN,EAAAA,IAAI,CAAG,CAAC,CAAA;AAC3D,CAAC;;;;"}
@@ -4,7 +4,6 @@ import './Button.styles_bj69th.css';
4
4
  Object.defineProperty(exports, '__esModule', { value: true });
5
5
 
6
6
  var react = require('@linaria/react');
7
- require('@linaria/core');
8
7
  var common = require('../../../../engines/common.js');
9
8
  var Button$1 = require('../../../Button/Button.js');
10
9
 
@@ -1 +1 @@
1
- {"version":3,"file":"Button.styles.js","sources":["../../../../../src/components/Attach/ui/Button/Button.styles.tsx"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { component, mergeConfig } from '../../../../engines';\nimport { buttonConfig, buttonTokens } from '../../../Button';\nimport { tokens as attachTokens } from '../../Attach.tokens';\n\nconst mergedConfig = mergeConfig(buttonConfig);\nconst Button = component(mergedConfig);\n\nexport const StyledButton = styled(Button)`\n ${buttonTokens.buttonColor}: var(${attachTokens.buttonColor});\n ${buttonTokens.buttonValueColor}: var(${attachTokens.buttonValueColor});\n ${buttonTokens.buttonBackgroundColor}: var(${attachTokens.buttonBackgroundColor});\n ${buttonTokens.buttonColorHover}: var(${attachTokens.buttonColorHover});\n ${buttonTokens.buttonBackgroundColorHover}: var(${attachTokens.buttonBackgroundColorHover});\n ${buttonTokens.buttonColorActive}: var(${attachTokens.buttonColorActive});\n ${buttonTokens.buttonBackgroundColorActive}: var(${attachTokens.buttonBackgroundColorActive});\n ${buttonTokens.buttonLoadingBackgroundColor}: var(${attachTokens.buttonLoadingBackgroundColor});\n\n ${buttonTokens.buttonScaleHover}: var(${attachTokens.buttonScaleHover});\n ${buttonTokens.buttonScaleActive}: var(${attachTokens.buttonScaleActive});\n ${buttonTokens.buttonHeight}: var(${attachTokens.buttonHeight});\n ${buttonTokens.buttonWidth}: var(${attachTokens.buttonWidth});\n ${buttonTokens.buttonPadding}: var(${attachTokens.buttonPadding});\n ${buttonTokens.buttonRadius}: var(${attachTokens.buttonRadius});\n ${buttonTokens.buttonRadiusCircle}: var(${attachTokens.buttonRadiusCircle});\n\n ${buttonTokens.buttonFontFamily}: var(${attachTokens.buttonFontFamily});\n ${buttonTokens.buttonFontSize}: var(${attachTokens.buttonFontSize});\n ${buttonTokens.buttonFontStyle}: var(${attachTokens.buttonFontStyle});\n ${buttonTokens.buttonFontWeight}: var(${attachTokens.buttonFontWeight});\n ${buttonTokens.buttonLetterSpacing}: var(${attachTokens.buttonLetterSpacing});\n ${buttonTokens.buttonLineHeight}: var(${attachTokens.buttonLineHeight});\n\n ${buttonTokens.buttonLeftContentMargin}: var(${attachTokens.buttonLeftContentMargin});\n ${buttonTokens.buttonLeftContentAlignSelf}: var(${attachTokens.buttonLeftContentAlignSelf});\n ${buttonTokens.buttonRightContentMargin}: var(${attachTokens.buttonRightContentMargin});\n ${buttonTokens.buttonRightContentAlignSelf}: var(${attachTokens.buttonRightContentAlignSelf});\n ${buttonTokens.buttonValueMargin}: var(${attachTokens.buttonValueMargin});\n\n ${buttonTokens.buttonDisabledOpacity}: var(${attachTokens.buttonDisabledOpacity});\n ${buttonTokens.buttonFocusColor}: var(${attachTokens.buttonFocusColor});\n\n ${buttonTokens.buttonSpinnerColor}: var(${attachTokens.buttonSpinnerColor});\n ${buttonTokens.buttonSpinnerSize}: var(${attachTokens.buttonSpinnerSize});\n`;\n"],"names":["mergedConfig","mergeConfig","buttonConfig","Button","component","_exp","StyledButton","styled","name","class","propsAsIs"],"mappings":";;;;;;;;;AAMA,IAAMA,YAAY,gBAAGC,kBAAW,CAACC,qBAAY,CAAC,CAAA;AAC9C,IAAMC,MAAM,gBAAGC,gBAAS,CAACJ,YAAY,CAAC,CAAA;AAAC,IAAAK,IAAA,GANrBA,SAMqBA,IAAAA,GAAA;AAAA,EAAA,OAEJF,MAAM,CAAA;AAAA,CAAA,CAAA;AAAlC,IAAMG,YAAY,gBAAGC,YAAM,CAAAF,IAAA,EAAA,CAAA,CAAA;AAAAG,EAAAA,IAAA,EAAA,cAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CAoCjC;;;;"}
1
+ {"version":3,"file":"Button.styles.js","sources":["../../../../../src/components/Attach/ui/Button/Button.styles.tsx"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { component, mergeConfig } from '../../../../engines';\nimport { buttonConfig, buttonTokens } from '../../../Button';\nimport { tokens as attachTokens } from '../../Attach.tokens';\n\nconst mergedConfig = mergeConfig(buttonConfig);\nconst Button = component(mergedConfig);\n\nexport const StyledButton = styled(Button)`\n ${buttonTokens.buttonColor}: var(${attachTokens.buttonColor});\n ${buttonTokens.buttonValueColor}: var(${attachTokens.buttonValueColor});\n ${buttonTokens.buttonBackgroundColor}: var(${attachTokens.buttonBackgroundColor});\n ${buttonTokens.buttonColorHover}: var(${attachTokens.buttonColorHover});\n ${buttonTokens.buttonBackgroundColorHover}: var(${attachTokens.buttonBackgroundColorHover});\n ${buttonTokens.buttonColorActive}: var(${attachTokens.buttonColorActive});\n ${buttonTokens.buttonBackgroundColorActive}: var(${attachTokens.buttonBackgroundColorActive});\n ${buttonTokens.buttonLoadingBackgroundColor}: var(${attachTokens.buttonLoadingBackgroundColor});\n\n ${buttonTokens.buttonScaleHover}: var(${attachTokens.buttonScaleHover});\n ${buttonTokens.buttonScaleActive}: var(${attachTokens.buttonScaleActive});\n ${buttonTokens.buttonHeight}: var(${attachTokens.buttonHeight});\n ${buttonTokens.buttonWidth}: var(${attachTokens.buttonWidth});\n ${buttonTokens.buttonPadding}: var(${attachTokens.buttonPadding});\n ${buttonTokens.buttonRadius}: var(${attachTokens.buttonRadius});\n ${buttonTokens.buttonRadiusCircle}: var(${attachTokens.buttonRadiusCircle});\n\n ${buttonTokens.buttonFontFamily}: var(${attachTokens.buttonFontFamily});\n ${buttonTokens.buttonFontSize}: var(${attachTokens.buttonFontSize});\n ${buttonTokens.buttonFontStyle}: var(${attachTokens.buttonFontStyle});\n ${buttonTokens.buttonFontWeight}: var(${attachTokens.buttonFontWeight});\n ${buttonTokens.buttonLetterSpacing}: var(${attachTokens.buttonLetterSpacing});\n ${buttonTokens.buttonLineHeight}: var(${attachTokens.buttonLineHeight});\n\n ${buttonTokens.buttonLeftContentMargin}: var(${attachTokens.buttonLeftContentMargin});\n ${buttonTokens.buttonLeftContentAlignSelf}: var(${attachTokens.buttonLeftContentAlignSelf});\n ${buttonTokens.buttonRightContentMargin}: var(${attachTokens.buttonRightContentMargin});\n ${buttonTokens.buttonRightContentAlignSelf}: var(${attachTokens.buttonRightContentAlignSelf});\n ${buttonTokens.buttonValueMargin}: var(${attachTokens.buttonValueMargin});\n\n ${buttonTokens.buttonDisabledOpacity}: var(${attachTokens.buttonDisabledOpacity});\n ${buttonTokens.buttonFocusColor}: var(${attachTokens.buttonFocusColor});\n\n ${buttonTokens.buttonSpinnerColor}: var(${attachTokens.buttonSpinnerColor});\n ${buttonTokens.buttonSpinnerSize}: var(${attachTokens.buttonSpinnerSize});\n`;\n"],"names":["mergedConfig","mergeConfig","buttonConfig","Button","component","_exp","StyledButton","styled","name","class","propsAsIs"],"mappings":";;;;;;;;AAMA,IAAMA,YAAY,gBAAGC,kBAAW,CAACC,qBAAY,CAAC,CAAA;AAC9C,IAAMC,MAAM,gBAAGC,gBAAS,CAACJ,YAAY,CAAC,CAAA;AAAC,IAAAK,IAAA,GANrBA,SAMqBA,IAAAA,GAAA;AAAA,EAAA,OAEJF,MAAM,CAAA;AAAA,CAAA,CAAA;AAAlC,IAAMG,YAAY,gBAAGC,YAAM,CAAAF,IAAA,EAAA,CAAA,CAAA;AAAAG,EAAAA,IAAA,EAAA,cAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CAoCjC;;;;"}
@@ -4,9 +4,7 @@ import './Cell.styles_69w962.css';
4
4
  Object.defineProperty(exports, '__esModule', { value: true });
5
5
 
6
6
  var react = require('@linaria/react');
7
- require('@linaria/core');
8
7
  var common = require('../../../../engines/common.js');
9
- require('react');
10
8
  var Cell$1 = require('../../../Cell/Cell.js');
11
9
 
12
10
  var mergedConfig = /*#__PURE__*/common.mergeConfig(Cell$1.cellConfig);
@@ -1 +1 @@
1
- {"version":3,"file":"Cell.styles.js","sources":["../../../../../src/components/Attach/ui/Cell/Cell.styles.tsx"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { component, mergeConfig } from '../../../../engines';\nimport { cellConfig, cellTokens } from '../../../Cell';\nimport { tokens as attachTokens, classes } from '../../Attach.tokens';\n\nconst mergedConfig = mergeConfig(cellConfig);\nconst Cell = component(mergedConfig);\n\nexport const StyledCell = styled(Cell)`\n ${cellTokens.cellLabelColor}: var(${attachTokens.cellLabelColor});\n ${cellTokens.cellTitleColor}: var(${attachTokens.cellTitleColor});\n ${cellTokens.cellSubtitleColor}: var(${attachTokens.cellSubtitleColor});\n ${cellTokens.cellBackgroundColor}: var(${attachTokens.cellBackgroundColor});\n\n ${cellTokens.cellWidth}: var(${attachTokens.cellWidth});\n ${cellTokens.cellPadding}: var(${attachTokens.cellPadding});\n ${cellTokens.cellPaddingLeftContent}: var(${attachTokens.cellPaddingLeftContent});\n ${cellTokens.cellPaddingContent}: var(${attachTokens.cellPaddingContent});\n ${cellTokens.cellPaddingRightContent}: var(${attachTokens.cellPaddingRightContent});\n\n ${cellTokens.cellTextboxGap}: var(${attachTokens.cellTextboxGap});\n ${cellTokens.cellGap}: var(${attachTokens.cellGap});\n\n ${cellTokens.cellLabelFontFamily}: var(${attachTokens.cellLabelFontFamily});\n ${cellTokens.cellLabelFontSize}: var(${attachTokens.cellLabelFontSize});\n ${cellTokens.cellLabelFontStyle}: var(${attachTokens.cellLabelFontStyle});\n ${cellTokens.cellLabelFontWeight}: var(${attachTokens.cellLabelFontWeight});\n ${cellTokens.cellLabelLetterSpacing}: var(${attachTokens.cellLabelLetterSpacing});\n ${cellTokens.cellLabelLineHeight}: var(${attachTokens.cellLabelLineHeight});\n\n ${cellTokens.cellTitleFontFamily}: var(${attachTokens.cellTitleFontFamily});\n ${cellTokens.cellTitleFontSize}: var(${attachTokens.cellTitleFontSize});\n ${cellTokens.cellTitleFontStyle}: var(${attachTokens.cellTitleFontStyle});\n ${cellTokens.cellTitleFontWeight}: var(${attachTokens.cellTitleFontWeight});\n ${cellTokens.cellTitleLetterSpacing}: var(${attachTokens.cellTitleLetterSpacing});\n ${cellTokens.cellTitleLineHeight}: var(${attachTokens.cellTitleLineHeight});\n\n ${cellTokens.cellSubtitleFontFamily}: var(${attachTokens.cellSubtitleFontFamily});\n ${cellTokens.cellSubtitleFontSize}: var(${attachTokens.cellSubtitleFontSize});\n ${cellTokens.cellSubtitleFontStyle}: var(${attachTokens.cellSubtitleFontStyle});\n ${cellTokens.cellSubtitleFontWeight}: var(${attachTokens.cellSubtitleFontWeight});\n ${cellTokens.cellSubtitleLetterSpacing}: var(${attachTokens.cellSubtitleLetterSpacing});\n ${cellTokens.cellSubtitleLineHeight}: var(${attachTokens.cellSubtitleLineHeight});\n\n white-space: nowrap;\n\n &.${classes.cellHidden} {\n visibility: hidden;\n }\n`;\n"],"names":["mergedConfig","mergeConfig","cellConfig","Cell","component","_exp","StyledCell","styled","name","class","propsAsIs"],"mappings":";;;;;;;;;;AAMA,IAAMA,YAAY,gBAAGC,kBAAW,CAACC,iBAAU,CAAC,CAAA;AAC5C,IAAMC,IAAI,gBAAGC,gBAAS,CAACJ,YAAY,CAAC,CAAA;AAAC,IAAAK,IAAA,GANnBA,SAMmBA,IAAAA,GAAA;AAAA,EAAA,OAEJF,IAAI,CAAA;AAAA,CAAA,CAAA;AAA9B,IAAMG,UAAU,gBAAGC,YAAM,CAAAF,IAAA,EAAA,CAAA,CAAA;AAAAG,EAAAA,IAAA,EAAA,YAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CAyC/B;;;;"}
1
+ {"version":3,"file":"Cell.styles.js","sources":["../../../../../src/components/Attach/ui/Cell/Cell.styles.tsx"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { component, mergeConfig } from '../../../../engines';\nimport { cellConfig, cellTokens } from '../../../Cell';\nimport { tokens as attachTokens, classes } from '../../Attach.tokens';\n\nconst mergedConfig = mergeConfig(cellConfig);\nconst Cell = component(mergedConfig);\n\nexport const StyledCell = styled(Cell)`\n ${cellTokens.cellLabelColor}: var(${attachTokens.cellLabelColor});\n ${cellTokens.cellTitleColor}: var(${attachTokens.cellTitleColor});\n ${cellTokens.cellSubtitleColor}: var(${attachTokens.cellSubtitleColor});\n ${cellTokens.cellBackgroundColor}: var(${attachTokens.cellBackgroundColor});\n\n ${cellTokens.cellWidth}: var(${attachTokens.cellWidth});\n ${cellTokens.cellPadding}: var(${attachTokens.cellPadding});\n ${cellTokens.cellPaddingLeftContent}: var(${attachTokens.cellPaddingLeftContent});\n ${cellTokens.cellPaddingContent}: var(${attachTokens.cellPaddingContent});\n ${cellTokens.cellPaddingRightContent}: var(${attachTokens.cellPaddingRightContent});\n\n ${cellTokens.cellTextboxGap}: var(${attachTokens.cellTextboxGap});\n ${cellTokens.cellGap}: var(${attachTokens.cellGap});\n\n ${cellTokens.cellLabelFontFamily}: var(${attachTokens.cellLabelFontFamily});\n ${cellTokens.cellLabelFontSize}: var(${attachTokens.cellLabelFontSize});\n ${cellTokens.cellLabelFontStyle}: var(${attachTokens.cellLabelFontStyle});\n ${cellTokens.cellLabelFontWeight}: var(${attachTokens.cellLabelFontWeight});\n ${cellTokens.cellLabelLetterSpacing}: var(${attachTokens.cellLabelLetterSpacing});\n ${cellTokens.cellLabelLineHeight}: var(${attachTokens.cellLabelLineHeight});\n\n ${cellTokens.cellTitleFontFamily}: var(${attachTokens.cellTitleFontFamily});\n ${cellTokens.cellTitleFontSize}: var(${attachTokens.cellTitleFontSize});\n ${cellTokens.cellTitleFontStyle}: var(${attachTokens.cellTitleFontStyle});\n ${cellTokens.cellTitleFontWeight}: var(${attachTokens.cellTitleFontWeight});\n ${cellTokens.cellTitleLetterSpacing}: var(${attachTokens.cellTitleLetterSpacing});\n ${cellTokens.cellTitleLineHeight}: var(${attachTokens.cellTitleLineHeight});\n\n ${cellTokens.cellSubtitleFontFamily}: var(${attachTokens.cellSubtitleFontFamily});\n ${cellTokens.cellSubtitleFontSize}: var(${attachTokens.cellSubtitleFontSize});\n ${cellTokens.cellSubtitleFontStyle}: var(${attachTokens.cellSubtitleFontStyle});\n ${cellTokens.cellSubtitleFontWeight}: var(${attachTokens.cellSubtitleFontWeight});\n ${cellTokens.cellSubtitleLetterSpacing}: var(${attachTokens.cellSubtitleLetterSpacing});\n ${cellTokens.cellSubtitleLineHeight}: var(${attachTokens.cellSubtitleLineHeight});\n\n white-space: nowrap;\n\n &.${classes.cellHidden} {\n visibility: hidden;\n }\n`;\n"],"names":["mergedConfig","mergeConfig","cellConfig","Cell","component","_exp","StyledCell","styled","name","class","propsAsIs"],"mappings":";;;;;;;;AAMA,IAAMA,YAAY,gBAAGC,kBAAW,CAACC,iBAAU,CAAC,CAAA;AAC5C,IAAMC,IAAI,gBAAGC,gBAAS,CAACJ,YAAY,CAAC,CAAA;AAAC,IAAAK,IAAA,GANnBA,SAMmBA,IAAAA,GAAA;AAAA,EAAA,OAEJF,IAAI,CAAA;AAAA,CAAA,CAAA;AAA9B,IAAMG,UAAU,gBAAGC,YAAM,CAAAF,IAAA,EAAA,CAAA,CAAA;AAAAG,EAAAA,IAAA,EAAA,YAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CAyC/B;;;;"}
@@ -4,7 +4,6 @@ import './IconButton.styles_1q2jfs2.css';
4
4
  Object.defineProperty(exports, '__esModule', { value: true });
5
5
 
6
6
  var react = require('@linaria/react');
7
- require('@linaria/core');
8
7
  var common = require('../../../../engines/common.js');
9
8
  var IconButton$1 = require('../../../IconButton/IconButton.js');
10
9
 
@@ -1 +1 @@
1
- {"version":3,"file":"IconButton.styles.js","sources":["../../../../../src/components/Attach/ui/IconButton/IconButton.styles.tsx"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { component, mergeConfig } from '../../../../engines';\nimport { iconButtonConfig, iconButtonTokens } from '../../../IconButton';\nimport { tokens as attachTokens } from '../../Attach.tokens';\n\nconst mergedConfig = mergeConfig(iconButtonConfig);\nconst IconButton = component(mergedConfig);\n\nexport const StyledIconButton = styled(IconButton)`\n ${iconButtonTokens.iconButtonColor}: var(${attachTokens.iconButtonColor});\n ${iconButtonTokens.iconButtonBackgroundColor}: var(${attachTokens.iconButtonBackgroundColor});\n ${iconButtonTokens.iconButtonLoadingBackgroundColor}: var(${attachTokens.iconButtonLoadingBackgroundColor});\n ${iconButtonTokens.iconButtonColorHover}: var(${attachTokens.iconButtonColorHover});\n ${iconButtonTokens.iconButtonBackgroundColorHover}: var(${attachTokens.iconButtonBackgroundColorHover});\n ${iconButtonTokens.iconButtonColorActive}: var(${attachTokens.iconButtonColorActive});\n ${iconButtonTokens.iconButtonBackgroundColorActive}: var(${attachTokens.iconButtonBackgroundColorActive});\n\n ${iconButtonTokens.iconButtonScaleHover}: var(${attachTokens.iconButtonScaleHover});\n ${iconButtonTokens.iconButtonScaleActive}: var(${attachTokens.iconButtonScaleActive});\n ${iconButtonTokens.iconButtonHeight}: var(${attachTokens.iconButtonHeight});\n ${iconButtonTokens.iconButtonWidth}: var(${attachTokens.iconButtonWidth});\n ${iconButtonTokens.iconButtonPadding}: var(${attachTokens.iconButtonPadding});\n ${iconButtonTokens.iconButtonRadius}: var(${attachTokens.iconButtonRadius});\n ${iconButtonTokens.iconButtonRadiusCircle}: var(${attachTokens.iconButtonRadiusCircle});\n\n ${iconButtonTokens.iconButtonFontFamily}: var(${attachTokens.iconButtonFontFamily});\n ${iconButtonTokens.iconButtonFontSize}: var(${attachTokens.iconButtonFontSize});\n ${iconButtonTokens.iconButtonFontStyle}: var(${attachTokens.iconButtonFontStyle});\n ${iconButtonTokens.iconButtonFontWeight}: var(${attachTokens.iconButtonFontWeight});\n ${iconButtonTokens.iconButtonLetterSpacing}: var(${attachTokens.iconButtonLetterSpacing});\n ${iconButtonTokens.iconButtonLineHeight}: var(${attachTokens.iconButtonLineHeight});\n\n ${iconButtonTokens.iconButtonDisabledOpacity}: var(${attachTokens.iconButtonDisabledOpacity});\n ${iconButtonTokens.iconButtonFocusColor}: var(${attachTokens.iconButtonFocusColor});\n ${iconButtonTokens.iconButtonSpinnerColor}: var(${attachTokens.iconButtonSpinnerColor});\n ${iconButtonTokens.iconButtonSpinnerSize}: var(${attachTokens.iconButtonSpinnerSize});\n\n flex-shrink: 0;\n`;\n\nexport const StyledIconButtonCancel = styled(IconButton)`\n ${iconButtonTokens.iconButtonColor}: var(${attachTokens.iconButtonCancelColor});\n ${iconButtonTokens.iconButtonBackgroundColor}: var(${attachTokens.iconButtonCancelBackgroundColor});\n ${iconButtonTokens.iconButtonLoadingBackgroundColor}: var(${attachTokens.iconButtonCancelLoadingBackgroundColor});\n ${iconButtonTokens.iconButtonColorHover}: var(${attachTokens.iconButtonCancelColorHover});\n ${iconButtonTokens.iconButtonBackgroundColorHover}: var(${attachTokens.iconButtonCancelBackgroundColorHover});\n ${iconButtonTokens.iconButtonColorActive}: var(${attachTokens.iconButtonCancelColorActive});\n ${iconButtonTokens.iconButtonBackgroundColorActive}: var(${attachTokens.iconButtonCancelBackgroundColorActive});\n\n ${iconButtonTokens.iconButtonScaleHover}: var(${attachTokens.iconButtonCancelScaleHover});\n ${iconButtonTokens.iconButtonScaleActive}: var(${attachTokens.iconButtonCancelScaleActive});\n ${iconButtonTokens.iconButtonHeight}: var(${attachTokens.iconButtonCancelHeight});\n ${iconButtonTokens.iconButtonWidth}: var(${attachTokens.iconButtonCancelWidth});\n ${iconButtonTokens.iconButtonPadding}: var(${attachTokens.iconButtonCancelPadding});\n ${iconButtonTokens.iconButtonRadius}: var(${attachTokens.iconButtonCancelRadius});\n ${iconButtonTokens.iconButtonRadiusCircle}: var(${attachTokens.iconButtonCancelRadiusCircle});\n\n ${iconButtonTokens.iconButtonFontFamily}: var(${attachTokens.iconButtonCancelFontFamily});\n ${iconButtonTokens.iconButtonFontSize}: var(${attachTokens.iconButtonCancelFontSize});\n ${iconButtonTokens.iconButtonFontStyle}: var(${attachTokens.iconButtonCancelFontStyle});\n ${iconButtonTokens.iconButtonFontWeight}: var(${attachTokens.iconButtonCancelFontWeight});\n ${iconButtonTokens.iconButtonLetterSpacing}: var(${attachTokens.iconButtonCancelLetterSpacing});\n ${iconButtonTokens.iconButtonLineHeight}: var(${attachTokens.iconButtonCancelLineHeight});\n\n ${iconButtonTokens.iconButtonDisabledOpacity}: var(${attachTokens.iconButtonCancelDisabledOpacity});\n ${iconButtonTokens.iconButtonFocusColor}: var(${attachTokens.iconButtonCancelFocusColor});\n ${iconButtonTokens.iconButtonSpinnerColor}: var(${attachTokens.iconButtonCancelSpinnerColor});\n ${iconButtonTokens.iconButtonSpinnerSize}: var(${attachTokens.iconButtonCancelSpinnerSize});\n`;\n"],"names":["mergedConfig","mergeConfig","iconButtonConfig","IconButton","component","_exp","StyledIconButton","styled","name","class","propsAsIs","_exp50","StyledIconButtonCancel"],"mappings":";;;;;;;;;AAMA,IAAMA,YAAY,gBAAGC,kBAAW,CAACC,6BAAgB,CAAC,CAAA;AAClD,IAAMC,UAAU,gBAAGC,gBAAS,CAACJ,YAAY,CAAC,CAAA;AAAC,IAAAK,IAAA,GANzBA,SAMyBA,IAAAA,GAAA;AAAA,EAAA,OAEJF,UAAU,CAAA;AAAA,CAAA,CAAA;AAA1C,IAAMG,gBAAgB,gBAAGC,YAAM,CAAAF,IAAA,EAAA,CAAA,CAAA;AAAAG,EAAAA,IAAA,EAAA,kBAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CA8BrC,EAAA;AAAC,IAAAC,MAAA,GAtCgBA,SAsChBA,MAAAA,GAAA;AAAA,EAAA,OAE2CR,UAAU,CAAA;AAAA,CAAA,CAAA;AAAhD,IAAMS,sBAAsB,gBAAGL,YAAM,CAAAI,MAAA,EAAA,CAAA,CAAA;AAAAH,EAAAA,IAAA,EAAA,wBAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CA4B3C;;;;;"}
1
+ {"version":3,"file":"IconButton.styles.js","sources":["../../../../../src/components/Attach/ui/IconButton/IconButton.styles.tsx"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { component, mergeConfig } from '../../../../engines';\nimport { iconButtonConfig, iconButtonTokens } from '../../../IconButton';\nimport { tokens as attachTokens } from '../../Attach.tokens';\n\nconst mergedConfig = mergeConfig(iconButtonConfig);\nconst IconButton = component(mergedConfig);\n\nexport const StyledIconButton = styled(IconButton)`\n ${iconButtonTokens.iconButtonColor}: var(${attachTokens.iconButtonColor});\n ${iconButtonTokens.iconButtonBackgroundColor}: var(${attachTokens.iconButtonBackgroundColor});\n ${iconButtonTokens.iconButtonLoadingBackgroundColor}: var(${attachTokens.iconButtonLoadingBackgroundColor});\n ${iconButtonTokens.iconButtonColorHover}: var(${attachTokens.iconButtonColorHover});\n ${iconButtonTokens.iconButtonBackgroundColorHover}: var(${attachTokens.iconButtonBackgroundColorHover});\n ${iconButtonTokens.iconButtonColorActive}: var(${attachTokens.iconButtonColorActive});\n ${iconButtonTokens.iconButtonBackgroundColorActive}: var(${attachTokens.iconButtonBackgroundColorActive});\n\n ${iconButtonTokens.iconButtonScaleHover}: var(${attachTokens.iconButtonScaleHover});\n ${iconButtonTokens.iconButtonScaleActive}: var(${attachTokens.iconButtonScaleActive});\n ${iconButtonTokens.iconButtonHeight}: var(${attachTokens.iconButtonHeight});\n ${iconButtonTokens.iconButtonWidth}: var(${attachTokens.iconButtonWidth});\n ${iconButtonTokens.iconButtonPadding}: var(${attachTokens.iconButtonPadding});\n ${iconButtonTokens.iconButtonRadius}: var(${attachTokens.iconButtonRadius});\n ${iconButtonTokens.iconButtonRadiusCircle}: var(${attachTokens.iconButtonRadiusCircle});\n\n ${iconButtonTokens.iconButtonFontFamily}: var(${attachTokens.iconButtonFontFamily});\n ${iconButtonTokens.iconButtonFontSize}: var(${attachTokens.iconButtonFontSize});\n ${iconButtonTokens.iconButtonFontStyle}: var(${attachTokens.iconButtonFontStyle});\n ${iconButtonTokens.iconButtonFontWeight}: var(${attachTokens.iconButtonFontWeight});\n ${iconButtonTokens.iconButtonLetterSpacing}: var(${attachTokens.iconButtonLetterSpacing});\n ${iconButtonTokens.iconButtonLineHeight}: var(${attachTokens.iconButtonLineHeight});\n\n ${iconButtonTokens.iconButtonDisabledOpacity}: var(${attachTokens.iconButtonDisabledOpacity});\n ${iconButtonTokens.iconButtonFocusColor}: var(${attachTokens.iconButtonFocusColor});\n ${iconButtonTokens.iconButtonSpinnerColor}: var(${attachTokens.iconButtonSpinnerColor});\n ${iconButtonTokens.iconButtonSpinnerSize}: var(${attachTokens.iconButtonSpinnerSize});\n\n flex-shrink: 0;\n`;\n\nexport const StyledIconButtonCancel = styled(IconButton)`\n ${iconButtonTokens.iconButtonColor}: var(${attachTokens.iconButtonCancelColor});\n ${iconButtonTokens.iconButtonBackgroundColor}: var(${attachTokens.iconButtonCancelBackgroundColor});\n ${iconButtonTokens.iconButtonLoadingBackgroundColor}: var(${attachTokens.iconButtonCancelLoadingBackgroundColor});\n ${iconButtonTokens.iconButtonColorHover}: var(${attachTokens.iconButtonCancelColorHover});\n ${iconButtonTokens.iconButtonBackgroundColorHover}: var(${attachTokens.iconButtonCancelBackgroundColorHover});\n ${iconButtonTokens.iconButtonColorActive}: var(${attachTokens.iconButtonCancelColorActive});\n ${iconButtonTokens.iconButtonBackgroundColorActive}: var(${attachTokens.iconButtonCancelBackgroundColorActive});\n\n ${iconButtonTokens.iconButtonScaleHover}: var(${attachTokens.iconButtonCancelScaleHover});\n ${iconButtonTokens.iconButtonScaleActive}: var(${attachTokens.iconButtonCancelScaleActive});\n ${iconButtonTokens.iconButtonHeight}: var(${attachTokens.iconButtonCancelHeight});\n ${iconButtonTokens.iconButtonWidth}: var(${attachTokens.iconButtonCancelWidth});\n ${iconButtonTokens.iconButtonPadding}: var(${attachTokens.iconButtonCancelPadding});\n ${iconButtonTokens.iconButtonRadius}: var(${attachTokens.iconButtonCancelRadius});\n ${iconButtonTokens.iconButtonRadiusCircle}: var(${attachTokens.iconButtonCancelRadiusCircle});\n\n ${iconButtonTokens.iconButtonFontFamily}: var(${attachTokens.iconButtonCancelFontFamily});\n ${iconButtonTokens.iconButtonFontSize}: var(${attachTokens.iconButtonCancelFontSize});\n ${iconButtonTokens.iconButtonFontStyle}: var(${attachTokens.iconButtonCancelFontStyle});\n ${iconButtonTokens.iconButtonFontWeight}: var(${attachTokens.iconButtonCancelFontWeight});\n ${iconButtonTokens.iconButtonLetterSpacing}: var(${attachTokens.iconButtonCancelLetterSpacing});\n ${iconButtonTokens.iconButtonLineHeight}: var(${attachTokens.iconButtonCancelLineHeight});\n\n ${iconButtonTokens.iconButtonDisabledOpacity}: var(${attachTokens.iconButtonCancelDisabledOpacity});\n ${iconButtonTokens.iconButtonFocusColor}: var(${attachTokens.iconButtonCancelFocusColor});\n ${iconButtonTokens.iconButtonSpinnerColor}: var(${attachTokens.iconButtonCancelSpinnerColor});\n ${iconButtonTokens.iconButtonSpinnerSize}: var(${attachTokens.iconButtonCancelSpinnerSize});\n`;\n"],"names":["mergedConfig","mergeConfig","iconButtonConfig","IconButton","component","_exp","StyledIconButton","styled","name","class","propsAsIs","_exp50","StyledIconButtonCancel"],"mappings":";;;;;;;;AAMA,IAAMA,YAAY,gBAAGC,kBAAW,CAACC,6BAAgB,CAAC,CAAA;AAClD,IAAMC,UAAU,gBAAGC,gBAAS,CAACJ,YAAY,CAAC,CAAA;AAAC,IAAAK,IAAA,GANzBA,SAMyBA,IAAAA,GAAA;AAAA,EAAA,OAEJF,UAAU,CAAA;AAAA,CAAA,CAAA;AAA1C,IAAMG,gBAAgB,gBAAGC,YAAM,CAAAF,IAAA,EAAA,CAAA,CAAA;AAAAG,EAAAA,IAAA,EAAA,kBAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CA8BrC,EAAA;AAAC,IAAAC,MAAA,GAtCgBA,SAsChBA,MAAAA,GAAA;AAAA,EAAA,OAE2CR,UAAU,CAAA;AAAA,CAAA,CAAA;AAAhD,IAAMS,sBAAsB,gBAAGL,YAAM,CAAAI,MAAA,EAAA,CAAA,CAAA;AAAAH,EAAAA,IAAA,EAAA,wBAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CA4B3C;;;;;"}
@@ -3,13 +3,12 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var React = require('react');
6
- require('@linaria/react');
7
- var IconBlankCsvOutline = require('../../_Icon/Icons/IconBlankCsvOutline.js');
8
- var IconBlankDocOutline = require('../../_Icon/Icons/IconBlankDocOutline.js');
9
6
  var IconBlankOutline = require('../../_Icon/Icons/IconBlankOutline.js');
10
- var IconBlankPdfOutline = require('../../_Icon/Icons/IconBlankPdfOutline.js');
7
+ var IconBlankCsvOutline = require('../../_Icon/Icons/IconBlankCsvOutline.js');
11
8
  var IconBlankTxtOutline = require('../../_Icon/Icons/IconBlankTxtOutline.js');
12
9
  var IconBlankXlsOutline = require('../../_Icon/Icons/IconBlankXlsOutline.js');
10
+ var IconBlankDocOutline = require('../../_Icon/Icons/IconBlankDocOutline.js');
11
+ var IconBlankPdfOutline = require('../../_Icon/Icons/IconBlankPdfOutline.js');
13
12
 
14
13
  var getFileicon = function getFileicon(extension, size) {
15
14
  var iconSize = size === 'xs' ? 'xs' : 's';
@@ -1 +1 @@
1
- {"version":3,"file":"getFileicon.js","sources":["../../../../src/components/Attach/utils/getFileicon.tsx"],"sourcesContent":["import React from 'react';\n\nimport {\n IconBlankCsvOutline,\n IconBlankDocOutline,\n IconBlankOutline,\n IconBlankPdfOutline,\n IconBlankTxtOutline,\n IconBlankXlsOutline,\n} from '../../_Icon';\n\nexport const getFileicon = (extension?: string, size?: string) => {\n const iconSize = size === 'xs' ? 'xs' : 's';\n\n switch (extension) {\n case 'pdf':\n return <IconBlankPdfOutline size={iconSize} color=\"inherit\" />;\n case 'doc':\n return <IconBlankDocOutline size={iconSize} color=\"inherit\" />;\n case 'xls':\n return <IconBlankXlsOutline size={iconSize} color=\"inherit\" />;\n case 'txt':\n return <IconBlankTxtOutline size={iconSize} color=\"inherit\" />;\n case 'csv':\n return <IconBlankCsvOutline size={iconSize} color=\"inherit\" />;\n default:\n return <IconBlankOutline size={iconSize} color=\"inherit\" />;\n }\n};\n"],"names":["getFileicon","extension","size","iconSize","React","createElement","IconBlankPdfOutline","color","IconBlankDocOutline","IconBlankXlsOutline","IconBlankTxtOutline","IconBlankCsvOutline","IconBlankOutline"],"mappings":";;;;;;;;;;;;;AAWO,IAAMA,WAAW,GAAG,SAAdA,WAAWA,CAAIC,SAAkB,EAAEC,IAAa,EAAK;EAC9D,IAAMC,QAAQ,GAAGD,IAAI,KAAK,IAAI,GAAG,IAAI,GAAG,GAAG,CAAA;AAE3C,EAAA,QAAQD,SAAS;AACb,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOG,KAAA,CAAAC,aAAA,CAACC,uCAAmB,EAAA;AAACJ,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACG,uCAAmB,EAAA;AAACN,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACI,uCAAmB,EAAA;AAACP,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACK,uCAAmB,EAAA;AAACR,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACM,uCAAmB,EAAA;AAACT,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA;AACI,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACO,iCAAgB,EAAA;AAACV,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AACnE,GAAA;AACJ;;;;"}
1
+ {"version":3,"file":"getFileicon.js","sources":["../../../../src/components/Attach/utils/getFileicon.tsx"],"sourcesContent":["import React from 'react';\n\nimport {\n IconBlankCsvOutline,\n IconBlankDocOutline,\n IconBlankOutline,\n IconBlankPdfOutline,\n IconBlankTxtOutline,\n IconBlankXlsOutline,\n} from '../../_Icon';\n\nexport const getFileicon = (extension?: string, size?: string) => {\n const iconSize = size === 'xs' ? 'xs' : 's';\n\n switch (extension) {\n case 'pdf':\n return <IconBlankPdfOutline size={iconSize} color=\"inherit\" />;\n case 'doc':\n return <IconBlankDocOutline size={iconSize} color=\"inherit\" />;\n case 'xls':\n return <IconBlankXlsOutline size={iconSize} color=\"inherit\" />;\n case 'txt':\n return <IconBlankTxtOutline size={iconSize} color=\"inherit\" />;\n case 'csv':\n return <IconBlankCsvOutline size={iconSize} color=\"inherit\" />;\n default:\n return <IconBlankOutline size={iconSize} color=\"inherit\" />;\n }\n};\n"],"names":["getFileicon","extension","size","iconSize","React","createElement","IconBlankPdfOutline","color","IconBlankDocOutline","IconBlankXlsOutline","IconBlankTxtOutline","IconBlankCsvOutline","IconBlankOutline"],"mappings":";;;;;;;;;;;;AAWO,IAAMA,WAAW,GAAG,SAAdA,WAAWA,CAAIC,SAAkB,EAAEC,IAAa,EAAK;EAC9D,IAAMC,QAAQ,GAAGD,IAAI,KAAK,IAAI,GAAG,IAAI,GAAG,GAAG,CAAA;AAE3C,EAAA,QAAQD,SAAS;AACb,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOG,KAAA,CAAAC,aAAA,CAACC,uCAAmB,EAAA;AAACJ,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACG,uCAAmB,EAAA;AAACN,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACI,uCAAmB,EAAA;AAACP,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACK,uCAAmB,EAAA;AAACR,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA,KAAK,KAAK;AACN,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACM,uCAAmB,EAAA;AAACT,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AAClE,IAAA;AACI,MAAA,oBAAOH,KAAA,CAAAC,aAAA,CAACO,iCAAgB,EAAA;AAACV,QAAAA,IAAI,EAAEC,QAAS;AAACI,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAAA;AACnE,GAAA;AACJ;;;;"}
@@ -2,9 +2,6 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- require('react');
6
- require('@linaria/react');
7
-
8
5
  var separator = '...';
9
6
 
10
7
  exports.separator = separator;
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sources":["../../../../src/components/Attach/utils/index.ts"],"sourcesContent":["export { extractExtension } from './extractExtension';\nexport { getFileicon } from './getFileicon';\nexport { addSeparator } from './addSeparator';\n\nexport const separator = '...';\n"],"names":["separator"],"mappings":";;;;;;;AAIO,IAAMA,SAAS,GAAG;;;;"}
1
+ {"version":3,"file":"index.js","sources":["../../../../src/components/Attach/utils/index.ts"],"sourcesContent":["export { extractExtension } from './extractExtension';\nexport { getFileicon } from './getFileicon';\nexport { addSeparator } from './addSeparator';\n\nexport const separator = '...';\n"],"names":["separator"],"mappings":";;;;AAIO,IAAMA,SAAS,GAAG;;;;"}
@@ -5,15 +5,14 @@ Object.defineProperty(exports, '__esModule', { value: true });
5
5
  var _rollupPluginBabelHelpers = require('../../_virtual/_rollupPluginBabelHelpers.js');
6
6
  var React = require('react');
7
7
  var plasmaCore = require('@salutejs/plasma-core');
8
- var useDidMountEffect = require('../../hooks/useDidMountEffect.js');
9
- var useOutsideClick = require('../../hooks/useOutsideClick.js');
10
- require('../../utils/react.js');
11
- var getPopoverPlacement = require('../../utils/getPopoverPlacement.js');
12
8
  var focusedReducer = require('./reducers/focusedReducer.js');
13
- var TextField_styles = require('./ui/TextField/TextField.styles.js');
14
- var SuggestionItem = require('./ui/SuggestionItem/SuggestionItem.js');
15
9
  var Autocomplete_styles = require('./Autocomplete.styles.js');
16
10
  var useKeyboardNavigation = require('./hooks/useKeyboardNavigation.js');
11
+ var useOutsideClick = require('../../hooks/useOutsideClick.js');
12
+ var useDidMountEffect = require('../../hooks/useDidMountEffect.js');
13
+ var TextField_styles = require('./ui/TextField/TextField.styles.js');
14
+ var SuggestionItem = require('./ui/SuggestionItem/SuggestionItem.js');
15
+ var getPopoverPlacement = require('../../utils/getPopoverPlacement.js');
17
16
 
18
17
  var _excluded = ["value", "onChange", "suggestions", "view", "size", "labelPlacement", "disabled", "readOnly", "label", "leftHelper", "contentLeft", "contentRight", "textBefore", "textAfter", "onScroll", "listMaxHeight", "listWidth", "portal", "filter", "onSuggestionSelect", "threshold", "renderList", "renderListEnd", "onSearch", "hintText"];
19
18
 
@@ -1 +1 @@
1
- {"version":3,"file":"Autocomplete.js","sources":["../../../src/components/Autocomplete/Autocomplete.tsx"],"sourcesContent":["import React, { forwardRef, useState, useReducer } from 'react';\nimport { safeUseId } from '@salutejs/plasma-core';\n\nimport { useDidMountEffect, useOutsideClick } from '../../hooks';\nimport { RootProps } from '../../engines';\nimport { getPlacements } from '../../utils';\n\nimport { focusedReducer } from './reducers/focusedReducer';\nimport { SuggestionItem, StyledTextField } from './ui';\nimport { StyledPopover, Ul, LeftHelper, base, InfiniteLoaderWrapper } from './Autocomplete.styles';\nimport type { AutocompleteProps, SuggestionItemType } from './Autocomplete.types';\nimport { useKeyNavigation } from './hooks/useKeyboardNavigation';\n\n/**\n * Компонент Autocomplete. Поле ввода с подсказками в выпадающем списке.\n */\nexport const autocompleteRoot = (Root: RootProps<HTMLInputElement, AutocompleteProps>) =>\n forwardRef<HTMLInputElement, AutocompleteProps>(\n (\n {\n value: outerValue,\n onChange,\n suggestions,\n view,\n size,\n labelPlacement,\n disabled,\n readOnly,\n label,\n leftHelper,\n contentLeft,\n contentRight,\n textBefore,\n textAfter,\n onScroll,\n listMaxHeight,\n listWidth,\n portal,\n filter,\n onSuggestionSelect,\n threshold = 2,\n renderList,\n renderListEnd,\n onSearch,\n\n hintText,\n\n ...rest\n },\n ref,\n ) => {\n const [focused, dispatchFocused] = useReducer(focusedReducer, null);\n const [innerValue, setInnerValue] = useState<string | number>('');\n const [isOpen, setIsOpen] = useState(false);\n\n const listId = safeUseId();\n const value = outerValue ?? innerValue;\n\n const helperTextId = safeUseId();\n\n const targetRef = useOutsideClick<HTMLDivElement>(() => {\n setIsOpen(false);\n });\n\n const handleFocus = () => {\n if (value.toString().length >= threshold) {\n setIsOpen(true);\n }\n };\n\n const handleItemClick = (e: SuggestionItemType) => {\n setInnerValue(e.label);\n\n if (onSuggestionSelect) {\n onSuggestionSelect(e);\n }\n\n setIsOpen(false);\n };\n\n const handleChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n const currentValue = e.target.value;\n\n setInnerValue(currentValue);\n\n if (onChange) {\n onChange(e);\n }\n\n if (currentValue.toString().length >= threshold) {\n setIsOpen(true);\n } else {\n setIsOpen(false);\n }\n };\n\n const defaultFilterCallback = ({ label }: { label: string }) => {\n return label.toLowerCase().includes(value.toString().toLowerCase());\n };\n\n const finalResults = suggestions?.filter(filter || defaultFilterCallback) || [];\n\n const { onKeyDown } = useKeyNavigation({\n isOpen,\n setIsOpen,\n focused,\n dispatchFocused,\n finalResults,\n handleItemClick,\n });\n\n useDidMountEffect(() => {\n dispatchFocused({ type: 'reset' });\n }, [value]);\n\n return (\n <Root view={view} size={size} labelPlacement={labelPlacement} disabled={disabled} readOnly={readOnly}>\n <StyledPopover\n opened={isOpen}\n offset={[0, 0]}\n placement={getPlacements('bottom')}\n isFocusTrapped={false}\n usePortal={Boolean(portal)}\n frame={portal}\n target={\n <StyledTextField\n value={value}\n onChange={handleChange}\n onSearch={focused === null ? onSearch : undefined}\n ref={ref}\n size={size}\n view={view}\n labelPlacement={labelPlacement}\n disabled={disabled}\n readOnly={readOnly}\n label={label}\n contentLeft={contentLeft}\n contentRight={contentRight}\n textBefore={textBefore}\n textAfter={textAfter}\n onFocus={handleFocus}\n onKeyDown={onKeyDown}\n role=\"combobox\"\n aria-autocomplete=\"list\"\n aria-controls={listId}\n aria-expanded={isOpen}\n aria-activedescendant={`${listId}/${focused}`}\n aria-describedby={helperTextId}\n hintText={String(hintText || '')}\n {...rest}\n />\n }\n preventOverflow={false}\n ref={targetRef}\n listWidth={listWidth}\n >\n {(renderList && renderList(finalResults)) ||\n (Boolean(finalResults.length) && (\n <Root\n view={view}\n size={size}\n labelPlacement={labelPlacement}\n disabled={disabled}\n readOnly={readOnly}\n >\n <Ul\n id={listId}\n role=\"listbox\"\n aria-label={label}\n onScroll={onScroll}\n listMaxHeight={listMaxHeight}\n >\n {finalResults.map((suggestion, index) => (\n <SuggestionItem\n key={index}\n item={suggestion}\n onClick={handleItemClick}\n id={`${listId}/${index}`}\n focused={focused === index}\n />\n ))}\n\n {renderListEnd && (\n <InfiniteLoaderWrapper>{renderListEnd()}</InfiniteLoaderWrapper>\n )}\n </Ul>\n </Root>\n ))}\n </StyledPopover>\n\n {/* TODO: Дублируем хелпер для корректного позиционирования списка подсказок */}\n {leftHelper && (\n <LeftHelper id={helperTextId} disabled={disabled} readOnly={readOnly}>\n {leftHelper}\n </LeftHelper>\n )}\n </Root>\n );\n },\n );\n\nexport const autocompleteConfig = {\n name: 'Autocomplete',\n tag: 'div',\n layout: autocompleteRoot,\n base,\n defaults: {\n view: 'default',\n size: 'l',\n labelPlacement: 'outer',\n },\n variations: {\n view: {\n css: '',\n },\n },\n};\n"],"names":["autocompleteRoot","Root","forwardRef","_ref","ref","outerValue","value","onChange","suggestions","view","size","labelPlacement","disabled","readOnly","label","leftHelper","contentLeft","contentRight","textBefore","textAfter","onScroll","listMaxHeight","listWidth","portal","filter","onSuggestionSelect","_ref$threshold","threshold","renderList","renderListEnd","onSearch","hintText","rest","_objectWithoutProperties","_excluded","_useReducer","useReducer","focusedReducer","_useReducer2","_slicedToArray","focused","dispatchFocused","_useState","useState","_useState2","innerValue","setInnerValue","_useState3","_useState4","isOpen","setIsOpen","listId","safeUseId","helperTextId","targetRef","useOutsideClick","handleFocus","toString","length","handleItemClick","e","handleChange","currentValue","target","defaultFilterCallback","_ref2","toLowerCase","includes","finalResults","_useKeyNavigation","useKeyNavigation","onKeyDown","useDidMountEffect","type","React","createElement","StyledPopover","opened","offset","placement","getPlacements","isFocusTrapped","usePortal","Boolean","frame","StyledTextField","_extends","undefined","onFocus","role","concat","String","preventOverflow","Ul","id","map","suggestion","index","SuggestionItem","key","item","onClick","InfiniteLoaderWrapper","LeftHelper","autocompleteConfig","name","tag","layout","base","defaults","variations","css"],"mappings":";;;;;;;;;;;;;;;;;;;AAaA;AACA;AACA;IACaA,gBAAgB,GAAG,SAAnBA,gBAAgBA,CAAIC,IAAoD,EAAA;AAAA,EAAA,oBACjFC,gBAAU,CACN,UAAAC,IAAA,EA+BIC,GAAG,EACF;AAAA,IAAA,IA9BUC,UAAU,GAAAF,IAAA,CAAjBG,KAAK;MACLC,QAAQ,GAAAJ,IAAA,CAARI,QAAQ;MACRC,WAAW,GAAAL,IAAA,CAAXK,WAAW;MACXC,IAAI,GAAAN,IAAA,CAAJM,IAAI;MACJC,IAAI,GAAAP,IAAA,CAAJO,IAAI;MACJC,cAAc,GAAAR,IAAA,CAAdQ,cAAc;MACdC,QAAQ,GAAAT,IAAA,CAARS,QAAQ;MACRC,QAAQ,GAAAV,IAAA,CAARU,QAAQ;MACRC,KAAK,GAAAX,IAAA,CAALW,KAAK;MACLC,UAAU,GAAAZ,IAAA,CAAVY,UAAU;MACVC,WAAW,GAAAb,IAAA,CAAXa,WAAW;MACXC,YAAY,GAAAd,IAAA,CAAZc,YAAY;MACZC,UAAU,GAAAf,IAAA,CAAVe,UAAU;MACVC,SAAS,GAAAhB,IAAA,CAATgB,SAAS;MACTC,QAAQ,GAAAjB,IAAA,CAARiB,QAAQ;MACRC,aAAa,GAAAlB,IAAA,CAAbkB,aAAa;MACbC,SAAS,GAAAnB,IAAA,CAATmB,SAAS;MACTC,MAAM,GAAApB,IAAA,CAANoB,MAAM;MACNC,MAAM,GAAArB,IAAA,CAANqB,MAAM;MACNC,kBAAkB,GAAAt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ACC,MAAAA,QAAQ,EAAEA,QAAAA;KACvDE,EAAAA,UACO,CAEd,CAAC,CAAA;AAEf,GACJ,CAAC,CAAA;AAAA,EAAA;AAEE,IAAMyF,kBAAkB,GAAG;AAC9BC,EAAAA,IAAI,EAAE,cAAc;AACpBC,EAAAA,GAAG,EAAE,KAAK;AACVC,EAAAA,MAAM,EAAE3G,gBAAgB;AACxB4G,EAAAA,IAAI,EAAJA,wBAAI;AACJC,EAAAA,QAAQ,EAAE;AACNpG,IAAAA,IAAI,EAAE,SAAS;AACfC,IAAAA,IAAI,EAAE,GAAG;AACTC,IAAAA,cAAc,EAAE,OAAA;GACnB;AACDmG,EAAAA,UAAU,EAAE;AACRrG,IAAAA,IAAI,EAAE;AACFsG,MAAAA,GAAG,EAAE,EAAA;AACT,KAAA;AACJ,GAAA;AACJ;;;;;"}
1
+ {"version":3,"file":"Autocomplete.js","sources":["../../../src/components/Autocomplete/Autocomplete.tsx"],"sourcesContent":["import React, { forwardRef, useState, useReducer } from 'react';\nimport { safeUseId } from '@salutejs/plasma-core';\n\nimport { useDidMountEffect, useOutsideClick } from '../../hooks';\nimport { RootProps } from '../../engines';\nimport { getPlacements } from '../../utils';\n\nimport { focusedReducer } from './reducers/focusedReducer';\nimport { SuggestionItem, StyledTextField } from './ui';\nimport { StyledPopover, Ul, LeftHelper, base, InfiniteLoaderWrapper } from './Autocomplete.styles';\nimport type { AutocompleteProps, SuggestionItemType } from './Autocomplete.types';\nimport { useKeyNavigation } from './hooks/useKeyboardNavigation';\n\n/**\n * Компонент Autocomplete. Поле ввода с подсказками в выпадающем списке.\n */\nexport const autocompleteRoot = (Root: RootProps<HTMLInputElement, AutocompleteProps>) =>\n forwardRef<HTMLInputElement, AutocompleteProps>(\n (\n {\n value: outerValue,\n onChange,\n suggestions,\n view,\n size,\n labelPlacement,\n disabled,\n readOnly,\n label,\n leftHelper,\n contentLeft,\n contentRight,\n textBefore,\n textAfter,\n onScroll,\n listMaxHeight,\n listWidth,\n portal,\n filter,\n onSuggestionSelect,\n threshold = 2,\n renderList,\n renderListEnd,\n onSearch,\n\n hintText,\n\n ...rest\n },\n ref,\n ) => {\n const [focused, dispatchFocused] = useReducer(focusedReducer, null);\n const [innerValue, setInnerValue] = useState<string | number>('');\n const [isOpen, setIsOpen] = useState(false);\n\n const listId = safeUseId();\n const value = outerValue ?? innerValue;\n\n const helperTextId = safeUseId();\n\n const targetRef = useOutsideClick<HTMLDivElement>(() => {\n setIsOpen(false);\n });\n\n const handleFocus = () => {\n if (value.toString().length >= threshold) {\n setIsOpen(true);\n }\n };\n\n const handleItemClick = (e: SuggestionItemType) => {\n setInnerValue(e.label);\n\n if (onSuggestionSelect) {\n onSuggestionSelect(e);\n }\n\n setIsOpen(false);\n };\n\n const handleChange = (e: React.ChangeEvent<HTMLInputElement>) => {\n const currentValue = e.target.value;\n\n setInnerValue(currentValue);\n\n if (onChange) {\n onChange(e);\n }\n\n if (currentValue.toString().length >= threshold) {\n setIsOpen(true);\n } else {\n setIsOpen(false);\n }\n };\n\n const defaultFilterCallback = ({ label }: { label: string }) => {\n return label.toLowerCase().includes(value.toString().toLowerCase());\n };\n\n const finalResults = suggestions?.filter(filter || defaultFilterCallback) || [];\n\n const { onKeyDown } = useKeyNavigation({\n isOpen,\n setIsOpen,\n focused,\n dispatchFocused,\n finalResults,\n handleItemClick,\n });\n\n useDidMountEffect(() => {\n dispatchFocused({ type: 'reset' });\n }, [value]);\n\n return (\n <Root view={view} size={size} labelPlacement={labelPlacement} disabled={disabled} readOnly={readOnly}>\n <StyledPopover\n opened={isOpen}\n offset={[0, 0]}\n placement={getPlacements('bottom')}\n isFocusTrapped={false}\n usePortal={Boolean(portal)}\n frame={portal}\n target={\n <StyledTextField\n value={value}\n onChange={handleChange}\n onSearch={focused === null ? onSearch : undefined}\n ref={ref}\n size={size}\n view={view}\n labelPlacement={labelPlacement}\n disabled={disabled}\n readOnly={readOnly}\n label={label}\n contentLeft={contentLeft}\n contentRight={contentRight}\n textBefore={textBefore}\n textAfter={textAfter}\n onFocus={handleFocus}\n onKeyDown={onKeyDown}\n role=\"combobox\"\n aria-autocomplete=\"list\"\n aria-controls={listId}\n aria-expanded={isOpen}\n aria-activedescendant={`${listId}/${focused}`}\n aria-describedby={helperTextId}\n hintText={String(hintText || '')}\n {...rest}\n />\n }\n preventOverflow={false}\n ref={targetRef}\n listWidth={listWidth}\n >\n {(renderList && renderList(finalResults)) ||\n (Boolean(finalResults.length) && (\n <Root\n view={view}\n size={size}\n labelPlacement={labelPlacement}\n disabled={disabled}\n readOnly={readOnly}\n >\n <Ul\n id={listId}\n role=\"listbox\"\n aria-label={label}\n onScroll={onScroll}\n listMaxHeight={listMaxHeight}\n >\n {finalResults.map((suggestion, index) => (\n <SuggestionItem\n key={index}\n item={suggestion}\n onClick={handleItemClick}\n id={`${listId}/${index}`}\n focused={focused === index}\n />\n ))}\n\n {renderListEnd && (\n <InfiniteLoaderWrapper>{renderListEnd()}</InfiniteLoaderWrapper>\n )}\n </Ul>\n </Root>\n ))}\n </StyledPopover>\n\n {/* TODO: Дублируем хелпер для корректного позиционирования списка подсказок */}\n {leftHelper && (\n <LeftHelper id={helperTextId} disabled={disabled} readOnly={readOnly}>\n {leftHelper}\n </LeftHelper>\n )}\n </Root>\n );\n },\n );\n\nexport const autocompleteConfig = {\n name: 'Autocomplete',\n tag: 'div',\n layout: autocompleteRoot,\n base,\n defaults: {\n view: 'default',\n size: 'l',\n labelPlacement: 'outer',\n },\n variations: {\n view: {\n css: '',\n },\n },\n};\n"],"names":["autocompleteRoot","Root","forwardRef","_ref","ref","outerValue","value","onChange","suggestions","view","size","labelPlacement","disabled","readOnly","label","leftHelper","contentLeft","contentRight","textBefore","textAfter","onScroll","listMaxHeight","listWidth","portal","filter","onSuggestionSelect","_ref$threshold","threshold","renderList","renderListEnd","onSearch","hintText","rest","_objectWithoutProperties","_excluded","_useReducer","useReducer","focusedReducer","_useReducer2","_slicedToArray","focused","dispatchFocused","_useState","useState","_useState2","innerValue","setInnerValue","_useState3","_useState4","isOpen","setIsOpen","listId","safeUseId","helperTextId","targetRef","useOutsideClick","handleFocus","toString","length","handleItemClick","e","handleChange","currentValue","target","defaultFilterCallback","_ref2","toLowerCase","includes","finalResults","_useKeyNavigation","useKeyNavigation","onKeyDown","useDidMountEffect","type","React","createElement","StyledPopover","opened","offset","placement","getPlacements","isFocusTrapped","usePortal","Boolean","frame","StyledTextField","_extends","undefined","onFocus","role","concat","String","preventOverflow","Ul","id","map","suggestion","index","SuggestionItem","key","item","onClick","InfiniteLoaderWrapper","LeftHelper","autocompleteConfig","name","tag","layout","base","defaults","variations","css"],"mappings":";;;;;;;;;;;;;;;;;;AAaA;AACA;AACA;IACaA,gBAAgB,GAAG,SAAnBA,gBAAgBA,CAAIC,IAAoD,EAAA;AAAA,EAAA,oBACjFC,gBAAU,CACN,UAAAC,IAAA,EA+BIC,GAAG,EACF;AAAA,IAAA,IA9BUC,UAAU,GAAAF,IAAA,CAAjBG,KAAK;MACLC,QAAQ,GAAAJ,IAAA,CAARI,QAAQ;MACRC,WAAW,GAAAL,IAAA,CAAXK,WAAW;MACXC,IAAI,GAAAN,IAAA,CAAJM,IAAI;MACJC,IAAI,GAAAP,IAAA,CAAJO,IAAI;MACJC,cAAc,GAAAR,IAAA,CAAdQ,cAAc;MACdC,QAAQ,GAAAT,IAAA,CAARS,QAAQ;MACRC,QAAQ,GAAAV,IAAA,CAARU,QAAQ;MACRC,KAAK,GAAAX,IAAA,CAALW,KAAK;MACLC,UAAU,GAAAZ,IAAA,CAAVY,UAAU;MACVC,WAAW,GAAAb,IAAA,CAAXa,WAAW;MACXC,YAAY,GAAAd,IAAA,CAAZc,YAAY;MACZC,UAAU,GAAAf,IAAA,CAAVe,UAAU;MACVC,SAAS,GAAAhB,IAAA,CAATgB,SAAS;MACTC,QAAQ,GAAAjB,IAAA,CAARiB,QAAQ;MACRC,aAAa,GAAAlB,IAAA,CAAbkB,aAAa;MACbC,SAAS,GAAAnB,IAAA,CAATmB,S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AC,aAAA,CAAC4B,8BAAU,EAAA;AAACT,MAAAA,EAAE,EAAEzC,YAAa;AAACzC,MAAAA,QAAQ,EAAEA,QAAS;AAACC,MAAAA,QAAQ,EAAEA,QAAAA;KACvDE,EAAAA,UACO,CAEd,CAAC,CAAA;AAEf,GACJ,CAAC,CAAA;AAAA,EAAA;AAEE,IAAMyF,kBAAkB,GAAG;AAC9BC,EAAAA,IAAI,EAAE,cAAc;AACpBC,EAAAA,GAAG,EAAE,KAAK;AACVC,EAAAA,MAAM,EAAE3G,gBAAgB;AACxB4G,EAAAA,IAAI,EAAJA,wBAAI;AACJC,EAAAA,QAAQ,EAAE;AACNpG,IAAAA,IAAI,EAAE,SAAS;AACfC,IAAAA,IAAI,EAAE,GAAG;AACTC,IAAAA,cAAc,EAAE,OAAA;GACnB;AACDmG,EAAAA,UAAU,EAAE;AACRrG,IAAAA,IAAI,EAAE;AACFsG,MAAAA,GAAG,EAAE,EAAA;AACT,KAAA;AACJ,GAAA;AACJ;;;;;"}
@@ -4,10 +4,9 @@ import './Autocomplete.styles_192fzgs.css';
4
4
  Object.defineProperty(exports, '__esModule', { value: true });
5
5
 
6
6
  var react = require('@linaria/react');
7
- var Popover$1 = require('../Popover/Popover.js');
8
- require('@linaria/core');
9
- var common = require('../../engines/common.js');
10
7
  var Autocomplete_tokens = require('./Autocomplete.tokens.js');
8
+ var common = require('../../engines/common.js');
9
+ var Popover$1 = require('../Popover/Popover.js');
11
10
 
12
11
  var base = "bn6ooh7";
13
12
  var Popover = /*#__PURE__*/common.component(Popover$1.popoverConfig);
@@ -1 +1 @@
1
- {"version":3,"file":"Autocomplete.styles.js","sources":["../../../src/components/Autocomplete/Autocomplete.styles.ts"],"sourcesContent":["import { styled } from '@linaria/react';\nimport { css } from '@linaria/core';\n\nimport { popoverClasses, popoverConfig } from '../Popover';\nimport { component } from '../../engines';\n\nimport { AutocompleteProps } from './Autocomplete.types';\nimport { tokens } from './Autocomplete.tokens';\n\nexport const base = css`\n .${popoverClasses.wrapper}, .${popoverClasses.target} {\n display: block;\n }\n`;\n\nconst Popover = component(popoverConfig);\n\nexport const StyledPopover = styled(Popover)<{ listWidth: AutocompleteProps['listWidth'] }>`\n .${String(popoverClasses.root)} {\n display: block;\n width: ${({ listWidth }) => listWidth || '100%'};\n }\n`;\n\nexport const Ul = styled.ul<{\n listMaxHeight: AutocompleteProps['listMaxHeight'];\n}>`\n box-sizing: border-box;\n\n background: var(${tokens.background});\n box-shadow: var(${tokens.boxShadow});\n\n border-radius: var(${tokens.borderRadius});\n height: auto;\n max-height: ${({ listMaxHeight }) => listMaxHeight || 'none'};\n overflow-y: scroll;\n border: var(${tokens.dropdownBorderWidth}) solid var(${tokens.dropdownBorderColor});\n\n margin: 0;\n padding: var(${tokens.padding});\n`;\n\nexport const LeftHelper = styled.div<{\n disabled: AutocompleteProps['disabled'];\n readOnly: AutocompleteProps['readOnly'];\n}>`\n color: ${({ readOnly, disabled }) =>\n readOnly && !disabled\n ? `var(${tokens.textFieldLeftHelperColorReadOnly})`\n : `var(${tokens.textFieldLeftHelperColor})`};\n margin-top: var(${tokens.textFieldLeftHelperOffset});\n\n font-family: var(${tokens.textFieldLeftHelperFontFamily});\n font-size: var(${tokens.textFieldLeftHelperFontSize});\n font-style: var(${tokens.textFieldLeftHelperFontStyle});\n font-weight: var(${tokens.textFieldLeftHelperFontWeight});\n letter-spacing: var(${tokens.textFieldLeftHelperLetterSpacing});\n line-height: var(${tokens.textFieldLeftHelperLineHeight});\n\n opacity: var(${tokens.textFieldDisabledOpacity});\n cursor: ${({ disabled }) => (disabled ? 'not-allowed' : 'auto')};\n`;\n\nexport const InfiniteLoaderWrapper = styled.li`\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: content-box;\n min-height: var(${tokens.textFieldHeight});\n`;\n"],"names":["base","Popover","component","popoverConfig","_exp3","_exp5","_ref","listWidth","StyledPopover","styled","name","class","propsAsIs","vars","_exp9","_ref2","listMaxHeight","Ul","_exp13","_ref3","readOnly","dis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.styles.js","sources":["../../../src/components/Autocomplete/Autocomplete.styles.ts"],"sourcesContent":["import { styled } from '@linaria/react';\nimport { css } from '@linaria/core';\n\nimport { popoverClasses, popoverConfig } from '../Popover';\nimport { component } from '../../engines';\n\nimport { AutocompleteProps } from './Autocomplete.types';\nimport { tokens } from './Autocomplete.tokens';\n\nexport const base = css`\n .${popoverClasses.wrapper}, .${popoverClasses.target} {\n display: block;\n }\n`;\n\nconst Popover = component(popoverConfig);\n\nexport const StyledPopover = styled(Popover)<{ listWidth: AutocompleteProps['listWidth'] }>`\n .${String(popoverClasses.root)} {\n display: block;\n width: ${({ listWidth }) => listWidth || '100%'};\n }\n`;\n\nexport const Ul = styled.ul<{\n listMaxHeight: AutocompleteProps['listMaxHeight'];\n}>`\n box-sizing: border-box;\n\n background: var(${tokens.background});\n box-shadow: var(${tokens.boxShadow});\n\n border-radius: var(${tokens.borderRadius});\n height: auto;\n max-height: ${({ listMaxHeight }) => listMaxHeight || 'none'};\n overflow-y: scroll;\n border: var(${tokens.dropdownBorderWidth}) solid var(${tokens.dropdownBorderColor});\n\n margin: 0;\n padding: var(${tokens.padding});\n`;\n\nexport const LeftHelper = styled.div<{\n disabled: AutocompleteProps['disabled'];\n readOnly: AutocompleteProps['readOnly'];\n}>`\n color: ${({ readOnly, disabled }) =>\n readOnly && !disabled\n ? `var(${tokens.textFieldLeftHelperColorReadOnly})`\n : `var(${tokens.textFieldLeftHelperColor})`};\n margin-top: var(${tokens.textFieldLeftHelperOffset});\n\n font-family: var(${tokens.textFieldLeftHelperFontFamily});\n font-size: var(${tokens.textFieldLeftHelperFontSize});\n font-style: var(${tokens.textFieldLeftHelperFontStyle});\n font-weight: var(${tokens.textFieldLeftHelperFontWeight});\n letter-spacing: var(${tokens.textFieldLeftHelperLetterSpacing});\n line-height: var(${tokens.textFieldLeftHelperLineHeight});\n\n opacity: var(${tokens.textFieldDisabledOpacity});\n cursor: ${({ disabled }) => (disabled ? 'not-allowed' : 'auto')};\n`;\n\nexport const InfiniteLoaderWrapper = styled.li`\n display: flex;\n align-items: center;\n justify-content: center;\n box-sizing: content-box;\n min-height: var(${tokens.textFieldHeight});\n`;\n"],"names":["base","Popover","component","popoverConfig","_exp3","_exp5","_ref","listWidth","StyledPopover","styled","name","class","propsAsIs","vars","_exp9","_ref2","listMaxHeight","Ul","_exp13","_ref3","readOnly","disabled","concat","tokens","textFieldLeftHelperColorReadOnly","textFieldLeftHelperColor","_exp22","_ref4","LeftHelper","InfiniteLoaderWrapper"],"mappings":";;;;;;;;;AASO,IAAMA,IAAI,GAIhB,UAAA;AAED,IAAMC,OAAO,gBAAGC,gBAAS,CAACC,uBAAa,CAAC,CAAA;AAAC,IAAAC,KAAA,GAdvBA,SAcuBA,KAAAA,GAAA;AAAA,EAAA,OAELH,OAAO,CAAA;AAAA,CAAA,CAAA;AAAA,IAAAI,KAAA,GAhBzBA,SAgByBA,KAAAA,GAAA;AAAA,EAAA,OAG1B,UAAAC,IAAA,EAAA;AAAA,IAAA,IAAGC,SAAAA,GAAAA,IAAAA,CAAAA,SAAAA,CAAAA;IAAAA,OAAgBA,SAAS,IAAI,MAAM,CAAA;AAAA,GAAA,CAAA;AAAA,CAAA,CAAA;AAHhD,IAAMC,aAAa,gBAAGC,YAAM,CAAAL,KAAA,EAAA,CAAA,CAAA;AAAAM,EAAAA,IAAA,EAAA,eAAA;AAAAC,EAAAA,OAAAA,EAAA,UAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAAC,EAAAA,IAAA,EAAA;AAAA,IAAA,YAAA,EAAA,cAGlBR,KAAsC,EAAA,CAAA;AAAA,GAAA;AAAA,CAEtD,EAAA;AAAC,IAAAS,KAAA,GArBgBA,SAqBhBA,KAAAA,GAAA;AAAA,EAAA,OAYgB,UAAAC,KAAA,EAAA;AAAA,IAAA,IAAGC,aAAAA,GAAAA,KAAAA,CAAAA,aAAAA,CAAAA;IAAAA,OAAoBA,aAAa,IAAI,MAAM,CAAA;AAAA,GAAA,CAAA;AAAA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CAClE,EAAA;AAEM,IAAMG,qBAAqB,gBAAGpB,YAAM,CAAA,IAAA,CAAA,CAAA;AAAAC,EAAAA,IAAA,EAAA,uBAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,KAAA;AAAA,CAM1C;;;;;;;;"}
@@ -4,9 +4,8 @@ import './TextField.styles_1csckkd.css';
4
4
  Object.defineProperty(exports, '__esModule', { value: true });
5
5
 
6
6
  var react = require('@linaria/react');
7
- var TextField$1 = require('../../../TextField/TextField.js');
8
- require('@linaria/core');
9
7
  var common = require('../../../../engines/common.js');
8
+ var TextField$1 = require('../../../TextField/TextField.js');
10
9
 
11
10
  var mergedConfig = /*#__PURE__*/common.mergeConfig(TextField$1.textFieldConfig);
12
11
  var TextField = /*#__PURE__*/common.component(mergedConfig);
@@ -1 +1 @@
1
- {"version":3,"file":"TextField.styles.js","sources":["../../../../../src/components/Autocomplete/ui/TextField/TextField.styles.ts"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { textFieldConfig, textFieldTokens } from '../../../TextField';\nimport { component, mergeConfig } from '../../../../engines';\nimport { tokens as autocompleteTokens } from '../../Autocomplete.tokens';\n\nconst mergedConfig = mergeConfig(textFieldConfig);\nconst TextField = component(mergedConfig);\n\nexport const StyledTextField = styled(TextField)`\n ${textFieldTokens.color}: var(${autocompleteTokens.textFieldColor});\n ${textFieldTokens.placeholderColorFocus}: var(${autocompleteTokens.textFieldPlaceholderColorFocus});\n ${textFieldTokens.backgroundColor}: var(${autocompleteTokens.textFieldBackgroundColor});\n ${textFieldTokens.backgroundColorHover}: var(${autocompleteTokens.textFieldBackgroundColorHover});\n ${textFieldTokens.backgroundColorFocus}: var(${autocompleteTokens.textFieldBackgroundColorFocus});\n ${textFieldTokens.borderColor}: var(${autocompleteTokens.textFieldBorderColor});\n ${textFieldTokens.borderColorHover}: var(${autocompleteTokens.textFieldBorderColorHover});\n ${textFieldTokens.borderColorFocus}: var(${autocompleteTokens.textFieldBorderColorFocus});\n ${textFieldTokens.colorReadOnly}: var(${autocompleteTokens.textFieldColorReadOnly});\n ${textFieldTokens.backgroundColorReadOnly}: var(${autocompleteTokens.textFieldBackgroundColorReadOnly});\n ${textFieldTokens.borderColorReadOnly}: var(${autocompleteTokens.textFieldBorderColorReadOnly});\n ${textFieldTokens.placeholderColorReadOnly}: var(${autocompleteTokens.textFieldPlaceholderColorReadOnly});\n ${textFieldTokens.caretColor}: var(${autocompleteTokens.textFieldCaretColor});\n ${textFieldTokens.placeholderColor}: var(${autocompleteTokens.textFieldPlaceholderColor});\n ${textFieldTokens.height}: var(${autocompleteTokens.textFieldHeight});\n ${textFieldTokens.borderWidth}: var(${autocompleteTokens.textFieldBorderWidth});\n ${textFieldTokens.borderRadius}: var(${autocompleteTokens.textFieldBorderRadius});\n ${textFieldTokens.padding}: var(${autocompleteTokens.textFieldPadding});\n ${textFieldTokens.leftContentMargin}: var(${autocompleteTokens.textFieldLeftContentMargin});\n ${textFieldTokens.rightContentMargin}: var(${autocompleteTokens.textFieldRightContentMargin});\n ${textFieldTokens.fontFamily}: var(${autocompleteTokens.textFieldFontFamily});\n ${textFieldTokens.fontStyle}: var(${autocompleteTokens.textFieldFontStyle});\n ${textFieldTokens.fontSize}: var(${autocompleteTokens.textFieldFontSize});\n ${textFieldTokens.fontWeight}: var(${autocompleteTokens.textFieldFontWeight});\n ${textFieldTokens.letterSpacing}: var(${autocompleteTokens.textFieldLetterSpacing});\n ${textFieldTokens.lineHeight}: var(${autocompleteTokens.textFieldLineHeight});\n ${textFieldTokens.labelColor}: var(${autocompleteTokens.textFieldLabelColor});\n ${textFieldTokens.labelColorReadOnly}: var(${autocompleteTokens.textFieldLabelColorReadOnly});\n ${textFieldTokens.labelOffset}: var(${autocompleteTokens.textFieldLabelOffset});\n ${textFieldTokens.labelFontFamily}: var(${autocompleteTokens.textFieldLabelFontFamily});\n ${textFieldTokens.labelFontStyle}: var(${autocompleteTokens.textFieldLabelFontStyle});\n ${textFieldTokens.labelFontSize}: var(${autocompleteTokens.textFieldLabelFontSize});\n ${textFieldTokens.labelFontWeight}: var(${autocompleteTokens.textFieldLabelFontWeight});\n ${textFieldTokens.labelLetterSpacing}: var(${autocompleteTokens.textFieldLabelLetterSpacing});\n ${textFieldTokens.labelLineHeight}: var(${autocompleteTokens.textFieldLabelLineHeight});\n ${textFieldTokens.labelInnerFontFamily}: var(${autocompleteTokens.textFieldLabelInnerFontFamily});\n ${textFieldTokens.labelInnerFontStyle}: var(${autocompleteTokens.textFieldLabelInnerFontStyle});\n ${textFieldTokens.labelInnerFontSize}: var(${autocompleteTokens.textFieldLabelInnerFontSize});\n ${textFieldTokens.labelInnerFontWeight}: var(${autocompleteTokens.textFieldLabelInnerFontWeight});\n ${textFieldTokens.labelInnerLetterSpacing}: var(${autocompleteTokens.textFieldLabelInnerLetterSpacing});\n ${textFieldTokens.labelInnerLineHeight}: var(${autocompleteTokens.textFieldLabelInnerLineHeight});\n ${textFieldTokens.labelInnerPadding}: var(${autocompleteTokens.textFieldLabelInnerPadding});\n ${textFieldTokens.contentLabelInnerPadding}: var(${autocompleteTokens.textFieldContentLabelInnerPadding});\n ${textFieldTokens.leftHelperColor}: var(${autocompleteTokens.textFieldLeftHelperColor});\n ${textFieldTokens.leftHelperColorReadOnly}: var(${autocompleteTokens.textFieldLeftHelperColorReadOnly});\n ${textFieldTokens.leftHelperOffset}: var(${autocompleteTokens.textFieldLeftHelperOffset});\n ${textFieldTokens.leftHelperFontFamily}: var(${autocompleteTokens.textFieldLeftHelperFontFamily});\n ${textFieldTokens.leftHelperFontStyle}: var(${autocompleteTokens.textFieldLeftHelperFontStyle});\n ${textFieldTokens.leftHelperFontSize}: var(${autocompleteTokens.textFieldLeftHelperFontSize});\n ${textFieldTokens.leftHelperFontWeight}: var(${autocompleteTokens.textFieldLeftHelperFontWeight});\n ${textFieldTokens.leftHelperLetterSpacing}: var(${autocompleteTokens.textFieldLeftHelperLetterSpacing});\n ${textFieldTokens.leftHelperLineHeight}: var(${autocompleteTokens.textFieldLeftHelperLineHeight});\n ${textFieldTokens.textBeforeColor}: var(${autocompleteTokens.textFieldTextBeforeColor});\n ${textFieldTokens.textAfterColor}: var(${autocompleteTokens.textFieldTextAfterColor});\n ${textFieldTokens.textBeforeMargin}: var(${autocompleteTokens.textFieldTextBeforeMargin});\n ${textFieldTokens.textAfterMargin}: var(${autocompleteTokens.textFieldTextAfterMargin});\n ${textFieldTokens.disabledOpacity}: var(${autocompleteTokens.textFieldDisabledOpacity});\n ${textFieldTokens.focusColor}: var(${autocompleteTokens.textFieldFocusColor});\n ${textFieldTokens.contentSlotColor}: var(${autocompleteTokens.textFieldContentSlotColor}, var(${autocompleteTokens.textFieldColor}));\n`;\n"],"names":["mergedConfig","mergeConfig","textFieldConfig","TextField","component","_exp","StyledTextField","styled","name","class","propsAsIs"],"mappings":";;;;;;;;;AAMA,IAAMA,YAAY,gBAAGC,kBAAW,CAACC,2BAAe,CAAC,CAAA;AACjD,IAAMC,SAAS,gBAAGC,gBAAS,CAACJ,YAAY,CAAC,CAAA;AAAC,IAAAK,IAAA,GANxBA,SAMwBA,IAAAA,GAAA;AAAA,EAAA,OAEJF,SAAS,CAAA;AAAA,CAAA,CAAA;AAAxC,IAAMG,eAAe,gBAAGC,YAAM,CAAAF,IAAA,EAAA,CAAA,CAAA;AAAAG,EAAAA,IAAA,EAAA,iBAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CA4DpC;;;;"}
1
+ {"version":3,"file":"TextField.styles.js","sources":["../../../../../src/components/Autocomplete/ui/TextField/TextField.styles.ts"],"sourcesContent":["import { styled } from '@linaria/react';\n\nimport { textFieldConfig, textFieldTokens } from '../../../TextField';\nimport { component, mergeConfig } from '../../../../engines';\nimport { tokens as autocompleteTokens } from '../../Autocomplete.tokens';\n\nconst mergedConfig = mergeConfig(textFieldConfig);\nconst TextField = component(mergedConfig);\n\nexport const StyledTextField = styled(TextField)`\n ${textFieldTokens.color}: var(${autocompleteTokens.textFieldColor});\n ${textFieldTokens.placeholderColorFocus}: var(${autocompleteTokens.textFieldPlaceholderColorFocus});\n ${textFieldTokens.backgroundColor}: var(${autocompleteTokens.textFieldBackgroundColor});\n ${textFieldTokens.backgroundColorHover}: var(${autocompleteTokens.textFieldBackgroundColorHover});\n ${textFieldTokens.backgroundColorFocus}: var(${autocompleteTokens.textFieldBackgroundColorFocus});\n ${textFieldTokens.borderColor}: var(${autocompleteTokens.textFieldBorderColor});\n ${textFieldTokens.borderColorHover}: var(${autocompleteTokens.textFieldBorderColorHover});\n ${textFieldTokens.borderColorFocus}: var(${autocompleteTokens.textFieldBorderColorFocus});\n ${textFieldTokens.colorReadOnly}: var(${autocompleteTokens.textFieldColorReadOnly});\n ${textFieldTokens.backgroundColorReadOnly}: var(${autocompleteTokens.textFieldBackgroundColorReadOnly});\n ${textFieldTokens.borderColorReadOnly}: var(${autocompleteTokens.textFieldBorderColorReadOnly});\n ${textFieldTokens.placeholderColorReadOnly}: var(${autocompleteTokens.textFieldPlaceholderColorReadOnly});\n ${textFieldTokens.caretColor}: var(${autocompleteTokens.textFieldCaretColor});\n ${textFieldTokens.placeholderColor}: var(${autocompleteTokens.textFieldPlaceholderColor});\n ${textFieldTokens.height}: var(${autocompleteTokens.textFieldHeight});\n ${textFieldTokens.borderWidth}: var(${autocompleteTokens.textFieldBorderWidth});\n ${textFieldTokens.borderRadius}: var(${autocompleteTokens.textFieldBorderRadius});\n ${textFieldTokens.padding}: var(${autocompleteTokens.textFieldPadding});\n ${textFieldTokens.leftContentMargin}: var(${autocompleteTokens.textFieldLeftContentMargin});\n ${textFieldTokens.rightContentMargin}: var(${autocompleteTokens.textFieldRightContentMargin});\n ${textFieldTokens.fontFamily}: var(${autocompleteTokens.textFieldFontFamily});\n ${textFieldTokens.fontStyle}: var(${autocompleteTokens.textFieldFontStyle});\n ${textFieldTokens.fontSize}: var(${autocompleteTokens.textFieldFontSize});\n ${textFieldTokens.fontWeight}: var(${autocompleteTokens.textFieldFontWeight});\n ${textFieldTokens.letterSpacing}: var(${autocompleteTokens.textFieldLetterSpacing});\n ${textFieldTokens.lineHeight}: var(${autocompleteTokens.textFieldLineHeight});\n ${textFieldTokens.labelColor}: var(${autocompleteTokens.textFieldLabelColor});\n ${textFieldTokens.labelColorReadOnly}: var(${autocompleteTokens.textFieldLabelColorReadOnly});\n ${textFieldTokens.labelOffset}: var(${autocompleteTokens.textFieldLabelOffset});\n ${textFieldTokens.labelFontFamily}: var(${autocompleteTokens.textFieldLabelFontFamily});\n ${textFieldTokens.labelFontStyle}: var(${autocompleteTokens.textFieldLabelFontStyle});\n ${textFieldTokens.labelFontSize}: var(${autocompleteTokens.textFieldLabelFontSize});\n ${textFieldTokens.labelFontWeight}: var(${autocompleteTokens.textFieldLabelFontWeight});\n ${textFieldTokens.labelLetterSpacing}: var(${autocompleteTokens.textFieldLabelLetterSpacing});\n ${textFieldTokens.labelLineHeight}: var(${autocompleteTokens.textFieldLabelLineHeight});\n ${textFieldTokens.labelInnerFontFamily}: var(${autocompleteTokens.textFieldLabelInnerFontFamily});\n ${textFieldTokens.labelInnerFontStyle}: var(${autocompleteTokens.textFieldLabelInnerFontStyle});\n ${textFieldTokens.labelInnerFontSize}: var(${autocompleteTokens.textFieldLabelInnerFontSize});\n ${textFieldTokens.labelInnerFontWeight}: var(${autocompleteTokens.textFieldLabelInnerFontWeight});\n ${textFieldTokens.labelInnerLetterSpacing}: var(${autocompleteTokens.textFieldLabelInnerLetterSpacing});\n ${textFieldTokens.labelInnerLineHeight}: var(${autocompleteTokens.textFieldLabelInnerLineHeight});\n ${textFieldTokens.labelInnerPadding}: var(${autocompleteTokens.textFieldLabelInnerPadding});\n ${textFieldTokens.contentLabelInnerPadding}: var(${autocompleteTokens.textFieldContentLabelInnerPadding});\n ${textFieldTokens.leftHelperColor}: var(${autocompleteTokens.textFieldLeftHelperColor});\n ${textFieldTokens.leftHelperColorReadOnly}: var(${autocompleteTokens.textFieldLeftHelperColorReadOnly});\n ${textFieldTokens.leftHelperOffset}: var(${autocompleteTokens.textFieldLeftHelperOffset});\n ${textFieldTokens.leftHelperFontFamily}: var(${autocompleteTokens.textFieldLeftHelperFontFamily});\n ${textFieldTokens.leftHelperFontStyle}: var(${autocompleteTokens.textFieldLeftHelperFontStyle});\n ${textFieldTokens.leftHelperFontSize}: var(${autocompleteTokens.textFieldLeftHelperFontSize});\n ${textFieldTokens.leftHelperFontWeight}: var(${autocompleteTokens.textFieldLeftHelperFontWeight});\n ${textFieldTokens.leftHelperLetterSpacing}: var(${autocompleteTokens.textFieldLeftHelperLetterSpacing});\n ${textFieldTokens.leftHelperLineHeight}: var(${autocompleteTokens.textFieldLeftHelperLineHeight});\n ${textFieldTokens.textBeforeColor}: var(${autocompleteTokens.textFieldTextBeforeColor});\n ${textFieldTokens.textAfterColor}: var(${autocompleteTokens.textFieldTextAfterColor});\n ${textFieldTokens.textBeforeMargin}: var(${autocompleteTokens.textFieldTextBeforeMargin});\n ${textFieldTokens.textAfterMargin}: var(${autocompleteTokens.textFieldTextAfterMargin});\n ${textFieldTokens.disabledOpacity}: var(${autocompleteTokens.textFieldDisabledOpacity});\n ${textFieldTokens.focusColor}: var(${autocompleteTokens.textFieldFocusColor});\n ${textFieldTokens.contentSlotColor}: var(${autocompleteTokens.textFieldContentSlotColor}, var(${autocompleteTokens.textFieldColor}));\n`;\n"],"names":["mergedConfig","mergeConfig","textFieldConfig","TextField","component","_exp","StyledTextField","styled","name","class","propsAsIs"],"mappings":";;;;;;;;AAMA,IAAMA,YAAY,gBAAGC,kBAAW,CAACC,2BAAe,CAAC,CAAA;AACjD,IAAMC,SAAS,gBAAGC,gBAAS,CAACJ,YAAY,CAAC,CAAA;AAAC,IAAAK,IAAA,GANxBA,SAMwBA,IAAAA,GAAA;AAAA,EAAA,OAEJF,SAAS,CAAA;AAAA,CAAA,CAAA;AAAxC,IAAMG,eAAe,gBAAGC,YAAM,CAAAF,IAAA,EAAA,CAAA,CAAA;AAAAG,EAAAA,IAAA,EAAA,iBAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CA4DpC;;;;"}
@@ -6,15 +6,14 @@ Object.defineProperty(exports, '__esModule', { value: true });
6
6
  var _rollupPluginBabelHelpers = require('../../_virtual/_rollupPluginBabelHelpers.js');
7
7
  var React = require('react');
8
8
  var react = require('@linaria/react');
9
- require('@linaria/core');
10
- var common = require('../../engines/common.js');
11
9
  var index = require('../../utils/index.js');
12
- var Indicator$1 = require('../Indicator/Indicator.js');
13
10
  var Avatar_tokens = require('./Avatar.tokens.js');
14
11
  var Avatar_styles = require('./Avatar.styles.js');
15
12
  var base = require('./variations/_size/base.js');
16
13
  var base$1 = require('./variations/_focused/base.js');
17
14
  var getInitialsForName = require('./utils/getInitialsForName.js');
15
+ var common = require('../../engines/common.js');
16
+ var Indicator$1 = require('../Indicator/Indicator.js');
18
17
 
19
18
  var _excluded = ["size", "name", "url", "customText", "status", "className", "focused", "isScalable", "statusLabels"];
20
19
  var StatusLabelsDefault = {