From e363a902953960e7adb6cea1f44962fb8faf61a7 Mon Sep 17 00:00:00 2001 From: Alan Silva Date: Sun, 8 Nov 2026 01:05:07 +0000 Subject: [PATCH] Integrate scoped Settings restoration and preserve detail on Back --- app/lib/application/pipelines_app.dart | 5 ++++- .../chat/workspace/chat_workspace_divider.dart | 1 + app/notes/chat-pane-divider-grips.md | 7 +++++++ app/test/application/tab_location_navigation_test.dart | 10 ++++++++++ 4 files changed, 22 insertions(+), 1 deletion(-) diff --git a/app/lib/application/pipelines_app.dart b/app/lib/application/pipelines_app.dart index cbda6a00..8a278a50 100644 --- a/app/lib/application/pipelines_app.dart +++ b/app/lib/application/pipelines_app.dart @@ -664,7 +664,9 @@ class _PipelinesAppState extends State cupertino: _cupertino, destination: _destinationOf(route.kind), onDestinationSelected: _selectDestination, - onClosePage: () => _delegate.goTo(AppRoute.pipelines), + onClosePage: () => _delegate.goTo( + _bodyRoutes[AppDestination.pipelines] ?? AppRoute.pipelines, + ), destinationBodies: { AppDestination.pipelines: (_) => PipelinesDestination( session: _session, @@ -745,6 +747,7 @@ class _PipelinesAppState extends State // Settings is a page of the Pipelines tab (its bar's gear), not a // tab; the shell shows it with Back to Pipelines. AppDestination.settings: (_) => SettingsScreen( + navigationScope: _navigationScope, client: _session.client, // A phone signs in at the web login; a browser has its own. showSignIn: !kIsWeb, diff --git a/app/lib/features/chat/workspace/chat_workspace_divider.dart b/app/lib/features/chat/workspace/chat_workspace_divider.dart index 451c274b..191f7f12 100644 --- a/app/lib/features/chat/workspace/chat_workspace_divider.dart +++ b/app/lib/features/chat/workspace/chat_workspace_divider.dart @@ -95,6 +95,7 @@ class _ChatWorkspaceDividerState extends State { onPanEnd: (_) => setState(() => _drag = null), onPanCancel: () => setState(() => _drag = null), child: Tooltip( + excludeFromSemantics: true, message: 'Drag to resize chat panes', child: Stack( fit: StackFit.expand, diff --git a/app/notes/chat-pane-divider-grips.md b/app/notes/chat-pane-divider-grips.md index 3efd3f40..ad4974c5 100644 --- a/app/notes/chat-pane-divider-grips.md +++ b/app/notes/chat-pane-divider-grips.md @@ -6,3 +6,10 @@ existing 12-pixel divider; split geometry and resize limits are unchanged. Hover/focus/drag highlights the grip. Existing mouse/touch/keyboard resizing and double-click reset remain on the same hit target. Mobile keeps its existing grip size and appearance through the shared widget. + +Sixteen focused workspace/mobile-pane tests pass (`/tmp/memwatch/out.0QqRuP`), +analysis clean. Full-app browser captures at 1280x1000 show side-by-side and +stacked separators in Material and Cupertino; both grips and native theme +colors were inspected. Cupertino dragging changed both split extents using +the grips. Evidence: `/tmp/review/pane-divider-grips` and +`/tmp/review/pane-divider-grips-cupertino`. Native device verification is absent. diff --git a/app/test/application/tab_location_navigation_test.dart b/app/test/application/tab_location_navigation_test.dart index 8cb7cb77..71ce2b33 100644 --- a/app/test/application/tab_location_navigation_test.dart +++ b/app/test/application/tab_location_navigation_test.dart @@ -197,6 +197,16 @@ void main() { await tab(tester, 'pipelines'); expect(app.provider.value.uri.path, '/settings'); expect(tester.widget(hidden).initialPipelineId, 1); + await tester.tap(find.byKey(const Key('shell.back'))); + await tester.pumpAndSettle(); + expect(app.provider.value.uri.path, '/pipelines/1'); + expect(tester.state(find.byType(PipelinesScreen)), same(pipelineState)); + expect( + tester + .widget(find.byType(PipelinesScreen)) + .initialPipelineId, + 1, + ); expect(tester.takeException(), isNull); }); }