@medialane/ui 0.355.0 → 0.357.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 (35) 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/button.d.cts +1 -1
  4. package/dist/components/button.d.ts +1 -1
  5. package/dist/components/collection-page.cjs +2 -5
  6. package/dist/components/collection-page.cjs.map +1 -1
  7. package/dist/components/collection-page.js +2 -5
  8. package/dist/components/collection-page.js.map +1 -1
  9. package/dist/components/collection-showcase.cjs +28 -7
  10. package/dist/components/collection-showcase.cjs.map +1 -1
  11. package/dist/components/collection-showcase.js +28 -7
  12. package/dist/components/collection-showcase.js.map +1 -1
  13. package/dist/components/launchpad/edition-mint-schema.d.cts +4 -4
  14. package/dist/components/launchpad/edition-mint-schema.d.ts +4 -4
  15. package/dist/components/more-menu.cjs +16 -1
  16. package/dist/components/more-menu.cjs.map +1 -1
  17. package/dist/components/more-menu.d.cts +2 -1
  18. package/dist/components/more-menu.d.ts +2 -1
  19. package/dist/components/more-menu.js +7 -2
  20. package/dist/components/more-menu.js.map +1 -1
  21. package/dist/index.cjs +0 -3
  22. package/dist/index.cjs.map +1 -1
  23. package/dist/index.d.cts +0 -1
  24. package/dist/index.d.ts +0 -1
  25. package/dist/index.js +0 -2
  26. package/dist/index.js.map +1 -1
  27. package/dist/utils/media-wallet/use-erc20-balance.d.cts +1 -1
  28. package/dist/utils/media-wallet/use-erc20-balance.d.ts +1 -1
  29. package/package.json +1 -1
  30. package/dist/components/owner-setup-panel.cjs +0 -91
  31. package/dist/components/owner-setup-panel.cjs.map +0 -1
  32. package/dist/components/owner-setup-panel.d.cts +0 -10
  33. package/dist/components/owner-setup-panel.d.ts +0 -10
  34. package/dist/components/owner-setup-panel.js +0 -57
  35. package/dist/components/owner-setup-panel.js.map +0 -1
@@ -15,7 +15,7 @@ function offsetFrom(index, current, count) {
15
15
  return distance > count / 2 ? distance - count : distance;
16
16
  }
