@code0-tech/pictor 1.0.0 → 1.1.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 (454) hide show
  1. package/dist/_virtual/rolldown_runtime.js +9 -0
  2. package/dist/assets/Alert.style.css +1 -0
  3. package/dist/assets/Aurora.style.css +1 -0
  4. package/dist/assets/Avatar.style.css +1 -0
  5. package/dist/assets/Badge.style.css +1 -0
  6. package/dist/assets/Breadcrumb.style.css +1 -0
  7. package/dist/assets/Button.style.css +1 -0
  8. package/dist/assets/ButtonGroup.style.css +1 -0
  9. package/dist/assets/Card.style.css +1 -0
  10. package/dist/assets/Chart.style.css +1 -0
  11. package/dist/assets/Col.style.css +1 -0
  12. package/dist/assets/ColorInput.style.css +1 -0
  13. package/dist/assets/Command.style.css +1 -0
  14. package/dist/assets/Container.style.css +1 -0
  15. package/dist/assets/ContextMenu.style.css +1 -0
  16. package/dist/assets/DataTable.style.css +1 -0
  17. package/dist/assets/DateInput.style.css +1 -0
  18. package/dist/assets/Dialog.style.css +1 -0
  19. package/dist/assets/Editor.styles.css +1 -0
  20. package/dist/assets/EditorInput.style.css +1 -0
  21. package/dist/assets/FileInput.style.css +1 -0
  22. package/dist/assets/FileTabs.style.css +1 -0
  23. package/dist/assets/FullScreen.style.css +1 -0
  24. package/dist/assets/Gantt.style.css +1 -0
  25. package/dist/assets/Icon.style.css +1 -0
  26. package/dist/assets/Input.style.css +1 -0
  27. package/dist/assets/InputWrapper.style.css +1 -0
  28. package/dist/assets/JsonView.style.css +1 -0
  29. package/dist/assets/Layout.style.css +1 -0
  30. package/dist/assets/Menu.style.css +1 -0
  31. package/dist/assets/Progress.style.css +1 -0
  32. package/dist/assets/Quote.style.css +1 -0
  33. package/dist/assets/Resizable.style.css +1 -0
  34. package/dist/assets/Row.style.css +1 -0
  35. package/dist/assets/ScrollArea.style.css +1 -0
  36. package/dist/assets/SegmentedControl.style.css +1 -0
  37. package/dist/assets/SelectInput.style.css +1 -0
  38. package/dist/assets/Tab.style.css +1 -0
  39. package/dist/assets/Text.style.css +1 -0
  40. package/dist/assets/Toast.style.css +1 -0
  41. package/dist/assets/Tooltip.style.css +1 -0
  42. package/dist/components/alert/Alert.js +33 -41
  43. package/dist/components/aurora/Aurora.js +26 -22
  44. package/dist/components/avatar/Avatar.js +57 -55
  45. package/dist/components/badge/Badge.js +57 -64
  46. package/dist/components/breadcrumb/Breadcrumb.js +16 -21
  47. package/dist/components/button/Button.js +23 -31
  48. package/dist/components/button-group/ButtonGroup.js +28 -31
  49. package/dist/components/card/Card.js +28 -43
  50. package/dist/components/card/CardSection.js +21 -29
  51. package/dist/components/chart/Chart.js +138 -153
  52. package/dist/components/chart/LineChart.js +74 -74
  53. package/dist/components/chart/index.js +3 -8
  54. package/dist/components/col/Col.js +18 -29
  55. package/dist/components/command/Command.js +100 -134
  56. package/dist/components/container/Container.js +18 -23
  57. package/dist/components/context-menu/ContextMenu.js +118 -112
  58. package/dist/components/data-table/DataTable.js +53 -64
  59. package/dist/components/data-table/DataTableColumn.js +17 -22
  60. package/dist/components/data-table/DataTableFilterInput.js +208 -205
  61. package/dist/components/data-table/DataTableFilterSuggestionMenu.js +58 -48
  62. package/dist/components/data-table/DataTableHeader.js +33 -38
  63. package/dist/components/data-table/DataTablePagination.js +61 -74
  64. package/dist/components/data-table/index.js +7 -22
  65. package/dist/components/dialog/Dialog.js +106 -97
  66. package/dist/components/editor/Editor.js +352 -323
  67. package/dist/components/file-tabs/FileTabs.js +77 -73
  68. package/dist/components/file-tabs/FileTabs.service.js +85 -87
  69. package/dist/components/file-tabs/FileTabs.view.js +0 -1
  70. package/dist/components/file-tabs/index.js +3 -9
  71. package/dist/components/flex/Flex.js +18 -23
  72. package/dist/components/form/CheckboxInput.js +72 -76
  73. package/dist/components/form/ColorInput.js +378 -353
  74. package/dist/components/form/DateInput.js +315 -265
  75. package/dist/components/form/EditorInput.js +597 -579
  76. package/dist/components/form/EmailInput.js +30 -23
  77. package/dist/components/form/FileInput.js +92 -123
  78. package/dist/components/form/Input.js +64 -58
  79. package/dist/components/form/Input.utils.js +25 -37
  80. package/dist/components/form/InputDescription.js +10 -11
  81. package/dist/components/form/InputLabel.js +17 -22
  82. package/dist/components/form/InputMessage.js +16 -17
  83. package/dist/components/form/InputWrapper.js +55 -65
  84. package/dist/components/form/NumberInput.js +41 -20
  85. package/dist/components/form/PasswordInput.js +71 -54
  86. package/dist/components/form/PinInput.js +49 -65
  87. package/dist/components/form/RadioGroup.js +41 -50
  88. package/dist/components/form/RadioInput.js +30 -29
  89. package/dist/components/form/SelectInput.js +68 -92
  90. package/dist/components/form/SwitchInput.js +17 -18
  91. package/dist/components/form/TagInput.js +108 -122
  92. package/dist/components/form/TextAreaInput.js +24 -21
  93. package/dist/components/form/TextInput.js +30 -22
  94. package/dist/components/form/index.js +22 -87
  95. package/dist/components/form/useForm.js +87 -88
  96. package/dist/components/fullscreen/FullScreen.js +27 -27
  97. package/dist/components/gantt/Gantt.js +99 -98
  98. package/dist/components/gantt/GanttGroup.js +210 -195
  99. package/dist/components/gantt/GanttHeader.js +78 -81
  100. package/dist/components/gantt/GanttItem.js +18 -22
  101. package/dist/components/icon/Icon.d.ts +6 -4
  102. package/dist/components/icon/Icon.js +53 -42
  103. package/dist/components/icon/codezero/codezero.js +10 -0
  104. package/dist/components/icon/codezero/gls.js +9 -0
  105. package/dist/components/icon/codezero/index.js +17 -13
  106. package/dist/components/json-view/JsonView.js +119 -109
  107. package/dist/components/layout/Layout.js +100 -78
  108. package/dist/components/menu/Menu.js +134 -128
  109. package/dist/components/progress/ProgressCircle.js +60 -49
  110. package/dist/components/progress/ProgressLinear.js +39 -43
  111. package/dist/components/quote/Quote.js +51 -43
  112. package/dist/components/resizable/Resizable.js +35 -33
  113. package/dist/components/row/Row.js +18 -23
  114. package/dist/components/scroll-area/ScrollArea.js +65 -76
  115. package/dist/components/segmented-control/SegmentedControl.js +46 -50
  116. package/dist/components/spacing/Spacing.js +15 -23
  117. package/dist/components/tab/Tab.js +73 -66
  118. package/dist/components/text/Text.js +18 -25
  119. package/dist/components/toast/Toast.js +104 -82
  120. package/dist/components/tooltip/Tooltip.js +65 -55
  121. package/dist/index.js +76 -272
  122. package/dist/node_modules/@lezer/common/dist/index.js +778 -143
  123. package/dist/node_modules/@lezer/highlight/dist/index.js +305 -536
  124. package/dist/node_modules/prettier/plugins/babel.js +9582 -7023
  125. package/dist/node_modules/prettier/plugins/estree.js +6997 -4377
  126. package/dist/node_modules/prettier/standalone.js +3444 -2415
  127. package/dist/utils/arrayService.js +0 -1
  128. package/dist/utils/color.js +46 -41
  129. package/dist/utils/component.js +60 -129
  130. package/dist/utils/contextStore.js +47 -58
  131. package/dist/utils/index.js +7 -29
  132. package/dist/utils/motion.js +84 -113
  133. package/dist/utils/reactiveArrayService.js +80 -76
  134. package/dist/utils/size.js +14 -26
  135. package/dist/utils/utils.js +0 -1
  136. package/dist/utils/view.js +27 -24
  137. package/dist/vite-env.d.js +0 -1
  138. package/package.json +28 -23
  139. package/dist/_virtual/compiler-runtime.js +0 -5
  140. package/dist/_virtual/compiler-runtime2.js +0 -4
  141. package/dist/_virtual/react-compiler-runtime.development.js +0 -4
  142. package/dist/_virtual/react-compiler-runtime.production.js +0 -4
  143. package/dist/assets/components/alert/Alert.style.css +0 -1
  144. package/dist/assets/components/aurora/Aurora.style.css +0 -1
  145. package/dist/assets/components/avatar/Avatar.style.css +0 -1
  146. package/dist/assets/components/badge/Badge.style.css +0 -1
  147. package/dist/assets/components/breadcrumb/Breadcrumb.style.css +0 -1
  148. package/dist/assets/components/button/Button.style.css +0 -1
  149. package/dist/assets/components/button-group/ButtonGroup.style.css +0 -1
  150. package/dist/assets/components/card/Card.style.css +0 -1
  151. package/dist/assets/components/chart/Chart.style.css +0 -1
  152. package/dist/assets/components/col/Col.style.css +0 -1
  153. package/dist/assets/components/command/Command.style.css +0 -1
  154. package/dist/assets/components/container/Container.style.css +0 -1
  155. package/dist/assets/components/context-menu/ContextMenu.style.css +0 -1
  156. package/dist/assets/components/data-table/DataTable.style.css +0 -1
  157. package/dist/assets/components/dialog/Dialog.style.css +0 -1
  158. package/dist/assets/components/editor/Editor.styles.css +0 -1
  159. package/dist/assets/components/file-tabs/FileTabs.style.css +0 -1
  160. package/dist/assets/components/form/ColorInput.style.css +0 -1
  161. package/dist/assets/components/form/DateInput.style.css +0 -1
  162. package/dist/assets/components/form/EditorInput.style.css +0 -1
  163. package/dist/assets/components/form/FileInput.style.css +0 -1
  164. package/dist/assets/components/form/Input.style.css +0 -1
  165. package/dist/assets/components/form/InputWrapper.style.css +0 -1
  166. package/dist/assets/components/form/SelectInput.style.css +0 -1
  167. package/dist/assets/components/fullscreen/FullScreen.style.css +0 -1
  168. package/dist/assets/components/gantt/Gantt.style.css +0 -1
  169. package/dist/assets/components/icon/Icon.style.css +0 -1
  170. package/dist/assets/components/json-view/JsonView.style.css +0 -1
  171. package/dist/assets/components/layout/Layout.style.css +0 -1
  172. package/dist/assets/components/menu/Menu.style.css +0 -1
  173. package/dist/assets/components/progress/Progress.style.css +0 -1
  174. package/dist/assets/components/quote/Quote.style.css +0 -1
  175. package/dist/assets/components/resizable/Resizable.style.css +0 -1
  176. package/dist/assets/components/row/Row.style.css +0 -1
  177. package/dist/assets/components/scroll-area/ScrollArea.style.css +0 -1
  178. package/dist/assets/components/segmented-control/SegmentedControl.style.css +0 -1
  179. package/dist/assets/components/tab/Tab.style.css +0 -1
  180. package/dist/assets/components/text/Text.style.css +0 -1
  181. package/dist/assets/components/toast/Toast.style.css +0 -1
  182. package/dist/assets/components/tooltip/Tooltip.style.css +0 -1
  183. package/dist/components/icon/codezero/codezero.svg.js +0 -5
  184. package/dist/components/icon/codezero/gls.svg.js +0 -5
  185. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.js +0 -59
  186. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.js +0 -34
  187. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/index.js +0 -47
  188. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/use-presence.js +0 -17
  189. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/utils.js +0 -12
  190. package/dist/node_modules/framer-motion/dist/es/context/LayoutGroupContext.js +0 -5
  191. package/dist/node_modules/framer-motion/dist/es/context/LazyContext.js +0 -5
  192. package/dist/node_modules/framer-motion/dist/es/context/MotionConfigContext.js +0 -9
  193. package/dist/node_modules/framer-motion/dist/es/context/MotionContext/create.js +0 -13
  194. package/dist/node_modules/framer-motion/dist/es/context/MotionContext/index.js +0 -5
  195. package/dist/node_modules/framer-motion/dist/es/context/MotionContext/utils.js +0 -15
  196. package/dist/node_modules/framer-motion/dist/es/context/PresenceContext.js +0 -5
  197. package/dist/node_modules/framer-motion/dist/es/context/SwitchLayoutGroupContext.js +0 -5
  198. package/dist/node_modules/framer-motion/dist/es/events/add-pointer-event.js +0 -8
  199. package/dist/node_modules/framer-motion/dist/es/events/event-info.js +0 -14
  200. package/dist/node_modules/framer-motion/dist/es/gestures/drag/VisualElementDragControls.js +0 -285
  201. package/dist/node_modules/framer-motion/dist/es/gestures/drag/index.js +0 -22
  202. package/dist/node_modules/framer-motion/dist/es/gestures/drag/utils/constraints.js +0 -67
  203. package/dist/node_modules/framer-motion/dist/es/gestures/focus.js +0 -28
  204. package/dist/node_modules/framer-motion/dist/es/gestures/hover.js +0 -21
  205. package/dist/node_modules/framer-motion/dist/es/gestures/pan/PanSession.js +0 -130
  206. package/dist/node_modules/framer-motion/dist/es/gestures/pan/index.js +0 -43
  207. package/dist/node_modules/framer-motion/dist/es/gestures/press.js +0 -29
  208. package/dist/node_modules/framer-motion/dist/es/motion/features/animation/exit.js +0 -45
  209. package/dist/node_modules/framer-motion/dist/es/motion/features/animation/index.js +0 -33
  210. package/dist/node_modules/framer-motion/dist/es/motion/features/animations.js +0 -13
  211. package/dist/node_modules/framer-motion/dist/es/motion/features/definitions.js +0 -39
  212. package/dist/node_modules/framer-motion/dist/es/motion/features/drag.js +0 -17
  213. package/dist/node_modules/framer-motion/dist/es/motion/features/gestures.js +0 -21
  214. package/dist/node_modules/framer-motion/dist/es/motion/features/layout/MeasureLayout.js +0 -60
  215. package/dist/node_modules/framer-motion/dist/es/motion/features/layout.js +0 -11
  216. package/dist/node_modules/framer-motion/dist/es/motion/features/load-features.js +0 -14
  217. package/dist/node_modules/framer-motion/dist/es/motion/features/viewport/index.js +0 -45
  218. package/dist/node_modules/framer-motion/dist/es/motion/features/viewport/observers.js +0 -21
  219. package/dist/node_modules/framer-motion/dist/es/motion/index.js +0 -62
  220. package/dist/node_modules/framer-motion/dist/es/motion/utils/symbol.js +0 -4
  221. package/dist/node_modules/framer-motion/dist/es/motion/utils/use-motion-ref.js +0 -21
  222. package/dist/node_modules/framer-motion/dist/es/motion/utils/use-visual-element.js +0 -65
  223. package/dist/node_modules/framer-motion/dist/es/motion/utils/use-visual-state.js +0 -52
  224. package/dist/node_modules/framer-motion/dist/es/motion/utils/valid-prop.js +0 -39
  225. package/dist/node_modules/framer-motion/dist/es/render/components/create-proxy.js +0 -18
  226. package/dist/node_modules/framer-motion/dist/es/render/components/motion/feature-bundle.js +0 -13
  227. package/dist/node_modules/framer-motion/dist/es/render/components/motion/proxy.js +0 -7
  228. package/dist/node_modules/framer-motion/dist/es/render/dom/create-visual-element.js +0 -10
  229. package/dist/node_modules/framer-motion/dist/es/render/dom/use-render.js +0 -16
  230. package/dist/node_modules/framer-motion/dist/es/render/dom/utils/filter-props.js +0 -21
  231. package/dist/node_modules/framer-motion/dist/es/render/dom/utils/is-svg-component.js +0 -24
  232. package/dist/node_modules/framer-motion/dist/es/render/html/use-html-visual-state.js +0 -10
  233. package/dist/node_modules/framer-motion/dist/es/render/html/use-props.js +0 -27
  234. package/dist/node_modules/framer-motion/dist/es/render/html/utils/create-render-state.js +0 -9
  235. package/dist/node_modules/framer-motion/dist/es/render/svg/lowercase-elements.js +0 -30
  236. package/dist/node_modules/framer-motion/dist/es/render/svg/use-props.js +0 -22
  237. package/dist/node_modules/framer-motion/dist/es/render/svg/use-svg-visual-state.js +0 -10
  238. package/dist/node_modules/framer-motion/dist/es/render/svg/utils/create-render-state.js +0 -8
  239. package/dist/node_modules/framer-motion/dist/es/utils/distance.js +0 -9
  240. package/dist/node_modules/framer-motion/dist/es/utils/get-context-window.js +0 -4
  241. package/dist/node_modules/framer-motion/dist/es/utils/is-browser.js +0 -4
  242. package/dist/node_modules/framer-motion/dist/es/utils/is-ref-object.js +0 -6
  243. package/dist/node_modules/framer-motion/dist/es/utils/reduced-motion/use-reduced-motion.js +0 -12
  244. package/dist/node_modules/framer-motion/dist/es/utils/use-composed-ref.js +0 -28
  245. package/dist/node_modules/framer-motion/dist/es/utils/use-constant.js +0 -8
  246. package/dist/node_modules/framer-motion/dist/es/utils/use-isomorphic-effect.js +0 -6
  247. package/dist/node_modules/motion-dom/dist/es/animation/AsyncMotionValueAnimation.js +0 -112
  248. package/dist/node_modules/motion-dom/dist/es/animation/JSAnimation.js +0 -144
  249. package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimation.js +0 -106
  250. package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimationExtended.js +0 -38
  251. package/dist/node_modules/motion-dom/dist/es/animation/animate/single-value.js +0 -10
  252. package/dist/node_modules/motion-dom/dist/es/animation/drivers/frame.js +0 -17
  253. package/dist/node_modules/motion-dom/dist/es/animation/generators/inertia.js +0 -37
  254. package/dist/node_modules/motion-dom/dist/es/animation/generators/keyframes.js +0 -30
  255. package/dist/node_modules/motion-dom/dist/es/animation/generators/spring.js +0 -178
  256. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/calc-duration.js +0 -13
  257. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/create-generator-easing.js +0 -13
  258. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/is-generator.js +0 -6
  259. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/velocity.js +0 -9
  260. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/motion-value.js +0 -46
  261. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-target.js +0 -59
  262. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-variant.js +0 -29
  263. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element.js +0 -22
  264. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/DOMKeyframesResolver.js +0 -68
  265. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/KeyframesResolver.js +0 -74
  266. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/get-final.js +0 -8
  267. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/offsets/default.js +0 -8
  268. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/offsets/fill.js +0 -12
  269. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/offsets/time.js +0 -6
  270. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/fill-wildcards.js +0 -7
  271. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/is-none.js +0 -7
  272. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/make-none-animatable.js +0 -16
  273. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/unit-conversion.js +0 -37
  274. package/dist/node_modules/motion-dom/dist/es/animation/optimized-appear/data-id.js +0 -6
  275. package/dist/node_modules/motion-dom/dist/es/animation/optimized-appear/get-appear-id.js +0 -7
  276. package/dist/node_modules/motion-dom/dist/es/animation/utils/WithPromise.js +0 -27
  277. package/dist/node_modules/motion-dom/dist/es/animation/utils/calc-child-stagger.js +0 -7
  278. package/dist/node_modules/motion-dom/dist/es/animation/utils/can-animate.js +0 -23
  279. package/dist/node_modules/motion-dom/dist/es/animation/utils/css-variables-conversion.js +0 -31
  280. package/dist/node_modules/motion-dom/dist/es/animation/utils/default-transitions.js +0 -22
  281. package/dist/node_modules/motion-dom/dist/es/animation/utils/get-value-transition.js +0 -8
  282. package/dist/node_modules/motion-dom/dist/es/animation/utils/is-animatable.js +0 -7
  283. package/dist/node_modules/motion-dom/dist/es/animation/utils/is-css-variable.js +0 -9
  284. package/dist/node_modules/motion-dom/dist/es/animation/utils/is-transition-defined.js +0 -21
  285. package/dist/node_modules/motion-dom/dist/es/animation/utils/make-animation-instant.js +0 -6
  286. package/dist/node_modules/motion-dom/dist/es/animation/utils/replace-transition-type.js +0 -16
  287. package/dist/node_modules/motion-dom/dist/es/animation/utils/resolve-transition.js +0 -10
  288. package/dist/node_modules/motion-dom/dist/es/animation/waapi/easing/cubic-bezier.js +0 -4
  289. package/dist/node_modules/motion-dom/dist/es/animation/waapi/easing/map-easing.js +0 -12
  290. package/dist/node_modules/motion-dom/dist/es/animation/waapi/easing/supported.js +0 -15
  291. package/dist/node_modules/motion-dom/dist/es/animation/waapi/start-waapi-animation.js +0 -21
  292. package/dist/node_modules/motion-dom/dist/es/animation/waapi/supports/waapi.js +0 -33
  293. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/accelerated-values.js +0 -12
  294. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/apply-generator.js +0 -8
  295. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/is-browser-color.js +0 -10
  296. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/linear.js +0 -10
  297. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/unsupported-easing.js +0 -17
  298. package/dist/node_modules/motion-dom/dist/es/events/add-dom-event.js +0 -6
  299. package/dist/node_modules/motion-dom/dist/es/frameloop/batcher.js +0 -27
  300. package/dist/node_modules/motion-dom/dist/es/frameloop/frame.js +0 -9
  301. package/dist/node_modules/motion-dom/dist/es/frameloop/microtask.js +0 -5
  302. package/dist/node_modules/motion-dom/dist/es/frameloop/order.js +0 -21
  303. package/dist/node_modules/motion-dom/dist/es/frameloop/render-step.js +0 -43
  304. package/dist/node_modules/motion-dom/dist/es/frameloop/sync-time.js +0 -15
  305. package/dist/node_modules/motion-dom/dist/es/gestures/drag/state/is-active.js +0 -11
  306. package/dist/node_modules/motion-dom/dist/es/gestures/drag/state/set-active.js +0 -11
  307. package/dist/node_modules/motion-dom/dist/es/gestures/hover.js +0 -38
  308. package/dist/node_modules/motion-dom/dist/es/gestures/press/index.js +0 -34
  309. package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/is-keyboard-accessible.js +0 -18
  310. package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/keyboard.js +0 -27
  311. package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/state.js +0 -4
  312. package/dist/node_modules/motion-dom/dist/es/gestures/utils/is-node-or-child.js +0 -4
  313. package/dist/node_modules/motion-dom/dist/es/gestures/utils/is-primary-pointer.js +0 -4
  314. package/dist/node_modules/motion-dom/dist/es/gestures/utils/setup.js +0 -12
  315. package/dist/node_modules/motion-dom/dist/es/projection/animation/mix-values.js +0 -32
  316. package/dist/node_modules/motion-dom/dist/es/projection/geometry/conversion.js +0 -25
  317. package/dist/node_modules/motion-dom/dist/es/projection/geometry/copy.js +0 -14
  318. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-apply.js +0 -53
  319. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-calc.js +0 -38
  320. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-remove.js +0 -25
  321. package/dist/node_modules/motion-dom/dist/es/projection/geometry/models.js +0 -18
  322. package/dist/node_modules/motion-dom/dist/es/projection/geometry/utils.js +0 -34
  323. package/dist/node_modules/motion-dom/dist/es/projection/node/DocumentProjectionNode.js +0 -13
  324. package/dist/node_modules/motion-dom/dist/es/projection/node/HTMLProjectionNode.js +0 -25
  325. package/dist/node_modules/motion-dom/dist/es/projection/node/create-projection-node.js +0 -618
  326. package/dist/node_modules/motion-dom/dist/es/projection/node/state.js +0 -15
  327. package/dist/node_modules/motion-dom/dist/es/projection/shared/stack.js +0 -53
  328. package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-border-radius.js +0 -21
  329. package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-box-shadow.js +0 -16
  330. package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-correction.js +0 -21
  331. package/dist/node_modules/motion-dom/dist/es/projection/styles/transform.js +0 -13
  332. package/dist/node_modules/motion-dom/dist/es/projection/utils/compare-by-depth.js +0 -4
  333. package/dist/node_modules/motion-dom/dist/es/projection/utils/each-axis.js +0 -6
  334. package/dist/node_modules/motion-dom/dist/es/projection/utils/flat-tree.js +0 -19
  335. package/dist/node_modules/motion-dom/dist/es/projection/utils/has-transform.js +0 -20
  336. package/dist/node_modules/motion-dom/dist/es/projection/utils/measure.js +0 -13
  337. package/dist/node_modules/motion-dom/dist/es/render/Feature.js +0 -10
  338. package/dist/node_modules/motion-dom/dist/es/render/VisualElement.js +0 -263
  339. package/dist/node_modules/motion-dom/dist/es/render/dom/DOMVisualElement.js +0 -28
  340. package/dist/node_modules/motion-dom/dist/es/render/dom/is-css-var.js +0 -4
  341. package/dist/node_modules/motion-dom/dist/es/render/dom/parse-transform.js +0 -65
  342. package/dist/node_modules/motion-dom/dist/es/render/dom/style-set.js +0 -7
  343. package/dist/node_modules/motion-dom/dist/es/render/dom/utils/camel-to-dash.js +0 -6
  344. package/dist/node_modules/motion-dom/dist/es/render/html/HTMLVisualElement.js +0 -37
  345. package/dist/node_modules/motion-dom/dist/es/render/html/utils/build-styles.js +0 -29
  346. package/dist/node_modules/motion-dom/dist/es/render/html/utils/build-transform.js +0 -38
  347. package/dist/node_modules/motion-dom/dist/es/render/html/utils/render.js +0 -12
  348. package/dist/node_modules/motion-dom/dist/es/render/html/utils/scrape-motion-values.js +0 -13
  349. package/dist/node_modules/motion-dom/dist/es/render/store.js +0 -4
  350. package/dist/node_modules/motion-dom/dist/es/render/svg/SVGVisualElement.js +0 -40
  351. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/build-attrs.js +0 -32
  352. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/camel-case-attrs.js +0 -28
  353. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/is-svg-tag.js +0 -4
  354. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/path.js +0 -15
  355. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/render.js +0 -11
  356. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/scrape-motion-values.js +0 -15
  357. package/dist/node_modules/motion-dom/dist/es/render/utils/animation-state.js +0 -143
  358. package/dist/node_modules/motion-dom/dist/es/render/utils/get-variant-context.js +0 -20
  359. package/dist/node_modules/motion-dom/dist/es/render/utils/is-animation-controls.js +0 -6
  360. package/dist/node_modules/motion-dom/dist/es/render/utils/is-controlling-variants.js +0 -13
  361. package/dist/node_modules/motion-dom/dist/es/render/utils/is-forced-motion-value.js +0 -9
  362. package/dist/node_modules/motion-dom/dist/es/render/utils/is-keyframes-target.js +0 -4
  363. package/dist/node_modules/motion-dom/dist/es/render/utils/is-variant-label.js +0 -6
  364. package/dist/node_modules/motion-dom/dist/es/render/utils/keys-position.js +0 -13
  365. package/dist/node_modules/motion-dom/dist/es/render/utils/keys-transform.js +0 -23
  366. package/dist/node_modules/motion-dom/dist/es/render/utils/motion-values.js +0 -25
  367. package/dist/node_modules/motion-dom/dist/es/render/utils/reduced-motion/index.js +0 -15
  368. package/dist/node_modules/motion-dom/dist/es/render/utils/reduced-motion/state.js +0 -5
  369. package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-dynamic-variants.js +0 -8
  370. package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-variants.js +0 -20
  371. package/dist/node_modules/motion-dom/dist/es/render/utils/setters.js +0 -21
  372. package/dist/node_modules/motion-dom/dist/es/render/utils/shallow-compare.js +0 -14
  373. package/dist/node_modules/motion-dom/dist/es/render/utils/variant-props.js +0 -13
  374. package/dist/node_modules/motion-dom/dist/es/resize/handle-element.js +0 -39
  375. package/dist/node_modules/motion-dom/dist/es/resize/handle-window.js +0 -23
  376. package/dist/node_modules/motion-dom/dist/es/resize/index.js +0 -8
  377. package/dist/node_modules/motion-dom/dist/es/utils/delay.js +0 -12
  378. package/dist/node_modules/motion-dom/dist/es/utils/interpolate.js +0 -42
  379. package/dist/node_modules/motion-dom/dist/es/utils/is-html-element.js +0 -7
  380. package/dist/node_modules/motion-dom/dist/es/utils/is-svg-element.js +0 -7
  381. package/dist/node_modules/motion-dom/dist/es/utils/is-svg-svg-element.js +0 -7
  382. package/dist/node_modules/motion-dom/dist/es/utils/mix/color.js +0 -29
  383. package/dist/node_modules/motion-dom/dist/es/utils/mix/complex.js +0 -51
  384. package/dist/node_modules/motion-dom/dist/es/utils/mix/immediate.js +0 -6
  385. package/dist/node_modules/motion-dom/dist/es/utils/mix/index.js +0 -8
  386. package/dist/node_modules/motion-dom/dist/es/utils/mix/number.js +0 -4
  387. package/dist/node_modules/motion-dom/dist/es/utils/mix/visibility.js +0 -8
  388. package/dist/node_modules/motion-dom/dist/es/utils/resolve-elements.js +0 -15
  389. package/dist/node_modules/motion-dom/dist/es/utils/supports/flags.js +0 -4
  390. package/dist/node_modules/motion-dom/dist/es/utils/supports/linear-easing.js +0 -12
  391. package/dist/node_modules/motion-dom/dist/es/utils/supports/memo.js +0 -9
  392. package/dist/node_modules/motion-dom/dist/es/utils/supports/scroll-timeline.js +0 -5
  393. package/dist/node_modules/motion-dom/dist/es/value/index.js +0 -212
  394. package/dist/node_modules/motion-dom/dist/es/value/types/auto.js +0 -7
  395. package/dist/node_modules/motion-dom/dist/es/value/types/color/hex.js +0 -19
  396. package/dist/node_modules/motion-dom/dist/es/value/types/color/hsla-to-rgba.js +0 -22
  397. package/dist/node_modules/motion-dom/dist/es/value/types/color/hsla.js +0 -12
  398. package/dist/node_modules/motion-dom/dist/es/value/types/color/index.js +0 -15
  399. package/dist/node_modules/motion-dom/dist/es/value/types/color/rgba.js +0 -16
  400. package/dist/node_modules/motion-dom/dist/es/value/types/color/utils.js +0 -18
  401. package/dist/node_modules/motion-dom/dist/es/value/types/complex/filter.js +0 -24
  402. package/dist/node_modules/motion-dom/dist/es/value/types/complex/index.js +0 -51
  403. package/dist/node_modules/motion-dom/dist/es/value/types/complex/mask.js +0 -11
  404. package/dist/node_modules/motion-dom/dist/es/value/types/dimensions.js +0 -9
  405. package/dist/node_modules/motion-dom/dist/es/value/types/int.js +0 -8
  406. package/dist/node_modules/motion-dom/dist/es/value/types/maps/defaults.js +0 -27
  407. package/dist/node_modules/motion-dom/dist/es/value/types/maps/number.js +0 -70
  408. package/dist/node_modules/motion-dom/dist/es/value/types/maps/transform.js +0 -37
  409. package/dist/node_modules/motion-dom/dist/es/value/types/numbers/index.js +0 -17
  410. package/dist/node_modules/motion-dom/dist/es/value/types/numbers/units.js +0 -17
  411. package/dist/node_modules/motion-dom/dist/es/value/types/test.js +0 -4
  412. package/dist/node_modules/motion-dom/dist/es/value/types/utils/animatable-none.js +0 -12
  413. package/dist/node_modules/motion-dom/dist/es/value/types/utils/color-regex.js +0 -4
  414. package/dist/node_modules/motion-dom/dist/es/value/types/utils/find.js +0 -8
  415. package/dist/node_modules/motion-dom/dist/es/value/types/utils/float-regex.js +0 -4
  416. package/dist/node_modules/motion-dom/dist/es/value/types/utils/get-as-type.js +0 -4
  417. package/dist/node_modules/motion-dom/dist/es/value/types/utils/is-nullish.js +0 -6
  418. package/dist/node_modules/motion-dom/dist/es/value/types/utils/sanitize.js +0 -4
  419. package/dist/node_modules/motion-dom/dist/es/value/types/utils/single-color-regex.js +0 -4
  420. package/dist/node_modules/motion-dom/dist/es/value/utils/is-motion-value.js +0 -4
  421. package/dist/node_modules/motion-dom/dist/es/value/utils/resolve-motion-value.js +0 -7
  422. package/dist/node_modules/motion-dom/dist/es/value/will-change/add-will-change.js +0 -14
  423. package/dist/node_modules/motion-dom/dist/es/value/will-change/is.js +0 -7
  424. package/dist/node_modules/motion-utils/dist/es/array.js +0 -11
  425. package/dist/node_modules/motion-utils/dist/es/clamp.js +0 -4
  426. package/dist/node_modules/motion-utils/dist/es/easing/anticipate.js +0 -5
  427. package/dist/node_modules/motion-utils/dist/es/easing/back.js +0 -9
  428. package/dist/node_modules/motion-utils/dist/es/easing/circ.js +0 -8
  429. package/dist/node_modules/motion-utils/dist/es/easing/cubic-bezier.js +0 -19
  430. package/dist/node_modules/motion-utils/dist/es/easing/ease.js +0 -7
  431. package/dist/node_modules/motion-utils/dist/es/easing/modifiers/mirror.js +0 -4
  432. package/dist/node_modules/motion-utils/dist/es/easing/modifiers/reverse.js +0 -4
  433. package/dist/node_modules/motion-utils/dist/es/easing/utils/is-bezier-definition.js +0 -4
  434. package/dist/node_modules/motion-utils/dist/es/easing/utils/is-easing-array.js +0 -4
  435. package/dist/node_modules/motion-utils/dist/es/easing/utils/map.js +0 -32
  436. package/dist/node_modules/motion-utils/dist/es/errors.js +0 -14
  437. package/dist/node_modules/motion-utils/dist/es/format-error-message.js +0 -6
  438. package/dist/node_modules/motion-utils/dist/es/global-config.js +0 -4
  439. package/dist/node_modules/motion-utils/dist/es/is-numerical-string.js +0 -4
  440. package/dist/node_modules/motion-utils/dist/es/is-object.js +0 -4
  441. package/dist/node_modules/motion-utils/dist/es/is-zero-value-string.js +0 -4
  442. package/dist/node_modules/motion-utils/dist/es/memo.js +0 -8
  443. package/dist/node_modules/motion-utils/dist/es/noop.js +0 -4
  444. package/dist/node_modules/motion-utils/dist/es/pipe.js +0 -4
  445. package/dist/node_modules/motion-utils/dist/es/progress.js +0 -7
  446. package/dist/node_modules/motion-utils/dist/es/subscription-manager.js +0 -29
  447. package/dist/node_modules/motion-utils/dist/es/time-conversion.js +0 -5
  448. package/dist/node_modules/motion-utils/dist/es/velocity-per-second.js +0 -4
  449. package/dist/node_modules/motion-utils/dist/es/warn-once.js +0 -8
  450. package/dist/node_modules/react/cjs/react-compiler-runtime.development.js +0 -21
  451. package/dist/node_modules/react/cjs/react-compiler-runtime.production.js +0 -14
  452. package/dist/node_modules/react/compiler-runtime.js +0 -10
  453. /package/dist/assets/{components/flex/Flex.style.css → Flex.style.css} +0 -0
  454. /package/dist/assets/{components/spacing/Spacing.style.css → Spacing.style.css} +0 -0
