@loafmarkets/ui 0.1.408 → 0.1.410

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/index.mjs CHANGED
@@ -2644,6 +2644,22 @@ var PropertyTour = React5.forwardRef(
2644
2644
  }
2645
2645
  );
2646
2646
  PropertyTour.displayName = "PropertyTour";
2647
+
2648
+ // src/lib/isSafeUrl.ts
2649
+ var CONTROL_CHARS = /[\u0000-\u001F\u007F]/g;
2650
+ function isSafeUrl(url) {
2651
+ if (!url) return false;
2652
+ const cleaned = url.replace(CONTROL_CHARS, "").replace(/\\/g, "/").trim();
2653
+ if (cleaned === "") return false;
2654
+ if (cleaned.startsWith("//")) return false;
2655
+ if (cleaned.startsWith("/")) return true;
2656
+ try {
2657
+ const { protocol } = new URL(cleaned);
2658
+ return protocol === "http:" || protocol === "https:";
2659
+ } catch {
2660
+ return false;
2661
+ }
2662
+ }
2647
2663
  var ITEMS_PER_PAGE = 5;
2648
2664
  var ITEMS_PER_PAGE_MOBILE = 5;
2649
2665
  var ensureAnimationsInjected = () => {
@@ -2839,7 +2855,7 @@ function NewsArticleModal({ item, onClose }) {
2839
2855
  ] }),
2840
2856
  /* @__PURE__ */ jsx("div", { style: { height: "1px", background: "rgba(255,255,255,0.08)", marginBottom: "1.25rem" } }),
2841
2857
  item.summary ? /* @__PURE__ */ jsx("p", { style: { fontSize: "0.875rem", color: "rgba(255,255,255,0.8)", lineHeight: 1.75, margin: 0 }, children: item.summary }) : /* @__PURE__ */ jsx("p", { style: { fontSize: "0.8rem", color: "rgba(255,255,255,0.35)", fontStyle: "italic", margin: 0 }, children: "Summary not available for this article." }),
