@tarsis/toolkit 0.5.6 → 0.5.7

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.
@@ -52094,11 +52094,11 @@ const BubblyParticlesButton = () => {
52094
52094
  return /* @__PURE__ */ jsx("button", { className: styles$4H.root, onClick: handleClick, children: "Click me!" });
52095
52095
  };
52096
52096
 
52097
- const root$4i = "_root_1pxow_1";
52098
- const button$o = "_button_1pxow_13";
52099
- const p$1 = "_p_1pxow_26";
52100
- const text$z = "_text_1pxow_26";
52101
- const effects = "_effects_1pxow_240";
52097
+ const root$4i = "_root_1wli6_1";
52098
+ const button$o = "_button_1wli6_13";
52099
+ const p$1 = "_p_1wli6_26";
52100
+ const text$z = "_text_1wli6_26";
52101
+ const effects = "_effects_1wli6_240";
52102
52102
  const styles$4G = {
52103
52103
  root: root$4i,
52104
52104
  button: button$o,
@@ -59661,11 +59661,6 @@ var module = {};
59661
59661
  const confetti = module.exports;
59662
59662
  module.exports.create;
59663
59663
 
59664
- const root$4d = "_root_s1prb_1";
59665
- const styles$4z = {
59666
- root: root$4d
59667
- };
59668
-
59669
59664
  const LayoutGroupContext = createContext({});
59670
59665
 
59671
59666
  const useIsomorphicLayoutEffect$2 = isBrowser$1 ? useLayoutEffect : useEffect;
@@ -61779,11 +61774,12 @@ function distance2D(a, b) {
61779
61774
  return Math.sqrt(xDelta ** 2 + yDelta ** 2);
61780
61775
  }
61781
61776
 
61777
+ const overflowStyles = /*#__PURE__*/ new Set(["auto", "scroll"]);
61782
61778
  /**
61783
61779
  * @internal
61784
61780
  */
61785
61781
  class PanSession {
61786
- constructor(event, handlers, { transformPagePoint, contextWindow = window, dragSnapToOrigin = false, distanceThreshold = 3, } = {}) {
61782
+ constructor(event, handlers, { transformPagePoint, contextWindow = window, dragSnapToOrigin = false, distanceThreshold = 3, element, } = {}) {
61787
61783
  /**
61788
61784
  * @internal
61789
61785
  */
@@ -61804,6 +61800,22 @@ class PanSession {
61804
61800
  * @internal
61805
61801
  */
61806
61802
  this.contextWindow = window;
61803
+ /**
61804
+ * Scroll positions of scrollable ancestors and window.
61805
+ * @internal
61806
+ */
61807
+ this.scrollPositions = new Map();
61808
+ /**
61809
+ * Cleanup function for scroll listeners.
61810
+ * @internal
61811
+ */
61812
+ this.removeScrollListeners = null;
61813
+ this.onElementScroll = (event) => {
61814
+ this.handleScroll(event.target);
61815
+ };
61816
+ this.onWindowScroll = () => {
61817
+ this.handleScroll(window);
61818
+ };
61807
61819
  this.updatePoint = () => {
61808
61820
  if (!(this.lastMoveEvent && this.lastMoveEventInfo))
61809
61821
  return;
@@ -61866,12 +61878,93 @@ class PanSession {
61866
61878
  onSessionStart &&
61867
61879
  onSessionStart(event, getPanInfo(initialInfo, this.history));
61868
61880
  this.removeListeners = pipe$1(addPointerEvent(this.contextWindow, "pointermove", this.handlePointerMove), addPointerEvent(this.contextWindow, "pointerup", this.handlePointerUp), addPointerEvent(this.contextWindow, "pointercancel", this.handlePointerUp));
61881
+ // Start scroll tracking if element provided
61882
+ if (element) {
61883
+ this.startScrollTracking(element);
61884
+ }
61885
+ }
61886
+ /**
61887
+ * Start tracking scroll on ancestors and window.
61888
+ */
61889
+ startScrollTracking(element) {
61890
+ // Store initial scroll positions for scrollable ancestors
61891
+ let current = element.parentElement;
61892
+ while (current) {
61893
+ const style = getComputedStyle(current);
61894
+ if (overflowStyles.has(style.overflowX) ||
61895
+ overflowStyles.has(style.overflowY)) {
61896
+ this.scrollPositions.set(current, {
61897
+ x: current.scrollLeft,
61898
+ y: current.scrollTop,
61899
+ });
61900
+ }
61901
+ current = current.parentElement;
61902
+ }
61903
+ // Track window scroll
61904
+ this.scrollPositions.set(window, {
61905
+ x: window.scrollX,
61906
+ y: window.scrollY,
61907
+ });
61908
+ // Capture listener catches element scroll events as they bubble
61909
+ window.addEventListener("scroll", this.onElementScroll, {
61910
+ capture: true,
61911
+ passive: true,
61912
+ });
61913
+ // Direct window scroll listener (window scroll doesn't bubble)
61914
+ window.addEventListener("scroll", this.onWindowScroll, {
61915
+ passive: true,
61916
+ });
61917
+ this.removeScrollListeners = () => {
61918
+ window.removeEventListener("scroll", this.onElementScroll, {
61919
+ capture: true,
61920
+ });
61921
+ window.removeEventListener("scroll", this.onWindowScroll);
61922
+ };
61923
+ }
61924
+ /**
61925
+ * Handle scroll compensation during drag.
61926
+ *
61927
+ * For element scroll: adjusts history origin since pageX/pageY doesn't change.
61928
+ * For window scroll: adjusts lastMoveEventInfo since pageX/pageY would change.
61929
+ */
61930
+ handleScroll(target) {
61931
+ const initial = this.scrollPositions.get(target);
61932
+ if (!initial)
61933
+ return;
61934
+ const isWindow = target === window;
61935
+ const current = isWindow
61936
+ ? { x: window.scrollX, y: window.scrollY }
61937
+ : {
61938
+ x: target.scrollLeft,
61939
+ y: target.scrollTop,
61940
+ };
61941
+ const delta = { x: current.x - initial.x, y: current.y - initial.y };
61942
+ if (delta.x === 0 && delta.y === 0)
61943
+ return;
61944
+ if (isWindow) {
61945
+ // Window scroll: pageX/pageY changes, so update lastMoveEventInfo
61946
+ if (this.lastMoveEventInfo) {
61947
+ this.lastMoveEventInfo.point.x += delta.x;
61948
+ this.lastMoveEventInfo.point.y += delta.y;
61949
+ }
61950
+ }
61951
+ else {
61952
+ // Element scroll: pageX/pageY unchanged, so adjust history origin
61953
+ if (this.history.length > 0) {
61954
+ this.history[0].x -= delta.x;
61955
+ this.history[0].y -= delta.y;
61956
+ }
61957
+ }
61958
+ this.scrollPositions.set(target, current);
61959
+ frame$2.update(this.updatePoint, true);
61869
61960
  }
61870
61961
  updateHandlers(handlers) {
61871
61962
  this.handlers = handlers;
61872
61963
  }
61873
61964
  end() {
61874
61965
  this.removeListeners && this.removeListeners();
61966
+ this.removeScrollListeners && this.removeScrollListeners();
61967
+ this.scrollPositions.clear();
61875
61968
  cancelFrame(this.updatePoint);
61876
61969
  }
61877
61970
  }
@@ -62122,7 +62215,7 @@ class VisualElementDragControls {
62122
62215
  this.visualElement.projection.target = undefined;
62123
62216
  }
62124
62217
  /**
62125
- * Record gesture origin
62218
+ * Record gesture origin and pointer offset
62126
62219
  */
62127
62220
  eachAxis((axis) => {
62128
62221
  let current = this.getAxisMotionValue(axis).get() || 0;
@@ -62203,6 +62296,7 @@ class VisualElementDragControls {
62203
62296
  dragSnapToOrigin,
62204
62297
  distanceThreshold,
62205
62298
  contextWindow: getContextWindow(this.visualElement),
62299
+ element: this.visualElement.current,
62206
62300
  });
62207
62301
  }
62208
62302
  /**
@@ -65122,6 +65216,11 @@ function useAnimate() {
65122
65216
  return [scope, animate];
65123
65217
  }
65124
65218
 
65219
+ const root$4d = "_root_s1prb_1";
65220
+ const styles$4z = {
65221
+ root: root$4d
65222
+ };
65223
+
65125
65224
  const useConfetti = () => useCallback(async (rect, options = {}) => {
65126
65225
  const { x, y, width, height } = rect;
65127
65226
  const origin = {
@@ -68107,9 +68206,9 @@ const NeonButton = ({ className = "", ...rest }) => {
68107
68206
  return /* @__PURE__ */ jsx("button", { type: "button", ...rest, className: clsx(styles$48.root, className), children: "Neon" });
68108
68207
  };
68109
68208
 
68110
- const root$3P = "_root_1u78n_2";
68111
- const i$6 = "_i_1u78n_22";
68112
- const text$s = "_text_1u78n_482";
68209
+ const root$3P = "_root_1cxbn_2";
68210
+ const i$6 = "_i_1cxbn_22";
68211
+ const text$s = "_text_1cxbn_482";
68113
68212
  const styles$47 = {
68114
68213
  root: root$3P,
68115
68214
  i: i$6,
@@ -69435,30 +69534,15 @@ const SquishButton = ({ children, className = "", ...rest }) => {
69435
69534
  return /* @__PURE__ */ jsx("button", { type: "button", ...rest, className: clsx(styles$3P.root, className), children });
69436
69535
  };
69437
69536
 
69438
- const root$3w = "_root_v4ko6_1";
69439
- const pending = "_pending_v4ko6_12";
69440
- const loading$1 = "_loading_v4ko6_17";
69441
- const success$1 = "_success_v4ko6_20";
69442
- const icon$f = "_icon_v4ko6_25";
69443
- const fingerprint = "_fingerprint_v4ko6_50";
69444
- const styles$3O = {
69445
- root: root$3w,
69446
- pending: pending,
69447
- loading: loading$1,
69448
- success: success$1,
69449
- icon: icon$f,
69450
- fingerprint: fingerprint
69451
- };
69452
-
69453
- const root$3v = "_root_g5l4r_1";
69537
+ const root$3w = "_root_g5l4r_1";
69454
69538
  const a$3 = "_a_g5l4r_9";
69455
69539
  const b$2 = "_b_g5l4r_10";
69456
69540
  const c$3 = "_c_g5l4r_11";
69457
69541
  const d$3 = "_d_g5l4r_12";
69458
69542
  const e$3 = "_e_g5l4r_13";
69459
69543
  const active$m = "_active_g5l4r_20";
69460
- const styles$3N = {
69461
- root: root$3v,
69544
+ const styles$3O = {
69545
+ root: root$3w,
69462
69546
  a: a$3,
69463
69547
  b: b$2,
69464
69548
  c: c$3,
@@ -69471,7 +69555,7 @@ const Fingerprint = ({ className = "" }) => {
69471
69555
  return /* @__PURE__ */ jsx(
69472
69556
  "svg",
69473
69557
  {
69474
- className: clsx(styles$3N.root, className),
69558
+ className: clsx(styles$3O.root, className),
69475
69559
  width: "34px",
69476
69560
  height: "34px",
69477
69561
  viewBox: "0 0 34 34",
@@ -69493,35 +69577,35 @@ const Fingerprint = ({ className = "" }) => {
69493
69577
  /* @__PURE__ */ jsx(
69494
69578
  "path",
69495
69579
  {
69496
- className: clsx(styles$3N.a, { [styles$3N.active]: isActive }),
69580
+ className: clsx(styles$3O.a, { [styles$3O.active]: isActive }),
69497
69581
  d: "M3.14414922,1.97419264 C3.14414922,1.97419264 5.30885997,0.506351808 9.06036082,0.506351808 C12.8118617,0.506351808 14.781903,1.97419264 14.781903,1.97419264"
69498
69582
  }
69499
69583
  ),
69500
69584
  /* @__PURE__ */ jsx(
69501
69585
  "path",
69502
69586
  {
69503
- className: clsx(styles$3N.b, { [styles$3N.active]: isActive }),
69587
+ className: clsx(styles$3O.b, { [styles$3O.active]: isActive }),
69504
69588
  d: "M0.466210729,7.27628774 C0.466210729,7.27628774 3.19024811,2.75878123 9.09512428,2.96502806 C15.0000005,3.17127489 17.4745821,7.17202872 17.4745821,7.17202872"
69505
69589
  }
69506
69590
  ),
69507
69591
  /* @__PURE__ */ jsx(
69508
69592
  "path",
69509
69593
  {
69510
- className: clsx(styles$3N.c, { [styles$3N.active]: isActive }),
69594
+ className: clsx(styles$3O.c, { [styles$3O.active]: isActive }),
69511
69595
  d: "M2,16.4687762 C2,16.4687762 1.12580828,14.9305411 1.27082278,11.9727304 C1.45871447,8.14036841 5.19587478,5.30175361 9.05270871,5.30175361 C12.9095426,5.30175361 15.0000001,7.82879552 15.8975926,9.33195218 C16.5919575,10.4947729 17.7597991,14.4361492 14.6226101,15.0206592 C12.41268,15.4324056 11.5911303,13.4911155 11.5911303,12.9859143 C11.5911303,11.9727302 11.1054172,10.2336826 9.05270848,10.2336826 C6.99999978,10.2336826 6.11384543,11.8665663 6.4593664,13.7955614 C6.6532895,14.8782069 7.59887942,18.3701197 12.0173963,19.5605638"
69512
69596
  }
69513
69597
  ),
69514
69598
  /* @__PURE__ */ jsx(
69515
69599
  "path",
69516
69600
  {
69517
- className: clsx(styles$3N.d, { [styles$3N.active]: isActive }),
69601
+ className: clsx(styles$3O.d, { [styles$3O.active]: isActive }),
69518
69602
  d: "M7.0204614,19.6657197 C7.0204614,19.6657197 3.88328263,16.5690127 3.88328268,12.9603117 C3.88328274,9.35161068 6.59923746,7.80642537 9.0076008,7.80642554 C11.4159641,7.8064257 14.1798468,9.55747124 14.1798468,12.759562"
69519
69603
  }
69520
69604
  ),
69521
69605
  /* @__PURE__ */ jsx(
69522
69606
  "path",
69523
69607
  {
69524
- className: clsx(styles$3N.e, { [styles$3N.active]: isActive }),
69608
+ className: clsx(styles$3O.e, { [styles$3O.active]: isActive }),
69525
69609
  d: "M8.95538742,12.6694189 C8.95538742,12.6694189 9.04883608,18.1288401 15.069217,17.3610597"
69526
69610
  }
69527
69611
  )
@@ -69532,15 +69616,30 @@ const Fingerprint = ({ className = "" }) => {
69532
69616
  );
69533
69617
  };
69534
69618
 
69619
+ const root$3v = "_root_v4ko6_1";
69620
+ const pending = "_pending_v4ko6_12";
69621
+ const loading$1 = "_loading_v4ko6_17";
69622
+ const success$1 = "_success_v4ko6_20";
69623
+ const icon$f = "_icon_v4ko6_25";
69624
+ const fingerprint = "_fingerprint_v4ko6_50";
69625
+ const styles$3N = {
69626
+ root: root$3v,
69627
+ pending: pending,
69628
+ loading: loading$1,
69629
+ success: success$1,
69630
+ icon: icon$f,
69631
+ fingerprint: fingerprint
69632
+ };
69633
+
69535
69634
  const SuccessLoader = ({ status }) => /* @__PURE__ */ jsx(
69536
69635
  "div",
69537
69636
  {
69538
- className: clsx(styles$3O.root, {
69539
- [styles$3O.success]: status === "success",
69540
- [styles$3O.loading]: status === "loading",
69541
- [styles$3O.pending]: status === "pending"
69637
+ className: clsx(styles$3N.root, {
69638
+ [styles$3N.success]: status === "success",
69639
+ [styles$3N.loading]: status === "loading",
69640
+ [styles$3N.pending]: status === "pending"
69542
69641
  }),
69543
- children: status === "success" ? /* @__PURE__ */ jsx("span", { className: styles$3O.icon }) : status === "pending" ? /* @__PURE__ */ jsx(Fingerprint, { className: styles$3O.fingerprint }) : null
69642
+ children: status === "success" ? /* @__PURE__ */ jsx("span", { className: styles$3N.icon }) : status === "pending" ? /* @__PURE__ */ jsx(Fingerprint, { className: styles$3N.fingerprint }) : null
69544
69643
  }
69545
69644
  );
69546
69645
 
@@ -71056,54 +71155,6 @@ const BulletsCarousel = () => {
71056
71155
  ] }) });
71057
71156
  };
71058
71157
 
71059
- const MOCK_CARD_CAROUSEL_ITEMS = [
71060
- {
71061
- id: "Tour",
71062
- image: "https://images.pexels.com/photos/991012/pexels-photo-991012.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=650&w=940",
71063
- subtitle: "The grand moment",
71064
- title: "Le tour",
71065
- description: "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.",
71066
- href: "#",
71067
- hrefTitle: "Explore the tour"
71068
- },
71069
- {
71070
- id: "Window",
71071
- image: "https://images.pexels.com/photos/921294/pexels-photo-921294.png?auto=compress&cs=tinysrgb&h=750&w=1260",
71072
- subtitle: "The big window",
71073
- title: "Minimal window",
71074
- description: "Clear Glass Window With Brown and White Wooden Frame iste natus error sit voluptatem accusantium doloremque laudantium.",
71075
- href: "#",
71076
- hrefTitle: "Read the article"
71077
- },
71078
- {
71079
- id: "Palms",
71080
- image: "https://images.pexels.com/photos/92733/pexels-photo-92733.jpeg?auto=compress&cs=tinysrgb&h=750&w=1260",
71081
- subtitle: "Tropical palms",
71082
- title: "Palms",
71083
- description: "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.",
71084
- href: "#",
71085
- hrefTitle: "Explore the palms"
71086
- },
71087
- {
71088
- id: "Beach",
71089
- image: "https://images.pexels.com/photos/1008732/pexels-photo-1008732.jpeg?auto=compress&cs=tinysrgb&h=750&w=1260",
71090
- subtitle: "Beach",
71091
- title: "The beach",
71092
- description: "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.",
71093
- href: "#",
71094
- hrefTitle: "Explore the beach"
71095
- },
71096
- {
71097
- id: "Building",
71098
- image: "https://images.pexels.com/photos/1029614/pexels-photo-1029614.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=650&w=940",
71099
- subtitle: "The white building",
71100
- title: "White Building",
71101
- description: "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.",
71102
- href: "#",
71103
- hrefTitle: "Read article"
71104
- }
71105
- ];
71106
-
71107
71158
  const root$35 = "_root_1f7ly_1";
71108
71159
  const item$m = "_item_1f7ly_14";
71109
71160
  const itemInfo = "_itemInfo_1f7ly_32";
@@ -71159,6 +71210,54 @@ const CardCarouselItem = ({
71159
71210
  ] });
71160
71211
  };
71161
71212
 
71213
+ const MOCK_CARD_CAROUSEL_ITEMS = [
71214
+ {
71215
+ id: "Tour",
71216
+ image: "https://images.pexels.com/photos/991012/pexels-photo-991012.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=650&w=940",
71217
+ subtitle: "The grand moment",
71218
+ title: "Le tour",
71219
+ description: "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.",
71220
+ href: "#",
71221
+ hrefTitle: "Explore the tour"
71222
+ },
71223
+ {
71224
+ id: "Window",
71225
+ image: "https://images.pexels.com/photos/921294/pexels-photo-921294.png?auto=compress&cs=tinysrgb&h=750&w=1260",
71226
+ subtitle: "The big window",
71227
+ title: "Minimal window",
71228
+ description: "Clear Glass Window With Brown and White Wooden Frame iste natus error sit voluptatem accusantium doloremque laudantium.",
71229
+ href: "#",
71230
+ hrefTitle: "Read the article"
71231
+ },
71232
+ {
71233
+ id: "Palms",
71234
+ image: "https://images.pexels.com/photos/92733/pexels-photo-92733.jpeg?auto=compress&cs=tinysrgb&h=750&w=1260",
71235
+ subtitle: "Tropical palms",
71236
+ title: "Palms",
71237
+ description: "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.",
71238
+ href: "#",
71239
+ hrefTitle: "Explore the palms"
71240
+ },
71241
+ {
71242
+ id: "Beach",
71243
+ image: "https://images.pexels.com/photos/1008732/pexels-photo-1008732.jpeg?auto=compress&cs=tinysrgb&h=750&w=1260",
71244
+ subtitle: "Beach",
71245
+ title: "The beach",
71246
+ description: "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.",
71247
+ href: "#",
71248
+ hrefTitle: "Explore the beach"
71249
+ },
71250
+ {
71251
+ id: "Building",
71252
+ image: "https://images.pexels.com/photos/1029614/pexels-photo-1029614.jpeg?auto=compress&cs=tinysrgb&dpr=2&h=650&w=940",
71253
+ subtitle: "The white building",
71254
+ title: "White Building",
71255
+ description: "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam.",
71256
+ href: "#",
71257
+ hrefTitle: "Read article"
71258
+ }
71259
+ ];
71260
+
71162
71261
  const CardCarousel = ({ items = MOCK_CARD_CAROUSEL_ITEMS }) => {
71163
71262
  const [activeIndex, setActiveIndex] = useState(0);
71164
71263
  return /* @__PURE__ */ jsxs("div", { className: styles$3l.root, children: [
@@ -74038,17 +74137,6 @@ const DockMotionEmbedded = ({ children }) => {
74038
74137
  return /* @__PURE__ */ jsx("span", { className: styles$2T.root, children });
74039
74138
  };
74040
74139
 
74041
- const root$2F = "_root_1oncf_1";
74042
- const block = "_block_1oncf_4";
74043
- const item$g = "_item_1oncf_14";
74044
- const gloss = "_gloss_1oncf_31";
74045
- const styles$2S = {
74046
- root: root$2F,
74047
- block: block,
74048
- item: item$g,
74049
- gloss: gloss
74050
- };
74051
-
74052
74140
  function hasWindow() {
74053
74141
  return typeof window !== 'undefined';
74054
74142
  }
@@ -78102,7 +78190,7 @@ function useRole(context, props) {
78102
78190
 
78103
78191
  const tooltip = "_tooltip_pli88_1";
78104
78192
  const tooltipContent = "_tooltipContent_pli88_6";
78105
- const styles$2R = {
78193
+ const styles$2S = {
78106
78194
  tooltip: tooltip,
78107
78195
  tooltipContent: tooltipContent
78108
78196
  };
@@ -78118,6 +78206,9 @@ const Tooltip = ({
78118
78206
  }) => {
78119
78207
  const [isOpen, setIsOpen] = useState(false);
78120
78208
  const shouldReduceMotion = useReducedMotion();
78209
+ const hasFinePointer = useMatchMedia("(pointer: fine)");
78210
+ const isMobile = hasFinePointer === false;
78211
+ const timeoutRef = useRef(null);
78121
78212
  const variants = shouldReduceMotion ? void 0 : {
78122
78213
  initial: {
78123
78214
  scale: animate ? 0.6 : 1,
@@ -78163,6 +78254,28 @@ const Tooltip = ({
78163
78254
  dismiss,
78164
78255
  role
78165
78256
  ]);
78257
+ useEffect(() => {
78258
+ if (timeoutRef.current) {
78259
+ clearTimeout(timeoutRef.current);
78260
+ timeoutRef.current = null;
78261
+ }
78262
+ if (isOpen && isMobile) {
78263
+ timeoutRef.current = setTimeout(() => {
78264
+ setIsOpen(false);
78265
+ }, 2e3);
78266
+ }
78267
+ return () => {
78268
+ if (timeoutRef.current) {
78269
+ clearTimeout(timeoutRef.current);
78270
+ timeoutRef.current = null;
78271
+ }
78272
+ };
78273
+ }, [isOpen, isMobile]);
78274
+ const handleMobileClick = (_e) => {
78275
+ if (isMobile) {
78276
+ setIsOpen(true);
78277
+ }
78278
+ };
78166
78279
  const childRef = isValidElement(children) && children.props && children.props.ref ? children.props.ref : null;
78167
78280
  const mergedRef = useMergeRefs([refs.setReference, childRef]);
78168
78281
  if (isValidElement(children)) {
@@ -78178,6 +78291,10 @@ const Tooltip = ({
78178
78291
  const mergedProps = {
78179
78292
  ...childProps,
78180
78293
  ref: mergedRef,
78294
+ onClick: mergeEventHandler(
78295
+ childProps.onClick,
78296
+ handleMobileClick
78297
+ ),
78181
78298
  onMouseEnter: mergeEventHandler(
78182
78299
  childProps.onMouseEnter,
78183
78300
  tooltipProps.onMouseEnter
@@ -78203,11 +78320,11 @@ const Tooltip = ({
78203
78320
  ref: refs.setFloating,
78204
78321
  style: floatingStyles,
78205
78322
  ...getFloatingProps(),
78206
- className: styles$2R.tooltip,
78323
+ className: styles$2S.tooltip,
78207
78324
  children: /* @__PURE__ */ jsx(
78208
78325
  motion.div,
78209
78326
  {
78210
- className: clsx(styles$2R.tooltipContent, className),
78327
+ className: clsx(styles$2S.tooltipContent, className),
78211
78328
  variants,
78212
78329
  initial: shouldReduceMotion ? void 0 : "initial",
78213
78330
  animate: shouldReduceMotion ? void 0 : "animate",
@@ -78226,6 +78343,7 @@ const Tooltip = ({
78226
78343
  {
78227
78344
  ref: refs.setReference,
78228
78345
  ...getReferenceProps(),
78346
+ onClick: handleMobileClick,
78229
78347
  style: { display: "contents" },
78230
78348
  children
78231
78349
  }
@@ -78236,11 +78354,11 @@ const Tooltip = ({
78236
78354
  ref: refs.setFloating,
78237
78355
  style: floatingStyles,
78238
78356
  ...getFloatingProps(),
78239
- className: styles$2R.tooltip,
78357
+ className: styles$2S.tooltip,
78240
78358
  children: /* @__PURE__ */ jsx(
78241
78359
  motion.div,
78242
78360
  {
78243
- className: clsx(styles$2R.tooltipContent, className),
78361
+ className: clsx(styles$2S.tooltipContent, className),
78244
78362
  variants,
78245
78363
  initial: shouldReduceMotion ? void 0 : "initial",
78246
78364
  animate: shouldReduceMotion ? void 0 : "animate",
@@ -78254,15 +78372,15 @@ const Tooltip = ({
78254
78372
  ] });
78255
78373
  };
78256
78374
 
78257
- const root$2E = "_root_1uu8h_1";
78375
+ const root$2F = "_root_1uu8h_1";
78258
78376
  const label$8 = "_label_1uu8h_21";
78259
78377
  const input$m = "_input_1uu8h_28";
78260
78378
  const output = "_output_1uu8h_88";
78261
78379
  const valueTrack = "_valueTrack_1uu8h_90";
78262
78380
  const outputValues = "_outputValues_1uu8h_91";
78263
78381
  const outputValue = "_outputValue_1uu8h_91";
78264
- const styles$2Q = {
78265
- root: root$2E,
78382
+ const styles$2R = {
78383
+ root: root$2F,
78266
78384
  label: label$8,
78267
78385
  input: input$m,
78268
78386
  output: output,
@@ -78302,18 +78420,18 @@ const TooltipRangeSlider = () => {
78302
78420
  return /* @__PURE__ */ jsxs(
78303
78421
  "form",
78304
78422
  {
78305
- className: styles$2Q.root,
78423
+ className: styles$2R.root,
78306
78424
  action: "",
78307
78425
  style: {
78308
78426
  "--percent": `${percent}%`,
78309
78427
  "--transX": `${transX}em`
78310
78428
  },
78311
78429
  children: [
78312
- /* @__PURE__ */ jsx("label", { className: styles$2Q.label, htmlFor: "dummy", children: "Range" }),
78430
+ /* @__PURE__ */ jsx("label", { className: styles$2R.label, htmlFor: "dummy", children: "Range" }),
78313
78431
  /* @__PURE__ */ jsx(
78314
78432
  "input",
78315
78433
  {
78316
- className: styles$2Q.input,
78434
+ className: styles$2R.input,
78317
78435
  type: "range",
78318
78436
  value,
78319
78437
  min: min$1,
@@ -78322,12 +78440,12 @@ const TooltipRangeSlider = () => {
78322
78440
  onChange: update
78323
78441
  }
78324
78442
  ),
78325
- /* @__PURE__ */ jsx("div", { className: styles$2Q.output, "aria-hidden": "true", children: /* @__PURE__ */ jsx("div", { className: styles$2Q.valueTrack, children: /* @__PURE__ */ jsx("div", { className: styles$2Q.outputValues, children: useMemo(() => {
78443
+ /* @__PURE__ */ jsx("div", { className: styles$2R.output, "aria-hidden": "true", children: /* @__PURE__ */ jsx("div", { className: styles$2R.valueTrack, children: /* @__PURE__ */ jsx("div", { className: styles$2R.outputValues, children: useMemo(() => {
78326
78444
  const totalValues = (Math.abs(max$1) + Math.abs(min$1)) / step$2 + 1;
78327
78445
  const values = [];
78328
78446
  for (let i = min$1; i < totalValues; i += 1) {
78329
78447
  values.push(
78330
- /* @__PURE__ */ jsx("span", { className: styles$2Q.outputValue, children: i }, i)
78448
+ /* @__PURE__ */ jsx("span", { className: styles$2R.outputValue, children: i }, i)
78331
78449
  );
78332
78450
  }
78333
78451
  return values;
@@ -78337,6 +78455,17 @@ const TooltipRangeSlider = () => {
78337
78455
  );
78338
78456
  };
78339
78457
 
78458
+ const root$2E = "_root_1oncf_1";
78459
+ const block = "_block_1oncf_4";
78460
+ const item$g = "_item_1oncf_14";
78461
+ const gloss = "_gloss_1oncf_31";
78462
+ const styles$2Q = {
78463
+ root: root$2E,
78464
+ block: block,
78465
+ item: item$g,
78466
+ gloss: gloss
78467
+ };
78468
+
78340
78469
  const baseWidth = 48;
78341
78470
  const distanceLimit = baseWidth * 5;
78342
78471
  const distanceInput = [
@@ -78451,7 +78580,7 @@ const DockMotionItem = ({
78451
78580
  const isInteractive = rest.use !== "div";
78452
78581
  const ContentElement = useMemo(() => {
78453
78582
  if (rest.use && typeof rest.use !== "string") {
78454
- return motion(rest.use);
78583
+ return motion.create(rest.use);
78455
78584
  }
78456
78585
  switch (rest.use) {
78457
78586
  case "a":
@@ -78471,13 +78600,13 @@ const DockMotionItem = ({
78471
78600
  "div",
78472
78601
  {
78473
78602
  ref,
78474
- className: clsx(styles$2S.root, { [styles$2S.block]: type === "block" }),
78603
+ className: clsx(styles$2Q.root, { [styles$2Q.block]: type === "block" }),
78475
78604
  children: /* @__PURE__ */ jsxs(
78476
78605
  ContentElement,
78477
78606
  {
78478
78607
  ref: scope,
78479
78608
  layoutId: itemId,
78480
- className: clsx(styles$2S.item, className),
78609
+ className: clsx(styles$2Q.item, className),
78481
78610
  onMouseEnter,
78482
78611
  style: contentStyle,
78483
78612
  "data-action": isInteractive,
@@ -78527,7 +78656,7 @@ const DockMotionItem = ({
78527
78656
  whileDrag: { zIndex: 1 },
78528
78657
  ...linkProps,
78529
78658
  children: [
78530
- /* @__PURE__ */ jsx("div", { className: styles$2S.gloss }),
78659
+ /* @__PURE__ */ jsx("div", { className: styles$2Q.gloss }),
78531
78660
  children
78532
78661
  ]
78533
78662
  },
@@ -80622,7 +80751,7 @@ const EndlessLoader = ({ container }) => {
80622
80751
  return;
80623
80752
  }
80624
80753
  try {
80625
- const GLModule = await import('./gl-BRR71tEA.js');
80754
+ const GLModule = await import('./gl-Bd0Q7rQc.js');
80626
80755
  if (!isActiveRef.current) {
80627
80756
  return;
80628
80757
  }
@@ -86530,11 +86659,11 @@ const ScrambledText = ({ children, reveal = false }) => {
86530
86659
  );
86531
86660
  };
86532
86661
 
86533
- const root$Y = "_root_1d8jp_1";
86534
- const line = "_line_1d8jp_9";
86535
- const word$1 = "_word_1d8jp_14";
86536
- const link = "_link_1d8jp_18";
86537
- const letter = "_letter_1d8jp_22";
86662
+ const root$Y = "_root_j4qg1_1";
86663
+ const line = "_line_j4qg1_9";
86664
+ const word$1 = "_word_j4qg1_14";
86665
+ const link = "_link_j4qg1_18";
86666
+ const letter = "_letter_j4qg1_22";
86538
86667
  const styles$11 = {
86539
86668
  root: root$Y,
86540
86669
  line: line,
@@ -96488,7 +96617,7 @@ const Lock = () => {
96488
96617
  }
96489
96618
  };
96490
96619
  const asynchronously = async () => {
96491
- const Flickity = await import('./index-DZDOztP9.js').then(n => n.i).then((m) => m.default);
96620
+ const Flickity = await import('./index-DrWf0hU5.js').then(n => n.i).then((m) => m.default);
96492
96621
  if (!rowsRef.current || !window) return;
96493
96622
  const rows = rowsRef.current.children;
96494
96623
  for (let i = 0, len = rows.length; i < len; i++) {
@@ -102288,6 +102417,34 @@ function useDrag(handler, config) {
102288
102417
  }, config || {}, 'drag');
102289
102418
  }
102290
102419
 
102420
+ function normalize(value, min, max) {
102421
+ return (value - min) / (max - min);
102422
+ }
102423
+ function calculateDistance(coordinates1, coordinates2) {
102424
+ const h = coordinates1.x - coordinates2.x;
102425
+ const v = coordinates1.y - coordinates2.y;
102426
+ return Math.sqrt(h * h + v * v);
102427
+ }
102428
+ function calculateAngle(coordinates1, coordinates2) {
102429
+ let theta = 0;
102430
+ const dy = coordinates2.y - coordinates1.y;
102431
+ const dx = coordinates2.x - coordinates1.x;
102432
+ theta = Math.atan2(dy, dx);
102433
+ theta *= 180 / Math.PI;
102434
+ return theta;
102435
+ }
102436
+ function getGlowLayers(factor, intensity) {
102437
+ const glowMap = [1, 2, 7, 14, 24, 42, 86, 124];
102438
+ const scale = intensity * factor;
102439
+ const glowLayers = Array.from({ length: 8 }, (_, i) => {
102440
+ return {
102441
+ radius: scale * glowMap[i],
102442
+ opacity: i > 0 ? 1 / i : 1
102443
+ };
102444
+ });
102445
+ return glowLayers;
102446
+ }
102447
+
102291
102448
  const root$h = "_root_1xwkj_1";
102292
102449
  const sun = "_sun_1xwkj_9";
102293
102450
  const moon = "_moon_1xwkj_20";
@@ -102341,34 +102498,6 @@ const BaileysBead = ({ theta, offset = 0, opa }) => {
102341
102498
  );
102342
102499
  };
102343
102500
 
102344
- function normalize(value, min, max) {
102345
- return (value - min) / (max - min);
102346
- }
102347
- function calculateDistance(coordinates1, coordinates2) {
102348
- const h = coordinates1.x - coordinates2.x;
102349
- const v = coordinates1.y - coordinates2.y;
102350
- return Math.sqrt(h * h + v * v);
102351
- }
102352
- function calculateAngle(coordinates1, coordinates2) {
102353
- let theta = 0;
102354
- const dy = coordinates2.y - coordinates1.y;
102355
- const dx = coordinates2.x - coordinates1.x;
102356
- theta = Math.atan2(dy, dx);
102357
- theta *= 180 / Math.PI;
102358
- return theta;
102359
- }
102360
- function getGlowLayers(factor, intensity) {
102361
- const glowMap = [1, 2, 7, 14, 24, 42, 86, 124];
102362
- const scale = intensity * factor;
102363
- const glowLayers = Array.from({ length: 8 }, (_, i) => {
102364
- return {
102365
- radius: scale * glowMap[i],
102366
- opacity: i > 0 ? 1 / i : 1
102367
- };
102368
- });
102369
- return glowLayers;
102370
- }
102371
-
102372
102501
  const SolarEclipse = () => {
102373
102502
  const [theta, setTheta] = useState(0);
102374
102503
  const [obscurity, setObscurity] = useState(0);