Switch to different package for date-picker

This commit is contained in:
Neeraj Gupta 2023-06-13 16:43:34 +05:30
parent 5d4784e3ff
commit 766946c3da
7 changed files with 23 additions and 22 deletions

View file

@ -193,7 +193,7 @@ DEPENDENCIES:
- flutter_sodium (from `.symlinks/plugins/flutter_sodium/ios`) - flutter_sodium (from `.symlinks/plugins/flutter_sodium/ios`)
- fluttertoast (from `.symlinks/plugins/fluttertoast/ios`) - fluttertoast (from `.symlinks/plugins/fluttertoast/ios`)
- image_editor_common (from `.symlinks/plugins/image_editor_common/ios`) - image_editor_common (from `.symlinks/plugins/image_editor_common/ios`)
- in_app_purchase_storekit (from `.symlinks/plugins/in_app_purchase_storekit/ios`) - in_app_purchase_storekit (from `.symlinks/plugins/in_app_purchase_storekit/darwin`)
- integration_test (from `.symlinks/plugins/integration_test/ios`) - integration_test (from `.symlinks/plugins/integration_test/ios`)
- local_auth_ios (from `.symlinks/plugins/local_auth_ios/ios`) - local_auth_ios (from `.symlinks/plugins/local_auth_ios/ios`)
- media_extension (from `.symlinks/plugins/media_extension/ios`) - media_extension (from `.symlinks/plugins/media_extension/ios`)
@ -201,12 +201,12 @@ DEPENDENCIES:
- move_to_background (from `.symlinks/plugins/move_to_background/ios`) - move_to_background (from `.symlinks/plugins/move_to_background/ios`)
- open_mail_app (from `.symlinks/plugins/open_mail_app/ios`) - open_mail_app (from `.symlinks/plugins/open_mail_app/ios`)
- package_info_plus (from `.symlinks/plugins/package_info_plus/ios`) - package_info_plus (from `.symlinks/plugins/package_info_plus/ios`)
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/ios`) - path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
- photo_manager (from `.symlinks/plugins/photo_manager/ios`) - photo_manager (from `.symlinks/plugins/photo_manager/ios`)
- receive_sharing_intent (from `.symlinks/plugins/receive_sharing_intent/ios`) - receive_sharing_intent (from `.symlinks/plugins/receive_sharing_intent/ios`)
- sentry_flutter (from `.symlinks/plugins/sentry_flutter/ios`) - sentry_flutter (from `.symlinks/plugins/sentry_flutter/ios`)
- share_plus (from `.symlinks/plugins/share_plus/ios`) - share_plus (from `.symlinks/plugins/share_plus/ios`)
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/ios`) - shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
- sqflite (from `.symlinks/plugins/sqflite/ios`) - sqflite (from `.symlinks/plugins/sqflite/ios`)
- tflite_flutter (from `.symlinks/plugins/tflite_flutter/ios`) - tflite_flutter (from `.symlinks/plugins/tflite_flutter/ios`)
- tflite_flutter_helper (from `.symlinks/plugins/tflite_flutter_helper/ios`) - tflite_flutter_helper (from `.symlinks/plugins/tflite_flutter_helper/ios`)
@ -273,7 +273,7 @@ EXTERNAL SOURCES:
image_editor_common: image_editor_common:
:path: ".symlinks/plugins/image_editor_common/ios" :path: ".symlinks/plugins/image_editor_common/ios"
in_app_purchase_storekit: in_app_purchase_storekit:
:path: ".symlinks/plugins/in_app_purchase_storekit/ios" :path: ".symlinks/plugins/in_app_purchase_storekit/darwin"
integration_test: integration_test:
:path: ".symlinks/plugins/integration_test/ios" :path: ".symlinks/plugins/integration_test/ios"
local_auth_ios: local_auth_ios:
@ -289,7 +289,7 @@ EXTERNAL SOURCES:
package_info_plus: package_info_plus:
:path: ".symlinks/plugins/package_info_plus/ios" :path: ".symlinks/plugins/package_info_plus/ios"
path_provider_foundation: path_provider_foundation:
:path: ".symlinks/plugins/path_provider_foundation/ios" :path: ".symlinks/plugins/path_provider_foundation/darwin"
photo_manager: photo_manager:
:path: ".symlinks/plugins/photo_manager/ios" :path: ".symlinks/plugins/photo_manager/ios"
receive_sharing_intent: receive_sharing_intent:
@ -299,7 +299,7 @@ EXTERNAL SOURCES:
share_plus: share_plus:
:path: ".symlinks/plugins/share_plus/ios" :path: ".symlinks/plugins/share_plus/ios"
shared_preferences_foundation: shared_preferences_foundation:
:path: ".symlinks/plugins/shared_preferences_foundation/ios" :path: ".symlinks/plugins/shared_preferences_foundation/darwin"
sqflite: sqflite:
:path: ".symlinks/plugins/sqflite/ios" :path: ".symlinks/plugins/sqflite/ios"
tflite_flutter: tflite_flutter:
@ -344,7 +344,7 @@ SPEC CHECKSUMS:
GoogleUtilities: 9aa0ad5a7bc171f8bae016300bfcfa3fb8425749 GoogleUtilities: 9aa0ad5a7bc171f8bae016300bfcfa3fb8425749
image_editor_common: d6f6644ae4a6de80481e89fe6d0a8c49e30b4b43 image_editor_common: d6f6644ae4a6de80481e89fe6d0a8c49e30b4b43
in_app_purchase_storekit: 4fb7ee9e824b1f09107fbfbbce8c4b276366dc43 in_app_purchase_storekit: 4fb7ee9e824b1f09107fbfbbce8c4b276366dc43
integration_test: a1e7d09bd98eca2fc37aefd79d4f41ad37bdbbe5 integration_test: 13825b8a9334a850581300559b8839134b124670
libwebp: f62cb61d0a484ba548448a4bd52aabf150ff6eef libwebp: f62cb61d0a484ba548448a4bd52aabf150ff6eef
local_auth_ios: c6cf091ded637a88f24f86a8875d8b0f526e2605 local_auth_ios: c6cf091ded637a88f24f86a8875d8b0f526e2605
Mantle: c5aa8794a29a022dfbbfc9799af95f477a69b62d Mantle: c5aa8794a29a022dfbbfc9799af95f477a69b62d

