Resolve all remaining lint issues (#88)
* Rework 'navIdx' variables from number arrays to strings to avoid equality-check failures in react hooks * Resolve all remaining lint issues * Fix tests * Use node v18 in gh action test
This commit is contained in:
parent
3a90114f3a
commit
f36c956536
60 changed files with 478 additions and 482 deletions
|
@ -5,6 +5,7 @@ import {HorzSwipe} from './gestures/HorzSwipe'
|
|||
import {useAnimatedValue} from '../../lib/hooks/useAnimatedValue'
|
||||
import {OnScrollCb} from '../../lib/hooks/useOnMainScroll'
|
||||
import {clamp} from '../../../lib/numbers'
|
||||
import {s} from '../../lib/styles'
|
||||
|
||||
const HEADER_ITEM = {_reactKey: '__header__'}
|
||||
const SELECTOR_ITEM = {_reactKey: '__selector__'}
|
||||
|
@ -54,7 +55,7 @@ export function ViewSelector({
|
|||
setSelectedIndex(clamp(index, 0, sections.length))
|
||||
useEffect(() => {
|
||||
onSelectView?.(selectedIndex)
|
||||
}, [selectedIndex])
|
||||
}, [selectedIndex, onSelectView])
|
||||
|
||||
// rendering
|
||||
// =
|
||||
|
@ -98,7 +99,7 @@ export function ViewSelector({
|
|||
onScroll={onScroll}
|
||||
onRefresh={onRefresh}
|
||||
onEndReached={onEndReached}
|
||||
contentContainerStyle={{paddingBottom: 200}}
|
||||
contentContainerStyle={s.contentContainer}
|
||||
/>
|
||||
</HorzSwipe>
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue