@pieai/swimmer-ui-kit 2.10.0 → 2.11.0

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.
@@ -1 +1 @@
1
- :root{--game-ui-assistance-z:96;--game-ui-liquid-reveal-bg:#050c0df0;--game-ui-liquid-reveal-solid:#101718;--game-ui-liquid-reveal-text:#f2f7f4;--game-ui-liquid-reveal-muted:#b6c7c0;--game-ui-liquid-reveal-shadow:0 22px 70px #00000038;--game-ui-liquid-reveal-backdrop:#0000003d;--game-ui-liquid-action-face:#fff8ec;--game-ui-liquid-action-ink:#403127;--game-ui-liquid-action-lip:#ae9e87;--game-ui-liquid-action-border:#dccdb9;--game-ui-liquid-field-face:#0000003d;--game-ui-liquid-material-ink:#020a08;--game-ui-liquid-material-muted:#020a08;--game-ui-liquid-material-field:#104a41;--game-ui-liquid-field-ink:#f2f7f4}.game-ui-liquid-reveal .game-ui-button--secondary{background:var(--game-ui-liquid-action-face);color:var(--game-ui-liquid-action-ink);border:1px solid var(--game-ui-liquid-action-border);--game-ui-button-lip-ink:var(--game-ui-liquid-action-lip);--game-ui-shadow-button:inset 0 1px 0 color-mix(in srgb, var(--game-ui-liquid-action-face) 90%, transparent)}.game-ui-liquid-reveal .game-ui-button:disabled{opacity:.55}.game-ui-liquid-reveal .game-ui-button--ghost{color:var(--game-ui-liquid-reveal-muted)}.game-ui-liquid-reveal{isolation:isolate;min-width:0;color:var(--game-ui-liquid-reveal-text);font-family:var(--game-ui-font-body);border-radius:32px;position:relative}.game-ui-liquid-reveal:before{content:"";z-index:-1;background:var(--game-ui-liquid-reveal-bg);backdrop-filter:blur(8px);box-shadow:var(--game-ui-liquid-reveal-shadow);pointer-events:none;border-radius:27px;position:absolute;inset:6px}.game-ui-liquid-reveal-content{z-index:1;min-width:0;padding:12px;position:relative}.game-ui-liquid-reveal[data-reveal-surface=material]{--game-ui-liquid-reveal-text:var(--game-ui-liquid-material-ink);--game-ui-liquid-reveal-muted:var(--game-ui-liquid-material-muted);--game-ui-liquid-field-face:var(--game-ui-liquid-material-field)}.game-ui-liquid-reveal[data-reveal-surface=material]:before{backdrop-filter:none;background:0 0}.game-ui-liquid-reveal[data-reveal-surface=material][data-reveal-motion=preparing] .game-ui-liquid-reveal-content,.game-ui-liquid-reveal[data-reveal-surface=material][data-reveal-motion=preparing] .game-ui-liquid-reveal-ink{opacity:0}.game-ui-liquid-reveal[data-reveal-surface=material]:is([data-reveal-motion=preparing],[data-reveal-motion=drawing]):before{box-shadow:none}.game-ui-liquid-reveal[data-reveal-filter=flat]:before{backdrop-filter:none;background:var(--game-ui-liquid-reveal-solid)}.game-ui-liquid-reveal-ink{pointer-events:none;position:absolute;inset:0;overflow:visible}.game-ui-liquid-reveal[data-reveal-variant=input]{border-radius:36px}.game-ui-liquid-reveal[data-reveal-variant=input]:before{border-radius:30px}@media (forced-colors:active){.game-ui-liquid-reveal{color:canvastext;border:2px solid canvastext}.game-ui-liquid-reveal:before{box-shadow:none;backdrop-filter:none;background:canvas}.game-ui-liquid-reveal[data-reveal-surface=material]{--game-ui-liquid-reveal-text:CanvasText;--game-ui-liquid-reveal-muted:CanvasText;--game-ui-liquid-field-ink:CanvasText;--game-ui-liquid-field-face:Canvas}.game-ui-liquid-reveal[data-reveal-surface=material]:before{background:canvas}.game-ui-liquid-reveal-ink{display:none}}.game-ui-liquid-presence{--liquid-presence-from:var(--game-ui-secondary);--liquid-presence-to:var(--game-ui-secondary);vertical-align:middle;pointer-events:none;color:var(--game-ui-secondary);flex:none;line-height:0;display:inline-block;position:relative}.game-ui-liquid-presence>svg{width:100%;height:100%;display:block;overflow:visible}.game-ui-liquid-presence[data-activity=disabled]{opacity:.5}.game-ui-liquid-presence[data-activity=error],.game-ui-liquid-presence[data-activity=unknown]{--liquid-presence-from:var(--game-ui-warning);--liquid-presence-to:var(--game-ui-warning)}.game-ui-liquid-presence-overlay{z-index:95;pointer-events:none;color:var(--game-ui-secondary);position:fixed;inset:0;overflow:visible}.game-ui-liquid-presence-overlay>[hidden]{display:none!important}.game-ui-liquid-presence-flight,.game-ui-liquid-presence-seat{transform-origin:50%;position:absolute;top:0;left:0;overflow:visible}.game-ui-liquid-presence-flight{width:96px;height:72px}.game-ui-liquid-presence-seat{width:112px;height:56px}.game-ui-liquid-presence-label{box-sizing:border-box;border-radius:var(--game-ui-radius-control,12px);background:var(--game-ui-panel-strong);width:max-content;max-width:min(260px,100vw - 32px);color:var(--game-ui-text);box-shadow:var(--game-ui-shadow-button);font:500 13px/1.5 var(--game-ui-font-body);overflow-wrap:anywhere;text-wrap:pretty;padding:9px 14px;position:absolute;top:0;left:0}.game-ui-liquid-presence-label--guide{overscroll-behavior:contain;pointer-events:auto;text-wrap:wrap;border-radius:16px;width:300px;max-width:calc(100vw - 32px);max-height:min(300px,42dvh);padding:16px;overflow:auto}.game-ui-liquid-presence-label--expanded{flex-direction:column;width:420px;max-height:min(560px,65dvh);display:flex}@media (prefers-reduced-motion:reduce){.game-ui-liquid-presence-flight{display:none}}@media (forced-colors:active){.game-ui-liquid-presence svg g,.game-ui-liquid-presence-overlay svg g,.game-ui-liquid-presence-overlay svg path{filter:none;fill:highlight}.game-ui-liquid-presence-label{color:canvastext;box-shadow:none;background:canvas;border:1px solid canvastext}}.game-ui-liquid-anchor{z-index:var(--game-ui-assistance-z,95);width:max-content}
1
+ @layer swimmer-ui{.game-ui-button[data-game-ui-control=liquid-presence]{box-shadow:none;color:inherit;background:0 0;border:0;border-radius:50%;padding:0}.game-ui-button[data-game-ui-control=liquid-presence]:is(:hover,:active){transform:translate(0,0)scale(1)}:root{--game-ui-assistance-z:96;--game-ui-liquid-reveal-bg:#050c0df0;--game-ui-liquid-reveal-solid:#101718;--game-ui-liquid-reveal-text:#f2f7f4;--game-ui-liquid-reveal-muted:#b6c7c0;--game-ui-liquid-reveal-shadow:0 22px 70px #00000038;--game-ui-liquid-reveal-backdrop:#0000003d;--game-ui-liquid-action-face:#fff8ec;--game-ui-liquid-action-ink:#403127;--game-ui-liquid-action-lip:#ae9e87;--game-ui-liquid-action-border:#dccdb9;--game-ui-liquid-field-face:#0000003d;--game-ui-liquid-material-ink:#020a08;--game-ui-liquid-material-muted:#020a08;--game-ui-liquid-material-field:#104a41;--game-ui-liquid-field-ink:#f2f7f4}.game-ui-liquid-reveal .game-ui-button--secondary{background:var(--game-ui-liquid-action-face);color:var(--game-ui-liquid-action-ink);border:1px solid var(--game-ui-liquid-action-border);--game-ui-button-lip-ink:var(--game-ui-liquid-action-lip);--game-ui-shadow-button:inset 0 1px 0 color-mix(in srgb, var(--game-ui-liquid-action-face) 90%, transparent)}.game-ui-liquid-reveal .game-ui-button:disabled{opacity:.55}.game-ui-liquid-reveal .game-ui-button--ghost{color:var(--game-ui-liquid-reveal-muted)}.game-ui-liquid-reveal{isolation:isolate;min-width:0;color:var(--game-ui-liquid-reveal-text);font-family:var(--game-ui-font-body);border-radius:32px;position:relative}.game-ui-liquid-reveal:before{content:"";z-index:-1;background:var(--game-ui-liquid-reveal-bg);backdrop-filter:blur(8px);box-shadow:var(--game-ui-liquid-reveal-shadow);pointer-events:none;border-radius:27px;position:absolute;inset:6px}.game-ui-liquid-reveal-content{z-index:1;min-width:0;padding:12px;position:relative}.game-ui-liquid-reveal[data-reveal-surface=material]{--game-ui-liquid-reveal-text:var(--game-ui-liquid-material-ink);--game-ui-liquid-reveal-muted:var(--game-ui-liquid-material-muted);--game-ui-liquid-field-face:var(--game-ui-liquid-material-field)}.game-ui-liquid-reveal[data-reveal-surface=material]:before{backdrop-filter:none;background:0 0}.game-ui-liquid-reveal[data-reveal-surface=material][data-reveal-motion=preparing] .game-ui-liquid-reveal-content,.game-ui-liquid-reveal[data-reveal-surface=material][data-reveal-motion=preparing] .game-ui-liquid-reveal-ink{opacity:0}.game-ui-liquid-reveal[data-reveal-surface=material]:is([data-reveal-motion=preparing],[data-reveal-motion=drawing]):before{box-shadow:none}.game-ui-liquid-reveal[data-reveal-filter=flat]:before{backdrop-filter:none;background:var(--game-ui-liquid-reveal-solid)}.game-ui-liquid-reveal-ink{pointer-events:none;position:absolute;inset:0;overflow:visible}.game-ui-liquid-reveal[data-reveal-variant=input]{border-radius:36px}.game-ui-liquid-reveal[data-reveal-variant=input]:before{border-radius:30px}@media (forced-colors:active){.game-ui-liquid-reveal{color:canvastext;border:2px solid canvastext}.game-ui-liquid-reveal:before{box-shadow:none;backdrop-filter:none;background:canvas}.game-ui-liquid-reveal[data-reveal-surface=material]{--game-ui-liquid-reveal-text:CanvasText;--game-ui-liquid-reveal-muted:CanvasText;--game-ui-liquid-field-ink:CanvasText;--game-ui-liquid-field-face:Canvas}.game-ui-liquid-reveal[data-reveal-surface=material]:before{background:canvas}.game-ui-liquid-reveal-ink{display:none}}.game-ui-liquid-presence{--liquid-presence-from:var(--game-ui-secondary);--liquid-presence-to:var(--game-ui-secondary);vertical-align:middle;pointer-events:none;color:var(--game-ui-secondary);flex:none;line-height:0;display:inline-block;position:relative}.game-ui-liquid-presence>svg{width:100%;height:100%;display:block;overflow:visible}.game-ui-liquid-presence[data-activity=disabled]{opacity:.5}.game-ui-liquid-presence[data-activity=error],.game-ui-liquid-presence[data-activity=unknown]{--liquid-presence-from:var(--game-ui-warning);--liquid-presence-to:var(--game-ui-warning)}.game-ui-liquid-presence-overlay{z-index:95;pointer-events:none;color:var(--game-ui-secondary);position:fixed;inset:0;overflow:visible}.game-ui-liquid-presence-overlay>[hidden]{display:none!important}.game-ui-liquid-presence-flight,.game-ui-liquid-presence-seat{transform-origin:50%;position:absolute;top:0;left:0;overflow:visible}.game-ui-liquid-presence-flight{width:96px;height:72px}.game-ui-liquid-presence-seat{width:112px;height:56px}.game-ui-liquid-presence-label{box-sizing:border-box;border-radius:var(--game-ui-radius-control,12px);background:var(--game-ui-panel-strong);width:max-content;max-width:min(260px,100vw - 32px);color:var(--game-ui-text);box-shadow:var(--game-ui-shadow-button);font:500 13px/1.5 var(--game-ui-font-body);overflow-wrap:anywhere;text-wrap:pretty;padding:9px 14px;position:absolute;top:0;left:0}.game-ui-liquid-presence-label--guide{overscroll-behavior:contain;pointer-events:auto;text-wrap:wrap;border-radius:16px;width:300px;max-width:calc(100vw - 32px);max-height:min(300px,42dvh);padding:16px;overflow:auto}.game-ui-liquid-presence-label--expanded{flex-direction:column;width:420px;max-height:min(560px,65dvh);display:flex}@media (prefers-reduced-motion:reduce){.game-ui-liquid-presence-flight{display:none}}@media (forced-colors:active){.game-ui-liquid-presence svg g,.game-ui-liquid-presence-overlay svg g,.game-ui-liquid-presence-overlay svg path{filter:none;fill:highlight}.game-ui-liquid-presence-label{color:canvastext;box-shadow:none;background:canvas;border:1px solid canvastext}}.game-ui-liquid-anchor{z-index:var(--game-ui-assistance-z,95);width:max-content}}
@@ -232,34 +232,34 @@ var V = (e, t, n) => {
232
232
  let r = String(n);
233
233
  e.getAttribute(t) !== r && e.setAttribute(t, r);
234
234
  };
235
- function H(e, t, n) {
235
+ function re(e, t, n) {
236
236
  let r = e.overlay.getBoundingClientRect(), i = r.width / (e.overlay.clientWidth || r.width || 1) || 1, a = r.height / (e.overlay.clientHeight || r.height || 1) || 1;
237
237
  return {
238
238
  x: (t - r.x) / i,
239
239
  y: (n - r.y) / a
240
240
  };
241
241
  }
242
- function re(e, t, n, r, i = 0, a = 1, o = !1, s = 0) {
242
+ function ie(e, t, n, r, i = 0, a = 1, o = !1, s = 0) {
243
243
  V(e.source, "data-liquid-phase", t.phase), V(e.overlay, "data-liquid-phase", t.phase), V(e.body, "d", M(r, i, t.separation, a, s));
244
244
  let c = t.bud ? Math.sin(t.separation * Math.PI) * .045 : 0;
245
245
  V(e.body, "transform", `translate(${((t.bud?.x ?? 80) - 80) * c} ${((t.bud?.y ?? 80) - 80) * c})`), B(e.bud, !!t.bud), t.bud && (V(e.bud, "cx", t.bud.x), V(e.bud, "cy", t.bud.y), V(e.bud, "r", t.bud.radius));
246
246
  let l = t.phase === "flight" || t.phase === "return";
247
247
  B(e.flight, l);
248
- let u = H(e, t.point.x, t.point.y);
248
+ let u = re(e, t.point.x, t.point.y);
249
249
  if (l) {
250
250
  let n = t.diameter / 32;
251
251
  e.flight.style.transform = `translate(${u.x - 48}px, ${u.y - 36}px)`, V(e.flightBody, "transform", `rotate(${t.angle}) scale(${n * t.stretch} ${n / Math.sqrt(t.stretch)})`), V(e.trail, "opacity", Math.min(.8, (t.stretch - 1) * 3));
252
252
  }
253
253
  B(e.seat, t.seat !== null), t.seat !== null && (e.seat.style.transform = `translate(${u.x - 56}px, ${u.y - 28}px)`, V(e.seatBody, "d", N(t.seatWidth ?? n, t.seat, t.diameter))), B(e.label, o || t.phase !== "gather" && t.seat !== null && t.seat > .45);
254
254
  }
255
- function ie(e, t, n, r) {
255
+ function ae(e, t, n, r) {
256
256
  e.satellites.forEach((e, i) => {
257
257
  if (B(e, n), !n) return;
258
258
  let a = t * .7 + i * Math.PI * 2 / 3, o = 63 + Math.max(0, Math.sin(t * 1.6 + i * 2)) * (16 + r * 12);
259
259
  V(e, "cx", 80 + Math.cos(a) * o), V(e, "cy", 80 + Math.sin(a) * o), V(e, "r", 7 + i * 1.5);
260
260
  });
261
261
  }
262
- function U() {
262
+ function H() {
263
263
  let e = window.visualViewport;
264
264
  return {
265
265
  x: e?.offsetLeft ?? 0,
@@ -270,23 +270,23 @@ function U() {
270
270
  }
271
271
  //#endregion
272
272
  //#region src/liquidPresenceTracking.ts
273
- function ae(e) {
273
+ function oe(e) {
274
274
  try {
275
275
  let t = e.contextElement;
276
276
  if (t && t.ownerDocument !== document || t && (!t.isConnected || t.closest("[hidden], [inert]")) || t && getComputedStyle(t).visibility === "hidden") return null;
277
277
  let n = document.querySelector("dialog:modal");
278
278
  if (n && (!t || !n.contains(t))) return null;
279
279
  let r = e.getRect();
280
- return E(r) && D(r, U()) ? r : null;
280
+ return E(r) && D(r, H()) ? r : null;
281
281
  } catch {
282
282
  return null;
283
283
  }
284
284
  }
285
- function oe(e, t, n, r) {
285
+ function se(e, t, n, r) {
286
286
  let i = t.contextElement, a = {
287
287
  ...i ? { contextElement: i } : {},
288
288
  getBoundingClientRect: () => {
289
- let e = ae(t) ?? {
289
+ let e = oe(t) ?? {
290
290
  x: 0,
291
291
  y: 0,
292
292
  width: 0,
@@ -343,8 +343,60 @@ function oe(e, t, n, r) {
343
343
  };
344
344
  }
345
345
  //#endregion
346
+ //#region src/liquidPanelObstacles.ts
347
+ var U = /* @__PURE__ */ new Map(), W = /* @__PURE__ */ new Set();
348
+ function G(e, t) {
349
+ let n = U.get(e), r = t && E(t) ? {
350
+ x: t.x,
351
+ y: t.y,
352
+ width: t.width,
353
+ height: t.height
354
+ } : null;
355
+ if (!(!n && !r || n && r && n.x === r.x && n.y === r.y && n.width === r.width && n.height === r.height)) {
356
+ r ? U.set(e, r) : U.delete(e);
357
+ for (let e of [...W]) try {
358
+ e();
359
+ } catch {}
360
+ }
361
+ }
362
+ function ce(e) {
363
+ return [...U].filter(([t]) => t.isConnected && !t.contains(e) && !e.contains(t)).map(([, e]) => e);
364
+ }
365
+ function le(e) {
366
+ return W.add(e), () => {
367
+ W.delete(e);
368
+ };
369
+ }
370
+ function ue(e, t, n, r) {
371
+ let { width: i, height: a } = t;
372
+ if (!Number.isFinite(i + a) || i <= 0 || a <= 0) return null;
373
+ let o = n.x + 12, s = n.y + 12, c = n.x + n.width - i - 12, l = n.y + n.height - a - 12;
374
+ if (c < o || l < s) return null;
375
+ let u = r.filter(E), d = [
376
+ e.x,
377
+ o,
378
+ c
379
+ ], f = [
380
+ e.y,
381
+ s,
382
+ l
383
+ ];
384
+ for (let e of u) d.push(e.x - i - 8, e.x + e.width + 8), f.push(e.y - a - 8, e.y + e.height + 8);
385
+ let p = null, m = Infinity;
386
+ for (let t of d) for (let n of f) {
387
+ let r = Math.min(c, Math.max(o, t)), d = Math.min(l, Math.max(s, n));
388
+ if (u.some((e) => r < e.x + e.width + 8 && r + i > e.x - 8 && d < e.y + e.height + 8 && d + a > e.y - 8)) continue;
389
+ let f = (r - e.x) ** 2 + (d - e.y) ** 2;
390
+ f < m && (p = {
391
+ x: r,
392
+ y: d
393
+ }, m = f);
394
+ }
395
+ return p;
396
+ }
397
+ //#endregion
346
398
  //#region src/useLiquidPresenceMotion.ts
347
- function W(t, n, i, o) {
399
+ function K(t, n, i, o) {
348
400
  let s = d(i);
349
401
  s.current = i;
350
402
  let l = !!i.guideContent, u = d(null), f = d(null), p = d(null), m = d(0), h = d(+(i.idleMotion === "breathe")), g = d(() => {});
@@ -371,36 +423,36 @@ function W(t, n, i, o) {
371
423
  "land",
372
424
  "gather",
373
425
  "return"
374
- ].includes(d.phase) ? d.point : void 0, x = d?.point ?? O(i.getBoundingClientRect()), E = d?.seatWidth ?? 48, k = d ?? void 0, j = i.getBoundingClientRect(), M = performance.now(), N = null, P = () => {}, F = !0, I = !1, L = !1, R = !0, z = 0, V = m.current, H = performance.now(), W = 0, G = 0, K = null, q = () => {}, J, Y = () => {
426
+ ].includes(d.phase) ? d.point : void 0, x = d?.point ?? O(i.getBoundingClientRect()), E = d?.seatWidth ?? 48, k = d ?? void 0, j = i.getBoundingClientRect(), M = performance.now(), N = null, P = () => {}, F = !0, I = !1, L = !1, R = !0, z = 0, V = m.current, re = performance.now(), U = 0, W = 0, G = null, K = () => {}, q, J = () => {
375
427
  I && r(), I = !1;
376
- }, X = (e) => {
428
+ }, Y = (e) => {
377
429
  if (l) {
378
- f.current = l.key, l = null, _ = !!(u.current && u.current.phase !== "still"), k = u.current ?? void 0, v = u.current?.point, x = v ?? x, M = performance.now(), q(), clearTimeout(J), G++, B(c.label, !1);
430
+ f.current = l.key, l = null, _ = !!(u.current && u.current.phase !== "still"), k = u.current ?? void 0, v = u.current?.point, x = v ?? x, M = performance.now(), K(), clearTimeout(q), W++, B(c.label, !1);
379
431
  try {
380
432
  s.current.onDismiss?.(e);
381
433
  } catch {}
382
434
  $();
383
435
  }
384
- }, se = () => {
436
+ }, X = () => {
385
437
  if (!l) return null;
386
438
  let e = c.label.style.pointerEvents;
387
439
  s.current.guideContent && (c.label.style.pointerEvents = "none");
388
440
  try {
389
- return ae(s.current.target?.key === l.key ? s.current.target : l);
441
+ return oe(s.current.target?.key === l.key ? s.current.target : l);
390
442
  } finally {
391
443
  c.label.style.pointerEvents = e;
392
444
  }
393
445
  }, Z = () => {
394
446
  if (!l) return;
395
- let e = se();
447
+ let e = X();
396
448
  if (!e) {
397
- X("unavailable");
449
+ Y("unavailable");
398
450
  return;
399
451
  }
400
- let t = ee(e, U()), n = A(e, U()), r = (e) => T(e === "top" ? n.y - 10 : n.y + n.height + 10, U().y + 18, U().y + U().height - 18);
452
+ let t = ee(e, H()), n = A(e, H()), r = (e) => T(e === "top" ? n.y - 10 : n.y + n.height + 10, H().y + 18, H().y + H().height - 18);
401
453
  x = {
402
454
  x: t.x,
403
- y: r(K ?? t.side)
455
+ y: r(G ?? t.side)
404
456
  }, E = t.width;
405
457
  let i = {
406
458
  ...l.contextElement ? { contextElement: l.contextElement } : {},
@@ -411,15 +463,15 @@ function W(t, n, i, o) {
411
463
  bottom: n.y + n.height,
412
464
  right: n.x + n.width
413
465
  })
414
- }, a = ++G, o = s.current.guideSize === "expanded";
466
+ }, a = ++W, o = s.current.guideSize === "expanded";
415
467
  o || (c.label.style.maxHeight = ""), s.current.guideContent && !c.label.style.transform && (c.label.style.visibility = "hidden", B(c.label, !0)), y(i, c.label, {
416
468
  strategy: "absolute",
417
- placement: o && U().width >= 900 ? "right" : t.side,
469
+ placement: o && H().width >= 900 ? "right" : t.side,
418
470
  middleware: [
419
471
  S(26),
420
472
  b({
421
473
  padding: 16,
422
- ...o && U().width >= 900 ? { fallbackPlacements: [
474
+ ...o && H().width >= 900 ? { fallbackPlacements: [
423
475
  "left",
424
476
  "bottom",
425
477
  "top"
@@ -432,18 +484,33 @@ function W(t, n, i, o) {
432
484
  ...o ? [w({
433
485
  padding: 16,
434
486
  apply({ availableHeight: e, elements: t }) {
435
- let n = `${Math.max(0, Math.min(560, U().height * .65, e))}px`;
487
+ let n = `${Math.max(0, Math.min(560, H().height * .65, e))}px`;
436
488
  t.floating.style.maxHeight !== n && (t.floating.style.maxHeight = n);
437
489
  }
438
490
  })] : []
439
491
  ]
440
- }).then(({ x: e, y: n, placement: i }) => {
441
- if (F && a === G) {
442
- c.label.style.transform = `translate(${e}px, ${n}px)`, c.label.style.visibility = "", K = i.startsWith("top") ? "top" : i.startsWith("bottom") ? "bottom" : t.side;
443
- let a = r(K);
444
- x.y !== a && (x = {
492
+ }).then(({ x: e, y: i, placement: o }) => {
493
+ if (F && a === W) {
494
+ let a = ce(c.label);
495
+ if (a.length && c.label.offsetWidth && c.label.offsetHeight) {
496
+ let t = ue({
497
+ x: e,
498
+ y: i
499
+ }, {
500
+ width: c.label.offsetWidth,
501
+ height: c.label.offsetHeight
502
+ }, H(), [...a, n]);
503
+ if (!t) {
504
+ c.label.style.visibility = "hidden";
505
+ return;
506
+ }
507
+ e = t.x, i = t.y;
508
+ }
509
+ c.label.style.transform = `translate(${e}px, ${i}px)`, c.label.style.visibility = "", G = o.startsWith("top") ? "top" : o.startsWith("bottom") ? "bottom" : t.side;
510
+ let s = r(G);
511
+ x.y !== s && (x = {
445
512
  x: t.x,
446
- y: a
513
+ y: s
447
514
  }, $());
448
515
  }
449
516
  }).catch(() => {});
@@ -453,31 +520,31 @@ function W(t, n, i, o) {
453
520
  "thinking",
454
521
  "speaking",
455
522
  "working"
456
- ].includes(s.current.activity ?? "idle"), ce = () => s.current.idleMotion === "breathe" && (s.current.activity ?? "idle") === "idle", le = () => {
457
- if (L = !1, s.current.reducedMotion || s.current.activity === "disabled" || document.hidden || !R || !D(i.getBoundingClientRect(), U())) return !1;
523
+ ].includes(s.current.activity ?? "idle"), de = () => s.current.idleMotion === "breathe" && (s.current.activity ?? "idle") === "idle", fe = () => {
524
+ if (L = !1, s.current.reducedMotion || s.current.activity === "disabled" || document.hidden || !R || !D(i.getBoundingClientRect(), H())) return !1;
458
525
  let t = document.querySelector("dialog:modal");
459
526
  if (t && !t.contains(i)) return !1;
460
527
  let n = l?.contextElement?.closest("dialog") ?? null;
461
528
  if (l && i.closest("dialog") !== n) return !1;
462
529
  let r = 13184 + (i.getBoundingClientRect().width * 2) ** 2, o = a();
463
- return o.maxAnimatedGroups === 0 || r > o.maxFilterArea ? (Y(), !1) : !(l || _ || Q()) && ce() && !I && o.activeGroups > 0 ? (L = !0, !1) : (I ||= e(r), I);
530
+ return o.maxAnimatedGroups === 0 || r > o.maxFilterArea ? (J(), !1) : !(l || _ || Q()) && de() && !I && o.activeGroups > 0 ? (L = !0, !1) : (I ||= e(r), I);
464
531
  };
465
- function ue(e) {
532
+ function pe(e) {
466
533
  if (!F || document.hidden) return;
467
534
  let t = c.source.getBoundingClientRect();
468
535
  if (!c.source.isConnected || c.source.closest("[hidden], [inert]") || t.width <= 0 || t.height <= 0) {
469
- _ = !1, u.current = null, X("unavailable"), B(c.label, !1), B(c.flight, !1), B(c.seat, !1), Y();
536
+ _ = !1, u.current = null, Y("unavailable"), B(c.label, !1), B(c.flight, !1), B(c.seat, !1), J();
470
537
  return;
471
538
  }
472
- if (l && !se()) {
473
- X("unavailable");
539
+ if (l && !X()) {
540
+ Y("unavailable");
474
541
  return;
475
542
  }
476
- let n = le(), r = ne({
543
+ let n = fe(), r = ne({
477
544
  elapsed: e - M,
478
545
  source: _ ? t : j,
479
546
  destination: x,
480
- viewport: U(),
547
+ viewport: H(),
481
548
  returning: _,
482
549
  ...v ? { from: v } : {},
483
550
  ...k ? { origin: k } : {}
@@ -496,61 +563,65 @@ function W(t, n, i, o) {
496
563
  seat: l ? 1 : null,
497
564
  separation: +!!l
498
565
  }), _ && r.phase === "still" && (_ = !1), l && r.phase === "dock" && (p.current = l.key);
499
- let i = !["still", "dock"].includes(r.phase), a = s.current.levelRef?.current, o = !i && ce(), d = Math.max(0, Math.min(160, e - H));
500
- H = e;
566
+ let i = !["still", "dock"].includes(r.phase), a = s.current.levelRef?.current, o = !i && de(), d = Math.max(0, Math.min(160, e - re));
567
+ re = e;
501
568
  let f = typeof a == "number" ? T(a, 0, 1) : 0;
502
- W += (f - W) * (1 - Math.exp(-d / (f > W ? 65 : 140)));
569
+ U += (f - U) * (1 - Math.exp(-d / (f > U ? 65 : 140)));
503
570
  let g = T(s.current.motionSpeed ?? 1, .5, 1.5), y = T(s.current.motionIntensity ?? 1, .25, 1.25);
504
571
  n && (i || Q() || o) && (V += d * (o ? 84e-5 : .00105) * g), m.current = V, n && (i || Q() || o) && (h.current += (+!!o - h.current) * (1 - Math.exp(-d / 500)));
505
- let b = n && Q() && !i ? .14 + W * .75 : i ? .2 : 0, S = c.label.hasAttribute("hidden");
506
- re(c, r, E, V, b, y, !!(s.current.guideContent && l), h.current), ie(c, V, n && s.current.splashes !== !1 && s.current.activity === "speaking" && r.phase === "still", W);
572
+ let b = n && Q() && !i ? .14 + U * .75 : i ? .2 : 0, S = c.label.hasAttribute("hidden");
573
+ ie(c, r, E, V, b, y, !!(s.current.guideContent && l), h.current), ae(c, V, n && s.current.splashes !== !1 && s.current.activity === "speaking" && r.phase === "still", U);
507
574
  let C = n && (i || Q()) ? "animated" : n && o ? "ambient" : "static";
508
575
  c.source.dataset.liquidMotion !== C && (c.source.dataset.liquidMotion = C), u.current = {
509
576
  ...r,
510
577
  seatWidth: r.phase === "gather" ? k?.seatWidth ?? E : E
511
- }, l && S && !c.label.hasAttribute("hidden") && Z(), n && (i || Q()) ? N = requestAnimationFrame(de) : (Y(), o && (n || L) && (P = te(() => {
512
- P = () => {}, F && !document.hidden && R && de(performance.now());
578
+ }, l && S && !c.label.hasAttribute("hidden") && Z(), n && (i || Q()) ? N = requestAnimationFrame(me) : (J(), o && (n || L) && (P = te(() => {
579
+ P = () => {}, F && !document.hidden && R && me(performance.now());
513
580
  }, L ? 250 : 1e3 / 12)));
514
581
  }
515
- function de(e) {
582
+ function me(e) {
516
583
  if (N = null, !F || document.hidden) {
517
- Y();
584
+ J();
518
585
  return;
519
586
  }
520
587
  if ((u.current?.phase === "still" || u.current?.phase === "dock") && e - z < 32) {
521
- N = requestAnimationFrame(de);
588
+ N = requestAnimationFrame(me);
522
589
  return;
523
590
  }
524
- z = e, ue(e);
591
+ z = e, pe(e);
525
592
  }
526
593
  function $() {
527
- !F || N !== null || document.hidden || (P(), P = () => {}, ue(performance.now()));
594
+ !F || N !== null || document.hidden || (P(), P = () => {}, pe(performance.now()));
528
595
  }
529
596
  g.current = $;
530
- let fe = () => {
531
- if (q(), q = () => {}, !l || document.hidden) return;
532
- let e = oe(c.source, l, c.label, () => {
597
+ let he = () => {
598
+ if (K(), K = () => {}, !l || document.hidden) return;
599
+ let e = se(c.source, l, c.label, () => {
533
600
  Z(), $();
534
601
  });
535
- q = e, l || e();
602
+ K = e, l || e();
536
603
  };
537
- l && (Z(), l && (fe(), l && !s.current.guideContent && (J = setTimeout(() => X("expired"), 12e3))));
538
- let pe = (e) => {
604
+ l && (Z(), l && (he(), l && !s.current.guideContent && (q = setTimeout(() => Y("expired"), 12e3))));
605
+ let ge = (e) => {
539
606
  if (e.key === "Escape" && !e.isComposing && l) {
540
607
  if (s.current.guideContent && e.target instanceof Node && c.label.contains(e.target)) return;
541
608
  let t = document.querySelector("dialog:modal");
542
609
  if (t && !t.contains(c.label)) return;
543
- s.current.guideContent && e.preventDefault(), X("dismissed");
610
+ s.current.guideContent && e.preventDefault(), Y("dismissed");
544
611
  }
545
- }, me = (e) => {
546
- s.current.dismissOnTargetClick !== !1 && l?.contextElement && e.target instanceof Node && l.contextElement.contains(e.target) && X("dismissed");
547
- }, he = () => {
548
- document.hidden ? (P(), P = () => {}, N !== null && cancelAnimationFrame(N), N = null, q(), G++, Y()) : (H = performance.now(), fe(), $());
549
- }, ge = typeof IntersectionObserver > "u" ? null : new IntersectionObserver((e) => {
550
- R = e[0]?.isIntersecting ?? !0, R || (P(), P = () => {}, N !== null && cancelAnimationFrame(N), N = null, Y()), $();
612
+ }, _e = (e) => {
613
+ s.current.dismissOnTargetClick !== !1 && l?.contextElement && e.target instanceof Node && l.contextElement.contains(e.target) && Y("dismissed");
614
+ }, ve = () => {
615
+ document.hidden ? (P(), P = () => {}, N !== null && cancelAnimationFrame(N), N = null, K(), W++, J()) : (re = performance.now(), he(), $());
616
+ }, ye = typeof IntersectionObserver > "u" ? null : new IntersectionObserver((e) => {
617
+ R = e[0]?.isIntersecting ?? !0, R || (P(), P = () => {}, N !== null && cancelAnimationFrame(N), N = null, J()), $();
618
+ });
619
+ ye?.observe(i), document.addEventListener("keydown", ge, !0), document.addEventListener("click", _e), document.addEventListener("visibilitychange", ve), document.addEventListener("close", $, !0), document.addEventListener("toggle", $, !0);
620
+ let be = le(() => {
621
+ Z(), $();
551
622
  });
552
- return ge?.observe(i), document.addEventListener("keydown", pe, !0), document.addEventListener("click", me), document.addEventListener("visibilitychange", he), document.addEventListener("close", $, !0), document.addEventListener("toggle", $, !0), $(), () => {
553
- F = !1, g.current = () => {}, G++, N !== null && cancelAnimationFrame(N), clearTimeout(J), P(), q(), ge?.disconnect(), Y(), document.removeEventListener("keydown", pe, !0), document.removeEventListener("click", me), document.removeEventListener("visibilitychange", he), document.removeEventListener("close", $, !0), document.removeEventListener("toggle", $, !0);
623
+ return $(), () => {
624
+ F = !1, g.current = () => {}, W++, N !== null && cancelAnimationFrame(N), clearTimeout(q), P(), K(), be(), ye?.disconnect(), J(), document.removeEventListener("keydown", ge, !0), document.removeEventListener("click", _e), document.removeEventListener("visibilitychange", ve), document.removeEventListener("close", $, !0), document.removeEventListener("toggle", $, !0);
554
625
  };
555
626
  }, [
556
627
  t,
@@ -571,7 +642,7 @@ function W(t, n, i, o) {
571
642
  }
572
643
  //#endregion
573
644
  //#region src/LiquidPresence.tsx
574
- function G(e) {
645
+ function q(e) {
575
646
  let t = s() || e.reducedMotion === !0, r = T(e.size ?? 64, 32, 224), i = `presence-${l().replace(/[^a-zA-Z0-9_-]/g, "")}`, a = d(null), o = d(null), [u, _] = f(null);
576
647
  c(() => {
577
648
  let t = e.target?.contextElement?.closest("dialog");
@@ -617,7 +688,7 @@ function G(e) {
617
688
  return r(), window.addEventListener("resize", r, { passive: !0 }), () => {
618
689
  i.disconnect(), window.removeEventListener("resize", r);
619
690
  };
620
- }, [u]), W(a, o, {
691
+ }, [u]), K(a, o, {
621
692
  ...e,
622
693
  size: r,
623
694
  reducedMotion: t
@@ -778,7 +849,7 @@ function G(e) {
778
849
  }
779
850
  //#endregion
780
851
  //#region src/liquidRevealGeometry.ts
781
- function K(e, n, r, a = 0, o = 1) {
852
+ function J(e, n, r, a = 0, o = 1) {
782
853
  let s = Math.max(44, e), c = Math.max(44, n), l = Math.min(28, (s - 12) / 2, (c - 12) / 2), u = i(6, 6, s - 12, c - 12, [
783
854
  l,
784
855
  l,
@@ -802,7 +873,7 @@ function K(e, n, r, a = 0, o = 1) {
802
873
  }
803
874
  //#endregion
804
875
  //#region src/useLiquidRevealAmbient.ts
805
- function q(t, n, i, o, s, l = 1, u = 1) {
876
+ function Y(t, n, i, o, s, l = 1, u = 1) {
806
877
  let f = d(0);
807
878
  return c(() => {
808
879
  let c = t.current;
@@ -821,7 +892,7 @@ function q(t, n, i, o, s, l = 1, u = 1) {
821
892
  }
822
893
  try {
823
894
  f.current += n * Math.PI * 2 * u / 1e4;
824
- let e = K(i, o, s, f.current, l);
895
+ let e = J(i, o, s, f.current, l);
825
896
  g?.setAttribute("d", e.outline), _?.setAttribute("d", e.outline), v?.setAttribute("d", e.ribbon), c.dataset.revealAmbient = "flowing";
826
897
  } finally {
827
898
  r();
@@ -847,14 +918,14 @@ function q(t, n, i, o, s, l = 1, u = 1) {
847
918
  }
848
919
  //#endregion
849
920
  //#region src/liquidRevealEntranceGeometry.ts
850
- var J = (e) => {
921
+ var X = (e) => {
851
922
  let t = Math.min(1, Math.max(0, e));
852
923
  return t * t * t * (10 + t * (-15 + 6 * t));
853
924
  };
854
- function Y(e, t, n, r, a, o, s = 1) {
855
- let c = K(e, t, n, 0, s).outline;
925
+ function Z(e, t, n, r, a, o, s = 1) {
926
+ let c = J(e, t, n, 0, s).outline;
856
927
  return Array.from({ length: 49 }, (l, u) => {
857
- let d = u / 48, f = J((d - .08) / .34), p = j(r, a, f, o), m = J((d - .39) / .46), h = J((d - .47) / .46), g = J((d - .3) / .14) * (1 - m), _ = 8 + 20 * J(d / .15) + 10 * g, v = 1 + Math.sin(f * Math.PI) * .35, y = a.x - r.x, b = a.y - r.y, x = Math.abs(y) > Math.abs(b), S = _ * (x ? v : 1 / Math.sqrt(v)), C = _ * (x ? 1 / Math.sqrt(v) : v), w = S + (e - 12 - S) * m, T = C + (t - 12 - C) * h, E = (p.x - S / 2) * (1 - m) + 6 * m, D = (p.y - C / 2) * (1 - h) + 6 * h, O = Math.min(w / 2, T / 2, 28 + 12 * (1 - h));
928
+ let d = u / 48, f = X((d - .08) / .34), p = j(r, a, f, o), m = X((d - .39) / .46), h = X((d - .47) / .46), g = X((d - .3) / .14) * (1 - m), _ = 8 + 20 * X(d / .15) + 10 * g, v = 1 + Math.sin(f * Math.PI) * .35, y = a.x - r.x, b = a.y - r.y, x = Math.abs(y) > Math.abs(b), S = _ * (x ? v : 1 / Math.sqrt(v)), C = _ * (x ? 1 / Math.sqrt(v) : v), w = S + (e - 12 - S) * m, T = C + (t - 12 - C) * h, E = (p.x - S / 2) * (1 - m) + 6 * m, D = (p.y - C / 2) * (1 - h) + 6 * h, O = Math.min(w / 2, T / 2, 28 + 12 * (1 - h));
858
929
  return {
859
930
  d: `path("${d >= .95 ? c : i(E, D, w, T, [
860
931
  O,
@@ -873,7 +944,7 @@ function Y(e, t, n, r, a, o, s = 1) {
873
944
  }
874
945
  //#endregion
875
946
  //#region src/useLiquidRevealEntrance.ts
876
- function X(t, n, i, a, o, s, c, l, f = 1) {
947
+ function Q(t, n, i, a, o, s, c, l, f = 1) {
877
948
  let p = d(null);
878
949
  u(() => {
879
950
  let u = t.current;
@@ -914,7 +985,7 @@ function X(t, n, i, a, o, s, c, l, f = 1) {
914
985
  height: innerHeight / w
915
986
  };
916
987
  if (c && s && CSS.supports("d", "path(\"M0 0L1 1Z\")")) {
917
- let e = Y(a, o, l, T, D, O, f);
988
+ let e = Z(a, o, l, T, D, O, f);
918
989
  v.push(s.animate(e, {
919
990
  duration: 720,
920
991
  fill: "both",
@@ -985,7 +1056,7 @@ function X(t, n, i, a, o, s, c, l, f = 1) {
985
1056
  }
986
1057
  //#endregion
987
1058
  //#region src/LiquidReveal.tsx
988
- function se({ children: e, source: t, revealKey: r = "initial", variant: i = "content", surface: o = "dark", reducedMotion: c, idleMotion: p = "still", colorFrom: m, colorTo: _, motionIntensity: v = 1, motionSpeed: y = 1, className: b = "" }) {
1059
+ function de({ children: e, source: t, revealKey: r = "initial", variant: i = "content", surface: o = "dark", reducedMotion: c, idleMotion: p = "still", colorFrom: m, colorTo: _, motionIntensity: v = 1, motionSpeed: y = 1, className: b = "" }) {
989
1060
  let x = s() || c === !0, S = T(v, .25, 1.25), C = T(y, .5, 1.5), w = d(null), [E, D] = f({
990
1061
  width: 0,
991
1062
  height: 0
@@ -1003,8 +1074,8 @@ function se({ children: e, source: t, revealKey: r = "initial", variant: i = "co
1003
1074
  t();
1004
1075
  let n = new ResizeObserver(t);
1005
1076
  return n.observe(e), () => n.disconnect();
1006
- }, []), X(w, t, r, E.width, E.height, x, o === "material", i === "input", S);
1007
- let k = Math.max(44, E.width), A = Math.max(44, E.height), ee = q(w, !x && p === "breathe", E.width, E.height, i === "input", S, C), j = K(k, A, i === "input", ee.current, S), M = (k + 24) * (A + 24) <= a().maxFilterArea;
1077
+ }, []), Q(w, t, r, E.width, E.height, x, o === "material", i === "input", S);
1078
+ let k = Math.max(44, E.width), A = Math.max(44, E.height), ee = Y(w, !x && p === "breathe", E.width, E.height, i === "input", S, C), j = J(k, A, i === "input", ee.current, S), M = (k + 24) * (A + 24) <= a().maxFilterArea;
1008
1079
  return /* @__PURE__ */ g("div", {
1009
1080
  ref: w,
1010
1081
  className: `game-ui-liquid-reveal ${b}`,
@@ -1085,7 +1156,7 @@ function se({ children: e, source: t, revealKey: r = "initial", variant: i = "co
1085
1156
  }
1086
1157
  //#endregion
1087
1158
  //#region src/LiquidAnchor.tsx
1088
- function Z({ source: e, children: t, placement: n = "top-end", onBoundsChange: r }) {
1159
+ function fe({ source: e, children: t, placement: n = "top-end", onBoundsChange: r }) {
1089
1160
  let [i, a] = f(null), o = d(r);
1090
1161
  o.current = r;
1091
1162
  let [s, c] = f(null);
@@ -1094,7 +1165,9 @@ function Z({ source: e, children: t, placement: n = "top-end", onBoundsChange: r
1094
1165
  }, [e]), u(() => {
1095
1166
  let t = e.current, r = i;
1096
1167
  if (!t || !r) return;
1097
- let a = !0, s = 0, c = null, l = null, u = () => {
1168
+ let a = (e) => {
1169
+ G(r, e), o.current?.(e);
1170
+ }, s = !0, c = 0, l = null, u = null, d = () => {
1098
1171
  let e = getComputedStyle(t);
1099
1172
  for (let t of Array.from(e)) if (t.startsWith("--game-ui-") || t.startsWith("--liquid-presence-")) {
1100
1173
  let n = e.getPropertyValue(t);
@@ -1105,18 +1178,18 @@ function Z({ source: e, children: t, placement: n = "top-end", onBoundsChange: r
1105
1178
  let e = getComputedStyle(n);
1106
1179
  for (let t of ["--liquid-presence-from", "--liquid-presence-to"]) r.style.setProperty(t, e.getPropertyValue(t));
1107
1180
  }
1108
- }, d = () => {
1109
- let e = ++s, i = t.getBoundingClientRect(), u = document.querySelector("dialog:modal");
1110
- if (c !== u && (l?.disconnect(), l = null, c = u, u && !u.contains(t) && !r.contains(u) && (l = new MutationObserver(() => {
1111
- (!u.isConnected || !u.matches(":modal")) && d();
1112
- }), l.observe(u, {
1181
+ }, f = () => {
1182
+ let e = ++c, i = t.getBoundingClientRect(), o = document.querySelector("dialog:modal");
1183
+ if (l !== o && (u?.disconnect(), u = null, l = o, o && !o.contains(t) && !r.contains(o) && (u = new MutationObserver(() => {
1184
+ (!o.isConnected || !o.matches(":modal")) && f();
1185
+ }), u.observe(o, {
1113
1186
  attributes: !0,
1114
1187
  attributeFilter: ["open"]
1115
- }), u.parentNode && l.observe(u.parentNode, { childList: !0 }))), !t.isConnected || t.closest("[hidden], [inert], [aria-hidden=\"true\"]") || typeof t.checkVisibility == "function" && !t.checkVisibility({
1188
+ }), o.parentNode && u.observe(o.parentNode, { childList: !0 }))), !t.isConnected || t.closest("[hidden], [inert], [aria-hidden=\"true\"]") || typeof t.checkVisibility == "function" && !t.checkVisibility({
1116
1189
  opacityProperty: !0,
1117
1190
  visibilityProperty: !0
1118
- }) || i.width <= 0 || i.height <= 0 || u && !u.contains(t) && !r.contains(u)) {
1119
- r.style.visibility = "hidden", o.current?.(null);
1191
+ }) || i.width <= 0 || i.height <= 0 || o && !o.contains(t) && !r.contains(o)) {
1192
+ r.style.visibility = "hidden", a(null);
1120
1193
  return;
1121
1194
  }
1122
1195
  y(t, r, {
@@ -1138,28 +1211,28 @@ function Z({ source: e, children: t, placement: n = "top-end", onBoundsChange: r
1138
1211
  x({ strategy: "referenceHidden" })
1139
1212
  ]
1140
1213
  }).then(({ x: t, y: n, middlewareData: i }) => {
1141
- if (!a || e !== s) return;
1214
+ if (!s || e !== c) return;
1142
1215
  if (i.hide?.referenceHidden) {
1143
- r.style.visibility = "hidden", o.current?.(null);
1216
+ r.style.visibility = "hidden", a(null);
1144
1217
  return;
1145
1218
  }
1146
1219
  r.style.left = `${t}px`, r.style.top = `${n}px`, r.style.visibility = "visible";
1147
- let c = r.getBoundingClientRect();
1148
- o.current?.({
1149
- x: c.x,
1150
- y: c.y,
1151
- width: c.width,
1152
- height: c.height
1220
+ let o = r.getBoundingClientRect();
1221
+ a({
1222
+ x: o.x,
1223
+ y: o.y,
1224
+ width: o.width,
1225
+ height: o.height
1153
1226
  });
1154
1227
  }).catch(() => {
1155
- !a || e !== s || (r.style.visibility = "hidden", o.current?.(null));
1228
+ !s || e !== c || (r.style.visibility = "hidden", a(null));
1156
1229
  });
1157
1230
  };
1158
- u();
1159
- let f = v(t, r, d), p = new MutationObserver(() => {
1160
- u(), d();
1231
+ d();
1232
+ let p = v(t, r, f), m = new MutationObserver(() => {
1233
+ d(), f();
1161
1234
  });
1162
- for (let e = t; e; e = e.parentElement) p.observe(e, {
1235
+ for (let e = t; e; e = e.parentElement) m.observe(e, {
1163
1236
  attributes: !0,
1164
1237
  attributeFilter: [
1165
1238
  "class",
@@ -1170,16 +1243,16 @@ function Z({ source: e, children: t, placement: n = "top-end", onBoundsChange: r
1170
1243
  "aria-hidden"
1171
1244
  ]
1172
1245
  });
1173
- let m = t.querySelector(".game-ui-liquid-presence");
1174
- return m && p.observe(m, {
1246
+ let h = t.querySelector(".game-ui-liquid-presence");
1247
+ return h && m.observe(h, {
1175
1248
  attributes: !0,
1176
1249
  attributeFilter: [
1177
1250
  "class",
1178
1251
  "style",
1179
1252
  "data-activity"
1180
1253
  ]
1181
- }), document.addEventListener("toggle", d, !0), document.addEventListener("close", d, !0), () => {
1182
- a = !1, s++, f(), p.disconnect(), l?.disconnect(), document.removeEventListener("toggle", d, !0), document.removeEventListener("close", d, !0), o.current?.(null);
1254
+ }), document.addEventListener("toggle", f, !0), document.addEventListener("close", f, !0), () => {
1255
+ s = !1, c++, p(), m.disconnect(), u?.disconnect(), document.removeEventListener("toggle", f, !0), document.removeEventListener("close", f, !0), a(null);
1183
1256
  };
1184
1257
  }, [
1185
1258
  i,
@@ -1202,4 +1275,4 @@ function Z({ source: e, children: t, placement: n = "top-end", onBoundsChange: r
1202
1275
  }) : null;
1203
1276
  }
1204
1277
  //#endregion
1205
- export { Z as LiquidAnchor, G as LiquidPresence, se as LiquidReveal };
1278
+ export { fe as LiquidAnchor, q as LiquidPresence, de as LiquidReveal };