From 5cfef24f771860a72ee179042e663c7d2f8b9516 Mon Sep 17 00:00:00 2001 From: Fabian Freund Date: Fri, 6 Feb 2026 13:00:52 +0100 Subject: [PATCH] fix formatting --- app/lib/core/providers/router.g.dart | 2 +- app/lib/core/routing/routes.feeds.dart | 4 +- .../routing/widgets/bottom_sheet_page.dart | 28 ++++----- .../domain/services/browser_addon.dart | 6 +- .../presentation/select_feed_dialog.dart | 5 +- lib/src/pigeons/speech_to_text.g.dart | 58 +++++++++++++------ 6 files changed, 65 insertions(+), 38 deletions(-) diff --git a/app/lib/core/providers/router.g.dart b/app/lib/core/providers/router.g.dart index 009adf96..c83954df 100644 --- a/app/lib/core/providers/router.g.dart +++ b/app/lib/core/providers/router.g.dart @@ -75,7 +75,7 @@ final class CurrentTopRouteProvider } } -String _$currentTopRouteHash() => r'71a66713adafb5f64359eec88a69344167aae64f'; +String _$currentTopRouteHash() => r'1d71db42203483c7d919f44879e673f2f36d2e6a'; abstract class _$CurrentTopRoute extends $Notifier { RouteBase? build(); diff --git a/app/lib/core/routing/routes.feeds.dart b/app/lib/core/routing/routes.feeds.dart index 58d164b4..3d62b3f0 100644 --- a/app/lib/core/routing/routes.feeds.dart +++ b/app/lib/core/routing/routes.feeds.dart @@ -74,7 +74,9 @@ class SelectFeedDialogRoute extends GoRouteData with $SelectFeedDialogRoute { ), ); - return BottomSheetPage(builder: (_) => SelectFeedDialog(feedUris: feedUris)); + return BottomSheetPage( + builder: (_) => SelectFeedDialog(feedUris: feedUris), + ); } } diff --git a/app/lib/core/routing/widgets/bottom_sheet_page.dart b/app/lib/core/routing/widgets/bottom_sheet_page.dart index 6d67fbb2..bbbdc8bd 100644 --- a/app/lib/core/routing/widgets/bottom_sheet_page.dart +++ b/app/lib/core/routing/widgets/bottom_sheet_page.dart @@ -44,18 +44,18 @@ class BottomSheetPage extends Page { @override Route createRoute(BuildContext context) => ModalBottomSheetRoute( - settings: this, - builder: builder, - barrierLabel: barrierLabel ?? - MaterialLocalizations.of(context).modalBarrierDismissLabel, - backgroundColor: - Theme.of(context).bottomSheetTheme.modalBackgroundColor, - elevation: Theme.of(context).bottomSheetTheme.modalElevation, - shape: Theme.of(context).bottomSheetTheme.shape, - clipBehavior: Clip.antiAlias, - constraints: Theme.of(context).bottomSheetTheme.constraints, - isScrollControlled: isScrollControlled, - isDismissible: barrierDismissible, - useSafeArea: useSafeArea, - ); + settings: this, + builder: builder, + barrierLabel: + barrierLabel ?? + MaterialLocalizations.of(context).modalBarrierDismissLabel, + backgroundColor: Theme.of(context).bottomSheetTheme.modalBackgroundColor, + elevation: Theme.of(context).bottomSheetTheme.modalElevation, + shape: Theme.of(context).bottomSheetTheme.shape, + clipBehavior: Clip.antiAlias, + constraints: Theme.of(context).bottomSheetTheme.constraints, + isScrollControlled: isScrollControlled, + isDismissible: barrierDismissible, + useSafeArea: useSafeArea, + ); } diff --git a/app/lib/features/geckoview/features/browser/domain/services/browser_addon.dart b/app/lib/features/geckoview/features/browser/domain/services/browser_addon.dart index c044f3c4..6a1b7adf 100644 --- a/app/lib/features/geckoview/features/browser/domain/services/browser_addon.dart +++ b/app/lib/features/geckoview/features/browser/domain/services/browser_addon.dart @@ -106,7 +106,11 @@ class BrowserAddonService extends _$BrowserAddonService { } } } catch (e, s) { - logger.e('Failed installing from file: $filePath', error: e, stackTrace: s); + logger.e( + 'Failed installing from file: $filePath', + error: e, + stackTrace: s, + ); rethrow; } } diff --git a/app/lib/features/web_feed/presentation/select_feed_dialog.dart b/app/lib/features/web_feed/presentation/select_feed_dialog.dart index b46c0c53..5f69d334 100644 --- a/app/lib/features/web_feed/presentation/select_feed_dialog.dart +++ b/app/lib/features/web_feed/presentation/select_feed_dialog.dart @@ -40,10 +40,7 @@ class SelectFeedDialog extends HookConsumerWidget { mainAxisSize: MainAxisSize.min, crossAxisAlignment: CrossAxisAlignment.stretch, children: [ - Text( - 'Add Feed', - style: Theme.of(context).textTheme.titleLarge, - ), + Text('Add Feed', style: Theme.of(context).textTheme.titleLarge), const SizedBox(height: 16), ...feedUris.map( (uri) => HookConsumer( diff --git a/lib/src/pigeons/speech_to_text.g.dart b/lib/src/pigeons/speech_to_text.g.dart index 124a8aee..9bfa7d93 100644 --- a/lib/src/pigeons/speech_to_text.g.dart +++ b/lib/src/pigeons/speech_to_text.g.dart @@ -15,7 +15,11 @@ PlatformException _createConnectionError(String channelName) { ); } -List wrapResponse({Object? result, PlatformException? error, bool empty = false}) { +List wrapResponse({ + Object? result, + PlatformException? error, + bool empty = false, +}) { if (empty) { return []; } @@ -25,7 +29,6 @@ List wrapResponse({Object? result, PlatformException? error, bool empty return [error.code, error.message, error.details]; } - class _PigeonCodec extends StandardMessageCodec { const _PigeonCodec(); @override @@ -52,9 +55,13 @@ class SpeechToTextApi { /// Constructor for [SpeechToTextApi]. The [binaryMessenger] named argument is /// available for dependency injection. If it is left null, the default /// BinaryMessenger will be used which routes to the host platform. - SpeechToTextApi({BinaryMessenger? binaryMessenger, String messageChannelSuffix = ''}) - : pigeonVar_binaryMessenger = binaryMessenger, - pigeonVar_messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + SpeechToTextApi({ + BinaryMessenger? binaryMessenger, + String messageChannelSuffix = '', + }) : pigeonVar_binaryMessenger = binaryMessenger, + pigeonVar_messageChannelSuffix = messageChannelSuffix.isNotEmpty + ? '.$messageChannelSuffix' + : ''; final BinaryMessenger? pigeonVar_binaryMessenger; static const MessageCodec pigeonChannelCodec = _PigeonCodec(); @@ -69,13 +76,16 @@ class SpeechToTextApi { /// The [locale] parameter specifies the language locale for recognition /// (e.g., 'en-US', 'de-DE'). If null, uses the device default. Future showDialog({String? locale}) async { - final pigeonVar_channelName = 'dev.flutter.pigeon.speech_to_text_dialog.SpeechToTextApi.showDialog$pigeonVar_messageChannelSuffix'; + final pigeonVar_channelName = + 'dev.flutter.pigeon.speech_to_text_dialog.SpeechToTextApi.showDialog$pigeonVar_messageChannelSuffix'; final pigeonVar_channel = BasicMessageChannel( pigeonVar_channelName, pigeonChannelCodec, binaryMessenger: pigeonVar_binaryMessenger, ); - final Future pigeonVar_sendFuture = pigeonVar_channel.send([locale]); + final Future pigeonVar_sendFuture = pigeonVar_channel.send( + [locale], + ); final pigeonVar_replyList = await pigeonVar_sendFuture as List?; if (pigeonVar_replyList == null) { throw _createConnectionError(pigeonVar_channelName); @@ -106,29 +116,43 @@ abstract class SpeechToTextEvents { /// recognition failed or was cancelled. void onTextReceived(String text); - static void setUp(SpeechToTextEvents? api, {BinaryMessenger? binaryMessenger, String messageChannelSuffix = '',}) { - messageChannelSuffix = messageChannelSuffix.isNotEmpty ? '.$messageChannelSuffix' : ''; + static void setUp( + SpeechToTextEvents? api, { + BinaryMessenger? binaryMessenger, + String messageChannelSuffix = '', + }) { + messageChannelSuffix = messageChannelSuffix.isNotEmpty + ? '.$messageChannelSuffix' + : ''; { final pigeonVar_channel = BasicMessageChannel( - 'dev.flutter.pigeon.speech_to_text_dialog.SpeechToTextEvents.onTextReceived$messageChannelSuffix', pigeonChannelCodec, - binaryMessenger: binaryMessenger); + 'dev.flutter.pigeon.speech_to_text_dialog.SpeechToTextEvents.onTextReceived$messageChannelSuffix', + pigeonChannelCodec, + binaryMessenger: binaryMessenger, + ); if (api == null) { pigeonVar_channel.setMessageHandler(null); } else { pigeonVar_channel.setMessageHandler((Object? message) async { - assert(message != null, - 'Argument for dev.flutter.pigeon.speech_to_text_dialog.SpeechToTextEvents.onTextReceived was null.'); + assert( + message != null, + 'Argument for dev.flutter.pigeon.speech_to_text_dialog.SpeechToTextEvents.onTextReceived was null.', + ); final List args = (message as List?)!; final String? arg_text = (args[0] as String?); - assert(arg_text != null, - 'Argument for dev.flutter.pigeon.speech_to_text_dialog.SpeechToTextEvents.onTextReceived was null, expected non-null String.'); + assert( + arg_text != null, + 'Argument for dev.flutter.pigeon.speech_to_text_dialog.SpeechToTextEvents.onTextReceived was null, expected non-null String.', + ); try { api.onTextReceived(arg_text!); return wrapResponse(empty: true); } on PlatformException catch (e) { return wrapResponse(error: e); - } catch (e) { - return wrapResponse(error: PlatformException(code: 'error', message: e.toString())); + } catch (e) { + return wrapResponse( + error: PlatformException(code: 'error', message: e.toString()), + ); } }); }