@medialane/ui 0.4.4 → 0.5.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/components/nav-command-menu.cjs +222 -0
- package/dist/components/nav-command-menu.cjs.map +1 -0
- package/dist/components/nav-command-menu.d.cts +34 -0
- package/dist/components/nav-command-menu.d.ts +34 -0
- package/dist/components/nav-command-menu.js +187 -0
- package/dist/components/nav-command-menu.js.map +1 -0
- package/dist/index.cjs +7 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +4 -1
- package/dist/index.js.map +1 -1
- package/dist/medialane.css +16 -0
- package/dist/preset/tailwind.cjs +1 -3
- package/dist/preset/tailwind.cjs.map +1 -1
- package/dist/preset/tailwind.d.cts +5 -0
- package/dist/preset/tailwind.d.ts +5 -0
- package/dist/preset/tailwind.js +1 -2
- package/dist/preset/tailwind.js.map +1 -1
- package/package.json +4 -2
|
@@ -0,0 +1,222 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
var __create = Object.create;
|
|
4
|
+
var __defProp = Object.defineProperty;
|
|
5
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
6
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
7
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
8
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
9
|
+
var __export = (target, all) => {
|
|
10
|
+
for (var name in all)
|
|
11
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
12
|
+
};
|
|
13
|
+
var __copyProps = (to, from, except, desc) => {
|
|
14
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
15
|
+
for (let key of __getOwnPropNames(from))
|
|
16
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
17
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
18
|
+
}
|
|
19
|
+
return to;
|
|
20
|
+
};
|
|
21
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
22
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
23
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
24
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
25
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
26
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
27
|
+
mod
|
|
28
|
+
));
|
|
29
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
30
|
+
var nav_command_menu_exports = {};
|
|
31
|
+
__export(nav_command_menu_exports, {
|
|
32
|
+
NavCommandMenu: () => NavCommandMenu,
|
|
33
|
+
useNavCommandMenu: () => useNavCommandMenu
|
|
34
|
+
});
|
|
35
|
+
module.exports = __toCommonJS(nav_command_menu_exports);
|
|
36
|
+
var import_jsx_runtime = require("react/jsx-runtime");
|
|
37
|
+
var React = __toESM(require("react"), 1);
|
|
38
|
+
var import_cmdk = require("cmdk");
|
|
39
|
+
var import_navigation = require("next/navigation");
|
|
40
|
+
var import_lucide_react = require("lucide-react");
|
|
41
|
+
var import_framer_motion = require("framer-motion");
|
|
42
|
+
var import_cn = require("../utils/cn.js");
|
|
43
|
+
const ML_NAV_OPEN = "ml:nav-open";
|
|
44
|
+
const ML_NAV_CLOSE = "ml:nav-close";
|
|
45
|
+
function useNavCommandMenu() {
|
|
46
|
+
return {
|
|
47
|
+
open: () => document.dispatchEvent(new CustomEvent(ML_NAV_OPEN)),
|
|
48
|
+
close: () => document.dispatchEvent(new CustomEvent(ML_NAV_CLOSE))
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
function NavCommandMenu({ commands, trigger }) {
|
|
52
|
+
const [open, setOpen] = React.useState(false);
|
|
53
|
+
const router = (0, import_navigation.useRouter)();
|
|
54
|
+
React.useEffect(() => {
|
|
55
|
+
const onKey = (e) => {
|
|
56
|
+
if (e.key === "k" && (e.metaKey || e.ctrlKey)) {
|
|
57
|
+
e.preventDefault();
|
|
58
|
+
setOpen((prev) => !prev);
|
|
59
|
+
}
|
|
60
|
+
if (e.key === "Escape") setOpen(false);
|
|
61
|
+
};
|
|
62
|
+
const onOpen = () => setOpen(true);
|
|
63
|
+
const onClose = () => setOpen(false);
|
|
64
|
+
document.addEventListener("keydown", onKey);
|
|
65
|
+
document.addEventListener(ML_NAV_OPEN, onOpen);
|
|
66
|
+
document.addEventListener(ML_NAV_CLOSE, onClose);
|
|
67
|
+
return () => {
|
|
68
|
+
document.removeEventListener("keydown", onKey);
|
|
69
|
+
document.removeEventListener(ML_NAV_OPEN, onOpen);
|
|
70
|
+
document.removeEventListener(ML_NAV_CLOSE, onClose);
|
|
71
|
+
};
|
|
72
|
+
}, []);
|
|
73
|
+
const runCommand = React.useCallback(
|
|
74
|
+
(cmd) => {
|
|
75
|
+
setOpen(false);
|
|
76
|
+
if (cmd.href) router.push(cmd.href);
|
|
77
|
+
else cmd.action?.();
|
|
78
|
+
},
|
|
79
|
+
[router]
|
|
80
|
+
);
|
|
81
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
|
|
82
|
+
trigger,
|
|
83
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_framer_motion.AnimatePresence, { children: open && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
|
|
84
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
85
|
+
import_framer_motion.motion.div,
|
|
86
|
+
{
|
|
87
|
+
className: "nav-canvas-aurora",
|
|
88
|
+
initial: { opacity: 0 },
|
|
89
|
+
animate: { opacity: 1 },
|
|
90
|
+
exit: { opacity: 0 },
|
|
91
|
+
transition: { duration: 0.2 },
|
|
92
|
+
children: [
|
|
93
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
94
|
+
"div",
|
|
95
|
+
{
|
|
96
|
+
className: "aurora-purple animate-blob w-[60vw] h-[60vw] -top-[10vw] -left-[10vw]",
|
|
97
|
+
style: { opacity: 0.25 }
|
|
98
|
+
}
|
|
99
|
+
),
|
|
100
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
101
|
+
"div",
|
|
102
|
+
{
|
|
103
|
+
className: "aurora-blue animate-blob-slow w-[50vw] h-[50vw] -top-[5vw] -right-[10vw]",
|
|
104
|
+
style: { opacity: 0.2 }
|
|
105
|
+
}
|
|
106
|
+
),
|
|
107
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
108
|
+
"div",
|
|
109
|
+
{
|
|
110
|
+
className: "aurora-rose animate-blob w-[45vw] h-[45vw] bottom-[5vw] -left-[5vw]",
|
|
111
|
+
style: { opacity: 0.15 }
|
|
112
|
+
}
|
|
113
|
+
),
|
|
114
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
115
|
+
"div",
|
|
116
|
+
{
|
|
117
|
+
className: "aurora-orange animate-blob-slow w-[40vw] h-[40vw] -bottom-[5vw] -right-[5vw]",
|
|
118
|
+
style: { opacity: 0.15 }
|
|
119
|
+
}
|
|
120
|
+
)
|
|
121
|
+
]
|
|
122
|
+
}
|
|
123
|
+
),
|
|
124
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
125
|
+
import_framer_motion.motion.div,
|
|
126
|
+
{
|
|
127
|
+
className: "nav-canvas-overlay",
|
|
128
|
+
initial: { opacity: 0 },
|
|
129
|
+
animate: { opacity: 1 },
|
|
130
|
+
exit: { opacity: 0 },
|
|
131
|
+
transition: { duration: 0.15 },
|
|
132
|
+
onClick: () => setOpen(false)
|
|
133
|
+
}
|
|
134
|
+
),
|
|
135
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
136
|
+
import_framer_motion.motion.div,
|
|
137
|
+
{
|
|
138
|
+
className: "fixed inset-0 z-[101] flex items-center justify-center p-4",
|
|
139
|
+
initial: { opacity: 0, scale: 0.97 },
|
|
140
|
+
animate: { opacity: 1, scale: 1 },
|
|
141
|
+
exit: { opacity: 0, scale: 0.97 },
|
|
142
|
+
transition: { duration: 0.15, ease: "easeOut" },
|
|
143
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
144
|
+
"div",
|
|
145
|
+
{
|
|
146
|
+
className: "w-full max-w-lg bg-background/90 border border-border/40 rounded-2xl overflow-hidden shadow-2xl",
|
|
147
|
+
onClick: (e) => e.stopPropagation(),
|
|
148
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_cmdk.Command, { shouldFilter: true, label: "Medialane navigation", children: [
|
|
149
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "flex items-center gap-3 px-4 py-3 border-b border-border/40", children: [
|
|
150
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.Search, { className: "h-4 w-4 text-muted-foreground shrink-0" }),
|
|
151
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
152
|
+
import_cmdk.Command.Input,
|
|
153
|
+
{
|
|
154
|
+
placeholder: "Type a command or search\u2026",
|
|
155
|
+
className: "flex-1 bg-transparent text-sm outline-none placeholder:text-muted-foreground"
|
|
156
|
+
}
|
|
157
|
+
),
|
|
158
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
159
|
+
"button",
|
|
160
|
+
{
|
|
161
|
+
onClick: () => setOpen(false),
|
|
162
|
+
className: "p-1 rounded-md hover:bg-muted/50 transition-colors",
|
|
163
|
+
"aria-label": "Close",
|
|
164
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.X, { className: "h-4 w-4 text-muted-foreground" })
|
|
165
|
+
}
|
|
166
|
+
)
|
|
167
|
+
] }),
|
|
168
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_cmdk.Command.List, { className: "max-h-[60vh] overflow-y-auto p-2", children: [
|
|
169
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_cmdk.Command.Empty, { className: "py-8 text-center text-sm text-muted-foreground", children: "No results found." }),
|
|
170
|
+
commands.map((group, i) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(React.Fragment, { children: [
|
|
171
|
+
i > 0 && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_cmdk.Command.Separator, { className: "my-1 h-px bg-border/40" }),
|
|
172
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(
|
|
173
|
+
import_cmdk.Command.Group,
|
|
174
|
+
{
|
|
175
|
+
heading: group.heading,
|
|
176
|
+
className: (0, import_cn.cn)(
|
|
177
|
+
"[&_[cmdk-group-heading]]:px-2",
|
|
178
|
+
"[&_[cmdk-group-heading]]:py-1.5",
|
|
179
|
+
"[&_[cmdk-group-heading]]:text-xs",
|
|
180
|
+
"[&_[cmdk-group-heading]]:font-medium",
|
|
181
|
+
"[&_[cmdk-group-heading]]:text-muted-foreground"
|
|
182
|
+
),
|
|
183
|
+
children: group.items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
|
|
184
|
+
import_cmdk.Command.Item,
|
|
185
|
+
{
|
|
186
|
+
value: [item.label, ...item.keywords ?? []].join(" "),
|
|
187
|
+
onSelect: () => runCommand(item),
|
|
188
|
+
className: (0, import_cn.cn)(
|
|
189
|
+
"flex items-center gap-3 px-3 py-2.5 rounded-xl text-sm cursor-pointer",
|
|
190
|
+
"transition-colors",
|
|
191
|
+
"aria-selected:bg-muted/60"
|
|
192
|
+
),
|
|
193
|
+
children: [
|
|
194
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(item.icon, { className: "h-4 w-4 text-muted-foreground shrink-0" }),
|
|
195
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "flex-1", children: item.label }),
|
|
196
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.ArrowRight, { className: "h-3.5 w-3.5 text-muted-foreground/40 shrink-0" })
|
|
197
|
+
]
|
|
198
|
+
},
|
|
199
|
+
item.id
|
|
200
|
+
))
|
|
201
|
+
}
|
|
202
|
+
)
|
|
203
|
+
] }, group.heading))
|
|
204
|
+
] }),
|
|
205
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "px-4 py-2.5 border-t border-border/40 flex items-center justify-between", children: [
|
|
206
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "text-[10px] text-muted-foreground/50", children: "medialane" }),
|
|
207
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("kbd", { className: "text-[10px] text-muted-foreground/50 font-mono", children: "\u2318K" })
|
|
208
|
+
] })
|
|
209
|
+
] })
|
|
210
|
+
}
|
|
211
|
+
)
|
|
212
|
+
}
|
|
213
|
+
)
|
|
214
|
+
] }) })
|
|
215
|
+
] });
|
|
216
|
+
}
|
|
217
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
218
|
+
0 && (module.exports = {
|
|
219
|
+
NavCommandMenu,
|
|
220
|
+
useNavCommandMenu
|
|
221
|
+
});
|
|
222
|
+
//# sourceMappingURL=nav-command-menu.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/components/nav-command-menu.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { Command } from \"cmdk\";\nimport { useRouter } from \"next/navigation\";\nimport { Search, X, ArrowRight } from \"lucide-react\";\nimport { AnimatePresence, motion } from \"framer-motion\";\nimport { cn } from \"../utils/cn.js\";\n\n// ── Types ─────────────────────────────────────────────────────────────────────\n\nexport interface NavCommand {\n id: string;\n label: string;\n icon: React.ComponentType<{ className?: string }>;\n href?: string;\n action?: () => void;\n /** Extra search terms beyond the label */\n keywords?: string[];\n}\n\nexport interface NavCommandGroup {\n heading: string;\n items: NavCommand[];\n}\n\ninterface NavCommandMenuProps {\n commands: NavCommandGroup[];\n /**\n * Optional trigger element rendered inline at the component's mount point.\n * For most apps, omit this and call `useNavCommandMenu().open()` from a\n * separate button — that keeps the trigger in the right place in the layout.\n */\n trigger?: React.ReactNode;\n}\n\n// ── Singleton hook ─────────────────────────────────────────────────────────────\n\nconst ML_NAV_OPEN = \"ml:nav-open\";\nconst ML_NAV_CLOSE = \"ml:nav-close\";\n\nexport function useNavCommandMenu() {\n return {\n open: () => document.dispatchEvent(new CustomEvent(ML_NAV_OPEN)),\n close: () => document.dispatchEvent(new CustomEvent(ML_NAV_CLOSE)),\n };\n}\n\n// ── Component ─────────────────────────────────────────────────────────────────\n\nexport function NavCommandMenu({ commands, trigger }: NavCommandMenuProps) {\n const [open, setOpen] = React.useState(false);\n const router = useRouter();\n\n React.useEffect(() => {\n const onKey = (e: KeyboardEvent) => {\n if (e.key === \"k\" && (e.metaKey || e.ctrlKey)) {\n e.preventDefault();\n setOpen((prev) => !prev);\n }\n if (e.key === \"Escape\") setOpen(false);\n };\n const onOpen = () => setOpen(true);\n const onClose = () => setOpen(false);\n\n document.addEventListener(\"keydown\", onKey);\n document.addEventListener(ML_NAV_OPEN, onOpen);\n document.addEventListener(ML_NAV_CLOSE, onClose);\n return () => {\n document.removeEventListener(\"keydown\", onKey);\n document.removeEventListener(ML_NAV_OPEN, onOpen);\n document.removeEventListener(ML_NAV_CLOSE, onClose);\n };\n }, []);\n\n const runCommand = React.useCallback(\n (cmd: NavCommand) => {\n setOpen(false);\n if (cmd.href) router.push(cmd.href);\n else cmd.action?.();\n },\n [router]\n );\n\n return (\n <>\n {trigger}\n\n <AnimatePresence>\n {open && (\n <>\n {/* Aurora blobs — vivid intensity */}\n <motion.div\n className=\"nav-canvas-aurora\"\n initial={{ opacity: 0 }}\n animate={{ opacity: 1 }}\n exit={{ opacity: 0 }}\n transition={{ duration: 0.2 }}\n >\n <div className=\"aurora-purple animate-blob w-[60vw] h-[60vw] -top-[10vw] -left-[10vw]\"\n style={{ opacity: 0.25 }} />\n <div className=\"aurora-blue animate-blob-slow w-[50vw] h-[50vw] -top-[5vw] -right-[10vw]\"\n style={{ opacity: 0.2 }} />\n <div className=\"aurora-rose animate-blob w-[45vw] h-[45vw] bottom-[5vw] -left-[5vw]\"\n style={{ opacity: 0.15 }} />\n <div className=\"aurora-orange animate-blob-slow w-[40vw] h-[40vw] -bottom-[5vw] -right-[5vw]\"\n style={{ opacity: 0.15 }} />\n </motion.div>\n\n {/* Backdrop blur */}\n <motion.div\n className=\"nav-canvas-overlay\"\n initial={{ opacity: 0 }}\n animate={{ opacity: 1 }}\n exit={{ opacity: 0 }}\n transition={{ duration: 0.15 }}\n onClick={() => setOpen(false)}\n />\n\n {/* Command panel */}\n <motion.div\n className=\"fixed inset-0 z-[101] flex items-center justify-center p-4\"\n initial={{ opacity: 0, scale: 0.97 }}\n animate={{ opacity: 1, scale: 1 }}\n exit={{ opacity: 0, scale: 0.97 }}\n transition={{ duration: 0.15, ease: \"easeOut\" }}\n >\n <div\n className=\"w-full max-w-lg bg-background/90 border border-border/40 rounded-2xl overflow-hidden shadow-2xl\"\n onClick={(e) => e.stopPropagation()}\n >\n <Command shouldFilter label=\"Medialane navigation\">\n {/* Search bar */}\n <div className=\"flex items-center gap-3 px-4 py-3 border-b border-border/40\">\n <Search className=\"h-4 w-4 text-muted-foreground shrink-0\" />\n <Command.Input\n placeholder=\"Type a command or search…\"\n className=\"flex-1 bg-transparent text-sm outline-none placeholder:text-muted-foreground\"\n />\n <button\n onClick={() => setOpen(false)}\n className=\"p-1 rounded-md hover:bg-muted/50 transition-colors\"\n aria-label=\"Close\"\n >\n <X className=\"h-4 w-4 text-muted-foreground\" />\n </button>\n </div>\n\n {/* Results */}\n <Command.List className=\"max-h-[60vh] overflow-y-auto p-2\">\n <Command.Empty className=\"py-8 text-center text-sm text-muted-foreground\">\n No results found.\n </Command.Empty>\n\n {commands.map((group, i) => (\n <React.Fragment key={group.heading}>\n {i > 0 && (\n <Command.Separator className=\"my-1 h-px bg-border/40\" />\n )}\n <Command.Group\n heading={group.heading}\n className={cn(\n \"[&_[cmdk-group-heading]]:px-2\",\n \"[&_[cmdk-group-heading]]:py-1.5\",\n \"[&_[cmdk-group-heading]]:text-xs\",\n \"[&_[cmdk-group-heading]]:font-medium\",\n \"[&_[cmdk-group-heading]]:text-muted-foreground\"\n )}\n >\n {group.items.map((item) => (\n <Command.Item\n key={item.id}\n value={[item.label, ...(item.keywords ?? [])].join(\" \")}\n onSelect={() => runCommand(item)}\n className={cn(\n \"flex items-center gap-3 px-3 py-2.5 rounded-xl text-sm cursor-pointer\",\n \"transition-colors\",\n \"aria-selected:bg-muted/60\"\n )}\n >\n <item.icon className=\"h-4 w-4 text-muted-foreground shrink-0\" />\n <span className=\"flex-1\">{item.label}</span>\n <ArrowRight className=\"h-3.5 w-3.5 text-muted-foreground/40 shrink-0\" />\n </Command.Item>\n ))}\n </Command.Group>\n </React.Fragment>\n ))}\n </Command.List>\n\n {/* Footer */}\n <div className=\"px-4 py-2.5 border-t border-border/40 flex items-center justify-between\">\n <span className=\"text-[10px] text-muted-foreground/50\">medialane</span>\n <kbd className=\"text-[10px] text-muted-foreground/50 font-mono\">⌘K</kbd>\n </div>\n </Command>\n </div>\n </motion.div>\n </>\n )}\n </AnimatePresence>\n </>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AA0FU;AAxFV,YAAuB;AACvB,kBAAwB;AACxB,wBAA0B;AAC1B,0BAAsC;AACtC,2BAAwC;AACxC,gBAAmB;AA+BnB,MAAM,cAAe;AACrB,MAAM,eAAe;AAEd,SAAS,oBAAoB;AAClC,SAAO;AAAA,IACL,MAAO,MAAM,SAAS,cAAc,IAAI,YAAY,WAAW,CAAC;AAAA,IAChE,OAAO,MAAM,SAAS,cAAc,IAAI,YAAY,YAAY,CAAC;AAAA,E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AA,iBACF;AAAA;AAAA,UACF;AAAA;AAAA,MACF;AAAA,OACF,GAEJ;AAAA,KACF;AAEJ;","names":[]}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
interface NavCommand {
|
|
5
|
+
id: string;
|
|
6
|
+
label: string;
|
|
7
|
+
icon: React.ComponentType<{
|
|
8
|
+
className?: string;
|
|
9
|
+
}>;
|
|
10
|
+
href?: string;
|
|
11
|
+
action?: () => void;
|
|
12
|
+
/** Extra search terms beyond the label */
|
|
13
|
+
keywords?: string[];
|
|
14
|
+
}
|
|
15
|
+
interface NavCommandGroup {
|
|
16
|
+
heading: string;
|
|
17
|
+
items: NavCommand[];
|
|
18
|
+
}
|
|
19
|
+
interface NavCommandMenuProps {
|
|
20
|
+
commands: NavCommandGroup[];
|
|
21
|
+
/**
|
|
22
|
+
* Optional trigger element rendered inline at the component's mount point.
|
|
23
|
+
* For most apps, omit this and call `useNavCommandMenu().open()` from a
|
|
24
|
+
* separate button — that keeps the trigger in the right place in the layout.
|
|
25
|
+
*/
|
|
26
|
+
trigger?: React.ReactNode;
|
|
27
|
+
}
|
|
28
|
+
declare function useNavCommandMenu(): {
|
|
29
|
+
open: () => boolean;
|
|
30
|
+
close: () => boolean;
|
|
31
|
+
};
|
|
32
|
+
declare function NavCommandMenu({ commands, trigger }: NavCommandMenuProps): react_jsx_runtime.JSX.Element;
|
|
33
|
+
|
|
34
|
+
export { type NavCommand, type NavCommandGroup, NavCommandMenu, useNavCommandMenu };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import * as React from 'react';
|
|
3
|
+
|
|
4
|
+
interface NavCommand {
|
|
5
|
+
id: string;
|
|
6
|
+
label: string;
|
|
7
|
+
icon: React.ComponentType<{
|
|
8
|
+
className?: string;
|
|
9
|
+
}>;
|
|
10
|
+
href?: string;
|
|
11
|
+
action?: () => void;
|
|
12
|
+
/** Extra search terms beyond the label */
|
|
13
|
+
keywords?: string[];
|
|
14
|
+
}
|
|
15
|
+
interface NavCommandGroup {
|
|
16
|
+
heading: string;
|
|
17
|
+
items: NavCommand[];
|
|
18
|
+
}
|
|
19
|
+
interface NavCommandMenuProps {
|
|
20
|
+
commands: NavCommandGroup[];
|
|
21
|
+
/**
|
|
22
|
+
* Optional trigger element rendered inline at the component's mount point.
|
|
23
|
+
* For most apps, omit this and call `useNavCommandMenu().open()` from a
|
|
24
|
+
* separate button — that keeps the trigger in the right place in the layout.
|
|
25
|
+
*/
|
|
26
|
+
trigger?: React.ReactNode;
|
|
27
|
+
}
|
|
28
|
+
declare function useNavCommandMenu(): {
|
|
29
|
+
open: () => boolean;
|
|
30
|
+
close: () => boolean;
|
|
31
|
+
};
|
|
32
|
+
declare function NavCommandMenu({ commands, trigger }: NavCommandMenuProps): react_jsx_runtime.JSX.Element;
|
|
33
|
+
|
|
34
|
+
export { type NavCommand, type NavCommandGroup, NavCommandMenu, useNavCommandMenu };
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
+
import * as React from "react";
|
|
4
|
+
import { Command } from "cmdk";
|
|
5
|
+
import { useRouter } from "next/navigation";
|
|
6
|
+
import { Search, X, ArrowRight } from "lucide-react";
|
|
7
|
+
import { AnimatePresence, motion } from "framer-motion";
|
|
8
|
+
import { cn } from "../utils/cn.js";
|
|
9
|
+
const ML_NAV_OPEN = "ml:nav-open";
|
|
10
|
+
const ML_NAV_CLOSE = "ml:nav-close";
|
|
11
|
+
function useNavCommandMenu() {
|
|
12
|
+
return {
|
|
13
|
+
open: () => document.dispatchEvent(new CustomEvent(ML_NAV_OPEN)),
|
|
14
|
+
close: () => document.dispatchEvent(new CustomEvent(ML_NAV_CLOSE))
|
|
15
|
+
};
|
|
16
|
+
}
|
|
17
|
+
function NavCommandMenu({ commands, trigger }) {
|
|
18
|
+
const [open, setOpen] = React.useState(false);
|
|
19
|
+
const router = useRouter();
|
|
20
|
+
React.useEffect(() => {
|
|
21
|
+
const onKey = (e) => {
|
|
22
|
+
if (e.key === "k" && (e.metaKey || e.ctrlKey)) {
|
|
23
|
+
e.preventDefault();
|
|
24
|
+
setOpen((prev) => !prev);
|
|
25
|
+
}
|
|
26
|
+
if (e.key === "Escape") setOpen(false);
|
|
27
|
+
};
|
|
28
|
+
const onOpen = () => setOpen(true);
|
|
29
|
+
const onClose = () => setOpen(false);
|
|
30
|
+
document.addEventListener("keydown", onKey);
|
|
31
|
+
document.addEventListener(ML_NAV_OPEN, onOpen);
|
|
32
|
+
document.addEventListener(ML_NAV_CLOSE, onClose);
|
|
33
|
+
return () => {
|
|
34
|
+
document.removeEventListener("keydown", onKey);
|
|
35
|
+
document.removeEventListener(ML_NAV_OPEN, onOpen);
|
|
36
|
+
document.removeEventListener(ML_NAV_CLOSE, onClose);
|
|
37
|
+
};
|
|
38
|
+
}, []);
|
|
39
|
+
const runCommand = React.useCallback(
|
|
40
|
+
(cmd) => {
|
|
41
|
+
setOpen(false);
|
|
42
|
+
if (cmd.href) router.push(cmd.href);
|
|
43
|
+
else cmd.action?.();
|
|
44
|
+
},
|
|
45
|
+
[router]
|
|
46
|
+
);
|
|
47
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
48
|
+
trigger,
|
|
49
|
+
/* @__PURE__ */ jsx(AnimatePresence, { children: open && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
50
|
+
/* @__PURE__ */ jsxs(
|
|
51
|
+
motion.div,
|
|
52
|
+
{
|
|
53
|
+
className: "nav-canvas-aurora",
|
|
54
|
+
initial: { opacity: 0 },
|
|
55
|
+
animate: { opacity: 1 },
|
|
56
|
+
exit: { opacity: 0 },
|
|
57
|
+
transition: { duration: 0.2 },
|
|
58
|
+
children: [
|
|
59
|
+
/* @__PURE__ */ jsx(
|
|
60
|
+
"div",
|
|
61
|
+
{
|
|
62
|
+
className: "aurora-purple animate-blob w-[60vw] h-[60vw] -top-[10vw] -left-[10vw]",
|
|
63
|
+
style: { opacity: 0.25 }
|
|
64
|
+
}
|
|
65
|
+
),
|
|
66
|
+
/* @__PURE__ */ jsx(
|
|
67
|
+
"div",
|
|
68
|
+
{
|
|
69
|
+
className: "aurora-blue animate-blob-slow w-[50vw] h-[50vw] -top-[5vw] -right-[10vw]",
|
|
70
|
+
style: { opacity: 0.2 }
|
|
71
|
+
}
|
|
72
|
+
),
|
|
73
|
+
/* @__PURE__ */ jsx(
|
|
74
|
+
"div",
|
|
75
|
+
{
|
|
76
|
+
className: "aurora-rose animate-blob w-[45vw] h-[45vw] bottom-[5vw] -left-[5vw]",
|
|
77
|
+
style: { opacity: 0.15 }
|
|
78
|
+
}
|
|
79
|
+
),
|
|
80
|
+
/* @__PURE__ */ jsx(
|
|
81
|
+
"div",
|
|
82
|
+
{
|
|
83
|
+
className: "aurora-orange animate-blob-slow w-[40vw] h-[40vw] -bottom-[5vw] -right-[5vw]",
|
|
84
|
+
style: { opacity: 0.15 }
|
|
85
|
+
}
|
|
86
|
+
)
|
|
87
|
+
]
|
|
88
|
+
}
|
|
89
|
+
),
|
|
90
|
+
/* @__PURE__ */ jsx(
|
|
91
|
+
motion.div,
|
|
92
|
+
{
|
|
93
|
+
className: "nav-canvas-overlay",
|
|
94
|
+
initial: { opacity: 0 },
|
|
95
|
+
animate: { opacity: 1 },
|
|
96
|
+
exit: { opacity: 0 },
|
|
97
|
+
transition: { duration: 0.15 },
|
|
98
|
+
onClick: () => setOpen(false)
|
|
99
|
+
}
|
|
100
|
+
),
|
|
101
|
+
/* @__PURE__ */ jsx(
|
|
102
|
+
motion.div,
|
|
103
|
+
{
|
|
104
|
+
className: "fixed inset-0 z-[101] flex items-center justify-center p-4",
|
|
105
|
+
initial: { opacity: 0, scale: 0.97 },
|
|
106
|
+
animate: { opacity: 1, scale: 1 },
|
|
107
|
+
exit: { opacity: 0, scale: 0.97 },
|
|
108
|
+
transition: { duration: 0.15, ease: "easeOut" },
|
|
109
|
+
children: /* @__PURE__ */ jsx(
|
|
110
|
+
"div",
|
|
111
|
+
{
|
|
112
|
+
className: "w-full max-w-lg bg-background/90 border border-border/40 rounded-2xl overflow-hidden shadow-2xl",
|
|
113
|
+
onClick: (e) => e.stopPropagation(),
|
|
114
|
+
children: /* @__PURE__ */ jsxs(Command, { shouldFilter: true, label: "Medialane navigation", children: [
|
|
115
|
+
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-3 px-4 py-3 border-b border-border/40", children: [
|
|
116
|
+
/* @__PURE__ */ jsx(Search, { className: "h-4 w-4 text-muted-foreground shrink-0" }),
|
|
117
|
+
/* @__PURE__ */ jsx(
|
|
118
|
+
Command.Input,
|
|
119
|
+
{
|
|
120
|
+
placeholder: "Type a command or search\u2026",
|
|
121
|
+
className: "flex-1 bg-transparent text-sm outline-none placeholder:text-muted-foreground"
|
|
122
|
+
}
|
|
123
|
+
),
|
|
124
|
+
/* @__PURE__ */ jsx(
|
|
125
|
+
"button",
|
|
126
|
+
{
|
|
127
|
+
onClick: () => setOpen(false),
|
|
128
|
+
className: "p-1 rounded-md hover:bg-muted/50 transition-colors",
|
|
129
|
+
"aria-label": "Close",
|
|
130
|
+
children: /* @__PURE__ */ jsx(X, { className: "h-4 w-4 text-muted-foreground" })
|
|
131
|
+
}
|
|
132
|
+
)
|
|
133
|
+
] }),
|
|
134
|
+
/* @__PURE__ */ jsxs(Command.List, { className: "max-h-[60vh] overflow-y-auto p-2", children: [
|
|
135
|
+
/* @__PURE__ */ jsx(Command.Empty, { className: "py-8 text-center text-sm text-muted-foreground", children: "No results found." }),
|
|
136
|
+
commands.map((group, i) => /* @__PURE__ */ jsxs(React.Fragment, { children: [
|
|
137
|
+
i > 0 && /* @__PURE__ */ jsx(Command.Separator, { className: "my-1 h-px bg-border/40" }),
|
|
138
|
+
/* @__PURE__ */ jsx(
|
|
139
|
+
Command.Group,
|
|
140
|
+
{
|
|
141
|
+
heading: group.heading,
|
|
142
|
+
className: cn(
|
|
143
|
+
"[&_[cmdk-group-heading]]:px-2",
|
|
144
|
+
"[&_[cmdk-group-heading]]:py-1.5",
|
|
145
|
+
"[&_[cmdk-group-heading]]:text-xs",
|
|
146
|
+
"[&_[cmdk-group-heading]]:font-medium",
|
|
147
|
+
"[&_[cmdk-group-heading]]:text-muted-foreground"
|
|
148
|
+
),
|
|
149
|
+
children: group.items.map((item) => /* @__PURE__ */ jsxs(
|
|
150
|
+
Command.Item,
|
|
151
|
+
{
|
|
152
|
+
value: [item.label, ...item.keywords ?? []].join(" "),
|
|
153
|
+
onSelect: () => runCommand(item),
|
|
154
|
+
className: cn(
|
|
155
|
+
"flex items-center gap-3 px-3 py-2.5 rounded-xl text-sm cursor-pointer",
|
|
156
|
+
"transition-colors",
|
|
157
|
+
"aria-selected:bg-muted/60"
|
|
158
|
+
),
|
|
159
|
+
children: [
|
|
160
|
+
/* @__PURE__ */ jsx(item.icon, { className: "h-4 w-4 text-muted-foreground shrink-0" }),
|
|
161
|
+
/* @__PURE__ */ jsx("span", { className: "flex-1", children: item.label }),
|
|
162
|
+
/* @__PURE__ */ jsx(ArrowRight, { className: "h-3.5 w-3.5 text-muted-foreground/40 shrink-0" })
|
|
163
|
+
]
|
|
164
|
+
},
|
|
165
|
+
item.id
|
|
166
|
+
))
|
|
167
|
+
}
|
|
168
|
+
)
|
|
169
|
+
] }, group.heading))
|
|
170
|
+
] }),
|
|
171
|
+
/* @__PURE__ */ jsxs("div", { className: "px-4 py-2.5 border-t border-border/40 flex items-center justify-between", children: [
|
|
172
|
+
/* @__PURE__ */ jsx("span", { className: "text-[10px] text-muted-foreground/50", children: "medialane" }),
|
|
173
|
+
/* @__PURE__ */ jsx("kbd", { className: "text-[10px] text-muted-foreground/50 font-mono", children: "\u2318K" })
|
|
174
|
+
] })
|
|
175
|
+
] })
|
|
176
|
+
}
|
|
177
|
+
)
|
|
178
|
+
}
|
|
179
|
+
)
|
|
180
|
+
] }) })
|
|
181
|
+
] });
|
|
182
|
+
}
|
|
183
|
+
export {
|
|
184
|
+
NavCommandMenu,
|
|
185
|
+
useNavCommandMenu
|
|
186
|
+
};
|
|
187
|
+
//# sourceMappingURL=nav-command-menu.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../src/components/nav-command-menu.tsx"],"sourcesContent":["\"use client\";\n\nimport * as React from \"react\";\nimport { Command } from \"cmdk\";\nimport { useRouter } from \"next/navigation\";\nimport { Search, X, ArrowRight } from \"lucide-react\";\nimport { AnimatePresence, motion } from \"framer-motion\";\nimport { cn } from \"../utils/cn.js\";\n\n// ── Types ─────────────────────────────────────────────────────────────────────\n\nexport interface NavCommand {\n id: string;\n label: string;\n icon: React.ComponentType<{ className?: string }>;\n href?: string;\n action?: () => void;\n /** Extra search terms beyond the label */\n keywords?: string[];\n}\n\nexport interface NavCommandGroup {\n heading: string;\n items: NavCommand[];\n}\n\ninterface NavCommandMenuProps {\n commands: NavCommandGroup[];\n /**\n * Optional trigger element rendered inline at the component's mount point.\n * For most apps, omit this and call `useNavCommandMenu().open()` from a\n * separate button — that keeps the trigger in the right place in the layout.\n */\n trigger?: React.ReactNode;\n}\n\n// ── Singleton hook ─────────────────────────────────────────────────────────────\n\nconst ML_NAV_OPEN = \"ml:nav-open\";\nconst ML_NAV_CLOSE = \"ml:nav-close\";\n\nexport function useNavCommandMenu() {\n return {\n open: () => document.dispatchEvent(new CustomEvent(ML_NAV_OPEN)),\n close: () => document.dispatchEvent(new CustomEvent(ML_NAV_CLOSE)),\n };\n}\n\n// ── Component ─────────────────────────────────────────────────────────────────\n\nexport function NavCommandMenu({ commands, trigger }: NavCommandMenuProps) {\n const [open, setOpen] = React.useState(false);\n const router = useRouter();\n\n React.useEffect(() => {\n const onKey = (e: KeyboardEvent) => {\n if (e.key === \"k\" && (e.metaKey || e.ctrlKey)) {\n e.preventDefault();\n setOpen((prev) => !prev);\n }\n if (e.key === \"Escape\") setOpen(false);\n };\n const onOpen = () => setOpen(true);\n const onClose = () => setOpen(false);\n\n document.addEventListener(\"keydown\", onKey);\n document.addEventListener(ML_NAV_OPEN, onOpen);\n document.addEventListener(ML_NAV_CLOSE, onClose);\n return () => {\n document.removeEventListener(\"keydown\", onKey);\n document.removeEventListener(ML_NAV_OPEN, onOpen);\n document.removeEventListener(ML_NAV_CLOSE, onClose);\n };\n }, []);\n\n const runCommand = React.useCallback(\n (cmd: NavCommand) => {\n setOpen(false);\n if (cmd.href) router.push(cmd.href);\n else cmd.action?.();\n },\n [router]\n );\n\n return (\n <>\n {trigger}\n\n <AnimatePresence>\n {open && (\n <>\n {/* Aurora blobs — vivid intensity */}\n <motion.div\n className=\"nav-canvas-aurora\"\n initial={{ opacity: 0 }}\n animate={{ opacity: 1 }}\n exit={{ opacity: 0 }}\n transition={{ duration: 0.2 }}\n >\n <div className=\"aurora-purple animate-blob w-[60vw] h-[60vw] -top-[10vw] -left-[10vw]\"\n style={{ opacity: 0.25 }} />\n <div className=\"aurora-blue animate-blob-slow w-[50vw] h-[50vw] -top-[5vw] -right-[10vw]\"\n style={{ opacity: 0.2 }} />\n <div className=\"aurora-rose animate-blob w-[45vw] h-[45vw] bottom-[5vw] -left-[5vw]\"\n style={{ opacity: 0.15 }} />\n <div className=\"aurora-orange animate-blob-slow w-[40vw] h-[40vw] -bottom-[5vw] -right-[5vw]\"\n style={{ opacity: 0.15 }} />\n </motion.div>\n\n {/* Backdrop blur */}\n <motion.div\n className=\"nav-canvas-overlay\"\n initial={{ opacity: 0 }}\n animate={{ opacity: 1 }}\n exit={{ opacity: 0 }}\n transition={{ duration: 0.15 }}\n onClick={() => setOpen(false)}\n />\n\n {/* Command panel */}\n <motion.div\n className=\"fixed inset-0 z-[101] flex items-center justify-center p-4\"\n initial={{ opacity: 0, scale: 0.97 }}\n animate={{ opacity: 1, scale: 1 }}\n exit={{ opacity: 0, scale: 0.97 }}\n transition={{ duration: 0.15, ease: \"easeOut\" }}\n >\n <div\n className=\"w-full max-w-lg bg-background/90 border border-border/40 rounded-2xl overflow-hidden shadow-2xl\"\n onClick={(e) => e.stopPropagation()}\n >\n <Command shouldFilter label=\"Medialane navigation\">\n {/* Search bar */}\n <div className=\"flex items-center gap-3 px-4 py-3 border-b border-border/40\">\n <Search className=\"h-4 w-4 text-muted-foreground shrink-0\" />\n <Command.Input\n placeholder=\"Type a command or search…\"\n className=\"flex-1 bg-transparent text-sm outline-none placeholder:text-muted-foreground\"\n />\n <button\n onClick={() => setOpen(false)}\n className=\"p-1 rounded-md hover:bg-muted/50 transition-colors\"\n aria-label=\"Close\"\n >\n <X className=\"h-4 w-4 text-muted-foreground\" />\n </button>\n </div>\n\n {/* Results */}\n <Command.List className=\"max-h-[60vh] overflow-y-auto p-2\">\n <Command.Empty className=\"py-8 text-center text-sm text-muted-foreground\">\n No results found.\n </Command.Empty>\n\n {commands.map((group, i) => (\n <React.Fragment key={group.heading}>\n {i > 0 && (\n <Command.Separator className=\"my-1 h-px bg-border/40\" />\n )}\n <Command.Group\n heading={group.heading}\n className={cn(\n \"[&_[cmdk-group-heading]]:px-2\",\n \"[&_[cmdk-group-heading]]:py-1.5\",\n \"[&_[cmdk-group-heading]]:text-xs\",\n \"[&_[cmdk-group-heading]]:font-medium\",\n \"[&_[cmdk-group-heading]]:text-muted-foreground\"\n )}\n >\n {group.items.map((item) => (\n <Command.Item\n key={item.id}\n value={[item.label, ...(item.keywords ?? [])].join(\" \")}\n onSelect={() => runCommand(item)}\n className={cn(\n \"flex items-center gap-3 px-3 py-2.5 rounded-xl text-sm cursor-pointer\",\n \"transition-colors\",\n \"aria-selected:bg-muted/60\"\n )}\n >\n <item.icon className=\"h-4 w-4 text-muted-foreground shrink-0\" />\n <span className=\"flex-1\">{item.label}</span>\n <ArrowRight className=\"h-3.5 w-3.5 text-muted-foreground/40 shrink-0\" />\n </Command.Item>\n ))}\n </Command.Group>\n </React.Fragment>\n ))}\n </Command.List>\n\n {/* Footer */}\n <div className=\"px-4 py-2.5 border-t border-border/40 flex items-center justify-between\">\n <span className=\"text-[10px] text-muted-foreground/50\">medialane</span>\n <kbd className=\"text-[10px] text-muted-foreground/50 font-mono\">⌘K</kbd>\n </div>\n </Command>\n </div>\n </motion.div>\n </>\n )}\n </AnimatePresence>\n </>\n );\n}\n"],"mappings":";AA0FU,mBASI,KAPF,YAFF;AAxFV,YAAY,WAAW;AACvB,SAAS,eAAe;AACxB,SAAS,iBAAiB;AAC1B,SAAS,QAAQ,GAAG,kBAAkB;AACtC,SAAS,iBAAiB,cAAc;AACxC,SAAS,UAAU;AA+BnB,MAAM,cAAe;AACrB,MAAM,eAAe;AAEd,SAAS,oBAAoB;AAClC,SAAO;AAAA,IACL,MAAO,MAAM,SAAS,cAAc,IAAI,YAAY,WAAW,CAAC;AAAA,IAChE,OAAO,MAAM,SAAS,cAAc,IAAI,YAAY,YAAY,CAAC;AAAA,EACnE;AACF;AAIO,SAAS,eAAe,EAAE,UAAU,QAAQ,GAAwB;AACzE,QAAM,CAAC,MAAM,OAAO,IAAI,MAAM,SAAS,KAAK;AAC5C,QAAM,SAAS,UAAU;AAEzB,QAAM,UAAU,MAAM;AACpB,UAAM,QAAQ,CAAC,MAAqB;AAClC,UAAI,EAAE,QAAQ,QAAQ,EAAE,WAAW,EAAE,UAAU;AAC7C,UAAE,eAAe;AACjB,gBAAQ,CAAC,SAAS,CAAC,IAAI;AAAA,MACzB;AACA,UAAI,EAAE,QAAQ,SAAU,SAAQ,KAAK;AAAA,IACvC;AACA,UAAM,SAAU,MAAM,QAAQ,IAAI;AAClC,UAAM,UAAU,MAAM,QAAQ,KAAK;AAEnC,aAAS,iBAAiB,WAAW,KAAK;AAC1C,aAAS,iBAAiB,aAAa,MAAM;AAC7C,aAAS,iBAAiB,cAAc,OAAO;AAC/C,WAAO,MAAM;AACX,eAAS,oBAAoB,WAAW,KAAK;AAC7C,eAAS,oBAAoB,aAAa,MAAM;AAChD,eAAS,oBAAoB,cAA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KAAK,YAAY,CAAC,CAAE,EAAE,KAAK,GAAG;AAAA,4BACtD,UAAU,MAAM,WAAW,IAAI;AAAA,4BAC/B,WAAW;AAAA,8BACT;AAAA,8BACA;AAAA,8BACA;AAAA,4BACF;AAAA,4BAEA;AAAA,kDAAC,KAAK,MAAL,EAAU,WAAU,0CAAyC;AAAA,8BAC9D,oBAAC,UAAK,WAAU,UAAU,eAAK,OAAM;AAAA,8BACrC,oBAAC,cAAW,WAAU,iDAAgD;AAAA;AAAA;AAAA,0BAXjE,KAAK;AAAA,wBAYZ,CACD;AAAA;AAAA,oBACH;AAAA,uBA9BmB,MAAM,OA+B3B,CACD;AAAA,mBACH;AAAA,gBAGA,qBAAC,SAAI,WAAU,2EACb;AAAA,sCAAC,UAAK,WAAU,wCAAuC,uBAAS;AAAA,kBAChE,oBAAC,SAAI,WAAU,kDAAiD,qBAAE;AAAA,mBACpE;AAAA,iBACF;AAAA;AAAA,UACF;AAAA;AAAA,MACF;AAAA,OACF,GAEJ;AAAA,KACF;AAEJ;","names":[]}
|
package/dist/index.cjs
CHANGED
|
@@ -53,6 +53,7 @@ __export(index_exports, {
|
|
|
53
53
|
MedialaneIcon: () => import_brand_icon.MedialaneIcon,
|
|
54
54
|
MedialaneLogoFull: () => import_brand_logo.MedialaneLogoFull,
|
|
55
55
|
MotionCard: () => import_motion_primitives.MotionCard,
|
|
56
|
+
NavCommandMenu: () => import_nav_command_menu.NavCommandMenu,
|
|
56
57
|
PageContainer: () => import_page_container.PageContainer,
|
|
57
58
|
SPRING: () => import_motion_primitives.SPRING,
|
|
58
59
|
ScrollSection: () => import_scroll_section.ScrollSection,
|
|
@@ -66,7 +67,8 @@ __export(index_exports, {
|
|
|
66
67
|
formatDisplayPrice: () => import_format.formatDisplayPrice,
|
|
67
68
|
ipfsToHttp: () => import_ipfs.ipfsToHttp,
|
|
68
69
|
shortenAddress: () => import_address.shortenAddress,
|
|
69
|
-
timeAgo: () => import_time.timeAgo
|
|
70
|
+
timeAgo: () => import_time.timeAgo,
|
|
71
|
+
useNavCommandMenu: () => import_nav_command_menu.useNavCommandMenu
|
|
70
72
|
});
|
|
71
73
|
module.exports = __toCommonJS(index_exports);
|
|
72
74
|
var import_cn = require("./utils/cn.js");
|
|
@@ -102,6 +104,7 @@ var import_discover_creators_strip = require("./components/discover-creators-str
|
|
|
102
104
|
var import_discover_feed_section = require("./components/discover-feed-section.js");
|
|
103
105
|
var import_launchpad_services = require("./components/launchpad-services.js");
|
|
104
106
|
var import_launchpad_services2 = require("./data/launchpad-services.js");
|
|
107
|
+
var import_nav_command_menu = require("./components/nav-command-menu.js");
|
|
105
108
|
// Annotate the CommonJS export names for ESM import in node:
|
|
106
109
|
0 && (module.exports = {
|
|
107
110
|
ACTIVITY_TYPE_CONFIG,
|
|
@@ -139,6 +142,7 @@ var import_launchpad_services2 = require("./data/launchpad-services.js");
|
|
|
139
142
|
MedialaneIcon,
|
|
140
143
|
MedialaneLogoFull,
|
|
141
144
|
MotionCard,
|
|
145
|
+
NavCommandMenu,
|
|
142
146
|
PageContainer,
|
|
143
147
|
SPRING,
|
|
144
148
|
ScrollSection,
|
|
@@ -152,6 +156,7 @@ var import_launchpad_services2 = require("./data/launchpad-services.js");
|
|
|
152
156
|
formatDisplayPrice,
|
|
153
157
|
ipfsToHttp,
|
|
154
158
|
shortenAddress,
|
|
155
|
-
timeAgo
|
|
159
|
+
timeAgo,
|
|
160
|
+
useNavCommandMenu
|
|
156
161
|
});
|
|
157
162
|
//# sourceMappingURL=index.cjs.map
|
package/dist/index.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["// ── Utils ─────────────────────────────────────────────────────────────────────\nexport { cn } from \"./utils/cn.js\";\nexport { formatDisplayPrice } from \"./utils/format.js\";\nexport { shortenAddress } from \"./utils/address.js\";\nexport { ipfsToHttp } from \"./utils/ipfs.js\";\n\n// ── Data (server-safe — no React, safe in Server Components) ──────────────────\nexport { IP_TYPE_DATA, IP_TYPE_DATA_MAP } from \"./data/ip-types.js\";\nexport type { IpTypeData } from \"./data/ip-types.js\";\nexport { BRAND } from \"./data/brand.js\";\n\n// ── Components (client-only — all have \"use client\") ─────────────────────────\nexport { CurrencyIcon, CurrencyAmount } from \"./components/currency-icon.js\";\nexport type { CurrencyIconProps, CurrencyAmountProps } from \"./components/currency-icon.js\";\n\nexport { IpTypeBadge, IP_TYPE_CONFIG, IP_TYPE_MAP } from \"./components/ip-type-badge.js\";\nexport type { IpTypeBadgeProps, IpTypeConfig } from \"./components/ip-type-badge.js\";\n\nexport { AddressDisplay } from \"./components/address-display.js\";\nexport type { AddressDisplayProps } from \"./components/address-display.js\";\n\nexport { MedialaneIcon } from \"./components/brand-icon.js\";\nexport type { MedialaneIconProps } from \"./components/brand-icon.js\";\nexport { MedialaneLogoFull } from \"./components/brand-logo.js\";\nexport type { MedialaneLogoFullProps } from \"./components/brand-logo.js\";\n\n// ── v0.2 additions ────────────────────────────────────────────────────────────\nexport { MotionCard, FadeIn, Stagger, StaggerItem, KineticWords, SPRING, EASE_OUT } from \"./components/motion-primitives.js\";\nexport { PageContainer } from \"./components/page-container.js\";\nexport type { PageContainerProps } from \"./components/page-container.js\";\nexport { ScrollSection } from \"./components/scroll-section.js\";\nexport type { ScrollSectionProps } from \"./components/scroll-section.js\";\nexport { ShareButton } from \"./components/share-button.js\";\nexport type { ShareButtonProps } from \"./components/share-button.js\";\nexport { CollectionCard, CollectionCardSkeleton } from \"./components/collection-card.js\";\nexport type { CollectionCardProps } from \"./components/collection-card.js\";\nexport { TokenCard, TokenCardSkeleton } from \"./components/token-card.js\";\nexport type { TokenCardProps, RarityTier } from \"./components/token-card.js\";\n\n// ── v0.3 additions ────────────────────────────────────────────────────────────\nexport { timeAgo } from \"./utils/time.js\";\nexport { ACTIVITY_TYPE_CONFIG, TYPE_FILTERS } from \"./data/activity.js\";\nexport type { ActivityTypeConfig } from \"./data/activity.js\";\nexport { HeroSlider, HeroSliderSkeleton } from \"./components/hero-slider.js\";\nexport type { HeroSliderProps } from \"./components/hero-slider.js\";\nexport { ActivityTicker } from \"./components/activity-ticker.js\";\nexport type { ActivityTickerProps } from \"./components/activity-ticker.js\";\nexport { ListingCard, ListingCardSkeleton } from \"./components/listing-card.js\";\nexport type { ListingCardProps } from \"./components/listing-card.js\";\nexport { ActivityRow } from \"./components/activity-row.js\";\nexport type { ActivityRowProps } from \"./components/activity-row.js\";\nexport { ActivityFeedShell } from \"./components/activity-feed-shell.js\";\nexport type { ActivityFeedShellProps } from \"./components/activity-feed-shell.js\";\nexport { LaunchpadGrid } from \"./components/launchpad-grid.js\";\nexport type { LaunchpadGridProps, FeatureItem } from \"./components/launchpad-grid.js\";\nexport { CtaCardGrid } from \"./components/cta-card-grid.js\";\nexport type { CtaCardGridProps, CtaCardItem } from \"./components/cta-card-grid.js\";\n\n// ── v0.3.2 additions ─────────────────────────────────────────────────────────\nexport { DiscoverHero } from \"./components/discover-hero.js\";\nexport type { DiscoverHeroProps } from \"./components/discover-hero.js\";\nexport { FeaturedCarousel, FeaturedCarouselSkeleton } from \"./components/featured-carousel.js\";\nexport type { FeaturedCarouselProps } from \"./components/featured-carousel.js\";\nexport { DiscoverCollectionsStrip } from \"./components/discover-collections-strip.js\";\nexport type { DiscoverCollectionsStripProps } from \"./components/discover-collections-strip.js\";\nexport { DiscoverCreatorsStrip } from \"./components/discover-creators-strip.js\";\nexport type { DiscoverCreatorsStripProps } from \"./components/discover-creators-strip.js\";\nexport { DiscoverFeedSection } from \"./components/discover-feed-section.js\";\nexport type { DiscoverFeedSectionProps } from \"./components/discover-feed-section.js\";\n\n// ── v0.4 additions ────────────────────────────────────────────────────────────\nexport { LaunchpadServicesGrid } from \"./components/launchpad-services.js\";\nexport type { LaunchpadServicesGridProps, ServiceCardProps } from \"./components/launchpad-services.js\";\nexport { LAUNCHPAD_SERVICE_DEFINITIONS } from \"./data/launchpad-services.js\";\nexport type { ServiceDefinition, ServiceStatus, ServiceCategory } from \"./data/launchpad-services.js\";\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,gBAAmB;AACnB,oBAAmC;AACnC,qBAA+B;AAC/B,kBAA2B;AAG3B,sBAA+C;AAE/C,mBAAsB;AAGtB,2BAA6C;AAG7C,2BAAyD;AAGzD,6BAA+B;AAG/B,wBAA8B;AAE9B,wBAAkC;AAIlC,+BAAyF;AACzF,4BAA8B;AAE9B,4BAA8B;AAE9B,0BAA4B;AAE5B,6BAAuD;AAEvD,wBAA6C;AAI7C,kBAAwB;AACxB,sBAAmD;AAEnD,yBAA+C;AAE/C,6BAA+B;AAE/B,0BAAiD;AAEjD,0BAA4B;AAE5B,iCAAkC;AAElC,4BAA8B;AAE9B,2BAA4B;AAI5B,2BAA6B;AAE7B,+BAA2D;AAE3D,wCAAyC;AAEzC,qCAAsC;AAEtC,mCAAoC;AAIpC,gCAAsC;AAEtC,IAAAA,6BAA8C;","names":["import_launchpad_services"]}
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["// ── Utils ─────────────────────────────────────────────────────────────────────\nexport { cn } from \"./utils/cn.js\";\nexport { formatDisplayPrice } from \"./utils/format.js\";\nexport { shortenAddress } from \"./utils/address.js\";\nexport { ipfsToHttp } from \"./utils/ipfs.js\";\n\n// ── Data (server-safe — no React, safe in Server Components) ──────────────────\nexport { IP_TYPE_DATA, IP_TYPE_DATA_MAP } from \"./data/ip-types.js\";\nexport type { IpTypeData } from \"./data/ip-types.js\";\nexport { BRAND } from \"./data/brand.js\";\n\n// ── Components (client-only — all have \"use client\") ─────────────────────────\nexport { CurrencyIcon, CurrencyAmount } from \"./components/currency-icon.js\";\nexport type { CurrencyIconProps, CurrencyAmountProps } from \"./components/currency-icon.js\";\n\nexport { IpTypeBadge, IP_TYPE_CONFIG, IP_TYPE_MAP } from \"./components/ip-type-badge.js\";\nexport type { IpTypeBadgeProps, IpTypeConfig } from \"./components/ip-type-badge.js\";\n\nexport { AddressDisplay } from \"./components/address-display.js\";\nexport type { AddressDisplayProps } from \"./components/address-display.js\";\n\nexport { MedialaneIcon } from \"./components/brand-icon.js\";\nexport type { MedialaneIconProps } from \"./components/brand-icon.js\";\nexport { MedialaneLogoFull } from \"./components/brand-logo.js\";\nexport type { MedialaneLogoFullProps } from \"./components/brand-logo.js\";\n\n// ── v0.2 additions ────────────────────────────────────────────────────────────\nexport { MotionCard, FadeIn, Stagger, StaggerItem, KineticWords, SPRING, EASE_OUT } from \"./components/motion-primitives.js\";\nexport { PageContainer } from \"./components/page-container.js\";\nexport type { PageContainerProps } from \"./components/page-container.js\";\nexport { ScrollSection } from \"./components/scroll-section.js\";\nexport type { ScrollSectionProps } from \"./components/scroll-section.js\";\nexport { ShareButton } from \"./components/share-button.js\";\nexport type { ShareButtonProps } from \"./components/share-button.js\";\nexport { CollectionCard, CollectionCardSkeleton } from \"./components/collection-card.js\";\nexport type { CollectionCardProps } from \"./components/collection-card.js\";\nexport { TokenCard, TokenCardSkeleton } from \"./components/token-card.js\";\nexport type { TokenCardProps, RarityTier } from \"./components/token-card.js\";\n\n// ── v0.3 additions ────────────────────────────────────────────────────────────\nexport { timeAgo } from \"./utils/time.js\";\nexport { ACTIVITY_TYPE_CONFIG, TYPE_FILTERS } from \"./data/activity.js\";\nexport type { ActivityTypeConfig } from \"./data/activity.js\";\nexport { HeroSlider, HeroSliderSkeleton } from \"./components/hero-slider.js\";\nexport type { HeroSliderProps } from \"./components/hero-slider.js\";\nexport { ActivityTicker } from \"./components/activity-ticker.js\";\nexport type { ActivityTickerProps } from \"./components/activity-ticker.js\";\nexport { ListingCard, ListingCardSkeleton } from \"./components/listing-card.js\";\nexport type { ListingCardProps } from \"./components/listing-card.js\";\nexport { ActivityRow } from \"./components/activity-row.js\";\nexport type { ActivityRowProps } from \"./components/activity-row.js\";\nexport { ActivityFeedShell } from \"./components/activity-feed-shell.js\";\nexport type { ActivityFeedShellProps } from \"./components/activity-feed-shell.js\";\nexport { LaunchpadGrid } from \"./components/launchpad-grid.js\";\nexport type { LaunchpadGridProps, FeatureItem } from \"./components/launchpad-grid.js\";\nexport { CtaCardGrid } from \"./components/cta-card-grid.js\";\nexport type { CtaCardGridProps, CtaCardItem } from \"./components/cta-card-grid.js\";\n\n// ── v0.3.2 additions ─────────────────────────────────────────────────────────\nexport { DiscoverHero } from \"./components/discover-hero.js\";\nexport type { DiscoverHeroProps } from \"./components/discover-hero.js\";\nexport { FeaturedCarousel, FeaturedCarouselSkeleton } from \"./components/featured-carousel.js\";\nexport type { FeaturedCarouselProps } from \"./components/featured-carousel.js\";\nexport { DiscoverCollectionsStrip } from \"./components/discover-collections-strip.js\";\nexport type { DiscoverCollectionsStripProps } from \"./components/discover-collections-strip.js\";\nexport { DiscoverCreatorsStrip } from \"./components/discover-creators-strip.js\";\nexport type { DiscoverCreatorsStripProps } from \"./components/discover-creators-strip.js\";\nexport { DiscoverFeedSection } from \"./components/discover-feed-section.js\";\nexport type { DiscoverFeedSectionProps } from \"./components/discover-feed-section.js\";\n\n// ── v0.4 additions ────────────────────────────────────────────────────────────\nexport { LaunchpadServicesGrid } from \"./components/launchpad-services.js\";\nexport type { LaunchpadServicesGridProps, ServiceCardProps } from \"./components/launchpad-services.js\";\nexport { LAUNCHPAD_SERVICE_DEFINITIONS } from \"./data/launchpad-services.js\";\nexport type { ServiceDefinition, ServiceStatus, ServiceCategory } from \"./data/launchpad-services.js\";\n\n// ── v0.5.0 additions ─────────────────────────────────────────────────────────\nexport { NavCommandMenu, useNavCommandMenu } from \"./components/nav-command-menu.js\";\nexport type { NavCommand, NavCommandGroup } from \"./components/nav-command-menu.js\";\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AACA,gBAAmB;AACnB,oBAAmC;AACnC,qBAA+B;AAC/B,kBAA2B;AAG3B,sBAA+C;AAE/C,mBAAsB;AAGtB,2BAA6C;AAG7C,2BAAyD;AAGzD,6BAA+B;AAG/B,wBAA8B;AAE9B,wBAAkC;AAIlC,+BAAyF;AACzF,4BAA8B;AAE9B,4BAA8B;AAE9B,0BAA4B;AAE5B,6BAAuD;AAEvD,wBAA6C;AAI7C,kBAAwB;AACxB,sBAAmD;AAEnD,yBAA+C;AAE/C,6BAA+B;AAE/B,0BAAiD;AAEjD,0BAA4B;AAE5B,iCAAkC;AAElC,4BAA8B;AAE9B,2BAA4B;AAI5B,2BAA6B;AAE7B,+BAA2D;AAE3D,wCAAyC;AAEzC,qCAAsC;AAEtC,mCAAoC;AAIpC,gCAAsC;AAEtC,IAAAA,6BAA8C;AAI9C,8BAAkD;","names":["import_launchpad_services"]}
|
package/dist/index.d.cts
CHANGED
|
@@ -31,6 +31,7 @@ export { DiscoverCreatorsStrip, DiscoverCreatorsStripProps } from './components/
|
|
|
31
31
|
export { DiscoverFeedSection, DiscoverFeedSectionProps } from './components/discover-feed-section.cjs';
|
|
32
32
|
export { LaunchpadServicesGrid, LaunchpadServicesGridProps, ServiceCardProps } from './components/launchpad-services.cjs';
|
|
33
33
|
export { LAUNCHPAD_SERVICE_DEFINITIONS, ServiceCategory, ServiceDefinition, ServiceStatus } from './data/launchpad-services.cjs';
|
|
34
|
+
export { NavCommand, NavCommandGroup, NavCommandMenu, useNavCommandMenu } from './components/nav-command-menu.cjs';
|
|
34
35
|
import 'clsx';
|
|
35
36
|
import 'react/jsx-runtime';
|
|
36
37
|
import 'framer-motion';
|
package/dist/index.d.ts
CHANGED
|
@@ -31,6 +31,7 @@ export { DiscoverCreatorsStrip, DiscoverCreatorsStripProps } from './components/
|
|
|
31
31
|
export { DiscoverFeedSection, DiscoverFeedSectionProps } from './components/discover-feed-section.js';
|
|
32
32
|
export { LaunchpadServicesGrid, LaunchpadServicesGridProps, ServiceCardProps } from './components/launchpad-services.js';
|
|
33
33
|
export { LAUNCHPAD_SERVICE_DEFINITIONS, ServiceCategory, ServiceDefinition, ServiceStatus } from './data/launchpad-services.js';
|
|
34
|
+
export { NavCommand, NavCommandGroup, NavCommandMenu, useNavCommandMenu } from './components/nav-command-menu.js';
|
|
34
35
|
import 'clsx';
|
|
35
36
|
import 'react/jsx-runtime';
|
|
36
37
|
import 'framer-motion';
|
package/dist/index.js
CHANGED
|
@@ -31,6 +31,7 @@ import { DiscoverCreatorsStrip } from "./components/discover-creators-strip.js";
|
|
|
31
31
|
import { DiscoverFeedSection } from "./components/discover-feed-section.js";
|
|
32
32
|
import { LaunchpadServicesGrid } from "./components/launchpad-services.js";
|
|
33
33
|
import { LAUNCHPAD_SERVICE_DEFINITIONS } from "./data/launchpad-services.js";
|
|
34
|
+
import { NavCommandMenu, useNavCommandMenu } from "./components/nav-command-menu.js";
|
|
34
35
|
export {
|
|
35
36
|
ACTIVITY_TYPE_CONFIG,
|
|
36
37
|
ActivityFeedShell,
|
|
@@ -67,6 +68,7 @@ export {
|
|
|
67
68
|
MedialaneIcon,
|
|
68
69
|
MedialaneLogoFull,
|
|
69
70
|
MotionCard,
|
|
71
|
+
NavCommandMenu,
|
|
70
72
|
PageContainer,
|
|
71
73
|
SPRING,
|
|
72
74
|
ScrollSection,
|
|
@@ -80,6 +82,7 @@ export {
|
|
|
80
82
|
formatDisplayPrice,
|
|
81
83
|
ipfsToHttp,
|
|
82
84
|
shortenAddress,
|
|
83
|
-
timeAgo
|
|
85
|
+
timeAgo,
|
|
86
|
+
useNavCommandMenu
|
|
84
87
|
};
|
|
85
88
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["// ── Utils ─────────────────────────────────────────────────────────────────────\nexport { cn } from \"./utils/cn.js\";\nexport { formatDisplayPrice } from \"./utils/format.js\";\nexport { shortenAddress } from \"./utils/address.js\";\nexport { ipfsToHttp } from \"./utils/ipfs.js\";\n\n// ── Data (server-safe — no React, safe in Server Components) ──────────────────\nexport { IP_TYPE_DATA, IP_TYPE_DATA_MAP } from \"./data/ip-types.js\";\nexport type { IpTypeData } from \"./data/ip-types.js\";\nexport { BRAND } from \"./data/brand.js\";\n\n// ── Components (client-only — all have \"use client\") ─────────────────────────\nexport { CurrencyIcon, CurrencyAmount } from \"./components/currency-icon.js\";\nexport type { CurrencyIconProps, CurrencyAmountProps } from \"./components/currency-icon.js\";\n\nexport { IpTypeBadge, IP_TYPE_CONFIG, IP_TYPE_MAP } from \"./components/ip-type-badge.js\";\nexport type { IpTypeBadgeProps, IpTypeConfig } from \"./components/ip-type-badge.js\";\n\nexport { AddressDisplay } from \"./components/address-display.js\";\nexport type { AddressDisplayProps } from \"./components/address-display.js\";\n\nexport { MedialaneIcon } from \"./components/brand-icon.js\";\nexport type { MedialaneIconProps } from \"./components/brand-icon.js\";\nexport { MedialaneLogoFull } from \"./components/brand-logo.js\";\nexport type { MedialaneLogoFullProps } from \"./components/brand-logo.js\";\n\n// ── v0.2 additions ────────────────────────────────────────────────────────────\nexport { MotionCard, FadeIn, Stagger, StaggerItem, KineticWords, SPRING, EASE_OUT } from \"./components/motion-primitives.js\";\nexport { PageContainer } from \"./components/page-container.js\";\nexport type { PageContainerProps } from \"./components/page-container.js\";\nexport { ScrollSection } from \"./components/scroll-section.js\";\nexport type { ScrollSectionProps } from \"./components/scroll-section.js\";\nexport { ShareButton } from \"./components/share-button.js\";\nexport type { ShareButtonProps } from \"./components/share-button.js\";\nexport { CollectionCard, CollectionCardSkeleton } from \"./components/collection-card.js\";\nexport type { CollectionCardProps } from \"./components/collection-card.js\";\nexport { TokenCard, TokenCardSkeleton } from \"./components/token-card.js\";\nexport type { TokenCardProps, RarityTier } from \"./components/token-card.js\";\n\n// ── v0.3 additions ────────────────────────────────────────────────────────────\nexport { timeAgo } from \"./utils/time.js\";\nexport { ACTIVITY_TYPE_CONFIG, TYPE_FILTERS } from \"./data/activity.js\";\nexport type { ActivityTypeConfig } from \"./data/activity.js\";\nexport { HeroSlider, HeroSliderSkeleton } from \"./components/hero-slider.js\";\nexport type { HeroSliderProps } from \"./components/hero-slider.js\";\nexport { ActivityTicker } from \"./components/activity-ticker.js\";\nexport type { ActivityTickerProps } from \"./components/activity-ticker.js\";\nexport { ListingCard, ListingCardSkeleton } from \"./components/listing-card.js\";\nexport type { ListingCardProps } from \"./components/listing-card.js\";\nexport { ActivityRow } from \"./components/activity-row.js\";\nexport type { ActivityRowProps } from \"./components/activity-row.js\";\nexport { ActivityFeedShell } from \"./components/activity-feed-shell.js\";\nexport type { ActivityFeedShellProps } from \"./components/activity-feed-shell.js\";\nexport { LaunchpadGrid } from \"./components/launchpad-grid.js\";\nexport type { LaunchpadGridProps, FeatureItem } from \"./components/launchpad-grid.js\";\nexport { CtaCardGrid } from \"./components/cta-card-grid.js\";\nexport type { CtaCardGridProps, CtaCardItem } from \"./components/cta-card-grid.js\";\n\n// ── v0.3.2 additions ─────────────────────────────────────────────────────────\nexport { DiscoverHero } from \"./components/discover-hero.js\";\nexport type { DiscoverHeroProps } from \"./components/discover-hero.js\";\nexport { FeaturedCarousel, FeaturedCarouselSkeleton } from \"./components/featured-carousel.js\";\nexport type { FeaturedCarouselProps } from \"./components/featured-carousel.js\";\nexport { DiscoverCollectionsStrip } from \"./components/discover-collections-strip.js\";\nexport type { DiscoverCollectionsStripProps } from \"./components/discover-collections-strip.js\";\nexport { DiscoverCreatorsStrip } from \"./components/discover-creators-strip.js\";\nexport type { DiscoverCreatorsStripProps } from \"./components/discover-creators-strip.js\";\nexport { DiscoverFeedSection } from \"./components/discover-feed-section.js\";\nexport type { DiscoverFeedSectionProps } from \"./components/discover-feed-section.js\";\n\n// ── v0.4 additions ────────────────────────────────────────────────────────────\nexport { LaunchpadServicesGrid } from \"./components/launchpad-services.js\";\nexport type { LaunchpadServicesGridProps, ServiceCardProps } from \"./components/launchpad-services.js\";\nexport { LAUNCHPAD_SERVICE_DEFINITIONS } from \"./data/launchpad-services.js\";\nexport type { ServiceDefinition, ServiceStatus, ServiceCategory } from \"./data/launchpad-services.js\";\n"],"mappings":"AACA,SAAS,UAAU;AACnB,SAAS,0BAA0B;AACnC,SAAS,sBAAsB;AAC/B,SAAS,kBAAkB;AAG3B,SAAS,cAAc,wBAAwB;AAE/C,SAAS,aAAa;AAGtB,SAAS,cAAc,sBAAsB;AAG7C,SAAS,aAAa,gBAAgB,mBAAmB;AAGzD,SAAS,sBAAsB;AAG/B,SAAS,qBAAqB;AAE9B,SAAS,yBAAyB;AAIlC,SAAS,YAAY,QAAQ,SAAS,aAAa,cAAc,QAAQ,gBAAgB;AACzF,SAAS,qBAAqB;AAE9B,SAAS,qBAAqB;AAE9B,SAAS,mBAAmB;AAE5B,SAAS,gBAAgB,8BAA8B;AAEvD,SAAS,WAAW,yBAAyB;AAI7C,SAAS,eAAe;AACxB,SAAS,sBAAsB,oBAAoB;AAEnD,SAAS,YAAY,0BAA0B;AAE/C,SAAS,sBAAsB;AAE/B,SAAS,aAAa,2BAA2B;AAEjD,SAAS,mBAAmB;AAE5B,SAAS,yBAAyB;AAElC,SAAS,qBAAqB;AAE9B,SAAS,mBAAmB;AAI5B,SAAS,oBAAoB;AAE7B,SAAS,kBAAkB,gCAAgC;AAE3D,SAAS,gCAAgC;AAEzC,SAAS,6BAA6B;AAEtC,SAAS,2BAA2B;AAIpC,SAAS,6BAA6B;AAEtC,SAAS,qCAAqC;","names":[]}
|
|
1
|
+
{"version":3,"sources":["../src/index.ts"],"sourcesContent":["// ── Utils ─────────────────────────────────────────────────────────────────────\nexport { cn } from \"./utils/cn.js\";\nexport { formatDisplayPrice } from \"./utils/format.js\";\nexport { shortenAddress } from \"./utils/address.js\";\nexport { ipfsToHttp } from \"./utils/ipfs.js\";\n\n// ── Data (server-safe — no React, safe in Server Components) ──────────────────\nexport { IP_TYPE_DATA, IP_TYPE_DATA_MAP } from \"./data/ip-types.js\";\nexport type { IpTypeData } from \"./data/ip-types.js\";\nexport { BRAND } from \"./data/brand.js\";\n\n// ── Components (client-only — all have \"use client\") ─────────────────────────\nexport { CurrencyIcon, CurrencyAmount } from \"./components/currency-icon.js\";\nexport type { CurrencyIconProps, CurrencyAmountProps } from \"./components/currency-icon.js\";\n\nexport { IpTypeBadge, IP_TYPE_CONFIG, IP_TYPE_MAP } from \"./components/ip-type-badge.js\";\nexport type { IpTypeBadgeProps, IpTypeConfig } from \"./components/ip-type-badge.js\";\n\nexport { AddressDisplay } from \"./components/address-display.js\";\nexport type { AddressDisplayProps } from \"./components/address-display.js\";\n\nexport { MedialaneIcon } from \"./components/brand-icon.js\";\nexport type { MedialaneIconProps } from \"./components/brand-icon.js\";\nexport { MedialaneLogoFull } from \"./components/brand-logo.js\";\nexport type { MedialaneLogoFullProps } from \"./components/brand-logo.js\";\n\n// ── v0.2 additions ────────────────────────────────────────────────────────────\nexport { MotionCard, FadeIn, Stagger, StaggerItem, KineticWords, SPRING, EASE_OUT } from \"./components/motion-primitives.js\";\nexport { PageContainer } from \"./components/page-container.js\";\nexport type { PageContainerProps } from \"./components/page-container.js\";\nexport { ScrollSection } from \"./components/scroll-section.js\";\nexport type { ScrollSectionProps } from \"./components/scroll-section.js\";\nexport { ShareButton } from \"./components/share-button.js\";\nexport type { ShareButtonProps } from \"./components/share-button.js\";\nexport { CollectionCard, CollectionCardSkeleton } from \"./components/collection-card.js\";\nexport type { CollectionCardProps } from \"./components/collection-card.js\";\nexport { TokenCard, TokenCardSkeleton } from \"./components/token-card.js\";\nexport type { TokenCardProps, RarityTier } from \"./components/token-card.js\";\n\n// ── v0.3 additions ────────────────────────────────────────────────────────────\nexport { timeAgo } from \"./utils/time.js\";\nexport { ACTIVITY_TYPE_CONFIG, TYPE_FILTERS } from \"./data/activity.js\";\nexport type { ActivityTypeConfig } from \"./data/activity.js\";\nexport { HeroSlider, HeroSliderSkeleton } from \"./components/hero-slider.js\";\nexport type { HeroSliderProps } from \"./components/hero-slider.js\";\nexport { ActivityTicker } from \"./components/activity-ticker.js\";\nexport type { ActivityTickerProps } from \"./components/activity-ticker.js\";\nexport { ListingCard, ListingCardSkeleton } from \"./components/listing-card.js\";\nexport type { ListingCardProps } from \"./components/listing-card.js\";\nexport { ActivityRow } from \"./components/activity-row.js\";\nexport type { ActivityRowProps } from \"./components/activity-row.js\";\nexport { ActivityFeedShell } from \"./components/activity-feed-shell.js\";\nexport type { ActivityFeedShellProps } from \"./components/activity-feed-shell.js\";\nexport { LaunchpadGrid } from \"./components/launchpad-grid.js\";\nexport type { LaunchpadGridProps, FeatureItem } from \"./components/launchpad-grid.js\";\nexport { CtaCardGrid } from \"./components/cta-card-grid.js\";\nexport type { CtaCardGridProps, CtaCardItem } from \"./components/cta-card-grid.js\";\n\n// ── v0.3.2 additions ─────────────────────────────────────────────────────────\nexport { DiscoverHero } from \"./components/discover-hero.js\";\nexport type { DiscoverHeroProps } from \"./components/discover-hero.js\";\nexport { FeaturedCarousel, FeaturedCarouselSkeleton } from \"./components/featured-carousel.js\";\nexport type { FeaturedCarouselProps } from \"./components/featured-carousel.js\";\nexport { DiscoverCollectionsStrip } from \"./components/discover-collections-strip.js\";\nexport type { DiscoverCollectionsStripProps } from \"./components/discover-collections-strip.js\";\nexport { DiscoverCreatorsStrip } from \"./components/discover-creators-strip.js\";\nexport type { DiscoverCreatorsStripProps } from \"./components/discover-creators-strip.js\";\nexport { DiscoverFeedSection } from \"./components/discover-feed-section.js\";\nexport type { DiscoverFeedSectionProps } from \"./components/discover-feed-section.js\";\n\n// ── v0.4 additions ────────────────────────────────────────────────────────────\nexport { LaunchpadServicesGrid } from \"./components/launchpad-services.js\";\nexport type { LaunchpadServicesGridProps, ServiceCardProps } from \"./components/launchpad-services.js\";\nexport { LAUNCHPAD_SERVICE_DEFINITIONS } from \"./data/launchpad-services.js\";\nexport type { ServiceDefinition, ServiceStatus, ServiceCategory } from \"./data/launchpad-services.js\";\n\n// ── v0.5.0 additions ─────────────────────────────────────────────────────────\nexport { NavCommandMenu, useNavCommandMenu } from \"./components/nav-command-menu.js\";\nexport type { NavCommand, NavCommandGroup } from \"./components/nav-command-menu.js\";\n"],"mappings":"AACA,SAAS,UAAU;AACnB,SAAS,0BAA0B;AACnC,SAAS,sBAAsB;AAC/B,SAAS,kBAAkB;AAG3B,SAAS,cAAc,wBAAwB;AAE/C,SAAS,aAAa;AAGtB,SAAS,cAAc,sBAAsB;AAG7C,SAAS,aAAa,gBAAgB,mBAAmB;AAGzD,SAAS,sBAAsB;AAG/B,SAAS,qBAAqB;AAE9B,SAAS,yBAAyB;AAIlC,SAAS,YAAY,QAAQ,SAAS,aAAa,cAAc,QAAQ,gBAAgB;AACzF,SAAS,qBAAqB;AAE9B,SAAS,qBAAqB;AAE9B,SAAS,mBAAmB;AAE5B,SAAS,gBAAgB,8BAA8B;AAEvD,SAAS,WAAW,yBAAyB;AAI7C,SAAS,eAAe;AACxB,SAAS,sBAAsB,oBAAoB;AAEnD,SAAS,YAAY,0BAA0B;AAE/C,SAAS,sBAAsB;AAE/B,SAAS,aAAa,2BAA2B;AAEjD,SAAS,mBAAmB;AAE5B,SAAS,yBAAyB;AAElC,SAAS,qBAAqB;AAE9B,SAAS,mBAAmB;AAI5B,SAAS,oBAAoB;AAE7B,SAAS,kBAAkB,gCAAgC;AAE3D,SAAS,gCAAgC;AAEzC,SAAS,6BAA6B;AAEtC,SAAS,2BAA2B;AAIpC,SAAS,6BAA6B;AAEtC,SAAS,qCAAqC;AAI9C,SAAS,gBAAgB,yBAAyB;","names":[]}
|
package/dist/medialane.css
CHANGED
|
@@ -88,6 +88,22 @@
|
|
|
88
88
|
.dark .aurora-rose { opacity: 0.09; }
|
|
89
89
|
.dark .aurora-orange { opacity: 0.07; }
|
|
90
90
|
|
|
91
|
+
/* Navigation canvas */
|
|
92
|
+
.nav-canvas-overlay {
|
|
93
|
+
position: fixed;
|
|
94
|
+
inset: 0;
|
|
95
|
+
z-index: 100;
|
|
96
|
+
backdrop-filter: blur(48px) saturate(1.5);
|
|
97
|
+
-webkit-backdrop-filter: blur(48px) saturate(1.5);
|
|
98
|
+
}
|
|
99
|
+
.nav-canvas-aurora {
|
|
100
|
+
position: fixed;
|
|
101
|
+
inset: 0;
|
|
102
|
+
z-index: 99;
|
|
103
|
+
pointer-events: none;
|
|
104
|
+
overflow: hidden;
|
|
105
|
+
}
|
|
106
|
+
|
|
91
107
|
/* ── Card primitives ──────────────────────────────────────────────────── */
|
|
92
108
|
.card-base {
|
|
93
109
|
border-radius: calc(var(--radius) * 1.25);
|
package/dist/preset/tailwind.cjs
CHANGED
|
@@ -16,14 +16,12 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
16
16
|
return to;
|
|
17
17
|
};
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
-
|
|
20
|
-
// src/preset/tailwind.ts
|
|
21
19
|
var tailwind_exports = {};
|
|
22
20
|
__export(tailwind_exports, {
|
|
23
21
|
default: () => tailwind_default
|
|
24
22
|
});
|
|
25
23
|
module.exports = __toCommonJS(tailwind_exports);
|
|
26
|
-
|
|
24
|
+
const medialanePreset = {
|
|
27
25
|
theme: {
|
|
28
26
|
extend: {
|
|
29
27
|
colors: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/preset/tailwind.ts"],"sourcesContent":["import type { Config } from \"tailwindcss\";\n\nconst medialanePreset: Partial<Config> = {\n theme: {\n extend: {\n colors: {\n \"brand-blue\": \"#2563eb\",\n \"brand-navy\": \"#172554\",\n \"brand-rose\": \"#f43f5e\",\n \"brand-purple\": \"#9333ea\",\n \"brand-orange\": \"#ea580c\",\n },\n borderRadius: {\n brand: \"11px\",\n },\n },\n },\n};\n\nexport default medialanePreset;\n"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../../src/preset/tailwind.ts"],"sourcesContent":["import type { Config } from \"tailwindcss\";\n\nconst medialanePreset: Partial<Config> = {\n theme: {\n extend: {\n colors: {\n \"brand-blue\": \"#2563eb\",\n \"brand-navy\": \"#172554\",\n \"brand-rose\": \"#f43f5e\",\n \"brand-purple\": \"#9333ea\",\n \"brand-orange\": \"#ea580c\",\n },\n borderRadius: {\n brand: \"11px\",\n },\n },\n },\n};\n\nexport default medialanePreset;\n"],"mappings":";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAEA,MAAM,kBAAmC;AAAA,EACvC,OAAO;AAAA,IACL,QAAQ;AAAA,MACN,QAAQ;AAAA,QACN,cAAc;AAAA,QACd,cAAc;AAAA,QACd,cAAc;AAAA,QACd,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,MAClB;AAAA,MACA,cAAc;AAAA,QACZ,OAAO;AAAA,MACT;AAAA,IACF;AAAA,EACF;AACF;AAEA,IAAO,mBAAQ;","names":[]}
|
package/dist/preset/tailwind.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/preset/tailwind.ts"],"sourcesContent":["import type { Config } from \"tailwindcss\";\n\nconst medialanePreset: Partial<Config> = {\n theme: {\n extend: {\n colors: {\n \"brand-blue\": \"#2563eb\",\n \"brand-navy\": \"#172554\",\n \"brand-rose\": \"#f43f5e\",\n \"brand-purple\": \"#9333ea\",\n \"brand-orange\": \"#ea580c\",\n },\n borderRadius: {\n brand: \"11px\",\n },\n },\n },\n};\n\nexport default medialanePreset;\n"],"mappings":"
|
|
1
|
+
{"version":3,"sources":["../../src/preset/tailwind.ts"],"sourcesContent":["import type { Config } from \"tailwindcss\";\n\nconst medialanePreset: Partial<Config> = {\n theme: {\n extend: {\n colors: {\n \"brand-blue\": \"#2563eb\",\n \"brand-navy\": \"#172554\",\n \"brand-rose\": \"#f43f5e\",\n \"brand-purple\": \"#9333ea\",\n \"brand-orange\": \"#ea580c\",\n },\n borderRadius: {\n brand: \"11px\",\n },\n },\n },\n};\n\nexport default medialanePreset;\n"],"mappings":"AAEA,MAAM,kBAAmC;AAAA,EACvC,OAAO;AAAA,IACL,QAAQ;AAAA,MACN,QAAQ;AAAA,QACN,cAAc;AAAA,QACd,cAAc;AAAA,QACd,cAAc;AAAA,QACd,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,MAClB;AAAA,MACA,cAAc;AAAA,QACZ,OAAO;AAAA,MACT;AAAA,IACF;AAAA,EACF;AACF;AAEA,IAAO,mBAAQ;","names":[]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@medialane/ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.5.0",
|
|
4
4
|
"description": "Shared UI components for Medialane apps",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.cjs",
|
|
@@ -41,13 +41,15 @@
|
|
|
41
41
|
"react": ">=18.0.0",
|
|
42
42
|
"react-dom": ">=18.0.0",
|
|
43
43
|
"sonner": ">=1.0.0",
|
|
44
|
-
"tailwind-merge": ">=2.0.0"
|
|
44
|
+
"tailwind-merge": ">=2.0.0",
|
|
45
|
+
"cmdk": ">=1.0.0"
|
|
45
46
|
},
|
|
46
47
|
"devDependencies": {
|
|
47
48
|
"@medialane/sdk": "^0.8.2",
|
|
48
49
|
"@types/react": "^19.0.0",
|
|
49
50
|
"@types/react-dom": "^19.0.0",
|
|
50
51
|
"clsx": "^2.0.0",
|
|
52
|
+
"cmdk": "^1.1.1",
|
|
51
53
|
"framer-motion": "^11.0.0",
|
|
52
54
|
"lucide-react": "^0.400.0",
|
|
53
55
|
"next": "^15.0.0",
|