revert back to headerHeight
This commit is contained in:
@@ -29,7 +29,7 @@ interface LabelsSectionProps {
|
|||||||
labelerError: Error | null
|
labelerError: Error | null
|
||||||
moderationOpts: ModerationOpts
|
moderationOpts: ModerationOpts
|
||||||
scrollElRef: ListRef
|
scrollElRef: ListRef
|
||||||
headerOffset: number
|
headerHeight: number
|
||||||
isFocused: boolean
|
isFocused: boolean
|
||||||
setScrollViewTag: (tag: number | null) => void
|
setScrollViewTag: (tag: number | null) => void
|
||||||
}
|
}
|
||||||
@@ -41,7 +41,7 @@ export function ProfileLabelsSection({
|
|||||||
labelerError,
|
labelerError,
|
||||||
moderationOpts,
|
moderationOpts,
|
||||||
scrollElRef,
|
scrollElRef,
|
||||||
headerOffset,
|
headerHeight,
|
||||||
isFocused,
|
isFocused,
|
||||||
setScrollViewTag,
|
setScrollViewTag,
|
||||||
}: LabelsSectionProps) {
|
}: LabelsSectionProps) {
|
||||||
@@ -50,9 +50,9 @@ export function ProfileLabelsSection({
|
|||||||
const onScrollToTop = useCallback(() => {
|
const onScrollToTop = useCallback(() => {
|
||||||
scrollElRef.current?.scrollToOffset({
|
scrollElRef.current?.scrollToOffset({
|
||||||
animated: isNative,
|
animated: isNative,
|
||||||
offset: -headerOffset,
|
offset: -headerHeight,
|
||||||
})
|
})
|
||||||
}, [scrollElRef, headerOffset])
|
}, [scrollElRef, headerHeight])
|
||||||
|
|
||||||
useImperativeHandle(ref, () => ({
|
useImperativeHandle(ref, () => ({
|
||||||
scrollToTop: onScrollToTop,
|
scrollToTop: onScrollToTop,
|
||||||
@@ -124,7 +124,7 @@ export function ProfileLabelsSection({
|
|||||||
renderItem={renderItem}
|
renderItem={renderItem}
|
||||||
keyExtractor={keyExtractor}
|
keyExtractor={keyExtractor}
|
||||||
contentContainerStyle={a.px_xl}
|
contentContainerStyle={a.px_xl}
|
||||||
headerOffset={headerOffset}
|
headerOffset={headerHeight}
|
||||||
progressViewOffset={ios(0)}
|
progressViewOffset={ios(0)}
|
||||||
ListHeaderComponent={
|
ListHeaderComponent={
|
||||||
<LabelerListHeader
|
<LabelerListHeader
|
||||||
@@ -137,7 +137,7 @@ export function ProfileLabelsSection({
|
|||||||
}
|
}
|
||||||
ListFooterComponent={
|
ListFooterComponent={
|
||||||
<ListFooter
|
<ListFooter
|
||||||
height={headerOffset + 180}
|
height={headerHeight + 180}
|
||||||
style={a.border_transparent}
|
style={a.border_transparent}
|
||||||
/>
|
/>
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -380,7 +380,7 @@ function ProfileScreenLoaded({
|
|||||||
isLabelerLoading={isLabelerLoading}
|
isLabelerLoading={isLabelerLoading}
|
||||||
moderationOpts={moderationOpts}
|
moderationOpts={moderationOpts}
|
||||||
scrollElRef={scrollElRef as ListRef}
|
scrollElRef={scrollElRef as ListRef}
|
||||||
headerOffset={headerHeight}
|
headerHeight={headerHeight}
|
||||||
isFocused={isFocused}
|
isFocused={isFocused}
|
||||||
setScrollViewTag={setScrollViewTag}
|
setScrollViewTag={setScrollViewTag}
|
||||||
/>
|
/>
|
||||||
|
|||||||
Reference in New Issue
Block a user