@vuer-ai/vuer-uikit 0.0.2 → 0.0.3

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 (212) hide show
  1. package/README.md +80 -0
  2. package/dist/chunk-263CMARJ.mjs +155 -0
  3. package/dist/chunk-277NQUJD.js +99 -0
  4. package/dist/chunk-3FR3WKI4.mjs +24 -0
  5. package/dist/chunk-3HXPIWL3.js +51 -0
  6. package/dist/chunk-3Q75Z2CT.mjs +76 -0
  7. package/dist/chunk-5BIQ3IN7.js +93 -0
  8. package/dist/chunk-5JP4AZ4C.js +302 -0
  9. package/dist/chunk-5U4NWZMT.mjs +78 -0
  10. package/dist/chunk-75QDQ67T.js +56 -0
  11. package/dist/chunk-7IYL2AR4.js +375 -0
  12. package/dist/chunk-ATDHGFVI.mjs +82 -0
  13. package/dist/chunk-CFXL2XYO.mjs +339 -0
  14. package/dist/chunk-CLTLT5XW.js +27 -0
  15. package/dist/chunk-CN6ISLZA.js +102 -0
  16. package/dist/chunk-CP7QYV4N.mjs +110 -0
  17. package/dist/chunk-CZSRIDXN.mjs +165 -0
  18. package/dist/chunk-D4C5V4EN.mjs +53 -0
  19. package/dist/chunk-DQGTWUID.js +186 -0
  20. package/dist/chunk-DWIK2CUV.mjs +45 -0
  21. package/dist/chunk-FXIL4NQZ.js +58 -0
  22. package/dist/chunk-FYEZTS4S.mjs +90 -0
  23. package/dist/chunk-GA2JCN3F.mjs +111 -0
  24. package/dist/chunk-HW6SLBO3.mjs +9 -0
  25. package/dist/chunk-I6VKLSAJ.js +163 -0
  26. package/dist/chunk-J4RFFBDJ.mjs +94 -0
  27. package/dist/chunk-JIXJTLEO.js +93 -0
  28. package/dist/chunk-JOBQTBEM.mjs +49 -0
  29. package/dist/chunk-JZ7V43ZL.js +136 -0
  30. package/dist/chunk-KAPV3EZO.mjs +271 -0
  31. package/dist/chunk-KJ42IGH6.js +2 -0
  32. package/dist/chunk-KO7BQ6RR.js +83 -0
  33. package/dist/chunk-KVDEBKWR.mjs +106 -0
  34. package/dist/chunk-KVFK3YC7.js +187 -0
  35. package/dist/chunk-KYKEJFJT.js +110 -0
  36. package/dist/chunk-LBFO3QAA.js +202 -0
  37. package/dist/chunk-MASRZTZC.mjs +34 -0
  38. package/dist/chunk-NA7TVYOP.js +21 -0
  39. package/dist/chunk-OE56M4MX.js +93 -0
  40. package/dist/chunk-PKGNHHWG.mjs +60 -0
  41. package/dist/chunk-Q3APPCB2.mjs +91 -0
  42. package/dist/chunk-QNTUEKYQ.mjs +19 -0
  43. package/dist/chunk-QS7WS6DD.mjs +1 -0
  44. package/dist/chunk-RPXWKB6F.js +103 -0
  45. package/dist/chunk-SDN2OTHS.js +78 -0
  46. package/dist/chunk-SKWTWHB7.mjs +53 -0
  47. package/dist/chunk-ST4P6AN6.js +2 -0
  48. package/dist/chunk-SUU4Z6E5.mjs +200 -0
  49. package/dist/chunk-SZU2TX5H.js +24 -0
  50. package/dist/chunk-TOZYLDAL.mjs +72 -0
  51. package/dist/chunk-UFR656UY.mjs +87 -0
  52. package/dist/chunk-UWO6RBCE.js +11 -0
  53. package/dist/chunk-VGCVIHBR.mjs +1 -0
  54. package/dist/chunk-WI2J7NIV.mjs +161 -0
  55. package/dist/chunk-WK3M4X72.js +2 -0
  56. package/dist/chunk-WOG6UIG5.mjs +71 -0
  57. package/dist/chunk-XACRGXGF.js +75 -0
  58. package/dist/chunk-YQORMF34.js +110 -0
  59. package/dist/chunk-Z37VNICQ.js +67 -0
  60. package/dist/chunk-ZCYBA6YN.mjs +1 -0
  61. package/dist/chunk-ZJXBC33M.js +112 -0
  62. package/dist/chunk-ZKYQYCKN.mjs +15 -0
  63. package/dist/chunk-ZYBSCTBR.js +109 -0
  64. package/dist/highlight-cursor/cursor-context.d.mts +7 -0
  65. package/dist/highlight-cursor/cursor-context.d.ts +7 -0
  66. package/dist/highlight-cursor/cursor-context.js +14 -0
  67. package/dist/highlight-cursor/cursor-context.mjs +1 -0
  68. package/dist/highlight-cursor/cursor-provider.d.mts +7 -0
  69. package/dist/highlight-cursor/cursor-provider.d.ts +7 -0
  70. package/dist/highlight-cursor/cursor-provider.js +12 -0
  71. package/dist/highlight-cursor/cursor-provider.mjs +3 -0
  72. package/dist/highlight-cursor/enhanced-components.d.mts +20 -0
  73. package/dist/highlight-cursor/enhanced-components.d.ts +20 -0
  74. package/dist/highlight-cursor/enhanced-components.js +36 -0
  75. package/dist/highlight-cursor/enhanced-components.mjs +11 -0
  76. package/dist/highlight-cursor/index.d.mts +16 -0
  77. package/dist/highlight-cursor/index.d.ts +16 -0
  78. package/dist/highlight-cursor/index.js +50 -0
  79. package/dist/highlight-cursor/index.mjs +13 -0
  80. package/dist/highlight-cursor/tabs-cursor-context.d.mts +14 -0
  81. package/dist/highlight-cursor/tabs-cursor-context.d.ts +14 -0
  82. package/dist/highlight-cursor/tabs-cursor-context.js +14 -0
  83. package/dist/highlight-cursor/tabs-cursor-context.mjs +1 -0
  84. package/dist/highlight-cursor/types.d.mts +39 -0
  85. package/dist/highlight-cursor/types.d.ts +39 -0
  86. package/dist/highlight-cursor/types.js +2 -0
  87. package/dist/highlight-cursor/types.mjs +1 -0
  88. package/dist/highlight-cursor/with-cursor.d.mts +7 -0
  89. package/dist/highlight-cursor/with-cursor.d.ts +7 -0
  90. package/dist/highlight-cursor/with-cursor.js +11 -0
  91. package/dist/highlight-cursor/with-cursor.mjs +2 -0
  92. package/dist/index.css +294 -0
  93. package/dist/index.d.mts +48 -0
  94. package/dist/index.d.ts +48 -0
  95. package/dist/index.js +382 -6744
  96. package/dist/index.mjs +31 -0
  97. package/dist/styles/theme.css +185 -0
  98. package/dist/styles/theme.d.mts +2 -0
  99. package/dist/styles/theme.d.ts +2 -0
  100. package/dist/styles/toast.css +44 -0
  101. package/dist/styles/toast.d.mts +2 -0
  102. package/dist/styles/toast.d.ts +2 -0
  103. package/dist/styles/variables.css +184 -0
  104. package/dist/styles/variables.d.mts +2 -0
  105. package/dist/styles/variables.d.ts +2 -0
  106. package/dist/ui/avatar.d.mts +16 -0
  107. package/dist/ui/avatar.d.ts +16 -0
  108. package/dist/ui/avatar.js +23 -0
  109. package/dist/ui/avatar.mjs +2 -0
  110. package/dist/ui/badge.d.mts +14 -0
  111. package/dist/ui/badge.d.ts +14 -0
  112. package/dist/ui/badge.js +16 -0
  113. package/dist/ui/badge.mjs +3 -0
  114. package/dist/ui/button.d.mts +16 -0
  115. package/dist/ui/button.d.ts +16 -0
  116. package/dist/ui/button.js +12 -0
  117. package/dist/ui/button.mjs +3 -0
  118. package/dist/ui/card.d.mts +12 -0
  119. package/dist/ui/card.d.ts +12 -0
  120. package/dist/ui/card.js +36 -0
  121. package/dist/ui/card.mjs +3 -0
  122. package/dist/ui/checkbox.d.mts +11 -0
  123. package/dist/ui/checkbox.d.ts +11 -0
  124. package/dist/ui/checkbox.js +12 -0
  125. package/dist/ui/checkbox.mjs +3 -0
  126. package/dist/ui/collapsible.d.mts +9 -0
  127. package/dist/ui/collapsible.d.ts +9 -0
  128. package/dist/ui/collapsible.js +20 -0
  129. package/dist/ui/collapsible.mjs +3 -0
  130. package/dist/ui/dropdown.d.mts +28 -0
  131. package/dist/ui/dropdown.d.ts +28 -0
  132. package/dist/ui/dropdown.js +68 -0
  133. package/dist/ui/dropdown.mjs +3 -0
  134. package/dist/ui/index.d.mts +41 -0
  135. package/dist/ui/index.d.ts +41 -0
  136. package/dist/ui/index.js +355 -0
  137. package/dist/ui/index.mjs +26 -0
  138. package/dist/ui/input-numbers.d.mts +15 -0
  139. package/dist/ui/input-numbers.d.ts +15 -0
  140. package/dist/ui/input-numbers.js +13 -0
  141. package/dist/ui/input-numbers.mjs +4 -0
  142. package/dist/ui/input.d.mts +22 -0
  143. package/dist/ui/input.d.ts +22 -0
  144. package/dist/ui/input.js +16 -0
  145. package/dist/ui/input.mjs +3 -0
  146. package/dist/ui/modal.d.mts +28 -0
  147. package/dist/ui/modal.d.ts +28 -0
  148. package/dist/ui/modal.js +48 -0
  149. package/dist/ui/modal.mjs +3 -0
  150. package/dist/ui/popover.d.mts +10 -0
  151. package/dist/ui/popover.d.ts +10 -0
  152. package/dist/ui/popover.js +23 -0
  153. package/dist/ui/popover.mjs +2 -0
  154. package/dist/ui/radio-group.d.mts +8 -0
  155. package/dist/ui/radio-group.d.ts +8 -0
  156. package/dist/ui/radio-group.js +16 -0
  157. package/dist/ui/radio-group.mjs +3 -0
  158. package/dist/ui/select.d.mts +28 -0
  159. package/dist/{types/ui → ui}/select.d.ts +18 -14
  160. package/dist/ui/select.js +48 -0
  161. package/dist/ui/select.mjs +3 -0
  162. package/dist/ui/slider.d.mts +10 -0
  163. package/dist/ui/slider.d.ts +10 -0
  164. package/dist/ui/slider.js +12 -0
  165. package/dist/ui/slider.mjs +3 -0
  166. package/dist/ui/switch.d.mts +7 -0
  167. package/dist/ui/switch.d.ts +7 -0
  168. package/dist/ui/switch.js +12 -0
  169. package/dist/ui/switch.mjs +3 -0
  170. package/dist/ui/tabs.d.mts +16 -0
  171. package/dist/ui/tabs.d.ts +16 -0
  172. package/dist/ui/tabs.js +25 -0
  173. package/dist/ui/tabs.mjs +4 -0
  174. package/dist/ui/textarea.d.mts +16 -0
  175. package/dist/ui/textarea.d.ts +16 -0
  176. package/dist/ui/textarea.js +12 -0
  177. package/dist/ui/textarea.mjs +3 -0
  178. package/dist/ui/theme-context.d.mts +17 -0
  179. package/dist/{types/ui → ui}/theme-context.d.ts +5 -3
  180. package/dist/ui/theme-context.js +14 -0
  181. package/dist/ui/theme-context.mjs +1 -0
  182. package/dist/ui/toast.d.mts +7 -0
  183. package/dist/ui/toast.d.ts +7 -0
  184. package/dist/ui/toast.js +14 -0
  185. package/dist/ui/toast.mjs +1 -0
  186. package/dist/ui/toggle-group.d.mts +12 -0
  187. package/dist/ui/toggle-group.d.ts +12 -0
  188. package/dist/ui/toggle-group.js +17 -0
  189. package/dist/ui/toggle-group.mjs +4 -0
  190. package/dist/ui/toggle.d.mts +13 -0
  191. package/dist/ui/toggle.d.ts +13 -0
  192. package/dist/ui/toggle.js +16 -0
  193. package/dist/ui/toggle.mjs +3 -0
  194. package/dist/ui/tooltip.d.mts +10 -0
  195. package/dist/ui/tooltip.d.ts +10 -0
  196. package/dist/ui/tooltip.js +23 -0
  197. package/dist/ui/tooltip.mjs +2 -0
  198. package/dist/utils/cn.d.mts +5 -0
  199. package/dist/utils/cn.d.ts +5 -0
  200. package/dist/utils/cn.js +10 -0
  201. package/dist/utils/cn.mjs +1 -0
  202. package/dist/utils/index.d.mts +2 -0
  203. package/dist/utils/index.d.ts +2 -0
  204. package/dist/utils/index.js +11 -0
  205. package/dist/utils/index.mjs +2 -0
  206. package/package.json +48 -27
  207. package/dist/index.umd.js +0 -74
  208. package/dist/types/index.d.ts +0 -4
  209. package/dist/types/lib/utils.d.ts +0 -2
  210. package/dist/types/ui/button.d.ts +0 -13
  211. package/dist/types/ui/input.d.ts +0 -19
  212. package/dist/vuer-uikit.css +0 -1