2842
- item.url && /* @__PURE__ */ jsx("div", { style: { marginTop: "1.25rem", paddingTop: "1rem", borderTop: "1px solid rgba(255,255,255,0.08)" }, children: /* @__PURE__ */ jsxs(
2858
+ item.url && isSafeUrl(item.url) && /* @__PURE__ */ jsx("div", { style: { marginTop: "1.25rem", paddingTop: "1rem", borderTop: "1px solid rgba(255,255,255,0.08)" }, children: /* @__PURE__ */ jsxs(
2843
2859
  "a",
2844
2860
  {
2845
2861
  href: item.url,
@@ -5078,6 +5094,7 @@ var Header = ({
5078
5094
  onSettingsClick,
5079
5095
  onReferClick,
5080
5096
  portfolioSummary,
5097
+ totalPoints,
5081
5098
  fundsPending = false,
5082
5099
  transparentOnTop = false,
5083
5100
  headerCta = "deposit",
@@ -5541,6 +5558,11 @@ var Header = ({
5541
5558
  }
5542
5559
  ),
5543
5560
  isUserMenuOpen && /* @__PURE__ */ jsxs(DropdownMenu, { className: "user-menu-dropdown", children: [
5561
+ totalPoints != null && /* @__PURE__ */ jsxs(PointsHeader, { children: [
5562
+ /* @__PURE__ */ jsx("div", { className: "pts-label", children: "Total Points" }),
5563
+ /* @__PURE__ */ jsx("div", { className: "pts-value", children: totalPoints.toLocaleString() }),
5564
+ /* @__PURE__ */ jsx("div", { className: "pts-note", children: "Cumulative points earned. More soon." })
5565
+ ] }),
5544
5566
  /* @__PURE__ */ jsx(
5545
5567
  "button",
5546
5568
  {
@@ -5598,7 +5620,7 @@ var Header = ({
5598
5620
  }
5599
5621
  )
5600
5622
  ] }) : /* @__PURE__ */ jsxs("div", { style: { display: "flex", alignItems: "center" }, children: [
5601
- /* @__PURE__ */ jsx(Button2, { className: "signup", onClick: handleSignIn, children: "Connect" }),
5623
+ /* @__PURE__ */ jsx(Button2, { className: "signup", onClick: handleSignIn, children: "Join Competition" }),
5602
5624
  /* @__PURE__ */ jsx(
5603
5625
  MobileOnlyButton,
5604
5626
  {
@@ -6126,6 +6148,33 @@ var DropdownMenu = styled10.div`
6126
6148
  display: block;
6127
6149
  }
6128
6150
  `;
6151
+ var PointsHeader = styled10.div`
6152
+ padding: 0.7rem 1.25rem 0.8rem;
6153
+ margin-bottom: 0.35rem;
6154
+ border-bottom: 1px solid rgba(255, 255, 255, 0.08);
6155
+ .pts-note {
6156
+ margin-top: 0.4rem;
6157
+ font-size: 0.6rem;
6158
+ line-height: 1.4;
6159
+ color: rgba(255, 255, 255, 0.4);
6160
+ }
6161
+ .pts-label {
6162
+ font-family: 'SF Mono', 'Fira Code', ui-monospace, monospace;
6163
+ font-size: 0.56rem;
6164
+ font-weight: 700;
6165
+ letter-spacing: 0.16em;
6166
+ text-transform: uppercase;
6167
+ color: rgba(255, 255, 255, 0.45);
6168
+ }
6169
+ .pts-value {
6170
+ margin-top: 0.2rem;
6171
+ font-size: 1.15rem;
6172
+ font-weight: 800;
6173
+ color: #E6C87E;
6174
+ font-variant-numeric: tabular-nums;
6175
+ line-height: 1;
6176
+ }
6177
+ `;
6129
6178
  var MenuItem = styled10.div`
6130
6179
  padding: 0.75rem 1.25rem;
6131
6180
  cursor: pointer;
@@ -6582,6 +6631,16 @@ var PropertySubheader = React5.forwardRef(
6582
6631
  }
6583
6632
  );
6584
6633
  PropertySubheader.displayName = "PropertySubheader";
6634
+
6635
+ // src/lib/isTrustedTransakOrigin.ts
6636
+ function isTrustedTransakOrigin(eventOrigin, widgetUrl) {
6637
+ if (!widgetUrl) return false;
6638
+ try {
6639
+ return eventOrigin === new URL(widgetUrl).origin;
6640
+ } catch {
6641
+ return false;
6642
+ }
6643
+ }
6585
6644
  var DEFAULT_LOGO_SRC = Loaf_logo_Banner_default;
6586
6645
  var DEFAULT_LOGO_ALT = "Loaf";
6587
6646
  var OTP_INPUT_LENGTH = 6;
@@ -6722,7 +6781,7 @@ var LoginPopup = ({
6722
6781
  useEffect(() => {
6723
6782
  if (!transakWidgetUrl) return;
6724
6783
  const handleTransakMessage = (event) => {
6725
- if (!event.origin.includes("transak.com") && !event.origin.includes("global.transak.com")) {
6784
+ if (!isTrustedTransakOrigin(event.origin, transakWidgetUrl)) {
6726
6785
  return;
6727
6786
  }
6728
6787
  try {
@@ -9028,6 +9087,48 @@ var CodeLink = styled10.button`
9028
9087
  text-underline-offset: 2px;
9029
9088
  }
9030
9089
  `;
9090
+ var HandleField = styled10.div`
9091
+ display: flex;
9092
+ align-items: center;
9093
+ gap: 0.1rem;
9094
+ width: 100%;
9095
+ margin-bottom: 0.4rem;
9096
+ padding: 0 0.9rem;
9097
+ background: rgba(255, 255, 255, 0.04);
9098
+ border: 1px solid rgba(255, 255, 255, 0.1);
9099
+ border-radius: 10px;
9100
+ transition: border-color 0.15s ease;
9101
+
9102
+ &:focus-within {
9103
+ border-color: rgba(230, 200, 126, 0.6);
9104
+ }
9105
+ `;
9106
+ var HandleAt = styled10.span`
9107
+ color: rgba(255, 255, 255, 0.4);
9108
+ font-size: 1rem;
9109
+ font-weight: 600;
9110
+ `;
9111
+ var HandleInput = styled10.input`
9112
+ flex: 1;
9113
+ min-width: 0;
9114
+ padding: 0.85rem 0.4rem;
9115
+ border: none;
9116
+ background: transparent;
9117
+ color: #fff;
9118
+ font-size: 1rem;
9119
+ font-family: inherit;
9120
+ outline: none;
9121
+
9122
+ &::placeholder {
9123
+ color: rgba(255, 255, 255, 0.35);
9124
+ }
9125
+ `;
9126
+ var FieldError = styled10.div`
9127
+ width: 100%;
9128
+ margin-bottom: 0.6rem;
9129
+ font-size: 0.78rem;
9130
+ color: #ff6b6b;
9131
+ `;
9031
9132
  function OnboardingGuide({
9032
9133
  open,
9033
9134
  fundsReady,
@@ -9035,8 +9136,21 @@ function OnboardingGuide({
9035
9136
  onBrowseProperties,
9036
9137
  onEnterCode,
9037
9138
  onClose,
9139
+ onClaimHandle,
9038
9140
  logoSrc = "/Loaf-logo-Banner.png"
9039
9141
  }) {
9142
+ const [step, setStep] = useState(onClaimHandle ? "handle" : "funds");
9143
+ const [handle, setHandle] = useState("");
9144
+ const [claiming, setClaiming] = useState(false);
9145
+ const [handleError, setHandleError] = useState("");
9146
+ useEffect(() => {
9147
+ if (open) {
9148
+ setStep(onClaimHandle ? "handle" : "funds");
9149
+ setHandle("");
9150
+ setClaiming(false);
9151
+ setHandleError("");
9152
+ }
9153
+ }, [open, onClaimHandle]);
9040
9154
  useEffect(() => {
9041
9155
  if (!open) return;
9042
9156
  const onKey = (e) => {
@@ -9046,6 +9160,58 @@ function OnboardingGuide({
9046
9160
  return () => window.removeEventListener("keydown", onKey);
9047
9161
  }, [open, onClose]);
9048
9162
  if (!open) return null;
9163
+ const handleClaimContinue = async () => {
9164
+ const trimmed = handle.trim().replace(/^@+/, "");
9165
+ if (trimmed && onClaimHandle) {
9166
+ setClaiming(true);
9167
+ setHandleError("");
9168
+ try {
9169
+ await onClaimHandle(trimmed);
9170
+ } catch (err) {
9171
+ setHandleError(err instanceof Error ? err.message : "Couldn't claim that handle. Try another or skip.");
9172
+ setClaiming(false);
9173
+ return;
9174
+ }
9175
+ setClaiming(false);
9176
+ }
9177
+ setStep("funds");
9178
+ };
9179
+ if (step === "handle") {
9180
+ return /* @__PURE__ */ jsx(Overlay3, { onClick: onClose, role: "dialog", "aria-modal": "true", "aria-label": "Claim your handle", children: /* @__PURE__ */ jsxs(Card2, { onClick: (e) => e.stopPropagation(), children: [
9181
+ /* @__PURE__ */ jsx(CloseButton2, { onClick: onClose, "aria-label": "Skip", children: /* @__PURE__ */ jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, children: /* @__PURE__ */ jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M6 6l12 12M18 6L6 18" }) }) }),
9182
+ /* @__PURE__ */ jsxs(LogoRow, { children: [
9183
+ /* @__PURE__ */ jsx(LogoImage2, { src: logoSrc, alt: "Loaf" }),
9184
+ /* @__PURE__ */ jsx(LogoBeta2, { children: "Private Beta" })
9185
+ ] }),
9186
+ /* @__PURE__ */ jsx(Title2, { children: "Claim your handle" }),
9187
+ /* @__PURE__ */ jsx(Subtitle2, { children: "Pick a username for your Loaf profile. It's optional \u2014 you can set or change it later." }),
9188
+ /* @__PURE__ */ jsxs(HandleField, { children: [
9189
+ /* @__PURE__ */ jsx(HandleAt, { children: "@" }),
9190
+ /* @__PURE__ */ jsx(
9191
+ HandleInput,
9192
+ {
9193
+ type: "text",
9194
+ autoComplete: "off",
9195
+ autoCapitalize: "none",
9196
+ spellCheck: false,
9197
+ placeholder: "username (optional)",
9198
+ value: handle,
9199
+ onChange: (e) => {
9200
+ setHandle(e.target.value.replace(/[^a-zA-Z0-9_]/g, ""));
9201
+ setHandleError("");
9202
+ },
9203
+ onKeyDown: (e) => {
9204
+ if (e.key === "Enter" && !claiming) void handleClaimContinue();
9205
+ },
9206
+ autoFocus: true
9207
+ }
9208
+ )
9209
+ ] }),
9210
+ handleError && /* @__PURE__ */ jsx(FieldError, { children: handleError }),
9211
+ /* @__PURE__ */ jsx(PrimaryButton, { onClick: () => void handleClaimContinue(), disabled: claiming, children: claiming ? "Saving\u2026" : "Continue" }),
9212
+ /* @__PURE__ */ jsx(SkipButton, { onClick: () => setStep("funds"), disabled: claiming, children: "Skip for now" })
9213
+ ] }) });
9214
+ }
9049
9215
  return /* @__PURE__ */ jsx(Overlay3, { onClick: onClose, role: "dialog", "aria-modal": "true", "aria-label": "Welcome to Loaf", children: /* @__PURE__ */ jsxs(Card2, { onClick: (e) => e.stopPropagation(), children: [
9050
9216
  /* @__PURE__ */ jsx(CloseButton2, { onClick: onClose, "aria-label": "Skip", children: /* @__PURE__ */ jsx("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, children: /* @__PURE__ */ jsx("path", { strokeLinecap: "round", strokeLinejoin: "round", d: "M6 6l12 12M18 6L6 18" }) }) }),
9051
9217
  /* @__PURE__ */ jsxs(LogoRow, { children: [
@@ -12109,6 +12275,11 @@ var DocIcon = () => /* @__PURE__ */ jsxs("svg", { width: "20", height: "20", vie
12109
12275
  /* @__PURE__ */ jsx("line", { x1: "16", y1: "17", x2: "8", y2: "17" }),
12110
12276
  /* @__PURE__ */ jsx("polyline", { points: "10 9 9 9 8 9" })
12111
12277
  ] });
12278
+ var DownloadIcon = () => /* @__PURE__ */ jsxs("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", children: [
12279
+ /* @__PURE__ */ jsx("path", { d: "M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4" }),
12280
+ /* @__PURE__ */ jsx("polyline", { points: "7 10 12 15 17 10" }),
12281
+ /* @__PURE__ */ jsx("line", { x1: "12", y1: "15", x2: "12", y2: "3" })
12282
+ ] });
12112
12283
  var LIVE_TITLE_PATTERNS = [/term\s*sheet/i, /memo/i];
12113
12284
  var COMING_SOON_TITLES = [
12114
12285
  "Valuation Report",
@@ -12123,11 +12294,30 @@ var COMING_SOON_TITLES = [
12123
12294
  ];
12124
12295
  function PropertyDocuments({ documentsData, highlightDocument, onClearHighlight }) {
12125
12296
  const highlightRef = useRef(null);
12126
- useRef(null);
12297
+ const [previewUrl, setPreviewUrl] = useState(null);
12298
+ const [previewTitle, setPreviewTitle] = useState(null);
12299
+ const backendDocuments = Array.isArray(documentsData?.documents) ? documentsData.documents : [];
12300
+ const liveDocs = backendDocuments.filter(
12301
+ (d) => Boolean(d.documentUrl) && isSafeUrl(d.documentUrl) && LIVE_TITLE_PATTERNS.some((rx) => rx.test(d.title))
12302
+ );
12303
+ const comingSoonDocs = COMING_SOON_TITLES.filter(
12304
+ (title) => !liveDocs.some((d) => d.title.toLowerCase().includes(title.toLowerCase()) || title.toLowerCase().includes(d.title.toLowerCase()))
12305
+ ).map((title) => ({ title, documentUrl: "" }));
12306
+ const documents = [...liveDocs, ...comingSoonDocs];
12307
+ const activeUrl = previewUrl ?? (liveDocs[0]?.documentUrl || null);
12308
+ const activeTitle = previewUrl ? previewTitle : liveDocs[0]?.title || null;
12309
+ const selectPreview = (doc) => {
12310
+ setPreviewUrl(doc.documentUrl);
12311
+ setPreviewTitle(doc.title);
12312
+ };
12127
12313
  useEffect(() => {
12128
12314
  if (highlightDocument && highlightRef.current) {
12129
12315
  highlightRef.current.scrollIntoView({ behavior: "smooth", block: "nearest" });
12130
12316
  }
12317
+ if (highlightDocument) {
12318
+ const hit = liveDocs.find((d) => d.title.toLowerCase().includes(highlightDocument.toLowerCase()));
12319
+ if (hit) selectPreview(hit);
12320
+ }
12131
12321
  }, [highlightDocument]);
12132
12322
  useEffect(() => {
12133
12323
  if (!highlightDocument || !onClearHighlight) return;
@@ -12139,36 +12329,58 @@ function PropertyDocuments({ documentsData, highlightDocument, onClearHighlight
12139
12329
  document.addEventListener("click", handler, true);
12140
12330
  return () => document.removeEventListener("click", handler, true);
12141
12331
  }, [highlightDocument, onClearHighlight]);
12142
- const backendDocuments = Array.isArray(documentsData?.documents) ? documentsData.documents : [];
12143
- const liveDocs = backendDocuments.filter(
12144
- (d) => Boolean(d.documentUrl) && LIVE_TITLE_PATTERNS.some((rx) => rx.test(d.title))
12145
- );
12146
- const comingSoonDocs = COMING_SOON_TITLES.filter(
12147
- (title) => !liveDocs.some((d) => d.title.toLowerCase().includes(title.toLowerCase()) || title.toLowerCase().includes(d.title.toLowerCase()))
12148
- ).map((title) => ({ title, documentUrl: "" }));
12149
- const documents = [...liveDocs, ...comingSoonDocs];
12150
12332
  return /* @__PURE__ */ jsxs(Section2, { children: [
12151
12333
  /* @__PURE__ */ jsx(SectionHeading, { children: "Investment Documents" }),
12152
- /* @__PURE__ */ jsx(DocList, { children: documents.map(({ documentUrl, title }) => {
12153
- const isAvailable = Boolean(documentUrl);
12154
- const isHighlighted = highlightDocument != null && title.toLowerCase().includes(highlightDocument.toLowerCase());
12155
- return /* @__PURE__ */ jsx(
12156
- DocItem,
12334
+ /* @__PURE__ */ jsxs(SplitLayout, { children: [
12335
+ /* @__PURE__ */ jsx(DocList, { children: documents.map(({ documentUrl, title }) => {
12336
+ const isAvailable = Boolean(documentUrl);
12337
+ const isHighlighted = highlightDocument != null && title.toLowerCase().includes(highlightDocument.toLowerCase());
12338
+ const isActive = isAvailable && documentUrl === activeUrl;
12339
+ return /* @__PURE__ */ jsx(
12340
+ DocItem,
12341
+ {
12342
+ ref: isHighlighted ? highlightRef : void 0,
12343
+ $highlighted: isHighlighted,
12344
+ children: /* @__PURE__ */ jsxs(
12345
+ DocRow,
12346
+ {
12347
+ $available: isAvailable,
12348
+ $active: isActive,
12349
+ onMouseEnter: isAvailable ? () => selectPreview({ documentUrl, title }) : void 0,
12350
+ onClick: isAvailable ? () => selectPreview({ documentUrl, title }) : void 0,
12351
+ children: [
12352
+ /* @__PURE__ */ jsxs(DocName, { $available: isAvailable, children: [
12353
+ /* @__PURE__ */ jsx(DocIconWrapper, { children: /* @__PURE__ */ jsx(DocIcon, {}) }),
12354
+ title
12355
+ ] }),
12356
+ isAvailable ? /* @__PURE__ */ jsx(
12357
+ DownloadBtn,
12358
+ {
12359
+ href: documentUrl,
12360
+ target: "_blank",
12361
+ rel: "noopener noreferrer",
12362
+ "aria-label": `Open ${title}`,
12363
+ title: "Open document",
12364
+ onClick: (e) => e.stopPropagation(),
12365
+ children: /* @__PURE__ */ jsx(DownloadIcon, {})
12366
+ }
12367
+ ) : /* @__PURE__ */ jsx(ComingSoonBadge, { children: "Coming Soon" })
12368
+ ]
12369
+ }
12370
+ )
12371
+ },
12372
+ `${title}-${documentUrl || "pending"}`
12373
+ );
12374
+ }) }),
12375
+ /* @__PURE__ */ jsx(PreviewPane, { children: activeUrl ? /* @__PURE__ */ jsx(
12376
+ PreviewFrame,
12157
12377
  {
12158
- ref: isHighlighted ? highlightRef : void 0,
12159
- $highlighted: isHighlighted,
12160
- children: isAvailable ? /* @__PURE__ */ jsxs(DocLink, { href: documentUrl, target: "_blank", rel: "noopener noreferrer", children: [
12161
- /* @__PURE__ */ jsx(DocIconWrapper, { children: /* @__PURE__ */ jsx(DocIcon, {}) }),
12162
- title
12163
- ] }) : /* @__PURE__ */ jsxs(DocItemDisabled, { children: [
12164
- /* @__PURE__ */ jsx(DocIconWrapper, { children: /* @__PURE__ */ jsx(DocIcon, {}) }),
12165
- title,
12166
- /* @__PURE__ */ jsx(ComingSoonBadge, { children: "Coming Soon" })
12167
- ] })
12378
+ src: `${activeUrl}#toolbar=0&navpanes=0&view=FitH`,
12379
+ title: activeTitle ?? "Document preview"
12168
12380
  },
12169
- `${title}-${documentUrl || "pending"}`
12170
- );
12171
- }) })
12381
+ activeUrl
12382
+ ) : /* @__PURE__ */ jsx(PreviewEmpty, { children: "Hover a document to preview it here" }) })
12383
+ ] })
12172
12384
  ] });
