From 77dd06264d6012c696772e294bdd26dec2c57175 Mon Sep 17 00:00:00 2001 From: MohammadTaha Basiri Date: Fri, 22 Apr 2022 15:26:03 +0430 Subject: [PATCH] bug fixes + package upgrades --- lib/utils/date_time.dart | 7 ++++ .../home/direct/widgets/audio_widget.dart | 30 +++++++------- lib/views/home/news/news.dart | 2 +- lib/views/home/radar/radar.dart | 2 +- .../home/settings/bookmarks/bookmarks.dart | 2 +- lib/views/home/studio/studio.dart | 2 +- pubspec.lock | 40 +++++++++++++------ 7 files changed, 53 insertions(+), 32 deletions(-) diff --git a/lib/utils/date_time.dart b/lib/utils/date_time.dart index 41be0c6..3e50c93 100644 --- a/lib/utils/date_time.dart +++ b/lib/utils/date_time.dart @@ -47,6 +47,13 @@ class DateTimeUtils { initialDate: initialJalali, firstDate: firstDate, lastDate: lastDate, + builder: (context, child) => Theme( + data: Theme.of(context).copyWith( + textTheme: Theme.of(context) + .textTheme + .copyWith(headline4: Theme.of(context).textTheme.headline3)), + child: child!, + ), ); return result?.toDateTime().toString(); diff --git a/lib/views/home/direct/widgets/audio_widget.dart b/lib/views/home/direct/widgets/audio_widget.dart index 7e55bd4..5f1c8bd 100644 --- a/lib/views/home/direct/widgets/audio_widget.dart +++ b/lib/views/home/direct/widgets/audio_widget.dart @@ -20,24 +20,24 @@ class AudioWidget extends StatelessWidget { @override Widget build(BuildContext context) { - return Row( - children: [ - Expanded( - child: AudioSlider( - tag: 'message-$id', - ), - ), - StreamBuilder( - stream: MediaService.audioPlayer.isPlaying, - builder: (context, snapshot) { - return _AudioControllerButton( + return StreamBuilder( + stream: MediaService.audioPlayer.isPlaying, + builder: (context, snapshot) { + return Row( + children: [ + Expanded( + child: AudioSlider( + tag: 'message-$id', + ), + ), + _AudioControllerButton( audioFile: audioFile, audioUrl: audioUrl, id: id, - ); - }, - ), - ], + ), + ], + ); + }, ); } } diff --git a/lib/views/home/news/news.dart b/lib/views/home/news/news.dart index bbfed23..afa9c9e 100644 --- a/lib/views/home/news/news.dart +++ b/lib/views/home/news/news.dart @@ -91,7 +91,7 @@ class _NewsState extends State { void _onChanged(String value) { final state = context.read(); - if (value.length < 4 && value.isNotEmpty || state.lastSearch == value) { + if (value.length < 3 && value.isNotEmpty || state.lastSearch == value) { return; } _timer?.cancel(); diff --git a/lib/views/home/radar/radar.dart b/lib/views/home/radar/radar.dart index 78ebc55..42f3b08 100644 --- a/lib/views/home/radar/radar.dart +++ b/lib/views/home/radar/radar.dart @@ -203,7 +203,7 @@ class _RadarState extends State { void _onChanged(String value) { final state = context.read(); - if (value.length < 4 && value.isNotEmpty || state.lastSearch == value) { + if (value.length < 3 && value.isNotEmpty || state.lastSearch == value) { return; } _timer?.cancel(); diff --git a/lib/views/home/settings/bookmarks/bookmarks.dart b/lib/views/home/settings/bookmarks/bookmarks.dart index 81ddeab..01ae4fe 100644 --- a/lib/views/home/settings/bookmarks/bookmarks.dart +++ b/lib/views/home/settings/bookmarks/bookmarks.dart @@ -144,7 +144,7 @@ class _BookmarksState extends State { void _onChanged(String value) { final state = context.read(); - if (value.length < 4 && value.isNotEmpty || state.lastSearch == value) { + if (value.length < 3 && value.isNotEmpty || state.lastSearch == value) { return; } _timer?.cancel(); diff --git a/lib/views/home/studio/studio.dart b/lib/views/home/studio/studio.dart index 296a552..f437719 100644 --- a/lib/views/home/studio/studio.dart +++ b/lib/views/home/studio/studio.dart @@ -165,7 +165,7 @@ class _StudioState extends State { void _onChanged(String value) { final state = context.read(); - if (value.length < 4 && value.isNotEmpty || state.lastSearch == value) { + if (value.length < 3 && value.isNotEmpty || state.lastSearch == value) { return; } _timer?.cancel(); diff --git a/pubspec.lock b/pubspec.lock index 737d1d4..3823c80 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -182,7 +182,7 @@ packages: name: firebase_core url: "https://pub.dartlang.org" source: hosted - version: "1.14.0" + version: "1.15.0" firebase_core_platform_interface: dependency: transitive description: @@ -196,28 +196,28 @@ packages: name: firebase_core_web url: "https://pub.dartlang.org" source: hosted - version: "1.6.1" + version: "1.6.2" firebase_messaging: dependency: "direct main" description: name: firebase_messaging url: "https://pub.dartlang.org" source: hosted - version: "11.2.12" + version: "11.2.14" firebase_messaging_platform_interface: dependency: transitive description: name: firebase_messaging_platform_interface url: "https://pub.dartlang.org" source: hosted - version: "3.2.2" + version: "3.3.0" firebase_messaging_web: dependency: transitive description: name: firebase_messaging_web url: "https://pub.dartlang.org" source: hosted - version: "2.2.10" + version: "2.2.12" fl_chart: dependency: "direct main" description: @@ -236,7 +236,7 @@ packages: name: flutter_blurhash url: "https://pub.dartlang.org" source: hosted - version: "0.6.4" + version: "0.6.8" flutter_cache_manager: dependency: transitive description: @@ -250,7 +250,7 @@ packages: name: flutter_html url: "https://pub.dartlang.org" source: hosted - version: "3.0.0-alpha.2" + version: "3.0.0-alpha.3" flutter_lints: dependency: "direct dev" description: @@ -398,6 +398,13 @@ packages: name: image_picker url: "https://pub.dartlang.org" source: hosted + version: "0.8.5" + image_picker_android: + dependency: transitive + description: + name: image_picker_android + url: "https://pub.dartlang.org" + source: hosted version: "0.8.4+11" image_picker_for_web: dependency: transitive @@ -406,6 +413,13 @@ packages: url: "https://pub.dartlang.org" source: hosted version: "2.1.6" + image_picker_ios: + dependency: transitive + description: + name: image_picker_ios + url: "https://pub.dartlang.org" + source: hosted + version: "0.8.4+11" image_picker_platform_interface: dependency: transitive description: @@ -615,7 +629,7 @@ packages: name: pin_code_fields url: "https://pub.dartlang.org" source: hosted - version: "7.3.0" + version: "7.4.0" platform: dependency: transitive description: @@ -704,14 +718,14 @@ packages: name: sqflite url: "https://pub.dartlang.org" source: hosted - version: "2.0.2" + version: "2.0.2+1" sqflite_common: dependency: transitive description: name: sqflite_common url: "https://pub.dartlang.org" source: hosted - version: "2.2.1" + version: "2.2.1+1" stack_trace: dependency: transitive description: @@ -893,14 +907,14 @@ packages: name: webview_flutter url: "https://pub.dartlang.org" source: hosted - version: "3.0.1" + version: "3.0.2" webview_flutter_android: dependency: transitive description: name: webview_flutter_android url: "https://pub.dartlang.org" source: hosted - version: "2.8.4" + version: "2.8.5" webview_flutter_platform_interface: dependency: transitive description: @@ -914,7 +928,7 @@ packages: name: webview_flutter_wkwebview url: "https://pub.dartlang.org" source: hosted - version: "2.7.1" + version: "2.7.2" win32: dependency: transitive description: