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
Copy file name to clipboardExpand all lines: docs/docs/components/gallery.md
+35-4Lines changed: 35 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -176,21 +176,36 @@ Blank space between items.
176
176
| -------- | ------- |
177
177
|`number`|`0`|
178
178
179
-
Sets the initial position of the list.
179
+
Set the initial position of the list.
180
+
181
+
### rtl
182
+
| Type | Default |
183
+
| --------- | ------- |
184
+
|`boolean`|`false`|
185
+
186
+
Enable support for right to left layouts on horizontal mode, [more info](https://github.com/Glazzes/react-native-zoom-toolkit/issues/99#issuecomment-3029442065).
180
187
181
188
### vertical
182
189
183
190
| Type | Default |
184
191
| --------- | ------- |
185
192
|`boolean`|`false`|
186
193
187
-
Modifies the orientation of the component to vertical mode.
194
+
Modify the orientation of the component to vertical mode.
195
+
196
+
### snapTimingConfig
197
+
198
+
| Type | Default | Adittional Info |
199
+
| -------- | ------------| --------------- |
200
+
|`object`|`{duration: 300, easing: Easing.out(Easing.cubic)}`| see [timingConfig](https://docs.swmansion.com/react-native-reanimated/docs/animations/withTiming/#config-)|
201
+
202
+
Set the timing config used to snap between gallery's elements.
188
203
189
204
### maxScale
190
205
191
206
| Type | Default |
192
207
| -------------------------------- | ------- |
193
-
|`SizeVector<number>[] \| number`|`6`|
208
+
|`Size<number>[] \| number`|`6`|
194
209
195
210
Maximum scale value allowed by the pinch gesture for all elements, expects values bigger than or equals one.
196
211
@@ -288,6 +303,22 @@ Callback triggered when the list scrolls to the next or previous item.
288
303
289
304
Callback triggered when the user taps the current item once, provides additional metadata like index if you need it.
Copy file name to clipboardExpand all lines: docs/docs/components/snapbackzoom.md
+20Lines changed: 20 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -82,6 +82,26 @@ All properties for this component are optional.
82
82
83
83
Increase (Android only) or decrease the gesture detection area around your component in all directions by a given amount in pixels, useful when dealing with small components.
84
84
85
+
### minScale
86
+
87
+
| Type | Default |
88
+
| -------- | ------- |
89
+
|`number`|`0`|
90
+
91
+
Minimum scale value allowed by the pinch gesture, expects values greater than or equals one.
92
+
93
+
### maxScale
94
+
95
+
| Type | Default |
96
+
| ------------------------------ | ------- |
97
+
|`Size<number> \| number`|`6`|
98
+
99
+
Maximum scale value allowed by the pinch gesture, expects values bigger than or equals one.
100
+
101
+
Alternatively you can pass the resolution of your image/video, for instance `{ width: 1920, height: 1080 }`;
102
+
this will instruct the component to calculate `maxScale` in such a way it's a value just before your content
Copy file name to clipboardExpand all lines: docs/docs/utilities/usetransformationstate.md
+2-3Lines changed: 2 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -12,11 +12,10 @@ your choice, for a hands on example see [How to use with Skia Components](../gui
12
12
13
13
When calling this hook you will receive the three following properties:
14
14
15
-
-`onUpdate` is a worklet function which must be passed as a property to the zoom component's onUpdate
15
+
-`onUpdate` is a [worklet](https://docs.swmansion.com/react-native-reanimated/docs/guides/worklets/) which must be passed as a property to the zoom component's onUpdate
16
16
callback property, this way the zoom component will update transform and state properties.
17
17
-`transform` is a shared value describing zoom component's current transformations as an array.
18
-
-`state` is an object holding the shared values describing the current transformation state, in case
19
-
you need them.
18
+
-`state` is an object holding the [Reanimated's shared values](https://docs.swmansion.com/react-native-reanimated/docs/2.x/fundamentals/shared-values/) describing the current transformation state in case you need them.
20
19
21
20
```tsx{9,21}
22
21
import { useTransformationState } from 'react-native-zoom-toolkit';
0 commit comments