@loafmarkets/ui 0.1.418 → 0.1.420
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 +4 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.js +13 -30
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +13 -30
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1819,27 +1819,6 @@ function TradeRow({
|
|
|
1819
1819
|
}
|
|
1820
1820
|
);
|
|
1821
1821
|
}
|
|
1822
|
-
function BreadSliceGlyph() {
|
|
1823
|
-
return /* @__PURE__ */ jsx(
|
|
1824
|
-
"svg",
|
|
1825
|
-
{
|
|
1826
|
-
width: "10",
|
|
1827
|
-
height: "10",
|
|
1828
|
-
viewBox: "0 0 10 10",
|
|
1829
|
-
"aria-hidden": "true",
|
|
1830
|
-
style: { display: "block", filter: "drop-shadow(0 0 4px rgba(201,162,39,0.6))" },
|
|
1831
|
-
children: /* @__PURE__ */ jsx(
|
|
1832
|
-
"path",
|
|
1833
|
-
{
|
|
1834
|
-
d: "M1 4.2 C1 1.9 2.7 1 5 1 C7.3 1 9 1.9 9 4.2 L9 8.2 C9 8.6 8.6 9 8.2 9 L1.8 9 C1.4 9 1 8.6 1 8.2 Z",
|
|
1835
|
-
fill: "none",
|
|
1836
|
-
stroke: "#C9A227",
|
|
1837
|
-
strokeWidth: "1.3"
|
|
1838
|
-
}
|
|
1839
|
-
)
|
|
1840
|
-
}
|
|
1841
|
-
);
|
|
1842
|
-
}
|
|
1843
1822
|
function DepthRow({
|
|
1844
1823
|
side,
|
|
1845
1824
|
price,
|
|
@@ -1890,8 +1869,7 @@ function DepthRow({
|
|
|
1890
1869
|
"span",
|
|
1891
1870
|
{
|
|
1892
1871
|
"aria-label": "Your order at this price",
|
|
1893
|
-
className: "absolute left-0 top-1/2 -translate-y-1/2 z-[2]"
|
|
1894
|
-
children: /* @__PURE__ */ jsx(BreadSliceGlyph, {})
|
|
1872
|
+
className: "absolute left-0 top-1/2 -translate-y-1/2 z-[2] h-[6px] w-[6px] rounded-full bg-[#C9A227] shadow-[0_0_6px_rgba(201,162,39,0.7)]"
|
|
1895
1873
|
}
|
|
1896
1874
|
) : null,
|
|
1897
1875
|
/* @__PURE__ */ jsxs("div", { "data-cell": "price", className: cn("relative z-[1] tabular-nums", isAsk ? "text-[#f6465d]" : "text-[#0ecb81]"), children: [
|
|
@@ -2837,12 +2815,16 @@ function MobileDepthRow({
|
|
|
2837
2815
|
left: "2px",
|
|
2838
2816
|
top: "50%",
|
|
2839
2817
|
transform: "translateY(-50%)",
|
|
2818
|
+
width: "6px",
|
|
2819
|
+
height: "6px",
|
|
2820
|
+
borderRadius: "50%",
|
|
2821
|
+
backgroundColor: "#C9A227",
|
|
2822
|
+
boxShadow: "0 0 6px rgba(201,162,39,0.7)",
|
|
2840
2823
|
zIndex: 2
|
|
2841
|
-
}
|
|
2842
|
-
children: /* @__PURE__ */ jsx(BreadSliceGlyph, {})
|
|
2824
|
+
}
|
|
2843
2825
|
}
|
|
2844
2826
|
) : null,
|
|
2845
|
-
/* @__PURE__ */ jsxs("div", { style: { position: "relative", zIndex: 1, color: isAsk ? "#f6465d" : "#0ecb81", paddingLeft: hasUserOrder ? "
|
|
2827
|
+
/* @__PURE__ */ jsxs("div", { style: { position: "relative", zIndex: 1, color: isAsk ? "#f6465d" : "#0ecb81", paddingLeft: hasUserOrder ? "10px" : void 0 }, children: [
|
|
2846
2828
|
"$",
|
|
2847
2829
|
formatNumber(price, precision)
|
|
2848
2830
|
] }),
|
|
@@ -13293,18 +13275,19 @@ var COMING_SOON_TITLES = [
|
|
|
13293
13275
|
"Annual Financial Statements",
|
|
13294
13276
|
"Risk Disclosure Statement"
|
|
13295
13277
|
];
|
|
13296
|
-
function PropertyDocuments({ documentsData, highlightDocument, onClearHighlight }) {
|
|
13278
|
+
function PropertyDocuments({ documentsData, highlightDocument, onClearHighlight, forceComingSoon }) {
|
|
13297
13279
|
const highlightRef = useRef(null);
|
|
13298
13280
|
const [previewUrl, setPreviewUrl] = useState(null);
|
|
13299
13281
|
const [previewTitle, setPreviewTitle] = useState(null);
|
|
13300
13282
|
const backendDocuments = Array.isArray(documentsData?.documents) ? documentsData.documents : [];
|
|
13301
|
-
const liveDocs = backendDocuments.filter(
|
|
13283
|
+
const liveDocs = forceComingSoon ? [] : backendDocuments.filter(
|
|
13302
13284
|
(d) => Boolean(d.documentUrl) && isSafeUrl(d.documentUrl) && LIVE_TITLE_PATTERNS.some((rx) => rx.test(d.title))
|
|
13303
13285
|
);
|
|
13286
|
+
const visibleBackendDocs = forceComingSoon ? backendDocuments.map((d) => ({ title: d.title, documentUrl: "" })) : liveDocs;
|
|
13304
13287
|
const comingSoonDocs = COMING_SOON_TITLES.filter(
|
|
13305
|
-
(title) => !
|
|
13288
|
+
(title) => !visibleBackendDocs.some((d) => d.title.toLowerCase().includes(title.toLowerCase()) || title.toLowerCase().includes(d.title.toLowerCase()))
|
|
13306
13289
|
).map((title) => ({ title, documentUrl: "" }));
|
|
13307
|
-
const documents = [...
|
|
13290
|
+
const documents = [...visibleBackendDocs, ...comingSoonDocs];
|
|
13308
13291
|
const activeUrl = previewUrl ?? (liveDocs[0]?.documentUrl || null);
|
|
13309
13292
|
const activeTitle = previewUrl ? previewTitle : liveDocs[0]?.title || null;
|
|
13310
13293
|
const selectPreview = (doc) => {
|