@salutejs/plasma-new-hope 0.160.1-canary.1454.11177563590.0 → 0.161.0-canary.1392.11178979637.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (342) hide show
  1. package/cjs/components/Attach/Attach.js +9 -13
  2. package/cjs/components/Attach/Attach.js.map +1 -1
  3. package/cjs/components/Attach/utils/truncateFilename.js +24 -0
  4. package/cjs/components/Attach/utils/truncateFilename.js.map +1 -0
  5. package/cjs/components/Breadcrumbs/Breadcrumbs.styles.js +2 -2
  6. package/cjs/components/Breadcrumbs/Breadcrumbs.styles.js.map +1 -1
  7. package/cjs/components/Calendar/ui/CalendarHeader/CalendarHeader.js +5 -5
  8. package/cjs/components/Calendar/ui/CalendarHeader/CalendarHeader.js.map +1 -1
  9. package/cjs/components/Segment/tokens.js +14 -1
  10. package/cjs/components/Segment/tokens.js.map +1 -1
  11. package/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.css +8 -9
  12. package/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.js +68 -112
  13. package/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.js.map +1 -1
  14. package/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.styles.js +1 -7
  15. package/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.styles.js.map +1 -1
  16. package/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.styles_klze6h.css +3 -0
  17. package/cjs/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base.js +1 -1
  18. package/cjs/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base.js.map +1 -1
  19. package/cjs/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base_a7w5s0.css +1 -0
  20. package/cjs/components/Segment/ui/SegmentGroup/variations/_orientation/base.js +9 -0
  21. package/cjs/components/Segment/ui/SegmentGroup/variations/_orientation/base.js.map +1 -0
  22. package/cjs/components/Segment/ui/SegmentGroup/variations/_orientation/base_1ejecy9.css +1 -0
  23. package/cjs/components/Segment/ui/SegmentGroup/variations/_pilled/base.js +1 -1
  24. package/cjs/components/Segment/ui/SegmentGroup/variations/_pilled/base.js.map +1 -1
  25. package/cjs/components/Segment/ui/SegmentGroup/variations/_pilled/base_pxl3nb.css +1 -0
  26. package/cjs/components/Segment/ui/SegmentGroup/variations/_size/base.js +1 -1
  27. package/cjs/components/Segment/ui/SegmentGroup/variations/_size/base.js.map +1 -1
  28. package/cjs/components/Segment/ui/SegmentGroup/variations/_size/base_18cpjsq.css +1 -0
  29. package/cjs/components/Segment/ui/SegmentItem/SegmentItem.css +6 -4
  30. package/cjs/components/Segment/ui/SegmentItem/SegmentItem.js +17 -7
  31. package/cjs/components/Segment/ui/SegmentItem/SegmentItem.js.map +1 -1
  32. package/cjs/components/Segment/ui/SegmentItem/SegmentItem.styles.js +30 -1
  33. package/cjs/components/Segment/ui/SegmentItem/SegmentItem.styles.js.map +1 -1
  34. package/cjs/components/Segment/ui/SegmentItem/SegmentItem.styles_1ir79py.css +4 -0
  35. package/cjs/components/Segment/ui/SegmentItem/variations/_pilled/base.js +1 -1
  36. package/cjs/components/Segment/ui/SegmentItem/variations/_pilled/base.js.map +1 -1
  37. package/cjs/components/Segment/ui/SegmentItem/variations/_pilled/{base_15s0fel.css → base_omc5u1.css} +1 -1
  38. package/cjs/components/Segment/ui/SegmentItem/variations/_view/base.js +1 -1
  39. package/cjs/components/Segment/ui/SegmentItem/variations/_view/base.js.map +1 -1
  40. package/cjs/components/Segment/ui/SegmentItem/variations/_view/base_dettiq.css +1 -0
  41. package/cjs/components/Tabs/ui/Tabs/Tabs.js +6 -6
  42. package/cjs/components/Tabs/ui/Tabs/Tabs.js.map +1 -1
  43. package/cjs/components/_Icon/Icon.assets/{DisclosureLeft.js → DisclosureLeftCentered.js} +3 -3
  44. package/cjs/components/_Icon/Icon.assets/DisclosureLeftCentered.js.map +1 -0
  45. package/cjs/components/_Icon/Icon.assets/DisclosureRight.js +3 -4
  46. package/cjs/components/_Icon/Icon.assets/DisclosureRight.js.map +1 -1
  47. package/cjs/components/_Icon/Icons/{IconDisclosureLeft.js → IconDisclosureLeftCentered.js} +5 -5
  48. package/cjs/components/_Icon/Icons/IconDisclosureLeftCentered.js.map +1 -0
  49. package/cjs/index.css +14 -11
  50. package/emotion/cjs/components/Attach/Attach.js +6 -9
  51. package/emotion/cjs/components/Attach/utils/index.js +7 -9
  52. package/emotion/cjs/components/Attach/utils/truncateFilename.js +23 -0
  53. package/emotion/cjs/components/Breadcrumbs/Breadcrumbs.styles.js +4 -4
  54. package/emotion/cjs/components/Calendar/ui/CalendarHeader/CalendarHeader.js +2 -2
  55. package/emotion/cjs/components/Segment/README.md +61 -0
  56. package/emotion/cjs/components/Segment/tokens.js +14 -1
  57. package/emotion/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.js +66 -115
  58. package/emotion/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.styles.js +15 -33
  59. package/emotion/cjs/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base.js +1 -1
  60. package/emotion/cjs/components/Segment/ui/SegmentGroup/variations/_orientation/base.js +10 -0
  61. package/emotion/cjs/components/Segment/ui/SegmentGroup/variations/_orientation/tokens.json +1 -0
  62. package/emotion/cjs/components/Segment/ui/SegmentGroup/variations/_pilled/base.js +1 -1
  63. package/emotion/cjs/components/Segment/ui/SegmentGroup/variations/_size/base.js +1 -1
  64. package/emotion/cjs/components/Segment/ui/SegmentItem/SegmentItem.js +17 -7
  65. package/emotion/cjs/components/Segment/ui/SegmentItem/SegmentItem.styles.js +21 -7
  66. package/emotion/cjs/components/Segment/ui/SegmentItem/variations/_pilled/base.js +1 -1
  67. package/emotion/cjs/components/Segment/ui/SegmentItem/variations/_view/base.js +2 -1
  68. package/emotion/cjs/components/Tabs/ui/Tabs/Tabs.js +4 -4
  69. package/emotion/cjs/components/_Icon/Icon.assets/DisclosureDown.js +21 -0
  70. package/emotion/cjs/components/_Icon/Icon.assets/DisclosureLeft.js +3 -4
  71. package/emotion/cjs/components/_Icon/Icon.assets/DisclosureLeftCentered.js +22 -0
  72. package/emotion/cjs/components/_Icon/Icon.assets/DisclosureRight.js +3 -4
  73. package/emotion/cjs/components/_Icon/Icon.assets/DisclosureUp.js +21 -0
  74. package/emotion/cjs/components/_Icon/Icons/IconDisclosureDown.js +22 -0
  75. package/emotion/cjs/components/_Icon/Icons/IconDisclosureLeftCentered.js +22 -0
  76. package/emotion/cjs/components/_Icon/Icons/IconDisclosureUp.js +22 -0
  77. package/emotion/cjs/components/_Icon/index.js +21 -0
  78. package/emotion/cjs/examples/plasma_b2c/components/Editable/Editable.stories.tsx +2 -2
  79. package/emotion/cjs/examples/plasma_b2c/components/Notification/Notification.stories.tsx +6 -3
  80. package/emotion/cjs/examples/plasma_b2c/components/Segment/Segment.stories.tsx +118 -42
  81. package/emotion/cjs/examples/plasma_b2c/components/Segment/SegmentGroup.config.js +13 -10
  82. package/emotion/cjs/examples/plasma_b2c/components/Segment/SegmentItem.config.js +9 -9
  83. package/emotion/cjs/examples/plasma_b2c/components/Tooltip/Tooltip.stories.tsx +2 -2
  84. package/emotion/cjs/examples/plasma_web/components/Editable/Editable.stories.tsx +2 -2
  85. package/emotion/cjs/examples/plasma_web/components/Notification/Notification.stories.tsx +6 -3
  86. package/emotion/cjs/examples/plasma_web/components/Segment/Segment.stories.tsx +119 -42
  87. package/emotion/cjs/examples/plasma_web/components/Segment/SegmentGroup.config.js +15 -9
  88. package/emotion/cjs/examples/plasma_web/components/Segment/SegmentItem.config.js +9 -9
  89. package/emotion/cjs/examples/plasma_web/components/Tooltip/Tooltip.stories.tsx +2 -2
  90. package/emotion/es/components/Attach/Attach.js +7 -10
  91. package/emotion/es/components/Attach/utils/index.js +1 -2
  92. package/emotion/es/components/Attach/utils/truncateFilename.js +17 -0
  93. package/emotion/es/components/Breadcrumbs/Breadcrumbs.styles.js +5 -5
  94. package/emotion/es/components/Calendar/ui/CalendarHeader/CalendarHeader.js +3 -3
  95. package/emotion/es/components/Segment/README.md +61 -0
  96. package/emotion/es/components/Segment/tokens.js +14 -1
  97. package/emotion/es/components/Segment/ui/SegmentGroup/SegmentGroup.js +69 -118
  98. package/emotion/es/components/Segment/ui/SegmentGroup/SegmentGroup.styles.js +14 -32
  99. package/emotion/es/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base.js +1 -1
  100. package/emotion/es/components/Segment/ui/SegmentGroup/variations/_orientation/base.js +4 -0
  101. package/emotion/es/components/Segment/ui/SegmentGroup/variations/_orientation/tokens.json +1 -0
  102. package/emotion/es/components/Segment/ui/SegmentGroup/variations/_pilled/base.js +1 -1
  103. package/emotion/es/components/Segment/ui/SegmentGroup/variations/_size/base.js +1 -1
  104. package/emotion/es/components/Segment/ui/SegmentItem/SegmentItem.js +18 -8
  105. package/emotion/es/components/Segment/ui/SegmentItem/SegmentItem.styles.js +21 -7
  106. package/emotion/es/components/Segment/ui/SegmentItem/variations/_pilled/base.js +1 -1
  107. package/emotion/es/components/Segment/ui/SegmentItem/variations/_view/base.js +2 -1
  108. package/emotion/es/components/Tabs/ui/Tabs/Tabs.js +5 -5
  109. package/emotion/es/components/_Icon/Icon.assets/DisclosureDown.js +14 -0
  110. package/emotion/es/components/_Icon/Icon.assets/DisclosureLeft.js +3 -4
  111. package/emotion/es/components/_Icon/Icon.assets/DisclosureLeftCentered.js +15 -0
  112. package/emotion/es/components/_Icon/Icon.assets/DisclosureRight.js +3 -4
  113. package/emotion/es/components/_Icon/Icon.assets/DisclosureUp.js +14 -0
  114. package/emotion/es/components/_Icon/Icons/IconDisclosureDown.js +15 -0
  115. package/emotion/es/components/_Icon/Icons/IconDisclosureLeftCentered.js +15 -0
  116. package/emotion/es/components/_Icon/Icons/IconDisclosureUp.js +15 -0
  117. package/emotion/es/components/_Icon/index.js +3 -0
  118. package/emotion/es/examples/plasma_b2c/components/Editable/Editable.stories.tsx +2 -2
  119. package/emotion/es/examples/plasma_b2c/components/Notification/Notification.stories.tsx +6 -3
  120. package/emotion/es/examples/plasma_b2c/components/Segment/Segment.stories.tsx +118 -42
  121. package/emotion/es/examples/plasma_b2c/components/Segment/SegmentGroup.config.js +13 -10
  122. package/emotion/es/examples/plasma_b2c/components/Segment/SegmentItem.config.js +9 -9
  123. package/emotion/es/examples/plasma_b2c/components/Tooltip/Tooltip.stories.tsx +2 -2
  124. package/emotion/es/examples/plasma_web/components/Editable/Editable.stories.tsx +2 -2
  125. package/emotion/es/examples/plasma_web/components/Notification/Notification.stories.tsx +6 -3
  126. package/emotion/es/examples/plasma_web/components/Segment/Segment.stories.tsx +119 -42
  127. package/emotion/es/examples/plasma_web/components/Segment/SegmentGroup.config.js +15 -9
  128. package/emotion/es/examples/plasma_web/components/Segment/SegmentItem.config.js +9 -9
  129. package/emotion/es/examples/plasma_web/components/Tooltip/Tooltip.stories.tsx +2 -2
  130. package/es/components/Attach/Attach.js +9 -13
  131. package/es/components/Attach/Attach.js.map +1 -1
  132. package/es/components/Attach/utils/truncateFilename.js +20 -0
  133. package/es/components/Attach/utils/truncateFilename.js.map +1 -0
  134. package/es/components/Breadcrumbs/Breadcrumbs.styles.js +2 -2
  135. package/es/components/Breadcrumbs/Breadcrumbs.styles.js.map +1 -1
  136. package/es/components/Calendar/ui/CalendarHeader/CalendarHeader.js +5 -5
  137. package/es/components/Calendar/ui/CalendarHeader/CalendarHeader.js.map +1 -1
  138. package/es/components/Segment/tokens.js +14 -1
  139. package/es/components/Segment/tokens.js.map +1 -1
  140. package/es/components/Segment/ui/SegmentGroup/SegmentGroup.css +8 -9
  141. package/es/components/Segment/ui/SegmentGroup/SegmentGroup.js +73 -118
  142. package/es/components/Segment/ui/SegmentGroup/SegmentGroup.js.map +1 -1
  143. package/es/components/Segment/ui/SegmentGroup/SegmentGroup.styles.js +2 -7
  144. package/es/components/Segment/ui/SegmentGroup/SegmentGroup.styles.js.map +1 -1
  145. package/es/components/Segment/ui/SegmentGroup/SegmentGroup.styles_klze6h.css +3 -0
  146. package/es/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base.js +1 -1
  147. package/es/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base.js.map +1 -1
  148. package/es/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base_a7w5s0.css +1 -0
  149. package/es/components/Segment/ui/SegmentGroup/variations/_orientation/base.js +5 -0
  150. package/es/components/Segment/ui/SegmentGroup/variations/_orientation/base.js.map +1 -0
  151. package/es/components/Segment/ui/SegmentGroup/variations/_orientation/base_1ejecy9.css +1 -0
  152. package/es/components/Segment/ui/SegmentGroup/variations/_pilled/base.js +1 -1
  153. package/es/components/Segment/ui/SegmentGroup/variations/_pilled/base.js.map +1 -1
  154. package/es/components/Segment/ui/SegmentGroup/variations/_pilled/base_pxl3nb.css +1 -0
  155. package/es/components/Segment/ui/SegmentGroup/variations/_size/base.js +1 -1
  156. package/es/components/Segment/ui/SegmentGroup/variations/_size/base.js.map +1 -1
  157. package/es/components/Segment/ui/SegmentGroup/variations/_size/base_18cpjsq.css +1 -0
  158. package/es/components/Segment/ui/SegmentItem/SegmentItem.css +6 -4
  159. package/es/components/Segment/ui/SegmentItem/SegmentItem.js +18 -8
  160. package/es/components/Segment/ui/SegmentItem/SegmentItem.js.map +1 -1
  161. package/es/components/Segment/ui/SegmentItem/SegmentItem.styles.js +29 -2
  162. package/es/components/Segment/ui/SegmentItem/SegmentItem.styles.js.map +1 -1
  163. package/es/components/Segment/ui/SegmentItem/SegmentItem.styles_1ir79py.css +4 -0
  164. package/es/components/Segment/ui/SegmentItem/variations/_pilled/base.js +1 -1
  165. package/es/components/Segment/ui/SegmentItem/variations/_pilled/base.js.map +1 -1
  166. package/es/components/Segment/ui/SegmentItem/variations/_pilled/{base_15s0fel.css → base_omc5u1.css} +1 -1
  167. package/es/components/Segment/ui/SegmentItem/variations/_view/base.js +1 -1
  168. package/es/components/Segment/ui/SegmentItem/variations/_view/base.js.map +1 -1
  169. package/es/components/Segment/ui/SegmentItem/variations/_view/base_dettiq.css +1 -0
  170. package/es/components/Tabs/ui/Tabs/Tabs.js +6 -6
  171. package/es/components/Tabs/ui/Tabs/Tabs.js.map +1 -1
  172. package/es/components/_Icon/Icon.assets/{DisclosureLeft.js → DisclosureLeftCentered.js} +3 -3
  173. package/es/components/_Icon/Icon.assets/DisclosureLeftCentered.js.map +1 -0
  174. package/es/components/_Icon/Icon.assets/DisclosureRight.js +3 -4
  175. package/es/components/_Icon/Icon.assets/DisclosureRight.js.map +1 -1
  176. package/es/components/_Icon/Icons/{IconDisclosureLeft.js → IconDisclosureLeftCentered.js} +5 -5
  177. package/es/components/_Icon/Icons/IconDisclosureLeftCentered.js.map +1 -0
  178. package/es/index.css +14 -11
  179. package/package.json +2 -2
  180. package/styled-components/cjs/components/Attach/Attach.js +6 -9
  181. package/styled-components/cjs/components/Attach/utils/index.js +7 -9
  182. package/styled-components/cjs/components/Attach/utils/truncateFilename.js +23 -0
  183. package/styled-components/cjs/components/Breadcrumbs/Breadcrumbs.styles.js +1 -1
  184. package/styled-components/cjs/components/Calendar/ui/CalendarHeader/CalendarHeader.js +2 -2
  185. package/styled-components/cjs/components/Segment/README.md +61 -0
  186. package/styled-components/cjs/components/Segment/tokens.js +14 -1
  187. package/styled-components/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.js +66 -115
  188. package/styled-components/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.styles.js +4 -13
  189. package/styled-components/cjs/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base.js +1 -1
  190. package/styled-components/cjs/components/Segment/ui/SegmentGroup/variations/_orientation/base.js +10 -0
  191. package/styled-components/cjs/components/Segment/ui/SegmentGroup/variations/_orientation/tokens.json +1 -0
  192. package/styled-components/cjs/components/Segment/ui/SegmentGroup/variations/_pilled/base.js +1 -1
  193. package/styled-components/cjs/components/Segment/ui/SegmentGroup/variations/_size/base.js +1 -1
  194. package/styled-components/cjs/components/Segment/ui/SegmentItem/SegmentItem.js +17 -7
  195. package/styled-components/cjs/components/Segment/ui/SegmentItem/SegmentItem.styles.js +17 -5
  196. package/styled-components/cjs/components/Segment/ui/SegmentItem/variations/_pilled/base.js +1 -1
  197. package/styled-components/cjs/components/Segment/ui/SegmentItem/variations/_view/base.js +2 -1
  198. package/styled-components/cjs/components/Tabs/ui/Tabs/Tabs.js +4 -4
  199. package/styled-components/cjs/components/_Icon/Icon.assets/DisclosureDown.js +21 -0
  200. package/styled-components/cjs/components/_Icon/Icon.assets/DisclosureLeft.js +3 -4
  201. package/styled-components/cjs/components/_Icon/Icon.assets/DisclosureLeftCentered.js +22 -0
  202. package/styled-components/cjs/components/_Icon/Icon.assets/DisclosureRight.js +3 -4
  203. package/styled-components/cjs/components/_Icon/Icon.assets/DisclosureUp.js +21 -0
  204. package/styled-components/cjs/components/_Icon/Icons/IconDisclosureDown.js +22 -0
  205. package/styled-components/cjs/components/_Icon/Icons/IconDisclosureLeftCentered.js +22 -0
  206. package/styled-components/cjs/components/_Icon/Icons/IconDisclosureUp.js +22 -0
  207. package/styled-components/cjs/components/_Icon/index.js +21 -0
  208. package/styled-components/cjs/examples/plasma_b2c/components/Editable/Editable.stories.tsx +2 -2
  209. package/styled-components/cjs/examples/plasma_b2c/components/Notification/Notification.stories.tsx +6 -3
  210. package/styled-components/cjs/examples/plasma_b2c/components/Segment/Segment.stories.tsx +118 -42
  211. package/styled-components/cjs/examples/plasma_b2c/components/Segment/SegmentGroup.config.js +10 -7
  212. package/styled-components/cjs/examples/plasma_b2c/components/Segment/SegmentItem.config.js +8 -8
  213. package/styled-components/cjs/examples/plasma_b2c/components/Tooltip/Tooltip.stories.tsx +2 -2
  214. package/styled-components/cjs/examples/plasma_web/components/Editable/Editable.stories.tsx +2 -2
  215. package/styled-components/cjs/examples/plasma_web/components/Notification/Notification.stories.tsx +6 -3
  216. package/styled-components/cjs/examples/plasma_web/components/Segment/Segment.stories.tsx +119 -42
  217. package/styled-components/cjs/examples/plasma_web/components/Segment/SegmentGroup.config.js +13 -7
  218. package/styled-components/cjs/examples/plasma_web/components/Segment/SegmentItem.config.js +8 -8
  219. package/styled-components/cjs/examples/plasma_web/components/Tooltip/Tooltip.stories.tsx +2 -2
  220. package/styled-components/es/components/Attach/Attach.js +7 -10
  221. package/styled-components/es/components/Attach/utils/index.js +1 -2
  222. package/styled-components/es/components/Attach/utils/truncateFilename.js +17 -0
  223. package/styled-components/es/components/Breadcrumbs/Breadcrumbs.styles.js +2 -2
  224. package/styled-components/es/components/Calendar/ui/CalendarHeader/CalendarHeader.js +3 -3
  225. package/styled-components/es/components/Segment/README.md +61 -0
  226. package/styled-components/es/components/Segment/tokens.js +14 -1
  227. package/styled-components/es/components/Segment/ui/SegmentGroup/SegmentGroup.js +69 -118
  228. package/styled-components/es/components/Segment/ui/SegmentGroup/SegmentGroup.styles.js +3 -12
  229. package/styled-components/es/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base.js +1 -1
  230. package/styled-components/es/components/Segment/ui/SegmentGroup/variations/_orientation/base.js +4 -0
  231. package/styled-components/es/components/Segment/ui/SegmentGroup/variations/_orientation/tokens.json +1 -0
  232. package/styled-components/es/components/Segment/ui/SegmentGroup/variations/_pilled/base.js +1 -1
  233. package/styled-components/es/components/Segment/ui/SegmentGroup/variations/_size/base.js +1 -1
  234. package/styled-components/es/components/Segment/ui/SegmentItem/SegmentItem.js +18 -8
  235. package/styled-components/es/components/Segment/ui/SegmentItem/SegmentItem.styles.js +17 -5
  236. package/styled-components/es/components/Segment/ui/SegmentItem/variations/_pilled/base.js +1 -1
  237. package/styled-components/es/components/Segment/ui/SegmentItem/variations/_view/base.js +2 -1
  238. package/styled-components/es/components/Tabs/ui/Tabs/Tabs.js +5 -5
  239. package/styled-components/es/components/_Icon/Icon.assets/DisclosureDown.js +14 -0
  240. package/styled-components/es/components/_Icon/Icon.assets/DisclosureLeft.js +3 -4
  241. package/styled-components/es/components/_Icon/Icon.assets/DisclosureLeftCentered.js +15 -0
  242. package/styled-components/es/components/_Icon/Icon.assets/DisclosureRight.js +3 -4
  243. package/styled-components/es/components/_Icon/Icon.assets/DisclosureUp.js +14 -0
  244. package/styled-components/es/components/_Icon/Icons/IconDisclosureDown.js +15 -0
  245. package/styled-components/es/components/_Icon/Icons/IconDisclosureLeftCentered.js +15 -0
  246. package/styled-components/es/components/_Icon/Icons/IconDisclosureUp.js +15 -0
  247. package/styled-components/es/components/_Icon/index.js +3 -0
  248. package/styled-components/es/examples/plasma_b2c/components/Editable/Editable.stories.tsx +2 -2
  249. package/styled-components/es/examples/plasma_b2c/components/Notification/Notification.stories.tsx +6 -3
  250. package/styled-components/es/examples/plasma_b2c/components/Segment/Segment.stories.tsx +118 -42
  251. package/styled-components/es/examples/plasma_b2c/components/Segment/SegmentGroup.config.js +10 -7
  252. package/styled-components/es/examples/plasma_b2c/components/Segment/SegmentItem.config.js +8 -8
  253. package/styled-components/es/examples/plasma_b2c/components/Tooltip/Tooltip.stories.tsx +2 -2
  254. package/styled-components/es/examples/plasma_web/components/Editable/Editable.stories.tsx +2 -2
  255. package/styled-components/es/examples/plasma_web/components/Notification/Notification.stories.tsx +6 -3
  256. package/styled-components/es/examples/plasma_web/components/Segment/Segment.stories.tsx +119 -42
  257. package/styled-components/es/examples/plasma_web/components/Segment/SegmentGroup.config.js +13 -7
  258. package/styled-components/es/examples/plasma_web/components/Segment/SegmentItem.config.js +8 -8
  259. package/styled-components/es/examples/plasma_web/components/Tooltip/Tooltip.stories.tsx +2 -2
  260. package/types/components/Attach/Attach.d.ts.map +1 -1
  261. package/types/components/Attach/utils/index.d.ts +1 -2
  262. package/types/components/Attach/utils/index.d.ts.map +1 -1
  263. package/types/components/Attach/utils/truncateFilename.d.ts +7 -0
  264. package/types/components/Attach/utils/truncateFilename.d.ts.map +1 -0
  265. package/types/components/Segment/tokens.d.ts +13 -0
  266. package/types/components/Segment/tokens.d.ts.map +1 -1
  267. package/types/components/Segment/ui/SegmentGroup/SegmentGroup.d.ts +10 -1
  268. package/types/components/Segment/ui/SegmentGroup/SegmentGroup.d.ts.map +1 -1
  269. package/types/components/Segment/ui/SegmentGroup/SegmentGroup.styles.d.ts +0 -1
  270. package/types/components/Segment/ui/SegmentGroup/SegmentGroup.styles.d.ts.map +1 -1
  271. package/types/components/Segment/ui/SegmentGroup/SegmentGroup.types.d.ts +19 -1
  272. package/types/components/Segment/ui/SegmentGroup/SegmentGroup.types.d.ts.map +1 -1
  273. package/types/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base.d.ts.map +1 -1
  274. package/types/components/Segment/ui/SegmentGroup/variations/_orientation/base.d.ts +2 -0
  275. package/types/components/Segment/ui/SegmentGroup/variations/_orientation/base.d.ts.map +1 -0
  276. package/types/components/Segment/ui/SegmentGroup/variations/_pilled/base.d.ts.map +1 -1
  277. package/types/components/Segment/ui/SegmentGroup/variations/_size/base.d.ts.map +1 -1
  278. package/types/components/Segment/ui/SegmentItem/SegmentItem.d.ts +8 -2
  279. package/types/components/Segment/ui/SegmentItem/SegmentItem.d.ts.map +1 -1
  280. package/types/components/Segment/ui/SegmentItem/SegmentItem.styles.d.ts +7 -1
  281. package/types/components/Segment/ui/SegmentItem/SegmentItem.styles.d.ts.map +1 -1
  282. package/types/components/Segment/ui/SegmentItem/SegmentItem.types.d.ts +14 -1
  283. package/types/components/Segment/ui/SegmentItem/SegmentItem.types.d.ts.map +1 -1
  284. package/types/components/Segment/ui/SegmentItem/variations/_pilled/base.d.ts.map +1 -1
  285. package/types/components/Segment/ui/SegmentItem/variations/_view/base.d.ts.map +1 -1
  286. package/types/components/Tabs/ui/Tabs/Tabs.d.ts.map +1 -1
  287. package/types/components/_Icon/Icon.assets/DisclosureDown.d.ts +4 -0
  288. package/types/components/_Icon/Icon.assets/DisclosureDown.d.ts.map +1 -0
  289. package/types/components/_Icon/Icon.assets/DisclosureLeft.d.ts.map +1 -1
  290. package/types/components/_Icon/Icon.assets/DisclosureLeftCentered.d.ts +4 -0
  291. package/types/components/_Icon/Icon.assets/DisclosureLeftCentered.d.ts.map +1 -0
  292. package/types/components/_Icon/Icon.assets/DisclosureRight.d.ts.map +1 -1
  293. package/types/components/_Icon/Icon.assets/DisclosureUp.d.ts +4 -0
  294. package/types/components/_Icon/Icon.assets/DisclosureUp.d.ts.map +1 -0
  295. package/types/components/_Icon/Icons/IconDisclosureDown.d.ts +4 -0
  296. package/types/components/_Icon/Icons/IconDisclosureDown.d.ts.map +1 -0
  297. package/types/components/_Icon/Icons/IconDisclosureLeftCentered.d.ts +4 -0
  298. package/types/components/_Icon/Icons/IconDisclosureLeftCentered.d.ts.map +1 -0
  299. package/types/components/_Icon/Icons/IconDisclosureUp.d.ts +4 -0
  300. package/types/components/_Icon/Icons/IconDisclosureUp.d.ts.map +1 -0
  301. package/types/components/_Icon/index.d.ts +3 -0
  302. package/types/components/_Icon/index.d.ts.map +1 -1
  303. package/types/examples/plasma_b2c/components/Segment/Segment.d.ts +10 -1
  304. package/types/examples/plasma_b2c/components/Segment/Segment.d.ts.map +1 -1
  305. package/types/examples/plasma_b2c/components/Segment/SegmentGroup.config.d.ts +3 -0
  306. package/types/examples/plasma_b2c/components/Segment/SegmentGroup.config.d.ts.map +1 -1
  307. package/types/examples/plasma_b2c/components/Segment/SegmentItem.config.d.ts.map +1 -1
  308. package/types/examples/plasma_web/components/Segment/Segment.d.ts +13 -1
  309. package/types/examples/plasma_web/components/Segment/Segment.d.ts.map +1 -1
  310. package/types/examples/plasma_web/components/Segment/SegmentGroup.config.d.ts +6 -0
  311. package/types/examples/plasma_web/components/Segment/SegmentGroup.config.d.ts.map +1 -1
  312. package/types/examples/plasma_web/components/Segment/SegmentItem.config.d.ts.map +1 -1
  313. package/cjs/components/Attach/utils/addSeparator.js +0 -18
  314. package/cjs/components/Attach/utils/addSeparator.js.map +0 -1
  315. package/cjs/components/Attach/utils/index.js +0 -11
  316. package/cjs/components/Attach/utils/index.js.map +0 -1
  317. package/cjs/components/Segment/ui/SegmentGroup/SegmentGroup.styles_m9i9p0.css +0 -4
  318. package/cjs/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base_escgtx.css +0 -1
  319. package/cjs/components/Segment/ui/SegmentGroup/variations/_pilled/base_fqbatz.css +0 -1
  320. package/cjs/components/Segment/ui/SegmentGroup/variations/_size/base_m358nl.css +0 -1
  321. package/cjs/components/Segment/ui/SegmentItem/SegmentItem.styles_18h1p52.css +0 -2
  322. package/cjs/components/Segment/ui/SegmentItem/variations/_view/base_1m1u2ys.css +0 -1
  323. package/cjs/components/_Icon/Icon.assets/DisclosureLeft.js.map +0 -1
  324. package/cjs/components/_Icon/Icons/IconDisclosureLeft.js.map +0 -1
  325. package/emotion/cjs/components/Attach/utils/addSeparator.js +0 -16
  326. package/emotion/es/components/Attach/utils/addSeparator.js +0 -10
  327. package/es/components/Attach/utils/addSeparator.js +0 -14
  328. package/es/components/Attach/utils/addSeparator.js.map +0 -1
  329. package/es/components/Attach/utils/index.js +0 -7
  330. package/es/components/Attach/utils/index.js.map +0 -1
  331. package/es/components/Segment/ui/SegmentGroup/SegmentGroup.styles_m9i9p0.css +0 -4
  332. package/es/components/Segment/ui/SegmentGroup/variations/_filledBackgound/base_escgtx.css +0 -1
  333. package/es/components/Segment/ui/SegmentGroup/variations/_pilled/base_fqbatz.css +0 -1
  334. package/es/components/Segment/ui/SegmentGroup/variations/_size/base_m358nl.css +0 -1
  335. package/es/components/Segment/ui/SegmentItem/SegmentItem.styles_18h1p52.css +0 -2
  336. package/es/components/Segment/ui/SegmentItem/variations/_view/base_1m1u2ys.css +0 -1
  337. package/es/components/_Icon/Icon.assets/DisclosureLeft.js.map +0 -1
  338. package/es/components/_Icon/Icons/IconDisclosureLeft.js.map +0 -1
  339. package/styled-components/cjs/components/Attach/utils/addSeparator.js +0 -16
  340. package/styled-components/es/components/Attach/utils/addSeparator.js +0 -10
  341. package/types/components/Attach/utils/addSeparator.d.ts +0 -2
  342. package/types/components/Attach/utils/addSeparator.d.ts.map +0 -1
