feat(app): keep the tabs beside notes and paths, flat app bars, the sync dot on the cogs alone

A studyset's notes and learning paths are routes of the Library tab, as
its screen is, so the navigation stays beside them; studying, cards, PDFs
and settings still take the whole window. App bars stay flat when content
scrolls under them: Material 3's tint flickers as an overscroll crosses
the edge again and again. The sync trouble dot shows on the Settings cogs
only; Home has a cog of its own now, so the Profile tab needn't carry it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
Tizian 「ティツィアーン」 2026-10-08 10:41:49 +02:00
commit 770de51bff
Signed by: raisondetredev
GPG key ID: 07F6FCF405488B64

View file

@ -72,6 +72,51 @@ GoRouter buildRouter({String initialLocation = RoutePaths.home}) => GoRouter(
),
],
),
// A studyset's notes and paths keep the tabs beside them, as
// its screen does: reading and writing them is part of being in
// the library. What needs the whole window (studying, a card,
// a PDF) stays over the tabs.
// A note, new or stored; the new one's route first, as for cards.
GoRoute(
path: '/studysets/:studysetId/notes/new',
builder: (context, state) =>
_noteEditor(context, state.pathParameters['studysetId']!),
),
GoRoute(
path: '/studysets/:studysetId/notes/:noteId',
builder: (context, state) => _noteEditor(
context,
state.pathParameters['studysetId']!,
noteId: state.pathParameters['noteId'],
),
),
// A learning path: worked through, written, and one of its steps
// written.
GoRoute(
path: '/studysets/:studysetId/paths/:pathId',
builder: (context, state) => _pathRunner(
context,
state.pathParameters['studysetId']!,
state.pathParameters['pathId']!,
),
),
GoRoute(
path: '/studysets/:studysetId/paths/:pathId/edit',
builder: (context, state) => _pathEditor(
context,
state.pathParameters['studysetId']!,
state.pathParameters['pathId']!,
),
),
GoRoute(
path: '/studysets/:studysetId/paths/:pathId/steps/:stepId',
builder: (context, state) => _stepEditor(
context,
state.pathParameters['studysetId']!,
state.pathParameters['pathId']!,
state.pathParameters['stepId']!,
),
),
],
),
StatefulShellBranch(
@ -137,47 +182,6 @@ GoRouter buildRouter({String initialLocation = RoutePaths.home}) => GoRouter(
cardId: state.pathParameters['cardId'],
),
),
// A note, new or stored; the new one's route first, as for cards.
GoRoute(
path: '/studysets/:studysetId/notes/new',
builder: (context, state) =>
_noteEditor(context, state.pathParameters['studysetId']!),
),
GoRoute(
path: '/studysets/:studysetId/notes/:noteId',
builder: (context, state) => _noteEditor(
context,
state.pathParameters['studysetId']!,
noteId: state.pathParameters['noteId'],
),
),
// A learning path: worked through, written, and one of its steps
// written.
GoRoute(
path: '/studysets/:studysetId/paths/:pathId',
builder: (context, state) => _pathRunner(
context,
state.pathParameters['studysetId']!,
state.pathParameters['pathId']!,
),
),
GoRoute(
path: '/studysets/:studysetId/paths/:pathId/edit',
builder: (context, state) => _pathEditor(
context,
state.pathParameters['studysetId']!,
state.pathParameters['pathId']!,
),
),
GoRoute(
path: '/studysets/:studysetId/paths/:pathId/steps/:stepId',
builder: (context, state) => _stepEditor(
context,
state.pathParameters['studysetId']!,
state.pathParameters['pathId']!,
state.pathParameters['stepId']!,
),
),
GoRoute(
path: RoutePaths.readingTimeline,
builder: (context, state) => const ReadingTimelineScreen(),