@@ -0,0 +1,339 @@
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
+ ],
57
+ className
58
+ ),
59
+ ...props
60
+ }
61
+ ) });
62
+ }
63
+ function DropdownMenuGroup({
64
+ className,
65
+ ...props
66
+ }) {
67
+ return /* @__PURE__ */ jsx(
68
+ DropdownMenuPrimitive.Group,
69
+ {
70
+ "data-slot": "dropdown-menu-group",
71
+ className: cn("space-y-xs", className),
72
+ ...props
73
+ }
74
+ );
75
+ }
76
+ function DropdownMenuItem({
77
+ className,
78
+ inset,
79
+ variant = "default",
80
+ ...props
81
+ }) {
82
+ return /* @__PURE__ */ jsx(
83
+ DropdownMenuPrimitive.Item,
84
+ {
85
+ "data-slot": "dropdown-menu-item",
86
+ "data-inset": inset,
87
+ "data-variant": variant,
88
+ className: cn(
89
+ [
90
+ "w-full",
91
+ "flex",
92
+ "gap-md",
93
+ "items-center",
94
+ "pr-md",
95
+ "pl-[calc(var(--spacing-md)*2)]",
96
+ "py-xs",
97
+ "mb-xs",
98
+ "last:mb-0",
99
+ "relative",
100
+ "cursor-default",
101
+ "rounded-uk-xs",
102
+ "text-xs",
103
+ "outline-hidden",
104
+ "select-none",
105
+ "hover:bg-bg-tertiary",
106
+ "data-[disabled]:pointer-events-none",
107
+ "data-[disabled]:text-text-tertiary",
108
+ "data-[disabled]:bg-bg-tertiary",
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-text-tertiary",
150
+ "data-[disabled]:bg-bg-tertiary",
151
+ "[&_svg:not([class*='size-'])]:size-4",
152
+ "[&_svg]:pointer-events-none",
153
+ "[&_svg]:shrink-0"
154
+ ],
155
+ className
156
+ ),
157
+ checked,
158
+ ...props,
159
+ children: [
160
+ /* @__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" }) }) }),
161
+ children
162
+ ]
163
+ }
164
+ );
165
+ }
166
+ function DropdownMenuRadioGroup({
167
+ ...props
168
+ }) {
169
+ return /* @__PURE__ */ jsx(DropdownMenuPrimitive.RadioGroup, { "data-slot": "dropdown-menu-radio-group", ...props });
170
+ }
171
+ function DropdownMenuRadioItem({
172
+ className,
173
+ children,
174
+ ...props
175
+ }) {
176
+ return /* @__PURE__ */ jsxs(
177
+ DropdownMenuPrimitive.RadioItem,
178
+ {
179
+ "data-slot": "dropdown-menu-radio-item",
180
+ className: cn(
181
+ [
182
+ "w-full",
183
+ "hover:bg-bg-tertiary",
184
+ "outline-hidden",
185
+ "relative",
186
+ "flex",
187
+ "cursor-default",
188
+ "select-none",
189
+ "items-center",
190
+ "gap-md",
191
+ "rounded-uk-xs",
192
+ "py-xs",
193
+ "pl-[calc(var(--spacing-xl)*1.8)]",
194
+ "pr-md",
195
+ "mb-xs",
196
+ "last:mb-0",
197
+ "text-xs",
198
+ "data-[disabled]:pointer-events-none",
199
+ "data-[disabled]:text-text-tertiary",
200
+ "data-[disabled]:bg-bg-tertiary",
201
+ "[&_svg:not([class*='size-'])]:size-4",
202
+ "[&_svg]:pointer-events-none",
203
+ "[&_svg]:shrink-0"
204
+ ],
205
+ className
206
+ ),
207
+ ...props,
208
+ children: [
209
+ /* @__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" }) }) }),
210
+ children
211
+ ]
212
+ }
213
+ );
214
+ }
215
+ function DropdownMenuLabel({
216
+ className,
217
+ inset,
218
+ ...props
219
+ }) {
220
+ return /* @__PURE__ */ jsx(
221
+ DropdownMenuPrimitive.Label,
222
+ {
223
+ "data-slot": "dropdown-menu-label",
224
+ "data-inset": inset,
225
+ className: cn("text-text-secondary px-2 py-1.5 text-xs", className),
226
+ ...props
227
+ }
228
+ );
229
+ }
230
+ function DropdownMenuSeparator({
231
+ className,
232
+ ...props
233
+ }) {
234
+ return /* @__PURE__ */ jsx(
235
+ DropdownMenuPrimitive.Separator,
236
+ {
237
+ "data-slot": "dropdown-menu-separator",
238
+ className: cn("bg-line-primary my-lg pointer-events-none -mx-1 h-px", className),
239
+ ...props
240
+ }
241
+ );
242
+ }
243
+ function DropdownMenuShortcut({ className, ...props }) {
244
+ return /* @__PURE__ */ jsx(
245
+ "span",
246
+ {
247
+ "data-slot": "dropdown-menu-shortcut",
248
+ className: cn("text-text-tertiary ml-auto text-xs", className),
249
+ ...props
250
+ }
251
+ );
252
+ }
253
+ function DropdownMenuSub({ ...props }) {
254
+ return /* @__PURE__ */ jsx(DropdownMenuPrimitive.Sub, { "data-slot": "dropdown-menu-sub", ...props });
255
+ }
256
+ function DropdownMenuSubTrigger({
257
+ className,
258
+ inset,
259
+ children,
260
+ ...props
261
+ }) {
262
+ return /* @__PURE__ */ jsxs(
263
+ DropdownMenuPrimitive.SubTrigger,
264
+ {
265
+ "data-slot": "dropdown-menu-sub-trigger",
266
+ "data-inset": inset,
267
+ className: cn(
268
+ "w-full",
269
+ "flex",
270
+ "gap-md",
271
+ "items-center",
272
+ "pr-md",
273
+ "pl-[calc(var(--spacing-md)*2)]",
274
+ "py-xs",
275
+ "mb-xs",
276
+ "relative",
277
+ "cursor-default",
278
+ "rounded-uk-xs",
279
+ "text-xs",
280
+ "outline-hidden",
281
+ "select-none",
282
+ "hover:bg-bg-tertiary",
283
+ "data-[state=open]:bg-bg-tertiary",
284
+ "data-[disabled]:pointer-events-none",
285
+ "data-[disabled]:text-text-tertiary",
286
+ "data-[disabled]:bg-bg-tertiary",
287
+ "[&_svg]:pointer-events-none",
288
+ "[&_svg]:shrink-0",
289
+ "[&_svg:not([class*='size-'])]:size-4",
290
+ "[&_svg:not([class*='text-'])]:text-muted-foreground",
291
+ className
292
+ ),
293
+ ...props,
294
+ children: [
295
+ children,
296
+ /* @__PURE__ */ jsx(ChevronRightIcon, { className: "ml-auto size-4" })
297
+ ]
298
+ }
299
+ );
300
+ }
301
+ function DropdownMenuSubContent({
302
+ className,
303
+ ...props
304
+ }) {
305
+ return /* @__PURE__ */ jsx(
306
+ DropdownMenuPrimitive.SubContent,
307
+ {
308
+ "data-slot": "dropdown-menu-sub-content",
309
+ className: cn(
310
+ "bg-bg-primary",
311
+ "p-md",
312
+ "data-[state=open]:animate-in",
313
+ "data-[state=closed]:animate-out",
314
+ "data-[state=closed]:fade-out-0",
315
+ "data-[state=open]:fade-in-0",
316
+ "data-[state=closed]:zoom-out-95",
317
+ "data-[state=open]:zoom-in-95",
318
+ "data-[side=bottom]:slide-in-from-top-2",
319
+ "data-[side=left]:slide-in-from-right-2",
320
+ "data-[side=right]:slide-in-from-left-2",
321
+ "data-[side=top]:slide-in-from-bottom-2",
322
+ "relative",
323
+ "z-50",
324
+ "max-h-(--radix-dropdown-menu-content-available-height)",
325
+ "min-w-[8rem]",
326
+ "origin-(--radix-dropdown-menu-content-transform-origin)",
327
+ "overflow-x-hidden",
328
+ "overflow-y-auto",
329
+ "rounded-uk-md",
330
+ "shadow-md",
331
+ "shadow-[0_8px_20px_0_rgba(0,0,0,.80)]",
332
+ className
333
+ ),
334
+ ...props
335
+ }
336
+ );
337
+ }
338
+
339
+ export { DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger };
@@ -0,0 +1,27 @@
1
+ 'use strict';
2
+
3
+ var react = require('react');
4
+
5
+ // src/highlight-cursor/cursor-context.tsx
6
+ var defaultDimensions = {
7
+ width: 0,
8
+ height: 0,
9
+ x: 0,
10
+ y: 0
11
+ };
12
+ var defaultContext = {
13
+ mousePosition: { x: 0, y: 0 },
14
+ hoveredElementId: null,
15
+ elementDimensions: defaultDimensions,
16
+ registerHoveredElement: () => {
17
+ },
18
+ unregisterHoveredElement: () => {
19
+ },
20
+ updateElementDimensions: () => {
21
+ }
22
+ };
23
+ var CursorContext = react.createContext(defaultContext);
24
+ var useCursor = () => react.useContext(CursorContext);
25
+
26
+ exports.CursorContext = CursorContext;
27
+ exports.useCursor = useCursor;
@@ -0,0 +1,102 @@
1
+ 'use strict';
2
+
3
+ var chunkUWO6RBCE_js = require('./chunk-UWO6RBCE.js');
4
+ var jsxRuntime = require('react/jsx-runtime');
5
+
6
+ function Card({ className, ...props }) {
7
+ return /* @__PURE__ */ jsxRuntime.jsx(
8
+ "div",
9
+ {
10
+ "data-slot": "card",
11
+ className: chunkUWO6RBCE_js.cn(
12
+ "flex",
13
+ "flex-col",
14
+ "gap-lg",
15
+ "w-[300px]",
16
+ "m-h-[244px]",
17
+ "rounded-lg",
18
+ "p-lg",
19
+ "bg-bg-primary",
20
+ "border-text-secondary",
21
+ "shadow-[0_4px_16px_0_var(--color-shadow-secondary)]",
22
+ className
23
+ ),
24
+ ...props
25
+ }
26
+ );
27
+ }
28
+ function CardHeader({ className, ...props }) {
29
+ return /* @__PURE__ */ jsxRuntime.jsx(
30
+ "div",
31
+ {
32
+ "data-slot": "card-header",
33
+ className: chunkUWO6RBCE_js.cn("flex", "flex-row", "items-center", "justify-between", "gap-lg", className),
34
+ ...props
35
+ }
36
+ );
37
+ }
38
+ function CardTitle({ className, ...props }) {
39
+ return /* @__PURE__ */ jsxRuntime.jsx(
40
+ "div",
41
+ {
42
+ "data-slot": "card-title",
43
+ className: chunkUWO6RBCE_js.cn(
44
+ "text-text-highlight",
45
+ "text-[14px]",
46
+ "leading-[20px]",
47
+ "font-medium",
48
+ "vertical-align-middle",
49
+ className
50
+ ),
51
+ ...props
52
+ }
53
+ );
54
+ }
55
+ function CardDescription({ className, ...props }) {
56
+ return /* @__PURE__ */ jsxRuntime.jsx(
57
+ "div",
58
+ {
59
+ "data-slot": "card-description",
60
+ className: chunkUWO6RBCE_js.cn("text-muted-foreground text-sm", className),
61
+ ...props
62
+ }
63
+ );
64
+ }
65
+ function CardAction({ className, ...props }) {
66
+ return /* @__PURE__ */ jsxRuntime.jsx(
67
+ "div",
68
+ {
69
+ "data-slot": "card-action",
70
+ className: chunkUWO6RBCE_js.cn(
71
+ "text-text-secondary",
72
+ "text-[11px]",
73
+ "leading-[14px]",
74
+ "font-medium",
75
+ "vertical-align-middle",
76
+ className
77
+ ),
78
+ ...props
79
+ }
80
+ );
81
+ }
82
+ function CardContent({ className, ...props }) {
83
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { "data-slot": "card-content", className: chunkUWO6RBCE_js.cn("", className), ...props });
84
+ }
85
+ function CardFooter({ className, ...props }) {
86
+ return /* @__PURE__ */ jsxRuntime.jsx(
87
+ "div",
88
+ {
89
+ "data-slot": "card-footer",
90
+ className: chunkUWO6RBCE_js.cn("[.border-t]:pt-6 flex items-center", className),
91
+ ...props
92
+ }
93
+ );
94
+ }
95
+
96
+ exports.Card = Card;
97
+ exports.CardAction = CardAction;
98
+ exports.CardContent = CardContent;
99
+ exports.CardDescription = CardDescription;
100
+ exports.CardFooter = CardFooter;
101
+ exports.CardHeader = CardHeader;
102
+ exports.CardTitle = CardTitle;
@@ -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 };