a40a6e2e1c
The floating bar keeps the title at its own width (up to half the bar) and moves overflowable actions into one More menu instead of squeezing them below their touch targets. List rows keep their leading status avatar and More actions at any list-pane width; the time moves under the subtitle.
19 lines
584 B
Dart
19 lines
584 B
Dart
import 'package:flutter_test/flutter_test.dart';
|
|
import 'package:pipelines_app/ui/adaptive/segmented_bar.dart';
|
|
|
|
/// Taps a top-bar action: in the bar while it fits, or through the bar's
|
|
/// More menu (by its [label]) when a narrow bar moved it there.
|
|
Future<void> tapBarAction(
|
|
WidgetTester tester,
|
|
Finder action,
|
|
String label,
|
|
) async {
|
|
if (action.hitTestable().evaluate().isNotEmpty) {
|
|
await tester.tap(action);
|
|
return;
|
|
}
|
|
await tester.tap(find.byKey(segmentedMoreKey).hitTestable());
|
|
await tester.pumpAndSettle();
|
|
await tester.tap(find.text(label).last);
|
|
}
|