You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
|**speed**|`number`|| A value representing the elements scroll speed. If less than zero scroll will appear slower. If greater than zero scroll will appear faster. |
54
-
|**translateX**|`string[]` or `number[]`|| Start and end translation on x-axis in `%` or `px`. If no unit is passed percent is assumed. Percent is based on the elements width. |
55
-
|**translateY**|`string[]` or `number[]`|| Start and end translation on y-axis in `%` or `px`. If no unit is passed percent is assumed. Percent is based on the elements height. |
56
-
|**rotate**|`string[]` or `number[]`|| Start and end rotation on z-axis in `deg`, `rad`, or `turn`. If no unit is passed `deg` is assumed. |
57
-
|**rotateX**|`string[]` or `number[]`|| Start and end rotation on x-axis in `deg`, `rad`, or `turn`. If no unit is passed `deg` is assumed. |
58
-
|**rotateY**|`string[]` or `number[]`|| Start and end rotation on y-axis in `deg`, `rad`, or `turn`. If no unit is passed `deg` is assumed. |
59
-
|**rotateZ**|`string[]` or `number[]`|| Start and end rotation on z-axis in `deg`, `rad`, or `turn`. If no unit is passed `deg` is assumed. |
60
-
|**scale**|`number[]`|| Start and end scale on x-axis and y-axis. |
61
-
|**scaleX**|`number[]`|| Start and end scale on x-axis. |
62
-
|**scaleY**|`number[]`|| Start and end scale on y-axis. |
63
-
|**scaleZ**|`number[]`|| Start and end scale on z-axis. |
64
-
|**opacity**|`number[]`|| Start and end opacity value. |
65
-
|**className**|`string`|| Optionally pass additional class names to be added to the outermost parallax element. |
66
-
|**disabled**|`boolean`|`false`| Disables parallax effects on individual elements when `true`. |
67
-
|**styleInner**|`object`|| Optionally pass a style object to be added to the innermost parallax element. |
68
-
|**styleOuter**|`object`|| Optionally pass a style object to be added to the outermost parallax element. |
69
-
|**tagInner**|`string`|`div`| Optionally pass an element tag name to be applied to the innermost parallax element. |
70
-
|**tagOuter**|`string`|`div`| Optionally pass an element tag name to be applied to the outermost parallax element. |
|**speed**|`number`|| A value representing the elements scroll speed. If less than zero scroll will appear slower. If greater than zero scroll will appear faster. |
54
+
|**translateX**|`string[]` or `number[]`|| Start and end translation on x-axis in `%` or `px`. If no unit is passed percent is assumed. Percent is based on the elements width. |
55
+
|**translateY**|`string[]` or `number[]`|| Start and end translation on y-axis in `%` or `px`. If no unit is passed percent is assumed. Percent is based on the elements height. |
56
+
|**rotate**|`string[]` or `number[]`|| Start and end rotation on z-axis in `deg`, `rad`, or `turn`. If no unit is passed `deg` is assumed. |
57
+
|**rotateX**|`string[]` or `number[]`|| Start and end rotation on x-axis in `deg`, `rad`, or `turn`. If no unit is passed `deg` is assumed. |
58
+
|**rotateY**|`string[]` or `number[]`|| Start and end rotation on y-axis in `deg`, `rad`, or `turn`. If no unit is passed `deg` is assumed. |
59
+
|**rotateZ**|`string[]` or `number[]`|| Start and end rotation on z-axis in `deg`, `rad`, or `turn`. If no unit is passed `deg` is assumed. |
60
+
|**scale**|`number[]`|| Start and end scale on x-axis and y-axis. |
61
+
|**scaleX**|`number[]`|| Start and end scale on x-axis. |
62
+
|**scaleY**|`number[]`|| Start and end scale on y-axis. |
63
+
|**scaleZ**|`number[]`|| Start and end scale on z-axis. |
64
+
|**opacity**|`number[]`|| Start and end opacity value. |
65
+
|**easing**|`string` or `number[]`|| String representing an [easing preset](#easing-preset) or array of params to supply to a [cubic bezier easing function](#cubic-bezier-easing-function). |
66
+
|**className**|`string`|| Optionally pass additional class names to be added to the outermost parallax element. |
67
+
|**disabled**|`boolean`|`false`| Disables parallax effects on individual elements when `true`. |
68
+
|**styleInner**|`object`|| Optionally pass a style object to be added to the innermost parallax element. |
69
+
|**styleOuter**|`object`|| Optionally pass a style object to be added to the outermost parallax element. |
70
+
|**tagInner**|`string`|`div`| Optionally pass an element tag name to be applied to the innermost parallax element. |
71
+
|**tagOuter**|`string`|`div`| Optionally pass an element tag name to be applied to the outermost parallax element. |
72
+
73
+
### Easing Presets
74
+
75
+
The following easing values are preset and can be used as easing
76
+
77
+
```jsx
78
+
<Parallax easing="easeInCubic"/>
79
+
```
80
+
81
+
```
82
+
ease
83
+
easeIn
84
+
easeOut
85
+
easeInOut
86
+
easeInQuad
87
+
easeInCubic
88
+
easeInQuart
89
+
easeInQuint
90
+
easeInSine
91
+
easeInExpo
92
+
easeInCirc
93
+
easeOutQuad
94
+
easeOutCubic
95
+
easeOutQuart
96
+
easeOutQuint
97
+
easeOutSine
98
+
easeOutExpo
99
+
easeOutCirc
100
+
easeInOutQuad
101
+
easeInOutCubic
102
+
easeInOutQuart
103
+
easeInOutQuint
104
+
easeInOutSine
105
+
easeInOutExpo
106
+
easeInOutCirc
107
+
easeInBack
108
+
easeOutBack
109
+
easeInOutBack
110
+
```
111
+
112
+
### Cubic Bezier Easing Function
113
+
114
+
Just like with CSS `cubic-bezier(0.2,-0.67,1,-0.62);`, you can supply the 4 params to a custom bezier function.
0 commit comments