File tree Expand file tree Collapse file tree 3 files changed +5
-3
lines changed Expand file tree Collapse file tree 3 files changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -116,6 +116,7 @@ import Carousel from 'react-native-reanimated-carousel';
116116| onScrollBegin | ❌ | | () => void | Callback fired when scroll begin |
117117| onScrollEnd | ❌ | | (previous: number, current: number) => void | Callback fired when scroll end |
118118| panGestureHandlerProps | ❌ | {} | Omit<Partial\< PanGestureHandlerProps\> ,'onHandlerStateChange'> | PanGestureHandler props |
119+ | windowSize | ❌ | 0 | number | The maximum number of items that can respond to pan gesture events, ` 0 ` means all items will respond to pan gesture events
119120| onProgressChange | ❌ | | onProgressChange?: (offsetProgress: number,absoluteProgress: number) => void | On progress change. ` offsetProgress ` : Total of offset distance (0 390 780 ...); ` absoluteProgress ` : Convert to index (0 1 2 ...) |
120121
121122## Ref
Original file line number Diff line number Diff line change @@ -115,7 +115,8 @@ import Carousel from 'react-native-reanimated-carousel';
115115| onSnapToItem | ❌ | | (index: number) => void | 切换至另一张轮播图时触发 |
116116| onScrollBegin | ❌ | | () => void | 切换动画开始时触发 |
117117| onScrollEnd | ❌ | | (previous: number, current: number) => void | 切换动画结束时触发 |
118- | panGestureHandlerProps | ❌ | {} | Omit<Partial\< PanGestureHandlerProps\> ,'onHandlerStateChange'> | PanGestureHandler props |
118+ | panGestureHandlerProps | ❌ | {} | Omit<Partial\< PanGestureHandlerProps\> ,'onHandlerStateChange'> | PanGestureHandler props
119+ | windowSize | ❌ | 0 | number | 能响应平移手势事件的最大item数量,0表示所有元素都会先响应 |
119120| onProgressChange | ❌ | | onProgressChange?: (offsetProgress: number,absoluteProgress: number) => void | 当滚动进度发生变化时触发 ` offsetProgress ` :总的偏移值 (0 390 780 ...); ` absoluteProgress ` :转化为 index 的进度变化 (0 1 2 ...) |
120121
121122## Ref
Original file line number Diff line number Diff line change @@ -96,10 +96,10 @@ export interface ICarouselProps<T extends unknown> {
9696 'onHandlerStateChange'
9797 > ;
9898 /**
99- * Determines the maximum number of items will respond to scroll animation events,
99+ * Determines the maximum number of items will respond to pan gesture events,
100100 * windowSize={11} will active visible item plus up to 5 items above and 5 below the viewpor,
101101 * Reducing this number will reduce the calculation of the animation value and may improve performance.
102- * @default 0 all items will be activated .
102+ * @default 0 all items will respond to pan gesture events .
103103 */
104104 windowSize ?: number ;
105105 /**
You can’t perform that action at this time.
0 commit comments