Lower feedfeedback seen threshold to 0.5s (#6127)
This commit is contained in:
@@ -72,7 +72,7 @@ export function useFeedFeedback(feed: FeedDescriptor, hasSession: boolean) {
|
|||||||
|
|
||||||
const sendToFeed = React.useMemo(
|
const sendToFeed = React.useMemo(
|
||||||
() =>
|
() =>
|
||||||
throttle(sendToFeedNoDelay, 15e3, {
|
throttle(sendToFeedNoDelay, 10e3, {
|
||||||
leading: false,
|
leading: false,
|
||||||
trailing: true,
|
trailing: true,
|
||||||
}),
|
}),
|
||||||
|
|||||||
@@ -110,7 +110,7 @@ function ListImpl<ItemT>(
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
itemVisiblePercentThreshold: 40,
|
itemVisiblePercentThreshold: 40,
|
||||||
minimumViewTime: 1.5e3,
|
minimumViewTime: 0.5e3,
|
||||||
},
|
},
|
||||||
]
|
]
|
||||||
}, [onItemSeen])
|
}, [onItemSeen])
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ export type ListProps<ItemT> = Omit<
|
|||||||
}
|
}
|
||||||
export type ListRef = React.MutableRefObject<any | null> // TODO: Better types.
|
export type ListRef = React.MutableRefObject<any | null> // TODO: Better types.
|
||||||
|
|
||||||
const ON_ITEM_SEEN_WAIT_DURATION = 1.5e3 // when we consider post to be "seen"
|
const ON_ITEM_SEEN_WAIT_DURATION = 0.5e3 // when we consider post to be "seen"
|
||||||
const ON_ITEM_SEEN_INTERSECTION_OPTS = {
|
const ON_ITEM_SEEN_INTERSECTION_OPTS = {
|
||||||
rootMargin: '-200px 0px -200px 0px',
|
rootMargin: '-200px 0px -200px 0px',
|
||||||
} // post must be 200px visible to be "seen"
|
} // post must be 200px visible to be "seen"
|
||||||
|
|||||||
Reference in New Issue
Block a user