@medialane/ui 0.235.0 → 0.237.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.
Files changed (47) hide show
  1. package/dist/components/account/input-otp.d.cts +2 -2
  2. package/dist/components/account/input-otp.d.ts +2 -2
  3. package/dist/components/badge.d.cts +1 -1
  4. package/dist/components/badge.d.ts +1 -1
  5. package/dist/components/button.d.cts +2 -2
  6. package/dist/components/button.d.ts +2 -2
  7. package/dist/components/fast-mint/fast-mint.d.cts +2 -2
  8. package/dist/components/fast-mint/fast-mint.d.ts +2 -2
  9. package/dist/components/launchpad/collection-picker.cjs +147 -0
  10. package/dist/components/launchpad/collection-picker.cjs.map +1 -0
  11. package/dist/components/launchpad/collection-picker.d.cts +13 -0
  12. package/dist/components/launchpad/collection-picker.d.ts +13 -0
  13. package/dist/components/launchpad/collection-picker.js +113 -0
  14. package/dist/components/launchpad/collection-picker.js.map +1 -0
  15. package/dist/components/launchpad/edition-mint-fields.cjs +308 -0
  16. package/dist/components/launchpad/edition-mint-fields.cjs.map +1 -0
  17. package/dist/components/launchpad/edition-mint-fields.d.cts +24 -0
  18. package/dist/components/launchpad/edition-mint-fields.d.ts +24 -0
  19. package/dist/components/launchpad/edition-mint-fields.js +274 -0
  20. package/dist/components/launchpad/edition-mint-fields.js.map +1 -0
  21. package/dist/components/launchpad/edition-mint-schema.cjs +58 -0
  22. package/dist/components/launchpad/edition-mint-schema.cjs.map +1 -0
  23. package/dist/components/launchpad/edition-mint-schema.d.cts +48 -0
  24. package/dist/components/launchpad/edition-mint-schema.d.ts +48 -0
  25. package/dist/components/launchpad/edition-mint-schema.js +24 -0
  26. package/dist/components/launchpad/edition-mint-schema.js.map +1 -0
  27. package/dist/components/launchpad/edition-mint.cjs +244 -0
  28. package/dist/components/launchpad/edition-mint.cjs.map +1 -0
  29. package/dist/components/launchpad/edition-mint.d.cts +9 -0
  30. package/dist/components/launchpad/edition-mint.d.ts +9 -0
  31. package/dist/components/launchpad/edition-mint.js +210 -0
  32. package/dist/components/launchpad/edition-mint.js.map +1 -0
  33. package/dist/components/launchpad/single-edition-mint.cjs +427 -0
  34. package/dist/components/launchpad/single-edition-mint.cjs.map +1 -0
  35. package/dist/components/launchpad/single-edition-mint.d.cts +8 -0
  36. package/dist/components/launchpad/single-edition-mint.d.ts +8 -0
  37. package/dist/components/launchpad/single-edition-mint.js +393 -0
  38. package/dist/components/launchpad/single-edition-mint.js.map +1 -0
  39. package/dist/components/sheet.d.cts +1 -1
  40. package/dist/components/sheet.d.ts +1 -1
  41. package/dist/index.cjs +9 -0
  42. package/dist/index.cjs.map +1 -1
  43. package/dist/index.d.cts +3 -0
  44. package/dist/index.d.ts +3 -0
  45. package/dist/index.js +6 -0
  46. package/dist/index.js.map +1 -1
  47. package/package.json +1 -1
