fix: reduce store rerenders and cleanup timers
This commit is contained in:
@@ -1098,6 +1098,8 @@ function ProductClonePage(_props: ProductClonePageProps = {}) {
|
||||
};
|
||||
|
||||
const clearCloneSetCountHold = () => {
|
||||
window.removeEventListener("pointerup", clearCloneSetCountHold);
|
||||
window.removeEventListener("pointercancel", clearCloneSetCountHold);
|
||||
if (countHoldTimeoutRef.current !== null) {
|
||||
window.clearTimeout(countHoldTimeoutRef.current);
|
||||
countHoldTimeoutRef.current = null;
|
||||
|
||||
Reference in New Issue
Block a user