12173
12385
  }
12174
12386
  var Section2 = styled10.section`
@@ -12188,45 +12400,103 @@ var SectionHeading = styled10.h2`
12188
12400
  align-items: center;
12189
12401
  gap: 0.5rem;
12190
12402
  `;
12403
+ var SplitLayout = styled10.div`
12404
+ display: flex;
12405
+ gap: 1.25rem;
12406
+ align-items: stretch;
12407
+
12408
+ @media (max-width: 768px) {
12409
+ flex-direction: column;
12410
+ }
12411
+ `;
12191
12412
  var DocList = styled10.ul`
12192
12413
  list-style: none;
12193
12414
  padding: 0;
12194
12415
  margin: 0;
12416
+ flex: 1 1 50%;
12417
+ min-width: 0;
12195
12418
  `;
12196
12419
  var DocItem = styled10.li`
12197
- padding: 0.75rem 0;
12420
+ padding: 0.35rem 0;
12198
12421
  border-bottom: 1px solid var(--color-border, rgba(255, 255, 255, 0.1));
12199
12422
  border-radius: ${(p) => p.$highlighted ? "6px" : "0"};
12200
12423
  background: ${(p) => p.$highlighted ? "rgba(212, 175, 55, 0.08)" : "transparent"};
12201
- ${(p) => p.$highlighted ? "padding: 0.75rem;" : ""}
12202
12424
  transition: background 0.3s;
12203
12425
 
12204
12426
  &:last-child {
12205
12427
  border-bottom: none;
12206
12428
  }
12207
12429
  `;
12208
- var DocLink = styled10.a`
12430
+ var DocRow = styled10.div`
12209
12431
  display: flex;
12210
12432
  align-items: center;
12211
- color: var(--color-text);
12212
- text-decoration: none;
12213
- transition: color 0.2s;
12433
+ gap: 0.5rem;
12434
+ padding: 0.4rem 0.5rem;
12435
+ border-radius: 6px;
12436
+ cursor: ${(p) => p.$available ? "pointer" : "not-allowed"};
12437
+ background: ${(p) => p.$active ? "rgba(230, 200, 126, 0.10)" : "transparent"};
12438
+ transition: background 0.2s, color 0.2s;
12214
12439
 
12215
- &:hover {
12216
- color: var(--color-accent);
12217
- }
12440
+ ${(p) => p.$available && !p.$active ? "&:hover { background: rgba(230, 200, 126, 0.06); }" : ""}
12218
12441
  `;
12219
- var DocItemDisabled = styled10.div`
12442
+ var DocName = styled10.span`
12220
12443
  display: flex;
12221
12444
  align-items: center;
12222
- color: var(--color-text-secondary);
12223
- cursor: not-allowed;
12224
- opacity: 0.6;
12445
+ flex: 1;
12446
+ min-width: 0;
12447
+ color: ${(p) => p.$available ? "var(--color-text)" : "var(--color-text-secondary)"};
12448
+ opacity: ${(p) => p.$available ? 1 : 0.6};
12225
12449
  `;
12226
12450
  var DocIconWrapper = styled10.span`
