aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2026-09-04 07:12:20 -0700
committerAdam Soltys <[email protected]>2026-09-04 07:12:20 -0700
commitbae8f183e4f7095b027b81c3cc79f55dafbd2bba (patch)
tree74c1dfd53512aa3b1f6397d18a05051e3e6aae4e /src
parent787dd33d40cc33c32dc9f138561c1b58f6a765e7 (diff)
downloadcoinosv3-bae8f183e4f7095b027b81c3cc79f55dafbd2bba.tar.gz
coinosv3-bae8f183e4f7095b027b81c3cc79f55dafbd2bba.zip
TEMP: add dropped-frame logging to carousel diagnostics — logs any >40ms frame gap into __dl so a real drag's jank appears next to the release/settle it overlaps
Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01MrkLsNScXe9b6BviUSdmMr
Diffstat (limited to 'src')
-rw-r--r--src/app.js13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/app.js b/src/app.js
index 956d465..ab21cf9 100644
--- a/src/app.js
+++ b/src/app.js
@@ -3186,9 +3186,20 @@ function dlog(s) {
try {
const a = (window.__dl = window.__dl || []);
a.push(Math.round(performance.now()) + ' ' + s);
- if (a.length > 60) a.shift();
+ if (a.length > 120) a.shift();
} catch {}
}
+// TEMP: continuously watch for dropped frames and log any >40ms gap, so a
+// real drag's jank shows up in __dl next to the release/settle it overlaps.
+try {
+ let _lastFrame = performance.now();
+ const _fw = (t) => {
+ const gap = t - _lastFrame; _lastFrame = t;
+ if (gap > 40) dlog('FRAME-DROP ' + Math.round(gap) + 'ms');
+ requestAnimationFrame(_fw);
+ };
+ requestAnimationFrame(_fw);
+} catch {}
// Spending is opt-in: a wallet is born on-chain only, and the second balance
// (with its toggle, swipe, and Move money) appears once the user sets it up —
// or the moment money is already there (a restored wallet, a claimed gift),