@@ -0,0 +1,308 @@
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 edition_mint_fields_exports = {};
31
+ __export(edition_mint_fields_exports, {
32
+ EditionMintFields: () => EditionMintFields
33
+ });
34
+ module.exports = __toCommonJS(edition_mint_fields_exports);
35
+ var import_jsx_runtime = require("react/jsx-runtime");
36
+ var import_react = require("react");
37
+ var import_lucide_react = require("lucide-react");
38
+ var import_sdk = require("@medialane/sdk");
39
+ var import_image = __toESM(require("../image.js"), 1);
40
+ var import_button = require("../button.js");
41
+ var import_input = require("../input.js");
42
+ var import_textarea = require("../textarea.js");
43
+ var import_collapsible = require("../collapsible.js");
44
+ var import_collapsible_section = require("../collapsible-section.js");
45
+ var import_form = require("../form.js");
46
+ var import_select = require("../select.js");
47
+ var import_motion_primitives = require("../motion-primitives.js");
48
+ var import_ip_type_fields = require("../ip-type-fields.js");
49
+ var import_create_form_primitives = require("../create-form-primitives.js");
50
+ var import_ip = require("../../data/ip.js");
51
+ var import_cn = require("../../utils/cn.js");
52
+ function EditionMintFields({
53
+ form,
54
+ imagePreview,
55
+ imageUri,
56
+ imageUploading,
57
+ mintDisabled,
58
+ fileInputRef,
59
+ onImageSelect,
60
+ onClearImage,
61
+ metadataResetKey,
62
+ onMetadataFieldsChange,
63
+ uploadDocument
64
+ }) {
65
+ const [licensingOpen, setLicensingOpen] = (0, import_react.useState)(false);
66
+ const [advancedOpen, setAdvancedOpen] = (0, import_react.useState)(false);
67
+ const [ipTypeOpen, setIpTypeOpen] = (0, import_react.useState)(false);
68
+ const handleLicenseChange = (value) => {
69
+ form.setValue("licenseType", value);
70
+ const preset = import_ip.LICENSE_TYPES.find((license) => license.value === value);
71
+ if (preset) {
72
+ form.setValue("commercialUse", preset.commercialUse);
73
+ form.setValue("derivatives", preset.derivatives);
74
+ form.setValue("attribution", preset.attribution);
75
+ }
76
+ };
77
+ return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "space-y-5", children: [
78
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_motion_primitives.FadeIn, { delay: 0.06, children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "space-y-2", children: [
79
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("p", { className: "text-sm font-medium", children: [
80
+ "Asset image ",
81
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "text-destructive", children: "*" })
82
+ ] }),
83
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "flex items-center gap-4", children: [
84
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
85
+ "div",
86
+ {
87
+ role: "button",
88
+ tabIndex: 0,
89
+ onClick: () => !imageUploading && fileInputRef.current?.click(),
90
+ onKeyDown: (event) => {
91
+ if (event.key === "Enter") fileInputRef.current?.click();
92
+ },
93
+ className: "relative h-20 w-20 rounded-2xl border-2 border-dashed border-border bg-muted flex items-center justify-center overflow-hidden shrink-0 cursor-pointer hover:border-brand-purple/50 transition-colors",
94
+ children: [
95
+ imagePreview ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_image.default, { src: imagePreview, alt: "Token", fill: true, unoptimized: true, className: "object-cover" }) : /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.ImagePlus, { className: "h-6 w-6 text-muted-foreground" }),
96
+ imageUploading ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "absolute inset-0 bg-background/70 flex items-center justify-center", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.Loader2, { className: "h-4 w-4 animate-spin" }) }) : null
97
+ ]
98
+ }
99
+ ),
100
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "space-y-1.5", children: [
101
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
102
+ "input",
103
+ {
104
+ ref: fileInputRef,
105
+ type: "file",
106
+ accept: (0, import_sdk.acceptFor)("image"),
107
+ className: "hidden",
108
+ onChange: (event) => {
109
+ const file = event.target.files?.[0];
110
+ if (file) onImageSelect(file);
111
+ }
112
+ }
113
+ ),
114
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
115
+ import_button.Button,
116
+ {
117
+ type: "button",
118
+ variant: "outline",
119
+ size: "sm",
120
+ disabled: imageUploading,
121
+ onClick: () => fileInputRef.current?.click(),
122
+ children: imageUploading ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
123
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.Loader2, { className: "h-3.5 w-3.5 mr-1.5 animate-spin" }),
124
+ "Uploading\u2026"
125
+ ] }) : imagePreview ? "Change" : "Upload image"
126
+ }
127
+ ),
128
+ imagePreview ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
129
+ "button",
130
+ {
131
+ type: "button",
132
+ onClick: onClearImage,
133
+ className: "flex items-center gap-1 text-xs text-muted-foreground hover:text-destructive transition-colors",
134
+ children: [
135
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.X, { className: "h-3 w-3" }),
136
+ " Remove"
137
+ ]
138
+ }
139
+ ) : null,
140
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: "text-xs text-muted-foreground", children: imageUri ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "text-brand-purple", children: "\u2713 Uploaded" }) : "JPG, PNG, SVG or WebP" }),
141
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: "text-xs text-muted-foreground", children: "This media and metadata are pinned before the first mint is submitted." })
142
+ ] })
143
+ ] })
144
+ ] }) }),
145
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_motion_primitives.FadeIn, { delay: 0.08, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "name", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
146
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "Token name *" }),
147
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_input.Input, { placeholder: "Genesis Track #1", ...field }) }),
148
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormDescription, { children: "The title collectors will see for this edition." }),
149
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormMessage, {})
150
+ ] }) }) }),
151
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_motion_primitives.FadeIn, { delay: 0.1, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "description", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
152
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormLabel, { children: [
153
+ "Description ",
154
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "text-muted-foreground font-normal", children: "(optional)" })
155
+ ] }),
156
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_textarea.Textarea, { placeholder: "Describe this digital asset\u2026", rows: 3, ...field }) }),
157
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormDescription, { children: "Add context, utility, or creative notes for this token edition." }),
158
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormMessage, {})
159
+ ] }) }) }),
160
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_motion_primitives.FadeIn, { delay: 0.12, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "external_url", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
161
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormLabel, { children: [
162
+ "External link ",
163
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { className: "text-muted-foreground font-normal", children: "(optional)" })
164
+ ] }),
165
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_input.Input, { placeholder: "https://yourwebsite.com", ...field }) }),
166
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormDescription, { children: "Canonical link for this edition." }),
167
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormMessage, {})
168
+ ] }) }) }),
169
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_motion_primitives.FadeIn, { delay: 0.14, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "value", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
170
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "Quantity *" }),
171
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_input.Input, { type: "number", min: 1, placeholder: "1", className: "max-w-[180px]", ...field }) }),
172
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormDescription, { children: "Number of copies to mint for this token ID." }),
173
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormMessage, {})
174
+ ] }) }) }),
175
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_motion_primitives.FadeIn, { delay: 0.16, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "recipient", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
176
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "Recipient *" }),
177
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_input.Input, { placeholder: "0x\u2026", ...field }) }),
178
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormDescription, { children: "Account that receives the minted tokens. Defaults to your account." }),
179
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormMessage, {})
180
+ ] }) }) }),
181
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_motion_primitives.FadeIn, { delay: 0.18, children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
182
+ import_collapsible_section.CollapsibleSection,
183
+ {
184
+ open: licensingOpen,
185
+ onOpenChange: setLicensingOpen,
186
+ icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.ShieldCheck, { className: "h-4 w-4 text-primary" }),
187
+ label: "Licensing Terms",
188
+ hint: "Optional \xB7 Berne Convention",
189
+ children: [
190
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: "text-xs text-muted-foreground", children: "Set the licensing terms for this edition \u2014 saved permanently with it." }),
191
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "licenseType", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
192
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "License" }),
193
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_select.Select, { value: field.value, onValueChange: handleLicenseChange, children: [
194
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_select.SelectTrigger, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_select.SelectValue, {}) }) }),
195
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_select.SelectContent, { children: import_ip.LICENSE_TYPES.map((license) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_select.SelectItem, { value: license.value, children: license.label }, license.value)) })
196
+ ] }),
197
+ (() => {
198
+ const preset = import_ip.LICENSE_TYPES.find((license) => license.value === field.value);
199
+ return preset ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: "text-xs text-muted-foreground mt-1", children: preset.description }) : null;
200
+ })(),
201
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormMessage, {})
202
+ ] }) }),
203
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "commercialUse", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
204
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "Commercial Use" }),
205
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_create_form_primitives.ToggleGroup, { value: field.value, options: ["Yes", "No"], onChange: field.onChange })
206
+ ] }) }),
207
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "derivatives", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
208
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "Derivatives" }),
209
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_create_form_primitives.ToggleGroup, { value: field.value, options: import_ip.DERIVATIVES_OPTIONS, onChange: field.onChange })
210
+ ] }) }),
211
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "attribution", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
212
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "Attribution" }),
213
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_create_form_primitives.ToggleGroup, { value: field.value, options: ["Required", "Not Required"], onChange: field.onChange })
214
+ ] }) }),
215
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_collapsible.Collapsible, { open: advancedOpen, onOpenChange: setAdvancedOpen, children: [
216
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_collapsible.CollapsibleTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
217
+ "button",
218
+ {
219
+ type: "button",
220
+ className: "flex items-center gap-1.5 text-xs text-muted-foreground hover:text-foreground transition-colors",
221
+ children: [
222
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.ChevronDown, { className: (0, import_cn.cn)("h-3.5 w-3.5 transition-transform", advancedOpen && "rotate-180") }),
223
+ "Advanced options"
224
+ ]
225
+ }
226
+ ) }),
227
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_collapsible.CollapsibleContent, { className: "space-y-4 pt-3", children: [
228
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "geographicScope", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
229
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "Territory" }),
230
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_input.Input, { placeholder: "Worldwide", ...field }) })
231
+ ] }) }),
232
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "aiPolicy", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
233
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "AI & Data Mining" }),
234
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_create_form_primitives.ToggleGroup, { value: field.value, options: import_ip.AI_POLICIES, onChange: field.onChange })
235
+ ] }) }),
236
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "royalty", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
237
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "Royalty % (0-50)" }),
238
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
239
+ import_input.Input,
240
+ {
241
+ type: "number",
242
+ min: 0,
243
+ max: 50,
244
+ step: 0.5,
245
+ placeholder: "0",
246
+ ...field,
247
+ onChange: (event) => field.onChange(parseFloat(event.target.value) || 0)
248
+ }
249
+ ) }),
250
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormMessage, {})
251
+ ] }) })
252
+ ] })
253
+ ] })
254
+ ]
255
+ }
256
+ ) }),
257
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_motion_primitives.FadeIn, { delay: 0.2, children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
258
+ import_collapsible_section.CollapsibleSection,
259
+ {
260
+ open: ipTypeOpen,
261
+ onOpenChange: setIpTypeOpen,
262
+ icon: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.Layers, { className: "h-4 w-4 text-primary" }),
263
+ label: "IP Type & Metadata",
264
+ hint: "Optional",
265
+ children: [
266
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: "text-xs text-muted-foreground", children: "Choose a content type, fill suggested metadata, or add your own trait pairs." }),
267
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormField, { control: form.control, name: "ipType", render: ({ field }) => /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_form.FormItem, { children: [
268
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormLabel, { children: "IP Type" }),
269
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_select.Select, { onValueChange: field.onChange, value: field.value, children: [
270
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_form.FormControl, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_select.SelectTrigger, { children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_select.SelectValue, {}) }) }),
271
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_select.SelectContent, { children: import_ip.IP_TYPES.map((type) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_select.SelectItem, { value: type, children: type }, type)) })
272
+ ] })
273
+ ] }) }),
274
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
275
+ import_ip_type_fields.IPTypeFields,
276
+ {
277
+ ipType: form.watch("ipType"),
278
+ onChange: onMetadataFieldsChange,
279
+ uploadDocument
280
+ },
281
+ metadataResetKey
282
+ )
283
+ ]
284
+ }
285
+ ) }),
286
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_motion_primitives.FadeIn, { delay: 0.22, children: [
287
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
288
+ import_button.Button,
289
+ {
290
+ type: "submit",
291
+ size: "lg",
292
+ className: "w-full rounded-xl mt-2",
293
+ disabled: mintDisabled,
294
+ children: [
295
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.Sparkles, { className: "h-4 w-4 mr-2" }),
296
+ "Mint Edition"
297
+ ]
298
+ }
299
+ ),
300
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: "text-xs text-center text-muted-foreground mt-2", children: "Free to mint \u2014 protocol fee is zero." })
301
+ ] })
302
+ ] });
303
+ }
304
+ // Annotate the CommonJS export names for ESM import in node:
305
+ 0 && (module.exports = {
306
+ EditionMintFields
307
+ });
308
+ //# sourceMappingURL=edition-mint-fields.cjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../../src/components/launchpad/edition-mint-fields.tsx"],"sourcesContent":["\"use client\";\n\nimport { useState, type RefObject } from \"react\";\nimport type { UseFormReturn } from \"react-hook-form\";\nimport { ChevronDown, ImagePlus, Layers, Loader2, ShieldCheck, Sparkles, X } from \"lucide-react\";\nimport { acceptFor } from \"@medialane/sdk\";\nimport Image from \"../image.js\";\nimport { Button } from \"../button.js\";\nimport { Input } from \"../input.js\";\nimport { Textarea } from \"../textarea.js\";\nimport { Collapsible, CollapsibleContent, CollapsibleTrigger } from \"../collapsible.js\";\nimport { CollapsibleSection } from \"../collapsible-section.js\";\nimport { FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage } from \"../form.js\";\nimport { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from \"../select.js\";\nimport { FadeIn } from \"../motion-primitives.js\";\nimport { IPTypeFields, type MetadataField } from \"../ip-type-fields.js\";\nimport { ToggleGroup } from \"../create-form-primitives.js\";\nimport { AI_POLICIES, DERIVATIVES_OPTIONS, IP_TYPES, LICENSE_TYPES, type IPType } from \"../../data/ip.js\";\nimport { cn } from \"../../utils/cn.js\";\nimport type { EditionMintValues } from \"./edition-mint-schema.js\";\n\ninterface EditionMintFieldsProps {\n form: UseFormReturn<EditionMintValues>;\n imagePreview: string | null;\n imageUri: string | null;\n imageUploading: boolean;\n mintDisabled: boolean;\n fileInputRef: RefObject<HTMLInputElement | null>;\n onImageSelect: (file: File) => void;\n onClearImage: () => void;\n metadataResetKey: number;\n onMetadataFieldsChange: (fields: MetadataField[]) => void;\n uploadDocument: (file: File) => Promise<string>;\n}\n\nexport function EditionMintFields({\n form,\n imagePreview,\n imageUri,\n imageUploading,\n mintDisabled,\n fileInputRef,\n onImageSelect,\n onClearImage,\n metadataResetKey,\n onMetadataFieldsChange,\n uploadDocument,\n}: EditionMintFieldsProps) {\n const [licensingOpen, setLicensingOpen] = useState(false);\n const [advancedOpen, setAdvancedOpen] = useState(false);\n const [ipTypeOpen, setIpTypeOpen] = useState(false);\n\n const handleLicenseChange = (value: string) => {\n form.setValue(\"licenseType\", value);\n const preset = LICENSE_TYPES.find((license) => license.value === value);\n if (preset) {\n form.setValue(\"commercialUse\", preset.commercialUse);\n form.setValue(\"derivatives\", preset.derivatives);\n form.setValue(\"attribution\", preset.attribution);\n }\n };\n\n return (\n <div className=\"space-y-5\">\n <FadeIn delay={0.06}>\n <div className=\"space-y-2\">\n <p className=\"text-sm font-medium\">\n Asset image <span className=\"text-destructive\">*</span>\n </p>\n <div className=\"flex items-center gap-4\">\n <div\n role=\"button\"\n tabIndex={0}\n onClick={() => !imageUploading && fileInputRef.current?.click()}\n onKeyDown={(event) => { if (event.key === \"Enter\") fileInputRef.current?.click(); }}\n className=\"relative h-20 w-20 rounded-2xl border-2 border-dashed border-border bg-muted flex items-center justify-center overflow-hidden shrink-0 cursor-pointer hover:border-brand-purple/50 transition-colors\"\n >\n {imagePreview ? (\n <Image src={imagePreview} alt=\"Token\" fill unoptimized className=\"object-cover\" />\n ) : (\n <ImagePlus className=\"h-6 w-6 text-muted-foreground\" />\n )}\n {imageUploading ? (\n <div className=\"absolute inset-0 bg-background/70 flex items-center justify-center\">\n <Loader2 className=\"h-4 w-4 animate-spin\" />\n </div>\n ) : null}\n </div>\n <div className=\"space-y-1.5\">\n <input\n ref={fileInputRef}\n type=\"file\"\n accept={acceptFor(\"image\")}\n className=\"hidden\"\n onChange={(event) => {\n const file = event.target.files?.[0];\n if (file) onImageSelect(file);\n }}\n />\n <Button\n type=\"button\"\n variant=\"outline\"\n size=\"sm\"\n disabled={imageUploading}\n onClick={() => fileInputRef.current?.click()}\n >\n {imageUploading ? (\n <>\n <Loader2 className=\"h-3.5 w-3.5 mr-1.5 animate-spin\" />\n Uploading…\n </>\n ) : (\n imagePreview ? \"Change\" : \"Upload image\"\n )}\n </Button>\n {imagePreview ? (\n <button\n type=\"button\"\n onClick={onClearImage}\n className=\"flex items-center gap-1 text-xs text-muted-foreground hover:text-destructive transition-colors\"\n >\n <X className=\"h-3 w-3\" /> Remove\n </button>\n ) : null}\n <p className=\"text-xs text-muted-foreground\">\n {imageUri ? (\n <span className=\"text-brand-purple\">✓ Uploaded</span>\n ) : (\n \"JPG, PNG, SVG or WebP\"\n )}\n </p>\n <p className=\"text-xs text-muted-foreground\">This media and metadata are pinned before the first mint is submitted.</p>\n </div>\n </div>\n </div>\n </FadeIn>\n\n <FadeIn delay={0.08}>\n <FormField control={form.control} name=\"name\" render={({ field }) => (\n <FormItem>\n <FormLabel>Token name *</FormLabel>\n <FormControl><Input placeholder=\"Genesis Track #1\" {...field} /></FormControl>\n <FormDescription>The title collectors will see for this edition.</FormDescription>\n <FormMessage />\n </FormItem>\n )} />\n </FadeIn>\n\n <FadeIn delay={0.1}>\n <FormField control={form.control} name=\"description\" render={({ field }) => (\n <FormItem>\n <FormLabel>Description <span className=\"text-muted-foreground font-normal\">(optional)</span></FormLabel>\n <FormControl>\n <Textarea placeholder=\"Describe this digital asset…\" rows={3} {...field} />\n </FormControl>\n <FormDescription>Add context, utility, or creative notes for this token edition.</FormDescription>\n <FormMessage />\n </FormItem>\n )} />\n </FadeIn>\n\n <FadeIn delay={0.12}>\n <FormField control={form.control} name=\"external_url\" render={({ field }) => (\n <FormItem>\n <FormLabel>External link <span className=\"text-muted-foreground font-normal\">(optional)</span></FormLabel>\n <FormControl><Input placeholder=\"https://yourwebsite.com\" {...field} /></FormControl>\n <FormDescription>Canonical link for this edition.</FormDescription>\n <FormMessage />\n </FormItem>\n )} />\n </FadeIn>\n\n <FadeIn delay={0.14}>\n <FormField control={form.control} name=\"value\" render={({ field }) => (\n <FormItem>\n <FormLabel>Quantity *</FormLabel>\n <FormControl>\n <Input type=\"number\" min={1} placeholder=\"1\" className=\"max-w-[180px]\" {...field} />\n </FormControl>\n <FormDescription>Number of copies to mint for this token ID.</FormDescription>\n <FormMessage />\n </FormItem>\n )} />\n </FadeIn>\n\n <FadeIn delay={0.16}>\n <FormField control={form.control} name=\"recipient\" render={({ field }) => (\n <FormItem>\n <FormLabel>Recipient *</FormLabel>\n <FormControl>\n <Input placeholder=\"0x…\" {...field} />\n </FormControl>\n <FormDescription>Account that receives the minted tokens. Defaults to your account.</FormDescription>\n <FormMessage />\n </FormItem>\n )} />\n </FadeIn>\n\n <FadeIn delay={0.18}>\n <CollapsibleSection\n open={licensingOpen}\n onOpenChange={setLicensingOpen}\n icon={<ShieldCheck className=\"h-4 w-4 text-primary\" />}\n label=\"Licensing Terms\"\n hint=\"Optional · Berne Convention\"\n >\n <p className=\"text-xs text-muted-foreground\">\n Set the licensing terms for this edition — saved permanently with it.\n </p>\n\n <FormField control={form.control} name=\"licenseType\" render={({ field }) => (\n <FormItem>\n <FormLabel>License</FormLabel>\n <Select value={field.value} onValueChange={handleLicenseChange}>\n <FormControl>\n <SelectTrigger><SelectValue /></SelectTrigger>\n </FormControl>\n <SelectContent>\n {LICENSE_TYPES.map((license) => (\n <SelectItem key={license.value} value={license.value}>{license.label}</SelectItem>\n ))}\n </SelectContent>\n </Select>\n {(() => {\n const preset = LICENSE_TYPES.find((license) => license.value === field.value);\n return preset ? <p className=\"text-xs text-muted-foreground mt-1\">{preset.description}</p> : null;\n })()}\n <FormMessage />\n </FormItem>\n )} />\n\n <FormField control={form.control} name=\"commercialUse\" render={({ field }) => (\n <FormItem>\n <FormLabel>Commercial Use</FormLabel>\n <ToggleGroup value={field.value} options={[\"Yes\", \"No\"]} onChange={field.onChange} />\n </FormItem>\n )} />\n\n <FormField control={form.control} name=\"derivatives\" render={({ field }) => (\n <FormItem>\n <FormLabel>Derivatives</FormLabel>\n <ToggleGroup value={field.value} options={DERIVATIVES_OPTIONS} onChange={field.onChange} />\n </FormItem>\n )} />\n\n <FormField control={form.control} name=\"attribution\" render={({ field }) => (\n <FormItem>\n <FormLabel>Attribution</FormLabel>\n <ToggleGroup value={field.value} options={[\"Required\", \"Not Required\"]} onChange={field.onChange} />\n </FormItem>\n )} />\n\n <Collapsible open={advancedOpen} onOpenChange={setAdvancedOpen}>\n <CollapsibleTrigger asChild>\n <button\n type=\"button\"\n className=\"flex items-center gap-1.5 text-xs text-muted-foreground hover:text-foreground transition-colors\"\n >\n <ChevronDown className={cn(\"h-3.5 w-3.5 transition-transform\", advancedOpen && \"rotate-180\")} />\n Advanced options\n </button>\n </CollapsibleTrigger>\n <CollapsibleContent className=\"space-y-4 pt-3\">\n <FormField control={form.control} name=\"geographicScope\" render={({ field }) => (\n <FormItem>\n <FormLabel>Territory</FormLabel>\n <FormControl>\n <Input placeholder=\"Worldwide\" {...field} />\n </FormControl>\n </FormItem>\n )} />\n\n <FormField control={form.control} name=\"aiPolicy\" render={({ field }) => (\n <FormItem>\n <FormLabel>AI &amp; Data Mining</FormLabel>\n <ToggleGroup value={field.value} options={AI_POLICIES} onChange={field.onChange} />\n </FormItem>\n )} />\n\n <FormField control={form.control} name=\"royalty\" render={({ field }) => (\n <FormItem>\n <FormLabel>Royalty % (0-50)</FormLabel>\n <FormControl>\n <Input\n type=\"number\"\n min={0}\n max={50}\n step={0.5}\n placeholder=\"0\"\n {...field}\n onChange={(event) => field.onChange(parseFloat(event.target.value) || 0)}\n />\n </FormControl>\n <FormMessage />\n </FormItem>\n )} />\n </CollapsibleContent>\n </Collapsible>\n </CollapsibleSection>\n </FadeIn>\n\n <FadeIn delay={0.2}>\n <CollapsibleSection\n open={ipTypeOpen}\n onOpenChange={setIpTypeOpen}\n icon={<Layers className=\"h-4 w-4 text-primary\" />}\n label=\"IP Type &amp; Metadata\"\n hint=\"Optional\"\n >\n <p className=\"text-xs text-muted-foreground\">\n Choose a content type, fill suggested metadata, or add your own trait pairs.\n </p>\n\n <FormField control={form.control} name=\"ipType\" render={({ field }) => (\n <FormItem>\n <FormLabel>IP Type</FormLabel>\n <Select onValueChange={field.onChange} value={field.value}>\n <FormControl>\n <SelectTrigger><SelectValue /></SelectTrigger>\n </FormControl>\n <SelectContent>\n {IP_TYPES.map((type) => (\n <SelectItem key={type} value={type}>{type}</SelectItem>\n ))}\n </SelectContent>\n </Select>\n </FormItem>\n )} />\n\n <IPTypeFields\n key={metadataResetKey}\n ipType={form.watch(\"ipType\") as IPType}\n onChange={onMetadataFieldsChange}\n uploadDocument={uploadDocument}\n />\n </CollapsibleSection>\n </FadeIn>\n\n <FadeIn delay={0.22}>\n <Button\n type=\"submit\"\n size=\"lg\"\n className=\"w-full rounded-xl mt-2\"\n disabled={mintDisabled}\n >\n <Sparkles className=\"h-4 w-4 mr-2\" />\n Mint Edition\n </Button>\n <p className=\"text-xs text-center text-muted-foreground mt-2\">\n Free to mint — protocol fee is zero.\n </p>\n </FadeIn>\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAkEU;AAhEV,mBAAyC;AAEzC,0BAAkF;AAClF,iBAA0B;AAC1B,mBAAkB;AAClB,oBAAuB;AACvB,mBAAsB;AACtB,sBAAyB;AACzB,yBAAoE;AACpE,iCAAmC;AACnC,kBAA0F;AAC1F,oBAA8E;AAC9E,+BAAuB;AACvB,4BAAiD;AACjD,oCAA4B;AAC5B,gBAAuF;AACvF,gBAAmB;AAiBZ,SAAS,kBAAkB;AAAA,EAChC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAA2B;AACzB,QAAM,CAAC,eAAe,gBAAgB,QAAI,uBAAS,KAAK;AACxD,QAAM,CAAC,cAAc,eAAe,QAAI,uBAAS,KAAK;AACtD,QAAM,CAAC,YAAY,aAAa,QAAI,uBAAS,KAAK;AAElD,QAAM,sBAAsB,CAAC,UAAkB;AAC7C,SAAK,SAAS,eAAe,KAAK;AAClC,UAAM,SAAS,wBAAc,KAAK,CAAC,YAAY,QAAQ,UAAU,KAAK;AACtE,QAAI,QAAQ;AACV,WAAK,SAAS,iBAAiB,OAAO,aAAa;AACnD,WAAK,SAAS,eAAe,OAAO,WAAW;AAC/C,WAAK,SAAS,eAAe,OAAO,WAAW;AAAA,IACjD;AAAA,EACF;AAEA,SACE,6CAAC,SAAI,WAAU,aACb;AAAA,gDAAC,m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M;AAAA,QACN,MAAK;AAAA,QAEC;AAAA,sDAAC,OAAE,WAAU,iCAAgC,0FAE7C;AAAA,UAEA,4CAAC,yBAAU,SAAS,KAAK,SAAS,MAAK,UAAS,QAAQ,CAAC,EAAE,MAAM,MAC/D,6CAAC,wBACC;AAAA,wDAAC,yBAAU,qBAAO;AAAA,YAClB,6CAAC,wBAAO,eAAe,MAAM,UAAU,OAAO,MAAM,OAClD;AAAA,0DAAC,2BACC,sDAAC,+BAAc,sDAAC,6BAAY,GAAE,GAChC;AAAA,cACA,4CAAC,+BACE,6BAAS,IAAI,CAAC,SACb,4CAAC,4BAAsB,OAAO,MAAO,kBAApB,IAAyB,CAC3C,GACH;AAAA,eACF;AAAA,aACF,GACC;AAAA,UAEH;AAAA,YAAC;AAAA;AAAA,cAEC,QAAQ,KAAK,MAAM,QAAQ;AAAA,cAC3B,UAAU;AAAA,cACV;AAAA;AAAA,YAHK;AAAA,UAIP;AAAA;AAAA;AAAA,IACR,GACF;AAAA,IAEA,6CAAC,mCAAO,OAAO,MACb;AAAA;AAAA,QAAC;AAAA;AAAA,UACC,MAAK;AAAA,UACL,MAAK;AAAA,UACL,WAAU;AAAA,UACV,UAAU;AAAA,UAEV;AAAA,wDAAC,gCAAS,WAAU,gBAAe;AAAA,YAAE;AAAA;AAAA;AAAA,MAEvC;AAAA,MACA,4CAAC,OAAE,WAAU,kDAAiD,uDAE9D;AAAA,OACF;AAAA,KACF;AAEJ;","names":["Image"]}
@@ -0,0 +1,24 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { RefObject } from 'react';
3
+ import { UseFormReturn } from 'react-hook-form';
4
+ import { MetadataField } from '../ip-type-fields.cjs';
5
+ import { EditionMintValues } from './edition-mint-schema.cjs';
6
+ import '../../data/ip.cjs';
7
+ import 'zod';
8
+
9
+ interface EditionMintFieldsProps {
10
+ form: UseFormReturn<EditionMintValues>;
11
+ imagePreview: string | null;
12
+ imageUri: string | null;
13
+ imageUploading: boolean;
14
+ mintDisabled: boolean;
15
+ fileInputRef: RefObject<HTMLInputElement | null>;
16
+ onImageSelect: (file: File) => void;
17
+ onClearImage: () => void;
18
+ metadataResetKey: number;
19
+ onMetadataFieldsChange: (fields: MetadataField[]) => void;
20
+ uploadDocument: (file: File) => Promise<string>;
21
+ }
22
+ declare function EditionMintFields({ form, imagePreview, imageUri, imageUploading, mintDisabled, fileInputRef, onImageSelect, onClearImage, metadataResetKey, onMetadataFieldsChange, uploadDocument, }: EditionMintFieldsProps): react_jsx_runtime.JSX.Element;
23
+
24
+ export { EditionMintFields };
@@ -0,0 +1,24 @@
1
+ import * as react_jsx_runtime from 'react/jsx-runtime';
2
+ import { RefObject } from 'react';
3
+ import { UseFormReturn } from 'react-hook-form';
4
+ import { MetadataField } from '../ip-type-fields.js';
5
+ import { EditionMintValues } from './edition-mint-schema.js';
6
+ import '../../data/ip.js';
7
+ import 'zod';
8
+
9
+ interface EditionMintFieldsProps {
10
+ form: UseFormReturn<EditionMintValues>;
11
+ imagePreview: string | null;
12
+ imageUri: string | null;
13
+ imageUploading: boolean;
14
+ mintDisabled: boolean;
15
+ fileInputRef: RefObject<HTMLInputElement | null>;
16
+ onImageSelect: (file: File) => void;
17
+ onClearImage: () => void;
18
+ metadataResetKey: number;
19
+ onMetadataFieldsChange: (fields: MetadataField[]) => void;
20
+ uploadDocument: (file: File) => Promise<string>;
21
+ }
22
+ declare function EditionMintFields({ form, imagePreview, imageUri, imageUploading, mintDisabled, fileInputRef, onImageSelect, onClearImage, metadataResetKey, onMetadataFieldsChange, uploadDocument, }: EditionMintFieldsProps): react_jsx_runtime.JSX.Element;
23
+
24
+ export { EditionMintFields };