Remove view selector offsetting (close #1174) (#1183)

* Remove view selector offsetting (close #1174)

* Remove horizontal scroll indicator in view selector
zio/stable
Paul Frazee 2023-08-15 15:13:40 -07:00 committed by GitHub
parent ce1d75e164
commit 6964382bad
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 5 deletions

View File

@ -137,8 +137,6 @@ export const ViewSelector = React.forwardRef<
},
)
const SCROLLBAR_OFFSET = 12
export function Selector({
selectedIndex,
items,
@ -166,15 +164,15 @@ export function Selector({
width: '100%',
position: 'relative',
overflow: 'hidden',
marginTop: -SCROLLBAR_OFFSET,
height,
backgroundColor: pal.colors.background,
}}>
<ScrollView
horizontal
style={{position: 'absolute', bottom: -SCROLLBAR_OFFSET}}>
showsHorizontalScrollIndicator={false}
style={{position: 'absolute'}}>
<View
style={[pal.view, styles.outer, {paddingBottom: SCROLLBAR_OFFSET}]}
style={[pal.view, styles.outer]}
onLayout={e => {
const {height} = e.nativeEvent.layout
setHeight(height || 60)