View file

@ -228,6 +228,7 @@
files = ( files = (
); );
inputPaths = ( inputPaths = (
"${TARGET_BUILD_DIR}/${INFOPLIST_PATH}",
); );
name = "Thin Binary"; name = "Thin Binary";
outputPaths = ( outputPaths = (

View file

@ -1,5 +1,5 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_datetime_picker/flutter_datetime_picker.dart'; import "package:flutter_datetime_picker_bdaya/flutter_datetime_picker_bdaya.dart";
import 'package:photos/theme/colors.dart'; import 'package:photos/theme/colors.dart';
import 'package:photos/theme/ente_theme.dart'; import 'package:photos/theme/ente_theme.dart';
@ -277,13 +277,13 @@ extension CustomColorScheme on ColorScheme {
? const Color.fromARGB(255, 238, 238, 238) ? const Color.fromARGB(255, 238, 238, 238)
: const Color.fromRGBO(255, 255, 255, 1).withOpacity(0.1); : const Color.fromRGBO(255, 255, 255, 1).withOpacity(0.1);
DatePickerTheme get dateTimePickertheme => brightness == Brightness.light DatePickerThemeBdaya get dateTimePickertheme => brightness == Brightness.light
? const DatePickerTheme( ? const DatePickerThemeBdaya(
backgroundColor: Colors.white, backgroundColor: Colors.white,
itemStyle: TextStyle(color: Colors.black), itemStyle: TextStyle(color: Colors.black),
cancelStyle: TextStyle(color: Colors.black), cancelStyle: TextStyle(color: Colors.black),
) )
: const DatePickerTheme( : const DatePickerThemeBdaya(
backgroundColor: Colors.black, backgroundColor: Colors.black,
itemStyle: TextStyle(color: Colors.white), itemStyle: TextStyle(color: Colors.white),
cancelStyle: TextStyle(color: Colors.white), cancelStyle: TextStyle(color: Colors.white),

View file

@ -1,5 +1,5 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter_datetime_picker/flutter_datetime_picker.dart'; import "package:flutter_datetime_picker_bdaya/flutter_datetime_picker_bdaya.dart";
import 'package:photos/ente_theme_data.dart'; import 'package:photos/ente_theme_data.dart';
import "package:photos/generated/l10n.dart"; import "package:photos/generated/l10n.dart";
import 'package:photos/models/collection.dart'; import 'package:photos/models/collection.dart';
@ -142,7 +142,7 @@ class _ItemsWidgetState extends State<ItemsWidget> {
// _showDateTimePicker return null if user doesn't select date-time // _showDateTimePicker return null if user doesn't select date-time
Future<int?> _showDateTimePicker(BuildContext context) async { Future<int?> _showDateTimePicker(BuildContext context) async {
final dateResult = await DatePicker.showDatePicker( final dateResult = await DatePickerBdaya.showDatePicker(
context, context,
minTime: DateTime.now(), minTime: DateTime.now(),
currentTime: DateTime.now(), currentTime: DateTime.now(),
@ -152,7 +152,7 @@ class _ItemsWidgetState extends State<ItemsWidget> {
if (dateResult == null) { if (dateResult == null) {
return null; return null;
} }
final dateWithTimeResult = await DatePicker.showTime12hPicker( final dateWithTimeResult = await DatePickerBdaya.showTime12hPicker(
context, context,
showTitleActions: true, showTitleActions: true,
currentTime: dateResult, currentTime: dateResult,

View file

@ -1,5 +1,5 @@
import "package:flutter/material.dart"; import "package:flutter/material.dart";
import "package:flutter_datetime_picker/flutter_datetime_picker.dart"; import "package:flutter_datetime_picker_bdaya/flutter_datetime_picker_bdaya.dart";
import "package:intl/intl.dart"; import "package:intl/intl.dart";
import "package:photos/ente_theme_data.dart"; import "package:photos/ente_theme_data.dart";
import "package:photos/models/file.dart"; import "package:photos/models/file.dart";
@ -46,7 +46,7 @@ class _CreationTimeItemState extends State<CreationTimeItem> {
} }
void _showDateTimePicker(File file) async { void _showDateTimePicker(File file) async {
final dateResult = await DatePicker.showDatePicker( final dateResult = await DatePickerBdaya.showDatePicker(
context, context,
minTime: DateTime(1800, 1, 1), minTime: DateTime(1800, 1, 1),
maxTime: DateTime.now(), maxTime: DateTime.now(),
@ -57,7 +57,7 @@ class _CreationTimeItemState extends State<CreationTimeItem> {
if (dateResult == null) { if (dateResult == null) {
return; return;
} }
final dateWithTimeResult = await DatePicker.showTime12hPicker( final dateWithTimeResult = await DatePickerBdaya.showTime12hPicker(
context, context,
showTitleActions: true, showTitleActions: true,
currentTime: dateResult, currentTime: dateResult,

View file

@ -608,14 +608,14 @@ packages:
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "3.3.0" version: "3.3.0"
flutter_datetime_picker: flutter_datetime_picker_bdaya:
dependency: "direct main" dependency: "direct main"
description: description:
name: flutter_datetime_picker name: flutter_datetime_picker_bdaya
sha256: "8e695c63c769350e541951227c2775190ec73ceda774a315b1dc9a99d5facfe5" sha256: "6cb42a7d659cb9a10afa0a390b81677e15fd2f7e340e7eaffabf770e6b6709c0"
url: "https://pub.dev" url: "https://pub.dev"
source: hosted source: hosted
version: "1.5.1" version: "3.0.2"
flutter_driver: flutter_driver:
dependency: "direct dev" dependency: "direct dev"
description: flutter description: flutter

View file

@ -56,7 +56,7 @@ dependencies:
sdk: flutter sdk: flutter
flutter_animate: ^4.1.0 flutter_animate: ^4.1.0
flutter_cache_manager: ^3.3.0 flutter_cache_manager: ^3.3.0
flutter_datetime_picker: ^1.5.1 flutter_datetime_picker_bdaya: ^3.0.2
flutter_easyloading: ^3.0.0 flutter_easyloading: ^3.0.0
flutter_email_sender: ^5.2.0 flutter_email_sender: ^5.2.0
flutter_image_compress: ^1.1.0 flutter_image_compress: ^1.1.0