This commit is contained in:
Timothy Jaeryang Baek committed 2026-05-09 06:44:42 +09:00
1 parent bb0e6cb108
commit 29f6c72e87
1 file changed
+9 -3
@@ -71,11 +71,17 @@
};
const updateHandler = (content) => {
if (content && !pendingUpdate) {
pendingUpdate = requestAnimationFrame(() => {
if (content) {
if (done) {
cancelAnimationFrame(pendingUpdate);
pendingUpdate = null;
parseTokens();
});
} else if (!pendingUpdate) {
pendingUpdate = requestAnimationFrame(() => {
pendingUpdate = null;
parseTokens();
});
}
}
};