-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathindex.ts
36 lines (35 loc) · 982 Bytes
/
index.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import { easeIn, easeOut, easeInOut } from "../abstraction";
import { EasingFunction } from "../abstraction";
export type DefaultEasingFunction =
| "linear"
| "easeInQuad"
| "easeOutQuad"
| "easeInOutQuad"
| "easeInCubic"
| "easeOutCubic"
| "easeInOutCubic"
| "easeInQuart"
| "easeOutQuart"
| "easeInOutQuart"
| "easeInQuint"
| "easeOutQuint"
| "easeInOutQuint";
export type EasingFunctionCollection = {
[k in DefaultEasingFunction]: EasingFunction
};
//taken from https://gist.github.com/gre/1650294#gistcomment-1806616
export const easingFunctions: EasingFunctionCollection = {
linear: easeInOut(1),
easeInQuad: easeIn(2),
easeOutQuad: easeOut(2),
easeInOutQuad: easeInOut(2),
easeInCubic: easeIn(3),
easeOutCubic: easeOut(3),
easeInOutCubic: easeInOut(3),
easeInQuart: easeIn(4),
easeOutQuart: easeOut(4),
easeInOutQuart: easeInOut(4),
easeInQuint: easeIn(5),
easeOutQuint: easeOut(5),
easeInOutQuint: easeInOut(5)
};