@medialane/ui 0.211.2 → 0.212.1
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/account/input-otp.d.cts +2 -2
- package/dist/components/account/input-otp.d.ts +2 -2
- package/dist/components/asset-access-cards.cjs +2 -2
- package/dist/components/asset-access-cards.cjs.map +1 -1
- package/dist/components/asset-access-cards.d.cts +2 -1
- package/dist/components/asset-access-cards.d.ts +2 -1
- package/dist/components/asset-access-cards.js +2 -2
- package/dist/components/asset-access-cards.js.map +1 -1
- package/dist/components/asset-marketplace-panel.cjs +2 -1
- package/dist/components/asset-marketplace-panel.cjs.map +1 -1
- package/dist/components/asset-marketplace-panel.d.cts +2 -1
- package/dist/components/asset-marketplace-panel.d.ts +2 -1
- package/dist/components/asset-marketplace-panel.js +2 -1
- package/dist/components/asset-marketplace-panel.js.map +1 -1
- package/dist/components/asset-page.cjs +20 -24
- package/dist/components/asset-page.cjs.map +1 -1
- package/dist/components/asset-page.js +20 -24
- package/dist/components/asset-page.js.map +1 -1
- package/dist/components/asset-publication.cjs +59 -0
- package/dist/components/asset-publication.cjs.map +1 -0
- package/dist/components/asset-publication.d.cts +15 -0
- package/dist/components/asset-publication.d.ts +15 -0
- package/dist/components/asset-publication.js +35 -0
- package/dist/components/asset-publication.js.map +1 -0
- package/dist/components/button.d.cts +2 -2
- package/dist/components/button.d.ts +2 -2
- package/package.json +1 -1
- package/dist/components/asset-publication-header.cjs +0 -93
- package/dist/components/asset-publication-header.cjs.map +0 -1
- package/dist/components/asset-publication-header.d.cts +0 -22
- package/dist/components/asset-publication-header.d.ts +0 -22
- package/dist/components/asset-publication-header.js +0 -58
- package/dist/components/asset-publication-header.js.map +0 -1
|
@@ -1,93 +0,0 @@
|
|
|
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 asset_publication_header_exports = {};
|
|
31
|
-
__export(asset_publication_header_exports, {
|
|
32
|
-
AssetPublicationHeader: () => AssetPublicationHeader,
|
|
33
|
-
AssetPublicationText: () => AssetPublicationText
|
|
34
|
-
});
|
|
35
|
-
module.exports = __toCommonJS(asset_publication_header_exports);
|
|
36
|
-
var import_jsx_runtime = require("react/jsx-runtime");
|
|
37
|
-
var import_link = __toESM(require("./link.js"), 1);
|
|
38
|
-
var import_lucide_react = require("lucide-react");
|
|
39
|
-
var import_ip_type_badge = require("./ip-type-badge.js");
|
|
40
|
-
function webAddress(url) {
|
|
41
|
-
if (!url) return null;
|
|
42
|
-
try {
|
|
43
|
-
const parsed = new URL(url);
|
|
44
|
-
return parsed.protocol === "https:" || parsed.protocol === "http:" ? { href: parsed.href, host: parsed.host.replace(/^www\./, "") } : null;
|
|
45
|
-
} catch {
|
|
46
|
-
return null;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
function AssetPublicationHeader({
|
|
50
|
-
name,
|
|
51
|
-
ipType,
|
|
52
|
-
image,
|
|
53
|
-
imgError,
|
|
54
|
-
onImageError,
|
|
55
|
-
onZoom,
|
|
56
|
-
publisherName,
|
|
57
|
-
publisherImage,
|
|
58
|
-
publisherHref,
|
|
59
|
-
author,
|
|
60
|
-
publishedAt,
|
|
61
|
-
websiteUrl
|
|
62
|
-
}) {
|
|
63
|
-
const website = webAddress(websiteUrl);
|
|
64
|
-
const date = publishedAt ? new Date(publishedAt * 1e3).toLocaleDateString(void 0, { dateStyle: "long" }) : null;
|
|
65
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("header", { className: "space-y-6", children: [
|
|
66
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "space-y-4", children: [
|
|
67
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ip_type_badge.IpTypeBadge, { ipType, size: "md" }),
|
|
68
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)("h1", { className: "text-2xl lg:text-4xl font-bold break-words", children: name }),
|
|
69
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "flex flex-wrap items-center gap-x-3 gap-y-2 text-sm text-muted-foreground", children: [
|
|
70
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_link.default, { href: publisherHref, className: "inline-flex items-center gap-2 font-medium text-foreground hover:text-primary transition-colors", children: [
|
|
71
|
-
publisherImage ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("img", { src: publisherImage, alt: "", className: "h-7 w-7 rounded-full object-cover" }) : null,
|
|
72
|
-
publisherName
|
|
73
|
-
] }),
|
|
74
|
-
author ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: author }) : null,
|
|
75
|
-
date ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", { children: date }) : null,
|
|
76
|
-
website ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("a", { href: website.href, target: "_blank", rel: "noopener noreferrer", className: "inline-flex items-center gap-1.5 hover:text-primary transition-colors", children: [
|
|
77
|
-
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_lucide_react.Globe, { className: "h-3.5 w-3.5" }),
|
|
78
|
-
website.host
|
|
79
|
-
] }) : null
|
|
80
|
-
] })
|
|
81
|
-
] }),
|
|
82
|
-
image && !imgError ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("button", { type: "button", onClick: onZoom, "aria-label": "View full image", className: "block w-full overflow-hidden rounded-2xl cursor-zoom-in focus:outline-none", children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("img", { src: image, alt: name, onError: onImageError, className: "w-full h-auto max-h-72 object-cover" }) }) : null
|
|
83
|
-
] });
|
|
84
|
-
}
|
|
85
|
-
function AssetPublicationText({ text }) {
|
|
86
|
-
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "text-sm leading-relaxed text-foreground/90 break-words", children: text.split(/\n{2,}/).map((paragraph, i) => /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", { className: "my-4 whitespace-pre-line", children: paragraph }, i)) });
|
|
87
|
-
}
|
|
88
|
-
// Annotate the CommonJS export names for ESM import in node:
|
|
89
|
-
0 && (module.exports = {
|
|
90
|
-
AssetPublicationHeader,
|
|
91
|
-
AssetPublicationText
|
|
92
|
-
});
|
|
93
|
-
//# sourceMappingURL=asset-publication-header.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/components/asset-publication-header.tsx"],"sourcesContent":["\"use client\";\n\nimport Link from \"./link.js\";\nimport { Globe } from \"lucide-react\";\nimport { IpTypeBadge } from \"./ip-type-badge.js\";\n\nexport interface AssetPublicationHeaderProps {\n name: string;\n ipType: string;\n image: string | null;\n imgError: boolean;\n onImageError: () => void;\n onZoom: () => void;\n publisherName: string;\n publisherImage?: string | null;\n publisherHref: string;\n author?: string | null;\n publishedAt?: number | null;\n websiteUrl?: string | null;\n}\n\nfunction webAddress(url?: string | null) {\n if (!url) return null;\n try {\n const parsed = new URL(url);\n return parsed.protocol === \"https:\" || parsed.protocol === \"http:\" ? { href: parsed.href, host: parsed.host.replace(/^www\\./, \"\") } : null;\n } catch {\n return null;\n }\n}\n\nexport function AssetPublicationHeader({\n name,\n ipType,\n image,\n imgError,\n onImageError,\n onZoom,\n publisherName,\n publisherImage,\n publisherHref,\n author,\n publishedAt,\n websiteUrl,\n}: AssetPublicationHeaderProps) {\n const website = webAddress(websiteUrl);\n const date = publishedAt ? new Date(publishedAt * 1000).toLocaleDateString(undefined, { dateStyle: \"long\" }) : null;\n return (\n <header className=\"space-y-6\">\n <div className=\"space-y-4\">\n <IpTypeBadge ipType={ipType} size=\"md\" />\n <h1 className=\"text-2xl lg:text-4xl font-bold break-words\">{name}</h1>\n <div className=\"flex flex-wrap items-center gap-x-3 gap-y-2 text-sm text-muted-foreground\">\n <Link href={publisherHref} className=\"inline-flex items-center gap-2 font-medium text-foreground hover:text-primary transition-colors\">\n {publisherImage ? <img src={publisherImage} alt=\"\" className=\"h-7 w-7 rounded-full object-cover\" /> : null}\n {publisherName}\n </Link>\n {author ? <span>{author}</span> : null}\n {date ? <span>{date}</span> : null}\n {website ? (\n <a href={website.href} target=\"_blank\" rel=\"noopener noreferrer\" className=\"inline-flex items-center gap-1.5 hover:text-primary transition-colors\">\n <Globe className=\"h-3.5 w-3.5\" />\n {website.host}\n </a>\n ) : null}\n </div>\n </div>\n {image && !imgError ? (\n <button type=\"button\" onClick={onZoom} aria-label=\"View full image\" className=\"block w-full overflow-hidden rounded-2xl cursor-zoom-in focus:outline-none\">\n <img src={image} alt={name} onError={onImageError} className=\"w-full h-auto max-h-72 object-cover\" />\n </button>\n ) : null}\n </header>\n );\n}\n\nexport function AssetPublicationText({ text }: { text: string }) {\n return (\n <div className=\"text-sm leading-relaxed text-foreground/90 break-words\">\n {text.split(/\\n{2,}/).map((paragraph, i) => (\n <p key={i} className=\"my-4 whitespace-pre-line\">{paragraph}</p>\n ))}\n </div>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAkDQ;AAhDR,kBAAiB;AACjB,0BAAsB;AACtB,2BAA4B;AAiB5B,SAAS,WAAW,KAAqB;AACvC,MAAI,CAAC,IAAK,QAAO;AACjB,MAAI;AACF,UAAM,SAAS,IAAI,IAAI,GAAG;AAC1B,WAAO,OAAO,aAAa,YAAY,OAAO,aAAa,UAAU,EAAE,MAAM,OAAO,MAAM,MAAM,OAAO,KAAK,QAAQ,UAAU,EAAE,EAAE,IAAI;AAAA,EACxI,QAAQ;AACN,WAAO;AAAA,EACT;AACF;AAEO,SAAS,uBAAuB;AAAA,EACrC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAgC;AAC9B,QAAM,UAAU,WAAW,UAAU;AACrC,QAAM,OAAO,cAAc,IAAI,KAAK,cAAc,GAAI,EAAE,mBAAmB,QAAW,EAAE,WAAW,OAAO,CAAC,IAAI;AAC/G,SACE,6CAAC,YAAO,WAAU,aAChB;AAAA,iDAAC,SAAI,WAAU,aACb;AAAA,kDAAC,oCAAY,QAAgB,MAAK,MAAK;AAAA,MACvC,4CAAC,QAAG,WAAU,8CAA8C,gBAAK;AAAA,MACjE,6CAAC,SAAI,WAAU,6EACb;AAAA,qDAAC,YAAAA,SAAA,EAAK,MAAM,eAAe,WAAU,mGAClC;AAAA,2BAAiB,4CAAC,SAAI,KAAK,gBAAgB,KAAI,IAAG,WAAU,qCAAoC,IAAK;AAAA,UACrG;AAAA,WACH;AAAA,QACC,SAAS,4CAAC,UAAM,kBAAO,IAAU;AAAA,QACjC,OAAO,4CAAC,UAAM,gBAAK,IAAU;AAAA,QAC7B,UACC,6CAAC,OAAE,MAAM,QAAQ,MAAM,QAAO,UAAS,KAAI,uBAAsB,WAAU,yEACzE;AAAA,sDAAC,6BAAM,WAAU,eAAc;AAAA,UAC9B,QAAQ;AAAA,WACX,IACE;AAAA,SACN;AAAA,OACF;AAAA,IACC,SAAS,CAAC,WACT,4CAAC,YAAO,MAAK,UAAS,SAAS,QAAQ,cAAW,mBAAkB,WAAU,8EAC5E,sDAAC,SAAI,KAAK,OAAO,KAAK,MAAM,SAAS,cAAc,WAAU,uCAAsC,GACrG,IACE;AAAA,KACN;AAEJ;AAEO,SAAS,qBAAqB,EAAE,KAAK,GAAqB;AAC/D,SACE,4CAAC,SAAI,WAAU,0DACZ,eAAK,MAAM,QAAQ,EAAE,IAAI,CAAC,WAAW,MACpC,4CAAC,OAAU,WAAU,4BAA4B,uBAAzC,CAAmD,CAC5D,GACH;AAEJ;","names":["Link"]}
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
|
|
3
|
-
interface AssetPublicationHeaderProps {
|
|
4
|
-
name: string;
|
|
5
|
-
ipType: string;
|
|
6
|
-
image: string | null;
|
|
7
|
-
imgError: boolean;
|
|
8
|
-
onImageError: () => void;
|
|
9
|
-
onZoom: () => void;
|
|
10
|
-
publisherName: string;
|
|
11
|
-
publisherImage?: string | null;
|
|
12
|
-
publisherHref: string;
|
|
13
|
-
author?: string | null;
|
|
14
|
-
publishedAt?: number | null;
|
|
15
|
-
websiteUrl?: string | null;
|
|
16
|
-
}
|
|
17
|
-
declare function AssetPublicationHeader({ name, ipType, image, imgError, onImageError, onZoom, publisherName, publisherImage, publisherHref, author, publishedAt, websiteUrl, }: AssetPublicationHeaderProps): react_jsx_runtime.JSX.Element;
|
|
18
|
-
declare function AssetPublicationText({ text }: {
|
|
19
|
-
text: string;
|
|
20
|
-
}): react_jsx_runtime.JSX.Element;
|
|
21
|
-
|
|
22
|
-
export { AssetPublicationHeader, type AssetPublicationHeaderProps, AssetPublicationText };
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
|
|
3
|
-
interface AssetPublicationHeaderProps {
|
|
4
|
-
name: string;
|
|
5
|
-
ipType: string;
|
|
6
|
-
image: string | null;
|
|
7
|
-
imgError: boolean;
|
|
8
|
-
onImageError: () => void;
|
|
9
|
-
onZoom: () => void;
|
|
10
|
-
publisherName: string;
|
|
11
|
-
publisherImage?: string | null;
|
|
12
|
-
publisherHref: string;
|
|
13
|
-
author?: string | null;
|
|
14
|
-
publishedAt?: number | null;
|
|
15
|
-
websiteUrl?: string | null;
|
|
16
|
-
}
|
|
17
|
-
declare function AssetPublicationHeader({ name, ipType, image, imgError, onImageError, onZoom, publisherName, publisherImage, publisherHref, author, publishedAt, websiteUrl, }: AssetPublicationHeaderProps): react_jsx_runtime.JSX.Element;
|
|
18
|
-
declare function AssetPublicationText({ text }: {
|
|
19
|
-
text: string;
|
|
20
|
-
}): react_jsx_runtime.JSX.Element;
|
|
21
|
-
|
|
22
|
-
export { AssetPublicationHeader, type AssetPublicationHeaderProps, AssetPublicationText };
|
|
@@ -1,58 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { jsx, jsxs } from "react/jsx-runtime";
|
|
3
|
-
import Link from "./link.js";
|
|
4
|
-
import { Globe } from "lucide-react";
|
|
5
|
-
import { IpTypeBadge } from "./ip-type-badge.js";
|
|
6
|
-
function webAddress(url) {
|
|
7
|
-
if (!url) return null;
|
|
8
|
-
try {
|
|
9
|
-
const parsed = new URL(url);
|
|
10
|
-
return parsed.protocol === "https:" || parsed.protocol === "http:" ? { href: parsed.href, host: parsed.host.replace(/^www\./, "") } : null;
|
|
11
|
-
} catch {
|
|
12
|
-
return null;
|
|
13
|
-
}
|
|
14
|
-
}
|
|
15
|
-
function AssetPublicationHeader({
|
|
16
|
-
name,
|
|
17
|
-
ipType,
|
|
18
|
-
image,
|
|
19
|
-
imgError,
|
|
20
|
-
onImageError,
|
|
21
|
-
onZoom,
|
|
22
|
-
publisherName,
|
|
23
|
-
publisherImage,
|
|
24
|
-
publisherHref,
|
|
25
|
-
author,
|
|
26
|
-
publishedAt,
|
|
27
|
-
websiteUrl
|
|
28
|
-
}) {
|
|
29
|
-
const website = webAddress(websiteUrl);
|
|
30
|
-
const date = publishedAt ? new Date(publishedAt * 1e3).toLocaleDateString(void 0, { dateStyle: "long" }) : null;
|
|
31
|
-
return /* @__PURE__ */ jsxs("header", { className: "space-y-6", children: [
|
|
32
|
-
/* @__PURE__ */ jsxs("div", { className: "space-y-4", children: [
|
|
33
|
-
/* @__PURE__ */ jsx(IpTypeBadge, { ipType, size: "md" }),
|
|
34
|
-
/* @__PURE__ */ jsx("h1", { className: "text-2xl lg:text-4xl font-bold break-words", children: name }),
|
|
35
|
-
/* @__PURE__ */ jsxs("div", { className: "flex flex-wrap items-center gap-x-3 gap-y-2 text-sm text-muted-foreground", children: [
|
|
36
|
-
/* @__PURE__ */ jsxs(Link, { href: publisherHref, className: "inline-flex items-center gap-2 font-medium text-foreground hover:text-primary transition-colors", children: [
|
|
37
|
-
publisherImage ? /* @__PURE__ */ jsx("img", { src: publisherImage, alt: "", className: "h-7 w-7 rounded-full object-cover" }) : null,
|
|
38
|
-
publisherName
|
|
39
|
-
] }),
|
|
40
|
-
author ? /* @__PURE__ */ jsx("span", { children: author }) : null,
|
|
41
|
-
date ? /* @__PURE__ */ jsx("span", { children: date }) : null,
|
|
42
|
-
website ? /* @__PURE__ */ jsxs("a", { href: website.href, target: "_blank", rel: "noopener noreferrer", className: "inline-flex items-center gap-1.5 hover:text-primary transition-colors", children: [
|
|
43
|
-
/* @__PURE__ */ jsx(Globe, { className: "h-3.5 w-3.5" }),
|
|
44
|
-
website.host
|
|
45
|
-
] }) : null
|
|
46
|
-
] })
|
|
47
|
-
] }),
|
|
48
|
-
image && !imgError ? /* @__PURE__ */ jsx("button", { type: "button", onClick: onZoom, "aria-label": "View full image", className: "block w-full overflow-hidden rounded-2xl cursor-zoom-in focus:outline-none", children: /* @__PURE__ */ jsx("img", { src: image, alt: name, onError: onImageError, className: "w-full h-auto max-h-72 object-cover" }) }) : null
|
|
49
|
-
] });
|
|
50
|
-
}
|
|
51
|
-
function AssetPublicationText({ text }) {
|
|
52
|
-
return /* @__PURE__ */ jsx("div", { className: "text-sm leading-relaxed text-foreground/90 break-words", children: text.split(/\n{2,}/).map((paragraph, i) => /* @__PURE__ */ jsx("p", { className: "my-4 whitespace-pre-line", children: paragraph }, i)) });
|
|
53
|
-
}
|
|
54
|
-
export {
|
|
55
|
-
AssetPublicationHeader,
|
|
56
|
-
AssetPublicationText
|
|
57
|
-
};
|
|
58
|
-
//# sourceMappingURL=asset-publication-header.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/components/asset-publication-header.tsx"],"sourcesContent":["\"use client\";\n\nimport Link from \"./link.js\";\nimport { Globe } from \"lucide-react\";\nimport { IpTypeBadge } from \"./ip-type-badge.js\";\n\nexport interface AssetPublicationHeaderProps {\n name: string;\n ipType: string;\n image: string | null;\n imgError: boolean;\n onImageError: () => void;\n onZoom: () => void;\n publisherName: string;\n publisherImage?: string | null;\n publisherHref: string;\n author?: string | null;\n publishedAt?: number | null;\n websiteUrl?: string | null;\n}\n\nfunction webAddress(url?: string | null) {\n if (!url) return null;\n try {\n const parsed = new URL(url);\n return parsed.protocol === \"https:\" || parsed.protocol === \"http:\" ? { href: parsed.href, host: parsed.host.replace(/^www\\./, \"\") } : null;\n } catch {\n return null;\n }\n}\n\nexport function AssetPublicationHeader({\n name,\n ipType,\n image,\n imgError,\n onImageError,\n onZoom,\n publisherName,\n publisherImage,\n publisherHref,\n author,\n publishedAt,\n websiteUrl,\n}: AssetPublicationHeaderProps) {\n const website = webAddress(websiteUrl);\n const date = publishedAt ? new Date(publishedAt * 1000).toLocaleDateString(undefined, { dateStyle: \"long\" }) : null;\n return (\n <header className=\"space-y-6\">\n <div className=\"space-y-4\">\n <IpTypeBadge ipType={ipType} size=\"md\" />\n <h1 className=\"text-2xl lg:text-4xl font-bold break-words\">{name}</h1>\n <div className=\"flex flex-wrap items-center gap-x-3 gap-y-2 text-sm text-muted-foreground\">\n <Link href={publisherHref} className=\"inline-flex items-center gap-2 font-medium text-foreground hover:text-primary transition-colors\">\n {publisherImage ? <img src={publisherImage} alt=\"\" className=\"h-7 w-7 rounded-full object-cover\" /> : null}\n {publisherName}\n </Link>\n {author ? <span>{author}</span> : null}\n {date ? <span>{date}</span> : null}\n {website ? (\n <a href={website.href} target=\"_blank\" rel=\"noopener noreferrer\" className=\"inline-flex items-center gap-1.5 hover:text-primary transition-colors\">\n <Globe className=\"h-3.5 w-3.5\" />\n {website.host}\n </a>\n ) : null}\n </div>\n </div>\n {image && !imgError ? (\n <button type=\"button\" onClick={onZoom} aria-label=\"View full image\" className=\"block w-full overflow-hidden rounded-2xl cursor-zoom-in focus:outline-none\">\n <img src={image} alt={name} onError={onImageError} className=\"w-full h-auto max-h-72 object-cover\" />\n </button>\n ) : null}\n </header>\n );\n}\n\nexport function AssetPublicationText({ text }: { text: string }) {\n return (\n <div className=\"text-sm leading-relaxed text-foreground/90 break-words\">\n {text.split(/\\n{2,}/).map((paragraph, i) => (\n <p key={i} className=\"my-4 whitespace-pre-line\">{paragraph}</p>\n ))}\n </div>\n );\n}\n"],"mappings":";AAkDQ,cAGE,YAHF;AAhDR,OAAO,UAAU;AACjB,SAAS,aAAa;AACtB,SAAS,mBAAmB;AAiB5B,SAAS,WAAW,KAAqB;AACvC,MAAI,CAAC,IAAK,QAAO;AACjB,MAAI;AACF,UAAM,SAAS,IAAI,IAAI,GAAG;AAC1B,WAAO,OAAO,aAAa,YAAY,OAAO,aAAa,UAAU,EAAE,MAAM,OAAO,MAAM,MAAM,OAAO,KAAK,QAAQ,UAAU,EAAE,EAAE,IAAI;AAAA,EACxI,QAAQ;AACN,WAAO;AAAA,EACT;AACF;AAEO,SAAS,uBAAuB;AAAA,EACrC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,GAAgC;AAC9B,QAAM,UAAU,WAAW,UAAU;AACrC,QAAM,OAAO,cAAc,IAAI,KAAK,cAAc,GAAI,EAAE,mBAAmB,QAAW,EAAE,WAAW,OAAO,CAAC,IAAI;AAC/G,SACE,qBAAC,YAAO,WAAU,aAChB;AAAA,yBAAC,SAAI,WAAU,aACb;AAAA,0BAAC,eAAY,QAAgB,MAAK,MAAK;AAAA,MACvC,oBAAC,QAAG,WAAU,8CAA8C,gBAAK;AAAA,MACjE,qBAAC,SAAI,WAAU,6EACb;AAAA,6BAAC,QAAK,MAAM,eAAe,WAAU,mGAClC;AAAA,2BAAiB,oBAAC,SAAI,KAAK,gBAAgB,KAAI,IAAG,WAAU,qCAAoC,IAAK;AAAA,UACrG;AAAA,WACH;AAAA,QACC,SAAS,oBAAC,UAAM,kBAAO,IAAU;AAAA,QACjC,OAAO,oBAAC,UAAM,gBAAK,IAAU;AAAA,QAC7B,UACC,qBAAC,OAAE,MAAM,QAAQ,MAAM,QAAO,UAAS,KAAI,uBAAsB,WAAU,yEACzE;AAAA,8BAAC,SAAM,WAAU,eAAc;AAAA,UAC9B,QAAQ;AAAA,WACX,IACE;AAAA,SACN;AAAA,OACF;AAAA,IACC,SAAS,CAAC,WACT,oBAAC,YAAO,MAAK,UAAS,SAAS,QAAQ,cAAW,mBAAkB,WAAU,8EAC5E,8BAAC,SAAI,KAAK,OAAO,KAAK,MAAM,SAAS,cAAc,WAAU,uCAAsC,GACrG,IACE;AAAA,KACN;AAEJ;AAEO,SAAS,qBAAqB,EAAE,KAAK,GAAqB;AAC/D,SACE,oBAAC,SAAI,WAAU,0DACZ,eAAK,MAAM,QAAQ,EAAE,IAAI,CAAC,WAAW,MACpC,oBAAC,OAAU,WAAU,4BAA4B,uBAAzC,CAAmD,CAC5D,GACH;AAEJ;","names":[]}
|