@@ -12,13 +12,12 @@ var base$1 = require('./variations/_size/base.js');
12
12
  var base = require('./variations/_view/base.js');
13
13
  var Attach_styles = require('./Attach.styles.js');
14
14
  var Cell_styles = require('./ui/Cell/Cell.styles.js');
15
- var index$1 = require('./utils/index.js');
15
+ var extractExtension = require('./utils/extractExtension.js');
16
+ var getFileicon = require('./utils/getFileicon.js');
17
+ var truncateFilename = require('./utils/truncateFilename.js');
16
18
  var Attach_tokens = require('./Attach.tokens.js');
17
19
  var AttachButton = require('./components/AttachButton/AttachButton.js');
18
20
  var IconButton_styles = require('./ui/IconButton/IconButton.styles.js');
19
- var extractExtension = require('./utils/extractExtension.js');
20
- var addSeparator = require('./utils/addSeparator.js');
21
- var getFileicon = require('./utils/getFileicon.js');
22
21
 
23
22
  var _IconCloseCircleOutli;
24
23
  var _excluded = ["flow", "buttonType", "hasAttachment", "acceptedFileFormats", "size", "view", "className", "style", "isLoading", "disabled"];
@@ -77,18 +76,15 @@ var attachRoot = function attachRoot(Root) {
77
76
  cellLeft = _cellRef$current$getB.left;
78
77
  var leftDiff = cellLeft - parentLeft;
79
78
  var currentTextWidth = textWidth;
80
- if (currentTextWidth + emptyTextCellWidth.current + leftDiff <= parentWidth || currentTextWidth + emptyTextCellWidth.current < buttonWidth) {
81
- setTruncatedFilename(filename);
82
- return;
83
- }
84
- var currFilename = addSeparator.addSeparator(filename, index$1.separator);
85
- for (var i = currFilename.indexOf(index$1.separator) - 1; i > 0; i -= 1) {
79
+ var currFilename = filename;
80
+ for (var i = filename.length - 1; i > 0; i -= 1) {
86
81
  if (currentTextWidth + emptyTextCellWidth.current + leftDiff <= parentWidth) {
87
82
  break;
88
83
  }
89
- var left = currFilename.slice(0, i);
90
- var right = currFilename.slice(i + 1);
91
- var newFilename = "".concat(left).concat(right);
84
+ var newFilename = truncateFilename.truncateFilename({
85
+ filename: inputHelperRef.current.textContent,
86
+ startNameTruncationIndex: i
87
+ });
92
88
  inputHelperRef.current.textContent = newFilename;
93
89
  currentTextWidth = inputHelperRef.current.offsetWidth;
94
90
  if (currentTextWidth + emptyTextCellWidth.current < buttonWidth) {
@@ -1 +1 @@
1
- {"version":3,"file":"Attach.js","sources":["../../../src/components/Attach/Attach.tsx"],"sourcesContent":["import React, { forwardRef, useEffect, useRef, useState } 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 ...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 = () => {\n if (!inputRef.current || !inputRef.current.files) {\n return;\n }\n\n setFilename(inputRef.current.files[0].name);\n };\n\n const handleClear = () => {\n if (!inputRef.current) {\n return;\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=\"attachHiddenInput\"\n name=\"attachHiddenInput\"\n onChange={handleChange}\n />\n <StyledHiddenInputHelper ref={inputHelperRef} id=\"attachHiddenInputHelper\">\n {filename}\n </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","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","files","name","handleClear","value","React","createElement","cx","StyledHiddenInput","type","id","onChange","StyledHiddenInputHelper","AttachButton","_extends","onClick","StyledCell","stretching","title","contentLeft","contentRight","StyledIconButtonC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;AAAClG,QAAAA,IAAI,EAAC,IAAI;AAACmG,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAChC,CAAA;AAC3B,KACJ,CAEH,CAAC,CAAA;AAEf,GAAC,CAAC,CAAA;AAAA,EAAA;AAEC,IAAMC,YAAY,GAAG;AACxBvB,EAAAA,IAAI,EAAE,QAAQ;AACdwB,EAAAA,GAAG,EAAE,KAAK;AACVC,EAAAA,MAAM,EAAElH,UAAU;AAClBmH,EAAAA,IAAI,EAAJA,kBAAI;AACJC,EAAAA,UAAU,EAAE;AACRvG,IAAAA,IAAI,EAAE;AACFwG,MAAAA,GAAG,EAAEC,SAAAA;KACR;AACD1G,IAAAA,IAAI,EAAE;AACFyG,MAAAA,GAAG,EAAEE,WAAAA;AACT,KAAA;GACH;AACDC,EAAAA,QAAQ,EAAE;AACN3G,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 { 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, truncateFilename } 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 ...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\n let currentTextWidth = textWidth;\n let currFilename = filename;\n\n for (let i = filename.length - 1; i > 0; i -= 1) {\n if (currentTextWidth + emptyTextCellWidth.current + leftDiff <= parentWidth) {\n break;\n }\n\n const newFilename = truncateFilename({\n filename: inputHelperRef.current.textContent,\n startNameTruncationIndex: i,\n });\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 = () => {\n if (!inputRef.current || !inputRef.current.files) {\n return;\n }\n\n setFilename(inputRef.current.files[0].name);\n };\n\n const handleClear = () => {\n if (!inputRef.current) {\n return;\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=\"attachHiddenInput\"\n name=\"attachHiddenInput\"\n onChange={handleChange}\n />\n <StyledHiddenInputHelper ref={inputHelperRef} id=\"attachHiddenInputHelper\">\n {filename}\n </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","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","i","newFilename","truncateFilename","startNameTruncationIndex","handleClick","click","handleChange","files","name","handleClear","value","React","createElement","cx","StyledHiddenInput","type","id","onChange","StyledHiddenInputHelper","AttachButton","_extends","onClick","StyledCell","stretching","title","contentLeft","contentRight","StyledIconButtonCancel","_IconCloseCircleOutli","IconCloseCircleOutline","color","attachConfig","tag","layout","base","variations","css","viewCSS","sizeCSS","defaults"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;IAiBaA,UAAU,GAAG,SAAbA,UAAUA,CAAIC,IAA4C,EAAA;AAAA,EAAA,oBACnEC,gBAAU,CAA8B,UAACC,KAAK,EAAEC,QAAQ,EAAK;AACzD,IAAA,IAAAC,WAAA,GAYIF,KAAK,CAXLG,IAAI;AAAJA,MAAAA,IAAI,GAAAD,WAAA,KAAG,KAAA,CAAA,GAAA,MAAM,GAAAA,WAAA;MAAAE,iBAAA,GAWbJ,KAAK,CAVLK,UAAU;AAAVA,MAAAA,UAAU,GAAAD,iBAAA,KAAG,KAAA,CAAA,GAAA,QAAQ,GAAAA,iBAAA;MAAAE,oBAAA,GAUrBN,KAAK,CATLO,aAAa;AAAbA,MAAAA,aAAa,GAAAD,oBAAA,KAAG,KAAA,CAAA,GAAA,IAAI,GAAAA,oBAAA;MACpBE,mBAAmB,GAQnBR,KAAK,CARLQ,mBAAmB;MACnBC,IAAI,GAOJT,KAAK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AI,EAAEA,IAAK;AAACD,QAAAA,IAAI,EAAEA,IAAK;AAACsF,QAAAA,OAAO,EAAEZ,WAAAA;OAAYmB,EAAAA,qBAAA,KAAAA,qBAAA,gBACjEjB,KAAA,CAAAC,aAAA,CAACiB,6CAAsB,EAAA;AAAC9F,QAAAA,IAAI,EAAC,IAAI;AAAC+F,QAAAA,KAAK,EAAC,SAAA;AAAS,OAAE,CAAC,CAChC,CAAA;AAC3B,KACJ,CAEH,CAAC,CAAA;AAEf,GAAC,CAAC,CAAA;AAAA,EAAA;AAEC,IAAMC,YAAY,GAAG;AACxBvB,EAAAA,IAAI,EAAE,QAAQ;AACdwB,EAAAA,GAAG,EAAE,KAAK;AACVC,EAAAA,MAAM,EAAE9G,UAAU;AAClB+G,EAAAA,IAAI,EAAJA,kBAAI;AACJC,EAAAA,UAAU,EAAE;AACRnG,IAAAA,IAAI,EAAE;AACFoG,MAAAA,GAAG,EAAEC,SAAAA;KACR;AACDtG,IAAAA,IAAI,EAAE;AACFqG,MAAAA,GAAG,EAAEE,WAAAA;AACT,KAAA;GACH;AACDC,EAAAA,QAAQ,EAAE;AACNvG,IAAAA,IAAI,EAAE,SAAS;AACfD,IAAAA,IAAI,EAAE,GAAA;AACV,GAAA;AACJ;;;;;"}
@@ -0,0 +1,24 @@
1
+ 'use strict';
2
+
3
+ Object.defineProperty(exports, '__esModule', { value: true });
4
+
5
+ var truncateFilename = function truncateFilename(_ref) {
6
+ var filename = _ref.filename,
7
+ startNameTruncationIndex = _ref.startNameTruncationIndex,
8
+ _ref$separator = _ref.separator,
9
+ separator = _ref$separator === void 0 ? '...' : _ref$separator,
10
+ _ref$minNameLength = _ref.minNameLength,
11
+ minNameLength = _ref$minNameLength === void 0 ? 5 : _ref$minNameLength;
12
+ var strings = filename.split('.');
13
+ var extension = strings.length > 1 ? strings[strings.length - 1] : null;
14
+ var name = strings.length > 1 ? strings.slice(0, -1).join('.') : strings[0];
15
+ if (name.length <= minNameLength || startNameTruncationIndex >= name.length - 1) {
16
+ return filename;
17
+ }
18
+ var lastNameLetter = name[name.length - 1];
19
+ var truncatedName = "".concat(name.substring(0, startNameTruncationIndex)).concat(separator).concat(lastNameLetter);
20
+ return extension ? "".concat(truncatedName, ".").concat(extension) : truncatedName;
21
+ };
22
+
23
+ exports.truncateFilename = truncateFilename;
24
+ //# sourceMappingURL=truncateFilename.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"truncateFilename.js","sources":["../../../../src/components/Attach/utils/truncateFilename.ts"],"sourcesContent":["export const truncateFilename = ({\n filename,\n startNameTruncationIndex,\n separator = '...',\n minNameLength = 5,\n}: {\n filename: string;\n startNameTruncationIndex: number;\n separator?: string;\n minNameLength?: number;\n}) => {\n const strings = filename.split('.');\n const extension = strings.length > 1 ? strings[strings.length - 1] : null;\n const name = strings.length > 1 ? strings.slice(0, -1).join('.') : strings[0];\n\n if (name.length <= minNameLength || startNameTruncationIndex >= name.length - 1) {\n return filename;\n }\n\n const lastNameLetter = name[name.length - 1];\n const truncatedName = `${name.substring(0, startNameTruncationIndex)}${separator}${lastNameLetter}`;\n\n return extension ? `${truncatedName}.${extension}` : truncatedName;\n};\n"],"names":["truncateFilename","_ref","filename","startNameTruncationIndex","_ref$separator","separator","_ref$minNameLength","minNameLength","strings","split","extension","length","name","slice","join","lastNameLetter","truncatedName","concat","substring"],"mappings":";;;;IAAaA,gBAAgB,GAAG,SAAnBA,gBAAgBA,CAAAC,IAAA,EAUvB;AAAA,EAAA,IATFC,QAAQ,GAAAD,IAAA,CAARC,QAAQ;IACRC,wBAAwB,GAAAF,IAAA,CAAxBE,wBAAwB;IAAAC,cAAA,GAAAH,IAAA,CACxBI,SAAS;AAATA,IAAAA,SAAS,GAAAD,cAAA,KAAG,KAAA,CAAA,GAAA,KAAK,GAAAA,cAAA;IAAAE,kBAAA,GAAAL,IAAA,CACjBM,aAAa;AAAbA,IAAAA,aAAa,GAAAD,kBAAA,KAAG,KAAA,CAAA,GAAA,CAAC,GAAAA,kBAAA,CAAA;AAOjB,EAAA,IAAME,OAAO,GAAGN,QAAQ,CAACO,KAAK,CAAC,GAAG,CAAC,CAAA;AACnC,EAAA,IAAMC,SAAS,GAAGF,OAAO,CAACG,MAAM,GAAG,CAAC,GAAGH,OAAO,CAACA,OAAO,CAACG,MAAM,GAAG,CAAC,CAAC,GAAG,IAAI,CAAA;EACzE,IAAMC,IAAI,GAAGJ,OAAO,CAACG,MAAM,GAAG,CAAC,GAAGH,OAAO,CAACK,KAAK,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAACC,IAAI,CAAC,GAAG,CAAC,GAAGN,OAAO,CAAC,CAAC,CAAC,CAAA;AAE7E,EAAA,IAAII,IAAI,CAACD,MAAM,IAAIJ,aAAa,IAAIJ,wBAAwB,IAAIS,IAAI,CAACD,MAAM,GAAG,CAAC,EAAE;AAC7E,IAAA,OAAOT,QAAQ,CAAA;AACnB,GAAA;EAEA,IAAMa,cAAc,GAAGH,IAAI,CAACA,IAAI,CAACD,MAAM,GAAG,CAAC,CAAC,CAAA;EAC5C,IAAMK,aAAa,MAAAC,MAAA,CAAML,IAAI,CAACM,SAAS,CAAC,CAAC,EAAEf,wBAAwB,CAAC,CAAA,CAAAc,MAAA,CAAGZ,SAAS,EAAAY,MAAA,CAAGF,cAAc,CAAE,CAAA;EAEnG,OAAOL,SAAS,GAAAO,EAAAA,CAAAA,MAAA,CAAMD,aAAa,OAAAC,MAAA,CAAIP,SAAS,CAAA,GAAKM,aAAa,CAAA;AACtE;;;;"}
@@ -8,7 +8,7 @@ var Link$1 = require('../Link/Link.js');
8
8
  require('@linaria/core');
9
9
  var common = require('../../engines/common.js');
10
10
  require('react');
11
- var IconDisclosureRight = require('../_Icon/Icons/IconDisclosureRight.js');
11
+ var IconDisclosureRightCentered = require('../_Icon/Icons/IconDisclosureRightCentered.js');
12
12
  var Breadcrumbs_tokens = require('./Breadcrumbs.tokens.js');
13
13
 
14
14
  var mergedLinkConfig = /*#__PURE__*/common.mergeConfig(Link$1.linkConfig);
@@ -32,7 +32,7 @@ var StyledLink = /*#__PURE__*/react.styled(_exp())({
32
32
  });
33
33
  var base = "bkgt5xr";
34
34
  var _exp12 = function _exp12() {
35
- return IconDisclosureRight.IconDisclosureRight;
35
+ return IconDisclosureRightCentered.IconDisclosureRightCentered;
36
36
  };
37
37
  var Separator = /*#__PURE__*/react.styled(_exp12())({
38
38
  name: "Separator",
@@ -1 +1 @@
1
- {"version":3,"file":"Breadcrumbs.styles.js","sources":["../../../src/components/Breadcrumbs/Breadcrumbs.styles.ts"],"sourcesContent":["import { styled } from '@linaria/react';\nimport { css } from '@linaria/core';\n\nimport { linkConfig } from '../Link';\nimport { component, mergeConfig } from '../../engines';\nimport { IconDisclosureRight } from '../_Icon';\nimport { addFocus } from '../../mixins';\n\nimport { tokens } from './Breadcrumbs.tokens';\n\nconst mergedLinkConfig = mergeConfig(linkConfig);\nconst Link = component(mergedLinkConfig);\n\nexport const StyledLink = styled(Link)<{ isHref: boolean }>`\n opacity: ${({ isHref }) => (isHref ? 1 : `var(${tokens.breadcrumbsOpacity})`)};\n\n ${addFocus({\n outlineOffset: '0rem',\n outlineSize: '0.125rem',\n outlineRadius: '0rem',\n outlineColor: `var(${tokens.breadcrumbsFocusOutlineColor})`,\n })}\n`;\n\nexport const base = css`\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: var(${tokens.breadcrumbsGap});\n\n color: var(${tokens.breadcrumbsColor});\n font-family: var(${tokens.breadcrumbsFontFamily});\n font-size: var(${tokens.breadcrumbsFontSize});\n font-weight: var(${tokens.breadcrumbsFontWeight});\n font-style: var(${tokens.breadcrumbsFontStyle});\n letter-spacing: var(${tokens.breadcrumbsLetterSpacing});\n line-height: var(${tokens.breadcrumbsLineHeight});\n`;\n\nexport const Separator = styled(IconDisclosureRight)`\n color: var(${tokens.breadcrumbsColor});\n opacity: var(${tokens.breadcrumbsOpacity});\n`;\n"],"names":["mergedLinkConfig","mergeConfig","linkConfig","Link","component","_exp","_exp2","_ref","isHref","concat","tokens","breadcrumbsOpacity","StyledLink","styled","name","class","propsAsIs","vars","base","_exp12","IconDisclosureRight","Separator"],"mappings":";;;;;;;;;;;;AAUA,IAAMA,gBAAgB,gBAAGC,kBAAW,CAACC,iBAAU,CAAC,CAAA;AAChD,IAAMC,IAAI,gBAAGC,gBAAS,CAACJ,gBAAgB,CAAC,CAAA;AAAC,IAAAK,IAAA,GAVvBA,SAUuBA,IAAAA,GAAA;AAAA,EAAA,OAERF,IAAI,CAAA;AAAA,CAAA,CAAA;AAAA,IAAAG,KAAA,GAZnBA,SAYmBA,KAAAA,GAAA;AAAA,EAAA,OACtB,UAAAC,IAAA,EAAA;AAAA,IAAA,IAAGC,MAAAA,GAAAA,IAAAA,CAAAA,MAAAA,CAAAA;IAAAA,OAAcA,MAAM,GAAG,CAAC,GAAA,MAAA,CAAAC,MAAA,CAAUC,yBAAM,CAACC,kBAAmB,EAAG,GAAA,CAAA,CAAA;AAAA,GAAA,CAAA;AAAA,CAAA,CAAA;AAD1E,IAAMC,UAAU,gBAAGC,YAAM,CAAAR,IAAA,EAAA,CAAA,CAAA;AAAAS,EAAAA,IAAA,EAAA,YAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAAC,EAAAA,IAAA,EAAA;AAAA,IAAA,WAAA,EAAA,cACjBX,KAAkE,EAAA,CAAA;AAAA,GAAA;AAAA,CAQhF,EAAA;AAEM,IAAMY,IAAI,GAahB,UAAA;AAAC,IAAAC,MAAA,GApCgBA,SAoChBA,MAAAA,GAAA;AAAA,EAAA,OAE8BC,uCAAmB,CAAA;AAAA,CAAA,CAAA;AAA5C,IAAMC,SAAS,gBAAGR,YAAM,CAAAM,MAAA,EAAA,CAAA,CAAA;AAAAL,EAAAA,IAAA,EAAA,WAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CAG9B;;;;;;"}
1
+ {"version":3,"file":"Breadcrumbs.styles.js","sources":["../../../src/components/Breadcrumbs/Breadcrumbs.styles.ts"],"sourcesContent":["import { styled } from '@linaria/react';\nimport { css } from '@linaria/core';\n\nimport { linkConfig } from '../Link';\nimport { component, mergeConfig } from '../../engines';\nimport { IconDisclosureRightCentered } from '../_Icon';\nimport { addFocus } from '../../mixins';\n\nimport { tokens } from './Breadcrumbs.tokens';\n\nconst mergedLinkConfig = mergeConfig(linkConfig);\nconst Link = component(mergedLinkConfig);\n\nexport const StyledLink = styled(Link)<{ isHref: boolean }>`\n opacity: ${({ isHref }) => (isHref ? 1 : `var(${tokens.breadcrumbsOpacity})`)};\n\n ${addFocus({\n outlineOffset: '0rem',\n outlineSize: '0.125rem',\n outlineRadius: '0rem',\n outlineColor: `var(${tokens.breadcrumbsFocusOutlineColor})`,\n })}\n`;\n\nexport const base = css`\n display: flex;\n flex-direction: row;\n align-items: center;\n gap: var(${tokens.breadcrumbsGap});\n\n color: var(${tokens.breadcrumbsColor});\n font-family: var(${tokens.breadcrumbsFontFamily});\n font-size: var(${tokens.breadcrumbsFontSize});\n font-weight: var(${tokens.breadcrumbsFontWeight});\n font-style: var(${tokens.breadcrumbsFontStyle});\n letter-spacing: var(${tokens.breadcrumbsLetterSpacing});\n line-height: var(${tokens.breadcrumbsLineHeight});\n`;\n\nexport const Separator = styled(IconDisclosureRightCentered)`\n color: var(${tokens.breadcrumbsColor});\n opacity: var(${tokens.breadcrumbsOpacity});\n`;\n"],"names":["mergedLinkConfig","mergeConfig","linkConfig","Link","component","_exp","_exp2","_ref","isHref","concat","tokens","breadcrumbsOpacity","StyledLink","styled","name","class","propsAsIs","vars","base","_exp12","IconDisclosureRightCentered","Separator"],"mappings":";;;;;;;;;;;;AAUA,IAAMA,gBAAgB,gBAAGC,kBAAW,CAACC,iBAAU,CAAC,CAAA;AAChD,IAAMC,IAAI,gBAAGC,gBAAS,CAACJ,gBAAgB,CAAC,CAAA;AAAC,IAAAK,IAAA,GAVvBA,SAUuBA,IAAAA,GAAA;AAAA,EAAA,OAERF,IAAI,CAAA;AAAA,CAAA,CAAA;AAAA,IAAAG,KAAA,GAZnBA,SAYmBA,KAAAA,GAAA;AAAA,EAAA,OACtB,UAAAC,IAAA,EAAA;AAAA,IAAA,IAAGC,MAAAA,GAAAA,IAAAA,CAAAA,MAAAA,CAAAA;IAAAA,OAAcA,MAAM,GAAG,CAAC,GAAA,MAAA,CAAAC,MAAA,CAAUC,yBAAM,CAACC,kBAAmB,EAAG,GAAA,CAAA,CAAA;AAAA,GAAA,CAAA;AAAA,CAAA,CAAA;AAD1E,IAAMC,UAAU,gBAAGC,YAAM,CAAAR,IAAA,EAAA,CAAA,CAAA;AAAAS,EAAAA,IAAA,EAAA,YAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAAC,EAAAA,IAAA,EAAA;AAAA,IAAA,WAAA,EAAA,cACjBX,KAAkE,EAAA,CAAA;AAAA,GAAA;AAAA,CAQhF,EAAA;AAEM,IAAMY,IAAI,GAahB,UAAA;AAAC,IAAAC,MAAA,GApCgBA,SAoChBA,MAAAA,GAAA;AAAA,EAAA,OAE8BC,uDAA2B,CAAA;AAAA,CAAA,CAAA;AAApD,IAAMC,SAAS,gBAAGR,YAAM,CAAAM,MAAA,EAAA,CAAA,CAAA;AAAAL,EAAAA,IAAA,EAAA,WAAA;AAAAC,EAAAA,OAAAA,EAAA,SAAA;AAAAC,EAAAA,SAAA,EAAA,IAAA;AAAA,CAG9B;;;;;;"}
@@ -3,10 +3,10 @@
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
5
  var React = require('react');
6
- var IconDisclosureLeft = require('../../../_Icon/Icons/IconDisclosureLeft.js');
7
- var IconDisclosureRight = require('../../../_Icon/Icons/IconDisclosureRight.js');
8
- var IconDisclosureDownFill = require('../../../_Icon/Icons/IconDisclosureDownFill.js');
9
6
  require('@linaria/react');
7
+ var IconDisclosureDownFill = require('../../../_Icon/Icons/IconDisclosureDownFill.js');
8
+ var IconDisclosureLeftCentered = require('../../../_Icon/Icons/IconDisclosureLeftCentered.js');
9
+ var IconDisclosureRightCentered = require('../../../_Icon/Icons/IconDisclosureRightCentered.js');
10
10
  var types = require('../../store/types.js');
11
11
  var constants = require('../../utils/constants.js');
12
12
  var calendarGridHelper = require('../../utils/calendarGridHelper.js');
@@ -71,7 +71,7 @@ var CalendarHeader = function CalendarHeader(_ref) {
71
71
  onClick: function onClick() {
72
72
  return onPrev();
73
73
  }
74
- }, /*#__PURE__*/React.createElement(IconDisclosureLeft.IconDisclosureLeft, {
74
+ }, /*#__PURE__*/React.createElement(IconDisclosureLeftCentered.IconDisclosureLeftCentered, {
75
75
  color: "inherit",
76
76
  size: size === 'xs' ? 'xs' : 's'
77
77
  }));
@@ -82,7 +82,7 @@ var CalendarHeader = function CalendarHeader(_ref) {
82
82
  onClick: function onClick() {
83
83
  return onNext();
84
84
  }
85
- }, /*#__PURE__*/React.createElement(IconDisclosureRight.IconDisclosureRight, {
85
+ }, /*#__PURE__*/React.createElement(IconDisclosureRightCentered.IconDisclosureRightCentered, {
86
86
  color: "inherit",
87
87
  size: size === 'xs' ? 'xs' : 's'
88
88
  }));
@@ -1 +1 @@
1
- {"version":3,"file":"CalendarHeader.js","sources":["../../../../../src/components/Calendar/ui/CalendarHeader/CalendarHeader.tsx"],"sourcesContent":["import React, { useCallback, useMemo } from 'react';\n\nimport { IconDisclosureDownFill, IconDisclosureLeft, IconDisclosureRight } from '../../../_Icon';\nimport { CalendarState } from '../../store/types';\nimport { getCalendarType, MONTH_NAMES, YEAR_RENDER_COUNT } from '../../utils';\nimport type { DateObject } from '../../Calendar.types';\nimport { classes } from '../../Calendar.tokens';\nimport { sizeMap } from '../../store/reducer';\n\nimport type { CalendarHeaderProps } from './CalendarHeader.types';\nimport {\n StyledArrow,\n StyledArrows,\n StyledCalendarHeader,\n StyledDoubleHeaderWrapper,\n StyledHeader,\n StyledHeaderDate,\n StyledHeaderDouble,\n StyledNavigation,\n} from './CalendarHeader.styles';\n\n/**\n * Компонент шапки календаря.\n */\nexport const CalendarHeader: React.FC<CalendarHeaderProps> = ({\n type = 'Days',\n startYear = 0,\n size,\n firstDate,\n secondDate,\n isDouble,\n onPrev,\n onNext,\n onUpdateCalendarState,\n locale,\n}) => {\n const handleCalendarState = useCallback(() => {\n const newSize: [number, number] = isDouble ? sizeMap.Months.double : sizeMap.Months.single;\n\n if (type === CalendarState.Days) {\n onUpdateCalendarState?.(CalendarState.Months, newSize);\n }\n\n if (type === CalendarState.Months || type === CalendarState.Quarters) {\n onUpdateCalendarState?.(CalendarState.Years, newSize);\n }\n }, [type, onUpdateCalendarState]);\n\n const getHeaderContent = useCallback(\n (date?: DateObject, secondPart?: boolean) => {\n if (!date) {\n return '';\n }\n\n if (type === CalendarState.Days) {\n return (\n <>\n <StyledHeaderDate>{MONTH_NAMES[locale][date.monthIndex]}</StyledHeaderDate>\n <StyledHeaderDate>\n {date.year}\n <IconDisclosureDownFill color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledHeaderDate>\n </>\n );\n }\n\n if (type === CalendarState.Months || type === CalendarState.Quarters) {\n return (\n <StyledHeaderDate>\n {date.year}\n <IconDisclosureDownFill color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledHeaderDate>\n );\n }\n\n if (type === CalendarState.Years) {\n const yearValue = secondPart ? startYear + 12 : startYear;\n\n return (\n <StyledHeaderDate>\n {yearValue}—{yearValue + YEAR_RENDER_COUNT - 1}\n <IconDisclosureDownFill color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledHeaderDate>\n );\n }\n\n return '';\n },\n [type, startYear, size, locale],\n );\n\n const currentCalendarType = getCalendarType(type);\n\n const PreviousButton = useMemo(\n () => (\n <StyledArrow aria-label={`Предыдущий ${currentCalendarType}`} onClick={() => onPrev()}>\n <IconDisclosureLeft color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledArrow>\n ),\n [currentCalendarType, size, onPrev],\n );\n\n const NextButton = useMemo(\n () => (\n <StyledArrow aria-label={`Следующий ${currentCalendarType}`} onClick={() => onNext()}>\n <IconDisclosureRight color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledArrow>\n ),\n [currentCalendarType, size, onNext],\n );\n\n return (\n <StyledCalendarHeader>\n {isDouble ? (\n <StyledNavigation>\n <StyledDoubleHeaderWrapper>\n {PreviousButton}\n <StyledHeaderDouble onClick={handleCalendarState} aria-live=\"polite\">\n {getHeaderContent(firstDate)}\n </StyledHeaderDouble>\n </StyledDoubleHeaderWrapper>\n <StyledDoubleHeaderWrapper className={classes.doubleHeaderLastDateWrapper}>\n <StyledHeaderDouble onClick={handleCalendarState} aria-live=\"polite\">\n {getHeaderContent(secondDate, true)}\n </StyledHeaderDouble>\n {NextButton}\n </StyledDoubleHeaderWrapper>\n </StyledNavigation>\n ) : (\n <>\n <StyledHeader\n type=\"button\"\n aria-live=\"polite\"\n id=\"id-grid-label\"\n onClick={handleCalendarState}\n tabIndex={0}\n >\n {getHeaderContent(firstDate)}\n </StyledHeader>\n <StyledArrows>\n {PreviousButton}\n {NextButton}\n </StyledArrows>\n </>\n )}\n </StyledCalendarHeader>\n );\n};\n"],"names":["CalendarHeader","_ref","_ref$type","type","_ref$startYear","startYear","size","firstDate","secondDate","isDouble","onPrev","onNext","onUpdateCalendarState","locale","handleCalendarState","useCallback","newSize","sizeMap","Months","single","CalendarState","Days","Quarters","Years","getHeaderContent","date","secondPart","React","createElement","Fragment","StyledHeaderDate","MONTH_NAMES","monthIndex","year","IconDisclosureDownFill","color","yearValue","YEAR_RENDER_COUNT","currentCalendarType","getCalendarType","PreviousButton","useMemo","StyledArrow","concat","onClick","IconDisclosureLeft","NextButton","IconDisclosureRight","StyledCalendarHeader","StyledNavigation","StyledDoubleHeaderWrapper","StyledHeaderDouble","className","classes","doubleHeaderLastDateWrapper","StyledHeader","id","tabIndex","StyledArrows"],"mappings":";;;;;;;;;;;;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9B,mBAAoB;AAC7B2C,IAAAA,QAAQ,EAAE,CAAA;AAAE,GAAA,EAEXjC,gBAAgB,CAACjB,SAAS,CACjB,CAAC,eACfoB,KAAA,CAAAC,aAAA,CAAC8B,kCAAY,EACRlB,IAAAA,EAAAA,cAAc,EACdM,UACS,CAChB,CAEY,CAAC,CAAA;AAE/B;;;;"}
1
+ {"version":3,"file":"CalendarHeader.js","sources":["../../../../../src/components/Calendar/ui/CalendarHeader/CalendarHeader.tsx"],"sourcesContent":["import React, { useCallback, useMemo } from 'react';\n\nimport { IconDisclosureDownFill, IconDisclosureLeftCentered, IconDisclosureRightCentered } from '../../../_Icon';\nimport { CalendarState } from '../../store/types';\nimport { getCalendarType, MONTH_NAMES, YEAR_RENDER_COUNT } from '../../utils';\nimport type { DateObject } from '../../Calendar.types';\nimport { classes } from '../../Calendar.tokens';\nimport { sizeMap } from '../../store/reducer';\n\nimport type { CalendarHeaderProps } from './CalendarHeader.types';\nimport {\n StyledArrow,\n StyledArrows,\n StyledCalendarHeader,\n StyledDoubleHeaderWrapper,\n StyledHeader,\n StyledHeaderDate,\n StyledHeaderDouble,\n StyledNavigation,\n} from './CalendarHeader.styles';\n\n/**\n * Компонент шапки календаря.\n */\nexport const CalendarHeader: React.FC<CalendarHeaderProps> = ({\n type = 'Days',\n startYear = 0,\n size,\n firstDate,\n secondDate,\n isDouble,\n onPrev,\n onNext,\n onUpdateCalendarState,\n locale,\n}) => {\n const handleCalendarState = useCallback(() => {\n const newSize: [number, number] = isDouble ? sizeMap.Months.double : sizeMap.Months.single;\n\n if (type === CalendarState.Days) {\n onUpdateCalendarState?.(CalendarState.Months, newSize);\n }\n\n if (type === CalendarState.Months || type === CalendarState.Quarters) {\n onUpdateCalendarState?.(CalendarState.Years, newSize);\n }\n }, [type, onUpdateCalendarState]);\n\n const getHeaderContent = useCallback(\n (date?: DateObject, secondPart?: boolean) => {\n if (!date) {\n return '';\n }\n\n if (type === CalendarState.Days) {\n return (\n <>\n <StyledHeaderDate>{MONTH_NAMES[locale][date.monthIndex]}</StyledHeaderDate>\n <StyledHeaderDate>\n {date.year}\n <IconDisclosureDownFill color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledHeaderDate>\n </>\n );\n }\n\n if (type === CalendarState.Months || type === CalendarState.Quarters) {\n return (\n <StyledHeaderDate>\n {date.year}\n <IconDisclosureDownFill color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledHeaderDate>\n );\n }\n\n if (type === CalendarState.Years) {\n const yearValue = secondPart ? startYear + 12 : startYear;\n\n return (\n <StyledHeaderDate>\n {yearValue}—{yearValue + YEAR_RENDER_COUNT - 1}\n <IconDisclosureDownFill color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledHeaderDate>\n );\n }\n\n return '';\n },\n [type, startYear, size, locale],\n );\n\n const currentCalendarType = getCalendarType(type);\n\n const PreviousButton = useMemo(\n () => (\n <StyledArrow aria-label={`Предыдущий ${currentCalendarType}`} onClick={() => onPrev()}>\n <IconDisclosureLeftCentered color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledArrow>\n ),\n [currentCalendarType, size, onPrev],\n );\n\n const NextButton = useMemo(\n () => (\n <StyledArrow aria-label={`Следующий ${currentCalendarType}`} onClick={() => onNext()}>\n <IconDisclosureRightCentered color=\"inherit\" size={size === 'xs' ? 'xs' : 's'} />\n </StyledArrow>\n ),\n [currentCalendarType, size, onNext],\n );\n\n return (\n <StyledCalendarHeader>\n {isDouble ? (\n <StyledNavigation>\n <StyledDoubleHeaderWrapper>\n {PreviousButton}\n <StyledHeaderDouble onClick={handleCalendarState} aria-live=\"polite\">\n {getHeaderContent(firstDate)}\n </StyledHeaderDouble>\n </StyledDoubleHeaderWrapper>\n <StyledDoubleHeaderWrapper className={classes.doubleHeaderLastDateWrapper}>\n <StyledHeaderDouble onClick={handleCalendarState} aria-live=\"polite\">\n {getHeaderContent(secondDate, true)}\n </StyledHeaderDouble>\n {NextButton}\n </StyledDoubleHeaderWrapper>\n </StyledNavigation>\n ) : (\n <>\n <StyledHeader\n type=\"button\"\n aria-live=\"polite\"\n id=\"id-grid-label\"\n onClick={handleCalendarState}\n tabIndex={0}\n >\n {getHeaderContent(firstDate)}\n </StyledHeader>\n <StyledArrows>\n {PreviousButton}\n {NextButton}\n </StyledArrows>\n </>\n )}\n </StyledCalendarHeader>\n );\n};\n"],"names":["CalendarHeader","_ref","_ref$type","type","_ref$startYear","startYear","size","firstDate","secondDate","isDouble","onPrev","onNext","onUpdateCalendarState","locale","handleCalendarState","useCallback","newSize","sizeMap","Months","single","CalendarState","Days","Quarters","Years","getHeaderContent","date","secondPart","React","createElement","Fragment","StyledHeaderDate","MONTH_NAMES","monthIndex","year","IconDisclosureDownFill","color","yearValue","YEAR_RENDER_COUNT","currentCalendarType","getCalendarType","PreviousButton","useMemo","StyledArrow","concat","onClick","IconDisclosureLeftCentered","NextButton","IconDisclosureRightCentered","StyledCalendarHeader","StyledNavigation","StyledDoubleHeaderWrapper","StyledHeaderDouble","className","classes","doubleHeaderLastDateWrapper","StyledHeader","id","tabIndex","StyledArrows"],"mappings":";;;;;;;;;;;;;;;;AAqBA;AACA;AACA;IACaA,cAA6C,GAAG,SAAhDA,cAA6CA,CAAAC,IAAA,EAWpD;AAAA,EAAA,IAAAC,SAAA,GAAAD,IAAA,CAVFE,IAAI;AAAJA,IAAAA,IAAI,GAAAD,SAAA,KAAG,KAAA,CAAA,GAAA,MAAM,GAAAA,SAAA;IAAAE,cAAA,GAAAH,IAAA,CACbI,SAAS;AAATA,IAAAA,SAAS,GAAAD,cAAA,KAAG,KAAA,CAAA,GAAA,CAAC,GAAAA,cAAA;IACbE,IAAI,GAAAL,IAAA,CAAJK,IAAI;IACJC,SAAS,GAAAN,IAAA,CAATM,SAAS;IACTC,UAAU,GAAAP,IAAA,CAAVO,UAAU;IACVC,QAAQ,GAAAR,IAAA,CAARQ,QAAQ;IACRC,MAAM,GAAAT,IAAA,CAANS,MAAM;IACNC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AAA,IAAA,EACrBV,cAAc,eACfb,KAAA,CAAAC,aAAA,CAACuB,wCAAkB,EAAA;AAACP,IAAAA,OAAO,EAAE9B,mBAAoB;IAAC,WAAU,EAAA,QAAA;GACvDU,EAAAA,gBAAgB,CAACjB,SAAS,CACX,CACG,CAAC,eAC5BoB,KAAA,CAAAC,aAAA,CAACsB,+CAAyB,EAAA;IAACE,SAAS,EAAEC,uBAAO,CAACC,2BAAAA;AAA4B,GAAA,eACtE3B,KAAA,CAAAC,aAAA,CAACuB,wCAAkB,EAAA;AAACP,IAAAA,OAAO,EAAE9B,mBAAoB;IAAC,WAAU,EAAA,QAAA;GACvDU,EAAAA,gBAAgB,CAAChB,UAAU,EAAE,IAAI,CAClB,CAAC,EACpBsC,UACsB,CACb,CAAC,gBAEnBnB,KAAA,CAAAC,aAAA,CAAAD,KAAA,CAAAE,QAAA,qBACIF,KAAA,CAAAC,aAAA,CAAC2B,kCAAY,EAAA;AACTpD,IAAAA,IAAI,EAAC,QAAQ;AACb,IAAA,WAAA,EAAU,QAAQ;AAClBqD,IAAAA,EAAE,EAAC,eAAe;AAClBZ,IAAAA,OAAO,EAAE9B,mBAAoB;AAC7B2C,IAAAA,QAAQ,EAAE,CAAA;AAAE,GAAA,EAEXjC,gBAAgB,CAACjB,SAAS,CACjB,CAAC,eACfoB,KAAA,CAAAC,aAAA,CAAC8B,kCAAY,EACRlB,IAAAA,EAAAA,cAAc,EACdM,UACS,CAChB,CAEY,CAAC,CAAA;AAE/B;;;;"}
@@ -6,7 +6,11 @@ var classes = {
6
6
  selectedSegmentItem: 'selected-segment-item',
7
7
  segmentPilled: 'segment-pilled',
8
8
  segmentGroupFilledBackground: 'segment-group-filled-background',
9
- segmentStretch: 'segment-stretched'
9
+ segmentStretch: 'segment-stretched',
10
+ segmentVertical: 'segment-vertical',
11
+ segmentArrowPadding: 'segment-arrow-padding',
12
+ segmentXsSize: 'segment-xs-size',
13
+ segmentAdditionalText: 'segment-additional-text'
10
14
  };
11
15
  var tokens = {
12
16
  fontFamily: '--plasma-segment-item-font-family',
@@ -21,6 +25,8 @@ var tokens = {
21
25
  groupPilledBorderRadius: '--plasma-segment-group-pilled-border-radius',
22
26
  groupWidth: '--plasma-segment-group-width',
23
27
  groupHeight: '--plasma-segment-group-height',
28
+ groupArrowPadding: '--plasma-segment-group-arrow-padding',
29
+ groupVerticalArrowPadding: '--plasma-segment-group-vertical-arrow-padding',
24
30
  groupBackgroundColor: '--plasma-segment-group-background-color',
25
31
  groupFilledBackgroundColor: '--plasma-segment-group-filled-background-color',
26
32
  itemBorderRadius: '--plasma-segment-item-border-radius',
@@ -28,15 +34,22 @@ var tokens = {
28
34
  itemWidth: '--plasma-segment-item-width',
29
35
  itemHeight: '--plasma-segment-item-height',
30
36
  itemPadding: '--plasma-segment-item-padding',
37
+ itemPilledPadding: '--plasma-segment-item-pilled-padding',
31
38
  itemMarginLeft: '--plasma-segment-item-margin-left',
39
+ itemContentPadding: '--plasma-segment-item-content-padding',
40
+ itemIconMargin: '--plasma-segment-item-content-icon-margin',
32
41
  itemColor: '--plasma-segment-item-color',
33
42
  itemBackgroundColor: '--plasma-segment-item-background-color',
34
43
  itemColorHover: '--plasma-segment-item-color-hover',
35
44
  itemBackgroundColorHover: '--plasma-segment-item-background-color-hover',
45
+ itemAdditionalColor: '--plasma-segment-item-additional-color',
46
+ itemAdditionalColorHover: '--plasma-segment-item-additional-color-hover',
36
47
  itemSelectedColor: '--plasma-segment-item-selected-color',
37
48
  itemSelectedBackgroundColor: '--plasma-segment-item-selected-background-color',
38
49
  itemSelectedColorHover: '--plasma-segment-item-selected-color-hover',
39
50
  itemSelectedBackgroundColorHover: '--plasma-segment-item-selected-background-color-hover',
51
+ itemSelectedAdditionalColor: '--plasma-segment-item-selected-additional-color',
52
+ itemSelectedAdditionalColorHover: '--plasma-segment-item-selected-additional-color-hover',
40
53
  disabledOpacity: '--plasma-segment-disabled-opacity'
41
54
  };
42
55
 
@@ -1 +1 @@
1
- {"version":3,"file":"tokens.js","sources":["../../../src/components/Segment/tokens.ts"],"sourcesContent":["export const classes = {\n selectedSegmentItem: 'selected-segment-item',\n segmentPilled: 'segment-pilled',\n segmentGroupFilledBackground: 'segment-group-filled-background',\n segmentStretch: 'segment-stretched',\n};\n\nexport const tokens = {\n fontFamily: '--plasma-segment-item-font-family',\n fontSize: '--plasma-segment-item-font-size',\n fontStyle: '--plasma-segment-item-font-style',\n fontWeight: '--plasma-segment-item-font-weight',\n letterSpacing: '--plasma-segment-item-letter-spacing',\n lineHeight: '--plasma-segment-item-lineheight',\n\n outlineFocusColor: '--plasma-segment-outline-focus-color',\n\n arrowColor: '--plasma-segment-arrow-color',\n\n groupBorderRadius: '--plasma-segment-group-border-radius',\n groupPilledBorderRadius: '--plasma-segment-group-pilled-border-radius',\n groupWidth: '--plasma-segment-group-width',\n groupHeight: '--plasma-segment-group-height',\n\n groupBackgroundColor: '--plasma-segment-group-background-color',\n groupFilledBackgroundColor: '--plasma-segment-group-filled-background-color',\n\n itemBorderRadius: '--plasma-segment-item-border-radius',\n itemPilledBorderRadius: '--plasma-segment-item-pilled-border-radius',\n itemWidth: '--plasma-segment-item-width',\n itemHeight: '--plasma-segment-item-height',\n itemPadding: '--plasma-segment-item-padding',\n itemMarginLeft: '--plasma-segment-item-margin-left',\n\n itemColor: '--plasma-segment-item-color',\n itemBackgroundColor: '--plasma-segment-item-background-color',\n itemColorHover: '--plasma-segment-item-color-hover',\n itemBackgroundColorHover: '--plasma-segment-item-background-color-hover',\n\n itemSelectedColor: '--plasma-segment-item-selected-color',\n itemSelectedBackgroundColor: '--plasma-segment-item-selected-background-color',\n itemSelectedColorHover: '--plasma-segment-item-selected-color-hover',\n itemSelectedBackgroundColorHover: '--plasma-segment-item-selected-background-color-hover',\n\n disabledOpacity: '--plasma-segment-disabled-opacity',\n};\n"],"names":["classes","selectedSegmentItem","segmentPilled","segmentGroupFilledBackground","segmentStretch","tokens","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","outlineFocusColor","arrowColor","groupBorderRadius","groupPilledBorderRadius","groupWidth","groupHeight","groupBackgroundColor","groupFilledBackgroundColor","itemBorderRadius","itemPilledBorderRadius","itemWidth","itemHeight","itemPadding","itemMarginLeft","itemColor","itemBackgroundColor","itemColorHover","itemBackgroundColorHover","itemSelectedColor","itemSelectedBackgroundColor","itemSelectedColorHover","itemSelectedBackgroundColorHover","disabledOpacity"],"mappings":";;;;AAAO,IAAMA,OAAO,GAAG;AACnBC,EAAAA,mBAAmB,EAAE,uBAAuB;AAC5CC,EAAAA,aAAa,EAAE,gBAAgB;AAC/BC,EAAAA,4BAA4B,EAAE,iCAAiC;AAC/DC,EAAAA,cAAc,EAAE,mBAAA;AACpB,EAAC;AAEM,IAAMC,MAAM,GAAG;AAClBC,EAAAA,UAAU,EAAE,mCAAmC;AAC/CC,EAAAA,QAAQ,EAAE,iCAAiC;AAC3CC,EAAAA,SAAS,EAAE,kCAAkC;AAC7CC,EAAAA,UAAU,EAAE,mCAAmC;AAC/CC,EAAAA,aAAa,EAAE,sCAAsC;AACrDC,EAAAA,UAAU,EAAE,kCAAkC;AAE9CC,EAAAA,iBAAiB,EAAE,sCAAsC;AAEzDC,EAAAA,UAAU,EAAE,8BAA8B;AAE1CC,EAAAA,iBAAiB,EAAE,sCAAsC;AACzDC,EAAAA,uBAAuB,EAAE,6CAA6C;AACtEC,EAAAA,UAAU,EAAE,8BAA8B;AAC1CC,EAAAA,WAAW,EAAE,+BAA+B;AAE5CC,EAAAA,oBAAoB,EAAE,yCAAyC;AAC/DC,EAAAA,0BAA0B,EAAE,gDAAgD;AAE5EC,EAAAA,gBAAgB,EAAE,qCAAqC;AACvDC,EAAAA,sBAAsB,EAAE,4CAA4C;AACpEC,EAAAA,SAAS,EAAE,6BAA6B;AACxCC,EAAAA,UAAU,EAAE,8BAA8B;AAC1CC,EAAAA,WAAW,EAAE,+BAA+B;AAC5CC,EAAAA,cAAc,EAAE,mCAAmC;AAEnDC,EAAAA,SAAS,EAAE,6BAA6B;AACxCC,EAAAA,mBAAmB,EAAE,wCAAwC;AAC7DC,EAAAA,cAAc,EAAE,mCAAmC;AACnDC,EAAAA,wBAAwB,EAAE,8CAA8C;AAExEC,EAAAA,iBAAiB,EAAE,sCAAsC;AACzDC,EAAAA,2BAA2B,EAAE,iDAAiD;AAC9EC,EAAAA,sBAAsB,EAAE,4CAA4C;AACpEC,EAAAA,gCAAgC,EAAE,uDAAuD;AAEzFC,EAAAA,eAAe,EAAE,mCAAA;AACrB;;;;;"}
1
+ {"version":3,"file":"tokens.js","sources":["../../../src/components/Segment/tokens.ts"],"sourcesContent":["export const classes = {\n selectedSegmentItem: 'selected-segment-item',\n segmentPilled: 'segment-pilled',\n segmentGroupFilledBackground: 'segment-group-filled-background',\n segmentStretch: 'segment-stretched',\n segmentVertical: 'segment-vertical',\n segmentArrowPadding: 'segment-arrow-padding',\n segmentXsSize: 'segment-xs-size',\n segmentAdditionalText: 'segment-additional-text',\n};\n\nexport const tokens = {\n fontFamily: '--plasma-segment-item-font-family',\n fontSize: '--plasma-segment-item-font-size',\n fontStyle: '--plasma-segment-item-font-style',\n fontWeight: '--plasma-segment-item-font-weight',\n letterSpacing: '--plasma-segment-item-letter-spacing',\n lineHeight: '--plasma-segment-item-lineheight',\n\n outlineFocusColor: '--plasma-segment-outline-focus-color',\n\n arrowColor: '--plasma-segment-arrow-color',\n\n groupBorderRadius: '--plasma-segment-group-border-radius',\n groupPilledBorderRadius: '--plasma-segment-group-pilled-border-radius',\n groupWidth: '--plasma-segment-group-width',\n groupHeight: '--plasma-segment-group-height',\n groupArrowPadding: '--plasma-segment-group-arrow-padding',\n groupVerticalArrowPadding: '--plasma-segment-group-vertical-arrow-padding',\n\n groupBackgroundColor: '--plasma-segment-group-background-color',\n groupFilledBackgroundColor: '--plasma-segment-group-filled-background-color',\n\n itemBorderRadius: '--plasma-segment-item-border-radius',\n itemPilledBorderRadius: '--plasma-segment-item-pilled-border-radius',\n itemWidth: '--plasma-segment-item-width',\n itemHeight: '--plasma-segment-item-height',\n itemPadding: '--plasma-segment-item-padding',\n itemPilledPadding: '--plasma-segment-item-pilled-padding',\n itemMarginLeft: '--plasma-segment-item-margin-left',\n itemContentPadding: '--plasma-segment-item-content-padding',\n itemIconMargin: '--plasma-segment-item-content-icon-margin',\n\n itemColor: '--plasma-segment-item-color',\n itemBackgroundColor: '--plasma-segment-item-background-color',\n itemColorHover: '--plasma-segment-item-color-hover',\n itemBackgroundColorHover: '--plasma-segment-item-background-color-hover',\n itemAdditionalColor: '--plasma-segment-item-additional-color',\n itemAdditionalColorHover: '--plasma-segment-item-additional-color-hover',\n\n itemSelectedColor: '--plasma-segment-item-selected-color',\n itemSelectedBackgroundColor: '--plasma-segment-item-selected-background-color',\n itemSelectedColorHover: '--plasma-segment-item-selected-color-hover',\n itemSelectedBackgroundColorHover: '--plasma-segment-item-selected-background-color-hover',\n itemSelectedAdditionalColor: '--plasma-segment-item-selected-additional-color',\n itemSelectedAdditionalColorHover: '--plasma-segment-item-selected-additional-color-hover',\n\n disabledOpacity: '--plasma-segment-disabled-opacity',\n};\n"],"names":["classes","selectedSegmentItem","segmentPilled","segmentGroupFilledBackground","segmentStretch","segmentVertical","segmentArrowPadding","segmentXsSize","segmentAdditionalText","tokens","fontFamily","fontSize","fontStyle","fontWeight","letterSpacing","lineHeight","outlineFocusColor","arrowColor","groupBorderRadius","groupPilledBorderRadius","groupWidth","groupHeight","groupArrowPadding","groupVerticalArrowPadding","groupBackgroundColor","groupFilledBackgroundColor","itemBorderRadius","itemPilledBorderRadius","itemWidth","itemHeight","itemPadding","itemPilledPadding","itemMarginLeft","itemContentPadding","itemIconMargin","itemColor","itemBackgroundColor","itemColorHover","itemBackgroundColorHover","itemAdditionalColor","itemAdditionalColorHover","itemSelectedColor","itemSelectedBackgroundColor","itemSelectedColorHover","itemSelectedBackgroundColorHover","itemSelectedAdditionalColor","itemSelectedAdditionalColorHover","disabledOpacity"],"mappings":";;;;AAAO,IAAMA,OAAO,GAA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AAc,EAAE,2CAA2C;AAE3DC,EAAAA,SAAS,EAAE,6BAA6B;AACxCC,EAAAA,mBAAmB,EAAE,wCAAwC;AAC7DC,EAAAA,cAAc,EAAE,mCAAmC;AACnDC,EAAAA,wBAAwB,EAAE,8CAA8C;AACxEC,EAAAA,mBAAmB,EAAE,wCAAwC;AAC7DC,EAAAA,wBAAwB,EAAE,8CAA8C;AAExEC,EAAAA,iBAAiB,EAAE,sCAAsC;AACzDC,EAAAA,2BAA2B,EAAE,iDAAiD;AAC9EC,EAAAA,sBAAsB,EAAE,4CAA4C;AACpEC,EAAAA,gCAAgC,EAAE,uDAAuD;AACzFC,EAAAA,2BAA2B,EAAE,iDAAiD;AAC9EC,EAAAA,gCAAgC,EAAE,uDAAuD;AAEzFC,EAAAA,eAAe,EAAE,mCAAA;AACrB;;;;;"}
@@ -1,18 +1,17 @@
1
- .IconRoot_7pl7ig_svvlqhf__32c458a1{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;width:var(--svvlqhf-0);height:var(--svvlqhf-0);-webkit-flex:0 0 var(--svvlqhf-0);-ms-flex:0 0 var(--svvlqhf-0);flex:0 0 var(--svvlqhf-0);}
2
-
3
- .base_m358nl_b16s69xg__c51d77df{width:var(--plasma-segment-group-width);height:var(--plasma-segment-group-height);--plasma_private-outline-radius:var(--plasma-segment-group-border-radius);border-radius:var(--plasma-segment-group-border-radius);}
1
+ .base_18cpjsq_b16s69xg__2d529a83{width:var(--plasma-segment-group-width);height:var(--plasma-segment-group-height);}.base_18cpjsq_b16s69xg__2d529a83:before{border-radius:var(--plasma-segment-group-border-radius);}
4
2
 
5
3
  .base_hsx1sr_bo2wq9n__1e99adcc{background-color:var(--plasma-segment-group-background-color);}
6
4
 
7
5
  .base_1n8kaiq_bvqq8jn__3fd538b8[disabled]{opacity:var(--plasma-segment-disabled-opacity);cursor:not-allowed;}
8
6
 
9
- .base_fqbatz_b1re0ohg__24d92a6d.base_fqbatz_segmentPilled__24d92a6d{--plasma_private-outline-radius:var(--plasma-segment-group-pilled-border-radius);border-radius:var(--plasma-segment-group-pilled-border-radius);}
7
+ .base_pxl3nb_b1re0ohg__002ee1a3.base_pxl3nb_segmentPilled__002ee1a3:before{border-radius:var(--plasma-segment-group-pilled-border-radius);}
10
8
 
11
- .base_escgtx_b13sjoz1__a1f0e6e1.base_escgtx_segmentGroupFilledBackground__a1f0e6e1{background-color:var(--plasma-segment-group-filled-background-color);}
9
+ .base_a7w5s0_b13sjoz1__a0df01cb{position:relative;}.base_a7w5s0_b13sjoz1__a0df01cb.base_a7w5s0_segmentGroupFilledBackground__a0df01cb:before{content:'';position:absolute;inset:-0.125rem;background-color:var(--plasma-segment-group-filled-background-color);}
12
10
 
13
11
  .base_74wj10_b1bb2stb__3b76a172.base_74wj10_segmentStretched__3b76a172{width:100%;}.base_74wj10_b1bb2stb__3b76a172.base_74wj10_segmentStretched__3b76a172 .base_74wj10_spuzt9m__3b76a172,.base_74wj10_b1bb2stb__3b76a172.base_74wj10_segmentStretched__3b76a172 .base_74wj10_sin9wo2__3b76a172,.base_74wj10_b1bb2stb__3b76a172.base_74wj10_segmentStretched__3b76a172 .base_74wj10_sin9wo2__3b76a172 > button{width:100%;}
14
12
 
15
- .SegmentGroup_styles_m9i9p0_b2sori2__a29c0677{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}
16
- .SegmentGroup_styles_m9i9p0_sin9wo2__a29c0677{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}
17
- .SegmentGroup_styles_m9i9p0_spuzt9m__a29c0677{position:relative;height:100%;margin:0;padding:0.25rem;overflow-x:auto;overflow-y:hidden;-webkit-scroll-behavior:smooth;-moz-scroll-behavior:smooth;-ms-scroll-behavior:smooth;scroll-behavior:smooth;-webkit-scroll-snap-type:x mandatory;-moz-scroll-snap-type:x mandatory;-ms-scroll-snap-type:x mandatory;scroll-snap-type:x mandatory;}.SegmentGroup_styles_m9i9p0_spuzt9m__a29c0677::-webkit-scrollbar{display:none;}
18
- .SegmentGroup_styles_m9i9p0_s1qf4oye__a29c0677{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;cursor:pointer;border:none;background-color:transparent;padding:0;outline:none;position:relative;}.SegmentGroup_styles_m9i9p0_s1qf4oye__a29c0677::before{content:'';position:absolute;top:-0.125rem;left:-0.125rem;right:-0.125rem;bottom:-0.125rem;z-index:1;display:block;box-sizing:content-box;border:0.063rem solid transparent;border-radius:calc(var(--plasma_private-outline-radius) - 0.063rem);-webkit-transition:box-shadow 0.2s ease-in-out;transition:box-shadow 0.2s ease-in-out;pointer-events:none;}.SegmentGroup_styles_m9i9p0_s1qf4oye__a29c0677.SegmentGroup_styles_m9i9p0_focusVisible__a29c0677:focus::before,.SegmentGroup_styles_m9i9p0_s1qf4oye__a29c0677[data-focus-visible-added]::before{outline:none;box-shadow:0 0 0 0.063rem var(--plasma-segment-outline-focus-color);}.SegmentGroup_styles_m9i9p0_s1qf4oye__a29c0677[disabled]{cursor:not-allowed;}
13
+ .base_1ejecy9_bb2d6sr__61b9631c.base_1ejecy9_segmentVertical__61b9631c{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}.base_1ejecy9_bb2d6sr__61b9631c.base_1ejecy9_segmentVertical__61b9631c .base_1ejecy9_spuzt9m__61b9631c{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}.base_1ejecy9_bb2d6sr__61b9631c.base_1ejecy9_segmentVertical__61b9631c .base_1ejecy9_sin9wo2__61b9631c{-webkit-flex-direction:column;-ms-flex-direction:column;flex-direction:column;}
14
+
15
+ .SegmentGroup_styles_klze6h_b2sori2__dfb131db{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-width:100%;}.SegmentGroup_styles_klze6h_b2sori2__dfb131db:before{border-radius:var(--plasma-segment-group-border-radius);}
16
+ .SegmentGroup_styles_klze6h_sin9wo2__dfb131db{display:-webkit-inline-box;display:-webkit-inline-flex;display:-ms-inline-flexbox;display:inline-flex;-webkit-flex-direction:row;-ms-flex-direction:row;flex-direction:row;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;max-width:100%;}
17
+ .SegmentGroup_styles_klze6h_spuzt9m__dfb131db{position:relative;height:100%;width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-align-items:center;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}