brd-ui-kit 0.1.57 → 0.1.59

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 (327) hide show
  1. package/dist/_commonjsHelpers-DKOUU3wS.cjs +2 -0
  2. package/dist/_commonjsHelpers-DKOUU3wS.cjs.map +1 -0
  3. package/dist/_commonjsHelpers-DaMA6jEr.js +9 -0
  4. package/dist/_commonjsHelpers-DaMA6jEr.js.map +1 -0
  5. package/dist/chart-CgVfpT_X.cjs +63 -0
  6. package/dist/chart-CgVfpT_X.cjs.map +1 -0
  7. package/dist/chart-D15EtNmb.js +13139 -0
  8. package/dist/chart-D15EtNmb.js.map +1 -0
  9. package/dist/components/app-pagination/app-pagination.styles.d.ts +4 -3
  10. package/dist/components/app-sidebar/app-sidebar.styles.d.ts +5 -4
  11. package/dist/components/ui/badge/badge.styles.d.ts +3 -2
  12. package/dist/components/ui/button/button.styles.d.ts +2 -1
  13. package/dist/components/ui/card/card.styles.d.ts +7 -6
  14. package/dist/components/ui/combobox/combobox.styles.d.ts +4 -3
  15. package/dist/components/ui/field/field.styles.d.ts +2 -1
  16. package/dist/components/ui/icon/icon-dictionary.d.ts +52 -50
  17. package/dist/components/ui/input/input.styles.d.ts +2 -1
  18. package/dist/components/ui/input-group/input-group.styles.d.ts +3 -2
  19. package/dist/components/ui/label/label.d.ts +2 -1
  20. package/dist/components/ui/navigation-item/navigation-item.styles.d.ts +2 -1
  21. package/dist/components/ui/navigation-menu/navigation-menu.styles.d.ts +2 -1
  22. package/dist/components/ui/tabs/tabs.styles.d.ts +3 -2
  23. package/dist/components/ui/typography/typography.styles.d.ts +2 -1
  24. package/dist/components-app-pagination-app-pagination.js +97 -0
  25. package/dist/components-app-pagination-app-pagination.js.map +1 -0
  26. package/dist/components-app-pagination-app-pagination.styles.js +85 -0
  27. package/dist/components-app-pagination-app-pagination.styles.js.map +1 -0
  28. package/dist/components-app-pagination.js +5 -0
  29. package/dist/components-app-pagination.js.map +1 -0
  30. package/dist/components-app-sidebar-app-sidebar.js +97 -0
  31. package/dist/components-app-sidebar-app-sidebar.js.map +1 -0
  32. package/dist/components-app-sidebar-app-sidebar.styles.js +59 -0
  33. package/dist/components-app-sidebar-app-sidebar.styles.js.map +1 -0
  34. package/dist/components-app-sidebar.js +5 -0
  35. package/dist/components-app-sidebar.js.map +1 -0
  36. package/dist/components-avatar-uploader-avatar-uploader.cjs +2 -2
  37. package/dist/components-avatar-uploader-avatar-uploader.cjs.map +1 -1
  38. package/dist/components-avatar-uploader-avatar-uploader.js +103 -0
  39. package/dist/components-avatar-uploader-avatar-uploader.js.map +1 -0
  40. package/dist/components-avatar-uploader.js +5 -0
  41. package/dist/components-avatar-uploader.js.map +1 -0
  42. package/dist/components-basic-avatar-basic-avatar.cjs +1 -1
  43. package/dist/components-basic-avatar-basic-avatar.cjs.map +1 -1
  44. package/dist/components-basic-avatar-basic-avatar.js +99 -0
  45. package/dist/components-basic-avatar-basic-avatar.js.map +1 -0
  46. package/dist/components-basic-avatar.js +5 -0
  47. package/dist/components-basic-avatar.js.map +1 -0
  48. package/dist/components-basic-chart-basic-chart.cjs +3 -1
  49. package/dist/components-basic-chart-basic-chart.cjs.map +1 -1
  50. package/dist/components-basic-chart-basic-chart.js +5546 -0
  51. package/dist/components-basic-chart-basic-chart.js.map +1 -0
  52. package/dist/components-basic-chart.js +5 -0
  53. package/dist/components-basic-chart.js.map +1 -0
  54. package/dist/components-basic-checkbox-basic-checkbox.js +54 -0
  55. package/dist/components-basic-checkbox-basic-checkbox.js.map +1 -0
  56. package/dist/components-basic-checkbox.js +5 -0
  57. package/dist/components-basic-checkbox.js.map +1 -0
  58. package/dist/components-basic-drawer-basic-drawer.cjs +1 -1
  59. package/dist/components-basic-drawer-basic-drawer.cjs.map +1 -1
  60. package/dist/components-basic-drawer-basic-drawer.js +74 -0
  61. package/dist/components-basic-drawer-basic-drawer.js.map +1 -0
  62. package/dist/components-basic-drawer.js +5 -0
  63. package/dist/components-basic-drawer.js.map +1 -0
  64. package/dist/components-basic-modal-basic-modal.js +56 -0
  65. package/dist/components-basic-modal-basic-modal.js.map +1 -0
  66. package/dist/components-basic-modal.js +5 -0
  67. package/dist/components-basic-modal.js.map +1 -0
  68. package/dist/components-basic-select-basic-select.js +53 -0
  69. package/dist/components-basic-select-basic-select.js.map +1 -0
  70. package/dist/components-basic-select.js +5 -0
  71. package/dist/components-basic-select.js.map +1 -0
  72. package/dist/components-basic-table-basic-table.js +1961 -0
  73. package/dist/components-basic-table-basic-table.js.map +1 -0
  74. package/dist/components-basic-table.js +5 -0
  75. package/dist/components-basic-table.js.map +1 -0
  76. package/dist/components-basic-tooltip-basic-tooltip.js +61 -0
  77. package/dist/components-basic-tooltip-basic-tooltip.js.map +1 -0
  78. package/dist/components-basic-tooltip.js +5 -0
  79. package/dist/components-basic-tooltip.js.map +1 -0
  80. package/dist/components-files-uploader-files-uploader.cjs +3 -3
  81. package/dist/components-files-uploader-files-uploader.cjs.map +1 -1
  82. package/dist/components-files-uploader-files-uploader.js +185 -0
  83. package/dist/components-files-uploader-files-uploader.js.map +1 -0
  84. package/dist/components-files-uploader.js +5 -0
  85. package/dist/components-files-uploader.js.map +1 -0
  86. package/dist/components-input-field-input-field.js +56 -0
  87. package/dist/components-input-field-input-field.js.map +1 -0
  88. package/dist/components-input-field.js +5 -0
  89. package/dist/components-input-field.js.map +1 -0
  90. package/dist/components-input-password-input-password.cjs +1 -1
  91. package/dist/components-input-password-input-password.cjs.map +1 -1
  92. package/dist/components-input-password-input-password.js +67 -0
  93. package/dist/components-input-password-input-password.js.map +1 -0
  94. package/dist/components-input-password.js +5 -0
  95. package/dist/components-input-password.js.map +1 -0
  96. package/dist/components-popover-modal-popover-modal.js +40 -0
  97. package/dist/components-popover-modal-popover-modal.js.map +1 -0
  98. package/dist/components-popover-modal.js +5 -0
  99. package/dist/components-popover-modal.js.map +1 -0
  100. package/dist/components-radio-button-radio-button.js +74 -0
  101. package/dist/components-radio-button-radio-button.js.map +1 -0
  102. package/dist/components-radio-button.js +5 -0
  103. package/dist/components-radio-button.js.map +1 -0
  104. package/dist/components-select-field-select-field.js +179 -0
  105. package/dist/components-select-field-select-field.js.map +1 -0
  106. package/dist/components-select-field.js +5 -0
  107. package/dist/components-select-field.js.map +1 -0
  108. package/dist/components-select-groups-select-groups.js +91 -0
  109. package/dist/components-select-groups-select-groups.js.map +1 -0
  110. package/dist/components-select-groups.js +5 -0
  111. package/dist/components-select-groups.js.map +1 -0
  112. package/dist/components-textarea-field-textarea-field.js +30 -0
  113. package/dist/components-textarea-field-textarea-field.js.map +1 -0
  114. package/dist/components-textarea-field.js +5 -0
  115. package/dist/components-textarea-field.js.map +1 -0
  116. package/dist/components-ui-avatar-avatar.js +149 -0
  117. package/dist/components-ui-avatar-avatar.js.map +1 -0
  118. package/dist/components-ui-avatar.js +10 -0
  119. package/dist/components-ui-avatar.js.map +1 -0
  120. package/dist/components-ui-badge-badge.js +47 -0
  121. package/dist/components-ui-badge-badge.js.map +1 -0
  122. package/dist/components-ui-badge-badge.styles.js +53 -0
  123. package/dist/components-ui-badge-badge.styles.js.map +1 -0
  124. package/dist/components-ui-badge.js +7 -0
  125. package/dist/components-ui-badge.js.map +1 -0
  126. package/dist/components-ui-button-button.js +26 -0
  127. package/dist/components-ui-button-button.js.map +1 -0
  128. package/dist/components-ui-button-button.styles.js +58 -0
  129. package/dist/components-ui-button-button.styles.js.map +1 -0
  130. package/dist/components-ui-button.js +7 -0
  131. package/dist/components-ui-button.js.map +1 -0
  132. package/dist/components-ui-card-card.js +95 -0
  133. package/dist/components-ui-card-card.js.map +1 -0
  134. package/dist/components-ui-card-card.styles.js +55 -0
  135. package/dist/components-ui-card-card.styles.js.map +1 -0
  136. package/dist/components-ui-card.js +10 -0
  137. package/dist/components-ui-card.js.map +1 -0
  138. package/dist/components-ui-chart-chart.cjs +1 -21
  139. package/dist/components-ui-chart-chart.cjs.map +1 -1
  140. package/dist/components-ui-chart-chart.js +13 -0
  141. package/dist/components-ui-chart-chart.js.map +1 -0
  142. package/dist/components-ui-chart.cjs +1 -1
  143. package/dist/components-ui-chart.js +10 -0
  144. package/dist/components-ui-chart.js.map +1 -0
  145. package/dist/components-ui-checkbox-checkbox.js +26 -0
  146. package/dist/components-ui-checkbox-checkbox.js.map +1 -0
  147. package/dist/components-ui-checkbox-checkbox.styles.js +20 -0
  148. package/dist/components-ui-checkbox-checkbox.styles.js.map +1 -0
  149. package/dist/components-ui-checkbox.js +5 -0
  150. package/dist/components-ui-checkbox.js.map +1 -0
  151. package/dist/components-ui-combobox-combobox.cjs +5 -5
  152. package/dist/components-ui-combobox-combobox.cjs.map +1 -1
  153. package/dist/components-ui-combobox-combobox.js +7155 -0
  154. package/dist/components-ui-combobox-combobox.js.map +1 -0
  155. package/dist/components-ui-combobox-combobox.styles.js +93 -0
  156. package/dist/components-ui-combobox-combobox.styles.js.map +1 -0
  157. package/dist/components-ui-combobox.js +20 -0
  158. package/dist/components-ui-combobox.js.map +1 -0
  159. package/dist/components-ui-dialog-dialog.js +88 -0
  160. package/dist/components-ui-dialog-dialog.js.map +1 -0
  161. package/dist/components-ui-dialog-dialog.styles.js +34 -0
  162. package/dist/components-ui-dialog-dialog.styles.js.map +1 -0
  163. package/dist/components-ui-dialog.js +14 -0
  164. package/dist/components-ui-dialog.js.map +1 -0
  165. package/dist/components-ui-drawer-drawer.cjs +1 -1
  166. package/dist/components-ui-drawer-drawer.cjs.map +1 -1
  167. package/dist/components-ui-drawer-drawer.js +177 -0
  168. package/dist/components-ui-drawer-drawer.js.map +1 -0
  169. package/dist/components-ui-drawer.js +14 -0
  170. package/dist/components-ui-drawer.js.map +1 -0
  171. package/dist/components-ui-field-field.js +155 -0
  172. package/dist/components-ui-field-field.js.map +1 -0
  173. package/dist/components-ui-field-field.styles.js +59 -0
  174. package/dist/components-ui-field-field.styles.js.map +1 -0
  175. package/dist/components-ui-field.js +14 -0
  176. package/dist/components-ui-field.js.map +1 -0
  177. package/dist/components-ui-icon-icon-dictionary.js +60 -0
  178. package/dist/components-ui-icon-icon-dictionary.js.map +1 -0
  179. package/dist/components-ui-icon-icon.js +40 -0
  180. package/dist/components-ui-icon-icon.js.map +1 -0
  181. package/dist/components-ui-icon-overrides.js +65 -0
  182. package/dist/components-ui-icon-overrides.js.map +1 -0
  183. package/dist/components-ui-icon.js +5 -0
  184. package/dist/components-ui-icon.js.map +1 -0
  185. package/dist/components-ui-input-group-input-group.js +129 -0
  186. package/dist/components-ui-input-group-input-group.js.map +1 -0
  187. package/dist/components-ui-input-group-input-group.styles.js +43 -0
  188. package/dist/components-ui-input-group-input-group.styles.js.map +1 -0
  189. package/dist/components-ui-input-group.js +10 -0
  190. package/dist/components-ui-input-group.js.map +1 -0
  191. package/dist/components-ui-input-input.js +18 -0
  192. package/dist/components-ui-input-input.js.map +1 -0
  193. package/dist/components-ui-input-input.styles.js +31 -0
  194. package/dist/components-ui-input-input.styles.js.map +1 -0
  195. package/dist/components-ui-input.js +5 -0
  196. package/dist/components-ui-input.js.map +1 -0
  197. package/dist/components-ui-label-label.js +19 -0
  198. package/dist/components-ui-label-label.js.map +1 -0
  199. package/dist/components-ui-label.js +5 -0
  200. package/dist/components-ui-label.js.map +1 -0
  201. package/dist/components-ui-navigation-item-navigation-item.js +66 -0
  202. package/dist/components-ui-navigation-item-navigation-item.js.map +1 -0
  203. package/dist/components-ui-navigation-item-navigation-item.styles.js +32 -0
  204. package/dist/components-ui-navigation-item-navigation-item.styles.js.map +1 -0
  205. package/dist/components-ui-navigation-item.js +5 -0
  206. package/dist/components-ui-navigation-item.js.map +1 -0
  207. package/dist/components-ui-navigation-menu-navigation-menu.js +25 -0
  208. package/dist/components-ui-navigation-menu-navigation-menu.js.map +1 -0
  209. package/dist/components-ui-navigation-menu-navigation-menu.styles.js +23 -0
  210. package/dist/components-ui-navigation-menu-navigation-menu.styles.js.map +1 -0
  211. package/dist/components-ui-navigation-menu.js +5 -0
  212. package/dist/components-ui-navigation-menu.js.map +1 -0
  213. package/dist/components-ui-pagination-pagination.js +110 -0
  214. package/dist/components-ui-pagination-pagination.js.map +1 -0
  215. package/dist/components-ui-pagination.js +11 -0
  216. package/dist/components-ui-pagination.js.map +1 -0
  217. package/dist/components-ui-popover-popover.js +117 -0
  218. package/dist/components-ui-popover-popover.js.map +1 -0
  219. package/dist/components-ui-popover-popover.styles.js +13 -0
  220. package/dist/components-ui-popover-popover.styles.js.map +1 -0
  221. package/dist/components-ui-popover.js +11 -0
  222. package/dist/components-ui-popover.js.map +1 -0
  223. package/dist/components-ui-progress-progress.js +49 -0
  224. package/dist/components-ui-progress-progress.js.map +1 -0
  225. package/dist/components-ui-progress.js +5 -0
  226. package/dist/components-ui-progress.js.map +1 -0
  227. package/dist/components-ui-radio-group-radio-group.js +29 -0
  228. package/dist/components-ui-radio-group-radio-group.js.map +1 -0
  229. package/dist/components-ui-radio-group-radio-group.styles.js +23 -0
  230. package/dist/components-ui-radio-group-radio-group.styles.js.map +1 -0
  231. package/dist/components-ui-radio-group.js +6 -0
  232. package/dist/components-ui-radio-group.js.map +1 -0
  233. package/dist/components-ui-select-select.js +194 -0
  234. package/dist/components-ui-select-select.js.map +1 -0
  235. package/dist/components-ui-select-select.styles.js +43 -0
  236. package/dist/components-ui-select-select.styles.js.map +1 -0
  237. package/dist/components-ui-select.js +14 -0
  238. package/dist/components-ui-select.js.map +1 -0
  239. package/dist/components-ui-separator-separator.js +29 -0
  240. package/dist/components-ui-separator-separator.js.map +1 -0
  241. package/dist/components-ui-separator.js +5 -0
  242. package/dist/components-ui-separator.js.map +1 -0
  243. package/dist/components-ui-sonner-sonner.cjs +1 -1
  244. package/dist/components-ui-sonner-sonner.cjs.map +1 -1
  245. package/dist/components-ui-sonner-sonner.js +72 -0
  246. package/dist/components-ui-sonner-sonner.js.map +1 -0
  247. package/dist/components-ui-sonner-sonner.styles.js +42 -0
  248. package/dist/components-ui-sonner-sonner.styles.js.map +1 -0
  249. package/dist/components-ui-sonner.cjs +1 -1
  250. package/dist/components-ui-sonner.js +7 -0
  251. package/dist/components-ui-sonner.js.map +1 -0
  252. package/dist/components-ui-switch-switch.js +19 -0
  253. package/dist/components-ui-switch-switch.js.map +1 -0
  254. package/dist/components-ui-switch-switch.styles.js +22 -0
  255. package/dist/components-ui-switch-switch.styles.js.map +1 -0
  256. package/dist/components-ui-switch.js +5 -0
  257. package/dist/components-ui-switch.js.map +1 -0
  258. package/dist/components-ui-table-table.js +130 -0
  259. package/dist/components-ui-table-table.js.map +1 -0
  260. package/dist/components-ui-table.js +12 -0
  261. package/dist/components-ui-table.js.map +1 -0
  262. package/dist/components-ui-tabs-tabs.js +62 -0
  263. package/dist/components-ui-tabs-tabs.js.map +1 -0
  264. package/dist/components-ui-tabs-tabs.styles.js +64 -0
  265. package/dist/components-ui-tabs-tabs.styles.js.map +1 -0
  266. package/dist/components-ui-tabs.js +8 -0
  267. package/dist/components-ui-tabs.js.map +1 -0
  268. package/dist/components-ui-textarea-textarea.js +16 -0
  269. package/dist/components-ui-textarea-textarea.js.map +1 -0
  270. package/dist/components-ui-textarea-textarea.styles.js +13 -0
  271. package/dist/components-ui-textarea-textarea.styles.js.map +1 -0
  272. package/dist/components-ui-textarea.js +5 -0
  273. package/dist/components-ui-textarea.js.map +1 -0
  274. package/dist/components-ui-tooltip-tooltip.js +28 -0
  275. package/dist/components-ui-tooltip-tooltip.js.map +1 -0
  276. package/dist/components-ui-tooltip-tooltip.styles.js +11 -0
  277. package/dist/components-ui-tooltip-tooltip.styles.js.map +1 -0
  278. package/dist/components-ui-tooltip.js +9 -0
  279. package/dist/components-ui-tooltip.js.map +1 -0
  280. package/dist/components-ui-typography-typography.js +19 -0
  281. package/dist/components-ui-typography-typography.js.map +1 -0
  282. package/dist/components-ui-typography-typography.styles.js +85 -0
  283. package/dist/components-ui-typography-typography.styles.js.map +1 -0
  284. package/dist/components-ui-typography.js +9 -0
  285. package/dist/components-ui-typography.js.map +1 -0
  286. package/dist/hooks-usePopupControls.js +14 -0
  287. package/dist/hooks-usePopupControls.js.map +1 -0
  288. package/dist/index-B5Id-jNC.js +2830 -0
  289. package/dist/index-B5Id-jNC.js.map +1 -0
  290. package/dist/index-C4iHL8Gs.js +776 -0
  291. package/dist/index-C4iHL8Gs.js.map +1 -0
  292. package/dist/index-C6N9aMq_.js +1038 -0
  293. package/dist/index-C6N9aMq_.js.map +1 -0
  294. package/dist/index-D8y9Cogu.cjs +7 -0
  295. package/dist/index-D8y9Cogu.cjs.map +1 -0
  296. package/dist/index-DGxwh2Ms.cjs +2 -0
  297. package/dist/index-DGxwh2Ms.cjs.map +1 -0
  298. package/dist/index-fTTv8YY8.cjs +4 -0
  299. package/dist/index-fTTv8YY8.cjs.map +1 -0
  300. package/dist/index.cjs +1 -1
  301. package/dist/index.js +194 -0
  302. package/dist/index.js.map +1 -0
  303. package/dist/lib-utils.js +16 -0
  304. package/dist/lib-utils.js.map +1 -0
  305. package/dist/lodash-FemA_LCk.js +3688 -0
  306. package/dist/lodash-FemA_LCk.js.map +1 -0
  307. package/dist/lodash-kqhtUJfz.cjs +21 -0
  308. package/dist/lodash-kqhtUJfz.cjs.map +1 -0
  309. package/dist/types-types.js +2 -0
  310. package/dist/types-types.js.map +1 -0
  311. package/dist/utils-helpers.js +17 -0
  312. package/dist/utils-helpers.js.map +1 -0
  313. package/dist/with-selector-CNcGWQ-h.js +534 -0
  314. package/dist/with-selector-CNcGWQ-h.js.map +1 -0
  315. package/dist/with-selector-DSbfqgSY.cjs +8 -0
  316. package/dist/with-selector-DSbfqgSY.cjs.map +1 -0
  317. package/package.json +87 -625
  318. package/.githooks/pre-commit +0 -19
  319. package/.prettierignore +0 -13
  320. package/components.json +0 -25
  321. package/prettier.config.mjs +0 -28
  322. package/public/vite.svg +0 -1
  323. package/scripts/generate-exports.js +0 -76
  324. package/scripts/get-entry-points.ts +0 -102
  325. package/tsconfig.app.json +0 -40
  326. package/tsconfig.node.json +0 -26
  327. package/tsconfig.storybook.json +0 -7
