@mt-gloss/ui 0.0.45 → 0.0.47
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +1126 -1104
- package/lib/primitives/dashboard/DevTuningPanel/useResizeTuning.d.ts +1 -1
- package/lib/primitives/dashboard/MetricCard/__tests__/fixtures/nyquist-09-parity-matrix.d.ts +5 -2
- package/lib/primitives/dashboard/MetricCard/resizePhysics.d.ts +1 -1
- package/lib/primitives/dashboard/MetricCard/useEdgeHoverResize.d.ts +17 -2
- package/package.json +1 -1
|
@@ -18,7 +18,7 @@ declare const _TUNING_DEFAULTS_LITERAL: {
|
|
|
18
18
|
readonly snapInPx: 60;
|
|
19
19
|
readonly snapOutPx: 90;
|
|
20
20
|
readonly stiffness: 500;
|
|
21
|
-
readonly damping:
|
|
21
|
+
readonly damping: 22;
|
|
22
22
|
readonly mass: 1;
|
|
23
23
|
readonly snapInFraction: number;
|
|
24
24
|
readonly snapOutFraction: number;
|
package/lib/primitives/dashboard/MetricCard/__tests__/fixtures/nyquist-09-parity-matrix.d.ts
CHANGED
|
@@ -3,7 +3,10 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Typed array of 144 rows enumerating the 7-axis resize parity space:
|
|
5
5
|
*
|
|
6
|
-
* spring — 3 presets: default (
|
|
6
|
+
* spring — 3 presets: default (S500D22M1, retuned 260419 for
|
|
7
|
+
* visible overshoot — was S500D35M1; see Fix E /
|
|
8
|
+
* 260419-resize-integration-broken), gentle (S300D30M1),
|
|
9
|
+
* stiff (S700D40M1)
|
|
7
10
|
* viewport — round-robin across [1280, 1920, 2560] (all 3 appear in asserted set)
|
|
8
11
|
* reducedMotion — {false, true}
|
|
9
12
|
* pointerType — {'mouse', 'touch'}
|
|
@@ -47,7 +50,7 @@
|
|
|
47
50
|
*/
|
|
48
51
|
export interface Nyquist09Row {
|
|
49
52
|
/**
|
|
50
|
-
* Stable row id, e.g. '
|
|
53
|
+
* Stable row id, e.g. 'S500D22M1-vw1280-rm_off-mouse-stack-commit-dndk_on'.
|
|
51
54
|
* Shape: `S{stiffness}D{damping}M{mass}-vw{viewport}-rm_{on|off}-{pointer}-{stack|spark}-{cancelPath}-dndk_{on|off}`.
|
|
52
55
|
*/
|
|
53
56
|
id: string;
|
|
@@ -37,6 +37,21 @@ export interface UseEdgeHoverResizeArgs {
|
|
|
37
37
|
* session 260419-ghost-slides-across-page — AP-17 companion invariant).
|
|
38
38
|
*/
|
|
39
39
|
maxColSpan?: 1 | 2 | 3;
|
|
40
|
+
/**
|
|
41
|
+
* Polish Fix #7 (0.0.46 UAT) — optional slot-scoped container element.
|
|
42
|
+
* When provided, the hook installs a window-level pointermove listener
|
|
43
|
+
* during 'dwelling' and 'handle-visible' states. If the cursor's target
|
|
44
|
+
* is NOT within `containerRef.current`, the hook force-calls
|
|
45
|
+
* `leaveEdgeZone()` — self-heal that fires when a consumer's own
|
|
46
|
+
* pointerleave guard (e.g. MetricCardSlot's `closest('.edge-hover-sentinel')`)
|
|
47
|
+
* incorrectly matches a SIBLING card's sentinel during a rapid sweep,
|
|
48
|
+
* leaving this card stuck at 'handle-visible' while the pointer has
|
|
49
|
+
* already moved on. Drag/settling are exempt (pointer capture owns the
|
|
50
|
+
* gesture); the self-heal only resets pre-gesture hover state.
|
|
51
|
+
*/
|
|
52
|
+
containerRef?: React.RefObject<Element | null> | {
|
|
53
|
+
current: Element | null;
|
|
54
|
+
};
|
|
40
55
|
}
|
|
41
56
|
export interface UseEdgeHoverResizeReturn {
|
|
42
57
|
state: ResizeState;
|
|
@@ -85,7 +100,7 @@ export interface UseEdgeHoverResizeReturn {
|
|
|
85
100
|
* - MotionValue ghost tracking (D-07) — zero React re-renders per pointermove
|
|
86
101
|
* - Hysteresis snap (D-06) replaces Math.round(dx/step)
|
|
87
102
|
* - Velocity ring buffer (D-09) feeds spring commit
|
|
88
|
-
* - Spring commit via framer-motion animate() (D-08: stiffness 500, damping
|
|
103
|
+
* - Spring commit via framer-motion animate() (D-08: stiffness 500, damping 22, mass 1 — retuned 260419 for visible overshoot, was damping 35)
|
|
89
104
|
* - 'settling' state (D-12) hard-blocks re-engagement during spring
|
|
90
105
|
* - committed state removed (D-05) — rolls into settling → idle
|
|
91
106
|
* - Keyboard step (D-16): onKeyboardStep('grow'|'shrink')
|
|
@@ -98,4 +113,4 @@ export interface UseEdgeHoverResizeReturn {
|
|
|
98
113
|
* - Bug E handle pointerenter keeps zone alive on sentinel→handle crossover
|
|
99
114
|
* - Dwell timer cleanup on unmount
|
|
100
115
|
*/
|
|
101
|
-
export declare function useEdgeHoverResize({ currentColSpan, stackable, onResize, onCancel, step, gap, tuning, dwellMs, enterMs, exitMs, maxColSpan, }: UseEdgeHoverResizeArgs): UseEdgeHoverResizeReturn;
|
|
116
|
+
export declare function useEdgeHoverResize({ currentColSpan, stackable, onResize, onCancel, step, gap, tuning, dwellMs, enterMs, exitMs, maxColSpan, containerRef, }: UseEdgeHoverResizeArgs): UseEdgeHoverResizeReturn;
|