@hanzo/ui 5.3.35 → 5.3.36

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 (254) hide show
  1. package/bin/create-registry.js +0 -0
  2. package/bin/npx-registry-mcp.js +0 -0
  3. package/bin/registry-mcp-wrapper.sh +0 -0
  4. package/bin/registry-mcp.js +0 -0
  5. package/bin/start-mcp-server.sh +0 -0
  6. package/bin/test-mcp.sh +0 -0
  7. package/dist/3d/button.js +1 -297
  8. package/dist/3d/button.mjs +1 -272
  9. package/dist/3d/card.js +1 -233
  10. package/dist/3d/card.mjs +1 -206
  11. package/dist/3d/carousel.js +1 -370
  12. package/dist/3d/carousel.mjs +1 -343
  13. package/dist/3d/grid.js +1 -361
  14. package/dist/3d/grid.mjs +1 -336
  15. package/dist/3d/index.js +1 -1517
  16. package/dist/3d/index.mjs +1 -1471
  17. package/dist/3d/marquee.js +1 -351
  18. package/dist/3d/marquee.mjs +1 -326
  19. package/dist/3d/pin.js +1 -45
  20. package/dist/3d/pin.mjs +1 -23
  21. package/dist/accordion.js +1 -79
  22. package/dist/accordion.mjs +1 -54
  23. package/dist/alert-dialog.js +1 -224
  24. package/dist/alert-dialog.mjs +1 -191
  25. package/dist/alert.js +1 -97
  26. package/dist/alert.mjs +1 -91
  27. package/dist/animation/animated-background.js +1 -423
  28. package/dist/animation/animated-background.mjs +1 -417
  29. package/dist/animation/animated-beam.js +1 -118
  30. package/dist/animation/animated-beam.mjs +1 -96
  31. package/dist/animation/animated-cursor.js +1 -274
  32. package/dist/animation/animated-cursor.mjs +1 -269
  33. package/dist/animation/animated-icon.js +2 -356
  34. package/dist/animation/animated-icon.mjs +2 -350
  35. package/dist/animation/animated-list.js +1 -338
  36. package/dist/animation/animated-list.mjs +1 -332
  37. package/dist/animation/animated-number.js +1 -282
  38. package/dist/animation/animated-number.mjs +1 -276
  39. package/dist/animation/animated-testimonials.js +1 -96
  40. package/dist/animation/animated-testimonials.mjs +1 -74
  41. package/dist/animation/animated-tooltip.js +1 -66
  42. package/dist/animation/animated-tooltip.mjs +1 -44
  43. package/dist/animation/apple-cards-carousel.js +1 -307
  44. package/dist/animation/apple-cards-carousel.mjs +1 -284
  45. package/dist/animation/apple-hello-effect.js +1 -59
  46. package/dist/animation/apple-hello-effect.mjs +1 -37
  47. package/dist/animation/index.js +2 -1951
  48. package/dist/animation/index.mjs +2 -1920
  49. package/dist/avatar.js +1 -70
  50. package/dist/avatar.mjs +1 -46
  51. package/dist/badge.js +1 -60
  52. package/dist/badge.mjs +1 -54
  53. package/dist/blocks/index.js +2 -1684
  54. package/dist/blocks/index.mjs +2 -1645
  55. package/dist/breadcrumb.js +1 -106
  56. package/dist/breadcrumb.mjs +1 -98
  57. package/dist/calendar-ext/index.js +1 -207
  58. package/dist/calendar-ext/index.mjs +1 -169
  59. package/dist/calendar.js +1 -193
  60. package/dist/calendar.mjs +1 -168
  61. package/dist/carousel.js +1 -282
  62. package/dist/carousel.mjs +1 -253
  63. package/dist/charts/index.js +6 -5840
  64. package/dist/charts/index.mjs +6 -5749
  65. package/dist/checkbox.js +1 -59
  66. package/dist/checkbox.mjs +1 -34
  67. package/dist/code/block.js +2 -225
  68. package/dist/code/block.mjs +2 -202
  69. package/dist/code/compare.js +5 -444
  70. package/dist/code/compare.mjs +5 -421
  71. package/dist/code/diff.js +12 -429
  72. package/dist/code/diff.mjs +11 -405
  73. package/dist/code/editor.js +1 -242
  74. package/dist/code/editor.mjs +1 -217
  75. package/dist/code/explorer.js +1 -290
  76. package/dist/code/explorer.mjs +1 -267
  77. package/dist/code/index.js +26 -2514
  78. package/dist/code/index.mjs +24 -2471
  79. package/dist/code/preview.js +6 -363
  80. package/dist/code/preview.mjs +6 -340
  81. package/dist/code/snippet.js +2 -273
  82. package/dist/code/snippet.mjs +2 -249
  83. package/dist/code/tabs.js +1 -74
  84. package/dist/code/tabs.mjs +1 -52
  85. package/dist/code/terminal.js +3 -436
  86. package/dist/code/terminal.mjs +3 -413
  87. package/dist/collapsible.js +1 -32
  88. package/dist/collapsible.mjs +1 -8
  89. package/dist/command.js +1 -282
  90. package/dist/command.mjs +1 -251
  91. package/dist/context-menu.js +1 -206
  92. package/dist/context-menu.mjs +1 -170
  93. package/dist/desktop/hooks.js +1 -223
  94. package/dist/desktop/hooks.mjs +1 -198
  95. package/dist/desktop/index.js +1 -685
  96. package/dist/desktop/index.mjs +1 -657
  97. package/dist/desktop/spotlight.js +1 -260
  98. package/dist/desktop/spotlight.mjs +1 -235
  99. package/dist/desktop/window.js +1 -273
  100. package/dist/desktop/window.mjs +1 -247
  101. package/dist/device/index.js +1 -2
  102. package/dist/device/index.mjs +0 -1
  103. package/dist/dialog.js +1 -245
  104. package/dist/dialog.mjs +1 -213
  105. package/dist/dock/basic.js +1 -173
  106. package/dist/dock/basic.mjs +1 -150
  107. package/dist/dock/index.js +1 -647
  108. package/dist/dock/index.mjs +1 -620
  109. package/dist/dock/limelight-nav.js +1 -314
  110. package/dist/dock/limelight-nav.mjs +1 -293
  111. package/dist/dock/macos.js +1 -140
  112. package/dist/dock/macos.mjs +1 -117
  113. package/dist/dock/menu.js +1 -69
  114. package/dist/dock/menu.mjs +1 -47
  115. package/dist/dock/message.js +1 -148
  116. package/dist/dock/message.mjs +1 -126
  117. package/dist/drawer.js +1 -114
  118. package/dist/drawer.mjs +1 -102
  119. package/dist/dropdown-menu.js +1 -201
  120. package/dist/dropdown-menu.mjs +1 -165
  121. package/dist/finance/AdvancedChart.js +2 -47
  122. package/dist/finance/AdvancedChart.mjs +2 -45
  123. package/dist/finance/CompanyProfile.js +2 -47
  124. package/dist/finance/CompanyProfile.mjs +2 -45
  125. package/dist/finance/CryptoScreener.js +2 -44
  126. package/dist/finance/CryptoScreener.mjs +2 -42
  127. package/dist/finance/Financials.js +2 -51
  128. package/dist/finance/Financials.mjs +2 -49
  129. package/dist/finance/ForexScreener.js +2 -45
  130. package/dist/finance/ForexScreener.mjs +2 -43
  131. package/dist/finance/MarketOverview.js +2 -103
  132. package/dist/finance/MarketOverview.mjs +2 -101
  133. package/dist/finance/NewsTimeline.js +2 -43
  134. package/dist/finance/NewsTimeline.mjs +2 -41
  135. package/dist/finance/OrderEntry.js +1 -130
  136. package/dist/finance/OrderEntry.mjs +1 -128
  137. package/dist/finance/OrdersHistory.js +1 -63
  138. package/dist/finance/OrdersHistory.mjs +1 -61
  139. package/dist/finance/PositionsList.js +1 -79
  140. package/dist/finance/PositionsList.mjs +1 -77
  141. package/dist/finance/StockScreener.js +2 -45
  142. package/dist/finance/StockScreener.mjs +2 -43
  143. package/dist/finance/SymbolInfo.js +2 -45
  144. package/dist/finance/SymbolInfo.mjs +2 -43
  145. package/dist/finance/TechnicalAnalysis.js +2 -53
  146. package/dist/finance/TechnicalAnalysis.mjs +2 -51
  147. package/dist/finance/TickerTape.js +2 -55
  148. package/dist/finance/TickerTape.mjs +2 -53
  149. package/dist/finance/TradingPanel.js +1 -190
  150. package/dist/finance/TradingPanel.mjs +1 -188
  151. package/dist/finance/index.js +2 -929
  152. package/dist/finance/index.mjs +2 -913
  153. package/dist/form/index.js +1 -153
  154. package/dist/form/index.mjs +1 -123
  155. package/dist/form.js +1 -171
  156. package/dist/form.mjs +1 -141
  157. package/dist/hover-card.js +1 -57
  158. package/dist/hover-card.mjs +1 -33
  159. package/dist/index.js +192 -9618
  160. package/dist/index.mjs +192 -9202
  161. package/dist/input-otp.js +1 -78
  162. package/dist/input-otp.mjs +1 -53
  163. package/dist/kanban/index.js +1 -593
  164. package/dist/kanban/index.mjs +1 -571
  165. package/dist/lib/utils.js +1 -28
  166. package/dist/lib/utils.mjs +1 -24
  167. package/dist/mermaid/index.js +1 -280
  168. package/dist/mermaid/index.mjs +1 -253
  169. package/dist/navigation/index.js +1 -97
  170. package/dist/navigation/index.mjs +1 -78
  171. package/dist/navigation-menu.js +1 -148
  172. package/dist/navigation-menu.mjs +1 -115
  173. package/dist/pattern/grid-pattern.js +3 -325
  174. package/dist/pattern/grid-pattern.mjs +3 -302
  175. package/dist/pattern/index.js +3 -325
  176. package/dist/pattern/index.mjs +3 -302
  177. package/dist/popover.js +1 -62
  178. package/dist/popover.mjs +1 -36
  179. package/dist/progress.js +1 -61
  180. package/dist/progress.mjs +1 -36
  181. package/dist/project/gantt.js +1 -64
  182. package/dist/project/gantt.mjs +1 -42
  183. package/dist/project/index.js +1 -635
  184. package/dist/project/index.mjs +1 -610
  185. package/dist/project/kanban.js +1 -596
  186. package/dist/project/kanban.mjs +1 -571
  187. package/dist/project/list.js +1 -34
  188. package/dist/project/list.mjs +1 -11
  189. package/dist/radio-group.js +1 -67
  190. package/dist/radio-group.mjs +1 -44
  191. package/dist/resizable.js +1 -71
  192. package/dist/resizable.mjs +1 -47
  193. package/dist/scroll-area.js +1 -88
  194. package/dist/scroll-area.mjs +1 -65
  195. package/dist/select.js +1 -139
  196. package/dist/select.mjs +1 -110
  197. package/dist/separator.js +1 -58
  198. package/dist/separator.mjs +1 -33
  199. package/dist/sheet.js +1 -147
  200. package/dist/sheet.mjs +1 -116
  201. package/dist/skeleton.js +1 -31
  202. package/dist/skeleton.mjs +1 -26
  203. package/dist/slider.js +1 -98
  204. package/dist/slider.mjs +1 -72
  205. package/dist/sonner.js +1 -33
  206. package/dist/sonner.mjs +1 -28
  207. package/dist/spline/index.js +1 -210
  208. package/dist/spline/index.mjs +1 -201
  209. package/dist/spline/media-stack.js +1 -192
  210. package/dist/spline/media-stack.mjs +1 -184
  211. package/dist/spline/player.js +1 -36
  212. package/dist/spline/player.mjs +1 -30
  213. package/dist/switch.js +1 -61
  214. package/dist/switch.mjs +1 -36
  215. package/dist/table.js +1 -109
  216. package/dist/table.mjs +1 -100
  217. package/dist/tabs.js +1 -127
  218. package/dist/tabs.mjs +1 -101
  219. package/dist/tailwind/index.mjs +1 -2011
  220. package/dist/textarea.js +1 -77
  221. package/dist/textarea.mjs +1 -55
  222. package/dist/toggle-group.js +1 -117
  223. package/dist/toggle-group.mjs +1 -92
  224. package/dist/toggle.js +1 -70
  225. package/dist/toggle.mjs +1 -47
  226. package/dist/tooltip.js +1 -66
  227. package/dist/tooltip.mjs +1 -39
  228. package/dist/types/index.mjs +1 -51
  229. package/dist/ui/announcement.js +1 -133
  230. package/dist/ui/announcement.mjs +1 -111
  231. package/dist/ui/avatar-group.js +1 -87
  232. package/dist/ui/avatar-group.mjs +1 -64
  233. package/dist/ui/banner.js +1 -84
  234. package/dist/ui/banner.mjs +1 -61
  235. package/dist/ui/cursor.js +1 -77
  236. package/dist/ui/cursor.mjs +1 -55
  237. package/dist/ui/index.js +1 -494
  238. package/dist/ui/index.mjs +1 -461
  239. package/dist/ui/marquee.js +1 -73
  240. package/dist/ui/marquee.mjs +1 -51
  241. package/dist/ui/pill.js +1 -84
  242. package/dist/ui/pill.mjs +1 -61
  243. package/dist/ui/spinner.js +1 -27
  244. package/dist/ui/spinner.mjs +1 -25
  245. package/dist/ui/tags.js +1 -116
  246. package/dist/ui/tags.mjs +1 -94
  247. package/dist/ui/ticker.js +1 -72
  248. package/dist/ui/ticker.mjs +1 -50
  249. package/dist/util/index.mjs +1 -404
  250. package/package.json +28 -27
  251. package/dist/primitives/index.js +0 -9619
  252. package/dist/primitives/index.mjs +0 -9203
  253. package/dist/primitives-export.js +0 -9619
  254. package/dist/primitives-export.mjs +0 -9203
