From 41fd9b525ba20680d673cd3833d815ae53b94458 Mon Sep 17 00:00:00 2001 From: guyluz Date: Mon, 29 May 2023 23:36:44 +0300 Subject: [PATCH 1/3] Updated dependencies --- .../pick_repeat_time_page.dart | 14 ++-- lib/presentation/routes/app_router.dart | 4 +- pubspec.yaml | 72 +++++++++---------- .../flutter/generated_plugin_registrant.cc | 3 - windows/flutter/generated_plugins.cmake | 1 - 5 files changed, 44 insertions(+), 50 deletions(-) diff --git a/lib/presentation/add_new_automation_process/add_routine/pick_repeat_time/pick_repeat_time_page.dart b/lib/presentation/add_new_automation_process/add_routine/pick_repeat_time/pick_repeat_time_page.dart index 6050a2f71..8de216394 100644 --- a/lib/presentation/add_new_automation_process/add_routine/pick_repeat_time/pick_repeat_time_page.dart +++ b/lib/presentation/add_new_automation_process/add_routine/pick_repeat_time/pick_repeat_time_page.dart @@ -19,13 +19,13 @@ class PickRepeatTimePage extends StatelessWidget { @override Widget build(BuildContext context) { final List days = [ - DayInWeek("Sun"), - DayInWeek("Mon"), - DayInWeek("Tue", isSelected: true), - DayInWeek("Wed"), - DayInWeek("Thu"), - DayInWeek("Fri"), - DayInWeek("Sat"), + DayInWeek('Sun', dayKey: 'Sun'), + DayInWeek('Mon', dayKey: 'Mon'), + DayInWeek('Tue', dayKey: 'Tue', isSelected: true), + DayInWeek('Wed', dayKey: 'Wed'), + DayInWeek('Thu', dayKey: 'Thu'), + DayInWeek('Fri', dayKey: 'Fri'), + DayInWeek('Sat', dayKey: 'Sat'), ]; RoutineCbjRepeatDateDays? daysToRepeat; diff --git a/lib/presentation/routes/app_router.dart b/lib/presentation/routes/app_router.dart index c7c481478..e9521dd16 100644 --- a/lib/presentation/routes/app_router.dart +++ b/lib/presentation/routes/app_router.dart @@ -49,9 +49,7 @@ class AppRouter extends $AppRouter { AutoRoute(page: RoomsSmartTvsRoute.page), AutoRoute(page: RoomsPrintersRoute.page), AutoRoute(page: SwitchesInTheRoomRoute.page), - AutoRoute( - page: RoomsSmartPlugsRoute.page, - ), + AutoRoute(page: RoomsSmartPlugsRoute.page), AutoRoute(page: SmartPlugsInTheRoomRoute.page), AutoRoute(page: RoomsBlindsRoute.page), AutoRoute(page: RoomsBoilersRoute.page), diff --git a/pubspec.yaml b/pubspec.yaml index 2653be3ff..a5d56107a 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -36,19 +36,19 @@ dependencies: # Collection of some cool and awesome text animations. animated_text_kit: ^4.2.2 # More customization when notifying your user. - another_flushbar: ^1.12.29 + another_flushbar: ^1.12.30 # Utility classes to work with asynchronous computations. async: ^2.11.0 # Declarative routing solution, where everything needed for navigation is automatically generated for you. - auto_route: ^6.0.1 + auto_route: ^7.3.2 # Automatically resizes text to fit perfectly within its bounds. auto_size_text: ^3.0.0 # Helps implement the BLoC pattern. - bloc: ^8.1.1 + bloc: ^8.1.2 # Copy text from and to clipboard clipboard: ^0.1.3 # Allow discover network connectivity - connectivity_plus: ^3.0.3 + connectivity_plus: ^4.0.1 # The following adds the Cupertino Icons font to your application. # Use with the CupertinoIcons class for iOS style icons. cupertino_icons: ^1.0.5 @@ -57,35 +57,35 @@ dependencies: # A day night time picker. day_night_time_picker: ^1.2.0+2 # Helps us to select days in a week. - day_picker: ^2.1.1 + day_picker: ^2.2.0 # Get current device information - device_info_plus: ^8.1.0 + device_info_plus: ^9.0.2 # Internationalization (Easy translations) - easy_localization: ^3.0.1 + easy_localization: ^3.0.2 # An "expansion" on the Flutter SDK's standard ExpansionTile - expansion_tile_card: ^2.0.0 + expansion_tile_card: ^3.0.0 flutter: sdk: flutter # Bloc for state management, replace StatefulWidget - flutter_bloc: ^8.1.2 + flutter_bloc: ^8.1.3 # HSV(HSB)/HSL/RGB/Material color picker flutter_colorpicker: ^1.0.3 # A cross platform plugin for displaying local notifications. - flutter_local_notifications: ^13.0.0 + flutter_local_notifications: ^14.1.0 # An easy to implement custom switch flutter_switch: ^0.3.2 # Getting the local timezone of the os. - flutter_timezone: ^1.0.4 + flutter_timezone: ^1.0.6 # Toast Library for Flutter, Easily create toast messages in single line of code. - fluttertoast: ^8.2.1 + fluttertoast: ^8.2.2 # Font Awesome Icon pack available as Flutter Icons. font_awesome_flutter: ^10.4.0 # Annotations for freezed freezed_annotation: ^2.2.0 # Service locator - get_it: ^7.2.0 + get_it: ^7.6.0 # Google Mobile Ads - google_mobile_ads: ^2.3.0 + google_mobile_ads: ^3.0.0 # Secure authentication system for signing in with a Google account on Android and iOS # google_sign_in: ^5.0.4 # A high performance, open source, general RPC framework that puts mobile and HTTP/2 first. @@ -93,23 +93,23 @@ dependencies: # Add hex color codes to your flutter projects hexcolor: ^3.0.1 # A composable, multi-platform, Future-based API for HTTP requests. - http: ^0.13.5 + http: ^0.13.0 # Open source icon sets for flutter iconify_flutter: ^0.0.5 # Convenient code generator for get_it - injectable: ^2.1.0 + injectable: ^2.1.1 # Allow you to have a screen at launcher for example - introduction_screen: ^3.1.7 + introduction_screen: ^3.1.8 # Extremely fast, easy to use, and fully async NoSQL database for Flutter. - isar: ^3.1.0 + isar: ^3.1.0+1 # Isar Core binaries for the Isar Database. Needs to be included for Flutter apps. - isar_flutter_libs: ^3.1.0 + isar_flutter_libs: ^3.1.0+1 # Defines the annotations used by json_serializable to create code for JSON serialization and deserialization. - json_annotation: ^4.8.0 + json_annotation: ^4.8.1 # Dart Build System builders for handling JSON. - json_serializable: ^6.6.1 + json_serializable: ^6.7.0 # Port of Kotlin's Kotlin Standard library for Dart/Flutter projects - kt_dart: ^1.0.0 + kt_dart: ^1.1.0 # Liquid progress indicator for Flutter. liquid_progress_indicator: ^0.4.0 # Handles getting a location on @@ -123,13 +123,13 @@ dependencies: # Service discovery over multicast DNS (mDNS), Bonjour, and Avahi. multicast_dns: ^0.3.2+3 # Discover network info and configure themselves accordingly - network_info_plus: ^3.0.2 + network_info_plus: ^4.0.1 # Helps you discover open ports, devices on subnet and more. - network_tools: ^3.0.0+3 + network_tools: ^3.2.1 # Querying information about the application package, such as CFBundleVersion - package_info_plus: ^3.0.3 + package_info_plus: ^4.0.2 # Finding commonly used locations on the filesystem - path_provider: ^2.0.14 + path_provider: ^2.0.15 # Popup that ask for the requested permission permission_handler: ^10.2.0 # Provides runtime support for a Dart implementation of protobufs. @@ -139,11 +139,11 @@ dependencies: # Implementation of the popular reactiveX api for asynchronous programming rxdart: ^0.27.7 # Reading and writing simple key-value pairs - shared_preferences: ^2.0.20 + shared_preferences: ^2.1.1 # Highly customizable circular slider/progress bar & spinner. sleek_circular_slider: ^2.0.1 # Plugin for launching a URL - url_launcher: ^6.1.10 + url_launcher: ^6.1.11 # Simple, fast generation of RFC4122 UUIDs. uuid: ^3.0.7 # Get available wifi ssid list, user can connect to wifi with ssid and password, and create hotspot @@ -154,20 +154,20 @@ dependencies: dev_dependencies: # Generator for auto_route library. - auto_route_generator: ^6.0.0 + auto_route_generator: ^7.1.1 # A build system for Dart code generation and modular compilation. - build_runner: ^2.3.3 + build_runner: ^2.4.4 # Package which simplifies the task of updating your Flutter app's launcher icon. - flutter_launcher_icons: ^0.12.0 + flutter_launcher_icons: ^0.13.1 # Code generator for unions/pattern-matching/copy. - freezed: ^2.3.2 + freezed: ^2.3.4 # Convenient code generator for get_it. - injectable_generator: ^2.1.4 + injectable_generator: ^2.1.5 # Code generator for the Isar Database. Finds classes annotated with @Collection. - isar_generator: ^3.1.0 + isar_generator: ^3.1.0+1 # Collection of lint rules for Dart and Flutter projects. - lint: ^2.0.1 + lint: ^2.1.2 # # Mock framework with APIs for Fakes, Mocks, behavior verification, and stubbing. # mockito: ^5.3.0 # A full featured library for writing and running Dart tests across platforms. - test: ^1.24.0 + test: ^1.24.3 diff --git a/windows/flutter/generated_plugin_registrant.cc b/windows/flutter/generated_plugin_registrant.cc index a6e4f3293..e027532d1 100644 --- a/windows/flutter/generated_plugin_registrant.cc +++ b/windows/flutter/generated_plugin_registrant.cc @@ -8,7 +8,6 @@ #include #include -#include #include #include @@ -17,8 +16,6 @@ void RegisterPlugins(flutter::PluginRegistry* registry) { registry->GetRegistrarForPlugin("ConnectivityPlusWindowsPlugin")); IsarFlutterLibsPluginRegisterWithRegistrar( registry->GetRegistrarForPlugin("IsarFlutterLibsPlugin")); - NetworkInfoPlusWindowsPluginRegisterWithRegistrar( - registry->GetRegistrarForPlugin("NetworkInfoPlusWindowsPlugin")); PermissionHandlerWindowsPluginRegisterWithRegistrar( registry->GetRegistrarForPlugin("PermissionHandlerWindowsPlugin")); UrlLauncherWindowsRegisterWithRegistrar( diff --git a/windows/flutter/generated_plugins.cmake b/windows/flutter/generated_plugins.cmake index 5a35eae45..b393d4d40 100644 --- a/windows/flutter/generated_plugins.cmake +++ b/windows/flutter/generated_plugins.cmake @@ -5,7 +5,6 @@ list(APPEND FLUTTER_PLUGIN_LIST connectivity_plus isar_flutter_libs - network_info_plus permission_handler_windows url_launcher_windows ) From 44b1792f204a90d4d3c511396cb35b6fff3190f8 Mon Sep 17 00:00:00 2001 From: guyluz Date: Tue, 30 May 2023 00:08:52 +0300 Subject: [PATCH 2/3] Fixed app stopped login automatically after last updates --- android/build.gradle | 2 +- .../isar_local_db/isar_repository.dart | 12 ++++++------ lib/main.dart | 2 +- .../widgets/computer_connection_check_widget.dart | 2 +- .../widgets/configure_new_cbj_comp_widget.dart | 3 ++- lib/presentation/core/app_widget.dart | 5 +++-- pubspec.yaml | 2 +- 7 files changed, 15 insertions(+), 13 deletions(-) diff --git a/android/build.gradle b/android/build.gradle index f6a5e340c..526936b85 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -30,6 +30,6 @@ subprojects { project.evaluationDependsOn(':app') } -task clean(type: Delete) { +tasks.register("clean", Delete) { delete rootProject.buildDir } diff --git a/lib/infrastructure/isar_local_db/isar_repository.dart b/lib/infrastructure/isar_local_db/isar_repository.dart index b0c6d2d8e..aaec20404 100644 --- a/lib/infrastructure/isar_local_db/isar_repository.dart +++ b/lib/infrastructure/isar_local_db/isar_repository.dart @@ -12,12 +12,12 @@ import 'package:path_provider/path_provider.dart'; @LazySingleton(as: ILocalDbRepository) class IsarRepository extends ILocalDbRepository { IsarRepository() { - asyncConstractor(); + asyncConstructor(); } late Isar isar; - Future asyncConstractor() async { + Future asyncConstructor() async { final dir = await getApplicationDocumentsDirectory(); isar = await Isar.open( [ @@ -117,7 +117,7 @@ class IsarRepository extends ILocalDbRepository { logger.i("Didn't find any remote pipes in the local DB"); } catch (e) { - logger.e('Local DB isar error: $e'); + logger.e('Local DB isar getRemotePipesDnsName error: $e'); } return left(const LocalDbFailures.unexpected()); } @@ -140,7 +140,7 @@ class IsarRepository extends ILocalDbRepository { logger.i("Didn't find any Hub entity in the local DB"); } catch (e) { - logger.e('Local DB isar error: $e'); + logger.e('Local DB isar getHubEntityLastKnownIp error: $e'); } return left(const LocalDbFailures.unexpected()); } @@ -164,7 +164,7 @@ class IsarRepository extends ILocalDbRepository { logger.i("Didn't find any Hub entity in the local DB"); } catch (e) { - logger.e('Local DB isar error: $e'); + logger.e('Local DB isar getHubEntityNetworkBssid error: $e'); } return left(const LocalDbFailures.unexpected()); } @@ -187,7 +187,7 @@ class IsarRepository extends ILocalDbRepository { logger.i("Didn't find any Hub entity in the local DB"); } catch (e) { - logger.e('Local DB isar error: $e'); + logger.e('Local DB isar getHubEntityNetworkName error: $e'); } return left(const LocalDbFailures.unexpected()); } diff --git a/lib/main.dart b/lib/main.dart index 37f69a01a..c5439ebba 100644 --- a/lib/main.dart +++ b/lib/main.dart @@ -42,10 +42,10 @@ class ReceivedNotification { Future main() async { configureDependencies(Env.prod); + WidgetsFlutterBinding.ensureInitialized(); getIt(); getIt.registerSingleton(AppRouter()); - WidgetsFlutterBinding.ensureInitialized(); AdState? adState; // Adds package only support Android and IOS diff --git a/lib/presentation/add_new_devices_process/computer_connection_check/widgets/computer_connection_check_widget.dart b/lib/presentation/add_new_devices_process/computer_connection_check/widgets/computer_connection_check_widget.dart index 1017517c8..a9d5130d0 100644 --- a/lib/presentation/add_new_devices_process/computer_connection_check/widgets/computer_connection_check_widget.dart +++ b/lib/presentation/add_new_devices_process/computer_connection_check/widgets/computer_connection_check_widget.dart @@ -5,7 +5,7 @@ import 'package:cybear_jinni/domain/cbj_comp/cbj_comp_entity.dart'; import 'package:cybear_jinni/presentation/routes/app_router.gr.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; -import 'package:liquid_progress_indicator/liquid_progress_indicator.dart'; +import 'package:liquid_progress_indicator_v2/liquid_progress_indicator.dart'; class ComputerConnectionCheckWidget extends StatelessWidget { const ComputerConnectionCheckWidget({ diff --git a/lib/presentation/add_new_devices_process/configure_new_cbj_comp/widgets/configure_new_cbj_comp_widget.dart b/lib/presentation/add_new_devices_process/configure_new_cbj_comp/widgets/configure_new_cbj_comp_widget.dart index be44daddf..89b8e1465 100644 --- a/lib/presentation/add_new_devices_process/configure_new_cbj_comp/widgets/configure_new_cbj_comp_widget.dart +++ b/lib/presentation/add_new_devices_process/configure_new_cbj_comp/widgets/configure_new_cbj_comp_widget.dart @@ -12,7 +12,8 @@ import 'package:cybear_jinni/presentation/routes/app_router.gr.dart'; import 'package:flutter/material.dart'; import 'package:flutter_bloc/flutter_bloc.dart'; import 'package:font_awesome_flutter/font_awesome_flutter.dart'; -import 'package:liquid_progress_indicator/liquid_progress_indicator.dart'; +import 'package:liquid_progress_indicator_v2/liquid_progress_indicator.dart'; + class ConfigureNewCbjCompWidgets extends StatelessWidget { const ConfigureNewCbjCompWidgets({ diff --git a/lib/presentation/core/app_widget.dart b/lib/presentation/core/app_widget.dart index d036f8eab..451876965 100644 --- a/lib/presentation/core/app_widget.dart +++ b/lib/presentation/core/app_widget.dart @@ -66,14 +66,15 @@ class AppWidget extends StatelessWidget { ), ), textTheme: const TextTheme( - bodyText1: TextStyle(color: Colors.white), - bodyText2: TextStyle(color: Colors.white70), + bodyLarge: TextStyle(color: Colors.white), + bodyMedium: TextStyle(color: Colors.white70), ), fontFamily: 'gidole_regular', colorScheme: ColorScheme.fromSwatch( primarySwatch: createMaterialColor( const Color.fromRGBO(162, 129, 162, 1.0), ), + accentColor: Colors.yellow, ).copyWith( secondary: Colors.indigo, ), diff --git a/pubspec.yaml b/pubspec.yaml index a5d56107a..d59976346 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -111,7 +111,7 @@ dependencies: # Port of Kotlin's Kotlin Standard library for Dart/Flutter projects kt_dart: ^1.1.0 # Liquid progress indicator for Flutter. - liquid_progress_indicator: ^0.4.0 + liquid_progress_indicator_v2: ^0.5.0 # Handles getting a location on location: ^4.4.0 # Small, easy to use and extensible logger which prints beautiful logs. From 4e8b30a746aa3cd49f1088c1b7bb31390b44b979 Mon Sep 17 00:00:00 2001 From: Parjanya Rajput Date: Sat, 30 Sep 2023 23:59:17 +0530 Subject: [PATCH 3/3] Upgrading to flutter 3.7.0 #632 --- android/build.gradle | 2 +- .../pick_repeat_time/pick_repeat_time_page.dart | 14 +++++++------- lib/presentation/core/app_widget.dart | 1 + pubspec.yaml | 4 ++-- 4 files changed, 11 insertions(+), 10 deletions(-) diff --git a/android/build.gradle b/android/build.gradle index f6a5e340c..526936b85 100644 --- a/android/build.gradle +++ b/android/build.gradle @@ -30,6 +30,6 @@ subprojects { project.evaluationDependsOn(':app') } -task clean(type: Delete) { +tasks.register("clean", Delete) { delete rootProject.buildDir } diff --git a/lib/presentation/add_new_automation_process/add_routine/pick_repeat_time/pick_repeat_time_page.dart b/lib/presentation/add_new_automation_process/add_routine/pick_repeat_time/pick_repeat_time_page.dart index 6050a2f71..bd00247ed 100644 --- a/lib/presentation/add_new_automation_process/add_routine/pick_repeat_time/pick_repeat_time_page.dart +++ b/lib/presentation/add_new_automation_process/add_routine/pick_repeat_time/pick_repeat_time_page.dart @@ -19,13 +19,13 @@ class PickRepeatTimePage extends StatelessWidget { @override Widget build(BuildContext context) { final List days = [ - DayInWeek("Sun"), - DayInWeek("Mon"), - DayInWeek("Tue", isSelected: true), - DayInWeek("Wed"), - DayInWeek("Thu"), - DayInWeek("Fri"), - DayInWeek("Sat"), + DayInWeek("Sun", dayKey: '1'), + DayInWeek("Mon", dayKey: '2'), + DayInWeek("Tue", isSelected: true, dayKey: '3'), + DayInWeek("Wed", dayKey: '4'), + DayInWeek("Thu", dayKey: '5'), + DayInWeek("Fri", dayKey: '6'), + DayInWeek("Sat", dayKey: '7'), ]; RoutineCbjRepeatDateDays? daysToRepeat; diff --git a/lib/presentation/core/app_widget.dart b/lib/presentation/core/app_widget.dart index d036f8eab..faae97a2c 100644 --- a/lib/presentation/core/app_widget.dart +++ b/lib/presentation/core/app_widget.dart @@ -57,6 +57,7 @@ class AppWidget extends StatelessWidget { // darkTheme: ThemeData(brightness: Brightness.dark), debugShowCheckedModeBanner: false, theme: ThemeData( + useMaterial3: true, primaryColor: createMaterialColor(const Color.fromRGBO(162, 129, 162, 1.0)), primaryColorDark: const Color(0xFF271052), diff --git a/pubspec.yaml b/pubspec.yaml index 2653be3ff..355c3e80f 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -6,7 +6,7 @@ homepage: https://cybearjinni.com publish_to: 'none' environment: - sdk: ">=2.18.2 <3.0.0" + sdk: ">=2.19.0 <3.0.0" # Don't get confuse, this is from the package flutter_launcher_icons and not flutter_icons flutter_icons: @@ -97,7 +97,7 @@ dependencies: # Open source icon sets for flutter iconify_flutter: ^0.0.5 # Convenient code generator for get_it - injectable: ^2.1.0 + injectable: ^2.3.0 # Allow you to have a screen at launcher for example introduction_screen: ^3.1.7 # Extremely fast, easy to use, and fully async NoSQL database for Flutter.