diff --git a/lib/screen/scan_qr/scan_qr_page.dart b/lib/screen/scan_qr/scan_qr_page.dart index 85f6cc023..03473cbea 100644 --- a/lib/screen/scan_qr/scan_qr_page.dart +++ b/lib/screen/scan_qr/scan_qr_page.dart @@ -273,7 +273,8 @@ enum ScannerItem { BEACON_CONNECT, ETH_ADDRESS, XTZ_ADDRESS, - GLOBAL + GLOBAL, + CANVAS, } class QRScanView extends StatefulWidget { @@ -615,7 +616,23 @@ class QRScanViewState extends State ), ), ); - + case ScannerItem.CANVAS: + return RichText( + text: TextSpan( + text: 'display_with_ff'.tr(), + children: [ + TextSpan( + text: ' ', + style: theme.textTheme.ppMori400Grey14, + ), + TextSpan( + text: 'on_tv_or_desktop'.tr(), + style: theme.textTheme.ppMori400Grey14, + ), + ], + style: theme.textTheme.ppMori400White14, + ), + ); case ScannerItem.ETH_ADDRESS: case ScannerItem.XTZ_ADDRESS: return Column( @@ -669,6 +686,9 @@ class QRScanViewState extends State return; } else { switch (widget.scannerItem) { + case ScannerItem.CANVAS: + + /// handled with deeplink case ScannerItem.WALLET_CONNECT: if (code.startsWith('wc:')) { await _handleAutonomyConnect(code); diff --git a/lib/view/stream_device_view.dart b/lib/view/stream_device_view.dart index 1efc04ac4..f191b8b01 100644 --- a/lib/view/stream_device_view.dart +++ b/lib/view/stream_device_view.dart @@ -125,7 +125,7 @@ class _StreamDeviceViewState extends State { ), recognizer: TapGestureRecognizer() ..onTap = () async { - await scanToAddMore(context); + await _scanToAddMore(context); }, ), TextSpan( @@ -174,9 +174,9 @@ class _StreamDeviceViewState extends State { ); } - Future scanToAddMore(BuildContext context) async { + Future _scanToAddMore(BuildContext context) async { final device = await Navigator.of(context) - .pushNamed(AppRouter.scanQRPage, arguments: ScannerItem.GLOBAL); + .pushNamed(AppRouter.scanQRPage, arguments: ScannerItem.CANVAS); log.info('device selected: $device'); _canvasDeviceBloc.add(CanvasDeviceGetDevicesEvent()); }