* Computes the destination by the velocity and the `flickPower` option. * * @param velocity - The drag velocity. * * @return The destination.
( velocity: number )
| 296 | * @return The destination. |
| 297 | */ |
| 298 | function computeDestination( velocity: number ): number { |
| 299 | return getPosition() + sign( velocity ) * min( |
| 300 | abs( velocity ) * ( options.flickPower || 600 ), |
| 301 | isFree ? Infinity : Components.Layout.listSize() * ( options.flickMaxPages || 1 ) |
| 302 | ); |
| 303 | } |
| 304 | |
| 305 | /** |
| 306 | * Returns the coord difference between the provided and base events. |
no test coverage detected
searching dependent graphs…