@@ -1,621 +1,2 @@
1
1
  "use client";
2
- import * as React from 'react';
3
- import { useRef, useImperativeHandle, useEffect } from 'react';
4
- import { useMotionValue, useSpring, useTransform, motion } from 'framer-motion';
5
- import { clsx } from 'clsx';
6
- import { twMerge } from 'tailwind-merge';
7
- import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
8
- import { Loader2, Search, Command, X, EyeOffIcon, EyeIcon } from 'lucide-react';
9
- import { Slot } from '@radix-ui/react-slot';
10
- import { cva } from 'class-variance-authority';
11
-
12
- var __defProp = Object.defineProperty;
13
- var __name = (target, value) => __defProp(target, "name", { value, configurable: true });
14
- function cn(...inputs) {
15
- return twMerge(clsx(inputs));
16
- }
17
- __name(cn, "cn");
18
- var DockContext = React.createContext({
19
- magnification: 60,
20
- distance: 140
21
- });
22
- var Dock = React.forwardRef(
23
- ({
24
- className,
25
- children,
26
- position = "bottom",
27
- magnification = 60,
28
- distance = 140
29
- }, ref) => {
30
- const positionClasses = {
31
- bottom: "bottom-0 left-1/2 -translate-x-1/2 flex-row",
32
- left: "left-0 top-1/2 -translate-y-1/2 flex-col",
33
- right: "right-0 top-1/2 -translate-y-1/2 flex-col"
34
- };
35
- return /* @__PURE__ */ jsx(DockContext.Provider, { value: { magnification, distance }, children: /* @__PURE__ */ jsx(
36
- "div",
37
- {
38
- ref,
39
- className: cn(
40
- "fixed z-50 flex items-end gap-1 rounded-2xl border border-white/10 bg-black/10 p-2 backdrop-blur-xl",
41
- "shadow-2xl shadow-black/20",
42
- "before:absolute before:inset-0 before:rounded-2xl before:bg-gradient-to-b before:from-white/10 before:to-transparent before:opacity-50",
43
- positionClasses[position],
44
- className
45
- ),
46
- children
47
- }
48
- ) });
49
- }
50
- );
51
- Dock.displayName = "Dock";
52
- var DockItem = React.forwardRef(
53
- ({
54
- className,
55
- children,
56
- onClick,
57
- tooltip,
58
- magnification: itemMagnification,
59
- distance: itemDistance
60
- }, ref) => {
61
- const buttonRef = React.useRef(null);
62
- const { magnification: contextMagnification, distance: contextDistance } = React.useContext(DockContext);
63
- const magnification = itemMagnification ?? contextMagnification;
64
- const distance = itemDistance ?? contextDistance;
65
- const [isHovered, setIsHovered] = React.useState(false);
66
- const mouseX = useMotionValue(Infinity);
67
- const springConfig = { mass: 0.1, stiffness: 150, damping: 12 };
68
- const size = useSpring(
69
- useTransform(
70
- mouseX,
71
- [-distance, 0, distance],
72
- [48, 48 + magnification, 48]
73
- ),
74
- springConfig
75
- );
76
- const handleMouseMove = /* @__PURE__ */ __name((e) => {
77
- if (!buttonRef.current) return;
78
- const rect = buttonRef.current.getBoundingClientRect();
79
- const centerX = rect.left + rect.width / 2;
80
- mouseX.set(e.clientX - centerX);
81
- }, "handleMouseMove");
82
- const handleMouseLeave = /* @__PURE__ */ __name(() => {
83
- mouseX.set(Infinity);
84
- setIsHovered(false);
85
- }, "handleMouseLeave");
86
- return /* @__PURE__ */ jsxs(
87
- motion.div,
88
- {
89
- className: "relative",
90
- onMouseMove: handleMouseMove,
91
- onMouseLeave: handleMouseLeave,
92
- onMouseEnter: () => setIsHovered(true),
93
- children: [
94
- tooltip && isHovered && /* @__PURE__ */ jsxs(
95
- motion.div,
96
- {
97
- initial: { opacity: 0, y: 10, scale: 0.9 },
98
- animate: { opacity: 1, y: 0, scale: 1 },
99
- exit: { opacity: 0, y: 5, scale: 0.95 },
100
- transition: { duration: 0.15 },
101
- className: "absolute bottom-full left-1/2 mb-2 -translate-x-1/2 whitespace-nowrap rounded-lg bg-black/80 px-2 py-1 text-xs text-white backdrop-blur-md",
102
- children: [
103
- tooltip,
104
- /* @__PURE__ */ jsx("div", { className: "absolute -bottom-1 left-1/2 h-2 w-2 -translate-x-1/2 rotate-45 bg-black/80" })
105
- ]
106
- }
107
- ),
108
- /* @__PURE__ */ jsxs(
109
- motion.button,
110
- {
111
- ref: buttonRef,
112
- style: {
113
- width: size,
114
- height: size
115
- },
116
- whileTap: { scale: 0.9 },
117
- onClick,
118
- className: cn(
119
- "relative flex items-center justify-center rounded-xl bg-white/10 backdrop-blur-md transition-colors",
120
- "hover:bg-white/20",
121
- "focus:outline-none focus-visible:ring-2 focus-visible:ring-white/50",
122
- className
123
- ),
124
- children: [
125
- /* @__PURE__ */ jsx(
126
- motion.div,
127
- {
128
- style: {
129
- width: size,
130
- height: size
131
- },
132
- className: "flex items-center justify-center",
133
- children
134
- }
135
- ),
136
- /* @__PURE__ */ jsx(
137
- motion.div,
138
- {
139
- className: "absolute inset-0 rounded-xl",
140
- style: {
141
- background: "linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%)"
142
- }
143
- }
144
- )
145
- ]
146
- }
147
- )
148
- ]
149
- }
150
- );
151
- }
152
- );
153
- DockItem.displayName = "DockItem";
154
- var DockContext2 = React.createContext({
155
- magnification: 60,
156
- distance: 140,
157
- mouseX: null
158
- });
159
- var Dock2 = React.forwardRef(
160
- ({ className, children, magnification = 60, distance = 140 }, ref) => {
161
- const mouseX = useMotionValue(Infinity);
162
- return /* @__PURE__ */ jsx(DockContext2.Provider, { value: { magnification, distance, mouseX }, children: /* @__PURE__ */ jsx(
163
- motion.div,
164
- {
165
- ref,
166
- onMouseMove: (e) => mouseX.set(e.pageX),
167
- onMouseLeave: () => mouseX.set(Infinity),
168
- className: cn(
169
- "mx-auto flex h-16 items-end gap-2 rounded-2xl border border-white/10 bg-black/10 px-3 pb-2 backdrop-blur-xl",
170
- "shadow-2xl shadow-black/20",
171
- "before:absolute before:inset-0 before:rounded-2xl before:bg-gradient-to-b before:from-white/10 before:to-transparent before:opacity-50",
172
- className
173
- ),
174
- children
175
- }
176
- ) });
177
- }
178
- );
179
- Dock2.displayName = "Dock";
180
- var DockItem2 = React.forwardRef(
181
- ({ className, children, onClick, tooltip }, ref) => {
182
- const buttonRef = React.useRef(null);
183
- const { magnification, distance, mouseX } = React.useContext(DockContext2);
184
- const [isHovered, setIsHovered] = React.useState(false);
185
- const distanceCalc = useTransform(mouseX, (val) => {
186
- const bounds = buttonRef.current?.getBoundingClientRect() ?? {
187
- x: 0,
188
- width: 0
189
- };
190
- return val - bounds.x - bounds.width / 2;
191
- });
192
- const widthSync = useTransform(
193
- distanceCalc,
194
- [-distance, 0, distance],
195
- [48, 48 + magnification, 48]
196
- );
197
- const width = useSpring(widthSync, {
198
- mass: 0.1,
199
- stiffness: 150,
200
- damping: 12
201
- });
202
- return /* @__PURE__ */ jsxs(
203
- motion.div,
204
- {
205
- className: "relative",
206
- onMouseEnter: () => setIsHovered(true),
207
- onMouseLeave: () => setIsHovered(false),
208
- children: [
209
- tooltip && isHovered && /* @__PURE__ */ jsxs(
210
- motion.div,
211
- {
212
- initial: { opacity: 0, y: 10, scale: 0.9 },
213
- animate: { opacity: 1, y: 0, scale: 1 },
214
- exit: { opacity: 0, y: 5, scale: 0.95 },
215
- transition: { duration: 0.15 },
216
- className: "absolute bottom-full left-1/2 mb-2 -translate-x-1/2 whitespace-nowrap rounded-lg bg-black/80 px-2 py-1 text-xs text-white backdrop-blur-md",
217
- children: [
218
- tooltip,
219
- /* @__PURE__ */ jsx("div", { className: "absolute -bottom-1 left-1/2 h-2 w-2 -translate-x-1/2 rotate-45 bg-black/80" })
220
- ]
221
- }
222
- ),
223
- /* @__PURE__ */ jsxs(
224
- motion.button,
225
- {
226
- ref: buttonRef,
227
- style: { width },
228
- whileTap: { scale: 0.95 },
229
- onClick,
230
- className: cn(
231
- "aspect-square w-12 rounded-xl bg-white/10 backdrop-blur-md transition-colors",
232
- "hover:bg-white/20",
233
- "focus:outline-none focus-visible:ring-2 focus-visible:ring-white/50",
234
- "relative overflow-hidden",
235
- className
236
- ),
237
- children: [
238
- /* @__PURE__ */ jsx("div", { className: "flex h-full w-full items-center justify-center", children }),
239
- /* @__PURE__ */ jsx(
240
- "div",
241
- {
242
- className: "pointer-events-none absolute inset-0 rounded-xl",
243
- style: {
244
- background: "linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%)"
245
- }
246
- }
247
- )
248
- ]
249
- }
250
- )
251
- ]
252
- }
253
- );
254
- }
255
- );
256
- DockItem2.displayName = "DockItem";
257
- var buttonVariants = cva(
258
- 'inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*="size-"])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive',
259
- {
260
- variants: {
261
- variant: {
262
- default: "bg-primary text-primary-foreground hover:bg-primary/90",
263
- destructive: "bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",
264
- outline: "border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",
265
- secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80",
266
- ghost: "hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",
267
- link: "text-primary underline-offset-4 hover:underline",
268
- // Keep the additional Hanzo variants for backward compatibility
269
- primary: "bg-primary text-primary-foreground shadow hover:bg-primary/90",
270
- linkFG: "text-primary underline-offset-4 hover:underline",
271
- linkMuted: "text-muted-foreground underline-offset-4 hover:underline hover:text-foreground"
272
- },
273
- size: {
274
- default: "h-9 px-4 py-2 has-[>svg]:px-3",
275
- sm: "h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",
276
- lg: "h-10 rounded-md px-6 has-[>svg]:px-4",
277
- icon: "size-9",
278
- "icon-sm": "size-8",
279
- "icon-lg": "size-10"
280
- }
281
- },
282
- defaultVariants: {
283
- variant: "default",
284
- size: "default"
285
- }
286
- }
287
- );
288
- var Button = React.forwardRef(
289
- ({ className, variant = "default", size = "default", asChild = false, isLoading = false, children, ...props }, ref) => {
290
- const Comp = asChild ? Slot : "button";
291
- return /* @__PURE__ */ jsxs(
292
- Comp,
293
- {
294
- "data-slot": "button",
295
- "data-variant": variant,
296
- "data-size": size,
297
- className: cn(buttonVariants({ variant, size, className })),
298
- ref,
299
- ...props,
300
- children: [
301
- isLoading ? /* @__PURE__ */ jsx(
302
- Loader2,
303
- {
304
- className: cn("h-4 w-4 animate-spin", size !== "icon" && size !== "icon-sm" && size !== "icon-lg" && "mr-2")
305
- }
306
- ) : null,
307
- isLoading && (size === "icon" || size === "icon-sm" || size === "icon-lg") ? null : children
308
- ]
309
- }
310
- );
311
- }
312
- );
313
- Button.displayName = "Button";
314
- var badgeVariants = cva(
315
- "inline-flex items-center justify-center w-fit whitespace-nowrap shrink-0 rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] focus-visible:outline-none aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive [&>svg]:pointer-events-none overflow-hidden",
316
- {
317
- variants: {
318
- variant: {
319
- default: "bg-primary text-primary-foreground hover:bg-primary/90 border-transparent shadow-sm",
320
- secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80 border-transparent",
321
- destructive: "bg-destructive text-white hover:bg-destructive/90 border-transparent shadow-sm focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",
322
- outline: "text-foreground border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground",
323
- ghost: "hover:bg-accent hover:text-accent-foreground border-transparent",
324
- link: "text-primary underline-offset-4 hover:underline border-transparent",
325
- // Hanzo-specific variants for backward compatibility
326
- inputAdornment: "bg-gray-600 px-2 font-medium text-white border-transparent",
327
- tags: "text-muted-foreground border-border bg-muted rounded-lg px-2 py-1 font-normal capitalize"
328
- }
329
- },
330
- defaultVariants: {
331
- variant: "default"
332
- }
333
- }
334
- );
335
- function Badge({
336
- className,
337
- variant = "default",
338
- asChild = false,
339
- ...props
340
- }) {
341
- const Comp = asChild ? Slot : "span";
342
- return /* @__PURE__ */ jsx(
343
- Comp,
344
- {
345
- "data-slot": "badge",
346
- "data-variant": variant,
347
- className: cn(badgeVariants({ variant }), className),
348
- ...props
349
- }
350
- );
351
- }
352
- __name(Badge, "Badge");
353
- var Input = /* @__PURE__ */ __name(({
354
- className,
355
- type,
356
- startAdornment,
357
- endAdornment,
358
- hidePasswordToggle,
359
- ref,
360
- ...props
361
- }) => {
362
- const inputRef = useRef(null);
363
- const startAdornmentRef = useRef(null);
364
- const endAdornmentRef = useRef(null);
365
- const [showPassword, setShowPassword] = React.useState(false);
366
- const togglePasswordVisibility = /* @__PURE__ */ __name(() => {
367
- setShowPassword(!showPassword);
368
- }, "togglePasswordVisibility");
369
- const style = {};
370
- if (startAdornment) {
371
- style.paddingLeft = `${(startAdornmentRef?.current?.offsetWidth ?? 0) + 20}px`;
372
- }
373
- if (endAdornment) {
374
- style.paddingRight = `${(endAdornmentRef?.current?.offsetWidth ?? 0) + 20}px`;
375
- }
376
- useImperativeHandle(ref, () => inputRef.current, []);
377
- useEffect(() => {
378
- if (props.autoFocus) {
379
- setTimeout(() => {
380
- inputRef?.current?.focus();
381
- }, 0);
382
- }
383
- }, [props.autoFocus]);
384
- const inputType = type === "password" && showPassword ? "text" : type;
385
- return /* @__PURE__ */ jsxs(Fragment, { children: [
386
- /* @__PURE__ */ jsx(
387
- "input",
388
- {
389
- className: cn(
390
- "h-input border-border-input bg-bg-secondary focus:border-border-input-focus disabled:bg-bg-input-disabled peer placeholder-shown:border-border-input text-text-default w-full rounded-lg border px-4 py-3 pt-8 text-sm font-medium placeholder-transparent outline outline-0 transition-all placeholder-shown:border focus:border focus:outline-0 disabled:border-0 disabled:text-gray-400",
391
- startAdornment && "pl-[var(--custom-padding-left-input)]",
392
- endAdornment && "pr-[var(--custom-padding-right-input)]",
393
- type === "password" && "pr-[60px]",
394
- className
395
- ),
396
- placeholder: " ",
397
- ref: inputRef,
398
- spellCheck: false,
399
- style,
400
- type: inputType,
401
- ...props
402
- }
403
- ),
404
- startAdornment ? /* @__PURE__ */ jsx(
405
- Badge,
406
- {
407
- className: "peer/adornment adornment absolute top-[30px] left-4",
408
- ref: startAdornmentRef,
409
- variant: "inputAdornment",
410
- children: startAdornment
411
- }
412
- ) : null,
413
- endAdornment && typeof endAdornment === "string" ? /* @__PURE__ */ jsx(
414
- Badge,
415
- {
416
- className: "peer/adornment adornment absolute top-[30px] right-4",
417
- ref: endAdornmentRef,
418
- variant: "inputAdornment",
419
- children: endAdornment
420
- }
421
- ) : null,
422
- endAdornment && typeof endAdornment !== "string" && React.isValidElement(endAdornment) ? React.cloneElement(endAdornment, {
423
- ref: endAdornmentRef
424
- }) : null,
425
- type === "password" && !hidePasswordToggle && /* @__PURE__ */ jsx(
426
- Button,
427
- {
428
- "aria-label": showPassword ? "Hide password" : "Show password",
429
- className: "absolute top-3 right-3",
430
- onClick: togglePasswordVisibility,
431
- size: "icon",
432
- type: "button",
433
- variant: "ghost",
434
- children: showPassword ? /* @__PURE__ */ jsx(EyeOffIcon, { "aria-hidden": "true", className: "h-4 w-4" }) : /* @__PURE__ */ jsx(EyeIcon, { "aria-hidden": "true", className: "h-4 w-4" })
435
- }
436
- )
437
- ] });
438
- }, "Input");
439
- Input.displayName = "Input";
440
- var LimelightNav = React.forwardRef(
441
- ({ className, items = [], ...props }, ref) => {
442
- const [isOpen, setIsOpen] = React.useState(false);
443
- const [search, setSearch] = React.useState("");
444
- React.useEffect(() => {
445
- const down = /* @__PURE__ */ __name((e) => {
446
- if (e.key === "k" && (e.metaKey || e.ctrlKey)) {
447
- e.preventDefault();
448
- setIsOpen((open) => !open);
449
- }
450
- }, "down");
451
- document.addEventListener("keydown", down);
452
- return () => document.removeEventListener("keydown", down);
453
- }, []);
454
- const filteredItems = items.filter(
455
- (item) => item.label.toLowerCase().includes(search.toLowerCase())
456
- );
457
- return /* @__PURE__ */ jsxs(Fragment, { children: [
458
- /* @__PURE__ */ jsxs(
459
- "nav",
460
- {
461
- ref,
462
- className: cn("flex items-center gap-4", className),
463
- ...props,
464
- children: [
465
- /* @__PURE__ */ jsxs(
466
- Button,
467
- {
468
- variant: "outline",
469
- onClick: () => setIsOpen(true),
470
- className: "relative w-64 justify-start",
471
- children: [
472
- /* @__PURE__ */ jsx(Search, { className: "mr-2 h-4 w-4" }),
473
- /* @__PURE__ */ jsx("span", { className: "text-muted-foreground", children: "Search..." }),
474
- /* @__PURE__ */ jsxs("kbd", { className: "pointer-events-none absolute right-2 hidden h-5 select-none items-center gap-1 rounded border bg-muted px-1.5 font-mono text-[10px] font-medium opacity-100 sm:flex", children: [
475
- /* @__PURE__ */ jsx(Command, { className: "h-3 w-3" }),
476
- "K"
477
- ] })
478
- ]
479
- }
480
- ),
481
- items.slice(0, 4).map((item) => /* @__PURE__ */ jsx(
482
- "a",
483
- {
484
- href: item.href,
485
- className: "text-sm font-medium transition-colors hover:text-primary",
486
- children: item.label
487
- },
488
- item.href
489
- ))
490
- ]
491
- }
492
- ),
493
- isOpen && /* @__PURE__ */ jsx(
494
- "div",
495
- {
496
- className: "fixed inset-0 z-50 bg-background/80 backdrop-blur-sm",
497
- onClick: () => setIsOpen(false),
498
- children: /* @__PURE__ */ jsxs(
499
- "div",
500
- {
501
- className: "fixed left-1/2 top-1/2 z-50 w-full max-w-lg -translate-x-1/2 -translate-y-1/2 rounded-lg border bg-card p-6 shadow-lg",
502
- onClick: (e) => e.stopPropagation(),
503
- children: [
504
- /* @__PURE__ */ jsx(
505
- Input,
506
- {
507
- placeholder: "Search navigation...",
508
- value: search,
509
- onChange: (e) => setSearch(e.target.value),
510
- autoFocus: true,
511
- className: "mb-4"
512
- }
513
- ),
514
- /* @__PURE__ */ jsx("div", { className: "max-h-96 space-y-1 overflow-auto", children: filteredItems.map((item) => /* @__PURE__ */ jsx(
515
- "a",
516
- {
517
- href: item.href,
518
- className: "block rounded-md px-4 py-2 hover:bg-accent",
519
- onClick: () => setIsOpen(false),
520
- children: item.label
521
- },
522
- item.href
523
- )) })
524
- ]
525
- }
526
- )
527
- }
528
- )
529
- ] });
530
- }
531
- );
532
- LimelightNav.displayName = "LimelightNav";
533
- var MenuDock = React.forwardRef(
534
- ({ className, items, orientation = "horizontal", ...props }, ref) => {
535
- return /* @__PURE__ */ jsx(
536
- "div",
537
- {
538
- ref,
539
- className: cn(
540
- "flex gap-2 rounded-full border bg-background/95 p-2 shadow-lg backdrop-blur",
541
- orientation === "vertical" ? "flex-col" : "flex-row",
542
- className
543
- ),
544
- ...props,
545
- children: items.map((item, index) => /* @__PURE__ */ jsxs(
546
- "button",
547
- {
548
- onClick: item.onClick,
549
- className: cn(
550
- "group relative flex items-center justify-center rounded-full p-3 transition-colors hover:bg-accent",
551
- item.active && "bg-primary text-primary-foreground hover:bg-primary/90"
552
- ),
553
- title: item.label,
554
- children: [
555
- item.icon,
556
- /* @__PURE__ */ jsx("span", { className: "sr-only", children: item.label }),
557
- /* @__PURE__ */ jsx("span", { className: "absolute -top-8 left-1/2 -translate-x-1/2 whitespace-nowrap rounded bg-popover px-2 py-1 text-xs text-popover-foreground opacity-0 transition-opacity group-hover:opacity-100", children: item.label })
558
- ]
559
- },
560
- index
561
- ))
562
- }
563
- );
564
- }
565
- );
566
- MenuDock.displayName = "MenuDock";
567
- var MessageDock = React.forwardRef(
568
- ({ className, messages, onClose, position = "bottom-right", ...props }, ref) => {
569
- const positionClasses = {
570
- top: "top-4 left-1/2 -translate-x-1/2",
571
- bottom: "bottom-4 left-1/2 -translate-x-1/2",
572
- "top-right": "top-4 right-4",
573
- "bottom-right": "bottom-4 right-4"
574
- };
575
- return /* @__PURE__ */ jsx(
576
- "div",
577
- {
578
- ref,
579
- className: cn(
580
- "fixed z-50 flex flex-col gap-2",
581
- positionClasses[position],
582
- className
583
- ),
584
- ...props,
585
- children: messages.map((message) => /* @__PURE__ */ jsx(
586
- "div",
587
- {
588
- className: cn(
589
- "min-w-[300px] rounded-lg border p-4 shadow-lg",
590
- message.type === "success" && "border-green-500 bg-green-50 dark:bg-green-950",
591
- message.type === "warning" && "border-yellow-500 bg-yellow-50 dark:bg-yellow-950",
592
- message.type === "error" && "border-red-500 bg-red-50 dark:bg-red-950",
593
- message.type === "info" && "border-blue-500 bg-blue-50 dark:bg-blue-950",
594
- !message.type && "bg-background"
595
- ),
596
- children: /* @__PURE__ */ jsxs("div", { className: "flex items-start justify-between gap-4", children: [
597
- /* @__PURE__ */ jsxs("div", { className: "flex-1", children: [
598
- /* @__PURE__ */ jsx("h4", { className: "font-medium", children: message.title }),
599
- message.description && /* @__PURE__ */ jsx("p", { className: "mt-1 text-sm text-muted-foreground", children: message.description })
600
- ] }),
601
- onClose && /* @__PURE__ */ jsx(
602
- Button,
603
- {
604
- variant: "ghost",
605
- size: "icon",
606
- className: "h-6 w-6",
607
- onClick: () => onClose(message.id),
608
- children: /* @__PURE__ */ jsx(X, { className: "h-4 w-4" })
609
- }
610
- )
611
- ] })
612
- },
613
- message.id
614
- ))
615
- }
616
- );
617
- }
618
- );
619
- MessageDock.displayName = "MessageDock";
620
-
621
- export { Dock, DockItem, LimelightNav, Dock2 as MacDock, DockItem2 as MacDockItem, MenuDock, MessageDock };
2
+ import*as p from'react';import {useRef,useImperativeHandle,useEffect}from'react';import {useMotionValue,useSpring,useTransform,motion}from'framer-motion';import {clsx}from'clsx';import {twMerge}from'tailwind-merge';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {Loader2,Search,Command,X,EyeOffIcon,EyeIcon}from'lucide-react';import {Slot}from'@radix-ui/react-slot';import {cva}from'class-variance-authority';var re=Object.defineProperty;var u=(i,r)=>re(i,"name",{value:r,configurable:true});function s(...i){return twMerge(clsx(i))}u(s,"cn");var _=p.createContext({magnification:60,distance:140}),F=p.forwardRef(({className:i,children:r,position:e="bottom",magnification:t=60,distance:c=140},o)=>{let l={bottom:"bottom-0 left-1/2 -translate-x-1/2 flex-row",left:"left-0 top-1/2 -translate-y-1/2 flex-col",right:"right-0 top-1/2 -translate-y-1/2 flex-col"};return jsx(_.Provider,{value:{magnification:t,distance:c},children:jsx("div",{ref:o,className:s("fixed z-50 flex items-end gap-1 rounded-2xl border border-white/10 bg-black/10 p-2 backdrop-blur-xl","shadow-2xl shadow-black/20","before:absolute before:inset-0 before:rounded-2xl before:bg-gradient-to-b before:from-white/10 before:to-transparent before:opacity-50",l[e],i),children:r})})});F.displayName="Dock";var K=p.forwardRef(({className:i,children:r,onClick:e,tooltip:t,magnification:c,distance:o},l)=>{let a=p.useRef(null),{magnification:f,distance:n}=p.useContext(_),d=c??f,b=o??n,[N,g]=p.useState(false),h=useMotionValue(1/0),P={mass:.1,stiffness:150,damping:12},I=useSpring(useTransform(h,[-b,0,b],[48,48+d,48]),P),Z=u(te=>{if(!a.current)return;let X=a.current.getBoundingClientRect(),oe=X.left+X.width/2;h.set(te.clientX-oe);},"handleMouseMove"),ee=u(()=>{h.set(1/0),g(false);},"handleMouseLeave");return jsxs(motion.div,{className:"relative",onMouseMove:Z,onMouseLeave:ee,onMouseEnter:()=>g(true),children:[t&&N&&jsxs(motion.div,{initial:{opacity:0,y:10,scale:.9},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:5,scale:.95},transition:{duration:.15},className:"absolute bottom-full left-1/2 mb-2 -translate-x-1/2 whitespace-nowrap rounded-lg bg-black/80 px-2 py-1 text-xs text-white backdrop-blur-md",children:[t,jsx("div",{className:"absolute -bottom-1 left-1/2 h-2 w-2 -translate-x-1/2 rotate-45 bg-black/80"})]}),jsxs(motion.button,{ref:a,style:{width:I,height:I},whileTap:{scale:.9},onClick:e,className:s("relative flex items-center justify-center rounded-xl bg-white/10 backdrop-blur-md transition-colors","hover:bg-white/20","focus:outline-none focus-visible:ring-2 focus-visible:ring-white/50",i),children:[jsx(motion.div,{style:{width:I,height:I},className:"flex items-center justify-center",children:r}),jsx(motion.div,{className:"absolute inset-0 rounded-xl",style:{background:"linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%)"}})]})]})});K.displayName="DockItem";var U=p.createContext({magnification:60,distance:140,mouseX:null}),$=p.forwardRef(({className:i,children:r,magnification:e=60,distance:t=140},c)=>{let o=useMotionValue(1/0);return jsx(U.Provider,{value:{magnification:e,distance:t,mouseX:o},children:jsx(motion.div,{ref:c,onMouseMove:l=>o.set(l.pageX),onMouseLeave:()=>o.set(1/0),className:s("mx-auto flex h-16 items-end gap-2 rounded-2xl border border-white/10 bg-black/10 px-3 pb-2 backdrop-blur-xl","shadow-2xl shadow-black/20","before:absolute before:inset-0 before:rounded-2xl before:bg-gradient-to-b before:from-white/10 before:to-transparent before:opacity-50",i),children:r})})});$.displayName="Dock";var A=p.forwardRef(({className:i,children:r,onClick:e,tooltip:t},c)=>{let o=p.useRef(null),{magnification:l,distance:a,mouseX:f}=p.useContext(U),[n,d]=p.useState(false),b=useTransform(f,h=>{let P=o.current?.getBoundingClientRect()??{x:0,width:0};return h-P.x-P.width/2}),N=useTransform(b,[-a,0,a],[48,48+l,48]),g=useSpring(N,{mass:.1,stiffness:150,damping:12});return jsxs(motion.div,{className:"relative",onMouseEnter:()=>d(true),onMouseLeave:()=>d(false),children:[t&&n&&jsxs(motion.div,{initial:{opacity:0,y:10,scale:.9},animate:{opacity:1,y:0,scale:1},exit:{opacity:0,y:5,scale:.95},transition:{duration:.15},className:"absolute bottom-full left-1/2 mb-2 -translate-x-1/2 whitespace-nowrap rounded-lg bg-black/80 px-2 py-1 text-xs text-white backdrop-blur-md",children:[t,jsx("div",{className:"absolute -bottom-1 left-1/2 h-2 w-2 -translate-x-1/2 rotate-45 bg-black/80"})]}),jsxs(motion.button,{ref:o,style:{width:g},whileTap:{scale:.95},onClick:e,className:s("aspect-square w-12 rounded-xl bg-white/10 backdrop-blur-md transition-colors","hover:bg-white/20","focus:outline-none focus-visible:ring-2 focus-visible:ring-white/50","relative overflow-hidden",i),children:[jsx("div",{className:"flex h-full w-full items-center justify-center",children:r}),jsx("div",{className:"pointer-events-none absolute inset-0 rounded-xl",style:{background:"linear-gradient(135deg, rgba(255,255,255,0.1) 0%, rgba(255,255,255,0) 100%)"}})]})]})});A.displayName="DockItem";var fe=cva('inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium transition-all disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg:not([class*="size-"])]:size-4 shrink-0 [&_svg]:shrink-0 outline-none focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive',{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-white hover:bg-destructive/90 focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:bg-input/30 dark:border-input dark:hover:bg-input/50",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50",link:"text-primary underline-offset-4 hover:underline",primary:"bg-primary text-primary-foreground shadow hover:bg-primary/90",linkFG:"text-primary underline-offset-4 hover:underline",linkMuted:"text-muted-foreground underline-offset-4 hover:underline hover:text-foreground"},size:{default:"h-9 px-4 py-2 has-[>svg]:px-3",sm:"h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5",lg:"h-10 rounded-md px-6 has-[>svg]:px-4",icon:"size-9","icon-sm":"size-8","icon-lg":"size-10"}},defaultVariants:{variant:"default",size:"default"}}),x=p.forwardRef(({className:i,variant:r="default",size:e="default",asChild:t=false,isLoading:c=false,children:o,...l},a)=>jsxs(t?Slot:"button",{"data-slot":"button","data-variant":r,"data-size":e,className:s(fe({variant:r,size:e,className:i})),ref:a,...l,children:[c?jsx(Loader2,{className:s("h-4 w-4 animate-spin",e!=="icon"&&e!=="icon-sm"&&e!=="icon-lg"&&"mr-2")}):null,c&&(e==="icon"||e==="icon-sm"||e==="icon-lg")?null:o]}));x.displayName="Button";var xe=cva("inline-flex items-center justify-center w-fit whitespace-nowrap shrink-0 rounded-md border px-2.5 py-0.5 text-xs font-semibold transition-colors focus-visible:border-ring focus-visible:ring-ring/50 focus-visible:ring-[3px] focus-visible:outline-none aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive [&>svg]:pointer-events-none overflow-hidden",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90 border-transparent shadow-sm",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80 border-transparent",destructive:"bg-destructive text-white hover:bg-destructive/90 border-transparent shadow-sm focus-visible:ring-destructive/20 dark:focus-visible:ring-destructive/40 dark:bg-destructive/60",outline:"text-foreground border-input bg-background shadow-xs hover:bg-accent hover:text-accent-foreground",ghost:"hover:bg-accent hover:text-accent-foreground border-transparent",link:"text-primary underline-offset-4 hover:underline border-transparent",inputAdornment:"bg-gray-600 px-2 font-medium text-white border-transparent",tags:"text-muted-foreground border-border bg-muted rounded-lg px-2 py-1 font-normal capitalize"}},defaultVariants:{variant:"default"}});function B({className:i,variant:r="default",asChild:e=false,...t}){return jsx(e?Slot:"span",{"data-slot":"badge","data-variant":r,className:s(xe({variant:r}),i),...t})}u(B,"Badge");var V=u(({className:i,type:r,startAdornment:e,endAdornment:t,hidePasswordToggle:c,ref:o,...l})=>{let a=useRef(null),f=useRef(null),n=useRef(null),[d,b]=p.useState(false),N=u(()=>{b(!d);},"togglePasswordVisibility"),g={};e&&(g.paddingLeft=`${(f?.current?.offsetWidth??0)+20}px`),t&&(g.paddingRight=`${(n?.current?.offsetWidth??0)+20}px`),useImperativeHandle(o,()=>a.current,[]),useEffect(()=>{l.autoFocus&&setTimeout(()=>{a?.current?.focus();},0);},[l.autoFocus]);let h=r==="password"&&d?"text":r;return jsxs(Fragment,{children:[jsx("input",{className:s("h-input border-border-input bg-bg-secondary focus:border-border-input-focus disabled:bg-bg-input-disabled peer placeholder-shown:border-border-input text-text-default w-full rounded-lg border px-4 py-3 pt-8 text-sm font-medium placeholder-transparent outline outline-0 transition-all placeholder-shown:border focus:border focus:outline-0 disabled:border-0 disabled:text-gray-400",e&&"pl-[var(--custom-padding-left-input)]",t&&"pr-[var(--custom-padding-right-input)]",r==="password"&&"pr-[60px]",i),placeholder:" ",ref:a,spellCheck:false,style:g,type:h,...l}),e?jsx(B,{className:"peer/adornment adornment absolute top-[30px] left-4",ref:f,variant:"inputAdornment",children:e}):null,t&&typeof t=="string"?jsx(B,{className:"peer/adornment adornment absolute top-[30px] right-4",ref:n,variant:"inputAdornment",children:t}):null,t&&typeof t!="string"&&p.isValidElement(t)?p.cloneElement(t,{ref:n}):null,r==="password"&&!c&&jsx(x,{"aria-label":d?"Hide password":"Show password",className:"absolute top-3 right-3",onClick:N,size:"icon",type:"button",variant:"ghost",children:d?jsx(EyeOffIcon,{"aria-hidden":"true",className:"h-4 w-4"}):jsx(EyeIcon,{"aria-hidden":"true",className:"h-4 w-4"})})]})},"Input");V.displayName="Input";var j=p.forwardRef(({className:i,items:r=[],...e},t)=>{let[c,o]=p.useState(false),[l,a]=p.useState("");p.useEffect(()=>{let n=u(d=>{d.key==="k"&&(d.metaKey||d.ctrlKey)&&(d.preventDefault(),o(b=>!b));},"down");return document.addEventListener("keydown",n),()=>document.removeEventListener("keydown",n)},[]);let f=r.filter(n=>n.label.toLowerCase().includes(l.toLowerCase()));return jsxs(Fragment,{children:[jsxs("nav",{ref:t,className:s("flex items-center gap-4",i),...e,children:[jsxs(x,{variant:"outline",onClick:()=>o(true),className:"relative w-64 justify-start",children:[jsx(Search,{className:"mr-2 h-4 w-4"}),jsx("span",{className:"text-muted-foreground",children:"Search..."}),jsxs("kbd",{className:"pointer-events-none absolute right-2 hidden h-5 select-none items-center gap-1 rounded border bg-muted px-1.5 font-mono text-[10px] font-medium opacity-100 sm:flex",children:[jsx(Command,{className:"h-3 w-3"}),"K"]})]}),r.slice(0,4).map(n=>jsx("a",{href:n.href,className:"text-sm font-medium transition-colors hover:text-primary",children:n.label},n.href))]}),c&&jsx("div",{className:"fixed inset-0 z-50 bg-background/80 backdrop-blur-sm",onClick:()=>o(false),children:jsxs("div",{className:"fixed left-1/2 top-1/2 z-50 w-full max-w-lg -translate-x-1/2 -translate-y-1/2 rounded-lg border bg-card p-6 shadow-lg",onClick:n=>n.stopPropagation(),children:[jsx(V,{placeholder:"Search navigation...",value:l,onChange:n=>a(n.target.value),autoFocus:true,className:"mb-4"}),jsx("div",{className:"max-h-96 space-y-1 overflow-auto",children:f.map(n=>jsx("a",{href:n.href,className:"block rounded-md px-4 py-2 hover:bg-accent",onClick:()=>o(false),children:n.label},n.href))})]})})]})});j.displayName="LimelightNav";var G=p.forwardRef(({className:i,items:r,orientation:e="horizontal",...t},c)=>jsx("div",{ref:c,className:s("flex gap-2 rounded-full border bg-background/95 p-2 shadow-lg backdrop-blur",e==="vertical"?"flex-col":"flex-row",i),...t,children:r.map((o,l)=>jsxs("button",{onClick:o.onClick,className:s("group relative flex items-center justify-center rounded-full p-3 transition-colors hover:bg-accent",o.active&&"bg-primary text-primary-foreground hover:bg-primary/90"),title:o.label,children:[o.icon,jsx("span",{className:"sr-only",children:o.label}),jsx("span",{className:"absolute -top-8 left-1/2 -translate-x-1/2 whitespace-nowrap rounded bg-popover px-2 py-1 text-xs text-popover-foreground opacity-0 transition-opacity group-hover:opacity-100",children:o.label})]},l))}));G.displayName="MenuDock";var Y=p.forwardRef(({className:i,messages:r,onClose:e,position:t="bottom-right",...c},o)=>jsx("div",{ref:o,className:s("fixed z-50 flex flex-col gap-2",{top:"top-4 left-1/2 -translate-x-1/2",bottom:"bottom-4 left-1/2 -translate-x-1/2","top-right":"top-4 right-4","bottom-right":"bottom-4 right-4"}[t],i),...c,children:r.map(a=>jsx("div",{className:s("min-w-[300px] rounded-lg border p-4 shadow-lg",a.type==="success"&&"border-green-500 bg-green-50 dark:bg-green-950",a.type==="warning"&&"border-yellow-500 bg-yellow-50 dark:bg-yellow-950",a.type==="error"&&"border-red-500 bg-red-50 dark:bg-red-950",a.type==="info"&&"border-blue-500 bg-blue-50 dark:bg-blue-950",!a.type&&"bg-background"),children:jsxs("div",{className:"flex items-start justify-between gap-4",children:[jsxs("div",{className:"flex-1",children:[jsx("h4",{className:"font-medium",children:a.title}),a.description&&jsx("p",{className:"mt-1 text-sm text-muted-foreground",children:a.description})]}),e&&jsx(x,{variant:"ghost",size:"icon",className:"h-6 w-6",onClick:()=>e(a.id),children:jsx(X,{className:"h-4 w-4"})})]})},a.id))}));Y.displayName="MessageDock";export{F as Dock,K as DockItem,j as LimelightNav,$ as MacDock,A as MacDockItem,G as MenuDock,Y as MessageDock};