@yorozu/animations 0.3.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.
- package/LICENSE +21 -0
- package/README.md +199 -0
- package/index.d.ts +1 -0
- package/index.js +2229 -0
- package/package.json +21 -0
- package/playground/src/catalog.d.ts +8 -0
- package/playground/src/level-switch.d.ts +1 -0
- package/playground/src/level.d.ts +7 -0
- package/playground/src/main.d.ts +0 -0
- package/playground/src/overlay.d.ts +2 -0
- package/playground/src/testers/digit-flip.d.ts +1 -0
- package/playground/src/testers/dock.d.ts +1 -0
- package/playground/src/testers/fade.d.ts +1 -0
- package/playground/src/testers/list-layer.d.ts +1 -0
- package/playground/src/testers/list-reorder.d.ts +1 -0
- package/playground/src/testers/pinch-zoom.d.ts +1 -0
- package/playground/src/testers/popover.d.ts +1 -0
- package/playground/src/testers/presence-pop.d.ts +1 -0
- package/playground/src/testers/ripple.d.ts +1 -0
- package/playground/src/testers/scroll-tween.d.ts +1 -0
- package/playground/src/testers/send-flight.d.ts +1 -0
- package/playground/src/testers/shared-element.d.ts +1 -0
- package/playground/src/testers/sliding-indicator.d.ts +1 -0
- package/playground/src/testers/spoiler.d.ts +1 -0
- package/playground/src/testers/swipe-reveal.d.ts +1 -0
- package/playground/src/testers/tabs.d.ts +1 -0
- package/playground/src/testers/view-slide-modes.d.ts +3 -0
- package/playground/src/testers/view-slide.d.ts +1 -0
- package/playground/src/testers/waveform.d.ts +1 -0
- package/src/core/level.d.ts +10 -0
- package/src/core/playback.d.ts +7 -0
- package/src/core/raf.d.ts +1 -0
- package/src/core/reduced-motion.d.ts +1 -0
- package/src/core/styles.d.ts +2 -0
- package/src/core/tween.d.ts +11 -0
- package/src/core/types.d.ts +9 -0
- package/src/digit-flip/play.d.ts +12 -0
- package/src/digit-flip/slots.d.ts +14 -0
- package/src/dock/dock.d.ts +23 -0
- package/src/dock/transforms.d.ts +14 -0
- package/src/fade/fade.d.ts +11 -0
- package/src/index.d.ts +45 -0
- package/src/list-reorder/classify.d.ts +10 -0
- package/src/list-reorder/reorder.d.ts +19 -0
- package/src/pinch-zoom/math.d.ts +21 -0
- package/src/pinch-zoom/pinch.d.ts +15 -0
- package/src/popover/popover.d.ts +14 -0
- package/src/rect/fit.d.ts +5 -0
- package/src/rect/types.d.ts +17 -0
- package/src/ripple/ripple.d.ts +13 -0
- package/src/scroll-tween/scroll.d.ts +8 -0
- package/src/send-flight/flight.d.ts +14 -0
- package/src/shared-element/math.d.ts +45 -0
- package/src/shared-element/player.d.ts +52 -0
- package/src/sliding-indicator/indicator.d.ts +15 -0
- package/src/spoiler/spoiler.d.ts +14 -0
- package/src/swipe-reveal/swipe.d.ts +16 -0
- package/src/view-slide/session.d.ts +27 -0
- package/src/view-slide/transforms.d.ts +34 -0
- package/src/waveform/decode.d.ts +2 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { AnimationLevel } from '../core/level';
|
|
2
|
+
import { Key } from '../core/types';
|
|
3
|
+
export type SlideDirection = "forward" | "back";
|
|
4
|
+
export type ViewSlideMode = "push" | "crossfade" | "cover" | "peek" | "lift" | "zoom" | "reveal" | "none";
|
|
5
|
+
export type ViewSlideKind = "stack" | "layer";
|
|
6
|
+
export type ViewSlideMountPolicy = "keep-visited" | "active-plus-leaving";
|
|
7
|
+
export type PanelRole = "entering" | "leaving" | "active" | "idle";
|
|
8
|
+
export type SlidePanelState = {
|
|
9
|
+
transform: string;
|
|
10
|
+
opacity: string;
|
|
11
|
+
clipPath?: string;
|
|
12
|
+
};
|
|
13
|
+
export type SlideTransforms = {
|
|
14
|
+
fromStart: SlidePanelState;
|
|
15
|
+
fromEnd: SlidePanelState;
|
|
16
|
+
toStart: SlidePanelState;
|
|
17
|
+
toEnd: SlidePanelState;
|
|
18
|
+
};
|
|
19
|
+
export declare const VIEW_SLIDE_FADE_OFFSET: string;
|
|
20
|
+
export declare const VIEW_SLIDE_MS: number;
|
|
21
|
+
export declare const VIEW_SLIDE_EASING: string;
|
|
22
|
+
export declare const VIEW_SLIDE_COVER_MS: number;
|
|
23
|
+
export declare const VIEW_SLIDE_COVER_EASING: string;
|
|
24
|
+
export declare const VIEW_SLIDE_ZOOM_MS: number;
|
|
25
|
+
export declare const VIEW_SLIDE_ZOOM_EASING: string;
|
|
26
|
+
export declare const VIEW_SLIDE_REVEAL_MS: number;
|
|
27
|
+
export declare const VIEW_SLIDE_REVEAL_EASING: string;
|
|
28
|
+
export declare function slideDirectionByIndex(from: Key, to: Key, items: readonly {
|
|
29
|
+
id: Key;
|
|
30
|
+
}[]): SlideDirection | null;
|
|
31
|
+
export declare function resolveViewSlideMode(level: AnimationLevel, kind: ViewSlideKind): ViewSlideMode;
|
|
32
|
+
export declare function viewSlideDurationMs(mode: Exclude<ViewSlideMode, "none">): number;
|
|
33
|
+
export declare function viewSlideEasing(mode: Exclude<ViewSlideMode, "none">): string;
|
|
34
|
+
export declare function viewSlideTransforms(direction: SlideDirection, mode: Exclude<ViewSlideMode, "none">): SlideTransforms;
|