@loafmarkets/ui 0.1.151 → 0.1.152

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 CHANGED
@@ -7971,6 +7971,7 @@ function GalleryMapSection({
7971
7971
  const [carouselIndex, setCarouselIndex] = React5.useState(0);
7972
7972
  const [showVideo, setShowVideo] = React5.useState(false);
7973
7973
  const [autoPlaying, setAutoPlaying] = React5.useState(autoPlay);
7974
+ const [showFullMap, setShowFullMap] = React5.useState(false);
7974
7975
  const resolvedMapUrl = mapUrl ?? (tokenName ? `/map/${tokenName}?embed=true&zoom=14&hideOthers=true` : "about:blank");
7975
7976
  React5.useEffect(() => {
7976
7977
  if (!autoPlaying || images.length <= 1) return;
@@ -8064,7 +8065,13 @@ function GalleryMapSection({
8064
8065
  /* @__PURE__ */ jsxRuntime.jsx(bi.BiMap, {}),
8065
8066
  " Location"
8066
8067
  ] }),
8067
- /* @__PURE__ */ jsxRuntime.jsx("span", { children: propertyLocation })
8068
+ /* @__PURE__ */ jsxRuntime.jsxs(MapHeaderRight, { children: [
8069
+ /* @__PURE__ */ jsxRuntime.jsx("span", { children: propertyLocation }),
8070
+ /* @__PURE__ */ jsxRuntime.jsxs("button", { type: "button", onClick: () => setShowFullMap(true), children: [
8071
+ /* @__PURE__ */ jsxRuntime.jsx("svg", { viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", style: { width: 14, height: 14 }, children: /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M8 3H5a2 2 0 00-2 2v3m18 0V5a2 2 0 00-2-2h-3m0 18h3a2 2 0 002-2v-3M3 16v3a2 2 0 002 2h3" }) }),
8072
+ "Full Screen"
8073
+ ] })
8074
+ ] })
8068
8075
  ] }),
8069
8076
  /* @__PURE__ */ jsxRuntime.jsxs(MapFrame, { children: [
8070
8077
  /* @__PURE__ */ jsxRuntime.jsx(IframeShield, { onClick: (e) => e.currentTarget.style.display = "none" }),
@@ -8082,9 +8089,40 @@ function GalleryMapSection({
8082
8089
  }
8083
8090
  )
8084
8091
  ] })
8085
- ] })
8092
+ ] }),
8093
+ showFullMap && /* @__PURE__ */ jsxRuntime.jsx(FullMapPopup, { onClose: () => setShowFullMap(false) })
8086
8094
  ] });
8087
8095
  }
8096
+ function FullMapPopup({ onClose }) {
8097
+ React5.useEffect(() => {
8098
+ const handleEsc = (e) => {
8099
+ if (e.key === "Escape") onClose();
8100
+ };
8101
+ window.addEventListener("keydown", handleEsc);
8102
+ return () => window.removeEventListener("keydown", handleEsc);
8103
+ }, [onClose]);
8104
+ return /* @__PURE__ */ jsxRuntime.jsx(FullMapOverlay, { onClick: onClose, children: /* @__PURE__ */ jsxRuntime.jsxs(FullMapPanel, { onClick: (e) => e.stopPropagation(), children: [
8105
+ /* @__PURE__ */ jsxRuntime.jsxs(FullMapHeader, { children: [
8106
+ /* @__PURE__ */ jsxRuntime.jsxs(FullMapTitle, { children: [
8107
+ /* @__PURE__ */ jsxRuntime.jsx(bi.BiMap, {}),
8108
+ " Map View"
8109
+ ] }),
8110
+ /* @__PURE__ */ jsxRuntime.jsx(FullMapClose, { onClick: onClose, "aria-label": "Close map", children: "\u2715" })
8111
+ ] }),
8112
+ /* @__PURE__ */ jsxRuntime.jsx(FullMapFrame, { children: /* @__PURE__ */ jsxRuntime.jsx(
8113
+ "iframe",
8114
+ {
8115
+ src: "/map",
8116
+ width: "100%",
8117
+ height: "100%",
8118
+ style: { border: 0 },
8119
+ allow: "autoplay; fullscreen; web-share; xr-spatial-tracking;",
8120
+ title: "Full Screen Map",
8121
+ referrerPolicy: "unsafe-url"
8122
+ }
8123
+ ) })
8124
+ ] }) });
8125
+ }
8088
8126
  var Row = styled9__default.default.div`
8089
8127
  display: grid;
8090
8128
  grid-template-columns: 2fr 1fr;
@@ -8207,6 +8245,62 @@ var MapFrame = styled9__default.default.div`
8207
8245
  var IframeShield = styled9__default.default.div`
8208
8246
  position: absolute; inset: 0; z-index: 1; cursor: pointer;
8209
8247
  `;
8248
+ var MapHeaderRight = styled9__default.default.div`
8249
+ display: flex;
8250
+ align-items: center;
8251
+ gap: 0.75rem;
8252
+ `;
8253
+ var FullMapOverlay = styled9__default.default.div`
8254
+ position: fixed;
8255
+ inset: 0;
8256
+ background: rgba(0,0,0,0.75);
8257
+ z-index: 9999;
8258
+ display: flex;
8259
+ align-items: center;
8260
+ justify-content: center;
8261
+ backdrop-filter: blur(4px);
8262
+ `;
8263
+ var FullMapPanel = styled9__default.default.div`
8264
+ background: #111;
8265
+ border: 1px solid rgba(255,255,255,0.08);
8266
+ border-radius: 14px;
8267
+ width: 94%;
8268
+ height: 90vh;
8269
+ display: flex;
8270
+ flex-direction: column;
8271
+ overflow: hidden;
8272
+ `;
8273
+ var FullMapHeader = styled9__default.default.div`
8274
+ display: flex;
8275
+ align-items: center;
8276
+ justify-content: space-between;
8277
+ padding: 1rem 1.5rem;
8278
+ border-bottom: 1px solid rgba(255,255,255,0.06);
8279
+ flex-shrink: 0;
8280
+ `;
8281
+ var FullMapTitle = styled9__default.default.h3`
8282
+ margin: 0;
8283
+ font-size: 1.1rem;
8284
+ font-weight: 600;
8285
+ color: #fff;
8286
+ display: flex;
8287
+ align-items: center;
8288
+ gap: 0.5rem;
8289
+ `;
8290
+ var FullMapClose = styled9__default.default.button`
8291
+ background: none;
8292
+ border: none;
8293
+ color: rgba(255,255,255,0.4);
8294
+ font-size: 1.1rem;
8295
+ cursor: pointer;
8296
+ padding: 0.25rem;
8297
+ line-height: 1;
8298
+ &:hover { color: #fff; }
8299
+ `;
8300
+ var FullMapFrame = styled9__default.default.div`
8301
+ flex: 1;
8302
+ min-height: 0;
8303
+ `;
8210
8304
  var BedIcon = /* @__PURE__ */ jsxRuntime.jsxs("svg", { width: "16", height: "16", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.5", strokeLinecap: "round", strokeLinejoin: "round", children: [
8211
8305
  /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M2 4v16" }),
8212
8306
  /* @__PURE__ */ jsxRuntime.jsx("path", { d: "M2 8h18a2 2 0 0 1 2 2v10" }),