@pixodesk/svg-animator-web 1.0.26 → 1.0.28

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/dist/index.d.cts CHANGED
@@ -117,6 +117,13 @@ declare function createFrameLoopAnimator(doc: PxAnimatedSvgDocument, adapter?: P
117
117
  * @param forceEvenIfHasUnsupportedAttrs If true, an animator will be created even if some CSS properties are not supported.
118
118
  * @returns An PxAnimatorAPI instance, or null if unsupported features are used and not forced.
119
119
  */
120
- declare function createWebApiAnimator(doc: PxAnimatedSvgDocument, callbacks?: PxAnimatorCallbacksConfig, rootElement?: Element | null, forceEvenIfHasUnsupportedAttrs?: boolean): PxAnimatorAPI | null;
120
+ /** `driver: 'native'` payload (see PxScrollDriver.createNativeScrollTimeline): the
121
+ * browser-native timeline every Animation attaches to, plus optional range offsets. */
122
+ interface PxWebApiScrollTimeline {
123
+ timeline: AnimationTimeline;
124
+ rangeStart?: Record<string, unknown>;
125
+ rangeEnd?: Record<string, unknown>;
126
+ }
127
+ declare function createWebApiAnimator(doc: PxAnimatedSvgDocument, callbacks?: PxAnimatorCallbacksConfig, rootElement?: Element | null, forceEvenIfHasUnsupportedAttrs?: boolean, scrollTimeline?: PxWebApiScrollTimeline): PxAnimatorAPI | null;
121
128
 
122
129
  export { PX_ANIMATOR_DATA_KEY, type PxAnimatorAPI, type PxAnimatorOptions, type PxBasicAnimatorAPI, createAnimator, createAnimatorImpl, createFrameLoopAnimator, createWebApiAnimator, loadTagAnimators, renderNode, setupAnimationTriggers };
package/dist/index.d.ts CHANGED
@@ -117,6 +117,13 @@ declare function createFrameLoopAnimator(doc: PxAnimatedSvgDocument, adapter?: P
117
117
  * @param forceEvenIfHasUnsupportedAttrs If true, an animator will be created even if some CSS properties are not supported.
118
118
  * @returns An PxAnimatorAPI instance, or null if unsupported features are used and not forced.
119
119
  */
120
- declare function createWebApiAnimator(doc: PxAnimatedSvgDocument, callbacks?: PxAnimatorCallbacksConfig, rootElement?: Element | null, forceEvenIfHasUnsupportedAttrs?: boolean): PxAnimatorAPI | null;
120
+ /** `driver: 'native'` payload (see PxScrollDriver.createNativeScrollTimeline): the
121
+ * browser-native timeline every Animation attaches to, plus optional range offsets. */
122
+ interface PxWebApiScrollTimeline {
123
+ timeline: AnimationTimeline;
124
+ rangeStart?: Record<string, unknown>;
125
+ rangeEnd?: Record<string, unknown>;
126
+ }
127
+ declare function createWebApiAnimator(doc: PxAnimatedSvgDocument, callbacks?: PxAnimatorCallbacksConfig, rootElement?: Element | null, forceEvenIfHasUnsupportedAttrs?: boolean, scrollTimeline?: PxWebApiScrollTimeline): PxAnimatorAPI | null;
121
128
 
122
129
  export { PX_ANIMATOR_DATA_KEY, type PxAnimatorAPI, type PxAnimatorOptions, type PxBasicAnimatorAPI, createAnimator, createAnimatorImpl, createFrameLoopAnimator, createWebApiAnimator, loadTagAnimators, renderNode, setupAnimationTriggers };