@flamingo-stack/openframe-frontend-core 0.0.519 → 0.0.520

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.
Files changed (93) hide show
  1. package/dist/{chunk-QQZWLTYU.cjs → chunk-2HL3BXWV.cjs} +4 -4
  2. package/dist/{chunk-QQZWLTYU.cjs.map → chunk-2HL3BXWV.cjs.map} +1 -1
  3. package/dist/{chunk-HWA3NZPK.js → chunk-2Y4REKE5.js} +2 -2
  4. package/dist/{chunk-ZGGI4XMF.cjs → chunk-37OBDW56.cjs} +9 -9
  5. package/dist/{chunk-ZGGI4XMF.cjs.map → chunk-37OBDW56.cjs.map} +1 -1
  6. package/dist/{chunk-QEGGWVFV.cjs → chunk-4NEP3KY7.cjs} +26 -26
  7. package/dist/{chunk-QEGGWVFV.cjs.map → chunk-4NEP3KY7.cjs.map} +1 -1
  8. package/dist/{chunk-HVXGSQ4V.js → chunk-5PT2RQRU.js} +6 -6
  9. package/dist/{chunk-6FLRFCK4.cjs → chunk-5ZQKEGL3.cjs} +870 -796
  10. package/dist/chunk-5ZQKEGL3.cjs.map +1 -0
  11. package/dist/{chunk-ZA5PFNHR.js → chunk-AQHR5D7X.js} +324 -250
  12. package/dist/chunk-AQHR5D7X.js.map +1 -0
  13. package/dist/{chunk-BUZOZOQ2.js → chunk-DMITCSFH.js} +2 -2
  14. package/dist/{chunk-VH7BOHRG.js → chunk-HI3TQS4D.js} +2 -2
  15. package/dist/{chunk-S4OAWVKF.js → chunk-JKICCXLC.js} +2 -2
  16. package/dist/{chunk-QGLEI6T2.cjs → chunk-JZC5BBAF.cjs} +5 -5
  17. package/dist/{chunk-QGLEI6T2.cjs.map → chunk-JZC5BBAF.cjs.map} +1 -1
  18. package/dist/{chunk-JMGVYERE.js → chunk-LB66ECD7.js} +2 -2
  19. package/dist/{chunk-MEWHQVOU.js → chunk-P7AQ5XKO.js} +2 -2
  20. package/dist/{chunk-5PMRHRMM.cjs → chunk-PA6L55NF.cjs} +14 -14
  21. package/dist/{chunk-5PMRHRMM.cjs.map → chunk-PA6L55NF.cjs.map} +1 -1
  22. package/dist/{chunk-YACGPO7I.js → chunk-QICUWGET.js} +2 -2
  23. package/dist/{chunk-OBJSXQ67.cjs → chunk-R3Y65KPT.cjs} +3 -3
  24. package/dist/{chunk-OBJSXQ67.cjs.map → chunk-R3Y65KPT.cjs.map} +1 -1
  25. package/dist/{chunk-FWCENA3G.cjs → chunk-RRCSGTT5.cjs} +31 -31
  26. package/dist/{chunk-FWCENA3G.cjs.map → chunk-RRCSGTT5.cjs.map} +1 -1
  27. package/dist/{chunk-SAPKMN4W.js → chunk-RT4IGTJ6.js} +2 -2
  28. package/dist/{chunk-UBT2KBK7.js → chunk-RTJ6Q7JA.js} +5 -5
  29. package/dist/{chunk-KCDKQXE5.cjs → chunk-S5HO5E6R.cjs} +7 -7
  30. package/dist/{chunk-KCDKQXE5.cjs.map → chunk-S5HO5E6R.cjs.map} +1 -1
  31. package/dist/{chunk-CCK2MFIQ.cjs → chunk-SVYXGHJG.cjs} +26 -26
  32. package/dist/{chunk-CCK2MFIQ.cjs.map → chunk-SVYXGHJG.cjs.map} +1 -1
  33. package/dist/{chunk-BFCBR277.cjs → chunk-TRIU3RJD.cjs} +11 -11
  34. package/dist/{chunk-BFCBR277.cjs.map → chunk-TRIU3RJD.cjs.map} +1 -1
  35. package/dist/{chunk-GLFQSFYV.cjs → chunk-UDPOAWKH.cjs} +61 -61
  36. package/dist/{chunk-GLFQSFYV.cjs.map → chunk-UDPOAWKH.cjs.map} +1 -1
  37. package/dist/{chunk-CRJRVUWB.js → chunk-UOMUR62H.js} +2 -2
  38. package/dist/{chunk-OQHHJDUB.js → chunk-W3UAL5GU.js} +4 -4
  39. package/dist/{chunk-6WQN7NLD.js → chunk-Y43UWXF7.js} +4 -4
  40. package/dist/{chunk-WEPJKF65.cjs → chunk-YD7JM53S.cjs} +37 -37
  41. package/dist/{chunk-WEPJKF65.cjs.map → chunk-YD7JM53S.cjs.map} +1 -1
  42. package/dist/{chunk-V3MAG3G5.cjs → chunk-YPHKO6C5.cjs} +87 -87
  43. package/dist/{chunk-V3MAG3G5.cjs.map → chunk-YPHKO6C5.cjs.map} +1 -1
  44. package/dist/components/case-studies/index.cjs +8 -8
  45. package/dist/components/case-studies/index.js +2 -2
  46. package/dist/components/chat/index.cjs +2 -2
  47. package/dist/components/chat/index.js +1 -1
  48. package/dist/components/contact/index.cjs +3 -3
  49. package/dist/components/contact/index.js +2 -2
  50. package/dist/components/docs/index.cjs +5 -5
  51. package/dist/components/docs/index.js +4 -4
  52. package/dist/components/embeds/index.cjs +3 -3
  53. package/dist/components/embeds/index.js +2 -2
  54. package/dist/components/faq/index.cjs +3 -3
  55. package/dist/components/faq/index.js +2 -2
  56. package/dist/components/features/index.cjs +2 -2
  57. package/dist/components/features/index.js +1 -1
  58. package/dist/components/help-center-pages/index.cjs +22 -22
  59. package/dist/components/help-center-pages/index.js +13 -13
  60. package/dist/components/index.cjs +132 -132
  61. package/dist/components/index.js +11 -11
  62. package/dist/components/meeting-scheduler/index.cjs +34 -34
  63. package/dist/components/meeting-scheduler/index.js +3 -3
  64. package/dist/components/navigation/index.cjs +2 -2
  65. package/dist/components/navigation/index.js +1 -1
  66. package/dist/components/onboarding-guides/index.cjs +5 -5
  67. package/dist/components/onboarding-guides/index.js +4 -4
  68. package/dist/components/related-content/index.cjs +3 -3
  69. package/dist/components/related-content/index.js +2 -2
  70. package/dist/components/tickets/index.cjs +6 -6
  71. package/dist/components/tickets/index.js +5 -5
  72. package/dist/components/ui/index.cjs +2 -2
  73. package/dist/components/ui/index.js +1 -1
  74. package/dist/components/ui/modal-v2.d.ts.map +1 -1
  75. package/dist/index.cjs +2 -2
  76. package/dist/index.js +1 -1
  77. package/package.json +1 -1
  78. package/src/components/ui/modal-v2.tsx +95 -1
  79. package/dist/chunk-6FLRFCK4.cjs.map +0 -1
  80. package/dist/chunk-ZA5PFNHR.js.map +0 -1
  81. /package/dist/{chunk-HWA3NZPK.js.map → chunk-2Y4REKE5.js.map} +0 -0
  82. /package/dist/{chunk-HVXGSQ4V.js.map → chunk-5PT2RQRU.js.map} +0 -0
  83. /package/dist/{chunk-BUZOZOQ2.js.map → chunk-DMITCSFH.js.map} +0 -0
  84. /package/dist/{chunk-VH7BOHRG.js.map → chunk-HI3TQS4D.js.map} +0 -0
  85. /package/dist/{chunk-S4OAWVKF.js.map → chunk-JKICCXLC.js.map} +0 -0
  86. /package/dist/{chunk-JMGVYERE.js.map → chunk-LB66ECD7.js.map} +0 -0
  87. /package/dist/{chunk-MEWHQVOU.js.map → chunk-P7AQ5XKO.js.map} +0 -0
  88. /package/dist/{chunk-YACGPO7I.js.map → chunk-QICUWGET.js.map} +0 -0
  89. /package/dist/{chunk-SAPKMN4W.js.map → chunk-RT4IGTJ6.js.map} +0 -0
  90. /package/dist/{chunk-UBT2KBK7.js.map → chunk-RTJ6Q7JA.js.map} +0 -0
  91. /package/dist/{chunk-CRJRVUWB.js.map → chunk-UOMUR62H.js.map} +0 -0
  92. /package/dist/{chunk-OQHHJDUB.js.map → chunk-W3UAL5GU.js.map} +0 -0
  93. /package/dist/{chunk-6WQN7NLD.js.map → chunk-Y43UWXF7.js.map} +0 -0
@@ -10696,9 +10696,78 @@ init_cn();
10696
10696
  import { jsx as jsx55, jsxs as jsxs45 } from "react/jsx-runtime";
10697
10697
  var ANIMATION_DURATION = 200;
10698
10698
  var ModalContext = React26.createContext({});
