aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/features/messages.js4
-rw-r--r--tools/avatar-profile-test.js8
2 files changed, 11 insertions, 1 deletions
diff --git a/src/features/messages.js b/src/features/messages.js
index c6a99b5..452377e 100644
--- a/src/features/messages.js
+++ b/src/features/messages.js
@@ -7680,7 +7680,9 @@ export function messagesFeature(ctx) {
...items.map((f) => h('button', {
class: 'feed-chip' + (f.id === curFeedId ? ' on' : ''), type: 'button', 'data-key': 'chip:' + f.id,
onClick: () => switchFeed(f.id),
- }, f.name)),
+ // someone's timeline carries the person, not a name — an empty
+ // label left a blank black pill
+ }, f.of ? t('feedOfTitle', { name: displayName(f.of) }) : f.name || feedSummary(f))),
h('button', { class: 'feed-chip add', type: 'button', title: t('feedNew'), 'aria-label': t('feedNew'), onClick: () => openFeedEditor(null) }, '+'));
}
// The sheets a post (or a person) can open: the ⋯ menu, the reaction
diff --git a/tools/avatar-profile-test.js b/tools/avatar-profile-test.js
index c91ad26..0f59e10 100644
--- a/tools/avatar-profile-test.js
+++ b/tools/avatar-profile-test.js
@@ -68,6 +68,14 @@ try {
back = await page.evaluate(() => ({ y: window.scrollY, feed: !!document.querySelector('.notes-feed') }));
}
check('back returns to the feed where the reader was', back.feed && Math.abs(back.y - feedY) < 60, 'scrollY ' + back.y + ' vs ' + feedY);
+
+ // "Their timeline" from the profile: its chip names it (it was a blank pill)
+ await page.evaluate(() => { const r = [...document.querySelectorAll('.notes-feed .note-avatar')].find((n) => n.closest('[data-key]')?.innerText.includes('Bob Poster')); r.click(); });
+ await sleep(1000);
+ await click('their timeline');
+ await sleep(1500);
+ const chip = await page.evaluate(() => document.querySelector('.feed-chip.on')?.textContent || null);
+ check('someone’s timeline has a labelled chip', !!chip && /Bob Poster/.test(chip), JSON.stringify(chip));
} finally { await browser.close(); server.stop(true); }
console.log(ok ? '\n✅ a face opens its profile at the top' : '\n❌ failed');
process.exit(ok ? 0 : 1);