mirror of
https://github.com/Stremio/stremio-web.git
synced 2026-03-11 21:27:05 +00:00
refactor(BottomSheet): remove unnecessary useCallback
This commit is contained in:
parent
1d0cb4dfa0
commit
19085da76b
1 changed files with 2 additions and 2 deletions
|
|
@ -40,10 +40,10 @@ const BottomSheet = ({ children, title, show }: Props) => {
|
|||
setOffset(Math.max(0, clientY - startOffset));
|
||||
}, [startOffset]);
|
||||
|
||||
const onTouchEnd = useCallback(() => {
|
||||
const onTouchEnd = () => {
|
||||
setOffset((offset) => offset > CLOSE_THRESHOLD ? containerHeight() : 0);
|
||||
setStartOffset(0);
|
||||
}, []);
|
||||
};
|
||||
|
||||
const onTransitionEnd = useCallback(() => {
|
||||
(offset === containerHeight()) && close();
|
||||
|
|
|
|||
Loading…
Reference in a new issue