@vuer-ai/vuer-uikit 0.0.2 → 0.0.4

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 (230) hide show
  1. package/README.md +80 -0
  2. package/dist/chunk-25GQKTNF.mjs +105 -0
  3. package/dist/chunk-277NQUJD.js +99 -0
  4. package/dist/chunk-3FR3WKI4.mjs +24 -0
  5. package/dist/chunk-3Q75Z2CT.mjs +76 -0
  6. package/dist/chunk-5BIQ3IN7.js +93 -0
  7. package/dist/chunk-5GPQ7U5B.mjs +50 -0
  8. package/dist/chunk-66JQXJEV.mjs +272 -0
  9. package/dist/chunk-6ILSFDR5.mjs +161 -0
  10. package/dist/chunk-6L4KPPOD.mjs +90 -0
  11. package/dist/chunk-75QDQ67T.js +56 -0
  12. package/dist/chunk-7A7VNE3J.mjs +31 -0
  13. package/dist/chunk-7SXCVFSA.mjs +200 -0
  14. package/dist/chunk-7V4ELMOH.js +52 -0
  15. package/dist/chunk-7WUQTWQX.js +303 -0
  16. package/dist/chunk-A2Z57NAA.js +202 -0
  17. package/dist/chunk-ATDHGFVI.mjs +82 -0
  18. package/dist/chunk-ATEHWT2R.mjs +78 -0
  19. package/dist/chunk-B5EMQBVL.js +93 -0
  20. package/dist/chunk-CLTLT5XW.js +27 -0
  21. package/dist/chunk-COFRS37Z.mjs +337 -0
  22. package/dist/chunk-CP7QYV4N.mjs +110 -0
  23. package/dist/chunk-CZSRIDXN.mjs +165 -0
  24. package/dist/chunk-D4C5V4EN.mjs +53 -0
  25. package/dist/chunk-DWIK2CUV.mjs +45 -0
  26. package/dist/chunk-ECWCQWV5.js +148 -0
  27. package/dist/chunk-ENZI5WM7.js +108 -0
  28. package/dist/chunk-FVT46HEE.js +21 -0
  29. package/dist/chunk-FXIL4NQZ.js +58 -0
  30. package/dist/chunk-FYS6YECN.js +33 -0
  31. package/dist/chunk-G7XNQVPB.js +187 -0
  32. package/dist/chunk-GSXXTAQ3.js +373 -0
  33. package/dist/chunk-HUQZOPYD.js +2 -0
  34. package/dist/chunk-HW6SLBO3.mjs +9 -0
  35. package/dist/chunk-IPKCIMU4.mjs +156 -0
  36. package/dist/chunk-J7PTSP4Q.mjs +19 -0
  37. package/dist/chunk-KJ42IGH6.js +2 -0
  38. package/dist/chunk-KO7BQ6RR.js +83 -0
  39. package/dist/chunk-KQHNQQUZ.js +103 -0
  40. package/dist/chunk-KVFK3YC7.js +187 -0
  41. package/dist/chunk-KYKEJFJT.js +110 -0
  42. package/dist/chunk-LD7Y34QT.js +79 -0
  43. package/dist/chunk-LVSI4HYF.mjs +409 -0
  44. package/dist/chunk-M3KBBKQR.mjs +15 -0
  45. package/dist/chunk-MASRZTZC.mjs +34 -0
  46. package/dist/chunk-NN7R5DNL.mjs +119 -0
  47. package/dist/chunk-OE56M4MX.js +93 -0
  48. package/dist/chunk-OTDY2E2A.js +163 -0
  49. package/dist/chunk-PKGNHHWG.mjs +60 -0
  50. package/dist/chunk-Q3APPCB2.mjs +91 -0
  51. package/dist/chunk-QOUX33X5.mjs +111 -0
  52. package/dist/chunk-QS7WS6DD.mjs +1 -0
  53. package/dist/chunk-QZASHJNJ.js +24 -0
  54. package/dist/chunk-R6XNT4PN.js +431 -0
  55. package/dist/chunk-RACVRWME.js +136 -0
  56. package/dist/chunk-S2F2GRDB.mjs +1 -0
  57. package/dist/chunk-SI56IQWH.js +102 -0
  58. package/dist/chunk-ST4P6AN6.js +2 -0
  59. package/dist/chunk-TOZYLDAL.mjs +72 -0
  60. package/dist/chunk-UFR656UY.mjs +87 -0
  61. package/dist/chunk-UWO6RBCE.js +11 -0
  62. package/dist/chunk-VGCVIHBR.mjs +1 -0
  63. package/dist/chunk-WOG6UIG5.mjs +71 -0
  64. package/dist/chunk-X2QENXCS.mjs +54 -0
  65. package/dist/chunk-XACRGXGF.js +75 -0
  66. package/dist/chunk-XPNUQSKQ.mjs +94 -0
  67. package/dist/chunk-YQORMF34.js +110 -0
  68. package/dist/chunk-Z37VNICQ.js +67 -0
  69. package/dist/chunk-ZJXBC33M.js +112 -0
  70. package/dist/highlight-cursor/cursor-context.d.mts +7 -0
  71. package/dist/highlight-cursor/cursor-context.d.ts +7 -0
  72. package/dist/highlight-cursor/cursor-context.js +14 -0
  73. package/dist/highlight-cursor/cursor-context.mjs +1 -0
  74. package/dist/highlight-cursor/cursor-provider.d.mts +7 -0
  75. package/dist/highlight-cursor/cursor-provider.d.ts +7 -0
  76. package/dist/highlight-cursor/cursor-provider.js +12 -0
  77. package/dist/highlight-cursor/cursor-provider.mjs +3 -0
  78. package/dist/highlight-cursor/enhanced-components.d.mts +20 -0
  79. package/dist/highlight-cursor/enhanced-components.d.ts +20 -0
  80. package/dist/highlight-cursor/enhanced-components.js +36 -0
  81. package/dist/highlight-cursor/enhanced-components.mjs +11 -0
  82. package/dist/highlight-cursor/index.d.mts +16 -0
  83. package/dist/highlight-cursor/index.d.ts +16 -0
  84. package/dist/highlight-cursor/index.js +50 -0
  85. package/dist/highlight-cursor/index.mjs +13 -0
  86. package/dist/highlight-cursor/tabs-cursor-context.d.mts +14 -0
  87. package/dist/highlight-cursor/tabs-cursor-context.d.ts +14 -0
  88. package/dist/highlight-cursor/tabs-cursor-context.js +14 -0
  89. package/dist/highlight-cursor/tabs-cursor-context.mjs +1 -0
  90. package/dist/highlight-cursor/types.d.mts +39 -0
  91. package/dist/highlight-cursor/types.d.ts +39 -0
  92. package/dist/highlight-cursor/types.js +2 -0
  93. package/dist/highlight-cursor/types.mjs +1 -0
  94. package/dist/highlight-cursor/with-cursor.d.mts +7 -0
  95. package/dist/highlight-cursor/with-cursor.d.ts +7 -0
  96. package/dist/highlight-cursor/with-cursor.js +11 -0
  97. package/dist/highlight-cursor/with-cursor.mjs +2 -0
  98. package/dist/index.css +314 -0
  99. package/dist/index.d.mts +51 -0
  100. package/dist/index.d.ts +51 -0
  101. package/dist/index.js +425 -6744
  102. package/dist/index.mjs +34 -0
  103. package/dist/styles/theme.css +191 -0
  104. package/dist/styles/theme.d.mts +2 -0
  105. package/dist/styles/theme.d.ts +2 -0
  106. package/dist/styles/toast.css +58 -0
  107. package/dist/styles/toast.d.mts +2 -0
  108. package/dist/styles/toast.d.ts +2 -0
  109. package/dist/styles/variables.css +188 -0
  110. package/dist/styles/variables.d.mts +2 -0
  111. package/dist/styles/variables.d.ts +2 -0
  112. package/dist/ui/avatar.d.mts +16 -0
  113. package/dist/ui/avatar.d.ts +16 -0
  114. package/dist/ui/avatar.js +23 -0
  115. package/dist/ui/avatar.mjs +2 -0
  116. package/dist/ui/badge.d.mts +14 -0
  117. package/dist/ui/badge.d.ts +14 -0
  118. package/dist/ui/badge.js +16 -0
  119. package/dist/ui/badge.mjs +3 -0
  120. package/dist/ui/button.d.mts +16 -0
  121. package/dist/ui/button.d.ts +16 -0
  122. package/dist/ui/button.js +12 -0
  123. package/dist/ui/button.mjs +3 -0
  124. package/dist/ui/card.d.mts +12 -0
  125. package/dist/ui/card.d.ts +12 -0
  126. package/dist/ui/card.js +36 -0
  127. package/dist/ui/card.mjs +3 -0
  128. package/dist/ui/checkbox.d.mts +11 -0
  129. package/dist/ui/checkbox.d.ts +11 -0
  130. package/dist/ui/checkbox.js +12 -0
  131. package/dist/ui/checkbox.mjs +3 -0
  132. package/dist/ui/collapsible.d.mts +9 -0
  133. package/dist/ui/collapsible.d.ts +9 -0
  134. package/dist/ui/collapsible.js +20 -0
  135. package/dist/ui/collapsible.mjs +3 -0
  136. package/dist/ui/dropdown.d.mts +28 -0
  137. package/dist/ui/dropdown.d.ts +28 -0
  138. package/dist/ui/dropdown.js +68 -0
  139. package/dist/ui/dropdown.mjs +3 -0
  140. package/dist/ui/index.d.mts +44 -0
  141. package/dist/ui/index.d.ts +44 -0
  142. package/dist/ui/index.js +398 -0
  143. package/dist/ui/index.mjs +29 -0
  144. package/dist/ui/input-numbers.d.mts +15 -0
  145. package/dist/ui/input-numbers.d.ts +15 -0
  146. package/dist/ui/input-numbers.js +13 -0
  147. package/dist/ui/input-numbers.mjs +4 -0
  148. package/dist/ui/input.d.mts +22 -0
  149. package/dist/ui/input.d.ts +22 -0
  150. package/dist/ui/input.js +16 -0
  151. package/dist/ui/input.mjs +3 -0
  152. package/dist/ui/layout.d.mts +12 -0
  153. package/dist/ui/layout.d.ts +12 -0
  154. package/dist/ui/layout.js +12 -0
  155. package/dist/ui/layout.mjs +3 -0
  156. package/dist/ui/modal.d.mts +28 -0
  157. package/dist/ui/modal.d.ts +28 -0
  158. package/dist/ui/modal.js +48 -0
  159. package/dist/ui/modal.mjs +3 -0
  160. package/dist/ui/popover.d.mts +10 -0
  161. package/dist/ui/popover.d.ts +10 -0
  162. package/dist/ui/popover.js +23 -0
  163. package/dist/ui/popover.mjs +2 -0
  164. package/dist/ui/radio-group.d.mts +8 -0
  165. package/dist/ui/radio-group.d.ts +8 -0
  166. package/dist/ui/radio-group.js +16 -0
  167. package/dist/ui/radio-group.mjs +3 -0
  168. package/dist/ui/select.d.mts +28 -0
  169. package/dist/{types/ui → ui}/select.d.ts +18 -14
  170. package/dist/ui/select.js +48 -0
  171. package/dist/ui/select.mjs +3 -0
  172. package/dist/ui/sheet.d.mts +16 -0
  173. package/dist/ui/sheet.d.ts +16 -0
  174. package/dist/ui/sheet.js +39 -0
  175. package/dist/ui/sheet.mjs +2 -0
  176. package/dist/ui/slider.d.mts +10 -0
  177. package/dist/ui/slider.d.ts +10 -0
  178. package/dist/ui/slider.js +12 -0
  179. package/dist/ui/slider.mjs +3 -0
  180. package/dist/ui/switch.d.mts +7 -0
  181. package/dist/ui/switch.d.ts +7 -0
  182. package/dist/ui/switch.js +12 -0
  183. package/dist/ui/switch.mjs +3 -0
  184. package/dist/ui/tabs.d.mts +16 -0
  185. package/dist/ui/tabs.d.ts +16 -0
  186. package/dist/ui/tabs.js +25 -0
  187. package/dist/ui/tabs.mjs +4 -0
  188. package/dist/ui/textarea.d.mts +16 -0
  189. package/dist/ui/textarea.d.ts +16 -0
  190. package/dist/ui/textarea.js +12 -0
  191. package/dist/ui/textarea.mjs +3 -0
  192. package/dist/ui/theme-context.d.mts +17 -0
  193. package/dist/{types/ui → ui}/theme-context.d.ts +5 -3
  194. package/dist/ui/theme-context.js +14 -0
  195. package/dist/ui/theme-context.mjs +1 -0
  196. package/dist/ui/toast.d.mts +7 -0
  197. package/dist/ui/toast.d.ts +7 -0
  198. package/dist/ui/toast.js +14 -0
  199. package/dist/ui/toast.mjs +1 -0
  200. package/dist/ui/toggle-group.d.mts +12 -0
  201. package/dist/ui/toggle-group.d.ts +12 -0
  202. package/dist/ui/toggle-group.js +17 -0
  203. package/dist/ui/toggle-group.mjs +4 -0
  204. package/dist/ui/toggle.d.mts +13 -0
  205. package/dist/ui/toggle.d.ts +13 -0
  206. package/dist/ui/toggle.js +16 -0
  207. package/dist/ui/toggle.mjs +3 -0
  208. package/dist/ui/tooltip.d.mts +10 -0
  209. package/dist/ui/tooltip.d.ts +10 -0
  210. package/dist/ui/tooltip.js +23 -0
  211. package/dist/ui/tooltip.mjs +2 -0
  212. package/dist/ui/tree-view.d.mts +27 -0
  213. package/dist/ui/tree-view.d.ts +27 -0
  214. package/dist/ui/tree-view.js +11 -0
  215. package/dist/ui/tree-view.mjs +2 -0
  216. package/dist/utils/cn.d.mts +5 -0
  217. package/dist/utils/cn.d.ts +5 -0
  218. package/dist/utils/cn.js +10 -0
  219. package/dist/utils/cn.mjs +1 -0
  220. package/dist/utils/index.d.mts +2 -0
  221. package/dist/utils/index.d.ts +2 -0
  222. package/dist/utils/index.js +11 -0
  223. package/dist/utils/index.mjs +2 -0
  224. package/package.json +49 -27
  225. package/dist/index.umd.js +0 -74
  226. package/dist/types/index.d.ts +0 -4
  227. package/dist/types/lib/utils.d.ts +0 -2
  228. package/dist/types/ui/button.d.ts +0 -13
  229. package/dist/types/ui/input.d.ts +0 -19
  230. package/dist/vuer-uikit.css +0 -1
@@ -0,0 +1,337 @@
1
+ import { cn } from './chunk-HW6SLBO3.mjs';
2
+ import * as DropdownMenuPrimitive from '@radix-ui/react-dropdown-menu';
3
+ import { CheckIcon, CircleIcon, ChevronRightIcon } from 'lucide-react';
4
+ import { jsx, jsxs } from 'react/jsx-runtime';
5
+
6
+ function DropdownMenu({ ...props }) {
7
+ return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Root, { "data-slot": "dropdown-menu", ...props });
8
+ }
9
+ function DropdownMenuPortal({ ...props }) {
10
+ return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Portal, { "data-slot": "dropdown-menu-portal", ...props });
11
+ }
12
+ function DropdownMenuTrigger({ ...props }) {
13
+ return /* @__PURE__ */ jsx(
14
+ DropdownMenuPrimitive.Trigger,
15
+ {
16
+ "data-slot": "dropdown-menu-trigger",
17
+ className: "text-text-primary hover:text-text-highlight disabled:text-text-tertiary active:text-text-secondary",
18
+ ...props
19
+ }
20
+ );
21
+ }
22
+ function DropdownMenuContent({
23
+ className,
24
+ sideOffset = 4,
25
+ ...props
26
+ }) {
27
+ return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Portal, { children: /* @__PURE__ */ jsx(
28
+ DropdownMenuPrimitive.Content,
29
+ {
30
+ "data-slot": "dropdown-menu-content",
31
+ sideOffset,
32
+ className: cn(
33
+ [
34
+ "bg-bg-primary",
35
+ "p-md",
36
+ "data-[state=open]:animate-in",
37
+ "data-[state=closed]:animate-out",
38
+ "data-[state=closed]:fade-out-0",
39
+ "data-[state=open]:fade-in-0",
40
+ "data-[state=closed]:zoom-out-95",
41
+ "data-[state=open]:zoom-in-95",
42
+ "data-[side=bottom]:slide-in-from-top-2",
43
+ "data-[side=left]:slide-in-from-right-2",
44
+ "data-[side=right]:slide-in-from-left-2",
45
+ "data-[side=top]:slide-in-from-bottom-2",
46
+ "relative",
47
+ "z-50",
48
+ "max-h-(--radix-dropdown-menu-content-available-height)",
49
+ "min-w-[8rem]",
50
+ "origin-(--radix-dropdown-menu-content-transform-origin)",
51
+ "overflow-x-hidden",
52
+ "overflow-y-auto",
53
+ "rounded-uk-md",
54
+ "shadow-md",
55
+ "shadow-[0_8px_20px_0_rgba(0,0,0,.80)]",
56
+ "liquid:liquid-bg"
57
+ ],
58
+ className
59
+ ),
60
+ ...props
61
+ }
62
+ ) });
63
+ }
64
+ function DropdownMenuGroup({
65
+ className,
66
+ ...props
67
+ }) {
68
+ return /* @__PURE__ */ jsx(
69
+ DropdownMenuPrimitive.Group,
70
+ {
71
+ "data-slot": "dropdown-menu-group",
72
+ className: cn("space-y-xs", className),
73
+ ...props
74
+ }
75
+ );
76
+ }
77
+ function DropdownMenuItem({
78
+ className,
79
+ inset,
80
+ variant = "default",
81
+ ...props
82
+ }) {
83
+ return /* @__PURE__ */ jsx(
84
+ DropdownMenuPrimitive.Item,
85
+ {
86
+ "data-slot": "dropdown-menu-item",
87
+ "data-inset": inset,
88
+ "data-variant": variant,
89
+ className: cn(
90
+ [
91
+ "w-full",
92
+ "flex",
93
+ "gap-md",
94
+ "items-center",
95
+ "pr-md",
96
+ "pl-[calc(var(--spacing-md)*2)]",
97
+ "py-xs",
98
+ "mb-xs",
99
+ "last:mb-0",
100
+ "relative",
101
+ "cursor-default",
102
+ "rounded-uk-xs",
103
+ "text-xs",
104
+ "outline-hidden",
105
+ "select-none",
106
+ "hover:bg-bg-tertiary",
107
+ "data-[disabled]:pointer-events-none",
108
+ "data-[disabled]:text-bg-quaternary",
109
+ "[&_svg]:pointer-events-none",
110
+ "[&_svg]:shrink-0",
111
+ "[&_svg:not([class*='size-'])]:size-4",
112
+ "[&_svg:not([class*='text-'])]:text-muted-foreground"
113
+ ],
114
+ className
115
+ ),
116
+ ...props
117
+ }
118
+ );
119
+ }
120
+ function DropdownMenuCheckboxItem({
121
+ className,
122
+ children,
123
+ checked,
124
+ ...props
125
+ }) {
126
+ return /* @__PURE__ */ jsxs(
127
+ DropdownMenuPrimitive.CheckboxItem,
128
+ {
129
+ "data-slot": "dropdown-menu-checkbox-item",
130
+ className: cn(
131
+ [
132
+ "w-full",
133
+ "flex",
134
+ "gap-md",
135
+ "items-center",
136
+ "pr-md",
137
+ "pl-[calc(var(--spacing-xl)*1.8)]",
138
+ "py-xs",
139
+ "mb-xs",
140
+ "last:mb-0",
141
+ "relative",
142
+ "cursor-default",
143
+ "rounded-uk-xs",
144
+ "text-xs",
145
+ "outline-hidden",
146
+ "select-none",
147
+ "hover:bg-bg-tertiary",
148
+ "data-[disabled]:pointer-events-none",
149
+ "data-[disabled]:text-bg-quaternary",
150
+ "[&_svg:not([class*='size-'])]:size-4",
151
+ "[&_svg]:pointer-events-none",
152
+ "[&_svg]:shrink-0"
153
+ ],
154
+ className
155
+ ),
156
+ checked,
157
+ ...props,
158
+ children: [
159
+ /* @__PURE__ */ jsx("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(CheckIcon, { className: "size-4" }) }) }),
160
+ children
161
+ ]
162
+ }
163
+ );
164
+ }
165
+ function DropdownMenuRadioGroup({
166
+ ...props
167
+ }) {
168
+ return /* @__PURE__ */ jsx(DropdownMenuPrimitive.RadioGroup, { "data-slot": "dropdown-menu-radio-group", ...props });
169
+ }
170
+ function DropdownMenuRadioItem({
171
+ className,
172
+ children,
173
+ ...props
174
+ }) {
175
+ return /* @__PURE__ */ jsxs(
176
+ DropdownMenuPrimitive.RadioItem,
177
+ {
178
+ "data-slot": "dropdown-menu-radio-item",
179
+ className: cn(
180
+ [
181
+ "w-full",
182
+ "hover:bg-bg-tertiary",
183
+ "outline-hidden",
184
+ "relative",
185
+ "flex",
186
+ "cursor-default",
187
+ "select-none",
188
+ "items-center",
189
+ "gap-md",
190
+ "rounded-uk-xs",
191
+ "py-xs",
192
+ "pl-[calc(var(--spacing-xl)*1.8)]",
193
+ "pr-md",
194
+ "mb-xs",
195
+ "last:mb-0",
196
+ "text-xs",
197
+ "data-[disabled]:pointer-events-none",
198
+ "data-[disabled]:text-bg-quaternary",
199
+ "[&_svg:not([class*='size-'])]:size-4",
200
+ "[&_svg]:pointer-events-none",
201
+ "[&_svg]:shrink-0"
202
+ ],
203
+ className
204
+ ),
205
+ ...props,
206
+ children: [
207
+ /* @__PURE__ */ jsx("span", { className: "pointer-events-none absolute left-2 flex size-3.5 items-center justify-center", children: /* @__PURE__ */ jsx(DropdownMenuPrimitive.ItemIndicator, { children: /* @__PURE__ */ jsx(CircleIcon, { className: "size-2 fill-current" }) }) }),
208
+ children
209
+ ]
210
+ }
211
+ );
212
+ }
213
+ function DropdownMenuLabel({
214
+ className,
215
+ inset,
216
+ ...props
217
+ }) {
218
+ return /* @__PURE__ */ jsx(
219
+ DropdownMenuPrimitive.Label,
220
+ {
221
+ "data-slot": "dropdown-menu-label",
222
+ "data-inset": inset,
223
+ className: cn("text-text-secondary px-2 py-1.5 text-xs", className),
224
+ ...props
225
+ }
226
+ );
227
+ }
228
+ function DropdownMenuSeparator({
229
+ className,
230
+ ...props
231
+ }) {
232
+ return /* @__PURE__ */ jsx(
233
+ DropdownMenuPrimitive.Separator,
234
+ {
235
+ "data-slot": "dropdown-menu-separator",
236
+ className: cn("bg-line-primary my-lg pointer-events-none -mx-1 h-px", className),
237
+ ...props
238
+ }
239
+ );
240
+ }
241
+ function DropdownMenuShortcut({ className, ...props }) {
242
+ return /* @__PURE__ */ jsx(
243
+ "span",
244
+ {
245
+ "data-slot": "dropdown-menu-shortcut",
246
+ className: cn("text-text-tertiary ml-auto text-xs", className),
247
+ ...props
248
+ }
249
+ );
250
+ }
251
+ function DropdownMenuSub({ ...props }) {
252
+ return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Sub, { "data-slot": "dropdown-menu-sub", ...props });
253
+ }
254
+ function DropdownMenuSubTrigger({
255
+ className,
256
+ inset,
257
+ children,
258
+ ...props
259
+ }) {
260
+ return /* @__PURE__ */ jsxs(
261
+ DropdownMenuPrimitive.SubTrigger,
262
+ {
263
+ "data-slot": "dropdown-menu-sub-trigger",
264
+ "data-inset": inset,
265
+ className: cn(
266
+ "w-full",
267
+ "flex",
268
+ "gap-md",
269
+ "items-center",
270
+ "pr-md",
271
+ "pl-[calc(var(--spacing-md)*2)]",
272
+ "py-xs",
273
+ "mb-xs",
274
+ "relative",
275
+ "cursor-default",
276
+ "rounded-uk-xs",
277
+ "text-xs",
278
+ "outline-hidden",
279
+ "select-none",
280
+ "hover:bg-bg-tertiary",
281
+ "data-[state=open]:bg-bg-tertiary",
282
+ "data-[disabled]:pointer-events-none",
283
+ "data-[disabled]:text-bg-quaternary",
284
+ "[&_svg]:pointer-events-none",
285
+ "[&_svg]:shrink-0",
286
+ "[&_svg:not([class*='size-'])]:size-4",
287
+ "[&_svg:not([class*='text-'])]:text-muted-foreground",
288
+ className
289
+ ),
290
+ ...props,
291
+ children: [
292
+ children,
293
+ /* @__PURE__ */ jsx(ChevronRightIcon, { className: "ml-auto size-4" })
294
+ ]
295
+ }
296
+ );
297
+ }
298
+ function DropdownMenuSubContent({
299
+ className,
300
+ ...props
301
+ }) {
302
+ return /* @__PURE__ */ jsx(
303
+ DropdownMenuPrimitive.SubContent,
304
+ {
305
+ "data-slot": "dropdown-menu-sub-content",
306
+ className: cn(
307
+ "bg-bg-primary",
308
+ "p-md",
309
+ "data-[state=open]:animate-in",
310
+ "data-[state=closed]:animate-out",
311
+ "data-[state=closed]:fade-out-0",
312
+ "data-[state=open]:fade-in-0",
313
+ "data-[state=closed]:zoom-out-95",
314
+ "data-[state=open]:zoom-in-95",
315
+ "data-[side=bottom]:slide-in-from-top-2",
316
+ "data-[side=left]:slide-in-from-right-2",
317
+ "data-[side=right]:slide-in-from-left-2",
318
+ "data-[side=top]:slide-in-from-bottom-2",
319
+ "relative",
320
+ "z-50",
321
+ "max-h-(--radix-dropdown-menu-content-available-height)",
322
+ "min-w-[8rem]",
323
+ "origin-(--radix-dropdown-menu-content-transform-origin)",
324
+ "overflow-x-hidden",
325
+ "overflow-y-auto",
326
+ "rounded-uk-md",
327
+ "shadow-md",
328
+ "shadow-[0_8px_20px_0_rgba(0,0,0,.80)]",
329
+ "liquid:liquid-bg",
330
+ className
331
+ ),
332
+ ...props
333
+ }
334
+ );
335
+ }
336
+
337
+ export { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger };
@@ -0,0 +1,110 @@
1
+ import { useCursor } from './chunk-3FR3WKI4.mjs';
2
+ import { forwardRef, useId, useRef } from 'react';
3
+ import { jsx } from 'react/jsx-runtime';
4
+
5
+ var getVisibleRect = (element, elementRect) => {
6
+ let parent = element.parentElement;
7
+ let visibleRect = {
8
+ ...elementRect,
9
+ left: elementRect.left,
10
+ right: elementRect.right,
11
+ top: elementRect.top,
12
+ bottom: elementRect.bottom,
13
+ width: elementRect.width,
14
+ height: elementRect.height,
15
+ x: elementRect.x,
16
+ y: elementRect.y
17
+ };
18
+ while (parent) {
19
+ const style = window.getComputedStyle(parent);
20
+ const hasOverflow = [style.overflowY, style.overflowX].some(
21
+ (overflow) => ["auto", "scroll", "hidden"].includes(overflow)
22
+ );
23
+ if (hasOverflow) {
24
+ const parentRect = parent.getBoundingClientRect();
25
+ const newLeft = Math.max(visibleRect.left, parentRect.left);
26
+ const newTop = Math.max(visibleRect.top, parentRect.top);
27
+ const newRight = Math.min(visibleRect.right, parentRect.right);
28
+ const newBottom = Math.min(visibleRect.bottom, parentRect.bottom);
29
+ visibleRect = {
30
+ ...visibleRect,
31
+ left: newLeft,
32
+ top: newTop,
33
+ right: newRight,
34
+ bottom: newBottom,
35
+ width: Math.max(0, newRight - newLeft),
36
+ height: Math.max(0, newBottom - newTop),
37
+ x: newLeft,
38
+ y: newTop
39
+ };
40
+ if (visibleRect.width <= 0 || visibleRect.height <= 0) {
41
+ return new DOMRect(0, 0, 0, 0);
42
+ }
43
+ }
44
+ parent = parent.parentElement;
45
+ }
46
+ return DOMRect.fromRect(visibleRect);
47
+ };
48
+ function withCursor(Component) {
49
+ const displayName = Component.displayName || Component.name || "Component";
50
+ const EnhancedComponent = forwardRef(
51
+ ({ id: propId, onMouseEnter, onMouseMove, onMouseLeave, ...props }, ref) => {
52
+ const { registerHoveredElement, unregisterHoveredElement, updateElementDimensions } = useCursor();
53
+ const generatedId = useId();
54
+ const id = propId || `cursor-element-${generatedId}`;
55
+ const elementRef = useRef(null);
56
+ const handleMouseEnter = (event) => {
57
+ if (elementRef.current) {
58
+ const elementRect = elementRef.current.getBoundingClientRect();
59
+ const visibleRect = getVisibleRect(elementRef.current, elementRect);
60
+ registerHoveredElement(id, visibleRect, elementRef.current);
61
+ }
62
+ onMouseEnter == null ? void 0 : onMouseEnter(event);
63
+ };
64
+ const handleMouseMove = (event) => {
65
+ if (elementRef.current) {
66
+ const elementRect = elementRef.current.getBoundingClientRect();
67
+ const visibleRect = getVisibleRect(elementRef.current, elementRect);
68
+ updateElementDimensions(visibleRect);
69
+ }
70
+ onMouseMove == null ? void 0 : onMouseMove(event);
71
+ };
72
+ const handleMouseOut = (event) => {
73
+ var _a;
74
+ const rect = (_a = elementRef.current) == null ? void 0 : _a.getBoundingClientRect();
75
+ if (rect) {
76
+ const { clientX, clientY } = event;
77
+ const isOutside = clientX < rect.left || clientX > rect.right || clientY < rect.top || clientY > rect.bottom;
78
+ if (isOutside) {
79
+ unregisterHoveredElement();
80
+ }
81
+ } else {
82
+ unregisterHoveredElement();
83
+ }
84
+ onMouseLeave == null ? void 0 : onMouseLeave(event);
85
+ };
86
+ return /* @__PURE__ */ jsx(
87
+ Component,
88
+ {
89
+ ...props,
90
+ id,
91
+ ref: (node) => {
92
+ if (typeof ref === "function") {
93
+ ref(node);
94
+ } else if (ref) {
95
+ ref.current = node;
96
+ }
97
+ elementRef.current = node;
98
+ },
99
+ onMouseEnter: handleMouseEnter,
100
+ onMouseMove: handleMouseMove,
101
+ onMouseOut: handleMouseOut
102
+ }
103
+ );
104
+ }
105
+ );
106
+ EnhancedComponent.displayName = `withCursor(${displayName})`;
107
+ return EnhancedComponent;
108
+ }
109
+
110
+ export { withCursor };
@@ -0,0 +1,165 @@
1
+ import { cn } from './chunk-HW6SLBO3.mjs';
2
+ import * as SliderPrimitive from '@radix-ui/react-slider';
3
+ import { forwardRef, useState, useMemo } from 'react';
4
+ import { jsxs, jsx } from 'react/jsx-runtime';
5
+
6
+ var Slider = forwardRef(function Slider2({
7
+ className,
8
+ defaultValue,
9
+ value,
10
+ onValueChange,
11
+ showStep = false,
12
+ step = 1,
13
+ min = 0,
14
+ max = 100,
15
+ ...props
16
+ }, ref) {
17
+ const [currentValue, setCurrentValue] = useState(value ?? defaultValue ?? [0]);
18
+ const _values = useMemo(
19
+ () => Array.isArray(value) ? value : Array.isArray(defaultValue) ? defaultValue : [min, max],
20
+ [value, defaultValue, min, max]
21
+ );
22
+ return /* @__PURE__ */ jsxs(
23
+ SliderPrimitive.Root,
24
+ {
25
+ "data-slot": "slider",
26
+ value,
27
+ defaultValue,
28
+ onValueChange: (v) => {
29
+ onValueChange == null ? void 0 : onValueChange(v);
30
+ setCurrentValue(v);
31
+ },
32
+ ref,
33
+ min,
34
+ max,
35
+ step,
36
+ className: cn(
37
+ "relative",
38
+ "flex",
39
+ "w-full",
40
+ "touch-none",
41
+ "select-none",
42
+ "items-center",
43
+ "data-[orientation=vertical]:h-full",
44
+ "data-[orientation=vertical]:min-h-44",
45
+ "data-[orientation=vertical]:w-auto",
46
+ "data-[orientation=vertical]:flex-col",
47
+ className
48
+ ),
49
+ ...props,
50
+ children: [
51
+ /* @__PURE__ */ jsx(
52
+ SliderPrimitive.Track,
53
+ {
54
+ "data-slot": "slider-track",
55
+ className: cn(
56
+ "peer/slider-track",
57
+ "bg-line-primary",
58
+ "relative",
59
+ "grow",
60
+ "overflow-hidden",
61
+ "rounded-full",
62
+ "data-[disabled]:bg-bg-secondary",
63
+ "data-[orientation=vertical]:w-0.5",
64
+ "data-[orientation=vertical]:h-full",
65
+ "data-[orientation=horizontal]:h-0.5",
66
+ "data-[orientation=horizontal]:w-full"
67
+ ),
68
+ children: /* @__PURE__ */ jsx(
69
+ SliderPrimitive.Range,
70
+ {
71
+ "data-slot": "slider-range",
72
+ className: cn(
73
+ "bg-brand-primary",
74
+ "absolute",
75
+ "data-[disabled]:bg-bg-secondary",
76
+ "data-[orientation=vertical]:w-full",
77
+ "data-[orientation=horizontal]:h-full"
78
+ )
79
+ }
80
+ )
81
+ }
82
+ ),
83
+ showStep && /* @__PURE__ */ jsx(SliderSteps, { currentValue, max, min, step }),
84
+ Array.from({ length: _values.length }, (_, index) => /* @__PURE__ */ jsx(
85
+ SliderPrimitive.Thumb,
86
+ {
87
+ "data-slot": "slider-thumb",
88
+ className: cn(
89
+ "ring-brand-primary/50",
90
+ "bg-brand-primary",
91
+ "block",
92
+ "h-4",
93
+ "w-[0.6rem]",
94
+ "shrink-0",
95
+ "rounded-[3px]",
96
+ "transition-[color,box-shadow]",
97
+ "hover:ring-4",
98
+ "hover:cursor-ew-resize",
99
+ "focus-visible:ring-4",
100
+ "focus-visible:outline-hidden",
101
+ "data-[disabled]:bg-bg-tertiary",
102
+ "data-[disabled]:pointer-events-none"
103
+ )
104
+ },
105
+ index
106
+ ))
107
+ ]
108
+ }
109
+ );
110
+ });
111
+ function SliderSteps({ step, min, max, currentValue }) {
112
+ const steps = useMemo(() => {
113
+ const value = max - min;
114
+ const stepCount = Math.ceil(value / step);
115
+ return Array.from({ length: stepCount + 1 }, (_, i) => {
116
+ return { position: Math.min(100 / value * (i * step), 100), v: i * step + min };
117
+ });
118
+ }, [max, min, step]);
119
+ const [minRange, maxRange] = useMemo(() => {
120
+ if (currentValue.length > 1) {
121
+ return [Math.min(...currentValue), Math.max(...currentValue)];
122
+ } else {
123
+ return [0, ...currentValue];
124
+ }
125
+ }, [currentValue]);
126
+ return steps.map((step2, i) => {
127
+ const thumbInBoundsOffset = getThumbInBoundsOffset(9.6, step2.position, 1);
128
+ return /* @__PURE__ */ jsx(
129
+ "span",
130
+ {
131
+ "data-slot": "slider-step",
132
+ style: { left: `calc(${step2.position}% + ${thumbInBoundsOffset}px)` },
133
+ className: cn(
134
+ "absolute",
135
+ "top-1/2",
136
+ "translate-y-[-50%]",
137
+ "translate-x-[-50%]",
138
+ "bg-brand-primary",
139
+ "block",
140
+ "h-[5pt]",
141
+ "w-[1pt]",
142
+ "shrink-0",
143
+ "rounded-[1px]",
144
+ "peer-has-data-[disabled]/slider-track:bg-bg-tertiary",
145
+ { "bg-bg-tertiary": step2.v < minRange || step2.v > maxRange }
146
+ )
147
+ },
148
+ i
149
+ );
150
+ });
151
+ }
152
+ function getThumbInBoundsOffset(width, left, direction) {
153
+ const halfWidth = width / 2;
154
+ const halfPercent = 50;
155
+ const offset = linearScale([0, halfPercent], [0, halfWidth]);
156
+ return (halfWidth - offset(left) * direction) * direction;
157
+ }
158
+ function linearScale(input, output) {
159
+ return (value) => {
160
+ const ratio = (output[1] - output[0]) / (input[1] - input[0]);
161
+ return output[0] + ratio * (value - input[0]);
162
+ };
163
+ }
164
+
165
+ export { Slider };
@@ -0,0 +1,53 @@
1
+ import { createContext, useState, useEffect, useMemo, useContext } from 'react';
2
+ import { jsx } from 'react/jsx-runtime';
3
+
4
+ // src/ui/theme-context.tsx
5
+ var initialState = {
6
+ theme: "system",
7
+ setTheme: () => null
8
+ };
9
+ var ThemeProviderContext = createContext(initialState);
10
+ function ThemeProvider({
11
+ children,
12
+ defaultTheme = "system",
13
+ storageKey = "vuer-theme",
14
+ ...props
15
+ }) {
16
+ const [theme, setTheme] = useState(() => {
17
+ return localStorage.getItem(storageKey) || defaultTheme;
18
+ });
19
+ useEffect(() => {
20
+ const root = window.document.documentElement;
21
+ root.classList.remove("light", "dark", "liquidlight", "liquiddark", "system");
22
+ if (theme === "system") {
23
+ const systemTheme = window.matchMedia("(prefers-color-scheme: dark)").matches ? "dark" : "light";
24
+ root.classList.add(systemTheme);
25
+ return;
26
+ }
27
+ root.classList.add(theme);
28
+ }, [theme]);
29
+ return /* @__PURE__ */ jsx(
30
+ ThemeProviderContext.Provider,
31
+ {
32
+ ...props,
33
+ value: useMemo(
34
+ () => ({
35
+ theme,
36
+ setTheme: (theme2) => {
37
+ localStorage.setItem(storageKey, theme2);
38
+ setTheme(theme2);
39
+ }
40
+ }),
41
+ [storageKey, theme]
42
+ ),
43
+ children
44
+ }
45
+ );
46
+ }
47
+ var useTheme = () => {
48
+ const context = useContext(ThemeProviderContext);
49
+ if (context === void 0) throw new Error("useTheme must be used within a ThemeProvider");
50
+ return context;
51
+ };
52
+
53
+ export { ThemeProvider, useTheme };