@@ -0,0 +1,5 @@
1
+ import { BasicChart as o } from "./components-basic-chart-basic-chart.js";
2
+ export {
3
+ o as BasicChart
4
+ };
5
+ //# sourceMappingURL=components-basic-chart.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components-basic-chart.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -0,0 +1,54 @@
1
+ import { jsx as i, jsxs as m } from "react/jsx-runtime";
2
+ import { cn as n } from "./lib-utils.js";
3
+ import { Checkbox as d } from "./components-ui-checkbox-checkbox.js";
4
+ import { FieldGroup as p, Field as h, FieldLabel as x } from "./components-ui-field-field.js";
5
+ const b = ({
6
+ name: o,
7
+ orientation: t = "horizontal",
8
+ label: a,
9
+ disabled: c,
10
+ classNames: r,
11
+ isValid: e,
12
+ ...s
13
+ }) => {
14
+ const l = {
15
+ "aria-invalid": !!e,
16
+ "data-invalid": !!e
17
+ };
18
+ return /* @__PURE__ */ i(p, { className: r?.classNameGroup, children: /* @__PURE__ */ m(
19
+ h,
20
+ {
21
+ ...l,
22
+ orientation: t,
23
+ children: [
24
+ /* @__PURE__ */ i(
25
+ d,
26
+ {
27
+ ...s,
28
+ ...l,
29
+ id: o,
30
+ name: o,
31
+ disabled: c,
32
+ className: r?.classNameCheckbox
33
+ }
34
+ ),
35
+ a && /* @__PURE__ */ i(
36
+ x,
37
+ {
38
+ htmlFor: o,
39
+ className: n(
40
+ "text-[14px]",
41
+ r?.classNameLabel,
42
+ c && "cursor-not-allowed"
43
+ ),
44
+ children: a
45
+ }
46
+ )
47
+ ]
48
+ }
49
+ ) });
50
+ };
51
+ export {
52
+ b as BasicCheckbox
53
+ };
54
+ //# sourceMappingURL=components-basic-checkbox-basic-checkbox.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components-basic-checkbox-basic-checkbox.js","sources":["../src/components/basic-checkbox/basic-checkbox.tsx"],"sourcesContent":["import { cn } from \"@/lib/utils\";\nimport type * as CheckboxPrimitive from \"@radix-ui/react-checkbox\";\nimport { Checkbox } from \"../ui/checkbox\";\nimport { Field, FieldGroup, FieldLabel } from \"../ui/field\";\n\ntype BaseProps = {\n name?: string;\n orientation?: \"vertical\" | \"horizontal\";\n label?: React.ReactNode;\n classNames?: {\n classNameCheckbox?: string;\n classNameLabel?: string;\n classNameGroup?: string;\n };\n isValid?: boolean;\n};\n\ntype CheckboxProps = BaseProps &\n React.ComponentPropsWithoutRef<typeof CheckboxPrimitive.Root>;\n\nexport const BasicCheckbox = ({\n name,\n orientation = \"horizontal\",\n label,\n disabled,\n classNames,\n isValid,\n ...rest\n}: CheckboxProps) => {\n const validationProps = {\n \"aria-invalid\": !!isValid,\n \"data-invalid\": !!isValid,\n };\n\n // TODO: добавить вывод ошибки\n return (\n <FieldGroup className={classNames?.classNameGroup}>\n <Field\n {...validationProps}\n orientation={orientation}\n >\n <Checkbox\n {...rest}\n {...validationProps}\n id={name}\n name={name}\n disabled={disabled}\n className={classNames?.classNameCheckbox}\n />\n {label && (\n <FieldLabel\n htmlFor={name}\n className={cn(\n \"text-[14px]\",\n classNames?.classNameLabel,\n disabled && \"cursor-not-allowed\",\n )}\n >\n {label}\n </FieldLabel>\n )}\n </Field>\n </FieldGroup>\n );\n};\n\nexport type { CheckboxProps };\n"],"names":["BasicCheckbox","name","orientation","label","disabled","classNames","isValid","rest","validationProps","jsx","FieldGroup","jsxs","Field","Checkbox","FieldLabel","cn"],"mappings":";;;;AAoBO,MAAMA,IAAgB,CAAC;AAAA,EAC5B,MAAAC;AAAA,EACA,aAAAC,IAAc;AAAA,EACd,OAAAC;AAAA,EACA,UAAAC;AAAA,EACA,YAAAC;AAAA,EACA,SAAAC;AAAA,EACA,GAAGC;AACL,MAAqB;AACnB,QAAMC,IAAkB;AAAA,IACtB,gBAAgB,CAAC,CAACF;AAAA,IAClB,gBAAgB,CAAC,CAACA;AAAA,EAAA;AAIpB,SACE,gBAAAG,EAACC,GAAA,EAAW,WAAWL,GAAY,gBACjC,UAAA,gBAAAM;AAAA,IAACC;AAAA,IAAA;AAAA,MACE,GAAGJ;AAAA,MACJ,aAAAN;AAAA,MAEA,UAAA;AAAA,QAAA,gBAAAO;AAAA,UAACI;AAAA,UAAA;AAAA,YACE,GAAGN;AAAA,YACH,GAAGC;AAAA,YACJ,IAAIP;AAAA,YACJ,MAAAA;AAAA,YACA,UAAAG;AAAA,YACA,WAAWC,GAAY;AAAA,UAAA;AAAA,QAAA;AAAA,QAExBF,KACC,gBAAAM;AAAA,UAACK;AAAA,UAAA;AAAA,YACC,SAASb;AAAA,YACT,WAAWc;AAAA,cACT;AAAA,cACAV,GAAY;AAAA,cACZD,KAAY;AAAA,YAAA;AAAA,YAGb,UAAAD;AAAA,UAAA;AAAA,QAAA;AAAA,MACH;AAAA,IAAA;AAAA,EAAA,GAGN;AAEJ;"}
@@ -0,0 +1,5 @@
1
+ import { BasicCheckbox as e } from "./components-basic-checkbox-basic-checkbox.js";
2
+ export {
3
+ e as BasicCheckbox
4
+ };
5
+ //# sourceMappingURL=components-basic-checkbox.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components-basic-checkbox.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("react/jsx-runtime");require("vaul");const a=require("./components-ui-button-button.cjs");require("./components-ui-button-button.styles.cjs");const e=require("./components-ui-drawer-drawer.cjs"),q=({title:s,description:o,footer:c,open:d,drawer:u,trigger:l,close:h,content:j,header:w,btnCancel:i,btnConfirm:t,children:x,onOpenChange:n,onConfirm:D})=>{const p=()=>{n(!1)},_=()=>{D?.(),n(!1)},m=c&&r.jsxs(e.DrawerFooter,{...c,children:[r.jsx(e.DrawerClose,{asChild:!0,...h,children:r.jsx(a.Button,{...i?.props,onClick:p,children:i?.label})}),r.jsx(a.Button,{...t?.props,onClick:_,children:t?.label})]});return r.jsxs(e.Drawer,{...u,open:d,onOpenChange:n,children:[l?.children&&r.jsx(e.DrawerTrigger,{...l?.props,children:l?.children}),r.jsxs(e.DrawerContent,{...j,children:[s&&r.jsxs(e.DrawerHeader,{...w,children:[r.jsx(e.DrawerTitle,{...s.props,children:s.content}),o&&r.jsx(e.DrawerDescription,{...o.props,children:o.content})]}),r.jsx("div",{className:"flex-1 overflow-auto",children:x}),m]})]})};exports.BasicDrawer=q;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("react/jsx-runtime");require("./index-fTTv8YY8.cjs");const a=require("./components-ui-button-button.cjs");require("./components-ui-button-button.styles.cjs");const e=require("./components-ui-drawer-drawer.cjs"),q=({title:s,description:o,footer:c,open:d,drawer:u,trigger:l,close:h,content:j,header:w,btnCancel:i,btnConfirm:t,children:x,onOpenChange:n,onConfirm:D})=>{const p=()=>{n(!1)},_=()=>{D?.(),n(!1)},m=c&&r.jsxs(e.DrawerFooter,{...c,children:[r.jsx(e.DrawerClose,{asChild:!0,...h,children:r.jsx(a.Button,{...i?.props,onClick:p,children:i?.label})}),r.jsx(a.Button,{...t?.props,onClick:_,children:t?.label})]});return r.jsxs(e.Drawer,{...u,open:d,onOpenChange:n,children:[l?.children&&r.jsx(e.DrawerTrigger,{...l?.props,children:l?.children}),r.jsxs(e.DrawerContent,{...j,children:[s&&r.jsxs(e.DrawerHeader,{...w,children:[r.jsx(e.DrawerTitle,{...s.props,children:s.content}),o&&r.jsx(e.DrawerDescription,{...o.props,children:o.content})]}),r.jsx("div",{className:"flex-1 overflow-auto",children:x}),m]})]})};exports.BasicDrawer=q;
2
2
  //# sourceMappingURL=components-basic-drawer-basic-drawer.cjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"components-basic-drawer-basic-drawer.cjs","sources":["../src/components/basic-drawer/basic-drawer.tsx"],"sourcesContent":["import type { ComponentProps } from \"react\";\nimport { Drawer as DrawerPrimitive } from \"vaul\";\nimport { Button, type ButtonProps } from \"../ui/button\";\nimport {\n Drawer,\n DrawerClose,\n DrawerContent,\n DrawerDescription,\n DrawerFooter,\n DrawerHeader,\n DrawerTitle,\n DrawerTrigger,\n} from \"../ui/drawer\";\n\ntype DrawerProps = ComponentProps<typeof DrawerPrimitive.Root>;\ntype DrawerTriggerProps = ComponentProps<typeof DrawerPrimitive.Trigger>;\ntype DrawerPortalProps = ComponentProps<typeof DrawerPrimitive.Portal>;\ntype DrawerCloseProps = ComponentProps<typeof DrawerPrimitive.Close>;\ntype DrawerOverlayProps = ComponentProps<typeof DrawerPrimitive.Overlay>;\ntype DrawerContentProps = ComponentProps<typeof DrawerPrimitive.Content>;\ntype DrawerHeaderProps = ComponentProps<\"div\">;\ntype DrawerFooterProps = ComponentProps<\"div\">;\ntype DrawerTitleProps = ComponentProps<typeof DrawerPrimitive.Title>;\ntype DrawerDescriptionProps = ComponentProps<typeof DrawerPrimitive.Description>;\n\ntype Props = {\n open: boolean;\n onOpenChange: (value: boolean) => void;\n title?: {\n content?: React.ReactNode | string;\n props?: DrawerTitleProps;\n };\n description?: {\n content?: React.ReactNode | string;\n props?: DrawerDescriptionProps;\n };\n\n btnCancel?: {\n props?: ButtonProps;\n label?: string;\n };\n btnConfirm?: {\n props?: ButtonProps;\n label?: string;\n };\n\n drawer?: DrawerProps;\n trigger?: {\n children?: React.ReactNode;\n props?: DrawerTriggerProps;\n };\n close?: DrawerCloseProps;\n content?: DrawerContentProps;\n header?: DrawerHeaderProps;\n footer?: DrawerFooterProps | null;\n children?: React.ReactNode;\n\n onConfirm?: () => void;\n};\n\nexport const BasicDrawer = ({\n title,\n description,\n footer,\n open,\n drawer,\n trigger,\n close,\n content,\n header,\n btnCancel,\n btnConfirm,\n children,\n\n onOpenChange,\n onConfirm,\n}: Props) => {\n const handleCancelClick = () => {\n onOpenChange(false);\n };\n\n const handleConfirmClick = () => {\n onConfirm?.();\n onOpenChange(false);\n };\n\n const resolvedFooter = footer && (\n <DrawerFooter {...footer}>\n <DrawerClose\n asChild\n {...close}\n >\n <Button\n {...btnCancel?.props}\n onClick={handleCancelClick}\n >\n {btnCancel?.label}\n </Button>\n </DrawerClose>\n <Button\n {...btnConfirm?.props}\n onClick={handleConfirmClick}\n >\n {btnConfirm?.label}\n </Button>\n </DrawerFooter>\n );\n\n return (\n <Drawer\n {...drawer}\n open={open}\n onOpenChange={onOpenChange}\n >\n {trigger?.children && (\n <DrawerTrigger {...trigger?.props}>{trigger?.children}</DrawerTrigger>\n )}\n <DrawerContent {...content}>\n {title && (\n <DrawerHeader {...header}>\n <DrawerTitle {...title.props}>{title.content}</DrawerTitle>\n {description && (\n <DrawerDescription {...description.props}>\n {description.content}\n </DrawerDescription>\n )}\n </DrawerHeader>\n )}\n <div className=\"flex-1 overflow-auto\">{children}</div>\n {resolvedFooter}\n </DrawerContent>\n </Drawer>\n );\n};\n\nexport type {\n DrawerCloseProps,\n DrawerContentProps,\n DrawerDescriptionProps,\n DrawerFooterProps,\n DrawerHeaderProps,\n DrawerOverlayProps,\n DrawerPortalProps,\n DrawerProps,\n DrawerTitleProps,\n DrawerTriggerProps,\n};\n"],"names":["BasicDrawer","title","description","footer","open","drawer","trigger","close","content","header","btnCancel","btnConfirm","children","onOpenChange","onConfirm","handleCancelClick","handleConfirmClick","resolvedFooter","jsxs","DrawerFooter","jsx","DrawerClose","Button","Drawer","DrawerTrigger","DrawerContent","DrawerHeader","DrawerTitle","DrawerDescription"],"mappings":"mSA4DaA,EAAc,CAAC,CAC1B,MAAAC,EACA,YAAAC,EACA,OAAAC,EACA,KAAAC,EACA,OAAAC,EACA,QAAAC,EACA,MAAAC,EACA,QAAAC,EACA,OAAAC,EACA,UAAAC,EACA,WAAAC,EACA,SAAAC,EAEA,aAAAC,EACA,UAAAC,CACF,IAAa,CACX,MAAMC,EAAoB,IAAM,CAC9BF,EAAa,EAAK,CACpB,EAEMG,EAAqB,IAAM,CAC/BF,IAAA,EACAD,EAAa,EAAK,CACpB,EAEMI,EAAiBd,GACrBe,EAAAA,KAACC,EAAAA,aAAA,CAAc,GAAGhB,EAChB,SAAA,CAAAiB,EAAAA,IAACC,EAAAA,YAAA,CACC,QAAO,GACN,GAAGd,EAEJ,SAAAa,EAAAA,IAACE,EAAAA,OAAA,CACE,GAAGZ,GAAW,MACf,QAASK,EAER,SAAAL,GAAW,KAAA,CAAA,CACd,CAAA,EAEFU,EAAAA,IAACE,EAAAA,OAAA,CACE,GAAGX,GAAY,MAChB,QAASK,EAER,SAAAL,GAAY,KAAA,CAAA,CACf,EACF,EAGF,OACEO,EAAAA,KAACK,EAAAA,OAAA,CACE,GAAGlB,EACJ,KAAAD,EACA,aAAAS,EAEC,SAAA,CAAAP,GAAS,UACRc,MAACI,EAAAA,cAAA,CAAe,GAAGlB,GAAS,MAAQ,YAAS,SAAS,EAExDY,EAAAA,KAACO,EAAAA,cAAA,CAAe,GAAGjB,EAChB,SAAA,CAAAP,GACCiB,EAAAA,KAACQ,EAAAA,aAAA,CAAc,GAAGjB,EAChB,SAAA,CAAAW,MAACO,EAAAA,YAAA,CAAa,GAAG1B,EAAM,MAAQ,WAAM,QAAQ,EAC5CC,GACCkB,EAAAA,IAACQ,EAAAA,kBAAA,CAAmB,GAAG1B,EAAY,MAChC,WAAY,OAAA,CACf,CAAA,EAEJ,EAEFkB,EAAAA,IAAC,MAAA,CAAI,UAAU,uBAAwB,SAAAR,CAAA,CAAS,EAC/CK,CAAA,CAAA,CACH,CAAA,CAAA,CAAA,CAGN"}
