@web-my-money/blocks 1.0.0

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.
package/dist/fx.js ADDED
@@ -0,0 +1,1142 @@
1
+ "use strict";
2
+ var __create = Object.create;
3
+ var __defProp = Object.defineProperty;
4
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
+ var __getOwnPropNames = Object.getOwnPropertyNames;
6
+ var __getProtoOf = Object.getPrototypeOf;
7
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
8
+ var __export = (target, all) => {
9
+ for (var name in all)
10
+ __defProp(target, name, { get: all[name], enumerable: true });
11
+ };
12
+ var __copyProps = (to, from, except, desc) => {
13
+ if (from && typeof from === "object" || typeof from === "function") {
14
+ for (let key of __getOwnPropNames(from))
15
+ if (!__hasOwnProp.call(to, key) && key !== except)
16
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
17
+ }
18
+ return to;
19
+ };
20
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
+ // If the importer is in node compatibility mode or this is not an ESM
22
+ // file that has been converted to a CommonJS file using a Babel-
23
+ // compatible transform (i.e. "__esModule" has not been set), then set
24
+ // "default" to the CommonJS "module.exports" for node compatibility.
25
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
26
+ mod
27
+ ));
28
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
29
+
30
+ // src/fx.ts
31
+ var fx_exports = {};
32
+ __export(fx_exports, {
33
+ AuroraBackground: () => AuroraBackground,
34
+ BACKGROUND_VARIANTS: () => BACKGROUND_VARIANTS,
35
+ BorderBeam: () => BorderBeam,
36
+ DesignStudio: () => DesignStudio,
37
+ Dock: () => Dock,
38
+ DynamicBackground: () => DynamicBackground,
39
+ FxPreferencesProvider: () => FxPreferencesProvider,
40
+ GridBackground: () => GridBackground,
41
+ Logo3D: () => Logo3D,
42
+ Magnetic: () => Magnetic,
43
+ MeshGradient: () => MeshGradient,
44
+ NoiseOverlay: () => NoiseOverlay,
45
+ ParticleField: () => ParticleField,
46
+ SpotlightBackground: () => SpotlightBackground,
47
+ SpotlightCard: () => SpotlightCard,
48
+ TextShimmer: () => TextShimmer,
49
+ TiltCard: () => TiltCard,
50
+ useFxPreferences: () => useFxPreferences,
51
+ useOptionalFxPreferences: () => useOptionalFxPreferences
52
+ });
53
+ module.exports = __toCommonJS(fx_exports);
54
+
55
+ // src/utils.ts
56
+ var import_clsx = require("clsx");
57
+ var import_tailwind_merge = require("tailwind-merge");
58
+ function cn(...inputs) {
59
+ return (0, import_tailwind_merge.twMerge)((0, import_clsx.clsx)(inputs));
60
+ }
61
+
62
+ // src/fx/aurora-background.tsx
63
+ var import_jsx_runtime = require("react/jsx-runtime");
64
+ function AuroraBackground({
65
+ blur = "80px",
66
+ intensity = 0.6,
67
+ speed = 18,
68
+ vignette = true,
69
+ className
70
+ }) {
71
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
72
+ "div",
73
+ {
74
+ "aria-hidden": true,
75
+ className: cn("pointer-events-none absolute inset-0 overflow-hidden", className),
76
+ style: { opacity: intensity },
77
+ children: [
78
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
79
+ "div",
80
+ {
81
+ "data-wmm-fx": true,
82
+ className: "absolute -left-[10%] -top-[20%] h-[70%] w-[60%] rounded-full",
83
+ style: {
84
+ background: "radial-gradient(circle at center, color-mix(in srgb, var(--primary) 70%, transparent), transparent 70%)",
85
+ filter: `blur(${blur})`,
86
+ animation: `wmm-aurora-drift ${speed}s var(--ease-in-out, ease-in-out) infinite`
87
+ }
88
+ }
89
+ ),
90
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
91
+ "div",
92
+ {
93
+ "data-wmm-fx": true,
94
+ className: "absolute -right-[10%] top-[5%] h-[65%] w-[55%] rounded-full",
95
+ style: {
96
+ background: "radial-gradient(circle at center, color-mix(in srgb, var(--accent, var(--primary)) 65%, transparent), transparent 70%)",
97
+ filter: `blur(${blur})`,
98
+ animation: `wmm-aurora-drift-2 ${speed * 1.3}s var(--ease-in-out, ease-in-out) infinite`
99
+ }
100
+ }
101
+ ),
102
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
103
+ "div",
104
+ {
105
+ "data-wmm-fx": true,
106
+ className: "absolute bottom-[-15%] left-[25%] h-[55%] w-[50%] rounded-full",
107
+ style: {
108
+ background: "radial-gradient(circle at center, color-mix(in srgb, var(--primary) 50%, transparent), transparent 70%)",
109
+ filter: `blur(${blur})`,
110
+ animation: `wmm-aurora-drift ${speed * 0.85}s var(--ease-in-out, ease-in-out) infinite reverse`
111
+ }
112
+ }
113
+ ),
114
+ vignette && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
115
+ "div",
116
+ {
117
+ className: "absolute inset-0",
118
+ style: { background: "radial-gradient(ellipse at center, transparent 40%, var(--background) 100%)" }
119
+ }
120
+ )
121
+ ]
122
+ }
123
+ );
124
+ }
125
+
126
+ // src/fx/mesh-gradient.tsx
127
+ var import_jsx_runtime2 = require("react/jsx-runtime");
128
+ function MeshGradient({
129
+ speed = 15,
130
+ intensity = 0.5,
131
+ static: isStatic = false,
132
+ className
133
+ }) {
134
+ return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
135
+ "div",
136
+ {
137
+ "aria-hidden": true,
138
+ "data-wmm-fx": true,
139
+ className: cn("pointer-events-none absolute inset-0", className),
140
+ style: {
141
+ opacity: intensity,
142
+ backgroundImage: [
143
+ "radial-gradient(at 20% 30%, color-mix(in srgb, var(--primary) 55%, transparent) 0px, transparent 50%)",
144
+ "radial-gradient(at 80% 20%, color-mix(in srgb, var(--accent, var(--primary)) 45%, transparent) 0px, transparent 50%)",
145
+ "radial-gradient(at 70% 80%, color-mix(in srgb, var(--primary) 40%, transparent) 0px, transparent 50%)",
146
+ "radial-gradient(at 25% 75%, color-mix(in srgb, var(--accent, var(--primary)) 35%, transparent) 0px, transparent 50%)"
147
+ ].join(", "),
148
+ backgroundSize: "150% 150%",
149
+ animation: isStatic ? void 0 : `wmm-mesh-pan ${speed}s var(--ease-in-out, ease-in-out) infinite`
150
+ }
151
+ }
152
+ );
153
+ }
154
+
155
+ // src/fx/grid-background.tsx
156
+ var React = __toESM(require("react"));
157
+ var import_jsx_runtime3 = require("react/jsx-runtime");
158
+ function GridBackground({
159
+ variant = "dot",
160
+ size = 32,
161
+ spotlight = false,
162
+ spotlightRadius = 220,
163
+ fade = true,
164
+ className
165
+ }) {
166
+ const ref = React.useRef(null);
167
+ const frame = React.useRef(null);
168
+ React.useEffect(() => {
169
+ if (!spotlight) return;
170
+ const el = ref.current;
171
+ if (!el) return;
172
+ const onMove = (e) => {
173
+ if (frame.current != null) return;
174
+ frame.current = requestAnimationFrame(() => {
175
+ frame.current = null;
176
+ const rect = el.getBoundingClientRect();
177
+ el.style.setProperty("--wmm-x", `${e.clientX - rect.left}px`);
178
+ el.style.setProperty("--wmm-y", `${e.clientY - rect.top}px`);
179
+ });
180
+ };
181
+ window.addEventListener("pointermove", onMove);
182
+ return () => {
183
+ window.removeEventListener("pointermove", onMove);
184
+ if (frame.current != null) cancelAnimationFrame(frame.current);
185
+ };
186
+ }, [spotlight]);
187
+ const lineColor = "color-mix(in srgb, var(--foreground) 10%, transparent)";
188
+ const gridImage = variant === "dot" ? `radial-gradient(${lineColor} 1px, transparent 1px)` : `linear-gradient(${lineColor} 1px, transparent 1px), linear-gradient(90deg, ${lineColor} 1px, transparent 1px)`;
189
+ const maskParts = [];
190
+ if (spotlight) {
191
+ maskParts.push(
192
+ `radial-gradient(${spotlightRadius}px circle at var(--wmm-x, -100%) var(--wmm-y, -100%), black 0%, transparent 100%)`
193
+ );
194
+ } else if (fade) {
195
+ maskParts.push("radial-gradient(ellipse at center, black 50%, transparent 100%)");
196
+ }
197
+ const maskStyle = maskParts.length > 0 ? { WebkitMaskImage: maskParts.join(", "), maskImage: maskParts.join(", ") } : {};
198
+ return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
199
+ "div",
200
+ {
201
+ ref,
202
+ "aria-hidden": true,
203
+ className: cn("pointer-events-none absolute inset-0", className),
204
+ style: {
205
+ backgroundImage: gridImage,
206
+ backgroundSize: `${size}px ${size}px`,
207
+ ...maskStyle
208
+ }
209
+ }
210
+ );
211
+ }
212
+
213
+ // src/fx/spotlight-background.tsx
214
+ var React2 = __toESM(require("react"));
215
+ var import_jsx_runtime4 = require("react/jsx-runtime");
216
+ function SpotlightBackground({
217
+ radius = 400,
218
+ intensity = 0.15,
219
+ idleFloat = true,
220
+ className
221
+ }) {
222
+ const ref = React2.useRef(null);
223
+ const frame = React2.useRef(null);
224
+ const [active, setActive] = React2.useState(false);
225
+ React2.useEffect(() => {
226
+ const el = ref.current;
227
+ if (!el) return;
228
+ const onMove = (e) => {
229
+ if (frame.current != null) return;
230
+ frame.current = requestAnimationFrame(() => {
231
+ frame.current = null;
232
+ const rect = el.getBoundingClientRect();
233
+ el.style.setProperty("--wmm-x", `${e.clientX - rect.left}px`);
234
+ el.style.setProperty("--wmm-y", `${e.clientY - rect.top}px`);
235
+ if (!active) setActive(true);
236
+ });
237
+ };
238
+ window.addEventListener("pointermove", onMove);
239
+ return () => {
240
+ window.removeEventListener("pointermove", onMove);
241
+ if (frame.current != null) cancelAnimationFrame(frame.current);
242
+ };
243
+ }, [active]);
244
+ return /* @__PURE__ */ (0, import_jsx_runtime4.jsx)(
245
+ "div",
246
+ {
247
+ ref,
248
+ "aria-hidden": true,
249
+ "data-wmm-fx": idleFloat && !active ? "" : void 0,
250
+ className: cn("pointer-events-none absolute inset-0", className),
251
+ style: {
252
+ background: `radial-gradient(${radius}px circle at var(--wmm-x, 50%) var(--wmm-y, 30%), color-mix(in srgb, var(--primary) ${Math.round(
253
+ intensity * 100
254
+ )}%, transparent), transparent 80%)`,
255
+ animation: idleFloat && !active ? "wmm-float 7s var(--ease-in-out, ease-in-out) infinite" : void 0,
256
+ transition: "background 120ms linear"
257
+ }
258
+ }
259
+ );
260
+ }
261
+
262
+ // src/fx/particle-field.tsx
263
+ var React3 = __toESM(require("react"));
264
+ var import_jsx_runtime5 = require("react/jsx-runtime");
265
+ function ParticleField({
266
+ count = 60,
267
+ connect = true,
268
+ linkDistance = 130,
269
+ color,
270
+ speed = 1,
271
+ interactive = true,
272
+ className
273
+ }) {
274
+ const canvasRef = React3.useRef(null);
275
+ React3.useEffect(() => {
276
+ const canvas = canvasRef.current;
277
+ if (!canvas) return;
278
+ const ctx = canvas.getContext("2d");
279
+ if (!ctx) return;
280
+ const reduced = typeof window !== "undefined" && window.matchMedia?.("(prefers-reduced-motion: reduce)").matches;
281
+ const resolvedColor = color || getComputedStyle(canvas).getPropertyValue("--primary").trim() || "currentColor";
282
+ let width = 0;
283
+ let height = 0;
284
+ let dpr = 1;
285
+ let particles = [];
286
+ const mouse = { x: -9999, y: -9999 };
287
+ const isSmall = typeof window !== "undefined" && window.innerWidth < 768;
288
+ const n = Math.max(8, Math.round(isSmall ? count * 0.5 : count));
289
+ const resize = () => {
290
+ const parent = canvas.parentElement;
291
+ if (!parent) return;
292
+ dpr = Math.min(window.devicePixelRatio || 1, 1.5);
293
+ width = parent.clientWidth;
294
+ height = parent.clientHeight;
295
+ canvas.width = width * dpr;
296
+ canvas.height = height * dpr;
297
+ canvas.style.width = `${width}px`;
298
+ canvas.style.height = `${height}px`;
299
+ ctx.setTransform(dpr, 0, 0, dpr, 0, 0);
300
+ };
301
+ const seed = () => {
302
+ particles = Array.from({ length: n }, () => ({
303
+ x: Math.random() * width,
304
+ y: Math.random() * height,
305
+ vx: (Math.random() - 0.5) * 0.4 * speed,
306
+ vy: (Math.random() - 0.5) * 0.4 * speed
307
+ }));
308
+ };
309
+ const draw = () => {
310
+ ctx.clearRect(0, 0, width, height);
311
+ for (const p of particles) {
312
+ ctx.beginPath();
313
+ ctx.arc(p.x, p.y, 1.6, 0, Math.PI * 2);
314
+ ctx.fillStyle = resolvedColor;
315
+ ctx.globalAlpha = 0.7;
316
+ ctx.fill();
317
+ }
318
+ if (connect) {
319
+ for (let i = 0; i < particles.length; i++) {
320
+ for (let j = i + 1; j < particles.length; j++) {
321
+ const a = particles[i];
322
+ const b = particles[j];
323
+ const dx = a.x - b.x;
324
+ const dy = a.y - b.y;
325
+ const dist = Math.hypot(dx, dy);
326
+ if (dist < linkDistance) {
327
+ ctx.beginPath();
328
+ ctx.moveTo(a.x, a.y);
329
+ ctx.lineTo(b.x, b.y);
330
+ ctx.strokeStyle = resolvedColor;
331
+ ctx.globalAlpha = (1 - dist / linkDistance) * 0.25;
332
+ ctx.lineWidth = 1;
333
+ ctx.stroke();
334
+ }
335
+ }
336
+ }
337
+ }
338
+ ctx.globalAlpha = 1;
339
+ };
340
+ const step = () => {
341
+ for (const p of particles) {
342
+ p.x += p.vx;
343
+ p.y += p.vy;
344
+ if (interactive) {
345
+ const dx = mouse.x - p.x;
346
+ const dy = mouse.y - p.y;
347
+ const d = Math.hypot(dx, dy);
348
+ if (d < 120 && d > 0.1) {
349
+ p.x += dx / d * 0.4;
350
+ p.y += dy / d * 0.4;
351
+ }
352
+ }
353
+ if (p.x < 0 || p.x > width) p.vx *= -1;
354
+ if (p.y < 0 || p.y > height) p.vy *= -1;
355
+ p.x = Math.max(0, Math.min(width, p.x));
356
+ p.y = Math.max(0, Math.min(height, p.y));
357
+ }
358
+ draw();
359
+ };
360
+ let raf = 0;
361
+ let running = false;
362
+ const loop = () => {
363
+ step();
364
+ raf = requestAnimationFrame(loop);
365
+ };
366
+ const start = () => {
367
+ if (running || reduced) return;
368
+ running = true;
369
+ raf = requestAnimationFrame(loop);
370
+ };
371
+ const stop = () => {
372
+ running = false;
373
+ cancelAnimationFrame(raf);
374
+ };
375
+ resize();
376
+ seed();
377
+ draw();
378
+ const io = new IntersectionObserver(
379
+ ([entry]) => entry.isIntersecting ? start() : stop(),
380
+ { threshold: 0.01 }
381
+ );
382
+ io.observe(canvas);
383
+ const onVisibility = () => document.hidden ? stop() : start();
384
+ const onResize = () => {
385
+ resize();
386
+ seed();
387
+ };
388
+ const onMove = (e) => {
389
+ const rect = canvas.getBoundingClientRect();
390
+ mouse.x = e.clientX - rect.left;
391
+ mouse.y = e.clientY - rect.top;
392
+ };
393
+ const onLeave = () => {
394
+ mouse.x = -9999;
395
+ mouse.y = -9999;
396
+ };
397
+ document.addEventListener("visibilitychange", onVisibility);
398
+ window.addEventListener("resize", onResize);
399
+ if (interactive) {
400
+ window.addEventListener("pointermove", onMove);
401
+ window.addEventListener("pointerleave", onLeave);
402
+ }
403
+ return () => {
404
+ stop();
405
+ io.disconnect();
406
+ document.removeEventListener("visibilitychange", onVisibility);
407
+ window.removeEventListener("resize", onResize);
408
+ window.removeEventListener("pointermove", onMove);
409
+ window.removeEventListener("pointerleave", onLeave);
410
+ };
411
+ }, [count, connect, linkDistance, color, speed, interactive]);
412
+ return /* @__PURE__ */ (0, import_jsx_runtime5.jsx)(
413
+ "canvas",
414
+ {
415
+ ref: canvasRef,
416
+ "aria-hidden": true,
417
+ className: cn("pointer-events-none absolute inset-0 h-full w-full", className)
418
+ }
419
+ );
420
+ }
421
+
422
+ // src/fx/noise-overlay.tsx
423
+ var import_jsx_runtime6 = require("react/jsx-runtime");
424
+ var NOISE_SVG = encodeURIComponent(
425
+ `<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>`
426
+ ).replace(/%23/g, "%23");
427
+ function NoiseOverlay({ opacity = 0.04, blend = "overlay", className }) {
428
+ return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
429
+ "div",
430
+ {
431
+ "aria-hidden": true,
432
+ className: cn("pointer-events-none absolute inset-0", className),
433
+ style: {
434
+ opacity,
435
+ mixBlendMode: blend,
436
+ backgroundImage: `url("data:image/svg+xml,${NOISE_SVG}")`,
437
+ backgroundSize: "120px 120px"
438
+ }
439
+ }
440
+ );
441
+ }
442
+
443
+ // src/fx/preferences.tsx
444
+ var React4 = __toESM(require("react"));
445
+ var import_jsx_runtime7 = require("react/jsx-runtime");
446
+ var BACKGROUND_VARIANTS = [
447
+ "none",
448
+ "aurora",
449
+ "mesh",
450
+ "grid",
451
+ "spotlight",
452
+ "particles"
453
+ ];
454
+ var Ctx = React4.createContext(null);
455
+ var PREFS_KEY = "wmm-fx-prefs";
456
+ var THEME_KEY = "wmm-theme";
457
+ function readStored() {
458
+ if (typeof window === "undefined") return {};
459
+ try {
460
+ return JSON.parse(window.localStorage.getItem(PREFS_KEY) || "{}");
461
+ } catch {
462
+ return {};
463
+ }
464
+ }
465
+ function FxPreferencesProvider({
466
+ children,
467
+ defaultBackground = "none"
468
+ }) {
469
+ const [background, setBackgroundState] = React4.useState(defaultBackground);
470
+ const [logo, setLogoState] = React4.useState(null);
471
+ const [theme, setThemeState] = React4.useState("dark");
472
+ React4.useEffect(() => {
473
+ const stored = readStored();
474
+ if (stored.background) setBackgroundState(stored.background);
475
+ if (stored.logo !== void 0) setLogoState(stored.logo ?? null);
476
+ const domTheme = document.documentElement.dataset.theme || void 0;
477
+ const lsTheme = window.localStorage.getItem(THEME_KEY) || void 0;
478
+ if (domTheme || lsTheme) setThemeState(domTheme || lsTheme || "dark");
479
+ }, []);
480
+ const persist = React4.useCallback((next) => {
481
+ if (typeof window === "undefined") return;
482
+ const merged = { ...readStored(), ...next };
483
+ window.localStorage.setItem(PREFS_KEY, JSON.stringify(merged));
484
+ }, []);
485
+ const setBackground = React4.useCallback(
486
+ (b) => {
487
+ setBackgroundState(b);
488
+ persist({ background: b });
489
+ },
490
+ [persist]
491
+ );
492
+ const setLogo = React4.useCallback(
493
+ (id) => {
494
+ setLogoState(id);
495
+ persist({ logo: id });
496
+ },
497
+ [persist]
498
+ );
499
+ const setTheme = React4.useCallback((t) => {
500
+ setThemeState(t);
501
+ if (typeof document !== "undefined") {
502
+ document.documentElement.dataset.theme = t;
503
+ try {
504
+ window.localStorage.setItem(THEME_KEY, t);
505
+ } catch {
506
+ }
507
+ }
508
+ }, []);
509
+ const value = React4.useMemo(
510
+ () => ({ background, setBackground, logo, setLogo, theme, setTheme }),
511
+ [background, setBackground, logo, setLogo, theme, setTheme]
512
+ );
513
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(Ctx.Provider, { value, children });
514
+ }
515
+ function useFxPreferences() {
516
+ const ctx = React4.useContext(Ctx);
517
+ if (!ctx) throw new Error("useFxPreferences must be used within <FxPreferencesProvider>");
518
+ return ctx;
519
+ }
520
+ function useOptionalFxPreferences() {
521
+ return React4.useContext(Ctx);
522
+ }
523
+
524
+ // src/fx/dynamic-background.tsx
525
+ var import_jsx_runtime8 = require("react/jsx-runtime");
526
+ function DynamicBackground({
527
+ variant,
528
+ noise = false,
529
+ aurora,
530
+ mesh,
531
+ grid,
532
+ spotlight,
533
+ particles,
534
+ className
535
+ }) {
536
+ const prefs = useOptionalFxPreferences();
537
+ const active = variant ?? prefs?.background ?? "none";
538
+ let bg = null;
539
+ switch (active) {
540
+ case "aurora":
541
+ bg = /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(AuroraBackground, { ...aurora });
542
+ break;
543
+ case "mesh":
544
+ bg = /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(MeshGradient, { ...mesh });
545
+ break;
546
+ case "grid":
547
+ bg = /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(GridBackground, { ...grid });
548
+ break;
549
+ case "spotlight":
550
+ bg = /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SpotlightBackground, { ...spotlight });
551
+ break;
552
+ case "particles":
553
+ bg = /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ParticleField, { ...particles });
554
+ break;
555
+ case "none":
556
+ default:
557
+ bg = null;
558
+ }
559
+ if (!bg && !noise) return null;
560
+ return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { "aria-hidden": true, className: className ?? "pointer-events-none absolute inset-0 overflow-hidden", children: [
561
+ bg,
562
+ noise && /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(NoiseOverlay, {})
563
+ ] });
564
+ }
565
+
566
+ // src/fx/spotlight-card.tsx
567
+ var React5 = __toESM(require("react"));
568
+ var import_jsx_runtime9 = require("react/jsx-runtime");
569
+ function SpotlightCard({
570
+ radius = 320,
571
+ intensity = 0.12,
572
+ borderGlow = true,
573
+ className,
574
+ children,
575
+ style,
576
+ ...rest
577
+ }) {
578
+ const ref = React5.useRef(null);
579
+ const frame = React5.useRef(null);
580
+ const onMove = React5.useCallback((e) => {
581
+ const el = ref.current;
582
+ if (!el || frame.current != null) return;
583
+ const cx = e.clientX;
584
+ const cy = e.clientY;
585
+ frame.current = requestAnimationFrame(() => {
586
+ frame.current = null;
587
+ const rect = el.getBoundingClientRect();
588
+ el.style.setProperty("--wmm-x", `${cx - rect.left}px`);
589
+ el.style.setProperty("--wmm-y", `${cy - rect.top}px`);
590
+ });
591
+ }, []);
592
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(
593
+ "div",
594
+ {
595
+ ref,
596
+ onPointerMove: onMove,
597
+ className: cn(
598
+ "group/spot relative overflow-hidden rounded-2xl border border-border bg-card",
599
+ className
600
+ ),
601
+ style,
602
+ ...rest,
603
+ children: [
604
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
605
+ "div",
606
+ {
607
+ "aria-hidden": true,
608
+ className: "pointer-events-none absolute inset-0 opacity-0 transition-opacity duration-300 group-hover/spot:opacity-100",
609
+ style: {
610
+ background: `radial-gradient(${radius}px circle at var(--wmm-x, 50%) var(--wmm-y, 50%), color-mix(in srgb, var(--primary) ${Math.round(
611
+ intensity * 100
612
+ )}%, transparent), transparent 70%)`
613
+ }
614
+ }
615
+ ),
616
+ borderGlow && /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
617
+ "div",
618
+ {
619
+ "aria-hidden": true,
620
+ className: "pointer-events-none absolute inset-0 rounded-2xl opacity-0 transition-opacity duration-300 group-hover/spot:opacity-100",
621
+ style: {
622
+ background: `radial-gradient(${radius}px circle at var(--wmm-x, 50%) var(--wmm-y, 50%), color-mix(in srgb, var(--primary) 40%, transparent), transparent 60%)`,
623
+ WebkitMask: "linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0)",
624
+ WebkitMaskComposite: "xor",
625
+ maskComposite: "exclude",
626
+ padding: 1
627
+ }
628
+ }
629
+ ),
630
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { className: "relative", children })
631
+ ]
632
+ }
633
+ );
634
+ }
635
+
636
+ // src/fx/tilt-card.tsx
637
+ var React6 = __toESM(require("react"));
638
+ var import_framer_motion = require("framer-motion");
639
+ var import_jsx_runtime10 = require("react/jsx-runtime");
640
+ function TiltCard({
641
+ max = 10,
642
+ lift = 0,
643
+ glare = true,
644
+ className,
645
+ children,
646
+ style,
647
+ ...rest
648
+ }) {
649
+ const ref = React6.useRef(null);
650
+ const px = (0, import_framer_motion.useMotionValue)(0.5);
651
+ const py = (0, import_framer_motion.useMotionValue)(0.5);
652
+ const sx = (0, import_framer_motion.useSpring)(px, { stiffness: 220, damping: 18 });
653
+ const sy = (0, import_framer_motion.useSpring)(py, { stiffness: 220, damping: 18 });
654
+ const rotateX = (0, import_framer_motion.useTransform)(sy, [0, 1], [max, -max]);
655
+ const rotateY = (0, import_framer_motion.useTransform)(sx, [0, 1], [-max, max]);
656
+ const glareX = (0, import_framer_motion.useTransform)(sx, [0, 1], ["0%", "100%"]);
657
+ const glareY = (0, import_framer_motion.useTransform)(sy, [0, 1], ["0%", "100%"]);
658
+ const glareBg = import_framer_motion.useMotionTemplate`radial-gradient(circle at ${glareX} ${glareY}, color-mix(in srgb, var(--foreground) 18%, transparent), transparent 60%)`;
659
+ const onMove = (e) => {
660
+ const el = ref.current;
661
+ if (!el) return;
662
+ const rect = el.getBoundingClientRect();
663
+ px.set((e.clientX - rect.left) / rect.width);
664
+ py.set((e.clientY - rect.top) / rect.height);
665
+ };
666
+ const onLeave = () => {
667
+ px.set(0.5);
668
+ py.set(0.5);
669
+ };
670
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
671
+ import_framer_motion.motion.div,
672
+ {
673
+ ref,
674
+ onPointerMove: onMove,
675
+ onPointerLeave: onLeave,
676
+ style: { perspective: 900, ...style },
677
+ className: cn("relative", className),
678
+ ...rest,
679
+ children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
680
+ import_framer_motion.motion.div,
681
+ {
682
+ style: { rotateX, rotateY, transformStyle: "preserve-3d", translateZ: lift },
683
+ className: "relative h-full w-full rounded-2xl",
684
+ children: [
685
+ children,
686
+ glare && /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
687
+ import_framer_motion.motion.div,
688
+ {
689
+ "aria-hidden": true,
690
+ className: "pointer-events-none absolute inset-0 rounded-2xl",
691
+ style: { background: glareBg }
692
+ }
693
+ )
694
+ ]
695
+ }
696
+ )
697
+ }
698
+ );
699
+ }
700
+
701
+ // src/fx/magnetic.tsx
702
+ var React7 = __toESM(require("react"));
703
+ var import_framer_motion2 = require("framer-motion");
704
+ var import_jsx_runtime11 = require("react/jsx-runtime");
705
+ function Magnetic({ strength = 0.35, radius = 120, className, children }) {
706
+ const ref = React7.useRef(null);
707
+ const x = (0, import_framer_motion2.useMotionValue)(0);
708
+ const y = (0, import_framer_motion2.useMotionValue)(0);
709
+ const sx = (0, import_framer_motion2.useSpring)(x, { stiffness: 260, damping: 16, mass: 0.4 });
710
+ const sy = (0, import_framer_motion2.useSpring)(y, { stiffness: 260, damping: 16, mass: 0.4 });
711
+ React7.useEffect(() => {
712
+ const el = ref.current;
713
+ if (!el) return;
714
+ const onMove = (e) => {
715
+ const rect = el.getBoundingClientRect();
716
+ const cx = rect.left + rect.width / 2;
717
+ const cy = rect.top + rect.height / 2;
718
+ const dx = e.clientX - cx;
719
+ const dy = e.clientY - cy;
720
+ const dist = Math.hypot(dx, dy);
721
+ if (dist < radius) {
722
+ x.set(dx * strength);
723
+ y.set(dy * strength);
724
+ } else {
725
+ x.set(0);
726
+ y.set(0);
727
+ }
728
+ };
729
+ window.addEventListener("pointermove", onMove);
730
+ return () => window.removeEventListener("pointermove", onMove);
731
+ }, [strength, radius, x, y]);
732
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_framer_motion2.motion.div, { ref, style: { x: sx, y: sy }, className: cn("inline-flex", className), children });
733
+ }
734
+
735
+ // src/fx/border-beam.tsx
736
+ var import_jsx_runtime12 = require("react/jsx-runtime");
737
+ function BorderBeam({
738
+ size = 1.5,
739
+ speed = 6,
740
+ radius = 16,
741
+ color = "var(--primary)",
742
+ className
743
+ }) {
744
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
745
+ "div",
746
+ {
747
+ "aria-hidden": true,
748
+ className: cn("pointer-events-none absolute inset-0 overflow-hidden", className),
749
+ style: { borderRadius: radius },
750
+ children: [
751
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
752
+ "div",
753
+ {
754
+ "data-wmm-fx": true,
755
+ className: "absolute left-1/2 top-1/2 aspect-square w-[140%]",
756
+ style: {
757
+ background: `conic-gradient(from 0deg, transparent 0deg, ${color} 60deg, transparent 120deg)`,
758
+ animation: `wmm-border-spin ${speed}s linear infinite`,
759
+ transform: "translate(-50%, -50%)"
760
+ }
761
+ }
762
+ ),
763
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
764
+ "div",
765
+ {
766
+ className: "absolute bg-card",
767
+ style: { inset: size, borderRadius: Math.max(0, radius - size) }
768
+ }
769
+ )
770
+ ]
771
+ }
772
+ );
773
+ }
774
+
775
+ // src/fx/logo-3d.tsx
776
+ var React8 = __toESM(require("react"));
777
+ var import_framer_motion3 = require("framer-motion");
778
+ var import_jsx_runtime13 = require("react/jsx-runtime");
779
+ function Logo3D({
780
+ children,
781
+ max = 18,
782
+ idle = true,
783
+ shadow = true,
784
+ sheen = true,
785
+ className
786
+ }) {
787
+ const ref = React8.useRef(null);
788
+ const px = (0, import_framer_motion3.useMotionValue)(0.5);
789
+ const py = (0, import_framer_motion3.useMotionValue)(0.5);
790
+ const sx = (0, import_framer_motion3.useSpring)(px, { stiffness: 150, damping: 15 });
791
+ const sy = (0, import_framer_motion3.useSpring)(py, { stiffness: 150, damping: 15 });
792
+ const [hovering, setHovering] = React8.useState(false);
793
+ const rotateX = (0, import_framer_motion3.useTransform)(sy, [0, 1], [max, -max]);
794
+ const rotateY = (0, import_framer_motion3.useTransform)(sx, [0, 1], [-max, max]);
795
+ const sheenX = (0, import_framer_motion3.useTransform)(sx, [0, 1], ["0%", "100%"]);
796
+ const sheenY = (0, import_framer_motion3.useTransform)(sy, [0, 1], ["0%", "100%"]);
797
+ const sheenBg = import_framer_motion3.useMotionTemplate`radial-gradient(circle at ${sheenX} ${sheenY}, color-mix(in srgb, var(--foreground) 35%, transparent), transparent 55%)`;
798
+ const onMove = (e) => {
799
+ const el = ref.current;
800
+ if (!el) return;
801
+ const rect = el.getBoundingClientRect();
802
+ px.set((e.clientX - rect.left) / rect.width);
803
+ py.set((e.clientY - rect.top) / rect.height);
804
+ };
805
+ const onLeave = () => {
806
+ setHovering(false);
807
+ px.set(0.5);
808
+ py.set(0.5);
809
+ };
810
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
811
+ "div",
812
+ {
813
+ ref,
814
+ onPointerMove: onMove,
815
+ onPointerEnter: () => setHovering(true),
816
+ onPointerLeave: onLeave,
817
+ className: cn("relative inline-flex select-none", className),
818
+ style: { perspective: 800 },
819
+ children: [
820
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
821
+ import_framer_motion3.motion.div,
822
+ {
823
+ "data-wmm-fx": idle && !hovering ? "" : void 0,
824
+ style: { rotateX, rotateY, transformStyle: "preserve-3d" },
825
+ className: "relative",
826
+ animate: idle && !hovering ? { y: [0, -8, 0] } : { y: 0 },
827
+ transition: idle && !hovering ? { duration: 5, repeat: Infinity, ease: "easeInOut" } : { duration: 0.3 },
828
+ children: [
829
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { style: { transform: "translateZ(40px)" }, children }),
830
+ sheen && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
831
+ import_framer_motion3.motion.div,
832
+ {
833
+ "aria-hidden": true,
834
+ className: "pointer-events-none absolute inset-0 mix-blend-overlay",
835
+ style: { background: sheenBg, transform: "translateZ(41px)" }
836
+ }
837
+ )
838
+ ]
839
+ }
840
+ ),
841
+ shadow && /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
842
+ "div",
843
+ {
844
+ "aria-hidden": true,
845
+ className: "pointer-events-none absolute -bottom-4 left-1/2 h-4 w-2/3 -translate-x-1/2 rounded-[50%]",
846
+ style: { background: "color-mix(in srgb, var(--foreground) 30%, transparent)", filter: "blur(12px)" }
847
+ }
848
+ )
849
+ ]
850
+ }
851
+ );
852
+ }
853
+
854
+ // src/fx/text-shimmer.tsx
855
+ var React9 = __toESM(require("react"));
856
+ function TextShimmer({ children, className, duration = 2.5, as = "span" }) {
857
+ return React9.createElement(
858
+ as,
859
+ {
860
+ "data-wmm-fx": true,
861
+ className: cn("inline-block bg-clip-text text-transparent", className),
862
+ style: {
863
+ backgroundImage: "linear-gradient(90deg, var(--muted-foreground) 0%, var(--foreground) 50%, var(--muted-foreground) 100%)",
864
+ backgroundSize: "200% 100%",
865
+ animation: `wmm-shimmer ${duration}s linear infinite`
866
+ }
867
+ },
868
+ children
869
+ );
870
+ }
871
+
872
+ // src/fx/dock.tsx
873
+ var React10 = __toESM(require("react"));
874
+ var import_framer_motion4 = require("framer-motion");
875
+ var import_jsx_runtime14 = require("react/jsx-runtime");
876
+ var MouseCtx = React10.createContext(null);
877
+ function Dock({ children, className, maxSize = 64, baseSize = 44 }) {
878
+ const mouseX = (0, import_framer_motion4.useMotionValue)(Infinity);
879
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(MouseCtx.Provider, { value: mouseX, children: /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
880
+ "div",
881
+ {
882
+ "data-wmm-fx": true,
883
+ onMouseMove: (e) => mouseX.set(e.pageX),
884
+ onMouseLeave: () => mouseX.set(Infinity),
885
+ className: cn(
886
+ "mx-auto flex items-end gap-3 rounded-2xl border border-border bg-card/80 px-3 pb-2 pt-2 backdrop-blur",
887
+ className
888
+ ),
889
+ style: { height: maxSize + 16 },
890
+ children: React10.Children.map(children, (child) => /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(DockSlot, { maxSize, baseSize, children: child }))
891
+ }
892
+ ) });
893
+ }
894
+ function DockSlot({ children, maxSize, baseSize }) {
895
+ const ref = React10.useRef(null);
896
+ const mouseX = React10.useContext(MouseCtx);
897
+ const distance = (0, import_framer_motion4.useTransform)(mouseX, (val) => {
898
+ const b = ref.current?.getBoundingClientRect() ?? { x: 0, width: baseSize };
899
+ return val - b.x - b.width / 2;
900
+ });
901
+ const sizeRaw = (0, import_framer_motion4.useTransform)(distance, [-150, 0, 150], [baseSize, maxSize, baseSize]);
902
+ const size = (0, import_framer_motion4.useSpring)(sizeRaw, { mass: 0.1, stiffness: 150, damping: 12 });
903
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
904
+ import_framer_motion4.motion.div,
905
+ {
906
+ ref,
907
+ style: { width: size, height: size },
908
+ className: "flex items-center justify-center rounded-xl bg-muted text-foreground",
909
+ children
910
+ }
911
+ );
912
+ }
913
+
914
+ // src/fx/design-studio.tsx
915
+ var React11 = __toESM(require("react"));
916
+ var import_framer_motion5 = require("framer-motion");
917
+ var import_jsx_runtime15 = require("react/jsx-runtime");
918
+ var THEMES = [
919
+ { id: "light", label: "Light" },
920
+ { id: "dark", label: "Dark" },
921
+ { id: "wmm", label: "WMM" }
922
+ ];
923
+ var BG_LABEL = {
924
+ none: "None",
925
+ aurora: "Aurora",
926
+ mesh: "Mesh",
927
+ grid: "Grid",
928
+ spotlight: "Spotlight",
929
+ particles: "Particles"
930
+ };
931
+ var POSITION = {
932
+ "bottom-right": "bottom-5 right-5 origin-bottom-right",
933
+ "bottom-left": "bottom-5 left-5 origin-bottom-left",
934
+ "top-right": "top-5 right-5 origin-top-right",
935
+ "top-left": "top-5 left-5 origin-top-left"
936
+ };
937
+ function SparkleIcon() {
938
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", "aria-hidden": true, children: [
939
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
940
+ "path",
941
+ {
942
+ d: "M12 3l1.8 4.9L18.7 9 13.8 10.8 12 15.6 10.2 10.8 5.3 9l4.9-1.1L12 3z",
943
+ fill: "currentColor"
944
+ }
945
+ ),
946
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("path", { d: "M18.5 14.5l.7 1.9 1.9.7-1.9.7-.7 1.9-.7-1.9-1.9-.7 1.9-.7.7-1.9z", fill: "currentColor" })
947
+ ] });
948
+ }
949
+ function CloseIcon() {
950
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", "aria-hidden": true, children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("path", { d: "M6 6l12 12M18 6L6 18", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round" }) });
951
+ }
952
+ function BgSwatch({ variant }) {
953
+ const common = "absolute inset-0";
954
+ switch (variant) {
955
+ case "aurora":
956
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
957
+ "div",
958
+ {
959
+ className: common,
960
+ style: {
961
+ background: "radial-gradient(circle at 30% 30%, color-mix(in srgb, var(--primary) 80%, transparent), transparent 60%), radial-gradient(circle at 70% 70%, color-mix(in srgb, var(--accent, var(--primary)) 70%, transparent), transparent 60%)",
962
+ filter: "blur(4px)"
963
+ }
964
+ }
965
+ );
966
+ case "mesh":
967
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
968
+ "div",
969
+ {
970
+ className: common,
971
+ style: {
972
+ background: "radial-gradient(at 20% 30%, color-mix(in srgb, var(--primary) 70%, transparent), transparent 50%), radial-gradient(at 80% 70%, color-mix(in srgb, var(--accent, var(--primary)) 60%, transparent), transparent 50%)"
973
+ }
974
+ }
975
+ );
976
+ case "grid":
977
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
978
+ "div",
979
+ {
980
+ className: common,
981
+ style: {
982
+ backgroundImage: "radial-gradient(color-mix(in srgb, var(--foreground) 35%, transparent) 1px, transparent 1px)",
983
+ backgroundSize: "8px 8px"
984
+ }
985
+ }
986
+ );
987
+ case "spotlight":
988
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
989
+ "div",
990
+ {
991
+ className: common,
992
+ style: {
993
+ background: "radial-gradient(circle at 50% 40%, color-mix(in srgb, var(--primary) 60%, transparent), transparent 70%)"
994
+ }
995
+ }
996
+ );
997
+ case "particles":
998
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: common, children: [
999
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "absolute left-1/4 top-1/3 h-1 w-1 rounded-full bg-primary" }),
1000
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "absolute left-2/3 top-1/4 h-1 w-1 rounded-full bg-primary" }),
1001
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "absolute left-1/2 top-2/3 h-1 w-1 rounded-full bg-primary" }),
1002
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "absolute left-1/3 top-3/4 h-px w-1/3 rotate-12 bg-primary/40" })
1003
+ ] });
1004
+ case "none":
1005
+ default:
1006
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: cn(common, "bg-muted/40") });
1007
+ }
1008
+ }
1009
+ function DesignStudio({
1010
+ position = "bottom-right",
1011
+ title = "Design Studio",
1012
+ showThemes = true,
1013
+ showBackgrounds = true,
1014
+ logos,
1015
+ defaultOpen = false,
1016
+ className
1017
+ }) {
1018
+ const { background, setBackground, theme, setTheme, logo, setLogo } = useFxPreferences();
1019
+ const [open, setOpen] = React11.useState(defaultOpen);
1020
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: cn("fixed z-[1400]", POSITION[position], className), children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_framer_motion5.AnimatePresence, { mode: "popLayout", children: open ? /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
1021
+ import_framer_motion5.motion.div,
1022
+ {
1023
+ initial: { opacity: 0, scale: 0.9, y: 8 },
1024
+ animate: { opacity: 1, scale: 1, y: 0 },
1025
+ exit: { opacity: 0, scale: 0.9, y: 8 },
1026
+ transition: { duration: 0.18, ease: [0.16, 1, 0.3, 1] },
1027
+ className: "w-72 rounded-2xl border border-border bg-card/95 p-4 text-foreground shadow-2xl backdrop-blur-xl",
1028
+ style: { boxShadow: "var(--shadow-dialog, 0 20px 60px rgba(0,0,0,0.4))" },
1029
+ children: [
1030
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "mb-3 flex items-center justify-between", children: [
1031
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "flex items-center gap-2 text-sm font-semibold", children: [
1032
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "text-primary", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(SparkleIcon, {}) }),
1033
+ title
1034
+ ] }),
1035
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1036
+ "button",
1037
+ {
1038
+ onClick: () => setOpen(false),
1039
+ "aria-label": "Close design studio",
1040
+ className: "rounded-md p-1 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",
1041
+ children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(CloseIcon, {})
1042
+ }
1043
+ )
1044
+ ] }),
1045
+ showThemes && /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("section", { className: "mb-4", children: [
1046
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { className: "mb-1.5 text-[11px] font-medium uppercase tracking-wider text-muted-foreground", children: "Theme" }),
1047
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "grid grid-cols-3 gap-1.5", children: THEMES.map((t) => /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1048
+ "button",
1049
+ {
1050
+ onClick: () => setTheme(t.id),
1051
+ className: cn(
1052
+ "rounded-lg border px-2 py-1.5 text-xs font-medium transition-colors",
1053
+ theme === t.id ? "border-primary bg-primary text-primary-foreground" : "border-border text-muted-foreground hover:border-primary/40 hover:text-foreground"
1054
+ ),
1055
+ children: t.label
1056
+ },
1057
+ t.id
1058
+ )) })
1059
+ ] }),
1060
+ showBackgrounds && /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("section", { className: "mb-1", children: [
1061
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { className: "mb-1.5 text-[11px] font-medium uppercase tracking-wider text-muted-foreground", children: "Background" }),
1062
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "grid grid-cols-3 gap-1.5", children: BACKGROUND_VARIANTS.map((v) => /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
1063
+ "button",
1064
+ {
1065
+ onClick: () => setBackground(v),
1066
+ className: cn(
1067
+ "group relative flex h-14 flex-col overflow-hidden rounded-lg border text-left transition-colors",
1068
+ background === v ? "border-primary ring-1 ring-primary" : "border-border hover:border-primary/40"
1069
+ ),
1070
+ children: [
1071
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "relative flex-1 overflow-hidden bg-background", children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(BgSwatch, { variant: v }) }),
1072
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1073
+ "span",
1074
+ {
1075
+ className: cn(
1076
+ "px-1.5 py-0.5 text-[10px] font-medium",
1077
+ background === v ? "bg-primary text-primary-foreground" : "bg-card text-muted-foreground"
1078
+ ),
1079
+ children: BG_LABEL[v]
1080
+ }
1081
+ )
1082
+ ]
1083
+ },
1084
+ v
1085
+ )) })
1086
+ ] }),
1087
+ logos && logos.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("section", { className: "mt-4", children: [
1088
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("p", { className: "mb-1.5 text-[11px] font-medium uppercase tracking-wider text-muted-foreground", children: "Logo" }),
1089
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "flex flex-wrap gap-2", children: logos.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1090
+ "button",
1091
+ {
1092
+ onClick: () => setLogo(opt.id),
1093
+ title: opt.label,
1094
+ className: cn(
1095
+ "flex h-16 w-16 items-center justify-center overflow-hidden rounded-lg border bg-background p-2 transition-colors",
1096
+ logo === opt.id ? "border-primary ring-1 ring-primary" : "border-border hover:border-primary/40"
1097
+ ),
1098
+ children: opt.node
1099
+ },
1100
+ opt.id
1101
+ )) })
1102
+ ] })
1103
+ ]
1104
+ },
1105
+ "panel"
1106
+ ) : /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
1107
+ import_framer_motion5.motion.button,
1108
+ {
1109
+ initial: { opacity: 0, scale: 0.8 },
1110
+ animate: { opacity: 1, scale: 1 },
1111
+ exit: { opacity: 0, scale: 0.8 },
1112
+ onClick: () => setOpen(true),
1113
+ "aria-label": "Open design studio",
1114
+ className: "flex h-12 w-12 items-center justify-center rounded-full border border-border bg-card text-primary shadow-xl backdrop-blur-xl transition-transform hover:scale-105",
1115
+ style: { boxShadow: "var(--glow-primary, 0 0 40px rgba(0,0,0,0.2))" },
1116
+ children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(SparkleIcon, {})
1117
+ },
1118
+ "fab"
1119
+ ) }) });
1120
+ }
1121
+ // Annotate the CommonJS export names for ESM import in node:
1122
+ 0 && (module.exports = {
1123
+ AuroraBackground,
1124
+ BACKGROUND_VARIANTS,
1125
+ BorderBeam,
1126
+ DesignStudio,
1127
+ Dock,
1128
+ DynamicBackground,
1129
+ FxPreferencesProvider,
1130
+ GridBackground,
1131
+ Logo3D,
1132
+ Magnetic,
1133
+ MeshGradient,
1134
+ NoiseOverlay,
1135
+ ParticleField,
1136
+ SpotlightBackground,
1137
+ SpotlightCard,
1138
+ TextShimmer,
1139
+ TiltCard,
1140
+ useFxPreferences,
1141
+ useOptionalFxPreferences
1142
+ });