12227
12451
  margin-right: 0.75rem;
12228
12452
  flex-shrink: 0;
12229
12453
  color: var(--color-text-secondary);
12454
+ display: inline-flex;
12455
+ `;
12456
+ var DownloadBtn = styled10.a`
12457
+ flex-shrink: 0;
12458
+ display: inline-flex;
12459
+ align-items: center;
12460
+ justify-content: center;
12461
+ width: 30px;
12462
+ height: 30px;
12463
+ border-radius: 6px;
12464
+ color: var(--color-text-secondary);
12465
+ transition: color 0.2s, background 0.2s;
12466
+
12467
+ &:hover {
12468
+ color: var(--color-accent);
12469
+ background: rgba(230, 200, 126, 0.1);
12470
+ }
12471
+ `;
12472
+ var PreviewPane = styled10.div`
12473
+ flex: 1 1 50%;
12474
+ min-width: 0;
12475
+ min-height: 360px;
12476
+ display: flex;
12477
+ border: 1px solid var(--color-border, rgba(255, 255, 255, 0.1));
12478
+ border-radius: 10px;
12479
+ overflow: hidden;
12480
+ background: rgba(0, 0, 0, 0.25);
12481
+
12482
+ /* No hover on touch devices — fall back to the list + download icon. */
12483
+ @media (max-width: 768px) {
12484
+ display: none;
12485
+ }
12486
+ `;
12487
+ var PreviewFrame = styled10.iframe`
12488
+ width: 100%;
12489
+ height: 100%;
12490
+ min-height: 360px;
12491
+ border: 0;
12492
+ background: #fff;
12493
+ `;
12494
+ var PreviewEmpty = styled10.div`
12495
+ margin: auto;
12496
+ padding: 1rem;
12497
+ text-align: center;
12498
+ color: var(--color-text-secondary);
12499
+ font-size: 0.85rem;
12230
12500
  `;
12231
12501
  var ComingSoonBadge = styled10.span`
