@loafmarkets/ui 0.1.159 → 0.1.161

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
@@ -8100,6 +8100,28 @@ function FullMapPopup({ onClose }) {
8100
8100
  window.addEventListener("keydown", handleEsc);
8101
8101
  return () => window.removeEventListener("keydown", handleEsc);
8102
8102
  }, [onClose]);
8103
+ useEffect(() => {
8104
+ const handleMessage = (e) => {
8105
+ if (e.data === "loaf:close-embed") onClose();
8106
+ };
8107
+ window.addEventListener("message", handleMessage);
8108
+ return () => window.removeEventListener("message", handleMessage);
8109
+ }, [onClose]);
8110
+ const iframeRef = useCallback((node) => {
8111
+ if (!node) return;
8112
+ const handleLoad = () => {
8113
+ try {
8114
+ const iframeDoc = node.contentDocument || node.contentWindow?.document;
8115
+ if (iframeDoc) {
8116
+ iframeDoc.addEventListener("keydown", (e) => {
8117
+ if (e.key === "Escape") onClose();
8118
+ });
8119
+ }
8120
+ } catch (_) {
8121
+ }
8122
+ };
8123
+ node.addEventListener("load", handleLoad);
8124
+ }, [onClose]);
8103
8125
  return /* @__PURE__ */ jsx(FullMapOverlay, { onClick: onClose, children: /* @__PURE__ */ jsxs(FullMapPanel, { onClick: (e) => e.stopPropagation(), children: [
8104
8126
  /* @__PURE__ */ jsxs(FullMapHeader, { children: [
8105
8127
  /* @__PURE__ */ jsxs(FullMapTitle, { children: [
@@ -8111,7 +8133,8 @@ function FullMapPopup({ onClose }) {
8111
8133
  /* @__PURE__ */ jsx(FullMapFrame, { children: /* @__PURE__ */ jsx(
8112
8134
  "iframe",
8113
8135
  {
8114
- src: "/map",
8136
+ ref: iframeRef,
8137
+ src: "/map?embed=true",
8115
8138
  width: "100%",
8116
8139
  height: "100%",
8117
8140
  style: { border: 0 },
@@ -8516,7 +8539,7 @@ function PropertyOverview({
8516
8539
  ] });
8517
8540
  const tokenDetailsItems = [
8518
8541
  { label: "Chain", value: chainValue },
8519
- { label: "Contract Address", value: contractAddress ? truncateAddress(contractAddress) : "\u2014", mono: true, link: contractAddress ? `https://basescan.org/address/${contractAddress}` : void 0 },
8542
+ { label: "On-Chain Address", value: contractAddress ? truncateAddress(contractAddress) : "\u2014", mono: true, link: contractAddress ? `https://basescan.org/address/${contractAddress}` : void 0 },
8520
8543
  { label: "Token Ticker", value: ticker ?? "\u2014" },
8521
8544
  { label: "Total Tokens", value: isLoading && resolvedTokensIssued == null ? loadingSkeleton : resolvedTokensIssued?.toLocaleString() ?? "\u2014" },
8522
8545
  { label: "Percentage Tokenized", value: percentageTokenized != null ? `${percentageTokenized}%` : "\u2014" },