diff --git a/.fvmrc b/.fvmrc new file mode 100644 index 00000000..ff263c64 --- /dev/null +++ b/.fvmrc @@ -0,0 +1,3 @@ +{ + "flutter": "3.24.4" +} \ No newline at end of file diff --git a/.vscode/settings.json b/.vscode/settings.json new file mode 100644 index 00000000..aaf0d685 --- /dev/null +++ b/.vscode/settings.json @@ -0,0 +1,3 @@ +{ + "dart.flutterSdkPath": ".fvm/versions/3.24.4" +} \ No newline at end of file diff --git a/README.md b/README.md index 3cc3405c..e453a900 100644 --- a/README.md +++ b/README.md @@ -190,6 +190,15 @@ compileSdkVersion 32 + + + + Vineet/ +
+ Vineet +
+ + diff --git a/example/macos/Flutter/GeneratedPluginRegistrant.swift b/example/macos/Flutter/GeneratedPluginRegistrant.swift index ae781ad9..9068eca8 100644 --- a/example/macos/Flutter/GeneratedPluginRegistrant.swift +++ b/example/macos/Flutter/GeneratedPluginRegistrant.swift @@ -13,6 +13,7 @@ import firebase_crashlytics import firebase_messaging import flutter_tts import geolocator_apple +import location import open_file_mac import package_info_plus import path_provider_foundation @@ -30,6 +31,7 @@ func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) { FLTFirebaseMessagingPlugin.register(with: registry.registrar(forPlugin: "FLTFirebaseMessagingPlugin")) FlutterTtsPlugin.register(with: registry.registrar(forPlugin: "FlutterTtsPlugin")) GeolocatorPlugin.register(with: registry.registrar(forPlugin: "GeolocatorPlugin")) + LocationPlugin.register(with: registry.registrar(forPlugin: "LocationPlugin")) OpenFilePlugin.register(with: registry.registrar(forPlugin: "OpenFilePlugin")) FPPPackageInfoPlusPlugin.register(with: registry.registrar(forPlugin: "FPPPackageInfoPlusPlugin")) PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin")) diff --git a/example/pubspec.lock b/example/pubspec.lock index 669c19d5..a9956023 100644 --- a/example/pubspec.lock +++ b/example/pubspec.lock @@ -863,26 +863,26 @@ packages: dependency: transitive description: name: leak_tracker - sha256: "78eb209deea09858f5269f5a5b02be4049535f568c07b275096836f01ea323fa" + sha256: "3f87a60e8c63aecc975dda1ceedbc8f24de75f09e4856ea27daf8958f2f0ce05" url: "https://pub.dev" source: hosted - version: "10.0.0" + version: "10.0.5" leak_tracker_flutter_testing: dependency: transitive description: name: leak_tracker_flutter_testing - sha256: b46c5e37c19120a8a01918cfaf293547f47269f7cb4b0058f21531c2465d6ef0 + sha256: "932549fb305594d82d7183ecd9fa93463e9914e1b67cacc34bc40906594a1806" url: "https://pub.dev" source: hosted - version: "2.0.1" + version: "3.0.5" leak_tracker_testing: dependency: transitive description: name: leak_tracker_testing - sha256: a597f72a664dbd293f3bfc51f9ba69816f84dcd403cdac7066cb3f6003f3ab47 + sha256: "6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3" url: "https://pub.dev" source: hosted - version: "2.0.1" + version: "3.0.1" lints: dependency: transitive description: @@ -891,6 +891,30 @@ packages: url: "https://pub.dev" source: hosted version: "1.0.1" + location: + dependency: transitive + description: + name: location + sha256: "06be54f682c9073cbfec3899eb9bc8ed90faa0e17735c9d9fa7fe426f5be1dd1" + url: "https://pub.dev" + source: hosted + version: "5.0.3" + location_platform_interface: + dependency: transitive + description: + name: location_platform_interface + sha256: "8aa1d34eeecc979d7c9fe372931d84f6d2ebbd52226a54fe1620de6fdc0753b1" + url: "https://pub.dev" + source: hosted + version: "3.1.2" + location_web: + dependency: transitive + description: + name: location_web + sha256: ec484c66e8a4ff1ee5d044c203f4b6b71e3a0556a97b739a5bc9616de672412b + url: "https://pub.dev" + source: hosted + version: "4.2.0" logger: dependency: transitive description: @@ -919,18 +943,18 @@ packages: dependency: transitive description: name: material_color_utilities - sha256: "0e0a020085b65b6083975e499759762399b4475f766c21668c4ecca34ea74e5a" + sha256: f7142bb1154231d7ea5f96bc7bde4bda2a0945d2806bb11670e30b850d56bdec url: "https://pub.dev" source: hosted - version: "0.8.0" + version: "0.11.1" meta: dependency: transitive description: name: meta - sha256: d584fa6707a52763a52446f02cc621b077888fb63b93bbcb1143a7be5a0c0c04 + sha256: bdb68674043280c3428e9ec998512fb681678676b3c54e773629ffe74419f8c7 url: "https://pub.dev" source: hosted - version: "1.11.0" + version: "1.15.0" mime: dependency: transitive description: @@ -1412,10 +1436,10 @@ packages: dependency: transitive description: name: test_api - sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b" + sha256: "5b8a98dafc4d5c4c9c72d8b31ab2b23fc13422348d2997120294d3bac86b4ddb" url: "https://pub.dev" source: hosted - version: "0.6.1" + version: "0.7.2" time: dependency: transitive description: @@ -1556,10 +1580,10 @@ packages: dependency: transitive description: name: vm_service - sha256: b3d56ff4341b8f182b96aceb2fa20e3dcb336b9f867bc0eafc0de10f1048e957 + sha256: "5c5f338a667b4c644744b661f309fb8080bb94b18a7e91ef1dbd343bed00ed6d" url: "https://pub.dev" source: hosted - version: "13.0.0" + version: "14.2.5" web: dependency: transitive description: diff --git a/lib/src/core/location_info/location_info.dart b/lib/src/core/location_info/location_info.dart index 458ba8fc..a6dcadc4 100644 --- a/lib/src/core/location_info/location_info.dart +++ b/lib/src/core/location_info/location_info.dart @@ -1,23 +1,29 @@ import 'dart:async'; -import 'package:fa_flutter_core/fa_flutter_core.dart'; +import 'package:fa_flutter_core/fa_flutter_core.dart' hide Location; import 'package:fa_flutter_ui_kit/fa_flutter_ui_kit.dart'; import 'package:fa_flutter_ui_kit/src/core/location_info/models/place_mark_data/place_mark_data.dart'; import 'package:fa_flutter_ui_kit/src/utils/log_utils.dart'; import 'package:flutter/foundation.dart'; import 'package:flutter/material.dart'; +import 'package:location/location.dart' hide LocationAccuracy; abstract class LocationInfo { - LocationData get currentLocation; + LocationModel get currentLocation; - Stream get locationStream; + Stream get locationStream; Future initLocation(); - Future getLocationWithPlacemarkData(); + Future getLocationWithPlacemarkData(); + + Future forceUpdateCurrentLocation(); @protected - Future getAddress(Position location); + Future getAddress({ + required double lat, + required double lng, + }); /// Check if [inputLocation] and [currentLocation] /// is within the [minDistance] in metres @@ -41,16 +47,32 @@ class LocationInfoImpl implements LocationInfo { final String defaultLocationReason = 'Your current location helps your manager in reviewing work done by you'; - final _deviceLocation = ValueNotifier(null); + final _deviceLocation = ValueNotifier(null); Timer? locationCheckTimer; StreamSubscription? locationStreamSubs; @override - LocationData get currentLocation => _deviceLocation.value!; + LocationModel get currentLocation => _deviceLocation.value!; + + final _location2 = Location(); - Stream? positionStream; + // Stream? positionStream; + @override + Future forceUpdateCurrentLocation() async { + if (isWeb) { + return; + } + final location = await _getLocation(forceGPSUpdate: true); + if (location == null) { + throw MyException( + '${Constants.locationNotAvailable} \n $defaultLocationReason', + ); + } + final locationModel = await _parseLocation(location); + _setLocation(locationModel); + } @override Future initLocation() async { @@ -88,7 +110,7 @@ class LocationInfoImpl implements LocationInfo { ); } } else { - final location = LocationData( + final location = LocationModel( latitude: 26.85, longitude: 80.94, capturedAddress: 'Lucknow 22606', @@ -99,12 +121,122 @@ class LocationInfoImpl implements LocationInfo { } } - static Future _getLocation() async { + Future _getLocation({bool forceGPSUpdate = false}) async { + try { + if (isIOS) { + final location = await Geolocator.getCurrentPosition( + desiredAccuracy: LocationAccuracy.best, + forceAndroidLocationManager: isAndroid && forceGPSUpdate, + timeLimit: Duration(seconds: 10), + ); + return location; + } else { + final location = await _location2.getLocation(); + + if (location.latitude == null || location.longitude == null) { + return null; + } + return Position( + longitude: location.longitude!, + latitude: location.latitude!, + timestamp: DateTime.now(), + accuracy: location.accuracy ?? 9999, + altitude: location.altitude ?? 9999, + heading: location.heading ?? 9999, + speed: location.speed ?? 9999, + speedAccuracy: location.speedAccuracy ?? 9999, + altitudeAccuracy: location.accuracy ?? 9999, + headingAccuracy: location.headingAccuracy ?? 9999, + ); + } + } catch (e, s) { + // ToastUtils.showException(e); + logger.e(e, s); + + if (isWeb) { + return null; + } + + final _currLocFromGeoCoder = + await Geolocator.getCurrentPosition().timeout( + Duration(seconds: 10), + onTimeout: () async { + final _location = await Geolocator.getLastKnownPosition().timeout( + Duration(seconds: 5), + onTimeout: () { + logger.w( + "unable to get last known position using previous captured location"); + // ToastUtils.showException("_get Location Exception Time out"); + final _currentLocation = currentLocation; + return Position( + longitude: _currentLocation.longitude, + latitude: _currentLocation.latitude, + timestamp: DateTime.now(), + accuracy: _currentLocation.accuracy?.toDouble() ?? 9999, + altitude: 0, + heading: 0, + speed: 0, + speedAccuracy: 0, + altitudeAccuracy: 0, + headingAccuracy: 0, + ); + }, + ); + if (_location == null) { + throw LocationException("Unable to capture location"); + } + + return Position( + longitude: _location.longitude, + latitude: _location.latitude, + timestamp: DateTime.now(), + accuracy: _location.accuracy, + altitude: _location.altitude, + heading: _location.heading, + speed: _location.speed, + speedAccuracy: _location.speedAccuracy, + altitudeAccuracy: _location.altitudeAccuracy, + headingAccuracy: _location.headingAccuracy, + ); + }, + ); + + return Position( + longitude: _currLocFromGeoCoder.longitude, + latitude: _currLocFromGeoCoder.latitude, + timestamp: DateTime.now(), + accuracy: _currLocFromGeoCoder.accuracy.toDouble(), + altitude: _currLocFromGeoCoder.altitude, + heading: _currLocFromGeoCoder.heading, + speed: _currLocFromGeoCoder.speed, + speedAccuracy: _currLocFromGeoCoder.speedAccuracy, + altitudeAccuracy: _currLocFromGeoCoder.altitudeAccuracy, + headingAccuracy: _currLocFromGeoCoder.headingAccuracy, + ); + } + } + +/* + static Future _getLocation({bool forceGPSUpdate = false}) async { + try { + if (isIOS) { + final location = await Geolocator.getCurrentPosition( + desiredAccuracy: LocationAccuracy.best, + forceAndroidLocationManager: isAndroid && forceGPSUpdate, + timeLimit: Duration(seconds: 10), + ); + } + } + catch final location = await Geolocator.getCurrentPosition( - desiredAccuracy: LocationAccuracy.high, + desiredAccuracy: LocationAccuracy. + high + , ); - return location; + return + location; } +*/ bool _isPermissionGranted(LocationPermission permission) { return permission != LocationPermission.denied && @@ -137,20 +269,15 @@ class LocationInfoImpl implements LocationInfo { } void _startLocationFetchStream() { - positionStream ??= Geolocator.getPositionStream( + locationStreamSubs ??= Geolocator.getPositionStream( locationSettings: getLocationSetting(), - ).bufferTime(const Duration(seconds: 2)).transform( - StreamTransformer.fromHandlers(handleData: (d, sink) { - if (d.isNotEmpty) { - sink.add(d.last); - } - }), - ).shareValue(); - locationStreamSubs ??= positionStream?.listen((position) async { - if (position != null) { - final locationData = await _parseLocation(position); - _setLocation(locationData); - } + ) + .asBroadcastStream() + .shareValue() + .throttleTime(Duration(seconds: 10), trailing: true) + .listen((position) async { + final locationModel = await _parseLocation(position); + _setLocation(locationModel); }); } @@ -158,7 +285,7 @@ class LocationInfoImpl implements LocationInfo { locationStreamSubs?.cancel(); } - void _setLocation(LocationData location) { + void _setLocation(LocationModel location) { if (location != null) { _deviceLocation.value = location; //prefsHelper.lastLocation = jsonEncode(_deviceLocation.value.toJson()); @@ -169,7 +296,7 @@ class LocationInfoImpl implements LocationInfo { } } - Future _parseLocation(Position location) async { + Future _parseLocation(Position location) async { PlaceMarkData? placemark; try { if (enforceGeocoding) { @@ -180,14 +307,14 @@ class LocationInfoImpl implements LocationInfo { }); } } finally { - final locationData = LocationData( + final locationData = LocationModel( latitude: location.latitude, longitude: location.longitude, accuracy: location.accuracy.toInt(), captureTime: location.timestamp.millisecondsSinceEpoch ~/ 1000, captureLocationTime: DateTimeUtils.getCurrentISOTimeString( dateTime: location.timestamp.toLocal()), - source: isAndroid ? 'Android' : (isIOS ? 'iOS' : 'Unknown'), + source: isAndroid ? 'Android_geolocator' : (isIOS ? 'iOS' : 'Unknown'), capturedAddress: placemark?.getFullAddress() ?? null, placeMarkData: placemark, ); @@ -196,20 +323,34 @@ class LocationInfoImpl implements LocationInfo { } Future _fetchLocation() async { - await _startFetchingLocation().timeout(const Duration(seconds: 10), - onTimeout: () async { - final position = await Geolocator.getLastKnownPosition() + try { + await _startFetchingLocation().timeout(const Duration(seconds: 10), + onTimeout: () async { + final position = await Geolocator.getCurrentPosition() + .timeout(Duration(seconds: 10), onTimeout: () { + throw Exception("Location Exception"); + }); + // if (position == null) { + // throw LocationException( + // '${Constants.locationNotAvailable}\n$defaultLocationReason', + // ); + // } else { + await _onLocationFetch(position); + // } + }); + } catch (e, s) { + logger.e(e, s); + final _location = await Geolocator.getLastKnownPosition() .timeout(Duration(seconds: 5), onTimeout: () { - return null; + throw LocationException('Unable to capture location'); }); - if (position == null) { - throw LocationException( - '${Constants.locationNotAvailable}\n$defaultLocationReason', + if (_location != null) { + final location = await _parseLocation( + _location, ); - } else { - await _onLocationFetch(position); + _deviceLocation.value = location; } - }); + } } Future _onLocationFetch(Position location) async { @@ -224,7 +365,7 @@ class LocationInfoImpl implements LocationInfo { } Future _startFetchingLocation() async { - Position location; + Position? location; location = await _getLocation(); if (location == null) { throw LocationException( @@ -263,11 +404,16 @@ class LocationInfoImpl implements LocationInfo { } @override - Future getAddress(Position location) async { + Future getAddress({ + required double lat, + required double lng, + }) async { String _address = ""; try { final placemark = await getPlacemarkDataFromCoordinates( - latitude: location.latitude, longitude: location.longitude); + latitude: lat, + longitude: lng, + ); _address = placemark.getFullAddress(); } catch (e, s) { @@ -298,8 +444,51 @@ class LocationInfoImpl implements LocationInfo { } @override - Stream get locationStream { - if (isMobile && positionStream != null) { + Stream get locationStream { + if (isIOS) { + return Geolocator.getPositionStream( + locationSettings: getLocationSetting(), + ) + .asBroadcastStream() + .shareValue() + .throttleTime(Duration(seconds: 10), trailing: true) + .transform( + StreamTransformer.fromHandlers( + handleData: (data, sink) async { + logger.i("Got data parsing location.."); + final locationModel = await _parseLocation(data); + _setLocation(locationModel); + await Future.delayed(Duration(milliseconds: 500)); + return sink.add(locationModel); + }, + ), + ); + } else { + //Location works for Android, but doesn't support iOS 16 yet. + return _location2.onLocationChanged + .asBroadcastStream() + .shareValue() + .throttleTime(Duration(seconds: 15)) + .transform( + StreamTransformer.fromHandlers( + handleData: (data, sink) async { + final locationModel = await _parseLocation2(data); + _setLocation(locationModel); + return sink.add(locationModel); + }, + ), + ).timeout( + Duration(seconds: 15), + onTimeout: (sink1) { + // final _locationData = await _location2.getLocation(); + // final _locationModel = await _parseLocation2(_locationData); + if (_deviceLocation.value != null) { + return sink1.add(_deviceLocation.value!); + } + }, + ); + } + /*if (isMobile && positionStream != null) { return positionStream!.transform( StreamTransformer.fromHandlers( handleData: (data, sink) async { @@ -315,7 +504,31 @@ class LocationInfoImpl implements LocationInfo { ); } else { return BehaviorSubject.seeded(currentLocation); - } + }*/ + } + + Future _parseLocation2(LocationData location) async { + final _address = await getAddress( + lat: location.latitude!, + lng: location.longitude!, + ); + final _capturedTime = + (location.time ?? DateTime.now().millisecondsSinceEpoch).toInt() ~/ + 1000; + final locationModel = LocationModel( + latitude: location.latitude!, + longitude: location.longitude!, + accuracy: location.accuracy?.toInt() ?? 0, + captureTime: _capturedTime, + captureLocationTime: DateTimeUtils.getCurrentISOTimeString( + dateTime: DateTime.fromMillisecondsSinceEpoch(_capturedTime), + ), + source: isAndroid ? 'Android_location' : (isIOS ? 'iOS' : 'Unknown'), + capturedAddress: _address, + ); + // await _nwLogger.sendLogViaNetwork(data: "_parseLocation - $_address"); + + return locationModel; } @override @@ -331,10 +544,11 @@ class LocationInfoImpl implements LocationInfo { } @override - Future getLocationWithPlacemarkData() async { + Future getLocationWithPlacemarkData() async { final placemarkData = await getPlacemarkDataforNoGeocoding( - latitude: currentLocation.latitude ?? 26.85, - longitude: currentLocation.longitude ?? 80.94); + latitude: currentLocation.latitude ?? 26.85, + longitude: currentLocation.longitude ?? 80.94, + ); return currentLocation.copyWith( capturedAddress: placemarkData?.getFullAddress() ?? null, diff --git a/lib/src/core/location_info/models/location_data.dart b/lib/src/core/location_info/models/location_data.dart index f22419aa..3e06b09e 100644 --- a/lib/src/core/location_info/models/location_data.dart +++ b/lib/src/core/location_info/models/location_data.dart @@ -2,13 +2,14 @@ import 'package:fa_flutter_ui_kit/src/core/location_info/models/place_mark_data/ import 'package:freezed_annotation/freezed_annotation.dart'; part 'location_data.freezed.dart'; + part 'location_data.g.dart'; @freezed -abstract class LocationData with _$LocationData { - factory LocationData({ - @JsonKey(name: 'Longitude', required: true) final double? longitude, - @JsonKey(name: 'Latitude', required: true) final double? latitude, +abstract class LocationModel with _$LocationModel { + factory LocationModel({ + @JsonKey(name: 'Longitude', required: true) required final double longitude, + @JsonKey(name: 'Latitude', required: true) required final double latitude, @JsonKey(defaultValue: 0) final int? accuracy, @JsonKey(defaultValue: "NA") final String? source, final PlaceMarkData? placeMarkData, @@ -17,6 +18,6 @@ abstract class LocationData with _$LocationData { final String? captureLocationTime, }) = _LocationData; - factory LocationData.fromJson(Map json) => - _$LocationDataFromJson(json); + factory LocationModel.fromJson(Map json) => + _$LocationModelFromJson(json); } diff --git a/lib/src/core/location_info/models/location_data.freezed.dart b/lib/src/core/location_info/models/location_data.freezed.dart index 466783c0..e03b666b 100644 --- a/lib/src/core/location_info/models/location_data.freezed.dart +++ b/lib/src/core/location_info/models/location_data.freezed.dart @@ -12,18 +12,18 @@ part of 'location_data.dart'; T _$identity(T value) => value; final _privateConstructorUsedError = UnsupportedError( - 'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#custom-getters-and-methods'); + 'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models'); -LocationData _$LocationDataFromJson(Map json) { +LocationModel _$LocationModelFromJson(Map json) { return _LocationData.fromJson(json); } /// @nodoc -mixin _$LocationData { +mixin _$LocationModel { @JsonKey(name: 'Longitude', required: true) - double? get longitude => throw _privateConstructorUsedError; + double get longitude => throw _privateConstructorUsedError; @JsonKey(name: 'Latitude', required: true) - double? get latitude => throw _privateConstructorUsedError; + double get latitude => throw _privateConstructorUsedError; @JsonKey(defaultValue: 0) int? get accuracy => throw _privateConstructorUsedError; @JsonKey(defaultValue: "NA") @@ -35,19 +35,19 @@ mixin _$LocationData { Map toJson() => throw _privateConstructorUsedError; @JsonKey(ignore: true) - $LocationDataCopyWith get copyWith => + $LocationModelCopyWith get copyWith => throw _privateConstructorUsedError; } /// @nodoc -abstract class $LocationDataCopyWith<$Res> { - factory $LocationDataCopyWith( - LocationData value, $Res Function(LocationData) then) = - _$LocationDataCopyWithImpl<$Res, LocationData>; +abstract class $LocationModelCopyWith<$Res> { + factory $LocationModelCopyWith( + LocationModel value, $Res Function(LocationModel) then) = + _$LocationModelCopyWithImpl<$Res, LocationModel>; @useResult $Res call( - {@JsonKey(name: 'Longitude', required: true) double? longitude, - @JsonKey(name: 'Latitude', required: true) double? latitude, + {@JsonKey(name: 'Longitude', required: true) double longitude, + @JsonKey(name: 'Latitude', required: true) double latitude, @JsonKey(defaultValue: 0) int? accuracy, @JsonKey(defaultValue: "NA") String? source, PlaceMarkData? placeMarkData, @@ -59,9 +59,9 @@ abstract class $LocationDataCopyWith<$Res> { } /// @nodoc -class _$LocationDataCopyWithImpl<$Res, $Val extends LocationData> - implements $LocationDataCopyWith<$Res> { - _$LocationDataCopyWithImpl(this._value, this._then); +class _$LocationModelCopyWithImpl<$Res, $Val extends LocationModel> + implements $LocationModelCopyWith<$Res> { + _$LocationModelCopyWithImpl(this._value, this._then); // ignore: unused_field final $Val _value; @@ -71,8 +71,8 @@ class _$LocationDataCopyWithImpl<$Res, $Val extends LocationData> @pragma('vm:prefer-inline') @override $Res call({ - Object? longitude = freezed, - Object? latitude = freezed, + Object? longitude = null, + Object? latitude = null, Object? accuracy = freezed, Object? source = freezed, Object? placeMarkData = freezed, @@ -81,14 +81,14 @@ class _$LocationDataCopyWithImpl<$Res, $Val extends LocationData> Object? captureLocationTime = freezed, }) { return _then(_value.copyWith( - longitude: freezed == longitude + longitude: null == longitude ? _value.longitude : longitude // ignore: cast_nullable_to_non_nullable - as double?, - latitude: freezed == latitude + as double, + latitude: null == latitude ? _value.latitude : latitude // ignore: cast_nullable_to_non_nullable - as double?, + as double, accuracy: freezed == accuracy ? _value.accuracy : accuracy // ignore: cast_nullable_to_non_nullable @@ -130,16 +130,16 @@ class _$LocationDataCopyWithImpl<$Res, $Val extends LocationData> } /// @nodoc -abstract class _$$_LocationDataCopyWith<$Res> - implements $LocationDataCopyWith<$Res> { - factory _$$_LocationDataCopyWith( - _$_LocationData value, $Res Function(_$_LocationData) then) = - __$$_LocationDataCopyWithImpl<$Res>; +abstract class _$$LocationDataImplCopyWith<$Res> + implements $LocationModelCopyWith<$Res> { + factory _$$LocationDataImplCopyWith( + _$LocationDataImpl value, $Res Function(_$LocationDataImpl) then) = + __$$LocationDataImplCopyWithImpl<$Res>; @override @useResult $Res call( - {@JsonKey(name: 'Longitude', required: true) double? longitude, - @JsonKey(name: 'Latitude', required: true) double? latitude, + {@JsonKey(name: 'Longitude', required: true) double longitude, + @JsonKey(name: 'Latitude', required: true) double latitude, @JsonKey(defaultValue: 0) int? accuracy, @JsonKey(defaultValue: "NA") String? source, PlaceMarkData? placeMarkData, @@ -152,18 +152,18 @@ abstract class _$$_LocationDataCopyWith<$Res> } /// @nodoc -class __$$_LocationDataCopyWithImpl<$Res> - extends _$LocationDataCopyWithImpl<$Res, _$_LocationData> - implements _$$_LocationDataCopyWith<$Res> { - __$$_LocationDataCopyWithImpl( - _$_LocationData _value, $Res Function(_$_LocationData) _then) +class __$$LocationDataImplCopyWithImpl<$Res> + extends _$LocationModelCopyWithImpl<$Res, _$LocationDataImpl> + implements _$$LocationDataImplCopyWith<$Res> { + __$$LocationDataImplCopyWithImpl( + _$LocationDataImpl _value, $Res Function(_$LocationDataImpl) _then) : super(_value, _then); @pragma('vm:prefer-inline') @override $Res call({ - Object? longitude = freezed, - Object? latitude = freezed, + Object? longitude = null, + Object? latitude = null, Object? accuracy = freezed, Object? source = freezed, Object? placeMarkData = freezed, @@ -171,15 +171,15 @@ class __$$_LocationDataCopyWithImpl<$Res> Object? capturedAddress = freezed, Object? captureLocationTime = freezed, }) { - return _then(_$_LocationData( - longitude: freezed == longitude + return _then(_$LocationDataImpl( + longitude: null == longitude ? _value.longitude : longitude // ignore: cast_nullable_to_non_nullable - as double?, - latitude: freezed == latitude + as double, + latitude: null == latitude ? _value.latitude : latitude // ignore: cast_nullable_to_non_nullable - as double?, + as double, accuracy: freezed == accuracy ? _value.accuracy : accuracy // ignore: cast_nullable_to_non_nullable @@ -210,10 +210,10 @@ class __$$_LocationDataCopyWithImpl<$Res> /// @nodoc @JsonSerializable() -class _$_LocationData implements _LocationData { - _$_LocationData( - {@JsonKey(name: 'Longitude', required: true) this.longitude, - @JsonKey(name: 'Latitude', required: true) this.latitude, +class _$LocationDataImpl implements _LocationData { + _$LocationDataImpl( + {@JsonKey(name: 'Longitude', required: true) required this.longitude, + @JsonKey(name: 'Latitude', required: true) required this.latitude, @JsonKey(defaultValue: 0) this.accuracy, @JsonKey(defaultValue: "NA") this.source, this.placeMarkData, @@ -221,15 +221,15 @@ class _$_LocationData implements _LocationData { this.capturedAddress, this.captureLocationTime}); - factory _$_LocationData.fromJson(Map json) => - _$$_LocationDataFromJson(json); + factory _$LocationDataImpl.fromJson(Map json) => + _$$LocationDataImplFromJson(json); @override @JsonKey(name: 'Longitude', required: true) - final double? longitude; + final double longitude; @override @JsonKey(name: 'Latitude', required: true) - final double? latitude; + final double latitude; @override @JsonKey(defaultValue: 0) final int? accuracy; @@ -247,14 +247,14 @@ class _$_LocationData implements _LocationData { @override String toString() { - return 'LocationData(longitude: $longitude, latitude: $latitude, accuracy: $accuracy, source: $source, placeMarkData: $placeMarkData, captureTime: $captureTime, capturedAddress: $capturedAddress, captureLocationTime: $captureLocationTime)'; + return 'LocationModel(longitude: $longitude, latitude: $latitude, accuracy: $accuracy, source: $source, placeMarkData: $placeMarkData, captureTime: $captureTime, capturedAddress: $capturedAddress, captureLocationTime: $captureLocationTime)'; } @override - bool operator ==(dynamic other) { + bool operator ==(Object other) { return identical(this, other) || (other.runtimeType == runtimeType && - other is _$_LocationData && + other is _$LocationDataImpl && (identical(other.longitude, longitude) || other.longitude == longitude) && (identical(other.latitude, latitude) || @@ -280,37 +280,38 @@ class _$_LocationData implements _LocationData { @JsonKey(ignore: true) @override @pragma('vm:prefer-inline') - _$$_LocationDataCopyWith<_$_LocationData> get copyWith => - __$$_LocationDataCopyWithImpl<_$_LocationData>(this, _$identity); + _$$LocationDataImplCopyWith<_$LocationDataImpl> get copyWith => + __$$LocationDataImplCopyWithImpl<_$LocationDataImpl>(this, _$identity); @override Map toJson() { - return _$$_LocationDataToJson( + return _$$LocationDataImplToJson( this, ); } } -abstract class _LocationData implements LocationData { +abstract class _LocationData implements LocationModel { factory _LocationData( - {@JsonKey(name: 'Longitude', required: true) final double? longitude, - @JsonKey(name: 'Latitude', required: true) final double? latitude, + {@JsonKey(name: 'Longitude', required: true) + required final double longitude, + @JsonKey(name: 'Latitude', required: true) required final double latitude, @JsonKey(defaultValue: 0) final int? accuracy, @JsonKey(defaultValue: "NA") final String? source, final PlaceMarkData? placeMarkData, final int? captureTime, final String? capturedAddress, - final String? captureLocationTime}) = _$_LocationData; + final String? captureLocationTime}) = _$LocationDataImpl; factory _LocationData.fromJson(Map json) = - _$_LocationData.fromJson; + _$LocationDataImpl.fromJson; @override @JsonKey(name: 'Longitude', required: true) - double? get longitude; + double get longitude; @override @JsonKey(name: 'Latitude', required: true) - double? get latitude; + double get latitude; @override @JsonKey(defaultValue: 0) int? get accuracy; @@ -327,6 +328,6 @@ abstract class _LocationData implements LocationData { String? get captureLocationTime; @override @JsonKey(ignore: true) - _$$_LocationDataCopyWith<_$_LocationData> get copyWith => + _$$LocationDataImplCopyWith<_$LocationDataImpl> get copyWith => throw _privateConstructorUsedError; } diff --git a/lib/src/core/location_info/models/location_data.g.dart b/lib/src/core/location_info/models/location_data.g.dart index 3805b736..81af7a33 100644 --- a/lib/src/core/location_info/models/location_data.g.dart +++ b/lib/src/core/location_info/models/location_data.g.dart @@ -6,26 +6,26 @@ part of 'location_data.dart'; // JsonSerializableGenerator // ************************************************************************** -_$_LocationData _$$_LocationDataFromJson(Map json) { +_$LocationDataImpl _$$LocationDataImplFromJson(Map json) { $checkKeys( json, requiredKeys: const ['Longitude', 'Latitude'], ); - return _$_LocationData( - longitude: (json['Longitude'] as num?)?.toDouble(), - latitude: (json['Latitude'] as num?)?.toDouble(), - accuracy: json['accuracy'] as int? ?? 0, + return _$LocationDataImpl( + longitude: (json['Longitude'] as num).toDouble(), + latitude: (json['Latitude'] as num).toDouble(), + accuracy: (json['accuracy'] as num?)?.toInt() ?? 0, source: json['source'] as String? ?? 'NA', placeMarkData: json['placeMarkData'] == null ? null : PlaceMarkData.fromJson(json['placeMarkData'] as Map), - captureTime: json['captureTime'] as int?, + captureTime: (json['captureTime'] as num?)?.toInt(), capturedAddress: json['capturedAddress'] as String?, captureLocationTime: json['captureLocationTime'] as String?, ); } -Map _$$_LocationDataToJson(_$_LocationData instance) => +Map _$$LocationDataImplToJson(_$LocationDataImpl instance) => { 'Longitude': instance.longitude, 'Latitude': instance.latitude, diff --git a/lib/src/core/location_info/models/place_mark_data/place_mark_data.freezed.dart b/lib/src/core/location_info/models/place_mark_data/place_mark_data.freezed.dart index 58e02d41..b344d4aa 100644 --- a/lib/src/core/location_info/models/place_mark_data/place_mark_data.freezed.dart +++ b/lib/src/core/location_info/models/place_mark_data/place_mark_data.freezed.dart @@ -12,7 +12,7 @@ part of 'place_mark_data.dart'; T _$identity(T value) => value; final _privateConstructorUsedError = UnsupportedError( - 'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#custom-getters-and-methods'); + 'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models'); PlaceMarkData _$PlaceMarkDataFromJson(Map json) { return _PlaceMarkData.fromJson(json); @@ -133,11 +133,11 @@ class _$PlaceMarkDataCopyWithImpl<$Res, $Val extends PlaceMarkData> } /// @nodoc -abstract class _$$_PlaceMarkDataCopyWith<$Res> +abstract class _$$PlaceMarkDataImplCopyWith<$Res> implements $PlaceMarkDataCopyWith<$Res> { - factory _$$_PlaceMarkDataCopyWith( - _$_PlaceMarkData value, $Res Function(_$_PlaceMarkData) then) = - __$$_PlaceMarkDataCopyWithImpl<$Res>; + factory _$$PlaceMarkDataImplCopyWith( + _$PlaceMarkDataImpl value, $Res Function(_$PlaceMarkDataImpl) then) = + __$$PlaceMarkDataImplCopyWithImpl<$Res>; @override @useResult $Res call( @@ -155,11 +155,11 @@ abstract class _$$_PlaceMarkDataCopyWith<$Res> } /// @nodoc -class __$$_PlaceMarkDataCopyWithImpl<$Res> - extends _$PlaceMarkDataCopyWithImpl<$Res, _$_PlaceMarkData> - implements _$$_PlaceMarkDataCopyWith<$Res> { - __$$_PlaceMarkDataCopyWithImpl( - _$_PlaceMarkData _value, $Res Function(_$_PlaceMarkData) _then) +class __$$PlaceMarkDataImplCopyWithImpl<$Res> + extends _$PlaceMarkDataCopyWithImpl<$Res, _$PlaceMarkDataImpl> + implements _$$PlaceMarkDataImplCopyWith<$Res> { + __$$PlaceMarkDataImplCopyWithImpl( + _$PlaceMarkDataImpl _value, $Res Function(_$PlaceMarkDataImpl) _then) : super(_value, _then); @pragma('vm:prefer-inline') @@ -177,7 +177,7 @@ class __$$_PlaceMarkDataCopyWithImpl<$Res> Object? thoroughfare = freezed, Object? subThoroughfare = freezed, }) { - return _then(_$_PlaceMarkData( + return _then(_$PlaceMarkDataImpl( name: freezed == name ? _value.name : name // ignore: cast_nullable_to_non_nullable @@ -228,8 +228,8 @@ class __$$_PlaceMarkDataCopyWithImpl<$Res> /// @nodoc @JsonSerializable() -class _$_PlaceMarkData extends _PlaceMarkData { - _$_PlaceMarkData( +class _$PlaceMarkDataImpl extends _PlaceMarkData { + _$PlaceMarkDataImpl( {this.name, this.street, this.isoCountryCode, @@ -243,8 +243,8 @@ class _$_PlaceMarkData extends _PlaceMarkData { this.subThoroughfare}) : super._(); - factory _$_PlaceMarkData.fromJson(Map json) => - _$$_PlaceMarkDataFromJson(json); + factory _$PlaceMarkDataImpl.fromJson(Map json) => + _$$PlaceMarkDataImplFromJson(json); @override final String? name; @@ -275,10 +275,10 @@ class _$_PlaceMarkData extends _PlaceMarkData { } @override - bool operator ==(dynamic other) { + bool operator ==(Object other) { return identical(this, other) || (other.runtimeType == runtimeType && - other is _$_PlaceMarkData && + other is _$PlaceMarkDataImpl && (identical(other.name, name) || other.name == name) && (identical(other.street, street) || other.street == street) && (identical(other.isoCountryCode, isoCountryCode) || @@ -319,12 +319,12 @@ class _$_PlaceMarkData extends _PlaceMarkData { @JsonKey(ignore: true) @override @pragma('vm:prefer-inline') - _$$_PlaceMarkDataCopyWith<_$_PlaceMarkData> get copyWith => - __$$_PlaceMarkDataCopyWithImpl<_$_PlaceMarkData>(this, _$identity); + _$$PlaceMarkDataImplCopyWith<_$PlaceMarkDataImpl> get copyWith => + __$$PlaceMarkDataImplCopyWithImpl<_$PlaceMarkDataImpl>(this, _$identity); @override Map toJson() { - return _$$_PlaceMarkDataToJson( + return _$$PlaceMarkDataImplToJson( this, ); } @@ -342,11 +342,11 @@ abstract class _PlaceMarkData extends PlaceMarkData { final String? locality, final String? subLocality, final String? thoroughfare, - final String? subThoroughfare}) = _$_PlaceMarkData; + final String? subThoroughfare}) = _$PlaceMarkDataImpl; _PlaceMarkData._() : super._(); factory _PlaceMarkData.fromJson(Map json) = - _$_PlaceMarkData.fromJson; + _$PlaceMarkDataImpl.fromJson; @override String? get name; @@ -372,6 +372,6 @@ abstract class _PlaceMarkData extends PlaceMarkData { String? get subThoroughfare; @override @JsonKey(ignore: true) - _$$_PlaceMarkDataCopyWith<_$_PlaceMarkData> get copyWith => + _$$PlaceMarkDataImplCopyWith<_$PlaceMarkDataImpl> get copyWith => throw _privateConstructorUsedError; } diff --git a/lib/src/core/location_info/models/place_mark_data/place_mark_data.g.dart b/lib/src/core/location_info/models/place_mark_data/place_mark_data.g.dart index a81f8c1a..058db50b 100644 --- a/lib/src/core/location_info/models/place_mark_data/place_mark_data.g.dart +++ b/lib/src/core/location_info/models/place_mark_data/place_mark_data.g.dart @@ -6,8 +6,8 @@ part of 'place_mark_data.dart'; // JsonSerializableGenerator // ************************************************************************** -_$_PlaceMarkData _$$_PlaceMarkDataFromJson(Map json) => - _$_PlaceMarkData( +_$PlaceMarkDataImpl _$$PlaceMarkDataImplFromJson(Map json) => + _$PlaceMarkDataImpl( name: json['name'] as String?, street: json['street'] as String?, isoCountryCode: json['isoCountryCode'] as String?, @@ -21,7 +21,7 @@ _$_PlaceMarkData _$$_PlaceMarkDataFromJson(Map json) => subThoroughfare: json['subThoroughfare'] as String?, ); -Map _$$_PlaceMarkDataToJson(_$_PlaceMarkData instance) => +Map _$$PlaceMarkDataImplToJson(_$PlaceMarkDataImpl instance) => { 'name': instance.name, 'street': instance.street, diff --git a/lib/src/data/models/country/country.freezed.dart b/lib/src/data/models/country/country.freezed.dart index 4dd0a9ac..29735122 100644 --- a/lib/src/data/models/country/country.freezed.dart +++ b/lib/src/data/models/country/country.freezed.dart @@ -12,7 +12,7 @@ part of 'country.dart'; T _$identity(T value) => value; final _privateConstructorUsedError = UnsupportedError( - 'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#custom-getters-and-methods'); + 'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models'); Country _$CountryFromJson(Map json) { return _Country.fromJson(json); @@ -96,10 +96,10 @@ class _$CountryCopyWithImpl<$Res, $Val extends Country> } /// @nodoc -abstract class _$$_CountryCopyWith<$Res> implements $CountryCopyWith<$Res> { - factory _$$_CountryCopyWith( - _$_Country value, $Res Function(_$_Country) then) = - __$$_CountryCopyWithImpl<$Res>; +abstract class _$$CountryImplCopyWith<$Res> implements $CountryCopyWith<$Res> { + factory _$$CountryImplCopyWith( + _$CountryImpl value, $Res Function(_$CountryImpl) then) = + __$$CountryImplCopyWithImpl<$Res>; @override @useResult $Res call( @@ -112,10 +112,11 @@ abstract class _$$_CountryCopyWith<$Res> implements $CountryCopyWith<$Res> { } /// @nodoc -class __$$_CountryCopyWithImpl<$Res> - extends _$CountryCopyWithImpl<$Res, _$_Country> - implements _$$_CountryCopyWith<$Res> { - __$$_CountryCopyWithImpl(_$_Country _value, $Res Function(_$_Country) _then) +class __$$CountryImplCopyWithImpl<$Res> + extends _$CountryCopyWithImpl<$Res, _$CountryImpl> + implements _$$CountryImplCopyWith<$Res> { + __$$CountryImplCopyWithImpl( + _$CountryImpl _value, $Res Function(_$CountryImpl) _then) : super(_value, _then); @pragma('vm:prefer-inline') @@ -128,7 +129,7 @@ class __$$_CountryCopyWithImpl<$Res> Object? nationality = freezed, Object? countryName = freezed, }) { - return _then(_$_Country( + return _then(_$CountryImpl( countryId: freezed == countryId ? _value.countryId : countryId // ignore: cast_nullable_to_non_nullable @@ -159,8 +160,8 @@ class __$$_CountryCopyWithImpl<$Res> /// @nodoc @JsonSerializable() -class _$_Country implements _Country { - _$_Country( +class _$CountryImpl implements _Country { + _$CountryImpl( {this.countryId, this.countryCode, this.dialCode, @@ -168,8 +169,8 @@ class _$_Country implements _Country { this.nationality, this.countryName}); - factory _$_Country.fromJson(Map json) => - _$$_CountryFromJson(json); + factory _$CountryImpl.fromJson(Map json) => + _$$CountryImplFromJson(json); @override final String? countryId; @@ -190,10 +191,10 @@ class _$_Country implements _Country { } @override - bool operator ==(dynamic other) { + bool operator ==(Object other) { return identical(this, other) || (other.runtimeType == runtimeType && - other is _$_Country && + other is _$CountryImpl && (identical(other.countryId, countryId) || other.countryId == countryId) && (identical(other.countryCode, countryCode) || @@ -216,12 +217,12 @@ class _$_Country implements _Country { @JsonKey(ignore: true) @override @pragma('vm:prefer-inline') - _$$_CountryCopyWith<_$_Country> get copyWith => - __$$_CountryCopyWithImpl<_$_Country>(this, _$identity); + _$$CountryImplCopyWith<_$CountryImpl> get copyWith => + __$$CountryImplCopyWithImpl<_$CountryImpl>(this, _$identity); @override Map toJson() { - return _$$_CountryToJson( + return _$$CountryImplToJson( this, ); } @@ -234,9 +235,9 @@ abstract class _Country implements Country { final String? dialCode, final String? flagCode, final String? nationality, - final String? countryName}) = _$_Country; + final String? countryName}) = _$CountryImpl; - factory _Country.fromJson(Map json) = _$_Country.fromJson; + factory _Country.fromJson(Map json) = _$CountryImpl.fromJson; @override String? get countryId; @@ -252,6 +253,6 @@ abstract class _Country implements Country { String? get countryName; @override @JsonKey(ignore: true) - _$$_CountryCopyWith<_$_Country> get copyWith => + _$$CountryImplCopyWith<_$CountryImpl> get copyWith => throw _privateConstructorUsedError; } diff --git a/lib/src/data/models/country/country.g.dart b/lib/src/data/models/country/country.g.dart index f4e964f4..8f20dc4a 100644 --- a/lib/src/data/models/country/country.g.dart +++ b/lib/src/data/models/country/country.g.dart @@ -6,7 +6,8 @@ part of 'country.dart'; // JsonSerializableGenerator // ************************************************************************** -_$_Country _$$_CountryFromJson(Map json) => _$_Country( +_$CountryImpl _$$CountryImplFromJson(Map json) => + _$CountryImpl( countryId: json['countryId'] as String?, countryCode: json['countryCode'] as String?, dialCode: json['dialCode'] as String?, @@ -15,7 +16,7 @@ _$_Country _$$_CountryFromJson(Map json) => _$_Country( countryName: json['countryName'] as String?, ); -Map _$$_CountryToJson(_$_Country instance) => +Map _$$CountryImplToJson(_$CountryImpl instance) => { 'countryId': instance.countryId, 'countryCode': instance.countryCode, diff --git a/lib/src/widgets/order_booking/summary/order_amount_summary.dart b/lib/src/widgets/order_booking/summary/order_amount_summary.dart index 6bba43ce..52683c46 100644 --- a/lib/src/widgets/order_booking/summary/order_amount_summary.dart +++ b/lib/src/widgets/order_booking/summary/order_amount_summary.dart @@ -74,6 +74,7 @@ class OrderAmountSummaryWidget extends StatelessWidget { this.payableAmountInSecondCurrency, this.showTotalQtyInAllUnits = false, this.isRestrictStockValueVisibility = false, + this.miscWidget, super.key, }); @@ -108,6 +109,7 @@ class OrderAmountSummaryWidget extends StatelessWidget { final bool compactNumber; final String? payableAmountInSecondCurrency; final bool showTotalQtyInAllUnits; + final Widget? miscWidget; final bool isRestrictStockValueVisibility; final titleTextStyle = TextStyle( @@ -323,6 +325,10 @@ class OrderAmountSummaryWidget extends StatelessWidget { ), ], ), + if (miscWidget != null) ...[ + DottedDivider(), + miscWidget!, + ], if (decimalInfoString != null) Padding( padding: EdgeInsets.fromLTRB(16, 16, 16, 2), diff --git a/pubspec.lock b/pubspec.lock index d6a41cc9..827c9fd3 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -1008,26 +1008,50 @@ packages: dependency: transitive description: name: leak_tracker - sha256: "78eb209deea09858f5269f5a5b02be4049535f568c07b275096836f01ea323fa" + sha256: "3f87a60e8c63aecc975dda1ceedbc8f24de75f09e4856ea27daf8958f2f0ce05" url: "https://pub.dev" source: hosted - version: "10.0.0" + version: "10.0.5" leak_tracker_flutter_testing: dependency: transitive description: name: leak_tracker_flutter_testing - sha256: b46c5e37c19120a8a01918cfaf293547f47269f7cb4b0058f21531c2465d6ef0 + sha256: "932549fb305594d82d7183ecd9fa93463e9914e1b67cacc34bc40906594a1806" url: "https://pub.dev" source: hosted - version: "2.0.1" + version: "3.0.5" leak_tracker_testing: dependency: transitive description: name: leak_tracker_testing - sha256: a597f72a664dbd293f3bfc51f9ba69816f84dcd403cdac7066cb3f6003f3ab47 + sha256: "6ba465d5d76e67ddf503e1161d1f4a6bc42306f9d66ca1e8f079a47290fb06d3" url: "https://pub.dev" source: hosted - version: "2.0.1" + version: "3.0.1" + location: + dependency: "direct main" + description: + name: location + sha256: "06be54f682c9073cbfec3899eb9bc8ed90faa0e17735c9d9fa7fe426f5be1dd1" + url: "https://pub.dev" + source: hosted + version: "5.0.3" + location_platform_interface: + dependency: transitive + description: + name: location_platform_interface + sha256: "8aa1d34eeecc979d7c9fe372931d84f6d2ebbd52226a54fe1620de6fdc0753b1" + url: "https://pub.dev" + source: hosted + version: "3.1.2" + location_web: + dependency: transitive + description: + name: location_web + sha256: ec484c66e8a4ff1ee5d044c203f4b6b71e3a0556a97b739a5bc9616de672412b + url: "https://pub.dev" + source: hosted + version: "4.2.0" logger: dependency: transitive description: @@ -1064,18 +1088,18 @@ packages: dependency: transitive description: name: material_color_utilities - sha256: "0e0a020085b65b6083975e499759762399b4475f766c21668c4ecca34ea74e5a" + sha256: f7142bb1154231d7ea5f96bc7bde4bda2a0945d2806bb11670e30b850d56bdec url: "https://pub.dev" source: hosted - version: "0.8.0" + version: "0.11.1" meta: dependency: transitive description: name: meta - sha256: d584fa6707a52763a52446f02cc621b077888fb63b93bbcb1143a7be5a0c0c04 + sha256: bdb68674043280c3428e9ec998512fb681678676b3c54e773629ffe74419f8c7 url: "https://pub.dev" source: hosted - version: "1.11.0" + version: "1.15.0" mime: dependency: transitive description: @@ -1621,10 +1645,10 @@ packages: dependency: transitive description: name: test_api - sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b" + sha256: "5b8a98dafc4d5c4c9c72d8b31ab2b23fc13422348d2997120294d3bac86b4ddb" url: "https://pub.dev" source: hosted - version: "0.6.1" + version: "0.7.2" time: dependency: transitive description: @@ -1773,10 +1797,10 @@ packages: dependency: transitive description: name: vm_service - sha256: b3d56ff4341b8f182b96aceb2fa20e3dcb336b9f867bc0eafc0de10f1048e957 + sha256: "5c5f338a667b4c644744b661f309fb8080bb94b18a7e91ef1dbd343bed00ed6d" url: "https://pub.dev" source: hosted - version: "13.0.0" + version: "14.2.5" watcher: dependency: transitive description: diff --git a/pubspec.yaml b/pubspec.yaml index 795209c8..a721c4dc 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -16,6 +16,7 @@ dependencies: flutter_tts: ^4.0.2 file_picker: ^8.0.0+1 open_file: ^3.3.2 + location: ^5.0.3 # Core fa_flutter_core: