File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -348,6 +348,7 @@ class _ImageLightboxPageState extends State<_ImageLightboxPage> {
348
348
buildBottomAppBar: _buildBottomAppBar,
349
349
child: SizedBox .expand (
350
350
child: InteractiveViewer (
351
+ maxScale: 10 , // TODO adjust based on device and image size; see #1091
351
352
child: SafeArea (
352
353
child: LightboxHero (
353
354
messageImageContext: widget.messageImageContext,
Original file line number Diff line number Diff line change @@ -366,6 +366,16 @@ void main() {
366
366
debugNetworkImageHttpClientProvider = null ;
367
367
});
368
368
369
+ testWidgets ('image can zoom up to 10x' , (tester) async {
370
+ prepareBoringImageHttpClient ();
371
+ await setupPage (tester, thumbnailUrl: null );
372
+
373
+ check (tester.widget <InteractiveViewer >(find.byType (InteractiveViewer )).maxScale)
374
+ .equals (10 );
375
+
376
+ debugNetworkImageHttpClientProvider = null ;
377
+ });
378
+
369
379
void checkAppBarNameAndDate (WidgetTester tester, String expectedName, String expectedDate) {
370
380
final labelTextWidget = tester.widget <RichText >(
371
381
find.descendant (of: find.byType (AppBar ).last,
You can’t perform that action at this time.
0 commit comments