@max-ts/kit 0.26.0 → 0.27.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (291) hide show
  1. package/lib/components/Accordion/Accordion.d.ts +4 -4
  2. package/lib/components/Accordion/Accordion.d.ts.map +1 -1
  3. package/lib/components/Accordion/styles.css.d.ts.map +1 -1
  4. package/lib/components/AlertDialog/AlertDialog.d.ts +11 -11
  5. package/lib/components/AlertDialog/AlertDialog.d.ts.map +1 -1
  6. package/lib/components/AlertDialog/styles.css.d.ts.map +1 -1
  7. package/lib/components/Avatar/Avatar.d.ts +6 -6
  8. package/lib/components/Avatar/Avatar.d.ts.map +1 -1
  9. package/lib/components/Breadcrumb/Breadcrumb.d.ts +6 -6
  10. package/lib/components/Breadcrumb/Breadcrumb.d.ts.map +1 -1
  11. package/lib/components/Button/Button.d.ts +1 -1
  12. package/lib/components/Button/Button.d.ts.map +1 -1
  13. package/lib/components/ButtonGroup/ButtonGroup.d.ts +2 -2
  14. package/lib/components/ButtonGroup/ButtonGroup.d.ts.map +1 -1
  15. package/lib/components/ButtonGroup/styles.css.d.ts.map +1 -1
  16. package/lib/components/Calendar/Calendar.d.ts +1 -1
  17. package/lib/components/Calendar/Calendar.d.ts.map +1 -1
  18. package/lib/components/Calendar/DayButton/DayButton.d.ts +1 -1
  19. package/lib/components/Calendar/DayButton/DayButton.d.ts.map +1 -1
  20. package/lib/components/Calendar/Dropdown/Dropdown.d.ts +1 -1
  21. package/lib/components/Calendar/Dropdown/Dropdown.d.ts.map +1 -1
  22. package/lib/components/Card/Card.d.ts +6 -6
  23. package/lib/components/Carousel/Buttons/Buttons.d.ts +1 -1
  24. package/lib/components/Carousel/Buttons/Buttons.d.ts.map +1 -1
  25. package/lib/components/Carousel/Carousel.d.ts +1 -1
  26. package/lib/components/Carousel/Carousel.d.ts.map +1 -1
  27. package/lib/components/Carousel/Content/Content.d.ts +1 -1
  28. package/lib/components/Carousel/Content/Content.d.ts.map +1 -1
  29. package/lib/components/Carousel/Dots/Dots.d.ts +1 -1
  30. package/lib/components/Carousel/Dots/Dots.d.ts.map +1 -1
  31. package/lib/components/Carousel/Item/Item.d.ts +1 -1
  32. package/lib/components/Carousel/Item/Item.d.ts.map +1 -1
  33. package/lib/components/Checkbox/Checkbox.d.ts +1 -1
  34. package/lib/components/Checkbox/Checkbox.d.ts.map +1 -1
  35. package/lib/components/Collapsible/Collapsible.d.ts +3 -3
  36. package/lib/components/Collapsible/Collapsible.d.ts.map +1 -1
  37. package/lib/components/ConfirmAction/ConfirmAction.d.ts +1 -1
  38. package/lib/components/ConfirmAction/ConfirmAction.d.ts.map +1 -1
  39. package/lib/components/ContentState/ContentState.d.ts +1 -1
  40. package/lib/components/ContentState/ContentState.d.ts.map +1 -1
  41. package/lib/components/CopyTypography/CopyTypography.d.ts +1 -1
  42. package/lib/components/CopyTypography/CopyTypography.d.ts.map +1 -1
  43. package/lib/components/DashboardLayout/DashboardLayout.d.ts +3 -3
  44. package/lib/components/DashboardLayout/Main/Main.d.ts +1 -1
  45. package/lib/components/DashboardLayout/Main/Main.d.ts.map +1 -1
  46. package/lib/components/DashboardLayout/Sidebar/Sidebar.d.ts +1 -1
  47. package/lib/components/DashboardLayout/Sidebar/Sidebar.d.ts.map +1 -1
  48. package/lib/components/DataGrid/Body/Body.d.ts +1 -1
  49. package/lib/components/DataGrid/Body/Body.d.ts.map +1 -1
  50. package/lib/components/DataGrid/Cell/Cell.d.ts +1 -1
  51. package/lib/components/DataGrid/Cell/Cell.d.ts.map +1 -1
  52. package/lib/components/DataGrid/DataGrid.d.ts +1 -1
  53. package/lib/components/DataGrid/DataGrid.d.ts.map +1 -1
  54. package/lib/components/DataGrid/Footer/Footer.d.ts +1 -1
  55. package/lib/components/DataGrid/Footer/Footer.d.ts.map +1 -1
  56. package/lib/components/DataGrid/Header/Header.d.ts +1 -1
  57. package/lib/components/DataGrid/Header/Header.d.ts.map +1 -1
  58. package/lib/components/DataGrid/HeaderCell/HeaderCell.d.ts +1 -1
  59. package/lib/components/DataGrid/HeaderCell/HeaderCell.d.ts.map +1 -1
  60. package/lib/components/DataGrid/Row/Row.d.ts +1 -1
  61. package/lib/components/DataGrid/Row/Row.d.ts.map +1 -1
  62. package/lib/components/DataGrid/State/State.d.ts +1 -1
  63. package/lib/components/DataGrid/State/State.d.ts.map +1 -1
  64. package/lib/components/DataGridActionCell/DataGridActionCell.d.ts +1 -1
  65. package/lib/components/DataGridActionCell/DataGridActionCell.d.ts.map +1 -1
  66. package/lib/components/DataGridActionCell/MainAction/MainAction.d.ts +1 -1
  67. package/lib/components/DataGridActionCell/MainAction/MainAction.d.ts.map +1 -1
  68. package/lib/components/DataGridActionCell/MainAction/MainIconButton/MainIconButton.d.ts +1 -1
  69. package/lib/components/DataGridActionCell/MainAction/MainIconButton/MainIconButton.d.ts.map +1 -1
  70. package/lib/components/DataGridActionCell/SecondaryAction/SecondaryAction.d.ts +1 -1
  71. package/lib/components/DataGridActionCell/SecondaryAction/SecondaryAction.d.ts.map +1 -1
  72. package/lib/components/DataGridSortHeader/DataGridSortHeader.d.ts +1 -1
  73. package/lib/components/DataGridSortHeader/DataGridSortHeader.d.ts.map +1 -1
  74. package/lib/components/DataList/DataList.d.ts +1 -1
  75. package/lib/components/DataList/DataList.d.ts.map +1 -1
  76. package/lib/components/DataList/EndData/EndData.d.ts +1 -1
  77. package/lib/components/DataList/EndData/EndData.d.ts.map +1 -1
  78. package/lib/components/DataList/ErrorState/ErrorState.d.ts +1 -1
  79. package/lib/components/DataList/ErrorState/ErrorState.d.ts.map +1 -1
  80. package/lib/components/DataList/Loader/Loader.d.ts +1 -1
  81. package/lib/components/DataList/Loader/Loader.d.ts.map +1 -1
  82. package/lib/components/DataList/NoData/NoData.d.ts +1 -1
  83. package/lib/components/DataList/NoData/NoData.d.ts.map +1 -1
  84. package/lib/components/DataList/ScrollToTopButton/ScrollToTopButton.d.ts +1 -1
  85. package/lib/components/DataList/ScrollToTopButton/ScrollToTopButton.d.ts.map +1 -1
  86. package/lib/components/DatePicker/DatePicker.d.ts +1 -1
  87. package/lib/components/DatePicker/DatePicker.d.ts.map +1 -1
  88. package/lib/components/Description/Description.d.ts +3 -3
  89. package/lib/components/Description/DescriptionContext/DescriptionContextProvider/DescriptionContextProvider.d.ts +1 -1
  90. package/lib/components/Description/DescriptionContext/DescriptionContextProvider/DescriptionContextProvider.d.ts.map +1 -1
  91. package/lib/components/Description/Name/Name.d.ts +1 -1
  92. package/lib/components/Description/Name/Name.d.ts.map +1 -1
  93. package/lib/components/Description/Value/Value.d.ts +1 -1
  94. package/lib/components/Description/Value/Value.d.ts.map +1 -1
  95. package/lib/components/Dialog/Dialog.d.ts +10 -10
  96. package/lib/components/Dialog/Dialog.d.ts.map +1 -1
  97. package/lib/components/Dialog/styles.css.d.ts.map +1 -1
  98. package/lib/components/Drawer/Drawer.d.ts +1 -1
  99. package/lib/components/Drawer/Drawer.d.ts.map +1 -1
  100. package/lib/components/DropdownMenu/DropdownMenu.d.ts +15 -15
  101. package/lib/components/DropdownMenu/DropdownMenu.d.ts.map +1 -1
  102. package/lib/components/DropdownMenu/styles.css.d.ts.map +1 -1
  103. package/lib/components/Empty/Empty.d.ts +6 -6
  104. package/lib/components/Empty/Empty.d.ts.map +1 -1
  105. package/lib/components/Empty/styles.css.d.ts.map +1 -1
  106. package/lib/components/ImageCarousel/ImageCarousel.d.ts +1 -1
  107. package/lib/components/ImageCarousel/ImageCarousel.d.ts.map +1 -1
  108. package/lib/components/Input/Input.d.ts +1 -1
  109. package/lib/components/Input/Input.d.ts.map +1 -1
  110. package/lib/components/Input/styles.css.d.ts.map +1 -1
  111. package/lib/components/InputOTP/InputOTP.d.ts +1 -1
  112. package/lib/components/InputOTP/InputOTP.d.ts.map +1 -1
  113. package/lib/components/InputOTP/Separator/Separator.d.ts +1 -1
  114. package/lib/components/InputOTP/Separator/Separator.d.ts.map +1 -1
  115. package/lib/components/InputOTP/Slot/Slot.d.ts +1 -1
  116. package/lib/components/InputOTP/Slot/Slot.d.ts.map +1 -1
  117. package/lib/components/Label/Label.d.ts +1 -1
  118. package/lib/components/Label/Label.d.ts.map +1 -1
  119. package/lib/components/MaskField/MaskField.d.ts +1 -1
  120. package/lib/components/MaskField/MaskField.d.ts.map +1 -1
  121. package/lib/components/Notification/NotificationContainer/NotificationContainer.d.ts +1 -1
  122. package/lib/components/Notification/NotificationContainer/NotificationContainer.d.ts.map +1 -1
  123. package/lib/components/OverflowTypography/OverflowTypography.d.ts +1 -1
  124. package/lib/components/OverflowTypography/OverflowTypography.d.ts.map +1 -1
  125. package/lib/components/PageLayout/Aside/Aside.d.ts +1 -1
  126. package/lib/components/PageLayout/Aside/Aside.d.ts.map +1 -1
  127. package/lib/components/PageLayout/Content/Content.d.ts +1 -1
  128. package/lib/components/PageLayout/Content/Content.d.ts.map +1 -1
  129. package/lib/components/PageLayout/Footer/Footer.d.ts +1 -1
  130. package/lib/components/PageLayout/Footer/Footer.d.ts.map +1 -1
  131. package/lib/components/PageLayout/Header/Header.d.ts +1 -1
  132. package/lib/components/PageLayout/Header/Header.d.ts.map +1 -1
  133. package/lib/components/PageLayout/PageLayout.d.ts +5 -5
  134. package/lib/components/Pagination/Pagination.d.ts +1 -1
  135. package/lib/components/Pagination/Pagination.d.ts.map +1 -1
  136. package/lib/components/PeriodPicker/PeriodPicker.d.ts +1 -1
  137. package/lib/components/PeriodPicker/PeriodPicker.d.ts.map +1 -1
  138. package/lib/components/PeriodPicker/YearsDropdown/YearsDropdown.d.ts +1 -1
  139. package/lib/components/PeriodPicker/YearsDropdown/YearsDropdown.d.ts.map +1 -1
  140. package/lib/components/Placeholder/Image/Image.d.ts +1 -1
  141. package/lib/components/Placeholder/Image/Image.d.ts.map +1 -1
  142. package/lib/components/Placeholder/Placeholder.d.ts +1 -1
  143. package/lib/components/Placeholder/Placeholder.d.ts.map +1 -1
  144. package/lib/components/Popover/Popover.d.ts +3 -3
  145. package/lib/components/RadioGroup/RadioGroup.d.ts +1 -1
  146. package/lib/components/RadioGroup/RadioGroup.d.ts.map +1 -1
  147. package/lib/components/RadioGroup/RadioGroupItem.d.ts +1 -1
  148. package/lib/components/RadioGroup/RadioGroupItem.d.ts.map +1 -1
  149. package/lib/components/RangeInput/RangeInput.d.ts +1 -1
  150. package/lib/components/RangeInput/RangeInput.d.ts.map +1 -1
  151. package/lib/components/ScrollTopButton/ScrollTopButton.d.ts +1 -1
  152. package/lib/components/ScrollTopButton/ScrollTopButton.d.ts.map +1 -1
  153. package/lib/components/Select/Select.d.ts +7 -7
  154. package/lib/components/Select/Select.d.ts.map +1 -1
  155. package/lib/components/Select/styles.css.d.ts.map +1 -1
  156. package/lib/components/Sheet/Sheet.d.ts +10 -10
  157. package/lib/components/Sheet/Sheet.d.ts.map +1 -1
  158. package/lib/components/Sheet/styles.css.d.ts.map +1 -1
  159. package/lib/components/Sidebar/Sidebar.d.ts +19 -19
  160. package/lib/components/Sidebar/Sidebar.d.ts.map +1 -1
  161. package/lib/components/Sidebar/constants.d.ts +7 -0
  162. package/lib/components/Sidebar/constants.d.ts.map +1 -0
  163. package/lib/components/Sidebar/styles.css.d.ts.map +1 -1
  164. package/lib/components/Slider/Slider.d.ts +2 -1
  165. package/lib/components/Slider/Slider.d.ts.map +1 -1
  166. package/lib/components/Tabs/Tabs.d.ts +4 -4
  167. package/lib/components/Tabs/TabsContent.d.ts +1 -1
  168. package/lib/components/Tabs/TabsContent.d.ts.map +1 -1
  169. package/lib/components/Tabs/TabsList.d.ts +1 -1
  170. package/lib/components/Tabs/TabsList.d.ts.map +1 -1
  171. package/lib/components/Tabs/TabsTrigger.d.ts +1 -1
  172. package/lib/components/Tabs/TabsTrigger.d.ts.map +1 -1
  173. package/lib/components/TextField/TextField.d.ts +1 -1
  174. package/lib/components/TextField/TextField.d.ts.map +1 -1
  175. package/lib/components/ToggleGroup/ToggleGroup.d.ts +1 -1
  176. package/lib/components/ToggleGroup/ToggleGroup.d.ts.map +1 -1
  177. package/lib/components/Tooltip/Tooltip.d.ts +1 -1
  178. package/lib/components/Tooltip/Tooltip.d.ts.map +1 -1
  179. package/lib/components/Typography/Typography.d.ts +1 -1
  180. package/lib/components/Typography/Typography.d.ts.map +1 -1
  181. package/lib/form/Form/Form.d.ts +1 -1
  182. package/lib/form/Form/Form.d.ts.map +1 -1
  183. package/lib/form/FormMaskField/FormMaskField.d.ts +1 -1
  184. package/lib/form/FormMaskField/FormMaskField.d.ts.map +1 -1
  185. package/lib/form/FormSubmitButton/FormSubmitButton.d.ts +1 -1
  186. package/lib/form/FormSubmitButton/FormSubmitButton.d.ts.map +1 -1
  187. package/lib/form/FormTextField/FormTextField.d.ts +1 -1
  188. package/lib/form/FormTextField/FormTextField.d.ts.map +1 -1
  189. package/lib/hooks/index.d.ts +1 -0
  190. package/lib/hooks/index.d.ts.map +1 -1
  191. package/lib/hooks/useIsMobile/constants.d.ts +2 -0
  192. package/lib/hooks/useIsMobile/constants.d.ts.map +1 -0
  193. package/lib/hooks/useIsMobile/index.d.ts +2 -0
  194. package/lib/hooks/useIsMobile/index.d.ts.map +1 -0
  195. package/lib/hooks/useIsMobile/useIsMobile.d.ts +2 -0
  196. package/lib/hooks/useIsMobile/useIsMobile.d.ts.map +1 -0
  197. package/lib/index.mjs +4510 -1
  198. package/lib/stories/Accordion.stories.d.ts +1 -1
  199. package/lib/stories/Accordion.stories.d.ts.map +1 -1
  200. package/lib/stories/AlertDialog.stories.d.ts +4 -4
  201. package/lib/stories/AlertDialog.stories.d.ts.map +1 -1
  202. package/lib/stories/Badge.stories.d.ts +1 -1
  203. package/lib/stories/Badge.stories.d.ts.map +1 -1
  204. package/lib/stories/Breadcrumb.stories.d.ts +4 -4
  205. package/lib/stories/Breadcrumb.stories.d.ts.map +1 -1
  206. package/lib/stories/Button.stories.d.ts +12 -12
  207. package/lib/stories/Button.stories.d.ts.map +1 -1
  208. package/lib/stories/ButtonGroup.stories.d.ts +5 -5
  209. package/lib/stories/ButtonGroup.stories.d.ts.map +1 -1
  210. package/lib/stories/Calendar.stories.d.ts +6 -6
  211. package/lib/stories/Calendar.stories.d.ts.map +1 -1
  212. package/lib/stories/Card.stories.d.ts +7 -7
  213. package/lib/stories/Card.stories.d.ts.map +1 -1
  214. package/lib/stories/Carousel.stories.d.ts +2 -2
  215. package/lib/stories/Carousel.stories.d.ts.map +1 -1
  216. package/lib/stories/Checkbox.stories.d.ts +2 -2
  217. package/lib/stories/Checkbox.stories.d.ts.map +1 -1
  218. package/lib/stories/CircularProgress.stories.d.ts +2 -2
  219. package/lib/stories/CircularProgress.stories.d.ts.map +1 -1
  220. package/lib/stories/ConfirmAction.stories.d.ts +5 -5
  221. package/lib/stories/ConfirmAction.stories.d.ts.map +1 -1
  222. package/lib/stories/CopyTypography.stories.d.ts +5 -5
  223. package/lib/stories/CopyTypography.stories.d.ts.map +1 -1
  224. package/lib/stories/DashboardLayout.stories.d.ts +4 -4
  225. package/lib/stories/DashboardLayout.stories.d.ts.map +1 -1
  226. package/lib/stories/DataGrid.stories.d.ts +7 -7
  227. package/lib/stories/DataGrid.stories.d.ts.map +1 -1
  228. package/lib/stories/DataGridActionCell.stories.d.ts +4 -4
  229. package/lib/stories/DataGridActionCell.stories.d.ts.map +1 -1
  230. package/lib/stories/DataList.stories.d.ts +9 -7
  231. package/lib/stories/DataList.stories.d.ts.map +1 -1
  232. package/lib/stories/DatePicker.stories.d.ts +1 -1
  233. package/lib/stories/DatePicker.stories.d.ts.map +1 -1
  234. package/lib/stories/Description.stories.d.ts +15 -15
  235. package/lib/stories/Description.stories.d.ts.map +1 -1
  236. package/lib/stories/Dialog.stories.d.ts +5 -5
  237. package/lib/stories/Dialog.stories.d.ts.map +1 -1
  238. package/lib/stories/Drawer.stories.d.ts +2 -1
  239. package/lib/stories/Drawer.stories.d.ts.map +1 -1
  240. package/lib/stories/DropdownMenu.stories.d.ts +5 -5
  241. package/lib/stories/DropdownMenu.stories.d.ts.map +1 -1
  242. package/lib/stories/Empty.stories.d.ts +3 -3
  243. package/lib/stories/Empty.stories.d.ts.map +1 -1
  244. package/lib/stories/Input.stories.d.ts +6 -6
  245. package/lib/stories/Input.stories.d.ts.map +1 -1
  246. package/lib/stories/InputOTP.stories.d.ts +1 -1
  247. package/lib/stories/InputOTP.stories.d.ts.map +1 -1
  248. package/lib/stories/MaskField.stories.d.ts +2 -2
  249. package/lib/stories/MaskField.stories.d.ts.map +1 -1
  250. package/lib/stories/OverflowTypography.stories.d.ts +5 -5
  251. package/lib/stories/OverflowTypography.stories.d.ts.map +1 -1
  252. package/lib/stories/Pagination.stories.d.ts +1 -1
  253. package/lib/stories/Pagination.stories.d.ts.map +1 -1
  254. package/lib/stories/PeriodPicker.stories.d.ts +2 -2
  255. package/lib/stories/PeriodPicker.stories.d.ts.map +1 -1
  256. package/lib/stories/Popover.stories.d.ts +1 -1
  257. package/lib/stories/Popover.stories.d.ts.map +1 -1
  258. package/lib/stories/RadioGroup.stories.d.ts +1 -1
  259. package/lib/stories/RadioGroup.stories.d.ts.map +1 -1
  260. package/lib/stories/RangeInput.stories.d.ts +2 -1
  261. package/lib/stories/RangeInput.stories.d.ts.map +1 -1
  262. package/lib/stories/Select.stories.d.ts +3 -3
  263. package/lib/stories/Select.stories.d.ts.map +1 -1
  264. package/lib/stories/Sheet.stories.d.ts +3 -3
  265. package/lib/stories/Sheet.stories.d.ts.map +1 -1
  266. package/lib/stories/Sidebar/Sidebar.stories.d.ts +38 -0
  267. package/lib/stories/Sidebar/Sidebar.stories.d.ts.map +1 -0
  268. package/lib/stories/{sidebarDemo.css.d.ts → Sidebar/sidebarDemo.css.d.ts} +4 -0
  269. package/lib/stories/Sidebar/sidebarDemo.css.d.ts.map +1 -0
  270. package/lib/stories/Slider.stories.d.ts +5 -5
  271. package/lib/stories/Slider.stories.d.ts.map +1 -1
  272. package/lib/stories/Tabs.stories.d.ts +3 -3
  273. package/lib/stories/Tabs.stories.d.ts.map +1 -1
  274. package/lib/stories/TextField.stories.d.ts +4 -4
  275. package/lib/stories/TextField.stories.d.ts.map +1 -1
  276. package/lib/stories/ToggleGroup.stories.d.ts +4 -4
  277. package/lib/stories/ToggleGroup.stories.d.ts.map +1 -1
  278. package/lib/stories/Tooltip.stories.d.ts +2 -2
  279. package/lib/stories/Tooltip.stories.d.ts.map +1 -1
  280. package/lib/stories/Typography.stories.d.ts +12 -12
  281. package/lib/stories/Typography.stories.d.ts.map +1 -1
  282. package/lib/styles.css +4924 -1
  283. package/lib/theme/index.d.ts +1 -0
  284. package/lib/theme/index.d.ts.map +1 -1
  285. package/lib/{utils.d.ts → theme/utils.d.ts} +1 -1
  286. package/lib/theme/utils.d.ts.map +1 -0
  287. package/package.json +21 -21
  288. package/lib/stories/Sidebar.stories.d.ts +0 -38
  289. package/lib/stories/Sidebar.stories.d.ts.map +0 -1
  290. package/lib/stories/sidebarDemo.css.d.ts.map +0 -1
  291. package/lib/utils.d.ts.map +0 -1
