@loafmarkets/ui 0.1.141 → 0.1.143
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.js +8 -11
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +8 -11
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -8336,12 +8336,15 @@ function PropertyOverview({
|
|
|
8336
8336
|
const weeklyRent = overviewData?.weeklyRent ?? 0;
|
|
8337
8337
|
const annualRent = weeklyRent * 52;
|
|
8338
8338
|
const dividendYield = resolvedValuation && annualRent > 0 ? (annualRent / resolvedValuation * 100).toFixed(2) : null;
|
|
8339
|
+
const monthlyCoupon = annualRent / 12;
|
|
8340
|
+
const tokenMarketCap = tokenPriceValue && resolvedTokensIssued ? tokenPriceValue * resolvedTokensIssued : null;
|
|
8341
|
+
const currentDividendYield = tokenMarketCap && monthlyCoupon > 0 ? (monthlyCoupon * 12 / tokenMarketCap * 100).toFixed(2) : null;
|
|
8339
8342
|
const loadingSkeleton = /* @__PURE__ */ jsx(Skeleton, { width: 90, height: 18 });
|
|
8340
8343
|
const resolvedPropertyType = overviewData?.propertyType ?? propertyTypeLabel ?? null;
|
|
8341
8344
|
const galleryImages = images ?? [];
|
|
8342
8345
|
const tokenDetailsItems = [
|
|
8343
8346
|
{ label: "Chain", value: chain },
|
|
8344
|
-
{ label: "Contract Address", value: contractAddress ? truncateAddress(contractAddress) : "\u2014", mono: true },
|
|
8347
|
+
{ label: "Contract Address", value: contractAddress ? truncateAddress(contractAddress) : "\u2014", mono: true, link: contractAddress ? `https://basescan.org/address/${contractAddress}` : void 0 },
|
|
8345
8348
|
{ label: "Token Ticker", value: ticker ?? "\u2014" },
|
|
8346
8349
|
{ label: "Total Tokens", value: isLoading && resolvedTokensIssued == null ? loadingSkeleton : resolvedTokensIssued?.toLocaleString() ?? "\u2014" },
|
|
8347
8350
|
{ label: "Percentage Tokenized", value: percentageTokenized != null ? `${percentageTokenized}%` : "\u2014" },
|
|
@@ -8356,7 +8359,7 @@ function PropertyOverview({
|
|
|
8356
8359
|
];
|
|
8357
8360
|
const propertyStats = [
|
|
8358
8361
|
{ label: "Offering Valuation", value: isLoading && resolvedValuation == null ? loadingSkeleton : resolvedValuation ? resolvedValuation >= 1e6 ? `$${(resolvedValuation / 1e6).toFixed(2)}M` : `$${resolvedValuation.toLocaleString()}` : "\u2014" },
|
|
8359
|
-
{ label: "
|
|
8362
|
+
{ label: "Current Dividend Yield", value: isLoading && currentDividendYield == null ? loadingSkeleton : currentDividendYield ? `${currentDividendYield}%` : "\u2014" },
|
|
8360
8363
|
{ label: "Annual Rent", value: isLoading && !overviewData ? loadingSkeleton : annualRent > 0 ? `$${annualRent.toLocaleString()}/yr` : "\u2014" },
|
|
8361
8364
|
{ label: "Year Built", value: isLoading && !overviewData ? loadingSkeleton : overviewData?.yearBuilt ? String(overviewData.yearBuilt) : "\u2014" }
|
|
8362
8365
|
];
|
|
@@ -8378,7 +8381,7 @@ function PropertyOverview({
|
|
|
8378
8381
|
/* @__PURE__ */ jsx(TokenDetailsTitle, { children: "Token Details" }),
|
|
8379
8382
|
tokenDetailsItems.map((item) => /* @__PURE__ */ jsxs(TokenDetailRow, { children: [
|
|
8380
8383
|
/* @__PURE__ */ jsx(TokenDetailLabel, { children: item.label }),
|
|
8381
|
-
/* @__PURE__ */ jsx(TokenDetailValue, { $mono: !!item.mono, children: item.value })
|
|
8384
|
+
/* @__PURE__ */ jsx(TokenDetailValue, { $mono: !!item.mono, children: item.link ? /* @__PURE__ */ jsx("a", { href: item.link, target: "_blank", rel: "noopener noreferrer", style: { color: "#3380FF", textDecoration: "none" }, children: item.value }) : item.value })
|
|
8382
8385
|
] }, item.label))
|
|
8383
8386
|
] })
|
|
8384
8387
|
] })
|
|
@@ -8396,13 +8399,7 @@ function PropertyOverview({
|
|
|
8396
8399
|
/* @__PURE__ */ jsxs(StatsColumn, { children: [
|
|
8397
8400
|
/* @__PURE__ */ jsx(StatsColumnHeader, { children: "Property Fundamentals" }),
|
|
8398
8401
|
propertyStats.map((item) => /* @__PURE__ */ jsxs(StatRow, { children: [
|
|
8399
|
-
/* @__PURE__ */
|
|
8400
|
-
item.label,
|
|
8401
|
-
item.badge && /* @__PURE__ */ jsxs(StatBadge, { children: [
|
|
8402
|
-
/* @__PURE__ */ jsx("span", { style: { width: 5, height: 5, borderRadius: "50%", backgroundColor: "#4CAF50", display: "inline-block" } }),
|
|
8403
|
-
item.badge
|
|
8404
|
-
] })
|
|
8405
|
-
] }),
|
|
8402
|
+
/* @__PURE__ */ jsx(StatLabel, { children: item.label }),
|
|
8406
8403
|
/* @__PURE__ */ jsx(StatValue, { children: item.value })
|
|
8407
8404
|
] }, item.label))
|
|
8408
8405
|
] })
|
|
@@ -8644,7 +8641,7 @@ var StatLabel = styled19.span`
|
|
|
8644
8641
|
align-items: center;
|
|
8645
8642
|
gap: 0.5rem;
|
|
8646
8643
|
`;
|
|
8647
|
-
|
|
8644
|
+
styled19.span`
|
|
8648
8645
|
font-size: 0.6rem;
|
|
8649
8646
|
color: #4CAF50;
|
|
8650
8647
|
display: inline-flex;
|