12232
12502
  margin-left: auto;
@@ -12238,6 +12508,7 @@ var ComingSoonBadge = styled10.span`
12238
12508
  font-weight: 500;
12239
12509
  text-transform: uppercase;
12240
12510
  letter-spacing: 0.05em;
12511
+ flex-shrink: 0;
12241
12512
  `;
12242
12513
  var formatIsoDate = (value) => {
12243
12514
  const parsed = new Date(value);
@@ -19875,7 +20146,7 @@ var OpenMailButton = styled10.a`
19875
20146
  `;
19876
20147
  var ContactPopup = ({ onClose }) => {
19877
20148
  const [copied, setCopied] = useState(false);
19878
- const email = "Gavin@loafmarkets.com";
20149
+ const email = "admin@loafmarkets.com";
19879
20150
  const handleCopy = async () => {
19880
20151
  try {
19881
20152
  await navigator.clipboard.writeText(email);
@@ -20102,7 +20373,17 @@ var SiteFooter = () => {
20102
20373
  /* @__PURE__ */ jsx(FooterLinkItem, { children: /* @__PURE__ */ jsx(FooterLink, { href: "/trade", children: "Trade" }) }),
20103
20374
  /* @__PURE__ */ jsx(FooterLinkItem, { children: /* @__PURE__ */ jsx(FooterLink, { href: "/offerings", children: "Initial Offerings" }) }),
20104
20375
  /* @__PURE__ */ jsx(FooterLinkItem, { children: /* @__PURE__ */ jsx(FooterLink, { href: "/map", children: "Property Map" }) }),
20105
- /* @__PURE__ */ jsx(FooterLinkItem, { children: /* @__PURE__ */ jsx(FooterLink, { href: "/loaf-liquidity", children: "Loaf Liquidity" }) })
20376
+ /* @__PURE__ */ jsx(FooterLinkItem, { children: /* @__PURE__ */ jsx(
20377
+ FooterLink,
20378
+ {
20379
+ href: "/loaf-liquidity",
20380
+ onClick: (e) => {
20381
+ e.preventDefault();
20382
+ if (typeof window !== "undefined") window.dispatchEvent(new CustomEvent("loaf:open-liquidity-popup"));
20383
+ },
20384
+ children: "Loaf Liquidity"
20385
+ }
20386
+ ) })
20106
20387
  ] })
20107
20388
  ] }),
