diff --git a/example/src/component/NavigationPanel/LogsPanel.tsx b/example/src/component/NavigationPanel/LogsPanel.tsx index ae89692f..317d372e 100644 --- a/example/src/component/NavigationPanel/LogsPanel.tsx +++ b/example/src/component/NavigationPanel/LogsPanel.tsx @@ -4,7 +4,6 @@ import { FlatList } from 'react-native-gesture-handler'; import type { LogsPanelProps } from './types'; export function LogsPanel({ logs }: LogsPanelProps) { - console.log(logs); return ( { render() { const fractionalPosition = this.props.progress.position + this.props.progress.offset; - const size = fractionalPosition / (this.props.numberOfPages - 1); + const size = + this.props.numberOfPages > 1 + ? fractionalPosition / (this.props.numberOfPages - 1) + : 0; const clampedSize = Math.max(0, Math.min(1, size)); return (