From bae8f183e4f7095b027b81c3cc79f55dafbd2bba Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Fri, 4 Sep 2026 07:12:20 -0700 Subject: 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 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: Claude Fable 5 Claude-Session: https://claude.ai/code/session_01MrkLsNScXe9b6BviUSdmMr --- src/app.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'src') 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), -- cgit v1.2.3