diff --git a/packages/at_invitation_flutter/example/ios/Flutter/AppFrameworkInfo.plist b/packages/at_invitation_flutter/example/ios/Flutter/AppFrameworkInfo.plist
index 8d4492f97..9625e105d 100644
--- a/packages/at_invitation_flutter/example/ios/Flutter/AppFrameworkInfo.plist
+++ b/packages/at_invitation_flutter/example/ios/Flutter/AppFrameworkInfo.plist
@@ -21,6 +21,6 @@
CFBundleVersion
1.0
MinimumOSVersion
- 9.0
+ 11.0
diff --git a/packages/at_invitation_flutter/example/ios/Podfile.lock b/packages/at_invitation_flutter/example/ios/Podfile.lock
index 0551a8953..41358d2ca 100644
--- a/packages/at_invitation_flutter/example/ios/Podfile.lock
+++ b/packages/at_invitation_flutter/example/ios/Podfile.lock
@@ -1,20 +1,24 @@
PODS:
- at_backupkey_flutter (0.0.1):
- Flutter
+ - at_file_saver (0.0.1):
+ - Flutter
- at_invitation_flutter (0.0.1):
- Flutter
- at_onboarding_flutter (0.0.1):
- Flutter
- biometric_storage (0.0.1):
- Flutter
- - DKImagePickerController/Core (4.3.2):
+ - device_info_plus (0.0.1):
+ - Flutter
+ - DKImagePickerController/Core (4.3.4):
- DKImagePickerController/ImageDataManager
- DKImagePickerController/Resource
- - DKImagePickerController/ImageDataManager (4.3.2)
- - DKImagePickerController/PhotoGallery (4.3.2):
+ - DKImagePickerController/ImageDataManager (4.3.4)
+ - DKImagePickerController/PhotoGallery (4.3.4):
- DKImagePickerController/Core
- DKPhotoGallery
- - DKImagePickerController/Resource (4.3.2)
+ - DKImagePickerController/Resource (4.3.4)
- DKPhotoGallery (0.0.17):
- DKPhotoGallery/Core (= 0.0.17)
- DKPhotoGallery/Model (= 0.0.17)
@@ -41,23 +45,31 @@ PODS:
- file_picker (0.0.1):
- DKImagePickerController/PhotoGallery
- Flutter
- - file_saver (0.0.1):
+ - file_selector_ios (0.0.1):
- Flutter
- Flutter (1.0.0)
- flutter_keychain (0.0.1):
- Flutter
- - flutter_qr_reader (0.0.1):
+ - MTBBarcodeScanner (5.0.11)
+ - package_info_plus (0.4.5):
- Flutter
- - path_provider_ios (0.0.1):
+ - path_provider_foundation (0.0.1):
- Flutter
- - "permission_handler (5.1.0+2)":
+ - FlutterMacOS
+ - permission_handler_apple (9.1.1):
- Flutter
- - SDWebImage (5.11.1):
- - SDWebImage/Core (= 5.11.1)
- - SDWebImage/Core (5.11.1)
+ - qr_code_scanner (0.2.0):
+ - Flutter
+ - MTBBarcodeScanner
+ - SDWebImage (5.18.10):
+ - SDWebImage/Core (= 5.18.10)
+ - SDWebImage/Core (5.18.10)
- share_plus (0.0.1):
- Flutter
- - SwiftyGif (5.4.0)
+ - shared_preferences_foundation (0.0.1):
+ - Flutter
+ - FlutterMacOS
+ - SwiftyGif (5.4.4)
- uni_links (0.0.1):
- Flutter
- url_launcher_ios (0.0.1):
@@ -67,17 +79,21 @@ PODS:
DEPENDENCIES:
- at_backupkey_flutter (from `.symlinks/plugins/at_backupkey_flutter/ios`)
+ - at_file_saver (from `.symlinks/plugins/at_file_saver/ios`)
- at_invitation_flutter (from `.symlinks/plugins/at_invitation_flutter/ios`)
- at_onboarding_flutter (from `.symlinks/plugins/at_onboarding_flutter/ios`)
- biometric_storage (from `.symlinks/plugins/biometric_storage/ios`)
+ - device_info_plus (from `.symlinks/plugins/device_info_plus/ios`)
- file_picker (from `.symlinks/plugins/file_picker/ios`)
- - file_saver (from `.symlinks/plugins/file_saver/ios`)
+ - file_selector_ios (from `.symlinks/plugins/file_selector_ios/ios`)
- Flutter (from `Flutter`)
- flutter_keychain (from `.symlinks/plugins/flutter_keychain/ios`)
- - flutter_qr_reader (from `.symlinks/plugins/flutter_qr_reader/ios`)
- - path_provider_ios (from `.symlinks/plugins/path_provider_ios/ios`)
- - permission_handler (from `.symlinks/plugins/permission_handler/ios`)
+ - package_info_plus (from `.symlinks/plugins/package_info_plus/ios`)
+ - path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
+ - permission_handler_apple (from `.symlinks/plugins/permission_handler_apple/ios`)
+ - qr_code_scanner (from `.symlinks/plugins/qr_code_scanner/ios`)
- share_plus (from `.symlinks/plugins/share_plus/ios`)
+ - shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
- uni_links (from `.symlinks/plugins/uni_links/ios`)
- url_launcher_ios (from `.symlinks/plugins/url_launcher_ios/ios`)
- webview_flutter_wkwebview (from `.symlinks/plugins/webview_flutter_wkwebview/ios`)
@@ -86,34 +102,43 @@ SPEC REPOS:
trunk:
- DKImagePickerController
- DKPhotoGallery
+ - MTBBarcodeScanner
- SDWebImage
- SwiftyGif
EXTERNAL SOURCES:
at_backupkey_flutter:
:path: ".symlinks/plugins/at_backupkey_flutter/ios"
+ at_file_saver:
+ :path: ".symlinks/plugins/at_file_saver/ios"
at_invitation_flutter:
:path: ".symlinks/plugins/at_invitation_flutter/ios"
at_onboarding_flutter:
:path: ".symlinks/plugins/at_onboarding_flutter/ios"
biometric_storage:
:path: ".symlinks/plugins/biometric_storage/ios"
+ device_info_plus:
+ :path: ".symlinks/plugins/device_info_plus/ios"
file_picker:
:path: ".symlinks/plugins/file_picker/ios"
- file_saver:
- :path: ".symlinks/plugins/file_saver/ios"
+ file_selector_ios:
+ :path: ".symlinks/plugins/file_selector_ios/ios"
Flutter:
:path: Flutter
flutter_keychain:
:path: ".symlinks/plugins/flutter_keychain/ios"
- flutter_qr_reader:
- :path: ".symlinks/plugins/flutter_qr_reader/ios"
- path_provider_ios:
- :path: ".symlinks/plugins/path_provider_ios/ios"
- permission_handler:
- :path: ".symlinks/plugins/permission_handler/ios"
+ package_info_plus:
+ :path: ".symlinks/plugins/package_info_plus/ios"
+ path_provider_foundation:
+ :path: ".symlinks/plugins/path_provider_foundation/darwin"
+ permission_handler_apple:
+ :path: ".symlinks/plugins/permission_handler_apple/ios"
+ qr_code_scanner:
+ :path: ".symlinks/plugins/qr_code_scanner/ios"
share_plus:
:path: ".symlinks/plugins/share_plus/ios"
+ shared_preferences_foundation:
+ :path: ".symlinks/plugins/shared_preferences_foundation/darwin"
uni_links:
:path: ".symlinks/plugins/uni_links/ios"
url_launcher_ios:
@@ -123,25 +148,30 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS:
at_backupkey_flutter: 2fc3d01138175e41bce8b574387a47544c53e01b
+ at_file_saver: c0e052c72d8c0296318bd70f2ae7f510887014ce
at_invitation_flutter: 96015bc9cd2c14148bfea6e6b73151120d701234
at_onboarding_flutter: e8219b6d0bfb236d3837ec3528871aebdcc56e8d
biometric_storage: 1400f1382af3a4cc2bf05340e13c3d8de873ceb9
- DKImagePickerController: b5eb7f7a388e4643264105d648d01f727110fc3d
+ device_info_plus: c6fb39579d0f423935b0c9ce7ee2f44b71b9fce6
+ DKImagePickerController: b512c28220a2b8ac7419f21c491fc8534b7601ac
DKPhotoGallery: fdfad5125a9fdda9cc57df834d49df790dbb4179
- file_picker: 3e6c3790de664ccf9b882732d9db5eaf6b8d4eb1
- file_saver: 503e386464dbe118f630e17b4c2e1190fa0cf808
- Flutter: 50d75fe2f02b26cc09d224853bb45737f8b3214a
+ file_picker: 15fd9539e4eb735dc54bae8c0534a7a9511a03de
+ file_selector_ios: 8c25d700d625e1dcdd6599f2d927072f2254647b
+ Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
flutter_keychain: 01aabf894ffe8b01adfda1d9df21c210c1b4b452
- flutter_qr_reader: d930dde3b2cfe2b3d0bb7d66e5ff3e514300a5e5
- path_provider_ios: 7d7ce634493af4477d156294792024ec3485acd5
- permission_handler: ccb20a9fad0ee9b1314a52b70b76b473c5f8dab0
- SDWebImage: a7f831e1a65eb5e285e3fb046a23fcfbf08e696d
- share_plus: 056a1e8ac890df3e33cb503afffaf1e9b4fbae68
- SwiftyGif: 5d4af95df24caf1c570dbbcb32a3b8a0763bc6d7
+ MTBBarcodeScanner: f453b33c4b7dfe545d8c6484ed744d55671788cb
+ package_info_plus: 115f4ad11e0698c8c1c5d8a689390df880f47e85
+ path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943
+ permission_handler_apple: e76247795d700c14ea09e3a2d8855d41ee80a2e6
+ qr_code_scanner: bb67d64904c3b9658ada8c402e8b4d406d5d796e
+ SDWebImage: fc8f2d48bbfd72ef39d70e981bd24a3f3be53fec
+ share_plus: c3fef564749587fc939ef86ffb283ceac0baf9f5
+ shared_preferences_foundation: 5b919d13b803cadd15ed2dc053125c68730e5126
+ SwiftyGif: 93a1cc87bf3a51916001cf8f3d63835fb64c819f
uni_links: d97da20c7701486ba192624d99bffaaffcfc298a
- url_launcher_ios: 02f1989d4e14e998335b02b67a7590fa34f971af
- webview_flutter_wkwebview: 005fbd90c888a42c5690919a1527ecc6649e1162
+ url_launcher_ios: bf5ce03e0e2088bad9cc378ea97fa0ed5b49673b
+ webview_flutter_wkwebview: 2e2d318f21a5e036e2c3f26171342e95908bd60a
-PODFILE CHECKSUM: aafe91acc616949ddb318b77800a7f51bffa2a4c
+PODFILE CHECKSUM: ef19549a9bc3046e7bb7d2fab4d021637c0c58a3
-COCOAPODS: 1.10.1
+COCOAPODS: 1.12.1
diff --git a/packages/at_invitation_flutter/example/pubspec.yaml b/packages/at_invitation_flutter/example/pubspec.yaml
index d8c47253e..c387590e6 100644
--- a/packages/at_invitation_flutter/example/pubspec.yaml
+++ b/packages/at_invitation_flutter/example/pubspec.yaml
@@ -49,6 +49,14 @@ dependencies:
uni_links: ^0.5.1
url_launcher: ^6.1.14
+
+dependency_overrides:
+ at_onboarding_flutter:
+ git:
+ url: https://github.com/atsign-foundation/at_widgets.git
+ path: packages/at_onboarding_flutter
+ ref: fix/onboarding_deps_and_pub_points
+
dev_dependencies:
# The "flutter_lints" package below contains a set of recommended lints to
# encourage good coding practices. The lint set provided by the package is
diff --git a/packages/at_invitation_flutter/lib/services/invitation_service.dart b/packages/at_invitation_flutter/lib/services/invitation_service.dart
index 59a6a8c8b..445dc4b18 100644
--- a/packages/at_invitation_flutter/lib/services/invitation_service.dart
+++ b/packages/at_invitation_flutter/lib/services/invitation_service.dart
@@ -28,6 +28,8 @@ class InvitationService {
bool hasMonitorStarted = false;
GlobalKey get navigatorKey => navkey ?? GlobalKey();
+
+ /// initialize the invitation service
void initInvitationService(
GlobalKey? navkeyFromApp,
String? webPageFromApp,
@@ -92,7 +94,7 @@ class InvitationService {
// build and fetch self key
AtKey atKey = AtKey()..metadata = Metadata();
atKey.key = '$invitationKey.${receivedInformation.identifier ?? ''}';
- atKey.metadata?.ttr = -1;
+ atKey.metadata.ttr = -1;
var result = await AtClientManager.getInstance().atClient.get(atKey);
MessageShareModel sentInformation =
MessageShareModel.fromJson(jsonDecode(result.value));
@@ -113,6 +115,7 @@ class InvitationService {
}
}
+ /// share message and inviate the atsign provided
Future shareAndinvite(BuildContext context, String jsonData) async {
// create a key and save the json data
var keyID = const Uuid().v4();
@@ -124,7 +127,7 @@ class InvitationService {
AtKey atKey = AtKey()..metadata = Metadata();
atKey.key = '$invitationKey.$keyID';
- atKey.metadata?.ttr = -1;
+ atKey.metadata.ttr = -1;
var result = await AtClientManager.getInstance()
.atClient
.put(atKey, jsonEncode(messageContent))
@@ -146,6 +149,7 @@ class InvitationService {
}
}
+ /// show the OTP dialog and fetch the invite data
Future fetchInviteData(
BuildContext context, String data, String atsign) async {
String otp = await showDialog(
@@ -155,7 +159,7 @@ class InvitationService {
AtKey atKey = AtKey()..metadata = Metadata();
atKey.key = '$invitationAckKey.$data';
atKey.sharedWith = atsign;
- atKey.metadata?.ttr = -1;
+ atKey.metadata.ttr = -1;
MessageShareModel messageContent = MessageShareModel(
passcode: otp, identifier: data, message: 'invite acknowledgement');
await AtClientManager.getInstance()
diff --git a/packages/at_invitation_flutter/lib/utils/init_invitation_service.dart b/packages/at_invitation_flutter/lib/utils/init_invitation_service.dart
index ea8d346d1..5960dd31b 100644
--- a/packages/at_invitation_flutter/lib/utils/init_invitation_service.dart
+++ b/packages/at_invitation_flutter/lib/utils/init_invitation_service.dart
@@ -1,6 +1,8 @@
import 'package:flutter/material.dart';
import 'package:at_invitation_flutter/services/invitation_service.dart';
+
+/// Initialize the invitation service
void initializeInvitationService(
{@required GlobalKey? navkey,
@required String? webPage,
@@ -10,10 +12,12 @@ void initializeInvitationService(
.initInvitationService(navkey, webPage, rootDomain, rootPort);
}
+/// call shareAndInvite method from the invitaion service
void shareAndInvite(BuildContext context, String jsonData) {
InvitationService().shareAndinvite(context, jsonData);
}
+/// call fetchInviteData method from the invitaion service
fetchInviteData(BuildContext context, String data, String atsign) {
InvitationService().fetchInviteData(context, data, atsign);
}
diff --git a/packages/at_invitation_flutter/lib/widgets/otp_dialog.dart b/packages/at_invitation_flutter/lib/widgets/otp_dialog.dart
index 9b675ec44..1ac16d68d 100644
--- a/packages/at_invitation_flutter/lib/widgets/otp_dialog.dart
+++ b/packages/at_invitation_flutter/lib/widgets/otp_dialog.dart
@@ -38,7 +38,7 @@ class _OTPDialogState extends State {
@override
Widget build(BuildContext context) {
SizeConfig().init(context);
- var deviceTextFactor = MediaQuery.of(context).textScaleFactor;
+ var deviceTextFactor = MediaQuery.of(context).textScaler.scale(20) / 20;
return SizedBox(
height: 100.toHeight * deviceTextFactor,
width: 100.toWidth,
diff --git a/packages/at_invitation_flutter/lib/widgets/share_dialog.dart b/packages/at_invitation_flutter/lib/widgets/share_dialog.dart
index 5f96300f0..60fcc02e0 100644
--- a/packages/at_invitation_flutter/lib/widgets/share_dialog.dart
+++ b/packages/at_invitation_flutter/lib/widgets/share_dialog.dart
@@ -51,7 +51,7 @@ class _ShareDialogState extends State {
@override
Widget build(BuildContext context) {
SizeConfig().init(context);
- var deviceTextFactor = MediaQuery.of(context).textScaleFactor;
+ var deviceTextFactor = MediaQuery.of(context).textScaler.scale(20) / 20;
return SizedBox(
height: 100.toHeight * deviceTextFactor,
width: 100.toWidth,
diff --git a/packages/at_invitation_flutter/pubspec.yaml b/packages/at_invitation_flutter/pubspec.yaml
index 549591add..94274bbb8 100644
--- a/packages/at_invitation_flutter/pubspec.yaml
+++ b/packages/at_invitation_flutter/pubspec.yaml
@@ -2,9 +2,9 @@ name: at_invitation_flutter
description: A Flutter package to invite contacts into apps that use atProtocol.
version: 2.0.2
homepage: https://docs.atsign.com/
-repository: https://github.com/atsign-foundation/at_widgets/tree/trunk/at_invitation_flutter
+repository: https://github.com/atsign-foundation/at_widgets/tree/trunk/packages/at_invitation_flutter
issue_tracker: https://github.com/atsign-foundation/at_widgets/issues
-documentation: https://atsign.dev/docs/functional_architecture/libraries/#at_invitation_flutter
+documentation: https://docs.atsign.com/
environment:
sdk: ">=2.15.1 <4.0.0"
@@ -13,15 +13,15 @@ environment:
dependencies:
at_client_mobile: ^3.2.12
at_common_flutter: ^2.0.12
- at_commons: ^3.0.55
+ at_commons: ^4.0.1
at_lookup: ^3.0.40
- at_utils: ^3.0.15
+ at_utils: ^3.0.16
flutter:
sdk: flutter
pin_code_fields: ^8.0.1
- url_launcher: ^6.1.14
- uuid: ^3.0.4
+ url_launcher: ^6.2.4
+ uuid: ^3.0.7
dev_dependencies:
flutter_lints: ^2.0.3