feat(app): glass viewer bars, graph controls and immersive image viewer

Review findings F12, F13, F25 and F1 for viewers: the artifact viewer's
actions/pager and the Changes pager float as glass pills over content,
file facts move to the top bar, graph overlay controls are one glass pill
(duplicate fullscreen glyph removed), the image viewer is immersive, and
diff/artifact/graph views let content pass behind the bar. Implemented by
pipeline run #204 (Terra); its Review stopped after three rejections, the
last being an empty glass bar for a single unresolved artifact, which the
manager fixed here with a regression test.
This commit is contained in:
2026-10-31 04:26:22 +00:00
parent 6ab8551348
commit fde086cc4a
13 changed files with 301 additions and 199 deletions
@@ -1,6 +1,5 @@
import 'dart:async';
import 'dart:convert';
import 'dart:typed_data';
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
@@ -16,6 +15,7 @@ import 'package:pipelines_app/features/artifacts/ui/artifact_gallery_page.dart';
import 'package:pipelines_app/features/artifacts/ui/artifact_viewer_fetch.dart';
import 'package:pipelines_app/features/artifacts/ui/artifact_viewer_page.dart';
import 'package:pipelines_app/features/artifacts/ui/artifact_visit_list.dart';
import 'package:pipelines_app/ui/adaptive/glass_pill.dart';
import 'package:pipelines_app/features/chat/ui/transcript/chat_markdown_view.dart';
import '../domain/artifact_fixtures.dart';
@@ -179,6 +179,26 @@ void main() {
expect(find.byType(AlertDialog), findsNothing);
});
testWidgets('a single unresolvable artifact shows no empty glass bar', (
tester,
) async {
final odd = recordedArtifact(
'notes.txt',
url: 'ftp://example.invalid/notes.txt',
contentType: 'text/plain',
);
await _pumpViewer(
tester,
groups: [
_group([odd]),
],
selected: artifactVisitIdentity(_group([odd]), odd),
);
expect(find.byKey(const Key('artifact-viewer-actions')), findsNothing);
expect(find.byKey(const Key('artifact-viewer-swipe')), findsOneWidget);
});
testWidgets('text/plain is fetched and shown as selectable text', (
tester,
) async {
@@ -199,6 +219,13 @@ void main() {
expect(find.byType(SelectableText), findsOneWidget);
expect(find.text('build ok\n'), findsOneWidget);
expect(
find.ancestor(
of: find.byKey(const Key('artifact-viewer-actions')),
matching: find.byType(GlassPill),
),
findsOneWidget,
);
await showFacts(tester);
expect(find.text('text/plain · 0\u00a0B'), findsOneWidget);
});
@@ -374,6 +401,7 @@ void main() {
);
expect(find.text('1 of 3 · image/png'), findsOneWidget);
expect(find.byKey(const Key('artifact-info')), findsOneWidget);
expect(
tester.widget<IconButton>(find.byKey(artifactPreviousKey)).onPressed,
isNull,