Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
  • Loading branch information
pavelbabenko committed Jul 29, 2024
1 parent a4b20a6 commit 6a56cd6
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ return (
| doubleTapInterval? | Time in milliseconds between single and double tap events | `number` | `500` |
| maxScale? | Maximum scale user can set with gesture | `number` | `6` |
| pinchEnabled? | Is pinch gesture enabled | `boolean` | `true` |
| swipeEnabled? | Is pan gesture enabled | `boolean` | `true` |
| doubleTapEnabled? | Is double tap enabled | `boolean` | `true` |
| disableTransitionOnScaledImage? | Disables transition to next/previous image when scale > 1 | `boolean` | `false` |
| hideAdjacentImagesOnScaledImage? | Hides next and previous images when scale > 1 | `boolean` | `false` |
Expand All @@ -96,15 +97,16 @@ return (

## Events

| Prop | Description | Type |
|---------------------------|--------------------------------------------------------------------------------------------------------------------------------|------------|
| onSwipeToClose | Fired when user swiped to top/bottom | `Function` |
| onTap | Fired when user tap on image | `Function` |
| onDoubleTap | Fired when user double tap on image | `Function` |
| onLongPress | Fired when long press is detected | `Function` |
| onScaleStart | Fired when pinch gesture starts | `Function` |
| onScaleEnd(scale: number) | Fired when pinch gesture ends. Use case: add haptic feedback when user finished gesture with `scale > maxScale` or `scale < 1` | `Function` |
| onPanStart | Fired when pan gesture starts | `Function` |
| Prop | Description | Type |
|------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------|------------|
| onSwipeToClose() | Fired when user swiped to top/bottom | `Function` |
| onTranslationYChange(translationY: number, shouldClose: boolean) | `'worklet';` Fired when user is swiping vertically to close the gallery | `Worklet` |
| onTap() | Fired when user tap on image | `Function` |
| onDoubleTap(toScale: number) | Fired when user double tap on image | `Function` |
| onLongPress() | Fired when long press is detected | `Function` |
| onScaleStart(scale: number) | Fired when pinch gesture starts | `Function` |
| onScaleEnd(scale: number) | Fired when pinch gesture ends. Use case: add haptic feedback when user finished gesture with `scale > maxScale` or `scale < 1` | `Function` |
| onPanStart() | Fired when pan gesture starts | `Function` |

## Methods

Expand Down

0 comments on commit 6a56cd6

Please sign in to comment.