1
+ {"version":3,"file":"components-basic-drawer-basic-drawer.cjs","sources":["../src/components/basic-drawer/basic-drawer.tsx"],"sourcesContent":["import type { ComponentProps } from \"react\";\nimport { Drawer as DrawerPrimitive } from \"vaul\";\nimport { Button, type ButtonProps } from \"../ui/button\";\nimport {\n Drawer,\n DrawerClose,\n DrawerContent,\n DrawerDescription,\n DrawerFooter,\n DrawerHeader,\n DrawerTitle,\n DrawerTrigger,\n} from \"../ui/drawer\";\n\ntype DrawerProps = ComponentProps<typeof DrawerPrimitive.Root>;\ntype DrawerTriggerProps = ComponentProps<typeof DrawerPrimitive.Trigger>;\ntype DrawerPortalProps = ComponentProps<typeof DrawerPrimitive.Portal>;\ntype DrawerCloseProps = ComponentProps<typeof DrawerPrimitive.Close>;\ntype DrawerOverlayProps = ComponentProps<typeof DrawerPrimitive.Overlay>;\ntype DrawerContentProps = ComponentProps<typeof DrawerPrimitive.Content>;\ntype DrawerHeaderProps = ComponentProps<\"div\">;\ntype DrawerFooterProps = ComponentProps<\"div\">;\ntype DrawerTitleProps = ComponentProps<typeof DrawerPrimitive.Title>;\ntype DrawerDescriptionProps = ComponentProps<typeof DrawerPrimitive.Description>;\n\ntype Props = {\n open: boolean;\n onOpenChange: (value: boolean) => void;\n title?: {\n content?: React.ReactNode | string;\n props?: DrawerTitleProps;\n };\n description?: {\n content?: React.ReactNode | string;\n props?: DrawerDescriptionProps;\n };\n\n btnCancel?: {\n props?: ButtonProps;\n label?: string;\n };\n btnConfirm?: {\n props?: ButtonProps;\n label?: string;\n };\n\n drawer?: DrawerProps;\n trigger?: {\n children?: React.ReactNode;\n props?: DrawerTriggerProps;\n };\n close?: DrawerCloseProps;\n content?: DrawerContentProps;\n header?: DrawerHeaderProps;\n footer?: DrawerFooterProps | null;\n children?: React.ReactNode;\n\n onConfirm?: () => void;\n};\n\nexport const BasicDrawer = ({\n title,\n description,\n footer,\n open,\n drawer,\n trigger,\n close,\n content,\n header,\n btnCancel,\n btnConfirm,\n children,\n\n onOpenChange,\n onConfirm,\n}: Props) => {\n const handleCancelClick = () => {\n onOpenChange(false);\n };\n\n const handleConfirmClick = () => {\n onConfirm?.();\n onOpenChange(false);\n };\n\n const resolvedFooter = footer && (\n <DrawerFooter {...footer}>\n <DrawerClose\n asChild\n {...close}\n >\n <Button\n {...btnCancel?.props}\n onClick={handleCancelClick}\n >\n {btnCancel?.label}\n </Button>\n </DrawerClose>\n <Button\n {...btnConfirm?.props}\n onClick={handleConfirmClick}\n >\n {btnConfirm?.label}\n </Button>\n </DrawerFooter>\n );\n\n return (\n <Drawer\n {...drawer}\n open={open}\n onOpenChange={onOpenChange}\n >\n {trigger?.children && (\n <DrawerTrigger {...trigger?.props}>{trigger?.children}</DrawerTrigger>\n )}\n <DrawerContent {...content}>\n {title && (\n <DrawerHeader {...header}>\n <DrawerTitle {...title.props}>{title.content}</DrawerTitle>\n {description && (\n <DrawerDescription {...description.props}>\n {description.content}\n </DrawerDescription>\n )}\n </DrawerHeader>\n )}\n <div className=\"flex-1 overflow-auto\">{children}</div>\n {resolvedFooter}\n </DrawerContent>\n </Drawer>\n );\n};\n\nexport type {\n DrawerCloseProps,\n DrawerContentProps,\n DrawerDescriptionProps,\n DrawerFooterProps,\n DrawerHeaderProps,\n DrawerOverlayProps,\n DrawerPortalProps,\n DrawerProps,\n DrawerTitleProps,\n DrawerTriggerProps,\n};\n"],"names":["BasicDrawer","title","description","footer","open","drawer","trigger","close","content","header","btnCancel","btnConfirm","children","onOpenChange","onConfirm","handleCancelClick","handleConfirmClick","resolvedFooter","jsxs","DrawerFooter","jsx","DrawerClose","Button","Drawer","DrawerTrigger","DrawerContent","DrawerHeader","DrawerTitle","DrawerDescription"],"mappings":"mTA4DaA,EAAc,CAAC,CAC1B,MAAAC,EACA,YAAAC,EACA,OAAAC,EACA,KAAAC,EACA,OAAAC,EACA,QAAAC,EACA,MAAAC,EACA,QAAAC,EACA,OAAAC,EACA,UAAAC,EACA,WAAAC,EACA,SAAAC,EAEA,aAAAC,EACA,UAAAC,CACF,IAAa,CACX,MAAMC,EAAoB,IAAM,CAC9BF,EAAa,EAAK,CACpB,EAEMG,EAAqB,IAAM,CAC/BF,IAAA,EACAD,EAAa,EAAK,CACpB,EAEMI,EAAiBd,GACrBe,EAAAA,KAACC,EAAAA,aAAA,CAAc,GAAGhB,EAChB,SAAA,CAAAiB,EAAAA,IAACC,EAAAA,YAAA,CACC,QAAO,GACN,GAAGd,EAEJ,SAAAa,EAAAA,IAACE,EAAAA,OAAA,CACE,GAAGZ,GAAW,MACf,QAASK,EAER,SAAAL,GAAW,KAAA,CAAA,CACd,CAAA,EAEFU,EAAAA,IAACE,EAAAA,OAAA,CACE,GAAGX,GAAY,MAChB,QAASK,EAER,SAAAL,GAAY,KAAA,CAAA,CACf,EACF,EAGF,OACEO,EAAAA,KAACK,EAAAA,OAAA,CACE,GAAGlB,EACJ,KAAAD,EACA,aAAAS,EAEC,SAAA,CAAAP,GAAS,UACRc,MAACI,EAAAA,cAAA,CAAe,GAAGlB,GAAS,MAAQ,YAAS,SAAS,EAExDY,EAAAA,KAACO,EAAAA,cAAA,CAAe,GAAGjB,EAChB,SAAA,CAAAP,GACCiB,EAAAA,KAACQ,EAAAA,aAAA,CAAc,GAAGjB,EAChB,SAAA,CAAAW,MAACO,EAAAA,YAAA,CAAa,GAAG1B,EAAM,MAAQ,WAAM,QAAQ,EAC5CC,GACCkB,EAAAA,IAACQ,EAAAA,kBAAA,CAAmB,GAAG1B,EAAY,MAChC,WAAY,OAAA,CACf,CAAA,EAEJ,EAEFkB,EAAAA,IAAC,MAAA,CAAI,UAAU,uBAAwB,SAAAR,CAAA,CAAS,EAC/CK,CAAA,CAAA,CACH,CAAA,CAAA,CAAA,CAGN"}
@@ -0,0 +1,74 @@
1
+ import { jsxs as e, jsx as r } from "react/jsx-runtime";
2
+ import "./index-C6N9aMq_.js";
3
+ import { Button as d } from "./components-ui-button-button.js";
4
+ import "./components-ui-button-button.styles.js";
5
+ import { DrawerFooter as x, DrawerClose as v, Drawer as j, DrawerTrigger as B, DrawerContent as F, DrawerHeader as T, DrawerTitle as H, DrawerDescription as N } from "./components-ui-drawer-drawer.js";
6
+ const E = ({
7
+ title: l,
8
+ description: o,
9
+ footer: a,
10
+ open: t,
11
+ drawer: h,
12
+ trigger: c,
13
+ close: p,
14
+ content: w,
15
+ header: D,
16
+ btnCancel: n,
17
+ btnConfirm: s,
18
+ children: m,
19
+ onOpenChange: i,
20
+ onConfirm: f
21
+ }) => {
22
+ const C = () => {
23
+ i(!1);
24
+ }, k = () => {
25
+ f?.(), i(!1);
26
+ }, u = a && /* @__PURE__ */ e(x, { ...a, children: [
27
+ /* @__PURE__ */ r(
28
+ v,
29
+ {
30
+ asChild: !0,
31
+ ...p,
32
+ children: /* @__PURE__ */ r(
33
+ d,
34
+ {
35
+ ...n?.props,
36
+ onClick: C,
37
+ children: n?.label
38
+ }
39
+ )
40
+ }
41
+ ),
42
+ /* @__PURE__ */ r(
43
+ d,
44
+ {
45
+ ...s?.props,
46
+ onClick: k,
47
+ children: s?.label
48
+ }
49
+ )
50
+ ] });
51
+ return /* @__PURE__ */ e(
52
+ j,
53
+ {
54
+ ...h,
55
+ open: t,
56
+ onOpenChange: i,
57
+ children: [
58
+ c?.children && /* @__PURE__ */ r(B, { ...c?.props, children: c?.children }),
59
+ /* @__PURE__ */ e(F, { ...w, children: [
60
+ l && /* @__PURE__ */ e(T, { ...D, children: [
61
+ /* @__PURE__ */ r(H, { ...l.props, children: l.content }),
62
+ o && /* @__PURE__ */ r(N, { ...o.props, children: o.content })
63
+ ] }),
64
+ /* @__PURE__ */ r("div", { className: "flex-1 overflow-auto", children: m }),
65
+ u
66
+ ] })
67
+ ]
68
+ }
69
+ );
70
+ };
71
+ export {
72
+ E as BasicDrawer
73
+ };
74
+ //# sourceMappingURL=components-basic-drawer-basic-drawer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components-basic-drawer-basic-drawer.js","sources":["../src/components/basic-drawer/basic-drawer.tsx"],"sourcesContent":["import type { ComponentProps } from \"react\";\nimport { Drawer as DrawerPrimitive } from \"vaul\";\nimport { Button, type ButtonProps } from \"../ui/button\";\nimport {\n Drawer,\n DrawerClose,\n DrawerContent,\n DrawerDescription,\n DrawerFooter,\n DrawerHeader,\n DrawerTitle,\n DrawerTrigger,\n} from \"../ui/drawer\";\n\ntype DrawerProps = ComponentProps<typeof DrawerPrimitive.Root>;\ntype DrawerTriggerProps = ComponentProps<typeof DrawerPrimitive.Trigger>;\ntype DrawerPortalProps = ComponentProps<typeof DrawerPrimitive.Portal>;\ntype DrawerCloseProps = ComponentProps<typeof DrawerPrimitive.Close>;\ntype DrawerOverlayProps = ComponentProps<typeof DrawerPrimitive.Overlay>;\ntype DrawerContentProps = ComponentProps<typeof DrawerPrimitive.Content>;\ntype DrawerHeaderProps = ComponentProps<\"div\">;\ntype DrawerFooterProps = ComponentProps<\"div\">;\ntype DrawerTitleProps = ComponentProps<typeof DrawerPrimitive.Title>;\ntype DrawerDescriptionProps = ComponentProps<typeof DrawerPrimitive.Description>;\n\ntype Props = {\n open: boolean;\n onOpenChange: (value: boolean) => void;\n title?: {\n content?: React.ReactNode | string;\n props?: DrawerTitleProps;\n };\n description?: {\n content?: React.ReactNode | string;\n props?: DrawerDescriptionProps;\n };\n\n btnCancel?: {\n props?: ButtonProps;\n label?: string;\n };\n btnConfirm?: {\n props?: ButtonProps;\n label?: string;\n };\n\n drawer?: DrawerProps;\n trigger?: {\n children?: React.ReactNode;\n props?: DrawerTriggerProps;\n };\n close?: DrawerCloseProps;\n content?: DrawerContentProps;\n header?: DrawerHeaderProps;\n footer?: DrawerFooterProps | null;\n children?: React.ReactNode;\n\n onConfirm?: () => void;\n};\n\nexport const BasicDrawer = ({\n title,\n description,\n footer,\n open,\n drawer,\n trigger,\n close,\n content,\n header,\n btnCancel,\n btnConfirm,\n children,\n\n onOpenChange,\n onConfirm,\n}: Props) => {\n const handleCancelClick = () => {\n onOpenChange(false);\n };\n\n const handleConfirmClick = () => {\n onConfirm?.();\n onOpenChange(false);\n };\n\n const resolvedFooter = footer && (\n <DrawerFooter {...footer}>\n <DrawerClose\n asChild\n {...close}\n >\n <Button\n {...btnCancel?.props}\n onClick={handleCancelClick}\n >\n {btnCancel?.label}\n </Button>\n </DrawerClose>\n <Button\n {...btnConfirm?.props}\n onClick={handleConfirmClick}\n >\n {btnConfirm?.label}\n </Button>\n </DrawerFooter>\n );\n\n return (\n <Drawer\n {...drawer}\n open={open}\n onOpenChange={onOpenChange}\n >\n {trigger?.children && (\n <DrawerTrigger {...trigger?.props}>{trigger?.children}</DrawerTrigger>\n )}\n <DrawerContent {...content}>\n {title && (\n <DrawerHeader {...header}>\n <DrawerTitle {...title.props}>{title.content}</DrawerTitle>\n {description && (\n <DrawerDescription {...description.props}>\n {description.content}\n </DrawerDescription>\n )}\n </DrawerHeader>\n )}\n <div className=\"flex-1 overflow-auto\">{children}</div>\n {resolvedFooter}\n </DrawerContent>\n </Drawer>\n );\n};\n\nexport type {\n DrawerCloseProps,\n DrawerContentProps,\n DrawerDescriptionProps,\n DrawerFooterProps,\n DrawerHeaderProps,\n DrawerOverlayProps,\n DrawerPortalProps,\n DrawerProps,\n DrawerTitleProps,\n DrawerTriggerProps,\n};\n"],"names":["BasicDrawer","title","description","footer","open","drawer","trigger","close","content","header","btnCancel","btnConfirm","children","onOpenChange","onConfirm","handleCancelClick","handleConfirmClick","resolvedFooter","jsxs","DrawerFooter","jsx","DrawerClose","Button","Drawer","DrawerTrigger","DrawerContent","DrawerHeader","DrawerTitle","DrawerDescription"],"mappings":";;;;;AA4DO,MAAMA,IAAc,CAAC;AAAA,EAC1B,OAAAC;AAAA,EACA,aAAAC;AAAA,EACA,QAAAC;AAAA,EACA,MAAAC;AAAA,EACA,QAAAC;AAAA,EACA,SAAAC;AAAA,EACA,OAAAC;AAAA,EACA,SAAAC;AAAA,EACA,QAAAC;AAAA,EACA,WAAAC;AAAA,EACA,YAAAC;AAAA,EACA,UAAAC;AAAA,EAEA,cAAAC;AAAA,EACA,WAAAC;AACF,MAAa;AACX,QAAMC,IAAoB,MAAM;AAC9B,IAAAF,EAAa,EAAK;AAAA,EACpB,GAEMG,IAAqB,MAAM;AAC/B,IAAAF,IAAA,GACAD,EAAa,EAAK;AAAA,EACpB,GAEMI,IAAiBd,KACrB,gBAAAe,EAACC,GAAA,EAAc,GAAGhB,GAChB,UAAA;AAAA,IAAA,gBAAAiB;AAAA,MAACC;AAAA,MAAA;AAAA,QACC,SAAO;AAAA,QACN,GAAGd;AAAA,QAEJ,UAAA,gBAAAa;AAAA,UAACE;AAAA,UAAA;AAAA,YACE,GAAGZ,GAAW;AAAA,YACf,SAASK;AAAA,YAER,UAAAL,GAAW;AAAA,UAAA;AAAA,QAAA;AAAA,MACd;AAAA,IAAA;AAAA,IAEF,gBAAAU;AAAA,MAACE;AAAA,MAAA;AAAA,QACE,GAAGX,GAAY;AAAA,QAChB,SAASK;AAAA,QAER,UAAAL,GAAY;AAAA,MAAA;AAAA,IAAA;AAAA,EACf,GACF;AAGF,SACE,gBAAAO;AAAA,IAACK;AAAA,IAAA;AAAA,MACE,GAAGlB;AAAA,MACJ,MAAAD;AAAA,MACA,cAAAS;AAAA,MAEC,UAAA;AAAA,QAAAP,GAAS,YACR,gBAAAc,EAACI,GAAA,EAAe,GAAGlB,GAAS,OAAQ,aAAS,UAAS;AAAA,QAExD,gBAAAY,EAACO,GAAA,EAAe,GAAGjB,GAChB,UAAA;AAAA,UAAAP,KACC,gBAAAiB,EAACQ,GAAA,EAAc,GAAGjB,GAChB,UAAA;AAAA,YAAA,gBAAAW,EAACO,GAAA,EAAa,GAAG1B,EAAM,OAAQ,YAAM,SAAQ;AAAA,YAC5CC,KACC,gBAAAkB,EAACQ,GAAA,EAAmB,GAAG1B,EAAY,OAChC,YAAY,QAAA,CACf;AAAA,UAAA,GAEJ;AAAA,UAEF,gBAAAkB,EAAC,OAAA,EAAI,WAAU,wBAAwB,UAAAR,EAAA,CAAS;AAAA,UAC/CK;AAAA,QAAA,EAAA,CACH;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAGN;"}
@@ -0,0 +1,5 @@
1
+ import { BasicDrawer as e } from "./components-basic-drawer-basic-drawer.js";
2
+ export {
3
+ e as BasicDrawer
4
+ };
5
+ //# sourceMappingURL=components-basic-drawer.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components-basic-drawer.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -0,0 +1,56 @@
1
+ import { jsxs as a, jsx as o } from "react/jsx-runtime";
2
+ import { Button as c } from "./components-ui-button-button.js";
3
+ import "./components-ui-button-button.styles.js";
4
+ import { DialogFooter as k, Dialog as N, DialogContent as b, DialogHeader as g, DialogTitle as p } from "./components-ui-dialog-dialog.js";
5
+ const B = ({
6
+ open: d,
7
+ onOpenChange: r,
8
+ title: l,
9
+ cancelLabel: t = "Отмена",
10
+ confirmLabel: n = "Ок",
11
+ onConfirm: s,
12
+ children: m,
13
+ classes: i,
14
+ footer: e,
15
+ showCloseButton: h = !1,
16
+ ariaDescribedby: f = void 0
17
+ }) => {
18
+ const v = () => {
19
+ r(!1);
20
+ }, C = () => {
21
+ s?.(), r(!1);
22
+ }, D = e === void 0 ? /* @__PURE__ */ a(k, { className: i?.footer, children: [
23
+ /* @__PURE__ */ o(
24
+ c,
25
+ {
26
+ variant: "secondary",
27
+ onClick: v,
28
+ children: t
29
+ }
30
+ ),
31
+ /* @__PURE__ */ o(c, { onClick: C, children: n })
32
+ ] }) : e;
33
+ return /* @__PURE__ */ o(
34
+ N,
35
+ {
36
+ open: d,
37
+ onOpenChange: r,
38
+ children: /* @__PURE__ */ a(
39
+ b,
40
+ {
41
+ "aria-describedby": f,
42
+ showCloseButton: h,
43
+ children: [
44
+ l && /* @__PURE__ */ o(g, { className: i?.header, children: /* @__PURE__ */ o(p, { className: i?.title, children: l }) }),
45
+ /* @__PURE__ */ o("div", { className: i?.body, children: m }),
46
+ D
47
+ ]
48
+ }
49
+ )
50
+ }
51
+ );
52
+ };
53
+ export {
54
+ B as BasicModal
55
+ };
56
+ //# sourceMappingURL=components-basic-modal-basic-modal.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components-basic-modal-basic-modal.js","sources":["../src/components/basic-modal/basic-modal.tsx"],"sourcesContent":["import { Button } from \"../ui/button\";\nimport {\n Dialog,\n DialogContent,\n DialogFooter,\n DialogHeader,\n DialogTitle,\n} from \"../ui/dialog\";\n\ntype Props = {\n open: boolean;\n onOpenChange: (value: boolean) => void;\n title?: React.ReactNode | string;\n cancelLabel?: string;\n confirmLabel?: string;\n onConfirm?: () => void;\n classes?: {\n content?: string;\n header?: string;\n body?: string;\n footer?: string;\n title?: string;\n };\n children: React.ReactNode;\n footer?: React.ReactNode;\n showCloseButton?: boolean;\n ariaDescribedby?: string;\n};\n\nexport const BasicModal = ({\n open,\n onOpenChange,\n title,\n cancelLabel = \"Отмена\",\n confirmLabel = \"Ок\",\n onConfirm,\n children,\n classes,\n footer,\n showCloseButton = false,\n ariaDescribedby = undefined,\n}: Props) => {\n const handleCancelClick = () => {\n onOpenChange(false);\n };\n\n const handleConfirmClick = () => {\n onConfirm?.();\n onOpenChange(false);\n };\n\n const resolvedFooter =\n footer === undefined ? (\n <DialogFooter className={classes?.footer}>\n <Button\n variant=\"secondary\"\n onClick={handleCancelClick}\n >\n {cancelLabel}\n </Button>\n <Button onClick={handleConfirmClick}>{confirmLabel}</Button>\n </DialogFooter>\n ) : (\n footer\n );\n\n return (\n <Dialog\n open={open}\n onOpenChange={onOpenChange}\n >\n <DialogContent\n aria-describedby={ariaDescribedby}\n showCloseButton={showCloseButton}\n >\n {title && (\n <DialogHeader className={classes?.header}>\n <DialogTitle className={classes?.title}>{title}</DialogTitle>\n </DialogHeader>\n )}\n <div className={classes?.body}>{children}</div>\n {resolvedFooter}\n </DialogContent>\n </Dialog>\n );\n};\n"],"names":["BasicModal","open","onOpenChange","title","cancelLabel","confirmLabel","onConfirm","children","classes","footer","showCloseButton","ariaDescribedby","handleCancelClick","handleConfirmClick","resolvedFooter","DialogFooter","jsx","Button","Dialog","jsxs","DialogContent","DialogHeader","DialogTitle"],"mappings":";;;;AA6BO,MAAMA,IAAa,CAAC;AAAA,EACzB,MAAAC;AAAA,EACA,cAAAC;AAAA,EACA,OAAAC;AAAA,EACA,aAAAC,IAAc;AAAA,EACd,cAAAC,IAAe;AAAA,EACf,WAAAC;AAAA,EACA,UAAAC;AAAA,EACA,SAAAC;AAAA,EACA,QAAAC;AAAA,EACA,iBAAAC,IAAkB;AAAA,EAClB,iBAAAC,IAAkB;AACpB,MAAa;AACX,QAAMC,IAAoB,MAAM;AAC9B,IAAAV,EAAa,EAAK;AAAA,EACpB,GAEMW,IAAqB,MAAM;AAC/B,IAAAP,IAAA,GACAJ,EAAa,EAAK;AAAA,EACpB,GAEMY,IACJL,MAAW,2BACRM,GAAA,EAAa,WAAWP,GAAS,QAChC,UAAA;AAAA,IAAA,gBAAAQ;AAAA,MAACC;AAAA,MAAA;AAAA,QACC,SAAQ;AAAA,QACR,SAASL;AAAA,QAER,UAAAR;AAAA,MAAA;AAAA,IAAA;AAAA,IAEH,gBAAAY,EAACC,GAAA,EAAO,SAASJ,GAAqB,UAAAR,EAAA,CAAa;AAAA,EAAA,EAAA,CACrD,IAEAI;AAGJ,SACE,gBAAAO;AAAA,IAACE;AAAA,IAAA;AAAA,MACC,MAAAjB;AAAA,MACA,cAAAC;AAAA,MAEA,UAAA,gBAAAiB;AAAA,QAACC;AAAA,QAAA;AAAA,UACC,oBAAkBT;AAAA,UAClB,iBAAAD;AAAA,UAEC,UAAA;AAAA,YAAAP,KACC,gBAAAa,EAACK,GAAA,EAAa,WAAWb,GAAS,QAChC,UAAA,gBAAAQ,EAACM,GAAA,EAAY,WAAWd,GAAS,OAAQ,UAAAL,EAAA,CAAM,GACjD;AAAA,YAEF,gBAAAa,EAAC,OAAA,EAAI,WAAWR,GAAS,MAAO,UAAAD,GAAS;AAAA,YACxCO;AAAA,UAAA;AAAA,QAAA;AAAA,MAAA;AAAA,IACH;AAAA,EAAA;AAGN;"}
@@ -0,0 +1,5 @@
1
+ import { BasicModal as r } from "./components-basic-modal-basic-modal.js";
2
+ export {
3
+ r as BasicModal
4
+ };
5
+ //# sourceMappingURL=components-basic-modal.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components-basic-modal.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
@@ -0,0 +1,53 @@
1
+ import { jsxs as a, jsx as c } from "react/jsx-runtime";
2
+ import { Select as m, SelectTrigger as o, SelectValue as v, SelectContent as d, SelectGroup as p, SelectLabel as b, SelectItem as t, SelectSeparator as f } from "./components-ui-select-select.js";
3
+ const x = (e) => e.length > 0 && "items" in e[0], j = ({
4
+ data: e,
5
+ size: n = "default",
6
+ disabled: i = !1,
7
+ placeholder: s = "Select item...",
8
+ currentValue: u = "",
9
+ onValueChange: S = () => {
10
+ }
11
+ }) => /* @__PURE__ */ a(
12
+ m,
13
+ {
14
+ value: u,
15
+ onValueChange: S,
16
+ children: [
17
+ /* @__PURE__ */ c(
18
+ o,
19
+ {
20
+ size: n,
21
+ disabled: i,
22
+ className: "w-full max-w-48",
23
+ children: /* @__PURE__ */ c(v, { placeholder: s })
24
+ }
25
+ ),
26
+ /* @__PURE__ */ c(d, { className: "w-2.5", children: x(e) ? e.map((l, h) => /* @__PURE__ */ a("div", { children: [
27
+ /* @__PURE__ */ a(p, { children: [
28
+ /* @__PURE__ */ c(b, { children: l.label }),
29
+ l.items.map((r) => /* @__PURE__ */ c(
30
+ t,
31
+ {
32
+ value: r.value,
33
+ children: r.label
34
+ },
35
+ r.value
36
+ ))
37
+ ] }),
38
+ h < e.length - 1 && /* @__PURE__ */ c(f, {})
39
+ ] }, l.label)) : e.map((l) => /* @__PURE__ */ c(
40
+ t,
41
+ {
42
+ value: l.value,
43
+ children: l.label
44
+ },
45
+ l.value
46
+ )) })
47
+ ]
48
+ }
49
+ );
50
+ export {
51
+ j as BasicSelect
52
+ };
53
+ //# sourceMappingURL=components-basic-select-basic-select.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components-basic-select-basic-select.js","sources":["../src/components/basic-select/basic-select.tsx"],"sourcesContent":["import {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectLabel,\n SelectSeparator,\n SelectTrigger,\n SelectValue,\n} from \"../ui/select\";\n\ntype SelectItemType = {\n value: string;\n label: string;\n};\n\ntype SelectGroupType = {\n label: string;\n items: SelectItemType[];\n};\n\ntype SelectData = SelectGroupType[] | SelectItemType[];\n\ntype Props = {\n data: SelectData;\n size?: \"default\" | \"sm\";\n disabled?: boolean;\n placeholder?: string;\n currentValue?: string;\n onValueChange?: (value: string) => void;\n};\n\nconst isGroupedData = (data: SelectData): data is SelectGroupType[] => {\n return data.length > 0 && \"items\" in data[0];\n};\n\nexport const BasicSelect = ({\n data,\n size = \"default\",\n disabled = false,\n placeholder = \"Select item...\",\n currentValue = \"\",\n onValueChange = () => {},\n}: Props) => {\n return (\n <Select\n value={currentValue}\n onValueChange={onValueChange}\n >\n <SelectTrigger\n size={size}\n disabled={disabled}\n className=\"w-full max-w-48\"\n >\n <SelectValue placeholder={placeholder} />\n </SelectTrigger>\n <SelectContent className=\"w-2.5\">\n {isGroupedData(data)\n ? data.map((group, groupIndex) => (\n <div key={group.label}>\n <SelectGroup>\n <SelectLabel>{group.label}</SelectLabel>\n {group.items.map((item) => (\n <SelectItem\n key={item.value}\n value={item.value}\n >\n {item.label}\n </SelectItem>\n ))}\n </SelectGroup>\n {groupIndex < data.length - 1 && <SelectSeparator />}\n </div>\n ))\n : data.map((item) => (\n <SelectItem\n key={item.value}\n value={item.value}\n >\n {item.label}\n </SelectItem>\n ))}\n </SelectContent>\n </Select>\n );\n};\n\nexport type { Props as BasicSelectProps, SelectData, SelectGroupType, SelectItemType };\n"],"names":["isGroupedData","data","BasicSelect","size","disabled","placeholder","currentValue","onValueChange","jsxs","Select","jsx","SelectTrigger","SelectValue","SelectContent","group","groupIndex","SelectGroup","SelectLabel","item","SelectItem","SelectSeparator"],"mappings":";;AAgCA,MAAMA,IAAgB,CAACC,MACdA,EAAK,SAAS,KAAK,WAAWA,EAAK,CAAC,GAGhCC,IAAc,CAAC;AAAA,EAC1B,MAAAD;AAAA,EACA,MAAAE,IAAO;AAAA,EACP,UAAAC,IAAW;AAAA,EACX,aAAAC,IAAc;AAAA,EACd,cAAAC,IAAe;AAAA,EACf,eAAAC,IAAgB,MAAM;AAAA,EAAC;AACzB,MAEI,gBAAAC;AAAA,EAACC;AAAA,EAAA;AAAA,IACC,OAAOH;AAAA,IACP,eAAAC;AAAA,IAEA,UAAA;AAAA,MAAA,gBAAAG;AAAA,QAACC;AAAA,QAAA;AAAA,UACC,MAAAR;AAAA,UACA,UAAAC;AAAA,UACA,WAAU;AAAA,UAEV,UAAA,gBAAAM,EAACE,KAAY,aAAAP,EAAA,CAA0B;AAAA,QAAA;AAAA,MAAA;AAAA,MAEzC,gBAAAK,EAACG,GAAA,EAAc,WAAU,SACtB,UAAAb,EAAcC,CAAI,IACfA,EAAK,IAAI,CAACa,GAAOC,wBACd,OAAA,EACC,UAAA;AAAA,QAAA,gBAAAP,EAACQ,GAAA,EACC,UAAA;AAAA,UAAA,gBAAAN,EAACO,GAAA,EAAa,YAAM,MAAA,CAAM;AAAA,UACzBH,EAAM,MAAM,IAAI,CAACI,MAChB,gBAAAR;AAAA,YAACS;AAAA,YAAA;AAAA,cAEC,OAAOD,EAAK;AAAA,cAEX,UAAAA,EAAK;AAAA,YAAA;AAAA,YAHDA,EAAK;AAAA,UAAA,CAKb;AAAA,QAAA,GACH;AAAA,QACCH,IAAad,EAAK,SAAS,uBAAMmB,GAAA,CAAA,CAAgB;AAAA,MAAA,EAAA,GAZ1CN,EAAM,KAahB,CACD,IACDb,EAAK,IAAI,CAACiB,MACR,gBAAAR;AAAA,QAACS;AAAA,QAAA;AAAA,UAEC,OAAOD,EAAK;AAAA,UAEX,UAAAA,EAAK;AAAA,QAAA;AAAA,QAHDA,EAAK;AAAA,MAAA,CAKb,EAAA,CACP;AAAA,IAAA;AAAA,EAAA;AAAA;"}
@@ -0,0 +1,5 @@
1
+ import { BasicSelect as o } from "./components-basic-select-basic-select.js";
2
+ export {
3
+ o as BasicSelect
4
+ };
5
+ //# sourceMappingURL=components-basic-select.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"components-basic-select.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}