phase 0.0.6 → 0.0.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.
package/README.md CHANGED
@@ -34,6 +34,7 @@ Each guarantee is a [tested invariant](#guarantees), not an aspiration. Every ex
34
34
  - [createSight](#createsight)
35
35
  - [createLifecycle](#createlifecycle)
36
36
  - [createScrollProgress](#createscrollprogress)
37
+ - [createScroll](#createscroll)
37
38
  - [prefersReducedMotion](#prefersreducedmotion)
38
39
  - [Easing and math](#easing-and-math)
39
40
  - [Choosing a primitive](#choosing-a-primitive)
@@ -44,6 +45,7 @@ Each guarantee is a [tested invariant](#guarantees), not an aspiration. Every ex
44
45
  - [useTween](#usetween)
45
46
  - [usePresence](#usepresence)
46
47
  - [useScrollProgress](#usescrollprogress)
48
+ - [useScroll](#usescroll)
47
49
  - [Utility hooks](#utility-hooks)
48
50
  - [React components](#react-components)
49
51
  - [How animations work](#how-animations-work)
@@ -323,7 +325,7 @@ Pause priority is `reduced-motion` > `sight` > `manual`.
323
325
 
324
326
  Reports what fraction of an element is currently visible in the viewport (0–1), via the shared IntersectionObserver pool. Zero forced reflows, zero extra observers. Ideal for reveal/opacity effects.
325
327
 
326
- > **Not a scroll-scrubbing engine.** This reports `intersectionRatio`, which plateaus for tall elements once they fill the viewport. For continuous scroll-driven animation, use `motion`'s `useScroll` or the native `ScrollTimeline` API.
328
+ > **Visibility ratio, not scroll offset.** This reports `intersectionRatio` (how much of an element is visible in the viewport), which plateaus for tall elements once they fill it. For a scroll container's _own_ offset (scrollbars, carousels) use [`createScroll`](#createscroll); for CSS-declarative scroll-linked animation use the native `ScrollTimeline` API; for spring/gesture scroll use `motion`.
327
329
 
328
330
  ```ts
329
331
  import { createScrollProgress } from 'phase';
@@ -353,6 +355,49 @@ The `steps` option controls threshold granularity. Default `20` generates 21 eve
353
355
  | `root` | `Element \| Document \| null` | — | IO root element |
354
356
  | `rootMargin` | `string` | — | IO root margin |
355
357
 
358
+ ### createScroll
359
+
360
+ Tracks a scroll container's offset and progress. Reads `scrollLeft`/`scrollTop` once per rAF frame and reads the reflow-heavy geometry (`scrollWidth`/`clientWidth`) only on resize or explicit `measure()`, never on the scroll path. Auto-pauses off-screen via the shared IntersectionObserver pool. This is to `scroll` + `scrollWidth` what `createPointer` is to `pointermove` + `getBoundingClientRect`.
361
+
362
+ > **Scroll offset, not visibility ratio.** This reports the element's own scroll position (for scrollbars, carousels, position indicators). For _how much of an element is in the viewport_, use [`createScrollProgress`](#createscrollprogress); for CSS-declarative scroll-linked animation, use the native `ScrollTimeline` API.
363
+
364
+ ```ts
365
+ import { createScroll } from 'phase';
366
+
367
+ const scroll = createScroll({
368
+ element: viewport,
369
+ onScroll: (s) => {
370
+ // thumb CSS needs `transform-origin: left` so scaleX anchors to the track start
371
+ thumb.style.transform = `translateX(${s.progressX * (1 - s.visibleX) * 100}%) scaleX(${s.visibleX})`;
372
+ prevButton.disabled = s.x <= 1;
373
+ nextButton.disabled = s.x >= s.maxX - 1;
374
+ },
375
+ });
376
+
377
+ // scroll.state.progressX === 0.5 (synchronous read)
378
+
379
+ // after mutating scrollable content:
380
+ scroll.measure();
381
+
382
+ // cleanup:
383
+ scroll.stop();
384
+ ```
385
+
386
+ `onScroll` receives the same `ScrollState` object every frame (mutated in place, zero per-frame allocations): `x`, `y`, `maxX`, `maxY`, `progressX`, `progressY`, and the visible fractions `visibleX`/`visibleY` (`clientWidth / scrollWidth`, i.e. a scrollbar thumb's `scaleX`). The `ResizeObserver` recomputes geometry on container resize; call `measure()` after content changes that alter `scrollWidth`.
387
+
388
+ #### Scroll options
389
+
390
+ | Option | Type | Default | Description |
391
+ | --------------------- | ------------------------------ | --------- | -------------------------------------------------- |
392
+ | `element` | `Element` | required | Scroll container to track |
393
+ | `onScroll` | `(state: ScrollState) => void` | required | Called once per rAF frame with position + progress |
394
+ | `onPhaseChange` | `(phase, reason) => void` | — | Called on phase transitions |
395
+ | `visibility` | `'pause' \| 'ignore'` | `'pause'` | Pause tracking when off-screen, or ignore |
396
+ | `intersectionOptions` | `IntersectionObserverInit` | — | Forwarded to the visibility observer |
397
+ | `signal` | `AbortSignal` | — | Stops the tracker when aborted |
398
+
399
+ The options type is `CreateScrollOptions` (`ScrollOptions` is a `lib.dom` global and must not be shadowed).
400
+
356
401
  ### prefersReducedMotion
357
402
 
358
403
  Returns `true` when reduced motion is enabled at the OS level. Use it to gate expensive setup or dynamic imports.
@@ -576,7 +621,7 @@ return (
576
621
 
577
622
  ### useScrollProgress
578
623
 
579
- Element visibility ratio as a 0–1 value. Wraps `createScrollProgress` with React lifecycle management (see its [note on scope](#createscrollprogress) for the distinction between visibility ratio and scroll-scrubbing).
624
+ Element visibility ratio as a 0–1 value. Wraps `createScrollProgress` with React lifecycle management. This is a _visibility_ fraction (how much of the element is on screen); for a scroll container's own _position_ (scrollbars, carousels) use [`useScroll`](#usescroll) instead. See the [note on scope](#createscrollprogress) for the full distinction.
580
625
 
581
626
  ```tsx
582
627
  import { useScrollProgress } from 'phase/react';
@@ -593,6 +638,36 @@ function FadeIn({ children }) {
593
638
 
594
639
  Re-renders only at threshold crossings (~20 per full viewport traversal at default steps). `progress` is `0` before first observation.
595
640
 
641
+ ### useScroll
642
+
643
+ Scroll offset and progress for a scroll container. Wraps `createScroll` with React lifecycle management. Position is delivered imperatively via `onScroll` (never per-frame state); only the phase (`tracking`/`paused`) is reactive. Mirrors `usePointer`.
644
+
645
+ ```tsx
646
+ import { useRef } from 'react';
647
+ import { useScroll } from 'phase/react';
648
+
649
+ function Carousel({ children }) {
650
+ // thumb uses `origin-left` so scaleX anchors to the track start
651
+ const thumbRef = useRef<HTMLDivElement>(null);
652
+ const { ref, measure } = useScroll<HTMLDivElement>({
653
+ onScroll: (s) => {
654
+ thumbRef.current?.style.setProperty(
655
+ 'transform',
656
+ `translateX(${s.progressX * (1 - s.visibleX) * 100}%) scaleX(${s.visibleX})`,
657
+ );
658
+ },
659
+ });
660
+
661
+ return (
662
+ <div ref={ref} className="overflow-x-auto">
663
+ {children}
664
+ </div>
665
+ );
666
+ }
667
+ ```
668
+
669
+ Scrolling writes to the DOM directly with zero re-renders. Read the latest position on demand from `stateRef.current` (e.g. inside a `useLoop` tick), and call `measure()` after changing scrollable content.
670
+
596
671
  ### Utility hooks
597
672
 
598
673
  | Hook | Purpose |
@@ -898,15 +973,16 @@ Minimal footprint is a core promise (see [Why phase](#why-phase)). Every export
898
973
  | Export | Size (min+brotli) |
899
974
  | ------------------------- | ----------------: |
900
975
  | **Core** | |
901
- | `createTicker` | 837 B |
976
+ | `createTicker` | 834 B |
902
977
  | `createSight` | 963 B |
903
978
  | `createLifecycle` | 1.47 kB |
904
979
  | `createLoop` | 2.59 kB |
905
- | `createScrollProgress` | 857 B |
980
+ | `createScrollProgress` | 878 B |
906
981
  | `createRenderState` | 495 B |
907
982
  | `createDevicePixelRatio` | 544 B |
908
983
  | `createMutation` | 1.17 kB |
909
984
  | `createPointer` | 1.26 kB |
985
+ | `createScroll` | 1.45 kB |
910
986
  | `whenIdle` | 409 B |
911
987
  | `prefersReducedMotion` | 101 B |
912
988
  | **Ease** | |
@@ -918,20 +994,21 @@ Minimal footprint is a core promise (see [Why phase](#why-phase)). Every export
918
994
  | `useCanvas` | 3.44 kB |
919
995
  | `useMutation` | 1.36 kB |
920
996
  | `usePointer` | 1.48 kB |
997
+ | `useScroll` | 1.71 kB |
921
998
  | `useTween` | 617 B |
922
999
  | `usePresence` | 593 B |
923
1000
  | `useScrollProgress` | 993 B |
924
1001
  | `useSize` | 384 B |
925
- | `useContainerQuery` | 356 B |
926
- | `useMediaQuery` | 246 B |
1002
+ | `useContainerQuery` | 357 B |
1003
+ | `useMediaQuery` | 245 B |
927
1004
  | `usePrefersReducedMotion` | 272 B |
928
1005
  | `useDevicePixelRatio` | 231 B |
929
1006
  | `useSyncedRef` | 22 B |
930
1007
  | `useStableCallback` | 39 B |
931
- | `Presence` | 742 B |
1008
+ | `Presence` | 739 B |
932
1009
  | `WhenVisible` | 1.44 kB |
933
- | `WhenIdle` | 593 B |
934
- | `Defer` | 85 B |
1010
+ | `WhenIdle` | 592 B |
1011
+ | `Defer` | 86 B |
935
1012
  | `useIdle` | 435 B |
936
1013
  | `useWhenIdle` | 449 B |
937
1014
  | `useRenderState` | 527 B |
@@ -304,5 +304,59 @@ interface Pointer {
304
304
  /** Lifecycle-aware pointer tracker with rAF-batched `getBoundingClientRect`. */
305
305
  declare function createPointer(options: PointerOptions): Pointer;
306
306
  //#endregion
307
- export { LifecycleReason as A, TickerOptions as B, LoopReason as C, Lifecycle as D, createLoop as E, SightPhase as F, TickerReason as H, SightReason as I, createSight as L, createLifecycle as M, Sight as N, LifecycleOptions as O, SightOptions as P, FrameState as R, LoopPhase as S, ReducedMotionBehavior as T, createTicker as U, TickerPhase as V, createRenderState as _, PointerState as a, Loop as b, MutationOptions as c, createMutation as d, IdleOptions as f, RenderStateOptions as g, RenderState as h, PointerReason as i, LifecycleReducedMotion as j, LifecyclePhase as k, MutationPhase as l, RenderPhase as m, PointerOptions as n, createPointer as o, whenIdle as p, PointerPhase as r, Mutation as s, Pointer as t, MutationReason as u, DegradedBehavior as v, Quality as w, LoopOptions as x, DegradedReason as y, Ticker as z };
308
- //# sourceMappingURL=index-tRHsbTE2.d.ts.map
307
+ //#region src/core/scroll/index.d.ts
308
+ type ScrollPhase = 'tracking' | 'paused' | 'stopped';
309
+ type ScrollReason = 'initial' | 'started' | 'sight' | 'disposed';
310
+ interface ScrollState {
311
+ /** `scrollLeft`, clamped to `[0, maxX]`. */
312
+ x: number;
313
+ /** `scrollTop`, clamped to `[0, maxY]`. */
314
+ y: number;
315
+ /** Max horizontal scroll distance (`scrollWidth - clientWidth`, never negative). */
316
+ maxX: number;
317
+ /** Max vertical scroll distance (`scrollHeight - clientHeight`, never negative). */
318
+ maxY: number;
319
+ /** Horizontal scroll progress `x / maxX` (0–1). `0` when not scrollable. */
320
+ progressX: number;
321
+ /** Vertical scroll progress `y / maxY` (0–1). `0` when not scrollable. */
322
+ progressY: number;
323
+ /** Visible horizontal fraction `clientWidth / scrollWidth` (0–1). Thumb `scaleX`. */
324
+ visibleX: number;
325
+ /** Visible vertical fraction `clientHeight / scrollHeight` (0–1). Thumb `scaleY`. */
326
+ visibleY: number;
327
+ }
328
+ interface CreateScrollOptions {
329
+ element: Element;
330
+ /** Called once per rAF frame with the latest scroll position + progress. */
331
+ onScroll: (state: ScrollState) => void;
332
+ /** Called on phase transitions (tracking, paused, stopped). */
333
+ onPhaseChange?: (phase: ScrollPhase, reason: ScrollReason) => void;
334
+ /** Pause when off-screen or ignore visibility. Default `'pause'`. */
335
+ visibility?: 'pause' | 'ignore';
336
+ /** IO options forwarded to the visibility observer. */
337
+ intersectionOptions?: IntersectionObserverInit;
338
+ /** Stops the tracker when aborted. */
339
+ signal?: AbortSignal;
340
+ }
341
+ interface Scroll {
342
+ readonly phase: ScrollPhase;
343
+ readonly phaseReason: ScrollReason;
344
+ readonly state: Readonly<ScrollState>;
345
+ /** Re-read geometry (`scrollWidth`/`clientWidth`) after a content change. */
346
+ measure(): void;
347
+ stop(): void;
348
+ }
349
+ /**
350
+ * Lifecycle-aware scroll tracker. Reads `scrollLeft`/`scrollTop` once per rAF
351
+ * frame and reads the reflow-heavy geometry (`scrollWidth`/`clientWidth`) only
352
+ * on resize or explicit `measure()`, never on the scroll path. Auto-pauses when
353
+ * the element is off-screen.
354
+ *
355
+ * This is to `scroll` + `scrollWidth` what `createPointer` is to `pointermove`
356
+ * + `getBoundingClientRect`: the layout read is batched off the hot path so the
357
+ * per-scroll work is a single cheap position read plus math on cached geometry.
358
+ */
359
+ declare function createScroll(options: CreateScrollOptions): Scroll;
360
+ //#endregion
361
+ export { Quality as A, SightOptions as B, createRenderState as C, LoopOptions as D, Loop as E, LifecyclePhase as F, Ticker as G, SightReason as H, LifecycleReason as I, TickerReason as J, TickerOptions as K, LifecycleReducedMotion as L, createLoop as M, Lifecycle as N, LoopPhase as O, LifecycleOptions as P, createLifecycle as R, RenderStateOptions as S, DegradedReason as T, createSight as U, SightPhase as V, FrameState as W, createTicker as Y, createMutation as _, ScrollState as a, RenderPhase as b, PointerOptions as c, PointerState as d, createPointer as f, MutationReason as g, MutationPhase as h, ScrollReason as i, ReducedMotionBehavior as j, LoopReason as k, PointerPhase as l, MutationOptions as m, Scroll as n, createScroll as o, Mutation as p, TickerPhase as q, ScrollPhase as r, Pointer as s, CreateScrollOptions as t, PointerReason as u, IdleOptions as v, DegradedBehavior as w, RenderState as x, whenIdle as y, Sight as z };
362
+ //# sourceMappingURL=index-BRyL_Inx.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index-BRyL_Inx.d.ts","names":[],"sources":["../src/core/tick/index.ts","../src/core/sight/index.ts","../src/core/lifecycle/index.ts","../src/core/loop/index.ts","../src/core/render-state/index.ts","../src/core/idle/index.ts","../src/core/mutation/index.ts","../src/core/pointer/index.ts","../src/core/scroll/index.ts"],"mappings":";UAOiB,UAAA;EAAA;EAEf,IAAA;;EAEA,KAAA;EAFA;EAIA,OAAA;EAAA;EAEA,KAAA;AAAA;AAAA,KAGU,WAAA;AAAA,KACA,YAAA;AAAA,UAOK,aAAA;;EAEf,GAAA;EAVqB;AACvB;;;EAcE,MAAA,GAAS,KAAA,EAAO,UAAA;EAdM;EAgBtB,MAAA,GAAS,WAAA;AAAA;AAAA,UAGM,MAAA;EACf,KAAA;EACA,IAAA;EACA,KAAA;EACA,MAAA;EAAA,SACS,KAAA,EAAO,WAAA;EAAA,SACP,WAAA,EAAa,YAAA;AAAA;;;AANxB;;;;;iBAgFgB,YAAA,CAAa,OAAA,EAAS,aAAA,GAAgB,MAAA;;;KC9G1C,UAAA;AAAA,KACA,WAAA;AAAA,UAOK,YAAA;EACf,OAAA,EAAS,OAAA;EACT,mBAAA,GAAsB,wBAAA;EACtB,aAAA,IAAiB,KAAA,EAAO,UAAA,EAAY,MAAA,EAAQ,WAAA;EDR5C;ECUA,MAAA,GAAS,WAAA;AAAA;AAAA,UAGM,KAAA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;EPRY;EOUrB,SAAA,GAAY,KAAA,EAAO,YAAA;EPVE;EOYrB,aAAA,IAAiB,KAAA,EAAO,YAAA,EAAc,MAAA,EAAQ,aAAA;EPXpC;EOaV,UAAA;;EAEA,mBAAA,GAAsB,wBAAA;EPfA;EOiBtB,MAAA,GAAS,WAAA;AAAA;AAAA,UAGM,OAAA;EAAA,SACN,KAAA,EAAO,YAAA;EAAA,SACP,WAAA,EAAa,aAAA;EAAA,SACb,KAAA,EAAO,QAAA,CAAS,YAAA;EACzB,IAAA;AAAA;;iBAQc,aAAA,CAAc,OAAA,EAAS,cAAA,GAAiB,OAAA;;;KC1C5C,WAAA;AAAA,KACA,YAAA;AAAA,UAEK,WAAA;;EAEf,CAAA;ERLA;EQOA,CAAA;ERHA;EQKA,IAAA;ERHK;EQKL,IAAA;ERFU;EQIV,SAAA;;EAEA,SAAA;ERNqB;EQQrB,QAAA;ERPsB;EQStB,QAAA;AAAA;AAAA,UAIe,mBAAA;EACf,OAAA,EAAS,OAAA;ERPmB;EQS5B,QAAA,GAAW,KAAA,EAAO,WAAA;ERAE;EQEpB,aAAA,IAAiB,KAAA,EAAO,WAAA,EAAa,MAAA,EAAQ,YAAA;ERJ7C;EQMA,UAAA;ERNS;EQQT,mBAAA,GAAsB,wBAAA;ERNb;EQQT,MAAA,GAAS,WAAA;AAAA;AAAA,UAGM,MAAA;EAAA,SACN,KAAA,EAAO,WAAA;EAAA,SACP,WAAA,EAAa,YAAA;EAAA,SACb,KAAA,EAAO,QAAA,CAAS,WAAA;ERVzB;EQYA,OAAA;EACA,IAAA;AAAA;;;;;;;ARkEF;;;;iBQjDgB,YAAA,CAAa,OAAA,EAAS,mBAAA,GAAsB,MAAA"}
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { RemapOptions, clamp, clamp01, easeInOutCubic, easeOutBack, easeOutCubic, easeOutQuart, inverseLerp, lerp, linear, remap } from "./ease.js";
2
- import { A as LifecycleReason, B as TickerOptions, C as LoopReason, D as Lifecycle, E as createLoop, F as SightPhase, H as TickerReason, I as SightReason, L as createSight, M as createLifecycle, N as Sight, O as LifecycleOptions, P as SightOptions, R as FrameState, S as LoopPhase, T as ReducedMotionBehavior, U as createTicker, V as TickerPhase, _ as createRenderState, a as PointerState, b as Loop, c as MutationOptions, d as createMutation, f as IdleOptions, g as RenderStateOptions, h as RenderState, i as PointerReason, j as LifecycleReducedMotion, k as LifecyclePhase, l as MutationPhase, m as RenderPhase, n as PointerOptions, o as createPointer, p as whenIdle, r as PointerPhase, s as Mutation, t as Pointer, u as MutationReason, v as DegradedBehavior, w as Quality, x as LoopOptions, y as DegradedReason, z as Ticker } from "./index-tRHsbTE2.js";
2
+ import { A as Quality, B as SightOptions, C as createRenderState, D as LoopOptions, E as Loop, F as LifecyclePhase, G as Ticker, H as SightReason, I as LifecycleReason, J as TickerReason, K as TickerOptions, L as LifecycleReducedMotion, M as createLoop, N as Lifecycle, O as LoopPhase, P as LifecycleOptions, R as createLifecycle, S as RenderStateOptions, T as DegradedReason, U as createSight, V as SightPhase, W as FrameState, Y as createTicker, _ as createMutation, a as ScrollState, b as RenderPhase, c as PointerOptions, d as PointerState, f as createPointer, g as MutationReason, h as MutationPhase, i as ScrollReason, j as ReducedMotionBehavior, k as LoopReason, l as PointerPhase, m as MutationOptions, n as Scroll, o as createScroll, p as Mutation, q as TickerPhase, r as ScrollPhase, s as Pointer, t as CreateScrollOptions, u as PointerReason, v as IdleOptions, w as DegradedBehavior, x as RenderState, y as whenIdle, z as Sight } from "./index-BRyL_Inx.js";
3
3
 
4
4
  //#region src/core/scroll-progress/index.d.ts
5
5
  interface ScrollProgressOptions {
@@ -95,5 +95,5 @@ declare class PhaseError extends Error {
95
95
  /** Check if a value is a PhaseError instance. */
96
96
  declare function isPhaseError(error: unknown): error is PhaseError;
97
97
  //#endregion
98
- export { type DegradedBehavior, type DegradedReason, type DevicePixelRatio, type DevicePixelRatioOptions, type FrameState, type IdleOptions, type Lifecycle, type LifecycleOptions, type LifecyclePhase, type LifecycleReason, type LifecycleReducedMotion, type Loop, type LoopOptions, type LoopPhase, type LoopReason, type Mutation, type MutationOptions, type MutationPhase, type MutationReason, PhaseError, type PhaseErrorCode, type Pointer, type PointerOptions, type PointerPhase, type PointerReason, type PointerState, type Quality, type ReducedMotionBehavior, type RemapOptions, type RenderPhase, type RenderState, type RenderStateOptions, type ScrollProgress, type ScrollProgressOptions, type Sight, type SightOptions, type SightPhase, type SightReason, type Ticker, type TickerOptions, type TickerPhase, type TickerReason, clamp, clamp01, createDevicePixelRatio, createLifecycle, createLoop, createMutation, createPointer, createRenderState, createScrollProgress, createSight, createTicker, easeInOutCubic, easeOutBack, easeOutCubic, easeOutQuart, inverseLerp, isPhaseError, lerp, linear, prefersReducedMotion, remap, whenIdle };
98
+ export { type CreateScrollOptions, type DegradedBehavior, type DegradedReason, type DevicePixelRatio, type DevicePixelRatioOptions, type FrameState, type IdleOptions, type Lifecycle, type LifecycleOptions, type LifecyclePhase, type LifecycleReason, type LifecycleReducedMotion, type Loop, type LoopOptions, type LoopPhase, type LoopReason, type Mutation, type MutationOptions, type MutationPhase, type MutationReason, PhaseError, type PhaseErrorCode, type Pointer, type PointerOptions, type PointerPhase, type PointerReason, type PointerState, type Quality, type ReducedMotionBehavior, type RemapOptions, type RenderPhase, type RenderState, type RenderStateOptions, type Scroll, type ScrollPhase, type ScrollProgress, type ScrollProgressOptions, type ScrollReason, type ScrollState, type Sight, type SightOptions, type SightPhase, type SightReason, type Ticker, type TickerOptions, type TickerPhase, type TickerReason, clamp, clamp01, createDevicePixelRatio, createLifecycle, createLoop, createMutation, createPointer, createRenderState, createScroll, createScrollProgress, createSight, createTicker, easeInOutCubic, easeOutBack, easeOutCubic, easeOutQuart, inverseLerp, isPhaseError, lerp, linear, prefersReducedMotion, remap, whenIdle };
99
99
  //# sourceMappingURL=index.d.ts.map
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  import { clamp, clamp01, easeInOutCubic, easeOutBack, easeOutCubic, easeOutQuart, inverseLerp, lerp, linear, remap } from "./ease.js";
2
- import { a as whenIdle, b as serverContextError, c as createRenderState, d as createLifecycle, g as PhaseError, h as createTicker, i as prefersReducedMotion, l as createScrollProgress, m as createSight, n as createMutation, o as readDpr, s as subscribeDpr, t as createPointer, u as createLoop, v as isPhaseError, x as linkAbortSignal } from "./pointer-D5F7_Jjs.js";
2
+ import { C as linkAbortSignal, S as serverContextError, _ as createTicker, b as isPhaseError, c as readDpr, d as createScrollProgress, f as createLoop, g as createSight, i as createMutation, l as subscribeDpr, o as prefersReducedMotion, p as createLifecycle, r as createPointer, s as whenIdle, t as createScroll, u as createRenderState, v as PhaseError } from "./scroll-DZvWyPQE.js";
3
3
  //#region src/core/device-pixel-ratio/index.ts
4
4
  /**
5
5
  * Track devicePixelRatio changes (e.g. user drags the window between monitors
@@ -42,6 +42,6 @@ function createDevicePixelRatio(options) {
42
42
  };
43
43
  }
44
44
  //#endregion
45
- export { PhaseError, clamp, clamp01, createDevicePixelRatio, createLifecycle, createLoop, createMutation, createPointer, createRenderState, createScrollProgress, createSight, createTicker, easeInOutCubic, easeOutBack, easeOutCubic, easeOutQuart, inverseLerp, isPhaseError, lerp, linear, prefersReducedMotion, remap, whenIdle };
45
+ export { PhaseError, clamp, clamp01, createDevicePixelRatio, createLifecycle, createLoop, createMutation, createPointer, createRenderState, createScroll, createScrollProgress, createSight, createTicker, easeInOutCubic, easeOutBack, easeOutCubic, easeOutQuart, inverseLerp, isPhaseError, lerp, linear, prefersReducedMotion, remap, whenIdle };
46
46
 
47
47
  //# sourceMappingURL=index.js.map
package/dist/react.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { A as LifecycleReason, C as LoopReason, F as SightPhase, I as SightReason, R as FrameState, S as LoopPhase, T as ReducedMotionBehavior, a as PointerState, f as IdleOptions, i as PointerReason, j as LifecycleReducedMotion, k as LifecyclePhase, l as MutationPhase, m as RenderPhase, r as PointerPhase, u as MutationReason, v as DegradedBehavior, w as Quality, y as DegradedReason } from "./index-tRHsbTE2.js";
1
+ import { A as Quality, F as LifecyclePhase, H as SightReason, I as LifecycleReason, L as LifecycleReducedMotion, O as LoopPhase, T as DegradedReason, V as SightPhase, W as FrameState, a as ScrollState, b as RenderPhase, d as PointerState, g as MutationReason, h as MutationPhase, i as ScrollReason, j as ReducedMotionBehavior, k as LoopReason, l as PointerPhase, r as ScrollPhase, u as PointerReason, v as IdleOptions, w as DegradedBehavior } from "./index-BRyL_Inx.js";
2
2
  import { ComponentProps, ElementType, HTMLAttributes, JSX, ReactNode, Ref, RefObject } from "react";
3
3
 
4
4
  //#region src/react/use-synced-ref/index.d.ts
@@ -530,6 +530,45 @@ interface UsePointerResult<T extends Element = HTMLDivElement> {
530
530
  */
531
531
  declare function usePointer<T extends Element = HTMLDivElement>(options: UsePointerOptions<T>): UsePointerResult<T>;
532
532
  //#endregion
533
+ //#region src/react/use-scroll/index.d.ts
534
+ type ScrollCallback = (state: ScrollState) => void;
535
+ interface UseScrollOptions<T extends Element = HTMLDivElement> {
536
+ /** Element to track. When omitted, attach the returned `ref`. */
537
+ ref?: RefObject<T | null>;
538
+ /** Called once per rAF frame with the latest scroll position + progress. */
539
+ onScroll: ScrollCallback;
540
+ /** Pause when off-screen or ignore visibility. Default `'pause'`. */
541
+ visibility?: 'pause' | 'ignore';
542
+ /** When `false`, tears down the tracker entirely. Default `true`. */
543
+ enabled?: boolean;
544
+ /** IO options forwarded to the visibility observer. */
545
+ intersectionOptions?: IntersectionObserverInit;
546
+ }
547
+ interface UseScrollResult<T extends Element = HTMLDivElement> {
548
+ ref: RefObject<T | null>;
549
+ phase: ScrollPhase;
550
+ phaseReason: ScrollReason;
551
+ /** Phase via ref. Always current, never triggers re-render. */
552
+ phaseRef: RefObject<ScrollPhase>;
553
+ /** Reason via ref. Always current, never triggers re-render. */
554
+ phaseReasonRef: RefObject<ScrollReason>;
555
+ /** Latest scroll state via ref. Always current, never triggers re-render. */
556
+ stateRef: RefObject<ScrollState>;
557
+ /** Re-read geometry after a content change (e.g. after navigation). */
558
+ measure: () => void;
559
+ }
560
+ /**
561
+ * Lifecycle-aware scroll tracker. Scroll position is delivered imperatively via
562
+ * `onScroll` (never state) and mirrored in `stateRef` for on-demand reads; only
563
+ * the phase (tracking/paused) is reactive, since it flips rarely. This mirrors
564
+ * `usePointer`. Auto-pauses off-screen and tears down on unmount.
565
+ *
566
+ * Reads `scrollLeft`/`scrollTop` once per rAF frame; the reflow-heavy geometry
567
+ * (`scrollWidth`/`clientWidth`) is read only on resize or via `measure()`, never
568
+ * on the scroll path. Call `measure()` after mutating scrollable content.
569
+ */
570
+ declare function useScroll<T extends Element = HTMLDivElement>(options: UseScrollOptions<T>): UseScrollResult<T>;
571
+ //#endregion
533
572
  //#region src/react/use-tween/index.d.ts
534
573
  interface UseTweenOptions {
535
574
  target: number;
@@ -775,5 +814,5 @@ declare const Swap: typeof SwapRoot & {
775
814
  State: typeof SwapState;
776
815
  };
777
816
  //#endregion
778
- export { type CanvasDrawFn, type ContainerBreakpoint, Defer, type DeferProps, type IdleOptions, type LifecyclePhase, type LifecycleReason, type LifecycleReducedMotion, type LoopTickFn, type MutationRecordsCallback, type PointerCallback, Presence, type PresenceMode, type PresencePhase, type PresenceProps, type PresenceReason, type RenderPhase, type ScrollProgressCallback, type SightCallback, type Size, type SizeCallback, Swap, type SwapProps, type SwapStateProps, type UseCanvasOptions, type UseCanvasResult, type UseContainerQueryOptions, type UseContainerQueryResult, type UseLifecycleOptions, type UseLifecycleResult, type UseLoopOptions, type UseLoopResult, type UseMutationOptions, type UseMutationResult, type UsePointerOptions, type UsePointerResult, type UsePresenceOptions, type UsePresenceResult, type UseScrollProgressOptions, type UseScrollProgressReactiveResult, type UseScrollProgressResult, type UseScrollProgressTransientResult, type UseSightOptions, type UseSightReactiveResult, type UseSightResult, type UseSightTransientResult, type UseSizeOptions, type UseSizeReactiveResult, type UseSizeResult, type UseSizeTransientResult, type UseTweenOptions, WhenIdle, type WhenIdleProps, WhenVisible, type WhenVisibleProps, useCanvas, useContainerQuery, useDevicePixelRatio, useIdle, useLifecycle, useLoop, useMediaQuery, useMutation, usePointer, usePrefersReducedMotion, usePresence, useRenderState, useScrollProgress, useSight, useSize, useStableCallback, useSyncedRef, useTween, useWhenIdle };
817
+ export { type CanvasDrawFn, type ContainerBreakpoint, Defer, type DeferProps, type IdleOptions, type LifecyclePhase, type LifecycleReason, type LifecycleReducedMotion, type LoopTickFn, type MutationRecordsCallback, type PointerCallback, Presence, type PresenceMode, type PresencePhase, type PresenceProps, type PresenceReason, type RenderPhase, type ScrollCallback, type ScrollProgressCallback, type SightCallback, type Size, type SizeCallback, Swap, type SwapProps, type SwapStateProps, type UseCanvasOptions, type UseCanvasResult, type UseContainerQueryOptions, type UseContainerQueryResult, type UseLifecycleOptions, type UseLifecycleResult, type UseLoopOptions, type UseLoopResult, type UseMutationOptions, type UseMutationResult, type UsePointerOptions, type UsePointerResult, type UsePresenceOptions, type UsePresenceResult, type UseScrollOptions, type UseScrollProgressOptions, type UseScrollProgressReactiveResult, type UseScrollProgressResult, type UseScrollProgressTransientResult, type UseScrollResult, type UseSightOptions, type UseSightReactiveResult, type UseSightResult, type UseSightTransientResult, type UseSizeOptions, type UseSizeReactiveResult, type UseSizeResult, type UseSizeTransientResult, type UseTweenOptions, WhenIdle, type WhenIdleProps, WhenVisible, type WhenVisibleProps, useCanvas, useContainerQuery, useDevicePixelRatio, useIdle, useLifecycle, useLoop, useMediaQuery, useMutation, usePointer, usePrefersReducedMotion, usePresence, useRenderState, useScroll, useScrollProgress, useSight, useSize, useStableCallback, useSyncedRef, useTween, useWhenIdle };
779
818
  //# sourceMappingURL=react.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"react.d.ts","names":[],"sources":["../src/react/use-synced-ref/index.ts","../src/react/use-stable-callback/index.ts","../src/react/use-loop/index.ts","../src/react/use-lifecycle/index.ts","../src/react/use-device-pixel-ratio/index.ts","../src/react/use-media/index.ts","../src/react/use-reduced-motion/index.ts","../src/react/use-sight/index.ts","../src/react/use-size/index.ts","../src/react/use-container-query/index.ts","../src/react/use-scroll-progress/index.ts","../src/react/use-render-state/index.ts","../src/react/use-idle/index.ts","../src/react/use-when-idle/index.ts","../src/react/use-canvas/index.ts","../src/react/use-mutation/index.ts","../src/react/use-pointer/index.ts","../src/react/use-tween/index.ts","../src/react/use-presence/index.ts","../src/react/presence/index.tsx","../src/react/when-visible/index.tsx","../src/react/when-idle/index.tsx","../src/react/defer/index.tsx","../src/react/swap/index.tsx"],"mappings":";;;;;;;AAYA;;;;;;;iBAAgB,YAAA,GAAA,CAAgB,KAAA,EAAO,CAAA,GAAI,SAAA,CAAU,CAAA;;;;;;;AAArD;;;;;iBCDgB,iBAAA,2BAAA,CACd,QAAA,MAAc,IAAA,EAAM,IAAA,KAAS,CAAA,OACxB,IAAA,EAAM,IAAA,KAAS,CAAA;;;;ADDtB;;;;KEQY,UAAA,IAAc,KAAA,EAAO,UAAA;AAAA,UAEhB,cAAA,WAAyB,OAAA,GAAU,cAAA;EFVA;;;;EEelD,GAAA,GAAM,SAAA,CAAU,CAAA;EFfyB;;;;EEoBzC,MAAA,EAAQ,UAAA;EACR,GAAA;EACA,OAAA;EACA,aAAA,GAAgB,qBAAA;EDxBe;EC0B/B,QAAA,GAAW,gBAAA;EDzBS;EC2BpB,WAAA;EACA,mBAAA,GAAsB,wBAAA;AAAA;AAAA,UAGP,aAAA,WAAwB,OAAA,GAAU,cAAA;ED9B5B;ECgCrB,GAAA,EAAK,SAAA,CAAU,CAAA;EACf,KAAA,EAAO,SAAA;EACP,WAAA,EAAa,UAAA;EACb,OAAA,EAAS,OAAA;EACT,aAAA,EAAe,cAAA;AAAA;;;;;;;;;AA7BjB;;;iBAuDgB,OAAA,WAAkB,OAAA,GAAU,cAAA,CAAA,CAC1C,OAAA,EAAS,cAAA,CAAe,CAAA,IACvB,aAAA,CAAc,CAAA;;;UClEA,mBAAA,WAA8B,OAAA,GAAU,cAAA;;AHCzD;;;EGIE,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,QAAA;EACA,QAAA;EACA,GAAA,EAAK,YAAA;EAAA,GACF;AAAA,GACF,aAAA,GAAgB,GAAA,CAAI,OAAA;;;UC9BN,UAAA,SAAmB,IAAA,CAAK,cAAA,CAAe,WAAA;;;AtBFxD;;EsBOE,EAAA,GAAK,WAAA;EtBPgC;;;;EsBYrC,eAAA;EACA,QAAA,GAAW,SAAA;EACX,GAAA,GAAM,GAAA,CAAI,WAAA;AAAA;;;;;;iBAYI,KAAA,CAAA;EACd,EAAA,EAAI,SAAA;EACJ,eAAA;EACA,QAAA;EACA,GAAA;EAAA,GACG;AAAA,GACF,UAAA,GAAa,GAAA,CAAI,OAAA;;;UCPH,SAAA,SAAkB,cAAA;EACjC,MAAA;EACA,YAAA;EACA,QAAA,EAAU,SAAA;AAAA;;;;;;;;;;;;;;;;;AtB7BZ;iBsBiDS,QAAA,CAAA;EACP,MAAA;EACA,YAAA;EACA,QAAA;EAAA,GACG;AAAA,GACF,SAAA,GAAY,GAAA,CAAI,OAAA;AAAA,UA+BF,cAAA,SAAuB,cAAA;EACtC,EAAA;EACA,GAAA,GAAM,GAAA,CAAI,cAAA;AAAA;AAAA,iBAGH,SAAA,CAAA;EACP,EAAA;EACA,GAAA,EAAK,YAAA;EACL,QAAA;EAAA,GACG;AAAA,GACF,cAAA,GAAiB,GAAA,CAAI,OAAA;AAAA,cAwCX,IAAA,SAAa,QAAA;EAAa,KAAA,SAAc,SAAA;AAAA"}
1
+ {"version":3,"file":"react.d.ts","names":[],"sources":["../src/react/use-synced-ref/index.ts","../src/react/use-stable-callback/index.ts","../src/react/use-loop/index.ts","../src/react/use-lifecycle/index.ts","../src/react/use-device-pixel-ratio/index.ts","../src/react/use-media/index.ts","../src/react/use-reduced-motion/index.ts","../src/react/use-sight/index.ts","../src/react/use-size/index.ts","../src/react/use-container-query/index.ts","../src/react/use-scroll-progress/index.ts","../src/react/use-render-state/index.ts","../src/react/use-idle/index.ts","../src/react/use-when-idle/index.ts","../src/react/use-canvas/index.ts","../src/react/use-mutation/index.ts","../src/react/use-pointer/index.ts","../src/react/use-scroll/index.ts","../src/react/use-tween/index.ts","../src/react/use-presence/index.ts","../src/react/presence/index.tsx","../src/react/when-visible/index.tsx","../src/react/when-idle/index.tsx","../src/react/defer/index.tsx","../src/react/swap/index.tsx"],"mappings":";;;;;;;AAYA;;;;;;;iBAAgB,YAAA,GAAA,CAAgB,KAAA,EAAO,CAAA,GAAI,SAAA,CAAU,CAAA;;;;;;;AAArD;;;;;iBCDgB,iBAAA,2BAAA,CACd,QAAA,MAAc,IAAA,EAAM,IAAA,KAAS,CAAA,OACxB,IAAA,EAAM,IAAA,KAAS,CAAA;;;;ADDtB;;;;KEQY,UAAA,IAAc,KAAA,EAAO,UAAA;AAAA,UAEhB,cAAA,WAAyB,OAAA,GAAU,cAAA;EFVA;;;;EEelD,GAAA,GAAM,SAAA,CAAU,CAAA;EFfyB;;;;EEoBzC,MAAA,EAAQ,UAAA;EACR,GAAA;EACA,OAAA;EACA,aAAA,GAAgB,qBAAA;EDxBe;EC0B/B,QAAA,GAAW,gBAAA;EDzBS;EC2BpB,WAAA;EACA,mBAAA,GAAsB,wBAAA;AAAA;AAAA,UAGP,aAAA,WAAwB,OAAA,GAAU,cAAA;ED9B5B;ECgCrB,GAAA,EAAK,SAAA,CAAU,CAAA;EACf,KAAA,EAAO,SAAA;EACP,WAAA,EAAa,UAAA;EACb,OAAA,EAAS,OAAA;EACT,aAAA,EAAe,cAAA;AAAA;;;;;;;;;AA7BjB;;;iBAuDgB,OAAA,WAAkB,OAAA,GAAU,cAAA,CAAA,CAC1C,OAAA,EAAS,cAAA,CAAe,CAAA,IACvB,aAAA,CAAc,CAAA;;;UClEA,mBAAA,WAA8B,OAAA,GAAU,cAAA;;AHCzD;;;EGIE,GAAA,GAAM,SAAA,CAAU,CAAA;EHJmC;EGMnD,aAAA,GAAgB,sBAAA;EHNkC;EGQlD,MAAA;EHR2B;EGU3B,OAAA;EACA,mBAAA,GAAsB,wBAAA;EHX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