17
17
  function ShowcaseSkeleton() {
18
- return /* @__PURE__ */ jsxs("section", { className: "px-4 pb-8 pt-10 sm:pt-14", children: [
18
+ return /* @__PURE__ */ jsxs("section", { className: "px-4 pb-8 pt-20 sm:pt-14", children: [
19
19
  /* @__PURE__ */ jsx(Skeleton, { className: cn("mx-auto rounded-2xl", CARD_SIZE) }),
20
20
  /* @__PURE__ */ jsx(Skeleton, { className: "mx-auto mt-6 h-9 w-56" })
21
21
  ] });
@@ -25,14 +25,20 @@ function CollectionShowcase({ collections, isLoading, getHref }) {
25
25
  const reduceMotion = useReducedMotion();
26
26
  const [current, setCurrent] = useState(0);
27
27
  const [paused, setPaused] = useState(false);
28
+ const [hidden, setHidden] = useState(false);
28
29
  const dragged = useRef(false);
29
30
  const count = collections.length;
30
31
  const go = (step) => setCurrent((index) => (index + step + count) % count);
31
32
  useEffect(() => {
32
- if (count <= 1 || paused || reduceMotion) return;
33
+ const onVisibility = () => setHidden(document.hidden);
34
+ document.addEventListener("visibilitychange", onVisibility);
35
+ return () => document.removeEventListener("visibilitychange", onVisibility);
36
+ }, []);
37
+ useEffect(() => {
38
+ if (count <= 1 || paused || hidden || reduceMotion) return;
33
39
  const id = setInterval(() => setCurrent((index) => (index + 1) % count), AUTOPLAY_MS);
34
40
  return () => clearInterval(id);
35
- }, [count, paused, reduceMotion]);
41
+ }, [count, paused, hidden, reduceMotion]);
36
42
  if (isLoading) return /* @__PURE__ */ jsx(ShowcaseSkeleton, {});
37
43
  if (count === 0) return null;
38
44
  const active = collections[current % count];
@@ -42,7 +48,7 @@ function CollectionShowcase({ collections, isLoading, getHref }) {
42
48
  return /* @__PURE__ */ jsxs(
43
49
  "section",
44
50
  {
45
- className: "relative overflow-hidden px-4 pb-8 pt-10 sm:pt-14",
51
+ className: "relative overflow-hidden px-4 pb-8 pt-20 sm:pt-14",
46
52
  onPointerEnter: () => setPaused(true),
47
53
  onPointerLeave: () => setPaused(false),
48
54
  onFocus: () => setPaused(true),
@@ -52,7 +58,7 @@ function CollectionShowcase({ collections, isLoading, getHref }) {
52
58
  motion.div,
53
59
  {
54
60
  "aria-hidden": true,
55
- className: "pointer-events-none absolute inset-0 scale-125 opacity-30 blur-3xl dark:opacity-40",
61
+ className: "pointer-events-none absolute inset-0 scale-125 opacity-30 blur-3xl [-webkit-mask-image:linear-gradient(to_bottom,transparent_72px,black_220px)] [mask-image:linear-gradient(to_bottom,transparent_72px,black_220px)] dark:opacity-40",
56
62
  initial: reduceMotion ? false : { opacity: 0 },
57
63
  animate: { opacity: 1 },
58
64
  transition: { duration: 0.6 },
@@ -64,7 +70,21 @@ function CollectionShowcase({ collections, isLoading, getHref }) {
64
70
  /* @__PURE__ */ jsx(
65
71
  motion.div,
66
72
  {
67
- className: cn("relative mx-auto touch-pan-y", CARD_SIZE),
73
+ role: "group",
74
+ "aria-roledescription": "carousel",
75
+ "aria-label": "Featured collections",
76
+ tabIndex: count > 1 ? 0 : -1,
77
+ onKeyDown: (event) => {
78
+ if (count <= 1) return;
79
+ if (event.key === "ArrowLeft") {
80
+ event.preventDefault();
81
+ go(-1);
82
+ } else if (event.key === "ArrowRight") {
83
+ event.preventDefault();
84
+ go(1);
85
+ }
86
+ },
87
+ className: cn("relative mx-auto touch-pan-y rounded-2xl focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-4 focus-visible:ring-offset-background", CARD_SIZE),
68
88
  drag: count > 1 ? "x" : false,
69
89
  dragConstraints: { left: 0, right: 0 },
70
90
  dragElastic: 0.2,
@@ -108,7 +128,7 @@ function CollectionShowcase({ collections, isLoading, getHref }) {
108
128
  className: "relative block h-full w-full overflow-hidden rounded-2xl bg-muted shadow-2xl shadow-black/20 ring-1 ring-border dark:shadow-black/50",
109
129
  children: [
110
130
  image ? /* @__PURE__ */ jsx(Image, { src: image, alt: "", fill: true, sizes: "(min-width: 1024px) 340px, 58vw", className: "object-cover", priority: index === 0, unoptimized: true }) : /* @__PURE__ */ jsx("div", { className: "absolute inset-0 bg-gradient-to-br from-brand-purple/40 via-brand-blue/20 to-brand-navy/60" }),
111
- /* @__PURE__ */ jsx("span", { className: cn("absolute inset-0 bg-background/40 transition-opacity duration-500", offset === 0 ? "opacity-0" : "opacity-100") })
131
+ /* @__PURE__ */ jsx("span", { className: cn("absolute inset-0 bg-black/30 transition-opacity duration-500", offset === 0 ? "opacity-0" : "opacity-100") })
112
132
  ]
113
133
  }
114
134
  )
@@ -121,6 +141,7 @@ function CollectionShowcase({ collections, isLoading, getHref }) {
121
141
  /* @__PURE__ */ jsxs(
122
142
  motion.div,
123
143
  {
144
+ "aria-live": paused ? "polite" : "off",
124
145
  className: "relative mt-8 flex flex-col items-center gap-1 text-center",
125
146
  initial: reduceMotion ? false : { opacity: 0, y: 8 },
126
147
  animate: { opacity: 1, y: 0 },
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/components/collection-showcase.tsx"],"sourcesContent":["\"use client\";\n\nimport { useEffect, useRef, useState } from \"react\";\nimport { motion, useReducedMotion } from \"framer-motion\";\nimport type { ApiCollection } from \"@medialane/sdk\";\nimport Link from \"./link.js\";\nimport Image from \"./image.js\";\nimport { Skeleton } from \"./skeleton.js\";\nimport { cn } from \"../utils/cn.js\";\nimport { useImageUrl } from \"../utils/use-image-url.js\";\n\nexport interface CollectionShowcaseProps {\n collections: ApiCollection[];\n isLoading: boolean;\n getHref: (collection: ApiCollection) => string;\n}\n\nconst AUTOPLAY_MS = 6000;\nconst SWIPE_PX = 50;\nconst CARD_SIZE = \"aspect-[4/5] w-[58vw] max-w-[260px] sm:max-w-[300px] lg:max-w-[340px]\";\n\nfunction offsetFrom(index: number, current: number, count: number) {\n const distance = (index - current + count) % count;\n return distance > count / 2 ? distance - count : distance;\n}\n\nfunction ShowcaseSkeleton() {\n return (\n <section className=\"px-4 pb-8 pt-10 sm:pt-14\">\n <Skeleton className={cn(\"mx-auto rounded-2xl\", CARD_SIZE)} />\n <Skeleton className=\"mx-auto mt-6 h-9 w-56\" />\n </section>\n );\n}\n\nexport function CollectionShowcase({ collections, isLoading, getHref }: CollectionShowcaseProps) {\n const resolveImage = useImageUrl();\n const reduceMotion = useReducedMotion();\n const [current, setCurrent] = useState(0);\n const [paused, setPaused] = useState(false);\n const dragged = useRef(false);\n const count = collections.length;\n\n const go = (step: number) => setCurrent((index) => (index + step + count) % count);\n\n useEffect(() => {\n if (count <= 1 || paused || reduceMotion) return;\n const id = setInterval(() => setCurrent((index) => (index + 1) % count), AUTOPLAY_MS);\n return () => clearInterval(id);\n }, [count, paused, reduceMotion]);\n\n if (isLoading) return <ShowcaseSkeleton />;\n if (count === 0) return null;\n\n const active = collections[current % count]!;\n const activeImage = resolveImage(active.image, { width: 960 });\n const supply = active.totalSupply;\n const transition = reduceMotion ? { duration: 0 } : { type: \"spring\" as const, stiffness: 220, damping: 26 };\n\n return (\n <section\n className=\"relative overflow-hidden px-4 pb-8 pt-10 sm:pt-14\"\n onPointerEnter={() => setPaused(true)}\n onPointerLeave={() => setPaused(false)}\n onFocus={() => setPaused(true)}\n onBlur={() => setPaused(false)}\n >\n {activeImage && (\n <motion.div\n key={active.contractAddress}\n aria-hidden\n className=\"pointer-events-none absolute inset-0 scale-125 opacity-30 blur-3xl dark:opacity-40\"\n initial={reduceMotion ? false : { opacity: 0 }}\n animate={{ opacity: 1 }}\n transition={{ duration: 0.6 }}\n >\n <Image src={activeImage} alt=\"\" fill className=\"object-cover\" unoptimized />\n </motion.div>\n )}\n <div aria-hidden className=\"pointer-events-none absolute inset-x-0 bottom-0 h-1/2 bg-gradient-to-b from-transparent to-background\" />\n\n <motion.div\n className={cn(\"relative mx-auto touch-pan-y\", CARD_SIZE)}\n drag={count > 1 ? \"x\" : false}\n dragConstraints={{ left: 0, right: 0 }}\n dragElastic={0.2}\n onDragStart={() => { dragged.current = true; }}\n onDragEnd={(_, info) => {\n if (info.offset.x < -SWIPE_PX) go(1);\n else if (info.offset.x > SWIPE_PX) go(-1);\n setTimeout(() => { dragged.current = false; }, 0);\n }}\n >\n {collections.map((collection, index) => {\n const offset = offsetFrom(index, current, count);\n const distance = Math.abs(offset);\n const image = resolveImage(collection.image, { width: 640 });\n const name = collection.name ?? \"Collection\";\n return (\n <motion.div\n key={collection.contractAddress}\n className={cn(\"absolute inset-0\", distance > 2 && \"pointer-events-none\")}\n initial={false}\n animate={{\n x: `${offset * 58}%`,\n rotate: offset * 9,\n scale: 1 - distance * 0.12,\n opacity: distance > 2 ? 0 : 1,\n zIndex: 10 - distance,\n }}\n transition={transition}\n >\n <Link\n href={getHref(collection)}\n aria-label={name}\n draggable={false}\n onClick={(event) => { if (dragged.current) event.preventDefault(); }}\n className=\"relative block h-full w-full overflow-hidden rounded-2xl bg-muted shadow-2xl shadow-black/20 ring-1 ring-border dark:shadow-black/50\"\n >\n {image ? (\n <Image src={image} alt=\"\" fill sizes=\"(min-width: 1024px) 340px, 58vw\" className=\"object-cover\" priority={index === 0} unoptimized />\n ) : (\n <div className=\"absolute inset-0 bg-gradient-to-br from-brand-purple/40 via-brand-blue/20 to-brand-navy/60\" />\n )}\n <span className={cn(\"absolute inset-0 bg-background/40 transition-opacity duration-500\", offset === 0 ? \"opacity-0\" : \"opacity-100\")} />\n </Link>\n </motion.div>\n );\n })}\n </motion.div>\n\n <motion.div\n key={active.contractAddress}\n className=\"relative mt-8 flex flex-col items-center gap-1 text-center\"\n initial={reduceMotion ? false : { opacity: 0, y: 8 }}\n animate={{ opacity: 1, y: 0 }}\n transition={{ duration: 0.4 }}\n >\n <Link href={getHref(active)} className=\"transition-opacity hover:opacity-80\">\n <h2 className=\"text-3xl font-semibold leading-tight tracking-tight text-foreground sm:text-4xl lg:text-5xl\">\n {active.name ?? \"Collection\"}\n </h2>\n </Link>\n {supply != null && (\n <p className=\"text-sm text-muted-foreground\">\n {supply.toLocaleString()} {supply === 1 ? \"item\" : \"items\"}\n </p>\n )}\n </motion.div>\n\n {count > 1 && (\n <div className=\"relative mt-3 flex justify-center\">\n {collections.map((collection, index) => (\n <button\n key={collection.contractAddress}\n type=\"button\"\n aria-label={`Show ${collection.name ?? \"collection\"}`}\n aria-current={index === current ? \"true\" : undefined}\n onClick={() => setCurrent(index)}\n className=\"flex h-8 items-center px-0.5\"\n >\n <span className={cn(\"h-1.5 rounded-full transition-all\", index === current ? \"w-6 bg-foreground\" : \"w-1.5 bg-foreground/30\")} />\n </button>\n ))}\n </div>\n )}\n </section>\n );\n}\n"],"mappings":";AA4BI,SACE,KADF;AA1BJ,SAAS,WAAW,QAAQ,gBAAgB;AAC5C,SAAS,QAAQ,wBAAwB;AAEzC,OAAO,UAAU;AACjB,OAAO,WAAW;AAClB,SAAS,gBAAgB;AACzB,SAAS,UAAU;AACnB,SAAS,mBAAmB;AAQ5B,MAAM,cAAc;AACpB,MAAM,WAAW;AACjB,MAAM,YAAY;AAElB,SAAS,WAAW,OAAe,SAAiB,OAAe;AACjE,QAAM,YAAY,QAAQ,UAAU,SAAS;AAC7C,SAAO,WAAW,QAAQ,IAAI,WAAW,QAAQ;AACnD;AAEA,SAAS,mBAAmB;AAC1B,SACE,qBAAC,aAAQ,WAAU,4BACjB;AAAA,wBAAC,YAAS,WAAW,GAAG,uBAAuB,SAAS,GAAG;AAAA,IAC3D,oBAAC,YAAS,WAAU,yBAAwB;AAAA,KAC9C;AAEJ;AAEO,SAAS,mBAAmB,EAAE,aAAa,WAAW,QAAQ,GAA4B;AAC/F,QAAM,eAAe,YAAY;AACjC,QAAM,eAAe,iBAAiB;AACtC,QAAM,CAAC,SAAS,UAAU,IAAI,SAAS,CAAC;AACxC,QAAM,CAAC,QAAQ,SAAS,IAAI,SAAS,KAAK;AAC1C,QAAM,UAAU,OAAO,KAAK;AAC5B,QAAM,QAAQ,YAAY;AAE1B,QAAM,KAAK,CAAC,SAAiB,WAAW,CAAC,WAAW,QAAQ,OAAO,SAAS,KAAK;AAEjF,YAAU,MAAM;AACd,QAAI,SAAS,KAAK,UAAU,aAAc;AAC1C,UAAM,KAAK,YAAY,MAA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AAAA,kBACxI;AAAA;AAAA,gBAzBK,WAAW;AAAA,cA0BlB;AAAA,YAEJ,CAAC;AAAA;AAAA,QACH;AAAA,QAEA;AAAA,UAAC,OAAO;AAAA,UAAP;AAAA,YAEC,WAAU;AAAA,YACV,SAAS,eAAe,QAAQ,EAAE,SAAS,GAAG,GAAG,EAAE;AAAA,YACnD,SAAS,EAAE,SAAS,GAAG,GAAG,EAAE;AAAA,YAC5B,YAAY,EAAE,UAAU,IAAI;AAAA,YAE5B;AAAA,kCAAC,QAAK,MAAM,QAAQ,MAAM,GAAG,WAAU,uCACrC,8BAAC,QAAG,WAAU,+FACX,iBAAO,QAAQ,cAClB,GACF;AAAA,cACC,UAAU,QACT,qBAAC,OAAE,WAAU,iCACV;AAAA,uBAAO,eAAe;AAAA,gBAAE;AAAA,gBAAE,WAAW,IAAI,SAAS;AAAA,iBACrD;AAAA;AAAA;AAAA,UAdG,OAAO;AAAA,QAgBd;AAAA,QAEC,QAAQ,KACP,oBAAC,SAAI,WAAU,qCACZ,sBAAY,IAAI,CAAC,YAAY,UAC5B;AAAA,UAAC;AAAA;AAAA,YAEC,MAAK;AAAA,YACL,cAAY,QAAQ,WAAW,QAAQ,YAAY;AAAA,YACnD,gBAAc,UAAU,UAAU,SAAS;AAAA,YAC3C,SAAS,MAAM,WAAW,KAAK;AAAA,YAC/B,WAAU;AAAA,YAEV,8BAAC,UAAK,WAAW,GAAG,qCAAqC,UAAU,UAAU,sBAAsB,wBAAwB,GAAG;AAAA;AAAA,UAPzH,WAAW;AAAA,QAQlB,CACD,GACH;AAAA;AAAA;AAAA,EAEJ;AAEJ;","names":[]}
1
+ {"version":3,"sources":["../../src/components/collection-showcase.tsx"],"sourcesContent":["\"use client\";\n\nimport { useEffect, useRef, useState } from \"react\";\nimport { motion, useReducedMotion } from \"framer-motion\";\nimport type { ApiCollection } from \"@medialane/sdk\";\nimport Link from \"./link.js\";\nimport Image from \"./image.js\";\nimport { Skeleton } from \"./skeleton.js\";\nimport { cn } from \"../utils/cn.js\";\nimport { useImageUrl } from \"../utils/use-image-url.js\";\n\nexport interface CollectionShowcaseProps {\n collections: ApiCollection[];\n isLoading: boolean;\n getHref: (collection: ApiCollection) => string;\n}\n\nconst AUTOPLAY_MS = 6000;\nconst SWIPE_PX = 50;\nconst CARD_SIZE = \"aspect-[4/5] w-[58vw] max-w-[260px] sm:max-w-[300px] lg:max-w-[340px]\";\n\nfunction offsetFrom(index: number, current: number, count: number) {\n const distance = (index - current + count) % count;\n return distance > count / 2 ? distance - count : distance;\n}\n\nfunction ShowcaseSkeleton() {\n return (\n <section className=\"px-4 pb-8 pt-20 sm:pt-14\">\n <Skeleton className={cn(\"mx-auto rounded-2xl\", CARD_SIZE)} />\n <Skeleton className=\"mx-auto mt-6 h-9 w-56\" />\n </section>\n );\n}\n\nexport function CollectionShowcase({ collections, isLoading, getHref }: CollectionShowcaseProps) {\n const resolveImage = useImageUrl();\n const reduceMotion = useReducedMotion();\n const [current, setCurrent] = useState(0);\n const [paused, setPaused] = useState(false);\n const [hidden, setHidden] = useState(false);\n const dragged = useRef(false);\n const count = collections.length;\n\n const go = (step: number) => setCurrent((index) => (index + step + count) % count);\n\n useEffect(() => {\n const onVisibility = () => setHidden(document.hidden);\n document.addEventListener(\"visibilitychange\", onVisibility);\n return () => document.removeEventListener(\"visibilitychange\", onVisibility);\n }, []);\n\n useEffect(() => {\n if (count <= 1 || paused || hidden || reduceMotion) return;\n const id = setInterval(() => setCurrent((index) => (index + 1) % count), AUTOPLAY_MS);\n return () => clearInterval(id);\n }, [count, paused, hidden, reduceMotion]);\n\n if (isLoading) return <ShowcaseSkeleton />;\n if (count === 0) return null;\n\n const active = collections[current % count]!;\n const activeImage = resolveImage(active.image, { width: 960 });\n const supply = active.totalSupply;\n const transition = reduceMotion ? { duration: 0 } : { type: \"spring\" as const, stiffness: 220, damping: 26 };\n\n return (\n <section\n className=\"relative overflow-hidden px-4 pb-8 pt-20 sm:pt-14\"\n onPointerEnter={() => setPaused(true)}\n onPointerLeave={() => setPaused(false)}\n onFocus={() => setPaused(true)}\n onBlur={() => setPaused(false)}\n >\n {activeImage && (\n <motion.div\n key={active.contractAddress}\n aria-hidden\n className=\"pointer-events-none absolute inset-0 scale-125 opacity-30 blur-3xl [-webkit-mask-image:linear-gradient(to_bottom,transparent_72px,black_220px)] [mask-image:linear-gradient(to_bottom,transparent_72px,black_220px)] dark:opacity-40\"\n initial={reduceMotion ? false : { opacity: 0 }}\n animate={{ opacity: 1 }}\n transition={{ duration: 0.6 }}\n >\n <Image src={activeImage} alt=\"\" fill className=\"object-cover\" unoptimized />\n </motion.div>\n )}\n <div aria-hidden className=\"pointer-events-none absolute inset-x-0 bottom-0 h-1/2 bg-gradient-to-b from-transparent to-background\" />\n\n <motion.div\n role=\"group\"\n aria-roledescription=\"carousel\"\n aria-label=\"Featured collections\"\n tabIndex={count > 1 ? 0 : -1}\n onKeyDown={(event) => {\n if (count <= 1) return;\n if (event.key === \"ArrowLeft\") { event.preventDefault(); go(-1); }\n else if (event.key === \"ArrowRight\") { event.preventDefault(); go(1); }\n }}\n className={cn(\"relative mx-auto touch-pan-y rounded-2xl focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-4 focus-visible:ring-offset-background\", CARD_SIZE)}\n drag={count > 1 ? \"x\" : false}\n dragConstraints={{ left: 0, right: 0 }}\n dragElastic={0.2}\n onDragStart={() => { dragged.current = true; }}\n onDragEnd={(_, info) => {\n if (info.offset.x < -SWIPE_PX) go(1);\n else if (info.offset.x > SWIPE_PX) go(-1);\n setTimeout(() => { dragged.current = false; }, 0);\n }}\n >\n {collections.map((collection, index) => {\n const offset = offsetFrom(index, current, count);\n const distance = Math.abs(offset);\n const image = resolveImage(collection.image, { width: 640 });\n const name = collection.name ?? \"Collection\";\n return (\n <motion.div\n key={collection.contractAddress}\n className={cn(\"absolute inset-0\", distance > 2 && \"pointer-events-none\")}\n initial={false}\n animate={{\n x: `${offset * 58}%`,\n rotate: offset * 9,\n scale: 1 - distance * 0.12,\n opacity: distance > 2 ? 0 : 1,\n zIndex: 10 - distance,\n }}\n transition={transition}\n >\n <Link\n href={getHref(collection)}\n aria-label={name}\n draggable={false}\n onClick={(event) => { if (dragged.current) event.preventDefault(); }}\n className=\"relative block h-full w-full overflow-hidden rounded-2xl bg-muted shadow-2xl shadow-black/20 ring-1 ring-border dark:shadow-black/50\"\n >\n {image ? (\n <Image src={image} alt=\"\" fill sizes=\"(min-width: 1024px) 340px, 58vw\" className=\"object-cover\" priority={index === 0} unoptimized />\n ) : (\n <div className=\"absolute inset-0 bg-gradient-to-br from-brand-purple/40 via-brand-blue/20 to-brand-navy/60\" />\n )}\n <span className={cn(\"absolute inset-0 bg-black/30 transition-opacity duration-500\", offset === 0 ? \"opacity-0\" : \"opacity-100\")} />\n </Link>\n </motion.div>\n );\n })}\n </motion.div>\n\n <motion.div\n key={active.contractAddress}\n aria-live={paused ? \"polite\" : \"off\"}\n className=\"relative mt-8 flex flex-col items-center gap-1 text-center\"\n initial={reduceMotion ? false : { opacity: 0, y: 8 }}\n animate={{ opacity: 1, y: 0 }}\n transition={{ duration: 0.4 }}\n >\n <Link href={getHref(active)} className=\"transition-opacity hover:opacity-80\">\n <h2 className=\"text-3xl font-semibold leading-tight tracking-tight text-foreground sm:text-4xl lg:text-5xl\">\n {active.name ?? \"Collection\"}\n </h2>\n </Link>\n {supply != null && (\n <p className=\"text-sm text-muted-foreground\">\n {supply.toLocaleString()} {supply === 1 ? \"item\" : \"items\"}\n </p>\n )}\n </motion.div>\n\n {count > 1 && (\n <div className=\"relative mt-3 flex justify-center\">\n {collections.map((collection, index) => (\n <button\n key={collection.contractAddress}\n type=\"button\"\n aria-label={`Show ${collection.name ?? \"collection\"}`}\n aria-current={index === current ? \"true\" : undefined}\n onClick={() => setCurrent(index)}\n className=\"flex h-8 items-center px-0.5\"\n >\n <span className={cn(\"h-1.5 rounded-full transition-all\", index === current ? \"w-6 bg-foreground\" : \"w-1.5 bg-foreground/30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AAG,qCAAqC,UAAU,UAAU,sBAAsB,wBAAwB,GAAG;AAAA;AAAA,UAPzH,WAAW;AAAA,QAQlB,CACD,GACH;AAAA;AAAA;AAAA,EAEJ;AAEJ;","names":[]}
@@ -15,9 +15,8 @@ declare const editionMintSchema: z.ZodObject<{
15
15
  aiPolicy: z.ZodEnum<["Allowed", "Not Allowed", "Training Only"]>;
16
16
  royalty: z.ZodNumber;
17
17
  }, "strip", z.ZodTypeAny, {
18
- ipType: "Audio" | "Video" | "Art" | "Photography" | "NFT" | "Software" | "RWA" | "Patents" | "Posts" | "Publications" | "Documents" | "Custom";
19
18
  name: string;
20
- value: string;
19
+ ipType: "Audio" | "Video" | "Art" | "Photography" | "NFT" | "Software" | "RWA" | "Patents" | "Posts" | "Publications" | "Documents" | "Custom";
21
20
  licenseType: string;
22
21
  commercialUse: "Yes" | "No";
23
22
  derivatives: "Allowed" | "Not Allowed" | "Share-Alike";
@@ -25,13 +24,13 @@ declare const editionMintSchema: z.ZodObject<{
25
24
  geographicScope: string;
26
25
  aiPolicy: "Allowed" | "Not Allowed" | "Training Only";
27
26
  royalty: number;
27
+ value: string;
28
28
  recipient: string;
29
29
  description?: string | undefined;
30
30
  external_url?: string | undefined;
31
31
  }, {
32
- ipType: "Audio" | "Video" | "Art" | "Photography" | "NFT" | "Software" | "RWA" | "Patents" | "Posts" | "Publications" | "Documents" | "Custom";
33
32
  name: string;
34
- value: string;
33
+ ipType: "Audio" | "Video" | "Art" | "Photography" | "NFT" | "Software" | "RWA" | "Patents" | "Posts" | "Publications" | "Documents" | "Custom";
35
34
  licenseType: string;
36
35
  commercialUse: "Yes" | "No";
37
36
  derivatives: "Allowed" | "Not Allowed" | "Share-Alike";
@@ -39,6 +38,7 @@ declare const editionMintSchema: z.ZodObject<{
39
38
  geographicScope: string;
40
39
  aiPolicy: "Allowed" | "Not Allowed" | "Training Only";
41
40
  royalty: number;
41
+ value: string;
42
42
  recipient: string;
43
43
  description?: string | undefined;
44
44
  external_url?: string | undefined;
@@ -15,9 +15,8 @@ declare const editionMintSchema: z.ZodObject<{
15
15
  aiPolicy: z.ZodEnum<["Allowed", "Not Allowed", "Training Only"]>;
16
16
  royalty: z.ZodNumber;
17
17
  }, "strip", z.ZodTypeAny, {
18
- ipType: "Audio" | "Video" | "Art" | "Photography" | "NFT" | "Software" | "RWA" | "Patents" | "Posts" | "Publications" | "Documents" | "Custom";
19
18
  name: string;
20
- value: string;
19
+ ipType: "Audio" | "Video" | "Art" | "Photography" | "NFT" | "Software" | "RWA" | "Patents" | "Posts" | "Publications" | "Documents" | "Custom";
21
20
  licenseType: string;
22
21
  commercialUse: "Yes" | "No";
23
22
  derivatives: "Allowed" | "Not Allowed" | "Share-Alike";
@@ -25,13 +24,13 @@ declare const editionMintSchema: z.ZodObject<{
25
24
  geographicScope: string;
26
25
  aiPolicy: "Allowed" | "Not Allowed" | "Training Only";
27
26
  royalty: number;
27
+ value: string;
28
28
  recipient: string;
29
29
  description?: string | undefined;
30
30
  external_url?: string | undefined;
31
31
  }, {
32
- ipType: "Audio" | "Video" | "Art" | "Photography" | "NFT" | "Software" | "RWA" | "Patents" | "Posts" | "Publications" | "Documents" | "Custom";
33
32
  name: string;
34
- value: string;
33
+ ipType: "Audio" | "Video" | "Art" | "Photography" | "NFT" | "Software" | "RWA" | "Patents" | "Posts" | "Publications" | "Documents" | "Custom";
35
34
  licenseType: string;
36
35
  commercialUse: "Yes" | "No";
37
36
  derivatives: "Allowed" | "Not Allowed" | "Share-Alike";
@@ -39,6 +38,7 @@ declare const editionMintSchema: z.ZodObject<{
39
38
  geographicScope: string;
40
39
  aiPolicy: "Allowed" | "Not Allowed" | "Training Only";
41
40
  royalty: number;
41
+ value: string;
42
42
  recipient: string;
43
43
  description?: string | undefined;
44
44
  external_url?: string | undefined;
@@ -1,8 +1,10 @@
1
1
  "use strict";
2
2
  "use client";
3
+ var __create = Object.create;
3
4
  var __defProp = Object.defineProperty;
4
5
  var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
6
  var __getOwnPropNames = Object.getOwnPropertyNames;
7
+ var __getProtoOf = Object.getPrototypeOf;
6
8
  var __hasOwnProp = Object.prototype.hasOwnProperty;
7
9
  var __export = (target, all) => {
8
10
  for (var name in all)
@@ -16,6 +18,14 @@ var __copyProps = (to, from, except, desc) => {
16
18
  }
17
19
  return to;
18
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
+ ));
19
29
  var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
20
30
  var more_menu_exports = {};
21
31
  __export(more_menu_exports, {
@@ -25,9 +35,10 @@ module.exports = __toCommonJS(more_menu_exports);
25
35
  var import_jsx_runtime = require("react/jsx-runtime");
26
36
  var import_react = require("react");
27
37
  var import_lucide_react = require("lucide-react");
38
+ var import_link = __toESM(require("./link.js"), 1);
28
39
  var import_dropdown_menu = require("./dropdown-menu.js");
29
40
  var import_share = require("../utils/share.js");
30
- function MoreMenu({ explorerHref, shareTitle, onReport }) {
41
+ function MoreMenu({ explorerHref, shareTitle, settingsHref, onReport }) {
31
42
  const [copied, setCopied] = (0, import_react.useState)(false);
32
43
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_dropdown_menu.DropdownMenu, { children: [
33
44
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
@@ -39,6 +50,10 @@ function MoreMenu({ explorerHref, shareTitle, onReport }) {
39
50
  }
40
51
  ),
41
52
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_dropdown_menu.DropdownMenuContent, { align: "end", children: [
53
+ settingsHref ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_dropdown_menu.DropdownMenuItem, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_link.default, { href: settingsHref, children: [
54
+ /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.Settings, {}),
55
+ "Collection settings"
56
+ ] }) }) : null,
42
57
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_dropdown_menu.DropdownMenuItem, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("a", { href: explorerHref, target: "_blank", rel: "noopener noreferrer", children: [
43
58
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.ExternalLink, {}),
44
59
  "View on explorer"
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/components/more-menu.tsx"],"sourcesContent":["\"use client\";\n\nimport { useState } from \"react\";\nimport { Check, ExternalLink, Flag, MoreHorizontal, Share2 } from \"lucide-react\";\nimport { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger } from \"./dropdown-menu.js\";\nimport { shareOrCopy } from \"../utils/share.js\";\n\nexport function MoreMenu({ explorerHref, shareTitle, onReport }: { explorerHref: string; shareTitle: string; onReport: () => void }) {\n const [copied, setCopied] = useState(false);\n return (\n <DropdownMenu>\n <DropdownMenuTrigger\n aria-label=\"More options\"\n className=\"inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md border border-input bg-background text-muted-foreground transition-colors hover:bg-accent hover:text-foreground\"\n >\n <MoreHorizontal className=\"h-4 w-4\" />\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\">\n <DropdownMenuItem asChild>\n <a href={explorerHref} target=\"_blank\" rel=\"noopener noreferrer\">\n <ExternalLink />\n View on explorer\n </a>\n </DropdownMenuItem>\n <DropdownMenuItem\n onSelect={(e) => {\n e.preventDefault();\n void shareOrCopy(shareTitle).then((result) => {\n if (result !== \"copied\") return;\n setCopied(true);\n setTimeout(() => setCopied(false), 2000);\n });\n }}\n >\n {copied ? <Check className=\"text-emerald-500\" /> : <Share2 />}\n {copied ? \"Link copied\" : \"Share\"}\n </DropdownMenuItem>\n <DropdownMenuItem onSelect={onReport}>\n <Flag />\n Report\n </DropdownMenuItem>\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAeQ;AAbR,mBAAyB;AACzB,0BAAkE;AAClE,2BAAyF;AACzF,mBAA4B;AAErB,SAAS,SAAS,EAAE,cAAc,YAAY,SAAS,GAAuE;AACnI,QAAM,CAAC,QAAQ,SAAS,QAAI,uBAAS,KAAK;AAC1C,SACE,6CAAC,qCACC;AAAA;AAAA,MAAC;AAAA;AAAA,QACC,cAAW;AAAA,QACX,WAAU;AAAA,QAEV,sDAAC,sCAAe,WAAU,WAAU;AAAA;AAAA,IACtC;AAAA,IACA,6CAAC,4CAAoB,OAAM,OACzB;AAAA,kDAAC,yCAAiB,SAAO,MACvB,uDAAC,OAAE,MAAM,cAAc,QAAO,UAAS,KAAI,uBACzC;AAAA,oDAAC,oCAAa;AAAA,QAAE;AAAA,SAElB,GACF;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,UAAU,CAAC,MAAM;AACf,cAAE,eAAe;AACjB,qBAAK,0BAAY,UAAU,EAAE,KAAK,CAAC,WAAW;AAC5C,kBAAI,WAAW,SAAU;AACzB,wBAAU,IAAI;AACd,yBAAW,MAAM,UAAU,KAAK,GAAG,GAAI;AAAA,YACzC,CAAC;AAAA,UACH;AAAA,UAEC;AAAA,qBAAS,4CAAC,6BAAM,WAAU,oBAAmB,IAAK,4CAAC,8BAAO;AAAA,YAC1D,SAAS,gBAAgB;AAAA;AAAA;AAAA,MAC5B;AAAA,MACA,6CAAC,yCAAiB,UAAU,UAC1B;AAAA,oDAAC,4BAAK;AAAA,QAAE;AAAA,SAEV;AAAA,OACF;AAAA,KACF;AAEJ;","names":[]}
1
+ {"version":3,"sources":["../../src/components/more-menu.tsx"],"sourcesContent":["\"use client\";\n\nimport { useState } from \"react\";\nimport { Check, ExternalLink, Flag, MoreHorizontal, Settings, Share2 } from \"lucide-react\";\nimport Link from \"./link.js\";\nimport { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger } from \"./dropdown-menu.js\";\nimport { shareOrCopy } from \"../utils/share.js\";\n\nexport function MoreMenu({ explorerHref, shareTitle, settingsHref, onReport }: { explorerHref: string; shareTitle: string; settingsHref?: string; onReport: () => void }) {\n const [copied, setCopied] = useState(false);\n return (\n <DropdownMenu>\n <DropdownMenuTrigger\n aria-label=\"More options\"\n className=\"inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md border border-input bg-background text-muted-foreground transition-colors hover:bg-accent hover:text-foreground\"\n >\n <MoreHorizontal className=\"h-4 w-4\" />\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\">\n {settingsHref ? (\n <DropdownMenuItem asChild>\n <Link href={settingsHref}>\n <Settings />\n Collection settings\n </Link>\n </DropdownMenuItem>\n ) : null}\n <DropdownMenuItem asChild>\n <a href={explorerHref} target=\"_blank\" rel=\"noopener noreferrer\">\n <ExternalLink />\n View on explorer\n </a>\n </DropdownMenuItem>\n <DropdownMenuItem\n onSelect={(e) => {\n e.preventDefault();\n void shareOrCopy(shareTitle).then((result) => {\n if (result !== \"copied\") return;\n setCopied(true);\n setTimeout(() => setCopied(false), 2000);\n });\n }}\n >\n {copied ? <Check className=\"text-emerald-500\" /> : <Share2 />}\n {copied ? \"Link copied\" : \"Share\"}\n </DropdownMenuItem>\n <DropdownMenuItem onSelect={onReport}>\n <Flag />\n Report\n </DropdownMenuItem>\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAgBQ;AAdR,mBAAyB;AACzB,0BAA4E;AAC5E,kBAAiB;AACjB,2BAAyF;AACzF,mBAA4B;AAErB,SAAS,SAAS,EAAE,cAAc,YAAY,cAAc,SAAS,GAA8F;AACxK,QAAM,CAAC,QAAQ,SAAS,QAAI,uBAAS,KAAK;AAC1C,SACE,6CAAC,qCACC;AAAA;AAAA,MAAC;AAAA;AAAA,QACC,cAAW;AAAA,QACX,WAAU;AAAA,QAEV,sDAAC,sCAAe,WAAU,WAAU;AAAA;AAAA,IACtC;AAAA,IACA,6CAAC,4CAAoB,OAAM,OACxB;AAAA,qBACC,4CAAC,yCAAiB,SAAO,MACvB,uDAAC,YAAAA,SAAA,EAAK,MAAM,cACV;AAAA,oDAAC,gCAAS;AAAA,QAAE;AAAA,SAEd,GACF,IACE;AAAA,MACJ,4CAAC,yCAAiB,SAAO,MACvB,uDAAC,OAAE,MAAM,cAAc,QAAO,UAAS,KAAI,uBACzC;AAAA,oDAAC,oCAAa;AAAA,QAAE;AAAA,SAElB,GACF;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,UAAU,CAAC,MAAM;AACf,cAAE,eAAe;AACjB,qBAAK,0BAAY,UAAU,EAAE,KAAK,CAAC,WAAW;AAC5C,kBAAI,WAAW,SAAU;AACzB,wBAAU,IAAI;AACd,yBAAW,MAAM,UAAU,KAAK,GAAG,GAAI;AAAA,YACzC,CAAC;AAAA,UACH;AAAA,UAEC;AAAA,qBAAS,4CAAC,6BAAM,WAAU,oBAAmB,IAAK,4CAAC,8BAAO;AAAA,YAC1D,SAAS,gBAAgB;AAAA;AAAA;AAAA,MAC5B;AAAA,MACA,6CAAC,yCAAiB,UAAU,UAC1B;AAAA,oDAAC,4BAAK;AAAA,QAAE;AAAA,SAEV;AAAA,OACF;AAAA,KACF;AAEJ;","names":["Link"]}
@@ -1,8 +1,9 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
 
3
- declare function MoreMenu({ explorerHref, shareTitle, onReport }: {
3
+ declare function MoreMenu({ explorerHref, shareTitle, settingsHref, onReport }: {
4
4
  explorerHref: string;
5
5
  shareTitle: string;
6
+ settingsHref?: string;
6
7
  onReport: () => void;
7
8
  }): react_jsx_runtime.JSX.Element;
8
9
 
@@ -1,8 +1,9 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
2
 
3
- declare function MoreMenu({ explorerHref, shareTitle, onReport }: {
3
+ declare function MoreMenu({ explorerHref, shareTitle, settingsHref, onReport }: {
4
4
  explorerHref: string;
5
5
  shareTitle: string;
6
+ settingsHref?: string;
6
7
  onReport: () => void;
7
8
  }): react_jsx_runtime.JSX.Element;
8
9
 
@@ -1,10 +1,11 @@
1
1
  "use client";
2
2
  import { jsx, jsxs } from "react/jsx-runtime";
3
3
  import { useState } from "react";
4
- import { Check, ExternalLink, Flag, MoreHorizontal, Share2 } from "lucide-react";
4
+ import { Check, ExternalLink, Flag, MoreHorizontal, Settings, Share2 } from "lucide-react";
5
+ import Link from "./link.js";
5
6
  import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger } from "./dropdown-menu.js";
6
7
  import { shareOrCopy } from "../utils/share.js";
7
- function MoreMenu({ explorerHref, shareTitle, onReport }) {
8
+ function MoreMenu({ explorerHref, shareTitle, settingsHref, onReport }) {
8
9
  const [copied, setCopied] = useState(false);
9
10
  return /* @__PURE__ */ jsxs(DropdownMenu, { children: [
10
11
  /* @__PURE__ */ jsx(
@@ -16,6 +17,10 @@ function MoreMenu({ explorerHref, shareTitle, onReport }) {
16
17
  }
17
18
  ),
18
19
  /* @__PURE__ */ jsxs(DropdownMenuContent, { align: "end", children: [
20
+ settingsHref ? /* @__PURE__ */ jsx(DropdownMenuItem, { asChild: true, children: /* @__PURE__ */ jsxs(Link, { href: settingsHref, children: [
21
+ /* @__PURE__ */ jsx(Settings, {}),
22
+ "Collection settings"
23
+ ] }) }) : null,
19
24
  /* @__PURE__ */ jsx(DropdownMenuItem, { asChild: true, children: /* @__PURE__ */ jsxs("a", { href: explorerHref, target: "_blank", rel: "noopener noreferrer", children: [
20
25
  /* @__PURE__ */ jsx(ExternalLink, {}),
21
26
  "View on explorer"
@@ -1 +1 @@
1
- {"version":3,"sources":["../../src/components/more-menu.tsx"],"sourcesContent":["\"use client\";\n\nimport { useState } from \"react\";\nimport { Check, ExternalLink, Flag, MoreHorizontal, Share2 } from \"lucide-react\";\nimport { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger } from \"./dropdown-menu.js\";\nimport { shareOrCopy } from \"../utils/share.js\";\n\nexport function MoreMenu({ explorerHref, shareTitle, onReport }: { explorerHref: string; shareTitle: string; onReport: () => void }) {\n const [copied, setCopied] = useState(false);\n return (\n <DropdownMenu>\n <DropdownMenuTrigger\n aria-label=\"More options\"\n className=\"inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md border border-input bg-background text-muted-foreground transition-colors hover:bg-accent hover:text-foreground\"\n >\n <MoreHorizontal className=\"h-4 w-4\" />\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\">\n <DropdownMenuItem asChild>\n <a href={explorerHref} target=\"_blank\" rel=\"noopener noreferrer\">\n <ExternalLink />\n View on explorer\n </a>\n </DropdownMenuItem>\n <DropdownMenuItem\n onSelect={(e) => {\n e.preventDefault();\n void shareOrCopy(shareTitle).then((result) => {\n if (result !== \"copied\") return;\n setCopied(true);\n setTimeout(() => setCopied(false), 2000);\n });\n }}\n >\n {copied ? <Check className=\"text-emerald-500\" /> : <Share2 />}\n {copied ? \"Link copied\" : \"Share\"}\n </DropdownMenuItem>\n <DropdownMenuItem onSelect={onReport}>\n <Flag />\n Report\n </DropdownMenuItem>\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n"],"mappings":";AAeQ,cAIE,YAJF;AAbR,SAAS,gBAAgB;AACzB,SAAS,OAAO,cAAc,MAAM,gBAAgB,cAAc;AAClE,SAAS,cAAc,qBAAqB,kBAAkB,2BAA2B;AACzF,SAAS,mBAAmB;AAErB,SAAS,SAAS,EAAE,cAAc,YAAY,SAAS,GAAuE;AACnI,QAAM,CAAC,QAAQ,SAAS,IAAI,SAAS,KAAK;AAC1C,SACE,qBAAC,gBACC;AAAA;AAAA,MAAC;AAAA;AAAA,QACC,cAAW;AAAA,QACX,WAAU;AAAA,QAEV,8BAAC,kBAAe,WAAU,WAAU;AAAA;AAAA,IACtC;AAAA,IACA,qBAAC,uBAAoB,OAAM,OACzB;AAAA,0BAAC,oBAAiB,SAAO,MACvB,+BAAC,OAAE,MAAM,cAAc,QAAO,UAAS,KAAI,uBACzC;AAAA,4BAAC,gBAAa;AAAA,QAAE;AAAA,SAElB,GACF;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,UAAU,CAAC,MAAM;AACf,cAAE,eAAe;AACjB,iBAAK,YAAY,UAAU,EAAE,KAAK,CAAC,WAAW;AAC5C,kBAAI,WAAW,SAAU;AACzB,wBAAU,IAAI;AACd,yBAAW,MAAM,UAAU,KAAK,GAAG,GAAI;AAAA,YACzC,CAAC;AAAA,UACH;AAAA,UAEC;AAAA,qBAAS,oBAAC,SAAM,WAAU,oBAAmB,IAAK,oBAAC,UAAO;AAAA,YAC1D,SAAS,gBAAgB;AAAA;AAAA;AAAA,MAC5B;AAAA,MACA,qBAAC,oBAAiB,UAAU,UAC1B;AAAA,4BAAC,QAAK;AAAA,QAAE;AAAA,SAEV;AAAA,OACF;AAAA,KACF;AAEJ;","names":[]}
1
+ {"version":3,"sources":["../../src/components/more-menu.tsx"],"sourcesContent":["\"use client\";\n\nimport { useState } from \"react\";\nimport { Check, ExternalLink, Flag, MoreHorizontal, Settings, Share2 } from \"lucide-react\";\nimport Link from \"./link.js\";\nimport { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger } from \"./dropdown-menu.js\";\nimport { shareOrCopy } from \"../utils/share.js\";\n\nexport function MoreMenu({ explorerHref, shareTitle, settingsHref, onReport }: { explorerHref: string; shareTitle: string; settingsHref?: string; onReport: () => void }) {\n const [copied, setCopied] = useState(false);\n return (\n <DropdownMenu>\n <DropdownMenuTrigger\n aria-label=\"More options\"\n className=\"inline-flex h-8 w-8 shrink-0 items-center justify-center rounded-md border border-input bg-background text-muted-foreground transition-colors hover:bg-accent hover:text-foreground\"\n >\n <MoreHorizontal className=\"h-4 w-4\" />\n </DropdownMenuTrigger>\n <DropdownMenuContent align=\"end\">\n {settingsHref ? (\n <DropdownMenuItem asChild>\n <Link href={settingsHref}>\n <Settings />\n Collection settings\n </Link>\n </DropdownMenuItem>\n ) : null}\n <DropdownMenuItem asChild>\n <a href={explorerHref} target=\"_blank\" rel=\"noopener noreferrer\">\n <ExternalLink />\n View on explorer\n </a>\n </DropdownMenuItem>\n <DropdownMenuItem\n onSelect={(e) => {\n e.preventDefault();\n void shareOrCopy(shareTitle).then((result) => {\n if (result !== \"copied\") return;\n setCopied(true);\n setTimeout(() => setCopied(false), 2000);\n });\n }}\n >\n {copied ? <Check className=\"text-emerald-500\" /> : <Share2 />}\n {copied ? \"Link copied\" : \"Share\"}\n </DropdownMenuItem>\n <DropdownMenuItem onSelect={onReport}>\n <Flag />\n Report\n </DropdownMenuItem>\n </DropdownMenuContent>\n </DropdownMenu>\n );\n}\n"],"mappings":";AAgBQ,cAKI,YALJ;AAdR,SAAS,gBAAgB;AACzB,SAAS,OAAO,cAAc,MAAM,gBAAgB,UAAU,cAAc;AAC5E,OAAO,UAAU;AACjB,SAAS,cAAc,qBAAqB,kBAAkB,2BAA2B;AACzF,SAAS,mBAAmB;AAErB,SAAS,SAAS,EAAE,cAAc,YAAY,cAAc,SAAS,GAA8F;AACxK,QAAM,CAAC,QAAQ,SAAS,IAAI,SAAS,KAAK;AAC1C,SACE,qBAAC,gBACC;AAAA;AAAA,MAAC;AAAA;AAAA,QACC,cAAW;AAAA,QACX,WAAU;AAAA,QAEV,8BAAC,kBAAe,WAAU,WAAU;AAAA;AAAA,IACtC;AAAA,IACA,qBAAC,uBAAoB,OAAM,OACxB;AAAA,qBACC,oBAAC,oBAAiB,SAAO,MACvB,+BAAC,QAAK,MAAM,cACV;AAAA,4BAAC,YAAS;AAAA,QAAE;AAAA,SAEd,GACF,IACE;AAAA,MACJ,oBAAC,oBAAiB,SAAO,MACvB,+BAAC,OAAE,MAAM,cAAc,QAAO,UAAS,KAAI,uBACzC;AAAA,4BAAC,gBAAa;AAAA,QAAE;AAAA,SAElB,GACF;AAAA,MACA;AAAA,QAAC;AAAA;AAAA,UACC,UAAU,CAAC,MAAM;AACf,cAAE,eAAe;AACjB,iBAAK,YAAY,UAAU,EAAE,KAAK,CAAC,WAAW;AAC5C,kBAAI,WAAW,SAAU;AACzB,wBAAU,IAAI;AACd,yBAAW,MAAM,UAAU,KAAK,GAAG,GAAI;AAAA,YACzC,CAAC;AAAA,UACH;AAAA,UAEC;AAAA,qBAAS,oBAAC,SAAM,WAAU,oBAAmB,IAAK,oBAAC,UAAO;AAAA,YAC1D,SAAS,gBAAgB;AAAA;AAAA;AAAA,MAC5B;AAAA,MACA,qBAAC,oBAAiB,UAAU,UAC1B;AAAA,4BAAC,QAAK;AAAA,QAAE;AAAA,SAEV;AAAA,OACF;AAAA,KACF;AAEJ;","names":[]}
package/dist/index.cjs CHANGED
@@ -302,7 +302,6 @@ __export(index_exports, {
302
302
  OrderFields: () => import_order_fields.OrderFields,
303
303
  OrderSortControl: () => import_order_sort_control.OrderSortControl,
304
304
  OrderSummaryHero: () => import_marketplace_dialog_primitives.OrderSummaryHero,
305
- OwnerSetupPanel: () => import_owner_setup_panel.OwnerSetupPanel,
306
305
  PINATA_PUBLIC_GATEWAY: () => import_ipfs.DEFAULT_GATEWAY,
307
306
  PORTFOLIO_TABS: () => import_portfolio_shell.PORTFOLIO_TABS,
308
307
  PageBackdrop: () => import_media_header.PageBackdrop,
@@ -896,7 +895,6 @@ var import_use_remix_offers = require("./utils/use-remix-offers.js");
896
895
  var import_use_my_remix_offers = require("./utils/use-my-remix-offers.js");
897
896
  var import_use_swap_quote = require("./utils/use-swap-quote.js");
898
897
  var import_remixes_tab = require("./components/remixes-tab.js");
899
- var import_owner_setup_panel = require("./components/owner-setup-panel.js");
900
898
  var import_drop_countdown = require("./components/drop-countdown.js");
901
899
  var import_dialog = require("./components/dialog.js");
902
900
  var import_self_fund_consent_dialog = require("./components/wallet/self-fund-consent-dialog.js");
@@ -1200,7 +1198,6 @@ var import_asset_accents = require("./utils/asset-accents.js");
1200
1198
  OrderFields,
1201
1199
  OrderSortControl,
1202
1200
  OrderSummaryHero,
1203
- OwnerSetupPanel,
1204
1201
  PINATA_PUBLIC_GATEWAY,
1205
1202
  PORTFOLIO_TABS,
1206
1203
  PageBackdrop,