@daisforge/ui 1.12.0 → 1.12.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (471) hide show
  1. package/chunks/AnalyticalWidget-CBi-2MtJ.mjs +528 -0
  2. package/chunks/AnalyticalWidget-fBDe37Ur.cjs +43 -0
  3. package/chunks/ApprovalCenter-ClCoA3cr.mjs +176 -0
  4. package/chunks/ApprovalCenter-oACSjXxE.cjs +1 -0
  5. package/chunks/BlockTitle-CylSY2DM.cjs +1 -0
  6. package/chunks/BlockTitle-DTaIqiFF.mjs +85 -0
  7. package/chunks/Container-CV4sT-bB.mjs +117 -0
  8. package/chunks/Container-D8Bcg69e.cjs +17 -0
  9. package/chunks/EmptyState-BD6Ic-OX.cjs +1 -0
  10. package/chunks/EmptyState-Bct6Wrxv.mjs +459 -0
  11. package/chunks/FiltersActions-C3yWFtQT.mjs +429 -0
  12. package/chunks/FiltersActions-D1aQXh5d.cjs +1 -0
  13. package/chunks/FormDatePickers-BefllAQ_.cjs +1 -0
  14. package/chunks/FormDatePickers-_soI8Uaa.mjs +503 -0
  15. package/chunks/FormSegmentGroup-C8kROjlQ.mjs +168 -0
  16. package/chunks/FormSegmentGroup-DIaBZRWv.cjs +1 -0
  17. package/chunks/FormTextArea-BBYV56iU.mjs +107 -0
  18. package/chunks/FormTextArea-C7KG9PXC.cjs +1 -0
  19. package/chunks/GridDND-BP_H26We.cjs +1 -0
  20. package/chunks/GridDND-rVSi0xX1.mjs +852 -0
  21. package/chunks/LeftPanel-CgexykUg.cjs +1 -0
  22. package/chunks/LeftPanel-bKmeEOHx.mjs +162 -0
  23. package/chunks/ListOfFilters-DgInAZFi.cjs +1 -0
  24. package/chunks/ListOfFilters-IEPKSKxx.mjs +243 -0
  25. package/chunks/MassActions-BCgI08G9.cjs +1 -0
  26. package/chunks/MassActions-D4nb1_gx.mjs +966 -0
  27. package/chunks/PageTitle-B0tuR3fU.mjs +123 -0
  28. package/chunks/PageTitle-BC0PnHgQ.cjs +1 -0
  29. package/chunks/SplitView-C8de8YKV.mjs +236 -0
  30. package/chunks/SplitView-OUGciQ51.cjs +12 -0
  31. package/chunks/Stories--_pE4YtR.mjs +668 -0
  32. package/chunks/Stories-Dvh6rMeV.cjs +1 -0
  33. package/chunks/Table-Bj2se1hR.mjs +7757 -0
  34. package/chunks/Table-CnWVNNoW.cjs +31 -0
  35. package/chunks/TableCanvas-Y53zQ7M0.mjs +11857 -0
  36. package/chunks/TableCanvas-eYhmqTbp.cjs +30 -0
  37. package/chunks/{TableGlide-B61Yi-Hs.mjs → TableGlide-CuBMIM6Q.mjs} +1417 -1554
  38. package/chunks/TableGlide-CvMz7x7a.cjs +1 -0
  39. package/chunks/styles-Dd4uEa27.mjs +128 -0
  40. package/chunks/styles-kPI9R7DO.cjs +2 -0
  41. package/chunks/{utils-BNelzuI-.mjs → utils-C5SQhoON.mjs} +126 -151
  42. package/chunks/utils-DKi1rqLX.cjs +25 -0
  43. package/chunks/{vendor-D8Dozc4m.cjs → vendor-BauZZ2hr.mjs} +7 -33
  44. package/chunks/{vendor-BG4P-329.mjs → vendor-C47eH0xy.cjs} +2 -634
  45. package/components/AiAgentPopover/index.cjs +2 -2
  46. package/components/AiAgentPopover/index.mjs +248 -373
  47. package/components/AnalyticalWidget/components/AnalyticalWidgetChips/index.cjs +1 -1
  48. package/components/AnalyticalWidget/components/AnalyticalWidgetChips/index.mjs +1 -1
  49. package/components/AnalyticalWidget/components/AnalyticalWidgetHeader/index.cjs +1 -1
  50. package/components/AnalyticalWidget/components/AnalyticalWidgetHeader/index.mjs +1 -1
  51. package/components/AnalyticalWidget/index.cjs +1 -1
  52. package/components/AnalyticalWidget/index.mjs +1 -1
  53. package/components/ApprovalCenter/components/index.cjs +1 -1
  54. package/components/ApprovalCenter/components/index.mjs +1 -1
  55. package/components/ApprovalCenter/index.cjs +1 -1
  56. package/components/ApprovalCenter/index.mjs +1 -1
  57. package/components/Autocomplete/index.cjs +1 -1
  58. package/components/Autocomplete/index.mjs +22 -35
  59. package/components/AutocompleteSearch/index.cjs +1 -1
  60. package/components/AutocompleteSearch/index.mjs +33 -83
  61. package/components/BlockGradientScroll/index.cjs +1 -1
  62. package/components/BlockGradientScroll/index.mjs +41 -53
  63. package/components/BlockTitle/index.cjs +1 -1
  64. package/components/BlockTitle/index.mjs +1 -1
  65. package/components/BlockTitle/utils/index.cjs +1 -1
  66. package/components/BlockTitle/utils/index.mjs +1 -1
  67. package/components/Box/index.mjs +17 -7
  68. package/components/Collapse/index.cjs +1 -1
  69. package/components/Collapse/index.mjs +41 -62
  70. package/components/Combobox/index.cjs +1 -1
  71. package/components/Combobox/index.mjs +1 -1
  72. package/components/DatePicker/index.cjs +1 -1
  73. package/components/DatePicker/index.mjs +21 -59
  74. package/components/DrawerDF/index.cjs +1 -1
  75. package/components/DrawerDF/index.mjs +144 -391
  76. package/components/EmptyState/components/index.cjs +1 -1
  77. package/components/EmptyState/components/index.mjs +1 -1
  78. package/components/EmptyState/index.cjs +1 -1
  79. package/components/EmptyState/index.mjs +1 -1
  80. package/components/GridDND/index.cjs +1 -1
  81. package/components/GridDND/index.mjs +1 -1
  82. package/components/GridDND/utils/index.cjs +1 -1
  83. package/components/GridDND/utils/index.mjs +1 -1
  84. package/components/IconButton/index.cjs +1 -1
  85. package/components/IconButton/index.mjs +49 -112
  86. package/components/IconSvgSprite/index.cjs +1 -1
  87. package/components/IconSvgSprite/index.mjs +13 -49
  88. package/components/LeftPanel/components/index.cjs +1 -1
  89. package/components/LeftPanel/components/index.mjs +1 -1
  90. package/components/LeftPanel/hooks/index.cjs +1 -1
  91. package/components/LeftPanel/hooks/index.mjs +1 -1
  92. package/components/LeftPanel/index.cjs +1 -1
  93. package/components/LeftPanel/index.mjs +1 -1
  94. package/components/LeftPanel/utils/index.cjs +1 -1
  95. package/components/LeftPanel/utils/index.mjs +1 -1
  96. package/components/ListOfFilters/index.cjs +1 -1
  97. package/components/ListOfFilters/index.mjs +1 -1
  98. package/components/MassActions/hooks/index.cjs +1 -1
  99. package/components/MassActions/hooks/index.mjs +1 -1
  100. package/components/MassActions/index.cjs +1 -1
  101. package/components/MassActions/index.mjs +1 -1
  102. package/components/MassActionsStatic/index.cjs +2 -2
  103. package/components/MassActionsStatic/index.mjs +13 -34
  104. package/components/ModalDF/index.cjs +1 -1
  105. package/components/ModalDF/index.mjs +169 -381
  106. package/components/ModalDFConfirmation/index.cjs +1 -1
  107. package/components/ModalDFConfirmation/index.mjs +66 -114
  108. package/components/Notification/index.cjs +1 -1
  109. package/components/Notification/index.mjs +16 -22
  110. package/components/NumberFormat/index.cjs +1 -1
  111. package/components/NumberFormat/index.mjs +24 -37
  112. package/components/NumberFormatAmount/index.cjs +1 -1
  113. package/components/NumberFormatAmount/index.mjs +12 -27
  114. package/components/PageTitle/index.cjs +1 -1
  115. package/components/PageTitle/index.mjs +1 -1
  116. package/components/PageTitle/utils/index.cjs +1 -1
  117. package/components/PageTitle/utils/index.mjs +1 -1
  118. package/components/PopoverDF/index.cjs +1 -1
  119. package/components/PopoverDF/index.mjs +125 -261
  120. package/components/PopupDF/index.cjs +1 -1
  121. package/components/PopupDF/index.mjs +141 -308
  122. package/components/SplitView/index.cjs +1 -1
  123. package/components/SplitView/index.mjs +1 -1
  124. package/components/SplitView/utils/index.cjs +1 -1
  125. package/components/SplitView/utils/index.mjs +1 -1
  126. package/components/Stories/components/StoriesBanner/index.cjs +1 -1
  127. package/components/Stories/components/StoriesBanner/index.mjs +1 -1
  128. package/components/Stories/components/StoriesContent/index.cjs +1 -1
  129. package/components/Stories/components/StoriesContent/index.mjs +1 -1
  130. package/components/Stories/components/StoriesPreview/index.cjs +1 -1
  131. package/components/Stories/components/StoriesPreview/index.mjs +1 -1
  132. package/components/Stories/components/StoriesProgress/index.cjs +1 -1
  133. package/components/Stories/components/StoriesProgress/index.mjs +1 -1
  134. package/components/Stories/components/StoriesViewer/index.cjs +1 -1
  135. package/components/Stories/components/StoriesViewer/index.mjs +1 -1
  136. package/components/Stories/index.cjs +1 -1
  137. package/components/Stories/index.mjs +1 -1
  138. package/components/Table/components/TableDropdown/index.cjs +1 -1
  139. package/components/Table/components/TableDropdown/index.mjs +1 -1
  140. package/components/Table/feature-collapse-table/index.cjs +1 -1
  141. package/components/Table/feature-collapse-table/index.mjs +1 -1
  142. package/components/Table/feature-column-control/ColumnsList/index.cjs +1 -1
  143. package/components/Table/feature-column-control/ColumnsList/index.mjs +1 -1
  144. package/components/Table/feature-column-control/index.cjs +1 -1
  145. package/components/Table/feature-column-control/index.mjs +1 -1
  146. package/components/Table/feature-columns-grouping/index.cjs +1 -1
  147. package/components/Table/feature-columns-grouping/index.mjs +1 -1
  148. package/components/Table/feature-context-menu/index.cjs +1 -1
  149. package/components/Table/feature-context-menu/index.mjs +1 -1
  150. package/components/Table/feature-edit/index.cjs +1 -1
  151. package/components/Table/feature-edit/index.mjs +1 -1
  152. package/components/Table/feature-filtering/combobox/index.cjs +1 -1
  153. package/components/Table/feature-filtering/combobox/index.mjs +1 -1
  154. package/components/Table/feature-filtering/filter-list-block/index.cjs +1 -1
  155. package/components/Table/feature-filtering/filter-list-block/index.mjs +1 -1
  156. package/components/Table/feature-filtering/header-filter-button/index.cjs +1 -1
  157. package/components/Table/feature-filtering/header-filter-button/index.mjs +1 -1
  158. package/components/Table/feature-filtering/index.cjs +1 -1
  159. package/components/Table/feature-filtering/index.mjs +1 -1
  160. package/components/Table/feature-filtering/sidebar-filter-block/index.cjs +1 -1
  161. package/components/Table/feature-filtering/sidebar-filter-block/index.mjs +1 -1
  162. package/components/Table/feature-infinity-scroll/index.cjs +1 -1
  163. package/components/Table/feature-infinity-scroll/index.mjs +1 -1
  164. package/components/Table/feature-key-text/index.cjs +1 -1
  165. package/components/Table/feature-key-text/index.mjs +1 -1
  166. package/components/Table/feature-pagination/index.cjs +1 -1
  167. package/components/Table/feature-pagination/index.mjs +1 -1
  168. package/components/Table/feature-right-sidebar/index.cjs +1 -1
  169. package/components/Table/feature-right-sidebar/index.mjs +1 -1
  170. package/components/Table/feature-row-detail/index.cjs +1 -1
  171. package/components/Table/feature-row-detail/index.mjs +1 -1
  172. package/components/Table/feature-row-instruments/index.cjs +1 -1
  173. package/components/Table/feature-row-instruments/index.mjs +1 -1
  174. package/components/Table/feature-row-size/index.cjs +1 -1
  175. package/components/Table/feature-row-size/index.mjs +1 -1
  176. package/components/Table/feature-rows-grouping/index.cjs +1 -1
  177. package/components/Table/feature-rows-grouping/index.mjs +1 -1
  178. package/components/Table/feature-searching/index.cjs +1 -1
  179. package/components/Table/feature-searching/index.mjs +1 -1
  180. package/components/Table/feature-select-row/index.cjs +1 -1
  181. package/components/Table/feature-select-row/index.mjs +1 -1
  182. package/components/Table/feature-sorting/index.cjs +1 -1
  183. package/components/Table/feature-sorting/index.mjs +1 -1
  184. package/components/Table/feature-table-settings/index.cjs +1 -1
  185. package/components/Table/feature-table-settings/index.mjs +1 -1
  186. package/components/Table/feature-tree/index.cjs +1 -1
  187. package/components/Table/feature-tree/index.mjs +1 -1
  188. package/components/Table/index.cjs +1 -1
  189. package/components/Table/index.mjs +1 -1
  190. package/components/Table/renders/formatCell/index.cjs +1 -1
  191. package/components/Table/renders/formatCell/index.mjs +1 -1
  192. package/components/Table/styles/index.cjs +1 -1
  193. package/components/Table/styles/index.mjs +1 -1
  194. package/components/Table/table-hooks/index.cjs +1 -1
  195. package/components/Table/table-hooks/index.mjs +1 -1
  196. package/components/Table/types/index.cjs +1 -1
  197. package/components/Table/types/index.mjs +1 -1
  198. package/components/Table/utils/index.cjs +1 -1
  199. package/components/Table/utils/index.mjs +1 -1
  200. package/components/Table/widgets/control-block/index.cjs +1 -1
  201. package/components/Table/widgets/control-block/index.mjs +1 -1
  202. package/components/Table/widgets/control-block/right-side/index.cjs +1 -1
  203. package/components/Table/widgets/control-block/right-side/index.mjs +1 -1
  204. package/components/Table/widgets/index.cjs +1 -1
  205. package/components/Table/widgets/index.mjs +1 -1
  206. package/components/Table/widgets/mass-actions/index.cjs +1 -1
  207. package/components/Table/widgets/mass-actions/index.mjs +1 -1
  208. package/components/TableCanvas/TableGlideInstance/adapters/column/index.cjs +1 -1
  209. package/components/TableCanvas/TableGlideInstance/adapters/column/index.mjs +1 -1
  210. package/components/TableCanvas/TableGlideInstance/adapters/index.cjs +1 -1
  211. package/components/TableCanvas/TableGlideInstance/adapters/index.mjs +1 -1
  212. package/components/TableCanvas/TableGlideInstance/index.cjs +1 -1
  213. package/components/TableCanvas/TableGlideInstance/index.mjs +2 -2
  214. package/components/TableCanvas/TableGlideInstance/utils/column/index.cjs +1 -1
  215. package/components/TableCanvas/TableGlideInstance/utils/column/index.mjs +1 -1
  216. package/components/TableCanvas/TableGlideInstance/utils/index.cjs +1 -1
  217. package/components/TableCanvas/TableGlideInstance/utils/index.mjs +1 -1
  218. package/components/TableCanvas/components/SplitIconButton/index.cjs +1 -1
  219. package/components/TableCanvas/components/SplitIconButton/index.mjs +1 -1
  220. package/components/TableCanvas/components/TableDropdown/index.cjs +1 -1
  221. package/components/TableCanvas/components/TableDropdown/index.mjs +1 -1
  222. package/components/TableCanvas/feature-cell-transfer/index.cjs +1 -1
  223. package/components/TableCanvas/feature-cell-transfer/index.mjs +1 -1
  224. package/components/TableCanvas/feature-collapse-table/index.cjs +1 -1
  225. package/components/TableCanvas/feature-collapse-table/index.mjs +1 -1
  226. package/components/TableCanvas/feature-column-control/ColumnsList/index.cjs +1 -1
  227. package/components/TableCanvas/feature-column-control/ColumnsList/index.mjs +1 -1
  228. package/components/TableCanvas/feature-column-control/index.cjs +1 -1
  229. package/components/TableCanvas/feature-column-control/index.mjs +1 -1
  230. package/components/TableCanvas/feature-columns-grouping/index.cjs +1 -1
  231. package/components/TableCanvas/feature-columns-grouping/index.mjs +1 -1
  232. package/components/TableCanvas/feature-content-state/index.cjs +1 -1
  233. package/components/TableCanvas/feature-content-state/index.mjs +1 -1
  234. package/components/TableCanvas/feature-context-menu/index.cjs +1 -1
  235. package/components/TableCanvas/feature-context-menu/index.mjs +1 -1
  236. package/components/TableCanvas/feature-edit/index.cjs +1 -1
  237. package/components/TableCanvas/feature-edit/index.mjs +1 -1
  238. package/components/TableCanvas/feature-filtering/combobox/index.cjs +1 -1
  239. package/components/TableCanvas/feature-filtering/combobox/index.mjs +3 -3
  240. package/components/TableCanvas/feature-filtering/filter-list-block/index.cjs +1 -1
  241. package/components/TableCanvas/feature-filtering/filter-list-block/index.mjs +1 -1
  242. package/components/TableCanvas/feature-filtering/header-filter-button/index.cjs +1 -1
  243. package/components/TableCanvas/feature-filtering/header-filter-button/index.mjs +1 -1
  244. package/components/TableCanvas/feature-filtering/index.cjs +1 -1
  245. package/components/TableCanvas/feature-filtering/index.mjs +1 -1
  246. package/components/TableCanvas/feature-filtering/sidebar-filter-block/index.cjs +1 -1
  247. package/components/TableCanvas/feature-filtering/sidebar-filter-block/index.mjs +1 -1
  248. package/components/TableCanvas/feature-infinity-scroll/index.cjs +1 -1
  249. package/components/TableCanvas/feature-infinity-scroll/index.mjs +1 -1
  250. package/components/TableCanvas/feature-key-text/index.cjs +1 -1
  251. package/components/TableCanvas/feature-key-text/index.mjs +1 -1
  252. package/components/TableCanvas/feature-notifications/index.cjs +1 -1
  253. package/components/TableCanvas/feature-notifications/index.mjs +1 -1
  254. package/components/TableCanvas/feature-pagination/index.cjs +1 -1
  255. package/components/TableCanvas/feature-pagination/index.mjs +1 -1
  256. package/components/TableCanvas/feature-popover-table/context/index.cjs +1 -1
  257. package/components/TableCanvas/feature-popover-table/context/index.mjs +1 -1
  258. package/components/TableCanvas/feature-popover-table/hooks/index.cjs +1 -1
  259. package/components/TableCanvas/feature-popover-table/hooks/index.mjs +1 -1
  260. package/components/TableCanvas/feature-popover-table/index.cjs +1 -1
  261. package/components/TableCanvas/feature-popover-table/index.mjs +1 -1
  262. package/components/TableCanvas/feature-popover-table/utils/index.cjs +1 -1
  263. package/components/TableCanvas/feature-popover-table/utils/index.mjs +1 -1
  264. package/components/TableCanvas/feature-right-sidebar/index.cjs +1 -1
  265. package/components/TableCanvas/feature-right-sidebar/index.mjs +1 -1
  266. package/components/TableCanvas/feature-row-detail/index.cjs +1 -1
  267. package/components/TableCanvas/feature-row-detail/index.mjs +1 -1
  268. package/components/TableCanvas/feature-row-instruments/index.cjs +1 -1
  269. package/components/TableCanvas/feature-row-instruments/index.mjs +1 -1
  270. package/components/TableCanvas/feature-row-markers/index.cjs +1 -1
  271. package/components/TableCanvas/feature-row-markers/index.mjs +1 -1
  272. package/components/TableCanvas/feature-row-size/index.cjs +1 -1
  273. package/components/TableCanvas/feature-row-size/index.mjs +1 -1
  274. package/components/TableCanvas/feature-rows-grouping/index.cjs +1 -1
  275. package/components/TableCanvas/feature-rows-grouping/index.mjs +1 -1
  276. package/components/TableCanvas/feature-searching/index.cjs +1 -1
  277. package/components/TableCanvas/feature-searching/index.mjs +1 -1
  278. package/components/TableCanvas/feature-select-row/index.cjs +1 -1
  279. package/components/TableCanvas/feature-select-row/index.mjs +1 -1
  280. package/components/TableCanvas/feature-sorting/index.cjs +1 -1
  281. package/components/TableCanvas/feature-sorting/index.mjs +1 -1
  282. package/components/TableCanvas/feature-table-settings/TableSettingsWithTabs.d.ts +25 -2
  283. package/components/TableCanvas/feature-table-settings/index.cjs +1 -1
  284. package/components/TableCanvas/feature-table-settings/index.d.ts +1 -1
  285. package/components/TableCanvas/feature-table-settings/index.mjs +3 -2
  286. package/components/TableCanvas/feature-tooltip/index.cjs +1 -1
  287. package/components/TableCanvas/feature-tooltip/index.mjs +1 -1
  288. package/components/TableCanvas/feature-tooltip/utils/index.cjs +1 -1
  289. package/components/TableCanvas/feature-tooltip/utils/index.mjs +1 -1
  290. package/components/TableCanvas/feature-tree/index.cjs +1 -1
  291. package/components/TableCanvas/feature-tree/index.mjs +1 -1
  292. package/components/TableCanvas/index.cjs +1 -1
  293. package/components/TableCanvas/index.mjs +2 -2
  294. package/components/TableCanvas/renders/formatCell/index.cjs +1 -1
  295. package/components/TableCanvas/renders/formatCell/index.mjs +1 -1
  296. package/components/TableCanvas/styles/index.cjs +1 -1
  297. package/components/TableCanvas/styles/index.mjs +1 -1
  298. package/components/TableCanvas/table-hooks/index.cjs +1 -1
  299. package/components/TableCanvas/table-hooks/index.mjs +1 -1
  300. package/components/TableCanvas/types/index.cjs +1 -1
  301. package/components/TableCanvas/types/index.mjs +1 -1
  302. package/components/TableCanvas/types/table-config.type.d.ts +4 -0
  303. package/components/TableCanvas/utils/index.cjs +1 -1
  304. package/components/TableCanvas/utils/index.mjs +2 -2
  305. package/components/TableCanvas/widgets/control-block/compression/index.cjs +1 -1
  306. package/components/TableCanvas/widgets/control-block/compression/index.mjs +1 -1
  307. package/components/TableCanvas/widgets/control-block/index.cjs +1 -1
  308. package/components/TableCanvas/widgets/control-block/index.mjs +1 -1
  309. package/components/TableCanvas/widgets/control-block/right-side/index.cjs +1 -1
  310. package/components/TableCanvas/widgets/control-block/right-side/index.mjs +1 -1
  311. package/components/TableCanvas/widgets/index.cjs +1 -1
  312. package/components/TableCanvas/widgets/index.mjs +1 -1
  313. package/components/TableCanvas/widgets/mass-actions/hooks/index.cjs +1 -1
  314. package/components/TableCanvas/widgets/mass-actions/hooks/index.mjs +1 -1
  315. package/components/TableCanvas/widgets/mass-actions/index.cjs +1 -1
  316. package/components/TableCanvas/widgets/mass-actions/index.mjs +1 -1
  317. package/components/TableContract/index.cjs +2 -2
  318. package/components/TableContract/index.mjs +540 -798
  319. package/components/TableGlide/hooks/selection/index.cjs +1 -1
  320. package/components/TableGlide/hooks/selection/index.mjs +1 -1
  321. package/components/TableGlide/index.cjs +1 -1
  322. package/components/TableGlide/index.mjs +1 -1
  323. package/components/TableGlide/lib/canvas/cells/buttons/index.cjs +1 -1
  324. package/components/TableGlide/lib/canvas/cells/buttons/index.mjs +1 -1
  325. package/components/TableGlide/lib/canvas/cells/iconSprites/index.cjs +1 -1
  326. package/components/TableGlide/lib/canvas/cells/iconSprites/index.mjs +1 -1
  327. package/components/TableGlide/lib/canvas/cells/index.cjs +1 -1
  328. package/components/TableGlide/lib/canvas/cells/index.mjs +1 -1
  329. package/components/TableGlide/lib/canvas/cells/renderer/index.cjs +1 -1
  330. package/components/TableGlide/lib/canvas/cells/renderer/index.mjs +1 -1
  331. package/components/TableGlide/lib/canvas/core/helpers/index.cjs +1 -1
  332. package/components/TableGlide/lib/canvas/core/helpers/index.mjs +1 -1
  333. package/components/TableGlide/lib/canvas/core/index.cjs +1 -1
  334. package/components/TableGlide/lib/canvas/core/index.mjs +1 -1
  335. package/components/TableGlide/lib/canvas/hooks/index.cjs +1 -1
  336. package/components/TableGlide/lib/canvas/hooks/index.mjs +1 -1
  337. package/components/TableGlide/lib/canvas/index.cjs +1 -1
  338. package/components/TableGlide/lib/canvas/index.mjs +1 -1
  339. package/components/TableGlide/lib/canvas/miniflex/index.cjs +1 -1
  340. package/components/TableGlide/lib/canvas/miniflex/index.mjs +1 -1
  341. package/components/TableGlide/lib/canvas/primitives/index.cjs +1 -1
  342. package/components/TableGlide/lib/canvas/primitives/index.mjs +1 -1
  343. package/components/TableGlide/lib/canvas/utils/index.cjs +1 -1
  344. package/components/TableGlide/lib/canvas/utils/index.mjs +1 -1
  345. package/components/TableGlide/theming/index.cjs +1 -1
  346. package/components/TableGlide/theming/index.mjs +1 -1
  347. package/components/TableTabs/index.cjs +1 -1
  348. package/components/TableTabs/index.mjs +136 -305
  349. package/components/TextArea/index.cjs +1 -1
  350. package/components/TextArea/index.mjs +26 -40
  351. package/components/TextField/index.cjs +1 -1
  352. package/components/TextField/index.mjs +38 -82
  353. package/components/Tooltip/index.cjs +1 -1
  354. package/components/Tooltip/index.mjs +1 -1
  355. package/components/TourWidget/index.cjs +15 -15
  356. package/components/TourWidget/index.mjs +176 -371
  357. package/components/Typography/index.cjs +1 -1
  358. package/components/Typography/index.mjs +1 -1
  359. package/components/Widget/index.cjs +1 -1
  360. package/components/Widget/index.mjs +151 -363
  361. package/formComponents/FormAutocomplete/index.cjs +1 -1
  362. package/formComponents/FormAutocomplete/index.mjs +63 -68
  363. package/formComponents/FormCheckbox/index.cjs +1 -1
  364. package/formComponents/FormCheckbox/index.mjs +27 -55
  365. package/formComponents/FormCombobox/index.cjs +1 -1
  366. package/formComponents/FormCombobox/index.mjs +61 -75
  367. package/formComponents/FormDatePickers/FormDatePicker/index.cjs +1 -1
  368. package/formComponents/FormDatePickers/FormDatePicker/index.mjs +1 -1
  369. package/formComponents/FormDatePickers/FormDatePickerRange/index.cjs +1 -1
  370. package/formComponents/FormDatePickers/FormDatePickerRange/index.mjs +1 -1
  371. package/formComponents/FormDatePickers/FormDatePickerRange/lib/utils/index.cjs +1 -1
  372. package/formComponents/FormDatePickers/FormDatePickerRange/lib/utils/index.mjs +1 -1
  373. package/formComponents/FormDatePickers/index.cjs +1 -1
  374. package/formComponents/FormDatePickers/index.mjs +1 -1
  375. package/formComponents/FormMask/index.cjs +1 -1
  376. package/formComponents/FormMask/index.mjs +61 -66
  377. package/formComponents/FormNumberFormat/index.cjs +1 -1
  378. package/formComponents/FormNumberFormat/index.mjs +56 -68
  379. package/formComponents/FormRadioGroupBox/index.cjs +1 -1
  380. package/formComponents/FormRadioGroupBox/index.mjs +71 -144
  381. package/formComponents/FormSegments/index.cjs +1 -1
  382. package/formComponents/FormSegments/index.mjs +1 -1
  383. package/formComponents/FormSelect/index.cjs +1 -1
  384. package/formComponents/FormSelect/index.mjs +62 -76
  385. package/formComponents/FormSwitch/index.cjs +1 -1
  386. package/formComponents/FormSwitch/index.mjs +25 -53
  387. package/formComponents/FormTextArea/index.cjs +1 -1
  388. package/formComponents/FormTextArea/index.mjs +1 -1
  389. package/formComponents/FormTextArea/ui/index.cjs +1 -1
  390. package/formComponents/FormTextArea/ui/index.mjs +1 -1
  391. package/formComponents/FormTextField/index.cjs +1 -1
  392. package/formComponents/FormTextField/index.mjs +70 -101
  393. package/index.cjs +1 -1
  394. package/index.mjs +21 -21
  395. package/layouts/Container/index.cjs +1 -1
  396. package/layouts/Container/index.mjs +1 -1
  397. package/layouts/Container/lib/utils/index.cjs +1 -1
  398. package/layouts/Container/lib/utils/index.mjs +1 -1
  399. package/layouts/ErrorPage/index.cjs +1 -1
  400. package/layouts/ErrorPage/index.mjs +81 -146
  401. package/layouts/FiltersActions/hooks/index.cjs +1 -1
  402. package/layouts/FiltersActions/hooks/index.mjs +1 -1
  403. package/layouts/FiltersActions/index.cjs +1 -1
  404. package/layouts/FiltersActions/index.mjs +1 -1
  405. package/layouts/Layout/index.cjs +5 -5
  406. package/layouts/Layout/index.mjs +78 -115
  407. package/layouts/PageLayout/index.cjs +2 -2
  408. package/layouts/PageLayout/index.mjs +15 -32
  409. package/mixins/index.cjs +1 -1
  410. package/mixins/index.mjs +1 -1
  411. package/package.json +1 -1
  412. package/shared/ui/Search/index.cjs +1 -1
  413. package/shared/ui/Search/index.mjs +30 -52
  414. package/shared/utils/inputs/index.cjs +1 -1
  415. package/shared/utils/inputs/index.mjs +33 -48
  416. package/styles/index.cjs +1 -1
  417. package/styles/index.mjs +1 -1
  418. package/themes/index.cjs +1 -1
  419. package/themes/index.mjs +1 -1
  420. package/utils/breakpoint/index.cjs +1 -1
  421. package/utils/breakpoint/index.mjs +1 -1
  422. package/utils/clickStream/index.cjs +1 -1
  423. package/utils/clickStream/index.mjs +1 -1
  424. package/utils/eventBus/index.cjs +1 -1
  425. package/utils/eventBus/index.mjs +1 -1
  426. package/utils/hooks/index.cjs +1 -1
  427. package/utils/hooks/index.mjs +1 -1
  428. package/utils/index.cjs +1 -1
  429. package/utils/index.mjs +1 -1
  430. package/utils/styles/index.cjs +1 -1
  431. package/utils/styles/index.mjs +1 -1
  432. package/chunks/AnalyticalWidget-Ca_EuSTO.mjs +0 -868
  433. package/chunks/AnalyticalWidget-xgvWcsXx.cjs +0 -43
  434. package/chunks/ApprovalCenter-4aJlJfei.mjs +0 -531
  435. package/chunks/ApprovalCenter-Ij5NMkY-.cjs +0 -1
  436. package/chunks/BlockTitle-CgXVHok6.mjs +0 -180
  437. package/chunks/BlockTitle-SaP9H2PI.cjs +0 -1
  438. package/chunks/Container-ChuCs63G.cjs +0 -17
  439. package/chunks/Container-D8RdjkGo.mjs +0 -180
  440. package/chunks/EmptyState-BxUh2dhY.cjs +0 -1
  441. package/chunks/EmptyState-C0aHgxrn.mjs +0 -615
  442. package/chunks/FiltersActions-BekNxF-h.cjs +0 -1
  443. package/chunks/FiltersActions-CSucE-Ql.mjs +0 -637
  444. package/chunks/FormDatePickers-BCyW24Pr.cjs +0 -1
  445. package/chunks/FormDatePickers-DfdGdbwP.mjs +0 -538
  446. package/chunks/FormSegmentGroup-BKuHtPEn.cjs +0 -1
  447. package/chunks/FormSegmentGroup-DqFMVBr0.mjs +0 -268
  448. package/chunks/FormTextArea-CCrYx4pL.mjs +0 -159
  449. package/chunks/FormTextArea-sly1mY7h.cjs +0 -1
  450. package/chunks/GridDND-Bycwiynh.mjs +0 -1086
  451. package/chunks/GridDND-MsZt1fXJ.cjs +0 -1
  452. package/chunks/LeftPanel-C72uosX_.mjs +0 -303
  453. package/chunks/LeftPanel-Di-IqpZ_.cjs +0 -1
  454. package/chunks/ListOfFilters-B3bM1n4w.cjs +0 -1
  455. package/chunks/ListOfFilters-CPJGgMMc.mjs +0 -462
  456. package/chunks/MassActions-BbAXi3z9.cjs +0 -1
  457. package/chunks/MassActions-CZm8vqj8.mjs +0 -1352
  458. package/chunks/PageTitle-DEsijnDg.cjs +0 -1
  459. package/chunks/PageTitle-TusD1S2c.mjs +0 -282
  460. package/chunks/SplitView-BHdftJ9A.cjs +0 -12
  461. package/chunks/SplitView-Cd-xkxCe.mjs +0 -339
  462. package/chunks/Stories-CR_EUNO7.mjs +0 -1018
  463. package/chunks/Stories-CxsYx2OE.cjs +0 -1
  464. package/chunks/Table--05ONCr1.cjs +0 -31
  465. package/chunks/Table-l-P3NNUN.mjs +0 -11944
  466. package/chunks/TableCanvas-D-sndY82.cjs +0 -30
  467. package/chunks/TableCanvas-D4Bck7wv.mjs +0 -16900
  468. package/chunks/TableGlide-CbvaAM_H.cjs +0 -1
  469. package/chunks/styles-D8FDGdVz.mjs +0 -240
  470. package/chunks/styles-OR0WE1xm.cjs +0 -2
  471. package/chunks/utils-C93a2mD7.cjs +0 -25
