aboutsummaryrefslogtreecommitdiffstats
path: root/tools/profile-pager-test.js
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2026-10-18 06:19:39 -0700
committerAdam Soltys <[email protected]>2026-10-18 06:19:39 -0700
commit7859a2fb3937f44727c9a3408d407da926b4f724 (patch)
tree2f54e0c4aa991187ca91642b06e1752a5944540b /tools/profile-pager-test.js
parent78fbd1fb0be6c7029409c8ab5cb020009853c4c5 (diff)
downloadcoinosv3-7859a2fb3937f44727c9a3408d407da926b4f724.tar.gz
coinosv3-7859a2fb3937f44727c9a3408d407da926b4f724.zip
The media pager no longer goes round from its last post to its first (or first to last): a step, a flick or the wheel at an end stays there.
Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013ZDf1cyCQLkfjftYhymZAg
Diffstat (limited to 'tools/profile-pager-test.js')
-rw-r--r--tools/profile-pager-test.js15
1 files changed, 6 insertions, 9 deletions
diff --git a/tools/profile-pager-test.js b/tools/profile-pager-test.js
index aac681a..2a78598 100644
--- a/tools/profile-pager-test.js
+++ b/tools/profile-pager-test.js
@@ -105,18 +105,15 @@ try {
await page.keyboard.press('ArrowDown');
check('down again: her last', await resting('d.png'), await curPic());
await page.keyboard.press('ArrowDown'); await sleep(600);
- check('past her last wraps to her first post', await resting('a2.png'), await curPic());
- check('counter counts the first post once', await page.$eval('.mp-position', (e) => e.textContent) === '1 / 3');
+ check('past her last it stays on her last (no going round)', await resting('d.png'), await curPic());
+ check('counter still at the last post', await page.$eval('.mp-position', (e) => e.textContent) === '3 / 3');
check('no loading slide', await page.$('.mp-tail') === null);
- await page.keyboard.press('ArrowUp'); await resting('d.png');
- check('up from first wraps to last', await curPic() === 'd.png');
- check('counter at the last post', await page.$eval('.mp-position', (e) => e.textContent) === '3 / 3');
await page.touchscreen.touchStart(195, 650);
for (let i = 1; i <= 8; i++) { await page.touchscreen.touchMove(195, 650 - 40 * i); await sleep(16); }
- await page.touchscreen.touchEnd();
- check('touch swipe wraps to first post', await resting('a2.png'), await curPic());
- await page.evaluate(() => document.querySelector('.media-pager').dispatchEvent(new WheelEvent('wheel', { deltaY: -3, deltaMode: 1, bubbles: true, cancelable: true })));
- check('wheel wraps back to last post', await resting('d.png'), await curPic());
+ await page.touchscreen.touchEnd(); await sleep(600);
+ check('a touch swipe on from her last stays there', await resting('d.png'), await curPic());
+ await page.evaluate(() => document.querySelector('.media-pager').dispatchEvent(new WheelEvent('wheel', { deltaY: 3, deltaMode: 1, bubbles: true, cancelable: true }))); await sleep(600);
+ check('…and so does the wheel', await resting('d.png'), await curPic());
await page.keyboard.press('ArrowUp');
check('up: her post before', await resting('b.png'), await curPic());
await page.keyboard.press('Escape');