Server rail: the server with voice is shown on top
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -96,6 +96,8 @@
|
||||
</nav>
|
||||
|
||||
<style>
|
||||
/* The server you are talking on leads the list, wherever it sits in your own order */
|
||||
.tile.voice { order: -1; }
|
||||
.rail {
|
||||
width: 68px; flex: none; background: var(--bg-0); display: flex; flex-direction: column;
|
||||
align-items: center; gap: 8px; padding: 12px 0; overflow-y: auto;
|
||||
|
||||
@@ -881,6 +881,10 @@ try {
|
||||
await page.locator('.channel .name', { hasText: 'Root' }).dblclick();
|
||||
await until2('voice moved to the second server', () => !userState('alice-b')?.selfDeaf && !!userState('alice')?.selfDeaf);
|
||||
assert.equal(await page.locator('.rail .tile.voice').getAttribute('title').then(t => t?.startsWith('Second')), true);
|
||||
// The server with voice leads the rail, although it was added last
|
||||
const railTop = (title: string) => page.locator(`.rail .tile[title^="${title}"]`).boundingBox().then(b => b!.y);
|
||||
assert.ok(await railTop('Second') < await railTop('Test Server'), 'voice server on top');
|
||||
assert.match(await page.locator('.rail .tile').first().getAttribute('title') ?? '', /^Test Server/, 'the saved order is untouched');
|
||||
console.log('ok: voice follows the channel you join');
|
||||
|
||||
// Messages on the server not on screen show as unread on its tile
|
||||
|
||||
Reference in New Issue
Block a user