@@ -1,93 +1,69 @@
1
- import { jsx as o } from "react/jsx-runtime";
2
- import { c as r } from "../../_virtual/compiler-runtime.js";
3
- import * as s from "@radix-ui/react-select";
4
- import "../../utils/contextStore.js";
5
- import "react";
6
- import { mergeComponentProps as f } from "../../utils/component.js";
7
- import "js-md5";
8
- import { InputWrapper as R } from "./InputWrapper.js";
9
- import '../../assets/components/form/SelectInput.style.css';/* empty css */
10
- const A = (i) => {
11
- const t = r.c(24);
12
- let e, l, n, c, m, u, a, _, g, T;
13
- if (t[0] !== i) {
14
- const {
15
- title: I,
16
- description: y,
17
- left: C,
18
- leftType: p,
19
- rightType: w,
20
- right: P,
21
- formValidation: h,
22
- ...x
23
- } = i;
24
- l = R, c = I, m = y, u = C, a = p, _ = P, g = w, T = h, e = s.Root, n = f("select-input", {
25
- ...x,
26
- onValueChange: (d) => {
27
- h?.setValue?.(d), x.onValueChange?.(d);
28
- }
29
- }), t[0] = i, t[1] = e, t[2] = l, t[3] = n, t[4] = c, t[5] = m, t[6] = u, t[7] = a, t[8] = _, t[9] = g, t[10] = T;
30
- } else
31
- e = t[1], l = t[2], n = t[3], c = t[4], m = t[5], u = t[6], a = t[7], _ = t[8], g = t[9], T = t[10];
32
- const $ = n;
33
- let S;
34
- t[11] !== e || t[12] !== $ ? (S = /* @__PURE__ */ o(e, { ...$ }), t[11] = e, t[12] = $, t[13] = S) : S = t[13];
35
- let V;
36
- return t[14] !== l || t[15] !== c || t[16] !== m || t[17] !== u || t[18] !== a || t[19] !== _ || t[20] !== g || t[21] !== T || t[22] !== S ? (V = /* @__PURE__ */ o(l, { title: c, description: m, left: u, leftType: a, right: _, rightType: g, formValidation: T, children: S }), t[14] = l, t[15] = c, t[16] = m, t[17] = u, t[18] = a, t[19] = _, t[20] = g, t[21] = T, t[22] = S, t[23] = V) : V = t[23], V;
37
- }, B = (i) => {
38
- const t = r.c(4);
39
- let e;
40
- t[0] !== i ? (e = f("select-input__trigger", i), t[0] = i, t[1] = e) : e = t[1];
41
- let l;
42
- return t[2] !== e ? (l = /* @__PURE__ */ o(s.Trigger, { ...e }), t[2] = e, t[3] = l) : l = t[3], l;
43
- }, D = (i) => {
44
- const t = r.c(4);
45
- let e;
46
- t[0] !== i ? (e = f("select-input__value", i), t[0] = i, t[1] = e) : e = t[1];
47
- let l;
48
- return t[2] !== e ? (l = /* @__PURE__ */ o(s.Value, { ...e }), t[2] = e, t[3] = l) : l = t[3], l;
49
- }, F = (i) => {
50
- const t = r.c(5), e = `select-input__content select-input__content--${i.color ?? "primary"}`;
51
- let l;
52
- t[0] !== i || t[1] !== e ? (l = f(e, i), t[0] = i, t[1] = e, t[2] = l) : l = t[2];
53
- const n = l;
54
- let c;
55
- return t[3] !== n ? (c = /* @__PURE__ */ o(s.Content, { ...n }), t[3] = n, t[4] = c) : c = t[4], c;
56
- }, G = (i) => {
57
- const t = r.c(4);
58
- let e;
59
- t[0] !== i ? (e = f("select-input__portal", i), t[0] = i, t[1] = e) : e = t[1];
60
- const l = e;
61
- let n;
62
- return t[2] !== l ? (n = /* @__PURE__ */ o(s.Portal, { ...l }), t[2] = l, t[3] = n) : n = t[3], n;
63
- }, H = (i) => {
64
- const t = r.c(4);
65
- let e;
66
- t[0] !== i ? (e = f("select-input__viewport", i), t[0] = i, t[1] = e) : e = t[1];
67
- let l;
68
- return t[2] !== e ? (l = /* @__PURE__ */ o(s.Viewport, { ...e }), t[2] = e, t[3] = l) : l = t[3], l;
69
- }, J = (i) => {
70
- const t = r.c(4);
71
- let e;
72
- t[0] !== i ? (e = f("select-input__item", i), t[0] = i, t[1] = e) : e = t[1];
73
- const l = e;
74
- let n;
75
- return t[2] !== l ? (n = /* @__PURE__ */ o(s.Item, { ...l }), t[2] = l, t[3] = n) : n = t[3], n;
76
- }, K = (i) => {
77
- const t = r.c(4);
78
- let e;
79
- t[0] !== i ? (e = f("select-input__item-text", i), t[0] = i, t[1] = e) : e = t[1];
80
- const l = e;
81
- let n;
82
- return t[2] !== l ? (n = /* @__PURE__ */ o(s.ItemText, { ...l }), t[2] = l, t[3] = n) : n = t[3], n;
83
- };
84
- export {
85
- F as SelectContent,
86
- A as SelectInput,
87
- J as SelectItem,
88
- K as SelectItemText,
89
- G as SelectPortal,
90
- B as SelectTrigger,
91
- D as SelectValue,
92
- H as SelectViewport
1
+ import { mergeComponentProps } from "../../utils/component.js";
2
+ import "../../utils/index.js";
3
+ import { InputWrapper } from "./InputWrapper.js";
4
+ import '../../assets/SelectInput.style.css';/* empty css */
5
+ import { c } from "react/compiler-runtime";
6
+ import React from "react";
7
+ import { jsx } from "react/jsx-runtime";
8
+ import * as RadixSelect from "@radix-ui/react-select";
9
+ const SelectInput = (i) => {
10
+ let o = c(24), s, l, u, d, f, p, m, h, g, _;
11
+ if (o[0] !== i) {
12
+ let { title: r, description: a, left: v, leftType: y, rightType: b, right: x, formValidation: S, ...C } = i;
13
+ l = InputWrapper, d = r, f = a, p = v, m = y, h = x, g = b, _ = S, s = RadixSelect.Root, u = mergeComponentProps("select-input", {
14
+ ...C,
15
+ onValueChange: (e) => {
16
+ S?.setValue?.(e), C.onValueChange?.(e);
17
+ }
18
+ }), o[0] = i, o[1] = s, o[2] = l, o[3] = u, o[4] = d, o[5] = f, o[6] = p, o[7] = m, o[8] = h, o[9] = g, o[10] = _;
19
+ } else s = o[1], l = o[2], u = o[3], d = o[4], f = o[5], p = o[6], m = o[7], h = o[8], g = o[9], _ = o[10];
20
+ let v = u, y;
21
+ o[11] !== s || o[12] !== v ? (y = /* @__PURE__ */ jsx(s, { ...v }), o[11] = s, o[12] = v, o[13] = y) : y = o[13];
22
+ let b;
23
+ return o[14] !== l || o[15] !== d || o[16] !== f || o[17] !== p || o[18] !== m || o[19] !== h || o[20] !== g || o[21] !== _ || o[22] !== y ? (b = /* @__PURE__ */ jsx(l, {
24
+ title: d,
25
+ description: f,
26
+ left: p,
27
+ leftType: m,
28
+ right: h,
29
+ rightType: g,
30
+ formValidation: _,
31
+ children: y
32
+ }), o[14] = l, o[15] = d, o[16] = f, o[17] = p, o[18] = m, o[19] = h, o[20] = g, o[21] = _, o[22] = y, o[23] = b) : b = o[23], b;
33
+ }, SelectTrigger = (n) => {
34
+ let i = c(4), o;
35
+ i[0] === n ? o = i[1] : (o = mergeComponentProps("select-input__trigger", n), i[0] = n, i[1] = o);
36
+ let s;
37
+ return i[2] === o ? s = i[3] : (s = /* @__PURE__ */ jsx(RadixSelect.Trigger, { ...o }), i[2] = o, i[3] = s), s;
38
+ }, SelectValue = (n) => {
39
+ let i = c(4), o;
40
+ i[0] === n ? o = i[1] : (o = mergeComponentProps("select-input__value", n), i[0] = n, i[1] = o);
41
+ let s;
42
+ return i[2] === o ? s = i[3] : (s = /* @__PURE__ */ jsx(RadixSelect.Value, { ...o }), i[2] = o, i[3] = s), s;
43
+ }, SelectContent = (n) => {
44
+ let i = c(5), o = `select-input__content select-input__content--${n.color ?? "primary"}`, s;
45
+ i[0] !== n || i[1] !== o ? (s = mergeComponentProps(o, n), i[0] = n, i[1] = o, i[2] = s) : s = i[2];
46
+ let l = s, u;
47
+ return i[3] === l ? u = i[4] : (u = /* @__PURE__ */ jsx(RadixSelect.Content, { ...l }), i[3] = l, i[4] = u), u;
48
+ }, SelectPortal = (n) => {
49
+ let i = c(4), o;
50
+ i[0] === n ? o = i[1] : (o = mergeComponentProps("select-input__portal", n), i[0] = n, i[1] = o);
51
+ let s = o, l;
52
+ return i[2] === s ? l = i[3] : (l = /* @__PURE__ */ jsx(RadixSelect.Portal, { ...s }), i[2] = s, i[3] = l), l;
53
+ }, SelectViewport = (n) => {
54
+ let i = c(4), o;
55
+ i[0] === n ? o = i[1] : (o = mergeComponentProps("select-input__viewport", n), i[0] = n, i[1] = o);
56
+ let s;
57
+ return i[2] === o ? s = i[3] : (s = /* @__PURE__ */ jsx(RadixSelect.Viewport, { ...o }), i[2] = o, i[3] = s), s;
58
+ }, SelectItem = (n) => {
59
+ let i = c(4), o;
60
+ i[0] === n ? o = i[1] : (o = mergeComponentProps("select-input__item", n), i[0] = n, i[1] = o);
61
+ let s = o, l;
62
+ return i[2] === s ? l = i[3] : (l = /* @__PURE__ */ jsx(RadixSelect.Item, { ...s }), i[2] = s, i[3] = l), l;
63
+ }, SelectItemText = (n) => {
64
+ let i = c(4), o;
65
+ i[0] === n ? o = i[1] : (o = mergeComponentProps("select-input__item-text", n), i[0] = n, i[1] = o);
66
+ let s = o, l;
67
+ return i[2] === s ? l = i[3] : (l = /* @__PURE__ */ jsx(RadixSelect.ItemText, { ...s }), i[2] = s, i[3] = l), l;
93
68
  };
69
+ export { SelectContent, SelectInput, SelectItem, SelectItemText, SelectPortal, SelectTrigger, SelectValue, SelectViewport };
@@ -1,19 +1,18 @@
1
- import { jsx as n } from "react/jsx-runtime";
2
- import e from "react";
3
- import { Input as p } from "./Input.js";
4
- const m = e.forwardRef((r, t) => {
5
- t = t || e.useRef(null);
6
- const {
7
- value: l,
8
- initialValue: o,
9
- ...u
10
- } = r;
11
- return /* @__PURE__ */ n(p, { wrapperComponent: {
12
- className: "switch-input"
13
- }, type: "checkbox", right: null, left: null, ref: t, value: l, ...o ? {
14
- defaultChecked: !0
15
- } : {}, ...u });
1
+ import { Input } from "./Input.js";
2
+ import React from "react";
3
+ import { jsx } from "react/jsx-runtime";
4
+ const SwitchInput = React.forwardRef((r, i) => {
5
+ i ||= React.useRef(null);
6
+ let { value: a, initialValue: o, ...s } = r;
7
+ return /* @__PURE__ */ jsx(Input, {
8
+ wrapperComponent: { className: "switch-input" },
9
+ type: "checkbox",
10
+ right: null,
11
+ left: null,
12
+ ref: i,
13
+ value: a,
14
+ ...o ? { defaultChecked: !0 } : {},
15
+ ...s
16
+ });
16
17
  });
17
- export {
18
- m as SwitchInput
19
- };
18
+ export { SwitchInput };
@@ -1,124 +1,110 @@
1
- import { jsx as l } from "react/jsx-runtime";
2
- import { c as I } from "../../_virtual/compiler-runtime.js";
3
- import b, { useState as K, useRef as k, useReducer as j, useCallback as A, useEffect as v, useMemo as B, useContext as L } from "react";
4
- import { EditorInput as U, EditorInputMenu as q, EditorInputMenuItem as z, EditorInputSubMenu as F, EditorInputTrigger as G, EditorInputValue as H } from "./EditorInput.js";
5
- import { Badge as J } from "../badge/Badge.js";
6
- import { Text as $ } from "../text/Text.js";
7
- const E = "⟦", d = "⟧", R = new RegExp(`${E}([^${d}]+)${d}`, "g"), Q = new RegExp(`(${E}[^${d}]+${d})|([^${E}${d}]+)`, "g"), V = (t) => `${E}${String(t)}${d}`, W = (t) => t.slice(E.length, -d.length), y = (t) => t.map((e) => V(e.value)).join(""), X = (t) => t.replace(R, "").trim(), Y = (t, e) => {
8
- let n = !1;
9
- const r = t.replace(Q, (a, o, c) => o || (!n && c.trim() ? (n = !0, e) : ""));
10
- return n ? r : r + e;
11
- }, _ = b.createContext(null), D = () => {
12
- const t = L(_);
13
- if (!t)
14
- throw new Error("TagInput.* components must be used inside <TagInput>");
15
- return t;
16
- }, se = (t) => {
17
- const {
18
- allowCustomValues: e = !1,
19
- onChange: n,
20
- formValidation: r,
21
- tokenRules: a,
22
- value: o,
23
- initialValue: c,
24
- defaultValue: T,
25
- children: h,
26
- ...p
27
- } = t, i = o ?? c ?? T, [g, C] = K(() => y(i ?? [])), M = k(/* @__PURE__ */ new Map()), [, N] = j((u) => u + 1, 0), O = A((u, s) => {
28
- M.current.set(u, s), N();
29
- }, []), x = k(i), S = (u) => {
30
- const s = [...u.matchAll(R)].map(([, m]) => {
31
- const f = M.current.get(m);
32
- return {
33
- value: f ? f.value : m,
34
- valueData: f?.data
35
- };
36
- });
37
- x.current = s, C(u), r?.setValue?.(s), n?.(s);
38
- };
39
- v(() => {
40
- i !== x.current && (x.current = i, C(y(i ?? [])));
41
- }, [i]);
42
- const P = B(() => [{
43
- pattern: R,
44
- void: !0,
45
- // The chip (input rendering) is defined by the token alone — the menu
46
- // item's `children` is menu-only and must NOT be reused here. The tag's
47
- // value is matched against the consumer's `tokenRules` to pick the chip.
48
- wrap: (u) => {
49
- const s = W(u), m = a?.find((f) => new RegExp(f.pattern.source, f.pattern.flags.replace("g", "")).test(s));
50
- if (m?.wrap) {
51
- const f = new RegExp(m.pattern.source, m.pattern.flags.replace("g", "")).exec(s);
52
- return m.wrap(s, /* @__PURE__ */ l($, { children: s }), f ?? [s]);
53
- }
54
- return m ? /* @__PURE__ */ l("span", { style: m.style, className: m.className, children: /* @__PURE__ */ l($, { children: s }) }) : /* @__PURE__ */ l(J, { m: 0.01, children: /* @__PURE__ */ l($, { children: s }) });
55
- }
56
- }], [a]), w = {
57
- search: X(g),
58
- allowCustomValues: e,
59
- insertToken: (u) => S(Y(g, u)),
60
- registerTag: O
61
- };
62
- return /* @__PURE__ */ l(_.Provider, { value: w, children: /* @__PURE__ */ l(U, { ...p, value: g, search: w.search, tokenRules: P, formValidation: r && {
63
- valid: r.valid,
64
- notValidMessage: r.notValidMessage
65
- }, onChange: S, onSelect: (u) => w.insertToken(String(u)), children: h }) });
66
- }, ae = (t) => {
67
- const e = I.c(2);
68
- let n;
69
- return e[0] !== t ? (n = /* @__PURE__ */ l(q, { ...t }), e[0] = t, e[1] = n) : n = e[1], n;
70
- }, ce = (t) => {
71
- const e = I.c(2);
72
- let n;
73
- return e[0] !== t ? (n = /* @__PURE__ */ l(F, { ...t }), e[0] = t, e[1] = n) : n = e[1], n;
74
- }, ue = ({
75
- value: t,
76
- data: e,
77
- onlyOnce: n,
78
- aliases: r,
79
- children: a
80
- }) => {
81
- const {
82
- registerTag: o
83
- } = D(), c = k({
84
- value: t,
85
- data: e,
86
- children: a
87
- });
88
- return c.current.value = t, c.current.data = e, c.current.children = a, v(() => o(String(t), c.current), [t, o]), /* @__PURE__ */ l(z, { value: V(t), data: e, onlyOnce: n, aliases: [String(t), ...r ?? []], children: a });
89
- }, le = (t) => {
90
- const e = I.c(14);
91
- let n, r;
92
- e[0] !== t ? ({
93
- onKeyDown: n,
94
- ...r
95
- } = t, e[0] = t, e[1] = n, e[2] = r) : (n = e[1], r = e[2]);
96
- const {
97
- search: a,
98
- allowCustomValues: o,
99
- insertToken: c
100
- } = D();
101
- let T;
102
- e[3] !== o || e[4] !== c || e[5] !== a ? (T = () => {
103
- o && a && c(V(a));
104
- }, e[3] = o, e[4] = c, e[5] = a, e[6] = T) : T = e[6];
105
- const h = T;
106
- let p;
107
- e[7] !== o || e[8] !== h || e[9] !== n ? (p = (g) => {
108
- (g.key === "Enter" && !g.defaultPrevented || g.key === "," && o) && (g.preventDefault(), h()), n?.(g);
109
- }, e[7] = o, e[8] = h, e[9] = n, e[10] = p) : p = e[10];
110
- let i;
111
- return e[11] !== r || e[12] !== p ? (i = /* @__PURE__ */ l(H, { ...r, onKeyDown: p }), e[11] = r, e[12] = p, e[13] = i) : i = e[13], i;
112
- }, ie = (t) => {
113
- const e = I.c(2);
114
- let n;
115
- return e[0] !== t ? (n = /* @__PURE__ */ l(G, { ...t }), e[0] = t, e[1] = n) : n = e[1], n;
1
+ import { Badge } from "../badge/Badge.js";
2
+ import { Text } from "../text/Text.js";
3
+ import { EditorInput, EditorInputMenu, EditorInputMenuItem, EditorInputSubMenu, EditorInputTrigger, EditorInputValue } from "./EditorInput.js";
4
+ import { c } from "react/compiler-runtime";
5
+ import React, { useCallback, useContext, useEffect, useMemo, useReducer, useRef, useState } from "react";
6
+ import { jsx } from "react/jsx-runtime";
7
+ var TOKEN_OPEN = "⟦", TOKEN_CLOSE = "⟧", tokenPattern = RegExp(`${TOKEN_OPEN}([^${TOKEN_CLOSE}]+)${TOKEN_CLOSE}`, "g"), tokenOrTextPattern = RegExp(`(${TOKEN_OPEN}[^${TOKEN_CLOSE}]+${TOKEN_CLOSE})|([^${TOKEN_OPEN}${TOKEN_CLOSE}]+)`, "g"), encodeToken = (e) => `${TOKEN_OPEN}${String(e)}${TOKEN_CLOSE}`, decodeToken = (e) => e.slice(1, -1), tagsToText = (e) => e.map((e) => encodeToken(e.value)).join(""), textToSearch = (e) => e.replace(tokenPattern, "").trim(), insertTokenAtCaret = (e, p) => {
8
+ let m = !1, h = e.replace(tokenOrTextPattern, (e, h, g) => h || (!m && g.trim() ? (m = !0, p) : ""));
9
+ return m ? h : h + p;
10
+ }, TagInputContext = React.createContext(null), useTagInput = () => {
11
+ let e = useContext(TagInputContext);
12
+ if (!e) throw Error("TagInput.* components must be used inside <TagInput>");
13
+ return e;
116
14
  };
117
- export {
118
- se as TagInput,
119
- ae as TagInputMenu,
120
- ue as TagInputMenuItem,
121
- ce as TagInputSubMenu,
122
- ie as TagInputTrigger,
123
- le as TagInputValue
15
+ const TagInput = (h) => {
16
+ let { allowCustomValues: g = !1, onChange: _, formValidation: v, tokenRules: y, value: b, initialValue: x, defaultValue: C, children: T, ...E } = h, D = b ?? x ?? C, [O, k] = useState(() => tagsToText(D ?? [])), A = useRef(/* @__PURE__ */ new Map()), [, j] = useReducer((e) => e + 1, 0), M = useCallback((e, p) => {
17
+ A.current.set(e, p), j();
18
+ }, []), N = useRef(D), P = (e) => {
19
+ let p = [...e.matchAll(tokenPattern)].map(([, e]) => {
20
+ let p = A.current.get(e);
21
+ return {
22
+ value: p ? p.value : e,
23
+ valueData: p?.data
24
+ };
25
+ });
26
+ N.current = p, k(e), v?.setValue?.(p), _?.(p);
27
+ };
28
+ useEffect(() => {
29
+ D !== N.current && (N.current = D, k(tagsToText(D ?? [])));
30
+ }, [D]);
31
+ let F = useMemo(() => [{
32
+ pattern: tokenPattern,
33
+ void: !0,
34
+ wrap: (m) => {
35
+ let h = decodeToken(m), g = y?.find((e) => new RegExp(e.pattern.source, e.pattern.flags.replace("g", "")).test(h));
36
+ if (g?.wrap) {
37
+ let e = new RegExp(g.pattern.source, g.pattern.flags.replace("g", "")).exec(h);
38
+ return g.wrap(h, /* @__PURE__ */ jsx(Text, { children: h }), e ?? [h]);
39
+ }
40
+ return g ? /* @__PURE__ */ jsx("span", {
41
+ style: g.style,
42
+ className: g.className,
43
+ children: /* @__PURE__ */ jsx(Text, { children: h })
44
+ }) : /* @__PURE__ */ jsx(Badge, {
45
+ m: .01,
46
+ children: /* @__PURE__ */ jsx(Text, { children: h })
47
+ });
48
+ }
49
+ }], [y]), I = {
50
+ search: textToSearch(O),
51
+ allowCustomValues: g,
52
+ insertToken: (e) => P(insertTokenAtCaret(O, e)),
53
+ registerTag: M
54
+ };
55
+ return /* @__PURE__ */ jsx(TagInputContext.Provider, {
56
+ value: I,
57
+ children: /* @__PURE__ */ jsx(EditorInput, {
58
+ ...E,
59
+ value: O,
60
+ search: I.search,
61
+ tokenRules: F,
62
+ formValidation: v && {
63
+ valid: v.valid,
64
+ notValidMessage: v.notValidMessage
65
+ },
66
+ onChange: P,
67
+ onSelect: (e) => I.insertToken(String(e)),
68
+ children: T
69
+ })
70
+ });
71
+ }, TagInputMenu = (e) => {
72
+ let p = c(2), m;
73
+ return p[0] === e ? m = p[1] : (m = /* @__PURE__ */ jsx(EditorInputMenu, { ...e }), p[0] = e, p[1] = m), m;
74
+ }, TagInputSubMenu = (e) => {
75
+ let p = c(2), m;
76
+ return p[0] === e ? m = p[1] : (m = /* @__PURE__ */ jsx(EditorInputSubMenu, { ...e }), p[0] = e, p[1] = m), m;
77
+ }, TagInputMenuItem = ({ value: e, data: p, onlyOnce: m, aliases: h, children: _ }) => {
78
+ let { registerTag: v } = useTagInput(), y = useRef({
79
+ value: e,
80
+ data: p,
81
+ children: _
82
+ });
83
+ return y.current.value = e, y.current.data = p, y.current.children = _, useEffect(() => v(String(e), y.current), [e, v]), /* @__PURE__ */ jsx(EditorInputMenuItem, {
84
+ value: encodeToken(e),
85
+ data: p,
86
+ onlyOnce: m,
87
+ aliases: [String(e), ...h ?? []],
88
+ children: _
89
+ });
90
+ }, TagInputValue = (e) => {
91
+ let p = c(14), m, h;
92
+ p[0] === e ? (m = p[1], h = p[2]) : ({onKeyDown: m, ...h} = e, p[0] = e, p[1] = m, p[2] = h);
93
+ let { search: g, allowCustomValues: _, insertToken: v } = useTagInput(), x;
94
+ p[3] !== _ || p[4] !== v || p[5] !== g ? (x = () => {
95
+ _ && g && v(encodeToken(g));
96
+ }, p[3] = _, p[4] = v, p[5] = g, p[6] = x) : x = p[6];
97
+ let S = x, C;
98
+ p[7] !== _ || p[8] !== S || p[9] !== m ? (C = (e) => {
99
+ (e.key === "Enter" && !e.defaultPrevented || e.key === "," && _) && (e.preventDefault(), S()), m?.(e);
100
+ }, p[7] = _, p[8] = S, p[9] = m, p[10] = C) : C = p[10];
101
+ let w;
102
+ return p[11] !== h || p[12] !== C ? (w = /* @__PURE__ */ jsx(EditorInputValue, {
103
+ ...h,
104
+ onKeyDown: C
105
+ }), p[11] = h, p[12] = C, p[13] = w) : w = p[13], w;
106
+ }, TagInputTrigger = (e) => {
107
+ let p = c(2), m;
108
+ return p[0] === e ? m = p[1] : (m = /* @__PURE__ */ jsx(EditorInputTrigger, { ...e }), p[0] = e, p[1] = m), m;
124
109
  };
110
+ export { TagInput, TagInputMenu, TagInputMenuItem, TagInputSubMenu, TagInputTrigger, TagInputValue };
@@ -1,22 +1,25 @@
1
- import { jsx as e } from "react/jsx-runtime";
2
- import a from "react";
3
- import { Input as s } from "./Input.js";
4
- import { IconX as u } from "@tabler/icons-react";
5
- import { Button as p } from "../button/Button.js";
6
- import { clearInputElement as h } from "./Input.utils.js";
7
- const R = a.forwardRef((o, t) => {
8
- t = t || a.useRef(null);
9
- const {
10
- clearable: l = !1,
11
- right: c,
12
- ...m
13
- } = o, f = (r) => {
14
- h(t.current), o.onClear && o.onClear(r);
15
- }, n = [c];
16
- l && n.push(/* @__PURE__ */ e(p, { variant: "none", onClick: (r) => f(r), children: /* @__PURE__ */ e(u, { size: 13 }) }));
17
- const i = n.filter(Boolean);
18
- return /* @__PURE__ */ e(s, { right: i.length > 0 ? i : void 0, type: "textarea", ref: t, ...m });
1
+ import { Button } from "../button/Button.js";
2
+ import { Input } from "./Input.js";
3
+ import { clearInputElement } from "./Input.utils.js";
4
+ import React from "react";
5
+ import { jsx } from "react/jsx-runtime";
6
+ import { IconX } from "@tabler/icons-react";
7
+ const TextAreaInput = React.forwardRef((o, s) => {
8
+ s ||= React.useRef(null);
9
+ let { clearable: c = !1, right: l, ...u } = o, d = (e) => {
10
+ clearInputElement(s.current), o.onClear && o.onClear(e);
11
+ }, f = [l];
12
+ c && f.push(/* @__PURE__ */ jsx(Button, {
13
+ variant: "none",
14
+ onClick: (e) => d(e),
15
+ children: /* @__PURE__ */ jsx(IconX, { size: 13 })
16
+ }));
17
+ let p = f.filter(Boolean);
18
+ return /* @__PURE__ */ jsx(Input, {
19
+ right: p.length > 0 ? p : void 0,
20
+ type: "textarea",
21
+ ref: s,
22
+ ...u
23
+ });
19
24
  });
20
- export {
21
- R as TextAreaInput
22
- };
25
+ export { TextAreaInput };
@@ -1,23 +1,31 @@
1
- import { jsx as o } from "react/jsx-runtime";
2
- import l from "react";
3
- import { Input as s } from "./Input.js";
4
- import { IconX as u } from "@tabler/icons-react";
5
- import { Button as f } from "../button/Button.js";
6
- import { clearInputElement as d } from "./Input.utils.js";
7
- import { ButtonGroup as h } from "../button-group/ButtonGroup.js";
8
- const R = l.forwardRef((r, t) => {
9
- t = t || l.useRef(null);
10
- const {
11
- clearable: c = !1,
12
- right: a,
13
- ...m
14
- } = r, p = (e) => {
15
- d(t.current), r.onClear && r.onClear(e);
16
- }, n = [a];
17
- c && n.push(/* @__PURE__ */ o(f, { color: "secondary", tabIndex: -1, paddingSize: "xxs", onClick: (e) => p(e), children: /* @__PURE__ */ o(u, { size: 13 }) }));
18
- const i = n.filter(Boolean);
19
- return /* @__PURE__ */ o(s, { right: i.length > 0 ? /* @__PURE__ */ o(h, { color: "primary", children: i }) : void 0, type: "text", ref: t, ...m });
1
+ import { Button } from "../button/Button.js";
2
+ import { ButtonGroup } from "../button-group/ButtonGroup.js";
3
+ import { Input } from "./Input.js";
4
+ import { clearInputElement } from "./Input.utils.js";
5
+ import React from "react";
6
+ import { jsx } from "react/jsx-runtime";
7
+ import { IconX } from "@tabler/icons-react";
8
+ const TextInput = React.forwardRef((s, c) => {
9
+ c ||= React.useRef(null);
10
+ let { clearable: l = !1, right: u, ...d } = s, f = (e) => {
11
+ clearInputElement(c.current), s.onClear && s.onClear(e);
12
+ }, p = [u];
13
+ l && p.push(/* @__PURE__ */ jsx(Button, {
14
+ color: "secondary",
15
+ tabIndex: -1,
16
+ paddingSize: "xxs",
17
+ onClick: (e) => f(e),
18
+ children: /* @__PURE__ */ jsx(IconX, { size: 13 })
19
+ }));
20
+ let m = p.filter(Boolean);
21
+ return /* @__PURE__ */ jsx(Input, {
22
+ right: m.length > 0 ? /* @__PURE__ */ jsx(ButtonGroup, {
23
+ color: "primary",
24
+ children: m
25
+ }) : void 0,
26
+ type: "text",
27
+ ref: c,
28
+ ...d
29
+ });
20
30
  });
21
- export {
22
- R as TextInput
23
- };
31
+ export { TextInput };