20108
20389
  /* @__PURE__ */ jsxs(FooterColumn, { children: [
@@ -20138,7 +20419,7 @@ var SiteFooter = () => {
20138
20419
  /* @__PURE__ */ jsx(LegalLink, { href: "/cookies", children: "Cookie Policy" })
20139
20420
  ] })
20140
20421
  ] }),
20141
- /* @__PURE__ */ jsx(Disclaimer2, { children: /* @__PURE__ */ jsx(DisclaimerText, { children: "Warning: Digital asset prices can be volatile. The value of your investment can go down or up and you may not get back the amount invested. Past gains are not indicative of future returns. You are solely responsible for your investment decisions and Loaf is not liable for any losses you may incur. The information here should not be regarded as financial or investment advice. For more information, see our Terms of Use and Risk Warning." }) })
20422
+ /* @__PURE__ */ jsx(Disclaimer2, { children: /* @__PURE__ */ jsx(DisclaimerText, { children: "Warning: Digital asset prices can be volatile. The value of your investment can go down or up and you may not get back the amount invested. Past gains are not indicative of future returns. You are solely responsible for your investment decisions and Loaf is not liable for any losses you may incur. The information here should not be regarded as financial or investment advice. For more information, see our Terms of Use." }) })
20142
20423
  ] }) }),
20143
20424
  showContactPopup && /* @__PURE__ */ jsx(ContactPopup, { onClose: () => setShowContactPopup(false) })
20144
20425
  ] });