@ohhwells/bridge 0.1.46-next.109 → 0.1.47

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.cjs CHANGED
@@ -115,7 +115,6 @@ var import_react3 = require("react");
115
115
  var import_react2 = require("react");
116
116
  var import_radix_ui = require("radix-ui");
117
117
  var import_jsx_runtime = require("react/jsx-runtime");
118
- var isValidEmail = (value) => /^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(value);
119
118
  function Spinner() {
120
119
  return /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(
121
120
  "svg",
@@ -149,17 +148,12 @@ function EmailCaptureModal({ title, subtitle, onSubmit, onClose }) {
149
148
  const [error, setError] = (0, import_react2.useState)(null);
150
149
  const isBook = title === "Confirm your spot";
151
150
  const handleSubmit = async () => {
152
- const trimmed = email.trim();
153
- if (!trimmed) return;
154
- if (!isValidEmail(trimmed)) {
155
- setError("Please enter a valid email address.");
156
- return;
157
- }
151
+ if (!email.trim()) return;
158
152
  setLoading(true);
159
153
  setError(null);
160
154
  try {
161
- await onSubmit(trimmed);
162
- setSubmittedEmail(trimmed);
155
+ await onSubmit(email.trim());
156
+ setSubmittedEmail(email.trim());
163
157
  setSuccess(true);
164
158
  } catch (e) {
165
159
  setError(e instanceof Error ? e.message : "Something went wrong. Please try again.");
@@ -234,10 +228,7 @@ function EmailCaptureModal({ title, subtitle, onSubmit, onClose }) {
234
228
  {
235
229
  type: "email",
236
230
  value: email,
237
- onChange: (e) => {
238
- setEmail(e.target.value);
239
- if (error) setError(null);
240
- },
231
+ onChange: (e) => setEmail(e.target.value),
241
232
  onKeyDown: handleKeyDown,
242
233
  placeholder: "hello@gmail.com",
243
234
  autoFocus: true,
@@ -294,20 +285,12 @@ function formatClassTime(cls) {
294
285
  const em = endTotal % 60;
295
286
  return `${h}:${cls.startTime.minutes}-${eh}:${String(em).padStart(2, "0")}`;
296
287
  }
297
- function formatBookingLabel(cls) {
298
- const price = cls.price;
299
- const isFree = price === null || price === void 0 || `${price}` === "" || `${price}` === "0";
300
- return isFree ? "Book for free" : `Book for ${cls.currency ?? ""} ${price}`.trim();
301
- }
302
288
  function getBookingsOnDate(cls, date) {
303
289
  if (!cls.bookings?.length) return 0;
304
- const target = new Date(date);
305
- target.setHours(0, 0, 0, 0);
290
+ const ds = date.toISOString().split("T")[0];
306
291
  return cls.bookings.filter((b) => {
307
292
  try {
308
- const bookingDate = new Date(b.classDate);
309
- bookingDate.setHours(0, 0, 0, 0);
310
- return bookingDate.getTime() === target.getTime();
293
+ return new Date(b.classDate).toISOString().split("T")[0] === ds;
311
294
  } catch {
312
295
  return false;
313
296
  }
@@ -572,7 +555,7 @@ function ScheduleView({ schedule, dates, selectedIdx, onSelectDate, onOpenModal
572
555
  }
573
556
  )
574
557
  ] }),
575
- cls.showAvailability !== false && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: "sm:hidden flex flex-col gap-px", children: isFull ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "font-body text-sm text-(--color-dark,#200C02) opacity-80", children: "Full" }) : /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_jsx_runtime2.Fragment, { children: [
558
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: "sm:hidden flex flex-col gap-px", children: isFull ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "font-body text-sm text-(--color-dark,#200C02) opacity-80", children: "Full" }) : /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_jsx_runtime2.Fragment, { children: [
576
559
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("span", { className: "font-body text-sm text-(--color-dark,#200C02) opacity-80", children: [
577
560
  available,
578
561
  "/",
@@ -584,17 +567,9 @@ function ScheduleView({ schedule, dates, selectedIdx, onSelectDate, onOpenModal
584
567
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: "flex flex-1 flex-col gap-2 min-w-0 sm:contents", children: [
585
568
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: "flex-1 flex flex-col gap-2 min-w-0", children: [
586
569
  /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "font-body text-base font-bold text-(--color-dark,#200C02) block truncate", children: cls.name }),
587
- cls.hostName && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "font-body text-base font-normal text-(--color-dark,#200C02) opacity-80 block truncate", children: cls.hostName }),
588
- cls.description && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
589
- "span",
590
- {
591
- className: "font-body text-base font-normal text-(--color-dark,#200C02) opacity-80 block",
592
- style: { wordBreak: "break-word" },
593
- children: cls.description
594
- }
595
- )
570
+ cls.hostName && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "font-body text-base font-normal text-(--color-dark,#200C02) opacity-80 block truncate", children: cls.hostName })
596
571
  ] }),
597
- cls.showAvailability !== false && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: "hidden sm:flex w-14 shrink-0 flex-col gap-px", children: isFull ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "font-body text-sm text-(--color-dark,#200C02) opacity-80", children: "Full" }) : /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_jsx_runtime2.Fragment, { children: [
572
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("div", { className: "hidden sm:flex w-14 shrink-0 flex-col gap-px", children: isFull ? /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("span", { className: "font-body text-sm text-(--color-dark,#200C02) opacity-80", children: "Full" }) : /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)(import_jsx_runtime2.Fragment, { children: [
598
573
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("span", { className: "font-body text-sm text-(--color-dark,#200C02) opacity-80", children: [
599
574
  available,
600
575
  "/",
@@ -619,7 +594,7 @@ function ScheduleView({ schedule, dates, selectedIdx, onSelectDate, onOpenModal
619
594
  if (!cls.id) return;
620
595
  onOpenModal?.(isFull ? "waitlist" : "book", cls.id, selectedDate);
621
596
  },
622
- children: isFull ? "Join Waitlist" : formatBookingLabel(cls)
597
+ children: isFull ? "Join Waitlist" : "Book Now"
623
598
  }
624
599
  )
625
600
  ] })
@@ -661,17 +636,6 @@ function SchedulingWidget({ notifyOnConnect = false, initialScheduleId, insertAf
661
636
  const [isHovered, setIsHovered] = (0, import_react3.useState)(false);
662
637
  const [modalState, setModalState] = (0, import_react3.useState)(null);
663
638
  const switchScheduleIdRef = (0, import_react3.useRef)(null);
664
- const liveScheduleIdRef = (0, import_react3.useRef)(null);
665
- const refetchLiveSchedule = (0, import_react3.useCallback)(async () => {
666
- const id = liveScheduleIdRef.current;
667
- if (!id) return;
668
- try {
669
- const res = await fetch(`${API_URL}/api/schedule/id/${id}`);
670
- const data = await res.json();
671
- if (data?.id) setSchedule(data);
672
- } catch {
673
- }
674
- }, []);
675
639
  const dates = (0, import_react3.useMemo)(() => {
676
640
  const today = /* @__PURE__ */ new Date();
677
641
  today.setHours(0, 0, 0, 0);
@@ -691,18 +655,6 @@ function SchedulingWidget({ notifyOnConnect = false, initialScheduleId, insertAf
691
655
  }
692
656
  }
693
657
  }, [schedule, dates]);
694
- (0, import_react3.useEffect)(() => {
695
- if (typeof window === "undefined") return;
696
- const onVisible = () => {
697
- if (!document.hidden) void refetchLiveSchedule();
698
- };
699
- window.addEventListener("focus", refetchLiveSchedule);
700
- document.addEventListener("visibilitychange", onVisible);
701
- return () => {
702
- window.removeEventListener("focus", refetchLiveSchedule);
703
- document.removeEventListener("visibilitychange", onVisible);
704
- };
705
- }, [refetchLiveSchedule]);
706
658
  (0, import_react3.useEffect)(() => {
707
659
  if (typeof window === "undefined") return;
708
660
  const isInEditor = window.self !== window.top;
@@ -764,7 +716,7 @@ function SchedulingWidget({ notifyOnConnect = false, initialScheduleId, insertAf
764
716
  setLoading(false);
765
717
  return;
766
718
  }
767
- liveScheduleIdRef.current = effectiveId;
719
+ ;
768
720
  (async () => {
769
721
  try {
770
722
  const res = await fetch(`${API_URL}/api/schedule/id/${effectiveId}`);
@@ -821,14 +773,18 @@ function SchedulingWidget({ notifyOnConnect = false, initialScheduleId, insertAf
821
773
  const data = await res.json().catch(() => ({}));
822
774
  throw new Error(data?.message ?? "Something went wrong. Please try again.");
823
775
  }
824
- await refetchLiveSchedule();
825
776
  };
826
777
  const handleReplaceSchedule = () => {
827
778
  setIsHovered(false);
828
- window.parent.postMessage(
829
- { type: "ow:scheduling-not-connected", insertAfter, currentScheduleId: schedule?.id },
830
- "*"
831
- );
779
+ if (schedule) {
780
+ window.parent.postMessage({
781
+ type: "ow:schedule-connected",
782
+ schedule: { id: schedule.id, name: schedule.name },
783
+ insertAfter
784
+ }, "*");
785
+ } else {
786
+ window.parent.postMessage({ type: "ow:scheduling-not-connected", insertAfter }, "*");
787
+ }
832
788
  };
833
789
  if (!inEditor && !loading && !schedule) return null;
834
790
  const sectionId = `scheduling-${insertAfter}`;
@@ -871,19 +827,7 @@ function SchedulingWidget({ notifyOnConnect = false, initialScheduleId, insertAf
871
827
  ),
872
828
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: "max-w-[1280px] mx-auto flex flex-col items-center gap-16", children: [
873
829
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: "flex flex-col items-center gap-4", children: [
874
- /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
875
- "h2",
876
- {
877
- className: "font-display text-center m-0 text-(--color-dark,#200C02)",
878
- style: {
879
- fontSize: "var(--fs-section-h2, clamp(40px, 4.4vw, 64px))",
880
- fontWeight: "var(--font-weight-heading, 400)",
881
- lineHeight: 1.05,
882
- letterSpacing: "-0.02em"
883
- },
884
- children: schedule?.name ?? "Book an appointment"
885
- }
886
- ),
830
+ /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("h2", { className: "font-display text-4xl sm:text-5xl font-bold text-center m-0 text-(--color-dark,#200C02)", children: schedule?.name ?? "Book an appointment" }),
887
831
  schedule?.description && /* @__PURE__ */ (0, import_jsx_runtime2.jsx)("p", { className: "font-body text-body text-center m-0 text-(--color-accent,#A89B83)", children: schedule.description })
888
832
  ] }),
889
833
  /* @__PURE__ */ (0, import_jsx_runtime2.jsxs)("div", { className: "w-full flex flex-col items-end gap-3", children: [
@@ -4943,11 +4887,7 @@ function MediaOverlay({
4943
4887
  variant: "outline",
4944
4888
  size: "sm",
4945
4889
  className: "gap-1.5 cursor-pointer hover:bg-background",
4946
- style: {
4947
- ...OVERLAY_BUTTON_STYLE,
4948
- // Don't let Replace steal clicks when text (e.g. nav) sits on top of this media.
4949
- pointerEvents: hover.hasTextOverlap ? "none" : "auto"
4950
- },
4890
+ style: OVERLAY_BUTTON_STYLE,
4951
4891
  onMouseDown: (e) => e.preventDefault(),
4952
4892
  onClick: (e) => {
4953
4893
  e.stopPropagation();
@@ -7071,195 +7011,7 @@ function parseFooterOrder(content) {
7071
7011
  return null;
7072
7012
  }
7073
7013
  }
7074
- var FOOTER_HEADING_RE = /^footer-(\d+)-heading$/;
7075
- var FOOTER_LABEL_RE = /^footer-(\d+)-(\d+)-label$/;
7076
- var DEFAULT_FOOTER_COLUMN_HEADING = "New";
7077
- var DEFAULT_FOOTER_COLUMN_LINK_LABEL = "New link";
7078
- var DEFAULT_FOOTER_COLUMN_LINK_HREF = "";
7079
- function isFooterLinksContainer(el) {
7080
- return el.hasAttribute("data-ohw-footer-links") || el.classList.contains("rb-footer-links");
7081
- }
7082
- function getFooterColumnIndicesInDom() {
7083
- const indices = /* @__PURE__ */ new Set();
7084
- for (const col of listFooterColumns()) {
7085
- const attr = col.getAttribute("data-ohw-footer-col");
7086
- if (attr != null) {
7087
- const n = parseInt(attr, 10);
7088
- if (Number.isFinite(n)) indices.add(n);
7089
- }
7090
- for (const link of listFooterLinksInColumn(col)) {
7091
- const parsed = parseFooterHrefKey(link.getAttribute("data-ohw-href-key"));
7092
- if (parsed) indices.add(parsed.col);
7093
- }
7094
- const heading = col.querySelector('[data-ohw-key^="footer-"][data-ohw-key$="-heading"]');
7095
- const headingKey = heading?.getAttribute("data-ohw-key");
7096
- if (headingKey) {
7097
- const match = headingKey.match(FOOTER_HEADING_RE);
7098
- if (match) indices.add(parseInt(match[1], 10));
7099
- }
7100
- }
7101
- return [...indices].sort((a, b) => a - b);
7102
- }
7103
- function getNextFooterColumnIndex() {
7104
- const indices = getFooterColumnIndicesInDom();
7105
- if (indices.length === 0) return 0;
7106
- return Math.max(...indices) + 1;
7107
- }
7108
- function cloneFooterLinkShell(template) {
7109
- const anchor = document.createElement("a");
7110
- if (template) {
7111
- anchor.style.cssText = template.style.cssText;
7112
- if (template.className) anchor.className = template.className;
7113
- }
7114
- anchor.style.cursor = "pointer";
7115
- anchor.style.textDecoration = "none";
7116
- return anchor;
7117
- }
7118
- function buildFooterHeading(colIndex, text) {
7119
- const heading = document.createElement("p");
7120
- heading.setAttribute("data-ohw-editable", "text");
7121
- heading.setAttribute("data-ohw-key", `footer-${colIndex}-heading`);
7122
- heading.textContent = text;
7123
- heading.style.cssText = [
7124
- "color: var(--espresso, #3d312b)",
7125
- "font-size: 14px",
7126
- "font-weight: 800",
7127
- "opacity: 0.82",
7128
- "margin: 0 0 6px",
7129
- "padding: 0",
7130
- "line-height: 1.2"
7131
- ].join(";");
7132
- return heading;
7133
- }
7134
- function buildFooterLink(colIndex, itemIndex, href, label, template) {
7135
- const anchor = cloneFooterLinkShell(template);
7136
- anchor.setAttribute("href", href);
7137
- anchor.setAttribute("data-ohw-href-key", `footer-${colIndex}-${itemIndex}-href`);
7138
- const span = document.createElement("span");
7139
- span.setAttribute("data-ohw-editable", "text");
7140
- span.setAttribute("data-ohw-key", `footer-${colIndex}-${itemIndex}-label`);
7141
- span.textContent = label;
7142
- anchor.appendChild(span);
7143
- return anchor;
7144
- }
7145
- function footerColumnExistsInDom(colIndex) {
7146
- return document.querySelector(`[data-ohw-footer-col="${colIndex}"]`) !== null || document.querySelector(`[data-ohw-href-key^="footer-${colIndex}-"]`) !== null || document.querySelector(`[data-ohw-key="footer-${colIndex}-heading"]`) !== null;
7147
- }
7148
- function getFooterLinkTemplate() {
7149
- for (const col of listFooterColumns()) {
7150
- const link = listFooterLinksInColumn(col)[0];
7151
- if (link) return link;
7152
- }
7153
- return null;
7154
- }
7155
- function getFooterColumnTemplate() {
7156
- return listFooterColumns()[0] ?? null;
7157
- }
7158
- function insertFooterColumnDom(colIndex, heading, items) {
7159
- const container = getFooterLinksContainer();
7160
- if (!container) return null;
7161
- const colTemplate = getFooterColumnTemplate();
7162
- const linkTemplate = getFooterLinkTemplate();
7163
- const column = document.createElement("div");
7164
- if (colTemplate?.className) column.className = colTemplate.className;
7165
- else column.className = "rb-footer-link-col";
7166
- column.setAttribute("data-ohw-footer-col", String(colIndex));
7167
- if (colTemplate) {
7168
- const gap = getComputedStyle(colTemplate).gap;
7169
- if (gap && gap !== "normal") column.style.gap = gap;
7170
- column.style.display = getComputedStyle(colTemplate).display || "flex";
7171
- column.style.flexDirection = "column";
7172
- }
7173
- column.appendChild(buildFooterHeading(colIndex, heading));
7174
- let firstLink = null;
7175
- items.forEach((item, itemIndex) => {
7176
- const link = buildFooterLink(colIndex, itemIndex, item.href, item.label, linkTemplate);
7177
- column.appendChild(link);
7178
- if (!firstLink) firstLink = link;
7179
- });
7180
- container.appendChild(column);
7181
- return { column, firstLink };
7182
- }
7183
- function insertFooterColumn(heading = DEFAULT_FOOTER_COLUMN_HEADING, linkLabel = DEFAULT_FOOTER_COLUMN_LINK_LABEL, linkHref = DEFAULT_FOOTER_COLUMN_LINK_HREF) {
7184
- const colIndex = getNextFooterColumnIndex();
7185
- const inserted = insertFooterColumnDom(colIndex, heading, [{ href: linkHref, label: linkLabel }]);
7186
- if (!inserted?.firstLink) throw new Error("Failed to insert footer column");
7187
- syncFooterColumnIndices(listFooterColumns());
7188
- return {
7189
- column: inserted.column,
7190
- firstLink: inserted.firstLink,
7191
- colIndex,
7192
- headingKey: `footer-${colIndex}-heading`,
7193
- hrefKey: `footer-${colIndex}-0-href`,
7194
- labelKey: `footer-${colIndex}-0-label`,
7195
- heading,
7196
- label: linkLabel,
7197
- href: linkHref,
7198
- order: getFooterOrderFromDom()
7199
- };
7200
- }
7201
- function collectFooterColumnIndicesFromContent(content) {
7202
- const indices = /* @__PURE__ */ new Set();
7203
- for (const key of Object.keys(content)) {
7204
- const href = parseFooterHrefKey(key);
7205
- if (href) indices.add(href.col);
7206
- const heading = key.match(FOOTER_HEADING_RE);
7207
- if (heading) indices.add(parseInt(heading[1], 10));
7208
- const label = key.match(FOOTER_LABEL_RE);
7209
- if (label) indices.add(parseInt(label[1], 10));
7210
- }
7211
- const order = parseFooterOrder(content);
7212
- if (order) {
7213
- for (const col of order) {
7214
- for (const hrefKey of col) {
7215
- const parsed = parseFooterHrefKey(hrefKey);
7216
- if (parsed) indices.add(parsed.col);
7217
- }
7218
- }
7219
- }
7220
- return [...indices].sort((a, b) => a - b);
7221
- }
7222
- function collectFooterItemsForColumn(content, colIndex) {
7223
- const itemIndices = /* @__PURE__ */ new Set();
7224
- for (const key of Object.keys(content)) {
7225
- const href = parseFooterHrefKey(key);
7226
- if (href?.col === colIndex) itemIndices.add(href.item);
7227
- const label = key.match(FOOTER_LABEL_RE);
7228
- if (label && parseInt(label[1], 10) === colIndex) {
7229
- itemIndices.add(parseInt(label[2], 10));
7230
- }
7231
- }
7232
- const sorted = [...itemIndices].sort((a, b) => a - b);
7233
- if (sorted.length === 0) {
7234
- return [
7235
- {
7236
- href: content[`footer-${colIndex}-0-href`] ?? DEFAULT_FOOTER_COLUMN_LINK_HREF,
7237
- label: content[`footer-${colIndex}-0-label`] ?? DEFAULT_FOOTER_COLUMN_LINK_LABEL
7238
- }
7239
- ];
7240
- }
7241
- return sorted.map((itemIndex) => ({
7242
- href: content[`footer-${colIndex}-${itemIndex}-href`] ?? DEFAULT_FOOTER_COLUMN_LINK_HREF,
7243
- label: content[`footer-${colIndex}-${itemIndex}-label`] ?? DEFAULT_FOOTER_COLUMN_LINK_LABEL
7244
- }));
7245
- }
7246
- function reconcileFooterColumnsFromContent(content) {
7247
- const indices = collectFooterColumnIndicesFromContent(content);
7248
- for (const colIndex of indices) {
7249
- if (footerColumnExistsInDom(colIndex)) continue;
7250
- const heading = content[`footer-${colIndex}-heading`] ?? DEFAULT_FOOTER_COLUMN_HEADING;
7251
- const items = collectFooterItemsForColumn(content, colIndex);
7252
- const hasPayload = Boolean(content[`footer-${colIndex}-heading`]) || items.some(
7253
- (_, i) => content[`footer-${colIndex}-${i}-href`] !== void 0 || content[`footer-${colIndex}-${i}-label`] !== void 0
7254
- ) || (parseFooterOrder(content)?.some(
7255
- (col) => col.some((k) => parseFooterHrefKey(k)?.col === colIndex)
7256
- ) ?? false);
7257
- if (!hasPayload) continue;
7258
- insertFooterColumnDom(colIndex, heading, items);
7259
- }
7260
- }
7261
7014
  function reconcileFooterOrderFromContent(content) {
7262
- reconcileFooterColumnsFromContent(content);
7263
7015
  const order = parseFooterOrder(content);
7264
7016
  if (!order?.length) return;
7265
7017
  const current = getFooterOrderFromDom();
@@ -7269,26 +7021,6 @@ function reconcileFooterOrderFromContent(content) {
7269
7021
  }
7270
7022
  applyFooterOrder(order);
7271
7023
  }
7272
- function resolveFooterLinksContainerSelectionTarget(target, clientX, clientY, isPointOverItem) {
7273
- const container = getFooterLinksContainer();
7274
- if (!container) return null;
7275
- const inContainer = target === container || container.contains(target) && Boolean(target.closest("[data-ohw-footer-links], .rb-footer-links"));
7276
- if (!inContainer && target !== container) {
7277
- const r2 = container.getBoundingClientRect();
7278
- const over = clientX >= r2.left && clientX <= r2.right && clientY >= r2.top && clientY <= r2.bottom;
7279
- if (!over) return null;
7280
- }
7281
- if (isPointOverItem(container, clientX, clientY)) return null;
7282
- const column = target.closest("[data-ohw-footer-col], [data-ohw-footer-column]") ?? null;
7283
- if (column && container.contains(column)) {
7284
- if (target === column || column.contains(target)) return null;
7285
- }
7286
- if (target === container || container.contains(target) || inContainer) {
7287
- if (target === container || isFooterLinksContainer(target)) return container;
7288
- if (!column) return container;
7289
- }
7290
- return null;
7291
- }
7292
7024
  function isRowLayoutColumn(links) {
7293
7025
  if (links.length < 2) return false;
7294
7026
  const firstTop = links[0].getBoundingClientRect().top;
@@ -7444,30 +7176,6 @@ function hitTestColumnDropSlot(clientX, _clientY) {
7444
7176
  return best?.slot ?? null;
7445
7177
  }
7446
7178
 
7447
- // src/lib/add-footer-column.ts
7448
- function buildFooterColumnEditContentPatch(result) {
7449
- return {
7450
- [result.headingKey]: result.heading,
7451
- [result.hrefKey]: result.href,
7452
- [result.labelKey]: result.label,
7453
- [FOOTER_ORDER_KEY]: JSON.stringify(result.order)
7454
- };
7455
- }
7456
- function addFooterColumnWithPersist({
7457
- postToParent: postToParent2
7458
- }) {
7459
- const result = insertFooterColumn();
7460
- const patch = buildFooterColumnEditContentPatch(result);
7461
- setStoredLinkHref(result.hrefKey, result.href);
7462
- postToParent2({
7463
- type: "ow:change",
7464
- nodes: Object.entries(patch).map(([key, text]) => ({ key, text }))
7465
- });
7466
- postToParent2({ type: "ow:toast", title: "Item added", toastType: "success" });
7467
- enforceLinkHrefs();
7468
- return result;
7469
- }
7470
-
7471
7179
  // src/lib/item-drag-interaction.ts
7472
7180
  function disableNativeHrefDrag(el) {
7473
7181
  if (el.draggable) el.draggable = false;
@@ -8000,60 +7708,15 @@ function useNavItemDrag({
8000
7708
  };
8001
7709
  }
8002
7710
 
8003
- // src/ui/footer-container-chrome.tsx
7711
+ // src/ui/navbar-container-chrome.tsx
8004
7712
  var import_lucide_react10 = require("lucide-react");
8005
7713
  var import_jsx_runtime21 = require("react/jsx-runtime");
8006
- function FooterContainerChrome({ rect, onAdd }) {
8007
- const chromeGap = 6;
8008
- const buttonMargin = 7;
8009
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(TooltipProvider, { delayDuration: 0, children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
8010
- "div",
8011
- {
8012
- "data-ohw-footer-container-chrome": "",
8013
- "data-ohw-bridge": "",
8014
- className: "pointer-events-none fixed z-[2147483647]",
8015
- style: {
8016
- top: rect.top - chromeGap,
8017
- left: rect.left - chromeGap,
8018
- width: rect.width + chromeGap * 2,
8019
- height: rect.height + chromeGap * 2
8020
- },
8021
- children: /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(Tooltip, { children: [
8022
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
8023
- "button",
8024
- {
8025
- type: "button",
8026
- "data-ohw-footer-add-button": "",
8027
- className: "pointer-events-auto absolute left-1/2 flex size-7 -translate-x-1/2 -translate-y-full items-center justify-center rounded-[10px] border border-border bg-background p-0.5 shadow-sm transition-colors hover:bg-muted/80",
8028
- style: { top: chromeGap - buttonMargin },
8029
- "aria-label": "Add item",
8030
- onMouseDown: (e) => {
8031
- e.preventDefault();
8032
- e.stopPropagation();
8033
- },
8034
- onClick: (e) => {
8035
- e.preventDefault();
8036
- e.stopPropagation();
8037
- onAdd();
8038
- },
8039
- children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_lucide_react10.Plus, { className: "size-4 shrink-0 text-foreground", "aria-hidden": true })
8040
- }
8041
- ) }),
8042
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(TooltipContent, { side: "bottom", sideOffset: 9, children: "Add item" })
8043
- ] })
8044
- }
8045
- ) });
8046
- }
8047
-
8048
- // src/ui/navbar-container-chrome.tsx
8049
- var import_lucide_react11 = require("lucide-react");
8050
- var import_jsx_runtime22 = require("react/jsx-runtime");
8051
7714
  function NavbarContainerChrome({
8052
7715
  rect,
8053
7716
  onAdd
8054
7717
  }) {
8055
7718
  const chromeGap = 6;
8056
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
7719
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
8057
7720
  "div",
8058
7721
  {
8059
7722
  "data-ohw-navbar-container-chrome": "",
@@ -8065,7 +7728,7 @@ function NavbarContainerChrome({
8065
7728
  width: rect.width + chromeGap * 2,
8066
7729
  height: rect.height + chromeGap * 2
8067
7730
  },
8068
- children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
7731
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
8069
7732
  "button",
8070
7733
  {
8071
7734
  type: "button",
@@ -8082,7 +7745,7 @@ function NavbarContainerChrome({
8082
7745
  e.stopPropagation();
8083
7746
  onAdd();
8084
7747
  },
8085
- children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_lucide_react11.Plus, { className: "size-4 shrink-0 text-foreground", "aria-hidden": true })
7748
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_lucide_react10.Plus, { className: "size-4 shrink-0 text-foreground", "aria-hidden": true })
8086
7749
  }
8087
7750
  )
8088
7751
  }
@@ -8091,7 +7754,7 @@ function NavbarContainerChrome({
8091
7754
 
8092
7755
  // src/ui/drop-indicator.tsx
8093
7756
  var React10 = __toESM(require("react"), 1);
8094
- var import_jsx_runtime23 = require("react/jsx-runtime");
7757
+ var import_jsx_runtime22 = require("react/jsx-runtime");
8095
7758
  var dropIndicatorVariants = cva(
8096
7759
  "ov-gap-line pointer-events-none shrink-0 transition-opacity duration-150",
8097
7760
  {
@@ -8115,7 +7778,7 @@ var dropIndicatorVariants = cva(
8115
7778
  );
8116
7779
  var DropIndicator = React10.forwardRef(
8117
7780
  ({ className, direction, state, ...props }, ref) => {
8118
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(
7781
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
8119
7782
  "div",
8120
7783
  {
8121
7784
  ref,
@@ -8132,7 +7795,7 @@ var DropIndicator = React10.forwardRef(
8132
7795
  DropIndicator.displayName = "DropIndicator";
8133
7796
 
8134
7797
  // src/ui/badge.tsx
8135
- var import_jsx_runtime24 = require("react/jsx-runtime");
7798
+ var import_jsx_runtime23 = require("react/jsx-runtime");
8136
7799
  var badgeVariants = cva(
8137
7800
  "inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",
8138
7801
  {
@@ -8150,12 +7813,12 @@ var badgeVariants = cva(
8150
7813
  }
8151
7814
  );
8152
7815
  function Badge({ className, variant, ...props }) {
8153
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: cn(badgeVariants({ variant }), className), ...props });
7816
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("div", { className: cn(badgeVariants({ variant }), className), ...props });
8154
7817
  }
8155
7818
 
8156
7819
  // src/OhhwellsBridge.tsx
8157
- var import_lucide_react12 = require("lucide-react");
8158
- var import_jsx_runtime25 = require("react/jsx-runtime");
7820
+ var import_lucide_react11 = require("lucide-react");
7821
+ var import_jsx_runtime24 = require("react/jsx-runtime");
8159
7822
  var PRIMARY2 = "#0885FE";
8160
7823
  var IMAGE_FADE_MS = 300;
8161
7824
  function runOpacityFade(el, onDone) {
@@ -8334,7 +7997,7 @@ function mountSchedulingWidget(insertAfter, notifyOnConnect = false, scheduleId,
8334
7997
  const root = (0, import_client.createRoot)(container);
8335
7998
  (0, import_react_dom2.flushSync)(() => {
8336
7999
  root.render(
8337
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
8000
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
8338
8001
  SchedulingWidget,
8339
8002
  {
8340
8003
  notifyOnConnect,
@@ -8535,7 +8198,7 @@ function applyLinkByKey(key, val) {
8535
8198
  }
8536
8199
  function isInsideLinkEditor(target) {
8537
8200
  return Boolean(
8538
- target.closest("[data-ohw-link-popover-root]") || target.closest("[data-ohw-link-modal-root]") || target.closest("[data-ohw-link-page-dropdown]") || target.closest("[data-ohw-section-picker]") || target.closest("[data-ohw-navbar-container-chrome]") || target.closest("[data-ohw-navbar-add-button]") || target.closest("[data-ohw-footer-container-chrome]") || target.closest("[data-ohw-footer-add-button]") || target.closest('[data-slot="popover-content"]') || target.closest('[data-slot="dialog-content"]') || target.closest('[data-slot="dialog-overlay"]')
8201
+ target.closest("[data-ohw-link-popover-root]") || target.closest("[data-ohw-link-modal-root]") || target.closest("[data-ohw-link-page-dropdown]") || target.closest("[data-ohw-section-picker]") || target.closest("[data-ohw-navbar-container-chrome]") || target.closest("[data-ohw-navbar-add-button]") || target.closest('[data-slot="popover-content"]') || target.closest('[data-slot="dialog-content"]') || target.closest('[data-slot="dialog-overlay"]')
8539
8202
  );
8540
8203
  }
8541
8204
  function getHrefKeyFromElement(el) {
@@ -8616,7 +8279,7 @@ function isInferredFooterGroup(el) {
8616
8279
  return countFooterNavItems(el) >= 2;
8617
8280
  }
8618
8281
  function isNavigationContainer(el) {
8619
- return el.hasAttribute("data-ohw-nav-container") || isFooterLinksContainer(el) || el.hasAttribute("data-ohw-footer-col") || el.hasAttribute("data-ohw-footer-column") || isNavigationRoot(el) || isInferredFooterGroup(el);
8282
+ return el.hasAttribute("data-ohw-nav-container") || el.hasAttribute("data-ohw-footer-col") || el.hasAttribute("data-ohw-footer-column") || isNavigationRoot(el) || isInferredFooterGroup(el);
8620
8283
  }
8621
8284
  function isNavbarLinksContainer(el) {
8622
8285
  return el.hasAttribute("data-ohw-nav-container");
@@ -8635,9 +8298,6 @@ function isPointOverNavigation(x, y) {
8635
8298
  const roots = /* @__PURE__ */ new Set();
8636
8299
  const navRoot = document.querySelector("[data-ohw-nav-root]") ?? document.querySelector("nav");
8637
8300
  if (navRoot) roots.add(navRoot);
8638
- document.querySelectorAll("[data-ohw-nav-drawer], [data-ohw-nav-container]").forEach((el) => {
8639
- roots.add(el);
8640
- });
8641
8301
  const footer = document.querySelector("footer");
8642
8302
  if (footer) roots.add(footer);
8643
8303
  for (const root of roots) {
@@ -8666,12 +8326,6 @@ function isPointOverNavItem(container, x, y) {
8666
8326
  return x >= itemRect.left && x <= itemRect.right && y >= itemRect.top && y <= itemRect.bottom;
8667
8327
  });
8668
8328
  }
8669
- function isPointOverFooterColumn(x, y) {
8670
- return listFooterColumns().some((col) => {
8671
- const r2 = col.getBoundingClientRect();
8672
- return x >= r2.left && x <= r2.right && y >= r2.top && y <= r2.bottom;
8673
- });
8674
- }
8675
8329
  function resolveNavContainerSelectionTarget(target, clientX, clientY) {
8676
8330
  if (getNavigationItemAnchor(target)) return null;
8677
8331
  if (target.closest('[data-ohw-role="navbar-button"]')) return null;
@@ -8702,10 +8356,7 @@ function getNavigationSelectionParent(el) {
8702
8356
  if (footerGroup) return footerGroup;
8703
8357
  return getNavigationRoot(el);
8704
8358
  }
8705
- if (!isFooterLinksContainer(el) && (el.hasAttribute("data-ohw-footer-col") || el.hasAttribute("data-ohw-footer-column") || isInferredFooterGroup(el))) {
8706
- return getFooterLinksContainer();
8707
- }
8708
- if (el.hasAttribute("data-ohw-nav-container") || el.hasAttribute("data-ohw-footer-col") || el.hasAttribute("data-ohw-footer-column") || isFooterLinksContainer(el) || isInferredFooterGroup(el)) {
8359
+ if (el.hasAttribute("data-ohw-nav-container") || el.hasAttribute("data-ohw-footer-col") || el.hasAttribute("data-ohw-footer-column") || isInferredFooterGroup(el)) {
8709
8360
  return getNavigationRoot(el);
8710
8361
  }
8711
8362
  return null;
@@ -8932,7 +8583,7 @@ function EditGlowChrome({
8932
8583
  hideHandle = false
8933
8584
  }) {
8934
8585
  const GAP = SELECTION_CHROME_GAP2;
8935
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
8586
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
8936
8587
  "div",
8937
8588
  {
8938
8589
  ref: elRef,
@@ -8947,7 +8598,7 @@ function EditGlowChrome({
8947
8598
  zIndex: 2147483646
8948
8599
  },
8949
8600
  children: [
8950
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
8601
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
8951
8602
  "div",
8952
8603
  {
8953
8604
  style: {
@@ -8960,7 +8611,7 @@ function EditGlowChrome({
8960
8611
  }
8961
8612
  }
8962
8613
  ),
8963
- reorderHrefKey && !hideHandle && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
8614
+ reorderHrefKey && !hideHandle && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
8964
8615
  "div",
8965
8616
  {
8966
8617
  "data-ohw-drag-handle-container": "",
@@ -8972,7 +8623,7 @@ function EditGlowChrome({
8972
8623
  transform: "translate(calc(-100% - 7px), -50%)",
8973
8624
  pointerEvents: dragDisabled ? "none" : "auto"
8974
8625
  },
8975
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
8626
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
8976
8627
  DragHandle,
8977
8628
  {
8978
8629
  "aria-label": `Reorder ${reorderHrefKey}`,
@@ -9182,7 +8833,7 @@ function FloatingToolbar({
9182
8833
  return () => ro.disconnect();
9183
8834
  }, [showEditLink, activeCommands]);
9184
8835
  const { top, left, transform } = calcToolbarPos(rect, parentScroll, measuredW);
9185
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
8836
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
9186
8837
  "div",
9187
8838
  {
9188
8839
  ref: setRefs,
@@ -9194,12 +8845,12 @@ function FloatingToolbar({
9194
8845
  zIndex: 2147483647,
9195
8846
  pointerEvents: "auto"
9196
8847
  },
9197
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(CustomToolbar, { children: [
9198
- TOOLBAR_GROUPS.map((btns, gi) => /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(import_react9.default.Fragment, { children: [
9199
- gi > 0 && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(CustomToolbarDivider, {}),
8848
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(CustomToolbar, { children: [
8849
+ TOOLBAR_GROUPS.map((btns, gi) => /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_react9.default.Fragment, { children: [
8850
+ gi > 0 && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(CustomToolbarDivider, {}),
9200
8851
  btns.map((btn) => {
9201
8852
  const isActive = activeCommands.has(btn.cmd);
9202
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
8853
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
9203
8854
  CustomToolbarButton,
9204
8855
  {
9205
8856
  title: btn.title,
@@ -9208,7 +8859,7 @@ function FloatingToolbar({
9208
8859
  e.preventDefault();
9209
8860
  onCommand(btn.cmd);
9210
8861
  },
9211
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
8862
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
9212
8863
  "svg",
9213
8864
  {
9214
8865
  width: "16",
@@ -9229,7 +8880,7 @@ function FloatingToolbar({
9229
8880
  );
9230
8881
  })
9231
8882
  ] }, gi)),
9232
- showEditLink ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
8883
+ showEditLink ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
9233
8884
  CustomToolbarButton,
9234
8885
  {
9235
8886
  type: "button",
@@ -9243,7 +8894,7 @@ function FloatingToolbar({
9243
8894
  e.preventDefault();
9244
8895
  e.stopPropagation();
9245
8896
  },
9246
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_lucide_react12.Link, { className: "size-4 shrink-0", "aria-hidden": true })
8897
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_lucide_react11.Link, { className: "size-4 shrink-0", "aria-hidden": true })
9247
8898
  }
9248
8899
  ) : null
9249
8900
  ] })
@@ -9260,7 +8911,7 @@ function StateToggle({
9260
8911
  states,
9261
8912
  onStateChange
9262
8913
  }) {
9263
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
8914
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
9264
8915
  ToggleGroup,
9265
8916
  {
9266
8917
  "data-ohw-state-toggle": "",
@@ -9274,7 +8925,7 @@ function StateToggle({
9274
8925
  left: rect.right - 8,
9275
8926
  transform: "translateX(-100%)"
9276
8927
  },
9277
- children: states.map((state) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(ToggleGroupItem, { value: state, size: "sm", children: state }, state))
8928
+ children: states.map((state) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ToggleGroupItem, { value: state, size: "sm", children: state }, state))
9278
8929
  }
9279
8930
  );
9280
8931
  }
@@ -9770,18 +9421,6 @@ function OhhwellsBridge() {
9770
9421
  intent: "add-nav"
9771
9422
  });
9772
9423
  }, []);
9773
- const handleAddFooterColumn = (0, import_react9.useCallback)(() => {
9774
- deselectRef.current();
9775
- deactivateRef.current();
9776
- const result = addFooterColumnWithPersist({ postToParent: postToParent2 });
9777
- editContentRef.current = {
9778
- ...editContentRef.current,
9779
- ...buildFooterColumnEditContentPatch(result)
9780
- };
9781
- requestAnimationFrame(() => {
9782
- selectRef.current(result.firstLink);
9783
- });
9784
- }, [postToParent2]);
9785
9424
  const clearFooterDragVisuals = (0, import_react9.useCallback)(() => {
9786
9425
  footerDragRef.current = null;
9787
9426
  setSiblingHintRects([]);
@@ -10106,7 +9745,7 @@ function OhhwellsBridge() {
10106
9745
  const selectFrame = (0, import_react9.useCallback)((el) => {
10107
9746
  if (!isNavigationContainer(el)) return;
10108
9747
  if (activeElRef.current) deactivate();
10109
- const isFooterColumn = !isFooterLinksContainer(el) && (el.hasAttribute("data-ohw-footer-col") || Boolean(el.closest("footer") && isInferredFooterGroup(el)));
9748
+ const isFooterColumn = el.hasAttribute("data-ohw-footer-col") || Boolean(el.closest("footer") && isInferredFooterGroup(el));
10110
9749
  selectedElRef.current = el;
10111
9750
  selectedHrefKeyRef.current = null;
10112
9751
  selectedFooterColAttrRef.current = isFooterColumn ? el.getAttribute("data-ohw-footer-col") ?? String(listFooterColumns().indexOf(el)) : null;
@@ -10662,7 +10301,7 @@ function OhhwellsBridge() {
10662
10301
  }
10663
10302
  e.preventDefault();
10664
10303
  e.stopPropagation();
10665
- activateRef.current(editable, { caretX: e.clientX, caretY: e.clientY });
10304
+ activateRef.current(editable);
10666
10305
  return;
10667
10306
  }
10668
10307
  const hrefAnchor = getNavigationItemAnchor(target);
@@ -10689,18 +10328,6 @@ function OhhwellsBridge() {
10689
10328
  selectFrameRef.current(footerColClick);
10690
10329
  return;
10691
10330
  }
10692
- const footerLinksToSelect = resolveFooterLinksContainerSelectionTarget(
10693
- target,
10694
- e.clientX,
10695
- e.clientY,
10696
- isPointOverNavItem
10697
- );
10698
- if (footerLinksToSelect) {
10699
- e.preventDefault();
10700
- e.stopPropagation();
10701
- selectFrameRef.current(footerLinksToSelect);
10702
- return;
10703
- }
10704
10331
  const navContainerToSelect = resolveNavContainerSelectionTarget(target, e.clientX, e.clientY);
10705
10332
  if (navContainerToSelect) {
10706
10333
  e.preventDefault();
@@ -10759,8 +10386,8 @@ function OhhwellsBridge() {
10759
10386
  return;
10760
10387
  }
10761
10388
  const navLabel = getNavigationLabelEditable(target);
10762
- const editable = navLabel?.editable ?? target.closest('[data-ohw-editable="text"], [data-ohw-editable="plain"]');
10763
- if (!editable || isMediaEditable(editable) || editable.dataset.ohwEditable === "link") return;
10389
+ if (!navLabel) return;
10390
+ const { editable } = navLabel;
10764
10391
  e.preventDefault();
10765
10392
  e.stopPropagation();
10766
10393
  if (activeElRef.current !== editable) {
@@ -10781,38 +10408,16 @@ function OhhwellsBridge() {
10781
10408
  setHoveredNavContainerRect(null);
10782
10409
  return;
10783
10410
  }
10784
- {
10785
- const selected2 = selectedElRef.current;
10786
- const selectedIsFooterColumn = Boolean(selected2) && !isFooterLinksContainer(selected2) && (selected2.hasAttribute("data-ohw-footer-col") || selected2.hasAttribute("data-ohw-footer-column") || Boolean(selected2.closest("footer") && isInferredFooterGroup(selected2)));
10787
- const allowNavContainerHover = toolbarVariantRef.current !== "select-frame";
10788
- const allowFooterLinksHover = toolbarVariantRef.current !== "select-frame" || selectedIsFooterColumn;
10789
- if (allowNavContainerHover) {
10790
- const navContainer = target.closest("[data-ohw-nav-container]");
10791
- if (navContainer && !getNavigationItemAnchor(target)) {
10792
- hoveredNavContainerRef.current = navContainer;
10793
- setHoveredNavContainerRect(navContainer.getBoundingClientRect());
10794
- hoveredItemElRef.current = null;
10795
- setHoveredItemRect(null);
10796
- return;
10797
- }
10411
+ if (toolbarVariantRef.current !== "select-frame") {
10412
+ const navContainer = target.closest("[data-ohw-nav-container]");
10413
+ if (navContainer && !getNavigationItemAnchor(target)) {
10414
+ hoveredNavContainerRef.current = navContainer;
10415
+ setHoveredNavContainerRect(navContainer.getBoundingClientRect());
10416
+ hoveredItemElRef.current = null;
10417
+ setHoveredItemRect(null);
10418
+ return;
10798
10419
  }
10799
- if (allowFooterLinksHover) {
10800
- const navContainer = target.closest("[data-ohw-nav-container]");
10801
- if (!navContainer) {
10802
- const footerLinks = target.closest("[data-ohw-footer-links], .rb-footer-links") ?? null;
10803
- if (footerLinks && selected2 !== footerLinks && !getNavigationItemAnchor(target) && !target.closest("[data-ohw-footer-col], [data-ohw-footer-column]")) {
10804
- hoveredNavContainerRef.current = footerLinks;
10805
- setHoveredNavContainerRect(footerLinks.getBoundingClientRect());
10806
- hoveredItemElRef.current = null;
10807
- setHoveredItemRect(null);
10808
- return;
10809
- }
10810
- if (!footerLinks) {
10811
- hoveredNavContainerRef.current = null;
10812
- setHoveredNavContainerRect(null);
10813
- }
10814
- }
10815
- } else if (toolbarVariantRef.current === "select-frame") {
10420
+ if (!target.closest("[data-ohw-nav-container]")) {
10816
10421
  hoveredNavContainerRef.current = null;
10817
10422
  setHoveredNavContainerRect(null);
10818
10423
  }
@@ -10854,9 +10459,9 @@ function OhhwellsBridge() {
10854
10459
  };
10855
10460
  const handleMouseOut = (e) => {
10856
10461
  const target = e.target;
10857
- if (target.closest("[data-ohw-nav-container], [data-ohw-footer-col], [data-ohw-footer-column], [data-ohw-footer-links], .rb-footer-links")) {
10462
+ if (target.closest("[data-ohw-nav-container], [data-ohw-footer-col], [data-ohw-footer-column]")) {
10858
10463
  const related2 = e.relatedTarget instanceof Element ? e.relatedTarget : null;
10859
- if (related2?.closest("[data-ohw-nav-container], [data-ohw-footer-col], [data-ohw-footer-column], [data-ohw-footer-links], .rb-footer-links, [data-ohw-navbar-container-chrome], [data-ohw-navbar-add-button], [data-ohw-footer-container-chrome], [data-ohw-footer-add-button]")) {
10464
+ if (related2?.closest("[data-ohw-nav-container], [data-ohw-footer-col], [data-ohw-footer-column], [data-ohw-navbar-container-chrome], [data-ohw-navbar-add-button]")) {
10860
10465
  return;
10861
10466
  }
10862
10467
  hoveredNavContainerRef.current = null;
@@ -10951,15 +10556,6 @@ function OhhwellsBridge() {
10951
10556
  if (track) track.setAttribute("data-ohw-hover-paused", "");
10952
10557
  };
10953
10558
  const clearImageHover = () => setMediaHover(null);
10954
- const dismissImageHover = () => {
10955
- if (hoveredImageRef.current) {
10956
- hoveredImageRef.current = null;
10957
- hoveredImageHasTextOverlapRef.current = false;
10958
- resumeAnimTracks();
10959
- postToParentRef.current({ type: "ow:image-unhover" });
10960
- }
10961
- clearImageHover();
10962
- };
10963
10559
  const findImageAtPoint = (clientX, clientY, fromParentViewport) => {
10964
10560
  const { x, y } = toProbeCoords(clientX, clientY, fromParentViewport);
10965
10561
  const images = Array.from(document.querySelectorAll(MEDIA_SELECTOR));
@@ -11003,13 +10599,16 @@ function OhhwellsBridge() {
11003
10599
  }
11004
10600
  return smallest;
11005
10601
  };
10602
+ const dismissImageHover = () => {
10603
+ if (hoveredImageRef.current) {
10604
+ hoveredImageRef.current = null;
10605
+ hoveredImageHasTextOverlapRef.current = false;
10606
+ resumeAnimTracks();
10607
+ postToParentRef.current({ type: "ow:image-unhover" });
10608
+ }
10609
+ };
11006
10610
  const probeNavigationHoverAt = (x, y) => {
11007
- const selected = selectedElRef.current;
11008
- const selectedIsFooterColumn = Boolean(selected) && !isFooterLinksContainer(selected) && (selected.hasAttribute("data-ohw-footer-col") || selected.hasAttribute("data-ohw-footer-column") || Boolean(selected.closest("footer") && isInferredFooterGroup(selected)));
11009
- const selectedIsFooterLinks = Boolean(selected && isFooterLinksContainer(selected));
11010
- const allowNavContainerHover = toolbarVariantRef.current !== "select-frame";
11011
- const allowFooterLinksHover = (toolbarVariantRef.current !== "select-frame" || selectedIsFooterColumn) && !selectedIsFooterLinks;
11012
- if (toolbarVariantRef.current === "select-frame" && !allowFooterLinksHover) {
10611
+ if (toolbarVariantRef.current === "select-frame") {
11013
10612
  hoveredNavContainerRef.current = null;
11014
10613
  setHoveredNavContainerRect(null);
11015
10614
  }
@@ -11031,6 +10630,7 @@ function OhhwellsBridge() {
11031
10630
  if (navItemHit) {
11032
10631
  hoveredNavContainerRef.current = null;
11033
10632
  setHoveredNavContainerRect(null);
10633
+ const selected = selectedElRef.current;
11034
10634
  if (selected !== navItemHit) {
11035
10635
  clearHrefKeyHover(navItemHit);
11036
10636
  hoveredItemElRef.current = navItemHit;
@@ -11042,7 +10642,7 @@ function OhhwellsBridge() {
11042
10642
  return;
11043
10643
  }
11044
10644
  }
11045
- if (allowNavContainerHover) {
10645
+ if (toolbarVariantRef.current !== "select-frame") {
11046
10646
  for (const container of navContainers) {
11047
10647
  const containerRect = container.getBoundingClientRect();
11048
10648
  const overContainer = x >= containerRect.left && x <= containerRect.right && y >= containerRect.top && y <= containerRect.bottom;
@@ -11054,23 +10654,12 @@ function OhhwellsBridge() {
11054
10654
  setHoveredItemRect(null);
11055
10655
  return;
11056
10656
  }
10657
+ hoveredNavContainerRef.current = null;
10658
+ setHoveredNavContainerRect(null);
10659
+ } else {
10660
+ hoveredNavContainerRef.current = null;
10661
+ setHoveredNavContainerRect(null);
11057
10662
  }
11058
- if (allowFooterLinksHover) {
11059
- const footerLinks = getFooterLinksContainer();
11060
- if (footerLinks) {
11061
- const containerRect = footerLinks.getBoundingClientRect();
11062
- const overContainer = x >= containerRect.left && x <= containerRect.right && y >= containerRect.top && y <= containerRect.bottom;
11063
- if (overContainer && !isPointOverNavItem(footerLinks, x, y) && !isPointOverFooterColumn(x, y)) {
11064
- hoveredNavContainerRef.current = footerLinks;
11065
- setHoveredNavContainerRect(footerLinks.getBoundingClientRect());
11066
- hoveredItemElRef.current = null;
11067
- setHoveredItemRect(null);
11068
- return;
11069
- }
11070
- }
11071
- }
11072
- hoveredNavContainerRef.current = null;
11073
- setHoveredNavContainerRect(null);
11074
10663
  for (const column of footerColumns) {
11075
10664
  const containerRect = column.getBoundingClientRect();
11076
10665
  const overContainer = x >= containerRect.left && x <= containerRect.right && y >= containerRect.top && y <= containerRect.bottom;
@@ -11577,7 +11166,6 @@ function OhhwellsBridge() {
11577
11166
  }
11578
11167
  editContentRef.current = { ...editContentRef.current, ...content };
11579
11168
  reconcileNavbarItemsFromContent(editContentRef.current);
11580
- reconcileFooterOrderFromContent(editContentRef.current);
11581
11169
  syncNavigationDragCursorAttrs();
11582
11170
  enforceLinkHrefs();
11583
11171
  postToParentRef.current({ type: "ow:hydrate-done" });
@@ -11632,11 +11220,6 @@ function OhhwellsBridge() {
11632
11220
  }
11633
11221
  if (selectedElRef.current) {
11634
11222
  if (toolbarVariantRef.current === "select-frame") {
11635
- const parent2 = getNavigationSelectionParent(selectedElRef.current);
11636
- if (parent2 && isNavigationContainer(parent2) && isFooterLinksContainer(parent2) && !isFooterLinksContainer(selectedElRef.current)) {
11637
- selectFrameRef.current(parent2);
11638
- return;
11639
- }
11640
11223
  deselectRef.current();
11641
11224
  return;
11642
11225
  }
@@ -11652,10 +11235,13 @@ function OhhwellsBridge() {
11652
11235
  const handleKeyDown = (e) => {
11653
11236
  if (e.key === "Escape" && document.querySelector("[data-ohw-section-picker]")) return;
11654
11237
  if ((e.ctrlKey || e.metaKey) && e.key.toLowerCase() === "a" && activeElRef.current) {
11655
- e.preventDefault();
11656
- selectAllTextInEditable(activeElRef.current);
11657
- refreshActiveCommandsRef.current();
11658
- return;
11238
+ const navAnchor = getNavigationItemAnchor(activeElRef.current);
11239
+ if (navAnchor) {
11240
+ e.preventDefault();
11241
+ selectAllTextInEditable(activeElRef.current);
11242
+ refreshActiveCommandsRef.current();
11243
+ return;
11244
+ }
11659
11245
  }
11660
11246
  if (e.key === "Escape" && linkPopoverOpenRef.current) {
11661
11247
  setLinkPopoverRef.current(null);
@@ -11663,12 +11249,6 @@ function OhhwellsBridge() {
11663
11249
  }
11664
11250
  if (e.key === "Escape" && selectedElRef.current && !activeElRef.current) {
11665
11251
  if (toolbarVariantRef.current === "select-frame") {
11666
- const parent2 = getNavigationSelectionParent(selectedElRef.current);
11667
- if (parent2 && isNavigationContainer(parent2) && isFooterLinksContainer(parent2) && !isFooterLinksContainer(selectedElRef.current)) {
11668
- e.preventDefault();
11669
- selectFrameRef.current(parent2);
11670
- return;
11671
- }
11672
11252
  deselectRef.current();
11673
11253
  return;
11674
11254
  }
@@ -12455,9 +12035,9 @@ function OhhwellsBridge() {
12455
12035
  [postToParent2]
12456
12036
  );
12457
12037
  return bridgeRoot ? (0, import_react_dom3.createPortal)(
12458
- /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(import_jsx_runtime25.Fragment, { children: [
12459
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { ref: attachVisibleViewport, "data-ohw-visible-viewport": "", "aria-hidden": true }),
12460
- Object.entries(uploadingRects).map(([key, { rect, fadingOut }]) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12038
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [
12039
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { ref: attachVisibleViewport, "data-ohw-visible-viewport": "", "aria-hidden": true }),
12040
+ Object.entries(uploadingRects).map(([key, { rect, fadingOut }]) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12461
12041
  MediaOverlay,
12462
12042
  {
12463
12043
  hover: { key, rect, elementType: "image", isDragOver: false, hasTextOverlap: false },
@@ -12468,7 +12048,7 @@ function OhhwellsBridge() {
12468
12048
  },
12469
12049
  `uploading-${key}`
12470
12050
  )),
12471
- mediaHover && !(mediaHover.key in uploadingRects) && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12051
+ mediaHover && !(mediaHover.key in uploadingRects) && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12472
12052
  MediaOverlay,
12473
12053
  {
12474
12054
  hover: mediaHover,
@@ -12477,10 +12057,10 @@ function OhhwellsBridge() {
12477
12057
  onVideoSettingsChange: handleVideoSettingsChange
12478
12058
  }
12479
12059
  ),
12480
- siblingHintRect && !linkPopover && !isItemDragging && siblingHintRects.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(ItemInteractionLayer, { rect: siblingHintRect, state: "sibling-hint" }),
12481
- siblingHintRects.length > 0 && !linkPopover && !isItemDragging && siblingHintRects.map((rect, i) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(ItemInteractionLayer, { rect, state: "sibling-hint" }, `sibling-hint-${i}`)),
12482
- isItemDragging && draggedItemRect && selectedElRef.current !== footerDragRef.current?.draggedEl && selectedElRef.current !== navDragRef.current?.draggedEl && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(ItemInteractionLayer, { rect: draggedItemRect, state: "dragging" }),
12483
- isItemDragging && footerDropSlots.map((slot, i) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12060
+ siblingHintRect && !linkPopover && !isItemDragging && siblingHintRects.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ItemInteractionLayer, { rect: siblingHintRect, state: "sibling-hint" }),
12061
+ siblingHintRects.length > 0 && !linkPopover && !isItemDragging && siblingHintRects.map((rect, i) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ItemInteractionLayer, { rect, state: "sibling-hint" }, `sibling-hint-${i}`)),
12062
+ isItemDragging && draggedItemRect && selectedElRef.current !== footerDragRef.current?.draggedEl && selectedElRef.current !== navDragRef.current?.draggedEl && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ItemInteractionLayer, { rect: draggedItemRect, state: "dragging" }),
12063
+ isItemDragging && footerDropSlots.map((slot, i) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12484
12064
  "div",
12485
12065
  {
12486
12066
  className: "pointer-events-none fixed z-2147483646",
@@ -12490,7 +12070,7 @@ function OhhwellsBridge() {
12490
12070
  width: slot.width,
12491
12071
  height: slot.height
12492
12072
  },
12493
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12073
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12494
12074
  DropIndicator,
12495
12075
  {
12496
12076
  direction: slot.direction,
@@ -12501,7 +12081,7 @@ function OhhwellsBridge() {
12501
12081
  },
12502
12082
  `footer-drop-${slot.direction}-${slot.columnIndex}-${slot.insertIndex}-${i}`
12503
12083
  )),
12504
- isItemDragging && navDropSlots.map((slot, i) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12084
+ isItemDragging && navDropSlots.map((slot, i) => /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12505
12085
  "div",
12506
12086
  {
12507
12087
  className: "pointer-events-none fixed z-2147483646",
@@ -12511,7 +12091,7 @@ function OhhwellsBridge() {
12511
12091
  width: slot.width,
12512
12092
  height: slot.height
12513
12093
  },
12514
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12094
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12515
12095
  DropIndicator,
12516
12096
  {
12517
12097
  direction: slot.direction,
@@ -12522,11 +12102,10 @@ function OhhwellsBridge() {
12522
12102
  },
12523
12103
  `nav-drop-${slot.direction}-${slot.parentId ?? "root"}-${slot.insertIndex}-${i}`
12524
12104
  )),
12525
- hoveredNavContainerRect && (toolbarVariant !== "select-frame" || isFooterFrameSelection) && !linkPopover && !isItemDragging && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(ItemInteractionLayer, { rect: hoveredNavContainerRect, state: "hover" }),
12526
- hoveredItemRect && !linkPopover && !hoveredNavContainerRect && !isItemDragging && hoveredItemElRef.current !== selectedElRef.current && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(ItemInteractionLayer, { rect: hoveredItemRect, state: "hover" }),
12527
- toolbarVariant === "select-frame" && toolbarRect && !linkPopover && !isItemDragging && !isFooterFrameSelection && selectedElRef.current && isNavbarLinksContainer(selectedElRef.current) && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(NavbarContainerChrome, { rect: toolbarRect, onAdd: handleAddTopLevelNavItem }),
12528
- toolbarVariant === "select-frame" && toolbarRect && !linkPopover && !isItemDragging && !isFooterFrameSelection && selectedElRef.current && isFooterLinksContainer(selectedElRef.current) && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(FooterContainerChrome, { rect: toolbarRect, onAdd: handleAddFooterColumn }),
12529
- toolbarRect && !linkPopover && (toolbarVariant === "link-action" || toolbarVariant === "select-frame") && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12105
+ hoveredNavContainerRect && toolbarVariant !== "select-frame" && !linkPopover && !isItemDragging && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ItemInteractionLayer, { rect: hoveredNavContainerRect, state: "hover" }),
12106
+ hoveredItemRect && !linkPopover && !hoveredNavContainerRect && !isItemDragging && hoveredItemElRef.current !== selectedElRef.current && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ItemInteractionLayer, { rect: hoveredItemRect, state: "hover" }),
12107
+ toolbarVariant === "select-frame" && toolbarRect && !linkPopover && !isItemDragging && !isFooterFrameSelection && selectedElRef.current && isNavbarLinksContainer(selectedElRef.current) && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(NavbarContainerChrome, { rect: toolbarRect, onAdd: handleAddTopLevelNavItem }),
12108
+ toolbarRect && !linkPopover && (toolbarVariant === "link-action" || toolbarVariant === "select-frame") && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12530
12109
  ItemInteractionLayer,
12531
12110
  {
12532
12111
  rect: isItemDragging && draggedItemRect && (footerDragRef.current?.wasSelected || navDragRef.current?.wasSelected) ? draggedItemRect : toolbarRect,
@@ -12540,7 +12119,7 @@ function OhhwellsBridge() {
12540
12119
  onItemPointerDown: handleItemChromePointerDown,
12541
12120
  onItemClick: handleItemChromeClick,
12542
12121
  itemDragSurface: !isFooterFrameSelection,
12543
- toolbar: toolbarVariant === "link-action" && !isItemDragging ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12122
+ toolbar: toolbarVariant === "link-action" && !isItemDragging ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12544
12123
  ItemActionToolbar,
12545
12124
  {
12546
12125
  onEditLink: openLinkPopoverForSelected,
@@ -12553,8 +12132,8 @@ function OhhwellsBridge() {
12553
12132
  ) : void 0
12554
12133
  }
12555
12134
  ),
12556
- toolbarRect && toolbarVariant === "rich-text" && !linkPopover && /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(import_jsx_runtime25.Fragment, { children: [
12557
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12135
+ toolbarRect && toolbarVariant === "rich-text" && !linkPopover && /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [
12136
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12558
12137
  EditGlowChrome,
12559
12138
  {
12560
12139
  rect: toolbarRect,
@@ -12564,7 +12143,7 @@ function OhhwellsBridge() {
12564
12143
  hideHandle: isItemDragging
12565
12144
  }
12566
12145
  ),
12567
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12146
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12568
12147
  FloatingToolbar,
12569
12148
  {
12570
12149
  rect: toolbarRect,
@@ -12577,7 +12156,7 @@ function OhhwellsBridge() {
12577
12156
  }
12578
12157
  )
12579
12158
  ] }),
12580
- maxBadge && /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
12159
+ maxBadge && /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
12581
12160
  "div",
12582
12161
  {
12583
12162
  "data-ohw-max-badge": "",
@@ -12603,7 +12182,7 @@ function OhhwellsBridge() {
12603
12182
  ]
12604
12183
  }
12605
12184
  ),
12606
- toggleState && !linkPopover && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12185
+ toggleState && !linkPopover && /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12607
12186
  StateToggle,
12608
12187
  {
12609
12188
  rect: toggleState.rect,
@@ -12612,15 +12191,15 @@ function OhhwellsBridge() {
12612
12191
  onStateChange: handleStateChange
12613
12192
  }
12614
12193
  ),
12615
- sectionGap && !linkPopover && /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
12194
+ sectionGap && !linkPopover && /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(
12616
12195
  "div",
12617
12196
  {
12618
12197
  "data-ohw-section-insert-line": "",
12619
12198
  className: "fixed left-0 w-full z-2147483646 flex items-center pointer-events-none",
12620
12199
  style: { top: sectionGap.y, transform: "translateY(-50%)" },
12621
12200
  children: [
12622
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: "flex-1 bg-primary", style: { height: 3 } }),
12623
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12201
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "flex-1 bg-primary", style: { height: 3 } }),
12202
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12624
12203
  Badge,
12625
12204
  {
12626
12205
  className: "px-8 py-1 bg-primary hover:bg-primary text-primary-foreground text-xs font-medium shrink-0 rounded-full cursor-pointer pointer-events-auto",
@@ -12637,11 +12216,11 @@ function OhhwellsBridge() {
12637
12216
  children: "Add Section"
12638
12217
  }
12639
12218
  ),
12640
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: "flex-1 bg-primary", style: { height: 3 } })
12219
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "flex-1 bg-primary", style: { height: 3 } })
12641
12220
  ]
12642
12221
  }
12643
12222
  ),
12644
- linkPopover && dialogPortalContainer ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
12223
+ linkPopover && dialogPortalContainer ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
12645
12224
  LinkPopover,
12646
12225
  {
12647
12226
  panelRef: linkPopoverPanelRef,