10699
+ var modalStack = [];
10699
10700
  var Modal = React26.forwardRef(
10700
10701
  ({ isOpen, onClose, children, className }, ref) => {
10701
10702
  const [isMounted, setIsMounted] = useState21(isOpen);
10703
+ const panelRef = React26.useRef(null);
10704
+ const restoreFocusRef = React26.useRef(null);
10705
+ const stackIdRef = React26.useRef(/* @__PURE__ */ Symbol("modal"));
10706
+ useEffect15(() => {
10707
+ if (!isOpen) return;
10708
+ const stackId = stackIdRef.current;
10709
+ modalStack.push(stackId);
10710
+ restoreFocusRef.current = document.activeElement;
10711
+ const raf = requestAnimationFrame(() => {
10712
+ const panel = panelRef.current;
10713
+ if (!panel) return;
10714
+ if (panel.contains(document.activeElement)) return;
10715
+ panel.focus();
10716
+ });
10717
+ const containFocus = (event) => {
10718
+ if (modalStack[modalStack.length - 1] !== stackId) return;
10719
+ const panel = panelRef.current;
10720
+ if (!panel) return;
10721
+ const target = event.target;
10722
+ if (target && panel.contains(target)) return;
10723
+ panel.focus();
10724
+ };
10725
+ document.addEventListener("focusin", containFocus);
10726
+ const reasserts = [80, 240, 500].map(
10727
+ (ms) => setTimeout(() => {
10728
+ if (modalStack[modalStack.length - 1] !== stackId) return;
10729
+ const panel = panelRef.current;
10730
+ if (!panel) return;
10731
+ if (!panel.contains(document.activeElement)) panel.focus();
10732
+ }, ms)
10733
+ );
10734
+ return () => {
10735
+ cancelAnimationFrame(raf);
10736
+ reasserts.forEach(clearTimeout);
10737
+ document.removeEventListener("focusin", containFocus);
10738
+ const idx = modalStack.lastIndexOf(stackId);
10739
+ if (idx !== -1) modalStack.splice(idx, 1);
10740
+ restoreFocusRef.current?.focus?.();
10741
+ };
10742
+ }, [isOpen]);
10743
+ useEffect15(() => {
10744
+ if (!isOpen) return;
10745
+ const handleTab = (event) => {
10746
+ if (event.key !== "Tab") return;
10747
+ const panel = panelRef.current;
10748
+ if (!panel) return;
10749
+ const focusables = Array.from(
10750
+ panel.querySelectorAll(
10751
+ 'a[href], button:not([disabled]), input:not([disabled]):not([type="hidden"]), textarea:not([disabled]), select:not([disabled]), [tabindex]:not([tabindex="-1"])'
10752
+ )
10753
+ ).filter((el) => el.getAttribute("aria-hidden") !== "true" && el.offsetParent !== null);
10754
+ if (focusables.length === 0) return;
10755
+ const first = focusables[0];
10756
+ const last = focusables[focusables.length - 1];
10757
+ const active = document.activeElement;
10758
+ if (event.shiftKey) {
10759
+ if (active === first || !panel.contains(active)) {
10760
+ event.preventDefault();
10761
+ last.focus();
10762
+ }
10763
+ } else if (active === last || !panel.contains(active)) {
10764
+ event.preventDefault();
10765
+ first.focus();
10766
+ }
10767
+ };
10768
+ document.addEventListener("keydown", handleTab);
10769
+ return () => document.removeEventListener("keydown", handleTab);
10770
+ }, [isOpen]);
10702
10771
  useEffect15(() => {
10703
10772
  if (isOpen) {
10704
10773
  setIsMounted(true);
@@ -10743,7 +10812,12 @@ var Modal = React26.forwardRef(
10743
10812
  /* @__PURE__ */ jsx55(
10744
10813
  "div",
10745
10814
  {
10746
- ref,
10815
+ ref: (node) => {
10816
+ panelRef.current = node;
10817
+ if (typeof ref === "function") ref(node);
10818
+ else if (ref) ref.current = node;
10819
+ },
10820
+ tabIndex: -1,
10747
10821
  "data-state": state,
10748
10822
  className: cn(
10749
10823
  // min() keeps the desktop cap at 28rem while never letting content
@@ -11267,7 +11341,7 @@ function ChatPanelHeader({
11267
11341
  import * as React32 from "react";
11268
11342
 
11269
11343
  // src/components/chat/chat-attachment-bar.tsx
11270
- import { useEffect as useEffect18, useRef as useRef16, useState as useState24 } from "react";
11344
+ import { useEffect as useEffect18, useRef as useRef17, useState as useState24 } from "react";
11271
11345
  init_button2();
11272
11346
  init_cn();
11273
11347
 
@@ -11345,7 +11419,7 @@ function ChatAttachmentAddButton({
11345
11419
  disabled = false,
11346
11420
  size: size2 = "default"
11347
11421
  }) {
11348
- const fileInputRef = useRef16(null);
11422
+ const fileInputRef = useRef17(null);
11349
11423
  const compact = size2 === "compact";
11350
11424
  const boxClass = compact ? "h-6 w-6" : "h-7 w-7";
11351
11425
  if (!attachmentsEnabled) {
@@ -11498,7 +11572,7 @@ function useObjectUrl(file) {
11498
11572
  }
11499
11573
 
11500
11574
  // src/components/chat/chat-context-memory-bar.tsx
11501
- import { useEffect as useEffect19, useRef as useRef17, useState as useState25 } from "react";
11575
+ import { useEffect as useEffect19, useRef as useRef18, useState as useState25 } from "react";
11502
11576
  init_cn();
11503
11577
  import { jsx as jsx62, jsxs as jsxs51 } from "react/jsx-runtime";
11504
11578
  var itemKey3 = (item) => `${item.type}:${item.id}`;
@@ -11510,7 +11584,7 @@ function ChatContextMemoryBar({
11510
11584
  className
11511
11585
  }) {
11512
11586
  const [open, setOpen] = useState25(false);
11513
- const rootRef = useRef17(null);
11587
+ const rootRef = useRef18(null);
11514
11588
  useEffect19(() => {
11515
11589
  if (items.length === 0) setOpen(false);
11516
11590
  }, [items.length]);
@@ -12014,7 +12088,7 @@ function ChatArchivePage(props) {
12014
12088
  // src/components/chat/chat-sidebar.tsx
12015
12089
  init_cn();
12016
12090
  init_button2();
12017
- import { forwardRef as forwardRef22, useRef as useRef18, useEffect as useEffect20 } from "react";
12091
+ import { forwardRef as forwardRef22, useRef as useRef19, useEffect as useEffect20 } from "react";
12018
12092
 
12019
12093
  // src/components/chat/chat-sidebar-skeleton.tsx
12020
12094
  init_cn();
@@ -12130,11 +12204,11 @@ DialogListItem.displayName = "DialogListItem";
12130
12204
  var ChatSidebar = forwardRef22(
12131
12205
  ({ className, onNewChat, onDialogSelect, dialogs = [], activeDialogId, isLoading, isCreatingDialog, children, hasNextPage, isFetchingNextPage, onLoadMore, ...props }, ref) => {
12132
12206
  const showEmptyState = dialogs.length === 0 && !children;
12133
- const scrollContainerRef = useRef18(null);
12134
- const loadMoreRef = useRef18(null);
12135
- const onLoadMoreRef = useRef18(onLoadMore);
12207
+ const scrollContainerRef = useRef19(null);
12208
+ const loadMoreRef = useRef19(null);
12209
+ const onLoadMoreRef = useRef19(onLoadMore);
12136
12210
  onLoadMoreRef.current = onLoadMore;
12137
- const isFetchingRef = useRef18(isFetchingNextPage);
12211
+ const isFetchingRef = useRef19(isFetchingNextPage);
12138
12212
  isFetchingRef.current = isFetchingNextPage;
12139
12213
  useEffect20(() => {
12140
12214
  const scrollContainer = scrollContainerRef.current;
@@ -13278,7 +13352,7 @@ var TabsContent = React37.forwardRef(({ className, ...props }, ref) => /* @__PUR
13278
13352
  TabsContent.displayName = TabsPrimitive.Content.displayName;
13279
13353
 
13280
13354
  // src/components/features/video.tsx
13281
- import { useCallback as useCallback13, useEffect as useEffect24, useImperativeHandle as useImperativeHandle3, useMemo as useMemo19, useRef as useRef19, useState as useState29 } from "react";
13355
+ import { useCallback as useCallback13, useEffect as useEffect24, useImperativeHandle as useImperativeHandle3, useMemo as useMemo19, useRef as useRef20, useState as useState29 } from "react";
13282
13356
  import MuxPlayer from "@mux/mux-player-react";
13283
13357
 
13284
13358
  // src/components/features/video-center-badge.tsx
@@ -13639,9 +13713,9 @@ function FilePlayer({
13639
13713
  }) {
13640
13714
  const effectivePreload = preload ?? (saveDataEnabled() ? "none" : "metadata");
13641
13715
  const [hoverMutedFallback, setHoverMutedFallback] = useState29(false);
13642
- const hoverPlayerRef = useRef19(null);
13716
+ const hoverPlayerRef = useRef20(null);
13643
13717
  const [mutedFallbackBlocked, setMutedFallbackBlocked] = useState29(false);
13644
- const perfListenerRef = useRef19(null);
13718
+ const perfListenerRef = useRef20(null);
13645
13719
  const clearPerfListener = useCallback13(() => {
13646
13720
  if (perfListenerRef.current) {
13647
13721
  try {
@@ -13652,9 +13726,9 @@ function FilePlayer({
13652
13726
  }
13653
13727
  }, []);
13654
13728
  useEffect24(() => clearPerfListener, [clearPerfListener]);
13655
- const hoverActiveRef = useRef19(false);
13656
- const hoverGenerationRef = useRef19(0);
13657
- const activationWaiterRef = useRef19(null);
13729
+ const hoverActiveRef = useRef20(false);
13730
+ const hoverGenerationRef = useRef20(0);
13731
+ const activationWaiterRef = useRef20(null);
13658
13732
  const clearActivationWaiter = useCallback13(() => {
13659
13733
  if (activationWaiterRef.current) {
13660
13734
  activationWaiters.delete(activationWaiterRef.current);
@@ -13758,9 +13832,9 @@ function FilePlayer({
13758
13832
  }, [hoverControlled, playWhenHovered, startHoverPlayback, stopHoverPlayback]);
13759
13833
  const handleHoverEnter = playOnHover && !hoverControlled ? startHoverPlayback : void 0;
13760
13834
  const handleHoverLeave = playOnHover && !hoverControlled ? stopHoverPlayback : void 0;
13761
- const mutedIntentRef = useRef19(mutedIntent);
13835
+ const mutedIntentRef = useRef20(mutedIntent);
13762
13836
  mutedIntentRef.current = mutedIntent;
13763
- const onMutedFallbackChangeRef = useRef19(onMutedFallbackChange);
13837
+ const onMutedFallbackChangeRef = useRef20(onMutedFallbackChange);
13764
13838
  onMutedFallbackChangeRef.current = onMutedFallbackChange;
13765
13839
  useEffect24(() => {
13766
13840
  onMutedFallbackChangeRef.current?.({
@@ -13768,7 +13842,7 @@ function FilePlayer({
13768
13842
  blocked: hoverMutedFallback && mutedFallbackBlocked
13769
13843
  });
13770
13844
  }, [hoverMutedFallback, mutedFallbackBlocked]);
13771
- const autoPlayKickedRef = useRef19(false);
13845
+ const autoPlayKickedRef = useRef20(false);
13772
13846
  useEffect24(() => {
13773
13847
  if (autoPlayKickedRef.current) return;
13774
13848
  if (startMuted) {
@@ -13851,7 +13925,7 @@ function FilePlayer({
13851
13925
  }
13852
13926
  };
13853
13927
  }, []);
13854
- const onEndedRef = useRef19(onEnded);
13928
+ const onEndedRef = useRef20(onEnded);
13855
13929
  onEndedRef.current = onEnded;
13856
13930
  useEffect24(() => {
13857
13931
  const el = hoverPlayerRef.current;
@@ -14006,7 +14080,7 @@ function YouTubeFacadeInner({
14006
14080
  suspended
14007
14081
  }) {
14008
14082
  const [activated, setActivated] = useState29(Boolean(autoActivate));
14009
- const iframeRef = useRef19(null);
14083
+ const iframeRef = useRef20(null);
14010
14084
  const embedUrl = useMemo19(() => {
14011
14085
  const params = new URLSearchParams({
14012
14086
  autoplay: "1",
@@ -14079,7 +14153,7 @@ function YouTubeFacadeInner({
14079
14153
  if (blurTimer !== null) clearTimeout(blurTimer);
14080
14154
  };
14081
14155
  }, [activated]);
14082
- const prevSuspendedRef = useRef19(false);
14156
+ const prevSuspendedRef = useRef20(false);
14083
14157
  useEffect24(() => {
14084
14158
  const wasSuspended = prevSuspendedRef.current;
14085
14159
  prevSuspendedRef.current = Boolean(suspended);
@@ -14142,7 +14216,7 @@ import { useMemo as useMemo21, useState as useState32 } from "react";
14142
14216
 
14143
14217
  // src/components/features/video-hover-preview.tsx
14144
14218
  init_cn();
14145
- import { useEffect as useEffect25, useRef as useRef20, useState as useState30 } from "react";
14219
+ import { useEffect as useEffect25, useRef as useRef21, useState as useState30 } from "react";
14146
14220
  import { Fragment as Fragment21, jsx as jsx84, jsxs as jsxs65 } from "react/jsx-runtime";
14147
14221
  function VideoHoverPreviewSurface({
14148
14222
  url,
@@ -14167,7 +14241,7 @@ function VideoHoverPreviewSurface({
14167
14241
  }) {
14168
14242
  const previewUrl = toMuxPreviewUrl(url);
14169
14243
  const gateControlled = playerMounted !== void 0;
14170
- const rootElRef = useRef20(null);
14244
+ const rootElRef = useRef21(null);
14171
14245
  const [isNear, setIsNear] = useState30(false);
14172
14246
  useEffect25(() => {
14173
14247
  if (gateControlled) return;
@@ -14364,7 +14438,7 @@ function sortBitesByCreatedAtDesc(a, b) {
14364
14438
 
14365
14439
  // src/components/features/cards-strip.tsx
14366
14440
  init_cn();
14367
- import React41, { useCallback as useCallback14, useEffect as useEffect26, useMemo as useMemo20, useRef as useRef21, useState as useState31 } from "react";
14441
+ import React41, { useCallback as useCallback14, useEffect as useEffect26, useMemo as useMemo20, useRef as useRef22, useState as useState31 } from "react";
14368
14442
  init_button2();
14369
14443
 
14370
14444
  // src/components/layout/page-heading.tsx
@@ -14466,9 +14540,9 @@ function CardsStrip(props) {
14466
14540
  }
14467
14541
  return React41.isValidElement(item) && item.key != null ? String(item.key) : String(index);
14468
14542
  };
14469
- const wrapperRef = useRef21(null);
14470
- const scrollerRef = useRef21(null);
14471
- const trackRef = useRef21(null);
14543
+ const wrapperRef = useRef22(null);
14544
+ const scrollerRef = useRef22(null);
14545
+ const trackRef = useRef22(null);
14472
14546
  const [reducedMotion, setReducedMotion] = useState31(false);
14473
14547
  const [isTouch, setIsTouch] = useState31(false);
14474
14548
  const [isMobile, setIsMobile] = useState31(false);
@@ -14488,7 +14562,7 @@ function CardsStrip(props) {
14488
14562
  }, []);
14489
14563
  const [overflows, setOverflows] = useState31(false);
14490
14564
  const [marqueeEligible, setMarqueeEligible] = useState31(false);
14491
- const singleCopyWidthRef = useRef21(0);
14565
+ const singleCopyWidthRef = useRef22(0);
14492
14566
  const marqueeActive = autoScroll && !reducedMotion && marqueeEligible && items.length > 0;
14493
14567
  const measure = useCallback14(() => {
14494
14568
  const scroller = scrollerRef.current;
@@ -14510,8 +14584,8 @@ function CardsStrip(props) {
14510
14584
  ro.observe(track);
14511
14585
  return () => ro.disconnect();
14512
14586
  }, [measure, items.length, marqueeActive, isMobile]);
14513
- const chevronSuppressUntilRef = useRef21(0);
14514
- const userScrollSuppressUntilRef = useRef21(0);
14587
+ const chevronSuppressUntilRef = useRef22(0);
14588
+ const userScrollSuppressUntilRef = useRef22(0);
14515
14589
  const [nearViewport, setNearViewport] = useState31(true);
14516
14590
  useEffect26(() => {
14517
14591
  const el = wrapperRef.current;
@@ -14524,7 +14598,7 @@ function CardsStrip(props) {
14524
14598
  return () => io.disconnect();
14525
14599
  }, []);
14526
14600
  const [activeKey, setActiveKey] = useState31(null);
14527
- const activeKeyRef = useRef21(null);
14601
+ const activeKeyRef = useRef22(null);
14528
14602
  const activate = useCallback14((key) => {
14529
14603
  activeKeyRef.current = key;
14530
14604
  setActiveKey(key);
@@ -14533,8 +14607,8 @@ function CardsStrip(props) {
14533
14607
  if (activeKeyRef.current === key) activeKeyRef.current = null;
14534
14608
  setActiveKey((current) => current === key ? null : current);
14535
14609
  }, []);
14536
- const hoverPointerRef = useRef21({ x: 0, y: 0, inside: false });
14537
- const lastHoverSyncScrollRef = useRef21(-1);
14610
+ const hoverPointerRef = useRef22({ x: 0, y: 0, inside: false });
14611
+ const lastHoverSyncScrollRef = useRef22(-1);
14538
14612
  const syncHoverToPointer = useCallback14(() => {
14539
14613
  const p = hoverPointerRef.current;
14540
14614
  if (!p.inside) return;
@@ -14596,9 +14670,9 @@ function CardsStrip(props) {
14596
14670
  onAfterFrame: syncHoverIfScrolled
14597
14671
  });
14598
14672
  const [mountedIdx, setMountedIdx] = useState31(() => /* @__PURE__ */ new Set());
14599
- const cardObserverRef = useRef21(null);
14600
- const cardElIdxRef = useRef21(/* @__PURE__ */ new Map());
14601
- const cardElNearRef = useRef21(/* @__PURE__ */ new Map());
14673
+ const cardObserverRef = useRef22(null);
14674
+ const cardElIdxRef = useRef22(/* @__PURE__ */ new Map());
14675
+ const cardElNearRef = useRef22(/* @__PURE__ */ new Map());
14602
14676
  useEffect26(() => {
14603
14677
  if (typeof IntersectionObserver === "undefined") return;
14604
14678
  const io = new IntersectionObserver((entries) => {
@@ -14627,7 +14701,7 @@ function CardsStrip(props) {
14627
14701
  cardObserverRef.current = null;
14628
14702
  };
14629
14703
  }, []);
14630
- const cardRefFnsRef = useRef21(/* @__PURE__ */ new Map());
14704
+ const cardRefFnsRef = useRef22(/* @__PURE__ */ new Map());
14631
14705
  const getCardRef = useCallback14((idx) => {
14632
14706
  let fn = cardRefFnsRef.current.get(idx);
14633
14707
  if (!fn) {
@@ -14667,7 +14741,7 @@ function CardsStrip(props) {
14667
14741
  const onPointerDownIntent = useCallback14((e) => {
14668
14742
  if (e.pointerType === "touch") onUserScrollIntent();
14669
14743
  }, [onUserScrollIntent]);
14670
- const marqueeActiveRef = useRef21(false);
14744
+ const marqueeActiveRef = useRef22(false);
14671
14745
  marqueeActiveRef.current = marqueeActive;
14672
14746
  const onSeamWarp = useCallback14(() => {
14673
14747
  const scroller = scrollerRef.current;
@@ -17026,7 +17100,7 @@ import {
17026
17100
  useEffect as useEffect27,
17027
17101
  useImperativeHandle as useImperativeHandle4,
17028
17102
  useMemo as useMemo23,
17029
- useRef as useRef23,
17103
+ useRef as useRef24,
17030
17104
  useState as useState34
17031
17105
  } from "react";
17032
17106
  import * as PopoverPrimitive from "@radix-ui/react-popover";
@@ -17201,8 +17275,8 @@ function AutocompleteInner(props, ref) {
17201
17275
  };
17202
17276
  const [isOpen, setIsOpen] = useState34(false);
17203
17277
  const [highlightedIndex, setHighlightedIndex] = useState34(-1);
17204
- const containerRef = useRef23(null);
17205
- const hiddenTagsPopupRef = useRef23(null);
17278
+ const containerRef = useRef24(null);
17279
+ const hiddenTagsPopupRef = useRef24(null);
17206
17280
  const isInvalid = invalid || !!error;
17207
17281
  useImperativeHandle4(ref, () => containerRef.current);
17208
17282
  const selectedOptions = useMemo23(() => {
@@ -17220,7 +17294,7 @@ function AutocompleteInner(props, ref) {
17220
17294
  const hiddenTags = multiple ? selectedOptions.slice(visibleCount) : [];
17221
17295
  const hiddenTagsCount = multiple ? selectedOptions.length - visibleCount : 0;
17222
17296
  const [showHiddenTags, setShowHiddenTags] = useState34(false);
17223
- const hiddenTagsRef = useRef23(null);
17297
+ const hiddenTagsRef = useRef24(null);
17224
17298
  useEffect27(() => {
17225
17299
  if (!showHiddenTags) return;
17226
17300
  const handleClick = (e) => {
@@ -18908,7 +18982,7 @@ function DateFilterMenu({
18908
18982
 
18909
18983
  // src/components/ui/duration-input.tsx
18910
18984
  init_cn();
18911
- import { Fragment as Fragment31, useEffect as useEffect29, useRef as useRef24, useState as useState36 } from "react";
18985
+ import { Fragment as Fragment31, useEffect as useEffect29, useRef as useRef25, useState as useState36 } from "react";
18912
18986
  import { jsx as jsx113, jsxs as jsxs88 } from "react/jsx-runtime";
18913
18987
  var SEGMENT_META = [
18914
18988
  { label: "Hours", placeholder: "HH", max: 99 },
@@ -18923,7 +18997,7 @@ var split = (value) => {
18923
18997
  };
18924
18998
  function DurationInput({ value, onChange, invalid, className }) {
18925
18999
  const [segments, setSegments] = useState36(() => split(value));
18926
- const refs = [useRef24(null), useRef24(null), useRef24(null)];
19000
+ const refs = [useRef25(null), useRef25(null), useRef25(null)];
18927
19001
  useEffect29(() => {
18928
19002
  setSegments((prev) => compose(prev) === value ? prev : split(value));
18929
19003
  }, [value]);
@@ -19041,7 +19115,7 @@ init_cn();
19041
19115
  import React51 from "react";
19042
19116
 
19043
19117
  // src/components/ui/progress-bar.tsx
19044
- import { useEffect as useEffect30, useRef as useRef25, useState as useState37 } from "react";
19118
+ import { useEffect as useEffect30, useRef as useRef26, useState as useState37 } from "react";
19045
19119
  import { jsx as jsx115 } from "react/jsx-runtime";
19046
19120
  var ProgressBar = ({
19047
19121
  progress,
@@ -19057,7 +19131,7 @@ var ProgressBar = ({
19057
19131
  const isMdUp = useMdUp() ?? true;
19058
19132
  const effectiveSegmentWidth = isMdUp ? segmentWidth : mobileSegmentWidth;
19059
19133
  const effectiveHeight = isMdUp ? height : mobileHeight;
19060
- const containerRef = useRef25(null);
19134
+ const containerRef = useRef26(null);
19061
19135
  const [segmentCount, setSegmentCount] = useState37(0);
19062
19136
  useEffect30(() => {
19063
19137
  if (!containerRef.current) return;
@@ -22205,7 +22279,7 @@ function TabContent({
22205
22279
  // src/components/ui/tab-navigation.tsx
22206
22280
  init_next_navigation();
22207
22281
  init_cn();
22208
- import { useState as useState46, useEffect as useEffect37, useLayoutEffect as useLayoutEffect7, useDeferredValue, useMemo as useMemo28, useRef as useRef28, useCallback as useCallback19, memo as memo4, startTransition } from "react";
22282
+ import { useState as useState46, useEffect as useEffect37, useLayoutEffect as useLayoutEffect7, useDeferredValue, useMemo as useMemo28, useRef as useRef29, useCallback as useCallback19, memo as memo4, startTransition } from "react";
22209
22283
  import { Fragment as Fragment34, jsx as jsx147, jsxs as jsxs115 } from "react/jsx-runtime";
22210
22284
  var HIDDEN_INDICATOR = { left: 0, width: 0 };
22211
22285
  var StatusDot = ({ indicator, className }) => /* @__PURE__ */ jsx147("div", { className: cn(
@@ -22225,13 +22299,13 @@ var TabBar = memo4(function TabBar2({
22225
22299
  showRightGradient,
22226
22300
  stretchTabs
22227
22301
  }) {
22228
- const scrollRef = useRef28(null);
22229
- const activeTabRef = useRef28(null);
22230
- const isFirstActiveScrollRef = useRef28(true);
22302
+ const scrollRef = useRef29(null);
22303
+ const activeTabRef = useRef29(null);
22304
+ const isFirstActiveScrollRef = useRef29(true);
22231
22305
  const [canScrollLeft, setCanScrollLeft] = useState46(false);
22232
22306
  const [canScrollRight, setCanScrollRight] = useState46(false);
22233
22307
  const [indicator, setIndicator] = useState46(HIDDEN_INDICATOR);
22234
- const hasPlacedIndicatorRef = useRef28(false);
22308
+ const hasPlacedIndicatorRef = useRef29(false);
22235
22309
  const measureIndicator = useCallback19(() => {
22236
22310
  const active = activeTabRef.current;
22237
22311
  const next = active ? { left: active.offsetLeft, width: active.offsetWidth } : HIDDEN_INDICATOR;
@@ -22415,8 +22489,8 @@ function TabNavigation({
22415
22489
  };
22416
22490
  const [internalActiveTab, setInternalActiveTab] = useState46(getInitialTab);
22417
22491
  const activeTab = isUrlSyncEnabled ? internalActiveTab : controlledActiveTab || "";
22418
- const lastSyncedUrlTabRef = useRef28(urlTab);
22419
- const inFlightUrlTabsRef = useRef28([]);
22492
+ const lastSyncedUrlTabRef = useRef29(urlTab);
22493
+ const inFlightUrlTabsRef = useRef29([]);
22420
22494
  useEffect37(() => {
22421
22495
  if (!isUrlSyncEnabled) return;
22422
22496
  const landed = inFlightUrlTabsRef.current.indexOf(urlTab);
@@ -22435,7 +22509,7 @@ function TabNavigation({
22435
22509
  lastSyncedUrlTabRef.current = urlTab;
22436
22510
  setInternalActiveTab(validTabIds.has(urlTab) ? urlTab : fallbackTab);
22437
22511
  }, [isUrlSyncEnabled, urlTab, validTabIds, fallbackTab]);
22438
- const navRef = useRef28({ isUrlSyncEnabled, controlledOnTabChange, searchParams, pathname, paramName, replaceState });
22512
+ const navRef = useRef29({ isUrlSyncEnabled, controlledOnTabChange, searchParams, pathname, paramName, replaceState });
22439
22513
  useEffect37(() => {
22440
22514
  navRef.current = { isUrlSyncEnabled, controlledOnTabChange, searchParams, pathname, paramName, replaceState };
22441
22515
  });
@@ -22541,7 +22615,7 @@ function AIGeneratedBadge({ className }) {
22541
22615
  }
22542
22616
 
22543
22617
  // src/components/ui/fade-preview.tsx
22544
- import { useState as useState47, useRef as useRef29, useEffect as useEffect38 } from "react";
22618
+ import { useState as useState47, useRef as useRef30, useEffect as useEffect38 } from "react";
22545
22619
  import { ChevronDown as ChevronDown4 } from "lucide-react";
22546
22620
  import { Fragment as Fragment35, jsx as jsx150, jsxs as jsxs117 } from "react/jsx-runtime";
22547
22621
  function FadePreview({
@@ -22551,7 +22625,7 @@ function FadePreview({
22551
22625
  children
22552
22626
  }) {
22553
22627
  const [expanded, setExpanded] = useState47(false);
22554
- const contentRef = useRef29(null);
22628
+ const contentRef = useRef30(null);
22555
22629
  useEffect38(() => {
22556
22630
  setExpanded(false);
22557
22631
  }, [resetKey]);
@@ -22656,7 +22730,7 @@ function useRichMarkdownRuntime() {
22656
22730
  }
22657
22731
 
22658
22732
  // src/components/embeds/reddit-embed-client.tsx
22659
- import { useState as useState49, useEffect as useEffect40, useRef as useRef31 } from "react";
22733
+ import { useState as useState49, useEffect as useEffect40, useRef as useRef32 } from "react";
22660
22734
 
22661
22735
  // src/utils/social-embed-cache.ts
22662
22736
  var cachingRequests = /* @__PURE__ */ new Map();
@@ -22938,7 +23012,7 @@ var socialCache = SocialEmbedCache.getInstance();
22938
23012
 
22939
23013
  // src/components/media-carousel.tsx
22940
23014
  init_cn();
22941
- import { useState as useState48, useRef as useRef30, useEffect as useEffect39, memo as memo5, useCallback as useCallback20 } from "react";
23015
+ import { useState as useState48, useRef as useRef31, useEffect as useEffect39, memo as memo5, useCallback as useCallback20 } from "react";
22942
23016
  init_button2();
22943
23017
  import { Fragment as Fragment36, jsx as jsx153, jsxs as jsxs118 } from "react/jsx-runtime";
22944
23018
  var ChevronLeftIcon = () => /* @__PURE__ */ jsx153("svg", { width: "24", height: "24", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ jsx153("polyline", { points: "15,18 9,12 15,6" }) });
@@ -22958,7 +23032,7 @@ var MediaCarousel = memo5(function MediaCarousel2({
22958
23032
  const [touchEnd, setTouchEnd] = useState48(null);
22959
23033
  const [brokenResourceUrls, setBrokenResourceUrls] = useState48({});
22960
23034
  const [loadedImageSrc, setLoadedImageSrc] = useState48(null);
22961
- const carouselRef = useRef30(null);
23035
+ const carouselRef = useRef31(null);
22962
23036
  const onImageError = useCallback20((originalUrl) => {
22963
23037
  const key = originalUrl.trim() || "__missing_src__";
22964
23038
  setBrokenResourceUrls((b) => b[key] ? b : { ...b, [key]: true });
@@ -23251,7 +23325,7 @@ function RedditEmbedClient({ url, maxWidth = 700 }) {
23251
23325
  const [redditData, setRedditData] = useState49(null);
23252
23326
  const [loading, setLoading] = useState49(true);
23253
23327
  const [error, setError] = useState49(null);
23254
- const initializationDone = useRef31(false);
23328
+ const initializationDone = useRef32(false);
23255
23329
  useEffect40(() => {
23256
23330
  if (initializationDone.current) return;
23257
23331
  initializationDone.current = true;
@@ -23558,7 +23632,7 @@ function RedditEmbedClient({ url, maxWidth = 700 }) {
23558
23632
  }
23559
23633
 
23560
23634
  // src/components/embeds/twitter-embed-client.tsx
23561
- import { useState as useState50, useEffect as useEffect41, useRef as useRef32 } from "react";
23635
+ import { useState as useState50, useEffect as useEffect41, useRef as useRef33 } from "react";
23562
23636
  import { jsx as jsx156, jsxs as jsxs120 } from "react/jsx-runtime";
23563
23637
  var MessageCircleIcon2 = () => /* @__PURE__ */ jsx156("svg", { width: "16", height: "16", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ jsx156("path", { d: "M21 15a2 2 0 01-2 2H7l-4 4V5a2 2 0 012-2h14a2 2 0 012 2z" }) });
23564
23638
  var ExternalLinkIcon3 = () => /* @__PURE__ */ jsxs120("svg", { width: "16", height: "16", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: [
@@ -23587,7 +23661,7 @@ function TwitterEmbedClient({ url, tweetId, maxWidth = 700 }) {
23587
23661
  const [tweetData, setTweetData] = useState50(null);
23588
23662
  const [loading, setLoading] = useState50(true);
23589
23663
  const [error, setError] = useState50(null);
23590
- const initializationDone = useRef32(false);
23664
+ const initializationDone = useRef33(false);
23591
23665
  const extractedTweetId = tweetId || url.match(/status\/(\d+)/)?.[1];
23592
23666
  const tweetUrl = url.includes("twitter.com") || url.includes("x.com") ? url : `https://twitter.com/twitter/status/${extractedTweetId}`;
23593
23667
  useEffect41(() => {
@@ -24216,7 +24290,7 @@ function toFigmaOriginalUrl(url) {
24216
24290
  init_cn();
24217
24291
 
24218
24292
  // src/components/embeds/embed-iframe.tsx
24219
- import { useState as useState53, useCallback as useCallback21, useRef as useRef33, useEffect as useEffect43 } from "react";
24293
+ import { useState as useState53, useCallback as useCallback21, useRef as useRef34, useEffect as useEffect43 } from "react";
24220
24294
  import { Fragment as Fragment37, jsx as jsx159, jsxs as jsxs123 } from "react/jsx-runtime";
24221
24295
  function EmbedLoadingSkeleton({ height }) {
24222
24296
  return /* @__PURE__ */ jsx159(
@@ -24238,7 +24312,7 @@ function EmbedIframe({
24238
24312
  allowFullScreen
24239
24313
  }) {
24240
24314
  const [isLoaded, setIsLoaded] = useState53(false);
24241
- const iframeRef = useRef33(null);
24315
+ const iframeRef = useRef34(null);
24242
24316
  const handleLoad = useCallback21(() => setIsLoaded(true), []);
24243
24317
  useEffect43(() => {
24244
24318
  setIsLoaded(false);
@@ -25073,7 +25147,7 @@ function StatusIndicator({ status, label, href }) {
25073
25147
  }
25074
25148
 
25075
25149
  // src/components/ui/hover-dropdown.tsx
25076
- import { useState as useState57, useRef as useRef34, useCallback as useCallback23 } from "react";
25150
+ import { useState as useState57, useRef as useRef35, useCallback as useCallback23 } from "react";
25077
25151
  import { Fragment as Fragment39, jsx as jsx169, jsxs as jsxs131 } from "react/jsx-runtime";
25078
25152
  function DefaultAnchor({
25079
25153
  href,
@@ -25091,8 +25165,8 @@ function HoverDropdown({
25091
25165
  renderAnchor
25092
25166
  }) {
25093
25167
  const [open, setOpen] = useState57(false);
25094
- const timeoutRef = useRef34(void 0);
25095
- const containerRef = useRef34(null);
25168
+ const timeoutRef = useRef35(void 0);
25169
+ const containerRef = useRef35(null);
25096
25170
  const show = useCallback23(() => {
25097
25171
  clearTimeout(timeoutRef.current);
25098
25172
  setOpen(true);
@@ -31370,7 +31444,7 @@ var ErrorBoundary = class extends Component3 {
31370
31444
 
31371
31445
  // src/components/features/figma-prototype-viewer.tsx
31372
31446
  init_cn();
31373
- import { useState as useState66, useRef as useRef35, useEffect as useEffect51, useCallback as useCallback25, useMemo as useMemo33 } from "react";
31447
+ import { useState as useState66, useRef as useRef36, useEffect as useEffect51, useCallback as useCallback25, useMemo as useMemo33 } from "react";
31374
31448
 
31375
31449
  // src/components/features/section-selector.tsx
31376
31450
  init_cn();
@@ -31739,10 +31813,10 @@ var FigmaPrototypeViewer = ({
31739
31813
  }) => {
31740
31814
  const clientId = process.env.NEXT_PUBLIC_FIGMA_CLIENT_ID || "UTQPwZHR9OZp68TTGPFFi5";
31741
31815
  const showDebugPanel = process.env.NEXT_PUBLIC_FIGMA_DEBUG === "true";
31742
- const iframeRef = useRef35(null);
31743
- const containerRef = useRef35(null);
31744
- const navTimerRef = useRef35(null);
31745
- const touchTimerRef = useRef35(null);
31816
+ const iframeRef = useRef36(null);
31817
+ const containerRef = useRef36(null);
31818
+ const navTimerRef = useRef36(null);
31819
+ const touchTimerRef = useRef36(null);
31746
31820
  const [screenWidth, setScreenWidth] = useState66(
31747
31821
  typeof window !== "undefined" ? window.innerWidth : DESKTOP_BREAKPOINT
31748
31822
  );
@@ -32033,7 +32107,7 @@ var FigmaPrototypeViewer = ({
32033
32107
 
32034
32108
  // src/components/features/filters-dropdown.tsx
32035
32109
  init_cn();
32036
- import { useEffect as useEffect52, useRef as useRef36, useState as useState67 } from "react";
32110
+ import { useEffect as useEffect52, useRef as useRef37, useState as useState67 } from "react";
32037
32111
  import { jsx as jsx230, jsxs as jsxs179 } from "react/jsx-runtime";
32038
32112
  var FilterCheckbox = ({ checked, disabled = false, className }) => {
32039
32113
  return /* @__PURE__ */ jsx230(
@@ -32070,9 +32144,9 @@ var FiltersDropdown = ({
32070
32144
  const [isVisible, setIsVisible] = useState67(false);
32071
32145
  const [isMobile, setIsMobile] = useState67(false);
32072
32146
  const [actualPlacement, setActualPlacement] = useState67(placement);
32073
- const dropdownRef = useRef36(null);
32074
- const triggerRef = useRef36(null);
32075
- const containerRef = useRef36(null);
32147
+ const dropdownRef = useRef37(null);
32148
+ const triggerRef = useRef37(null);
32149
+ const containerRef = useRef37(null);
32076
32150
  useEffect52(() => {
32077
32151
  if (isOpen) {
32078
32152
  setShouldRender(true);
@@ -32474,7 +32548,7 @@ function useLoading() {
32474
32548
  }
32475
32549
 
32476
32550
  // src/components/features/media-gallery-manager.tsx
32477
- import { useState as useState69, useRef as useRef37, useCallback as useCallback26 } from "react";
32551
+ import { useState as useState69, useRef as useRef38, useCallback as useCallback26 } from "react";
32478
32552
  import {
32479
32553
  Upload,
32480
32554
  Image as ImageIcon2,
@@ -32494,7 +32568,7 @@ function MediaGalleryManager({
32494
32568
  modalTitle = "Media Gallery",
32495
32569
  className = ""
32496
32570
  }) {
32497
- const fileInputRef = useRef37(null);
32571
+ const fileInputRef = useRef38(null);
32498
32572
  const [deletingIndex, setDeletingIndex] = useState69(null);
32499
32573
  const [draggedIndex, setDraggedIndex] = useState69(null);
32500
32574
  const handleFileSelect = useCallback26(async (event) => {
@@ -32702,7 +32776,7 @@ function OSTypeBadgeGroup({
32702
32776
  }
32703
32777
 
32704
32778
  // src/components/features/parallax-image-showcase.tsx
32705
- import { useEffect as useEffect54, useState as useState70, useRef as useRef38 } from "react";
32779
+ import { useEffect as useEffect54, useState as useState70, useRef as useRef39 } from "react";
32706
32780
  import { motion, useScroll, useTransform, useMotionValue, useSpring } from "framer-motion";
32707
32781
  import { jsx as jsx237, jsxs as jsxs183 } from "react/jsx-runtime";
32708
32782
  var ParallaxImageShowcase = ({
@@ -32721,7 +32795,7 @@ var ParallaxImageShowcase = ({
32721
32795
  const mouseXSpring = useSpring(mouseX, springConfig);
32722
32796
  const mouseYSpring = useSpring(mouseY, springConfig);
32723
32797
  const [componentRect, setComponentRect] = useState70(null);
32724
- const componentRef = useRef38(null);
32798
+ const componentRef = useRef39(null);
32725
32799
  useEffect54(() => {
32726
32800
  const updateRect = () => {
32727
32801
  if (componentRef.current) {
@@ -33261,7 +33335,7 @@ function PushButtonSelector({
33261
33335
  }
33262
33336
 
33263
33337
  // src/components/features/release-media-manager.tsx
33264
- import { useState as useState71, useRef as useRef39 } from "react";
33338
+ import { useState as useState71, useRef as useRef40 } from "react";
33265
33339
  import { Trash2 as Trash24, Plus as Plus5, Image as ImageIcon3, Video as VideoIcon2, Upload as Upload2, Loader2 as Loader24, GripVertical as GripVertical2 } from "lucide-react";
33266
33340
  import { jsx as jsx241, jsxs as jsxs187 } from "react/jsx-runtime";
33267
33341
  function ReleaseMediaManager({
@@ -33270,7 +33344,7 @@ function ReleaseMediaManager({
33270
33344
  onUpload,
33271
33345
  className = ""
33272
33346
  }) {
33273
- const fileInputRef = useRef39(null);
33347
+ const fileInputRef = useRef40(null);
33274
33348
  const [uploadingIndex, setUploadingIndex] = useState71(null);
33275
33349
  const handleFileSelect = async (event) => {
33276
33350
  const file = event.target.files?.[0];
@@ -34278,7 +34352,7 @@ function VideoBitesDisplay({
34278
34352
  // src/components/features/floating-walkthrough-video.tsx
34279
34353
  init_cn();
34280
34354
  init_button2();
34281
- import { useCallback as useCallback27, useEffect as useEffect55, useMemo as useMemo34, useRef as useRef40, useState as useState74 } from "react";
34355
+ import { useCallback as useCallback27, useEffect as useEffect55, useMemo as useMemo34, useRef as useRef41, useState as useState74 } from "react";
34282
34356
  import * as DialogPrimitive3 from "@radix-ui/react-dialog";
34283
34357
  import { Fragment as Fragment48, jsx as jsx250, jsxs as jsxs194 } from "react/jsx-runtime";
34284
34358
  var isAtEnd = (duration, time) => duration > 0 && duration - time < 1;
@@ -34347,13 +34421,13 @@ function FloatingWalkthroughVideo({
34347
34421
  const [pausedOpenSession, setPausedOpenSession] = useState74(
34348
34422
  Boolean(defaultOpen && defaultOpenPaused) || deepLinkHit
34349
34423
  );
34350
- const previewHandleRef = useRef40(null);
34351
- const theaterHandleRef = useRef40(null);
34352
- const theaterForcedMuteRef = useRef40(false);
34353
- const resumeHandleRef = useRef40(null);
34354
- const closeButtonRef = useRef40(null);
34355
- const userMutedRef = useRef40(false);
34356
- const endedLatchRef = useRef40(false);
34424
+ const previewHandleRef = useRef41(null);
34425
+ const theaterHandleRef = useRef41(null);
34426
+ const theaterForcedMuteRef = useRef41(false);
34427
+ const resumeHandleRef = useRef41(null);
34428
+ const closeButtonRef = useRef41(null);
34429
+ const userMutedRef = useRef41(false);
34430
+ const endedLatchRef = useRef41(false);
34357
34431
  const [hovered, setHovered] = useState74(false);
34358
34432
  const [handoff, setHandoff] = useState74(null);
34359
34433
  const [suspended, setSuspended] = useState74(false);
@@ -34404,10 +34478,10 @@ function FloatingWalkthroughVideo({
34404
34478
  setCardPaused(true);
34405
34479
  setHovered(false);
34406
34480
  }, [footerHidden, resumeMode, hovered]);
34407
- const cardModeRef = useRef40("poster");
34408
- const selfDrivenForRef = useRef40(null);
34409
- const justClosedRef = useRef40(false);
34410
- const justClosedTimerRef = useRef40(null);
34481
+ const cardModeRef = useRef41("poster");
34482
+ const selfDrivenForRef = useRef41(null);
34483
+ const justClosedRef = useRef41(false);
34484
+ const justClosedTimerRef = useRef41(null);
34411
34485
  const commitOpen = useCallback27((next) => {
34412
34486
  if (!next) {
34413
34487
  justClosedRef.current = true;
@@ -36619,7 +36693,7 @@ PolicyConfigurationPanel.displayName = "PolicyConfigurationPanel";
36619
36693
  init_button2();
36620
36694
 
36621
36695
  // src/components/ui/phone-input.tsx
36622
- import { useCallback as useCallback29, useEffect as useEffect57, useMemo as useMemo35, useRef as useRef41, useState as useState78 } from "react";
36696
+ import { useCallback as useCallback29, useEffect as useEffect57, useMemo as useMemo35, useRef as useRef42, useState as useState78 } from "react";
36623
36697
  import { jsx as jsx270, jsxs as jsxs210 } from "react/jsx-runtime";
36624
36698
  function PhoneInput({
36625
36699
  value,
@@ -36637,7 +36711,7 @@ function PhoneInput({
36637
36711
  [countryCode, priority, others]
36638
36712
  );
36639
36713
  const [isInvalid, setIsInvalid] = useState78(false);
36640
- const debounceRef = useRef41(null);
36714
+ const debounceRef = useRef42(null);
36641
36715
  const digitCount = useCallback29((val) => val.replace(/[^0-9]/g, "").length, []);
36642
36716
  const runValidation = useCallback29((phone) => {
36643
36717
  if (!phone || digitCount(phone) === 0) {
@@ -37143,7 +37217,7 @@ function useOptionalNotifications() {
37143
37217
  }
37144
37218
 
37145
37219
  // src/components/features/notifications/notification-drawer.tsx
37146
- import { useEffect as useEffect62, useRef as useRef44 } from "react";
37220
+ import { useEffect as useEffect62, useRef as useRef45 } from "react";
37147
37221
 
37148
37222
  // src/components/navigation/app-layout-context.ts
37149
37223
  import { createContext as createContext10, useContext as useContext10 } from "react";
@@ -37911,9 +37985,9 @@ function DrawerScrollList({
37911
37985
  loadMoreRootMargin,
37912
37986
  renderTile
37913
37987
  }) {
37914
- const scrollRef = useRef44(null);
37915
- const sentinelRef = useRef44(null);
37916
- const loadMoreRef = useRef44(loadMore);
37988
+ const scrollRef = useRef45(null);
37989
+ const sentinelRef = useRef45(null);
37990
+ const loadMoreRef = useRef45(loadMore);
37917
37991
  loadMoreRef.current = loadMore;
37918
37992
  useEffect62(() => {
37919
37993
  if (!loadMore || !hasMore || isLoadingMore) return;
@@ -38782,7 +38856,7 @@ function LastEntryRow({ entry, onClick }) {
38782
38856
  // src/components/features/time-tracker/time-tracker-header-button.tsx
38783
38857
  init_cn();
38784
38858
  import * as PopoverPrimitive5 from "@radix-ui/react-popover";
38785
- import { useEffect as useEffect65, useRef as useRef45 } from "react";
38859
+ import { useEffect as useEffect65, useRef as useRef46 } from "react";
38786
38860
 
38787
38861
  // src/components/navigation/header-button.tsx
38788
38862
  init_cn();
@@ -38865,11 +38939,11 @@ function TimeTrackerHeaderButton({ className, disabled }) {
38865
38939
  const layoutContainer = useAppLayoutDrawerContainer();
38866
38940
  const coordination = useAppLayoutDrawerCoordination();
38867
38941
  const isOpen = ctx?.isOpen ?? false;
38868
- const isOpenRef = useRef45(isOpen);
38942
+ const isOpenRef = useRef46(isOpen);
38869
38943
  isOpenRef.current = isOpen;
38870
- const closeRef = useRef45(ctx?.close);
38944
+ const closeRef = useRef46(ctx?.close);
38871
38945
  closeRef.current = ctx?.close;
38872
- const selfHandleRef = useRef45(null);
38946
+ const selfHandleRef = useRef46(null);
38873
38947
  if (!selfHandleRef.current) {
38874
38948
  selfHandleRef.current = {
38875
38949
  close: () => {
@@ -39903,7 +39977,7 @@ function SortableRow({
39903
39977
 
39904
39978
  // src/components/navigation/header.tsx
39905
39979
  init_next_link();
39906
- import React115, { useEffect as useEffect69, useRef as useRef49, useState as useState91 } from "react";
39980
+ import React115, { useEffect as useEffect69, useRef as useRef50, useState as useState91 } from "react";
39907
39981
  init_button2();
39908
39982
 
39909
39983
  // src/components/navigation/mingo-ai-button.tsx
@@ -39957,14 +40031,14 @@ function MingoAiButton({ source, icon, label = "Mingo AI", className, onClick, .
39957
40031
  }
39958
40032
 
39959
40033
  // src/components/navigation/mobile-nav-panel.tsx
39960
- import { useRef as useRef48 } from "react";
40034
+ import { useRef as useRef49 } from "react";
39961
40035
  import { usePreventScroll as usePreventScroll3 } from "@react-aria/overlays";
39962
40036
  init_button2();
39963
40037
  import { X as X10 } from "lucide-react";
39964
40038
  import { Fragment as Fragment57, jsx as jsx291, jsxs as jsxs226 } from "react/jsx-runtime";
39965
40039
  var MOBILE_NAV_PANEL_ID = "mobile-nav-panel";
39966
40040
  function MobileNavPanel({ isOpen, config }) {
39967
- const panelRef = useRef48(null);
40041
+ const panelRef = useRef49(null);
39968
40042
  usePreventScroll3({ isDisabled: !isOpen });
39969
40043
  useFocusTrap(panelRef, isOpen, { onEscape: config.onClose });
39970
40044
  const headerHeight = useHeaderHeight(64, { enabled: isOpen });
@@ -40510,8 +40584,8 @@ function Header2({ config, platform }) {
40510
40584
  const [show, setShow] = useState91(true);
40511
40585
  const [lastScrollY, setLastScrollY] = useState91(0);
40512
40586
  const [openDropdowns, setOpenDropdowns] = useState91({});
40513
- const dropdownRefs = useRef49({});
40514
- const triggerRefs = useRef49({});
40587
+ const dropdownRefs = useRef50({});
40588
+ const triggerRefs = useRef50({});
40515
40589
  useEffect69(() => {
40516
40590
  const handleClickOutside = (event) => {
40517
40591
  const target = event.target;
@@ -40852,7 +40926,7 @@ function ClientOnlyHeader({ config, skeleton }) {
40852
40926
  }
40853
40927
 
40854
40928
  // src/components/navigation/sliding-sidebar.tsx
40855
- import { useState as useState93, useEffect as useEffect71, useRef as useRef50 } from "react";
40929
+ import { useState as useState93, useEffect as useEffect71, useRef as useRef51 } from "react";
40856
40930
  import { motion as motion2, AnimatePresence, useReducedMotion } from "framer-motion";
40857
40931
  import { usePreventScroll as usePreventScroll4 } from "@react-aria/overlays";
40858
40932
  init_button2();
@@ -40861,7 +40935,7 @@ function SlidingSidebar({ config }) {
40861
40935
  const [expandedItems, setExpandedItems] = useState93(/* @__PURE__ */ new Set());
40862
40936
  const [mounted, setMounted] = useState93(false);
40863
40937
  const headerHeight = useHeaderHeight();
40864
- const asideRef = useRef50(null);
40938
+ const asideRef = useRef51(null);
40865
40939
  const prefersReducedMotion2 = useReducedMotion();
40866
40940
  usePreventScroll4({ isDisabled: !config.isOpen });
40867
40941
  useFocusTrap(asideRef, config.isOpen, { onEscape: config.onClose, contain: false });
@@ -41033,7 +41107,7 @@ function SlidingSidebar({ config }) {
41033
41107
  }
41034
41108
 
41035
41109
  // src/components/navigation/sticky-section-nav.tsx
41036
- import { useEffect as useEffect72, useState as useState94, useCallback as useCallback36, useRef as useRef51 } from "react";
41110
+ import { useEffect as useEffect72, useState as useState94, useCallback as useCallback36, useRef as useRef52 } from "react";
41037
41111
  import { jsx as jsx299, jsxs as jsxs232 } from "react/jsx-runtime";
41038
41112
  function StickySectionNav({
41039
41113
  sections,
@@ -41095,7 +41169,7 @@ function StickySectionNav({
41095
41169
  }
41096
41170
  function useSectionNavigation(sections, options) {
41097
41171
  const [activeSection, setActiveSection] = useState94(sections[0]?.id || "");
41098
- const isScrollingFromClick = useRef51(false);
41172
+ const isScrollingFromClick = useRef52(false);
41099
41173
  const { offset: offset2 = 100 } = options || {};
41100
41174
  const handleSectionClick = useCallback36((sectionId) => {
41101
41175
  const targetElement = document.getElementById(sectionId);
@@ -41930,10 +42004,10 @@ function AppHeaderSkeleton({
41930
42004
  }
41931
42005
 
41932
42006
  // src/components/navigation/app-layout.tsx
41933
- import { useCallback as useCallback39, useMemo as useMemo43, useRef as useRef53, useState as useState96 } from "react";
42007
+ import { useCallback as useCallback39, useMemo as useMemo43, useRef as useRef54, useState as useState96 } from "react";
41934
42008
 
41935
42009
  // src/components/navigation/mobile-burger-menu.tsx
41936
- import React120, { useCallback as useCallback38, useRef as useRef52 } from "react";
42010
+ import React120, { useCallback as useCallback38, useRef as useRef53 } from "react";
41937
42011
  import { usePreventScroll as usePreventScroll5 } from "@react-aria/overlays";
41938
42012
  import { Fragment as Fragment64, jsx as jsx308, jsxs as jsxs241 } from "react/jsx-runtime";
41939
42013
  var HEADER_HEIGHT = 56;
@@ -41947,7 +42021,7 @@ var MobileBurgerMenu = React120.memo(function MobileBurgerMenu2({
41947
42021
  onLogout,
41948
42022
  disabled = false
41949
42023
  }) {
41950
- const panelRef = useRef52(null);
42024
+ const panelRef = useRef53(null);
41951
42025
  usePreventScroll5({ isDisabled: !isOpen });
41952
42026
  useFocusTrap(panelRef, isOpen, { onEscape: onClose });
41953
42027
  const handleItemClick = useCallback38((item) => {
@@ -42123,9 +42197,9 @@ function AppLayout({
42123
42197
  }) {
42124
42198
  const [mobileMenuOpen, setMobileMenuOpen] = useState96(false);
42125
42199
  const [drawerContainer, setDrawerContainer] = useState96(null);
42126
- const mobileMenuOpenRef = useRef53(mobileMenuOpen);
42200
+ const mobileMenuOpenRef = useRef54(mobileMenuOpen);
42127
42201
  mobileMenuOpenRef.current = mobileMenuOpen;
42128
- const drawerHandlesRef = useRef53(/* @__PURE__ */ new Set());
42202
+ const drawerHandlesRef = useRef54(/* @__PURE__ */ new Set());
42129
42203
  const handleToggleMobileMenu = useCallback39(() => {
42130
42204
  const opening = !mobileMenuOpenRef.current;
42131
42205
  if (opening) {
@@ -42752,7 +42826,7 @@ ScriptArguments.displayName = "ScriptArguments";
42752
42826
 
42753
42827
  // src/components/shared/onboarding/onboarding-walkthrough.tsx
42754
42828
  init_button2();
42755
- import React122, { useRef as useRef54, useCallback as useCallback40 } from "react";
42829
+ import React122, { useRef as useRef55, useCallback as useCallback40 } from "react";
42756
42830
 
42757
42831
  // src/components/shared/onboarding/onboarding-step-card.tsx
42758
42832
  import React121 from "react";
@@ -42876,10 +42950,10 @@ function OnboardingWalkthrough({
42876
42950
  allStepsComplete,
42877
42951
  markMultipleComplete
42878
42952
  } = useOnboardingState(storageKey);
42879
- const hasAutoMarkedRef = useRef54(false);
42880
- const autoMarkingInProgressRef = useRef54(false);
42881
- const lastCompletionStatusRef = useRef54(null);
42882
- const actionInProgressRef = useRef54(/* @__PURE__ */ new Set());
42953
+ const hasAutoMarkedRef = useRef55(false);
42954
+ const autoMarkingInProgressRef = useRef55(false);
42955
+ const lastCompletionStatusRef = useRef55(null);
42956
+ const actionInProgressRef = useRef55(/* @__PURE__ */ new Set());
42883
42957
  React122.useEffect(() => {
42884
42958
  if (isLoadingCompletion) {
42885
42959
  hasAutoMarkedRef.current = false;
@@ -43531,7 +43605,7 @@ var ListLoader = (props) => /* @__PURE__ */ jsx326(ContentLoader, { ...props, va
43531
43605
 
43532
43606
  // src/components/ui/table/table.tsx
43533
43607
  init_cn();
43534
- import { useEffect as useEffect75, useRef as useRef56 } from "react";
43608
+ import { useEffect as useEffect75, useRef as useRef57 } from "react";
43535
43609
  init_pagination();
43536
43610
  init_button2();
43537
43611
 
@@ -44291,8 +44365,8 @@ function Table({
44291
44365
  };
44292
44366
  const allSelected = selectedRows.length > 0 && selectedRows.length === data.length;
44293
44367
  const someSelected = selectedRows.length > 0 && selectedRows.length < data.length;
44294
- const sentinelRef = useRef56(null);
44295
- const onLoadMoreRef = useRef56(infiniteScroll?.onLoadMore);
44368
+ const sentinelRef = useRef57(null);
44369
+ const onLoadMoreRef = useRef57(infiniteScroll?.onLoadMore);
44296
44370
  onLoadMoreRef.current = infiniteScroll?.onLoadMore;
44297
44371
  useEffect75(() => {
44298
44372
  if (!infiniteScroll?.hasNextPage || infiniteScroll.isFetchingNextPage) return;
@@ -44512,7 +44586,7 @@ import { useMemo as useMemo45 } from "react";
44512
44586
 
44513
44587
  // src/components/ui/query-report-table/query-report-table-header.tsx
44514
44588
  init_cn();
44515
- import { useRef as useRef57, useState as useState99, useCallback as useCallback41 } from "react";
44589
+ import { useRef as useRef58, useState as useState99, useCallback as useCallback41 } from "react";
44516
44590
  import { jsx as jsx338, jsxs as jsxs266 } from "react/jsx-runtime";
44517
44591
  function QueryReportTableHeader({
44518
44592
  columns,
@@ -44541,7 +44615,7 @@ function QueryReportTableHeader({
44541
44615
  );
44542
44616
  }
44543
44617
  function TruncatedHeaderCell({ value, width }) {
44544
- const textRef = useRef57(null);
44618
+ const textRef = useRef58(null);
44545
44619
  const [isTruncated, setIsTruncated] = useState99(false);
44546
44620
  const checkTruncation = useCallback41(() => {
44547
44621
  const el = textRef.current;
@@ -44571,7 +44645,7 @@ function TruncatedHeaderCell({ value, width }) {
44571
44645
 
44572
44646
  // src/components/ui/query-report-table/query-report-table-row.tsx
44573
44647
  init_cn();
44574
- import { useRef as useRef58, useState as useState100, useCallback as useCallback42 } from "react";
44648
+ import { useRef as useRef59, useState as useState100, useCallback as useCallback42 } from "react";
44575
44649
  import { jsx as jsx339, jsxs as jsxs267 } from "react/jsx-runtime";
44576
44650
  function QueryReportTableRow({
44577
44651
  row,
@@ -44617,7 +44691,7 @@ function QueryReportTableRow({
44617
44691
  );
44618
44692
  }
44619
44693
  function TruncatedCell({ value, className }) {
44620
- const textRef = useRef58(null);
44694
+ const textRef = useRef59(null);
44621
44695
  const [isTruncated, setIsTruncated] = useState100(false);
44622
44696
  const checkTruncation = useCallback42(() => {
44623
44697
  const el = textRef.current;
@@ -45223,7 +45297,7 @@ function DataTableEmpty({ className, ...props }) {
45223
45297
  // src/components/ui/data-table/data-table-row.tsx
45224
45298
  init_next_link();
45225
45299
  init_cn();
45226
- import { memo as memo8, useCallback as useCallback44, useRef as useRef59 } from "react";
45300
+ import { memo as memo8, useCallback as useCallback44, useRef as useRef60 } from "react";
45227
45301
  import { flexRender as flexRender2 } from "@tanstack/react-table";
45228
45302
 
45229
45303
  // src/components/ui/data-table/data-table-skeleton.tsx
@@ -45317,7 +45391,7 @@ function DataTableRowImpl({
45317
45391
  const hasSubRow = subRow != null && subRow !== false;
45318
45392
  const isLinkMode = Boolean(href) && !onClick;
45319
45393
  const isWholeCardLink = isLinkMode && !hasSubRow;
45320
- const containerRef = useRef59(null);
45394
+ const containerRef = useRef60(null);
45321
45395
  const handleClick = useCallback44(
45322
45396
  (e) => {
45323
45397
  const target = e.target;
@@ -45488,7 +45562,7 @@ function DataTableBody({
45488
45562
  }
45489
45563
 
45490
45564
  // src/components/ui/data-table/data-table-infinite-footer.tsx
45491
- import { useEffect as useEffect76, useRef as useRef60 } from "react";
45565
+ import { useEffect as useEffect76, useRef as useRef61 } from "react";
45492
45566
  import { Fragment as Fragment72, jsx as jsx349, jsxs as jsxs275 } from "react/jsx-runtime";
45493
45567
  function DataTableInfiniteFooter({
45494
45568
  hasNextPage,
@@ -45497,8 +45571,8 @@ function DataTableInfiniteFooter({
45497
45571
  skeletonRows = 3,
45498
45572
  rootMargin = "200px"
45499
45573
  }) {
45500
- const sentinelRef = useRef60(null);
45501
- const onLoadMoreRef = useRef60(onLoadMore);
45574
+ const sentinelRef = useRef61(null);
45575
+ const onLoadMoreRef = useRef61(onLoadMore);
45502
45576
  onLoadMoreRef.current = onLoadMore;
45503
45577
  useEffect76(() => {
45504
45578
  if (!hasNextPage || isFetchingNextPage) return;
@@ -46136,7 +46210,7 @@ function FilterList({
46136
46210
  // src/components/ui/tag-search-input.tsx
46137
46211
  import {
46138
46212
  useEffect as useEffect78,
46139
- useRef as useRef62,
46213
+ useRef as useRef63,
46140
46214
  useState as useState102
46141
46215
  } from "react";
46142
46216
  init_cn();
@@ -46171,9 +46245,9 @@ function TagSearchInput({
46171
46245
  limitTags,
46172
46246
  placeholder: currentPlaceholder
46173
46247
  });
46174
- const wrapperRef = useRef62(null);
46175
- const hiddenTagsRef = useRef62(null);
46176
- const hiddenTagsPopupRef = useRef62(null);
46248
+ const wrapperRef = useRef63(null);
46249
+ const hiddenTagsRef = useRef63(null);
46250
+ const hiddenTagsPopupRef = useRef63(null);
46177
46251
  const [showHiddenTags, setShowHiddenTags] = useState102(false);
46178
46252
  useEffect78(() => {
46179
46253
  if (!showHiddenTags) return;
@@ -46337,7 +46411,7 @@ function TagSearchInput({
46337
46411
  }
46338
46412
 
46339
46413
  // src/components/ui/markdown-editor.tsx
46340
- import { useRef as useRef63, useCallback as useCallback45, useState as useState103, useEffect as useEffect79 } from "react";
46414
+ import { useRef as useRef64, useCallback as useCallback45, useState as useState103, useEffect as useEffect79 } from "react";
46341
46415
  init_cn();
46342
46416
  import { Loader2 as Loader28, Upload as Upload8 } from "lucide-react";
46343
46417
  import { jsx as jsx354, jsxs as jsxs280 } from "react/jsx-runtime";
@@ -46392,7 +46466,7 @@ function MarkdownEditor({
46392
46466
  onFileUploaded,
46393
46467
  renderPreview
46394
46468
  }) {
46395
- const fileInputRef = useRef63(null);
46469
+ const fileInputRef = useRef64(null);
46396
46470
  const [isUploading, setIsUploading] = useState103(false);
46397
46471
  const [uploadProgress, setUploadProgress] = useState103("");
46398
46472
  const [defaultExtraCommands, setDefaultExtraCommands] = useState103([]);
@@ -46485,11 +46559,11 @@ function MarkdownEditor({
46485
46559
  }
46486
46560
  } : null;
46487
46561
  const extraCommands = uploadCommand ? [...defaultExtraCommands, uploadCommand] : defaultExtraCommands;
46488
- const wrapperRef = useRef63(null);
46489
- const isDraggingRef = useRef63(false);
46490
- const mouseYRef = useRef63(0);
46491
- const rafRef = useRef63(0);
46492
- const scrollParentRef = useRef63(window);
46562
+ const wrapperRef = useRef64(null);
46563
+ const isDraggingRef = useRef64(false);
46564
+ const mouseYRef = useRef64(0);
46565
+ const rafRef = useRef64(0);
46566
+ const scrollParentRef = useRef64(window);
46493
46567
  const EDGE_ZONE = 60;
46494
46568
  const MAX_SCROLL_SPEED = 15;
46495
46569
  const findScrollParent = useCallback45((el) => {
@@ -52376,7 +52450,7 @@ function renderChatInlineEntityCard(chatRef, options = {}) {
52376
52450
  }
52377
52451
 
52378
52452
  // src/components/chat/hooks/use-chunk-catchup.ts
52379
- import { useCallback as useCallback48, useRef as useRef67 } from "react";
52453
+ import { useCallback as useCallback48, useRef as useRef68 } from "react";
52380
52454
  function makeSeqKey(messageType, chunkType, sequenceId) {
52381
52455
  return `${messageType}:${chunkType}:${sequenceId}`;
52382
52456
  }
@@ -52398,22 +52472,22 @@ function useChunkCatchup({
52398
52472
  chatTypes = [CHAT_TYPE.CLIENT],
52399
52473
  fetchChunks
52400
52474
  }) {
52401
- const processedSequenceKeys = useRef67(/* @__PURE__ */ new Set());
52402
- const lastSequenceId = useRef67(null);
52403
- const lastSequenceIdByType = useRef67(/* @__PURE__ */ new Map());
52404
- const fetchingInProgress = useRef67(false);
52405
- const lastFetchParams = useRef67(null);
52406
- const pendingCatchupRef = useRef67(null);
52407
- const chunkBuffer = useRef67([]);
52408
- const bufferUntilInitialCatchupComplete = useRef67(false);
52409
- const hasCompletedInitialCatchup = useRef67(false);
52410
- const dialogIdRef = useRef67(dialogId);
52475
+ const processedSequenceKeys = useRef68(/* @__PURE__ */ new Set());
52476
+ const lastSequenceId = useRef68(null);
52477
+ const lastSequenceIdByType = useRef68(/* @__PURE__ */ new Map());
52478
+ const fetchingInProgress = useRef68(false);
52479
+ const lastFetchParams = useRef68(null);
52480
+ const pendingCatchupRef = useRef68(null);
52481
+ const chunkBuffer = useRef68([]);
52482
+ const bufferUntilInitialCatchupComplete = useRef68(false);
52483
+ const hasCompletedInitialCatchup = useRef68(false);
52484
+ const dialogIdRef = useRef68(dialogId);
52411
52485
  dialogIdRef.current = dialogId;
52412
- const chatTypesRef = useRef67(chatTypes);
52486
+ const chatTypesRef = useRef68(chatTypes);
52413
52487
  chatTypesRef.current = chatTypes;
52414
- const fetchChunksRef = useRef67(fetchChunks);
52488
+ const fetchChunksRef = useRef68(fetchChunks);
52415
52489
  fetchChunksRef.current = fetchChunks;
52416
- const onChunkReceivedRef = useRef67(onChunkReceived);
52490
+ const onChunkReceivedRef = useRef68(onChunkReceived);
52417
52491
  onChunkReceivedRef.current = onChunkReceived;
52418
52492
  const processChunk = useCallback48((chunk, messageType, forceProcess = false) => {
52419
52493
  if (bufferUntilInitialCatchupComplete.current && !forceProcess) {
@@ -52611,7 +52685,7 @@ function useChunkCatchup({
52611
52685
  }
52612
52686
  }
52613
52687
  }, [flushBufferedRealtimeChunks]);
52614
- const catchUpChunksRef = useRef67(null);
52688
+ const catchUpChunksRef = useRef68(null);
52615
52689
  catchUpChunksRef.current = catchUpChunks;
52616
52690
  const resetChunkTracking = useCallback48(() => {
52617
52691
  processedSequenceKeys.current.clear();
@@ -52690,7 +52764,7 @@ function useScriptedStream(frames, resetKey, enabled = true) {
52690
52764
  }
52691
52765
 
52692
52766
  // src/components/chat/hooks/use-jetstream-dialog-subscription.ts
52693
- import { useEffect as useEffect85, useRef as useRef68, useState as useState115 } from "react";
52767
+ import { useEffect as useEffect85, useRef as useRef69, useState as useState115 } from "react";
52694
52768
  var DEFAULT_STREAM_NAME = "CHAT_CHUNKS";
52695
52769
  var RESYNC_AFTER_HIDDEN_MS = 1e4;
52696
52770
  var RECOVERY_REPORT_FLOOR_MS = 5e3;
@@ -52715,52 +52789,52 @@ function useJetStreamDialogSubscription({
52715
52789
  const [reconnectionCount, setReconnectionCount] = useState115(0);
52716
52790
  const [recoveryCount, setRecoveryCount] = useState115(0);
52717
52791
  const [currentStreamSeq, setCurrentStreamSeq] = useState115(null);
52718
- const lastRecoveryReportRef = useRef68(0);
52719
- const clientRef = useRef68(null);
52720
- const subscriptionRef = useRef68(null);
52721
- const highestStreamSeqRef = useRef68(null);
52722
- const onEventRef = useRef68(onEvent);
52792
+ const lastRecoveryReportRef = useRef69(0);
52793
+ const clientRef = useRef69(null);
52794
+ const subscriptionRef = useRef69(null);
52795
+ const highestStreamSeqRef = useRef69(null);
52796
+ const onEventRef = useRef69(onEvent);
52723
52797
  useEffect85(() => {
52724
52798
  onEventRef.current = onEvent;
52725
52799
  }, [onEvent]);
52726
- const onConnectRef = useRef68(onConnect);
52800
+ const onConnectRef = useRef69(onConnect);
52727
52801
  useEffect85(() => {
52728
52802
  onConnectRef.current = onConnect;
52729
52803
  }, [onConnect]);
52730
- const onDisconnectRef = useRef68(onDisconnect);
52804
+ const onDisconnectRef = useRef69(onDisconnect);
52731
52805
  useEffect85(() => {
52732
52806
  onDisconnectRef.current = onDisconnect;
52733
52807
  }, [onDisconnect]);
52734
- const onSubscribedRef = useRef68(onSubscribed);
52808
+ const onSubscribedRef = useRef69(onSubscribed);
52735
52809
  useEffect85(() => {
52736
52810
  onSubscribedRef.current = onSubscribed;
52737
52811
  }, [onSubscribed]);
52738
- const onBeforeReconnectRef = useRef68(onBeforeReconnect);
52812
+ const onBeforeReconnectRef = useRef69(onBeforeReconnect);
52739
52813
  useEffect85(() => {
52740
52814
  onBeforeReconnectRef.current = onBeforeReconnect;
52741
52815
  }, [onBeforeReconnect]);
52742
- const getNatsWsUrlRef = useRef68(getNatsWsUrl);
52816
+ const getNatsWsUrlRef = useRef69(getNatsWsUrl);
52743
52817
  useEffect85(() => {
52744
52818
  getNatsWsUrlRef.current = getNatsWsUrl;
52745
52819
  }, [getNatsWsUrl]);
52746
- const reconnectionBackoffRef = useRef68(reconnectionBackoff);
52820
+ const reconnectionBackoffRef = useRef69(reconnectionBackoff);
52747
52821
  useEffect85(() => {
52748
52822
  reconnectionBackoffRef.current = reconnectionBackoff;
52749
52823
  }, [reconnectionBackoff]);
52750
- const optStartSeqRef = useRef68(optStartSeq);
52824
+ const optStartSeqRef = useRef69(optStartSeq);
52751
52825
  useEffect85(() => {
52752
52826
  optStartSeqRef.current = optStartSeq;
52753
52827
  }, [optStartSeq]);
52754
- const inactiveThresholdRef = useRef68(inactiveThresholdMs);
52828
+ const inactiveThresholdRef = useRef69(inactiveThresholdMs);
52755
52829
  useEffect85(() => {
52756
52830
  inactiveThresholdRef.current = inactiveThresholdMs;
52757
52831
  }, [inactiveThresholdMs]);
52758
- const hadConnectionBeforeRef = useRef68(false);
52759
- const clientConfigRef = useRef68(clientConfig);
52832
+ const hadConnectionBeforeRef = useRef69(false);
52833
+ const clientConfigRef = useRef69(clientConfig);
52760
52834
  useEffect85(() => {
52761
52835
  clientConfigRef.current = clientConfig;
52762
52836
  }, [clientConfig]);
52763
- const currentWsUrlRef = useRef68("");
52837
+ const currentWsUrlRef = useRef69("");
52764
52838
  const wsUrl = getNatsWsUrl();
52765
52839
  useEffect85(() => {
52766
52840
  if (!enabled || !wsUrl) {
@@ -52965,7 +53039,7 @@ function useJetStreamDialogSubscription({
52965
53039
  }
52966
53040
 
52967
53041
  // src/components/chat/hooks/use-nats-dialog-subscription.ts
52968
- import { useEffect as useEffect86, useRef as useRef69, useState as useState116 } from "react";
53042
+ import { useEffect as useEffect86, useRef as useRef70, useState as useState116 } from "react";
52969
53043
  function useNatsDialogSubscription({
52970
53044
  enabled,
52971
53045
  dialogId,
@@ -52982,42 +53056,42 @@ function useNatsDialogSubscription({
52982
53056
  const [isConnected, setIsConnected] = useState116(false);
52983
53057
  const [isSubscribed, setIsSubscribed] = useState116(false);
52984
53058
  const [reconnectionCount, setReconnectionCount] = useState116(0);
52985
- const clientRef = useRef69(null);
52986
- const subscriptionRefs = useRef69(/* @__PURE__ */ new Map());
52987
- const onEventRef = useRef69(onEvent);
53059
+ const clientRef = useRef70(null);
53060
+ const subscriptionRefs = useRef70(/* @__PURE__ */ new Map());
53061
+ const onEventRef = useRef70(onEvent);
52988
53062
  useEffect86(() => {
52989
53063
  onEventRef.current = onEvent;
52990
53064
  }, [onEvent]);
52991
- const onConnectRef = useRef69(onConnect);
53065
+ const onConnectRef = useRef70(onConnect);
52992
53066
  useEffect86(() => {
52993
53067
  onConnectRef.current = onConnect;
52994
53068
  }, [onConnect]);
52995
- const onDisconnectRef = useRef69(onDisconnect);
53069
+ const onDisconnectRef = useRef70(onDisconnect);
52996
53070
  useEffect86(() => {
52997
53071
  onDisconnectRef.current = onDisconnect;
52998
53072
  }, [onDisconnect]);
52999
- const onSubscribedRef = useRef69(onSubscribed);
53073
+ const onSubscribedRef = useRef70(onSubscribed);
53000
53074
  useEffect86(() => {
53001
53075
  onSubscribedRef.current = onSubscribed;
53002
53076
  }, [onSubscribed]);
53003
- const onBeforeReconnectRef = useRef69(onBeforeReconnect);
53077
+ const onBeforeReconnectRef = useRef70(onBeforeReconnect);
53004
53078
  useEffect86(() => {
53005
53079
  onBeforeReconnectRef.current = onBeforeReconnect;
53006
53080
  }, [onBeforeReconnect]);
53007
- const hadConnectionBeforeRef = useRef69(false);
53008
- const getNatsWsUrlRef = useRef69(getNatsWsUrl);
53081
+ const hadConnectionBeforeRef = useRef70(false);
53082
+ const getNatsWsUrlRef = useRef70(getNatsWsUrl);
53009
53083
  useEffect86(() => {
53010
53084
  getNatsWsUrlRef.current = getNatsWsUrl;
53011
53085
  }, [getNatsWsUrl]);
53012
- const reconnectionBackoffRef = useRef69(reconnectionBackoff);
53086
+ const reconnectionBackoffRef = useRef70(reconnectionBackoff);
53013
53087
  useEffect86(() => {
53014
53088
  reconnectionBackoffRef.current = reconnectionBackoff;
53015
53089
  }, [reconnectionBackoff]);
53016
- const clientConfigRef = useRef69(clientConfig);
53090
+ const clientConfigRef = useRef70(clientConfig);
53017
53091
  useEffect86(() => {
53018
53092
  clientConfigRef.current = clientConfig;
53019
53093
  }, [clientConfig]);
53020
- const currentWsUrlRef = useRef69("");
53094
+ const currentWsUrlRef = useRef70("");
53021
53095
  const wsUrl = getNatsWsUrl();
53022
53096
  useEffect86(() => {
53023
53097
  if (!enabled || !wsUrl) {
@@ -53101,15 +53175,15 @@ function useNatsDialogSubscription({
53101
53175
  };
53102
53176
  }, [enabled, wsUrl]);
53103
53177
  const topicsKey = topics.join(",");
53104
- const topicsRef = useRef69(topics);
53178
+ const topicsRef = useRef70(topics);
53105
53179
  topicsRef.current = topics;
53106
- const lastSubscribedDialogIdRef = useRef69(null);
53107
- const isConnectedRef = useRef69(isConnected);
53180
+ const lastSubscribedDialogIdRef = useRef70(null);
53181
+ const isConnectedRef = useRef70(isConnected);
53108
53182
  useEffect86(() => {
53109
53183
  isConnectedRef.current = isConnected;
53110
53184
  }, [isConnected]);
53111
- const currentDialogIdRef = useRef69(null);
53112
- const abortControllerRef = useRef69(null);
53185
+ const currentDialogIdRef = useRef70(null);
53186
+ const abortControllerRef = useRef70(null);
53113
53187
  useEffect86(() => {
53114
53188
  currentDialogIdRef.current = dialogId;
53115
53189
  if (!enabled || !dialogId) {
@@ -53366,7 +53440,7 @@ function useEmptyStateConfig(emptyStateUrl, options) {
53366
53440
  }
53367
53441
 
53368
53442
  // src/components/chat/hooks/use-chat-attachments.ts
53369
- import { useCallback as useCallback49, useMemo as useMemo50, useRef as useRef70, useState as useState118 } from "react";
53443
+ import { useCallback as useCallback49, useMemo as useMemo50, useRef as useRef71, useState as useState118 } from "react";
53370
53444
  import { fileTypeFromBlob } from "file-type";
53371
53445
  var CHAT_ATTACHMENTS_BUCKET = "chat-attachments";
53372
53446
  var CHAT_ATTACHMENTS_FOLDER = "chat";
@@ -53443,7 +53517,7 @@ function useChatAttachments() {
53443
53517
  const runtime = useRequiredChatRuntime();
53444
53518
  const uploadUrlEndpoint = runtime.endpoints.attachmentUploadUrl;
53445
53519
  const [attachments, setAttachments] = useState118([]);
53446
- const controllersRef = useRef70(/* @__PURE__ */ new Map());
53520
+ const controllersRef = useRef71(/* @__PURE__ */ new Map());
53447
53521
  const updateOne = useCallback49((id, patch) => {
53448
53522
  setAttachments((prev) => prev.map((a) => a.id === id ? { ...a, ...patch } : a));
53449
53523
  }, []);
@@ -53532,7 +53606,7 @@ function useChatAttachments() {
53532
53606
  },
53533
53607
  [uploadUrlEndpoint, updateOne]
53534
53608
  );
53535
- const attachmentsRef = useRef70([]);
53609
+ const attachmentsRef = useRef71([]);
53536
53610
  attachmentsRef.current = attachments;
53537
53611
  const addFiles = useCallback49(
53538
53612
  (files) => {
@@ -53609,13 +53683,13 @@ function useChatAttachments() {
53609
53683
  }
53610
53684
 
53611
53685
  // src/components/chat/hooks/use-chat-attachment-image-gallery.tsx
53612
- import { useCallback as useCallback50, useEffect as useEffect88, useRef as useRef71, useState as useState119 } from "react";
53686
+ import { useCallback as useCallback50, useEffect as useEffect88, useRef as useRef72, useState as useState119 } from "react";
53613
53687
  import { jsx as jsx380 } from "react/jsx-runtime";
53614
53688
  var CLOSED = { isOpen: false, images: [], initialIndex: 0 };
53615
53689
  function useChatAttachmentImageGallery() {
53616
53690
  const runtime = useRequiredChatRuntime();
53617
53691
  const viewUrlPrefix = runtime.endpoints.attachmentViewUrlPrefix;
53618
- const panelRef = useRef71(null);
53692
+ const panelRef = useRef72(null);
53619
53693
  const [state, setState] = useState119(CLOSED);
53620
53694
  const handleClose = useCallback50(() => setState(CLOSED), []);
53621
53695
  useEffect88(() => {
@@ -53664,10 +53738,10 @@ function absolutize(prefix) {
53664
53738
  }
53665
53739
 
53666
53740
  // src/components/chat/hooks/use-close-on-navigation.ts
53667
- import { useEffect as useEffect89, useRef as useRef72 } from "react";
53741
+ import { useEffect as useEffect89, useRef as useRef73 } from "react";
53668
53742
  function useCloseOnNavigation(close, pathname) {
53669
- const prevPathnameRef = useRef72(null);
53670
- const initializedRef = useRef72(false);
53743
+ const prevPathnameRef = useRef73(null);
53744
+ const initializedRef = useRef73(false);
53671
53745
  useEffect89(() => {
53672
53746
  if (!initializedRef.current) {
53673
53747
  initializedRef.current = true;
@@ -53682,14 +53756,14 @@ function useCloseOnNavigation(close, pathname) {
53682
53756
  }
53683
53757
 
53684
53758
  // src/components/chat/hooks/use-chat.ts
53685
- import { useState as useState121, useCallback as useCallback52, useEffect as useEffect90, useRef as useRef74 } from "react";
53759
+ import { useState as useState121, useCallback as useCallback52, useEffect as useEffect90, useRef as useRef75 } from "react";
53686
53760
 
53687
53761
  // src/components/chat/hooks/use-sse.ts
53688
- import { useState as useState120, useCallback as useCallback51, useRef as useRef73 } from "react";
53762
+ import { useState as useState120, useCallback as useCallback51, useRef as useRef74 } from "react";
53689
53763
  function useSSE({ useMock = true, debugMode = false, streamFn } = {}) {
53690
53764
  const [isStreaming, setIsStreaming] = useState120(false);
53691
53765
  const [error, setError] = useState120(null);
53692
- const abortControllerRef = useRef73(null);
53766
+ const abortControllerRef = useRef74(null);
53693
53767
  const fallbackStream = useCallback51(async function* () {
53694
53768
  throw new Error(
53695
53769
  "[useSSE] No streamFn provided and `useMock: true` is no longer wired into the lib. Supply a `streamFn` (see `createDocStreamFn` in use-embedded-chat) or migrate the mock to your host code."
@@ -53757,8 +53831,8 @@ function useChat({
53757
53831
  } = {}) {
53758
53832
  const [messages, setMessages] = useState121(() => initialMessages ?? []);
53759
53833
  const [isTyping, setIsTyping] = useState121(false);
53760
- const currentAssistantSegmentsRef = useRef74([]);
53761
- const onMessagesChangeRef = useRef74(onMessagesChange);
53834
+ const currentAssistantSegmentsRef = useRef75([]);
53835
+ const onMessagesChangeRef = useRef75(onMessagesChange);
53762
53836
  onMessagesChangeRef.current = onMessagesChange;
53763
53837
  useEffect90(() => {
53764
53838
  onMessagesChangeRef.current?.(messages);
@@ -54053,7 +54127,7 @@ function useChat({
54053
54127
  }
54054
54128
 
54055
54129
  // src/components/chat/hooks/use-sse-chat-adapter.ts
54056
- import { useCallback as useCallback54, useMemo as useMemo52, useRef as useRef77 } from "react";
54130
+ import { useCallback as useCallback54, useMemo as useMemo52, useRef as useRef78 } from "react";
54057
54131
 
54058
54132
  // src/chat-protocol/frames.ts
54059
54133
  var FRAME_TERMINATOR = "\0";
@@ -54306,7 +54380,7 @@ function pruneStaleChatConversationStorage(source) {
54306
54380
  }
54307
54381
 
54308
54382
  // src/components/chat/hooks/use-chat-history-hydration.ts
54309
- import { useEffect as useEffect91, useRef as useRef75, useState as useState122 } from "react";
54383
+ import { useEffect as useEffect91, useRef as useRef76, useState as useState122 } from "react";
54310
54384
  function useChatHistoryHydration({
54311
54385
  active,
54312
54386
  source,
@@ -54318,7 +54392,7 @@ function useChatHistoryHydration({
54318
54392
  bumpMetaTick
54319
54393
  }) {
54320
54394
  const [isHydratingHistory, setIsHydratingHistory] = useState122(false);
54321
- const hydratedKeyRef = useRef75(null);
54395
+ const hydratedKeyRef = useRef76(null);
54322
54396
  useEffect91(() => {
54323
54397
  if (!active) return;
54324
54398
  const conversationId = conversationIdRef.current;
@@ -56307,7 +56381,7 @@ function createChatDialogStore(options = {}) {
56307
56381
  }
56308
56382
 
56309
56383
  // src/components/chat/stream/use-chat-stream-reducer.ts
56310
- import { useCallback as useCallback53, useEffect as useEffect92, useMemo as useMemo51, useRef as useRef76, useSyncExternalStore } from "react";
56384
+ import { useCallback as useCallback53, useEffect as useEffect92, useMemo as useMemo51, useRef as useRef77, useSyncExternalStore } from "react";
56311
56385
 
56312
56386
  // src/components/chat/stream/delta-batcher.ts
56313
56387
  var DELTA_FLUSH_FALLBACK_MS = 50;
@@ -56396,7 +56470,7 @@ function useChatStreamReducer({
56396
56470
  side = DEFAULT_DIALOG_SIDE,
56397
56471
  createReducerOptions
56398
56472
  }) {
56399
- const optionsRef = useRef76(createReducerOptions);
56473
+ const optionsRef = useRef77(createReducerOptions);
56400
56474
  optionsRef.current = createReducerOptions;
56401
56475
  const reducer2 = store.getReducer(dialogId, side, () => optionsRef.current?.() ?? {});
56402
56476
  const getSnapshot = useCallback53(() => store.getSnapshot(dialogId, side), [store, dialogId, side]);
@@ -56404,13 +56478,13 @@ function useChatStreamReducer({
56404
56478
  const subscribe = useCallback53((listener) => store.subscribe(listener), [store]);
56405
56479
  const state = useSyncExternalStore(subscribe, getSnapshot, getServerSnapshot);
56406
56480
  useEffect92(() => store.retain(dialogId, side), [store, dialogId, side]);
56407
- const keyRef = useRef76({ dialogId, side });
56481
+ const keyRef = useRef77({ dialogId, side });
56408
56482
  if (keyRef.current.dialogId !== dialogId || keyRef.current.side !== side) {
56409
56483
  keyRef.current = { dialogId, side };
56410
56484
  }
56411
- const storeRef = useRef76(store);
56485
+ const storeRef = useRef77(store);
56412
56486
  storeRef.current = store;
56413
- const batcherRef = useRef76(null);
56487
+ const batcherRef = useRef77(null);
56414
56488
  if (batcherRef.current === null) {
56415
56489
  batcherRef.current = createDeltaBatcher({
56416
56490
  applyOne: (event, key) => {
@@ -56460,7 +56534,7 @@ function useSseChatAdapter(options, runtimeOptions = {}) {
56460
56534
  const runtime = useRequiredChatRuntime();
56461
56535
  const source = runtime.source || DEFAULT_CHAT_SOURCE;
56462
56536
  const tableIdForDocumentType = options?.tableIdForDocumentType ?? defaultTableIdForDocumentType;
56463
- const sendMessageRef = useRef77(async () => true);
56537
+ const sendMessageRef = useRef78(async () => true);
56464
56538
  const cardResolve = useCallback54(
56465
56539
  (action) => (reqId) => {
56466
56540
  if (!reqId) return;
@@ -56480,17 +56554,17 @@ function useSseChatAdapter(options, runtimeOptions = {}) {
56480
56554
  }),
56481
56555
  [cardApprove, cardReject]
56482
56556
  );
56483
- const storeRef = useRef77(null);
56557
+ const storeRef = useRef78(null);
56484
56558
  if (storeRef.current === null) storeRef.current = createChatDialogStore();
56485
56559
  const { state, applyEvent, flushDeltas, mutate, reducer: reducer2 } = useChatStreamReducer({
56486
56560
  store: storeRef.current,
56487
56561
  dialogId: source,
56488
56562
  createReducerOptions
56489
56563
  });
56490
- const abortControllerRef = useRef77(null);
56564
+ const abortControllerRef = useRef78(null);
56491
56565
  const conversationStorage = useMemo52(() => createChatConversationStorage(source), [source]);
56492
- const conversationIdRef = useRef77(null);
56493
- const restoredConversationRef = useRef77(false);
56566
+ const conversationIdRef = useRef78(null);
56567
+ const restoredConversationRef = useRef78(false);
56494
56568
  if (!restoredConversationRef.current) {
56495
56569
  restoredConversationRef.current = true;
56496
56570
  pruneStaleChatConversationStorage(source);
@@ -56521,8 +56595,8 @@ function useSseChatAdapter(options, runtimeOptions = {}) {
56521
56595
  return map;
56522
56596
  }, [slashCommands]);
56523
56597
  const historyUrl = runtime.endpoints.chatHistoryUrl ?? `${runtime.endpoints.chatStreamUrl.replace(/\/+$/, "")}/history`;
56524
- const hydrationRefsMapRef = useRef77(/* @__PURE__ */ new Map());
56525
- const hydrationSendCountRef = useRef77(0);
56598
+ const hydrationRefsMapRef = useRef78(/* @__PURE__ */ new Map());
56599
+ const hydrationSendCountRef = useRef78(0);
56526
56600
  const hydrateMessages = useCallback54(
56527
56601
  (history) => {
56528
56602
  mutate((r) => {
@@ -56553,7 +56627,7 @@ function useSseChatAdapter(options, runtimeOptions = {}) {
56553
56627
  // `hydrateMessages` above) already invalidates the snapshot.
56554
56628
  bumpMetaTick: noopBumpMetaTick
56555
56629
  });
56556
- const endpointsRef = useRef77(runtime.endpoints);
56630
+ const endpointsRef = useRef78(runtime.endpoints);
56557
56631
  endpointsRef.current = runtime.endpoints;
56558
56632
  const captureConversationId = useCallback54(
56559
56633
  (event) => {
@@ -56820,7 +56894,7 @@ var noopBumpMetaTick = () => {
56820
56894
  };
56821
56895
 
56822
56896
  // src/components/chat/hooks/use-nats-chat-adapter.ts
56823
- import { useCallback as useCallback55, useEffect as useEffect93, useMemo as useMemo53, useRef as useRef78, useState as useState123 } from "react";
56897
+ import { useCallback as useCallback55, useEffect as useEffect93, useMemo as useMemo53, useRef as useRef79, useState as useState123 } from "react";
56824
56898
 
56825
56899
  // src/chat-protocol/nats-decoder.ts
56826
56900
  function normalizeToolCalls(raw) {
@@ -57612,11 +57686,11 @@ function useNatsChatAdapter(config, options = {}) {
57612
57686
  const isManagedMode = fetchDialogs !== void 0;
57613
57687
  const [internalDialogId, setInternalDialogId] = useState123(null);
57614
57688
  const dialogId = isManagedMode ? internalDialogId : controlledDialogId !== void 0 ? controlledDialogId : null;
57615
- const currentDialogIdRef = useRef78(dialogId);
57689
+ const currentDialogIdRef = useRef79(dialogId);
57616
57690
  currentDialogIdRef.current = dialogId;
57617
- const handleApproveRef = useRef78(async () => {
57691
+ const handleApproveRef = useRef79(async () => {
57618
57692
  });
57619
- const handleRejectRef = useRef78(
57693
+ const handleRejectRef = useRef79(
57620
57694
  async () => {
57621
57695
  }
57622
57696
  );
@@ -57628,8 +57702,8 @@ function useNatsChatAdapter(config, options = {}) {
57628
57702
  if (!requestId) return;
57629
57703
  return handleRejectRef.current(requestId);
57630
57704
  }, []);
57631
- const storeRef = useRef78(createChatDialogStore());
57632
- const globalApprovalStatusesRef = useRef78({});
57705
+ const storeRef = useRef79(createChatDialogStore());
57706
+ const globalApprovalStatusesRef = useRef79({});
57633
57707
  const dialogKey = dialogId ?? DRAFT_DIALOG_KEY;
57634
57708
  const { state, applyEvent, mutate } = useChatStreamReducer({
57635
57709
  store: storeRef.current,
@@ -57693,7 +57767,7 @@ function useNatsChatAdapter(config, options = {}) {
57693
57767
  const [messagesNextCursor, setMessagesNextCursor] = useState123(null);
57694
57768
  const [isMessagesLoading, setIsMessagesLoading] = useState123(false);
57695
57769
  const [connectionState, setConnectionState] = useState123("connecting");
57696
- const hasConnectedOnceRef = useRef78(false);
57770
+ const hasConnectedOnceRef = useRef79(false);
57697
57771
  const {
57698
57772
  processChunk: catchupProcessChunk,
57699
57773
  catchUpChunks,
@@ -57706,7 +57780,7 @@ function useNatsChatAdapter(config, options = {}) {
57706
57780
  onChunkReceived: (chunk) => processChunk(chunk),
57707
57781
  fetchChunks
57708
57782
  });
57709
- const historyLoadSeqRef = useRef78(0);
57783
+ const historyLoadSeqRef = useRef79(0);
57710
57784
  const loadDialogHistory = useCallback55(
57711
57785
  async (id, cursor) => {
57712
57786
  if (!fetchDialogMessages) return;
@@ -57769,7 +57843,7 @@ function useNatsChatAdapter(config, options = {}) {
57769
57843
  isBufferingActive
57770
57844
  ]
57771
57845
  );
57772
- const prevDialogIdRef = useRef78(void 0);
57846
+ const prevDialogIdRef = useRef79(void 0);
57773
57847
  useEffect93(() => {
57774
57848
  if (prevDialogIdRef.current === dialogId) return;
57775
57849
  prevDialogIdRef.current = dialogId;
@@ -57853,7 +57927,7 @@ function useNatsChatAdapter(config, options = {}) {
57853
57927
  }
57854
57928
  setConnectionState("connecting");
57855
57929
  }, [active, dialogId]);
57856
- const initialDialogsLoadedRef = useRef78(false);
57930
+ const initialDialogsLoadedRef = useRef79(false);
57857
57931
  const loadDialogsPage = useCallback55(
57858
57932
  async (cursor) => {
57859
57933
  if (!fetchDialogs) return;
@@ -58118,7 +58192,7 @@ function useNatsChatAdapter(config, options = {}) {
58118
58192
  }
58119
58193
 
58120
58194
  // src/components/chat/hooks/use-unified-chat.ts
58121
- import { useCallback as useCallback56, useMemo as useMemo54, useRef as useRef79 } from "react";
58195
+ import { useCallback as useCallback56, useMemo as useMemo54, useRef as useRef80 } from "react";
58122
58196
  var EMPTY_SSE_OPTIONS = {};
58123
58197
  function createDisabledNatsConfig() {
58124
58198
  return {
@@ -58133,7 +58207,7 @@ function createDisabledNatsConfig() {
58133
58207
  }
58134
58208
  function useUnifiedChat(options) {
58135
58209
  const { modes, activeMode, mingoStateOverride } = options;
58136
- const disabledNatsRef = useRef79(null);
58210
+ const disabledNatsRef = useRef80(null);
58137
58211
  if (disabledNatsRef.current === null) {
58138
58212
  disabledNatsRef.current = createDisabledNatsConfig();
58139
58213
  }
@@ -58147,7 +58221,7 @@ function useUnifiedChat(options) {
58147
58221
  { active: natsActive }
58148
58222
  );
58149
58223
  const activeState = activeMode === "guide" ? sseState : mingoStateOverride ?? natsState;
58150
- const activeStateRef = useRef79(activeState);
58224
+ const activeStateRef = useRef80(activeState);
58151
58225
  activeStateRef.current = activeState;
58152
58226
  const stopMessage = useCallback56(() => activeStateRef.current.stopMessage(), []);
58153
58227
  const clearMessages = useCallback56(
@@ -58546,7 +58620,7 @@ function buildStreamFrames(messages) {
58546
58620
 
58547
58621
  // src/components/chat/embeddable-chat.tsx
58548
58622
  init_cn();
58549
- import { useCallback as useCallback58, useEffect as useEffect94, useMemo as useMemo56, useRef as useRef81, useState as useState125 } from "react";
58623
+ import { useCallback as useCallback58, useEffect as useEffect94, useMemo as useMemo56, useRef as useRef82, useState as useState125 } from "react";
58550
58624
  import * as DialogPrimitive5 from "@radix-ui/react-dialog";
58551
58625
  import { usePreventScroll as usePreventScroll6 } from "@react-aria/overlays";
58552
58626
  import { isIOS } from "@react-aria/utils";
@@ -58633,7 +58707,7 @@ init_button2();
58633
58707
  import { FileText as FileText8, MessageSquare as MessageSquare3 } from "lucide-react";
58634
58708
 
58635
58709
  // src/components/chat/hooks/use-chat-dialog-manager.ts
58636
- import { useCallback as useCallback57, useMemo as useMemo55, useRef as useRef80, useState as useState124 } from "react";
58710
+ import { useCallback as useCallback57, useMemo as useMemo55, useRef as useRef81, useState as useState124 } from "react";
58637
58711
  function useChatDialogManager({
58638
58712
  dialogs,
58639
58713
  activeDialogId,
@@ -58673,7 +58747,7 @@ function useChatDialogManager({
58673
58747
  const [archivedCursor, setArchivedCursor] = useState124(null);
58674
58748
  const [archivedLoading, setArchivedLoading] = useState124(false);
58675
58749
  const [archivedPending, setArchivedPending] = useState124(false);
58676
- const archivedRequestIdRef = useRef80(0);
58750
+ const archivedRequestIdRef = useRef81(0);
58677
58751
  const loadArchivedPage = useCallback57(
58678
58752
  async (cursor) => {
58679
58753
  if (!fetchArchivedDialogs) return;
@@ -59178,7 +59252,7 @@ function EmbeddableChatInner({
59178
59252
  return !window.matchMedia("(pointer: coarse)").matches;
59179
59253
  });
59180
59254
  usePreventScroll6({ isDisabled: !isOpen || shellLess });
59181
- const navigatingAwayRef = useRef81(false);
59255
+ const navigatingAwayRef = useRef82(false);
59182
59256
  useEffect94(() => {
59183
59257
  if (!isOpen) return;
59184
59258
  if (shellLess) return;
@@ -59205,7 +59279,7 @@ function EmbeddableChatInner({
59205
59279
  window.scrollTo(0, scrollY);
59206
59280
  };
59207
59281
  }, [isOpen, shellLess]);
59208
- const chatInputRef = useRef81(null);
59282
+ const chatInputRef = useRef82(null);
59209
59283
  const [quickActionPreview, setQuickActionPreview] = useState125(null);
59210
59284
  const slashCommandsProp = useMemo56(
59211
59285
  () => ({
@@ -59311,7 +59385,7 @@ function EmbeddableChatInner({
59311
59385
  hasMoreMessages,
59312
59386
  loadMoreMessages
59313
59387
  } = useUnifiedChat({ modes: effectiveModes, activeMode, mingoStateOverride: mingoState });
59314
- const guidePromptSentRef = useRef81(false);
59388
+ const guidePromptSentRef = useRef82(false);
59315
59389
  useEffect94(() => {
59316
59390
  if (!guidePendingPrompt) {
59317
59391
  guidePromptSentRef.current = false;
@@ -59336,11 +59410,11 @@ function EmbeddableChatInner({
59336
59410
  const [contextItems, setContextItems] = useState125([]);
59337
59411
  const [contextPickerOpen, setContextPickerOpen] = useState125(false);
59338
59412
  const [mentionQuery, setMentionQuery] = useState125(null);
59339
- const mentionActiveRef = useRef81(false);
59413
+ const mentionActiveRef = useRef82(false);
59340
59414
  useEffect94(() => {
59341
59415
  mentionActiveRef.current = mentionQuery !== null;
59342
59416
  }, [mentionQuery]);
59343
- const mentionKeysRef = useRef81(/* @__PURE__ */ new Set());
59417
+ const mentionKeysRef = useRef82(/* @__PURE__ */ new Set());
59344
59418
  useEffect94(() => {
59345
59419
  setContextItems([]);
59346
59420
  setMentionQuery(null);
@@ -59437,7 +59511,7 @@ function EmbeddableChatInner({
59437
59511
  () => effectiveAssistantIcon ? /* @__PURE__ */ jsx383(EntityIcon, { icon: effectiveAssistantIcon, size: 24 }) : /* @__PURE__ */ jsx383(MingoIcon, { className: "h-6 w-6", cornerColor: "var(--ods-flamingo-cyan-base)" }),
59438
59512
  [effectiveAssistantIcon]
59439
59513
  );
59440
- const timestampCacheRef = useRef81(/* @__PURE__ */ new Map());
59514
+ const timestampCacheRef = useRef82(/* @__PURE__ */ new Map());
59441
59515
  const guideUserName = activeMode === "guide" ? [identityUser?.firstName, identityUser?.lastName].filter(Boolean).join(" ").trim() || identityUser?.name?.trim() || void 0 : void 0;
59442
59516
  const guideUserAvatar = activeMode === "guide" ? identityUser?.avatarUrl?.trim() || void 0 : void 0;
59443
59517
  const messages = useMemo56(() => {
@@ -59648,7 +59722,7 @@ function EmbeddableChatInner({
59648
59722
  const [portalHost, setPortalHost] = useState125(null);
59649
59723
  const [panelBoundary, setPanelBoundary] = useState125(null);
59650
59724
  const [panelWidth, setPanelWidth] = useState125(0);
59651
- const panelMeasureRef = useRef81(null);
59725
+ const panelMeasureRef = useRef82(null);
59652
59726
  useEffect94(() => {
59653
59727
  const el = panelMeasureRef.current;
59654
59728
  if (!el || typeof ResizeObserver === "undefined") return;
@@ -61325,4 +61399,4 @@ export {
61325
61399
  LogsList,
61326
61400
  assets
61327
61401
  };
61328
- //# sourceMappingURL=chunk-ZA5PFNHR.js.map
61402
+ //# sourceMappingURL=chunk-AQHR5D7X.js.map