@mt-gloss/ui 0.1.21 → 0.1.23

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.
@@ -20,6 +20,15 @@ export interface EdgeHoverHandleProps {
20
20
  edge?: 'right';
21
21
  /** D-16 — keyboard step handler (ArrowLeft → 'shrink', ArrowRight → 'grow'). */
22
22
  onKeyboardStep?: (direction: ResizeDirection) => void;
23
+ /**
24
+ * Quick 260422-gfr — fires when the browser implicitly releases pointer
25
+ * capture from the <button> (window blur / Alt-Tab / modal focus steal /
26
+ * touchcancel). Consumers wire this to the hook's `cancel()` so the gesture
27
+ * deterministically exits `'dragging'` on capture loss. Companion to the
28
+ * window-level blur / visibilitychange / pointercancel listeners installed
29
+ * inside useEdgeHoverResize. See .planning/debug/resize-state-leak-cross-card.md.
30
+ */
31
+ onLostPointerCapture?: (e: React.PointerEvent) => void;
23
32
  ariaLabel?: string;
24
33
  }
25
34
  /**
@@ -25,6 +25,17 @@ export declare class VelocityBuffer {
25
25
  private readonly capacity;
26
26
  push(sample: VelocitySample): void;
27
27
  clear(): void;
28
+ /**
29
+ * Quick 260422-gfr — last-known-position accessor for the window-level
30
+ * terminateDrag fallback in useEdgeHoverResize. When pointer capture is
31
+ * silently lost (Alt-Tab / blur / visibilitychange hidden), the React
32
+ * onPointerUp does not fire, so the window-level fallback needs the last
33
+ * pointer x-coordinate to compute `dx` for commitSpring. The most recent
34
+ * sample is the authoritative answer (pointermove pushes on every event).
35
+ *
36
+ * Returns `null` when the buffer is empty (no drag ever started).
37
+ */
38
+ tail(): VelocitySample | null;
28
39
  /**
29
40
  * D-09 — weighted-average velocity (px/sec).
30
41
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mt-gloss/ui",
3
- "version": "0.1.21",
3
+ "version": "0.1.23",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "restricted"