package/lib/index.mjs CHANGED
@@ -1 +1,4510 @@
1
- import{Fragment as e,jsx as t,jsxs as a}from"react/jsx-runtime";import{Accordion as r,Checkbox as l}from"@base-ui/react";import n,{clsx as s}from"clsx";import{ArrowDownNarrowWide as o,ArrowDownUp as i,ArrowDownWideNarrow as d,Calendar1 as c,Check as u,CheckIcon as _,ChevronDown as m,ChevronLeft as h,ChevronRight as p,ChevronRightIcon as g,ChevronUp as y,CircleCheck as b,CircleIcon as f,Copy as v,Ellipsis as N,EllipsisVertical as w,Info as k,MoreHorizontalIcon as x,OctagonAlert as C,PanelLeftClose as z,PanelLeftIcon as S,PanelLeftOpen as T,TriangleAlert as P,XIcon as D}from"lucide-react";import{AlertDialog as I}from"@base-ui/react/alert-dialog";import{Button as A}from"@base-ui/react/button";import{Avatar as L}from"@base-ui/react/avatar";import{mergeProps as R}from"@base-ui/react/merge-props";import{useRender as M}from"@base-ui/react/use-render";import{Separator as j}from"@base-ui/react/separator";import{DayPicker as F}from"react-day-picker";import{ru as O}from"react-day-picker/locale";import q,{createContext as B,createElement as E,useCallback as $,useContext as H,useEffect as G,useId as V,useLayoutEffect as W,useMemo as Y,useRef as K,useState as U}from"react";import X from"embla-carousel-react";import{Collapsible as J}from"@base-ui/react/collapsible";import{Popover as Q}from"@base-ui/react/popover";import{Arrow as Z,Content as ee,Portal as et,Provider as ea,Root as er,Trigger as el}from"@radix-ui/react-tooltip";import{Menu as en}from"@base-ui/react/menu";import{Virtuoso as es}from"react-virtuoso";import{useMask as eo}from"@react-input/mask";import{Root as ei}from"@radix-ui/react-label";import{Dialog as ed}from"@base-ui/react/dialog";import{Drawer as ec,Root as eu}from"vaul";import{OTPInput as e_}from"input-otp";import{Toaster as em,toast as eh}from"sonner";import{Indicator as ep,Item as eg,Root as ey}from"@radix-ui/react-radio-group";import{Slider as eb}from"@base-ui/react/slider";import{Content as ef,Group as ev,Icon as eN,Item as ew,ItemIndicator as ek,ItemText as ex,Label as eC,Portal as ez,Root as eS,ScrollDownButton as eT,ScrollUpButton as eP,Separator as eD,Trigger as eI,Value as eA,Viewport as eL}from"@radix-ui/react-select";import{Content as eR,List as eM,Tabs as ej,Trigger as eF}from"@radix-ui/react-tabs";import{Controller as eO,FormProvider as eq,useController as eB,useFieldArray as eE,useForm as e$,useFormContext as eH,useWatch as eG}from"react-hook-form";import*as eV from"react";var eW,eY={};eY.d=(e,t)=>{for(var a in t)eY.o(t,a)&&!eY.o(e,a)&&Object.defineProperty(e,a,{enumerable:!0,get:t[a]})},eY.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),eY.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var eK={};function eU({className:e,...a}){return t(r.Root,{"data-slot":"accordion",className:s("style__1b0hb6s2",e),...a})}eY.r(eK),eY.d(eK,{e:()=>eX,dK:()=>eJ,ru:()=>eQ,ik:()=>eZ,Fu:()=>e1,Lq:()=>e0,PM:()=>e2}),eU.Item=function({className:e,...a}){return t(r.Item,{"data-slot":"accordion-item",className:s("style__1b0hb6s3",e),...a})},eU.Trigger=function({className:e,children:l,...n}){return t(r.Header,{className:"style__1b0hb6s4",children:a(r.Trigger,{"data-slot":"accordion-trigger",className:s("style__1b0hb6s5",e),...n,children:[l,t(m,{"data-slot":"accordion-trigger-icon",size:16,className:"style__1b0hb6s7 style__1b0hb6s6"}),t(y,{"data-slot":"accordion-trigger-icon",size:16,className:"style__1b0hb6s8 style__1b0hb6s6"})]})})},eU.Content=function({className:e,children:a,...l}){return t(r.Panel,{"data-slot":"accordion-content",className:s("style__1b0hb6s9",e),...l,children:t("div",{className:s("style__1b0hb6sa",e),children:a})})};var eX="style__1ersxw10",eJ={sm:"sm__1ersxw19",md:"md__1ersxw1a",lg:"lg__1ersxw1b",icon:"icon__1ersxw1c",iconSm:"iconSm__1ersxw1d"},eQ={default:"default__1ersxw14",destructive:"destructive__1ersxw15",outline:"outline__1ersxw16",ghost:"ghost__1ersxw17",link:"link__1ersxw18"},eZ="style__1ersxw1f",e1="style__1ersxw13",e0="style__1ersxw12",e2="style__1ersxw1e";let e6=({className:e,variant:r="default",size:l="md",startAdornment:n,endAdornment:o,isLoading:i=!1,fullWidth:d,children:c,...u})=>a(A,{nativeButton:u.nativeButton??!u.render,className:s(eX,eQ[r],eJ[l],{[e1]:d,[e0]:i},e),...u,children:[n&&t("span",{className:e2,children:n}),c,o&&t("span",{className:eZ,children:o})]}),{ru:e5,dK:e9}=eK;function e4({...e}){return t(I.Portal,{"data-slot":"alert-dialog-portal",...e})}function e8({className:e,...a}){return t(I.Backdrop,{"data-slot":"alert-dialog-overlay",className:s("style__qmtpwy4",e),...a})}function e3({...e}){return t(I.Root,{"data-slot":"alert-dialog",...e})}function e7({className:e,size:a="default",...r}){return t(L.Root,{"data-slot":"avatar","data-size":a,className:s("style__hhcrfl0",e),...r})}e3.Trigger=function({...e}){return t(I.Trigger,{"data-slot":"alert-dialog-trigger",...e})},e3.Overlay=e8,e3.Content=function({className:e,size:r="default",...l}){return a(e4,{children:[t(e8,{}),t(I.Popup,{"data-slot":"alert-dialog-content","data-size":r,className:s("style__qmtpwy5",e),...l})]})},e3.Header=function({className:e,...a}){return t("div",{"data-slot":"alert-dialog-header",className:s("style__qmtpwy6",e),...a})},e3.Footer=function({className:e,...a}){return t("div",{"data-slot":"alert-dialog-footer",className:s("style__qmtpwy7",e),...a})},e3.Media=function({className:e,...a}){return t("div",{"data-slot":"alert-dialog-media",className:s("style__qmtpwy8",e),...a})},e3.Title=function({className:e,...a}){return t(I.Title,{"data-slot":"alert-dialog-title",className:s("style__qmtpwy9",e),...a})},e3.Description=function({className:e,...a}){return t(I.Description,{"data-slot":"alert-dialog-description",className:s("style__qmtpwya",e),...a})},e3.Action=function({className:e,...a}){return t(e6,{"data-slot":"alert-dialog-action",className:e,...a})},e3.Cancel=function({className:e,variant:a="outline",size:r="md",...l}){return t(I.Close,{"data-slot":"alert-dialog-cancel",className:e,render:t(e6,{variant:a,size:r}),...l})},e7.Image=function({className:e,...a}){return t(L.Image,{"data-slot":"avatar-image",className:s("style__hhcrfl1",e),...a})},e7.Fallback=function({className:e,...a}){return t(L.Fallback,{"data-slot":"avatar-fallback",className:s("style__hhcrfl2",e),...a})},e7.Badge=function({className:e,...a}){return t("span",{"data-slot":"avatar-badge",className:s("style__hhcrfl3",e),...a})},e7.Group=function({className:e,...a}){return t("div",{"data-slot":"avatar-group",className:s("style__hhcrfl4",e),...a})},e7.GroupCount=function({className:e,...a}){return t("div",{"data-slot":"avatar-group-count",className:s("style__hhcrfl5",e),...a})};var te={default:"default__1af895x1",secondary:"secondary__1af895x2",destructive:"destructive__1af895x3",outline:"outline__1af895x4"};function tt({className:e,variant:t="default",render:a,...r}){return M({defaultTagName:"span",props:R({className:s("style__1af895x0",te[t],e)},r),render:a,state:{slot:"badge",variant:t}})}function ta({className:e,...a}){return t("nav",{"aria-label":"breadcrumb","data-slot":"breadcrumb",className:e,...a})}function tr({className:e,orientation:a="horizontal",...r}){return t("fieldset",{"data-slot":"button-group","data-orientation":a,className:s("style__1mf3lgr0",e),...r})}ta.List=function({className:e,...a}){return t("ol",{"data-slot":"breadcrumb-list",className:s("style__1dceszz0",e),...a})},ta.Item=function({className:e,...a}){return t("li",{"data-slot":"breadcrumb-item",className:s("style__1dceszz1",e),...a})},ta.Link=function({className:e,render:t,...a}){return M({defaultTagName:"a",props:R({className:s("style__1dceszz2",e)},a),render:t,state:{slot:"breadcrumb-link"}})},ta.Page=function({className:e,...a}){return t("span",{"data-slot":"breadcrumb-page","aria-current":"page",className:s("style__1dceszz3",e),...a})},ta.Separator=function({children:e,className:a,...r}){return t("li",{"data-slot":"breadcrumb-separator",role:"presentation","aria-hidden":"true",className:s("style__1dceszz4",a),...r,children:e??t(g,{})})},ta.Ellipsis=function({className:e,...r}){return a("span",{"data-slot":"breadcrumb-ellipsis",role:"presentation","aria-hidden":"true",className:s("style__1dceszz5",e),...r,children:[t(x,{}),t("span",{className:"style__1dceszz6",children:"More"})]})},tr.Text=function({className:e,render:t,...a}){return M({defaultTagName:"div",props:R({className:s("style__1mf3lgr1",e)},a),render:t,state:{slot:"button-group-text"}})},tr.Separator=function({className:e,orientation:a="vertical",...r}){return t(j,{"data-slot":"button-group-separator","data-orientation":a,orientation:a,className:s("style__1mf3lgr2",e),...r})};var tl={left:"left__1sba6zok",center:"center__1sba6zol",right:"right__1sba6zom",justify:"justify__1sba6zon"},tn={primary:"primary__1sba6zoc",secondary:"secondary__1sba6zod",disabled:"disabled__1sba6zoe",success:"success__1sba6zof",error:"error__1sba6zog",warning:"warning__1sba6zoh",info:"info__1sba6zoi",muted:"muted__1sba6zoj"},ts={none:"none__1sba6zox",underline:"underline__1sba6zoy",lineThrough:"lineThrough__1sba6zoz"},to={block:"block__1sba6zoo",inline:"inline__1sba6zop"},ti={lowercase:"lowercase__1sba6zou",uppercase:"uppercase__1sba6zov",capitalize:"capitalize__1sba6zow"},td={h1:"h1__1sba6zo0",h2:"h2__1sba6zo1",h3:"h3__1sba6zo2",h4:"h4__1sba6zo3",h5:"h5__1sba6zo4",h6:"h6__1sba6zo5",subtitle1:"subtitle1__1sba6zo6",subtitle2:"subtitle2__1sba6zo7",body1:"body1__1sba6zo8",body2:"body2__1sba6zo9",caption:"caption__1sba6zoa",overline:"overline__1sba6zob"},tc={normal:"normal__1sba6zoq",medium:"medium__1sba6zor",semibold:"semibold__1sba6zos",bold:"bold__1sba6zot"};let tu={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",caption:"span",overline:"span"},t_=({className:e,variant:a="body1",component:r,color:l="primary",align:n="left",display:o="inline",weight:i="normal",transform:d,decoration:c="none",gutterBottom:u,children:_,...m})=>t(r||tu[a||"body1"],{className:s(ts[c],td[a],tn[l],tc[i],d&&ti[d],to[o],tl[n],{style__1sba6zo10:u},e),...m,children:_}),tm=e=>{let{modifiers:a,className:r,...l}=e,n=K(null);return G(()=>{a.focused&&n.current?.focus()},[a.focused]),t(e6,{ref:n,className:s("dayButton__hxs6pw0",{outside__hxs6pw2:a.outside,today__hxs6pw1:a.today},r),variant:a.selected?"default":"ghost",...l})};function th(e){let{options:r,onChange:l,...n}=e,s=r?.find(({value:e})=>e===n.value);return a(rd,{value:s?.value.toString(),onValueChange:e=>{l&&l({target:{value:e}})},children:[t(r_,{className:"style__1e2msjb0",children:t(ru,{placeholder:s?.label})}),t(rp,{children:r?.map(({value:e,label:a,disabled:r})=>t(ry,{value:e.toString(),disabled:r,children:t(t_,{align:"center",transform:"capitalize",children:a})},e))})]})}var tp="monthButton__14q7je21";let tg=({className:e,classNames:a,showOutsideDays:r=!0,...l})=>t(F,{locale:O,showOutsideDays:r,classNames:{month:"month__14q7je23",months:"months__14q7je22",nav:"nav__14q7je20",month_caption:"monthCaption__14q7je24",dropdown:"dropdownNav__14q7je26",dropdowns:"dropdowns__14q7je25"},components:{DayButton:tm,Dropdown:th,PreviousMonthButton:({className:e,color:a,...r})=>t(e6,{className:n(tp,e),variant:"ghost",...r}),NextMonthButton:({className:e,color:a,...r})=>t(e6,{className:n(tp,e),variant:"ghost",...r}),CaptionLabel:({className:e,color:a,...r})=>t(t_,{transform:"capitalize",className:e,...r})},...l});var ty={colors:{primary:"var(--colors-primary)",secondary:"var(--colors-secondary)",warning:"var(--colors-warning)",error:"var(--colors-error)",success:"var(--colors-success)",border:"var(--colors-border)",info:"var(--colors-info)",background:{tooltip:"var(--colors-background-tooltip)",paper:"var(--colors-background-paper)",element:"var(--colors-background-element)",elementHover:"var(--colors-background-elementHover)",sidebar:"var(--colors-background-sidebar)"},foreground:{primary:"var(--colors-foreground-primary)",secondary:"var(--colors-foreground-secondary)"},text:{primary:"var(--colors-text-primary)",secondary:"var(--colors-text-secondary)",disabled:"var(--colors-text-disabled)",hint:"var(--colors-text-hint)"}},spacing:{1:"var(--spacing-1)",2:"var(--spacing-2)",3:"var(--spacing-3)",4:"var(--spacing-4)",5:"var(--spacing-5)",6:"var(--spacing-6)",8:"var(--spacing-8)",10:"var(--spacing-10)",12:"var(--spacing-12)",16:"var(--spacing-16)",20:"var(--spacing-20)"},elevation:{1:"var(--elevation-1)",2:"var(--elevation-2)",3:"var(--elevation-3)",4:"var(--elevation-4)",6:"var(--elevation-5)"},fontSize:{xs:"var(--fontSize-xs)",sm:"var(--fontSize-sm)",base:"var(--fontSize-base)",lg:"var(--fontSize-lg)",xl:"var(--fontSize-xl)","2xl":"var(--fontSize-2xl)","3xl":"var(--fontSize-3xl)","4xl":"var(--fontSize-4xl)"},fontWeight:{normal:"var(--fontWeight-normal)",medium:"var(--fontWeight-medium)",semibold:"var(--fontWeight-semibold)",bold:"var(--fontWeight-bold)"},lineHeight:{none:"var(--lineHeight-none)",tight:"var(--lineHeight-tight)",snug:"var(--lineHeight-snug)",normal:"var(--lineHeight-normal)",relaxed:"var(--lineHeight-relaxed)",loose:"var(--lineHeight-loose)"},borderRadius:{sm:"var(--borderRadius-sm)",md:"var(--borderRadius-md)",lg:"var(--borderRadius-lg)"}};let tb=({className:e,elevation:a=2,...r})=>t("div",{style:{boxShadow:ty.elevation[a]},className:s("style__oyalw00",e),...r});tb.Footer=({className:e,...a})=>t("div",{className:s("style__oyalw05",e),...a}),tb.Header=({className:e,...a})=>t("div",{className:s("style__oyalw01",e),...a}),tb.Title=({className:e,...a})=>t("h3",{className:s("style__oyalw02",e),...a}),tb.Description=({className:e,...a})=>t("p",{className:s("style__oyalw03",e),...a}),tb.Content=({className:e,...a})=>t("div",{className:s("style__oyalw04",e),...a});let tf=q.createContext(null);function tv(){let e=q.useContext(tf);if(!e)throw Error("useCarousel must be used within a <Carousel />");return e}var tN={horizontal:"horizontal__2d6ocq3",vertical:"vertical__2d6ocq4"};function tw({className:r,...l}){let{orientation:n="horizontal",canScrollNext:o,scrollNext:i,canScrollPrev:d,scrollPrev:c}=tv();return a(e,{children:[t("button",{className:s("style__2d6ocq1 style__2d6ocq0",tN[n]),type:"button","data-slot":"carousel-next",disabled:!o,onClick:i,...l,children:"horizontal"===n?t(p,{}):t(m,{})}),t("button",{type:"button",className:s("style__2d6ocq2 style__2d6ocq0",tN[n]),"data-slot":"carousel-previous",disabled:!d,onClick:c,...l,children:"horizontal"===n?t(h,{}):t(y,{})})]})}var tk={horizontal:"horizontal__i1lems1",vertical:"vertical__i1lems2"};function tx(e){let{carouselRef:a,orientation:r="horizontal"}=tv();return t("div",{className:"style__i1lems0",ref:a,"data-slot":"carousel-content",children:t("div",{className:tk[r],...e})})}var tC={horizontal:"horizontal__e2zpp64 style__e2zpp63",vertical:"vertical__e2zpp65 style__e2zpp63"},tz={horizontal:"horizontal__e2zpp61 style__e2zpp60",vertical:"vertical__e2zpp62 style__e2zpp60"};let tS=({api:e,orientation:a})=>{let{selectedIndex:r,scrollSnaps:l,onDotButtonClick:n}=(e=>{let[t,a]=U(0),[r,l]=U([]),n=$(t=>{e&&e.scrollTo(t)},[e]),s=$(e=>{e&&l(e.scrollSnapList())},[]),o=$(e=>{e&&a(e.selectedScrollSnap())},[]);return G(()=>{e&&(s(e),o(e),e.on("reInit",s).on("reInit",o).on("select",o))},[e,s,o]),{selectedIndex:t,scrollSnaps:r,onDotButtonClick:n}})(e);return t("div",{className:tz[a],children:l.map((e,l)=>t("button",{type:"button",className:s(tC[a],{style__e2zpp66:l===r}),onClick:()=>n(l)},e))})};function tT(e){return t("div",{className:"style__1gif6yr0",role:"presentation","aria-roledescription":"slide","data-slot":"carousel-item",...e})}function tP({width:e="100%",height:r="100%",...l}){let{canScrollNext:n,canScrollPrev:o,scrollNext:i,scrollPrev:d,api:c,opts:u,orientation:_,carouselRef:m,handleKeyDown:h,data:p,isShowButtons:g,isShowDots:y}=(({orientation:e="horizontal",opts:t,setApi:a,plugins:r,data:l,showDots:n,showArrows:s})=>{let[o,i]=X({...t,axis:"horizontal"===e?"x":"y"},r),[d,c]=U(!1),[u,_]=U(!1),m=!!(s&&l.length>1),h=!!(n&&l.length>1),p=$(e=>{e&&(c(e.canScrollPrev()),_(e.canScrollNext()))},[]),g=$(e=>{i&&i.scrollTo(e)},[i]),y=$(()=>{i?.scrollPrev()},[i]),b=$(()=>{i?.scrollNext()},[i]),f=$(e=>{"ArrowLeft"===e.key?(e.preventDefault(),y()):"ArrowRight"===e.key&&(e.preventDefault(),b())},[y,b]);return G(()=>{i&&a&&a(i)},[i,a]),G(()=>{if(i)return p(i),i.on("reInit",p),i.on("select",p),()=>{i?.off("select",p)}},[i,p]),{carouselRef:o,api:i,scrollPrev:y,scrollNext:b,canScrollPrev:d,canScrollNext:u,handleKeyDown:f,opts:t,orientation:e,onDotButtonClick:g,isShowButtons:m,isShowDots:h,data:l}})(l);return t(tf.Provider,{value:{carouselRef:m,api:c,opts:u,orientation:_||(u?.axis==="y"?"vertical":"horizontal"),scrollPrev:d,scrollNext:i,canScrollPrev:o,canScrollNext:n},children:a("div",{onKeyDownCapture:h,className:s("Carousel__1jbydv50",l.className),"data-slot":"carousel",style:{width:e,height:r},children:[t(tx,{style:{width:e,height:r},children:p.map(e=>t(tT,{children:l.renderItem(e)},`${e[l.keyId]}`))}),g&&t(tw,{}),y&&t(tS,{api:c,orientation:_})]})})}let tD=({className:e,...a})=>t(l.Root,{"data-slot":"checkbox",className:s("style__b7yo4k0",e),...a,children:t(l.Indicator,{className:"style__b7yo4k1",children:t(u,{className:"style__b7yo4k2"})})});var tI={primary:"primary__m6b9n27",secondary:"secondary__m6b9n28",inherit:"inherit__m6b9n29"},tA={determinate:"determinate__m6b9n25",indeterminate:"indeterminate__m6b9n26"};let tL=({size:e=30,thickness:r=2.6,color:l="primary",value:s=0,variant:o="indeterminate",className:i})=>{let d=(e-r)/2,c=2*Math.PI*d;return t("div",{className:n("style__m6b9n22",tA[o],tI[l],i),style:{width:e,height:e},children:a("svg",{className:"style__m6b9n23",viewBox:`0 0 ${e} ${e}`,children:[t("title",{children:"Progress bar"}),t("circle",{className:n("style__m6b9n24","determinate"===o&&tA.determinate),cx:e/2,cy:e/2,r:d,fill:"none",strokeWidth:r,strokeDasharray:c,strokeDashoffset:"determinate"===o?c*(1-s/100):.25*c})]})})};function tR({...e}){return t(J.Root,{"data-slot":"collapsible",...e})}tR.Trigger=function({...e}){return t(J.Trigger,{"data-slot":"collapsible-trigger",...e})},tR.Content=function({...e}){return t(J.Panel,{"data-slot":"collapsible-content",...e})};let tM=Q.createHandle,tj=({...e})=>t(Q.Root,{"data-slot":"popover",...e});tj.Trigger=({...e})=>t(Q.Trigger,{"data-slot":"popover-trigger",...e}),tj.Content=({className:e,align:a="center",alignOffset:r=0,side:l="bottom",sideOffset:n=4,...o})=>t(Q.Portal,{children:t(Q.Positioner,{align:a,alignOffset:r,side:l,sideOffset:n,className:"style__1xy4jvu3",children:t(Q.Popup,{"data-slot":"popover-content",className:s("style__1xy4jvu2",e),...o})})}),tj.Root=tj;let tF=e=>{let{open:r,onActionComponentClick:l,onCancel:n,confirmButtonProps:o,onOpenChange:i}=(({skipConfirm:e,onConfirm:t,confirmButtonProps:a})=>{let[r,l]=U(!1);return{open:r,onActionComponentClick:()=>{e?t():l(!0)},confirmButtonProps:{variant:a?.isAccented?"destructive":"default",size:"sm",onClick:()=>{l(!1),t()}},onCancel:()=>{l(!1)},onOpenChange:e=>{l(e)}}})(e),{text:d,confirmButtonProps:c,popoverProps:u,actionComponent:_}=e,{text:m="Подтвердить"}=c||{},{side:h="bottom",align:p="center"}=u||{};return a(tj,{open:r,onOpenChange:i,children:[t(tj.Trigger,{children:_({onClick:l})}),t(tj.Content,{side:h,align:p,className:s("style__1q1uhgp2",{style__1q1uhgp3:!!d}),children:a("div",{className:"style__1q1uhgp1",children:[d&&t(t_,{children:d}),a("div",{className:"style__1q1uhgp0",children:[t(e6,{size:"sm",variant:"ghost",onClick:n,children:"Отмена"}),t(e6,{...o,children:m})]})]})})]})};var tO={sm:"sm__1o97kvm1",md:"md__1o97kvm2",lg:"lg__1o97kvm3"};let tq=e=>t("img",{alt:e.alt,src:e.src,className:n("style__1o97kvm0",tO[e.size||"md"],e.className),width:e.width,height:e.height}),tB={sm:"239px",md:"323px",lg:"458px"},tE={sm:"119px",md:"161px",lg:"229px"},t$={sm:"384px",md:"400px",lg:"460px"},tH={sm:"subtitle1",md:"h6",lg:"h5"};var tG={sm:"sm__1nenzg01",md:"md__1nenzg02",lg:"lg__1nenzg03"};let tV=({className:e,title:r,imgSrc:l,imgAlt:s,description:o,actions:i,size:d="sm",renderImage:c})=>{let u=Y(()=>c||tq,[c]);return a("div",{className:n("style__1nenzg00",tG[d],e),children:[a("div",{className:"style__1nenzg04",style:{maxWidth:t$[d]},children:[l&&t(u,{src:l,alt:s,width:tB[d],height:tE[d],size:d}),t(t_,{align:"center",color:"secondary",variant:tH[d],children:r}),o&&t(t_,{className:"style__1nenzg05",component:"div",variant:"body1",children:o})]}),i&&t("footer",{className:"style__1nenzg06",children:i})]})},tW=({isLoading:e,isError:a,isCustom:r,errorState:l,customState:n,children:s,loadingContent:o=t(tL,{color:"primary"})})=>{if(e)return t("div",{className:"style__nan0ao0",children:o});if(r&&n)return t(tV,{...n});if(a&&l){let{title:e="Произошла ошибка",imgAlt:a,imgSrc:r,errorList:n,onRetry:s,actions:o=t(e6,{onClick:s,children:"Попробовать снова"})}=l,i=n.map(e=>t(t_,{component:"p",children:e},e));return t(tV,{title:e,description:i,imgAlt:a,imgSrc:r,actions:o})}return s},tY=({sideOffset:e=4,alignOffset:a,ref:r,...l})=>t(ee,{ref:r,sideOffset:e,...l}),tK=({text:e,content:r,children:l,side:s="top",sideOffset:o=10,alignOffset:i,delayDuration:d=0,className:c,ref:u,..._})=>t(ea,{delayDuration:d,children:a(er,{..._,children:[t(el,{ref:u,asChild:!0,children:l}),r||e?t(et,{children:a(tY,{className:n("style__izacrl2",c),alignOffset:i,sideOffset:o,hideWhenDetached:!0,side:s,children:[r??t("p",{className:"style__izacrl3",children:e}),_.arrow&&t(Z,{className:"style__izacrl4"})]})}):null]})}),tU=e=>{let{children:r,copyPosition:l="right",copyText:n,isShowCopyText:o,color:i,className:d,...c}=e,u=()=>t(v,{className:"style__1wpx85c1"}),{tooltipOpen:_,handleMouseEnter:m,handleMouseLeave:h,handleClick:p,tooltipTitle:g,isIconOnLeft:y}=(({children:e,copyText:t,isShowCopyText:a,copyPosition:r})=>{let[l,n]=U("Скопировать"),[s,o]=U(!1);return{handleMouseLeave:()=>{"Скопировать"!==l&&setTimeout(()=>{n("Скопировать")},100),o(!1)},handleClick:a=>{a.stopPropagation(),navigator.clipboard.writeText(t||("string"==typeof e?e:"")).then(()=>n("Скопировано")).catch(()=>n("Ошибка копирования"))},tooltipTitle:a?`${l}: ${t}`:l,isIconOnLeft:"left"===r,tooltipOpen:s,handleMouseEnter:()=>{o(!0)}}})(e);return t(tK,{open:_,arrow:!0,text:g,side:"bottom",children:a(t_,{onMouseLeave:h,onMouseEnter:m,onClick:p,component:"div",color:i,className:s("style__1wpx85c0",d),...c,children:[y&&u(),r,!y&&u()]})})},tX=B({pinned:!0,hovered:!1,togglePinned:()=>{}}),tJ=()=>H(tX),tQ="dashboard::pinned",tZ=({children:e,className:a})=>{let{pinned:r,togglePinned:l}=(()=>{let[e,t]=U("true"===window.localStorage.getItem(tQ));return{pinned:e,togglePinned:()=>{t(!e),window.localStorage.setItem(tQ,String(!e))}}})();return t(tX.Provider,{value:{pinned:r,togglePinned:l},children:t("div",{className:s("DashboardLayout__113u7x50",a),children:e})})};function t1({row:e,column:a,rowIndex:r,height:l}){let{align:n,cellColor:o,isDisabled:i}=a;return t("td",{align:n??"left",style:{backgroundColor:o?.(e),height:l,width:a.width},className:s("style__1047swj0",{style__1047swj1:i},a.cellClassName?.(e)),children:t(()=>a.renderCell?a.renderCell(e,r):a.format?a.format(e)||"—":a.field?`${e[a.field]||"—"}`:"—",{})})}function t0({row:e,rowHeight:a,onRowClick:r,columns:l,rowIndex:n,rowId:o}){let i=$(()=>{r?.(e)},[r,e]);return t("tr",{onClick:i,onKeyDown:i,className:s("style__gsm9mv0",{style__gsm9mv1:!!r}),children:l.map((r,l)=>t(t1,{row:e,rowIndex:n,column:r,height:a},`${o}-${l}`))})}function t2({isLoading:e,isEmpty:a,columnsLength:r,emptyState:l={text:"Нет данных"},errorState:n={text:"Произошла ошибка"},isError:s,onRetry:o}){let i=({children:e})=>t("tr",{className:"style__15m2ib80",children:t("td",{colSpan:r,align:"center",children:e})});if(e)return t(i,{children:t("span",{className:"style__15m2ib81",children:t(tL,{})})});if(a){let{imgSrc:e,imgAlt:a,text:r}=l;return t(i,{children:t(tV,{title:r,imgSrc:e,imgAlt:a})})}if(s){let{imgSrc:e,imgAlt:a,text:r}=n;return t(i,{children:t(tV,{title:r,imgSrc:e,imgAlt:a,actions:o?t(e6,{variant:"outline",onClick:o,children:"Попробовать снова"}):void 0})})}return null}tZ.Sidebar=({width:e="16rem",header:r,footer:l,content:n,className:o})=>{let{pinned:i}=tJ();return a("div",{style:{width:i?e:0},className:"style__1low90p0",children:[t("span",{className:"SidebarTrigger__1low90p1"}),a("aside",{style:{width:e},className:s("SidebarContainer__1low90p2",{style__1low90p3:!i},o),children:[r&&t("header",{className:"SidebarHeader__1low90p4",children:r}),t("div",{className:"SidebarContent__1low90p6",children:n}),l&&t("footer",{className:"SidebarFooter__1low90p5",children:l})]})]})},tZ.Main=({children:e,className:a})=>t("main",{className:s("style__whkxou0",a),children:e});var t6="style__82af400";function t5({isError:e,isLoading:a,emptyState:r,errorState:l,columns:n,rows:s,rowHeight:o,keyId:i,onRowClick:d}){let c=0===s.length;return e||a||c?t("tbody",{className:t6,children:t(t2,{emptyState:r,errorState:l,isEmpty:c,isError:e,isLoading:a,columnsLength:n.length})}):t("tbody",{className:t6,children:s.map((e,a)=>{let r=String(e[i]);return t(t0,{row:e,rowId:r,rowHeight:o,columns:n,onRowClick:d,rowIndex:a},e[i])})})}function t9({children:e,className:a}){return t("footer",{className:s("style__2s55b60",a),children:e})}function t4({column:e,height:a,width:r}){return t("th",{style:{color:e.color,height:a,width:r},align:e.align??"left",title:e.title,className:"style__uma6hu0",children:e.renderHeaderCell?.(e)||e.title})}function t8({columns:e,height:a,sticky:r}){return t("thead",{children:t("tr",{className:s({style__fkgoub0:r}),children:e.map(e=>t(t4,{column:e,height:a,width:e.width},e.title))})})}function t3({rows:e,columns:r,height:l="100%",className:n,rowHeight:o=40,headerHeight:i=40,keyId:d,onRowClick:c,isLoading:u,isDisabled:_,isError:m,emptyState:h,errorState:p,footer:g,title:y,stickyHeader:b,onRetry:f}){let v=u||m||0===e.length;return a("div",{"data-slot":"data-grid",style:{height:l},className:s("style__1gqvluf0",n),children:[a("table",{className:s("style__1gqvluf1",{style__1gqvluf3:_,style__1gqvluf4:u,style__1gqvluf2:v},n),children:[y&&t("caption",{className:"style__1gqvluf5",children:y}),t(t8,{columns:r,height:i,sticky:b}),t(t5,{rows:e,columns:r,rowHeight:o,keyId:d,onRowClick:c,isLoading:u,emptyState:h,errorState:p,isError:m,onRetry:f})]}),g&&t(t9,{children:g})]})}var t7="style__1ib8wkth",ae="style__1ib8wktf";function at({...e}){return t(en.Root,{"data-slot":"dropdown-menu",...e})}function aa({align:e="start",alignOffset:a=0,side:r="bottom",sideOffset:l=4,className:n,...o}){return t(en.Portal,{children:t(en.Positioner,{align:e,alignOffset:a,side:r,sideOffset:l,className:"style__1ib8wkt6",children:t(en.Popup,{"data-slot":"dropdown-menu-content",className:s("style__1ib8wkt7",n),...o})})})}at.Portal=function({...e}){return t(en.Portal,{"data-slot":"dropdown-menu-portal",...e})},at.Trigger=function({...e}){return t(en.Trigger,{"data-slot":"dropdown-menu-trigger",...e})},at.Content=aa,at.Group=function({...e}){return t(en.Group,{"data-slot":"dropdown-menu-group",...e})},at.Label=function({className:e,inset:a,...r}){return t(en.GroupLabel,{"data-slot":"dropdown-menu-label","data-inset":a?"":void 0,className:s("style__1ib8wkt9",e),...r})},at.Item=function({className:e,inset:a,variant:r="default",...l}){return t(en.Item,{"data-slot":"dropdown-menu-item","data-inset":a?"":void 0,"data-variant":r,className:s("style__1ib8wkta",e),...l})},at.Sub=function({...e}){return t(en.SubmenuRoot,{"data-slot":"dropdown-menu-sub",...e})},at.SubTrigger=function({className:e,inset:r,children:l,...n}){return a(en.SubmenuTrigger,{"data-slot":"dropdown-menu-sub-trigger","data-inset":r?"":void 0,className:s("style__1ib8wktc style__1ib8wkta",e),...n,children:[l,t(g,{className:"style__1ib8wktg"})]})},at.SubContent=function({align:e="start",alignOffset:a=-3,side:r="right",sideOffset:l=0,className:n,...o}){return t(aa,{"data-slot":"dropdown-menu-sub-content",className:s("style__1ib8wkt8",n),align:e,alignOffset:a,side:r,sideOffset:l,...o})},at.Shortcut=function({className:e,...a}){return t("span",{"data-slot":"dropdown-menu-shortcut",className:s("style__1ib8wktj",e),...a})},at.Separator=function({className:e,...a}){return t(en.Separator,{"data-slot":"dropdown-menu-separator",className:s("style__1ib8wkti",e),...a})},at.RadioGroup=function({...e}){return t(en.RadioGroup,{"data-slot":"dropdown-menu-radio-group",...e})},at.RadioItem=function({className:e,children:r,inset:l,...n}){return a(en.RadioItem,{"data-slot":"dropdown-menu-radio-item","data-inset":l?"":void 0,className:s("style__1ib8wkte style__1ib8wkta",e),...n,children:[t("span",{className:ae,"data-slot":"dropdown-menu-radio-item-indicator",children:t(en.RadioItemIndicator,{children:t(_,{className:t7})})}),r]})},at.CheckboxItem=function({className:e,children:r,checked:l,inset:n,...o}){return a(en.CheckboxItem,{"data-slot":"dropdown-menu-checkbox-item","data-inset":n?"":void 0,className:s("style__1ib8wktd style__1ib8wkta",e),checked:l,...o,children:[t("span",{className:ae,"data-slot":"dropdown-menu-checkbox-item-indicator",children:t(en.CheckboxItemIndicator,{children:t(_,{className:t7})})}),r]})};let ar=a=>{let{tooltipProps:r}=(({action:e})=>{let{isLoading:t,disabledReason:a,name:r}=e,[l,n]=U(!1);return G(()=>{t&&n(!1)},[t]),{tooltipProps:{text:a||r,open:l,onOpenChange:e=>n(e)}}})(a),{action:l,onActionClick:n,isDisabled:s,tooltipPlacement:o}=a,{name:i,icon:d,needConfirm:c,confirmText:u,confirmButtonProps:_,disabled:m,isLoading:h,onClick:p}=l,g=e=>t(tK,{arrow:!0,side:o,...r,children:t(e6,{disabled:s||m,isLoading:h,variant:"ghost",size:"icon",...e,children:d})},i);return t(e,{children:c?t(tF,{text:u,confirmButtonProps:_,actionComponent:e=>g(e),onConfirm:n(p)}):g({onClick:n(p)})})},al=({action:e,onActionClick:r,isDisabled:l,tooltipPlacement:n})=>{if("actions"in e){let{disabled:s,icon:o,name:i,disabledReason:d,actions:c,isLoading:u}=e;return a(at,{children:[t(tK,{text:d||i,side:n,arrow:!0,children:t(at.Trigger,{render:t(e6,{variant:"ghost",size:"icon",isLoading:u,disabled:l||s,children:o})})},i),t(at.Content,{children:c.map(({name:e,onClick:a,...l})=>E(at.Item,{...l,key:e,render:t(e6,{size:"sm",onClick:r(a),children:e})}))})]})}return t(ar,{action:e,onActionClick:r,isDisabled:l,tooltipPlacement:n})},an=({actions:e,onActionClick:r,tooltipPlacement:l,isDisabled:n})=>a(at,{children:[t(at.Trigger,{render:t(e6,{disabled:n,variant:"ghost",size:"icon",children:t(w,{})})}),t(at.Content,{children:e.map(e=>{let{onClick:a,name:n,disabledReason:s,isLoading:o}=e;return t(tK,{arrow:!0,side:l,text:s,children:t(at.Item,{render:t(e6,{onClick:r(a),isLoading:o,variant:"ghost",size:"sm",fullWidth:!0,children:n})})},n)})})]}),as=e=>{let{isDisabledAction:r,handleWrapperClick:l,handleActionClick:n}=(({row:e,actions:t})=>{let{main:a,secondary:r}=t,l=[...a,...r||[]].find(e=>e.isBlockingOperation&&e.isLoading);return{isDisabledAction:!!l,handleActionClick:$(t=>()=>{t?.(e)},[e]),handleWrapperClick:e=>{e.stopPropagation()}}})(e),{actions:s}=e,{main:o,secondary:i}=s;return a("div",{onClick:l,onKeyDown:l,className:"style__y44ln70",children:[o.map(e=>t(al,{action:e,onActionClick:n,isDisabled:r,tooltipPlacement:"top"},e.name)),i&&t(an,{actions:i,onActionClick:n,tooltipPlacement:"left",isDisabled:r})]})};var ao={left:"left__o752f01",center:"center__o752f02",right:"right__o752f03",justify:"justify__o752f04"};function ai({sorting:e,setSorting:r,column:{title:l,field:n,align:c="left"},className:u}){return n?a("button",{type:"button",className:s("style__o752f00",ao[c],u),onClick:()=>{e.key===n?r({key:n,order:"asc"===e.order?"desc":"asc"}):r({key:n,order:"asc"})},children:[l,e.key===n?"asc"===e.order?t(o,{size:16}):t(d,{size:16}):t(i,{size:16})]}):null}let ad="Вы достигли конца списка",ac=({endOfScrollMsg:e=ad})=>t("li",{className:"style__1syvw5e0",children:t(t_,{children:e})}),au=({onRetry:e})=>a("li",{className:"style__qlujai0",children:[t(t_,{align:"center",children:"Ошибка загрузки"}),t(e6,{size:"sm",onClick:e,children:"Попробовать снова"})]}),a_=()=>t("li",{className:"style__111czea0",children:t(tL,{color:"primary"})}),am=({noDataImgSrc:e})=>t(tV,{title:"Нет данных",imgSrc:e}),ah=({onClick:e,isVisible:a})=>t(e6,{onClick:e,size:"icon",variant:"outline",className:s("style__1jg5nd90",{style__1jg5nd91:a}),children:t(y,{})}),ap=({data:r,keyId:l,className:n,itemContent:o,noDataPlaceholder:i,endOfScrollMsg:d,errorState:c,isLoading:u,isError:_,isEndReached:m,onRetry:h,onEndReached:p,ref:g})=>{let y=K(null),b=g||y,[f,v]=U(!1),N=$(e=>{e.startIndex>2?v(!0):v(!1)},[]),w=$(()=>b.current?.scrollToIndex({index:0,align:"start",behavior:"smooth"}),[b]),k=$(()=>{!m&&p&&p()},[m,p]),x=!!r?.length;return x||u||_?a(tW,{isLoading:u&&!x,isError:_&&!x,errorState:c,children:[t(es,{className:s("style__1ezen7g0",n),style:{height:"100%"},data:r,ref:b,overscan:30,endReached:k,rangeChanged:N,itemContent:(e,a)=>t("li",{children:o?.(a,{index:e,className:s("style__1ezen7g1","datalist_item")})},a[l]),components:{Footer:()=>a(e,{children:[u&&t(a_,{}),_&&t(au,{onRetry:h}),m&&t(ac,{endOfScrollMsg:d})]})}}),t(ah,{isVisible:f,onClick:w})]}):i?t(e,{children:i}):t(am,{})};var ag="style__1blk89uc",ay="style__1blk89u6",ab={sm:"sm__1blk89u9",md:"md__1blk89ua",lg:"lg__1blk89ub"},af={outlined:"outlined__1blk89u1",standard:"standard__1blk89u2"};let av=({error:e,variant:r="outlined",size:l="md",startAdornment:n,endAdornment:o,className:i,disabled:d,fullWidth:c,value:u,ref:_,...m})=>a("div",{className:s("Input__1blk89u0",af[r],{style__1blk89u7:e},{[ay]:d},{style__1blk89u3:c},i),children:[n&&t("span",{className:ag,children:n}),t("input",{className:s("style__1blk89u8",ab[l],{[ay]:d,style__1blk89ud:!!n,style__1blk89ue:!!o}),ref:_,disabled:d,value:u||"",...m}),o&&t("span",{className:ag,children:o})]}),aN=({className:e,disabled:a,...r})=>t(ei,{className:s("Label__c31e140",{style__c31e141:a,style__c31e142:r.error,style__c31e143:r.required},e),...r}),aw=({label:e,helperText:r,className:l,disabled:n,fullWidth:o,ref:i,labelClassName:d,...c})=>a("div",{className:s("style__kqu4y20",{style__kqu4y25:o},l),children:[e&&t(aN,{htmlFor:c.id||e,disabled:n,required:c.required,error:c.error,className:s("style__kqu4y21",d),children:e}),t(av,{ref:i,disabled:n,fullWidth:o,id:c.id||e,...c}),r&&t(t_,{variant:"caption",className:s("style__kqu4y22",{style__kqu4y24:c.error,style__kqu4y23:n}),children:r})]}),ak=({maskProps:e,ref:a,...r})=>{let l=eo(e);return t(aw,{ref:$(e=>{l.current=e,"function"==typeof a?a(e):a&&(a.current=e)},[l,a]),...r})},ax=e=>{let{label:r,disabled:l=!1,selected:n,onSelect:s,selectMonth:o,selectYear:i,error:d,helperText:u,className:_,fullWidth:m,size:h,name:p,...g}=e,[y,b]=U(null),[f,v]=U(!1),[N,w]=U(new Date),[k,x]=U("");return G(()=>{n?(x(n.toLocaleString("ru-RU",{day:"2-digit",month:"2-digit",year:"numeric"})),w(n)):x("")},[n]),a(tj,{open:f,onOpenChange:v,children:[t(ak,{value:k,onChange:e=>{b(null),x(e.target.value);let[t,a,r]=e.target.value.split(".").map(Number);if(Number.isNaN(t)||Number.isNaN(a)||Number.isNaN(r)||t<1||t>31||a<1||a>12||r<1e3)return void b("Некорректная дата");let l=new Date(r,a-1,t);s?.(l),w(l)},label:r,disabled:l,className:_,fullWidth:m,size:h,name:p,endAdornment:t(tj.Trigger,{render:t(e6,{variant:"ghost",size:"icon",onClick:()=>{v(!0)},children:t(c,{})})}),maskProps:{mask:"__.__.____",replacement:{_:/\d/},showMask:!0},placeholder:"дд.мм.гггг",error:!!y||d,helperText:y||u}),t(tj.Content,{align:"end",alignOffset:-10,side:"bottom",children:t(tg,{month:N,onMonthChange:w,selected:n,onSelect:e=>{e?(s?.(e),w(e),x(e.toLocaleString("ru-RU",{day:"2-digit",month:"2-digit",year:"numeric"}))):(x(""),s?.(void 0)),v(!1)},...g,mode:"single",captionLayout:o&&i?"dropdown":o?"dropdown-months":i?"dropdown-years":"label"})})]})},aC="descriptionRoot",az=B({leader:!1,separator:":",direction:"default"}),aS=({children:e,leader:a,separator:r,direction:l})=>t(az.Provider,{value:{leader:a,separator:r,direction:l},children:e});var aT={row:"row__1lociyw1",column:"column__1lociyw2"},aP={spaceBetween:"spaceBetween__1lociyw3",start:"start__1lociyw4"},aD="style__sdcsnp2";let aI=e=>{let{descriptionContextProviderProps:a,direction:r}=(({direction:e="row",separator:t=":"})=>({descriptionContextProviderProps:{separator:"column"===e?"":t},direction:e}))(e),{justifyContent:l="start",component:n="dl",children:o,leader:i=!1,className:d}=e;return t(aS,{leader:i,direction:r,...a,children:t(n,{className:s("style__1lociyw0",aT[r],aP[l],aC,d),children:o})})};function aA({...e}){return t(ed.Root,{"data-slot":"dialog",...e})}function aL({...e}){return t(ed.Portal,{"data-slot":"dialog-portal",...e})}function aR({className:e,...a}){return t(ed.Backdrop,{"data-slot":"dialog-overlay",className:s("style__8bkmbe4",e),...a})}aI.Name=({children:r,color:l="secondary",...n})=>{let{leader:o,separator:i}=H(az);return a(e,{children:[t("dt",{className:s("style__1tsgk1i0",{style__1tsgk1i1:o}),children:a(t_,{...n,color:l,children:[r,!o&&i]})}),o&&t("div",{className:"style__1tsgk1i2"})]})},aI.Value=e=>{let{valueToRender:a,isDefaultValueRender:r,leader:l}=(({canCopy:e,children:t,stub:a="—"})=>{let{leader:r,direction:l}=H(az);return{valueToRender:t||a,isDefaultValueRender:!e||!t,leader:r,direction:l}})(e),{copyPosition:s="right",copyText:o,canCopy:i,children:d,stub:c,...u}=e;return r?t(t_,{className:n("style__sdcsnp1",{[aD]:l}),component:"dd",...u,children:a}):t("dd",{className:"style__sdcsnp0",children:t(tU,{className:n({[aD]:l}),copyPosition:s,copyText:o,...u,children:a})})},aA.Trigger=function({...e}){return t(ed.Trigger,{"data-slot":"dialog-trigger",...e})},aA.Portal=aL,aA.Close=function({...e}){return t(ed.Close,{"data-slot":"dialog-close",...e})},aA.Overlay=aR,aA.Content=function({className:e,children:r,showCloseButton:l=!0,...n}){return a(aL,{children:[t(aR,{}),a(ed.Popup,{"data-slot":"dialog-content",className:s("style__8bkmbe5",e),...n,children:[r,l&&a(ed.Close,{"data-slot":"dialog-close",render:t(e6,{variant:"ghost",size:"iconSm",className:"style__8bkmbe6"}),children:[t(D,{}),t("span",{className:"style__8bkmbe7",children:"Close"})]})]})]})},aA.Header=function({className:e,...a}){return t("div",{"data-slot":"dialog-header",className:s("style__8bkmbe8",e),...a})},aA.Footer=function({className:e,showCloseButton:r=!1,children:l,...n}){return a("div",{"data-slot":"dialog-footer",className:s("style__8bkmbe9",e),...n,children:[l,r&&t(ed.Close,{render:t(e6,{variant:"outline"}),children:"Close"})]})},aA.Title=function({className:e,...a}){return t(ed.Title,{"data-slot":"dialog-title",className:s("style__8bkmbea",e),...a})},aA.Description=function({className:e,...a}){return t(ed.Description,{"data-slot":"dialog-description",className:s("style__8bkmbeb",e),...a})};let aM=({children:e,trigger:r,className:l,title:n,description:o="",footer:i,closeButton:d,...c})=>a(eu,{...c,children:[r&&t(ec.Trigger,{"data-slot":"drawer-trigger",asChild:!0,children:r}),a(ec.Portal,{"data-slot":"drawer-portal",children:[t(ec.Overlay,{"data-slot":"drawer-overlay",className:"style__ccss502"}),a(ec.Content,{"data-slot":"drawer-content",className:s("group/drawer-content","style__ccss503",l),children:[t("div",{className:"style__ccss504"}),a("div",{"data-slot":"drawer-header",className:"style__ccss505",children:[t(ec.Title,{"data-slot":"drawer-title",className:"style__ccss507",children:n}),t(ec.Description,{"data-slot":"drawer-description",className:"style__ccss508",children:o})]}),e,a("div",{"data-slot":"drawer-footer",className:"style__ccss506",children:[i,d&&t(ec.Close,{"data-slot":"drawer-close",asChild:!0,children:d})]})]})]})]});var aj={default:"default__e4li7y3",icon:"icon__e4li7y4"};function aF({className:e,...a}){return t("div",{"data-slot":"empty",className:s("style__e4li7y0",e),...a})}aF.Header=function({className:e,...a}){return t("div",{"data-slot":"empty-header",className:s("style__e4li7y1",e),...a})},aF.Media=function({className:e,variant:a="default",...r}){return t("div",{"data-slot":"empty-media","data-variant":a,className:s("style__e4li7y2",aj[a],e),...r})},aF.Title=function({className:e,...a}){return t("div",{"data-slot":"empty-title",className:s("style__e4li7y5",e),...a})},aF.Description=function({className:e,...a}){return t("div",{"data-slot":"empty-description",className:s("style__e4li7y6",e),...a})},aF.Content=function({className:e,...a}){return t("div",{"data-slot":"empty-content",className:s("style__e4li7y7",e),...a})};var aO="style__a5l83v4",aq="style__a5l83v0";let aB=({images:r=[],autoPlay:l=!1,interval:n=5e3})=>{let[o,i]=U(0);return(G(()=>{if(!l)return;let e=setInterval(()=>{i(e=>e===r.length-1?0:e+1)},n);return()=>clearInterval(e)},[l,r.length,n]),0===r.length)?t("div",{className:aq,children:"Нет изображений для отображения"}):a("div",{className:aq,children:[t("div",{className:"style__a5l83v1",style:{transform:`translateX(-${100*o}%)`},children:r.map((e,a)=>t("div",{className:"style__a5l83v2",children:t("img",{src:e.src,alt:e.alt||`Slide ${a+1}`,className:"style__a5l83v3"})},e.src))}),r.length>1&&a(e,{children:[t("button",{type:"button",className:s(aO,"style__a5l83v5"),onClick:()=>{i(e=>0===e?r.length-1:e-1)},children:t(h,{size:24})}),t("button",{type:"button",className:s(aO,"style__a5l83v6"),onClick:()=>{i(e=>e===r.length-1?0:e+1)},children:t(p,{size:24})}),t("div",{className:"style__a5l83v7",children:r.map(({src:e},a)=>t("button",{type:"button",className:`style__a5l83v8 ${o===a?"active":""}`,onClick:()=>{i(a)}},e))})]})]})},aE=({separator:e="•",...a})=>t("div",{...a,children:t("span",{className:"style__te1pgr0",children:e})}),a$=({char:e,hasFakeCaret:r,isActive:l,...n})=>a("div",{className:s("style__rtks2g0",{style__rtks2g1:l}),...n,children:[e,r&&t("div",{className:"style__rtks2g2",children:t("div",{className:"style__rtks2g4"})})]});var aH="style__1iixe0l2";let aG=({className:r,containerClassName:l,disabled:n,...o})=>t(e_,{containerClassName:s("style__1iixe0l0",{style__1iixe0l3:n},l),className:s("style__1iixe0l1",r),render:({slots:r})=>r.length%2!=0?t("div",{className:aH,children:r.map((e,a)=>t(a$,{...e},`${a.toString()}-${e.char}`))}):a(e,{children:[t("div",{className:aH,children:r.slice(0,r.length/2).map((e,a)=>t(a$,{...e},`${a.toString()}-${e.char}`))}),t(aE,{}),t("div",{className:aH,children:r.slice(r.length/2).map((e,a)=>t(a$,{...e},`${a.toString()}-${e.char}`))})]}),...o});var aV=((eW={}).info="info",eW.success="success",eW.warning="warning",eW.error="error",eW);let aW={topRight:"top-right",topLeft:"top-left",bottomRight:"bottom-right",bottomLeft:"bottom-left",topCenter:"top-center",bottomCenter:"bottom-center"};class aY{service;constructor(e){this.service=e}message(e,t){return this.service.message(e,{description:t})}success=e=>this.service.success(e);error=e=>this.service.error(e);info=e=>this.service.info(e);warning=e=>this.service.warning(e);loading=e=>this.service.loading(e);dismiss=e=>this.service.dismiss(e);custom=e=>this.service(e);action=({title:e,buttonLabel:t,onClick:a})=>this.service(e,{action:{label:t,onClick:a}})}let aK=new aY(eh),aU=({position:e="bottomRight",...a})=>t(em,{duration:3e3,icons:{error:t(C,{size:20,color:ty.colors.error}),success:t(b,{size:20,color:ty.colors.success}),warning:t(P,{size:20,color:ty.colors.warning}),info:t(k,{size:20,color:ty.colors.info})},position:aW[e],...a});var aX="style__t5ji060",aJ={left:"left__t5ji063",center:"center__t5ji064",right:"right__t5ji065",justify:"justify__t5ji066"};let aQ=(e,t=!1)=>{let a=K(null),r=K(void 0),[l,n]=U(!1),s=$(([{target:e,contentRect:a}])=>{let r=e.scrollHeight>Math.round(a.height),l=e.scrollWidth>Math.round(a.width),s=t?l||r:l;n(e=>e===s?e:s)},[t]),o=$(t=>{a.current=t,((e,t)=>{if(e){if("function"==typeof e)return e(t);e.current=t}})(e,t)},[e]),i=$(e=>{let t=a.current;t&&s([{target:t,contentRect:t.getBoundingClientRect()}])},[s]);return W(()=>{let e=a.current;if(!e)return;i();let t=new ResizeObserver(e=>{clearTimeout(r.current),r.current=setTimeout(()=>{s(e)},500)});return t.observe(e),()=>{clearTimeout(r.current),t.unobserve(e),t.disconnect()}},[i,s]),{check:i,isOverflowed:l,ref:o}},aZ=e=>{let{label:r,hasVisibleLastSymbols:l,hasMultipleRows:n,overflowRef:o,tooltipContent:i,restTooltipProps:d,style:c,visibleLastSymbolsCount:u}=(({text:e,children:t,tooltipProps:a,visibleLastSymbolsCount:r=0,rowsCount:l=1,ref:n,style:s})=>{let o={...s,"--rows-count":l},i=e??("string"==typeof t?t:void 0),d=!!(i&&r>0),c=!d&&l>1,u=[i,l,r,d].join("|"),{check:_,isOverflowed:m,ref:h}=aQ(n,c),{content:p,text:g,...y}=a||{},b=m?p??g??i:void 0;return W(()=>{_(u)},[_,u]),{label:i,hasVisibleLastSymbols:d,hasMultipleRows:c,overflowRef:h,tooltipContent:b,restTooltipProps:y,style:o,visibleLastSymbolsCount:r}})(e),{align:_="left",className:m,text:h,children:p}=e;if(l&&r){let{firstPartLabel:l,secondPartLabel:n}={firstPartLabel:r.slice(0,-u),secondPartLabel:r.slice(-u)};return t(tK,{...d,arrow:!0,content:i,children:a("div",{className:s("style__t5ji062",aJ[_]),"data-slot":"overflow-typography",children:[t(t_,{...e,align:_,className:s(aX,m),component:"span","data-slot":"overflow-typography-start",display:"block",ref:o,style:c,children:l}),t(t_,{...e,align:_,className:m,component:"span","data-slot":"overflow-typography-end",style:c,children:n})]})})}return t(tK,{...d,arrow:!0,content:i,children:t(t_,{...e,align:_,className:s(aX,n&&"style__t5ji061",m),"data-slot":"overflow-typography",display:"block",ref:o,style:c,children:h??p})})},a1=({children:e,className:a})=>t("div",{className:s("style__adrl250",a),children:e});a1.Header=e=>{let{title:r,subtitle:l,breadcrumbs:n,actions:o,backButton:i,className:d}=e,{pinned:c,togglePinned:u}=tJ();return G(()=>{"string"==typeof r&&(document.title=r)},[r]),a("header",{className:s("page_header","style__nvcxbd1",d),children:[a("div",{className:"style__nvcxbd2",children:[t(tK,{text:c?"Развернуть":"Свернуть",children:t(e6,{variant:"ghost",size:"icon",onClick:u,children:c?t(T,{}):t(z,{})})}),i&&t(tK,{text:"Назад",children:t(e6,{...i,variant:"ghost",children:t(h,{})})})]}),n&&t("div",{className:"Breadcrumbs__nvcxbd0",children:n}),t("div",{className:"style__nvcxbd3",children:o}),"string"==typeof r?t(t_,{className:"style__nvcxbd4",component:"h1",variant:"h3","aria-level":1,children:r}):t("div",{className:"style__nvcxbd5",children:r}),l&&"string"==typeof l&&t(t_,{className:"style__nvcxbd6","aria-level":2,children:l}),l&&"string"!=typeof l&&t("div",{className:"style__nvcxbd7",children:l})]})},a1.Content=e=>{let{className:a,children:r,isFullHeight:l=!0}=e;return t("article",{className:s("page-content","style__1hr0uh00",{style__1hr0uh01:l},a),children:r})},a1.Footer=e=>{let{children:a,className:r}=e;return t("footer",{className:s("style__1bd8jnw0",r),children:a})},a1.Aside=({children:e,className:a})=>t("aside",{className:s("PageLayoutAside__1un4hm80",a,"page_aside"),children:e});let a0=(e,t)=>Array.from({length:t-e+1},(t,a)=>a+e);function a2(e){let{onPageChange:r,totalCount:l,siblingCount:n=1,currentPage:s,pageSize:o,size:i="icon"}=e,d=(({totalCount:e,pageSize:t,siblingCount:a=1,currentPage:r})=>Y(()=>{if(t<=0||e<=0)return[];let l=Math.ceil(e/t);if(a+5>=l)return a0(1,l);let n=Math.max(r-a,1),s=Math.min(r+a,l),o=n>2,i=s<l-2;return!o&&i?[...a0(1,3+2*a),null,l]:o&&!i?[1,null,...a0(l-(3+2*a)+1,l)]:o&&i?[1,null,...a0(n,s),null,l]:[]},[e,t,a,r]))({currentPage:s,totalCount:l,siblingCount:n,pageSize:o});if(0===s||d&&d.length<2)return null;let c=d.at(-1);return a("nav",{className:"style__p708oq0",children:[t(e6,{variant:"ghost",size:i,onClick:()=>{r(s-1)},disabled:1===s,children:t(h,{})}),d?.map((e,a)=>e?t(e6,{size:i,variant:e===s?"default":"outline",onClick:()=>r(+e),children:e},`${e}${a.toString()}`):t("span",{className:"style__p708oq1",children:t(N,{})})),t(e6,{variant:"ghost",size:i,onClick:()=>{r(s+1)},disabled:s===c,children:t(p,{})})]})}let a6=["Янв.","Фев.","Мар.","Апр.","Май","Июн.","Июл.","Авг.","Сен.","Окт.","Ноя.","Дек."],a5=["I квартал","II квартал","III квартал","IV квартал"],a9=e=>Math.ceil(e/3);function a4({year:e,onSelect:r,minDate:l,maxDate:n}){let s=Array.from({length:n.getFullYear()-l.getFullYear()+1},(e,t)=>l.getFullYear()+t);return a(rd,{onValueChange:e=>{r?.(Number(e))},value:e.toString(),children:[t(r_,{children:t(ru,{placeholder:e.toString()})}),t(rp,{children:s.map(e=>t(ry,{value:e.toString(),children:t(t_,{align:"center",variant:"subtitle1",transform:"capitalize",children:e})},e))})]})}let a8=e=>{let{label:r,disabled:l=!1,value:n,onSelect:s,type:o="month",placeholder:i="month"===o?"Выберите месяц":"Выберите квартал",error:d,helperText:u,max:_=new Date(2050,0,1),min:m=new Date(2e3,0,1),className:h,size:p,fullWidth:g,name:y}=e,b=new Date,[f,v]=U(!1),[N,w]=U(b.getFullYear()),k=e=>{s?.(e),v(!1)},x="month"===o?n?.toLocaleDateString("ru-RU",{month:"long",year:"numeric"}):n?`${a5[a9(n.getMonth())]} ${n.getFullYear()}`:"";return G(()=>{n&&w(n.getFullYear())},[n]),a(tj,{open:f,onOpenChange:v,children:[t(aw,{label:r,value:x,disabled:l,size:p,fullWidth:g,name:y,endAdornment:t(tj.Trigger,{render:t(e6,{disabled:l,variant:"ghost",size:"icon",children:t(c,{})})}),placeholder:i,error:d,helperText:u,className:h}),t(tj.Content,{align:"end",alignOffset:-10,side:"bottom",children:a("div",{className:"style__1izfmw30",children:[t(a4,{year:N,onSelect:w,minDate:m,maxDate:_}),"month"===o?t("div",{className:"style__1izfmw31",children:a6.map((e,a)=>{let r=new Date(N,a,n?.getDate()||1);return t(e6,{variant:n?.getMonth()===a&&n.getFullYear()===r.getFullYear()?"default":"ghost",disabled:r<m||r>_,onClick:()=>k(r),children:e},e)})}):t("div",{className:"style__1izfmw32",children:a5.map((e,a)=>{let r=new Date(N,3*a,1);return t(e6,{variant:n&&[a9(n.getMonth())===a,n.getFullYear()===r.getFullYear()].every(Boolean)?"default":"ghost",disabled:r<m||r>_,onClick:()=>k(r),children:e},e)})})]})})]})},a3=({className:e,...a})=>t(ey,{"data-slot":"radio-group",className:n("RadioGroup__ia95d10",e),...a}),a7=({className:e,label:r,...l})=>a("div",{className:"style__ia95d11",children:[t(eg,{"data-slot":"radio-group-item",id:l.id||l.value,className:s("style__ia95d12",e),...l,children:t(ep,{"data-slot":"radio-group-indicator",className:"style__ia95d13",children:t(f,{className:"style__ia95d14"})})}),t(aN,{htmlFor:l.id||l.value,"data-slot":"radio-group-label",children:r})]});function re({className:e,defaultValue:r,value:l,min:n=0,max:o=100,onValueCommit:i,onValueCommitted:d,...c}){let u=eV.useMemo(()=>Array.isArray(l)?l:Array.isArray(r)?r:[n,o],[l,r,n,o]),_=eV.useMemo(()=>Array.from({length:u.length},(e,t)=>({key:`slider-thumb-${t}`,index:t})),[u.length]);return t(eb.Root,{"data-slot":"slider",className:s("style__h9oy580",e),defaultValue:r,value:l,min:n,max:o,thumbAlignment:"edge",onValueCommitted:(e,t)=>{d?.(e,t),i?.(e)},...c,children:a(eb.Control,{className:"style__h9oy581",children:[t(eb.Track,{"data-slot":"slider-track",className:"style__h9oy582",children:t(eb.Indicator,{"data-slot":"slider-range",className:"style__h9oy583"})}),_.map(e=>t(eb.Thumb,{"data-slot":"slider-thumb",index:e.index,className:"style__h9oy584"},e.key))]})})}var rt="style__1pnwkko6",ra={sm:"sm__1pnwkko2",md:"md__1pnwkko3",lg:"lg__1pnwkko4"},rr="style__1pnwkko5";function rl({min:e,max:r,onChange:l,minValue:n,maxValue:o,width:i=150,unit:d="",size:c="md",className:u,isActive:_,minInputRef:m,maxInputRef:h}){let{onMinValueChange:p,onMaxValueChange:g,minVal:y,maxVal:b,onKeyDown:f,onValueChange:v,onConfirm:N,minId:w,maxId:k}=(({min:e,max:t,maxValue:a,minValue:r,onChange:l})=>{let n=V(),s=V(),[o,i]=U(e),[d,c]=U(t);return G(()=>{i(r||e),c(a||t)},[r,a,e,t]),{maxId:s,minId:n,minVal:o,maxVal:d,onValueChange:e=>{e[0]===e[1]?l(e[0],e[1]):(i(e[0]),c(e[1]))},onMinValueChange:e=>{let{value:t}=e.target;Number.isNaN(+t)||i(+t)},onMaxValueChange:e=>{let{value:t}=e.target;Number.isNaN(t)||c(+t)},onKeyDown:a=>{"Enter"===a.key&&l(o>=e&&o<=t?o:e,d>=e&&d<=t?d:t)},onConfirm:e=>{l(e[0],e[1])}}})({min:e,max:r,maxValue:o,minValue:n,onChange:l});return a("div",{className:s("style__1pnwkko0",ra[c],{style__1pnwkko1:_},u),style:{width:i},children:[t(t_,{className:rr,color:"disabled",variant:"caption",children:"от"}),t("input",{className:rt,type:"text",id:w,value:y,onChange:p,onKeyDown:f,ref:m}),t(t_,{className:rr,color:"disabled",variant:"caption",children:"до"}),t("input",{className:rt,type:"text",id:k,value:b,onChange:g,onKeyDown:f,ref:h}),t(t_,{className:rr,color:"disabled",variant:"caption",children:d}),t("div",{className:"style__1pnwkko7",children:t(re,{min:e,max:r,value:[Number(y),Number(b)],onValueChange:v,onValueCommit:N})})]})}function rn({onClick:e,variant:a="outline",...r}){let[l,n]=U(!1);return G(()=>{let e=()=>{window.scrollY>400?n(!0):n(!1)};return window.addEventListener("scroll",e),()=>{window.removeEventListener("scroll",e)}},[]),t(e6,{type:"button",variant:a,className:s("style__1ou2vjc0",{style__1ou2vjc1:l}),onClick:e||(()=>{window.scrollTo({top:0,left:0,behavior:"smooth"})}),...r,children:t(y,{})})}var rs="style__5ilg7od",ro="style__5ilg7o6",ri={sm:"sm__5ilg7o3",md:"md__5ilg7o4",lg:"lg__5ilg7o5"};let rd=eS,rc=ev,ru=eA,r_=({className:e,children:r,size:l="md",...n})=>a(eI,{className:s("style__5ilg7o2",ri[l],e),...n,children:[r,t(eN,{asChild:!0,children:t(m,{className:"style__5ilg7oe"})})]}),rm=({className:e,...a})=>t(eP,{className:s(ro,e),...a,children:t(y,{className:rs})}),rh=({className:e,...a})=>t(eT,{className:s(ro,e),...a,children:t(m,{className:rs})}),rp=({className:e,children:r,position:l="popper",...n})=>t(ez,{children:a(ef,{className:s("style__5ilg7o7",e),position:l,...n,children:[t(rm,{}),t(eL,{className:"style__5ilg7o8",children:r}),t(rh,{})]})}),rg=({className:e,...a})=>t(eC,{className:`style__5ilg7o9 ${e||""}`,...a}),ry=({className:e,children:r,...l})=>a(ew,{className:`style__5ilg7oa ${e||""}`,...l,children:[t("span",{className:"style__5ilg7ob",children:t(ek,{children:t(u,{className:rs})})}),t(ex,{children:r})]}),rb=({className:e,...a})=>t(eD,{className:`style__5ilg7oc ${e||""}`,...a});function rf({...e}){return t(ed.Root,{"data-slot":"sheet",...e})}function rv({...e}){return t(ed.Portal,{"data-slot":"sheet-portal",...e})}function rN({className:e,...a}){return t(ed.Backdrop,{"data-slot":"sheet-overlay",className:s("style__5dkj2fa",e),...a})}rf.Trigger=function({...e}){return t(ed.Trigger,{"data-slot":"sheet-trigger",...e})},rf.Close=function({...e}){return t(ed.Close,{"data-slot":"sheet-close",...e})},rf.Portal=rv,rf.Overlay=rN,rf.Content=function({className:e,children:r,side:l="right",showCloseButton:n=!0,...o}){return a(rv,{children:[t(rN,{}),a(ed.Popup,{"data-slot":"sheet-content","data-side":l,className:s("style__5dkj2fb",e),...o,children:[r,n&&a(ed.Close,{"data-slot":"sheet-close",render:t(e6,{variant:"ghost",className:"style__5dkj2fc",size:"iconSm"}),children:[t(D,{}),t("span",{className:"style__5dkj2fd",children:"Close"})]})]})]})},rf.Header=function({className:e,...a}){return t("div",{"data-slot":"sheet-header",className:s("style__5dkj2fe",e),...a})},rf.Footer=function({className:e,...a}){return t("div",{"data-slot":"sheet-footer",className:s("style__5dkj2ff",e),...a})},rf.Title=function({className:e,...a}){return t(ed.Title,{"data-slot":"sheet-title",className:s("style__5dkj2fg",e),...a})},rf.Description=function({className:e,...a}){return t(ed.Description,{"data-slot":"sheet-description",className:s("style__5dkj2fh",e),...a})};var rw={default:"default__1xiua9nr",sm:"sm__1xiua9ns",lg:"lg__1xiua9nt"},rk={default:"default__1xiua9np",outline:"outline__1xiua9nq"},rx={sm:"sm__1xiua9n13",md:"md__1xiua9n14"},rC="style__1xiua9nx",rz="style__1xiua9n9";let rS=eV.createContext(null);function rT(){let e=eV.useContext(rS);if(!e)throw Error("useSidebar must be used within a Sidebar.Provider.");return e}let rP=Object.assign(function({side:e="left",variant:r="sidebar",collapsible:l="offcanvas",className:n,style:o,children:i,...d}){let{isMobile:c,state:u,openMobile:_,setOpenMobile:m}=rT();return"none"===l?t("div",{"data-slot":"sidebar",style:o,className:s("style__1xiua9n5",n),...d,children:i}):c?t(rf,{open:_,onOpenChange:m,children:a(rf.Content,{"data-sidebar":"sidebar","data-slot":"sidebar","data-mobile":"true",side:e,showCloseButton:!1,style:{"--sidebar-width":"18rem",...o},className:s("style__1xiua9n7",n),...d,children:[a(rf.Header,{className:rz,children:[t(rf.Title,{children:"Sidebar"}),t(rf.Description,{children:"Displays the mobile sidebar."})]}),t("div",{className:"style__1xiua9n8",children:i})]})}):a("div",{"data-state":u,"data-collapsible":"collapsed"===u?l:void 0,"data-variant":r,"data-side":e,"data-slot":"sidebar",className:"style__1xiua9n2",children:[t("div",{"data-slot":"sidebar-gap",className:"style__1xiua9n3"}),t("div",{"data-slot":"sidebar-container",className:s("style__1xiua9n4",n),style:o,...d,children:t("div",{"data-sidebar":"sidebar","data-slot":"sidebar-inner",className:"style__1xiua9n6",children:i})})]})},{Provider:function({defaultOpen:e=!0,open:a,onOpenChange:r,className:l,style:n,children:o,...i}){let d=function(){let[e,t]=eV.useState(void 0);return eV.useEffect(()=>{let e=window.matchMedia("(max-width: 767px)"),a=()=>{t(window.innerWidth<768)};return e.addEventListener("change",a),t(window.innerWidth<768),()=>e.removeEventListener("change",a)},[]),!!e}(),[c,u]=eV.useState(!1),[_,m]=eV.useState(e),h=a??_,p=eV.useCallback(e=>{let t="function"==typeof e?e(h):e;r?r(t):m(t),document.cookie=`sidebar_state=${t}; path=/; max-age=604800`},[r,h]),g=eV.useCallback(()=>{d?u(e=>!e):p(e=>!e)},[d,p]);eV.useEffect(()=>{let e=e=>{"b"===e.key&&(e.metaKey||e.ctrlKey)&&(e.preventDefault(),g())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[g]);let y=h?"expanded":"collapsed",b=eV.useMemo(()=>({state:y,open:h,setOpen:p,isMobile:d,openMobile:c,setOpenMobile:u,toggleSidebar:g}),[y,h,p,d,c,g]);return t(rS.Provider,{value:b,children:t("div",{"data-slot":"sidebar-wrapper",style:{"--sidebar-width":"16rem","--sidebar-width-icon":"3rem",...n},className:s("style__1xiua9n1",l),...i,children:o})})},Trigger:function({className:r,onClick:l,children:n,...o}){let{toggleSidebar:i}=rT();return t(e6,{"data-sidebar":"trigger","data-slot":"sidebar-trigger",variant:"ghost",size:"icon",className:s("style__1xiua9na",r),onClick:e=>{l?.(e),i()},...o,children:n??a(e,{children:[t(S,{}),t("span",{className:rz,children:"Toggle Sidebar"})]})})},Rail:function({className:e,...a}){let{toggleSidebar:r}=rT();return t("button",{type:"button","data-sidebar":"rail","data-slot":"sidebar-rail","aria-label":"Toggle Sidebar",tabIndex:-1,title:"Toggle Sidebar",className:s("style__1xiua9nb",e),onClick:r,...a})},Inset:function({className:e,...a}){return t("main",{"data-slot":"sidebar-inset",className:s("style__1xiua9nc",e),...a})},Input:function({className:e,...a}){return t(av,{"data-slot":"sidebar-input","data-sidebar":"input",className:s("style__1xiua9nd",e),...a})},Header:function({className:e,...a}){return t("div",{"data-slot":"sidebar-header","data-sidebar":"header",className:s("style__1xiua9ne",e),...a})},Footer:function({className:e,...a}){return t("div",{"data-slot":"sidebar-footer","data-sidebar":"footer",className:s("style__1xiua9nf",e),...a})},Separator:function({className:e,orientation:a="horizontal",...r}){return t(j,{"data-slot":"sidebar-separator","data-sidebar":"separator",orientation:a,className:s("style__1xiua9ng",e),...r})},Content:function({className:e,...a}){return t("div",{"data-slot":"sidebar-content","data-sidebar":"content",className:s("style__1xiua9nh",e),...a})},Group:function({className:e,...a}){return t("div",{"data-slot":"sidebar-group","data-sidebar":"group",className:s("style__1xiua9ni",e),...a})},GroupLabel:function({className:e,render:t,...a}){return M({defaultTagName:"div",render:t,props:R({"data-slot":"sidebar-group-label","data-sidebar":"group-label",className:s("style__1xiua9nj",e)},a)})},GroupAction:function({className:e,render:t,...a}){return M({defaultTagName:"button",render:t,props:R({type:"button","data-slot":"sidebar-group-action","data-sidebar":"group-action",className:s("style__1xiua9nk",e)},a)})},GroupContent:function({className:e,...a}){return t("div",{"data-slot":"sidebar-group-content","data-sidebar":"group-content",className:s("style__1xiua9nl",e),...a})},Menu:function({className:e,...a}){return t("ul",{"data-slot":"sidebar-menu","data-sidebar":"menu",className:s("style__1xiua9nm",e),...a})},MenuItem:function({className:e,...a}){return t("li",{"data-slot":"sidebar-menu-item","data-sidebar":"menu-item",className:s("style__1xiua9nn",e),...a})},MenuButton:function({isActive:e=!1,variant:a="default",size:r="default",tooltip:l,className:n,render:o,...i}){let{isMobile:d,state:c}=rT(),u=M({defaultTagName:"button",render:o,props:R({type:"button","data-slot":"sidebar-menu-button","data-sidebar":"menu-button","data-size":r,"data-active":e?"true":"false",className:s("style__1xiua9no",rk[a],rw[r],n)},i)});return!l||"collapsed"!==c||d?u:t(tK,{side:"right",...function(e){if("string"==typeof e)return{text:e};let{children:t,...a}=e;return{content:t,...a}}(l),children:u})},MenuAction:function({className:e,showOnHover:t=!1,render:a,...r}){return M({defaultTagName:"button",render:a,props:R({type:"button","data-slot":"sidebar-menu-action","data-sidebar":"menu-action","data-show-on-hover":t?"true":void 0,className:s("style__1xiua9nu",e)},r)})},MenuBadge:function({className:e,...a}){return t("div",{"data-slot":"sidebar-menu-badge","data-sidebar":"menu-badge",className:s("style__1xiua9nv",e),...a})},MenuSkeleton:function({className:e,showIcon:r=!1,...l}){let n=eV.useMemo(()=>`${Math.floor(40*Math.random())+50}%`,[]);return a("div",{"data-slot":"sidebar-menu-skeleton","data-sidebar":"menu-skeleton",className:s("style__1xiua9nw",e),...l,children:[r&&t("div",{className:s(rC,"style__1xiua9ny"),"data-sidebar":"menu-skeleton-icon"}),t("div",{className:s(rC,"style__1xiua9nz"),"data-sidebar":"menu-skeleton-text",style:{"--skeleton-width":n}})]})},MenuSub:function({className:e,...a}){return t("ul",{"data-slot":"sidebar-menu-sub","data-sidebar":"menu-sub",className:s("style__1xiua9n10",e),...a})},MenuSubItem:function({className:e,...a}){return t("li",{"data-slot":"sidebar-menu-sub-item","data-sidebar":"menu-sub-item",className:s("style__1xiua9n11",e),...a})},MenuSubButton:function({size:e="md",isActive:t=!1,className:a,render:r,...l}){return M({defaultTagName:"a",render:r,props:R({"data-slot":"sidebar-menu-sub-button","data-sidebar":"menu-sub-button","data-size":e,"data-active":t?"true":"false",className:s("style__1xiua9n12",rx[e],a)},l)})}});var rD={sm:"sm__hworoa2",md:"md__hworoa3",lg:"lg__hworoa4"};let rI=e=>t(ej,{...e});rI.Content=({className:e,...a})=>t(eR,{className:s("style__hworoa5",e),...a}),rI.List=({className:e,...a})=>t(eM,{className:s("style__hworoa0",e),...a}),rI.Trigger=({className:e,size:a="md",...r})=>t(eF,{className:s("style__hworoa1",rD[a],e),...r});let rA=({value:e,onChange:r,options:l,size:n,className:o,label:i,multiple:d})=>{let c=!0===d;return a("div",{className:s("style__10hvn8a0",o),children:[i&&t(aN,{className:"style__10hvn8a3",children:i}),t("div",{className:"style__10hvn8a1",children:l.map(a=>{var l;return t(tK,{arrow:!0,text:a.title,children:t(e6,{size:n,className:"style__10hvn8a2",disabled:a.disabled,onClick:()=>{var t;return t=a.value,void(c?e.includes(t)?r(e.filter(e=>e!==t)):r([...e,t]):r(t))},startAdornment:a.startAdornment,endAdornment:a.endAdornment,variant:(l=a.value,c?e.includes(l):e===l)?"default":"outline",children:a.label},a.value)},a.value)})})]})},rL=({form:e,children:a,...r})=>t(eq,{...e,children:t("form",{noValidate:!0,...r,children:a})});function rR({name:e,control:a,...r}){return t(eO,{control:a,name:e,render:({field:e,fieldState:a})=>t(ak,{...r,...e,error:!!a.error,helperText:a.error?.message})})}let rM=({mode:e="onBlur",...t}={})=>e$({...t,mode:e}),rj=({children:e,isLoading:a,...r})=>{let{formState:l}=eH();return t(e6,{type:"submit",isLoading:a||l.isSubmitting,...r,children:e})};function rF({name:e,control:a,gridArea:r,...l}){return t(eO,{control:a,name:e,render:({field:e,fieldState:a})=>t(aw,{...l,...e,style:{gridArea:r},value:e.value||"",error:!!a.error,helperText:a.error?.message})})}var rO=":",rq="—",rB="notify";export{eU as Accordion,e3 as AlertDialog,e7 as Avatar,tt as Badge,ta as Breadcrumb,tr as ButtonGroup,e6 as Button,e9 as buttonSizes,e5 as buttonVariants,tg as Calendar,tb as Card,tP as Carousel,tD as Checkbox,tL as CircularProgress,tR as Collapsible,tF as ConfirmAction,tW as ContentState,eO as FormController,tU as CopyTypography,aC as DESCRIPTION_ROOT_CLASSNAME,tZ as DashboardLayout,t3 as DataGrid,as as DataGridActionCell,ai as DataGridSortHeader,ap as DataList,ax as DatePicker,aI as Description,aA as Dialog,aM as Drawer,at as DropdownMenu,aF as Empty,rL as Form,rR as FormMaskField,eq as FormProvider,rj as FormSubmitButton,rF as FormTextField,aB as ImageCarousel,tq as Image,av as Input,aG as InputOTP,aN as Label,ak as MaskField,aW as NOTIFICATION_POSITIONS,aY as Notification,aU as NotificationContainer,aZ as OverflowTypography,a1 as PageLayout,a2 as Pagination,a8 as PeriodPicker,tV as Placeholder,tj as Popover,a7 as RadioGroupItem,a3 as RadioGroup,rl as RangeInput,rn as ScrollTopButton,rd as Select,rp as SelectContent,rc as SelectGroup,ry as SelectItem,rg as SelectLabel,rh as SelectScrollDownButton,rm as SelectScrollUpButton,rb as SelectSeparator,r_ as SelectTrigger,ru as SelectValue,rf as Sheet,rP as Sidebar,re as Slider,rI as Tabs,aw as TextField,rA as ToggleGroup,tK as Tooltip,t_ as Typography,tl as alignments,te as badgeVariants,tn as colors,aV as NotificationVariantTypes,tM as createHandle,to as displays,aK as notification,rO as DEFAULT_SEPARATOR,rq as DEFAULT_SYMBOL,rB as NOTIFY_CLASSNAME,ty as theme,ti as transforms,eB as useFormController,tJ as useDashboard,eE as useFormFieldArray,eH as useFormContext,rM as useForm,aQ as useOverflowed,rT as useSidebar,eG as useFormWatch,td as variants,tc as weights};
1
+ import { Fragment, jsx, jsxs } from "react/jsx-runtime";
2
+ import { Accordion, Checkbox } from "@base-ui/react";
3
+ import clsx_0, { clsx } from "clsx";
4
+ import { ArrowDownNarrowWide, ArrowDownUp, ArrowDownWideNarrow, Calendar1, Check, CheckIcon, ChevronDown, ChevronLeft, ChevronRight, ChevronRightIcon, ChevronUp, CircleCheck, CircleIcon, Copy, Ellipsis as external_lucide_react_Ellipsis, EllipsisVertical, Info, MoreHorizontalIcon, OctagonAlert, PanelLeftClose, PanelLeftIcon, PanelLeftOpen, TriangleAlert, XIcon } from "lucide-react";
5
+ import { AlertDialog } from "@base-ui/react/alert-dialog";
6
+ import { Button } from "@base-ui/react/button";
7
+ import { Avatar } from "@base-ui/react/avatar";
8
+ import { mergeProps } from "@base-ui/react/merge-props";
9
+ import { useRender } from "@base-ui/react/use-render";
10
+ import { Separator as separator_Separator } from "@base-ui/react/separator";
11
+ import { DayPicker } from "react-day-picker";
12
+ import { ru } from "react-day-picker/locale";
13
+ import react, { createContext, createElement, useCallback, useContext, useEffect, useId, useLayoutEffect, useMemo, useRef, useState } from "react";
14
+ import embla_carousel_react from "embla-carousel-react";
15
+ import { Collapsible } from "@base-ui/react/collapsible";
16
+ import { Popover } from "@base-ui/react/popover";
17
+ import { Arrow, Content as react_tooltip_Content, Portal as react_tooltip_Portal, Provider, Root, Trigger as react_tooltip_Trigger } from "@radix-ui/react-tooltip";
18
+ import { Menu } from "@base-ui/react/menu";
19
+ import { Virtuoso } from "react-virtuoso";
20
+ import { useMask } from "@react-input/mask";
21
+ import { Root as react_label_Root } from "@radix-ui/react-label";
22
+ import { Dialog } from "@base-ui/react/dialog";
23
+ import { Drawer, Root as external_vaul_Root } from "vaul";
24
+ import { OTPInput } from "input-otp";
25
+ import { Toaster, toast } from "sonner";
26
+ import { Indicator, Item as react_radio_group_Item, Root as react_radio_group_Root } from "@radix-ui/react-radio-group";
27
+ import { Slider } from "@base-ui/react/slider";
28
+ import { Content as react_select_Content, Group as react_select_Group, Icon, Item as react_select_Item, ItemIndicator, ItemText, Label as react_select_Label, Portal as react_select_Portal, Root as react_select_Root, ScrollDownButton, ScrollUpButton, Separator as react_select_Separator, Trigger as react_select_Trigger, Value as react_select_Value, Viewport } from "@radix-ui/react-select";
29
+ import { Content as react_tabs_Content, List as react_tabs_List, Tabs, Trigger as react_tabs_Trigger } from "@radix-ui/react-tabs";
30
+ import { Controller, FormProvider, useController, useFieldArray, useForm, useFormContext, useWatch } from "react-hook-form";
31
+ import * as __rspack_external_react from "react";
32
+ var __webpack_require__ = {};
33
+ (()=>{
34
+ __webpack_require__.d = (exports, getters, values)=>{
35
+ var define = (defs, kind)=>{
36
+ for(var key in defs)if (__webpack_require__.o(defs, key) && !__webpack_require__.o(exports, key)) Object.defineProperty(exports, key, {
37
+ enumerable: true,
38
+ [kind]: defs[key]
39
+ });
40
+ };
41
+ define(getters, "get");
42
+ define(values, "value");
43
+ };
44
+ })();
45
+ (()=>{
46
+ __webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop);
47
+ })();
48
+ (()=>{
49
+ __webpack_require__.r = (exports)=>{
50
+ if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports, Symbol.toStringTag, {
51
+ value: 'Module'
52
+ });
53
+ Object.defineProperty(exports, '__esModule', {
54
+ value: true
55
+ });
56
+ };
57
+ })();
58
+ var button_css_namespaceObject = {};
59
+ __webpack_require__.r(button_css_namespaceObject);
60
+ __webpack_require__.d(button_css_namespaceObject, {
61
+ e: ()=>buttonBase,
62
+ dK: ()=>buttonSizes,
63
+ ru: ()=>buttonVariants,
64
+ ik: ()=>button_css_endAdornment,
65
+ Fu: ()=>fullWidthStyle,
66
+ Lq: ()=>loading,
67
+ PM: ()=>button_css_startAdornment
68
+ });
69
+ var styles_css_header = 'style__1b0hb6s4';
70
+ var styles_css_item = 'style__1b0hb6s3';
71
+ var panel = 'style__1b0hb6s9';
72
+ var panelContent = 'style__1b0hb6sa';
73
+ var root = 'style__1b0hb6s2';
74
+ var styles_css_trigger = 'style__1b0hb6s5';
75
+ var triggerIconDown = 'style__1b0hb6s7 style__1b0hb6s6';
76
+ var triggerIconUp = 'style__1b0hb6s8 style__1b0hb6s6';
77
+ function Accordion_Accordion({ className, ...props }) {
78
+ return /*#__PURE__*/ jsx(Accordion.Root, {
79
+ "data-slot": "accordion",
80
+ className: clsx(root, className),
81
+ ...props
82
+ });
83
+ }
84
+ function Item({ className, ...props }) {
85
+ return /*#__PURE__*/ jsx(Accordion.Item, {
86
+ "data-slot": "accordion-item",
87
+ className: clsx(styles_css_item, className),
88
+ ...props
89
+ });
90
+ }
91
+ function Trigger({ className, children, ...props }) {
92
+ return /*#__PURE__*/ jsx(Accordion.Header, {
93
+ className: styles_css_header,
94
+ children: /*#__PURE__*/ jsxs(Accordion.Trigger, {
95
+ "data-slot": "accordion-trigger",
96
+ className: clsx(styles_css_trigger, className),
97
+ ...props,
98
+ children: [
99
+ children,
100
+ /*#__PURE__*/ jsx(ChevronDown, {
101
+ "data-slot": "accordion-trigger-icon",
102
+ size: 16,
103
+ className: triggerIconDown
104
+ }),
105
+ /*#__PURE__*/ jsx(ChevronUp, {
106
+ "data-slot": "accordion-trigger-icon",
107
+ size: 16,
108
+ className: triggerIconUp
109
+ })
110
+ ]
111
+ })
112
+ });
113
+ }
114
+ function Accordion_Content({ className, children, ...props }) {
115
+ return /*#__PURE__*/ jsx(Accordion.Panel, {
116
+ "data-slot": "accordion-content",
117
+ className: clsx(panel, className),
118
+ ...props,
119
+ children: /*#__PURE__*/ jsx("div", {
120
+ className: clsx(panelContent, className),
121
+ children: children
122
+ })
123
+ });
124
+ }
125
+ Accordion_Accordion.Item = Item;
126
+ Accordion_Accordion.Trigger = Trigger;
127
+ Accordion_Accordion.Content = Accordion_Content;
128
+ var buttonBase = 'style__1ersxw10';
129
+ var buttonSizes = {
130
+ sm: 'sm__1ersxw19',
131
+ md: 'md__1ersxw1a',
132
+ lg: 'lg__1ersxw1b',
133
+ icon: 'icon__1ersxw1c',
134
+ iconSm: 'iconSm__1ersxw1d'
135
+ };
136
+ var buttonVariants = {
137
+ default: 'default__1ersxw14',
138
+ destructive: 'destructive__1ersxw15',
139
+ outline: 'outline__1ersxw16',
140
+ ghost: 'ghost__1ersxw17',
141
+ link: 'link__1ersxw18'
142
+ };
143
+ var button_css_endAdornment = 'style__1ersxw1f';
144
+ var fullWidthStyle = 'style__1ersxw13';
145
+ var loading = 'style__1ersxw12';
146
+ var button_css_startAdornment = 'style__1ersxw1e';
147
+ const Button_Button = ({ className, variant = 'default', size = 'md', startAdornment, endAdornment, isLoading = false, fullWidth, children, ...props })=>/*#__PURE__*/ jsxs(Button, {
148
+ nativeButton: props.nativeButton ?? !props.render,
149
+ className: clsx(buttonBase, buttonVariants[variant], buttonSizes[size], {
150
+ [fullWidthStyle]: fullWidth,
151
+ [loading]: isLoading
152
+ }, className),
153
+ ...props,
154
+ children: [
155
+ startAdornment && /*#__PURE__*/ jsx("span", {
156
+ className: button_css_startAdornment,
157
+ children: startAdornment
158
+ }),
159
+ children,
160
+ endAdornment && /*#__PURE__*/ jsx("span", {
161
+ className: button_css_endAdornment,
162
+ children: endAdornment
163
+ })
164
+ ]
165
+ });
166
+ const { ru: Button_buttonVariants, dK: Button_buttonSizes } = button_css_namespaceObject;
167
+ var styles_css_content = 'style__qmtpwy5';
168
+ var styles_css_description = 'style__qmtpwya';
169
+ var styles_css_footer = 'style__qmtpwy7';
170
+ var AlertDialog_styles_css_header = 'style__qmtpwy6';
171
+ var media = 'style__qmtpwy8';
172
+ var overlay = 'style__qmtpwy4';
173
+ var styles_css_title = 'style__qmtpwy9';
174
+ function AlertDialog_Trigger({ ...props }) {
175
+ return /*#__PURE__*/ jsx(AlertDialog.Trigger, {
176
+ "data-slot": "alert-dialog-trigger",
177
+ ...props
178
+ });
179
+ }
180
+ function Portal({ ...props }) {
181
+ return /*#__PURE__*/ jsx(AlertDialog.Portal, {
182
+ "data-slot": "alert-dialog-portal",
183
+ ...props
184
+ });
185
+ }
186
+ function Overlay({ className, ...props }) {
187
+ return /*#__PURE__*/ jsx(AlertDialog.Backdrop, {
188
+ "data-slot": "alert-dialog-overlay",
189
+ className: clsx(overlay, className),
190
+ ...props
191
+ });
192
+ }
193
+ function AlertDialog_Content({ className, size = 'default', ...props }) {
194
+ return /*#__PURE__*/ jsxs(Portal, {
195
+ children: [
196
+ /*#__PURE__*/ jsx(Overlay, {}),
197
+ /*#__PURE__*/ jsx(AlertDialog.Popup, {
198
+ "data-slot": "alert-dialog-content",
199
+ "data-size": size,
200
+ className: clsx(styles_css_content, className),
201
+ ...props
202
+ })
203
+ ]
204
+ });
205
+ }
206
+ function Header({ className, ...props }) {
207
+ return /*#__PURE__*/ jsx("div", {
208
+ "data-slot": "alert-dialog-header",
209
+ className: clsx(AlertDialog_styles_css_header, className),
210
+ ...props
211
+ });
212
+ }
213
+ function Footer({ className, ...props }) {
214
+ return /*#__PURE__*/ jsx("div", {
215
+ "data-slot": "alert-dialog-footer",
216
+ className: clsx(styles_css_footer, className),
217
+ ...props
218
+ });
219
+ }
220
+ function Media({ className, ...props }) {
221
+ return /*#__PURE__*/ jsx("div", {
222
+ "data-slot": "alert-dialog-media",
223
+ className: clsx(media, className),
224
+ ...props
225
+ });
226
+ }
227
+ function Title({ className, ...props }) {
228
+ return /*#__PURE__*/ jsx(AlertDialog.Title, {
229
+ "data-slot": "alert-dialog-title",
230
+ className: clsx(styles_css_title, className),
231
+ ...props
232
+ });
233
+ }
234
+ function Description({ className, ...props }) {
235
+ return /*#__PURE__*/ jsx(AlertDialog.Description, {
236
+ "data-slot": "alert-dialog-description",
237
+ className: clsx(styles_css_description, className),
238
+ ...props
239
+ });
240
+ }
241
+ function Action({ className, ...props }) {
242
+ return /*#__PURE__*/ jsx(Button_Button, {
243
+ "data-slot": "alert-dialog-action",
244
+ className: className,
245
+ ...props
246
+ });
247
+ }
248
+ function Cancel({ className, variant = 'outline', size = 'md', ...props }) {
249
+ return /*#__PURE__*/ jsx(AlertDialog.Close, {
250
+ "data-slot": "alert-dialog-cancel",
251
+ className: className,
252
+ render: /*#__PURE__*/ jsx(Button_Button, {
253
+ variant: variant,
254
+ size: size
255
+ }),
256
+ ...props
257
+ });
258
+ }
259
+ function AlertDialog_AlertDialog({ ...props }) {
260
+ return /*#__PURE__*/ jsx(AlertDialog.Root, {
261
+ "data-slot": "alert-dialog",
262
+ ...props
263
+ });
264
+ }
265
+ AlertDialog_AlertDialog.Trigger = AlertDialog_Trigger;
266
+ AlertDialog_AlertDialog.Overlay = Overlay;
267
+ AlertDialog_AlertDialog.Content = AlertDialog_Content;
268
+ AlertDialog_AlertDialog.Header = Header;
269
+ AlertDialog_AlertDialog.Footer = Footer;
270
+ AlertDialog_AlertDialog.Media = Media;
271
+ AlertDialog_AlertDialog.Title = Title;
272
+ AlertDialog_AlertDialog.Description = Description;
273
+ AlertDialog_AlertDialog.Action = Action;
274
+ AlertDialog_AlertDialog.Cancel = Cancel;
275
+ var badge = 'style__hhcrfl3';
276
+ var fallback = 'style__hhcrfl2';
277
+ var group = 'style__hhcrfl4';
278
+ var groupCount = 'style__hhcrfl5';
279
+ var styles_css_image = 'style__hhcrfl1';
280
+ var styles_css_root = 'style__hhcrfl0';
281
+ function Avatar_Avatar({ className, size = 'default', ...props }) {
282
+ return /*#__PURE__*/ jsx(Avatar.Root, {
283
+ "data-slot": "avatar",
284
+ "data-size": size,
285
+ className: clsx(styles_css_root, className),
286
+ ...props
287
+ });
288
+ }
289
+ function Image({ className, ...props }) {
290
+ return /*#__PURE__*/ jsx(Avatar.Image, {
291
+ "data-slot": "avatar-image",
292
+ className: clsx(styles_css_image, className),
293
+ ...props
294
+ });
295
+ }
296
+ function Fallback({ className, ...props }) {
297
+ return /*#__PURE__*/ jsx(Avatar.Fallback, {
298
+ "data-slot": "avatar-fallback",
299
+ className: clsx(fallback, className),
300
+ ...props
301
+ });
302
+ }
303
+ function Badge({ className, ...props }) {
304
+ return /*#__PURE__*/ jsx("span", {
305
+ "data-slot": "avatar-badge",
306
+ className: clsx(badge, className),
307
+ ...props
308
+ });
309
+ }
310
+ function Group({ className, ...props }) {
311
+ return /*#__PURE__*/ jsx("div", {
312
+ "data-slot": "avatar-group",
313
+ className: clsx(group, className),
314
+ ...props
315
+ });
316
+ }
317
+ function GroupCount({ className, ...props }) {
318
+ return /*#__PURE__*/ jsx("div", {
319
+ "data-slot": "avatar-group-count",
320
+ className: clsx(groupCount, className),
321
+ ...props
322
+ });
323
+ }
324
+ Avatar_Avatar.Image = Image;
325
+ Avatar_Avatar.Fallback = Fallback;
326
+ Avatar_Avatar.Badge = Badge;
327
+ Avatar_Avatar.Group = Group;
328
+ Avatar_Avatar.GroupCount = GroupCount;
329
+ var badgeVariants = {
330
+ default: 'default__1af895x1',
331
+ secondary: 'secondary__1af895x2',
332
+ destructive: 'destructive__1af895x3',
333
+ outline: 'outline__1af895x4'
334
+ };
335
+ var rootClass = 'style__1af895x0';
336
+ function Badge_Badge({ className, variant = 'default', render, ...props }) {
337
+ return useRender({
338
+ defaultTagName: 'span',
339
+ props: mergeProps({
340
+ className: clsx(rootClass, badgeVariants[variant], className)
341
+ }, props),
342
+ render,
343
+ state: {
344
+ slot: 'badge',
345
+ variant
346
+ }
347
+ });
348
+ }
349
+ var ellipsis = 'style__1dceszz5';
350
+ var Breadcrumb_styles_css_item = 'style__1dceszz1';
351
+ var styles_css_link = 'style__1dceszz2';
352
+ var list = 'style__1dceszz0';
353
+ var page = 'style__1dceszz3';
354
+ var styles_css_separator = 'style__1dceszz4';
355
+ var visuallyHidden = 'style__1dceszz6';
356
+ function Breadcrumb({ className, ...props }) {
357
+ return /*#__PURE__*/ jsx("nav", {
358
+ "aria-label": "breadcrumb",
359
+ "data-slot": "breadcrumb",
360
+ className: className,
361
+ ...props
362
+ });
363
+ }
364
+ function List({ className, ...props }) {
365
+ return /*#__PURE__*/ jsx("ol", {
366
+ "data-slot": "breadcrumb-list",
367
+ className: clsx(list, className),
368
+ ...props
369
+ });
370
+ }
371
+ function Breadcrumb_Item({ className, ...props }) {
372
+ return /*#__PURE__*/ jsx("li", {
373
+ "data-slot": "breadcrumb-item",
374
+ className: clsx(Breadcrumb_styles_css_item, className),
375
+ ...props
376
+ });
377
+ }
378
+ function Link({ className, render, ...props }) {
379
+ return useRender({
380
+ defaultTagName: 'a',
381
+ props: mergeProps({
382
+ className: clsx(styles_css_link, className)
383
+ }, props),
384
+ render,
385
+ state: {
386
+ slot: 'breadcrumb-link'
387
+ }
388
+ });
389
+ }
390
+ function Page({ className, ...props }) {
391
+ return /*#__PURE__*/ jsx("span", {
392
+ "data-slot": "breadcrumb-page",
393
+ "aria-current": "page",
394
+ className: clsx(page, className),
395
+ ...props
396
+ });
397
+ }
398
+ function Separator({ children, className, ...props }) {
399
+ return /*#__PURE__*/ jsx("li", {
400
+ "data-slot": "breadcrumb-separator",
401
+ role: "presentation",
402
+ "aria-hidden": "true",
403
+ className: clsx(styles_css_separator, className),
404
+ ...props,
405
+ children: children ?? /*#__PURE__*/ jsx(ChevronRightIcon, {})
406
+ });
407
+ }
408
+ function Ellipsis({ className, ...props }) {
409
+ return /*#__PURE__*/ jsxs("span", {
410
+ "data-slot": "breadcrumb-ellipsis",
411
+ role: "presentation",
412
+ "aria-hidden": "true",
413
+ className: clsx(ellipsis, className),
414
+ ...props,
415
+ children: [
416
+ /*#__PURE__*/ jsx(MoreHorizontalIcon, {}),
417
+ /*#__PURE__*/ jsx("span", {
418
+ className: visuallyHidden,
419
+ children: "More"
420
+ })
421
+ ]
422
+ });
423
+ }
424
+ Breadcrumb.List = List;
425
+ Breadcrumb.Item = Breadcrumb_Item;
426
+ Breadcrumb.Link = Link;
427
+ Breadcrumb.Page = Page;
428
+ Breadcrumb.Separator = Separator;
429
+ Breadcrumb.Ellipsis = Ellipsis;
430
+ var ButtonGroup_styles_css_root = 'style__1mf3lgr0';
431
+ var ButtonGroup_styles_css_separator = 'style__1mf3lgr2';
432
+ var styles_css_text = 'style__1mf3lgr1';
433
+ function ButtonGroup({ className, orientation = 'horizontal', ...props }) {
434
+ return /*#__PURE__*/ jsx("fieldset", {
435
+ "data-slot": "button-group",
436
+ "data-orientation": orientation,
437
+ className: clsx(ButtonGroup_styles_css_root, className),
438
+ ...props
439
+ });
440
+ }
441
+ function Text({ className, render, ...props }) {
442
+ return useRender({
443
+ defaultTagName: 'div',
444
+ props: mergeProps({
445
+ className: clsx(styles_css_text, className)
446
+ }, props),
447
+ render,
448
+ state: {
449
+ slot: 'button-group-text'
450
+ }
451
+ });
452
+ }
453
+ function ButtonGroup_Separator({ className, orientation = 'vertical', ...props }) {
454
+ return /*#__PURE__*/ jsx(separator_Separator, {
455
+ "data-slot": "button-group-separator",
456
+ "data-orientation": orientation,
457
+ orientation: orientation,
458
+ className: clsx(ButtonGroup_styles_css_separator, className),
459
+ ...props
460
+ });
461
+ }
462
+ ButtonGroup.Text = Text;
463
+ ButtonGroup.Separator = ButtonGroup_Separator;
464
+ var alignments = {
465
+ left: 'left__1sba6zok',
466
+ center: 'center__1sba6zol',
467
+ right: 'right__1sba6zom',
468
+ justify: 'justify__1sba6zon'
469
+ };
470
+ var colors = {
471
+ primary: 'primary__1sba6zoc',
472
+ secondary: 'secondary__1sba6zod',
473
+ disabled: 'disabled__1sba6zoe',
474
+ success: 'success__1sba6zof',
475
+ error: 'error__1sba6zog',
476
+ warning: 'warning__1sba6zoh',
477
+ info: 'info__1sba6zoi',
478
+ muted: 'muted__1sba6zoj'
479
+ };
480
+ var decorations = {
481
+ none: 'none__1sba6zox',
482
+ underline: 'underline__1sba6zoy',
483
+ lineThrough: 'lineThrough__1sba6zoz'
484
+ };
485
+ var displays = {
486
+ block: 'block__1sba6zoo',
487
+ inline: 'inline__1sba6zop'
488
+ };
489
+ var gutterBottomClass = 'style__1sba6zo10';
490
+ var transforms = {
491
+ lowercase: 'lowercase__1sba6zou',
492
+ uppercase: 'uppercase__1sba6zov',
493
+ capitalize: 'capitalize__1sba6zow'
494
+ };
495
+ var variants = {
496
+ h1: 'h1__1sba6zo0',
497
+ h2: 'h2__1sba6zo1',
498
+ h3: 'h3__1sba6zo2',
499
+ h4: 'h4__1sba6zo3',
500
+ h5: 'h5__1sba6zo4',
501
+ h6: 'h6__1sba6zo5',
502
+ subtitle1: 'subtitle1__1sba6zo6',
503
+ subtitle2: 'subtitle2__1sba6zo7',
504
+ body1: 'body1__1sba6zo8',
505
+ body2: 'body2__1sba6zo9',
506
+ caption: 'caption__1sba6zoa',
507
+ overline: 'overline__1sba6zob'
508
+ };
509
+ var weights = {
510
+ normal: 'normal__1sba6zoq',
511
+ medium: 'medium__1sba6zor',
512
+ semibold: 'semibold__1sba6zos',
513
+ bold: 'bold__1sba6zot'
514
+ };
515
+ const VARIANT_COMPONENT_MAP = {
516
+ h1: 'h1',
517
+ h2: 'h2',
518
+ h3: 'h3',
519
+ h4: 'h4',
520
+ h5: 'h5',
521
+ h6: 'h6',
522
+ subtitle1: 'h6',
523
+ subtitle2: 'h6',
524
+ body1: 'p',
525
+ body2: 'p',
526
+ caption: 'span',
527
+ overline: 'span'
528
+ };
529
+ const Typography = ({ className, variant = 'body1', component, color = 'primary', align = 'left', display = 'inline', weight = 'normal', transform, decoration = 'none', gutterBottom, children, ...props })=>{
530
+ const Component = component || VARIANT_COMPONENT_MAP[variant || 'body1'];
531
+ return /*#__PURE__*/ jsx(Component, {
532
+ className: clsx(decorations[decoration], variants[variant], colors[color], weights[weight], transform && transforms[transform], displays[display], alignments[align], {
533
+ [gutterBottomClass]: gutterBottom
534
+ }, className),
535
+ ...props,
536
+ children: children
537
+ });
538
+ };
539
+ var styles_css_button = 'dayButton__hxs6pw0';
540
+ var outside = 'outside__hxs6pw2';
541
+ var today = 'today__hxs6pw1';
542
+ const DayButton = (props)=>{
543
+ const { modifiers, className, ...buttonProps } = props;
544
+ const ref = useRef(null);
545
+ useEffect(()=>{
546
+ if (modifiers.focused) ref.current?.focus();
547
+ }, [
548
+ modifiers.focused
549
+ ]);
550
+ return /*#__PURE__*/ jsx(Button_Button, {
551
+ ref: ref,
552
+ className: clsx(styles_css_button, {
553
+ [outside]: modifiers.outside,
554
+ [today]: modifiers.today
555
+ }, className),
556
+ variant: modifiers.selected ? 'default' : 'ghost',
557
+ ...buttonProps
558
+ });
559
+ };
560
+ var Dropdown_styles_css_trigger = 'style__1e2msjb0';
561
+ function Dropdown(props) {
562
+ const { options, onChange, ...restProps } = props;
563
+ const selectedOption = options?.find(({ value })=>value === restProps.value);
564
+ const handleChange = (value)=>{
565
+ if (onChange) onChange({
566
+ target: {
567
+ value
568
+ }
569
+ });
570
+ };
571
+ return /*#__PURE__*/ jsxs(Select, {
572
+ value: selectedOption?.value.toString(),
573
+ onValueChange: handleChange,
574
+ children: [
575
+ /*#__PURE__*/ jsx(SelectTrigger, {
576
+ className: Dropdown_styles_css_trigger,
577
+ children: /*#__PURE__*/ jsx(SelectValue, {
578
+ placeholder: selectedOption?.label
579
+ })
580
+ }),
581
+ /*#__PURE__*/ jsx(SelectContent, {
582
+ children: options?.map(({ value, label, disabled })=>/*#__PURE__*/ jsx(SelectItem, {
583
+ value: value.toString(),
584
+ disabled: disabled,
585
+ children: /*#__PURE__*/ jsx(Typography, {
586
+ align: "center",
587
+ transform: "capitalize",
588
+ children: label
589
+ })
590
+ }, value))
591
+ })
592
+ ]
593
+ });
594
+ }
595
+ var dropdownNav = 'dropdownNav__14q7je26';
596
+ var dropdowns = 'dropdowns__14q7je25';
597
+ var styles_css_month = 'month__14q7je23';
598
+ var monthButton = 'monthButton__14q7je21';
599
+ var monthCaption = 'monthCaption__14q7je24';
600
+ var months = 'months__14q7je22';
601
+ var nav = 'nav__14q7je20';
602
+ const Calendar = ({ className, classNames, showOutsideDays = true, ...props })=>/*#__PURE__*/ jsx(DayPicker, {
603
+ locale: ru,
604
+ showOutsideDays: showOutsideDays,
605
+ classNames: {
606
+ month: styles_css_month,
607
+ months: months,
608
+ nav: nav,
609
+ month_caption: monthCaption,
610
+ dropdown: dropdownNav,
611
+ dropdowns: dropdowns
612
+ },
613
+ components: {
614
+ DayButton: DayButton,
615
+ Dropdown: Dropdown,
616
+ PreviousMonthButton: ({ className, color, ...props })=>/*#__PURE__*/ jsx(Button_Button, {
617
+ className: clsx_0(monthButton, className),
618
+ variant: "ghost",
619
+ ...props
620
+ }),
621
+ NextMonthButton: ({ className, color, ...props })=>/*#__PURE__*/ jsx(Button_Button, {
622
+ className: clsx_0(monthButton, className),
623
+ variant: "ghost",
624
+ ...props
625
+ }),
626
+ CaptionLabel: ({ className, color, ...props })=>/*#__PURE__*/ jsx(Typography, {
627
+ transform: "capitalize",
628
+ className: className,
629
+ ...props
630
+ })
631
+ },
632
+ ...props
633
+ });
634
+ var theme = {
635
+ colors: {
636
+ primary: 'var(--colors-primary)',
637
+ secondary: 'var(--colors-secondary)',
638
+ warning: 'var(--colors-warning)',
639
+ error: 'var(--colors-error)',
640
+ success: 'var(--colors-success)',
641
+ border: 'var(--colors-border)',
642
+ info: 'var(--colors-info)',
643
+ background: {
644
+ tooltip: 'var(--colors-background-tooltip)',
645
+ paper: 'var(--colors-background-paper)',
646
+ element: 'var(--colors-background-element)',
647
+ elementHover: 'var(--colors-background-elementHover)',
648
+ sidebar: 'var(--colors-background-sidebar)'
649
+ },
650
+ foreground: {
651
+ primary: 'var(--colors-foreground-primary)',
652
+ secondary: 'var(--colors-foreground-secondary)'
653
+ },
654
+ text: {
655
+ primary: 'var(--colors-text-primary)',
656
+ secondary: 'var(--colors-text-secondary)',
657
+ disabled: 'var(--colors-text-disabled)',
658
+ hint: 'var(--colors-text-hint)'
659
+ }
660
+ },
661
+ spacing: {
662
+ 1: 'var(--spacing-1)',
663
+ 2: 'var(--spacing-2)',
664
+ 3: 'var(--spacing-3)',
665
+ 4: 'var(--spacing-4)',
666
+ 5: 'var(--spacing-5)',
667
+ 6: 'var(--spacing-6)',
668
+ 8: 'var(--spacing-8)',
669
+ 10: 'var(--spacing-10)',
670
+ 12: 'var(--spacing-12)',
671
+ 16: 'var(--spacing-16)',
672
+ 20: 'var(--spacing-20)'
673
+ },
674
+ elevation: {
675
+ 1: 'var(--elevation-1)',
676
+ 2: 'var(--elevation-2)',
677
+ 3: 'var(--elevation-3)',
678
+ 4: 'var(--elevation-4)',
679
+ 6: 'var(--elevation-5)'
680
+ },
681
+ fontSize: {
682
+ xs: 'var(--fontSize-xs)',
683
+ sm: 'var(--fontSize-sm)',
684
+ base: 'var(--fontSize-base)',
685
+ lg: 'var(--fontSize-lg)',
686
+ xl: 'var(--fontSize-xl)',
687
+ '2xl': 'var(--fontSize-2xl)',
688
+ '3xl': 'var(--fontSize-3xl)',
689
+ '4xl': 'var(--fontSize-4xl)'
690
+ },
691
+ fontWeight: {
692
+ normal: 'var(--fontWeight-normal)',
693
+ medium: 'var(--fontWeight-medium)',
694
+ semibold: 'var(--fontWeight-semibold)',
695
+ bold: 'var(--fontWeight-bold)'
696
+ },
697
+ lineHeight: {
698
+ none: 'var(--lineHeight-none)',
699
+ tight: 'var(--lineHeight-tight)',
700
+ snug: 'var(--lineHeight-snug)',
701
+ normal: 'var(--lineHeight-normal)',
702
+ relaxed: 'var(--lineHeight-relaxed)',
703
+ loose: 'var(--lineHeight-loose)'
704
+ },
705
+ borderRadius: {
706
+ sm: 'var(--borderRadius-sm)',
707
+ md: 'var(--borderRadius-md)',
708
+ lg: 'var(--borderRadius-lg)'
709
+ }
710
+ };
711
+ const negativeSpacing = (...keys)=>keys.map((key)=>`calc(-1 * ${theme.spacing[key]})`).join(' ');
712
+ const spacing = (...keys)=>keys.map((key)=>theme.spacing[key]).join(' ');
713
+ const calculateSize = (value)=>'number' == typeof value ? `${value}px` : value;
714
+ var card_css_content = 'style__oyalw04';
715
+ var card_css_description = 'style__oyalw03';
716
+ var card_css_footer = 'style__oyalw05';
717
+ var card_css_header = 'style__oyalw01';
718
+ var card_css_root = 'style__oyalw00';
719
+ var card_css_title = 'style__oyalw02';
720
+ const Card = ({ className, elevation = 2, ...props })=>/*#__PURE__*/ jsx("div", {
721
+ style: {
722
+ boxShadow: theme.elevation[elevation]
723
+ },
724
+ className: clsx(card_css_root, className),
725
+ ...props
726
+ });
727
+ const Card_Header = ({ className, ...props })=>/*#__PURE__*/ jsx("div", {
728
+ className: clsx(card_css_header, className),
729
+ ...props
730
+ });
731
+ const Card_Title = ({ className, ...props })=>/*#__PURE__*/ jsx("h3", {
732
+ className: clsx(card_css_title, className),
733
+ ...props
734
+ });
735
+ const Card_Description = ({ className, ...props })=>/*#__PURE__*/ jsx("p", {
736
+ className: clsx(card_css_description, className),
737
+ ...props
738
+ });
739
+ const Card_Content = ({ className, ...props })=>/*#__PURE__*/ jsx("div", {
740
+ className: clsx(card_css_content, className),
741
+ ...props
742
+ });
743
+ const Card_Footer = ({ className, ...props })=>/*#__PURE__*/ jsx("div", {
744
+ className: clsx(card_css_footer, className),
745
+ ...props
746
+ });
747
+ Card.Footer = Card_Footer;
748
+ Card.Header = Card_Header;
749
+ Card.Title = Card_Title;
750
+ Card.Description = Card_Description;
751
+ Card.Content = Card_Content;
752
+ const CarouselContext = react.createContext(null);
753
+ function useCarousel() {
754
+ const context = react.useContext(CarouselContext);
755
+ if (!context) throw new Error('useCarousel must be used within a <Carousel />');
756
+ return context;
757
+ }
758
+ var next = 'style__2d6ocq1 style__2d6ocq0';
759
+ var orientations = {
760
+ horizontal: 'horizontal__2d6ocq3',
761
+ vertical: 'vertical__2d6ocq4'
762
+ };
763
+ var prev = 'style__2d6ocq2 style__2d6ocq0';
764
+ function Buttons({ className, ...props }) {
765
+ const { orientation = 'horizontal', canScrollNext, scrollNext, canScrollPrev, scrollPrev } = useCarousel();
766
+ return /*#__PURE__*/ jsxs(Fragment, {
767
+ children: [
768
+ /*#__PURE__*/ jsx("button", {
769
+ className: clsx(next, orientations[orientation]),
770
+ type: "button",
771
+ "data-slot": "carousel-next",
772
+ disabled: !canScrollNext,
773
+ onClick: scrollNext,
774
+ ...props,
775
+ children: 'horizontal' === orientation ? /*#__PURE__*/ jsx(ChevronRight, {}) : /*#__PURE__*/ jsx(ChevronDown, {})
776
+ }),
777
+ /*#__PURE__*/ jsx("button", {
778
+ type: "button",
779
+ className: clsx(prev, orientations[orientation]),
780
+ "data-slot": "carousel-previous",
781
+ disabled: !canScrollPrev,
782
+ onClick: scrollPrev,
783
+ ...props,
784
+ children: 'horizontal' === orientation ? /*#__PURE__*/ jsx(ChevronLeft, {}) : /*#__PURE__*/ jsx(ChevronUp, {})
785
+ })
786
+ ]
787
+ });
788
+ }
789
+ var styles_css_orientations = {
790
+ horizontal: 'horizontal__i1lems1',
791
+ vertical: 'vertical__i1lems2'
792
+ };
793
+ var wrapper = 'style__i1lems0';
794
+ function Content_Content(props) {
795
+ const { carouselRef, orientation = 'horizontal' } = useCarousel();
796
+ return /*#__PURE__*/ jsx("div", {
797
+ className: wrapper,
798
+ ref: carouselRef,
799
+ "data-slot": "carousel-content",
800
+ children: /*#__PURE__*/ jsx("div", {
801
+ className: styles_css_orientations[orientation],
802
+ ...props
803
+ })
804
+ });
805
+ }
806
+ var dotButton = {
807
+ horizontal: 'horizontal__e2zpp64 style__e2zpp63',
808
+ vertical: 'vertical__e2zpp65 style__e2zpp63'
809
+ };
810
+ var styles_css_selected = 'style__e2zpp66';
811
+ var styles_css_wrapper = {
812
+ horizontal: 'horizontal__e2zpp61 style__e2zpp60',
813
+ vertical: 'vertical__e2zpp62 style__e2zpp60'
814
+ };
815
+ const useLogic = (api)=>{
816
+ const [selectedIndex, setSelectedIndex] = useState(0);
817
+ const [scrollSnaps, setScrollSnaps] = useState([]);
818
+ const onDotButtonClick = useCallback((index)=>{
819
+ if (!api) return;
820
+ api.scrollTo(index);
821
+ }, [
822
+ api
823
+ ]);
824
+ const onInit = useCallback((api)=>{
825
+ if (!api) return;
826
+ setScrollSnaps(api.scrollSnapList());
827
+ }, []);
828
+ const onSelect = useCallback((api)=>{
829
+ if (!api) return;
830
+ setSelectedIndex(api.selectedScrollSnap());
831
+ }, []);
832
+ useEffect(()=>{
833
+ if (!api) return;
834
+ onInit(api);
835
+ onSelect(api);
836
+ api.on('reInit', onInit).on('reInit', onSelect).on('select', onSelect);
837
+ }, [
838
+ api,
839
+ onInit,
840
+ onSelect
841
+ ]);
842
+ return {
843
+ selectedIndex,
844
+ scrollSnaps,
845
+ onDotButtonClick
846
+ };
847
+ };
848
+ const Dots = ({ api, orientation })=>{
849
+ const { selectedIndex, scrollSnaps, onDotButtonClick } = useLogic(api);
850
+ return /*#__PURE__*/ jsx("div", {
851
+ className: styles_css_wrapper[orientation],
852
+ children: scrollSnaps.map((number, index)=>/*#__PURE__*/ jsx("button", {
853
+ type: "button",
854
+ className: clsx(dotButton[orientation], {
855
+ [styles_css_selected]: index === selectedIndex
856
+ }),
857
+ onClick: ()=>onDotButtonClick(index)
858
+ }, number))
859
+ });
860
+ };
861
+ var Item_styles_css_item = 'style__1gif6yr0';
862
+ function Item_Item(props) {
863
+ return /*#__PURE__*/ jsx("div", {
864
+ className: Item_styles_css_item,
865
+ role: "presentation",
866
+ "aria-roledescription": "slide",
867
+ "data-slot": "carousel-item",
868
+ ...props
869
+ });
870
+ }
871
+ var styles_css_rootClass = 'Carousel__1jbydv50';
872
+ const useLogic_useLogic = ({ orientation = 'horizontal', opts, setApi, plugins, data, showDots, showArrows })=>{
873
+ const [carouselRef, api] = embla_carousel_react({
874
+ ...opts,
875
+ axis: 'horizontal' === orientation ? 'x' : 'y'
876
+ }, plugins);
877
+ const [canScrollPrev, setCanScrollPrev] = useState(false);
878
+ const [canScrollNext, setCanScrollNext] = useState(false);
879
+ const isShowButtons = Boolean(showArrows && data.length > 1);
880
+ const isShowDots = Boolean(showDots && data.length > 1);
881
+ const onSelect = useCallback((api)=>{
882
+ if (!api) return;
883
+ setCanScrollPrev(api.canScrollPrev());
884
+ setCanScrollNext(api.canScrollNext());
885
+ }, []);
886
+ const onDotButtonClick = useCallback((index)=>{
887
+ if (!api) return;
888
+ api.scrollTo(index);
889
+ }, [
890
+ api
891
+ ]);
892
+ const scrollPrev = useCallback(()=>{
893
+ api?.scrollPrev();
894
+ }, [
895
+ api
896
+ ]);
897
+ const scrollNext = useCallback(()=>{
898
+ api?.scrollNext();
899
+ }, [
900
+ api
901
+ ]);
902
+ const handleKeyDown = useCallback((event)=>{
903
+ if ('ArrowLeft' === event.key) {
904
+ event.preventDefault();
905
+ scrollPrev();
906
+ } else if ('ArrowRight' === event.key) {
907
+ event.preventDefault();
908
+ scrollNext();
909
+ }
910
+ }, [
911
+ scrollPrev,
912
+ scrollNext
913
+ ]);
914
+ useEffect(()=>{
915
+ if (!api || !setApi) return;
916
+ setApi(api);
917
+ }, [
918
+ api,
919
+ setApi
920
+ ]);
921
+ useEffect(()=>{
922
+ if (!api) return;
923
+ onSelect(api);
924
+ api.on('reInit', onSelect);
925
+ api.on('select', onSelect);
926
+ return ()=>{
927
+ api?.off('select', onSelect);
928
+ };
929
+ }, [
930
+ api,
931
+ onSelect
932
+ ]);
933
+ return {
934
+ carouselRef,
935
+ api,
936
+ scrollPrev,
937
+ scrollNext,
938
+ canScrollPrev,
939
+ canScrollNext,
940
+ handleKeyDown,
941
+ opts,
942
+ orientation,
943
+ onDotButtonClick,
944
+ isShowButtons,
945
+ isShowDots,
946
+ data
947
+ };
948
+ };
949
+ function Carousel({ width = '100%', height = '100%', ...props }) {
950
+ const { canScrollNext, canScrollPrev, scrollNext, scrollPrev, api, opts, orientation, carouselRef, handleKeyDown, data, isShowButtons, isShowDots } = useLogic_useLogic(props);
951
+ return /*#__PURE__*/ jsx(CarouselContext.Provider, {
952
+ value: {
953
+ carouselRef,
954
+ api,
955
+ opts,
956
+ orientation: orientation || (opts?.axis === 'y' ? 'vertical' : 'horizontal'),
957
+ scrollPrev,
958
+ scrollNext,
959
+ canScrollPrev,
960
+ canScrollNext
961
+ },
962
+ children: /*#__PURE__*/ jsxs("div", {
963
+ onKeyDownCapture: handleKeyDown,
964
+ className: clsx(styles_css_rootClass, props.className),
965
+ "data-slot": "carousel",
966
+ style: {
967
+ width,
968
+ height
969
+ },
970
+ children: [
971
+ /*#__PURE__*/ jsx(Content_Content, {
972
+ style: {
973
+ width,
974
+ height
975
+ },
976
+ children: data.map((item)=>/*#__PURE__*/ jsx(Item_Item, {
977
+ children: props.renderItem(item)
978
+ }, `${item[props.keyId]}`))
979
+ }),
980
+ isShowButtons && /*#__PURE__*/ jsx(Buttons, {}),
981
+ isShowDots && /*#__PURE__*/ jsx(Dots, {
982
+ api: api,
983
+ orientation: orientation
984
+ })
985
+ ]
986
+ })
987
+ });
988
+ }
989
+ var checkbox_css_icon = 'style__b7yo4k2';
990
+ var indicator = 'style__b7yo4k1';
991
+ var checkbox_css_root = 'style__b7yo4k0';
992
+ const Checkbox_Checkbox = ({ className, ...props })=>/*#__PURE__*/ jsx(Checkbox.Root, {
993
+ "data-slot": "checkbox",
994
+ className: clsx(checkbox_css_root, className),
995
+ ...props,
996
+ children: /*#__PURE__*/ jsx(Checkbox.Indicator, {
997
+ className: indicator,
998
+ children: /*#__PURE__*/ jsx(Check, {
999
+ className: checkbox_css_icon
1000
+ })
1001
+ })
1002
+ });
1003
+ var circle = 'style__m6b9n24';
1004
+ var styles_css_colors = {
1005
+ primary: 'primary__m6b9n27',
1006
+ secondary: 'secondary__m6b9n28',
1007
+ inherit: 'inherit__m6b9n29'
1008
+ };
1009
+ var CircularProgress_styles_css_root = 'style__m6b9n22';
1010
+ var svg = 'style__m6b9n23';
1011
+ var styles_css_variants = {
1012
+ determinate: 'determinate__m6b9n25',
1013
+ indeterminate: 'indeterminate__m6b9n26'
1014
+ };
1015
+ const CircularProgress = ({ size = 30, thickness = 2.6, color = 'primary', value = 0, variant = 'indeterminate', className })=>{
1016
+ const radius = (size - thickness) / 2;
1017
+ const circumference = 2 * Math.PI * radius;
1018
+ const dashOffset = 'determinate' === variant ? circumference * (1 - value / 100) : 0.25 * circumference;
1019
+ return /*#__PURE__*/ jsx("div", {
1020
+ className: clsx_0(CircularProgress_styles_css_root, styles_css_variants[variant], styles_css_colors[color], className),
1021
+ style: {
1022
+ width: size,
1023
+ height: size
1024
+ },
1025
+ children: /*#__PURE__*/ jsxs("svg", {
1026
+ className: svg,
1027
+ viewBox: `0 0 ${size} ${size}`,
1028
+ children: [
1029
+ /*#__PURE__*/ jsx("title", {
1030
+ children: "Progress bar"
1031
+ }),
1032
+ /*#__PURE__*/ jsx("circle", {
1033
+ className: clsx_0(circle, 'determinate' === variant && styles_css_variants.determinate),
1034
+ cx: size / 2,
1035
+ cy: size / 2,
1036
+ r: radius,
1037
+ fill: "none",
1038
+ strokeWidth: thickness,
1039
+ strokeDasharray: circumference,
1040
+ strokeDashoffset: dashOffset
1041
+ })
1042
+ ]
1043
+ })
1044
+ });
1045
+ };
1046
+ function Collapsible_Collapsible({ ...props }) {
1047
+ return /*#__PURE__*/ jsx(Collapsible.Root, {
1048
+ "data-slot": "collapsible",
1049
+ ...props
1050
+ });
1051
+ }
1052
+ function Collapsible_Trigger({ ...props }) {
1053
+ return /*#__PURE__*/ jsx(Collapsible.Trigger, {
1054
+ "data-slot": "collapsible-trigger",
1055
+ ...props
1056
+ });
1057
+ }
1058
+ function Collapsible_Content({ ...props }) {
1059
+ return /*#__PURE__*/ jsx(Collapsible.Panel, {
1060
+ "data-slot": "collapsible-content",
1061
+ ...props
1062
+ });
1063
+ }
1064
+ Collapsible_Collapsible.Trigger = Collapsible_Trigger;
1065
+ Collapsible_Collapsible.Content = Collapsible_Content;
1066
+ var Popover_styles_css_content = 'style__1xy4jvu2';
1067
+ var positioner = 'style__1xy4jvu3';
1068
+ const createHandle = Popover.createHandle;
1069
+ const Popover_Popover = ({ ...props })=>/*#__PURE__*/ jsx(Popover.Root, {
1070
+ "data-slot": "popover",
1071
+ ...props
1072
+ });
1073
+ const Popover_Trigger = ({ ...props })=>/*#__PURE__*/ jsx(Popover.Trigger, {
1074
+ "data-slot": "popover-trigger",
1075
+ ...props
1076
+ });
1077
+ const Popover_Content = ({ className, align = 'center', alignOffset = 0, side = 'bottom', sideOffset = 4, ...props })=>/*#__PURE__*/ jsx(Popover.Portal, {
1078
+ children: /*#__PURE__*/ jsx(Popover.Positioner, {
1079
+ align: align,
1080
+ alignOffset: alignOffset,
1081
+ side: side,
1082
+ sideOffset: sideOffset,
1083
+ className: positioner,
1084
+ children: /*#__PURE__*/ jsx(Popover.Popup, {
1085
+ "data-slot": "popover-content",
1086
+ className: clsx(Popover_styles_css_content, className),
1087
+ ...props
1088
+ })
1089
+ })
1090
+ });
1091
+ Popover_Popover.Trigger = Popover_Trigger;
1092
+ Popover_Popover.Content = Popover_Content;
1093
+ Popover_Popover.Root = Popover_Popover;
1094
+ var actionsClass = 'style__1q1uhgp0';
1095
+ var hasTextClass = 'style__1q1uhgp3';
1096
+ var popoverClass = 'style__1q1uhgp2';
1097
+ var wrapperClass = 'style__1q1uhgp1';
1098
+ const ConfirmAction_useLogic_useLogic = ({ skipConfirm, onConfirm, confirmButtonProps: externalConfirmButtonProps })=>{
1099
+ const [open, setOpen] = useState(false);
1100
+ const handleConfirm = ()=>{
1101
+ setOpen(false);
1102
+ onConfirm();
1103
+ };
1104
+ const confirmButtonProps = {
1105
+ variant: externalConfirmButtonProps?.isAccented ? 'destructive' : 'default',
1106
+ size: 'sm',
1107
+ onClick: handleConfirm
1108
+ };
1109
+ const onActionComponentClick = ()=>{
1110
+ if (skipConfirm) onConfirm();
1111
+ else setOpen(true);
1112
+ };
1113
+ const onOpenChange = (open)=>{
1114
+ setOpen(open);
1115
+ };
1116
+ const onCancel = ()=>{
1117
+ setOpen(false);
1118
+ };
1119
+ return {
1120
+ open,
1121
+ onActionComponentClick,
1122
+ confirmButtonProps,
1123
+ onCancel,
1124
+ onOpenChange
1125
+ };
1126
+ };
1127
+ const ConfirmAction = (props)=>{
1128
+ const { open, onActionComponentClick, onCancel, confirmButtonProps, onOpenChange } = ConfirmAction_useLogic_useLogic(props);
1129
+ const { text, confirmButtonProps: externalConfirmButtonProps, popoverProps: externalPopoverProps, actionComponent } = props;
1130
+ const { text: confirmButtonText = 'Подтвердить' } = externalConfirmButtonProps || {};
1131
+ const { side = 'bottom', align = 'center' } = externalPopoverProps || {};
1132
+ return /*#__PURE__*/ jsxs(Popover_Popover, {
1133
+ open: open,
1134
+ onOpenChange: onOpenChange,
1135
+ children: [
1136
+ /*#__PURE__*/ jsx(Popover_Popover.Trigger, {
1137
+ children: actionComponent({
1138
+ onClick: onActionComponentClick
1139
+ })
1140
+ }),
1141
+ /*#__PURE__*/ jsx(Popover_Popover.Content, {
1142
+ side: side,
1143
+ align: align,
1144
+ className: clsx(popoverClass, {
1145
+ [hasTextClass]: Boolean(text)
1146
+ }),
1147
+ children: /*#__PURE__*/ jsxs("div", {
1148
+ className: wrapperClass,
1149
+ children: [
1150
+ text && /*#__PURE__*/ jsx(Typography, {
1151
+ children: text
1152
+ }),
1153
+ /*#__PURE__*/ jsxs("div", {
1154
+ className: actionsClass,
1155
+ children: [
1156
+ /*#__PURE__*/ jsx(Button_Button, {
1157
+ size: "sm",
1158
+ variant: "ghost",
1159
+ onClick: onCancel,
1160
+ children: "Отмена"
1161
+ }),
1162
+ /*#__PURE__*/ jsx(Button_Button, {
1163
+ ...confirmButtonProps,
1164
+ children: confirmButtonText
1165
+ })
1166
+ ]
1167
+ })
1168
+ ]
1169
+ })
1170
+ })
1171
+ ]
1172
+ });
1173
+ };
1174
+ var sizes = {
1175
+ sm: 'sm__1o97kvm1',
1176
+ md: 'md__1o97kvm2',
1177
+ lg: 'lg__1o97kvm3'
1178
+ };
1179
+ var Image_styles_css_wrapper = 'style__1o97kvm0';
1180
+ const Image_Image = (props)=>/*#__PURE__*/ jsx("img", {
1181
+ alt: props.alt,
1182
+ src: props.src,
1183
+ className: clsx_0(Image_styles_css_wrapper, sizes[props.size || 'md'], props.className),
1184
+ width: props.width,
1185
+ height: props.height
1186
+ });
1187
+ const SIZE = {
1188
+ sm: 'sm',
1189
+ md: 'md',
1190
+ lg: 'lg'
1191
+ };
1192
+ const IMAGE_WIDTH = {
1193
+ [SIZE.sm]: '239px',
1194
+ [SIZE.md]: '323px',
1195
+ [SIZE.lg]: '458px'
1196
+ };
1197
+ const IMAGE_HEIGHT = {
1198
+ [SIZE.sm]: '119px',
1199
+ [SIZE.md]: '161px',
1200
+ [SIZE.lg]: '229px'
1201
+ };
1202
+ const MAX_INNER_WIDTH = {
1203
+ [SIZE.sm]: '384px',
1204
+ [SIZE.md]: '400px',
1205
+ [SIZE.lg]: '460px'
1206
+ };
1207
+ const TITLE_HEADER_LEVEL = {
1208
+ [SIZE.sm]: 'subtitle1',
1209
+ [SIZE.md]: 'h6',
1210
+ [SIZE.lg]: 'h5'
1211
+ };
1212
+ var descriptionClass = 'style__1nenzg05';
1213
+ var footerClass = 'style__1nenzg06';
1214
+ var innerContainer = 'style__1nenzg04';
1215
+ var styles_css_sizes = {
1216
+ sm: 'sm__1nenzg01',
1217
+ md: 'md__1nenzg02',
1218
+ lg: 'lg__1nenzg03'
1219
+ };
1220
+ var Placeholder_styles_css_wrapper = 'style__1nenzg00';
1221
+ const Placeholder = ({ className, title, imgSrc, imgAlt, description, actions, size = 'sm', renderImage })=>{
1222
+ const RenderImage = useMemo(()=>renderImage || Image_Image, [
1223
+ renderImage
1224
+ ]);
1225
+ return /*#__PURE__*/ jsxs("div", {
1226
+ className: clsx_0(Placeholder_styles_css_wrapper, styles_css_sizes[size], className),
1227
+ children: [
1228
+ /*#__PURE__*/ jsxs("div", {
1229
+ className: innerContainer,
1230
+ style: {
1231
+ maxWidth: MAX_INNER_WIDTH[size]
1232
+ },
1233
+ children: [
1234
+ imgSrc && /*#__PURE__*/ jsx(RenderImage, {
1235
+ src: imgSrc,
1236
+ alt: imgAlt,
1237
+ width: IMAGE_WIDTH[size],
1238
+ height: IMAGE_HEIGHT[size],
1239
+ size: size
1240
+ }),
1241
+ /*#__PURE__*/ jsx(Typography, {
1242
+ align: "center",
1243
+ color: "secondary",
1244
+ variant: TITLE_HEADER_LEVEL[size],
1245
+ children: title
1246
+ }),
1247
+ description && /*#__PURE__*/ jsx(Typography, {
1248
+ className: descriptionClass,
1249
+ component: "div",
1250
+ variant: "body1",
1251
+ children: description
1252
+ })
1253
+ ]
1254
+ }),
1255
+ actions && /*#__PURE__*/ jsx("footer", {
1256
+ className: footerClass,
1257
+ children: actions
1258
+ })
1259
+ ]
1260
+ });
1261
+ };
1262
+ var loadingContainer = 'style__nan0ao0';
1263
+ const ContentState = ({ isLoading, isError, isCustom, errorState, customState, children, loadingContent: LoadingContent = /*#__PURE__*/ jsx(CircularProgress, {
1264
+ color: "primary"
1265
+ }) })=>{
1266
+ if (isLoading) return /*#__PURE__*/ jsx("div", {
1267
+ className: loadingContainer,
1268
+ children: LoadingContent
1269
+ });
1270
+ if (isCustom && customState) return /*#__PURE__*/ jsx(Placeholder, {
1271
+ ...customState
1272
+ });
1273
+ if (isError && errorState) {
1274
+ const { title = 'Произошла ошибка', imgAlt, imgSrc, errorList, onRetry, actions = /*#__PURE__*/ jsx(Button_Button, {
1275
+ onClick: onRetry,
1276
+ children: "Попробовать снова"
1277
+ }) } = errorState;
1278
+ const description = errorList.map((errorMessage)=>/*#__PURE__*/ jsx(Typography, {
1279
+ component: "p",
1280
+ children: errorMessage
1281
+ }, errorMessage));
1282
+ return /*#__PURE__*/ jsx(Placeholder, {
1283
+ title: title,
1284
+ description: description,
1285
+ imgAlt: imgAlt,
1286
+ imgSrc: imgSrc,
1287
+ actions: actions
1288
+ });
1289
+ }
1290
+ return children;
1291
+ };
1292
+ var arrowClass = 'style__izacrl4';
1293
+ var contentClass = 'style__izacrl2';
1294
+ var textClass = 'style__izacrl3';
1295
+ const TooltipProvider = Provider;
1296
+ const TooltipRoot = Root;
1297
+ const TooltipTrigger = react_tooltip_Trigger;
1298
+ const TooltipContent = ({ sideOffset = 4, alignOffset, ref, ...props })=>/*#__PURE__*/ jsx(react_tooltip_Content, {
1299
+ ref: ref,
1300
+ sideOffset: sideOffset,
1301
+ ...props
1302
+ });
1303
+ const Tooltip = ({ text, content, children, side = 'top', sideOffset = 10, alignOffset, delayDuration = 0, className, ref, ...props })=>/*#__PURE__*/ jsx(TooltipProvider, {
1304
+ delayDuration: delayDuration,
1305
+ children: /*#__PURE__*/ jsxs(TooltipRoot, {
1306
+ ...props,
1307
+ children: [
1308
+ /*#__PURE__*/ jsx(TooltipTrigger, {
1309
+ ref: ref,
1310
+ asChild: true,
1311
+ children: children
1312
+ }),
1313
+ content || text ? /*#__PURE__*/ jsx(react_tooltip_Portal, {
1314
+ children: /*#__PURE__*/ jsxs(TooltipContent, {
1315
+ className: clsx_0(contentClass, className),
1316
+ alignOffset: alignOffset,
1317
+ sideOffset: sideOffset,
1318
+ hideWhenDetached: true,
1319
+ side: side,
1320
+ children: [
1321
+ content ?? /*#__PURE__*/ jsx("p", {
1322
+ className: textClass,
1323
+ children: text
1324
+ }),
1325
+ props.arrow && /*#__PURE__*/ jsx(Arrow, {
1326
+ className: arrowClass
1327
+ })
1328
+ ]
1329
+ })
1330
+ }) : null
1331
+ ]
1332
+ })
1333
+ });
1334
+ var copyIconClass = 'style__1wpx85c1';
1335
+ var CopyTypography_styles_css_wrapper = 'style__1wpx85c0';
1336
+ const useLogic_useLogic_useLogic = ({ children, copyText, isShowCopyText, copyPosition })=>{
1337
+ const [status, setStatus] = useState("Скопировать");
1338
+ const [tooltipOpen, setTooltipOpen] = useState(false);
1339
+ const handleMouseEnter = ()=>{
1340
+ setTooltipOpen(true);
1341
+ };
1342
+ const handleMouseLeave = ()=>{
1343
+ if ("Скопировать" !== status) setTimeout(()=>{
1344
+ setStatus("Скопировать");
1345
+ }, 100);
1346
+ setTooltipOpen(false);
1347
+ };
1348
+ const handleClick = (event)=>{
1349
+ event.stopPropagation();
1350
+ navigator.clipboard.writeText(copyText || ('string' == typeof children ? children : '')).then(()=>setStatus("Скопировано")).catch(()=>setStatus("Ошибка копирования"));
1351
+ };
1352
+ const tooltipTitle = isShowCopyText ? `${status}: ${copyText}` : status;
1353
+ const isIconOnLeft = 'left' === copyPosition;
1354
+ return {
1355
+ handleMouseLeave,
1356
+ handleClick,
1357
+ tooltipTitle,
1358
+ isIconOnLeft,
1359
+ tooltipOpen,
1360
+ handleMouseEnter
1361
+ };
1362
+ };
1363
+ const CopyTypography = (props)=>{
1364
+ const { children, copyPosition = 'right', copyText, isShowCopyText, color, className, ...restProps } = props;
1365
+ const renderIcon = ()=>/*#__PURE__*/ jsx(Copy, {
1366
+ className: copyIconClass
1367
+ });
1368
+ const { tooltipOpen, handleMouseEnter, handleMouseLeave, handleClick, tooltipTitle, isIconOnLeft } = useLogic_useLogic_useLogic(props);
1369
+ return /*#__PURE__*/ jsx(Tooltip, {
1370
+ open: tooltipOpen,
1371
+ arrow: true,
1372
+ text: tooltipTitle,
1373
+ side: "bottom",
1374
+ children: /*#__PURE__*/ jsxs(Typography, {
1375
+ onMouseLeave: handleMouseLeave,
1376
+ onMouseEnter: handleMouseEnter,
1377
+ onClick: handleClick,
1378
+ component: "div",
1379
+ color: color,
1380
+ className: clsx(CopyTypography_styles_css_wrapper, className),
1381
+ ...restProps,
1382
+ children: [
1383
+ isIconOnLeft && renderIcon(),
1384
+ children,
1385
+ !isIconOnLeft && renderIcon()
1386
+ ]
1387
+ })
1388
+ });
1389
+ };
1390
+ const DashboardContext = createContext({
1391
+ pinned: true,
1392
+ hovered: false,
1393
+ togglePinned: ()=>{}
1394
+ });
1395
+ const useDashboard = ()=>useContext(DashboardContext);
1396
+ const LOCAL_STORAGE_KEY = 'dashboard::pinned';
1397
+ const hooks_useLogic_useLogic = ()=>{
1398
+ const [pinned, setPinned] = useState('true' === window.localStorage.getItem(LOCAL_STORAGE_KEY));
1399
+ const togglePinned = ()=>{
1400
+ setPinned(!pinned);
1401
+ window.localStorage.setItem(LOCAL_STORAGE_KEY, String(!pinned));
1402
+ };
1403
+ return {
1404
+ pinned,
1405
+ togglePinned
1406
+ };
1407
+ };
1408
+ var Main_styles_css_rootClass = 'style__whkxou0';
1409
+ const Main = ({ children, className })=>/*#__PURE__*/ jsx("main", {
1410
+ className: clsx(Main_styles_css_rootClass, className),
1411
+ children: children
1412
+ });
1413
+ var styles_css_contentClass = 'SidebarContent__1low90p6';
1414
+ var styles_css_footerClass = 'SidebarFooter__1low90p5';
1415
+ var headerClass = 'SidebarHeader__1low90p4';
1416
+ var Sidebar_styles_css_rootClass = 'SidebarContainer__1low90p2';
1417
+ var triggerClass = 'SidebarTrigger__1low90p1';
1418
+ var unpinnedClass = 'style__1low90p3';
1419
+ var styles_css_wrapperClass = 'style__1low90p0';
1420
+ const Sidebar = ({ width = "16rem", header, footer, content, className })=>{
1421
+ const { pinned } = useDashboard();
1422
+ return /*#__PURE__*/ jsxs("div", {
1423
+ style: {
1424
+ width: pinned ? width : 0
1425
+ },
1426
+ className: styles_css_wrapperClass,
1427
+ children: [
1428
+ /*#__PURE__*/ jsx("span", {
1429
+ className: triggerClass
1430
+ }),
1431
+ /*#__PURE__*/ jsxs("aside", {
1432
+ style: {
1433
+ width
1434
+ },
1435
+ className: clsx(Sidebar_styles_css_rootClass, {
1436
+ [unpinnedClass]: !pinned
1437
+ }, className),
1438
+ children: [
1439
+ header && /*#__PURE__*/ jsx("header", {
1440
+ className: headerClass,
1441
+ children: header
1442
+ }),
1443
+ /*#__PURE__*/ jsx("div", {
1444
+ className: styles_css_contentClass,
1445
+ children: content
1446
+ }),
1447
+ footer && /*#__PURE__*/ jsx("footer", {
1448
+ className: styles_css_footerClass,
1449
+ children: footer
1450
+ })
1451
+ ]
1452
+ })
1453
+ ]
1454
+ });
1455
+ };
1456
+ var containerClass = 'DashboardLayout__113u7x50';
1457
+ const DashboardLayout = ({ children, className })=>{
1458
+ const { pinned, togglePinned } = hooks_useLogic_useLogic();
1459
+ return /*#__PURE__*/ jsx(DashboardContext.Provider, {
1460
+ value: {
1461
+ pinned,
1462
+ togglePinned
1463
+ },
1464
+ children: /*#__PURE__*/ jsx("div", {
1465
+ className: clsx(containerClass, className),
1466
+ children: children
1467
+ })
1468
+ });
1469
+ };
1470
+ DashboardLayout.Sidebar = Sidebar;
1471
+ DashboardLayout.Main = Main;
1472
+ var cellClass = 'style__1047swj0';
1473
+ var disabledClass = 'style__1047swj1';
1474
+ function Cell({ row, column, rowIndex, height }) {
1475
+ const { align, cellColor, isDisabled } = column;
1476
+ const Content = ()=>{
1477
+ if (column.renderCell) return column.renderCell(row, rowIndex);
1478
+ if (column.format) return column.format(row) || '—';
1479
+ if (column.field) return `${row[column.field] || '—'}`;
1480
+ return '—';
1481
+ };
1482
+ return /*#__PURE__*/ jsx("td", {
1483
+ align: align ?? 'left',
1484
+ style: {
1485
+ backgroundColor: cellColor?.(row),
1486
+ height,
1487
+ width: column.width
1488
+ },
1489
+ className: clsx(cellClass, {
1490
+ [disabledClass]: isDisabled
1491
+ }, column.cellClassName?.(row)),
1492
+ children: /*#__PURE__*/ jsx(Content, {})
1493
+ });
1494
+ }
1495
+ var rowClass = 'style__gsm9mv0';
1496
+ var selectableClass = 'style__gsm9mv1';
1497
+ function Row({ row, rowHeight, onRowClick, columns, rowIndex, rowId }) {
1498
+ const handleSelect = useCallback(()=>{
1499
+ onRowClick?.(row);
1500
+ }, [
1501
+ onRowClick,
1502
+ row
1503
+ ]);
1504
+ return /*#__PURE__*/ jsx("tr", {
1505
+ onClick: handleSelect,
1506
+ onKeyDown: handleSelect,
1507
+ className: clsx(rowClass, {
1508
+ [selectableClass]: Boolean(onRowClick)
1509
+ }),
1510
+ children: columns.map((column, index)=>{
1511
+ const cellId = `${rowId}-${index}`;
1512
+ return /*#__PURE__*/ jsx(Cell, {
1513
+ row: row,
1514
+ rowIndex: rowIndex,
1515
+ column: column,
1516
+ height: rowHeight
1517
+ }, cellId);
1518
+ })
1519
+ });
1520
+ }
1521
+ var container = 'style__15m2ib80';
1522
+ var loader = 'style__15m2ib81';
1523
+ function State({ isLoading, isEmpty, columnsLength, emptyState = {
1524
+ text: 'Нет данных'
1525
+ }, errorState = {
1526
+ text: 'Произошла ошибка'
1527
+ }, isError, onRetry }) {
1528
+ const Container = ({ children })=>/*#__PURE__*/ jsx("tr", {
1529
+ className: container,
1530
+ children: /*#__PURE__*/ jsx("td", {
1531
+ colSpan: columnsLength,
1532
+ align: "center",
1533
+ children: children
1534
+ })
1535
+ });
1536
+ if (isLoading) return /*#__PURE__*/ jsx(Container, {
1537
+ children: /*#__PURE__*/ jsx("span", {
1538
+ className: loader,
1539
+ children: /*#__PURE__*/ jsx(CircularProgress, {})
1540
+ })
1541
+ });
1542
+ if (isEmpty) {
1543
+ const { imgSrc, imgAlt, text } = emptyState;
1544
+ return /*#__PURE__*/ jsx(Container, {
1545
+ children: /*#__PURE__*/ jsx(Placeholder, {
1546
+ title: text,
1547
+ imgSrc: imgSrc,
1548
+ imgAlt: imgAlt
1549
+ })
1550
+ });
1551
+ }
1552
+ if (isError) {
1553
+ const { imgSrc, imgAlt, text } = errorState;
1554
+ return /*#__PURE__*/ jsx(Container, {
1555
+ children: /*#__PURE__*/ jsx(Placeholder, {
1556
+ title: text,
1557
+ imgSrc: imgSrc,
1558
+ imgAlt: imgAlt,
1559
+ actions: onRetry ? /*#__PURE__*/ jsx(Button_Button, {
1560
+ variant: "outline",
1561
+ onClick: onRetry,
1562
+ children: "Попробовать снова"
1563
+ }) : void 0
1564
+ })
1565
+ });
1566
+ }
1567
+ return null;
1568
+ }
1569
+ var styles_css_container = 'style__82af400';
1570
+ function Body({ isError, isLoading, emptyState, errorState, columns, rows, rowHeight, keyId, onRowClick }) {
1571
+ const isEmpty = 0 === rows.length;
1572
+ const isStateVisible = isError || isLoading || isEmpty;
1573
+ return isStateVisible ? /*#__PURE__*/ jsx("tbody", {
1574
+ className: styles_css_container,
1575
+ children: /*#__PURE__*/ jsx(State, {
1576
+ emptyState: emptyState,
1577
+ errorState: errorState,
1578
+ isEmpty: isEmpty,
1579
+ isError: isError,
1580
+ isLoading: isLoading,
1581
+ columnsLength: columns.length
1582
+ })
1583
+ }) : /*#__PURE__*/ jsx("tbody", {
1584
+ className: styles_css_container,
1585
+ children: rows.map((row, index)=>{
1586
+ const rowId = String(row[keyId]);
1587
+ return /*#__PURE__*/ jsx(Row, {
1588
+ row: row,
1589
+ rowId: rowId,
1590
+ rowHeight: rowHeight,
1591
+ columns: columns,
1592
+ onRowClick: onRowClick,
1593
+ rowIndex: index
1594
+ }, row[keyId]);
1595
+ })
1596
+ });
1597
+ }
1598
+ var Footer_styles_css_footerClass = 'style__2s55b60';
1599
+ function Footer_Footer({ children, className }) {
1600
+ return /*#__PURE__*/ jsx("footer", {
1601
+ className: clsx(Footer_styles_css_footerClass, className),
1602
+ children: children
1603
+ });
1604
+ }
1605
+ var headerCellClass = 'style__uma6hu0';
1606
+ function HeaderCell({ column, height, width }) {
1607
+ return /*#__PURE__*/ jsx("th", {
1608
+ style: {
1609
+ color: column.color,
1610
+ height,
1611
+ width
1612
+ },
1613
+ align: column.align ?? 'left',
1614
+ title: column.title,
1615
+ className: headerCellClass,
1616
+ children: column.renderHeaderCell?.(column) || column.title
1617
+ });
1618
+ }
1619
+ var stickyClass = 'style__fkgoub0';
1620
+ function Header_Header({ columns, height, sticky }) {
1621
+ return /*#__PURE__*/ jsx("thead", {
1622
+ children: /*#__PURE__*/ jsx("tr", {
1623
+ className: clsx({
1624
+ [stickyClass]: sticky
1625
+ }),
1626
+ children: columns.map((col)=>/*#__PURE__*/ jsx(HeaderCell, {
1627
+ column: col,
1628
+ height: height,
1629
+ width: col.width
1630
+ }, col.title))
1631
+ })
1632
+ });
1633
+ }
1634
+ var DataGrid_styles_css_container = 'style__1gqvluf0';
1635
+ var styles_css_disabled = 'style__1gqvluf3';
1636
+ var fullHeight = 'style__1gqvluf2';
1637
+ var styles_css_loading = 'style__1gqvluf4';
1638
+ var table = 'style__1gqvluf1';
1639
+ var titleClass = 'style__1gqvluf5';
1640
+ function DataGrid({ rows, columns, height = '100%', className, rowHeight = 40, headerHeight = 40, keyId, onRowClick, isLoading, isDisabled, isError, emptyState, errorState, footer, title, stickyHeader, onRetry }) {
1641
+ const isFullHeight = isLoading || isError || 0 === rows.length;
1642
+ return /*#__PURE__*/ jsxs("div", {
1643
+ "data-slot": "data-grid",
1644
+ style: {
1645
+ height
1646
+ },
1647
+ className: clsx(DataGrid_styles_css_container, className),
1648
+ children: [
1649
+ /*#__PURE__*/ jsxs("table", {
1650
+ className: clsx(table, {
1651
+ [styles_css_disabled]: isDisabled,
1652
+ [styles_css_loading]: isLoading,
1653
+ [fullHeight]: isFullHeight
1654
+ }, className),
1655
+ children: [
1656
+ title && /*#__PURE__*/ jsx("caption", {
1657
+ className: titleClass,
1658
+ children: title
1659
+ }),
1660
+ /*#__PURE__*/ jsx(Header_Header, {
1661
+ columns: columns,
1662
+ height: headerHeight,
1663
+ sticky: stickyHeader
1664
+ }),
1665
+ /*#__PURE__*/ jsx(Body, {
1666
+ rows: rows,
1667
+ columns: columns,
1668
+ rowHeight: rowHeight,
1669
+ keyId: keyId,
1670
+ onRowClick: onRowClick,
1671
+ isLoading: isLoading,
1672
+ emptyState: emptyState,
1673
+ errorState: errorState,
1674
+ isError: isError,
1675
+ onRetry: onRetry
1676
+ })
1677
+ ]
1678
+ }),
1679
+ footer && /*#__PURE__*/ jsx(Footer_Footer, {
1680
+ children: footer
1681
+ })
1682
+ ]
1683
+ });
1684
+ }
1685
+ var checkboxItem = 'style__1ib8wktd style__1ib8wkta';
1686
+ var DropdownMenu_styles_css_content = 'style__1ib8wkt7';
1687
+ var styles_css_icon = 'style__1ib8wkth';
1688
+ var DropdownMenu_styles_css_item = 'style__1ib8wkta';
1689
+ var itemIndicator = 'style__1ib8wktf';
1690
+ var styles_css_label = 'style__1ib8wkt9';
1691
+ var styles_css_positioner = 'style__1ib8wkt6';
1692
+ var radioItem = 'style__1ib8wkte style__1ib8wkta';
1693
+ var DropdownMenu_styles_css_separator = 'style__1ib8wkti';
1694
+ var shortcut = 'style__1ib8wktj';
1695
+ var subContent = 'style__1ib8wkt8';
1696
+ var subTrigger = 'style__1ib8wktc style__1ib8wkta';
1697
+ var subTriggerIcon = 'style__1ib8wktg';
1698
+ function DropdownMenu({ ...props }) {
1699
+ return /*#__PURE__*/ jsx(Menu.Root, {
1700
+ "data-slot": "dropdown-menu",
1701
+ ...props
1702
+ });
1703
+ }
1704
+ function DropdownMenu_Portal({ ...props }) {
1705
+ return /*#__PURE__*/ jsx(Menu.Portal, {
1706
+ "data-slot": "dropdown-menu-portal",
1707
+ ...props
1708
+ });
1709
+ }
1710
+ function DropdownMenu_Trigger({ ...props }) {
1711
+ return /*#__PURE__*/ jsx(Menu.Trigger, {
1712
+ "data-slot": "dropdown-menu-trigger",
1713
+ ...props
1714
+ });
1715
+ }
1716
+ function DropdownMenu_Content({ align = 'start', alignOffset = 0, side = 'bottom', sideOffset = 4, className, ...props }) {
1717
+ return /*#__PURE__*/ jsx(Menu.Portal, {
1718
+ children: /*#__PURE__*/ jsx(Menu.Positioner, {
1719
+ align: align,
1720
+ alignOffset: alignOffset,
1721
+ side: side,
1722
+ sideOffset: sideOffset,
1723
+ className: styles_css_positioner,
1724
+ children: /*#__PURE__*/ jsx(Menu.Popup, {
1725
+ "data-slot": "dropdown-menu-content",
1726
+ className: clsx(DropdownMenu_styles_css_content, className),
1727
+ ...props
1728
+ })
1729
+ })
1730
+ });
1731
+ }
1732
+ function DropdownMenu_Group({ ...props }) {
1733
+ return /*#__PURE__*/ jsx(Menu.Group, {
1734
+ "data-slot": "dropdown-menu-group",
1735
+ ...props
1736
+ });
1737
+ }
1738
+ function Label({ className, inset, ...props }) {
1739
+ return /*#__PURE__*/ jsx(Menu.GroupLabel, {
1740
+ "data-slot": "dropdown-menu-label",
1741
+ "data-inset": inset ? '' : void 0,
1742
+ className: clsx(styles_css_label, className),
1743
+ ...props
1744
+ });
1745
+ }
1746
+ function DropdownMenu_Item({ className, inset, variant = 'default', ...props }) {
1747
+ return /*#__PURE__*/ jsx(Menu.Item, {
1748
+ "data-slot": "dropdown-menu-item",
1749
+ "data-inset": inset ? '' : void 0,
1750
+ "data-variant": variant,
1751
+ className: clsx(DropdownMenu_styles_css_item, className),
1752
+ ...props
1753
+ });
1754
+ }
1755
+ function Sub({ ...props }) {
1756
+ return /*#__PURE__*/ jsx(Menu.SubmenuRoot, {
1757
+ "data-slot": "dropdown-menu-sub",
1758
+ ...props
1759
+ });
1760
+ }
1761
+ function SubTrigger({ className, inset, children, ...props }) {
1762
+ return /*#__PURE__*/ jsxs(Menu.SubmenuTrigger, {
1763
+ "data-slot": "dropdown-menu-sub-trigger",
1764
+ "data-inset": inset ? '' : void 0,
1765
+ className: clsx(subTrigger, className),
1766
+ ...props,
1767
+ children: [
1768
+ children,
1769
+ /*#__PURE__*/ jsx(ChevronRightIcon, {
1770
+ className: subTriggerIcon
1771
+ })
1772
+ ]
1773
+ });
1774
+ }
1775
+ function SubContent({ align = 'start', alignOffset = -3, side = 'right', sideOffset = 0, className, ...props }) {
1776
+ return /*#__PURE__*/ jsx(DropdownMenu_Content, {
1777
+ "data-slot": "dropdown-menu-sub-content",
1778
+ className: clsx(subContent, className),
1779
+ align: align,
1780
+ alignOffset: alignOffset,
1781
+ side: side,
1782
+ sideOffset: sideOffset,
1783
+ ...props
1784
+ });
1785
+ }
1786
+ function CheckboxItem({ className, children, checked, inset, ...props }) {
1787
+ return /*#__PURE__*/ jsxs(Menu.CheckboxItem, {
1788
+ "data-slot": "dropdown-menu-checkbox-item",
1789
+ "data-inset": inset ? '' : void 0,
1790
+ className: clsx(checkboxItem, className),
1791
+ checked: checked,
1792
+ ...props,
1793
+ children: [
1794
+ /*#__PURE__*/ jsx("span", {
1795
+ className: itemIndicator,
1796
+ "data-slot": "dropdown-menu-checkbox-item-indicator",
1797
+ children: /*#__PURE__*/ jsx(Menu.CheckboxItemIndicator, {
1798
+ children: /*#__PURE__*/ jsx(CheckIcon, {
1799
+ className: styles_css_icon
1800
+ })
1801
+ })
1802
+ }),
1803
+ children
1804
+ ]
1805
+ });
1806
+ }
1807
+ function RadioGroup({ ...props }) {
1808
+ return /*#__PURE__*/ jsx(Menu.RadioGroup, {
1809
+ "data-slot": "dropdown-menu-radio-group",
1810
+ ...props
1811
+ });
1812
+ }
1813
+ function RadioItem({ className, children, inset, ...props }) {
1814
+ return /*#__PURE__*/ jsxs(Menu.RadioItem, {
1815
+ "data-slot": "dropdown-menu-radio-item",
1816
+ "data-inset": inset ? '' : void 0,
1817
+ className: clsx(radioItem, className),
1818
+ ...props,
1819
+ children: [
1820
+ /*#__PURE__*/ jsx("span", {
1821
+ className: itemIndicator,
1822
+ "data-slot": "dropdown-menu-radio-item-indicator",
1823
+ children: /*#__PURE__*/ jsx(Menu.RadioItemIndicator, {
1824
+ children: /*#__PURE__*/ jsx(CheckIcon, {
1825
+ className: styles_css_icon
1826
+ })
1827
+ })
1828
+ }),
1829
+ children
1830
+ ]
1831
+ });
1832
+ }
1833
+ function DropdownMenu_Separator({ className, ...props }) {
1834
+ return /*#__PURE__*/ jsx(Menu.Separator, {
1835
+ "data-slot": "dropdown-menu-separator",
1836
+ className: clsx(DropdownMenu_styles_css_separator, className),
1837
+ ...props
1838
+ });
1839
+ }
1840
+ function Shortcut({ className, ...props }) {
1841
+ return /*#__PURE__*/ jsx("span", {
1842
+ "data-slot": "dropdown-menu-shortcut",
1843
+ className: clsx(shortcut, className),
1844
+ ...props
1845
+ });
1846
+ }
1847
+ DropdownMenu.Portal = DropdownMenu_Portal;
1848
+ DropdownMenu.Trigger = DropdownMenu_Trigger;
1849
+ DropdownMenu.Content = DropdownMenu_Content;
1850
+ DropdownMenu.Group = DropdownMenu_Group;
1851
+ DropdownMenu.Label = Label;
1852
+ DropdownMenu.Item = DropdownMenu_Item;
1853
+ DropdownMenu.Sub = Sub;
1854
+ DropdownMenu.SubTrigger = SubTrigger;
1855
+ DropdownMenu.SubContent = SubContent;
1856
+ DropdownMenu.Shortcut = Shortcut;
1857
+ DropdownMenu.Separator = DropdownMenu_Separator;
1858
+ DropdownMenu.RadioGroup = RadioGroup;
1859
+ DropdownMenu.RadioItem = RadioItem;
1860
+ DropdownMenu.CheckboxItem = CheckboxItem;
1861
+ const MainIconButton_useLogic_useLogic_useLogic = ({ action })=>{
1862
+ const { isLoading, disabledReason, name } = action;
1863
+ const [isVisibleTooltip, setVisibleTooltip] = useState(false);
1864
+ const handleOpenChange = (open)=>setVisibleTooltip(open);
1865
+ useEffect(()=>{
1866
+ if (isLoading) setVisibleTooltip(false);
1867
+ }, [
1868
+ isLoading
1869
+ ]);
1870
+ const text = disabledReason || name;
1871
+ return {
1872
+ tooltipProps: {
1873
+ text,
1874
+ open: isVisibleTooltip,
1875
+ onOpenChange: handleOpenChange
1876
+ }
1877
+ };
1878
+ };
1879
+ const MainIconButton = (props)=>{
1880
+ const { tooltipProps } = MainIconButton_useLogic_useLogic_useLogic(props);
1881
+ const { action, onActionClick, isDisabled, tooltipPlacement } = props;
1882
+ const { name, icon, needConfirm, confirmText, confirmButtonProps, disabled, isLoading, onClick } = action;
1883
+ const renderButton = (renderProps)=>/*#__PURE__*/ jsx(Tooltip, {
1884
+ arrow: true,
1885
+ side: tooltipPlacement,
1886
+ ...tooltipProps,
1887
+ children: /*#__PURE__*/ jsx(Button_Button, {
1888
+ disabled: isDisabled || disabled,
1889
+ isLoading: isLoading,
1890
+ variant: "ghost",
1891
+ size: "icon",
1892
+ ...renderProps,
1893
+ children: icon
1894
+ })
1895
+ }, name);
1896
+ return /*#__PURE__*/ jsx(Fragment, {
1897
+ children: needConfirm ? /*#__PURE__*/ jsx(ConfirmAction, {
1898
+ text: confirmText,
1899
+ confirmButtonProps: confirmButtonProps,
1900
+ actionComponent: (renderProps)=>renderButton(renderProps),
1901
+ onConfirm: onActionClick(onClick)
1902
+ }) : renderButton({
1903
+ onClick: onActionClick(onClick)
1904
+ })
1905
+ });
1906
+ };
1907
+ const MainAction = ({ action, onActionClick, isDisabled, tooltipPlacement })=>{
1908
+ if ('actions' in action) {
1909
+ const { disabled, icon, name, disabledReason, actions, isLoading } = action;
1910
+ return /*#__PURE__*/ jsxs(DropdownMenu, {
1911
+ children: [
1912
+ /*#__PURE__*/ jsx(Tooltip, {
1913
+ text: disabledReason || name,
1914
+ side: tooltipPlacement,
1915
+ arrow: true,
1916
+ children: /*#__PURE__*/ jsx(DropdownMenu.Trigger, {
1917
+ render: /*#__PURE__*/ jsx(Button_Button, {
1918
+ variant: "ghost",
1919
+ size: "icon",
1920
+ isLoading: isLoading,
1921
+ disabled: isDisabled || disabled,
1922
+ children: icon
1923
+ })
1924
+ })
1925
+ }, name),
1926
+ /*#__PURE__*/ jsx(DropdownMenu.Content, {
1927
+ children: actions.map(({ name: nestedActionName, onClick: onClickNested, ...props })=>/*#__PURE__*/ createElement(DropdownMenu.Item, {
1928
+ ...props,
1929
+ key: nestedActionName,
1930
+ render: /*#__PURE__*/ jsx(Button_Button, {
1931
+ size: "sm",
1932
+ onClick: onActionClick(onClickNested),
1933
+ children: nestedActionName
1934
+ })
1935
+ }))
1936
+ })
1937
+ ]
1938
+ });
1939
+ }
1940
+ return /*#__PURE__*/ jsx(MainIconButton, {
1941
+ action: action,
1942
+ onActionClick: onActionClick,
1943
+ isDisabled: isDisabled,
1944
+ tooltipPlacement: tooltipPlacement
1945
+ });
1946
+ };
1947
+ const SecondaryActions = ({ actions, onActionClick, tooltipPlacement, isDisabled })=>/*#__PURE__*/ jsxs(DropdownMenu, {
1948
+ children: [
1949
+ /*#__PURE__*/ jsx(DropdownMenu.Trigger, {
1950
+ render: /*#__PURE__*/ jsx(Button_Button, {
1951
+ disabled: isDisabled,
1952
+ variant: "ghost",
1953
+ size: "icon",
1954
+ children: /*#__PURE__*/ jsx(EllipsisVertical, {})
1955
+ })
1956
+ }),
1957
+ /*#__PURE__*/ jsx(DropdownMenu.Content, {
1958
+ children: actions.map((action)=>{
1959
+ const { onClick, name, disabledReason, isLoading } = action;
1960
+ return /*#__PURE__*/ jsx(Tooltip, {
1961
+ arrow: true,
1962
+ side: tooltipPlacement,
1963
+ text: disabledReason,
1964
+ children: /*#__PURE__*/ jsx(DropdownMenu.Item, {
1965
+ render: /*#__PURE__*/ jsx(Button_Button, {
1966
+ onClick: onActionClick(onClick),
1967
+ isLoading: isLoading,
1968
+ variant: "ghost",
1969
+ size: "sm",
1970
+ fullWidth: true,
1971
+ children: name
1972
+ })
1973
+ })
1974
+ }, name);
1975
+ })
1976
+ })
1977
+ ]
1978
+ });
1979
+ var DataGridActionCell_styles_css_wrapper = 'style__y44ln70';
1980
+ const DataGridActionCell_useLogic_useLogic_useLogic = ({ row, actions })=>{
1981
+ const { main, secondary } = actions;
1982
+ const blockingAction = [
1983
+ ...main,
1984
+ ...secondary || []
1985
+ ].find((action)=>action.isBlockingOperation && action.isLoading);
1986
+ const isDisabledAction = Boolean(blockingAction);
1987
+ const handleActionClick = useCallback((onClick)=>()=>{
1988
+ onClick?.(row);
1989
+ }, [
1990
+ row
1991
+ ]);
1992
+ const handleWrapperClick = (event)=>{
1993
+ event.stopPropagation();
1994
+ };
1995
+ return {
1996
+ isDisabledAction,
1997
+ handleActionClick,
1998
+ handleWrapperClick
1999
+ };
2000
+ };
2001
+ const TOOLTIP_PLACEMENT = {
2002
+ mainAction: 'top',
2003
+ secondaryAction: 'left'
2004
+ };
2005
+ const DataGridActionCell = (props)=>{
2006
+ const { isDisabledAction, handleWrapperClick, handleActionClick } = DataGridActionCell_useLogic_useLogic_useLogic(props);
2007
+ const { actions } = props;
2008
+ const { main, secondary } = actions;
2009
+ return /*#__PURE__*/ jsxs("div", {
2010
+ onClick: handleWrapperClick,
2011
+ onKeyDown: handleWrapperClick,
2012
+ className: DataGridActionCell_styles_css_wrapper,
2013
+ children: [
2014
+ main.map((action)=>/*#__PURE__*/ jsx(MainAction, {
2015
+ action: action,
2016
+ onActionClick: handleActionClick,
2017
+ isDisabled: isDisabledAction,
2018
+ tooltipPlacement: TOOLTIP_PLACEMENT.mainAction
2019
+ }, action.name)),
2020
+ secondary && /*#__PURE__*/ jsx(SecondaryActions, {
2021
+ actions: secondary,
2022
+ onActionClick: handleActionClick,
2023
+ tooltipPlacement: TOOLTIP_PLACEMENT.secondaryAction,
2024
+ isDisabled: isDisabledAction
2025
+ })
2026
+ ]
2027
+ });
2028
+ };
2029
+ var styles_css_alignments = {
2030
+ left: 'left__o752f01',
2031
+ center: 'center__o752f02',
2032
+ right: 'right__o752f03',
2033
+ justify: 'justify__o752f04'
2034
+ };
2035
+ var DataGridSortHeader_styles_css_wrapper = 'style__o752f00';
2036
+ function DataGridSortHeader({ sorting, setSorting, column: { title, field, align = 'left' }, className }) {
2037
+ if (!field) return null;
2038
+ const handleClick = ()=>{
2039
+ sorting.key === field ? setSorting({
2040
+ key: field,
2041
+ order: 'asc' === sorting.order ? 'desc' : 'asc'
2042
+ }) : setSorting({
2043
+ key: field,
2044
+ order: 'asc'
2045
+ });
2046
+ };
2047
+ return /*#__PURE__*/ jsxs("button", {
2048
+ type: "button",
2049
+ className: clsx(DataGridSortHeader_styles_css_wrapper, styles_css_alignments[align], className),
2050
+ onClick: handleClick,
2051
+ children: [
2052
+ title,
2053
+ sorting.key === field ? 'asc' === sorting.order ? /*#__PURE__*/ jsx(ArrowDownNarrowWide, {
2054
+ size: 16
2055
+ }) : /*#__PURE__*/ jsx(ArrowDownWideNarrow, {
2056
+ size: 16
2057
+ }) : /*#__PURE__*/ jsx(ArrowDownUp, {
2058
+ size: 16
2059
+ })
2060
+ ]
2061
+ });
2062
+ }
2063
+ const ITEM_CLASSNAME = 'datalist_item';
2064
+ const END_OF_SCROLL_MESSAGE = 'Вы достигли конца списка';
2065
+ var EndData_styles_css_item = 'style__1syvw5e0';
2066
+ const EndData = ({ endOfScrollMsg = END_OF_SCROLL_MESSAGE })=>/*#__PURE__*/ jsx("li", {
2067
+ className: EndData_styles_css_item,
2068
+ children: /*#__PURE__*/ jsx(Typography, {
2069
+ children: endOfScrollMsg
2070
+ })
2071
+ });
2072
+ const ERROR_MESSAGE = 'Ошибка загрузки';
2073
+ var ErrorState_styles_css_item = 'style__qlujai0';
2074
+ const ErrorState = ({ onRetry })=>/*#__PURE__*/ jsxs("li", {
2075
+ className: ErrorState_styles_css_item,
2076
+ children: [
2077
+ /*#__PURE__*/ jsx(Typography, {
2078
+ align: "center",
2079
+ children: ERROR_MESSAGE
2080
+ }),
2081
+ /*#__PURE__*/ jsx(Button_Button, {
2082
+ size: "sm",
2083
+ onClick: onRetry,
2084
+ children: "Попробовать снова"
2085
+ })
2086
+ ]
2087
+ });
2088
+ var Loader_styles_css_item = 'style__111czea0';
2089
+ const Loader = ()=>/*#__PURE__*/ jsx("li", {
2090
+ className: Loader_styles_css_item,
2091
+ children: /*#__PURE__*/ jsx(CircularProgress, {
2092
+ color: "primary"
2093
+ })
2094
+ });
2095
+ const NO_DATA_TEXT = 'Нет данных';
2096
+ const NoData = ({ noDataImgSrc })=>/*#__PURE__*/ jsx(Placeholder, {
2097
+ title: NO_DATA_TEXT,
2098
+ imgSrc: noDataImgSrc
2099
+ });
2100
+ var buttonClass = 'style__1jg5nd90';
2101
+ var visible = 'style__1jg5nd91';
2102
+ const ScrollToTopButton = ({ onClick, isVisible })=>/*#__PURE__*/ jsx(Button_Button, {
2103
+ onClick: onClick,
2104
+ size: "icon",
2105
+ variant: "outline",
2106
+ className: clsx(buttonClass, {
2107
+ [visible]: isVisible
2108
+ }),
2109
+ children: /*#__PURE__*/ jsx(ChevronUp, {})
2110
+ });
2111
+ var itemClass = 'style__1ezen7g1';
2112
+ var styles_css_list = 'style__1ezen7g0';
2113
+ const DataList = ({ data, keyId, className, itemContent, noDataPlaceholder, endOfScrollMsg, errorState, isLoading, isError, isEndReached, onRetry, onEndReached, ref })=>{
2114
+ const innerRef = useRef(null);
2115
+ const virtuoso = ref || innerRef;
2116
+ const [isStickyButtonActive, setIsStickyButtonActive] = useState(false);
2117
+ const handleRangeChanged = useCallback((range)=>{
2118
+ range.startIndex > 2 ? setIsStickyButtonActive(true) : setIsStickyButtonActive(false);
2119
+ }, []);
2120
+ const handleScrollToTop = useCallback(()=>virtuoso.current?.scrollToIndex({
2121
+ index: 0,
2122
+ align: 'start',
2123
+ behavior: 'smooth'
2124
+ }), [
2125
+ virtuoso
2126
+ ]);
2127
+ const handleEndReach = useCallback(()=>{
2128
+ if (!isEndReached && onEndReached) onEndReached();
2129
+ }, [
2130
+ isEndReached,
2131
+ onEndReached
2132
+ ]);
2133
+ const isDataExist = Boolean(data?.length);
2134
+ if (!isDataExist && !isLoading && !isError) return noDataPlaceholder ? /*#__PURE__*/ jsx(Fragment, {
2135
+ children: noDataPlaceholder
2136
+ }) : /*#__PURE__*/ jsx(NoData, {});
2137
+ return /*#__PURE__*/ jsxs(ContentState, {
2138
+ isLoading: isLoading && !isDataExist,
2139
+ isError: isError && !isDataExist,
2140
+ errorState: errorState,
2141
+ children: [
2142
+ /*#__PURE__*/ jsx(Virtuoso, {
2143
+ className: clsx(styles_css_list, className),
2144
+ style: {
2145
+ height: '100%'
2146
+ },
2147
+ data: data,
2148
+ ref: virtuoso,
2149
+ overscan: 30,
2150
+ endReached: handleEndReach,
2151
+ rangeChanged: handleRangeChanged,
2152
+ itemContent: (index, item)=>/*#__PURE__*/ jsx("li", {
2153
+ children: itemContent?.(item, {
2154
+ index,
2155
+ className: clsx(itemClass, ITEM_CLASSNAME)
2156
+ })
2157
+ }, item[keyId]),
2158
+ components: {
2159
+ Footer: ()=>/*#__PURE__*/ jsxs(Fragment, {
2160
+ children: [
2161
+ isLoading && /*#__PURE__*/ jsx(Loader, {}),
2162
+ isError && /*#__PURE__*/ jsx(ErrorState, {
2163
+ onRetry: onRetry
2164
+ }),
2165
+ isEndReached && /*#__PURE__*/ jsx(EndData, {
2166
+ endOfScrollMsg: endOfScrollMsg
2167
+ })
2168
+ ]
2169
+ })
2170
+ }
2171
+ }),
2172
+ /*#__PURE__*/ jsx(ScrollToTopButton, {
2173
+ isVisible: isStickyButtonActive,
2174
+ onClick: handleScrollToTop
2175
+ })
2176
+ ]
2177
+ });
2178
+ };
2179
+ var adornment = 'style__1blk89uc';
2180
+ var Input_styles_css_container = 'Input__1blk89u0';
2181
+ var styles_css_disabledClass = 'style__1blk89u6';
2182
+ var errorClass = 'style__1blk89u7';
2183
+ var fullWidthClass = 'style__1blk89u3';
2184
+ var input = 'style__1blk89u8';
2185
+ var Input_styles_css_sizes = {
2186
+ sm: 'sm__1blk89u9',
2187
+ md: 'md__1blk89ua',
2188
+ lg: 'lg__1blk89ub'
2189
+ };
2190
+ var Input_styles_css_variants = {
2191
+ outlined: 'outlined__1blk89u1',
2192
+ standard: 'standard__1blk89u2'
2193
+ };
2194
+ var withEndAdornment = 'style__1blk89ue';
2195
+ var withStartAdornment = 'style__1blk89ud';
2196
+ const Input = ({ error, variant = 'outlined', size = 'md', startAdornment, endAdornment, className, disabled, fullWidth, value, ref, ...props })=>/*#__PURE__*/ jsxs("div", {
2197
+ className: clsx(Input_styles_css_container, Input_styles_css_variants[variant], {
2198
+ [errorClass]: error
2199
+ }, {
2200
+ [styles_css_disabledClass]: disabled
2201
+ }, {
2202
+ [fullWidthClass]: fullWidth
2203
+ }, className),
2204
+ children: [
2205
+ startAdornment && /*#__PURE__*/ jsx("span", {
2206
+ className: adornment,
2207
+ children: startAdornment
2208
+ }),
2209
+ /*#__PURE__*/ jsx("input", {
2210
+ className: clsx(input, Input_styles_css_sizes[size], {
2211
+ [styles_css_disabledClass]: disabled,
2212
+ [withStartAdornment]: Boolean(startAdornment),
2213
+ [withEndAdornment]: Boolean(endAdornment)
2214
+ }),
2215
+ ref: ref,
2216
+ disabled: disabled,
2217
+ value: value || '',
2218
+ ...props
2219
+ }),
2220
+ endAdornment && /*#__PURE__*/ jsx("span", {
2221
+ className: adornment,
2222
+ children: endAdornment
2223
+ })
2224
+ ]
2225
+ });
2226
+ var label_css_disabled = 'style__c31e141';
2227
+ var label_css_error = 'style__c31e142';
2228
+ var required = 'style__c31e143';
2229
+ var label_css_root = 'Label__c31e140';
2230
+ const Label_Label = ({ className, disabled, ...props })=>/*#__PURE__*/ jsx(react_label_Root, {
2231
+ className: clsx(label_css_root, {
2232
+ [label_css_disabled]: disabled,
2233
+ [label_css_error]: props.error,
2234
+ [required]: props.required
2235
+ }, className),
2236
+ ...props
2237
+ });
2238
+ var TextField_styles_css_container = 'style__kqu4y20';
2239
+ var TextField_styles_css_disabledClass = 'style__kqu4y23';
2240
+ var styles_css_errorClass = 'style__kqu4y24';
2241
+ var styles_css_fullWidthClass = 'style__kqu4y25';
2242
+ var helperTextClass = 'style__kqu4y22';
2243
+ var labelClass = 'style__kqu4y21';
2244
+ const TextField = ({ label, helperText, className, disabled, fullWidth, ref, labelClassName, ...props })=>/*#__PURE__*/ jsxs("div", {
2245
+ className: clsx(TextField_styles_css_container, {
2246
+ [styles_css_fullWidthClass]: fullWidth
2247
+ }, className),
2248
+ children: [
2249
+ label && /*#__PURE__*/ jsx(Label_Label, {
2250
+ htmlFor: props.id || label,
2251
+ disabled: disabled,
2252
+ required: props.required,
2253
+ error: props.error,
2254
+ className: clsx(labelClass, labelClassName),
2255
+ children: label
2256
+ }),
2257
+ /*#__PURE__*/ jsx(Input, {
2258
+ ref: ref,
2259
+ disabled: disabled,
2260
+ fullWidth: fullWidth,
2261
+ id: props.id || label,
2262
+ ...props
2263
+ }),
2264
+ helperText && /*#__PURE__*/ jsx(Typography, {
2265
+ variant: "caption",
2266
+ className: clsx(helperTextClass, {
2267
+ [styles_css_errorClass]: props.error,
2268
+ [TextField_styles_css_disabledClass]: disabled
2269
+ }),
2270
+ children: helperText
2271
+ })
2272
+ ]
2273
+ });
2274
+ const MaskField = ({ maskProps, ref, ...textFieldProps })=>{
2275
+ const maskInputRef = useMask(maskProps);
2276
+ const mergedRef = useCallback((element)=>{
2277
+ maskInputRef.current = element;
2278
+ if ('function' == typeof ref) ref(element);
2279
+ else if (ref) ref.current = element;
2280
+ }, [
2281
+ maskInputRef,
2282
+ ref
2283
+ ]);
2284
+ return /*#__PURE__*/ jsx(TextField, {
2285
+ ref: mergedRef,
2286
+ ...textFieldProps
2287
+ });
2288
+ };
2289
+ const DatePicker = (props)=>{
2290
+ const { label, disabled = false, selected, onSelect, selectMonth, selectYear, error, helperText, className, fullWidth, size, name, ...rest } = props;
2291
+ const [innerError, setInnerError] = useState(null);
2292
+ const [isOpen, setIsOpen] = useState(false);
2293
+ const [month, setMonth] = useState(new Date());
2294
+ const [inputValue, setInputValue] = useState('');
2295
+ const getLayout = ()=>{
2296
+ if (selectMonth && selectYear) return 'dropdown';
2297
+ if (selectMonth) return 'dropdown-months';
2298
+ if (selectYear) return 'dropdown-years';
2299
+ return 'label';
2300
+ };
2301
+ const handleClick = ()=>{
2302
+ setIsOpen(true);
2303
+ };
2304
+ const handleClose = ()=>{
2305
+ setIsOpen(false);
2306
+ };
2307
+ const handleDayPickerSelect = (date)=>{
2308
+ if (date) {
2309
+ onSelect?.(date);
2310
+ setMonth(date);
2311
+ setInputValue(date.toLocaleString('ru-RU', {
2312
+ day: '2-digit',
2313
+ month: '2-digit',
2314
+ year: 'numeric'
2315
+ }));
2316
+ } else {
2317
+ setInputValue('');
2318
+ onSelect?.(void 0);
2319
+ }
2320
+ handleClose();
2321
+ };
2322
+ const handleInputChange = (e)=>{
2323
+ setInnerError(null);
2324
+ setInputValue(e.target.value);
2325
+ const [day, month, year] = e.target.value.split('.').map(Number);
2326
+ if (Number.isNaN(day) || Number.isNaN(month) || Number.isNaN(year) || day < 1 || day > 31 || month < 1 || month > 12 || year < 1000) return void setInnerError('Некорректная дата');
2327
+ const parsedDate = new Date(year, month - 1, day);
2328
+ onSelect?.(parsedDate);
2329
+ setMonth(parsedDate);
2330
+ };
2331
+ useEffect(()=>{
2332
+ if (selected) {
2333
+ setInputValue(selected.toLocaleString('ru-RU', {
2334
+ day: '2-digit',
2335
+ month: '2-digit',
2336
+ year: 'numeric'
2337
+ }));
2338
+ setMonth(selected);
2339
+ } else setInputValue('');
2340
+ }, [
2341
+ selected
2342
+ ]);
2343
+ return /*#__PURE__*/ jsxs(Popover_Popover, {
2344
+ open: isOpen,
2345
+ onOpenChange: setIsOpen,
2346
+ children: [
2347
+ /*#__PURE__*/ jsx(MaskField, {
2348
+ value: inputValue,
2349
+ onChange: handleInputChange,
2350
+ label: label,
2351
+ disabled: disabled,
2352
+ className: className,
2353
+ fullWidth: fullWidth,
2354
+ size: size,
2355
+ name: name,
2356
+ endAdornment: /*#__PURE__*/ jsx(Popover_Popover.Trigger, {
2357
+ render: /*#__PURE__*/ jsx(Button_Button, {
2358
+ variant: "ghost",
2359
+ size: "icon",
2360
+ onClick: handleClick,
2361
+ children: /*#__PURE__*/ jsx(Calendar1, {})
2362
+ })
2363
+ }),
2364
+ maskProps: {
2365
+ mask: '__.__.____',
2366
+ replacement: {
2367
+ _: /\d/
2368
+ },
2369
+ showMask: true
2370
+ },
2371
+ placeholder: "дд.мм.гггг",
2372
+ error: !!innerError || error,
2373
+ helperText: innerError || helperText
2374
+ }),
2375
+ /*#__PURE__*/ jsx(Popover_Popover.Content, {
2376
+ align: "end",
2377
+ alignOffset: -10,
2378
+ side: "bottom",
2379
+ children: /*#__PURE__*/ jsx(Calendar, {
2380
+ month: month,
2381
+ onMonthChange: setMonth,
2382
+ selected: selected,
2383
+ onSelect: handleDayPickerSelect,
2384
+ ...rest,
2385
+ mode: "single",
2386
+ captionLayout: getLayout()
2387
+ })
2388
+ })
2389
+ ]
2390
+ });
2391
+ };
2392
+ const DEFAULT_SEPARATOR = ':';
2393
+ const DEFAULT_SYMBOL = '—';
2394
+ const DESCRIPTION_ROOT_CLASSNAME = "descriptionRoot";
2395
+ const DescriptionContext = /*#__PURE__*/ createContext({
2396
+ leader: false,
2397
+ separator: ":",
2398
+ direction: 'default'
2399
+ });
2400
+ const DescriptionContextProvider = ({ children, leader, separator, direction })=>/*#__PURE__*/ jsx(DescriptionContext.Provider, {
2401
+ value: {
2402
+ leader,
2403
+ separator,
2404
+ direction
2405
+ },
2406
+ children: children
2407
+ });
2408
+ var dashedSeparator = 'style__1tsgk1i2';
2409
+ var styles_css_leader = 'style__1tsgk1i1';
2410
+ var Name_styles_css_wrapper = 'style__1tsgk1i0';
2411
+ const Name = ({ children, color = 'secondary', ...props })=>{
2412
+ const { leader, separator } = useContext(DescriptionContext);
2413
+ return /*#__PURE__*/ jsxs(Fragment, {
2414
+ children: [
2415
+ /*#__PURE__*/ jsx("dt", {
2416
+ className: clsx(Name_styles_css_wrapper, {
2417
+ [styles_css_leader]: leader
2418
+ }),
2419
+ children: /*#__PURE__*/ jsxs(Typography, {
2420
+ ...props,
2421
+ color: color,
2422
+ children: [
2423
+ children,
2424
+ !leader && separator
2425
+ ]
2426
+ })
2427
+ }),
2428
+ leader && /*#__PURE__*/ jsx("div", {
2429
+ className: dashedSeparator
2430
+ })
2431
+ ]
2432
+ });
2433
+ };
2434
+ var directions = {
2435
+ row: 'row__1lociyw1',
2436
+ column: 'column__1lociyw2'
2437
+ };
2438
+ var justify = {
2439
+ spaceBetween: 'spaceBetween__1lociyw3',
2440
+ start: 'start__1lociyw4'
2441
+ };
2442
+ var Description_styles_css_wrapper = 'style__1lociyw0';
2443
+ const Description_useLogic_useLogic_useLogic = ({ direction = 'row', separator = ":" })=>{
2444
+ const hasSeparator = 'column' === direction;
2445
+ const descriptionContextProviderProps = {
2446
+ separator: hasSeparator ? '' : separator
2447
+ };
2448
+ return {
2449
+ descriptionContextProviderProps,
2450
+ direction
2451
+ };
2452
+ };
2453
+ var Value_styles_css_leader = 'style__sdcsnp2';
2454
+ var Value_styles_css_text = 'style__sdcsnp1';
2455
+ var Value_styles_css_wrapper = 'style__sdcsnp0';
2456
+ const Value_useLogic_useLogic_useLogic = ({ canCopy, children, stub = '—' })=>{
2457
+ const { leader, direction } = useContext(DescriptionContext);
2458
+ const valueToRender = children || stub;
2459
+ const isDefaultValueRender = !canCopy || !children;
2460
+ return {
2461
+ valueToRender,
2462
+ isDefaultValueRender,
2463
+ leader,
2464
+ direction
2465
+ };
2466
+ };
2467
+ const Value = (props)=>{
2468
+ const { valueToRender, isDefaultValueRender, leader } = Value_useLogic_useLogic_useLogic(props);
2469
+ const { copyPosition = 'right', copyText, canCopy, children, stub, ...restProps } = props;
2470
+ if (isDefaultValueRender) return /*#__PURE__*/ jsx(Typography, {
2471
+ className: clsx_0(Value_styles_css_text, {
2472
+ [Value_styles_css_leader]: leader
2473
+ }),
2474
+ component: "dd",
2475
+ ...restProps,
2476
+ children: valueToRender
2477
+ });
2478
+ return /*#__PURE__*/ jsx("dd", {
2479
+ className: Value_styles_css_wrapper,
2480
+ children: /*#__PURE__*/ jsx(CopyTypography, {
2481
+ className: clsx_0({
2482
+ [Value_styles_css_leader]: leader
2483
+ }),
2484
+ copyPosition: copyPosition,
2485
+ copyText: copyText,
2486
+ ...restProps,
2487
+ children: valueToRender
2488
+ })
2489
+ });
2490
+ };
2491
+ const Description_Description = (props)=>{
2492
+ const { descriptionContextProviderProps, direction } = Description_useLogic_useLogic_useLogic(props);
2493
+ const { justifyContent = 'start', component: Component = 'dl', children, leader = false, className } = props;
2494
+ return /*#__PURE__*/ jsx(DescriptionContextProvider, {
2495
+ leader: leader,
2496
+ direction: direction,
2497
+ ...descriptionContextProviderProps,
2498
+ children: /*#__PURE__*/ jsx(Component, {
2499
+ className: clsx(Description_styles_css_wrapper, directions[direction], justify[justifyContent], DESCRIPTION_ROOT_CLASSNAME, className),
2500
+ children: children
2501
+ })
2502
+ });
2503
+ };
2504
+ Description_Description.Name = Name;
2505
+ Description_Description.Value = Value;
2506
+ var styles_css_closeButton = 'style__8bkmbe6';
2507
+ var closeText = 'style__8bkmbe7';
2508
+ var Dialog_styles_css_content = 'style__8bkmbe5';
2509
+ var Dialog_styles_css_description = 'style__8bkmbeb';
2510
+ var Dialog_styles_css_footer = 'style__8bkmbe9';
2511
+ var Dialog_styles_css_header = 'style__8bkmbe8';
2512
+ var styles_css_overlay = 'style__8bkmbe4';
2513
+ var Dialog_styles_css_title = 'style__8bkmbea';
2514
+ function Dialog_Dialog({ ...props }) {
2515
+ return /*#__PURE__*/ jsx(Dialog.Root, {
2516
+ "data-slot": "dialog",
2517
+ ...props
2518
+ });
2519
+ }
2520
+ function Dialog_Trigger({ ...props }) {
2521
+ return /*#__PURE__*/ jsx(Dialog.Trigger, {
2522
+ "data-slot": "dialog-trigger",
2523
+ ...props
2524
+ });
2525
+ }
2526
+ function Dialog_Portal({ ...props }) {
2527
+ return /*#__PURE__*/ jsx(Dialog.Portal, {
2528
+ "data-slot": "dialog-portal",
2529
+ ...props
2530
+ });
2531
+ }
2532
+ function Close({ ...props }) {
2533
+ return /*#__PURE__*/ jsx(Dialog.Close, {
2534
+ "data-slot": "dialog-close",
2535
+ ...props
2536
+ });
2537
+ }
2538
+ function Dialog_Overlay({ className, ...props }) {
2539
+ return /*#__PURE__*/ jsx(Dialog.Backdrop, {
2540
+ "data-slot": "dialog-overlay",
2541
+ className: clsx(styles_css_overlay, className),
2542
+ ...props
2543
+ });
2544
+ }
2545
+ function Dialog_Content({ className, children, showCloseButton = true, ...props }) {
2546
+ return /*#__PURE__*/ jsxs(Dialog_Portal, {
2547
+ children: [
2548
+ /*#__PURE__*/ jsx(Dialog_Overlay, {}),
2549
+ /*#__PURE__*/ jsxs(Dialog.Popup, {
2550
+ "data-slot": "dialog-content",
2551
+ className: clsx(Dialog_styles_css_content, className),
2552
+ ...props,
2553
+ children: [
2554
+ children,
2555
+ showCloseButton && /*#__PURE__*/ jsxs(Dialog.Close, {
2556
+ "data-slot": "dialog-close",
2557
+ render: /*#__PURE__*/ jsx(Button_Button, {
2558
+ variant: "ghost",
2559
+ size: "iconSm",
2560
+ className: styles_css_closeButton
2561
+ }),
2562
+ children: [
2563
+ /*#__PURE__*/ jsx(XIcon, {}),
2564
+ /*#__PURE__*/ jsx("span", {
2565
+ className: closeText,
2566
+ children: "Close"
2567
+ })
2568
+ ]
2569
+ })
2570
+ ]
2571
+ })
2572
+ ]
2573
+ });
2574
+ }
2575
+ function Dialog_Header({ className, ...props }) {
2576
+ return /*#__PURE__*/ jsx("div", {
2577
+ "data-slot": "dialog-header",
2578
+ className: clsx(Dialog_styles_css_header, className),
2579
+ ...props
2580
+ });
2581
+ }
2582
+ function Dialog_Footer({ className, showCloseButton = false, children, ...props }) {
2583
+ return /*#__PURE__*/ jsxs("div", {
2584
+ "data-slot": "dialog-footer",
2585
+ className: clsx(Dialog_styles_css_footer, className),
2586
+ ...props,
2587
+ children: [
2588
+ children,
2589
+ showCloseButton && /*#__PURE__*/ jsx(Dialog.Close, {
2590
+ render: /*#__PURE__*/ jsx(Button_Button, {
2591
+ variant: "outline"
2592
+ }),
2593
+ children: "Close"
2594
+ })
2595
+ ]
2596
+ });
2597
+ }
2598
+ function Dialog_Title({ className, ...props }) {
2599
+ return /*#__PURE__*/ jsx(Dialog.Title, {
2600
+ "data-slot": "dialog-title",
2601
+ className: clsx(Dialog_styles_css_title, className),
2602
+ ...props
2603
+ });
2604
+ }
2605
+ function Dialog_Description({ className, ...props }) {
2606
+ return /*#__PURE__*/ jsx(Dialog.Description, {
2607
+ "data-slot": "dialog-description",
2608
+ className: clsx(Dialog_styles_css_description, className),
2609
+ ...props
2610
+ });
2611
+ }
2612
+ Dialog_Dialog.Trigger = Dialog_Trigger;
2613
+ Dialog_Dialog.Portal = Dialog_Portal;
2614
+ Dialog_Dialog.Close = Close;
2615
+ Dialog_Dialog.Overlay = Dialog_Overlay;
2616
+ Dialog_Dialog.Content = Dialog_Content;
2617
+ Dialog_Dialog.Header = Dialog_Header;
2618
+ Dialog_Dialog.Footer = Dialog_Footer;
2619
+ Dialog_Dialog.Title = Dialog_Title;
2620
+ Dialog_Dialog.Description = Dialog_Description;
2621
+ var Drawer_styles_css_content = 'style__ccss503';
2622
+ var Drawer_styles_css_description = 'style__ccss508';
2623
+ var dragHandle = 'style__ccss504';
2624
+ var Drawer_styles_css_footer = 'style__ccss506';
2625
+ var Drawer_styles_css_header = 'style__ccss505';
2626
+ var Drawer_styles_css_overlay = 'style__ccss502';
2627
+ var Drawer_styles_css_title = 'style__ccss507';
2628
+ const Drawer_Drawer = ({ children, trigger, className, title, description = '', footer, closeButton, ...props })=>/*#__PURE__*/ jsxs(external_vaul_Root, {
2629
+ ...props,
2630
+ children: [
2631
+ trigger && /*#__PURE__*/ jsx(Drawer.Trigger, {
2632
+ "data-slot": "drawer-trigger",
2633
+ asChild: true,
2634
+ children: trigger
2635
+ }),
2636
+ /*#__PURE__*/ jsxs(Drawer.Portal, {
2637
+ "data-slot": "drawer-portal",
2638
+ children: [
2639
+ /*#__PURE__*/ jsx(Drawer.Overlay, {
2640
+ "data-slot": "drawer-overlay",
2641
+ className: Drawer_styles_css_overlay
2642
+ }),
2643
+ /*#__PURE__*/ jsxs(Drawer.Content, {
2644
+ "data-slot": "drawer-content",
2645
+ className: clsx('group/drawer-content', Drawer_styles_css_content, className),
2646
+ children: [
2647
+ /*#__PURE__*/ jsx("div", {
2648
+ className: dragHandle
2649
+ }),
2650
+ /*#__PURE__*/ jsxs("div", {
2651
+ "data-slot": "drawer-header",
2652
+ className: Drawer_styles_css_header,
2653
+ children: [
2654
+ /*#__PURE__*/ jsx(Drawer.Title, {
2655
+ "data-slot": "drawer-title",
2656
+ className: Drawer_styles_css_title,
2657
+ children: title
2658
+ }),
2659
+ /*#__PURE__*/ jsx(Drawer.Description, {
2660
+ "data-slot": "drawer-description",
2661
+ className: Drawer_styles_css_description,
2662
+ children: description
2663
+ })
2664
+ ]
2665
+ }),
2666
+ children,
2667
+ /*#__PURE__*/ jsxs("div", {
2668
+ "data-slot": "drawer-footer",
2669
+ className: Drawer_styles_css_footer,
2670
+ children: [
2671
+ footer,
2672
+ closeButton && /*#__PURE__*/ jsx(Drawer.Close, {
2673
+ "data-slot": "drawer-close",
2674
+ asChild: true,
2675
+ children: closeButton
2676
+ })
2677
+ ]
2678
+ })
2679
+ ]
2680
+ })
2681
+ ]
2682
+ })
2683
+ ]
2684
+ });
2685
+ var Empty_styles_css_content = 'style__e4li7y7';
2686
+ var Empty_styles_css_description = 'style__e4li7y6';
2687
+ var Empty_styles_css_header = 'style__e4li7y1';
2688
+ var styles_css_media = 'style__e4li7y2';
2689
+ var mediaVariants = {
2690
+ default: 'default__e4li7y3',
2691
+ icon: 'icon__e4li7y4'
2692
+ };
2693
+ var Empty_styles_css_root = 'style__e4li7y0';
2694
+ var Empty_styles_css_title = 'style__e4li7y5';
2695
+ function Empty({ className, ...props }) {
2696
+ return /*#__PURE__*/ jsx("div", {
2697
+ "data-slot": "empty",
2698
+ className: clsx(Empty_styles_css_root, className),
2699
+ ...props
2700
+ });
2701
+ }
2702
+ function Empty_Header({ className, ...props }) {
2703
+ return /*#__PURE__*/ jsx("div", {
2704
+ "data-slot": "empty-header",
2705
+ className: clsx(Empty_styles_css_header, className),
2706
+ ...props
2707
+ });
2708
+ }
2709
+ function Empty_Media({ className, variant = 'default', ...props }) {
2710
+ return /*#__PURE__*/ jsx("div", {
2711
+ "data-slot": "empty-media",
2712
+ "data-variant": variant,
2713
+ className: clsx(styles_css_media, mediaVariants[variant], className),
2714
+ ...props
2715
+ });
2716
+ }
2717
+ function Empty_Title({ className, ...props }) {
2718
+ return /*#__PURE__*/ jsx("div", {
2719
+ "data-slot": "empty-title",
2720
+ className: clsx(Empty_styles_css_title, className),
2721
+ ...props
2722
+ });
2723
+ }
2724
+ function Empty_Description({ className, ...props }) {
2725
+ return /*#__PURE__*/ jsx("div", {
2726
+ "data-slot": "empty-description",
2727
+ className: clsx(Empty_styles_css_description, className),
2728
+ ...props
2729
+ });
2730
+ }
2731
+ function Empty_Content({ className, ...props }) {
2732
+ return /*#__PURE__*/ jsx("div", {
2733
+ "data-slot": "empty-content",
2734
+ className: clsx(Empty_styles_css_content, className),
2735
+ ...props
2736
+ });
2737
+ }
2738
+ Empty.Header = Empty_Header;
2739
+ Empty.Media = Empty_Media;
2740
+ Empty.Title = Empty_Title;
2741
+ Empty.Description = Empty_Description;
2742
+ Empty.Content = Empty_Content;
2743
+ var arrow = 'style__a5l83v4';
2744
+ var arrowLeft = 'style__a5l83v5';
2745
+ var arrowRight = 'style__a5l83v6';
2746
+ var carousel = 'style__a5l83v0';
2747
+ var carouselInner = 'style__a5l83v1';
2748
+ var ImageCarousel_styles_css_image = 'style__a5l83v3';
2749
+ var styles_css_indicator = 'style__a5l83v8';
2750
+ var indicators = 'style__a5l83v7';
2751
+ var slide = 'style__a5l83v2';
2752
+ const ImageCarousel = ({ images = [], autoPlay = false, interval = 5000 })=>{
2753
+ const [currentIndex, setCurrentIndex] = useState(0);
2754
+ const goToPrevious = ()=>{
2755
+ setCurrentIndex((prevIndex)=>0 === prevIndex ? images.length - 1 : prevIndex - 1);
2756
+ };
2757
+ const goToNext = ()=>{
2758
+ setCurrentIndex((prevIndex)=>prevIndex === images.length - 1 ? 0 : prevIndex + 1);
2759
+ };
2760
+ const goToSlide = (index)=>{
2761
+ setCurrentIndex(index);
2762
+ };
2763
+ useEffect(()=>{
2764
+ if (!autoPlay) return;
2765
+ const timer = setInterval(()=>{
2766
+ setCurrentIndex((prevIndex)=>prevIndex === images.length - 1 ? 0 : prevIndex + 1);
2767
+ }, interval);
2768
+ return ()=>clearInterval(timer);
2769
+ }, [
2770
+ autoPlay,
2771
+ images.length,
2772
+ interval
2773
+ ]);
2774
+ if (0 === images.length) return /*#__PURE__*/ jsx("div", {
2775
+ className: carousel,
2776
+ children: "Нет изображений для отображения"
2777
+ });
2778
+ return /*#__PURE__*/ jsxs("div", {
2779
+ className: carousel,
2780
+ children: [
2781
+ /*#__PURE__*/ jsx("div", {
2782
+ className: carouselInner,
2783
+ style: {
2784
+ transform: `translateX(-${100 * currentIndex}%)`
2785
+ },
2786
+ children: images.map((image, index)=>/*#__PURE__*/ jsx("div", {
2787
+ className: slide,
2788
+ children: /*#__PURE__*/ jsx("img", {
2789
+ src: image.src,
2790
+ alt: image.alt || `Slide ${index + 1}`,
2791
+ className: ImageCarousel_styles_css_image
2792
+ })
2793
+ }, image.src))
2794
+ }),
2795
+ images.length > 1 && /*#__PURE__*/ jsxs(Fragment, {
2796
+ children: [
2797
+ /*#__PURE__*/ jsx("button", {
2798
+ type: "button",
2799
+ className: clsx(arrow, arrowLeft),
2800
+ onClick: goToPrevious,
2801
+ children: /*#__PURE__*/ jsx(ChevronLeft, {
2802
+ size: 24
2803
+ })
2804
+ }),
2805
+ /*#__PURE__*/ jsx("button", {
2806
+ type: "button",
2807
+ className: clsx(arrow, arrowRight),
2808
+ onClick: goToNext,
2809
+ children: /*#__PURE__*/ jsx(ChevronRight, {
2810
+ size: 24
2811
+ })
2812
+ }),
2813
+ /*#__PURE__*/ jsx("div", {
2814
+ className: indicators,
2815
+ children: images.map(({ src }, index)=>/*#__PURE__*/ jsx("button", {
2816
+ type: "button",
2817
+ className: `${styles_css_indicator} ${currentIndex === index ? 'active' : ''}`,
2818
+ onClick: ()=>goToSlide(index)
2819
+ }, src))
2820
+ })
2821
+ ]
2822
+ })
2823
+ ]
2824
+ });
2825
+ };
2826
+ var separatorClass = 'style__te1pgr0';
2827
+ const Separator_Separator = ({ separator = '•', ...props })=>/*#__PURE__*/ jsx("div", {
2828
+ ...props,
2829
+ children: /*#__PURE__*/ jsx("span", {
2830
+ className: separatorClass,
2831
+ children: separator
2832
+ })
2833
+ });
2834
+ var active = 'style__rtks2g1';
2835
+ var caret = 'style__rtks2g4';
2836
+ var caretContainer = 'style__rtks2g2';
2837
+ var styles_css_slot = 'style__rtks2g0';
2838
+ const Slot = ({ char, hasFakeCaret, isActive, ...props })=>/*#__PURE__*/ jsxs("div", {
2839
+ className: clsx(styles_css_slot, {
2840
+ [active]: isActive
2841
+ }),
2842
+ ...props,
2843
+ children: [
2844
+ char,
2845
+ hasFakeCaret && /*#__PURE__*/ jsx("div", {
2846
+ className: caretContainer,
2847
+ children: /*#__PURE__*/ jsx("div", {
2848
+ className: caret
2849
+ })
2850
+ })
2851
+ ]
2852
+ });
2853
+ var InputOTP_styles_css_container = 'style__1iixe0l0';
2854
+ var InputOTP_styles_css_disabled = 'style__1iixe0l3';
2855
+ var styles_css_group = 'style__1iixe0l2';
2856
+ var styles_css_input = 'style__1iixe0l1';
2857
+ const InputOTP = ({ className, containerClassName, disabled, ...props })=>/*#__PURE__*/ jsx(OTPInput, {
2858
+ containerClassName: clsx(InputOTP_styles_css_container, {
2859
+ [InputOTP_styles_css_disabled]: disabled
2860
+ }, containerClassName),
2861
+ className: clsx(styles_css_input, className),
2862
+ render: ({ slots })=>{
2863
+ if (slots.length % 2 !== 0) return /*#__PURE__*/ jsx("div", {
2864
+ className: styles_css_group,
2865
+ children: slots.map((slot, index)=>/*#__PURE__*/ jsx(Slot, {
2866
+ ...slot
2867
+ }, `${index.toString()}-${slot.char}`))
2868
+ });
2869
+ return /*#__PURE__*/ jsxs(Fragment, {
2870
+ children: [
2871
+ /*#__PURE__*/ jsx("div", {
2872
+ className: styles_css_group,
2873
+ children: slots.slice(0, slots.length / 2).map((slot, idx)=>/*#__PURE__*/ jsx(Slot, {
2874
+ ...slot
2875
+ }, `${idx.toString()}-${slot.char}`))
2876
+ }),
2877
+ /*#__PURE__*/ jsx(Separator_Separator, {}),
2878
+ /*#__PURE__*/ jsx("div", {
2879
+ className: styles_css_group,
2880
+ children: slots.slice(slots.length / 2).map((slot, idx)=>/*#__PURE__*/ jsx(Slot, {
2881
+ ...slot
2882
+ }, `${idx.toString()}-${slot.char}`))
2883
+ })
2884
+ ]
2885
+ });
2886
+ },
2887
+ ...props
2888
+ });
2889
+ var constants_NotificationVariantTypes = /*#__PURE__*/ function(NotificationVariantTypes) {
2890
+ NotificationVariantTypes["info"] = "info";
2891
+ NotificationVariantTypes["success"] = "success";
2892
+ NotificationVariantTypes["warning"] = "warning";
2893
+ NotificationVariantTypes["error"] = "error";
2894
+ return NotificationVariantTypes;
2895
+ }({});
2896
+ const NOTIFICATION_POSITIONS = {
2897
+ topRight: 'top-right',
2898
+ topLeft: 'top-left',
2899
+ bottomRight: 'bottom-right',
2900
+ bottomLeft: 'bottom-left',
2901
+ topCenter: 'top-center',
2902
+ bottomCenter: 'bottom-center'
2903
+ };
2904
+ const NOTIFY_CLASSNAME = 'notify';
2905
+ class Notification {
2906
+ service;
2907
+ constructor(sonner){
2908
+ this.service = sonner;
2909
+ }
2910
+ message(title, message) {
2911
+ return this.service.message(title, {
2912
+ description: message
2913
+ });
2914
+ }
2915
+ success = (title)=>this.service.success(title);
2916
+ error = (title)=>this.service.error(title);
2917
+ info = (title)=>this.service.info(title);
2918
+ warning = (title)=>this.service.warning(title);
2919
+ loading = (title)=>this.service.loading(title);
2920
+ dismiss = (id)=>this.service.dismiss(id);
2921
+ custom = (node)=>this.service(node);
2922
+ action = ({ title, buttonLabel, onClick })=>this.service(title, {
2923
+ action: {
2924
+ label: buttonLabel,
2925
+ onClick
2926
+ }
2927
+ });
2928
+ }
2929
+ const notification = new Notification(toast);
2930
+ const NotificationContainer = ({ position = 'bottomRight', ...props })=>/*#__PURE__*/ jsx(Toaster, {
2931
+ duration: 3000,
2932
+ icons: {
2933
+ error: /*#__PURE__*/ jsx(OctagonAlert, {
2934
+ size: 20,
2935
+ color: theme.colors.error
2936
+ }),
2937
+ success: /*#__PURE__*/ jsx(CircleCheck, {
2938
+ size: 20,
2939
+ color: theme.colors.success
2940
+ }),
2941
+ warning: /*#__PURE__*/ jsx(TriangleAlert, {
2942
+ size: 20,
2943
+ color: theme.colors.warning
2944
+ }),
2945
+ info: /*#__PURE__*/ jsx(Info, {
2946
+ size: 20,
2947
+ color: theme.colors.info
2948
+ })
2949
+ },
2950
+ position: NOTIFICATION_POSITIONS[position],
2951
+ ...props
2952
+ });
2953
+ var multipleRows = 'style__t5ji061';
2954
+ var truncate = 'style__t5ji060';
2955
+ var OverflowTypography_styles_css_wrapper = 'style__t5ji062';
2956
+ var wrapperAlignments = {
2957
+ left: 'left__t5ji063',
2958
+ center: 'center__t5ji064',
2959
+ right: 'right__t5ji065',
2960
+ justify: 'justify__t5ji066'
2961
+ };
2962
+ function useIsMobile() {
2963
+ const [isMobile, setIsMobile] = useState(void 0);
2964
+ useEffect(()=>{
2965
+ const mediaQuery = window.matchMedia("(max-width: 767px)");
2966
+ const onChange = ()=>{
2967
+ setIsMobile(window.innerWidth < 768);
2968
+ };
2969
+ mediaQuery.addEventListener('change', onChange);
2970
+ setIsMobile(window.innerWidth < 768);
2971
+ return ()=>mediaQuery.removeEventListener('change', onChange);
2972
+ }, []);
2973
+ return Boolean(isMobile);
2974
+ }
2975
+ const RESIZE_DEBOUNCE_MS = 500;
2976
+ const setRef = (ref, node)=>{
2977
+ if (!ref) return;
2978
+ if ('function' == typeof ref) return void ref(node);
2979
+ ref.current = node;
2980
+ };
2981
+ const useOverflowed = (forwardedRef, hasMultipleRows = false)=>{
2982
+ const localRef = useRef(null);
2983
+ const resizeTimer = useRef(void 0);
2984
+ const [isOverflowed, setOverflowed] = useState(false);
2985
+ const checkOverflow = useCallback(([{ target, contentRect }])=>{
2986
+ const isScrollHeightBigger = target.scrollHeight > Math.round(contentRect.height);
2987
+ const isScrollWidthBigger = target.scrollWidth > Math.round(contentRect.width);
2988
+ const nextIsOverflowed = hasMultipleRows ? isScrollWidthBigger || isScrollHeightBigger : isScrollWidthBigger;
2989
+ setOverflowed((current)=>current === nextIsOverflowed ? current : nextIsOverflowed);
2990
+ }, [
2991
+ hasMultipleRows
2992
+ ]);
2993
+ const ref = useCallback((node)=>{
2994
+ localRef.current = node;
2995
+ setRef(forwardedRef, node);
2996
+ }, [
2997
+ forwardedRef
2998
+ ]);
2999
+ const check = useCallback((_checkKey)=>{
3000
+ const node = localRef.current;
3001
+ if (!node) return;
3002
+ checkOverflow([
3003
+ {
3004
+ target: node,
3005
+ contentRect: node.getBoundingClientRect()
3006
+ }
3007
+ ]);
3008
+ }, [
3009
+ checkOverflow
3010
+ ]);
3011
+ useLayoutEffect(()=>{
3012
+ const node = localRef.current;
3013
+ if (!node) return;
3014
+ check();
3015
+ const resizeObserver = new ResizeObserver((entries)=>{
3016
+ clearTimeout(resizeTimer.current);
3017
+ resizeTimer.current = setTimeout(()=>{
3018
+ checkOverflow(entries);
3019
+ }, RESIZE_DEBOUNCE_MS);
3020
+ });
3021
+ resizeObserver.observe(node);
3022
+ return ()=>{
3023
+ clearTimeout(resizeTimer.current);
3024
+ resizeObserver.unobserve(node);
3025
+ resizeObserver.disconnect();
3026
+ };
3027
+ }, [
3028
+ check,
3029
+ checkOverflow
3030
+ ]);
3031
+ return {
3032
+ check,
3033
+ isOverflowed,
3034
+ ref
3035
+ };
3036
+ };
3037
+ const truncateString = (visibleLastSymbolsCount, label)=>{
3038
+ const firstPartLabel = label.slice(0, -visibleLastSymbolsCount);
3039
+ const secondPartLabel = label.slice(-visibleLastSymbolsCount);
3040
+ return {
3041
+ firstPartLabel,
3042
+ secondPartLabel
3043
+ };
3044
+ };
3045
+ const getRowsCountStyle = (rowsCount, style)=>({
3046
+ ...style,
3047
+ '--rows-count': rowsCount
3048
+ });
3049
+ const OverflowTypography_useLogic_useLogic = ({ text, children, tooltipProps, visibleLastSymbolsCount = 0, rowsCount = 1, ref, style: styleProp })=>{
3050
+ const style = getRowsCountStyle(rowsCount, styleProp);
3051
+ const label = text ?? ('string' == typeof children ? children : void 0);
3052
+ const hasVisibleLastSymbols = Boolean(label && visibleLastSymbolsCount > 0);
3053
+ const hasMultipleRows = hasVisibleLastSymbols ? false : rowsCount > 1;
3054
+ const overflowCheckKey = [
3055
+ label,
3056
+ rowsCount,
3057
+ visibleLastSymbolsCount,
3058
+ hasVisibleLastSymbols
3059
+ ].join('|');
3060
+ const { check, isOverflowed, ref: overflowRef } = useOverflowed(ref, hasMultipleRows);
3061
+ const { content: tooltipContent, text: tooltipText, ...restTooltipProps } = tooltipProps || {};
3062
+ const resolvedTooltipContent = isOverflowed ? tooltipContent ?? tooltipText ?? label : void 0;
3063
+ useLayoutEffect(()=>{
3064
+ check(overflowCheckKey);
3065
+ }, [
3066
+ check,
3067
+ overflowCheckKey
3068
+ ]);
3069
+ return {
3070
+ label,
3071
+ hasVisibleLastSymbols,
3072
+ hasMultipleRows,
3073
+ overflowRef,
3074
+ tooltipContent: resolvedTooltipContent,
3075
+ restTooltipProps,
3076
+ style,
3077
+ visibleLastSymbolsCount
3078
+ };
3079
+ };
3080
+ const OverflowTypography = (props)=>{
3081
+ const { label, hasVisibleLastSymbols, hasMultipleRows, overflowRef, tooltipContent, restTooltipProps, style, visibleLastSymbolsCount } = OverflowTypography_useLogic_useLogic(props);
3082
+ const { align = 'left', className, text, children } = props;
3083
+ if (hasVisibleLastSymbols && label) {
3084
+ const { firstPartLabel, secondPartLabel } = truncateString(visibleLastSymbolsCount, label);
3085
+ return /*#__PURE__*/ jsx(Tooltip, {
3086
+ ...restTooltipProps,
3087
+ arrow: true,
3088
+ content: tooltipContent,
3089
+ children: /*#__PURE__*/ jsxs("div", {
3090
+ className: clsx(OverflowTypography_styles_css_wrapper, wrapperAlignments[align]),
3091
+ "data-slot": "overflow-typography",
3092
+ children: [
3093
+ /*#__PURE__*/ jsx(Typography, {
3094
+ ...props,
3095
+ align: align,
3096
+ className: clsx(truncate, className),
3097
+ component: "span",
3098
+ "data-slot": "overflow-typography-start",
3099
+ display: "block",
3100
+ ref: overflowRef,
3101
+ style: style,
3102
+ children: firstPartLabel
3103
+ }),
3104
+ /*#__PURE__*/ jsx(Typography, {
3105
+ ...props,
3106
+ align: align,
3107
+ className: className,
3108
+ component: "span",
3109
+ "data-slot": "overflow-typography-end",
3110
+ style: style,
3111
+ children: secondPartLabel
3112
+ })
3113
+ ]
3114
+ })
3115
+ });
3116
+ }
3117
+ return /*#__PURE__*/ jsx(Tooltip, {
3118
+ ...restTooltipProps,
3119
+ arrow: true,
3120
+ content: tooltipContent,
3121
+ children: /*#__PURE__*/ jsx(Typography, {
3122
+ ...props,
3123
+ align: align,
3124
+ className: clsx(truncate, hasMultipleRows && multipleRows, className),
3125
+ "data-slot": "overflow-typography",
3126
+ display: "block",
3127
+ ref: overflowRef,
3128
+ style: style,
3129
+ children: text ?? children
3130
+ })
3131
+ });
3132
+ };
3133
+ const PAGE_CONTENT_CLASSNAME = 'page-content';
3134
+ const PAGE_HEADER_CLASSNAME = 'page_header';
3135
+ const PAGE_ASIDE_CLASSNAME = 'page_aside';
3136
+ var Aside_styles_css_rootClass = 'PageLayoutAside__1un4hm80';
3137
+ const Aside = ({ children, className })=>/*#__PURE__*/ jsx("aside", {
3138
+ className: clsx(Aside_styles_css_rootClass, className, PAGE_ASIDE_CLASSNAME),
3139
+ children: children
3140
+ });
3141
+ var fullHeightClass = 'style__1hr0uh01';
3142
+ var Content_styles_css_rootClass = 'style__1hr0uh00';
3143
+ const Content_Content_Content = (props)=>{
3144
+ const { className, children, isFullHeight = true } = props;
3145
+ return /*#__PURE__*/ jsx("article", {
3146
+ className: clsx(PAGE_CONTENT_CLASSNAME, Content_styles_css_rootClass, {
3147
+ [fullHeightClass]: isFullHeight
3148
+ }, className),
3149
+ children: children
3150
+ });
3151
+ };
3152
+ var Footer_styles_css_rootClass = 'style__1bd8jnw0';
3153
+ const Footer_Footer_Footer = (props)=>{
3154
+ const { children, className } = props;
3155
+ return /*#__PURE__*/ jsx("footer", {
3156
+ className: clsx(Footer_styles_css_rootClass, className),
3157
+ children: children
3158
+ });
3159
+ };
3160
+ var styles_css_actionsClass = 'style__nvcxbd3';
3161
+ var breadcrumbsClass = 'Breadcrumbs__nvcxbd0';
3162
+ var buttonsClass = 'style__nvcxbd2';
3163
+ var Header_styles_css_rootClass = 'style__nvcxbd1';
3164
+ var subtitleClass = 'style__nvcxbd6';
3165
+ var subtitleContainerClass = 'style__nvcxbd7';
3166
+ var styles_css_titleClass = 'style__nvcxbd4';
3167
+ var titleContainerClass = 'style__nvcxbd5';
3168
+ const Header_Header_Header = (props)=>{
3169
+ const { title, subtitle, breadcrumbs, actions, backButton, className } = props;
3170
+ const { pinned, togglePinned } = useDashboard();
3171
+ useEffect(()=>{
3172
+ if ('string' == typeof title) document.title = title;
3173
+ }, [
3174
+ title
3175
+ ]);
3176
+ return /*#__PURE__*/ jsxs("header", {
3177
+ className: clsx(PAGE_HEADER_CLASSNAME, Header_styles_css_rootClass, className),
3178
+ children: [
3179
+ /*#__PURE__*/ jsxs("div", {
3180
+ className: buttonsClass,
3181
+ children: [
3182
+ /*#__PURE__*/ jsx(Tooltip, {
3183
+ text: pinned ? 'Развернуть' : 'Свернуть',
3184
+ children: /*#__PURE__*/ jsx(Button_Button, {
3185
+ variant: "ghost",
3186
+ size: "icon",
3187
+ onClick: togglePinned,
3188
+ children: pinned ? /*#__PURE__*/ jsx(PanelLeftOpen, {}) : /*#__PURE__*/ jsx(PanelLeftClose, {})
3189
+ })
3190
+ }),
3191
+ backButton && /*#__PURE__*/ jsx(Tooltip, {
3192
+ text: "Назад",
3193
+ children: /*#__PURE__*/ jsx(Button_Button, {
3194
+ ...backButton,
3195
+ variant: "ghost",
3196
+ children: /*#__PURE__*/ jsx(ChevronLeft, {})
3197
+ })
3198
+ })
3199
+ ]
3200
+ }),
3201
+ breadcrumbs && /*#__PURE__*/ jsx("div", {
3202
+ className: breadcrumbsClass,
3203
+ children: breadcrumbs
3204
+ }),
3205
+ /*#__PURE__*/ jsx("div", {
3206
+ className: styles_css_actionsClass,
3207
+ children: actions
3208
+ }),
3209
+ 'string' == typeof title ? /*#__PURE__*/ jsx(Typography, {
3210
+ className: styles_css_titleClass,
3211
+ component: "h1",
3212
+ variant: "h3",
3213
+ "aria-level": 1,
3214
+ children: title
3215
+ }) : /*#__PURE__*/ jsx("div", {
3216
+ className: titleContainerClass,
3217
+ children: title
3218
+ }),
3219
+ subtitle && 'string' == typeof subtitle && /*#__PURE__*/ jsx(Typography, {
3220
+ className: subtitleClass,
3221
+ "aria-level": 2,
3222
+ children: subtitle
3223
+ }),
3224
+ subtitle && 'string' != typeof subtitle && /*#__PURE__*/ jsx("div", {
3225
+ className: subtitleContainerClass,
3226
+ children: subtitle
3227
+ })
3228
+ ]
3229
+ });
3230
+ };
3231
+ var PageLayout_styles_css_rootClass = 'style__adrl250';
3232
+ const PageLayout = ({ children, className })=>/*#__PURE__*/ jsx("div", {
3233
+ className: clsx(PageLayout_styles_css_rootClass, className),
3234
+ children: children
3235
+ });
3236
+ PageLayout.Header = Header_Header_Header;
3237
+ PageLayout.Content = Content_Content_Content;
3238
+ PageLayout.Footer = Footer_Footer_Footer;
3239
+ PageLayout.Aside = Aside;
3240
+ var ellipsisSpan = 'style__p708oq1';
3241
+ var paginationContainer = 'style__p708oq0';
3242
+ const useLogic_range = (start, end)=>{
3243
+ const length = end - start + 1;
3244
+ return Array.from({
3245
+ length
3246
+ }, (_, idx)=>idx + start);
3247
+ };
3248
+ const Pagination_useLogic_useLogic = ({ totalCount, pageSize, siblingCount = 1, currentPage })=>{
3249
+ const paginationRange = useMemo(()=>{
3250
+ if (pageSize <= 0 || totalCount <= 0) return [];
3251
+ const totalPageCount = Math.ceil(totalCount / pageSize);
3252
+ const totalPageNumbersToShow = siblingCount + 5;
3253
+ if (totalPageNumbersToShow >= totalPageCount) return useLogic_range(1, totalPageCount);
3254
+ const leftSibling = Math.max(currentPage - siblingCount, 1);
3255
+ const rightSibling = Math.min(currentPage + siblingCount, totalPageCount);
3256
+ const showLeftDots = leftSibling > 2;
3257
+ const showRightDots = rightSibling < totalPageCount - 2;
3258
+ const firstPage = 1;
3259
+ const lastPage = totalPageCount;
3260
+ if (!showLeftDots && showRightDots) {
3261
+ const visiblePageCountBeforeDots = 3 + 2 * siblingCount;
3262
+ const leftRange = useLogic_range(1, visiblePageCountBeforeDots);
3263
+ return [
3264
+ ...leftRange,
3265
+ null,
3266
+ totalPageCount
3267
+ ];
3268
+ }
3269
+ if (showLeftDots && !showRightDots) {
3270
+ const visiblePageCountAfterDots = 3 + 2 * siblingCount;
3271
+ const rightRange = useLogic_range(totalPageCount - visiblePageCountAfterDots + 1, totalPageCount);
3272
+ return [
3273
+ firstPage,
3274
+ null,
3275
+ ...rightRange
3276
+ ];
3277
+ }
3278
+ if (showLeftDots && showRightDots) {
3279
+ const middleRange = useLogic_range(leftSibling, rightSibling);
3280
+ return [
3281
+ firstPage,
3282
+ null,
3283
+ ...middleRange,
3284
+ null,
3285
+ lastPage
3286
+ ];
3287
+ }
3288
+ return [];
3289
+ }, [
3290
+ totalCount,
3291
+ pageSize,
3292
+ siblingCount,
3293
+ currentPage
3294
+ ]);
3295
+ return paginationRange;
3296
+ };
3297
+ function Pagination(props) {
3298
+ const { onPageChange, totalCount, siblingCount = 1, currentPage, pageSize, size = 'icon' } = props;
3299
+ const paginationRange = Pagination_useLogic_useLogic({
3300
+ currentPage,
3301
+ totalCount,
3302
+ siblingCount,
3303
+ pageSize
3304
+ });
3305
+ if (0 === currentPage || paginationRange && paginationRange.length < 2) return null;
3306
+ const onNext = ()=>{
3307
+ onPageChange(currentPage + 1);
3308
+ };
3309
+ const onPrevious = ()=>{
3310
+ onPageChange(currentPage - 1);
3311
+ };
3312
+ const lastPage = paginationRange.at(-1);
3313
+ return /*#__PURE__*/ jsxs("nav", {
3314
+ className: paginationContainer,
3315
+ children: [
3316
+ /*#__PURE__*/ jsx(Button_Button, {
3317
+ variant: "ghost",
3318
+ size: size,
3319
+ onClick: onPrevious,
3320
+ disabled: 1 === currentPage,
3321
+ children: /*#__PURE__*/ jsx(ChevronLeft, {})
3322
+ }),
3323
+ paginationRange?.map((pageNumber, index)=>{
3324
+ if (!pageNumber) return /*#__PURE__*/ jsx("span", {
3325
+ className: ellipsisSpan,
3326
+ children: /*#__PURE__*/ jsx(external_lucide_react_Ellipsis, {})
3327
+ });
3328
+ return /*#__PURE__*/ jsx(Button_Button, {
3329
+ size: size,
3330
+ variant: pageNumber === currentPage ? 'default' : 'outline',
3331
+ onClick: ()=>onPageChange(+pageNumber),
3332
+ children: pageNumber
3333
+ }, `${pageNumber}${index.toString()}`);
3334
+ }),
3335
+ /*#__PURE__*/ jsx(Button_Button, {
3336
+ variant: "ghost",
3337
+ size: size,
3338
+ onClick: onNext,
3339
+ disabled: currentPage === lastPage,
3340
+ children: /*#__PURE__*/ jsx(ChevronRight, {})
3341
+ })
3342
+ ]
3343
+ });
3344
+ }
3345
+ const MONTHS = [
3346
+ 'Янв.',
3347
+ 'Фев.',
3348
+ 'Мар.',
3349
+ 'Апр.',
3350
+ 'Май',
3351
+ 'Июн.',
3352
+ 'Июл.',
3353
+ 'Авг.',
3354
+ 'Сен.',
3355
+ 'Окт.',
3356
+ 'Ноя.',
3357
+ 'Дек.'
3358
+ ];
3359
+ const QUARTERS = [
3360
+ 'I квартал',
3361
+ 'II квартал',
3362
+ 'III квартал',
3363
+ 'IV квартал'
3364
+ ];
3365
+ var styles_css_months = 'style__1izfmw31';
3366
+ var quarters = 'style__1izfmw32';
3367
+ var PeriodPicker_styles_css_wrapper = 'style__1izfmw30';
3368
+ const getQuarter = (month)=>Math.ceil(month / 3);
3369
+ const getQuarterLabel = (date)=>{
3370
+ if (!date) return '';
3371
+ return `${QUARTERS[getQuarter(date.getMonth())]} ${date.getFullYear()}`;
3372
+ };
3373
+ function YearsDropdown({ year, onSelect, minDate, maxDate }) {
3374
+ const years = Array.from({
3375
+ length: maxDate.getFullYear() - minDate.getFullYear() + 1
3376
+ }, (_, index)=>minDate.getFullYear() + index);
3377
+ const onChange = (year)=>{
3378
+ onSelect?.(Number(year));
3379
+ };
3380
+ return /*#__PURE__*/ jsxs(Select, {
3381
+ onValueChange: onChange,
3382
+ value: year.toString(),
3383
+ children: [
3384
+ /*#__PURE__*/ jsx(SelectTrigger, {
3385
+ children: /*#__PURE__*/ jsx(SelectValue, {
3386
+ placeholder: year.toString()
3387
+ })
3388
+ }),
3389
+ /*#__PURE__*/ jsx(SelectContent, {
3390
+ children: years.map((value)=>/*#__PURE__*/ jsx(SelectItem, {
3391
+ value: value.toString(),
3392
+ children: /*#__PURE__*/ jsx(Typography, {
3393
+ align: "center",
3394
+ variant: "subtitle1",
3395
+ transform: "capitalize",
3396
+ children: value
3397
+ })
3398
+ }, value))
3399
+ })
3400
+ ]
3401
+ });
3402
+ }
3403
+ const PeriodPicker = (props)=>{
3404
+ const { label, disabled = false, value, onSelect, type = 'month', placeholder = 'month' === type ? 'Выберите месяц' : 'Выберите квартал', error, helperText, max = new Date(2050, 0, 1), min = new Date(2000, 0, 1), className, size, fullWidth, name } = props;
3405
+ const now = new Date();
3406
+ const [isOpen, setIsOpen] = useState(false);
3407
+ const [year, setYear] = useState(now.getFullYear());
3408
+ const handleClose = ()=>{
3409
+ setIsOpen(false);
3410
+ };
3411
+ const handleSelect = (date)=>{
3412
+ onSelect?.(date);
3413
+ handleClose();
3414
+ };
3415
+ const textValue = 'month' === type ? value?.toLocaleDateString('ru-RU', {
3416
+ month: 'long',
3417
+ year: 'numeric'
3418
+ }) : getQuarterLabel(value);
3419
+ useEffect(()=>{
3420
+ if (value) setYear(value.getFullYear());
3421
+ }, [
3422
+ value
3423
+ ]);
3424
+ return /*#__PURE__*/ jsxs(Popover_Popover, {
3425
+ open: isOpen,
3426
+ onOpenChange: setIsOpen,
3427
+ children: [
3428
+ /*#__PURE__*/ jsx(TextField, {
3429
+ label: label,
3430
+ value: textValue,
3431
+ disabled: disabled,
3432
+ size: size,
3433
+ fullWidth: fullWidth,
3434
+ name: name,
3435
+ endAdornment: /*#__PURE__*/ jsx(Popover_Popover.Trigger, {
3436
+ render: /*#__PURE__*/ jsx(Button_Button, {
3437
+ disabled: disabled,
3438
+ variant: "ghost",
3439
+ size: "icon",
3440
+ children: /*#__PURE__*/ jsx(Calendar1, {})
3441
+ })
3442
+ }),
3443
+ placeholder: placeholder,
3444
+ error: error,
3445
+ helperText: helperText,
3446
+ className: className
3447
+ }),
3448
+ /*#__PURE__*/ jsx(Popover_Popover.Content, {
3449
+ align: "end",
3450
+ alignOffset: -10,
3451
+ side: "bottom",
3452
+ children: /*#__PURE__*/ jsxs("div", {
3453
+ className: PeriodPicker_styles_css_wrapper,
3454
+ children: [
3455
+ /*#__PURE__*/ jsx(YearsDropdown, {
3456
+ year: year,
3457
+ onSelect: setYear,
3458
+ minDate: min,
3459
+ maxDate: max
3460
+ }),
3461
+ 'month' === type ? /*#__PURE__*/ jsx("div", {
3462
+ className: styles_css_months,
3463
+ children: MONTHS.map((label, index)=>{
3464
+ const date = new Date(year, index, value?.getDate() || 1);
3465
+ return /*#__PURE__*/ jsx(Button_Button, {
3466
+ variant: value?.getMonth() === index && value.getFullYear() === date.getFullYear() ? 'default' : 'ghost',
3467
+ disabled: date < min || date > max,
3468
+ onClick: ()=>handleSelect(date),
3469
+ children: label
3470
+ }, label);
3471
+ })
3472
+ }) : /*#__PURE__*/ jsx("div", {
3473
+ className: quarters,
3474
+ children: QUARTERS.map((label, index)=>{
3475
+ const monthIndex = 3 * index;
3476
+ const date = new Date(year, monthIndex, 1);
3477
+ return /*#__PURE__*/ jsx(Button_Button, {
3478
+ variant: value && [
3479
+ getQuarter(value.getMonth()) === index,
3480
+ value.getFullYear() === date.getFullYear()
3481
+ ].every(Boolean) ? 'default' : 'ghost',
3482
+ disabled: date < min || date > max,
3483
+ onClick: ()=>handleSelect(date),
3484
+ children: label
3485
+ }, label);
3486
+ })
3487
+ })
3488
+ ]
3489
+ })
3490
+ })
3491
+ ]
3492
+ });
3493
+ };
3494
+ var iconClass = 'style__ia95d14';
3495
+ var indicatorClass = 'style__ia95d13';
3496
+ var styles_css_itemClass = 'style__ia95d12';
3497
+ var itemWrapperClass = 'style__ia95d11';
3498
+ var radioGroupClass = 'RadioGroup__ia95d10';
3499
+ const RadioGroup_RadioGroup = ({ className, ...props })=>/*#__PURE__*/ jsx(react_radio_group_Root, {
3500
+ "data-slot": "radio-group",
3501
+ className: clsx_0(radioGroupClass, className),
3502
+ ...props
3503
+ });
3504
+ const RadioGroupItem = ({ className, label, ...props })=>/*#__PURE__*/ jsxs("div", {
3505
+ className: itemWrapperClass,
3506
+ children: [
3507
+ /*#__PURE__*/ jsx(react_radio_group_Item, {
3508
+ "data-slot": "radio-group-item",
3509
+ id: props.id || props.value,
3510
+ className: clsx(styles_css_itemClass, className),
3511
+ ...props,
3512
+ children: /*#__PURE__*/ jsx(Indicator, {
3513
+ "data-slot": "radio-group-indicator",
3514
+ className: indicatorClass,
3515
+ children: /*#__PURE__*/ jsx(CircleIcon, {
3516
+ className: iconClass
3517
+ })
3518
+ })
3519
+ }),
3520
+ /*#__PURE__*/ jsx(Label_Label, {
3521
+ htmlFor: props.id || props.value,
3522
+ "data-slot": "radio-group-label",
3523
+ children: label
3524
+ })
3525
+ ]
3526
+ });
3527
+ var styles_css_control = 'style__h9oy581';
3528
+ var styles_css_range = 'style__h9oy583';
3529
+ var Slider_styles_css_root = 'style__h9oy580';
3530
+ var styles_css_thumb = 'style__h9oy584';
3531
+ var track = 'style__h9oy582';
3532
+ function Slider_Slider({ className, defaultValue, value, min = 0, max = 100, onValueCommit, onValueCommitted, ...props }) {
3533
+ const values = __rspack_external_react.useMemo(()=>Array.isArray(value) ? value : Array.isArray(defaultValue) ? defaultValue : [
3534
+ min,
3535
+ max
3536
+ ], [
3537
+ value,
3538
+ defaultValue,
3539
+ min,
3540
+ max
3541
+ ]);
3542
+ const thumbs = __rspack_external_react.useMemo(()=>Array.from({
3543
+ length: values.length
3544
+ }, (_, thumbIndex)=>({
3545
+ key: `slider-thumb-${thumbIndex}`,
3546
+ index: thumbIndex
3547
+ })), [
3548
+ values.length
3549
+ ]);
3550
+ return /*#__PURE__*/ jsx(Slider.Root, {
3551
+ "data-slot": "slider",
3552
+ className: clsx(Slider_styles_css_root, className),
3553
+ defaultValue: defaultValue,
3554
+ value: value,
3555
+ min: min,
3556
+ max: max,
3557
+ thumbAlignment: "edge",
3558
+ onValueCommitted: (committedValue, eventDetails)=>{
3559
+ onValueCommitted?.(committedValue, eventDetails);
3560
+ onValueCommit?.(committedValue);
3561
+ },
3562
+ ...props,
3563
+ children: /*#__PURE__*/ jsxs(Slider.Control, {
3564
+ className: styles_css_control,
3565
+ children: [
3566
+ /*#__PURE__*/ jsx(Slider.Track, {
3567
+ "data-slot": "slider-track",
3568
+ className: track,
3569
+ children: /*#__PURE__*/ jsx(Slider.Indicator, {
3570
+ "data-slot": "slider-range",
3571
+ className: styles_css_range
3572
+ })
3573
+ }),
3574
+ thumbs.map((thumb)=>/*#__PURE__*/ jsx(Slider.Thumb, {
3575
+ "data-slot": "slider-thumb",
3576
+ index: thumb.index,
3577
+ className: styles_css_thumb
3578
+ }, thumb.key))
3579
+ ]
3580
+ })
3581
+ });
3582
+ }
3583
+ var activeClass = 'style__1pnwkko1';
3584
+ var RangeInput_styles_css_container = 'style__1pnwkko0';
3585
+ var inputClass = 'style__1pnwkko6';
3586
+ var RangeInput_styles_css_sizes = {
3587
+ sm: 'sm__1pnwkko2',
3588
+ md: 'md__1pnwkko3',
3589
+ lg: 'lg__1pnwkko4'
3590
+ };
3591
+ var sliderClass = 'style__1pnwkko7';
3592
+ var styles_css_textClass = 'style__1pnwkko5';
3593
+ const RangeInput_useLogic_useLogic_useLogic = ({ min, max, maxValue, minValue, onChange })=>{
3594
+ const minId = useId();
3595
+ const maxId = useId();
3596
+ const [minVal, setMinVal] = useState(min);
3597
+ const [maxVal, setMaxVal] = useState(max);
3598
+ const onValueChange = (newValue)=>{
3599
+ if (newValue[0] === newValue[1]) return void onChange(newValue[0], newValue[1]);
3600
+ setMinVal(newValue[0]);
3601
+ setMaxVal(newValue[1]);
3602
+ };
3603
+ const onMinValueChange = (event)=>{
3604
+ const { value } = event.target;
3605
+ if (!Number.isNaN(+value)) setMinVal(+value);
3606
+ };
3607
+ const onMaxValueChange = (event)=>{
3608
+ const { value } = event.target;
3609
+ if (!Number.isNaN(value)) setMaxVal(+value);
3610
+ };
3611
+ const onKeyDown = (event)=>{
3612
+ if ('Enter' === event.key) {
3613
+ const minValue = minVal >= min && minVal <= max ? minVal : min;
3614
+ const maxValue = maxVal >= min && maxVal <= max ? maxVal : max;
3615
+ onChange(minValue, maxValue);
3616
+ }
3617
+ };
3618
+ const onConfirm = (value)=>{
3619
+ onChange(value[0], value[1]);
3620
+ };
3621
+ useEffect(()=>{
3622
+ setMinVal(minValue ? minValue : min);
3623
+ setMaxVal(maxValue ? maxValue : max);
3624
+ }, [
3625
+ minValue,
3626
+ maxValue,
3627
+ min,
3628
+ max
3629
+ ]);
3630
+ return {
3631
+ maxId,
3632
+ minId,
3633
+ minVal,
3634
+ maxVal,
3635
+ onValueChange,
3636
+ onMinValueChange,
3637
+ onMaxValueChange,
3638
+ onKeyDown,
3639
+ onConfirm
3640
+ };
3641
+ };
3642
+ function RangeInput({ min, max, onChange, minValue, maxValue, width = 150, unit = '', size = 'md', className, isActive, minInputRef, maxInputRef }) {
3643
+ const { onMinValueChange, onMaxValueChange, minVal, maxVal, onKeyDown, onValueChange, onConfirm, minId, maxId } = RangeInput_useLogic_useLogic_useLogic({
3644
+ min,
3645
+ max,
3646
+ maxValue,
3647
+ minValue,
3648
+ onChange
3649
+ });
3650
+ return /*#__PURE__*/ jsxs("div", {
3651
+ className: clsx(RangeInput_styles_css_container, RangeInput_styles_css_sizes[size], {
3652
+ [activeClass]: isActive
3653
+ }, className),
3654
+ style: {
3655
+ width
3656
+ },
3657
+ children: [
3658
+ /*#__PURE__*/ jsx(Typography, {
3659
+ className: styles_css_textClass,
3660
+ color: "disabled",
3661
+ variant: "caption",
3662
+ children: "от"
3663
+ }),
3664
+ /*#__PURE__*/ jsx("input", {
3665
+ className: inputClass,
3666
+ type: "text",
3667
+ id: minId,
3668
+ value: minVal,
3669
+ onChange: onMinValueChange,
3670
+ onKeyDown: onKeyDown,
3671
+ ref: minInputRef
3672
+ }),
3673
+ /*#__PURE__*/ jsx(Typography, {
3674
+ className: styles_css_textClass,
3675
+ color: "disabled",
3676
+ variant: "caption",
3677
+ children: "до"
3678
+ }),
3679
+ /*#__PURE__*/ jsx("input", {
3680
+ className: inputClass,
3681
+ type: "text",
3682
+ id: maxId,
3683
+ value: maxVal,
3684
+ onChange: onMaxValueChange,
3685
+ onKeyDown: onKeyDown,
3686
+ ref: maxInputRef
3687
+ }),
3688
+ /*#__PURE__*/ jsx(Typography, {
3689
+ className: styles_css_textClass,
3690
+ color: "disabled",
3691
+ variant: "caption",
3692
+ children: unit
3693
+ }),
3694
+ /*#__PURE__*/ jsx("div", {
3695
+ className: sliderClass,
3696
+ children: /*#__PURE__*/ jsx(Slider_Slider, {
3697
+ min: min,
3698
+ max: max,
3699
+ value: [
3700
+ Number(minVal),
3701
+ Number(maxVal)
3702
+ ],
3703
+ onValueChange: onValueChange,
3704
+ onValueCommit: onConfirm
3705
+ })
3706
+ })
3707
+ ]
3708
+ });
3709
+ }
3710
+ var ScrollTopButton_styles_css_button = 'style__1ou2vjc0';
3711
+ var styles_css_visible = 'style__1ou2vjc1';
3712
+ function ScrollTopButton({ onClick, variant = 'outline', ...props }) {
3713
+ const [isVisible, setIsVisible] = useState(false);
3714
+ const scrollToTop = ()=>{
3715
+ window.scrollTo({
3716
+ top: 0,
3717
+ left: 0,
3718
+ behavior: 'smooth'
3719
+ });
3720
+ };
3721
+ useEffect(()=>{
3722
+ const toggleVisibility = ()=>{
3723
+ window.scrollY > 400 ? setIsVisible(true) : setIsVisible(false);
3724
+ };
3725
+ window.addEventListener('scroll', toggleVisibility);
3726
+ return ()=>{
3727
+ window.removeEventListener('scroll', toggleVisibility);
3728
+ };
3729
+ }, []);
3730
+ return /*#__PURE__*/ jsx(Button_Button, {
3731
+ type: "button",
3732
+ variant: variant,
3733
+ className: clsx(ScrollTopButton_styles_css_button, {
3734
+ [styles_css_visible]: isVisible
3735
+ }),
3736
+ onClick: onClick || scrollToTop,
3737
+ ...props,
3738
+ children: /*#__PURE__*/ jsx(ChevronUp, {})
3739
+ });
3740
+ }
3741
+ var chevron = 'style__5ilg7oe';
3742
+ var Select_styles_css_content = 'style__5ilg7o7';
3743
+ var Select_styles_css_icon = 'style__5ilg7od';
3744
+ var Select_styles_css_item = 'style__5ilg7oa';
3745
+ var itemIndicatorWrapper = 'style__5ilg7ob';
3746
+ var Select_styles_css_label = 'style__5ilg7o9';
3747
+ var scrollButton = 'style__5ilg7o6';
3748
+ var Select_styles_css_separator = 'style__5ilg7oc';
3749
+ var Select_styles_css_sizes = {
3750
+ sm: 'sm__5ilg7o3',
3751
+ md: 'md__5ilg7o4',
3752
+ lg: 'lg__5ilg7o5'
3753
+ };
3754
+ var Select_styles_css_trigger = 'style__5ilg7o2';
3755
+ var viewport = 'style__5ilg7o8';
3756
+ const Select = react_select_Root;
3757
+ const SelectGroup = react_select_Group;
3758
+ const SelectValue = react_select_Value;
3759
+ const SelectTrigger = ({ className, children, size = 'md', ...props })=>/*#__PURE__*/ jsxs(react_select_Trigger, {
3760
+ className: clsx(Select_styles_css_trigger, Select_styles_css_sizes[size], className),
3761
+ ...props,
3762
+ children: [
3763
+ children,
3764
+ /*#__PURE__*/ jsx(Icon, {
3765
+ asChild: true,
3766
+ children: /*#__PURE__*/ jsx(ChevronDown, {
3767
+ className: chevron
3768
+ })
3769
+ })
3770
+ ]
3771
+ });
3772
+ const SelectScrollUpButton = ({ className, ...props })=>/*#__PURE__*/ jsx(ScrollUpButton, {
3773
+ className: clsx(scrollButton, className),
3774
+ ...props,
3775
+ children: /*#__PURE__*/ jsx(ChevronUp, {
3776
+ className: Select_styles_css_icon
3777
+ })
3778
+ });
3779
+ const SelectScrollDownButton = ({ className, ...props })=>/*#__PURE__*/ jsx(ScrollDownButton, {
3780
+ className: clsx(scrollButton, className),
3781
+ ...props,
3782
+ children: /*#__PURE__*/ jsx(ChevronDown, {
3783
+ className: Select_styles_css_icon
3784
+ })
3785
+ });
3786
+ const SelectContent = ({ className, children, position = 'popper', ...props })=>/*#__PURE__*/ jsx(react_select_Portal, {
3787
+ children: /*#__PURE__*/ jsxs(react_select_Content, {
3788
+ className: clsx(Select_styles_css_content, className),
3789
+ position: position,
3790
+ ...props,
3791
+ children: [
3792
+ /*#__PURE__*/ jsx(SelectScrollUpButton, {}),
3793
+ /*#__PURE__*/ jsx(Viewport, {
3794
+ className: viewport,
3795
+ children: children
3796
+ }),
3797
+ /*#__PURE__*/ jsx(SelectScrollDownButton, {})
3798
+ ]
3799
+ })
3800
+ });
3801
+ const SelectLabel = ({ className, ...props })=>/*#__PURE__*/ jsx(react_select_Label, {
3802
+ className: `${Select_styles_css_label} ${className || ''}`,
3803
+ ...props
3804
+ });
3805
+ const SelectItem = ({ className, children, ...props })=>/*#__PURE__*/ jsxs(react_select_Item, {
3806
+ className: `${Select_styles_css_item} ${className || ''}`,
3807
+ ...props,
3808
+ children: [
3809
+ /*#__PURE__*/ jsx("span", {
3810
+ className: itemIndicatorWrapper,
3811
+ children: /*#__PURE__*/ jsx(ItemIndicator, {
3812
+ children: /*#__PURE__*/ jsx(Check, {
3813
+ className: Select_styles_css_icon
3814
+ })
3815
+ })
3816
+ }),
3817
+ /*#__PURE__*/ jsx(ItemText, {
3818
+ children: children
3819
+ })
3820
+ ]
3821
+ });
3822
+ const SelectSeparator = ({ className, ...props })=>/*#__PURE__*/ jsx(react_select_Separator, {
3823
+ className: `${Select_styles_css_separator} ${className || ''}`,
3824
+ ...props
3825
+ });
3826
+ var Sheet_styles_css_closeButton = 'style__5dkj2fc';
3827
+ var styles_css_closeText = 'style__5dkj2fd';
3828
+ var Sheet_styles_css_content = 'style__5dkj2fb';
3829
+ var Sheet_styles_css_description = 'style__5dkj2fh';
3830
+ var Sheet_styles_css_footer = 'style__5dkj2ff';
3831
+ var Sheet_styles_css_header = 'style__5dkj2fe';
3832
+ var Sheet_styles_css_overlay = 'style__5dkj2fa';
3833
+ var Sheet_styles_css_title = 'style__5dkj2fg';
3834
+ function Sheet({ ...props }) {
3835
+ return /*#__PURE__*/ jsx(Dialog.Root, {
3836
+ "data-slot": "sheet",
3837
+ ...props
3838
+ });
3839
+ }
3840
+ function Sheet_Trigger({ ...props }) {
3841
+ return /*#__PURE__*/ jsx(Dialog.Trigger, {
3842
+ "data-slot": "sheet-trigger",
3843
+ ...props
3844
+ });
3845
+ }
3846
+ function Sheet_Close({ ...props }) {
3847
+ return /*#__PURE__*/ jsx(Dialog.Close, {
3848
+ "data-slot": "sheet-close",
3849
+ ...props
3850
+ });
3851
+ }
3852
+ function Sheet_Portal({ ...props }) {
3853
+ return /*#__PURE__*/ jsx(Dialog.Portal, {
3854
+ "data-slot": "sheet-portal",
3855
+ ...props
3856
+ });
3857
+ }
3858
+ function Sheet_Overlay({ className, ...props }) {
3859
+ return /*#__PURE__*/ jsx(Dialog.Backdrop, {
3860
+ "data-slot": "sheet-overlay",
3861
+ className: clsx(Sheet_styles_css_overlay, className),
3862
+ ...props
3863
+ });
3864
+ }
3865
+ function Sheet_Content({ className, children, side = 'right', showCloseButton = true, ...props }) {
3866
+ return /*#__PURE__*/ jsxs(Sheet_Portal, {
3867
+ children: [
3868
+ /*#__PURE__*/ jsx(Sheet_Overlay, {}),
3869
+ /*#__PURE__*/ jsxs(Dialog.Popup, {
3870
+ "data-slot": "sheet-content",
3871
+ "data-side": side,
3872
+ className: clsx(Sheet_styles_css_content, className),
3873
+ ...props,
3874
+ children: [
3875
+ children,
3876
+ showCloseButton && /*#__PURE__*/ jsxs(Dialog.Close, {
3877
+ "data-slot": "sheet-close",
3878
+ render: /*#__PURE__*/ jsx(Button_Button, {
3879
+ variant: "ghost",
3880
+ className: Sheet_styles_css_closeButton,
3881
+ size: "iconSm"
3882
+ }),
3883
+ children: [
3884
+ /*#__PURE__*/ jsx(XIcon, {}),
3885
+ /*#__PURE__*/ jsx("span", {
3886
+ className: styles_css_closeText,
3887
+ children: "Close"
3888
+ })
3889
+ ]
3890
+ })
3891
+ ]
3892
+ })
3893
+ ]
3894
+ });
3895
+ }
3896
+ function Sheet_Header({ className, ...props }) {
3897
+ return /*#__PURE__*/ jsx("div", {
3898
+ "data-slot": "sheet-header",
3899
+ className: clsx(Sheet_styles_css_header, className),
3900
+ ...props
3901
+ });
3902
+ }
3903
+ function Sheet_Footer({ className, ...props }) {
3904
+ return /*#__PURE__*/ jsx("div", {
3905
+ "data-slot": "sheet-footer",
3906
+ className: clsx(Sheet_styles_css_footer, className),
3907
+ ...props
3908
+ });
3909
+ }
3910
+ function Sheet_Title({ className, ...props }) {
3911
+ return /*#__PURE__*/ jsx(Dialog.Title, {
3912
+ "data-slot": "sheet-title",
3913
+ className: clsx(Sheet_styles_css_title, className),
3914
+ ...props
3915
+ });
3916
+ }
3917
+ function Sheet_Description({ className, ...props }) {
3918
+ return /*#__PURE__*/ jsx(Dialog.Description, {
3919
+ "data-slot": "sheet-description",
3920
+ className: clsx(Sheet_styles_css_description, className),
3921
+ ...props
3922
+ });
3923
+ }
3924
+ Sheet.Trigger = Sheet_Trigger;
3925
+ Sheet.Close = Sheet_Close;
3926
+ Sheet.Portal = Sheet_Portal;
3927
+ Sheet.Overlay = Sheet_Overlay;
3928
+ Sheet.Content = Sheet_Content;
3929
+ Sheet.Header = Sheet_Header;
3930
+ Sheet.Footer = Sheet_Footer;
3931
+ Sheet.Title = Sheet_Title;
3932
+ Sheet.Description = Sheet_Description;
3933
+ const SIDEBAR_COOKIE_NAME = 'sidebar_state';
3934
+ var Sidebar_styles_css_container = 'style__1xiua9n4';
3935
+ var Sidebar_styles_css_content = 'style__1xiua9nh';
3936
+ var desktopSidebar = 'style__1xiua9n2';
3937
+ var Sidebar_styles_css_footer = 'style__1xiua9nf';
3938
+ var gap = 'style__1xiua9n3';
3939
+ var Sidebar_styles_css_group = 'style__1xiua9ni';
3940
+ var groupAction = 'style__1xiua9nk';
3941
+ var groupContent = 'style__1xiua9nl';
3942
+ var groupLabel = 'style__1xiua9nj';
3943
+ var Sidebar_styles_css_header = 'style__1xiua9ne';
3944
+ var inner = 'style__1xiua9n6';
3945
+ var Sidebar_styles_css_input = 'style__1xiua9nd';
3946
+ var styles_css_inset = 'style__1xiua9nc';
3947
+ var menu = 'style__1xiua9nm';
3948
+ var menuAction = 'style__1xiua9nu';
3949
+ var menuBadge = 'style__1xiua9nv';
3950
+ var menuButton = 'style__1xiua9no';
3951
+ var menuButtonSizes = {
3952
+ default: 'default__1xiua9nr',
3953
+ sm: 'sm__1xiua9ns',
3954
+ lg: 'lg__1xiua9nt'
3955
+ };
3956
+ var menuButtonVariants = {
3957
+ default: 'default__1xiua9np',
3958
+ outline: 'outline__1xiua9nq'
3959
+ };
3960
+ var menuItem = 'style__1xiua9nn';
3961
+ var menuSkeleton = 'style__1xiua9nw';
3962
+ var menuSub = 'style__1xiua9n10';
3963
+ var menuSubButton = 'style__1xiua9n12';
3964
+ var menuSubButtonSizes = {
3965
+ sm: 'sm__1xiua9n13',
3966
+ md: 'md__1xiua9n14'
3967
+ };
3968
+ var menuSubItem = 'style__1xiua9n11';
3969
+ var mobileContent = 'style__1xiua9n7';
3970
+ var mobileInner = 'style__1xiua9n8';
3971
+ var rail = 'style__1xiua9nb';
3972
+ var Sidebar_styles_css_separator = 'style__1xiua9ng';
3973
+ var skeleton = 'style__1xiua9nx';
3974
+ var skeletonIcon = 'style__1xiua9ny';
3975
+ var skeletonText = 'style__1xiua9nz';
3976
+ var staticSidebar = 'style__1xiua9n5';
3977
+ var Sidebar_styles_css_trigger = 'style__1xiua9na';
3978
+ var styles_css_visuallyHidden = 'style__1xiua9n9';
3979
+ var Sidebar_styles_css_wrapper = 'style__1xiua9n1';
3980
+ const SidebarContext = /*#__PURE__*/ __rspack_external_react.createContext(null);
3981
+ function useSidebar() {
3982
+ const context = __rspack_external_react.useContext(SidebarContext);
3983
+ if (!context) throw new Error('useSidebar must be used within a Sidebar.Provider.');
3984
+ return context;
3985
+ }
3986
+ function Sidebar_Provider({ defaultOpen = true, open: openProp, onOpenChange, className, style, children, ...props }) {
3987
+ const isMobile = useIsMobile();
3988
+ const [openMobile, setOpenMobile] = __rspack_external_react.useState(false);
3989
+ const [_open, _setOpen] = __rspack_external_react.useState(defaultOpen);
3990
+ const open = openProp ?? _open;
3991
+ const setOpen = __rspack_external_react.useCallback((value)=>{
3992
+ const openState = 'function' == typeof value ? value(open) : value;
3993
+ if (onOpenChange) onOpenChange(openState);
3994
+ else _setOpen(openState);
3995
+ document.cookie = `${SIDEBAR_COOKIE_NAME}=${openState}; path=/; max-age=604800`;
3996
+ }, [
3997
+ onOpenChange,
3998
+ open
3999
+ ]);
4000
+ const toggleSidebar = __rspack_external_react.useCallback(()=>{
4001
+ if (isMobile) return void setOpenMobile((currentOpen)=>!currentOpen);
4002
+ setOpen((currentOpen)=>!currentOpen);
4003
+ }, [
4004
+ isMobile,
4005
+ setOpen
4006
+ ]);
4007
+ __rspack_external_react.useEffect(()=>{
4008
+ const handleKeyDown = (event)=>{
4009
+ if ("b" === event.key && (event.metaKey || event.ctrlKey)) {
4010
+ event.preventDefault();
4011
+ toggleSidebar();
4012
+ }
4013
+ };
4014
+ window.addEventListener('keydown', handleKeyDown);
4015
+ return ()=>window.removeEventListener('keydown', handleKeyDown);
4016
+ }, [
4017
+ toggleSidebar
4018
+ ]);
4019
+ const state = open ? 'expanded' : 'collapsed';
4020
+ const contextValue = __rspack_external_react.useMemo(()=>({
4021
+ state,
4022
+ open,
4023
+ setOpen,
4024
+ isMobile,
4025
+ openMobile,
4026
+ setOpenMobile,
4027
+ toggleSidebar
4028
+ }), [
4029
+ state,
4030
+ open,
4031
+ setOpen,
4032
+ isMobile,
4033
+ openMobile,
4034
+ toggleSidebar
4035
+ ]);
4036
+ return /*#__PURE__*/ jsx(SidebarContext.Provider, {
4037
+ value: contextValue,
4038
+ children: /*#__PURE__*/ jsx("div", {
4039
+ "data-slot": "sidebar-wrapper",
4040
+ style: {
4041
+ '--sidebar-width': "16rem",
4042
+ '--sidebar-width-icon': "3rem",
4043
+ ...style
4044
+ },
4045
+ className: clsx(Sidebar_styles_css_wrapper, className),
4046
+ ...props,
4047
+ children: children
4048
+ })
4049
+ });
4050
+ }
4051
+ function SidebarRoot({ side = 'left', variant = 'sidebar', collapsible = 'offcanvas', className, style, children, ...props }) {
4052
+ const { isMobile, state, openMobile, setOpenMobile } = useSidebar();
4053
+ if ('none' === collapsible) return /*#__PURE__*/ jsx("div", {
4054
+ "data-slot": "sidebar",
4055
+ style: style,
4056
+ className: clsx(staticSidebar, className),
4057
+ ...props,
4058
+ children: children
4059
+ });
4060
+ if (isMobile) return /*#__PURE__*/ jsx(Sheet, {
4061
+ open: openMobile,
4062
+ onOpenChange: setOpenMobile,
4063
+ children: /*#__PURE__*/ jsxs(Sheet.Content, {
4064
+ "data-sidebar": "sidebar",
4065
+ "data-slot": "sidebar",
4066
+ "data-mobile": "true",
4067
+ side: side,
4068
+ showCloseButton: false,
4069
+ style: {
4070
+ '--sidebar-width': "18rem",
4071
+ ...style
4072
+ },
4073
+ className: clsx(mobileContent, className),
4074
+ ...props,
4075
+ children: [
4076
+ /*#__PURE__*/ jsxs(Sheet.Header, {
4077
+ className: styles_css_visuallyHidden,
4078
+ children: [
4079
+ /*#__PURE__*/ jsx(Sheet.Title, {
4080
+ children: "Sidebar"
4081
+ }),
4082
+ /*#__PURE__*/ jsx(Sheet.Description, {
4083
+ children: "Displays the mobile sidebar."
4084
+ })
4085
+ ]
4086
+ }),
4087
+ /*#__PURE__*/ jsx("div", {
4088
+ className: mobileInner,
4089
+ children: children
4090
+ })
4091
+ ]
4092
+ })
4093
+ });
4094
+ return /*#__PURE__*/ jsxs("div", {
4095
+ "data-state": state,
4096
+ "data-collapsible": 'collapsed' === state ? collapsible : void 0,
4097
+ "data-variant": variant,
4098
+ "data-side": side,
4099
+ "data-slot": "sidebar",
4100
+ className: desktopSidebar,
4101
+ children: [
4102
+ /*#__PURE__*/ jsx("div", {
4103
+ "data-slot": "sidebar-gap",
4104
+ className: gap
4105
+ }),
4106
+ /*#__PURE__*/ jsx("div", {
4107
+ "data-slot": "sidebar-container",
4108
+ className: clsx(Sidebar_styles_css_container, className),
4109
+ style: style,
4110
+ ...props,
4111
+ children: /*#__PURE__*/ jsx("div", {
4112
+ "data-sidebar": "sidebar",
4113
+ "data-slot": "sidebar-inner",
4114
+ className: inner,
4115
+ children: children
4116
+ })
4117
+ })
4118
+ ]
4119
+ });
4120
+ }
4121
+ function Sidebar_Trigger({ className, onClick, children, ...props }) {
4122
+ const { toggleSidebar } = useSidebar();
4123
+ return /*#__PURE__*/ jsx(Button_Button, {
4124
+ "data-sidebar": "trigger",
4125
+ "data-slot": "sidebar-trigger",
4126
+ variant: "ghost",
4127
+ size: "icon",
4128
+ className: clsx(Sidebar_styles_css_trigger, className),
4129
+ onClick: (event)=>{
4130
+ onClick?.(event);
4131
+ toggleSidebar();
4132
+ },
4133
+ ...props,
4134
+ children: children ?? /*#__PURE__*/ jsxs(Fragment, {
4135
+ children: [
4136
+ /*#__PURE__*/ jsx(PanelLeftIcon, {}),
4137
+ /*#__PURE__*/ jsx("span", {
4138
+ className: styles_css_visuallyHidden,
4139
+ children: "Toggle Sidebar"
4140
+ })
4141
+ ]
4142
+ })
4143
+ });
4144
+ }
4145
+ function Rail({ className, ...props }) {
4146
+ const { toggleSidebar } = useSidebar();
4147
+ return /*#__PURE__*/ jsx("button", {
4148
+ type: "button",
4149
+ "data-sidebar": "rail",
4150
+ "data-slot": "sidebar-rail",
4151
+ "aria-label": "Toggle Sidebar",
4152
+ tabIndex: -1,
4153
+ title: "Toggle Sidebar",
4154
+ className: clsx(rail, className),
4155
+ onClick: toggleSidebar,
4156
+ ...props
4157
+ });
4158
+ }
4159
+ function Inset({ className, ...props }) {
4160
+ return /*#__PURE__*/ jsx("main", {
4161
+ "data-slot": "sidebar-inset",
4162
+ className: clsx(styles_css_inset, className),
4163
+ ...props
4164
+ });
4165
+ }
4166
+ function SidebarInput({ className, ...props }) {
4167
+ return /*#__PURE__*/ jsx(Input, {
4168
+ "data-slot": "sidebar-input",
4169
+ "data-sidebar": "input",
4170
+ className: clsx(Sidebar_styles_css_input, className),
4171
+ ...props
4172
+ });
4173
+ }
4174
+ function Sidebar_Header({ className, ...props }) {
4175
+ return /*#__PURE__*/ jsx("div", {
4176
+ "data-slot": "sidebar-header",
4177
+ "data-sidebar": "header",
4178
+ className: clsx(Sidebar_styles_css_header, className),
4179
+ ...props
4180
+ });
4181
+ }
4182
+ function Sidebar_Footer({ className, ...props }) {
4183
+ return /*#__PURE__*/ jsx("div", {
4184
+ "data-slot": "sidebar-footer",
4185
+ "data-sidebar": "footer",
4186
+ className: clsx(Sidebar_styles_css_footer, className),
4187
+ ...props
4188
+ });
4189
+ }
4190
+ function Sidebar_Separator({ className, orientation = 'horizontal', ...props }) {
4191
+ return /*#__PURE__*/ jsx(separator_Separator, {
4192
+ "data-slot": "sidebar-separator",
4193
+ "data-sidebar": "separator",
4194
+ orientation: orientation,
4195
+ className: clsx(Sidebar_styles_css_separator, className),
4196
+ ...props
4197
+ });
4198
+ }
4199
+ function Sidebar_Content({ className, ...props }) {
4200
+ return /*#__PURE__*/ jsx("div", {
4201
+ "data-slot": "sidebar-content",
4202
+ "data-sidebar": "content",
4203
+ className: clsx(Sidebar_styles_css_content, className),
4204
+ ...props
4205
+ });
4206
+ }
4207
+ function Sidebar_Group({ className, ...props }) {
4208
+ return /*#__PURE__*/ jsx("div", {
4209
+ "data-slot": "sidebar-group",
4210
+ "data-sidebar": "group",
4211
+ className: clsx(Sidebar_styles_css_group, className),
4212
+ ...props
4213
+ });
4214
+ }
4215
+ function GroupLabel({ className, render, ...props }) {
4216
+ return useRender({
4217
+ defaultTagName: 'div',
4218
+ render,
4219
+ props: mergeProps({
4220
+ 'data-slot': 'sidebar-group-label',
4221
+ 'data-sidebar': 'group-label',
4222
+ className: clsx(groupLabel, className)
4223
+ }, props)
4224
+ });
4225
+ }
4226
+ function GroupAction({ className, render, ...props }) {
4227
+ return useRender({
4228
+ defaultTagName: 'button',
4229
+ render,
4230
+ props: mergeProps({
4231
+ type: 'button',
4232
+ 'data-slot': 'sidebar-group-action',
4233
+ 'data-sidebar': 'group-action',
4234
+ className: clsx(groupAction, className)
4235
+ }, props)
4236
+ });
4237
+ }
4238
+ function GroupContent({ className, ...props }) {
4239
+ return /*#__PURE__*/ jsx("div", {
4240
+ "data-slot": "sidebar-group-content",
4241
+ "data-sidebar": "group-content",
4242
+ className: clsx(groupContent, className),
4243
+ ...props
4244
+ });
4245
+ }
4246
+ function Sidebar_Menu({ className, ...props }) {
4247
+ return /*#__PURE__*/ jsx("ul", {
4248
+ "data-slot": "sidebar-menu",
4249
+ "data-sidebar": "menu",
4250
+ className: clsx(menu, className),
4251
+ ...props
4252
+ });
4253
+ }
4254
+ function MenuItem({ className, ...props }) {
4255
+ return /*#__PURE__*/ jsx("li", {
4256
+ "data-slot": "sidebar-menu-item",
4257
+ "data-sidebar": "menu-item",
4258
+ className: clsx(menuItem, className),
4259
+ ...props
4260
+ });
4261
+ }
4262
+ function getTooltipProps(tooltip) {
4263
+ if ('string' == typeof tooltip) return {
4264
+ text: tooltip
4265
+ };
4266
+ const { children, ...props } = tooltip;
4267
+ return {
4268
+ content: children,
4269
+ ...props
4270
+ };
4271
+ }
4272
+ function MenuButton({ isActive = false, variant = 'default', size = 'default', tooltip, className, render, ...props }) {
4273
+ const { isMobile, state } = useSidebar();
4274
+ const button = useRender({
4275
+ defaultTagName: 'button',
4276
+ render,
4277
+ props: mergeProps({
4278
+ type: 'button',
4279
+ 'data-slot': 'sidebar-menu-button',
4280
+ 'data-sidebar': 'menu-button',
4281
+ 'data-size': size,
4282
+ 'data-active': isActive ? 'true' : 'false',
4283
+ className: clsx(menuButton, menuButtonVariants[variant], menuButtonSizes[size], className)
4284
+ }, props)
4285
+ });
4286
+ if (!tooltip || 'collapsed' !== state || isMobile) return button;
4287
+ return /*#__PURE__*/ jsx(Tooltip, {
4288
+ side: "right",
4289
+ ...getTooltipProps(tooltip),
4290
+ children: button
4291
+ });
4292
+ }
4293
+ function MenuAction({ className, showOnHover = false, render, ...props }) {
4294
+ return useRender({
4295
+ defaultTagName: 'button',
4296
+ render,
4297
+ props: mergeProps({
4298
+ type: 'button',
4299
+ 'data-slot': 'sidebar-menu-action',
4300
+ 'data-sidebar': 'menu-action',
4301
+ 'data-show-on-hover': showOnHover ? 'true' : void 0,
4302
+ className: clsx(menuAction, className)
4303
+ }, props)
4304
+ });
4305
+ }
4306
+ function MenuBadge({ className, ...props }) {
4307
+ return /*#__PURE__*/ jsx("div", {
4308
+ "data-slot": "sidebar-menu-badge",
4309
+ "data-sidebar": "menu-badge",
4310
+ className: clsx(menuBadge, className),
4311
+ ...props
4312
+ });
4313
+ }
4314
+ function MenuSkeleton({ className, showIcon = false, ...props }) {
4315
+ const width = __rspack_external_react.useMemo(()=>`${Math.floor(40 * Math.random()) + 50}%`, []);
4316
+ return /*#__PURE__*/ jsxs("div", {
4317
+ "data-slot": "sidebar-menu-skeleton",
4318
+ "data-sidebar": "menu-skeleton",
4319
+ className: clsx(menuSkeleton, className),
4320
+ ...props,
4321
+ children: [
4322
+ showIcon && /*#__PURE__*/ jsx("div", {
4323
+ className: clsx(skeleton, skeletonIcon),
4324
+ "data-sidebar": "menu-skeleton-icon"
4325
+ }),
4326
+ /*#__PURE__*/ jsx("div", {
4327
+ className: clsx(skeleton, skeletonText),
4328
+ "data-sidebar": "menu-skeleton-text",
4329
+ style: {
4330
+ '--skeleton-width': width
4331
+ }
4332
+ })
4333
+ ]
4334
+ });
4335
+ }
4336
+ function MenuSub({ className, ...props }) {
4337
+ return /*#__PURE__*/ jsx("ul", {
4338
+ "data-slot": "sidebar-menu-sub",
4339
+ "data-sidebar": "menu-sub",
4340
+ className: clsx(menuSub, className),
4341
+ ...props
4342
+ });
4343
+ }
4344
+ function MenuSubItem({ className, ...props }) {
4345
+ return /*#__PURE__*/ jsx("li", {
4346
+ "data-slot": "sidebar-menu-sub-item",
4347
+ "data-sidebar": "menu-sub-item",
4348
+ className: clsx(menuSubItem, className),
4349
+ ...props
4350
+ });
4351
+ }
4352
+ function MenuSubButton({ size = 'md', isActive = false, className, render, ...props }) {
4353
+ return useRender({
4354
+ defaultTagName: 'a',
4355
+ render,
4356
+ props: mergeProps({
4357
+ 'data-slot': 'sidebar-menu-sub-button',
4358
+ 'data-sidebar': 'menu-sub-button',
4359
+ 'data-size': size,
4360
+ 'data-active': isActive ? 'true' : 'false',
4361
+ className: clsx(menuSubButton, menuSubButtonSizes[size], className)
4362
+ }, props)
4363
+ });
4364
+ }
4365
+ const Sidebar_Sidebar = Object.assign(SidebarRoot, {
4366
+ Provider: Sidebar_Provider,
4367
+ Trigger: Sidebar_Trigger,
4368
+ Rail: Rail,
4369
+ Inset: Inset,
4370
+ Input: SidebarInput,
4371
+ Header: Sidebar_Header,
4372
+ Footer: Sidebar_Footer,
4373
+ Separator: Sidebar_Separator,
4374
+ Content: Sidebar_Content,
4375
+ Group: Sidebar_Group,
4376
+ GroupLabel: GroupLabel,
4377
+ GroupAction: GroupAction,
4378
+ GroupContent: GroupContent,
4379
+ Menu: Sidebar_Menu,
4380
+ MenuItem: MenuItem,
4381
+ MenuButton: MenuButton,
4382
+ MenuAction: MenuAction,
4383
+ MenuBadge: MenuBadge,
4384
+ MenuSkeleton: MenuSkeleton,
4385
+ MenuSub: MenuSub,
4386
+ MenuSubItem: MenuSubItem,
4387
+ MenuSubButton: MenuSubButton
4388
+ });
4389
+ var Tabs_styles_css_contentClass = 'style__hworoa5';
4390
+ var listClass = 'style__hworoa0';
4391
+ var Tabs_styles_css_sizes = {
4392
+ sm: 'sm__hworoa2',
4393
+ md: 'md__hworoa3',
4394
+ lg: 'lg__hworoa4'
4395
+ };
4396
+ var styles_css_triggerClass = 'style__hworoa1';
4397
+ const TabsContent = ({ className, ...props })=>/*#__PURE__*/ jsx(react_tabs_Content, {
4398
+ className: clsx(Tabs_styles_css_contentClass, className),
4399
+ ...props
4400
+ });
4401
+ const TabsList = ({ className, ...props })=>/*#__PURE__*/ jsx(react_tabs_List, {
4402
+ className: clsx(listClass, className),
4403
+ ...props
4404
+ });
4405
+ const TabsTrigger = ({ className, size = 'md', ...props })=>/*#__PURE__*/ jsx(react_tabs_Trigger, {
4406
+ className: clsx(styles_css_triggerClass, Tabs_styles_css_sizes[size], className),
4407
+ ...props
4408
+ });
4409
+ const Tabs_Tabs = (props)=>/*#__PURE__*/ jsx(Tabs, {
4410
+ ...props
4411
+ });
4412
+ Tabs_Tabs.Content = TabsContent;
4413
+ Tabs_Tabs.List = TabsList;
4414
+ Tabs_Tabs.Trigger = TabsTrigger;
4415
+ var toggleGroup_css_buttonClass = 'style__10hvn8a2';
4416
+ var toggleGroup_css_buttonsClass = 'style__10hvn8a1';
4417
+ var toggleGroup_css_containerClass = 'style__10hvn8a0';
4418
+ var toggleGroup_css_labelClass = 'style__10hvn8a3';
4419
+ const ToggleGroup = ({ value, onChange, options, size, className, label, multiple })=>{
4420
+ const isMultiple = true === multiple;
4421
+ const isActive = (optionValue)=>{
4422
+ if (isMultiple) return value.includes(optionValue);
4423
+ return value === optionValue;
4424
+ };
4425
+ const handleChange = (optionValue)=>{
4426
+ if (isMultiple) {
4427
+ const currentValue = value;
4428
+ currentValue.includes(optionValue) ? onChange(currentValue.filter((v)=>v !== optionValue)) : onChange([
4429
+ ...currentValue,
4430
+ optionValue
4431
+ ]);
4432
+ } else onChange(optionValue);
4433
+ };
4434
+ return /*#__PURE__*/ jsxs("div", {
4435
+ className: clsx(toggleGroup_css_containerClass, className),
4436
+ children: [
4437
+ label && /*#__PURE__*/ jsx(Label_Label, {
4438
+ className: toggleGroup_css_labelClass,
4439
+ children: label
4440
+ }),
4441
+ /*#__PURE__*/ jsx("div", {
4442
+ className: toggleGroup_css_buttonsClass,
4443
+ children: options.map((option)=>/*#__PURE__*/ jsx(Tooltip, {
4444
+ arrow: true,
4445
+ text: option.title,
4446
+ children: /*#__PURE__*/ jsx(Button_Button, {
4447
+ size: size,
4448
+ className: toggleGroup_css_buttonClass,
4449
+ disabled: option.disabled,
4450
+ onClick: ()=>handleChange(option.value),
4451
+ startAdornment: option.startAdornment,
4452
+ endAdornment: option.endAdornment,
4453
+ variant: isActive(option.value) ? 'default' : 'outline',
4454
+ children: option.label
4455
+ }, option.value)
4456
+ }, option.value))
4457
+ })
4458
+ ]
4459
+ });
4460
+ };
4461
+ const Form = ({ form, children, ...props })=>/*#__PURE__*/ jsx(FormProvider, {
4462
+ ...form,
4463
+ children: /*#__PURE__*/ jsx("form", {
4464
+ noValidate: true,
4465
+ ...props,
4466
+ children: children
4467
+ })
4468
+ });
4469
+ function FormMaskField({ name, control, ...props }) {
4470
+ return /*#__PURE__*/ jsx(Controller, {
4471
+ control: control,
4472
+ name: name,
4473
+ render: ({ field, fieldState })=>/*#__PURE__*/ jsx(MaskField, {
4474
+ ...props,
4475
+ ...field,
4476
+ error: !!fieldState.error,
4477
+ helperText: fieldState.error?.message
4478
+ })
4479
+ });
4480
+ }
4481
+ const useForm_useForm = ({ mode = 'onBlur', ...params } = {})=>useForm({
4482
+ ...params,
4483
+ mode
4484
+ });
4485
+ const FormSubmitButton = ({ children, isLoading, ...props })=>{
4486
+ const { formState } = useFormContext();
4487
+ return /*#__PURE__*/ jsx(Button_Button, {
4488
+ type: "submit",
4489
+ isLoading: isLoading || formState.isSubmitting,
4490
+ ...props,
4491
+ children: children
4492
+ });
4493
+ };
4494
+ function FormTextField({ name, control, gridArea, ...props }) {
4495
+ return /*#__PURE__*/ jsx(Controller, {
4496
+ control: control,
4497
+ name: name,
4498
+ render: ({ field, fieldState })=>/*#__PURE__*/ jsx(TextField, {
4499
+ ...props,
4500
+ ...field,
4501
+ style: {
4502
+ gridArea
4503
+ },
4504
+ value: field.value || '',
4505
+ error: !!fieldState.error,
4506
+ helperText: fieldState.error?.message
4507
+ })
4508
+ });
4509
+ }
4510
+ export { Accordion_Accordion as Accordion, AlertDialog_AlertDialog as AlertDialog, Avatar_Avatar as Avatar, Badge_Badge as Badge, Breadcrumb, ButtonGroup, Button_Button as Button, Button_buttonSizes as buttonSizes, Button_buttonVariants as buttonVariants, Calendar, Card, Carousel, Checkbox_Checkbox as Checkbox, CircularProgress, Collapsible_Collapsible as Collapsible, ConfirmAction, ContentState, Controller as FormController, CopyTypography, DEFAULT_SEPARATOR, DEFAULT_SYMBOL, DESCRIPTION_ROOT_CLASSNAME, DashboardLayout, DataGrid, DataGridActionCell, DataGridSortHeader, DataList, DatePicker, Description_Description as Description, Dialog_Dialog as Dialog, Drawer_Drawer as Drawer, DropdownMenu, Empty, Form, FormMaskField, FormProvider, FormSubmitButton, FormTextField, ImageCarousel, Image_Image as Image, Input, InputOTP, Label_Label as Label, MaskField, NOTIFICATION_POSITIONS, NOTIFY_CLASSNAME, Notification, NotificationContainer, OverflowTypography, PageLayout, Pagination, PeriodPicker, Placeholder, Popover_Popover as Popover, RadioGroupItem, RadioGroup_RadioGroup as RadioGroup, RangeInput, ScrollTopButton, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Sheet, Sidebar_Sidebar as Sidebar, Slider_Slider as Slider, Tabs_Tabs as Tabs, TextField, ToggleGroup, Tooltip, Typography, alignments, badgeVariants, calculateSize, colors, constants_NotificationVariantTypes as NotificationVariantTypes, createHandle, displays, negativeSpacing, notification, spacing, theme, transforms, useController as useFormController, useDashboard, useFieldArray as useFormFieldArray, useFormContext, useForm_useForm as useForm, useIsMobile, useOverflowed, useSidebar, useWatch as useFormWatch, variants, weights };