feat(learn): a learning path's Scroll view, chosen in the study settings

A path shows either one step at a time (Steps) or on one page (Scroll,
as Tomorrow University's): the steps one below the other up to the first
question not answered right, answered in place with a lock below it, the
page running on once it is right, Finish at its end. A text step is done
once its end was on screen. The outline of the steps (done ticked, the
one in view marked, those beyond the question locked, a tap scrolling
there) is a column from expanded windows on, a drawer from the bar below.

The choice is the person's study option (`StudyOptions.pathView`,
settings schema 15), in Settings › Study and the session settings.

Whats-New: Learning paths can show on one scrolling page with an outline beside them: choose Scroll under Settings › Study.
Whats-New-De: Lernpfade lassen sich auf einer scrollbaren Seite mit Gliederung daneben zeigen: unter Einstellungen › Lernen „Scrollen“ wählen.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
This commit is contained in:
Tizian 「ティツィアーン」 2026-11-10 20:55:19 +01:00
commit 690f69fa55
Signed by: raisondetredev
GPG key ID: 07F6FCF405488B64

View file

@ -11,6 +11,7 @@ import 'package:halkyon_learn_flutter/src/core/router/route_paths.dart';
import 'package:halkyon_learn_flutter/src/core/version/app_version.dart';
import 'package:halkyon_learn_flutter/src/feature/dictionary/model/device_dictionary.dart';
import 'package:halkyon_learn_flutter/src/feature/settings/data/settings_repository.dart';
import 'package:halkyon_learn_flutter/src/feature/study/model/study_options.dart';
import 'package:halkyon_ui/halkyon_ui.dart';
import 'package:material_ui/material_ui.dart';
@ -472,6 +473,35 @@ void main() {
);
});
testWidgets('the Study card chooses how learning paths show, Steps or '
'Scroll, on every device of theirs (decided 10 Nov 2026)', (
tester,
) async {
final settings = FakeSettingsGateway();
tester.view.physicalSize = const Size(900, 2400);
tester.view.devicePixelRatio = 1;
addTearDown(tester.view.reset);
await pumpApp(
tester,
testDependencies(settingsGateway: settings),
location: RoutePaths.settings,
);
expect(find.text('Learning paths'), findsOneWidget);
SegmentedButton<PathView> views() => tester.widget(
find.byType(SegmentedButton<PathView>),
);
expect(views().selected, {PathView.steps});
await tester.tap(find.text('Scroll'));
await tester.pumpAndSettle();
expect(views().selected, {PathView.scroll});
expect(
(await SettingsRepository(settings).read()).study.pathView,
PathView.scroll,
);
});
group('This instance (ADR 0021, D34)', () {
FakeInstanceOperatorGateway operatorGateway({required bool operates}) =>
FakeInstanceOperatorGateway()