Call view: room for the tiles above the control bar; Watch stream opens the call (#612, #613) #627

Merged
charles merged 5 commits from fix/voice-view into textchat 2026-11-15 11:15:05 +00:00
Owner

Refs #612, #613

#612: the control bar covers the participants' tiles

Cause. The reporter's screenshot shows the focus layout: a stream is focused and the participants are shown in the mini grid under it. In the window, the stream kept the height rule of the layout without participants (min(76 % of the window, area − 3 rem), focus::main_size). So the mini grid started below the control bar's top edge, and its tiles (avatars, name plates) were cut off behind the bar unless the user scrolled (crates/fluxer-ui/src/screens/main/call/focus.rs, layout, non-fullscreen branch). The golden stream_focus.png showed it too.

Fix. With the participants shown, the original uses resolveFocusExpandedMainMetrics (VoiceFocusLayoutMetrics.ts, .focusExpandedScrollBody). The stream gives up the toggle's 44 px, 40 px of gaps and one row of the mini grid. It stays at least 180 px high and at most 95 rem wide. New focus::expanded_main_size does the same, and layout uses it whenever the mini grid is shown. Further rows scroll, as in the original. The layout without participants and the fullscreen layout are unchanged.

#428. I could not reproduce it on textchat. The plain grid (no focused stream) already packs its tiles into the height above the bar, and a single tile is centred there. The new test checks this at 1500×1240 and 1160×1303. #428 is not explained by the #612 rule, so it is left open.

#613: "Watch stream" from the hover card does not switch the view

Cause. stream_hover::update (Message::Watch, and the double click through Message::Pressed and the profile-backdrop press in main::update) only sent UserAction::WatchStream. The store watched the stream and joined or moved the connection, so its sound played, but nothing selected the stream's channel.

Fix. The new stream_hover::watch_actions(key) returns WatchStream, then SelectGuild(key.guild_id()) and SelectChannel(channel), as the original's openAndWatchStream → applyStreamWatchFocus → selectStreamChannel does. The call view's State::sync already pins a newly watched stream, so the call view opens on the focused stream. One difference from the original: it navigates right away instead of waiting for the voice connection, and the call view shows the connecting call in the meantime.

Tests

  • tests/stream_focus.rs::control_bar_leaves_room_for_the_tiles (new; fails without the fix, at the reporter-like 1861×700). Call view sizes 1861×700, 1280×720, 1000×640, 624×664 and 1500×1240, with 1, 2, 4 and 9 participants. In the grid, no tile's name plate reaches the bar's room. In the focus layout, the first mini-grid row's plates are above the bar. The test also covers the grid in short views (1280×400, 900×360) and the #428 single-tile centring.
  • tests/stream_focus.rs::fullscreen_moves_members_to_bottom_row: the windowed expectation is updated to the expanded rule, plus the 180 px floor and the unchanged rule without participants.
  • tests/stream_sidebar.rs::hover_card_watch_opens_the_call_view_on_the_stream (new; fails without the fix). The test hovers ada's row, clicks the card's Watch stream and runs main::update and call::State::sync. It then checks that the stream is watched, #Hangout is selected, and the call view focuses ada's stream, both when not in voice and when already in the call while viewing #general. double_click_watches now also asserts the navigation. The stream_hover unit test asserts the three actions.
  • Golden stream_focus.png regenerated (looked at first): the stream is smaller and the first row of tiles sits fully above the bar.
  • FLUXER_SCREENSHOT_TESTS=1 cargo xtask ci: all steps passed locally (Linux).

Not verified on Windows; the headless widget tests do not run on the Windows runner (#93).

🤖 Generated with Claude Code

Refs #612, #613 ## #612: the control bar covers the participants' tiles **Cause.** The reporter's screenshot shows the focus layout: a stream is focused and the participants are shown in the mini grid under it. In the window, the stream kept the height rule of the layout *without* participants (`min(76 % of the window, area − 3 rem)`, `focus::main_size`). So the mini grid started below the control bar's top edge, and its tiles (avatars, name plates) were cut off behind the bar unless the user scrolled (`crates/fluxer-ui/src/screens/main/call/focus.rs`, `layout`, non-fullscreen branch). The golden `stream_focus.png` showed it too. **Fix.** With the participants shown, the original uses `resolveFocusExpandedMainMetrics` (`VoiceFocusLayoutMetrics.ts`, `.focusExpandedScrollBody`). The stream gives up the toggle's 44 px, 40 px of gaps and one row of the mini grid. It stays at least 180 px high and at most 95 rem wide. New `focus::expanded_main_size` does the same, and `layout` uses it whenever the mini grid is shown. Further rows scroll, as in the original. The layout without participants and the fullscreen layout are unchanged. **#428.** I could not reproduce it on `textchat`. The plain grid (no focused stream) already packs its tiles into the height above the bar, and a single tile is centred there. The new test checks this at 1500×1240 and 1160×1303. #428 is not explained by the #612 rule, so it is left open. ## #613: "Watch stream" from the hover card does not switch the view **Cause.** `stream_hover::update` (`Message::Watch`, and the double click through `Message::Pressed` and the profile-backdrop press in `main::update`) only sent `UserAction::WatchStream`. The store watched the stream and joined or moved the connection, so its sound played, but nothing selected the stream's channel. **Fix.** The new `stream_hover::watch_actions(key)` returns `WatchStream`, then `SelectGuild(key.guild_id())` and `SelectChannel(channel)`, as the original's `openAndWatchStream` → `applyStreamWatchFocus` → `selectStreamChannel` does. The call view's `State::sync` already pins a newly watched stream, so the call view opens on the focused stream. One difference from the original: it navigates right away instead of waiting for the voice connection, and the call view shows the connecting call in the meantime. ## Tests - `tests/stream_focus.rs::control_bar_leaves_room_for_the_tiles` (new; fails without the fix, at the reporter-like 1861×700). Call view sizes 1861×700, 1280×720, 1000×640, 624×664 and 1500×1240, with 1, 2, 4 and 9 participants. In the grid, no tile's name plate reaches the bar's room. In the focus layout, the first mini-grid row's plates are above the bar. The test also covers the grid in short views (1280×400, 900×360) and the #428 single-tile centring. - `tests/stream_focus.rs::fullscreen_moves_members_to_bottom_row`: the windowed expectation is updated to the expanded rule, plus the 180 px floor and the unchanged rule without participants. - `tests/stream_sidebar.rs::hover_card_watch_opens_the_call_view_on_the_stream` (new; fails without the fix). The test hovers ada's row, clicks the card's Watch stream and runs `main::update` and `call::State::sync`. It then checks that the stream is watched, `#Hangout` is selected, and the call view focuses ada's stream, both when not in voice and when already in the call while viewing #general. `double_click_watches` now also asserts the navigation. The `stream_hover` unit test asserts the three actions. - Golden `stream_focus.png` regenerated (looked at first): the stream is smaller and the first row of tiles sits fully above the bar. - `FLUXER_SCREENSHOT_TESTS=1 cargo xtask ci`: all steps passed locally (Linux). Not verified on Windows; the headless widget tests do not run on the Windows runner (#93). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
The hover card's Watch stream and the double click on a streaming row only
told the store to watch: the stream's sound started but the view stayed on
the channel that was open. Like the original's openAndWatchStream /
applyStreamWatchFocus, they now also select the stream's guild and channel;
the call view's State::sync pins the newly watched stream.

Refs #613

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With a stream focused and the participants shown, the stream kept the
76 % / area − 3 rem height of the layout without participants, so the mini
grid under it started below the control bar: its tiles, avatars and names
were hidden behind the bar unless scrolled. The original's expanded focus
layout (resolveFocusExpandedMainMetrics) gives up the toggle, the gaps and
one row of the mini grid, keeping the stream at least 180 px high; the
window layout now does the same. The grid without a focused stream already
fits its tiles above the bar (tested, together with #428's centring).

Refs #612

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Refs #612, #613

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Author
Owner

Updated to textchat e932e06c (head now 052a1696).

  • Merge (00204001): the only conflict was fixtures/golden/stream_focus.png, which both sides had redrawn. The code merged cleanly. Since c8faabf4, textchat changed call/grid.rs (a single tile has no minimum size) and call/pip.rs (new menu-row fields), but not call/focus.rs, stream_hover.rs or this branch's main/mod.rs hunk. So focus::expanded_main_size, stream_hover::watch_actions (WatchStream → SelectGuild → SelectChannel) and task 36's voice badge/refusal UI are all as their authors left them.
  • Golden (052a1696): stream_focus.png redrawn on the reference renderer (lavapipe, fluxer-native-shots:u2204). With textchat's golden, the test differed by 17.3 %. The new frame differs from this branch's previous golden by 0.2 %, only around the member list (ada's "heads down" status line from textchat). It shows the smaller stream with the first row of tiles fully above the control bar. All 162 screenshot tests pass on lavapipe. No other golden changed.

Tests: stream_focus::control_bar_leaves_room_for_the_tiles, stream_sidebar::hover_card_watch_opens_the_call_view_on_the_stream and double_click_watches pass. FLUXER_SCREENSHOT_TESTS=1 cargo xtask ci: all steps passed (screenshots on the host GPU).

🤖 Generated with Claude Code

Updated to `textchat` e932e06c (head now 052a1696). - **Merge (00204001):** the only conflict was `fixtures/golden/stream_focus.png`, which both sides had redrawn. The code merged cleanly. Since c8faabf4, textchat changed `call/grid.rs` (a single tile has no minimum size) and `call/pip.rs` (new menu-row fields), but not `call/focus.rs`, `stream_hover.rs` or this branch's `main/mod.rs` hunk. So `focus::expanded_main_size`, `stream_hover::watch_actions` (WatchStream → SelectGuild → SelectChannel) and task 36's voice badge/refusal UI are all as their authors left them. - **Golden (052a1696):** `stream_focus.png` redrawn on the reference renderer (lavapipe, `fluxer-native-shots:u2204`). With textchat's golden, the test differed by 17.3 %. The new frame differs from this branch's previous golden by 0.2 %, only around the member list (ada's "heads down" status line from textchat). It shows the smaller stream with the first row of tiles fully above the control bar. All 162 screenshot tests pass on lavapipe. No other golden changed. Tests: `stream_focus::control_bar_leaves_room_for_the_tiles`, `stream_sidebar::hover_card_watch_opens_the_call_view_on_the_stream` and `double_click_watches` pass. `FLUXER_SCREENSHOT_TESTS=1 cargo xtask ci`: all steps passed (screenshots on the host GPU). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Only conflict: fixtures/golden/stream_focus.png (both sides redrew it);
textchat's copy is taken here and redrawn on lavapipe in the next commit.
The call-view and stream-hover code merged cleanly: textchat changed
call/grid.rs (one tile has no minimum) and call/pip.rs (menu row fields),
not focus.rs or stream_hover.rs.

Refs #612, #613

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Both sides had redrawn it: textchat for ada's custom status line in the
member list, this branch for the focused stream that leaves a row of tiles
above the control bar (#612). Drawn in the fluxer-native-shots:u2204 image
(Ubuntu 22.04 lavapipe); it shows both changes.

Refs #612

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
charles merged commit d4fd15a7f2 into textchat 2026-11-15 11:15:05 +00:00
Sign in to join this conversation.
No description provided.