aboutsummaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2026-10-13 23:36:16 +0000
committerAdam Soltys <[email protected]>2026-10-13 23:36:16 +0000
commit9ce87d8742ea44918e73625cc79a0fc184b4597c (patch)
tree6e5cc0cf40516d1dc576871fde75fdaa78c02a42 /tools
parent35feb53c50cf5662aca40e9af5a0547e36297631 (diff)
downloadcoinosv3-9ce87d8742ea44918e73625cc79a0fc184b4597c.tar.gz
coinosv3-9ce87d8742ea44918e73625cc79a0fc184b4597c.zip
Pager swipes: follow the finger sooner, page on a shorter swipe, glide faster, no step back
- The glide was timed from now, but a frame's time can be a little earlier: its first frame stepped back (72px -> 58) before going on, the choppy 'reset' on letting go. Timed from its first frame now. - Slides follow the finger after 10px (was 30: a dead zone, then a jump). A touch that comes and goes within 24px and 350ms is still a tap. - On letting go: on to the next past a tenth of the width across, an eighth of the height down, or a flick of 24px at 0.2px/ms (was a fifth, 48px, 0.3). - Glide at most 130ms (was 170). Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_01KPw21NEpWeTGu6swVASmBt
Diffstat (limited to 'tools')
-rw-r--r--tools/pager-tap-slop-test.js14
1 files changed, 12 insertions, 2 deletions
diff --git a/tools/pager-tap-slop-test.js b/tools/pager-tap-slop-test.js
index bcc790c..09f761a 100644
--- a/tools/pager-tap-slop-test.js
+++ b/tools/pager-tap-slop-test.js
@@ -99,9 +99,9 @@ try {
await drag(195, 420, 6, 14);
s = await st();
check('14px down and a little across: a tap — it plays on, still there', s.paused === false && s.on === 'tall.webm', JSON.stringify(s));
- await drag(195, 420, 0, -25, 1);
+ await drag(195, 420, 0, -20, 1);
s = await st();
- check('a quick 25px flick: still a tap — paused, not paged', s.paused === true && s.on === 'tall.webm', JSON.stringify(s));
+ check('a quick 20px flick: still a tap — paused, not paged', s.paused === true && s.on === 'tall.webm', JSON.stringify(s));
await drag(195, 420, 0, 0, 1);
s = await st();
check('a still tap plays it again', s.paused === false && s.on === 'tall.webm', JSON.stringify(s));
@@ -123,6 +123,16 @@ try {
await drag(195, 500, 0, -80, 2);
s = await st();
check('a quick 80px flick up: the next post', s.on === was, JSON.stringify(s));
+ await drag(195, 500, 0, 300, 8);
+ await drag(195, 500, 0, -40, 2);
+ s = await st();
+ check('a quick 40px flick up: the next post too', s.on === was, JSON.stringify(s));
+ await drag(195, 500, 0, 300, 8);
+ await page.touchscreen.touchStart(195, 500);
+ for (let i = 1; i <= 12; i++) { await page.touchscreen.touchMove(195, 500 - 9 * i); await sleep(30); }
+ await page.touchscreen.touchEnd(); await sleep(900);
+ s = await st();
+ check('a steady 108px drag up (an eighth of the screen): the next post', s.on === was, JSON.stringify(s));
console.log('\n[snappy: let go, and it lands at once]');
await drag(195, 500, 0, 300, 8);