@@ -0,0 +1 @@
1
+ "use strict";const c=require("react/jsx-runtime"),Y=require("@salutejs/plasma-icons"),Z=require("../components/Box/index.cjs"),ee=require("@salutejs/sdds-finai"),s=require("@salutejs/sdds-themes/tokens/sdds_finai"),h=require("styled-components"),$=require("./utils-DKi1rqLX.cjs"),n=require("react"),z={icon:"left-panel__toggle-button",leftBlockIsResizing:"left-panel__is-resizing"},te=72,ne=56,q=240,se=540,j=.2,oe=h(Z.Box).withConfig({displayName:"styled__PanelContainer"})(["width:100%;height:100%;min-width:","px;display:flex;background-color:",";margin-right:",";border-radius:",";box-shadow:",";transition:",";max-width:",";position:relative;overflow:hidden;padding-right:",";"],({minWidth:e})=>e,()=>s.surfaceSolidCard,s.spacing8x,s.spacing8x,()=>s.shadowDownSoftS,e=>e.$resizing?"none":`max-width ${j}s ease-in-out, opacity ${j}s ease-in-out`,e=>e.width!==void 0?`${Math.min(e.width,e.maxWidth)}px`:`${e.minWidth}px`,({showResizeable:e})=>e?s.spacing6x:0),ie=h.div.withConfig({displayName:"styled__PanelCrossfade"})(["flex:1 1 auto;min-width:0;height:100%;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr);overflow:hidden;"]),W=h.css(["grid-area:1 / 1;min-width:0;min-height:0;opacity:",";visibility:",";pointer-events:",";transition:opacity ","s ease-in-out,visibility 0s ",";"],({$active:e})=>e?1:0,({$active:e})=>e?"visible":"hidden",({$active:e})=>e?"auto":"none",j,({$active:e})=>e?"0s":`${j}s`),re=h.div.withConfig({displayName:"styled__PanelContent"})(["",";width:100%;height:100%;margin-top:0;position:relative;"],W),ae=h.div.withConfig({displayName:"styled__PanelCollapsedContent"})(["",";height:100%;position:relative;display:flex;flex-direction:column;align-items:center;justify-content:space-between;padding:",";width:100%;"],W,({$isAdaptive1280:e,showResizeable:t})=>t?e?"6px":"10px":s.spacing8x),le=h.div.withConfig({displayName:"styled__PanelCollapsedBody"})(["gap:",";display:flex;flex-direction:column;"],s.spacing8x),ce=h(ee.EmbedIconButton).withConfig({displayName:"styled__PanelIconButton"})(["z-index:1;position:",";top:",";right:",";width:","px !important;height:","px !important;.left-panel__toggle-button{transform:",";}"],e=>e.isAbsolute?"absolute":"static",s.spacing8x,s.spacing8x,({$isAdaptive1280:e})=>e?32:40,({$isAdaptive1280:e})=>e?32:40,e=>e.collapsed?"rotate(270deg)":"rotate(90deg)"),de=h.div.withConfig({displayName:"styled__PanelSeparator"})(["position:absolute;top:0;right:0px;width:12px;height:100%;cursor:col-resize;z-index:10;&::before{content:'';position:absolute;top:0;left:50%;transform:translateX(-50%);width:12px;height:100%;background-color:",";}&::after{content:'';position:absolute;top:",";left:50%;transform:translateX(-50%);border-radius:95px;width:4px;height:",";background-color:",";}&:hover{&::after{background-color:",";}}"],()=>s.surfaceSolidSecondary,`calc(50% - ${s.spacing16x} / 2)`,s.spacing16x,()=>s.outlineSolidSecondary,()=>s.outlineSolidSecondaryHover),k=({onClick:e,collapsed:t=!1,isAbsolute:i=!1,isAdaptive1280:r=!1,...u})=>c.jsx(ce,{onClick:e,$isAdaptive1280:r,collapsed:t,isAbsolute:i,view:"secondary",size:r?"s":"l",...u,children:c.jsx(Y.IconArrowBarDown,{className:z.icon})}),T=({setWidth:e,isResizingRef:t,setIsResizing:i,panelRef:r,minWidth:u,maxWidth:b,parentRef:P,isCollapsed:C,onResize:m})=>{const L=n.useCallback(()=>{var f;document.body.style.cursor="col-resize",document.body.style.userSelect="none",t.current=!0,i(!0),(f=r.current)==null||f.classList.add(z.leftBlockIsResizing)},[r,t,i]);return n.useEffect(()=>{const f=()=>{var _,a;document.body.style.cursor="auto",document.body.style.userSelect="",t.current=!1,i(!1),(_=r.current)==null||_.classList.remove(z.leftBlockIsResizing);const g=((a=r.current)==null?void 0:a.clientWidth)??0;g>u&&g<q&&e(u)},B=g=>{if(!t.current||!r.current||!P.current)return;g.preventDefault();const d=P.current.getBoundingClientRect(),a=g.clientX-d.left,l=$.clamp(u,a,b);e(l),!C&&m&&m(l)},x=$.throttleWithLastCall(B,16);return window.addEventListener("mousemove",x),window.addEventListener("mouseup",f),()=>{window.removeEventListener("mousemove",x),window.removeEventListener("mouseup",f)}},[e,t,i,r,u,b,P,C,m]),{startResizing:L}},X=e=>({buttonSize:e?"xs":"s"}),H=(e,t)=>t??(e?ne:te),E=(e,t)=>typeof e=="function"?e(t):e,O=({widthState:e,minWidth:t,maxWidth:i=se,disableMediaAdaptive:r=!1,collapseState:u,containerProps:b,contentProps:P,collapsedContentProps:C,expandedContent:m,collapsedContent:L,collapsedFooterContent:f,showToggleButton:B=!0,showResizeable:x=!0,onResize:g,onToggleCollapse:d})=>{const{down:_}=$.useBreakpoint(),a=!r&&_("xl"),l=H(a,t),w=n.useMemo(()=>X(a),[a]),R=n.useMemo(()=>E(m,w),[m,w]),F=n.useMemo(()=>E(L,w),[L,w]),K=n.useMemo(()=>E(f,w),[f,w]),V=n.useState(!1),[o,I]=u??V,G=n.useState(Number(o?l:i)),[y,v]=e??G,N=n.useRef(null),A=n.useRef(null),M=n.useRef(!1),[J,Q]=n.useState(!1),{startResizing:U}=T({setWidth:v,isResizingRef:M,setIsResizing:Q,panelRef:N,minWidth:l,maxWidth:i,parentRef:A,isCollapsed:o,onResize:g});n.useEffect(()=>{if(y!==void 0){const p=y<q;p!==o&&(I(p),d&&!M.current&&d(p))}},[y,o,d,I]),n.useEffect(()=>{!M.current&&o&&y!==l&&v(l)},[o,l,v,y]);const D=n.useCallback(()=>{I(p=>{const S=!p;return d&&d(S),v(S?l:i),S})},[d,I,v,l,i]);return c.jsxs(oe,{ref:N,collapsed:o,maxWidth:i,minWidth:l,width:y,$resizing:J,showResizeable:x,...b,children:[c.jsxs(ie,{children:[c.jsxs(re,{$active:!o,"aria-hidden":o,...P,children:[B&&c.jsx(k,{onClick:D,collapsed:o,isAdaptive1280:a,isAbsolute:!0}),R]}),c.jsxs(ae,{$active:o,"aria-hidden":!o,$isAdaptive1280:a,showResizeable:x,...C,children:[c.jsxs(le,{children:[B&&c.jsx(k,{onClick:D,collapsed:o,isAdaptive1280:a}),F]}),K]})]}),x&&c.jsx(de,{onMouseDown:p=>{var S;p.preventDefault(),(S=N.current)!=null&&S.parentElement&&(A.current=N.current.parentElement),U()}})]})};O.LeftPanelToggleButton=k;exports.LeftPanel=O;exports.LeftPanelToggleButton=k;exports.getLeftPanelMinWidth=H;exports.getLeftPanelSlotSizes=X;exports.renderLeftPanelSlot=E;exports.toggleButtonClassNames=z;exports.useResize=T;
@@ -0,0 +1,162 @@
1
+ import { jsx as S, jsxs as _ } from "react/jsx-runtime";
2
+ import { IconArrowBarDown as R } from "@salutejs/plasma-icons";
3
+ import { Box as tt } from "../components/Box/index.mjs";
4
+ import { EmbedIconButton as et } from "@salutejs/sdds-finai";
5
+ import { spacing8x as v, surfaceSolidCard as nt, shadowDownSoftS as ot, spacing6x as it, surfaceSolidSecondary as st, spacing16x as j, outlineSolidSecondary as rt, outlineSolidSecondaryHover as at } from "@salutejs/sdds-themes/tokens/sdds_finai";
6
+ import p, { css as lt } from "styled-components";
7
+ import { t as ct, e as dt, d as ut } from "./utils-C5SQhoON.mjs";
8
+ import { useCallback as O, useEffect as M, useMemo as B, useState as k, useRef as A } from "react";
9
+ const W = {
10
+ icon: "left-panel__toggle-button",
11
+ leftBlockIsResizing: "left-panel__is-resizing"
12
+ }, pt = 72, ft = 56, K = 240, mt = 540, z = 0.2, ht = p(tt).withConfig({
13
+ displayName: "styled__PanelContainer"
14
+ })(["width:100%;height:100%;min-width:", "px;display:flex;background-color:", ";margin-right:", ";border-radius:", ";box-shadow:", ";transition:", ";max-width:", ";position:relative;overflow:hidden;padding-right:", ";"], ({
15
+ minWidth: t
16
+ }) => t, () => nt, v, v, () => ot, (t) => t.$resizing ? "none" : `max-width ${z}s ease-in-out, opacity ${z}s ease-in-out`, (t) => t.width !== void 0 ? `${Math.min(t.width, t.maxWidth)}px` : `${t.minWidth}px`, ({
17
+ showResizeable: t
18
+ }) => t ? it : 0), gt = p.div.withConfig({
19
+ displayName: "styled__PanelCrossfade"
20
+ })(["flex:1 1 auto;min-width:0;height:100%;display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:minmax(0,1fr);overflow:hidden;"]), V = lt(["grid-area:1 / 1;min-width:0;min-height:0;opacity:", ";visibility:", ";pointer-events:", ";transition:opacity ", "s ease-in-out,visibility 0s ", ";"], ({
21
+ $active: t
22
+ }) => t ? 1 : 0, ({
23
+ $active: t
24
+ }) => t ? "visible" : "hidden", ({
25
+ $active: t
26
+ }) => t ? "auto" : "none", z, ({
27
+ $active: t
28
+ }) => t ? "0s" : `${z}s`), wt = p.div.withConfig({
29
+ displayName: "styled__PanelContent"
30
+ })(["", ";width:100%;height:100%;margin-top:0;position:relative;"], V), yt = p.div.withConfig({
31
+ displayName: "styled__PanelCollapsedContent"
32
+ })(["", ";height:100%;position:relative;display:flex;flex-direction:column;align-items:center;justify-content:space-between;padding:", ";width:100%;"], V, ({
33
+ $isAdaptive1280: t,
34
+ showResizeable: e
35
+ }) => e ? t ? "6px" : "10px" : v), vt = p.div.withConfig({
36
+ displayName: "styled__PanelCollapsedBody"
37
+ })(["gap:", ";display:flex;flex-direction:column;"], v), xt = p(et).withConfig({
38
+ displayName: "styled__PanelIconButton"
39
+ })(["z-index:1;position:", ";top:", ";right:", ";width:", "px !important;height:", "px !important;.left-panel__toggle-button{transform:", ";}"], (t) => t.isAbsolute ? "absolute" : "static", v, v, ({
40
+ $isAdaptive1280: t
41
+ }) => t ? 32 : 40, ({
42
+ $isAdaptive1280: t
43
+ }) => t ? 32 : 40, (t) => t.collapsed ? "rotate(270deg)" : "rotate(90deg)"), bt = p.div.withConfig({
44
+ displayName: "styled__PanelSeparator"
45
+ })(["position:absolute;top:0;right:0px;width:12px;height:100%;cursor:col-resize;z-index:10;&::before{content:'';position:absolute;top:0;left:50%;transform:translateX(-50%);width:12px;height:100%;background-color:", ";}&::after{content:'';position:absolute;top:", ";left:50%;transform:translateX(-50%);border-radius:95px;width:4px;height:", ";background-color:", ";}&:hover{&::after{background-color:", ";}}"], () => st, `calc(50% - ${j} / 2)`, j, () => rt, () => at), X = ({
46
+ onClick: t,
47
+ collapsed: e = !1,
48
+ isAbsolute: o = !1,
49
+ isAdaptive1280: i = !1,
50
+ ...l
51
+ }) => /* @__PURE__ */ S(xt, { onClick: t, $isAdaptive1280: i, collapsed: e, isAbsolute: o, view: "secondary", size: i ? "s" : "l", ...l, children: /* @__PURE__ */ S(R, { className: W.icon }) }), _t = ({
52
+ setWidth: t,
53
+ isResizingRef: e,
54
+ setIsResizing: o,
55
+ panelRef: i,
56
+ minWidth: l,
57
+ maxWidth: C,
58
+ parentRef: x,
59
+ isCollapsed: P,
60
+ onResize: f
61
+ }) => {
62
+ const I = O(() => {
63
+ var c;
64
+ document.body.style.cursor = "col-resize", document.body.style.userSelect = "none", e.current = !0, o(!0), (c = i.current) == null || c.classList.add(W.leftBlockIsResizing);
65
+ }, [i, e, o]);
66
+ return M(() => {
67
+ const c = () => {
68
+ var b, s;
69
+ document.body.style.cursor = "auto", document.body.style.userSelect = "", e.current = !1, o(!1), (b = i.current) == null || b.classList.remove(W.leftBlockIsResizing);
70
+ const u = ((s = i.current) == null ? void 0 : s.clientWidth) ?? 0;
71
+ u > l && u < K && t(l);
72
+ }, m = ct((u) => {
73
+ if (!e.current || !i.current || !x.current)
74
+ return;
75
+ u.preventDefault();
76
+ const a = x.current.getBoundingClientRect(), s = u.clientX - a.left, r = dt(l, s, C);
77
+ t(r), !P && f && f(r);
78
+ }, 16);
79
+ return window.addEventListener("mousemove", m), window.addEventListener("mouseup", c), () => {
80
+ window.removeEventListener("mousemove", m), window.removeEventListener("mouseup", c);
81
+ };
82
+ }, [t, e, o, i, l, C, x, P, f]), {
83
+ startResizing: I
84
+ };
85
+ }, St = (t) => ({
86
+ buttonSize: t ? "xs" : "s"
87
+ }), Ct = (t, e) => e ?? (t ? ft : pt), D = (t, e) => typeof t == "function" ? t(e) : t, Pt = ({
88
+ widthState: t,
89
+ minWidth: e,
90
+ maxWidth: o = mt,
91
+ disableMediaAdaptive: i = !1,
92
+ collapseState: l,
93
+ containerProps: C,
94
+ contentProps: x,
95
+ collapsedContentProps: P,
96
+ expandedContent: f,
97
+ collapsedContent: I,
98
+ collapsedFooterContent: c,
99
+ showToggleButton: E = !0,
100
+ showResizeable: m = !0,
101
+ onResize: u,
102
+ onToggleCollapse: a
103
+ }) => {
104
+ const {
105
+ down: b
106
+ } = ut(), s = !i && b("xl"), r = Ct(s, e), h = B(() => St(s), [s]), q = B(() => D(f, h), [f, h]), F = B(() => D(I, h), [I, h]), G = B(() => D(c, h), [c, h]), J = k(!1), [n, L] = l ?? J, Q = k(Number(n ? r : o)), [g, w] = t ?? Q, N = A(null), H = A(null), $ = A(!1), [U, Y] = k(!1), {
107
+ startResizing: Z
108
+ } = _t({
109
+ setWidth: w,
110
+ isResizingRef: $,
111
+ setIsResizing: Y,
112
+ panelRef: N,
113
+ minWidth: r,
114
+ maxWidth: o,
115
+ parentRef: H,
116
+ isCollapsed: n,
117
+ onResize: u
118
+ });
119
+ M(() => {
120
+ if (g !== void 0) {
121
+ const d = g < K;
122
+ d !== n && (L(d), a && !$.current && a(d));
123
+ }
124
+ }, [g, n, a, L]), M(() => {
125
+ !$.current && n && g !== r && w(r);
126
+ }, [n, r, w, g]);
127
+ const T = O(() => {
128
+ L((d) => {
129
+ const y = !d;
130
+ return a && a(y), w(y ? r : o), y;
131
+ });
132
+ }, [a, L, w, r, o]);
133
+ return /* @__PURE__ */ _(ht, { ref: N, collapsed: n, maxWidth: o, minWidth: r, width: g, $resizing: U, showResizeable: m, ...C, children: [
134
+ /* @__PURE__ */ _(gt, { children: [
135
+ /* @__PURE__ */ _(wt, { $active: !n, "aria-hidden": n, ...x, children: [
136
+ E && /* @__PURE__ */ S(X, { onClick: T, collapsed: n, isAdaptive1280: s, isAbsolute: !0 }),
137
+ q
138
+ ] }),
139
+ /* @__PURE__ */ _(yt, { $active: n, "aria-hidden": !n, $isAdaptive1280: s, showResizeable: m, ...P, children: [
140
+ /* @__PURE__ */ _(vt, { children: [
141
+ E && /* @__PURE__ */ S(X, { onClick: T, collapsed: n, isAdaptive1280: s }),
142
+ F
143
+ ] }),
144
+ G
145
+ ] })
146
+ ] }),
147
+ m && /* @__PURE__ */ S(bt, { onMouseDown: (d) => {
148
+ var y;
149
+ d.preventDefault(), (y = N.current) != null && y.parentElement && (H.current = N.current.parentElement), Z();
150
+ } })
151
+ ] });
152
+ };
153
+ Pt.LeftPanelToggleButton = X;
154
+ export {
155
+ Pt as L,
156
+ X as a,
157
+ St as b,
158
+ Ct as g,
159
+ D as r,
160
+ W as t,
161
+ _t as u
162
+ };
@@ -0,0 +1 @@
1
+ "use strict";const _=require("react"),f=require("react/jsx-runtime"),A=require("../components/Box/index.cjs"),w=require("@salutejs/sdds-finai"),$=require("../components/Collapse/index.cjs"),D=require("./Table-CnWVNNoW.cjs"),T=require("@salutejs/plasma-icons"),F=require("./utils-DKi1rqLX.cjs"),E=require("styled-components"),k=require("@salutejs/sdds-themes/tokens/sdds_finai"),W=require("./FiltersActions-D1aQXh5d.cjs"),C="list-of-filters",p={chipsGroup:`${C}__chip-group`,chipsGroupLabel:`${C}__chip-group__label`,chipsGroupCount:`${C}__chip-group__count`,chip:`${C}__chip`,clearButtonBlock:`${C}__clear-button-block`,chipsContainer:`${C}__chips-container`,container:`${C}__container`},N=s=>"groupId"in s,I=()=>E.css(k.bodyS),G=250,M=E(w.ChipGroup).withConfig({displayName:"ChipOrGroup__StyledChipGroup"})(["&{border-radius:",";padding:4px 2px;"," align-items:center;&.","{gap:4px;& .",":first-child,& ."," + .","{margin-left:4px;}& .","{display:inline-block;min-width:0;max-width:","px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}& .","{color:",";margin-left:4px;}& ."," svg{color:"," !important;}}}"],()=>k.borderRadiusS,()=>I(),p.chipsGroup,p.chip,p.chipsGroupLabel,p.chip,p.chipsGroupLabel,G,p.chipsGroupCount,()=>k.textPrimary,p.chip,()=>k.onLightTextSecondary),V=({itemOrGroup:s,maxLengthInGroup:n=2,ellipsisLabel:x=!1,chipStyle:o,renderGroupLabel:d,renderChipLabel:l})=>{if(N(s)){const h=s,m=h.items.slice(0,n),u=h.items.length-m.length,r=d?d(h):h.groupLabel;return f.jsxs(M,{className:p.chipsGroup,size:"xs",gap:"wide",view:"default",isCommonChipStyles:!1,children:[x?f.jsx("span",{className:p.chipsGroupLabel,title:r,children:r}):r,m.map(e=>f.jsx(w.Chip,{className:p.chip,title:"Удалить фильтр",view:"default",text:l?l(h,e):e.label.toString(),size:"xs",pilled:!0,onClick:e.onClick,style:{maxWidth:180,...D.overflowDotsStyle,...o&&o(h,e)},appearance:"transparent"},e.id)),u>0&&f.jsx(W.FiltersActionsTooltip,{groupLabel:r,items:h.items.map(e=>l?l(h,e):e.label.toString()),children:f.jsxs("span",{className:p.chipsGroupCount,children:["+",u]})})]})}return f.jsx(w.Chip,{className:p.chip,title:"Удалить фильтр",view:"default",text:l?l(null,s):s.label.toString(),size:"xs",pilled:!0,onClick:s.onClick,style:{maxWidth:150,...D.overflowDotsStyle,...o&&o(s,void 0)},appearance:"transparent"})},H=(s,n,x)=>{var c,t;const o=_.useRef(null),d=!!o.current,[l,h]=_.useState(0),m=o.current,u=(c=o.current)==null?void 0:c.firstChild,r=(t=o.current)==null?void 0:t.lastChild,e=(m&&u&&r&&m.offsetWidth-u.offsetWidth-r.offsetWidth-n*2-x*2)??void 0;return _.useEffect(()=>{const i=o.current;let y=0;function L(){y=(i==null?void 0:i.offsetWidth)??0,h(y)}L();const S=F.createSafeResizeObserver(L);return s&&i&&S.observe(i),()=>{S.disconnect()}},[s,d]),{refForContainer:o,maxWidthForCenterElement:e}},P={xs:{height:32,paddingInline:0}},B=1,q=`${B}px solid ${()=>D.COLORS.border}`,K=E(w.Tabs).withConfig({displayName:"ListOfFilters__StyledTabs"})({"&":{"& .tabs-clip-scroll":{overflowY:"hidden"},"& button.tab-item-animated":{marginLeft:"8px","&:first-of-type":{marginLeft:"0px"}}}}),U=({opened:s,items:n,clearAll:x,size:o="xs",paddingTop:d=0,maxLengthInGroup:l=2,ellipsisLabel:h=!1,sizeOnOpen:m,leftSlot:u,paddingInline:r,maxHeight:e,chipStyle:c,renderGroupLabel:t,renderChipLabel:i,showResetAllFiltersButton:y=!0,extraCss:L={}})=>{const S=P[o],z=r??S.paddingInline,b=e??S.height,{refForContainer:v}=H(s,z,B);return F.useDebouncedValue(s,200),f.jsx($.Collapse,{isOpen:s,sizeOnOpen:m??b+d,unMountOnClose:!0,children:f.jsxs(A.Box,{ref:v,className:p.container,$css:{display:"flex",borderInline:q,borderTop:q,paddingInline:z,maxHeight:b,marginTop:d,flexDirection:"row-reverse",...L},children:[f.jsx(A.Box,{$css:"display: inline;",children:u??null}),f.jsx(K,{className:p.chipsContainer,view:"clear",size:"xs",style:{height:b-B,flex:1,minWidth:0,overflow:"hidden"},children:!!n.length&&n.map((a,g)=>{let j;return"groupId"in a&&(j=a.groupId??g),"id"in a&&(j=a.id??g),f.jsx(w.TabItem,{view:"clear",onClick:O=>O.preventDefault(),children:f.jsx(V,{maxLengthInGroup:l,ellipsisLabel:h,itemOrGroup:a,chipStyle:c,renderGroupLabel:t,renderChipLabel:i})},j)})}),f.jsx(A.Box,{className:p.clearButtonBlock,$css:"display: inline-flex; margin-left: auto;",children:y&&f.jsx(w.Button,{view:"clear",size:"xs",text:"Сбросить все",disabled:!n.length,contentLeft:f.jsx(T.IconClose,{size:"xs",color:"inherit"}),onClick:x})})]})})},R=_.memo(U),Z=s=>s==null?"":s instanceof Date?s.toLocaleDateString():Array.isArray(s)?s.map(n=>n instanceof Date?n.toLocaleDateString():String(n??"")).join(", "):String(s),X=({filters:s,filtersInfo:n,options:x,updateFilters:o,order:d})=>{const{labelFromValueMaps:l}=_.useMemo(()=>{const u={};for(const r of Object.entries(x)){const[e,c]=r;u[e]=new Map(c.map(t=>[String(t.value),t.label]))}return{labelFromValueMaps:u}},[x]),h=_.useCallback(()=>{for(const u of Object.entries(n)){const[r,e]=u;o(r,e.clearedValue)}},[n,o]);return{..._.useMemo(()=>{const u=Object.entries(s).reduce((e,c)=>{var v;const t=c[0],i=c[1],y=Array.isArray(i);if(!(y&&i.length||!y&&i&&i!==!1)||i===n[t].clearedValue)return e;if(typeof i=="boolean"){const a={id:t,label:n[t].label,onClick:()=>{o(t,n[t].clearedValue)}};return e.push(a),e}const b={groupId:t,groupLabel:n[t].label,items:[]};if(y)b.items=i.map(a=>{var g,j;return{id:a,label:((j=(g=l==null?void 0:l[t])==null?void 0:g.get)==null?void 0:j.call(g,a))??a.toString(),onClick:()=>{o(t,i.filter(O=>O!==a))}}});else{const a=l==null?void 0:l[t],g=((v=a==null?void 0:a.get)==null?void 0:v.call(a,i))??Z(i);b.items=[{id:i.toString(),label:g,onClick:()=>{o(t,"clearedValue"in n[t]?n[t].clearedValue:"")}}]}return e.push(b),e},[]);let r=u;if(d&&d!=="default"){if(typeof d=="function")r=d(u);else if(Array.isArray(d)){const e=new Map;u.forEach(c=>{const t="groupId"in c?c.groupId:String(c.id);e.set(t,c)}),r=[],d.forEach(c=>{const t=e.get(c);t&&(r.push(t),e.delete(c))}),e.size>0&&Array.from(e.keys()).sort().forEach(t=>{const i=e.get(t);i&&r.push(i)})}}return{filterListOpened:u.length>0,filterList:r}},[s,n,l,o,d]),clearAll:h,labelFromValueMaps:l}},Y=Object.freeze(Object.defineProperty({__proto__:null,default:R},Symbol.toStringTag,{value:"Module"}));exports.ListOfFilters=R;exports.ListOfFilters_lazy=Y;exports.isGroup=N;exports.listOfFiltersClassNames=p;exports.useFiltersList=X;
@@ -0,0 +1,243 @@
1
+ import { useRef as W, useState as R, useEffect as T, memo as j, useMemo as E, useCallback as I } from "react";
2
+ import { jsxs as A, jsx as h } from "react/jsx-runtime";
3
+ import { Box as z } from "../components/Box/index.mjs";
4
+ import { Chip as O, ChipGroup as V, TabItem as F, Button as G, Tabs as M } from "@salutejs/sdds-finai";
5
+ import { Collapse as H } from "../components/Collapse/index.mjs";
6
+ import { o as N, C as P } from "./Table-Bj2se1hR.mjs";
7
+ import { IconClose as q } from "@salutejs/plasma-icons";
8
+ import { c as K, u as U } from "./utils-C5SQhoON.mjs";
9
+ import B, { css as Z } from "styled-components";
10
+ import { borderRadiusS as X, textPrimary as Y, onLightTextSecondary as J, bodyS as Q } from "@salutejs/sdds-themes/tokens/sdds_finai";
11
+ import { F as tt } from "./FiltersActions-C3yWFtQT.mjs";
12
+ const x = "list-of-filters", f = {
13
+ chipsGroup: `${x}__chip-group`,
14
+ chipsGroupLabel: `${x}__chip-group__label`,
15
+ chipsGroupCount: `${x}__chip-group__count`,
16
+ chip: `${x}__chip`,
17
+ clearButtonBlock: `${x}__clear-button-block`,
18
+ chipsContainer: `${x}__chips-container`,
19
+ container: `${x}__container`
20
+ }, et = (i) => "groupId" in i, it = () => Z(Q), st = 250, nt = B(V).withConfig({
21
+ displayName: "ChipOrGroup__StyledChipGroup"
22
+ })(["&{border-radius:", ";padding:4px 2px;", " align-items:center;&.", "{gap:4px;& .", ":first-child,& .", " + .", "{margin-left:4px;}& .", "{display:inline-block;min-width:0;max-width:", "px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}& .", "{color:", ";margin-left:4px;}& .", " svg{color:", " !important;}}}"], () => X, () => it(), f.chipsGroup, f.chip, f.chipsGroupLabel, f.chip, f.chipsGroupLabel, st, f.chipsGroupCount, () => Y, f.chip, () => J), ot = ({
23
+ itemOrGroup: i,
24
+ maxLengthInGroup: n = 2,
25
+ ellipsisLabel: m = !1,
26
+ chipStyle: o,
27
+ renderGroupLabel: u,
28
+ renderChipLabel: l
29
+ }) => {
30
+ if (et(i)) {
31
+ const d = i, b = d.items.slice(0, n), p = d.items.length - b.length, r = u ? u(d) : d.groupLabel;
32
+ return /* @__PURE__ */ A(nt, { className: f.chipsGroup, size: "xs", gap: "wide", view: "default", isCommonChipStyles: !1, children: [
33
+ m ? /* @__PURE__ */ h("span", { className: f.chipsGroupLabel, title: r, children: r }) : r,
34
+ b.map((t) => /* @__PURE__ */ h(O, { className: f.chip, title: "Удалить фильтр", view: "default", text: l ? l(d, t) : t.label.toString(), size: "xs", pilled: !0, onClick: t.onClick, style: {
35
+ maxWidth: 180,
36
+ ...N,
37
+ ...o && o(d, t)
38
+ }, appearance: "transparent" }, t.id)),
39
+ p > 0 && /* @__PURE__ */ h(tt, { groupLabel: r, items: d.items.map((t) => l ? l(d, t) : t.label.toString()), children: /* @__PURE__ */ A("span", { className: f.chipsGroupCount, children: [
40
+ "+",
41
+ p
42
+ ] }) })
43
+ ] });
44
+ }
45
+ return /* @__PURE__ */ h(O, { className: f.chip, title: "Удалить фильтр", view: "default", text: l ? l(null, i) : i.label.toString(), size: "xs", pilled: !0, onClick: i.onClick, style: {
46
+ maxWidth: 150,
47
+ ...N,
48
+ ...o && o(i, void 0)
49
+ }, appearance: "transparent" });
50
+ }, rt = (i, n, m) => {
51
+ var a, e;
52
+ const o = W(null), u = !!o.current, [l, d] = R(0), b = o.current, p = (a = o.current) == null ? void 0 : a.firstChild, r = (e = o.current) == null ? void 0 : e.lastChild, t = (b && p && r && b.offsetWidth - p.offsetWidth - r.offsetWidth - n * 2 - m * 2) ?? void 0;
53
+ return T(() => {
54
+ const s = o.current;
55
+ let y = 0;
56
+ function w() {
57
+ y = (s == null ? void 0 : s.offsetWidth) ?? 0, d(y);
58
+ }
59
+ w();
60
+ const _ = K(w);
61
+ return i && s && _.observe(s), () => {
62
+ _.disconnect();
63
+ };
64
+ }, [i, u]), {
65
+ refForContainer: o,
66
+ maxWidthForCenterElement: t
67
+ };
68
+ }, lt = {
69
+ xs: {
70
+ height: 32,
71
+ paddingInline: 0
72
+ }
73
+ }, D = 1, $ = `${D}px solid ${() => P.border}`, at = B(M).withConfig({
74
+ displayName: "ListOfFilters__StyledTabs"
75
+ })({
76
+ "&": {
77
+ "& .tabs-clip-scroll": {
78
+ overflowY: "hidden"
79
+ },
80
+ "& button.tab-item-animated": {
81
+ marginLeft: "8px",
82
+ "&:first-of-type": {
83
+ marginLeft: "0px"
84
+ }
85
+ }
86
+ }
87
+ }), ct = ({
88
+ opened: i,
89
+ items: n,
90
+ clearAll: m,
91
+ size: o = "xs",
92
+ paddingTop: u = 0,
93
+ maxLengthInGroup: l = 2,
94
+ ellipsisLabel: d = !1,
95
+ sizeOnOpen: b,
96
+ leftSlot: p,
97
+ paddingInline: r,
98
+ maxHeight: t,
99
+ chipStyle: a,
100
+ renderGroupLabel: e,
101
+ renderChipLabel: s,
102
+ showResetAllFiltersButton: y = !0,
103
+ extraCss: w = {}
104
+ }) => {
105
+ const _ = lt[o], k = r ?? _.paddingInline, C = t ?? _.height, {
106
+ refForContainer: L
107
+ } = rt(i, k, D);
108
+ return U(i, 200), /* @__PURE__ */ h(H, { isOpen: i, sizeOnOpen: b ?? C + u, unMountOnClose: !0, children: /* @__PURE__ */ A(z, { ref: L, className: f.container, $css: {
109
+ display: "flex",
110
+ borderInline: $,
111
+ borderTop: $,
112
+ paddingInline: k,
113
+ maxHeight: C,
114
+ marginTop: u,
115
+ // transition: `all ${DURATION}s ease`,
116
+ flexDirection: "row-reverse",
117
+ ...w
118
+ }, children: [
119
+ /* @__PURE__ */ h(z, { $css: "display: inline;", children: p ?? null }),
120
+ /* @__PURE__ */ h(at, { className: f.chipsContainer, view: "clear", size: "xs", style: {
121
+ height: C - D,
122
+ flex: 1,
123
+ // Добавляем стили вместо maxWidthForCenterElement
124
+ minWidth: 0,
125
+ // Добавляем стили вместо maxWidthForCenterElement
126
+ overflow: "hidden"
127
+ // Добавляем стили вместо maxWidthForCenterElement
128
+ // width: maxWidthForCenterElement, // убираем. в splitView вызывает "дерганье"
129
+ }, children: !!n.length && n.map((c, g) => {
130
+ let S;
131
+ return "groupId" in c && (S = c.groupId ?? g), "id" in c && (S = c.id ?? g), /* @__PURE__ */ h(F, { view: "clear", onClick: (v) => v.preventDefault(), children: /* @__PURE__ */ h(ot, { maxLengthInGroup: l, ellipsisLabel: d, itemOrGroup: c, chipStyle: a, renderGroupLabel: e, renderChipLabel: s }) }, S);
132
+ }) }),
133
+ /* @__PURE__ */ h(z, { className: f.clearButtonBlock, $css: "display: inline-flex; margin-left: auto;", children: y && /* @__PURE__ */ h(G, { view: "clear", size: "xs", text: "Сбросить все", disabled: !n.length, contentLeft: /* @__PURE__ */ h(q, { size: "xs", color: "inherit" }), onClick: m }) })
134
+ ] }) });
135
+ }, pt = j(ct), ut = (i) => i == null ? "" : i instanceof Date ? i.toLocaleDateString() : Array.isArray(i) ? i.map((n) => n instanceof Date ? n.toLocaleDateString() : String(n ?? "")).join(", ") : String(i), wt = ({
136
+ filters: i,
137
+ filtersInfo: n,
138
+ options: m,
139
+ updateFilters: o,
140
+ order: u
141
+ }) => {
142
+ const {
143
+ labelFromValueMaps: l
144
+ } = E(() => {
145
+ const p = {};
146
+ for (const r of Object.entries(m)) {
147
+ const [t, a] = r;
148
+ p[t] = new Map(a.map((e) => [String(e.value), e.label]));
149
+ }
150
+ return {
151
+ labelFromValueMaps: p
152
+ };
153
+ }, [m]), d = I(() => {
154
+ for (const p of Object.entries(n)) {
155
+ const [r, t] = p;
156
+ o(r, t.clearedValue);
157
+ }
158
+ }, [n, o]);
159
+ return {
160
+ ...E(() => {
161
+ const p = Object.entries(i).reduce((t, a) => {
162
+ var L;
163
+ const e = a[0], s = a[1], y = Array.isArray(s);
164
+ if (!(y && s.length || !y && s && s !== !1) || s === n[e].clearedValue)
165
+ return t;
166
+ if (typeof s == "boolean") {
167
+ const c = {
168
+ id: e,
169
+ label: n[e].label,
170
+ onClick: () => {
171
+ o(e, n[e].clearedValue);
172
+ }
173
+ };
174
+ return t.push(c), t;
175
+ }
176
+ const C = {
177
+ groupId: e,
178
+ groupLabel: n[e].label,
179
+ items: []
180
+ };
181
+ if (y)
182
+ C.items = s.map((c) => {
183
+ var g, S;
184
+ return {
185
+ id: c,
186
+ label: ((S = (g = l == null ? void 0 : l[e]) == null ? void 0 : g.get) == null ? void 0 : S.call(g, c)) ?? c.toString(),
187
+ onClick: () => {
188
+ o(e, s.filter((v) => v !== c));
189
+ }
190
+ };
191
+ });
192
+ else {
193
+ const c = l == null ? void 0 : l[e], g = (
194
+ // если это - single select, combobox; (имеют свои label), то otherLabelOptions имеется.
195
+ ((L = c == null ? void 0 : c.get) == null ? void 0 : L.call(c, s)) ?? ut(s)
196
+ );
197
+ C.items = [{
198
+ id: s.toString(),
199
+ label: g,
200
+ onClick: () => {
201
+ o(e, "clearedValue" in n[e] ? n[e].clearedValue : "");
202
+ }
203
+ }];
204
+ }
205
+ return t.push(C), t;
206
+ }, []);
207
+ let r = p;
208
+ if (u && u !== "default") {
209
+ if (typeof u == "function")
210
+ r = u(p);
211
+ else if (Array.isArray(u)) {
212
+ const t = /* @__PURE__ */ new Map();
213
+ p.forEach((a) => {
214
+ const e = "groupId" in a ? a.groupId : String(a.id);
215
+ t.set(e, a);
216
+ }), r = [], u.forEach((a) => {
217
+ const e = t.get(a);
218
+ e && (r.push(e), t.delete(a));
219
+ }), t.size > 0 && Array.from(t.keys()).sort().forEach((e) => {
220
+ const s = t.get(e);
221
+ s && r.push(s);
222
+ });
223
+ }
224
+ }
225
+ return {
226
+ filterListOpened: p.length > 0,
227
+ filterList: r
228
+ };
229
+ }, [i, n, l, o, u]),
230
+ clearAll: d,
231
+ labelFromValueMaps: l
232
+ };
233
+ }, Lt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
234
+ __proto__: null,
235
+ default: pt
236
+ }, Symbol.toStringTag, { value: "Module" }));
237
+ export {
238
+ pt as L,
239
+ Lt as a,
240
+ et as i,
241
+ f as l,
242
+ wt as u
243
+ };
@@ -0,0 +1 @@
1
+ "use strict";const g=require("react/jsx-runtime"),b=require("@salutejs/sdds-finai"),Rt=require("@salutejs/plasma-icons"),xt=require("./utils-DKi1rqLX.cjs"),p=require("react"),Wt=require("./Table-CnWVNNoW.cjs"),Vt=require("../constants/index.cjs"),Ct=require("@salutejs/sdds-themes/tokens/sdds_finai"),M=require("styled-components"),jt=require("../components/Box/index.cjs"),se=require("../components/Collapse/index.cjs"),Pt=require("./AnalyticalWidget-fBDe37Ur.cjs"),ht=24,L=4,wt=44,Nt=40,Et=24,Q={top:12,right:8,bottom:12,left:24},Bt={top:0,right:10,bottom:0,left:24},ie=Q.left+Q.right,vt=90,qt=110,gt=100,oe=300,Tt=550,Ut=350,Gt=50,Ht=100,Xt=({buttons:t,visibleButtonsCount:i})=>{const{visibleButtons:o,buttonsInDropdown:n}=p.useMemo(()=>{const e=t??[],c=new Set,h=[];e.forEach((f,u)=>{f.view==="accent"?c.add(u):h.push(u)});const l=c.size,a=Math.max(0,i-l),s=new Set(h.slice(0,a)),r=[],w=[];return e.forEach((f,u)=>{c.has(u)||s.has(u)?r.push(f):w.push(f)}),{visibleButtons:r,buttonsInDropdown:w}},[t,i]);return{visibleButtons:o,buttonsInDropdown:n,allButtons:t??[]}},Yt=({isCollapsed:t,setIsCollapsed:i,isSidebarOpen:o,calculatePositionForState:n,calculatePosition:e,setTranslateX:c,shouldApplySidebarOffsetRef:h,wasAutoCollapsedRef:l})=>({handleToggleCollapse:p.useCallback(()=>{const s=!t,r=n(s);r!==void 0&&c(r),o&&(s?h.current=!0:(h.current=!1,l.current=!1)),i(s),setTimeout(()=>{e()},Tt)},[t,o,n,e,c,h,l,i])}),Jt=({isCollapsed:t,containerRef:i,contentRef:o,middleSectionRef:n,buttonRefs:e,moreButtonRef:c,collapseButtonRef:h,leftSectionRef:l,dividerRef:a,buttons:s,isHaveSomeFeatureInSidebar:r,getContainerWidth:w,setVisibleButtonsCount:f,minPadding:u=Et,leftPadding:C=Q.left,rightPadding:A=Q.right,moreButtonWidthEstimate:I=Nt,enableDebugLogs:B=!1})=>{const N=p.useRef([]),z=p.useCallback(()=>{var dt,X,pt,rt,ut,W;const y=w();if(!y||y===0||!s||s.length===0)return B&&console.debug("❌ calculateInitialCompression: нет tableWidth или buttons"),!1;if(!s.every((x,E)=>e.current[E]!==null&&e.current[E]!==void 0))return B&&console.debug("❌ calculateInitialCompression: ref'ы еще не установлены",{buttonsCount:s.length,refsCount:e.current.filter(Boolean).length,refs:e.current.map((x,E)=>({index:E,hasRef:!!x}))}),!1;const S=y-(r?wt:0),q=((dt=l==null?void 0:l.current)==null?void 0:dt.getBoundingClientRect().width)??0,k=((X=n.current)==null?void 0:X.getBoundingClientRect().width)??0,$=s.length>0,R=$?((pt=a==null?void 0:a.current)==null?void 0:pt.getBoundingClientRect().width)??0:0,U=$?L:0,tt=$&&k>0?L:0,ot=R+tt+U,at=L*2,ct=q+k+ot+(((rt=h.current)==null?void 0:rt.getBoundingClientRect().width)??ht)+(C+A)+at,T=[];let P=!0;for(let x=0;x<s.length;x+=1){const E=e.current[x];if(!E){P=!1;break}const F=E.querySelector("button, a")||E;if(!F||!F.isConnected){P=!1;break}const ft=F.getBoundingClientRect(),lt=ft.width||F.offsetWidth||F.scrollWidth||F.clientWidth;if(lt>0)T.push(lt),N.current[x]=lt;else{console.debug("❌ calculateInitialCompression: кнопка не отрендерилась",{index:x,text:(ut=s[x])==null?void 0:ut.text,width:lt,isConnected:F.isConnected,rect:ft}),P=!1;break}}if(!P||T.length!==s.length)return B&&console.debug("❌ calculateInitialCompression: не все кнопки измерены",{allButtonsMeasured:P,buttonWidthsLength:T.length,buttonsLength:s.length}),!1;const et=((W=c.current)==null?void 0:W.getBoundingClientRect().width)??I,v=S-u*2,O=[],j=[];s.forEach((x,E)=>{if(T[E]===void 0)return;(x==null?void 0:x.view)==="accent"?O.push(E):j.push(E)});let V=0;O.forEach(x=>{const E=T[x];E!==void 0&&(V+=E)});const G=new Set(O);let nt=V,st=0;for(let x=0;x<j.length;x+=1){const E=j[x],D=typeof E<"u"?T[E]:0;if(D===void 0)continue;const ft=x<j.length-1?et+L:0,mt=(G.size+1-1)*L,At=nt+D+mt+ft;if(ct+At<=v)nt+=D,st+=1,typeof E<"u"&&G.add(E);else break}const H=G.size;return f(H),console.debug("✅ calculateInitialCompression: успешно выполнено",{buttonWidths:T,visibleCount:H,accentCount:O.length,regularVisibleCount:st}),!0},[s,w,r,f,e,l,n,c,h,a,B,u,C,A,I]);return{calculateCompression:p.useCallback(()=>{t||!i.current||!o.current||requestAnimationFrame(()=>{setTimeout(()=>{var lt,mt,At,It,Mt,St,Dt;const y=w();if(!y||y===0)return;const _=y-(r?wt:0);B&&(console.group("🔧 MassActions Compression"),console.debug("📏 Размеры контейнера:",JSON.stringify({tableWidth:y,isHaveSomeFeatureInSidebar:r,togglePanelWidth:r?wt:0,availableWidth:_,minPaddingRequired:u*2,maxPanelWidthAllowed:_-u*2},null,2)));const S=((lt=l==null?void 0:l.current)==null?void 0:lt.getBoundingClientRect().width)??0,q=((mt=n.current)==null?void 0:mt.getBoundingClientRect().width)??0,k=((s==null?void 0:s.length)??0)>0,$=k?((At=a==null?void 0:a.current)==null?void 0:At.getBoundingClientRect().width)??0:0,R=k?L:0,U=k&&q>0?L:0,tt=$+U+R;let ot=null;if(l!=null&&l.current){const d=l.current.getBoundingClientRect(),{children:m}=l.current,K=[];for(let Y=0;Y<m.length;Y+=1){const Z=m[Y];if(Z){const it=Z.getBoundingClientRect();K.push({tagName:Z.tagName,className:Z.className,width:it.width,height:it.height})}}ot={width:d.width,height:d.height,children:K,childrenTotalWidth:K.reduce((Y,Z)=>Y+Z.width,0)}}const at=L*2,ct=S+q+tt+(((It=h.current)==null?void 0:It.getBoundingClientRect().width)??ht)+(C+A)+at;B&&console.debug("🔲 Фиксированные элементы:",JSON.stringify({leftSectionWidth:S,leftSectionDetails:ot,middleSectionWidth:q,divider:{shouldShow:k,wrapperWidth:$,gapLeft:U,gapRight:R,totalWidth:tt},collapseButtonWidth:((Mt=h.current)==null?void 0:Mt.getBoundingClientRect().width)??ht,containerPadding:C+A,gapsBetweenFixedElements:at,fixedElementsTotal:ct},null,2));const T=[];let P=!0;for(let d=0;d<((s==null?void 0:s.length)??0);d+=1){const m=e.current[d];if(m){const Y=m.querySelector("button, a")||m,it=Y.getBoundingClientRect().width||Y.offsetWidth||Y.scrollWidth||Y.clientWidth;it>0?(T.push(it),N.current[d]=it):N.current[d]!==void 0?T.push(N.current[d]??gt):(P=!1,T.push(gt))}else N.current[d]!==void 0?T.push(N.current[d]??gt):(P=!1,T.push(gt))}if(!P&&T.length===0&&((s==null?void 0:s.length)??0)>0)return;const et=((St=c.current)==null?void 0:St.getBoundingClientRect().width)??I,v=_-u*2,O=i.current?i.current.getBoundingClientRect().width:0;B&&(console.debug("🎯 Ограничения и текущее состояние:",JSON.stringify({targetContainer:{tableWidth:y,availableWidth:_,minPaddingEach:u,minPaddingTotal:u*2,maxPanelWidth:v},currentPanel:{width:O,exceedsMax:O>v,exceedsAvailable:O>_,leftPadding:u,rightPadding:u},moreButtonWidth:et},null,2)),console.debug("🔘 Ширины кнопок:",JSON.stringify({buttons:s==null?void 0:s.map((d,m)=>({index:m,text:d.text,view:d.view,isAccent:d.view==="accent",width:T[m]})),totalButtonsWidth:T.reduce((d,m)=>d+m,0),averageButtonWidth:T.length>0?T.reduce((d,m)=>d+m,0)/T.length:0},null,2)));const j=s??[],V=[],G=[];j.forEach((d,m)=>{if(T[m]===void 0)return;(d==null?void 0:d.view)==="accent"?V.push(m):G.push(m)}),B&&console.debug("🎨 Распределение:",{accentCount:V.length,regularCount:G.length,accentButtons:V.map(d=>{var m;return{index:d,text:(m=j[d])==null?void 0:m.text,width:T[d]}})});let nt=0;V.forEach(d=>{const m=T[d];m!==void 0&&(nt+=m)});const st=new Set(V);let H=nt,dt=0;for(let d=0;d<G.length;d+=1){const m=G[d],K=typeof m<"u"?T[m]:0;if(K===void 0)continue;const Z=d<G.length-1?et+L:0,it=st.size+1,Lt=(it-1)*L,kt=H+K+Lt+Z,_t=ct+kt,yt=_t+3;if(B&&console.debug(` 🔍 Проверка кнопки ${d}:`,{text:typeof m<"u"?(Dt=j[m])==null?void 0:Dt.text:"",width:K,totalButtonsWidthBefore:H,visibleCountAfter:it,gapsBetweenButtons:Lt,moreButtonSpace:Z,requiredWidth:kt,testPanelWidth:_t,testWithBuffer:yt,maxPanelWidth:v,fits:_t<=v,fitsWithBuffer:yt<=v}),yt<=v)H+=K,dt+=1,typeof m<"u"&&st.add(m);else break}const X=st.size,rt=j.length-X>0,ut=X>0?(X-1)*L:0,W=H+ut+(rt?et+L:0),x=ct+W,E=[],D=[];j.forEach((d,m)=>{st.has(m)?E.push(d):D.push(d)});const F=X,ft={fixedElements:{leftSection:S,middleSection:q,divider:tt,collapseButton:ht,containerPadding:C+A,gapsBetweenFixedElements:at,total:ct},buttons:{accentButtonsWidth:nt,visibleRegularButtonsWidth:H-nt,totalButtonsWidth:H,gapsBetweenVisibleButtons:ut,buttonsAreaWidth:W,visibleButtonsCount:X,hiddenButtonsCount:D.length},moreButton:rt?{width:et,gap:L,total:et+L}:null,final:{calculatedWidth:x,actualPanelWidth:O,widthDifference:O-x,maxAllowedWidth:v,availableWidth:_,fits:x<=v,actualFits:O<=v,exceedsBy:x>v?x-v:0,actualExceedsBy:O>v?O-v:0,leftPaddingRequired:u,rightPaddingRequired:u,totalPaddingRequired:u*2}};B&&(console.debug("✅ Результат компрессии:",JSON.stringify({summary:{totalButtons:j.length,accentCount:V.length,visibleRegularCount:dt,visibleCount:F,hiddenCount:D.length,finalPanelWidth:x,maxPanelWidth:v,fits:x<=v,hasMoreButton:rt},breakdown:ft},null,2)),console.debug("👁️ Видимые кнопки:",{buttons:E.map(d=>({text:d.text,view:d.view,isAccent:d.view==="accent"}))}),console.debug("📦 Кнопки в dropdown:",{buttons:D.map(d=>({text:d.text,view:d.view}))}),console.groupEnd()),f(X)},Gt)})},[t,i,o,w,r,B,l,n,s,a,c,h,u,C,A,I,f,e]),calculateInitialCompression:z,measuredButtonWidthsRef:N}},Ft=t=>{const[i,o]=p.useState(0),n=p.useCallback(()=>typeof t=="function"?t():t.current,[t]),e=p.useCallback(()=>{const c=n();return c?c.getBoundingClientRect().width:0},[n]);return p.useEffect(()=>{const c=n();if(!c)return;o(c.getBoundingClientRect().width);const h=xt.createSafeResizeObserver(l=>{for(const a of l){const{width:s}=a.contentRect;o(s)}});return h.observe(c),()=>{h.disconnect()}},[n]),{containerWidth:i,getContainerWidth:e,getContainer:n}},Kt=({containerRef:t,buttonRefs:i,buttons:o,isVisible:n,isCollapsed:e,visibleButtonsCount:c,selectedCount:h,setIsCollapsed:l,setVisibleButtonsCount:a,calculatePosition:s,calculateCompression:r,measuredButtonWidthsRef:w,containerWidth:f})=>{p.useEffect(()=>{f>0&&(s(),r())},[f,s,r]),p.useLayoutEffect(()=>{if(!t.current)return;const u=xt.createSafeResizeObserver(()=>{s()});return u.observe(t.current),()=>{u.disconnect()}},[s,t]),p.useEffect(()=>{i.current=Array((o==null?void 0:o.length)??0).fill(null),a((o==null?void 0:o.length)??0),w.current=[]},[o==null?void 0:o.length,i,a,w]),p.useEffect(()=>{if(n&&!e){const u=setTimeout(()=>{r(),s()},Ht);return()=>{clearTimeout(u)}}},[n,e,r,s]),p.useEffect(()=>{if(e){s();return}s()},[e,c,s]),p.useEffect(()=>()=>{(!n||h===0)&&l(!1)},[n,h,l])},Zt=({containerRef:t,collapseButtonRef:i,leftSectionRef:o,getContainerWidth:n,isHaveSomeFeatureInSidebar:e,sidebarConfig:c,visibleButtonsCount:h,setTranslateX:l,minPadding:a=Et,enableDebugLogs:s=!1})=>{const r=(c==null?void 0:c.isOpen)??!1,w=(c==null?void 0:c.width)??0,f=(c==null?void 0:c.togglePanelWidth)??wt,u=p.useRef(!1),C=p.useCallback(I=>{var k,$;const B=n();if(!B||B===0)return;const N=w+f,z=r?N/2:0,J=e?f/2:0;let y=-(z+J),_;if(I){const R=((k=o==null?void 0:o.current)==null?void 0:k.getBoundingClientRect().width)??vt,U=(($=i.current)==null?void 0:$.getBoundingClientRect().width)??ht,tt=Bt.top+Bt.right+Bt.left;_=R+U+tt}else if(t.current)_=t.current.getBoundingClientRect().width;else{const R=h*gt,U=Q.top+Q.right+Q.left;_=vt+qt+ht+R+U}const S=B/2;return S-_/2+y<a&&(y=a-(S-_/2)),y},[n,t,i,o,e,r,w,f,h,a]);return{calculatePosition:p.useCallback(()=>{const I=n();if(!I||I===0||!t.current)return;s&&console.group("📍 MassActions Position");const B=w+f,N=r?B/2:0,z=e?f/2:0;let J=-(N+z);const y=t.current.getBoundingClientRect().width,_=I/2,S=_-y/2+J;S<a&&(J=a-(_-y/2)),s&&(console.log("🎯 Позиционирование:",JSON.stringify({tableWidth:I,panelWidth:y,tableCenter:_,sidebarWidth:w,toggleSidebarPanelWidth:f,isSidebarOpen:r,isHaveSomeFeatureInSidebar:e,totalSidebarWidth:B,sidebarOffset:N,togglePanelOffset:z,idealTranslateX:-(N+z),leftEdgePosition:S,minPadding:a,finalTranslateX:J,adjusted:S<Et},null,2)),console.groupEnd()),l(J),r?u.current=!0:u.current=!1},[n,t,s,w,f,e,r,l,a]),calculatePositionForState:C,shouldApplySidebarOffsetRef:u}},Qt=({isCollapsed:t,setIsCollapsed:i,calculatePositionForState:o,calculatePosition:n,setTranslateX:e,shouldApplySidebarOffsetRef:c,sidebarConfig:h,getContainerWidth:l})=>{const a=(h==null?void 0:h.isOpen)??!1,s=(h==null?void 0:h.width)??0,r=p.useRef(!1),w=p.useRef(a);return p.useEffect(()=>{if(!h)return;const u=w.current!==a;if(w.current=a,!u){n();return}if(a)if(t)n();else{r.current=!0;const C=o(!0);C!==void 0&&(e(C),c.current=!0),i(!0),setTimeout(()=>{n()},Tt)}else if(t){r.current=!1,c.current=!1;const C=o(!1);C!==void 0&&e(C),i(!1),setTimeout(()=>{n()},Tt)}else c.current=!1,n()},[a,s,l]),{isSidebarOpen:a,sidebarWidth:s,wasAutoCollapsedRef:r}},bt=t=>{const i=p.useRef(t),[o,n]=p.useState(t>0);return p.useEffect(()=>{var l;const e=i.current,c=e===0&&t>0,h=e>0&&t===0;if(c||h){const a=()=>{n(t>0)};document.startViewTransition?(l=document.startViewTransition)==null||l.call(document,a):a()}else n(t>0);i.current=t},[t]),o},ce="mass-actions-panel",zt={surfaceSolidCard:()=>Ct.surfaceSolidCard,outlineSolidPrimary:()=>Ct.outlineSolidPrimary},re=M(b.LinkButton).withConfig({displayName:"styled__StyledLinkButton"})({paddingInline:Vt.s.x8}),te=t=>M(t).withConfig({displayName:"styled__getButtonWithDropdown"})([""," ",""],({$hasDropdown:i})=>i&&M.css(["& > div > span:last-child{max-width:fit-content;min-width:unset;}"]),({$buttonStyles:i})=>i&&M.css(["",""],i)),le=te(b.Button),ae=te(re),de=M.div.withConfig({displayName:"styled__MassActionsContainer"})(["position:absolute;bottom:","px;left:50%;transform:",";background:",";border:2px solid ",";padding:",";border-radius:14px;display:block;width:fit-content;max-width:",";view-transition-name:",";opacity:",";transition:padding 0.3s cubic-bezier(0.4,0,0.2,1),transform 0.3s cubic-bezier(0.4,0,0.2,1),max-width 0.2s cubic-bezier(0.4,0,0.2,1),opacity 0.2s ease-in-out;will-change:padding,transform,max-width;box-shadow:",";"],({$bottom:t=24})=>t,({$translateX:t})=>t!==void 0?`translateX(calc(-50% + ${t}px))`:"translateX(-50%)",zt.surfaceSolidCard,zt.outlineSolidPrimary,({$isCollapsed:t,$size:i})=>{const o=i==="xs";return t?o?"0px 2px 0px 12px":"0px 10px 0px 24px":o?"4px 2px 4px 12px":"12px 8px 12px 24px"},({$isCollapsed:t})=>t?"350":"2000px",ce,({$isInitialCalculationComplete:t})=>t?1:0,Ct.shadowDownHardS),ue=M.div.withConfig({displayName:"styled__MassActionsContent"})(["display:flex;align-items:center;gap:",";"],({$isCollapsed:t,$isCompact:i})=>t?i?"4px":"8px":"0px"),he=M.div.withConfig({displayName:"styled__ActionsWrapper"})(["display:flex;max-height:",";align-items:center;gap:4px;flex:1;justify-content:flex-end;overflow:hidden;min-width:0;transition:max-height 0.2s cubic-bezier(0.4,0,0.2,1),opacity 0.3s cubic-bezier(0.4,0,0.2,1),max-width 0.1s cubic-bezier(0.4,0,0.2,1),margin 0.3s cubic-bezier(0.4,0,0.2,1),gap 0.3s cubic-bezier(0.4,0,0.2,1);",""],({$isCollapsed:t})=>t?"0":"40px",({$isCollapsed:t})=>t?M.css(["opacity:0;max-width:0;margin:0;gap:0;"]):M.css(["opacity:1;max-width:2000px;"])),pe=M.div.withConfig({displayName:"styled__HiddenButtonsMeasurementContainer"})(["position:absolute;left:-9999px;top:0;display:flex;gap:4px;align-items:center;z-index:-1;pointer-events:none;width:auto;height:auto;"]),fe=M.div.withConfig({displayName:"styled__ButtonMeasurementWrapper"})(["display:inline-flex;width:auto;height:auto;"]),ge=M.div.withConfig({displayName:"styled__VisibleButtonWrapper"})(["margin-left:0;"]),xe=M(Rt.IconDoubleDisclosureUp).withConfig({displayName:"styled__CollapseIcon"})(["transition:all 0.3s;transform:",";"],({$isCollapsed:t})=>t?"scaleY(1)":"scaleY(-1)"),we=M(b.EmbedIconButton).withConfig({displayName:"styled__CollapseButton"})(["padding:",";"],({$isCompact:t})=>t?Vt.s.x8:Ct.spacing10x);M(b.Button).withConfig({displayName:"styled__MoreButton"})(["margin-left:0;"]);const me=M(b.Divider).withConfig({displayName:"styled__StyledDivider"})(["padding-left:1px;margin-left:12px;margin-right:8px;"]),Ae=t=>{if(typeof t=="string"&&t.startsWith("link")){const i=t.slice(4);return i.charAt(0).toLowerCase()+i.slice(1)}return t??"default"},Be={size:"s",view:"linkDefault"},Ot=({type:t,view:i,showLabel:o,text:n,buttonStyles:e,dropdown:c,useTableDropdown:h=!1,...l})=>{const a=t??"linkButton",{view:s,...r}=Be,w=i??s,f=o?n:void 0,u=!!c;let C;if(a==="button"){const A=l,I=A.text??f;C=g.jsx(le,{...r,...A,view:w,text:I,$hasDropdown:u,$showLabel:o,$buttonStyles:e})}else{const A=String(w??"linkDefault"),B=A.startsWith("link")?Ae(A):A;C=g.jsx(ae,{...r,...l,view:B,text:f,$hasDropdown:u,$showLabel:o,$buttonStyles:e})}if(c&&c.items&&c.items.length>0)if(h)C=g.jsx(Wt.TableDropdown,{...c,children:C});else{const{$css:A,...I}=c;C=g.jsx(b.Dropdown,{...I,children:C})}return C},ee=({selectedCount:t,label:i="Выбрано",showCheckbox:o=!1,checked:n=!1,onCheckboxChange:e,className:c,indeterminate:h})=>{const{down:l}=xt.useBreakpoint(),a=l("xl"),s=t>0,r=a?"BodyXS":"BodyS",w=(()=>{if(t===0)return"0px";const u=t.toString().length;return`${Math.max(16,7.1+u*6.1)+4}px`})(),f=o?g.jsxs(jt.Box,{$css:{display:"flex",alignItems:"center",gap:"4px"},children:[g.jsx(b.Checkbox,{checked:n,indeterminate:h,onChange:e,size:"m"}),g.jsx(Pt.Typography,{variant:r,children:i})]}):g.jsx(Pt.Typography,{variant:r,children:i});return g.jsxs(jt.Box,{className:c,$css:{display:"flex",alignItems:"center"},children:[f,g.jsx(se.Collapse,{duration:.3,orientation:"horizontal",isOpen:s,unMountOnClose:!0,sizeOnOpen:w,extContainerCss:{overflow:"visible",display:"flex",justifyContent:"flex-end"},intContainerCss:{always:{opacity:"0",transition:".3s ease"},onOpen:{opacity:1}},children:s&&g.jsx(Wt.AnimatedCounter,{className:"counter",count:t,size:"xs",view:"accent",style:{marginBottom:"3px"}},t)})]})},Ce=(t=[])=>p.useMemo(()=>{const i=[],o={},n=new Map;return t.forEach(e=>{var c,h;if(e.dropdown){const l=`group-${e.key||e.text||Date.now()}`,a="items"in e.dropdown?e.dropdown.items||[]:[],s="onItemSelect"in e.dropdown?e.dropdown.onItemSelect:void 0;s&&n.set(l.toString(),s);const[r,w]=xt.processDropdownItems(a,s);w.forEach((f,u)=>n.set(u,f)),(c=e.dropdown)!=null&&c.$css&&Object.assign(o,(h=e.dropdown)==null?void 0:h.$css),i.push({label:e.text??"",value:l,contentLeft:e.contentLeft,items:r,className:e.className,disabled:e.disabled})}else{const l=e.key||e.text||`btn-${Date.now()}`,a={label:e.text||"Кнопка",value:l.toString(),disabled:e.disabled,contentLeft:e.contentLeft};e.onClick&&n.set(l.toString(),(s,r)=>{var f;const w={...r,nativeEvent:r.nativeEvent,preventDefault:r.preventDefault,stopPropagation:r.stopPropagation,target:r.target,currentTarget:r.currentTarget};(f=e.onClick)==null||f.call(e,w)}),i.push(a)}}),{dropdownItems:i,handlerMap:n,$summaryCSS:o}},[t]),Ee=({buttons:t=[],dividerIndexes:i=[],triggerSlot:o,dropdownProps:n,useTableDropdown:e=!1})=>{const{dropdownItems:c,handlerMap:h,$summaryCSS:l}=Ce(t),a=xt.useDropdownItemClickHandler(h),[s,r]=p.useState(!1),w=c.map((A,I)=>(i.includes(I)&&(A.dividerAfter=!0),A)),f={closeOnSelect:!0,...n,onItemSelect:a,items:w,onToggle:A=>r(A),portal:"document",view:(n==null?void 0:n.view)||"default"},{portal:u,...C}=f;return e?g.jsx(Wt.TableDropdown,{$css:l,...C,children:o}):g.jsx(b.Dropdown,{...f,children:o})},Te=({button:t,isCompact:i,compactSize:o="xs",useTableDropdown:n=!1})=>{const e=t.size??(i?o:"s");return g.jsx(Ot,{...t,size:e,showLabel:!0,useTableDropdown:n})},Ie=({button:t,isCompact:i,compactSize:o="xs",useTableDropdown:n=!1})=>{const e=t.size??(i?o:"s");return g.jsx(Ot,{...t,size:e,showLabel:!0,useTableDropdown:n})},$t=(t,i,o=!1,n="xs")=>t.type==="button"?g.jsx(Te,{button:t,isCompact:i,compactSize:n,useTableDropdown:o}):g.jsx(Ie,{button:t,isCompact:i,compactSize:n,useTableDropdown:o}),ne=({containerRef:t,leftSection:i,middleSection:o,buttons:n,sidebarConfig:e,isHaveSomeFeatureInSidebar:c=!1,collapsedDropdownProps:h,selectedCount:l,show:a,useTableDropdown:s=!1,enableDebugLogs:r=!1,bottom:w=16,minPadding:f=16,size:u})=>{const{down:C}=xt.useBreakpoint(),A=u?u==="xs":C("xl"),I=u?"xxs":"xs",[B,N]=p.useState(!1),z=p.useRef(null),J=p.useRef(null),y=p.useRef(null),_=p.useRef([]),S=p.useRef(null),q=p.useRef(null),k=p.useRef(null),$=p.useRef(null),[R,U]=p.useState((n==null?void 0:n.length)??0),[tt,ot]=p.useState(void 0),[at,ct]=p.useState(!1),{containerWidth:T,getContainerWidth:P}=Ft(t),et=bt(l),v=a!==void 0?a:et,{calculatePosition:O,calculatePositionForState:j,shouldApplySidebarOffsetRef:V}=Zt({containerRef:z,collapseButtonRef:q,leftSectionRef:k,getContainerWidth:P,isHaveSomeFeatureInSidebar:c,sidebarConfig:e,visibleButtonsCount:R,setTranslateX:ot,minPadding:f}),{calculateCompression:G,measuredButtonWidthsRef:nt}=Jt({isCollapsed:B,containerRef:z,contentRef:J,middleSectionRef:y,buttonRefs:_,moreButtonRef:S,collapseButtonRef:q,leftSectionRef:k,dividerRef:$,buttons:n,isHaveSomeFeatureInSidebar:c,getContainerWidth:P,setVisibleButtonsCount:U,enableDebugLogs:r,minPadding:f,leftPadding:Q.left,rightPadding:Q.right,moreButtonWidthEstimate:A?32:Nt}),{isSidebarOpen:st,wasAutoCollapsedRef:H}=Qt({isCollapsed:B,setIsCollapsed:N,calculatePositionForState:j,calculatePosition:O,setTranslateX:ot,shouldApplySidebarOffsetRef:V,sidebarConfig:e,getContainerWidth:P}),{handleToggleCollapse:dt}=Yt({isCollapsed:B,setIsCollapsed:N,isSidebarOpen:st,calculatePositionForState:j,calculatePosition:O,setTranslateX:ot,shouldApplySidebarOffsetRef:V,wasAutoCollapsedRef:H}),{visibleButtons:X,buttonsInDropdown:pt,allButtons:rt}=Xt({buttons:n,visibleButtonsCount:R});if(p.useEffect(()=>{const W=setTimeout(()=>ct(!0),Ut);return()=>clearTimeout(W)},[]),Kt({containerRef:z,buttonRefs:_,buttons:n,isVisible:v,isCollapsed:B,visibleButtonsCount:R,selectedCount:l,setIsCollapsed:N,setVisibleButtonsCount:U,calculatePosition:O,calculateCompression:G,measuredButtonWidthsRef:nt,containerWidth:T}),!v)return null;const ut=!B&&((n==null?void 0:n.length)??0)>0;return g.jsx(de,{ref:z,$isCollapsed:B,$size:u,$translateX:tt,$isInitialCalculationComplete:at,$bottom:w,children:g.jsxs(ue,{ref:J,$isCollapsed:B,$isCompact:A,children:[g.jsx(pe,{children:rt.map((W,x)=>{const E=W.key??`${W.text}${x}`;return g.jsx(fe,{ref:D=>{_.current[x]=D},children:$t(W,A,s,I)},`measure-${E}`)})}),g.jsx("div",{ref:k,children:i}),g.jsxs(he,{$isCollapsed:B,children:[o&&g.jsx("div",{ref:y,children:o}),ut&&g.jsx("div",{ref:$,children:g.jsx(me,{orientation:"vertical",length:"16px"})}),pt.length>0&&g.jsx("div",{ref:W=>{S.current=W},children:g.jsx(Ee,{buttons:pt,useTableDropdown:s,dropdownProps:{placement:"top",...h},triggerSlot:g.jsx(b.IconButton,{view:"secondary",size:A?I:"s",contentLeft:g.jsx(Rt.IconDotsVerticalCenteredOutline,{size:A?"xs":"s"})})})}),X.map((W,x)=>{const E=W.key??`${W.text}${x}`,D=g.jsx(ge,{children:$t(W,A,s,I)},E);return W.disabled&&W.disabledTooltipProps?g.jsx(b.Tooltip,{trigger:"hover",...W.disabledTooltipProps,children:D},E):D})]}),g.jsx("div",{ref:q,children:g.jsx(we,{size:A?"s":"m",$isCollapsed:B,$isCompact:A,onClick:dt,children:g.jsx(xe,{size:A?"xs":"s",$isCollapsed:B})})})]})})};ne.Counter=ee;exports.ACTION_BUTTON_WIDTH_ESTIMATE=gt;exports.ANIMATION_COMPLETE_DELAY=Tt;exports.ANIMATION_DURATION=oe;exports.COLLAPSE_BUTTON_WIDTH=ht;exports.COMPRESSION_CALCULATION_DELAY=Gt;exports.CONTAINER_PADDING_HORIZONTAL=ie;exports.COUNTER_WIDTH_ESTIMATE=vt;exports.DELAY_BEFORE_SHOW_PANEL=Ut;exports.ELEMENTS_GAP=L;exports.INITIAL_POSITION_CALCULATION_DELAY=Ht;exports.MIN_PANEL_PADDING=Et;exports.MORE_BUTTON_WIDTH_ESTIMATE=Nt;exports.MassActions=ne;exports.MassActionsButton=Ot;exports.MassActionsCounter=ee;exports.PANEL_PADDING_COLLAPSED=Bt;exports.PANEL_PADDING_EXPANDED=Q;exports.RESET_BUTTON_WIDTH_ESTIMATE=qt;exports.TOGGLE_SIDEBAR_PANEL_WIDTH=wt;exports.useMassActionsButtons=Xt;exports.useMassActionsCollapse=Yt;exports.useMassActionsCompression=Jt;exports.useMassActionsContainer=Ft;exports.useMassActionsEffects=Kt;exports.useMassActionsPosition=Zt;exports.useMassActionsSidebar=Qt;exports.useMassActionsVisibility=bt;