@loafmarkets/ui 0.1.344 → 0.1.345
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.d.mts +25 -4
- package/dist/index.d.ts +25 -4
- package/dist/index.js +385 -168
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +385 -168
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1716,17 +1716,21 @@ function getTradeKey(trade, fallbackIndex) {
|
|
|
1716
1716
|
if (trade.time != null) return `t-${trade.time}-${trade.type}-${trade.price}-${trade.amount}`;
|
|
1717
1717
|
return `idx-${fallbackIndex}-${trade.type}-${trade.price}-${trade.amount}`;
|
|
1718
1718
|
}
|
|
1719
|
-
function
|
|
1720
|
-
|
|
1719
|
+
function flashElement(node, side) {
|
|
1720
|
+
if (typeof node.animate !== "function") return;
|
|
1721
|
+
const color = side === "bid" ? FLASH_UP_COLOR : FLASH_DOWN_COLOR;
|
|
1722
|
+
node.animate(
|
|
1723
|
+
[{ backgroundColor: color }, { backgroundColor: "transparent" }],
|
|
1724
|
+
{ duration: FLASH_DURATION_MS, easing: "ease-out" }
|
|
1725
|
+
);
|
|
1726
|
+
}
|
|
1727
|
+
function useAmountChangeFlash(ref, amount, side, flashOnMount) {
|
|
1728
|
+
const prevAmountRef = React5__namespace.useRef(flashOnMount ? null : amount);
|
|
1721
1729
|
React5__namespace.useEffect(() => {
|
|
1722
1730
|
const prev = prevAmountRef.current;
|
|
1723
1731
|
const node = ref.current;
|
|
1724
|
-
if (
|
|
1725
|
-
|
|
1726
|
-
node.animate(
|
|
1727
|
-
[{ backgroundColor: color }, { backgroundColor: "transparent" }],
|
|
1728
|
-
{ duration: FLASH_DURATION_MS, easing: "ease-out" }
|
|
1729
|
-
);
|
|
1732
|
+
if (node && prev !== amount) {
|
|
1733
|
+
flashElement(node, side);
|
|
1730
1734
|
}
|
|
1731
1735
|
prevAmountRef.current = amount;
|
|
1732
1736
|
}, [amount, ref, side]);
|
|
@@ -1830,11 +1834,12 @@ function DepthRow({
|
|
|
1830
1834
|
precision,
|
|
1831
1835
|
amountPrecision,
|
|
1832
1836
|
hasUserOrder,
|
|
1833
|
-
onPriceClick
|
|
1837
|
+
onPriceClick,
|
|
1838
|
+
flashOnMount
|
|
1834
1839
|
}) {
|
|
1835
1840
|
const isAsk = side === "ask";
|
|
1836
1841
|
const rowRef = React5__namespace.useRef(null);
|
|
1837
|
-
useAmountChangeFlash(rowRef, amount, side);
|
|
1842
|
+
useAmountChangeFlash(rowRef, amount, side, flashOnMount);
|
|
1838
1843
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1839
1844
|
"div",
|
|
1840
1845
|
{
|
|
@@ -1846,11 +1851,15 @@ function DepthRow({
|
|
|
1846
1851
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
1847
1852
|
"div",
|
|
1848
1853
|
{
|
|
1849
|
-
className: cn(
|
|
1850
|
-
|
|
1851
|
-
|
|
1852
|
-
|
|
1853
|
-
|
|
1854
|
+
className: cn(isAsk ? "bg-rose-900/30" : "bg-emerald-900/30"),
|
|
1855
|
+
style: {
|
|
1856
|
+
position: "absolute",
|
|
1857
|
+
top: 0,
|
|
1858
|
+
bottom: 0,
|
|
1859
|
+
left: 0,
|
|
1860
|
+
width: `${clamp3(depthPct, 0, 100)}%`,
|
|
1861
|
+
transition: "width 300ms ease-out"
|
|
1862
|
+
}
|
|
1854
1863
|
}
|
|
1855
1864
|
),
|
|
1856
1865
|
hasUserOrder ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -1871,7 +1880,7 @@ function DepthRow({
|
|
|
1871
1880
|
);
|
|
1872
1881
|
}
|
|
1873
1882
|
var clamp3 = (value, min, max) => Math.min(max, Math.max(min, value));
|
|
1874
|
-
var LEVEL_ROWS_VISIBLE =
|
|
1883
|
+
var LEVEL_ROWS_VISIBLE = 8;
|
|
1875
1884
|
var DEPTH_ROW_HEIGHT_PX = 28;
|
|
1876
1885
|
var COMPACT_ROWS_VISIBLE = 5;
|
|
1877
1886
|
var COMPACT_ROW_HEIGHT_PX = 30;
|
|
@@ -1966,6 +1975,32 @@ var Orderbook = React5__namespace.forwardRef(
|
|
|
1966
1975
|
}
|
|
1967
1976
|
const combinedMaxCumDepth = Math.max(1, ...askCumDepths, ...bidCumDepths);
|
|
1968
1977
|
const askMaxCumDepth = combinedMaxCumDepth;
|
|
1978
|
+
const prevAskPricesRef = React5__namespace.useRef(null);
|
|
1979
|
+
const prevBidPricesRef = React5__namespace.useRef(null);
|
|
1980
|
+
const newAskPrices = React5__namespace.useMemo(() => {
|
|
1981
|
+
const current = new Set(askVisibleLevels.map((l) => l.price));
|
|
1982
|
+
const prev = prevAskPricesRef.current;
|
|
1983
|
+
if (!prev) return /* @__PURE__ */ new Set();
|
|
1984
|
+
const added = /* @__PURE__ */ new Set();
|
|
1985
|
+
for (const p of current) {
|
|
1986
|
+
if (!prev.has(p)) added.add(p);
|
|
1987
|
+
}
|
|
1988
|
+
return added;
|
|
1989
|
+
}, [askVisibleLevels]);
|
|
1990
|
+
const newBidPrices = React5__namespace.useMemo(() => {
|
|
1991
|
+
const current = new Set(bidVisibleLevels.map((l) => l.price));
|
|
1992
|
+
const prev = prevBidPricesRef.current;
|
|
1993
|
+
if (!prev) return /* @__PURE__ */ new Set();
|
|
1994
|
+
const added = /* @__PURE__ */ new Set();
|
|
1995
|
+
for (const p of current) {
|
|
1996
|
+
if (!prev.has(p)) added.add(p);
|
|
1997
|
+
}
|
|
1998
|
+
return added;
|
|
1999
|
+
}, [bidVisibleLevels]);
|
|
2000
|
+
React5__namespace.useEffect(() => {
|
|
2001
|
+
prevAskPricesRef.current = new Set(askVisibleLevels.map((l) => l.price));
|
|
2002
|
+
prevBidPricesRef.current = new Set(bidVisibleLevels.map((l) => l.price));
|
|
2003
|
+
}, [askVisibleLevels, bidVisibleLevels]);
|
|
1969
2004
|
const bidMaxCumDepth = combinedMaxCumDepth;
|
|
1970
2005
|
const midClass = midChangePercent == null ? "text-white" : midChangePercent >= 0 ? "text-[#0ecb81]" : "text-[#f6465d]";
|
|
1971
2006
|
const tradeFiltered = trades.filter((t) => tradeFilter === "all" || t.type === tradeFilter);
|
|
@@ -2000,7 +2035,9 @@ var Orderbook = React5__namespace.forwardRef(
|
|
|
2000
2035
|
onPriceClick,
|
|
2001
2036
|
levelCount: effectiveLevels,
|
|
2002
2037
|
compactLevelCount: effectiveCompactLevels,
|
|
2003
|
-
fillHeight
|
|
2038
|
+
fillHeight,
|
|
2039
|
+
newAskPrices,
|
|
2040
|
+
newBidPrices
|
|
2004
2041
|
};
|
|
2005
2042
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
2006
2043
|
Card,
|
|
@@ -2072,7 +2109,9 @@ function DesktopOrderbookLayout({
|
|
|
2072
2109
|
onPriceClick,
|
|
2073
2110
|
levelCount: effectiveLevels,
|
|
2074
2111
|
compactLevelCount: _compactLevelCount,
|
|
2075
|
-
fillHeight
|
|
2112
|
+
fillHeight,
|
|
2113
|
+
newAskPrices,
|
|
2114
|
+
newBidPrices
|
|
2076
2115
|
}) {
|
|
2077
2116
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2078
2117
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between px-4 pt-4", children: [
|
|
@@ -2192,7 +2231,8 @@ function DesktopOrderbookLayout({
|
|
|
2192
2231
|
precision,
|
|
2193
2232
|
amountPrecision,
|
|
2194
2233
|
hasUserOrder: userAskPrices.has(l.price),
|
|
2195
|
-
onPriceClick
|
|
2234
|
+
onPriceClick,
|
|
2235
|
+
flashOnMount: newAskPrices.has(l.price)
|
|
2196
2236
|
},
|
|
2197
2237
|
`ask-${l.price}`
|
|
2198
2238
|
))
|
|
@@ -2229,7 +2269,8 @@ function DesktopOrderbookLayout({
|
|
|
2229
2269
|
precision,
|
|
2230
2270
|
amountPrecision,
|
|
2231
2271
|
hasUserOrder: userBidPrices.has(l.price),
|
|
2232
|
-
onPriceClick
|
|
2272
|
+
onPriceClick,
|
|
2273
|
+
flashOnMount: newBidPrices.has(l.price)
|
|
2233
2274
|
},
|
|
2234
2275
|
`bid-${l.price}`
|
|
2235
2276
|
))
|
|
@@ -2267,7 +2308,9 @@ function MobileOrderbookLayout({
|
|
|
2267
2308
|
tradeExplorerUrl,
|
|
2268
2309
|
onPriceClick,
|
|
2269
2310
|
levelCount: _levelCount,
|
|
2270
|
-
compactLevelCount: effectiveCompactLevels
|
|
2311
|
+
compactLevelCount: effectiveCompactLevels,
|
|
2312
|
+
newAskPrices,
|
|
2313
|
+
newBidPrices
|
|
2271
2314
|
}) {
|
|
2272
2315
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2273
2316
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "px-3 pt-2", children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
|
|
@@ -2347,7 +2390,8 @@ function MobileOrderbookLayout({
|
|
|
2347
2390
|
precision,
|
|
2348
2391
|
amountPrecision,
|
|
2349
2392
|
hasUserOrder: userAskPrices.has(l.price),
|
|
2350
|
-
onPriceClick
|
|
2393
|
+
onPriceClick,
|
|
2394
|
+
flashOnMount: newAskPrices.has(l.price)
|
|
2351
2395
|
},
|
|
2352
2396
|
`mobile-ask-${l.price}`
|
|
2353
2397
|
)) }),
|
|
@@ -2393,7 +2437,8 @@ function MobileOrderbookLayout({
|
|
|
2393
2437
|
precision,
|
|
2394
2438
|
amountPrecision,
|
|
2395
2439
|
hasUserOrder: userBidPrices.has(l.price),
|
|
2396
|
-
onPriceClick
|
|
2440
|
+
onPriceClick,
|
|
2441
|
+
flashOnMount: newBidPrices.has(l.price)
|
|
2397
2442
|
},
|
|
2398
2443
|
`mobile-bid-${l.price}`
|
|
2399
2444
|
)) })
|
|
@@ -2437,11 +2482,12 @@ function MobileDepthRow({
|
|
|
2437
2482
|
precision,
|
|
2438
2483
|
amountPrecision,
|
|
2439
2484
|
hasUserOrder,
|
|
2440
|
-
onPriceClick
|
|
2485
|
+
onPriceClick,
|
|
2486
|
+
flashOnMount
|
|
2441
2487
|
}) {
|
|
2442
2488
|
const isAsk = side === "ask";
|
|
2443
2489
|
const rowRef = React5__namespace.useRef(null);
|
|
2444
|
-
useAmountChangeFlash(rowRef, amount, side);
|
|
2490
|
+
useAmountChangeFlash(rowRef, amount, side, flashOnMount);
|
|
2445
2491
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2446
2492
|
"div",
|
|
2447
2493
|
{
|
|
@@ -2486,7 +2532,7 @@ function MobileDepthRow({
|
|
|
2486
2532
|
style: {
|
|
2487
2533
|
position: "absolute",
|
|
2488
2534
|
top: 0,
|
|
2489
|
-
|
|
2535
|
+
left: 0,
|
|
2490
2536
|
bottom: 0,
|
|
2491
2537
|
width: `${clamp3(depthPct, 0, 100)}%`,
|
|
2492
2538
|
backgroundColor: isAsk ? "#f6465d" : "#0ecb81",
|
|
@@ -2598,7 +2644,8 @@ var PropertyTour = React5__namespace.forwardRef(
|
|
|
2598
2644
|
}
|
|
2599
2645
|
);
|
|
2600
2646
|
PropertyTour.displayName = "PropertyTour";
|
|
2601
|
-
var ITEMS_PER_PAGE =
|
|
2647
|
+
var ITEMS_PER_PAGE = 5;
|
|
2648
|
+
var ITEMS_PER_PAGE_MOBILE = 5;
|
|
2602
2649
|
var ensureAnimationsInjected = () => {
|
|
2603
2650
|
if (typeof document === "undefined") return;
|
|
2604
2651
|
if (document.getElementById("property-news-updates-animations")) return;
|
|
@@ -2854,6 +2901,15 @@ var PropertyNewsUpdates = React5__namespace.forwardRef(
|
|
|
2854
2901
|
const purchaseItems = purchasesProp ?? [];
|
|
2855
2902
|
const [page, setPage] = React5__namespace.useState(0);
|
|
2856
2903
|
const [selectedItem, setSelectedItem] = React5__namespace.useState(null);
|
|
2904
|
+
const [isMobile, setIsMobile] = React5__namespace.useState(
|
|
2905
|
+
() => typeof window !== "undefined" && window.innerWidth <= 768
|
|
2906
|
+
);
|
|
2907
|
+
React5__namespace.useEffect(() => {
|
|
2908
|
+
const check = () => setIsMobile(window.innerWidth <= 768);
|
|
2909
|
+
window.addEventListener("resize", check);
|
|
2910
|
+
return () => window.removeEventListener("resize", check);
|
|
2911
|
+
}, []);
|
|
2912
|
+
const homePageSize = isMobile ? ITEMS_PER_PAGE_MOBILE : ITEMS_PER_PAGE;
|
|
2857
2913
|
React5__namespace.useEffect(() => {
|
|
2858
2914
|
ensureAnimationsInjected();
|
|
2859
2915
|
}, []);
|
|
@@ -2874,10 +2930,10 @@ var PropertyNewsUpdates = React5__namespace.forwardRef(
|
|
|
2874
2930
|
[hasItems, items, homeTab]
|
|
2875
2931
|
);
|
|
2876
2932
|
const homeTotalPages = React5__namespace.useMemo(
|
|
2877
|
-
() => Math.max(1, Math.ceil(homeFilteredItems.length /
|
|
2878
|
-
[homeFilteredItems.length]
|
|
2933
|
+
() => Math.max(1, Math.ceil(homeFilteredItems.length / homePageSize)),
|
|
2934
|
+
[homeFilteredItems.length, homePageSize]
|
|
2879
2935
|
);
|
|
2880
|
-
const homePaginatedItems = disablePagination ? homeFilteredItems : homeFilteredItems.slice(homePage *
|
|
2936
|
+
const homePaginatedItems = disablePagination ? homeFilteredItems : homeFilteredItems.slice(homePage * homePageSize, (homePage + 1) * homePageSize);
|
|
2881
2937
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2882
2938
|
"div",
|
|
2883
2939
|
{
|
|
@@ -2888,18 +2944,18 @@ var PropertyNewsUpdates = React5__namespace.forwardRef(
|
|
|
2888
2944
|
),
|
|
2889
2945
|
...props,
|
|
2890
2946
|
children: [
|
|
2891
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", children: [
|
|
2947
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between", style: isHomeVariant ? { marginBottom: "0.5rem", minHeight: isMobile ? "32px" : "24px", gap: isMobile ? "0.5rem" : "1rem" } : void 0, children: [
|
|
2892
2948
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center", gap: "0.5rem" }, children: [
|
|
2893
|
-
isHomeVariant && /* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width:
|
|
2949
|
+
isHomeVariant && /* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: isMobile ? 14 : 16, height: isMobile ? 14 : 16, viewBox: "0 0 24 24", fill: "currentColor", style: { color: "var(--color-text, #fff)", flexShrink: 0, display: "block" }, children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm-5 14H4v-4h11v4zm0-5H4V9h11v4zm5 5h-4V9h4v9z" }) }),
|
|
2894
2950
|
isPurchaseVariant && /* @__PURE__ */ jsxRuntime.jsx("span", { style: { display: "inline-block", width: "8px", height: "8px", borderRadius: "50%", backgroundColor: "#0ecb81", boxShadow: "0 0 8px rgba(14,203,129,0.8)", animation: "propertyNewsPulse 1.5s infinite" } }),
|
|
2895
2951
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
2896
|
-
/* @__PURE__ */ jsxRuntime.jsx("p", {
|
|
2952
|
+
/* @__PURE__ */ jsxRuntime.jsx("p", { style: { margin: 0, fontSize: isHomeVariant ? isMobile ? "0.85rem" : "1rem" : "1.125rem", fontWeight: 600, color: "#fff", lineHeight: 1.2 }, children: resolvedHeading }),
|
|
2897
2953
|
subheading ? /* @__PURE__ */ jsxRuntime.jsx("p", { className: "text-sm text-white/60", children: subheading }) : null
|
|
2898
2954
|
] })
|
|
2899
2955
|
] }),
|
|
2900
|
-
isHomeVariant && viewAllHref ? /* @__PURE__ */ jsxRuntime.jsxs("a", { href: viewAllHref, style: { color: "var(--color-accent, #f0b90b)", fontWeight: 500, fontSize: "0.
|
|
2956
|
+
isHomeVariant && viewAllHref ? /* @__PURE__ */ jsxRuntime.jsxs("a", { href: viewAllHref, style: { color: "var(--color-accent, #f0b90b)", fontWeight: 500, fontSize: "0.75rem", textDecoration: "none", display: "flex", alignItems: "center", gap: "0.25rem", height: "24px" }, children: [
|
|
2901
2957
|
viewAllLabel,
|
|
2902
|
-
/* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: "
|
|
2958
|
+
/* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", width: "12", height: "12", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M10 6L8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z" }) })
|
|
2903
2959
|
] }) : !isHomeVariant && !isPurchaseVariant ? connectionStatus === "connecting" ? /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "inline-flex items-center font-semibold uppercase", style: { gap: "0.35rem", fontSize: "0.8rem", letterSpacing: "0.15em", color: "#f97316" }, children: [
|
|
2904
2960
|
/* @__PURE__ */ jsxRuntime.jsx("span", { style: { display: "inline-block", width: "10px", height: "10px", borderRadius: "50%", border: "2px solid rgba(249,115,22,0.3)", borderTopColor: "#f97316", animation: "propertyNewsSpin 0.8s linear infinite" } }),
|
|
2905
2961
|
"CONNECTING"
|
|
@@ -2908,7 +2964,7 @@ var PropertyNewsUpdates = React5__namespace.forwardRef(
|
|
|
2908
2964
|
"LIVE"
|
|
2909
2965
|
] }) : null
|
|
2910
2966
|
] }),
|
|
2911
|
-
isHomeVariant && /* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", gap: "1.5rem", marginTop: "0.
|
|
2967
|
+
isHomeVariant && /* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", gap: isMobile ? "1rem" : "1.5rem", marginTop: "0.25rem", marginBottom: "1rem", borderBottom: "1px solid rgba(255, 255, 255, 0.08)", paddingBottom: "0.5rem" }, children: ["all", "property", "market"].map((tab) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
2912
2968
|
"button",
|
|
2913
2969
|
{
|
|
2914
2970
|
type: "button",
|
|
@@ -2932,7 +2988,7 @@ var PropertyNewsUpdates = React5__namespace.forwardRef(
|
|
|
2932
2988
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
2933
2989
|
"div",
|
|
2934
2990
|
{
|
|
2935
|
-
className: cn("flex flex-1 flex-col overflow-y-auto overflow-x-hidden", isHomeVariant ? "
|
|
2991
|
+
className: cn("flex flex-1 flex-col overflow-y-auto overflow-x-hidden", isHomeVariant ? "gap-0" : "mt-4 gap-3"),
|
|
2936
2992
|
style: !isPurchaseVariant && !isHomeVariant ? { minHeight: `${ITEMS_PER_PAGE * 86}px` } : void 0,
|
|
2937
2993
|
children: isPurchaseVariant ? purchaseItems.length > 0 ? purchaseItems.slice(0, 7).map((purchase, index) => {
|
|
2938
2994
|
const maxAmount = 6e4;
|
|
@@ -2974,12 +3030,12 @@ var PropertyNewsUpdates = React5__namespace.forwardRef(
|
|
|
2974
3030
|
backgroundColor: "transparent",
|
|
2975
3031
|
border: "none",
|
|
2976
3032
|
cursor: "pointer",
|
|
2977
|
-
padding: "0.75rem 0",
|
|
3033
|
+
padding: isMobile ? "0.55rem 0" : "0.75rem 0",
|
|
2978
3034
|
borderBottom: index < homePaginatedItems.length - 1 ? "1px solid rgba(255,255,255,0.05)" : "none",
|
|
2979
3035
|
display: "flex",
|
|
2980
3036
|
justifyContent: "space-between",
|
|
2981
3037
|
alignItems: "flex-start",
|
|
2982
|
-
gap: "0.5rem",
|
|
3038
|
+
gap: isMobile ? "0.25rem" : "0.5rem",
|
|
2983
3039
|
color: "inherit",
|
|
2984
3040
|
transition: "background-color 0.15s"
|
|
2985
3041
|
},
|
|
@@ -2995,12 +3051,12 @@ var PropertyNewsUpdates = React5__namespace.forwardRef(
|
|
|
2995
3051
|
},
|
|
2996
3052
|
children: [
|
|
2997
3053
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { flex: 1 }, children: [
|
|
2998
|
-
/* @__PURE__ */ jsxRuntime.jsx("h3", { style: { fontSize: "0.95rem", fontWeight: 500, marginBottom: "0.35rem", color: "#f8f9fa", lineHeight: 1.
|
|
2999
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", gap: "0.5rem", alignItems: "center", flexWrap: "wrap" }, children: [
|
|
3000
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { style: { color: "#848e9c", fontSize: "0.7rem" }, children: formatDateShort(item.date) }),
|
|
3001
|
-
item.source && /* @__PURE__ */ jsxRuntime.jsx("span", { style: { padding: "0.1rem 0.4rem", borderRadius: "3px", fontSize: "0.62rem", fontWeight: 500, backgroundColor: "rgba(255,255,255,0.07)", color: "#848e9c", whiteSpace: "nowrap" }, children: item.source }),
|
|
3002
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { style: { padding: "0.15rem 0.4rem", borderRadius: "2px", fontSize: "0.65rem", fontWeight: 500, backgroundColor: isProperty ? "rgba(14,203,129,0.1)" : "rgba(240,185,11,0.1)", color: isProperty ? "#0ecb81" : "#f0b90b" }, children: isProperty ? "Property Update" : "Market News" }),
|
|
3003
|
-
sentimentInfo && /* @__PURE__ */ jsxRuntime.jsxs("span", { style: { fontSize: "0.65rem", fontWeight: 600, color: sentimentInfo.color }, children: [
|
|
3054
|
+
/* @__PURE__ */ jsxRuntime.jsx("h3", { style: { fontSize: isMobile ? "0.88rem" : "0.95rem", fontWeight: 500, marginBottom: isMobile ? "0.25rem" : "0.35rem", color: "#f8f9fa", lineHeight: isMobile ? 1.35 : 1.4, transition: "color 0.15s" }, children: item.title }),
|
|
3055
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", gap: isMobile ? "0.35rem" : "0.5rem", alignItems: "center", flexWrap: "wrap" }, children: [
|
|
3056
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { style: { color: "#848e9c", fontSize: isMobile ? "0.55rem" : "0.7rem" }, children: formatDateShort(item.date) }),
|
|
3057
|
+
item.source && /* @__PURE__ */ jsxRuntime.jsx("span", { style: { padding: isMobile ? "0.08rem 0.35rem" : "0.1rem 0.4rem", borderRadius: "3px", fontSize: isMobile ? "0.52rem" : "0.62rem", fontWeight: 500, backgroundColor: "rgba(255,255,255,0.07)", color: "#848e9c", whiteSpace: "nowrap" }, children: item.source }),
|
|
3058
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { style: { padding: isMobile ? "0.1rem 0.35rem" : "0.15rem 0.4rem", borderRadius: "2px", fontSize: isMobile ? "0.52rem" : "0.65rem", fontWeight: 500, backgroundColor: isProperty ? "rgba(14,203,129,0.1)" : "rgba(240,185,11,0.1)", color: isProperty ? "#0ecb81" : "#f0b90b" }, children: isProperty ? "Property Update" : "Market News" }),
|
|
3059
|
+
sentimentInfo && /* @__PURE__ */ jsxRuntime.jsxs("span", { style: { fontSize: isMobile ? "0.52rem" : "0.65rem", fontWeight: 600, color: sentimentInfo.color }, children: [
|
|
3004
3060
|
sentimentInfo.arrow ? `${sentimentInfo.arrow} ` : "",
|
|
3005
3061
|
sentimentInfo.label
|
|
3006
3062
|
] })
|
|
@@ -4565,6 +4621,9 @@ var PropertyHeroHeader = React5__namespace.forwardRef(
|
|
|
4565
4621
|
hideMakeOfferButton = false,
|
|
4566
4622
|
statusBadge,
|
|
4567
4623
|
isLoading = false,
|
|
4624
|
+
heroLabel,
|
|
4625
|
+
heroSidePanel,
|
|
4626
|
+
glowInfoCard,
|
|
4568
4627
|
...props
|
|
4569
4628
|
}, ref) => {
|
|
4570
4629
|
const isPositive = changePercent == null ? void 0 : changePercent >= 0;
|
|
@@ -4603,8 +4662,9 @@ var PropertyHeroHeader = React5__namespace.forwardRef(
|
|
|
4603
4662
|
statusBadge.variant === "live" ? /* @__PURE__ */ jsxRuntime.jsx(PulsingDot, {}) : null,
|
|
4604
4663
|
statusBadge.label
|
|
4605
4664
|
] }) : null,
|
|
4665
|
+
heroLabel ? /* @__PURE__ */ jsxRuntime.jsx(HeroTopLabel, { children: heroLabel }) : null,
|
|
4606
4666
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "absolute bottom-0 left-0 right-0 z-10 flex w-full items-end justify-center", style: { background: "linear-gradient(to top, rgba(0,0,0,0.7) 0%, rgba(0,0,0,0) 100%)" }, children: /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex w-full max-w-[1800px] flex-wrap items-end justify-between gap-4 p-8 max-[768px]:flex-col max-[768px]:items-start max-[768px]:gap-4 max-[768px]:p-6 max-[480px]:p-4", children: [
|
|
4607
|
-
/* @__PURE__ */ jsxRuntime.jsx(InfoCard, { children: /* @__PURE__ */ jsxRuntime.jsxs(CardLayout, { children: [
|
|
4667
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", flexDirection: "column", minWidth: 0 }, children: /* @__PURE__ */ jsxRuntime.jsx(InfoCard, { $glow: glowInfoCard, children: /* @__PURE__ */ jsxRuntime.jsxs(CardLayout, { children: [
|
|
4608
4668
|
/* @__PURE__ */ jsxRuntime.jsx(Thumbnail, { src: imageUrl, alt: imageAlt ?? name }),
|
|
4609
4669
|
/* @__PURE__ */ jsxRuntime.jsx(CardContent2, { children: /* @__PURE__ */ jsxRuntime.jsxs(InfoRow, { children: [
|
|
4610
4670
|
/* @__PURE__ */ jsxRuntime.jsx(NameGroup, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", flexDirection: "column" }, children: [
|
|
@@ -4629,7 +4689,8 @@ var PropertyHeroHeader = React5__namespace.forwardRef(
|
|
|
4629
4689
|
] }) : null
|
|
4630
4690
|
] })
|
|
4631
4691
|
] }) })
|
|
4632
|
-
] }) }),
|
|
4692
|
+
] }) }) }),
|
|
4693
|
+
heroSidePanel,
|
|
4633
4694
|
/* @__PURE__ */ jsxRuntime.jsxs(ActionButtons, { children: [
|
|
4634
4695
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
4635
4696
|
"button",
|
|
@@ -4793,6 +4854,14 @@ var CardContent2 = styled9__default.default.div`
|
|
|
4793
4854
|
min-width: 0;
|
|
4794
4855
|
flex: 1;
|
|
4795
4856
|
`;
|
|
4857
|
+
var infoCardGlow = styled9.keyframes`
|
|
4858
|
+
0%, 100% {
|
|
4859
|
+
box-shadow: 0 0 20px 4px rgba(230,185,50,0.3), 0 0 60px 15px rgba(230,185,50,0.15), 0 0 120px 40px rgba(210,150,30,0.08), inset 0 0 40px 5px rgba(230,185,50,0.04);
|
|
4860
|
+
}
|
|
4861
|
+
50% {
|
|
4862
|
+
box-shadow: 0 0 25px 6px rgba(230,185,50,0.4), 0 0 80px 20px rgba(230,185,50,0.2), 0 0 150px 50px rgba(210,150,30,0.1), inset 0 0 60px 8px rgba(230,185,50,0.06);
|
|
4863
|
+
}
|
|
4864
|
+
`;
|
|
4796
4865
|
var InfoCard = styled9__default.default.div`
|
|
4797
4866
|
border-radius: 12px;
|
|
4798
4867
|
background: rgba(0, 0, 0, 0.15);
|
|
@@ -4800,8 +4869,9 @@ var InfoCard = styled9__default.default.div`
|
|
|
4800
4869
|
color: #fff;
|
|
4801
4870
|
backdrop-filter: blur(6px);
|
|
4802
4871
|
box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
|
|
4803
|
-
border: 1px solid rgba(255, 255, 255, 0.12);
|
|
4872
|
+
border: 1px solid ${(p) => p.$glow ? "rgba(230, 200, 126, 0.35)" : "rgba(255, 255, 255, 0.12)"};
|
|
4804
4873
|
min-width: 0;
|
|
4874
|
+
${(p) => p.$glow && styled9.css`animation: ${infoCardGlow} 3s ease-in-out infinite;`}
|
|
4805
4875
|
|
|
4806
4876
|
@media (max-width: 768px) {
|
|
4807
4877
|
padding: 0.85rem 1.15rem;
|
|
@@ -4881,6 +4951,17 @@ var AddressText = styled9__default.default.p`
|
|
|
4881
4951
|
font-size: 0.9rem;
|
|
4882
4952
|
}
|
|
4883
4953
|
`;
|
|
4954
|
+
var HeroTopLabel = styled9__default.default.div`
|
|
4955
|
+
position: absolute;
|
|
4956
|
+
top: 2rem;
|
|
4957
|
+
left: 2.5rem;
|
|
4958
|
+
z-index: 10;
|
|
4959
|
+
|
|
4960
|
+
@media (max-width: 768px) {
|
|
4961
|
+
top: 1.25rem;
|
|
4962
|
+
left: 1.25rem;
|
|
4963
|
+
}
|
|
4964
|
+
`;
|
|
4884
4965
|
var PriceChangeRow = styled9__default.default.span`
|
|
4885
4966
|
display: inline-flex;
|
|
4886
4967
|
align-items: center;
|
|
@@ -4968,8 +5049,10 @@ var Header = ({
|
|
|
4968
5049
|
onWalletNavigate: _onWalletNavigate,
|
|
4969
5050
|
onSettingsClick,
|
|
4970
5051
|
showTradeTab = true,
|
|
4971
|
-
portfolioSummary
|
|
5052
|
+
portfolioSummary,
|
|
5053
|
+
transparentOnTop = false
|
|
4972
5054
|
}) => {
|
|
5055
|
+
const [headerBgOpacity, setHeaderBgOpacity] = React5.useState(transparentOnTop ? 0 : 1);
|
|
4973
5056
|
const [isUserMenuOpen, setIsUserMenuOpen] = React5.useState(false);
|
|
4974
5057
|
const [isMobileMenuOpen, setIsMobileMenuOpen] = React5.useState(false);
|
|
4975
5058
|
const [isMoreMenuOpen, setIsMoreMenuOpen] = React5.useState(false);
|
|
@@ -5025,6 +5108,19 @@ var Header = ({
|
|
|
5025
5108
|
document.documentElement.style.setProperty("--telegram-safe-top", "59px");
|
|
5026
5109
|
}
|
|
5027
5110
|
}, []);
|
|
5111
|
+
React5.useEffect(() => {
|
|
5112
|
+
if (!transparentOnTop) {
|
|
5113
|
+
setHeaderBgOpacity(1);
|
|
5114
|
+
return;
|
|
5115
|
+
}
|
|
5116
|
+
const onScroll = () => {
|
|
5117
|
+
const opacity = Math.min(window.scrollY / 200, 1);
|
|
5118
|
+
setHeaderBgOpacity(opacity);
|
|
5119
|
+
};
|
|
5120
|
+
onScroll();
|
|
5121
|
+
window.addEventListener("scroll", onScroll, { passive: true });
|
|
5122
|
+
return () => window.removeEventListener("scroll", onScroll);
|
|
5123
|
+
}, [transparentOnTop]);
|
|
5028
5124
|
React5.useEffect(() => {
|
|
5029
5125
|
const handleClickOutside = (event) => {
|
|
5030
5126
|
const target = event.target;
|
|
@@ -5131,7 +5227,9 @@ var Header = ({
|
|
|
5131
5227
|
};
|
|
5132
5228
|
const rawDisplayName = currentUser?.displayName;
|
|
5133
5229
|
const normalizedDisplayName = typeof rawDisplayName === "string" ? rawDisplayName.trim() : void 0;
|
|
5134
|
-
const
|
|
5230
|
+
const rawWallet = currentUser?.walletAddress;
|
|
5231
|
+
const shortWallet = rawWallet && rawWallet.length > 10 ? `${rawWallet.slice(0, 4)}\u2026${rawWallet.slice(-4)}` : rawWallet;
|
|
5232
|
+
const userPrimaryLabel = normalizedDisplayName || currentUser?.email || shortWallet || "User";
|
|
5135
5233
|
const resolveAuthReturnUrl = () => {
|
|
5136
5234
|
if (getAuthReturnUrl) {
|
|
5137
5235
|
return getAuthReturnUrl();
|
|
@@ -5212,7 +5310,7 @@ var Header = ({
|
|
|
5212
5310
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
5213
5311
|
/* @__PURE__ */ jsxRuntime.jsx(SafeAreaCover, {}),
|
|
5214
5312
|
/* @__PURE__ */ jsxRuntime.jsx(Overlay, { $isOpen: isMobileMenuOpen, onClick: () => setIsMobileMenuOpen(false) }),
|
|
5215
|
-
/* @__PURE__ */ jsxRuntime.jsxs(HeaderContainer, { id: "loaf-header", children: [
|
|
5313
|
+
/* @__PURE__ */ jsxRuntime.jsxs(HeaderContainer, { id: "loaf-header", $bgOpacity: headerBgOpacity, children: [
|
|
5216
5314
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { style: { display: "flex", alignItems: "center" }, children: [
|
|
5217
5315
|
/* @__PURE__ */ jsxRuntime.jsxs(Logo, { children: [
|
|
5218
5316
|
/* @__PURE__ */ jsxRuntime.jsx(LogoLink, { href: logoHref ?? resolvedHomePath, onClick: handleLogoNavigation, children: /* @__PURE__ */ jsxRuntime.jsx("img", { src: Loaf_logo_Banner_default, alt: "LOAF Logo" }) }),
|
|
@@ -5321,6 +5419,15 @@ var Header = ({
|
|
|
5321
5419
|
children: "API"
|
|
5322
5420
|
}
|
|
5323
5421
|
),
|
|
5422
|
+
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5423
|
+
NavLink,
|
|
5424
|
+
{
|
|
5425
|
+
href: "https://docs.loafmarkets.com/en/",
|
|
5426
|
+
target: "_blank",
|
|
5427
|
+
rel: "noopener noreferrer",
|
|
5428
|
+
children: "Docs"
|
|
5429
|
+
}
|
|
5430
|
+
),
|
|
5324
5431
|
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { marginLeft: "auto", display: "flex", alignItems: "center" }, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
5325
5432
|
"div",
|
|
5326
5433
|
{
|
|
@@ -5342,10 +5449,6 @@ var Header = ({
|
|
|
5342
5449
|
),
|
|
5343
5450
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mobile-menu-content", children: [
|
|
5344
5451
|
/* @__PURE__ */ jsxRuntime.jsx(MobileMenuHeader, { children: /* @__PURE__ */ jsxRuntime.jsx(MobileMenuClose, { onClick: () => setIsMobileMenuOpen(false), "aria-label": "Close menu", children: /* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z" }) }) }) }),
|
|
5345
|
-
/* @__PURE__ */ jsxRuntime.jsxs(SearchBar, { children: [
|
|
5346
|
-
/* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M15.5 14h-.79l-.28-.27A6.471 6.471 0 0 0 16 9.5 6.5 6.5 0 1 0 9.5 16c1.61 0 3.09-.59 4.23-1.57l.27.28v.79l5 4.99L20.49 19zM5 9.5C5 7.01 7.01 5 9.5 5S14 7.01 14 9.5 11.99 14 9.5 14 5 11.99 5 9.5z" }) }),
|
|
5347
|
-
/* @__PURE__ */ jsxRuntime.jsx("input", { type: "text", placeholder: "Search..." })
|
|
5348
|
-
] }),
|
|
5349
5452
|
/* @__PURE__ */ jsxRuntime.jsx(MobileNavItem, { onClick: () => handleNavigation(resolvedHomePath), children: "Home" }),
|
|
5350
5453
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5351
5454
|
MobileNavItem,
|
|
@@ -5368,6 +5471,7 @@ var Header = ({
|
|
|
5368
5471
|
/* @__PURE__ */ jsxRuntime.jsx(MobileNavItem, { onClick: () => handleNavigation(resolvedLearnPath), children: "Learn" }),
|
|
5369
5472
|
/* @__PURE__ */ jsxRuntime.jsx(MobileNavItem, { onClick: () => handleNavigation(resolvedAboutPath), children: "About" }),
|
|
5370
5473
|
/* @__PURE__ */ jsxRuntime.jsx(MobileNavItem, { onClick: () => handleNavigation(resolvedApiPath), children: "API" }),
|
|
5474
|
+
/* @__PURE__ */ jsxRuntime.jsx(MobileNavItem, { onClick: () => window.open("https://docs.loafmarkets.com/en/", "_blank", "noopener,noreferrer"), children: "Docs" }),
|
|
5371
5475
|
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { borderTop: "1px solid #2b3139", margin: "8px 0" } }),
|
|
5372
5476
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5373
5477
|
MobileNavItem,
|
|
@@ -5421,6 +5525,14 @@ var Header = ({
|
|
|
5421
5525
|
] })
|
|
5422
5526
|
] }),
|
|
5423
5527
|
/* @__PURE__ */ jsxRuntime.jsx(PBDot, {}),
|
|
5528
|
+
/* @__PURE__ */ jsxRuntime.jsxs(PBMetric, { children: [
|
|
5529
|
+
/* @__PURE__ */ jsxRuntime.jsx(PBMetricLabel, { children: "Locked Balance" }),
|
|
5530
|
+
/* @__PURE__ */ jsxRuntime.jsxs(PBMetricValue, { style: { color: "#B0B0B8" }, children: [
|
|
5531
|
+
"$",
|
|
5532
|
+
fmtInline(portfolioSummary.frozen ?? 0)
|
|
5533
|
+
] })
|
|
5534
|
+
] }),
|
|
5535
|
+
/* @__PURE__ */ jsxRuntime.jsx(PBDot, {}),
|
|
5424
5536
|
/* @__PURE__ */ jsxRuntime.jsxs(PBMetric, { children: [
|
|
5425
5537
|
/* @__PURE__ */ jsxRuntime.jsx(PBMetricLabel, { children: "P&L" }),
|
|
5426
5538
|
/* @__PURE__ */ jsxRuntime.jsxs(PBMetricValue, { $positive: isPLPos, $negative: !isPLPos, children: [
|
|
@@ -5464,7 +5576,7 @@ var Header = ({
|
|
|
5464
5576
|
$isOpen: isUserMenuOpen,
|
|
5465
5577
|
className: "user-menu",
|
|
5466
5578
|
children: [
|
|
5467
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", flexDirection: "column", alignItems: "flex-start" }, children: /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontWeight: 600
|
|
5579
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", flexDirection: "column", alignItems: "flex-start" }, children: /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontWeight: 600 }, children: userPrimaryLabel }) }),
|
|
5468
5580
|
/* @__PURE__ */ jsxRuntime.jsx("svg", { viewBox: "0 0 24 24", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M7 10l5 5 5-5H7z" }) })
|
|
5469
5581
|
]
|
|
5470
5582
|
}
|
|
@@ -5568,6 +5680,14 @@ var Header = ({
|
|
|
5568
5680
|
] })
|
|
5569
5681
|
] }),
|
|
5570
5682
|
/* @__PURE__ */ jsxRuntime.jsx(PBDot, {}),
|
|
5683
|
+
/* @__PURE__ */ jsxRuntime.jsxs(PBMetric, { children: [
|
|
5684
|
+
/* @__PURE__ */ jsxRuntime.jsx(PBMetricLabel, { children: "Locked Balance" }),
|
|
5685
|
+
/* @__PURE__ */ jsxRuntime.jsxs(PBMetricValue, { style: { color: "#B0B0B8" }, children: [
|
|
5686
|
+
"$",
|
|
5687
|
+
fmt(portfolioSummary.frozen ?? 0)
|
|
5688
|
+
] })
|
|
5689
|
+
] }),
|
|
5690
|
+
/* @__PURE__ */ jsxRuntime.jsx(PBDot, {}),
|
|
5571
5691
|
/* @__PURE__ */ jsxRuntime.jsxs(PBMetric, { children: [
|
|
5572
5692
|
/* @__PURE__ */ jsxRuntime.jsx(PBMetricLabel, { children: "P&L" }),
|
|
5573
5693
|
/* @__PURE__ */ jsxRuntime.jsxs(PBMetricValue, { $positive: isPLPositive, $negative: !isPLPositive, children: [
|
|
@@ -5620,15 +5740,15 @@ var MobileOnlyButton = styled9__default.default.button.attrs({ type: "button" })
|
|
|
5620
5740
|
display: none;
|
|
5621
5741
|
background-color: ${(props) => props.$isOpen ? "rgba(240, 185, 11, 0.2)" : "#f0b90b"};
|
|
5622
5742
|
color: ${(props) => props.$isOpen ? "#ffffff" : "#0b0e11"};
|
|
5623
|
-
font-size:
|
|
5743
|
+
font-size: 18px;
|
|
5624
5744
|
font-weight: bold;
|
|
5625
|
-
width:
|
|
5626
|
-
height:
|
|
5745
|
+
width: 34px;
|
|
5746
|
+
height: 34px;
|
|
5627
5747
|
justify-content: center;
|
|
5628
5748
|
align-items: center;
|
|
5629
|
-
margin-left: 0.
|
|
5749
|
+
margin-left: 0.5rem;
|
|
5630
5750
|
z-index: 1100;
|
|
5631
|
-
border-radius:
|
|
5751
|
+
border-radius: 6px;
|
|
5632
5752
|
border: ${(props) => props.$isOpen ? "1px solid #f0b90b" : "none"};
|
|
5633
5753
|
line-height: 1;
|
|
5634
5754
|
padding: 0;
|
|
@@ -5655,8 +5775,9 @@ var HeaderContainer = styled9__default.default.header`
|
|
|
5655
5775
|
still get the horizontal padding — only the top falls back to 0 */
|
|
5656
5776
|
padding: 0 2rem;
|
|
5657
5777
|
padding-top: max(env(safe-area-inset-top, 0px), var(--telegram-safe-top, 0px));
|
|
5658
|
-
background-color:
|
|
5659
|
-
border-bottom: 1px solid
|
|
5778
|
+
background-color: rgba(13, 17, 23, ${({ $bgOpacity }) => $bgOpacity ?? 1});
|
|
5779
|
+
border-bottom: 1px solid rgba(35, 42, 50, ${({ $bgOpacity }) => $bgOpacity ?? 1});
|
|
5780
|
+
transition: background-color 0.15s ease, border-bottom-color 0.15s ease;
|
|
5660
5781
|
position: fixed;
|
|
5661
5782
|
top: 0;
|
|
5662
5783
|
left: 0;
|
|
@@ -5677,11 +5798,11 @@ var HeaderContainer = styled9__default.default.header`
|
|
|
5677
5798
|
min-height: 46px;
|
|
5678
5799
|
padding: 0 0.75rem;
|
|
5679
5800
|
border-radius: 12px;
|
|
5680
|
-
background-color: rgba(13, 17, 23, 0.92);
|
|
5681
|
-
backdrop-filter: blur(
|
|
5682
|
-
border: 1px solid rgba(255, 255, 255, 0.08);
|
|
5683
|
-
border-bottom: 1px solid rgba(255, 255, 255, 0.08);
|
|
5684
|
-
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
|
|
5801
|
+
background-color: rgba(13, 17, 23, ${({ $bgOpacity }) => Math.max(($bgOpacity ?? 1) * 0.92, 0)});
|
|
5802
|
+
backdrop-filter: blur(${({ $bgOpacity }) => Math.round(($bgOpacity ?? 1) * 12)}px);
|
|
5803
|
+
border: 1px solid rgba(255, 255, 255, ${({ $bgOpacity }) => ($bgOpacity ?? 1) * 0.08});
|
|
5804
|
+
border-bottom: 1px solid rgba(255, 255, 255, ${({ $bgOpacity }) => ($bgOpacity ?? 1) * 0.08});
|
|
5805
|
+
box-shadow: 0 4px 20px rgba(0, 0, 0, ${({ $bgOpacity }) => ($bgOpacity ?? 1) * 0.3});
|
|
5685
5806
|
}
|
|
5686
5807
|
`;
|
|
5687
5808
|
var HeaderSpacer = styled9__default.default.div`
|
|
@@ -5903,6 +6024,11 @@ var UserButton = styled9__default.default.button.attrs({ type: "button" })`
|
|
|
5903
6024
|
transition: transform 0.2s ease;
|
|
5904
6025
|
transform: ${(props) => props.$isOpen ? "rotate(180deg)" : "rotate(0)"};
|
|
5905
6026
|
}
|
|
6027
|
+
|
|
6028
|
+
@media (max-width: 768px) {
|
|
6029
|
+
font-size: 11px;
|
|
6030
|
+
padding: 0 4px;
|
|
6031
|
+
}
|
|
5906
6032
|
`;
|
|
5907
6033
|
var DropdownMenu = styled9__default.default.div`
|
|
5908
6034
|
position: absolute;
|
|
@@ -5972,42 +6098,6 @@ var MobileMenuClose = styled9__default.default.button.attrs({ type: "button" })`
|
|
|
5972
6098
|
align-items: center;
|
|
5973
6099
|
justify-content: center;
|
|
5974
6100
|
`;
|
|
5975
|
-
var SearchBar = styled9__default.default.div`
|
|
5976
|
-
display: flex;
|
|
5977
|
-
align-items: center;
|
|
5978
|
-
background: rgba(255, 255, 255, 0.03);
|
|
5979
|
-
border-radius: 6px;
|
|
5980
|
-
padding: 10px 14px;
|
|
5981
|
-
margin: 16px 20px 12px;
|
|
5982
|
-
border: 1px solid rgba(255, 255, 255, 0.08);
|
|
5983
|
-
transition: all 0.2s ease;
|
|
5984
|
-
|
|
5985
|
-
&:focus-within {
|
|
5986
|
-
background: rgba(255, 255, 255, 0.05);
|
|
5987
|
-
border-color: rgba(240, 185, 11, 0.3);
|
|
5988
|
-
}
|
|
5989
|
-
|
|
5990
|
-
svg {
|
|
5991
|
-
color: rgba(240, 185, 11, 0.5);
|
|
5992
|
-
margin-right: 10px;
|
|
5993
|
-
width: 16px;
|
|
5994
|
-
height: 16px;
|
|
5995
|
-
}
|
|
5996
|
-
|
|
5997
|
-
input {
|
|
5998
|
-
background: none;
|
|
5999
|
-
border: none;
|
|
6000
|
-
color: #ffffff;
|
|
6001
|
-
font-size: 14px;
|
|
6002
|
-
width: 100%;
|
|
6003
|
-
outline: none;
|
|
6004
|
-
height: 20px;
|
|
6005
|
-
|
|
6006
|
-
&::placeholder {
|
|
6007
|
-
color: rgba(255, 255, 255, 0.4);
|
|
6008
|
-
}
|
|
6009
|
-
}
|
|
6010
|
-
`;
|
|
6011
6101
|
var MobileNavItem = styled9__default.default.div`
|
|
6012
6102
|
display: flex;
|
|
6013
6103
|
align-items: center;
|
|
@@ -6049,8 +6139,10 @@ var PortfolioEyeButton = styled9__default.default.button`
|
|
|
6049
6139
|
color: #D4AF37;
|
|
6050
6140
|
}
|
|
6051
6141
|
|
|
6052
|
-
@media (max-width:
|
|
6053
|
-
|
|
6142
|
+
@media (max-width: 768px) {
|
|
6143
|
+
margin-left: 2px;
|
|
6144
|
+
margin-right: 4px;
|
|
6145
|
+
padding: 4px;
|
|
6054
6146
|
}
|
|
6055
6147
|
`;
|
|
6056
6148
|
var DepositButton = styled9__default.default.button`
|
|
@@ -6083,7 +6175,7 @@ var PortfolioBarContainer = styled9__default.default.div`
|
|
|
6083
6175
|
top: calc(56px + max(env(safe-area-inset-top, 0px), var(--telegram-safe-top, 0px)));
|
|
6084
6176
|
left: 0;
|
|
6085
6177
|
right: 0;
|
|
6086
|
-
z-index:
|
|
6178
|
+
z-index: 1000;
|
|
6087
6179
|
display: none;
|
|
6088
6180
|
justify-content: flex-end;
|
|
6089
6181
|
align-items: flex-start;
|
|
@@ -6149,9 +6241,9 @@ var PortfolioBarPill = styled9__default.default.div`
|
|
|
6149
6241
|
}
|
|
6150
6242
|
|
|
6151
6243
|
@media (max-width: 768px) {
|
|
6152
|
-
gap: 0.
|
|
6153
|
-
padding: 0.
|
|
6154
|
-
border-radius: 0 0
|
|
6244
|
+
gap: 0.5rem;
|
|
6245
|
+
padding: 0.3rem 0.75rem;
|
|
6246
|
+
border-radius: 0 0 12px 12px;
|
|
6155
6247
|
}
|
|
6156
6248
|
`;
|
|
6157
6249
|
var PortfolioBarArrow = styled9__default.default.div`
|
|
@@ -6189,12 +6281,20 @@ var PBMetricLabel = styled9__default.default.span`
|
|
|
6189
6281
|
text-transform: uppercase;
|
|
6190
6282
|
letter-spacing: 0.5px;
|
|
6191
6283
|
font-weight: 500;
|
|
6284
|
+
|
|
6285
|
+
@media (max-width: 768px) {
|
|
6286
|
+
font-size: 0.45rem;
|
|
6287
|
+
}
|
|
6192
6288
|
`;
|
|
6193
6289
|
var PBMetricValue = styled9__default.default.span`
|
|
6194
6290
|
font-size: 0.75rem;
|
|
6195
6291
|
font-weight: 600;
|
|
6196
6292
|
color: ${(p) => p.$positive ? "#0ecb81" : p.$negative ? "#f6465d" : "#eaecef"};
|
|
6197
6293
|
font-variant-numeric: tabular-nums;
|
|
6294
|
+
|
|
6295
|
+
@media (max-width: 768px) {
|
|
6296
|
+
font-size: 0.65rem;
|
|
6297
|
+
}
|
|
6198
6298
|
`;
|
|
6199
6299
|
var PBDot = styled9__default.default.div`
|
|
6200
6300
|
width: 3px;
|
|
@@ -6208,6 +6308,10 @@ var PBOperator = styled9__default.default.span`
|
|
|
6208
6308
|
font-weight: 500;
|
|
6209
6309
|
color: rgba(255, 255, 255, 0.35);
|
|
6210
6310
|
flex-shrink: 0;
|
|
6311
|
+
|
|
6312
|
+
@media (max-width: 768px) {
|
|
6313
|
+
font-size: 0.55rem;
|
|
6314
|
+
}
|
|
6211
6315
|
`;
|
|
6212
6316
|
var PropertySubheader = React5__namespace.forwardRef(
|
|
6213
6317
|
({ className, tabs, activeTabId, onTabChange, actions, ...props }, ref) => {
|
|
@@ -6736,8 +6840,8 @@ var LoginPopup = ({
|
|
|
6736
6840
|
/* @__PURE__ */ jsxRuntime.jsxs(Annotation, { children: [
|
|
6737
6841
|
/* @__PURE__ */ jsxRuntime.jsx("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 24 24", fill: "currentColor", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zm3.1-9H8.9V6c0-1.71 1.39-3.1 3.1-3.1 1.71 0 3.1 1.39 3.1 3.1v2z" }) }),
|
|
6738
6842
|
/* @__PURE__ */ jsxRuntime.jsxs(AnnotationText, { children: [
|
|
6739
|
-
/* @__PURE__ */ jsxRuntime.jsx(AnnotationLabel, { children: "\u2190 Self
|
|
6740
|
-
"We never have ownership of your assets. All units are self
|
|
6843
|
+
/* @__PURE__ */ jsxRuntime.jsx(AnnotationLabel, { children: "\u2190 Self custodial" }),
|
|
6844
|
+
"We never have ownership of your assets. All units are self custodial"
|
|
6741
6845
|
] })
|
|
6742
6846
|
] })
|
|
6743
6847
|
] })
|
|
@@ -8618,6 +8722,7 @@ function PropertyOverview({
|
|
|
8618
8722
|
location,
|
|
8619
8723
|
midPrice,
|
|
8620
8724
|
onTradeClick,
|
|
8725
|
+
onDocumentsClick,
|
|
8621
8726
|
onPhotosClick,
|
|
8622
8727
|
description: descriptionProp,
|
|
8623
8728
|
tradeButtonLabel = "Trade",
|
|
@@ -8639,7 +8744,6 @@ function PropertyOverview({
|
|
|
8639
8744
|
ticker,
|
|
8640
8745
|
contractAddress,
|
|
8641
8746
|
chain = "Base (Ethereum L2)",
|
|
8642
|
-
percentageTokenized,
|
|
8643
8747
|
volume24h,
|
|
8644
8748
|
openOrdersValue,
|
|
8645
8749
|
holderCount,
|
|
@@ -8688,7 +8792,7 @@ function PropertyOverview({
|
|
|
8688
8792
|
{ label: "On-Chain Address", value: contractAddress ? truncateAddress(contractAddress) : "\u2014", mono: true, link: contractAddress ? `https://basescan.org/address/${contractAddress}` : void 0, copyValue: contractAddress },
|
|
8689
8793
|
{ label: "Token Ticker", value: ticker ?? "\u2014" },
|
|
8690
8794
|
{ label: "Total Circulating Tokens", value: isLoading && resolvedTokensIssued == null ? loadingSkeleton : resolvedTokensIssued?.toLocaleString() ?? "\u2014" },
|
|
8691
|
-
{ label: "
|
|
8795
|
+
{ label: "Legal Structuring", value: "See Documents", docLink: true },
|
|
8692
8796
|
{ label: "Property Type", value: resolvedPropertyType ?? "\u2014" },
|
|
8693
8797
|
{ label: "Location", value: location || "\u2014" }
|
|
8694
8798
|
];
|
|
@@ -8738,7 +8842,11 @@ function PropertyOverview({
|
|
|
8738
8842
|
tokenDetailsItems.map((item) => /* @__PURE__ */ jsxRuntime.jsxs(TokenDetailRow, { children: [
|
|
8739
8843
|
/* @__PURE__ */ jsxRuntime.jsx(TokenDetailLabel, { children: item.label }),
|
|
8740
8844
|
/* @__PURE__ */ jsxRuntime.jsxs(TokenDetailValue, { $mono: !!item.mono, children: [
|
|
8741
|
-
item.
|
|
8845
|
+
"docLink" in item && item.docLink ? /* @__PURE__ */ jsxRuntime.jsxs(DocLinkBtn, { onClick: onDocumentsClick, children: [
|
|
8846
|
+
item.value,
|
|
8847
|
+
" ",
|
|
8848
|
+
/* @__PURE__ */ jsxRuntime.jsx("svg", { width: "10", height: "10", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M1 9L9 1M9 1H4M9 1V6", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) })
|
|
8849
|
+
] }) : item.link ? /* @__PURE__ */ jsxRuntime.jsx("a", { href: item.link, target: "_blank", rel: "noopener noreferrer", style: { color: "#3380FF", textDecoration: "none" }, children: item.value }) : item.value,
|
|
8742
8850
|
item.copyValue && /* @__PURE__ */ jsxRuntime.jsx(
|
|
8743
8851
|
CopyBtn,
|
|
8744
8852
|
{
|
|
@@ -9000,7 +9108,10 @@ function PropertyOverview({
|
|
|
9000
9108
|
/* @__PURE__ */ jsxRuntime.jsxs(SecurityCol, { children: [
|
|
9001
9109
|
/* @__PURE__ */ jsxRuntime.jsxs(SecurityRow, { children: [
|
|
9002
9110
|
/* @__PURE__ */ jsxRuntime.jsx(SecurityLabel, { children: "Legal Structuring" }),
|
|
9003
|
-
/* @__PURE__ */ jsxRuntime.jsx(SecurityValue, { children:
|
|
9111
|
+
/* @__PURE__ */ jsxRuntime.jsx(SecurityValue, { children: /* @__PURE__ */ jsxRuntime.jsxs(DocLinkBtn, { onClick: onDocumentsClick, children: [
|
|
9112
|
+
"See Documents ",
|
|
9113
|
+
/* @__PURE__ */ jsxRuntime.jsx("svg", { width: "10", height: "10", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M1 9L9 1M9 1H4M9 1V6", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round" }) })
|
|
9114
|
+
] }) })
|
|
9004
9115
|
] }),
|
|
9005
9116
|
/* @__PURE__ */ jsxRuntime.jsxs(SecurityRow, { children: [
|
|
9006
9117
|
/* @__PURE__ */ jsxRuntime.jsx(SecurityLabel, { children: "Bankruptcy Remote" }),
|
|
@@ -9374,6 +9485,20 @@ var CopyBtn = styled9__default.default.button`
|
|
|
9374
9485
|
transition: color 0.15s;
|
|
9375
9486
|
&:hover { color: rgba(255,255,255,0.7); }
|
|
9376
9487
|
`;
|
|
9488
|
+
var DocLinkBtn = styled9__default.default.button`
|
|
9489
|
+
background: none;
|
|
9490
|
+
border: none;
|
|
9491
|
+
color: #D4AF37;
|
|
9492
|
+
cursor: pointer;
|
|
9493
|
+
padding: 0;
|
|
9494
|
+
font-size: inherit;
|
|
9495
|
+
font-weight: 600;
|
|
9496
|
+
display: inline-flex;
|
|
9497
|
+
align-items: center;
|
|
9498
|
+
gap: 4px;
|
|
9499
|
+
transition: opacity 0.15s;
|
|
9500
|
+
&:hover { opacity: 0.7; }
|
|
9501
|
+
`;
|
|
9377
9502
|
var ChainLogos = styled9__default.default.span`
|
|
9378
9503
|
display: inline-flex;
|
|
9379
9504
|
align-items: center;
|
|
@@ -9711,12 +9836,13 @@ var SecurityValue = styled9__default.default.span`
|
|
|
9711
9836
|
`;
|
|
9712
9837
|
var SecurityDocLink = styled9__default.default.a`
|
|
9713
9838
|
font-size: 0.82rem;
|
|
9714
|
-
color:
|
|
9839
|
+
color: #D4AF37;
|
|
9840
|
+
font-weight: 600;
|
|
9715
9841
|
text-decoration: none;
|
|
9716
9842
|
cursor: pointer;
|
|
9717
|
-
transition:
|
|
9843
|
+
transition: opacity 0.15s;
|
|
9718
9844
|
&:hover {
|
|
9719
|
-
|
|
9845
|
+
opacity: 0.7;
|
|
9720
9846
|
}
|
|
9721
9847
|
`;
|
|
9722
9848
|
var DividendHistoryBtn = styled9__default.default.button`
|
|
@@ -10687,7 +10813,24 @@ var fallbackDocs = [
|
|
|
10687
10813
|
{ href: "/documents/musgrave-risk-disclosure.pdf", label: "Risk Disclosure Statement" },
|
|
10688
10814
|
{ href: "/documents/musgrave-building-inspection.pdf", label: "Building & Pest Inspection Report" }
|
|
10689
10815
|
];
|
|
10690
|
-
function PropertyDocuments({ documentsData }) {
|
|
10816
|
+
function PropertyDocuments({ documentsData, highlightDocument, onClearHighlight }) {
|
|
10817
|
+
const highlightRef = React5.useRef(null);
|
|
10818
|
+
React5.useRef(null);
|
|
10819
|
+
React5.useEffect(() => {
|
|
10820
|
+
if (highlightDocument && highlightRef.current) {
|
|
10821
|
+
highlightRef.current.scrollIntoView({ behavior: "smooth", block: "nearest" });
|
|
10822
|
+
}
|
|
10823
|
+
}, [highlightDocument]);
|
|
10824
|
+
React5.useEffect(() => {
|
|
10825
|
+
if (!highlightDocument || !onClearHighlight) return;
|
|
10826
|
+
const handler = (e) => {
|
|
10827
|
+
if (highlightRef.current && !highlightRef.current.contains(e.target)) {
|
|
10828
|
+
onClearHighlight();
|
|
10829
|
+
}
|
|
10830
|
+
};
|
|
10831
|
+
document.addEventListener("click", handler, true);
|
|
10832
|
+
return () => document.removeEventListener("click", handler, true);
|
|
10833
|
+
}, [highlightDocument, onClearHighlight]);
|
|
10691
10834
|
const backendDocuments = Array.isArray(documentsData?.documents) ? documentsData.documents : null;
|
|
10692
10835
|
const hasBackendDocuments = !!backendDocuments?.length;
|
|
10693
10836
|
const documents = hasBackendDocuments ? backendDocuments : fallbackDocs.map((doc) => ({
|
|
@@ -10698,14 +10841,23 @@ function PropertyDocuments({ documentsData }) {
|
|
|
10698
10841
|
/* @__PURE__ */ jsxRuntime.jsx(SectionHeading, { children: "Investment Documents" }),
|
|
10699
10842
|
/* @__PURE__ */ jsxRuntime.jsx(DocList, { children: documents.map(({ documentUrl, title }) => {
|
|
10700
10843
|
const isAvailable = Boolean(documentUrl);
|
|
10701
|
-
|
|
10702
|
-
|
|
10703
|
-
|
|
10704
|
-
|
|
10705
|
-
|
|
10706
|
-
|
|
10707
|
-
|
|
10708
|
-
|
|
10844
|
+
const isHighlighted = highlightDocument != null && title.toLowerCase().includes(highlightDocument.toLowerCase());
|
|
10845
|
+
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
10846
|
+
DocItem,
|
|
10847
|
+
{
|
|
10848
|
+
ref: isHighlighted ? highlightRef : void 0,
|
|
10849
|
+
$highlighted: isHighlighted,
|
|
10850
|
+
children: hasBackendDocuments && isAvailable ? /* @__PURE__ */ jsxRuntime.jsxs(DocLink, { href: documentUrl, target: "_blank", rel: "noopener noreferrer", children: [
|
|
10851
|
+
/* @__PURE__ */ jsxRuntime.jsx(DocIconWrapper, { children: /* @__PURE__ */ jsxRuntime.jsx(DocIcon, {}) }),
|
|
10852
|
+
title
|
|
10853
|
+
] }) : /* @__PURE__ */ jsxRuntime.jsxs(DocItemDisabled, { children: [
|
|
10854
|
+
/* @__PURE__ */ jsxRuntime.jsx(DocIconWrapper, { children: /* @__PURE__ */ jsxRuntime.jsx(DocIcon, {}) }),
|
|
10855
|
+
title,
|
|
10856
|
+
/* @__PURE__ */ jsxRuntime.jsx(ComingSoonBadge, { children: "Coming Soon" })
|
|
10857
|
+
] })
|
|
10858
|
+
},
|
|
10859
|
+
`${title}-${documentUrl ?? "pending"}`
|
|
10860
|
+
);
|
|
10709
10861
|
}) })
|
|
10710
10862
|
] });
|
|
10711
10863
|
}
|
|
@@ -10734,6 +10886,10 @@ var DocList = styled9__default.default.ul`
|
|
|
10734
10886
|
var DocItem = styled9__default.default.li`
|
|
10735
10887
|
padding: 0.75rem 0;
|
|
10736
10888
|
border-bottom: 1px solid var(--color-border, rgba(255, 255, 255, 0.1));
|
|
10889
|
+
border-radius: ${(p) => p.$highlighted ? "6px" : "0"};
|
|
10890
|
+
background: ${(p) => p.$highlighted ? "rgba(212, 175, 55, 0.08)" : "transparent"};
|
|
10891
|
+
${(p) => p.$highlighted ? "padding: 0.75rem;" : ""}
|
|
10892
|
+
transition: background 0.3s;
|
|
10737
10893
|
|
|
10738
10894
|
&:last-child {
|
|
10739
10895
|
border-bottom: none;
|
|
@@ -10978,6 +11134,10 @@ var SignInButton = styled9__default.default.button`
|
|
|
10978
11134
|
background: rgba(240, 185, 11, 0.1);
|
|
10979
11135
|
}
|
|
10980
11136
|
`;
|
|
11137
|
+
function displayName(item) {
|
|
11138
|
+
if (item.name) return item.name;
|
|
11139
|
+
return item.tokenName.charAt(0).toUpperCase() + item.tokenName.slice(1);
|
|
11140
|
+
}
|
|
10981
11141
|
function AssetSelectorBar({
|
|
10982
11142
|
propertyName,
|
|
10983
11143
|
tokenPrice,
|
|
@@ -10987,7 +11147,8 @@ function AssetSelectorBar({
|
|
|
10987
11147
|
selectorItems,
|
|
10988
11148
|
onSelect,
|
|
10989
11149
|
trailing,
|
|
10990
|
-
imageUrl
|
|
11150
|
+
imageUrl,
|
|
11151
|
+
badgeLabel
|
|
10991
11152
|
}) {
|
|
10992
11153
|
const [isDropdownOpen, setIsDropdownOpen] = React5.useState(false);
|
|
10993
11154
|
const hasItems = selectorItems && selectorItems.length > 0;
|
|
@@ -10999,6 +11160,7 @@ function AssetSelectorBar({
|
|
|
10999
11160
|
imageUrl && /* @__PURE__ */ jsxRuntime.jsx(AssetThumbnail, { src: imageUrl, alt: propertyName }),
|
|
11000
11161
|
/* @__PURE__ */ jsxRuntime.jsx(AssetSelectorDropdown, { onClick: () => hasItems && setIsDropdownOpen((prev) => !prev), children: /* @__PURE__ */ jsxRuntime.jsxs(AssetName, { children: [
|
|
11001
11162
|
propertyName,
|
|
11163
|
+
badgeLabel && /* @__PURE__ */ jsxRuntime.jsx(CompetitionBadge, { children: badgeLabel }),
|
|
11002
11164
|
hasItems && /* @__PURE__ */ jsxRuntime.jsx(
|
|
11003
11165
|
"svg",
|
|
11004
11166
|
{
|
|
@@ -11043,14 +11205,16 @@ function AssetSelectorBar({
|
|
|
11043
11205
|
$selected: isCurrent,
|
|
11044
11206
|
style: { cursor: isCurrent ? "default" : "pointer" },
|
|
11045
11207
|
children: /* @__PURE__ */ jsxRuntime.jsxs(IPOOptionInner, { children: [
|
|
11046
|
-
item.imageUrl && /* @__PURE__ */ jsxRuntime.jsx(IPOOptionThumb, { src: item.imageUrl, alt: item
|
|
11208
|
+
item.imageUrl && /* @__PURE__ */ jsxRuntime.jsx(IPOOptionThumb, { src: item.imageUrl, alt: displayName(item) }),
|
|
11047
11209
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { children: [
|
|
11048
11210
|
/* @__PURE__ */ jsxRuntime.jsxs(IPOOptionName, { children: [
|
|
11049
|
-
item
|
|
11050
|
-
item.ticker ? ` (${item.ticker})` : ""
|
|
11211
|
+
displayName(item),
|
|
11212
|
+
item.ticker ? ` (${item.ticker})` : "",
|
|
11213
|
+
item.badge && /* @__PURE__ */ jsxRuntime.jsx(CompetitionBadge, { children: item.badge })
|
|
11051
11214
|
] }),
|
|
11052
11215
|
/* @__PURE__ */ jsxRuntime.jsxs(IPOOptionLocation, { children: [
|
|
11053
|
-
item.
|
|
11216
|
+
item.streetAddress,
|
|
11217
|
+
item.suburb ? `, ${item.suburb}` : "",
|
|
11054
11218
|
statusLabel && /* @__PURE__ */ jsxRuntime.jsx("span", { children: statusLabel })
|
|
11055
11219
|
] })
|
|
11056
11220
|
] })
|
|
@@ -11067,8 +11231,8 @@ var AssetSelectorWrapper = styled9__default.default.div`
|
|
|
11067
11231
|
var IPOAssetSelector = styled9__default.default.div`
|
|
11068
11232
|
position: relative;
|
|
11069
11233
|
display: flex;
|
|
11070
|
-
justify-content: space-between;
|
|
11071
11234
|
align-items: center;
|
|
11235
|
+
gap: 1rem;
|
|
11072
11236
|
padding: 1rem 1.25rem;
|
|
11073
11237
|
background: linear-gradient(135deg, var(--color-card-darker, #111) 0%, rgba(17,17,17,0.95) 100%);
|
|
11074
11238
|
border-radius: 12px;
|
|
@@ -11106,7 +11270,7 @@ var AssetSelectorDropdown = styled9__default.default.div`
|
|
|
11106
11270
|
padding: 0.5rem 0.75rem;
|
|
11107
11271
|
border-radius: 8px;
|
|
11108
11272
|
transition: all 0.2s ease;
|
|
11109
|
-
flex:
|
|
11273
|
+
flex: 0 1 auto;
|
|
11110
11274
|
min-width: 0;
|
|
11111
11275
|
overflow: hidden;
|
|
11112
11276
|
&:hover { background-color: rgba(255,255,255,0.05); }
|
|
@@ -11142,9 +11306,9 @@ var SelectorMetrics = styled9__default.default.div`
|
|
|
11142
11306
|
display: flex;
|
|
11143
11307
|
align-items: center;
|
|
11144
11308
|
gap: 1rem;
|
|
11145
|
-
margin-
|
|
11146
|
-
margin-right: 1rem;
|
|
11309
|
+
margin-right: auto;
|
|
11147
11310
|
padding: 0.5rem 1rem;
|
|
11311
|
+
flex-shrink: 0;
|
|
11148
11312
|
background: rgba(255,255,255,0.03);
|
|
11149
11313
|
border-radius: 8px;
|
|
11150
11314
|
border: 1px solid rgba(255,255,255,0.05);
|
|
@@ -11162,6 +11326,7 @@ var TrailingWrapper = styled9__default.default.div`
|
|
|
11162
11326
|
display: flex;
|
|
11163
11327
|
align-items: center;
|
|
11164
11328
|
flex-shrink: 0;
|
|
11329
|
+
margin-left: auto;
|
|
11165
11330
|
|
|
11166
11331
|
@media (max-width: 768px) {
|
|
11167
11332
|
overflow-x: auto;
|
|
@@ -11279,6 +11444,19 @@ var IPOOptionName = styled9__default.default.div`
|
|
|
11279
11444
|
color: ${"#ebebeb"};
|
|
11280
11445
|
line-height: 1.3;
|
|
11281
11446
|
`;
|
|
11447
|
+
var CompetitionBadge = styled9__default.default.span`
|
|
11448
|
+
margin-left: 0.4rem;
|
|
11449
|
+
font-size: 0.55rem;
|
|
11450
|
+
font-weight: 700;
|
|
11451
|
+
letter-spacing: 0.08em;
|
|
11452
|
+
text-transform: uppercase;
|
|
11453
|
+
color: #E6C87E;
|
|
11454
|
+
background: rgba(230, 200, 126, 0.1);
|
|
11455
|
+
border: 1px solid rgba(230, 200, 126, 0.2);
|
|
11456
|
+
padding: 1px 5px;
|
|
11457
|
+
border-radius: 3px;
|
|
11458
|
+
vertical-align: middle;
|
|
11459
|
+
`;
|
|
11282
11460
|
var IPOOptionLocation = styled9__default.default.div`
|
|
11283
11461
|
font-size: 0.72rem;
|
|
11284
11462
|
color: rgba(255,255,255,0.38);
|
|
@@ -11349,6 +11527,7 @@ function OfferingProgressCard({
|
|
|
11349
11527
|
totalSold,
|
|
11350
11528
|
supplyToSell,
|
|
11351
11529
|
opensAt,
|
|
11530
|
+
tradingStartsAt,
|
|
11352
11531
|
subscriberCount = 0,
|
|
11353
11532
|
raisedAmount,
|
|
11354
11533
|
targetAmount,
|
|
@@ -11365,26 +11544,36 @@ function OfferingProgressCard({
|
|
|
11365
11544
|
const timer = setInterval(() => setCurrentTime(/* @__PURE__ */ new Date()), 1e3);
|
|
11366
11545
|
return () => clearInterval(timer);
|
|
11367
11546
|
}, []);
|
|
11547
|
+
const [tradingCountdown, setTradingCountdown] = React5.useState(null);
|
|
11548
|
+
const calcCountdownFrom = (target) => {
|
|
11549
|
+
const now = Math.floor(Date.now() / 1e3);
|
|
11550
|
+
const diff = target - now;
|
|
11551
|
+
if (diff <= 0) return null;
|
|
11552
|
+
return {
|
|
11553
|
+
days: Math.floor(diff / 86400),
|
|
11554
|
+
hours: Math.floor(diff % 86400 / 3600),
|
|
11555
|
+
minutes: Math.floor(diff % 3600 / 60),
|
|
11556
|
+
seconds: diff % 60
|
|
11557
|
+
};
|
|
11558
|
+
};
|
|
11368
11559
|
React5.useEffect(() => {
|
|
11369
11560
|
if (!opensAt) {
|
|
11370
11561
|
setCountdown(null);
|
|
11371
11562
|
return;
|
|
11372
11563
|
}
|
|
11373
|
-
|
|
11374
|
-
|
|
11375
|
-
const diff = opensAt - now;
|
|
11376
|
-
if (diff <= 0) return null;
|
|
11377
|
-
return {
|
|
11378
|
-
days: Math.floor(diff / 86400),
|
|
11379
|
-
hours: Math.floor(diff % 86400 / 3600),
|
|
11380
|
-
minutes: Math.floor(diff % 3600 / 60),
|
|
11381
|
-
seconds: diff % 60
|
|
11382
|
-
};
|
|
11383
|
-
};
|
|
11384
|
-
setCountdown(calculateCountdown());
|
|
11385
|
-
const interval = setInterval(() => setCountdown(calculateCountdown()), 1e3);
|
|
11564
|
+
setCountdown(calcCountdownFrom(opensAt));
|
|
11565
|
+
const interval = setInterval(() => setCountdown(calcCountdownFrom(opensAt)), 1e3);
|
|
11386
11566
|
return () => clearInterval(interval);
|
|
11387
11567
|
}, [opensAt]);
|
|
11568
|
+
React5.useEffect(() => {
|
|
11569
|
+
if (!tradingStartsAt) {
|
|
11570
|
+
setTradingCountdown(null);
|
|
11571
|
+
return;
|
|
11572
|
+
}
|
|
11573
|
+
setTradingCountdown(calcCountdownFrom(tradingStartsAt));
|
|
11574
|
+
const interval = setInterval(() => setTradingCountdown(calcCountdownFrom(tradingStartsAt)), 1e3);
|
|
11575
|
+
return () => clearInterval(interval);
|
|
11576
|
+
}, [tradingStartsAt]);
|
|
11388
11577
|
if (variant === "compact") {
|
|
11389
11578
|
return /* @__PURE__ */ jsxRuntime.jsxs(CompactContainer, { style, className, children: [
|
|
11390
11579
|
/* @__PURE__ */ jsxRuntime.jsx(ProgressBarOuter, { children: /* @__PURE__ */ jsxRuntime.jsx(ProgressBarInner, { style: { width: `${Math.min(percentSold, 100)}%` } }) }),
|
|
@@ -11411,7 +11600,10 @@ function OfferingProgressCard({
|
|
|
11411
11600
|
/* @__PURE__ */ jsxRuntime.jsx(fa.FaChartLine, {}),
|
|
11412
11601
|
" Offering Progress"
|
|
11413
11602
|
] }),
|
|
11414
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", alignItems: "center", gap: "0.4rem" }, children:
|
|
11603
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { style: { display: "flex", alignItems: "center", gap: "0.4rem" }, children: ipoStatus === "CLOSED" || ipoStatus === "CANCELLED" ? /* @__PURE__ */ jsxRuntime.jsxs(StatusSpan, { $color: "#f6465d", children: [
|
|
11604
|
+
/* @__PURE__ */ jsxRuntime.jsx(StatusDot3, { $color: "#f6465d" }),
|
|
11605
|
+
ipoStatus === "CLOSED" ? "CLOSED" : "CANCELLED"
|
|
11606
|
+
] }) : ipoStarted ? /* @__PURE__ */ jsxRuntime.jsxs(StatusSpan, { $color: "#0ecb81", children: [
|
|
11415
11607
|
/* @__PURE__ */ jsxRuntime.jsx(StatusDot3, { $color: "#0ecb81", $pulse: true }),
|
|
11416
11608
|
"LIVE"
|
|
11417
11609
|
] }) : /* @__PURE__ */ jsxRuntime.jsxs(StatusSpan, { $color: statusColor || "#D4AF37", children: [
|
|
@@ -11419,20 +11611,45 @@ function OfferingProgressCard({
|
|
|
11419
11611
|
statusLabel || "Preparing"
|
|
11420
11612
|
] }) })
|
|
11421
11613
|
] }),
|
|
11422
|
-
|
|
11614
|
+
ipoStatus === "CLOSED" || ipoStatus === "CANCELLED" ? /* @__PURE__ */ jsxRuntime.jsxs(HomePreLiveRow, { children: [
|
|
11615
|
+
/* @__PURE__ */ jsxRuntime.jsxs(HomeCountdownSide, { children: [
|
|
11616
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownLabel, { style: { color: "#f6465d" }, children: "IPO has Closed, Trading begins in" }),
|
|
11617
|
+
tradingCountdown ? /* @__PURE__ */ jsxRuntime.jsxs(CountdownDigits, { children: [
|
|
11618
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children: String(tradingCountdown.days).padStart(2, "0") }),
|
|
11619
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownUnitLabel, { children: "D" }),
|
|
11620
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownSeparator, { children: ":" }),
|
|
11621
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children: String(tradingCountdown.hours).padStart(2, "0") }),
|
|
11622
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownUnitLabel, { children: "H" }),
|
|
11623
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownSeparator, { children: ":" }),
|
|
11624
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children: String(tradingCountdown.minutes).padStart(2, "0") }),
|
|
11625
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownUnitLabel, { children: "M" }),
|
|
11626
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownSeparator, { children: ":" }),
|
|
11627
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children: String(tradingCountdown.seconds).padStart(2, "0") }),
|
|
11628
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownUnitLabel, { children: "S" })
|
|
11629
|
+
] }) : /* @__PURE__ */ jsxRuntime.jsx(CountdownDigits, { children: /* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { style: { fontSize: "1.25rem" }, children: "Trading Now Open" }) })
|
|
11630
|
+
] }),
|
|
11631
|
+
/* @__PURE__ */ jsxRuntime.jsxs(HomeUnitsSide, { children: [
|
|
11632
|
+
/* @__PURE__ */ jsxRuntime.jsx(HomeUnitsLabel, { children: "Units Allocated" }),
|
|
11633
|
+
/* @__PURE__ */ jsxRuntime.jsx(HomeUnitsValue, { children: /* @__PURE__ */ jsxRuntime.jsxs("span", { children: [
|
|
11634
|
+
totalSold.toLocaleString(),
|
|
11635
|
+
" / ",
|
|
11636
|
+
supplyToSell.toLocaleString()
|
|
11637
|
+
] }) })
|
|
11638
|
+
] })
|
|
11639
|
+
] }) : isPreLive ? /* @__PURE__ */ jsxRuntime.jsxs(HomePreLiveRow, { children: [
|
|
11423
11640
|
countdown ? /* @__PURE__ */ jsxRuntime.jsxs(HomeCountdownSide, { children: [
|
|
11424
11641
|
/* @__PURE__ */ jsxRuntime.jsx(CountdownLabel, { children: "Opens In" }),
|
|
11425
11642
|
/* @__PURE__ */ jsxRuntime.jsxs(CountdownDigits, { children: [
|
|
11426
|
-
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children:
|
|
11643
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children: String(countdown.days).padStart(2, "0") }),
|
|
11427
11644
|
/* @__PURE__ */ jsxRuntime.jsx(CountdownUnitLabel, { children: "D" }),
|
|
11428
11645
|
/* @__PURE__ */ jsxRuntime.jsx(CountdownSeparator, { children: ":" }),
|
|
11429
|
-
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children:
|
|
11646
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children: String(countdown.hours).padStart(2, "0") }),
|
|
11430
11647
|
/* @__PURE__ */ jsxRuntime.jsx(CountdownUnitLabel, { children: "H" }),
|
|
11431
11648
|
/* @__PURE__ */ jsxRuntime.jsx(CountdownSeparator, { children: ":" }),
|
|
11432
|
-
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children:
|
|
11649
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children: String(countdown.minutes).padStart(2, "0") }),
|
|
11433
11650
|
/* @__PURE__ */ jsxRuntime.jsx(CountdownUnitLabel, { children: "M" }),
|
|
11434
11651
|
/* @__PURE__ */ jsxRuntime.jsx(CountdownSeparator, { children: ":" }),
|
|
11435
|
-
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children:
|
|
11652
|
+
/* @__PURE__ */ jsxRuntime.jsx(CountdownNumber, { children: String(countdown.seconds).padStart(2, "0") }),
|
|
11436
11653
|
/* @__PURE__ */ jsxRuntime.jsx(CountdownUnitLabel, { children: "S" })
|
|
11437
11654
|
] })
|
|
11438
11655
|
] }) : /* @__PURE__ */ jsxRuntime.jsx(HomeCountdownSide, { children: /* @__PURE__ */ jsxRuntime.jsx(PreLiveStatus, { $statusColor: statusColor, children: "Sale Not Yet Open" }) }),
|
|
@@ -11685,36 +11902,36 @@ var CountdownCenter = styled9__default.default.div`
|
|
|
11685
11902
|
margin-bottom: 1.25rem;
|
|
11686
11903
|
`;
|
|
11687
11904
|
var CountdownLabel = styled9__default.default.div`
|
|
11688
|
-
font-size: 0.
|
|
11689
|
-
color:
|
|
11905
|
+
font-size: 0.75rem;
|
|
11906
|
+
color: var(--color-text-secondary);
|
|
11690
11907
|
text-transform: uppercase;
|
|
11691
|
-
letter-spacing: 0.
|
|
11692
|
-
margin-bottom: 0.
|
|
11693
|
-
font-weight: 600;
|
|
11908
|
+
letter-spacing: 0.05em;
|
|
11909
|
+
margin-bottom: 0.75rem;
|
|
11694
11910
|
`;
|
|
11695
11911
|
var CountdownDigits = styled9__default.default.div`
|
|
11696
11912
|
display: flex;
|
|
11697
11913
|
align-items: baseline;
|
|
11698
11914
|
justify-content: center;
|
|
11699
|
-
gap: 0.
|
|
11915
|
+
gap: 0.25rem;
|
|
11700
11916
|
`;
|
|
11701
11917
|
var CountdownNumber = styled9__default.default.span`
|
|
11702
|
-
font-size:
|
|
11918
|
+
font-size: 2rem;
|
|
11703
11919
|
font-weight: 700;
|
|
11704
11920
|
font-family: monospace;
|
|
11705
11921
|
color: #D4AF37;
|
|
11706
11922
|
@media (max-width: 768px) {
|
|
11707
|
-
font-size: 1.
|
|
11923
|
+
font-size: 1.5rem;
|
|
11708
11924
|
}
|
|
11709
11925
|
`;
|
|
11710
11926
|
var CountdownUnitLabel = styled9__default.default.span`
|
|
11711
|
-
font-size: 0.
|
|
11927
|
+
font-size: 0.7rem;
|
|
11712
11928
|
color: var(--color-text-secondary);
|
|
11929
|
+
margin-right: 0.25rem;
|
|
11713
11930
|
`;
|
|
11714
11931
|
var CountdownSeparator = styled9__default.default.span`
|
|
11715
11932
|
color: rgba(255,255,255,0.2);
|
|
11716
|
-
margin: 0 0.
|
|
11717
|
-
font-size: 1.
|
|
11933
|
+
margin: 0 0.15rem;
|
|
11934
|
+
font-size: 1.25rem;
|
|
11718
11935
|
`;
|
|
11719
11936
|
var LiveBody = styled9__default.default.div`
|
|
11720
11937
|
display: flex;
|
|
@@ -11799,7 +12016,7 @@ var HomePreLiveRow = styled9__default.default.div`
|
|
|
11799
12016
|
display: flex;
|
|
11800
12017
|
align-items: center;
|
|
11801
12018
|
justify-content: space-between;
|
|
11802
|
-
|
|
12019
|
+
flex: 1;
|
|
11803
12020
|
`;
|
|
11804
12021
|
var HomeCountdownSide = styled9__default.default.div`
|
|
11805
12022
|
display: flex;
|