From 1b5c254ec50176f20dceef6f015d1a2731a4904e Mon Sep 17 00:00:00 2001 From: Adam Soltys Date: Sat, 17 Oct 2026 05:00:20 -0700 Subject: The "Tall only" / "Wide only" / "All shapes" toggle shows only in the video pager, not over the Videos grid. Over the grid it sat on its own line below the view chips, looking misplaced (Adam, 2026-10-17: "The tall only chip looks a bit misplaced here. Let's only show it in media mode"). The grid still follows the same setting, so a change in the pager shows up in the grid too. tools/pager-ready-gate-test.js: the grid shows four clips with no toggle over it; the pager's toggle checks are unchanged and pass. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_013ZDf1cyCQLkfjftYhymZAg --- src/features/messages.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/features') diff --git a/src/features/messages.js b/src/features/messages.js index 3789f93..017629f 100644 --- a/src/features/messages.js +++ b/src/features/messages.js @@ -12190,12 +12190,13 @@ export function messagesFeature(ctx) { // true/false, or null while the clip's shape isn't known const clipFits = (url) => { if (clipsAll()) return true; const sh = clipShape(url); return sh === null ? null : sh === 'square' || sh === (screenTall() ? 'tall' : 'wide'); }; const clipsLabel = () => t(clipsAll() ? 'clipsAll' : screenTall() ? 'clipsTall' : 'clipsWide'); - // the toggle: in the pager's top bar and over the Videos grid + // the toggle: in the pager's top bar only (over the grid it sat oddly + // apart from the chips); the grid follows the same setting function clipsToggle(cls, after) { return h('button', { class: cls, type: 'button', title: t('clipsToggleTitle'), onClick: (e) => { e.stopPropagation(); setClipsAll(!clipsAll()); - for (const b of document.querySelectorAll('.mp-fit, .media-fit-btn')) b.textContent = clipsLabel(); + for (const b of document.querySelectorAll('.mp-fit')) b.textContent = clipsLabel(); if (after) after(); if (mediaMode === 'videos') scheduleRepaint(); } }, clipsLabel()); @@ -12438,7 +12439,6 @@ export function messagesFeature(ctx) { if (missing.length) warmTileThumbs(missing).then(() => queueTileThumbs(missing.filter((u) => !tileThumbs.has(u)))); } return h('div', { class: 'media-grid', 'data-key': 'media-grid:' + mediaMode }, - mediaMode === 'videos' ? h('div', { class: 'media-fit', 'data-key': 'media-fit' }, clipsToggle('media-fit-btn')) : null, ...items.map((it) => { const k = mediaKey(it); // a video tile shows a still at once: kept, given, or the server's -- cgit v1.2.3