mirror of
https://github.com/cheeaun/phanpy.git
synced 2025-02-02 14:16:39 +01:00
Forgot to import
This commit is contained in:
parent
228c0e5028
commit
a78417ac60
1 changed files with 3 additions and 2 deletions
|
@ -7,6 +7,7 @@ import {
|
|||
MenuHeader,
|
||||
MenuItem,
|
||||
} from '@szhsin/react-menu';
|
||||
import 'long-press-event';
|
||||
import mem from 'mem';
|
||||
import pThrottle from 'p-throttle';
|
||||
import { memo } from 'preact/compat';
|
||||
|
@ -499,9 +500,9 @@ function Status({
|
|||
});
|
||||
setIsContextMenuOpen(true);
|
||||
}
|
||||
statusRef.current.addEventListener('long-press', openContextMenu);
|
||||
statusRef.current?.addEventListener?.('long-press', openContextMenu);
|
||||
return () => {
|
||||
statusRef.current.removeEventListener('long-press', openContextMenu);
|
||||
statusRef.current?.removeEventListener?.('long-press', openContextMenu);
|
||||
};
|
||||
}, []);
|
||||
|
||||
|
|
Loading…
Reference in a new issue