Fix the 11 failing application tests: two product fixes, stale fixtures
Product: - Settings jump index scrolls instead of overflowing a short wide window (overflowed by 48 px at 1200x800 once Open in chat added a section). - Chat: a route to the retained workspace's active pane shows it in the same frame again;ec3c1e4cdeferred it a frame behind a post-frame callback. Tests updated to intended behaviour: - first-run walkthrough (30ba70ad): seed a device that has seen it and was offered it for the fixture server; - Output section open by default (22af093e); - chat page Back closes its own route explicitly (19b1d132); - open-chat sync (c48a1559): answer chat_open_workspace statefully; - keyed session list (0a51add9) no longer re-reads chat_sessions on open. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -407,7 +407,17 @@ class _ChatScreenState extends State<ChatScreen>
|
||||
id != null &&
|
||||
id.isNotEmpty &&
|
||||
(_workspace.activePane?.sessionId != id || !_workspaceVisible);
|
||||
if (!reboundWorkspace && (routeChanged || targetIsNotActive)) {
|
||||
if (!reboundWorkspace &&
|
||||
targetIsNotActive &&
|
||||
_workspace.activePane?.sessionId == id) {
|
||||
// The routed chat is already the retained workspace's active pane (a
|
||||
// Chats re-tap, or Back then forward): only its visibility changes, which
|
||||
// notifies nothing, so it is shown in this frame and its entrance starts
|
||||
// with the tap rather than a frame later.
|
||||
_workspaceVisible = true;
|
||||
_publishedWorkspaceSession = id;
|
||||
_workspaceBinding?.changed();
|
||||
} else if (!reboundWorkspace && (routeChanged || targetIsNotActive)) {
|
||||
// The parent is rebuilding while didUpdateWidget runs. Opening a pane
|
||||
// notifies the workspace's ListenableBuilder, which must happen after
|
||||
// this build rather than during it.
|
||||
|
||||
@@ -41,7 +41,9 @@ class SettingsSearchField extends StatelessWidget {
|
||||
);
|
||||
}
|
||||
|
||||
/// The wide layout's slim jump index: one link per visible section.
|
||||
/// The wide layout's slim jump index: one link per visible section. It
|
||||
/// scrolls on its own when a short window cannot fit every link, so the last
|
||||
/// sections stay reachable instead of overflowing the page.
|
||||
class SettingsSectionIndex extends StatelessWidget {
|
||||
const SettingsSectionIndex({
|
||||
super.key,
|
||||
@@ -56,24 +58,28 @@ class SettingsSectionIndex extends StatelessWidget {
|
||||
Widget build(BuildContext context) => Semantics(
|
||||
container: true,
|
||||
label: 'Settings sections',
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.stretch,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: <Widget>[
|
||||
for (final section in sections)
|
||||
TextButton(
|
||||
key: ValueKey<String>('settings.index.${section.id}'),
|
||||
onPressed: () => onJump(section.id),
|
||||
style: TextButton.styleFrom(
|
||||
alignment: AlignmentDirectional.centerStart,
|
||||
child: SingleChildScrollView(
|
||||
// The page's own list owns the primary controller.
|
||||
primary: false,
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.stretch,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: <Widget>[
|
||||
for (final section in sections)
|
||||
TextButton(
|
||||
key: ValueKey<String>('settings.index.${section.id}'),
|
||||
onPressed: () => onJump(section.id),
|
||||
style: TextButton.styleFrom(
|
||||
alignment: AlignmentDirectional.centerStart,
|
||||
),
|
||||
child: Text(
|
||||
section.title,
|
||||
textAlign: TextAlign.start,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
),
|
||||
child: Text(
|
||||
section.title,
|
||||
textAlign: TextAlign.start,
|
||||
overflow: TextOverflow.ellipsis,
|
||||
),
|
||||
),
|
||||
],
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user