mirror of
https://gitlab.com/veilid/veilidchat.git
synced 2024-10-01 06:55:46 -04:00
scanning
This commit is contained in:
parent
e5f1619c65
commit
752392c02e
@ -12,7 +12,7 @@
|
||||
},
|
||||
"account": {
|
||||
"form_name": "Name",
|
||||
"form_title": "Title (optional)",
|
||||
"form_pronouns": "Pronouns (optional)",
|
||||
"form_lock_type": "Lock Type",
|
||||
"lock_type_none": "none",
|
||||
"lock_type_pin": "pin",
|
||||
@ -23,7 +23,9 @@
|
||||
"header": "Account Profile",
|
||||
"create": "Create",
|
||||
"instructions": "This information will be shared with the people you invite to connect with you on VeilidChat.",
|
||||
"error": "Account creation error"
|
||||
"error": "Account creation error",
|
||||
"name": "Name",
|
||||
"pronouns": "Pronouns"
|
||||
},
|
||||
"button": {
|
||||
"ok": "Ok",
|
||||
@ -101,8 +103,16 @@
|
||||
},
|
||||
"scan_invite_dialog": {
|
||||
"title": "Scan Contact Invite",
|
||||
"scan_invite_here": "Scan your contact invite QR code here:",
|
||||
"scan": "Scan"
|
||||
"instructions": "Position the contact invite QR code in the frame",
|
||||
"scan_qr_here": "Click here to scan a contact invite QR code:",
|
||||
"paste_qr_here": "Camera scanning is only available on mobile devices. You can copy a QR code image and paste it here:",
|
||||
"scan": "Scan",
|
||||
"paste": "Paste",
|
||||
"not_an_image": "Pasted data is not an image",
|
||||
"could_not_decode_image": "Could not decode pasted image",
|
||||
"not_a_valid_qr_code": "Not a valid QR code",
|
||||
"error": "Failed to capture QR code",
|
||||
"permission_error": "Capturing QR codes requires camera permisions. Allow camera permissions for VeilidChat in your settings."
|
||||
},
|
||||
"enter_pin_dialog": {
|
||||
"enter_pin": "Enter PIN",
|
||||
|
@ -37,5 +37,11 @@ end
|
||||
post_install do |installer|
|
||||
installer.pods_project.targets.each do |target|
|
||||
flutter_additional_ios_build_settings(target)
|
||||
target.build_configurations.each do |config|
|
||||
xcconfig_path = config.base_configuration_reference.real_path
|
||||
xcconfig = File.read(xcconfig_path)
|
||||
xcconfig_mod = xcconfig.gsub(/DT_TOOLCHAIN_DIR/, "TOOLCHAIN_DIR")
|
||||
File.open(xcconfig_path, "w") { |file| file << xcconfig_mod }
|
||||
end
|
||||
end
|
||||
end
|
@ -1,11 +1,72 @@
|
||||
PODS:
|
||||
- camera_avfoundation (0.0.1):
|
||||
- Flutter
|
||||
- Flutter (1.0.0)
|
||||
- FMDB (2.7.5):
|
||||
- FMDB/standard (= 2.7.5)
|
||||
- FMDB/standard (2.7.5)
|
||||
- GoogleDataTransport (9.2.5):
|
||||
- GoogleUtilities/Environment (~> 7.7)
|
||||
- nanopb (< 2.30910.0, >= 2.30908.0)
|
||||
- PromisesObjC (< 3.0, >= 1.2)
|
||||
- GoogleMLKit/BarcodeScanning (4.0.0):
|
||||
- GoogleMLKit/MLKitCore
|
||||
- MLKitBarcodeScanning (~> 3.0.0)
|
||||
- GoogleMLKit/MLKitCore (4.0.0):
|
||||
- MLKitCommon (~> 9.0.0)
|
||||
- GoogleToolboxForMac/DebugUtils (2.3.2):
|
||||
- GoogleToolboxForMac/Defines (= 2.3.2)
|
||||
- GoogleToolboxForMac/Defines (2.3.2)
|
||||
- GoogleToolboxForMac/Logger (2.3.2):
|
||||
- GoogleToolboxForMac/Defines (= 2.3.2)
|
||||
- "GoogleToolboxForMac/NSData+zlib (2.3.2)":
|
||||
- GoogleToolboxForMac/Defines (= 2.3.2)
|
||||
- "GoogleToolboxForMac/NSDictionary+URLArguments (2.3.2)":
|
||||
- GoogleToolboxForMac/DebugUtils (= 2.3.2)
|
||||
- GoogleToolboxForMac/Defines (= 2.3.2)
|
||||
- "GoogleToolboxForMac/NSString+URLArguments (= 2.3.2)"
|
||||
- "GoogleToolboxForMac/NSString+URLArguments (2.3.2)"
|
||||
- GoogleUtilities/Environment (7.11.5):
|
||||
- PromisesObjC (< 3.0, >= 1.2)
|
||||
- GoogleUtilities/Logger (7.11.5):
|
||||
- GoogleUtilities/Environment
|
||||
- GoogleUtilities/UserDefaults (7.11.5):
|
||||
- GoogleUtilities/Logger
|
||||
- GoogleUtilitiesComponents (1.1.0):
|
||||
- GoogleUtilities/Logger
|
||||
- GTMSessionFetcher/Core (2.3.0)
|
||||
- MLImage (1.0.0-beta4)
|
||||
- MLKitBarcodeScanning (3.0.0):
|
||||
- MLKitCommon (~> 9.0)
|
||||
- MLKitVision (~> 5.0)
|
||||
- MLKitCommon (9.0.0):
|
||||
- GoogleDataTransport (~> 9.0)
|
||||
- GoogleToolboxForMac/Logger (~> 2.1)
|
||||
- "GoogleToolboxForMac/NSData+zlib (~> 2.1)"
|
||||
- "GoogleToolboxForMac/NSDictionary+URLArguments (~> 2.1)"
|
||||
- GoogleUtilities/UserDefaults (~> 7.0)
|
||||
- GoogleUtilitiesComponents (~> 1.0)
|
||||
- GTMSessionFetcher/Core (< 3.0, >= 1.1)
|
||||
- MLKitVision (5.0.0):
|
||||
- GoogleToolboxForMac/Logger (~> 2.1)
|
||||
- "GoogleToolboxForMac/NSData+zlib (~> 2.1)"
|
||||
- GTMSessionFetcher/Core (< 3.0, >= 1.1)
|
||||
- MLImage (= 1.0.0-beta4)
|
||||
- MLKitCommon (~> 9.0)
|
||||
- mobile_scanner (3.2.0):
|
||||
- Flutter
|
||||
- GoogleMLKit/BarcodeScanning (~> 4.0.0)
|
||||
- nanopb (2.30909.0):
|
||||
- nanopb/decode (= 2.30909.0)
|
||||
- nanopb/encode (= 2.30909.0)
|
||||
- nanopb/decode (2.30909.0)
|
||||
- nanopb/encode (2.30909.0)
|
||||
- pasteboard (0.0.1):
|
||||
- Flutter
|
||||
- path_provider_foundation (0.0.1):
|
||||
- Flutter
|
||||
- FlutterMacOS
|
||||
- PromisesObjC (2.3.1)
|
||||
- share_plus (0.0.1):
|
||||
- Flutter
|
||||
- shared_preferences_foundation (0.0.1):
|
||||
@ -24,7 +85,10 @@ PODS:
|
||||
- Flutter
|
||||
|
||||
DEPENDENCIES:
|
||||
- camera_avfoundation (from `.symlinks/plugins/camera_avfoundation/ios`)
|
||||
- Flutter (from `Flutter`)
|
||||
- mobile_scanner (from `.symlinks/plugins/mobile_scanner/ios`)
|
||||
- pasteboard (from `.symlinks/plugins/pasteboard/ios`)
|
||||
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
|
||||
- share_plus (from `.symlinks/plugins/share_plus/ios`)
|
||||
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
|
||||
@ -37,10 +101,28 @@ DEPENDENCIES:
|
||||
SPEC REPOS:
|
||||
trunk:
|
||||
- FMDB
|
||||
- GoogleDataTransport
|
||||
- GoogleMLKit
|
||||
- GoogleToolboxForMac
|
||||
- GoogleUtilities
|
||||
- GoogleUtilitiesComponents
|
||||
- GTMSessionFetcher
|
||||
- MLImage
|
||||
- MLKitBarcodeScanning
|
||||
- MLKitCommon
|
||||
- MLKitVision
|
||||
- nanopb
|
||||
- PromisesObjC
|
||||
|
||||
EXTERNAL SOURCES:
|
||||
camera_avfoundation:
|
||||
:path: ".symlinks/plugins/camera_avfoundation/ios"
|
||||
Flutter:
|
||||
:path: Flutter
|
||||
mobile_scanner:
|
||||
:path: ".symlinks/plugins/mobile_scanner/ios"
|
||||
pasteboard:
|
||||
:path: ".symlinks/plugins/pasteboard/ios"
|
||||
path_provider_foundation:
|
||||
:path: ".symlinks/plugins/path_provider_foundation/darwin"
|
||||
share_plus:
|
||||
@ -59,9 +141,24 @@ EXTERNAL SOURCES:
|
||||
:path: ".symlinks/plugins/veilid/ios"
|
||||
|
||||
SPEC CHECKSUMS:
|
||||
camera_avfoundation: 3125e8cd1a4387f6f31c6c63abb8a55892a9eeeb
|
||||
Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854
|
||||
FMDB: 2ce00b547f966261cd18927a3ddb07cb6f3db82a
|
||||
GoogleDataTransport: 54dee9d48d14580407f8f5fbf2f496e92437a2f2
|
||||
GoogleMLKit: 2bd0dc6253c4d4f227aad460f69215a504b2980e
|
||||
GoogleToolboxForMac: 8bef7c7c5cf7291c687cf5354f39f9db6399ad34
|
||||
GoogleUtilities: 13e2c67ede716b8741c7989e26893d151b2b2084
|
||||
GoogleUtilitiesComponents: 679b2c881db3b615a2777504623df6122dd20afe
|
||||
GTMSessionFetcher: 3a63d75eecd6aa32c2fc79f578064e1214dfdec2
|
||||
MLImage: 7bb7c4264164ade9bf64f679b40fb29c8f33ee9b
|
||||
MLKitBarcodeScanning: 04e264482c5f3810cb89ebc134ef6b61e67db505
|
||||
MLKitCommon: c1b791c3e667091918d91bda4bba69a91011e390
|
||||
MLKitVision: 8baa5f46ee3352614169b85250574fde38c36f49
|
||||
mobile_scanner: 47056db0c04027ea5f41a716385542da28574662
|
||||
nanopb: b552cce312b6c8484180ef47159bc0f65a1f0431
|
||||
pasteboard: 982969ebaa7c78af3e6cc7761e8f5e77565d9ce0
|
||||
path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943
|
||||
PromisesObjC: c50d2056b5253dadbd6c2bea79b0674bd5a52fa4
|
||||
share_plus: 599aa54e4ea31d4b4c0e9c911bcc26c55e791028
|
||||
shared_preferences_foundation: 5b919d13b803cadd15ed2dc053125c68730e5126
|
||||
smart_auth: 4bedbc118723912d0e45a07e8ab34039c19e04f2
|
||||
@ -70,6 +167,6 @@ SPEC CHECKSUMS:
|
||||
url_launcher_ios: 08a3dfac5fb39e8759aeb0abbd5d9480f30fc8b4
|
||||
veilid: f5c2e662f91907b30cf95762619526ac3e4512fd
|
||||
|
||||
PODFILE CHECKSUM: fcab1959fbc0528061dce4ed4f921740dc46f1e5
|
||||
PODFILE CHECKSUM: 7f4cf2154d55730d953b184299e6feee7a274740
|
||||
|
||||
COCOAPODS: 1.12.1
|
||||
|
@ -49,5 +49,11 @@
|
||||
</array>
|
||||
<key>UIViewControllerBasedStatusBarAppearance</key>
|
||||
<false/>
|
||||
<key>NSCameraUsageDescription</key>
|
||||
<string>Camera is required for QR code scanning and video chat</string>
|
||||
<key>NSMicrophoneUsageDescription</key>
|
||||
<string>Microphone is required for voice chat</string>
|
||||
<key>NSPhotoLibraryUsageDescription</key>
|
||||
<string>Photos access is required to send images and get QR codes from photo library</string>
|
||||
</dict>
|
||||
</plist>
|
||||
|
@ -75,8 +75,8 @@ class ChatSingleContactItemWidget extends ConsumerWidget {
|
||||
title: Text(contact.editedProfile.name),
|
||||
|
||||
/// xxx show last message here
|
||||
subtitle: (contact.editedProfile.title.isNotEmpty)
|
||||
? Text(contact.editedProfile.title)
|
||||
subtitle: (contact.editedProfile.pronouns.isNotEmpty)
|
||||
? Text(contact.editedProfile.pronouns)
|
||||
: null,
|
||||
iconColor: scale.tertiaryScale.background,
|
||||
textColor: scale.tertiaryScale.text,
|
||||
|
@ -59,7 +59,7 @@ class ChatSingleContactListWidget extends ConsumerWidget {
|
||||
return contact.editedProfile.name
|
||||
.toLowerCase()
|
||||
.contains(lowerValue) ||
|
||||
contact.editedProfile.title
|
||||
contact.editedProfile.pronouns
|
||||
.toLowerCase()
|
||||
.contains(lowerValue);
|
||||
}).toList();
|
||||
|
@ -105,8 +105,8 @@ class ContactItemWidget extends ConsumerWidget {
|
||||
// }
|
||||
},
|
||||
title: Text(contact.editedProfile.name),
|
||||
subtitle: (contact.editedProfile.title.isNotEmpty)
|
||||
? Text(contact.editedProfile.title)
|
||||
subtitle: (contact.editedProfile.pronouns.isNotEmpty)
|
||||
? Text(contact.editedProfile.pronouns)
|
||||
: null,
|
||||
iconColor: scale.tertiaryScale.background,
|
||||
textColor: scale.tertiaryScale.text,
|
||||
|
@ -45,7 +45,7 @@ class ContactListWidget extends ConsumerWidget {
|
||||
element.editedProfile.name
|
||||
.toLowerCase()
|
||||
.contains(lowerValue) ||
|
||||
element.editedProfile.title
|
||||
element.editedProfile.pronouns
|
||||
.toLowerCase()
|
||||
.contains(lowerValue))
|
||||
.toList();
|
||||
|
@ -304,14 +304,14 @@ class InviteDialogState extends ConsumerState<InviteDialog> {
|
||||
if (_validInvitation != null && !_isValidating)
|
||||
Column(children: [
|
||||
Container(
|
||||
constraints: const BoxConstraints(maxHeight: 64),
|
||||
width: double.infinity,
|
||||
child: ProfileWidget(
|
||||
name: _validInvitation!
|
||||
.contactRequestPrivate.profile.name,
|
||||
title: _validInvitation!
|
||||
.contactRequestPrivate.profile.title))
|
||||
.paddingLTRB(0, 0, 0, 8),
|
||||
constraints: const BoxConstraints(maxHeight: 64),
|
||||
width: double.infinity,
|
||||
child: ProfileWidget(
|
||||
name: _validInvitation!
|
||||
.contactRequestPrivate.profile.name,
|
||||
pronouns: _validInvitation!
|
||||
.contactRequestPrivate.profile.pronouns,
|
||||
)).paddingLTRB(0, 0, 0, 8),
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
|
||||
children: [
|
||||
|
@ -8,12 +8,12 @@ import '../tools/tools.dart';
|
||||
class ProfileWidget extends ConsumerWidget {
|
||||
const ProfileWidget({
|
||||
required this.name,
|
||||
this.title,
|
||||
this.pronouns,
|
||||
super.key,
|
||||
});
|
||||
|
||||
final String name;
|
||||
final String? title;
|
||||
final String? pronouns;
|
||||
|
||||
@override
|
||||
// ignore: prefer_expression_function_bodies
|
||||
@ -33,8 +33,8 @@ class ProfileWidget extends ConsumerWidget {
|
||||
style: textTheme.headlineSmall,
|
||||
textAlign: TextAlign.left,
|
||||
).paddingAll(4),
|
||||
if (title != null && title!.isNotEmpty)
|
||||
Text(title!, style: textTheme.bodyMedium).paddingLTRB(4, 0, 4, 4),
|
||||
if (pronouns != null && pronouns!.isNotEmpty)
|
||||
Text(pronouns!, style: textTheme.bodyMedium).paddingLTRB(4, 0, 4, 4),
|
||||
]),
|
||||
);
|
||||
}
|
||||
@ -44,6 +44,6 @@ class ProfileWidget extends ConsumerWidget {
|
||||
super.debugFillProperties(properties);
|
||||
properties
|
||||
..add(StringProperty('name', name))
|
||||
..add(StringProperty('title', title));
|
||||
..add(StringProperty('pronouns', pronouns));
|
||||
}
|
||||
}
|
||||
|
@ -1,14 +1,112 @@
|
||||
import 'dart:async';
|
||||
import 'dart:io';
|
||||
import 'dart:math';
|
||||
import 'dart:typed_data';
|
||||
|
||||
import 'package:awesome_extensions/awesome_extensions.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter/scheduler.dart';
|
||||
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
||||
import 'package:flutter_translate/flutter_translate.dart';
|
||||
import 'package:pasteboard/pasteboard.dart';
|
||||
import 'package:zxing2/qrcode.dart';
|
||||
import 'package:mobile_scanner/mobile_scanner.dart';
|
||||
import 'package:image/image.dart' as img;
|
||||
|
||||
import '../tools/tools.dart';
|
||||
import 'invite_dialog.dart';
|
||||
|
||||
class BarcodeOverlay extends CustomPainter {
|
||||
BarcodeOverlay({
|
||||
required this.barcode,
|
||||
required this.arguments,
|
||||
required this.boxFit,
|
||||
required this.capture,
|
||||
});
|
||||
|
||||
final BarcodeCapture capture;
|
||||
final Barcode barcode;
|
||||
final MobileScannerArguments arguments;
|
||||
final BoxFit boxFit;
|
||||
|
||||
@override
|
||||
void paint(Canvas canvas, Size size) {
|
||||
if (barcode.corners == null) {
|
||||
return;
|
||||
}
|
||||
final adjustedSize = applyBoxFit(boxFit, arguments.size, size);
|
||||
|
||||
var verticalPadding = size.height - adjustedSize.destination.height;
|
||||
var horizontalPadding = size.width - adjustedSize.destination.width;
|
||||
if (verticalPadding > 0) {
|
||||
verticalPadding = verticalPadding / 2;
|
||||
} else {
|
||||
verticalPadding = 0;
|
||||
}
|
||||
|
||||
if (horizontalPadding > 0) {
|
||||
horizontalPadding = horizontalPadding / 2;
|
||||
} else {
|
||||
horizontalPadding = 0;
|
||||
}
|
||||
|
||||
final ratioWidth =
|
||||
(Platform.isIOS ? capture.width! : arguments.size.width) /
|
||||
adjustedSize.destination.width;
|
||||
final ratioHeight =
|
||||
(Platform.isIOS ? capture.height! : arguments.size.height) /
|
||||
adjustedSize.destination.height;
|
||||
|
||||
final adjustedOffset = <Offset>[];
|
||||
for (final offset in barcode.corners!) {
|
||||
adjustedOffset.add(
|
||||
Offset(
|
||||
offset.dx / ratioWidth + horizontalPadding,
|
||||
offset.dy / ratioHeight + verticalPadding,
|
||||
),
|
||||
);
|
||||
}
|
||||
final cutoutPath = Path()..addPolygon(adjustedOffset, true);
|
||||
|
||||
final backgroundPaint = Paint()
|
||||
..color = Colors.red.withOpacity(0.3)
|
||||
..style = PaintingStyle.fill
|
||||
..blendMode = BlendMode.dstOut;
|
||||
|
||||
canvas.drawPath(cutoutPath, backgroundPaint);
|
||||
}
|
||||
|
||||
@override
|
||||
bool shouldRepaint(covariant CustomPainter oldDelegate) => false;
|
||||
}
|
||||
|
||||
class ScannerOverlay extends CustomPainter {
|
||||
ScannerOverlay(this.scanWindow);
|
||||
|
||||
final Rect scanWindow;
|
||||
|
||||
@override
|
||||
void paint(Canvas canvas, Size size) {
|
||||
final backgroundPath = Path()..addRect(Rect.largest);
|
||||
final cutoutPath = Path()..addRect(scanWindow);
|
||||
|
||||
final backgroundPaint = Paint()
|
||||
..color = Colors.black.withOpacity(0.5)
|
||||
..style = PaintingStyle.fill
|
||||
..blendMode = BlendMode.dstOut;
|
||||
|
||||
final backgroundWithCutout = Path.combine(
|
||||
PathOperation.difference,
|
||||
backgroundPath,
|
||||
cutoutPath,
|
||||
);
|
||||
canvas.drawPath(backgroundWithCutout, backgroundPaint);
|
||||
}
|
||||
|
||||
@override
|
||||
bool shouldRepaint(covariant CustomPainter oldDelegate) => false;
|
||||
}
|
||||
|
||||
class ScanInviteDialog extends ConsumerStatefulWidget {
|
||||
const ScanInviteDialog({super.key});
|
||||
|
||||
@ -24,53 +122,204 @@ class ScanInviteDialog extends ConsumerStatefulWidget {
|
||||
}
|
||||
|
||||
class ScanInviteDialogState extends ConsumerState<ScanInviteDialog> {
|
||||
// final _pasteTextController = TextEditingController();
|
||||
bool scanned = false;
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
}
|
||||
|
||||
// Future<void> _onPasteChanged(
|
||||
// String text,
|
||||
// Future<void> Function({
|
||||
// required Uint8List inviteData,
|
||||
// }) validateInviteData) async {
|
||||
// final lines = text.split('\n');
|
||||
// if (lines.isEmpty) {
|
||||
// return;
|
||||
// }
|
||||
|
||||
// var firstline =
|
||||
// lines.indexWhere((element) => element.contains('BEGIN VEILIDCHAT'));
|
||||
// firstline += 1;
|
||||
|
||||
// var lastline =
|
||||
// lines.indexWhere((element) => element.contains('END VEILIDCHAT'));
|
||||
// if (lastline == -1) {
|
||||
// lastline = lines.length;
|
||||
// }
|
||||
// if (lastline <= firstline) {
|
||||
// return;
|
||||
// }
|
||||
// final inviteDataBase64 = lines.sublist(firstline, lastline).join();
|
||||
// final inviteData = base64UrlNoPadDecode(inviteDataBase64);
|
||||
|
||||
// await validateInviteData(inviteData: inviteData);
|
||||
// }
|
||||
|
||||
void onValidationCancelled() {
|
||||
// _pasteTextController.clear();
|
||||
setState(() {
|
||||
scanned = false;
|
||||
});
|
||||
}
|
||||
|
||||
void onValidationSuccess() {
|
||||
//_pasteTextController.clear();
|
||||
}
|
||||
void onValidationSuccess() {}
|
||||
void onValidationFailed() {
|
||||
//_pasteTextController.clear();
|
||||
setState(() {
|
||||
scanned = false;
|
||||
});
|
||||
}
|
||||
|
||||
bool inviteControlIsValid() => false; // _pasteTextController.text.isNotEmpty;
|
||||
|
||||
Future<Uint8List?> scanQRImage(BuildContext context) async {
|
||||
final theme = Theme.of(context);
|
||||
//final textTheme = theme.textTheme;
|
||||
final scale = theme.extension<ScaleScheme>()!;
|
||||
final windowSize = MediaQuery.of(context).size;
|
||||
//final maxDialogWidth = min(windowSize.width - 64.0, 800.0 - 64.0);
|
||||
//final maxDialogHeight = windowSize.height - 64.0;
|
||||
|
||||
final scanWindow = Rect.fromCenter(
|
||||
center: MediaQuery.of(context).size.center(Offset.zero),
|
||||
width: 200,
|
||||
height: 200,
|
||||
);
|
||||
|
||||
final cameraController = MobileScannerController();
|
||||
try {
|
||||
return showDialog(
|
||||
context: context,
|
||||
builder: (context) => Stack(
|
||||
fit: StackFit.expand,
|
||||
children: [
|
||||
MobileScanner(
|
||||
fit: BoxFit.contain,
|
||||
scanWindow: scanWindow,
|
||||
controller: cameraController,
|
||||
errorBuilder: (context, error, child) =>
|
||||
ScannerErrorWidget(error: error),
|
||||
onDetect: (c) {
|
||||
final barcode = c.barcodes.firstOrNull;
|
||||
|
||||
final barcodeBytes = barcode?.rawBytes;
|
||||
if (barcodeBytes != null) {
|
||||
cameraController.dispose();
|
||||
Navigator.pop(context, barcodeBytes);
|
||||
}
|
||||
}),
|
||||
CustomPaint(
|
||||
painter: ScannerOverlay(scanWindow),
|
||||
),
|
||||
Align(
|
||||
alignment: Alignment.bottomCenter,
|
||||
child: Container(
|
||||
alignment: Alignment.bottomCenter,
|
||||
height: 100,
|
||||
color: Colors.black.withOpacity(0.4),
|
||||
child: Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
|
||||
children: [
|
||||
IconButton(
|
||||
color: Colors.white,
|
||||
icon: ValueListenableBuilder(
|
||||
valueListenable: cameraController.torchState,
|
||||
builder: (context, state, child) {
|
||||
switch (state) {
|
||||
case TorchState.off:
|
||||
return Icon(Icons.flash_off,
|
||||
color:
|
||||
scale.grayScale.subtleBackground);
|
||||
case TorchState.on:
|
||||
return Icon(Icons.flash_on,
|
||||
color: scale.primaryScale.background);
|
||||
}
|
||||
},
|
||||
),
|
||||
iconSize: 32,
|
||||
onPressed: cameraController.toggleTorch,
|
||||
),
|
||||
SizedBox(
|
||||
width: windowSize.width - 120,
|
||||
height: 50,
|
||||
child: FittedBox(
|
||||
child: Text(
|
||||
translate('scan_invite_dialog.instructions'),
|
||||
overflow: TextOverflow.fade,
|
||||
style: Theme.of(context)
|
||||
.textTheme
|
||||
.labelLarge!
|
||||
.copyWith(color: Colors.white),
|
||||
),
|
||||
),
|
||||
),
|
||||
IconButton(
|
||||
color: Colors.white,
|
||||
icon: ValueListenableBuilder(
|
||||
valueListenable:
|
||||
cameraController.cameraFacingState,
|
||||
builder: (context, state, child) {
|
||||
switch (state) {
|
||||
case CameraFacing.front:
|
||||
return const Icon(Icons.camera_front);
|
||||
case CameraFacing.back:
|
||||
return const Icon(Icons.camera_rear);
|
||||
}
|
||||
},
|
||||
),
|
||||
iconSize: 32,
|
||||
onPressed: cameraController.switchCamera,
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
),
|
||||
Align(
|
||||
alignment: Alignment.topRight,
|
||||
child: IconButton(
|
||||
color: Colors.white,
|
||||
icon: Icon(Icons.close,
|
||||
color: scale.grayScale.background),
|
||||
iconSize: 32,
|
||||
onPressed: () => {
|
||||
SchedulerBinding.instance
|
||||
.addPostFrameCallback((_) {
|
||||
cameraController.dispose();
|
||||
Navigator.pop(context, null);
|
||||
})
|
||||
})),
|
||||
],
|
||||
));
|
||||
} on MobileScannerException catch (e) {
|
||||
if (e.errorCode == MobileScannerErrorCode.permissionDenied) {
|
||||
showErrorToast(
|
||||
context, translate('scan_invite_dialog.permission_error'));
|
||||
} else {
|
||||
showErrorToast(context, translate('scan_invite_dialog.error'));
|
||||
}
|
||||
} on Exception catch (_) {
|
||||
showErrorToast(context, translate('scan_invite_dialog.error'));
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
Future<Uint8List?> pasteQRImage(BuildContext context) async {
|
||||
final imageBytes = await Pasteboard.image;
|
||||
if (imageBytes == null) {
|
||||
if (context.mounted) {
|
||||
showErrorToast(context, translate('scan_invite_dialog.not_an_image'));
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
final image = img.decodeImage(imageBytes);
|
||||
if (image == null) {
|
||||
if (context.mounted) {
|
||||
showErrorToast(
|
||||
context, translate('scan_invite_dialog.could_not_decode_image'));
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
try {
|
||||
final source = RGBLuminanceSource(
|
||||
image.width,
|
||||
image.height,
|
||||
image
|
||||
.convert(numChannels: 4)
|
||||
.getBytes(order: img.ChannelOrder.abgr)
|
||||
.buffer
|
||||
.asInt32List());
|
||||
final bitmap = BinaryBitmap(HybridBinarizer(source));
|
||||
|
||||
final reader = QRCodeReader();
|
||||
final result = reader.decode(bitmap);
|
||||
|
||||
final segs = result.resultMetadata[ResultMetadataType.byteSegments]!
|
||||
as List<Int8List>;
|
||||
return Uint8List.fromList(segs[0].toList());
|
||||
} on Exception catch (_) {
|
||||
if (context.mounted) {
|
||||
showErrorToast(
|
||||
context, translate('scan_invite_dialog.not_a_valid_qr_code'));
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
Widget buildInviteControl(
|
||||
BuildContext context,
|
||||
InviteDialogState dialogState,
|
||||
@ -78,31 +327,56 @@ class ScanInviteDialogState extends ConsumerState<ScanInviteDialog> {
|
||||
validateInviteData) {
|
||||
final theme = Theme.of(context);
|
||||
//final scale = theme.extension<ScaleScheme>()!;
|
||||
final textTheme = theme.textTheme;
|
||||
//final textTheme = theme.textTheme;
|
||||
//final height = MediaQuery.of(context).size.height;
|
||||
|
||||
if (isiOS || isAndroid) {
|
||||
return Column(mainAxisSize: MainAxisSize.min, children: [
|
||||
if (!scanned)
|
||||
Text(
|
||||
translate('scan_invite_dialog.scan_qr_here'),
|
||||
).paddingLTRB(0, 0, 0, 8),
|
||||
if (!scanned)
|
||||
Container(
|
||||
constraints: const BoxConstraints(maxHeight: 200),
|
||||
child: ElevatedButton(
|
||||
onPressed: dialogState.isValidating
|
||||
? null
|
||||
: () async {
|
||||
final inviteData = await scanQRImage(context);
|
||||
if (inviteData != null) {
|
||||
setState(() {
|
||||
scanned = true;
|
||||
});
|
||||
await validateInviteData(inviteData: inviteData);
|
||||
}
|
||||
},
|
||||
child: Text(translate('scan_invite_dialog.scan'))),
|
||||
).paddingLTRB(0, 0, 0, 8)
|
||||
]);
|
||||
}
|
||||
return Column(mainAxisSize: MainAxisSize.min, children: [
|
||||
Text(
|
||||
translate('scan_invite_dialog.scan_invite_here'),
|
||||
).paddingLTRB(0, 0, 0, 8),
|
||||
// Container(
|
||||
// constraints: const BoxConstraints(maxHeight: 200),
|
||||
// child: TextField(
|
||||
// enabled: !dialogState.isValidating,
|
||||
// onChanged: (text) => _onPasteChanged(text, validateInviteData),
|
||||
// style: textTheme.labelSmall!
|
||||
// .copyWith(fontFamily: 'Victor Mono', fontSize: 11),
|
||||
// keyboardType: TextInputType.multiline,
|
||||
// maxLines: null,
|
||||
// controller: _pasteTextController,
|
||||
// decoration: const InputDecoration(
|
||||
// border: OutlineInputBorder(),
|
||||
// hintText: '--- BEGIN VEILIDCHAT CONTACT INVITE ----\n'
|
||||
// 'XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX\n'
|
||||
// '---- END VEILIDCHAT CONTACT INVITE -----\n',
|
||||
// //labelText: translate('paste_invite_dialog.paste')
|
||||
// ),
|
||||
// )).paddingLTRB(0, 0, 0, 8)
|
||||
if (!scanned)
|
||||
Text(
|
||||
translate('scan_invite_dialog.paste_qr_here'),
|
||||
).paddingLTRB(0, 0, 0, 8),
|
||||
if (!scanned)
|
||||
Container(
|
||||
constraints: const BoxConstraints(maxHeight: 200),
|
||||
child: ElevatedButton(
|
||||
onPressed: dialogState.isValidating
|
||||
? null
|
||||
: () async {
|
||||
final inviteData = await pasteQRImage(context);
|
||||
if (inviteData != null) {
|
||||
setState(() {
|
||||
scanned = true;
|
||||
});
|
||||
await validateInviteData(inviteData: inviteData);
|
||||
}
|
||||
},
|
||||
child: Text(translate('scan_invite_dialog.paste'))),
|
||||
).paddingLTRB(0, 0, 0, 8)
|
||||
]);
|
||||
}
|
||||
|
||||
|
@ -117,11 +117,11 @@ class _$LocalAccountCopyWithImpl<$Res, $Val extends LocalAccount>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_LocalAccountCopyWith<$Res>
|
||||
abstract class _$$LocalAccountImplCopyWith<$Res>
|
||||
implements $LocalAccountCopyWith<$Res> {
|
||||
factory _$$_LocalAccountCopyWith(
|
||||
_$_LocalAccount value, $Res Function(_$_LocalAccount) then) =
|
||||
__$$_LocalAccountCopyWithImpl<$Res>;
|
||||
factory _$$LocalAccountImplCopyWith(
|
||||
_$LocalAccountImpl value, $Res Function(_$LocalAccountImpl) then) =
|
||||
__$$LocalAccountImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call(
|
||||
@ -137,11 +137,11 @@ abstract class _$$_LocalAccountCopyWith<$Res>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_LocalAccountCopyWithImpl<$Res>
|
||||
extends _$LocalAccountCopyWithImpl<$Res, _$_LocalAccount>
|
||||
implements _$$_LocalAccountCopyWith<$Res> {
|
||||
__$$_LocalAccountCopyWithImpl(
|
||||
_$_LocalAccount _value, $Res Function(_$_LocalAccount) _then)
|
||||
class __$$LocalAccountImplCopyWithImpl<$Res>
|
||||
extends _$LocalAccountCopyWithImpl<$Res, _$LocalAccountImpl>
|
||||
implements _$$LocalAccountImplCopyWith<$Res> {
|
||||
__$$LocalAccountImplCopyWithImpl(
|
||||
_$LocalAccountImpl _value, $Res Function(_$LocalAccountImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -154,7 +154,7 @@ class __$$_LocalAccountCopyWithImpl<$Res>
|
||||
Object? hiddenAccount = null,
|
||||
Object? name = null,
|
||||
}) {
|
||||
return _then(_$_LocalAccount(
|
||||
return _then(_$LocalAccountImpl(
|
||||
identityMaster: null == identityMaster
|
||||
? _value.identityMaster
|
||||
: identityMaster // ignore: cast_nullable_to_non_nullable
|
||||
@ -185,8 +185,8 @@ class __$$_LocalAccountCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_LocalAccount implements _LocalAccount {
|
||||
const _$_LocalAccount(
|
||||
class _$LocalAccountImpl implements _LocalAccount {
|
||||
const _$LocalAccountImpl(
|
||||
{required this.identityMaster,
|
||||
@Uint8ListJsonConverter() required this.identitySecretBytes,
|
||||
required this.encryptionKeyType,
|
||||
@ -194,8 +194,8 @@ class _$_LocalAccount implements _LocalAccount {
|
||||
required this.hiddenAccount,
|
||||
required this.name});
|
||||
|
||||
factory _$_LocalAccount.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_LocalAccountFromJson(json);
|
||||
factory _$LocalAccountImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$LocalAccountImplFromJson(json);
|
||||
|
||||
// The master key record for the account, containing the identityPublicKey
|
||||
@override
|
||||
@ -228,7 +228,7 @@ class _$_LocalAccount implements _LocalAccount {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_LocalAccount &&
|
||||
other is _$LocalAccountImpl &&
|
||||
(identical(other.identityMaster, identityMaster) ||
|
||||
other.identityMaster == identityMaster) &&
|
||||
const DeepCollectionEquality()
|
||||
@ -256,12 +256,12 @@ class _$_LocalAccount implements _LocalAccount {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_LocalAccountCopyWith<_$_LocalAccount> get copyWith =>
|
||||
__$$_LocalAccountCopyWithImpl<_$_LocalAccount>(this, _$identity);
|
||||
_$$LocalAccountImplCopyWith<_$LocalAccountImpl> get copyWith =>
|
||||
__$$LocalAccountImplCopyWithImpl<_$LocalAccountImpl>(this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_LocalAccountToJson(
|
||||
return _$$LocalAccountImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -274,10 +274,10 @@ abstract class _LocalAccount implements LocalAccount {
|
||||
required final EncryptionKeyType encryptionKeyType,
|
||||
required final bool biometricsEnabled,
|
||||
required final bool hiddenAccount,
|
||||
required final String name}) = _$_LocalAccount;
|
||||
required final String name}) = _$LocalAccountImpl;
|
||||
|
||||
factory _LocalAccount.fromJson(Map<String, dynamic> json) =
|
||||
_$_LocalAccount.fromJson;
|
||||
_$LocalAccountImpl.fromJson;
|
||||
|
||||
@override // The master key record for the account, containing the identityPublicKey
|
||||
IdentityMaster get identityMaster;
|
||||
@ -296,6 +296,6 @@ abstract class _LocalAccount implements LocalAccount {
|
||||
String get name;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_LocalAccountCopyWith<_$_LocalAccount> get copyWith =>
|
||||
_$$LocalAccountImplCopyWith<_$LocalAccountImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
}
|
||||
|
@ -6,8 +6,8 @@ part of 'local_account.dart';
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
_$_LocalAccount _$$_LocalAccountFromJson(Map<String, dynamic> json) =>
|
||||
_$_LocalAccount(
|
||||
_$LocalAccountImpl _$$LocalAccountImplFromJson(Map<String, dynamic> json) =>
|
||||
_$LocalAccountImpl(
|
||||
identityMaster: IdentityMaster.fromJson(json['identity_master']),
|
||||
identitySecretBytes: const Uint8ListJsonConverter()
|
||||
.fromJson(json['identity_secret_bytes'] as String),
|
||||
@ -18,7 +18,7 @@ _$_LocalAccount _$$_LocalAccountFromJson(Map<String, dynamic> json) =>
|
||||
name: json['name'] as String,
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_LocalAccountToJson(_$_LocalAccount instance) =>
|
||||
Map<String, dynamic> _$$LocalAccountImplToJson(_$LocalAccountImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'identity_master': instance.identityMaster.toJson(),
|
||||
'identity_secret_bytes':
|
||||
|
@ -77,11 +77,11 @@ class _$LockPreferenceCopyWithImpl<$Res, $Val extends LockPreference>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_LockPreferenceCopyWith<$Res>
|
||||
abstract class _$$LockPreferenceImplCopyWith<$Res>
|
||||
implements $LockPreferenceCopyWith<$Res> {
|
||||
factory _$$_LockPreferenceCopyWith(
|
||||
_$_LockPreference value, $Res Function(_$_LockPreference) then) =
|
||||
__$$_LockPreferenceCopyWithImpl<$Res>;
|
||||
factory _$$LockPreferenceImplCopyWith(_$LockPreferenceImpl value,
|
||||
$Res Function(_$LockPreferenceImpl) then) =
|
||||
__$$LockPreferenceImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call(
|
||||
@ -91,11 +91,11 @@ abstract class _$$_LockPreferenceCopyWith<$Res>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_LockPreferenceCopyWithImpl<$Res>
|
||||
extends _$LockPreferenceCopyWithImpl<$Res, _$_LockPreference>
|
||||
implements _$$_LockPreferenceCopyWith<$Res> {
|
||||
__$$_LockPreferenceCopyWithImpl(
|
||||
_$_LockPreference _value, $Res Function(_$_LockPreference) _then)
|
||||
class __$$LockPreferenceImplCopyWithImpl<$Res>
|
||||
extends _$LockPreferenceCopyWithImpl<$Res, _$LockPreferenceImpl>
|
||||
implements _$$LockPreferenceImplCopyWith<$Res> {
|
||||
__$$LockPreferenceImplCopyWithImpl(
|
||||
_$LockPreferenceImpl _value, $Res Function(_$LockPreferenceImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -105,7 +105,7 @@ class __$$_LockPreferenceCopyWithImpl<$Res>
|
||||
Object? lockWhenSwitching = null,
|
||||
Object? lockWithSystemLock = null,
|
||||
}) {
|
||||
return _then(_$_LockPreference(
|
||||
return _then(_$LockPreferenceImpl(
|
||||
inactivityLockSecs: null == inactivityLockSecs
|
||||
? _value.inactivityLockSecs
|
||||
: inactivityLockSecs // ignore: cast_nullable_to_non_nullable
|
||||
@ -124,14 +124,14 @@ class __$$_LockPreferenceCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_LockPreference implements _LockPreference {
|
||||
const _$_LockPreference(
|
||||
class _$LockPreferenceImpl implements _LockPreference {
|
||||
const _$LockPreferenceImpl(
|
||||
{required this.inactivityLockSecs,
|
||||
required this.lockWhenSwitching,
|
||||
required this.lockWithSystemLock});
|
||||
|
||||
factory _$_LockPreference.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_LockPreferenceFromJson(json);
|
||||
factory _$LockPreferenceImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$LockPreferenceImplFromJson(json);
|
||||
|
||||
@override
|
||||
final int inactivityLockSecs;
|
||||
@ -149,7 +149,7 @@ class _$_LockPreference implements _LockPreference {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_LockPreference &&
|
||||
other is _$LockPreferenceImpl &&
|
||||
(identical(other.inactivityLockSecs, inactivityLockSecs) ||
|
||||
other.inactivityLockSecs == inactivityLockSecs) &&
|
||||
(identical(other.lockWhenSwitching, lockWhenSwitching) ||
|
||||
@ -166,12 +166,13 @@ class _$_LockPreference implements _LockPreference {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_LockPreferenceCopyWith<_$_LockPreference> get copyWith =>
|
||||
__$$_LockPreferenceCopyWithImpl<_$_LockPreference>(this, _$identity);
|
||||
_$$LockPreferenceImplCopyWith<_$LockPreferenceImpl> get copyWith =>
|
||||
__$$LockPreferenceImplCopyWithImpl<_$LockPreferenceImpl>(
|
||||
this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_LockPreferenceToJson(
|
||||
return _$$LockPreferenceImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -181,10 +182,10 @@ abstract class _LockPreference implements LockPreference {
|
||||
const factory _LockPreference(
|
||||
{required final int inactivityLockSecs,
|
||||
required final bool lockWhenSwitching,
|
||||
required final bool lockWithSystemLock}) = _$_LockPreference;
|
||||
required final bool lockWithSystemLock}) = _$LockPreferenceImpl;
|
||||
|
||||
factory _LockPreference.fromJson(Map<String, dynamic> json) =
|
||||
_$_LockPreference.fromJson;
|
||||
_$LockPreferenceImpl.fromJson;
|
||||
|
||||
@override
|
||||
int get inactivityLockSecs;
|
||||
@ -194,7 +195,7 @@ abstract class _LockPreference implements LockPreference {
|
||||
bool get lockWithSystemLock;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_LockPreferenceCopyWith<_$_LockPreference> get copyWith =>
|
||||
_$$LockPreferenceImplCopyWith<_$LockPreferenceImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
}
|
||||
|
||||
@ -262,11 +263,11 @@ class _$ThemePreferencesCopyWithImpl<$Res, $Val extends ThemePreferences>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_ThemePreferencesCopyWith<$Res>
|
||||
abstract class _$$ThemePreferencesImplCopyWith<$Res>
|
||||
implements $ThemePreferencesCopyWith<$Res> {
|
||||
factory _$$_ThemePreferencesCopyWith(
|
||||
_$_ThemePreferences value, $Res Function(_$_ThemePreferences) then) =
|
||||
__$$_ThemePreferencesCopyWithImpl<$Res>;
|
||||
factory _$$ThemePreferencesImplCopyWith(_$ThemePreferencesImpl value,
|
||||
$Res Function(_$ThemePreferencesImpl) then) =
|
||||
__$$ThemePreferencesImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call(
|
||||
@ -276,11 +277,11 @@ abstract class _$$_ThemePreferencesCopyWith<$Res>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_ThemePreferencesCopyWithImpl<$Res>
|
||||
extends _$ThemePreferencesCopyWithImpl<$Res, _$_ThemePreferences>
|
||||
implements _$$_ThemePreferencesCopyWith<$Res> {
|
||||
__$$_ThemePreferencesCopyWithImpl(
|
||||
_$_ThemePreferences _value, $Res Function(_$_ThemePreferences) _then)
|
||||
class __$$ThemePreferencesImplCopyWithImpl<$Res>
|
||||
extends _$ThemePreferencesCopyWithImpl<$Res, _$ThemePreferencesImpl>
|
||||
implements _$$ThemePreferencesImplCopyWith<$Res> {
|
||||
__$$ThemePreferencesImplCopyWithImpl(_$ThemePreferencesImpl _value,
|
||||
$Res Function(_$ThemePreferencesImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -290,7 +291,7 @@ class __$$_ThemePreferencesCopyWithImpl<$Res>
|
||||
Object? colorPreference = null,
|
||||
Object? displayScale = null,
|
||||
}) {
|
||||
return _then(_$_ThemePreferences(
|
||||
return _then(_$ThemePreferencesImpl(
|
||||
brightnessPreference: null == brightnessPreference
|
||||
? _value.brightnessPreference
|
||||
: brightnessPreference // ignore: cast_nullable_to_non_nullable
|
||||
@ -309,14 +310,14 @@ class __$$_ThemePreferencesCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_ThemePreferences implements _ThemePreferences {
|
||||
const _$_ThemePreferences(
|
||||
class _$ThemePreferencesImpl implements _ThemePreferences {
|
||||
const _$ThemePreferencesImpl(
|
||||
{required this.brightnessPreference,
|
||||
required this.colorPreference,
|
||||
required this.displayScale});
|
||||
|
||||
factory _$_ThemePreferences.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_ThemePreferencesFromJson(json);
|
||||
factory _$ThemePreferencesImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$ThemePreferencesImplFromJson(json);
|
||||
|
||||
@override
|
||||
final BrightnessPreference brightnessPreference;
|
||||
@ -334,7 +335,7 @@ class _$_ThemePreferences implements _ThemePreferences {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_ThemePreferences &&
|
||||
other is _$ThemePreferencesImpl &&
|
||||
(identical(other.brightnessPreference, brightnessPreference) ||
|
||||
other.brightnessPreference == brightnessPreference) &&
|
||||
(identical(other.colorPreference, colorPreference) ||
|
||||
@ -351,12 +352,13 @@ class _$_ThemePreferences implements _ThemePreferences {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_ThemePreferencesCopyWith<_$_ThemePreferences> get copyWith =>
|
||||
__$$_ThemePreferencesCopyWithImpl<_$_ThemePreferences>(this, _$identity);
|
||||
_$$ThemePreferencesImplCopyWith<_$ThemePreferencesImpl> get copyWith =>
|
||||
__$$ThemePreferencesImplCopyWithImpl<_$ThemePreferencesImpl>(
|
||||
this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_ThemePreferencesToJson(
|
||||
return _$$ThemePreferencesImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -366,10 +368,10 @@ abstract class _ThemePreferences implements ThemePreferences {
|
||||
const factory _ThemePreferences(
|
||||
{required final BrightnessPreference brightnessPreference,
|
||||
required final ColorPreference colorPreference,
|
||||
required final double displayScale}) = _$_ThemePreferences;
|
||||
required final double displayScale}) = _$ThemePreferencesImpl;
|
||||
|
||||
factory _ThemePreferences.fromJson(Map<String, dynamic> json) =
|
||||
_$_ThemePreferences.fromJson;
|
||||
_$ThemePreferencesImpl.fromJson;
|
||||
|
||||
@override
|
||||
BrightnessPreference get brightnessPreference;
|
||||
@ -379,7 +381,7 @@ abstract class _ThemePreferences implements ThemePreferences {
|
||||
double get displayScale;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_ThemePreferencesCopyWith<_$_ThemePreferences> get copyWith =>
|
||||
_$$ThemePreferencesImplCopyWith<_$ThemePreferencesImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
}
|
||||
|
||||
@ -465,11 +467,11 @@ class _$PreferencesCopyWithImpl<$Res, $Val extends Preferences>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_PreferencesCopyWith<$Res>
|
||||
abstract class _$$PreferencesImplCopyWith<$Res>
|
||||
implements $PreferencesCopyWith<$Res> {
|
||||
factory _$$_PreferencesCopyWith(
|
||||
_$_Preferences value, $Res Function(_$_Preferences) then) =
|
||||
__$$_PreferencesCopyWithImpl<$Res>;
|
||||
factory _$$PreferencesImplCopyWith(
|
||||
_$PreferencesImpl value, $Res Function(_$PreferencesImpl) then) =
|
||||
__$$PreferencesImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call(
|
||||
@ -484,11 +486,11 @@ abstract class _$$_PreferencesCopyWith<$Res>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_PreferencesCopyWithImpl<$Res>
|
||||
extends _$PreferencesCopyWithImpl<$Res, _$_Preferences>
|
||||
implements _$$_PreferencesCopyWith<$Res> {
|
||||
__$$_PreferencesCopyWithImpl(
|
||||
_$_Preferences _value, $Res Function(_$_Preferences) _then)
|
||||
class __$$PreferencesImplCopyWithImpl<$Res>
|
||||
extends _$PreferencesCopyWithImpl<$Res, _$PreferencesImpl>
|
||||
implements _$$PreferencesImplCopyWith<$Res> {
|
||||
__$$PreferencesImplCopyWithImpl(
|
||||
_$PreferencesImpl _value, $Res Function(_$PreferencesImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -498,7 +500,7 @@ class __$$_PreferencesCopyWithImpl<$Res>
|
||||
Object? language = null,
|
||||
Object? locking = null,
|
||||
}) {
|
||||
return _then(_$_Preferences(
|
||||
return _then(_$PreferencesImpl(
|
||||
themePreferences: null == themePreferences
|
||||
? _value.themePreferences
|
||||
: themePreferences // ignore: cast_nullable_to_non_nullable
|
||||
@ -517,14 +519,14 @@ class __$$_PreferencesCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_Preferences implements _Preferences {
|
||||
const _$_Preferences(
|
||||
class _$PreferencesImpl implements _Preferences {
|
||||
const _$PreferencesImpl(
|
||||
{required this.themePreferences,
|
||||
required this.language,
|
||||
required this.locking});
|
||||
|
||||
factory _$_Preferences.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_PreferencesFromJson(json);
|
||||
factory _$PreferencesImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$PreferencesImplFromJson(json);
|
||||
|
||||
@override
|
||||
final ThemePreferences themePreferences;
|
||||
@ -542,7 +544,7 @@ class _$_Preferences implements _Preferences {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_Preferences &&
|
||||
other is _$PreferencesImpl &&
|
||||
(identical(other.themePreferences, themePreferences) ||
|
||||
other.themePreferences == themePreferences) &&
|
||||
(identical(other.language, language) ||
|
||||
@ -558,12 +560,12 @@ class _$_Preferences implements _Preferences {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_PreferencesCopyWith<_$_Preferences> get copyWith =>
|
||||
__$$_PreferencesCopyWithImpl<_$_Preferences>(this, _$identity);
|
||||
_$$PreferencesImplCopyWith<_$PreferencesImpl> get copyWith =>
|
||||
__$$PreferencesImplCopyWithImpl<_$PreferencesImpl>(this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_PreferencesToJson(
|
||||
return _$$PreferencesImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -573,10 +575,10 @@ abstract class _Preferences implements Preferences {
|
||||
const factory _Preferences(
|
||||
{required final ThemePreferences themePreferences,
|
||||
required final LanguagePreference language,
|
||||
required final LockPreference locking}) = _$_Preferences;
|
||||
required final LockPreference locking}) = _$PreferencesImpl;
|
||||
|
||||
factory _Preferences.fromJson(Map<String, dynamic> json) =
|
||||
_$_Preferences.fromJson;
|
||||
_$PreferencesImpl.fromJson;
|
||||
|
||||
@override
|
||||
ThemePreferences get themePreferences;
|
||||
@ -586,6 +588,6 @@ abstract class _Preferences implements Preferences {
|
||||
LockPreference get locking;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_PreferencesCopyWith<_$_Preferences> get copyWith =>
|
||||
_$$PreferencesImplCopyWith<_$PreferencesImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
}
|
||||
|
@ -6,43 +6,46 @@ part of 'preferences.dart';
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
_$_LockPreference _$$_LockPreferenceFromJson(Map<String, dynamic> json) =>
|
||||
_$_LockPreference(
|
||||
_$LockPreferenceImpl _$$LockPreferenceImplFromJson(Map<String, dynamic> json) =>
|
||||
_$LockPreferenceImpl(
|
||||
inactivityLockSecs: json['inactivity_lock_secs'] as int,
|
||||
lockWhenSwitching: json['lock_when_switching'] as bool,
|
||||
lockWithSystemLock: json['lock_with_system_lock'] as bool,
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_LockPreferenceToJson(_$_LockPreference instance) =>
|
||||
Map<String, dynamic> _$$LockPreferenceImplToJson(
|
||||
_$LockPreferenceImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'inactivity_lock_secs': instance.inactivityLockSecs,
|
||||
'lock_when_switching': instance.lockWhenSwitching,
|
||||
'lock_with_system_lock': instance.lockWithSystemLock,
|
||||
};
|
||||
|
||||
_$_ThemePreferences _$$_ThemePreferencesFromJson(Map<String, dynamic> json) =>
|
||||
_$_ThemePreferences(
|
||||
_$ThemePreferencesImpl _$$ThemePreferencesImplFromJson(
|
||||
Map<String, dynamic> json) =>
|
||||
_$ThemePreferencesImpl(
|
||||
brightnessPreference:
|
||||
BrightnessPreference.fromJson(json['brightness_preference']),
|
||||
colorPreference: ColorPreference.fromJson(json['color_preference']),
|
||||
displayScale: (json['display_scale'] as num).toDouble(),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_ThemePreferencesToJson(_$_ThemePreferences instance) =>
|
||||
Map<String, dynamic> _$$ThemePreferencesImplToJson(
|
||||
_$ThemePreferencesImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'brightness_preference': instance.brightnessPreference.toJson(),
|
||||
'color_preference': instance.colorPreference.toJson(),
|
||||
'display_scale': instance.displayScale,
|
||||
};
|
||||
|
||||
_$_Preferences _$$_PreferencesFromJson(Map<String, dynamic> json) =>
|
||||
_$_Preferences(
|
||||
_$PreferencesImpl _$$PreferencesImplFromJson(Map<String, dynamic> json) =>
|
||||
_$PreferencesImpl(
|
||||
themePreferences: ThemePreferences.fromJson(json['theme_preferences']),
|
||||
language: LanguagePreference.fromJson(json['language']),
|
||||
locking: LockPreference.fromJson(json['locking']),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_PreferencesToJson(_$_Preferences instance) =>
|
||||
Map<String, dynamic> _$$PreferencesImplToJson(_$PreferencesImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'theme_preferences': instance.themePreferences.toJson(),
|
||||
'language': instance.language.toJson(),
|
||||
|
@ -97,10 +97,11 @@ class _$UserLoginCopyWithImpl<$Res, $Val extends UserLogin>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_UserLoginCopyWith<$Res> implements $UserLoginCopyWith<$Res> {
|
||||
factory _$$_UserLoginCopyWith(
|
||||
_$_UserLogin value, $Res Function(_$_UserLogin) then) =
|
||||
__$$_UserLoginCopyWithImpl<$Res>;
|
||||
abstract class _$$UserLoginImplCopyWith<$Res>
|
||||
implements $UserLoginCopyWith<$Res> {
|
||||
factory _$$UserLoginImplCopyWith(
|
||||
_$UserLoginImpl value, $Res Function(_$UserLoginImpl) then) =
|
||||
__$$UserLoginImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call(
|
||||
@ -114,11 +115,11 @@ abstract class _$$_UserLoginCopyWith<$Res> implements $UserLoginCopyWith<$Res> {
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_UserLoginCopyWithImpl<$Res>
|
||||
extends _$UserLoginCopyWithImpl<$Res, _$_UserLogin>
|
||||
implements _$$_UserLoginCopyWith<$Res> {
|
||||
__$$_UserLoginCopyWithImpl(
|
||||
_$_UserLogin _value, $Res Function(_$_UserLogin) _then)
|
||||
class __$$UserLoginImplCopyWithImpl<$Res>
|
||||
extends _$UserLoginCopyWithImpl<$Res, _$UserLoginImpl>
|
||||
implements _$$UserLoginImplCopyWith<$Res> {
|
||||
__$$UserLoginImplCopyWithImpl(
|
||||
_$UserLoginImpl _value, $Res Function(_$UserLoginImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -129,7 +130,7 @@ class __$$_UserLoginCopyWithImpl<$Res>
|
||||
Object? accountRecordInfo = null,
|
||||
Object? lastActive = null,
|
||||
}) {
|
||||
return _then(_$_UserLogin(
|
||||
return _then(_$UserLoginImpl(
|
||||
accountMasterRecordKey: null == accountMasterRecordKey
|
||||
? _value.accountMasterRecordKey
|
||||
: accountMasterRecordKey // ignore: cast_nullable_to_non_nullable
|
||||
@ -152,15 +153,15 @@ class __$$_UserLoginCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_UserLogin implements _UserLogin {
|
||||
const _$_UserLogin(
|
||||
class _$UserLoginImpl implements _UserLogin {
|
||||
const _$UserLoginImpl(
|
||||
{required this.accountMasterRecordKey,
|
||||
required this.identitySecret,
|
||||
required this.accountRecordInfo,
|
||||
required this.lastActive});
|
||||
|
||||
factory _$_UserLogin.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_UserLoginFromJson(json);
|
||||
factory _$UserLoginImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$UserLoginImplFromJson(json);
|
||||
|
||||
// Master record key for the user used to index the local accounts table
|
||||
@override
|
||||
@ -184,7 +185,7 @@ class _$_UserLogin implements _UserLogin {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_UserLogin &&
|
||||
other is _$UserLoginImpl &&
|
||||
(identical(other.accountMasterRecordKey, accountMasterRecordKey) ||
|
||||
other.accountMasterRecordKey == accountMasterRecordKey) &&
|
||||
(identical(other.identitySecret, identitySecret) ||
|
||||
@ -203,12 +204,12 @@ class _$_UserLogin implements _UserLogin {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_UserLoginCopyWith<_$_UserLogin> get copyWith =>
|
||||
__$$_UserLoginCopyWithImpl<_$_UserLogin>(this, _$identity);
|
||||
_$$UserLoginImplCopyWith<_$UserLoginImpl> get copyWith =>
|
||||
__$$UserLoginImplCopyWithImpl<_$UserLoginImpl>(this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_UserLoginToJson(
|
||||
return _$$UserLoginImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -219,10 +220,10 @@ abstract class _UserLogin implements UserLogin {
|
||||
{required final Typed<FixedEncodedString43> accountMasterRecordKey,
|
||||
required final Typed<FixedEncodedString43> identitySecret,
|
||||
required final AccountRecordInfo accountRecordInfo,
|
||||
required final Timestamp lastActive}) = _$_UserLogin;
|
||||
required final Timestamp lastActive}) = _$UserLoginImpl;
|
||||
|
||||
factory _UserLogin.fromJson(Map<String, dynamic> json) =
|
||||
_$_UserLogin.fromJson;
|
||||
_$UserLoginImpl.fromJson;
|
||||
|
||||
@override // Master record key for the user used to index the local accounts table
|
||||
Typed<FixedEncodedString43> get accountMasterRecordKey;
|
||||
@ -234,7 +235,7 @@ abstract class _UserLogin implements UserLogin {
|
||||
Timestamp get lastActive;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_UserLoginCopyWith<_$_UserLogin> get copyWith =>
|
||||
_$$UserLoginImplCopyWith<_$UserLoginImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
}
|
||||
|
||||
@ -297,11 +298,11 @@ class _$ActiveLoginsCopyWithImpl<$Res, $Val extends ActiveLogins>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_ActiveLoginsCopyWith<$Res>
|
||||
abstract class _$$ActiveLoginsImplCopyWith<$Res>
|
||||
implements $ActiveLoginsCopyWith<$Res> {
|
||||
factory _$$_ActiveLoginsCopyWith(
|
||||
_$_ActiveLogins value, $Res Function(_$_ActiveLogins) then) =
|
||||
__$$_ActiveLoginsCopyWithImpl<$Res>;
|
||||
factory _$$ActiveLoginsImplCopyWith(
|
||||
_$ActiveLoginsImpl value, $Res Function(_$ActiveLoginsImpl) then) =
|
||||
__$$ActiveLoginsImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call(
|
||||
@ -310,11 +311,11 @@ abstract class _$$_ActiveLoginsCopyWith<$Res>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_ActiveLoginsCopyWithImpl<$Res>
|
||||
extends _$ActiveLoginsCopyWithImpl<$Res, _$_ActiveLogins>
|
||||
implements _$$_ActiveLoginsCopyWith<$Res> {
|
||||
__$$_ActiveLoginsCopyWithImpl(
|
||||
_$_ActiveLogins _value, $Res Function(_$_ActiveLogins) _then)
|
||||
class __$$ActiveLoginsImplCopyWithImpl<$Res>
|
||||
extends _$ActiveLoginsCopyWithImpl<$Res, _$ActiveLoginsImpl>
|
||||
implements _$$ActiveLoginsImplCopyWith<$Res> {
|
||||
__$$ActiveLoginsImplCopyWithImpl(
|
||||
_$ActiveLoginsImpl _value, $Res Function(_$ActiveLoginsImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -323,7 +324,7 @@ class __$$_ActiveLoginsCopyWithImpl<$Res>
|
||||
Object? userLogins = null,
|
||||
Object? activeUserLogin = freezed,
|
||||
}) {
|
||||
return _then(_$_ActiveLogins(
|
||||
return _then(_$ActiveLoginsImpl(
|
||||
userLogins: null == userLogins
|
||||
? _value.userLogins
|
||||
: userLogins // ignore: cast_nullable_to_non_nullable
|
||||
@ -338,11 +339,11 @@ class __$$_ActiveLoginsCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_ActiveLogins implements _ActiveLogins {
|
||||
const _$_ActiveLogins({required this.userLogins, this.activeUserLogin});
|
||||
class _$ActiveLoginsImpl implements _ActiveLogins {
|
||||
const _$ActiveLoginsImpl({required this.userLogins, this.activeUserLogin});
|
||||
|
||||
factory _$_ActiveLogins.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_ActiveLoginsFromJson(json);
|
||||
factory _$ActiveLoginsImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$ActiveLoginsImplFromJson(json);
|
||||
|
||||
// The list of current logged in accounts
|
||||
@override
|
||||
@ -360,7 +361,7 @@ class _$_ActiveLogins implements _ActiveLogins {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_ActiveLogins &&
|
||||
other is _$ActiveLoginsImpl &&
|
||||
const DeepCollectionEquality()
|
||||
.equals(other.userLogins, userLogins) &&
|
||||
(identical(other.activeUserLogin, activeUserLogin) ||
|
||||
@ -375,12 +376,12 @@ class _$_ActiveLogins implements _ActiveLogins {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_ActiveLoginsCopyWith<_$_ActiveLogins> get copyWith =>
|
||||
__$$_ActiveLoginsCopyWithImpl<_$_ActiveLogins>(this, _$identity);
|
||||
_$$ActiveLoginsImplCopyWith<_$ActiveLoginsImpl> get copyWith =>
|
||||
__$$ActiveLoginsImplCopyWithImpl<_$ActiveLoginsImpl>(this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_ActiveLoginsToJson(
|
||||
return _$$ActiveLoginsImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -389,10 +390,10 @@ class _$_ActiveLogins implements _ActiveLogins {
|
||||
abstract class _ActiveLogins implements ActiveLogins {
|
||||
const factory _ActiveLogins(
|
||||
{required final IList<UserLogin> userLogins,
|
||||
final Typed<FixedEncodedString43>? activeUserLogin}) = _$_ActiveLogins;
|
||||
final Typed<FixedEncodedString43>? activeUserLogin}) = _$ActiveLoginsImpl;
|
||||
|
||||
factory _ActiveLogins.fromJson(Map<String, dynamic> json) =
|
||||
_$_ActiveLogins.fromJson;
|
||||
_$ActiveLoginsImpl.fromJson;
|
||||
|
||||
@override // The list of current logged in accounts
|
||||
IList<UserLogin> get userLogins;
|
||||
@ -400,6 +401,6 @@ abstract class _ActiveLogins implements ActiveLogins {
|
||||
Typed<FixedEncodedString43>? get activeUserLogin;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_ActiveLoginsCopyWith<_$_ActiveLogins> get copyWith =>
|
||||
_$$ActiveLoginsImplCopyWith<_$ActiveLoginsImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
}
|
||||
|
@ -6,7 +6,8 @@ part of 'user_login.dart';
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
_$_UserLogin _$$_UserLoginFromJson(Map<String, dynamic> json) => _$_UserLogin(
|
||||
_$UserLoginImpl _$$UserLoginImplFromJson(Map<String, dynamic> json) =>
|
||||
_$UserLoginImpl(
|
||||
accountMasterRecordKey: Typed<FixedEncodedString43>.fromJson(
|
||||
json['account_master_record_key']),
|
||||
identitySecret:
|
||||
@ -16,7 +17,7 @@ _$_UserLogin _$$_UserLoginFromJson(Map<String, dynamic> json) => _$_UserLogin(
|
||||
lastActive: Timestamp.fromJson(json['last_active']),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_UserLoginToJson(_$_UserLogin instance) =>
|
||||
Map<String, dynamic> _$$UserLoginImplToJson(_$UserLoginImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'account_master_record_key': instance.accountMasterRecordKey.toJson(),
|
||||
'identity_secret': instance.identitySecret.toJson(),
|
||||
@ -24,8 +25,8 @@ Map<String, dynamic> _$$_UserLoginToJson(_$_UserLogin instance) =>
|
||||
'last_active': instance.lastActive.toJson(),
|
||||
};
|
||||
|
||||
_$_ActiveLogins _$$_ActiveLoginsFromJson(Map<String, dynamic> json) =>
|
||||
_$_ActiveLogins(
|
||||
_$ActiveLoginsImpl _$$ActiveLoginsImplFromJson(Map<String, dynamic> json) =>
|
||||
_$ActiveLoginsImpl(
|
||||
userLogins: IList<UserLogin>.fromJson(
|
||||
json['user_logins'], (value) => UserLogin.fromJson(value)),
|
||||
activeUserLogin: json['active_user_login'] == null
|
||||
@ -33,7 +34,7 @@ _$_ActiveLogins _$$_ActiveLoginsFromJson(Map<String, dynamic> json) =>
|
||||
: Typed<FixedEncodedString43>.fromJson(json['active_user_login']),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_ActiveLoginsToJson(_$_ActiveLogins instance) =>
|
||||
Map<String, dynamic> _$$ActiveLoginsImplToJson(_$ActiveLoginsImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'user_logins': instance.userLogins.toJson(
|
||||
(value) => value.toJson(),
|
||||
|
@ -122,8 +122,10 @@ class HomePageState extends ConsumerState<HomePage>
|
||||
onPressed: () async {
|
||||
context.go('/home/settings');
|
||||
}).paddingLTRB(0, 0, 8, 0),
|
||||
ProfileWidget(name: account.profile.name, title: account.profile.title)
|
||||
.expanded(),
|
||||
ProfileWidget(
|
||||
name: account.profile.name,
|
||||
pronouns: account.profile.pronouns,
|
||||
).expanded(),
|
||||
]).paddingAll(8),
|
||||
MainPager(
|
||||
localAccounts: localAccounts,
|
||||
|
@ -173,7 +173,7 @@ class MainPagerState extends ConsumerState<MainPager>
|
||||
IconButton(
|
||||
onPressed: () async {
|
||||
Navigator.pop(context);
|
||||
//await scanContactInvitationDialog(context);
|
||||
await ScanInviteDialog.show(context);
|
||||
},
|
||||
iconSize: 64,
|
||||
icon: const Icon(Icons.qr_code_scanner)),
|
||||
|
@ -27,7 +27,7 @@ class NewAccountPageState extends ConsumerState<NewAccountPage> {
|
||||
final _formKey = GlobalKey<FormBuilderState>();
|
||||
late bool isInAsyncCall = false;
|
||||
static const String formFieldName = 'name';
|
||||
static const String formFieldTitle = 'title';
|
||||
static const String formFieldPronouns = 'pronouns';
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
@ -48,8 +48,8 @@ class NewAccountPageState extends ConsumerState<NewAccountPage> {
|
||||
final logins = ref.read(loginsProvider.notifier);
|
||||
|
||||
final name = _formKey.currentState!.fields[formFieldName]!.value as String;
|
||||
final title =
|
||||
_formKey.currentState!.fields[formFieldTitle]!.value as String;
|
||||
final pronouns =
|
||||
_formKey.currentState!.fields[formFieldPronouns]!.value as String;
|
||||
|
||||
final imws = await IdentityMasterWithSecrets.create();
|
||||
try {
|
||||
@ -57,7 +57,7 @@ class NewAccountPageState extends ConsumerState<NewAccountPage> {
|
||||
identityMaster: imws.identityMaster,
|
||||
identitySecret: imws.identitySecret,
|
||||
name: name,
|
||||
title: title);
|
||||
pronouns: pronouns);
|
||||
|
||||
// Log in the new account by default with no pin
|
||||
final ok = await logins.login(localAccount.identityMaster.masterRecordKey,
|
||||
@ -83,7 +83,7 @@ class NewAccountPageState extends ConsumerState<NewAccountPage> {
|
||||
autofocus: true,
|
||||
name: formFieldName,
|
||||
decoration:
|
||||
InputDecoration(hintText: translate('account.form_name')),
|
||||
InputDecoration(labelText: translate('account.form_name')),
|
||||
maxLength: 64,
|
||||
// The validator receives the text that the user has entered.
|
||||
validator: FormBuilderValidators.compose([
|
||||
@ -91,10 +91,10 @@ class NewAccountPageState extends ConsumerState<NewAccountPage> {
|
||||
]),
|
||||
),
|
||||
FormBuilderTextField(
|
||||
name: formFieldTitle,
|
||||
name: formFieldPronouns,
|
||||
maxLength: 64,
|
||||
decoration:
|
||||
InputDecoration(hintText: translate('account.form_title')),
|
||||
decoration: InputDecoration(
|
||||
labelText: translate('account.form_pronouns')),
|
||||
),
|
||||
Row(children: [
|
||||
const Spacer(),
|
||||
|
@ -372,7 +372,7 @@ class Profile extends $pb.GeneratedMessage {
|
||||
|
||||
static final $pb.BuilderInfo _i = $pb.BuilderInfo(_omitMessageNames ? '' : 'Profile', package: const $pb.PackageName(_omitMessageNames ? '' : 'veilidchat'), createEmptyInstance: create)
|
||||
..aOS(1, _omitFieldNames ? '' : 'name')
|
||||
..aOS(2, _omitFieldNames ? '' : 'title')
|
||||
..aOS(2, _omitFieldNames ? '' : 'pronouns')
|
||||
..aOS(3, _omitFieldNames ? '' : 'status')
|
||||
..e<Availability>(4, _omitFieldNames ? '' : 'availability', $pb.PbFieldType.OE, defaultOrMaker: Availability.AVAILABILITY_UNSPECIFIED, valueOf: Availability.valueOf, enumValues: Availability.values)
|
||||
..aOM<$1.TypedKey>(5, _omitFieldNames ? '' : 'avatar', subBuilder: $1.TypedKey.create)
|
||||
@ -410,13 +410,13 @@ class Profile extends $pb.GeneratedMessage {
|
||||
void clearName() => clearField(1);
|
||||
|
||||
@$pb.TagNumber(2)
|
||||
$core.String get title => $_getSZ(1);
|
||||
$core.String get pronouns => $_getSZ(1);
|
||||
@$pb.TagNumber(2)
|
||||
set title($core.String v) { $_setString(1, v); }
|
||||
set pronouns($core.String v) { $_setString(1, v); }
|
||||
@$pb.TagNumber(2)
|
||||
$core.bool hasTitle() => $_has(1);
|
||||
$core.bool hasPronouns() => $_has(1);
|
||||
@$pb.TagNumber(2)
|
||||
void clearTitle() => clearField(2);
|
||||
void clearPronouns() => clearField(2);
|
||||
|
||||
@$pb.TagNumber(3)
|
||||
$core.String get status => $_getSZ(2);
|
||||
|
@ -163,7 +163,7 @@ const Profile$json = {
|
||||
'1': 'Profile',
|
||||
'2': [
|
||||
{'1': 'name', '3': 1, '4': 1, '5': 9, '10': 'name'},
|
||||
{'1': 'title', '3': 2, '4': 1, '5': 9, '10': 'title'},
|
||||
{'1': 'pronouns', '3': 2, '4': 1, '5': 9, '10': 'pronouns'},
|
||||
{'1': 'status', '3': 3, '4': 1, '5': 9, '10': 'status'},
|
||||
{'1': 'availability', '3': 4, '4': 1, '5': 14, '6': '.veilidchat.Availability', '10': 'availability'},
|
||||
{'1': 'avatar', '3': 5, '4': 1, '5': 11, '6': '.veilid.TypedKey', '9': 0, '10': 'avatar', '17': true},
|
||||
@ -175,10 +175,10 @@ const Profile$json = {
|
||||
|
||||
/// Descriptor for `Profile`. Decode as a `google.protobuf.DescriptorProto`.
|
||||
final $typed_data.Uint8List profileDescriptor = $convert.base64Decode(
|
||||
'CgdQcm9maWxlEhIKBG5hbWUYASABKAlSBG5hbWUSFAoFdGl0bGUYAiABKAlSBXRpdGxlEhYKBn'
|
||||
'N0YXR1cxgDIAEoCVIGc3RhdHVzEjwKDGF2YWlsYWJpbGl0eRgEIAEoDjIYLnZlaWxpZGNoYXQu'
|
||||
'QXZhaWxhYmlsaXR5UgxhdmFpbGFiaWxpdHkSLQoGYXZhdGFyGAUgASgLMhAudmVpbGlkLlR5cG'
|
||||
'VkS2V5SABSBmF2YXRhcogBAUIJCgdfYXZhdGFy');
|
||||
'CgdQcm9maWxlEhIKBG5hbWUYASABKAlSBG5hbWUSGgoIcHJvbm91bnMYAiABKAlSCHByb25vdW'
|
||||
'5zEhYKBnN0YXR1cxgDIAEoCVIGc3RhdHVzEjwKDGF2YWlsYWJpbGl0eRgEIAEoDjIYLnZlaWxp'
|
||||
'ZGNoYXQuQXZhaWxhYmlsaXR5UgxhdmFpbGFiaWxpdHkSLQoGYXZhdGFyGAUgASgLMhAudmVpbG'
|
||||
'lkLlR5cGVkS2V5SABSBmF2YXRhcogBAUIJCgdfYXZhdGFy');
|
||||
|
||||
@$core.Deprecated('Use chatDescriptor instead')
|
||||
const Chat$json = {
|
||||
|
@ -95,13 +95,13 @@ enum Availability {
|
||||
// Publicly shared profile information for both contacts and accounts
|
||||
// Contains:
|
||||
// Name - Friendly name
|
||||
// Title - Title of user
|
||||
// Pronouns - Pronouns of user
|
||||
// Icon - Little picture to represent user in contact list
|
||||
message Profile {
|
||||
// Friendy name
|
||||
string name = 1;
|
||||
// Title of user
|
||||
string title = 2;
|
||||
// Pronouns of user
|
||||
string pronouns = 2;
|
||||
// Status/away message
|
||||
string status = 3;
|
||||
// Availability
|
||||
|
@ -65,7 +65,7 @@ class LocalAccounts extends _$LocalAccounts
|
||||
{required IdentityMaster identityMaster,
|
||||
required SecretKey identitySecret,
|
||||
required String name,
|
||||
required String title,
|
||||
required String pronouns,
|
||||
EncryptionKeyType encryptionKeyType = EncryptionKeyType.none,
|
||||
String encryptionKey = ''}) async {
|
||||
final localAccounts = state.requireValue;
|
||||
@ -92,7 +92,7 @@ class LocalAccounts extends _$LocalAccounts
|
||||
final account = proto.Account()
|
||||
..profile = (proto.Profile()
|
||||
..name = name
|
||||
..title = title)
|
||||
..pronouns = pronouns)
|
||||
..contactList = contactList.toProto()
|
||||
..contactInvitationRecords = contactInvitationRecords.toProto()
|
||||
..chatList = chatRecords.toProto();
|
||||
|
@ -159,7 +159,7 @@ class _FetchLocalAccountProviderElement
|
||||
(origin as FetchLocalAccountProvider).accountMasterRecordKey;
|
||||
}
|
||||
|
||||
String _$localAccountsHash() => r'0ab9eca923cb9e15149f06d9edbb9de0cfed6790';
|
||||
String _$localAccountsHash() => r'148d98fcd8a61147bb475708d50b9699887c5bec';
|
||||
|
||||
/// See also [LocalAccounts].
|
||||
@ProviderFor(LocalAccounts)
|
||||
|
51
lib/tools/scanner_error_widget.dart
Normal file
51
lib/tools/scanner_error_widget.dart
Normal file
@ -0,0 +1,51 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:mobile_scanner/mobile_scanner.dart';
|
||||
|
||||
class ScannerErrorWidget extends StatelessWidget {
|
||||
const ScannerErrorWidget({Key? key, required this.error}) : super(key: key);
|
||||
|
||||
final MobileScannerException error;
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
String errorMessage;
|
||||
|
||||
switch (error.errorCode) {
|
||||
case MobileScannerErrorCode.controllerUninitialized:
|
||||
errorMessage = 'Controller not ready.';
|
||||
break;
|
||||
case MobileScannerErrorCode.permissionDenied:
|
||||
errorMessage = 'Permission denied';
|
||||
break;
|
||||
case MobileScannerErrorCode.unsupported:
|
||||
errorMessage = 'Scanning is unsupported on this device';
|
||||
break;
|
||||
default:
|
||||
errorMessage = 'Generic Error';
|
||||
break;
|
||||
}
|
||||
|
||||
return ColoredBox(
|
||||
color: Colors.black,
|
||||
child: Center(
|
||||
child: Column(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
const Padding(
|
||||
padding: EdgeInsets.only(bottom: 16),
|
||||
child: Icon(Icons.error, color: Colors.white),
|
||||
),
|
||||
Text(
|
||||
errorMessage,
|
||||
style: const TextStyle(color: Colors.white),
|
||||
),
|
||||
Text(
|
||||
error.errorDetails?.message ?? '',
|
||||
style: const TextStyle(color: Colors.white),
|
||||
),
|
||||
],
|
||||
),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
@ -8,3 +8,4 @@ export 'secret_crypto.dart';
|
||||
export 'state_logger.dart';
|
||||
export 'theme_service.dart';
|
||||
export 'widget_helpers.dart';
|
||||
export 'scanner_error_widget.dart';
|
||||
|
@ -82,12 +82,12 @@ class _$DHTRecordPoolAllocationsCopyWithImpl<$Res,
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_DHTRecordPoolAllocationsCopyWith<$Res>
|
||||
abstract class _$$DHTRecordPoolAllocationsImplCopyWith<$Res>
|
||||
implements $DHTRecordPoolAllocationsCopyWith<$Res> {
|
||||
factory _$$_DHTRecordPoolAllocationsCopyWith(
|
||||
_$_DHTRecordPoolAllocations value,
|
||||
$Res Function(_$_DHTRecordPoolAllocations) then) =
|
||||
__$$_DHTRecordPoolAllocationsCopyWithImpl<$Res>;
|
||||
factory _$$DHTRecordPoolAllocationsImplCopyWith(
|
||||
_$DHTRecordPoolAllocationsImpl value,
|
||||
$Res Function(_$DHTRecordPoolAllocationsImpl) then) =
|
||||
__$$DHTRecordPoolAllocationsImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call(
|
||||
@ -97,12 +97,13 @@ abstract class _$$_DHTRecordPoolAllocationsCopyWith<$Res>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_DHTRecordPoolAllocationsCopyWithImpl<$Res>
|
||||
class __$$DHTRecordPoolAllocationsImplCopyWithImpl<$Res>
|
||||
extends _$DHTRecordPoolAllocationsCopyWithImpl<$Res,
|
||||
_$_DHTRecordPoolAllocations>
|
||||
implements _$$_DHTRecordPoolAllocationsCopyWith<$Res> {
|
||||
__$$_DHTRecordPoolAllocationsCopyWithImpl(_$_DHTRecordPoolAllocations _value,
|
||||
$Res Function(_$_DHTRecordPoolAllocations) _then)
|
||||
_$DHTRecordPoolAllocationsImpl>
|
||||
implements _$$DHTRecordPoolAllocationsImplCopyWith<$Res> {
|
||||
__$$DHTRecordPoolAllocationsImplCopyWithImpl(
|
||||
_$DHTRecordPoolAllocationsImpl _value,
|
||||
$Res Function(_$DHTRecordPoolAllocationsImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -112,7 +113,7 @@ class __$$_DHTRecordPoolAllocationsCopyWithImpl<$Res>
|
||||
Object? parentByChild = null,
|
||||
Object? rootRecords = null,
|
||||
}) {
|
||||
return _then(_$_DHTRecordPoolAllocations(
|
||||
return _then(_$DHTRecordPoolAllocationsImpl(
|
||||
childrenByParent: null == childrenByParent
|
||||
? _value.childrenByParent
|
||||
: childrenByParent // ignore: cast_nullable_to_non_nullable
|
||||
@ -131,14 +132,14 @@ class __$$_DHTRecordPoolAllocationsCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_DHTRecordPoolAllocations implements _DHTRecordPoolAllocations {
|
||||
const _$_DHTRecordPoolAllocations(
|
||||
class _$DHTRecordPoolAllocationsImpl implements _DHTRecordPoolAllocations {
|
||||
const _$DHTRecordPoolAllocationsImpl(
|
||||
{required this.childrenByParent,
|
||||
required this.parentByChild,
|
||||
required this.rootRecords});
|
||||
|
||||
factory _$_DHTRecordPoolAllocations.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_DHTRecordPoolAllocationsFromJson(json);
|
||||
factory _$DHTRecordPoolAllocationsImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$DHTRecordPoolAllocationsImplFromJson(json);
|
||||
|
||||
@override
|
||||
final IMap<String, ISet<Typed<FixedEncodedString43>>> childrenByParent;
|
||||
@ -158,7 +159,7 @@ class _$_DHTRecordPoolAllocations implements _DHTRecordPoolAllocations {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_DHTRecordPoolAllocations &&
|
||||
other is _$DHTRecordPoolAllocationsImpl &&
|
||||
(identical(other.childrenByParent, childrenByParent) ||
|
||||
other.childrenByParent == childrenByParent) &&
|
||||
(identical(other.parentByChild, parentByChild) ||
|
||||
@ -175,13 +176,13 @@ class _$_DHTRecordPoolAllocations implements _DHTRecordPoolAllocations {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_DHTRecordPoolAllocationsCopyWith<_$_DHTRecordPoolAllocations>
|
||||
get copyWith => __$$_DHTRecordPoolAllocationsCopyWithImpl<
|
||||
_$_DHTRecordPoolAllocations>(this, _$identity);
|
||||
_$$DHTRecordPoolAllocationsImplCopyWith<_$DHTRecordPoolAllocationsImpl>
|
||||
get copyWith => __$$DHTRecordPoolAllocationsImplCopyWithImpl<
|
||||
_$DHTRecordPoolAllocationsImpl>(this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_DHTRecordPoolAllocationsToJson(
|
||||
return _$$DHTRecordPoolAllocationsImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -193,10 +194,10 @@ abstract class _DHTRecordPoolAllocations implements DHTRecordPoolAllocations {
|
||||
childrenByParent,
|
||||
required final IMap<String, Typed<FixedEncodedString43>> parentByChild,
|
||||
required final ISet<Typed<FixedEncodedString43>>
|
||||
rootRecords}) = _$_DHTRecordPoolAllocations;
|
||||
rootRecords}) = _$DHTRecordPoolAllocationsImpl;
|
||||
|
||||
factory _DHTRecordPoolAllocations.fromJson(Map<String, dynamic> json) =
|
||||
_$_DHTRecordPoolAllocations.fromJson;
|
||||
_$DHTRecordPoolAllocationsImpl.fromJson;
|
||||
|
||||
@override
|
||||
IMap<String, ISet<Typed<FixedEncodedString43>>> get childrenByParent;
|
||||
@ -206,7 +207,7 @@ abstract class _DHTRecordPoolAllocations implements DHTRecordPoolAllocations {
|
||||
ISet<Typed<FixedEncodedString43>> get rootRecords;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_DHTRecordPoolAllocationsCopyWith<_$_DHTRecordPoolAllocations>
|
||||
_$$DHTRecordPoolAllocationsImplCopyWith<_$DHTRecordPoolAllocationsImpl>
|
||||
get copyWith => throw _privateConstructorUsedError;
|
||||
}
|
||||
|
||||
@ -267,22 +268,24 @@ class _$OwnedDHTRecordPointerCopyWithImpl<$Res,
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_OwnedDHTRecordPointerCopyWith<$Res>
|
||||
abstract class _$$OwnedDHTRecordPointerImplCopyWith<$Res>
|
||||
implements $OwnedDHTRecordPointerCopyWith<$Res> {
|
||||
factory _$$_OwnedDHTRecordPointerCopyWith(_$_OwnedDHTRecordPointer value,
|
||||
$Res Function(_$_OwnedDHTRecordPointer) then) =
|
||||
__$$_OwnedDHTRecordPointerCopyWithImpl<$Res>;
|
||||
factory _$$OwnedDHTRecordPointerImplCopyWith(
|
||||
_$OwnedDHTRecordPointerImpl value,
|
||||
$Res Function(_$OwnedDHTRecordPointerImpl) then) =
|
||||
__$$OwnedDHTRecordPointerImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call({Typed<FixedEncodedString43> recordKey, KeyPair owner});
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_OwnedDHTRecordPointerCopyWithImpl<$Res>
|
||||
extends _$OwnedDHTRecordPointerCopyWithImpl<$Res, _$_OwnedDHTRecordPointer>
|
||||
implements _$$_OwnedDHTRecordPointerCopyWith<$Res> {
|
||||
__$$_OwnedDHTRecordPointerCopyWithImpl(_$_OwnedDHTRecordPointer _value,
|
||||
$Res Function(_$_OwnedDHTRecordPointer) _then)
|
||||
class __$$OwnedDHTRecordPointerImplCopyWithImpl<$Res>
|
||||
extends _$OwnedDHTRecordPointerCopyWithImpl<$Res,
|
||||
_$OwnedDHTRecordPointerImpl>
|
||||
implements _$$OwnedDHTRecordPointerImplCopyWith<$Res> {
|
||||
__$$OwnedDHTRecordPointerImplCopyWithImpl(_$OwnedDHTRecordPointerImpl _value,
|
||||
$Res Function(_$OwnedDHTRecordPointerImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -291,7 +294,7 @@ class __$$_OwnedDHTRecordPointerCopyWithImpl<$Res>
|
||||
Object? recordKey = null,
|
||||
Object? owner = null,
|
||||
}) {
|
||||
return _then(_$_OwnedDHTRecordPointer(
|
||||
return _then(_$OwnedDHTRecordPointerImpl(
|
||||
recordKey: null == recordKey
|
||||
? _value.recordKey
|
||||
: recordKey // ignore: cast_nullable_to_non_nullable
|
||||
@ -306,12 +309,12 @@ class __$$_OwnedDHTRecordPointerCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_OwnedDHTRecordPointer implements _OwnedDHTRecordPointer {
|
||||
const _$_OwnedDHTRecordPointer(
|
||||
class _$OwnedDHTRecordPointerImpl implements _OwnedDHTRecordPointer {
|
||||
const _$OwnedDHTRecordPointerImpl(
|
||||
{required this.recordKey, required this.owner});
|
||||
|
||||
factory _$_OwnedDHTRecordPointer.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_OwnedDHTRecordPointerFromJson(json);
|
||||
factory _$OwnedDHTRecordPointerImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$OwnedDHTRecordPointerImplFromJson(json);
|
||||
|
||||
@override
|
||||
final Typed<FixedEncodedString43> recordKey;
|
||||
@ -327,7 +330,7 @@ class _$_OwnedDHTRecordPointer implements _OwnedDHTRecordPointer {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_OwnedDHTRecordPointer &&
|
||||
other is _$OwnedDHTRecordPointerImpl &&
|
||||
(identical(other.recordKey, recordKey) ||
|
||||
other.recordKey == recordKey) &&
|
||||
(identical(other.owner, owner) || other.owner == owner));
|
||||
@ -340,13 +343,13 @@ class _$_OwnedDHTRecordPointer implements _OwnedDHTRecordPointer {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_OwnedDHTRecordPointerCopyWith<_$_OwnedDHTRecordPointer> get copyWith =>
|
||||
__$$_OwnedDHTRecordPointerCopyWithImpl<_$_OwnedDHTRecordPointer>(
|
||||
this, _$identity);
|
||||
_$$OwnedDHTRecordPointerImplCopyWith<_$OwnedDHTRecordPointerImpl>
|
||||
get copyWith => __$$OwnedDHTRecordPointerImplCopyWithImpl<
|
||||
_$OwnedDHTRecordPointerImpl>(this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_OwnedDHTRecordPointerToJson(
|
||||
return _$$OwnedDHTRecordPointerImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -355,10 +358,10 @@ class _$_OwnedDHTRecordPointer implements _OwnedDHTRecordPointer {
|
||||
abstract class _OwnedDHTRecordPointer implements OwnedDHTRecordPointer {
|
||||
const factory _OwnedDHTRecordPointer(
|
||||
{required final Typed<FixedEncodedString43> recordKey,
|
||||
required final KeyPair owner}) = _$_OwnedDHTRecordPointer;
|
||||
required final KeyPair owner}) = _$OwnedDHTRecordPointerImpl;
|
||||
|
||||
factory _OwnedDHTRecordPointer.fromJson(Map<String, dynamic> json) =
|
||||
_$_OwnedDHTRecordPointer.fromJson;
|
||||
_$OwnedDHTRecordPointerImpl.fromJson;
|
||||
|
||||
@override
|
||||
Typed<FixedEncodedString43> get recordKey;
|
||||
@ -366,6 +369,6 @@ abstract class _OwnedDHTRecordPointer implements OwnedDHTRecordPointer {
|
||||
KeyPair get owner;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_OwnedDHTRecordPointerCopyWith<_$_OwnedDHTRecordPointer> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
_$$OwnedDHTRecordPointerImplCopyWith<_$OwnedDHTRecordPointerImpl>
|
||||
get copyWith => throw _privateConstructorUsedError;
|
||||
}
|
||||
|
@ -6,9 +6,9 @@ part of 'dht_record_pool.dart';
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
_$_DHTRecordPoolAllocations _$$_DHTRecordPoolAllocationsFromJson(
|
||||
_$DHTRecordPoolAllocationsImpl _$$DHTRecordPoolAllocationsImplFromJson(
|
||||
Map<String, dynamic> json) =>
|
||||
_$_DHTRecordPoolAllocations(
|
||||
_$DHTRecordPoolAllocationsImpl(
|
||||
childrenByParent:
|
||||
IMap<String, ISet<Typed<FixedEncodedString43>>>.fromJson(
|
||||
json['children_by_parent'] as Map<String, dynamic>,
|
||||
@ -24,8 +24,8 @@ _$_DHTRecordPoolAllocations _$$_DHTRecordPoolAllocationsFromJson(
|
||||
(value) => Typed<FixedEncodedString43>.fromJson(value)),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_DHTRecordPoolAllocationsToJson(
|
||||
_$_DHTRecordPoolAllocations instance) =>
|
||||
Map<String, dynamic> _$$DHTRecordPoolAllocationsImplToJson(
|
||||
_$DHTRecordPoolAllocationsImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'children_by_parent': instance.childrenByParent.toJson(
|
||||
(value) => value,
|
||||
@ -42,15 +42,15 @@ Map<String, dynamic> _$$_DHTRecordPoolAllocationsToJson(
|
||||
),
|
||||
};
|
||||
|
||||
_$_OwnedDHTRecordPointer _$$_OwnedDHTRecordPointerFromJson(
|
||||
_$OwnedDHTRecordPointerImpl _$$OwnedDHTRecordPointerImplFromJson(
|
||||
Map<String, dynamic> json) =>
|
||||
_$_OwnedDHTRecordPointer(
|
||||
_$OwnedDHTRecordPointerImpl(
|
||||
recordKey: Typed<FixedEncodedString43>.fromJson(json['record_key']),
|
||||
owner: KeyPair.fromJson(json['owner']),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_OwnedDHTRecordPointerToJson(
|
||||
_$_OwnedDHTRecordPointer instance) =>
|
||||
Map<String, dynamic> _$$OwnedDHTRecordPointerImplToJson(
|
||||
_$OwnedDHTRecordPointerImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'record_key': instance.recordKey.toJson(),
|
||||
'owner': instance.owner.toJson(),
|
||||
|
@ -73,11 +73,11 @@ class _$AccountRecordInfoCopyWithImpl<$Res, $Val extends AccountRecordInfo>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_AccountRecordInfoCopyWith<$Res>
|
||||
abstract class _$$AccountRecordInfoImplCopyWith<$Res>
|
||||
implements $AccountRecordInfoCopyWith<$Res> {
|
||||
factory _$$_AccountRecordInfoCopyWith(_$_AccountRecordInfo value,
|
||||
$Res Function(_$_AccountRecordInfo) then) =
|
||||
__$$_AccountRecordInfoCopyWithImpl<$Res>;
|
||||
factory _$$AccountRecordInfoImplCopyWith(_$AccountRecordInfoImpl value,
|
||||
$Res Function(_$AccountRecordInfoImpl) then) =
|
||||
__$$AccountRecordInfoImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call({OwnedDHTRecordPointer accountRecord});
|
||||
@ -87,11 +87,11 @@ abstract class _$$_AccountRecordInfoCopyWith<$Res>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_AccountRecordInfoCopyWithImpl<$Res>
|
||||
extends _$AccountRecordInfoCopyWithImpl<$Res, _$_AccountRecordInfo>
|
||||
implements _$$_AccountRecordInfoCopyWith<$Res> {
|
||||
__$$_AccountRecordInfoCopyWithImpl(
|
||||
_$_AccountRecordInfo _value, $Res Function(_$_AccountRecordInfo) _then)
|
||||
class __$$AccountRecordInfoImplCopyWithImpl<$Res>
|
||||
extends _$AccountRecordInfoCopyWithImpl<$Res, _$AccountRecordInfoImpl>
|
||||
implements _$$AccountRecordInfoImplCopyWith<$Res> {
|
||||
__$$AccountRecordInfoImplCopyWithImpl(_$AccountRecordInfoImpl _value,
|
||||
$Res Function(_$AccountRecordInfoImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -99,7 +99,7 @@ class __$$_AccountRecordInfoCopyWithImpl<$Res>
|
||||
$Res call({
|
||||
Object? accountRecord = null,
|
||||
}) {
|
||||
return _then(_$_AccountRecordInfo(
|
||||
return _then(_$AccountRecordInfoImpl(
|
||||
accountRecord: null == accountRecord
|
||||
? _value.accountRecord
|
||||
: accountRecord // ignore: cast_nullable_to_non_nullable
|
||||
@ -110,11 +110,11 @@ class __$$_AccountRecordInfoCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_AccountRecordInfo implements _AccountRecordInfo {
|
||||
const _$_AccountRecordInfo({required this.accountRecord});
|
||||
class _$AccountRecordInfoImpl implements _AccountRecordInfo {
|
||||
const _$AccountRecordInfoImpl({required this.accountRecord});
|
||||
|
||||
factory _$_AccountRecordInfo.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_AccountRecordInfoFromJson(json);
|
||||
factory _$AccountRecordInfoImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$AccountRecordInfoImplFromJson(json);
|
||||
|
||||
// Top level account keys and secrets
|
||||
@override
|
||||
@ -129,7 +129,7 @@ class _$_AccountRecordInfo implements _AccountRecordInfo {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_AccountRecordInfo &&
|
||||
other is _$AccountRecordInfoImpl &&
|
||||
(identical(other.accountRecord, accountRecord) ||
|
||||
other.accountRecord == accountRecord));
|
||||
}
|
||||
@ -141,13 +141,13 @@ class _$_AccountRecordInfo implements _AccountRecordInfo {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_AccountRecordInfoCopyWith<_$_AccountRecordInfo> get copyWith =>
|
||||
__$$_AccountRecordInfoCopyWithImpl<_$_AccountRecordInfo>(
|
||||
_$$AccountRecordInfoImplCopyWith<_$AccountRecordInfoImpl> get copyWith =>
|
||||
__$$AccountRecordInfoImplCopyWithImpl<_$AccountRecordInfoImpl>(
|
||||
this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_AccountRecordInfoToJson(
|
||||
return _$$AccountRecordInfoImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -156,16 +156,16 @@ class _$_AccountRecordInfo implements _AccountRecordInfo {
|
||||
abstract class _AccountRecordInfo implements AccountRecordInfo {
|
||||
const factory _AccountRecordInfo(
|
||||
{required final OwnedDHTRecordPointer accountRecord}) =
|
||||
_$_AccountRecordInfo;
|
||||
_$AccountRecordInfoImpl;
|
||||
|
||||
factory _AccountRecordInfo.fromJson(Map<String, dynamic> json) =
|
||||
_$_AccountRecordInfo.fromJson;
|
||||
_$AccountRecordInfoImpl.fromJson;
|
||||
|
||||
@override // Top level account keys and secrets
|
||||
OwnedDHTRecordPointer get accountRecord;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_AccountRecordInfoCopyWith<_$_AccountRecordInfo> get copyWith =>
|
||||
_$$AccountRecordInfoImplCopyWith<_$AccountRecordInfoImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
}
|
||||
|
||||
@ -218,21 +218,22 @@ class _$IdentityCopyWithImpl<$Res, $Val extends Identity>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_IdentityCopyWith<$Res> implements $IdentityCopyWith<$Res> {
|
||||
factory _$$_IdentityCopyWith(
|
||||
_$_Identity value, $Res Function(_$_Identity) then) =
|
||||
__$$_IdentityCopyWithImpl<$Res>;
|
||||
abstract class _$$IdentityImplCopyWith<$Res>
|
||||
implements $IdentityCopyWith<$Res> {
|
||||
factory _$$IdentityImplCopyWith(
|
||||
_$IdentityImpl value, $Res Function(_$IdentityImpl) then) =
|
||||
__$$IdentityImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call({IMap<String, ISet<AccountRecordInfo>> accountRecords});
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_IdentityCopyWithImpl<$Res>
|
||||
extends _$IdentityCopyWithImpl<$Res, _$_Identity>
|
||||
implements _$$_IdentityCopyWith<$Res> {
|
||||
__$$_IdentityCopyWithImpl(
|
||||
_$_Identity _value, $Res Function(_$_Identity) _then)
|
||||
class __$$IdentityImplCopyWithImpl<$Res>
|
||||
extends _$IdentityCopyWithImpl<$Res, _$IdentityImpl>
|
||||
implements _$$IdentityImplCopyWith<$Res> {
|
||||
__$$IdentityImplCopyWithImpl(
|
||||
_$IdentityImpl _value, $Res Function(_$IdentityImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -240,7 +241,7 @@ class __$$_IdentityCopyWithImpl<$Res>
|
||||
$Res call({
|
||||
Object? accountRecords = null,
|
||||
}) {
|
||||
return _then(_$_Identity(
|
||||
return _then(_$IdentityImpl(
|
||||
accountRecords: null == accountRecords
|
||||
? _value.accountRecords
|
||||
: accountRecords // ignore: cast_nullable_to_non_nullable
|
||||
@ -251,11 +252,11 @@ class __$$_IdentityCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_Identity implements _Identity {
|
||||
const _$_Identity({required this.accountRecords});
|
||||
class _$IdentityImpl implements _Identity {
|
||||
const _$IdentityImpl({required this.accountRecords});
|
||||
|
||||
factory _$_Identity.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_IdentityFromJson(json);
|
||||
factory _$IdentityImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$IdentityImplFromJson(json);
|
||||
|
||||
// Top level account keys and secrets
|
||||
@override
|
||||
@ -270,7 +271,7 @@ class _$_Identity implements _Identity {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_Identity &&
|
||||
other is _$IdentityImpl &&
|
||||
(identical(other.accountRecords, accountRecords) ||
|
||||
other.accountRecords == accountRecords));
|
||||
}
|
||||
@ -282,12 +283,12 @@ class _$_Identity implements _Identity {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_IdentityCopyWith<_$_Identity> get copyWith =>
|
||||
__$$_IdentityCopyWithImpl<_$_Identity>(this, _$identity);
|
||||
_$$IdentityImplCopyWith<_$IdentityImpl> get copyWith =>
|
||||
__$$IdentityImplCopyWithImpl<_$IdentityImpl>(this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_IdentityToJson(
|
||||
return _$$IdentityImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -296,15 +297,16 @@ class _$_Identity implements _Identity {
|
||||
abstract class _Identity implements Identity {
|
||||
const factory _Identity(
|
||||
{required final IMap<String, ISet<AccountRecordInfo>>
|
||||
accountRecords}) = _$_Identity;
|
||||
accountRecords}) = _$IdentityImpl;
|
||||
|
||||
factory _Identity.fromJson(Map<String, dynamic> json) = _$_Identity.fromJson;
|
||||
factory _Identity.fromJson(Map<String, dynamic> json) =
|
||||
_$IdentityImpl.fromJson;
|
||||
|
||||
@override // Top level account keys and secrets
|
||||
IMap<String, ISet<AccountRecordInfo>> get accountRecords;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_IdentityCopyWith<_$_Identity> get copyWith =>
|
||||
_$$IdentityImplCopyWith<_$IdentityImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
}
|
||||
|
||||
@ -399,11 +401,11 @@ class _$IdentityMasterCopyWithImpl<$Res, $Val extends IdentityMaster>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
abstract class _$$_IdentityMasterCopyWith<$Res>
|
||||
abstract class _$$IdentityMasterImplCopyWith<$Res>
|
||||
implements $IdentityMasterCopyWith<$Res> {
|
||||
factory _$$_IdentityMasterCopyWith(
|
||||
_$_IdentityMaster value, $Res Function(_$_IdentityMaster) then) =
|
||||
__$$_IdentityMasterCopyWithImpl<$Res>;
|
||||
factory _$$IdentityMasterImplCopyWith(_$IdentityMasterImpl value,
|
||||
$Res Function(_$IdentityMasterImpl) then) =
|
||||
__$$IdentityMasterImplCopyWithImpl<$Res>;
|
||||
@override
|
||||
@useResult
|
||||
$Res call(
|
||||
@ -416,11 +418,11 @@ abstract class _$$_IdentityMasterCopyWith<$Res>
|
||||
}
|
||||
|
||||
/// @nodoc
|
||||
class __$$_IdentityMasterCopyWithImpl<$Res>
|
||||
extends _$IdentityMasterCopyWithImpl<$Res, _$_IdentityMaster>
|
||||
implements _$$_IdentityMasterCopyWith<$Res> {
|
||||
__$$_IdentityMasterCopyWithImpl(
|
||||
_$_IdentityMaster _value, $Res Function(_$_IdentityMaster) _then)
|
||||
class __$$IdentityMasterImplCopyWithImpl<$Res>
|
||||
extends _$IdentityMasterCopyWithImpl<$Res, _$IdentityMasterImpl>
|
||||
implements _$$IdentityMasterImplCopyWith<$Res> {
|
||||
__$$IdentityMasterImplCopyWithImpl(
|
||||
_$IdentityMasterImpl _value, $Res Function(_$IdentityMasterImpl) _then)
|
||||
: super(_value, _then);
|
||||
|
||||
@pragma('vm:prefer-inline')
|
||||
@ -433,7 +435,7 @@ class __$$_IdentityMasterCopyWithImpl<$Res>
|
||||
Object? identitySignature = null,
|
||||
Object? masterSignature = null,
|
||||
}) {
|
||||
return _then(_$_IdentityMaster(
|
||||
return _then(_$IdentityMasterImpl(
|
||||
identityRecordKey: null == identityRecordKey
|
||||
? _value.identityRecordKey
|
||||
: identityRecordKey // ignore: cast_nullable_to_non_nullable
|
||||
@ -464,8 +466,8 @@ class __$$_IdentityMasterCopyWithImpl<$Res>
|
||||
|
||||
/// @nodoc
|
||||
@JsonSerializable()
|
||||
class _$_IdentityMaster implements _IdentityMaster {
|
||||
const _$_IdentityMaster(
|
||||
class _$IdentityMasterImpl implements _IdentityMaster {
|
||||
const _$IdentityMasterImpl(
|
||||
{required this.identityRecordKey,
|
||||
required this.identityPublicKey,
|
||||
required this.masterRecordKey,
|
||||
@ -473,8 +475,8 @@ class _$_IdentityMaster implements _IdentityMaster {
|
||||
required this.identitySignature,
|
||||
required this.masterSignature});
|
||||
|
||||
factory _$_IdentityMaster.fromJson(Map<String, dynamic> json) =>
|
||||
_$$_IdentityMasterFromJson(json);
|
||||
factory _$IdentityMasterImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$IdentityMasterImplFromJson(json);
|
||||
|
||||
// Private DHT record storing identity account mapping
|
||||
@override
|
||||
@ -504,7 +506,7 @@ class _$_IdentityMaster implements _IdentityMaster {
|
||||
bool operator ==(dynamic other) {
|
||||
return identical(this, other) ||
|
||||
(other.runtimeType == runtimeType &&
|
||||
other is _$_IdentityMaster &&
|
||||
other is _$IdentityMasterImpl &&
|
||||
(identical(other.identityRecordKey, identityRecordKey) ||
|
||||
other.identityRecordKey == identityRecordKey) &&
|
||||
(identical(other.identityPublicKey, identityPublicKey) ||
|
||||
@ -533,12 +535,13 @@ class _$_IdentityMaster implements _IdentityMaster {
|
||||
@JsonKey(ignore: true)
|
||||
@override
|
||||
@pragma('vm:prefer-inline')
|
||||
_$$_IdentityMasterCopyWith<_$_IdentityMaster> get copyWith =>
|
||||
__$$_IdentityMasterCopyWithImpl<_$_IdentityMaster>(this, _$identity);
|
||||
_$$IdentityMasterImplCopyWith<_$IdentityMasterImpl> get copyWith =>
|
||||
__$$IdentityMasterImplCopyWithImpl<_$IdentityMasterImpl>(
|
||||
this, _$identity);
|
||||
|
||||
@override
|
||||
Map<String, dynamic> toJson() {
|
||||
return _$$_IdentityMasterToJson(
|
||||
return _$$IdentityMasterImplToJson(
|
||||
this,
|
||||
);
|
||||
}
|
||||
@ -546,15 +549,16 @@ class _$_IdentityMaster implements _IdentityMaster {
|
||||
|
||||
abstract class _IdentityMaster implements IdentityMaster {
|
||||
const factory _IdentityMaster(
|
||||
{required final Typed<FixedEncodedString43> identityRecordKey,
|
||||
required final FixedEncodedString43 identityPublicKey,
|
||||
required final Typed<FixedEncodedString43> masterRecordKey,
|
||||
required final FixedEncodedString43 masterPublicKey,
|
||||
required final FixedEncodedString86 identitySignature,
|
||||
required final FixedEncodedString86 masterSignature}) = _$_IdentityMaster;
|
||||
{required final Typed<FixedEncodedString43> identityRecordKey,
|
||||
required final FixedEncodedString43 identityPublicKey,
|
||||
required final Typed<FixedEncodedString43> masterRecordKey,
|
||||
required final FixedEncodedString43 masterPublicKey,
|
||||
required final FixedEncodedString86 identitySignature,
|
||||
required final FixedEncodedString86 masterSignature}) =
|
||||
_$IdentityMasterImpl;
|
||||
|
||||
factory _IdentityMaster.fromJson(Map<String, dynamic> json) =
|
||||
_$_IdentityMaster.fromJson;
|
||||
_$IdentityMasterImpl.fromJson;
|
||||
|
||||
@override // Private DHT record storing identity account mapping
|
||||
Typed<FixedEncodedString43> get identityRecordKey;
|
||||
@ -570,6 +574,6 @@ abstract class _IdentityMaster implements IdentityMaster {
|
||||
FixedEncodedString86 get masterSignature;
|
||||
@override
|
||||
@JsonKey(ignore: true)
|
||||
_$$_IdentityMasterCopyWith<_$_IdentityMaster> get copyWith =>
|
||||
_$$IdentityMasterImplCopyWith<_$IdentityMasterImpl> get copyWith =>
|
||||
throw _privateConstructorUsedError;
|
||||
}
|
||||
|
@ -6,18 +6,20 @@ part of 'identity.dart';
|
||||
// JsonSerializableGenerator
|
||||
// **************************************************************************
|
||||
|
||||
_$_AccountRecordInfo _$$_AccountRecordInfoFromJson(Map<String, dynamic> json) =>
|
||||
_$_AccountRecordInfo(
|
||||
_$AccountRecordInfoImpl _$$AccountRecordInfoImplFromJson(
|
||||
Map<String, dynamic> json) =>
|
||||
_$AccountRecordInfoImpl(
|
||||
accountRecord: OwnedDHTRecordPointer.fromJson(json['account_record']),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_AccountRecordInfoToJson(
|
||||
_$_AccountRecordInfo instance) =>
|
||||
Map<String, dynamic> _$$AccountRecordInfoImplToJson(
|
||||
_$AccountRecordInfoImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'account_record': instance.accountRecord.toJson(),
|
||||
};
|
||||
|
||||
_$_Identity _$$_IdentityFromJson(Map<String, dynamic> json) => _$_Identity(
|
||||
_$IdentityImpl _$$IdentityImplFromJson(Map<String, dynamic> json) =>
|
||||
_$IdentityImpl(
|
||||
accountRecords: IMap<String, ISet<AccountRecordInfo>>.fromJson(
|
||||
json['account_records'] as Map<String, dynamic>,
|
||||
(value) => value as String,
|
||||
@ -25,7 +27,7 @@ _$_Identity _$$_IdentityFromJson(Map<String, dynamic> json) => _$_Identity(
|
||||
value, (value) => AccountRecordInfo.fromJson(value))),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_IdentityToJson(_$_Identity instance) =>
|
||||
Map<String, dynamic> _$$IdentityImplToJson(_$IdentityImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'account_records': instance.accountRecords.toJson(
|
||||
(value) => value,
|
||||
@ -35,8 +37,8 @@ Map<String, dynamic> _$$_IdentityToJson(_$_Identity instance) =>
|
||||
),
|
||||
};
|
||||
|
||||
_$_IdentityMaster _$$_IdentityMasterFromJson(Map<String, dynamic> json) =>
|
||||
_$_IdentityMaster(
|
||||
_$IdentityMasterImpl _$$IdentityMasterImplFromJson(Map<String, dynamic> json) =>
|
||||
_$IdentityMasterImpl(
|
||||
identityRecordKey:
|
||||
Typed<FixedEncodedString43>.fromJson(json['identity_record_key']),
|
||||
identityPublicKey:
|
||||
@ -49,7 +51,8 @@ _$_IdentityMaster _$$_IdentityMasterFromJson(Map<String, dynamic> json) =>
|
||||
masterSignature: FixedEncodedString86.fromJson(json['master_signature']),
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$_IdentityMasterToJson(_$_IdentityMaster instance) =>
|
||||
Map<String, dynamic> _$$IdentityMasterImplToJson(
|
||||
_$IdentityMasterImpl instance) =>
|
||||
<String, dynamic>{
|
||||
'identity_record_key': instance.identityRecordKey.toJson(),
|
||||
'identity_public_key': instance.identityPublicKey.toJson(),
|
||||
|
@ -6,6 +6,7 @@
|
||||
|
||||
#include "generated_plugin_registrant.h"
|
||||
|
||||
#include <pasteboard/pasteboard_plugin.h>
|
||||
#include <screen_retriever/screen_retriever_plugin.h>
|
||||
#include <smart_auth/smart_auth_plugin.h>
|
||||
#include <url_launcher_linux/url_launcher_plugin.h>
|
||||
@ -13,6 +14,9 @@
|
||||
#include <window_manager/window_manager_plugin.h>
|
||||
|
||||
void fl_register_plugins(FlPluginRegistry* registry) {
|
||||
g_autoptr(FlPluginRegistrar) pasteboard_registrar =
|
||||
fl_plugin_registry_get_registrar_for_plugin(registry, "PasteboardPlugin");
|
||||
pasteboard_plugin_register_with_registrar(pasteboard_registrar);
|
||||
g_autoptr(FlPluginRegistrar) screen_retriever_registrar =
|
||||
fl_plugin_registry_get_registrar_for_plugin(registry, "ScreenRetrieverPlugin");
|
||||
screen_retriever_plugin_register_with_registrar(screen_retriever_registrar);
|
||||
|
@ -3,6 +3,7 @@
|
||||
#
|
||||
|
||||
list(APPEND FLUTTER_PLUGIN_LIST
|
||||
pasteboard
|
||||
screen_retriever
|
||||
smart_auth
|
||||
url_launcher_linux
|
||||
|
@ -5,6 +5,8 @@
|
||||
import FlutterMacOS
|
||||
import Foundation
|
||||
|
||||
import mobile_scanner
|
||||
import pasteboard
|
||||
import path_provider_foundation
|
||||
import screen_retriever
|
||||
import share_plus
|
||||
@ -16,6 +18,8 @@ import veilid
|
||||
import window_manager
|
||||
|
||||
func RegisterGeneratedPlugins(registry: FlutterPluginRegistry) {
|
||||
MobileScannerPlugin.register(with: registry.registrar(forPlugin: "MobileScannerPlugin"))
|
||||
PasteboardPlugin.register(with: registry.registrar(forPlugin: "PasteboardPlugin"))
|
||||
PathProviderPlugin.register(with: registry.registrar(forPlugin: "PathProviderPlugin"))
|
||||
ScreenRetrieverPlugin.register(with: registry.registrar(forPlugin: "ScreenRetrieverPlugin"))
|
||||
SharePlusMacosPlugin.register(with: registry.registrar(forPlugin: "SharePlusMacosPlugin"))
|
||||
|
@ -3,6 +3,10 @@ PODS:
|
||||
- FMDB (2.7.5):
|
||||
- FMDB/standard (= 2.7.5)
|
||||
- FMDB/standard (2.7.5)
|
||||
- mobile_scanner (3.0.0):
|
||||
- FlutterMacOS
|
||||
- pasteboard (0.0.1):
|
||||
- FlutterMacOS
|
||||
- path_provider_foundation (0.0.1):
|
||||
- Flutter
|
||||
- FlutterMacOS
|
||||
@ -27,6 +31,8 @@ PODS:
|
||||
|
||||
DEPENDENCIES:
|
||||
- FlutterMacOS (from `Flutter/ephemeral`)
|
||||
- mobile_scanner (from `Flutter/ephemeral/.symlinks/plugins/mobile_scanner/macos`)
|
||||
- pasteboard (from `Flutter/ephemeral/.symlinks/plugins/pasteboard/macos`)
|
||||
- path_provider_foundation (from `Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin`)
|
||||
- screen_retriever (from `Flutter/ephemeral/.symlinks/plugins/screen_retriever/macos`)
|
||||
- share_plus (from `Flutter/ephemeral/.symlinks/plugins/share_plus/macos`)
|
||||
@ -44,6 +50,10 @@ SPEC REPOS:
|
||||
EXTERNAL SOURCES:
|
||||
FlutterMacOS:
|
||||
:path: Flutter/ephemeral
|
||||
mobile_scanner:
|
||||
:path: Flutter/ephemeral/.symlinks/plugins/mobile_scanner/macos
|
||||
pasteboard:
|
||||
:path: Flutter/ephemeral/.symlinks/plugins/pasteboard/macos
|
||||
path_provider_foundation:
|
||||
:path: Flutter/ephemeral/.symlinks/plugins/path_provider_foundation/darwin
|
||||
screen_retriever:
|
||||
@ -66,6 +76,8 @@ EXTERNAL SOURCES:
|
||||
SPEC CHECKSUMS:
|
||||
FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24
|
||||
FMDB: 2ce00b547f966261cd18927a3ddb07cb6f3db82a
|
||||
mobile_scanner: ed7618fb749adc6574563e053f3b8e5002c13994
|
||||
pasteboard: 9b69dba6fedbb04866be632205d532fe2f6b1d99
|
||||
path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943
|
||||
screen_retriever: 59634572a57080243dd1bf715e55b6c54f241a38
|
||||
share_plus: 76dd39142738f7a68dd57b05093b5e8193f220f7
|
||||
|
202
pubspec.lock
202
pubspec.lock
@ -45,10 +45,10 @@ packages:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: archive
|
||||
sha256: e0902a06f0e00414e4e3438a084580161279f137aeb862274710f29ec10cf01e
|
||||
sha256: "20071638cbe4e5964a427cfa0e86dce55d060bc7d82d56f3554095d7239a8765"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "3.3.9"
|
||||
version: "3.4.2"
|
||||
args:
|
||||
dependency: transitive
|
||||
description:
|
||||
@ -133,10 +133,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: build_resolvers
|
||||
sha256: d912852cce27c9e80a93603db721c267716894462e7033165178b91138587972
|
||||
sha256: "0713a05b0386bd97f9e63e78108805a4feca5898a4b821d6610857f10c91e975"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.3.2"
|
||||
version: "2.4.0"
|
||||
build_runner:
|
||||
dependency: "direct dev"
|
||||
description:
|
||||
@ -149,10 +149,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: build_runner_core
|
||||
sha256: "6d6ee4276b1c5f34f21fdf39425202712d2be82019983d52f351c94aafbc2c41"
|
||||
sha256: c9e32d21dd6626b5c163d48b037ce906bbe428bc23ab77bcd77bb21e593b6185
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "7.2.10"
|
||||
version: "7.2.11"
|
||||
built_collection:
|
||||
dependency: transitive
|
||||
description:
|
||||
@ -173,26 +173,66 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: cached_network_image
|
||||
sha256: fd3d0dc1d451f9a252b32d95d3f0c3c487bc41a75eba2e6097cb0b9c71491b15
|
||||
sha256: f98972704692ba679db144261172a8e20feb145636c617af0eb4022132a6797f
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "3.2.3"
|
||||
version: "3.3.0"
|
||||
cached_network_image_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: cached_network_image_platform_interface
|
||||
sha256: bb2b8403b4ccdc60ef5f25c70dead1f3d32d24b9d6117cfc087f496b178594a7
|
||||
sha256: "56aa42a7a01e3c9db8456d9f3f999931f1e05535b5a424271e9a38cabf066613"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.0.0"
|
||||
version: "3.0.0"
|
||||
cached_network_image_web:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: cached_network_image_web
|
||||
sha256: b8eb814ebfcb4dea049680f8c1ffb2df399e4d03bf7a352c775e26fa06e02fa0
|
||||
sha256: "759b9a9f8f6ccbb66c185df805fac107f05730b1dab9c64626d1008cca532257"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.0.2"
|
||||
version: "1.1.0"
|
||||
camera:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: camera
|
||||
sha256: f63f2687fb1795c36f7c57b18a03071880eabb0fd8b5291b0fcd3fb979cb0fb1
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.10.5+4"
|
||||
camera_android:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: camera_android
|
||||
sha256: "796438641b13bc26f6d9fe07e183b708e856db21ddeb9ec99de5591286e1910c"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.10.8+10"
|
||||
camera_avfoundation:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: camera_avfoundation
|
||||
sha256: dde42d19ad4cdf79287f9e410599db72beaec7e505787dc6abfd0ce5b526e9c0
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.9.13+5"
|
||||
camera_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: camera_platform_interface
|
||||
sha256: "8734d1c682f034bdb12d0d6ff379b0535a9b8e44266b530025bf8266d6a62f28"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.5.2"
|
||||
camera_web:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: camera_web
|
||||
sha256: d4c2c571c7af04f8b10702ca16bb9ed2a26e64534171e8f75c9349b2c004d8f1
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.3.2+3"
|
||||
change_case:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -217,6 +257,14 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.3.1"
|
||||
charset:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: charset
|
||||
sha256: e8346cf597b6cea278d2d3a29b2d01ed8fb325aad718e70f22b0cb653cb31700
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.2.0"
|
||||
checked_yaml:
|
||||
dependency: transitive
|
||||
description:
|
||||
@ -269,10 +317,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: code_builder
|
||||
sha256: "315a598c7fbe77f22de1c9da7cfd6fd21816312f16ffa124453b4fc679e540f1"
|
||||
sha256: "1be9be30396d7e4c0db42c35ea6ccd7cc6a1e19916b5dc64d6ac216b5544d677"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "4.6.0"
|
||||
version: "4.7.0"
|
||||
collection:
|
||||
dependency: transitive
|
||||
description:
|
||||
@ -422,14 +470,6 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "4.2.0+1"
|
||||
flutter_blurhash:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: flutter_blurhash
|
||||
sha256: "05001537bd3fac7644fa6558b09ec8c0a3f2eba78c0765f88912882b1331a5c6"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.7.0"
|
||||
flutter_cache_manager:
|
||||
dependency: transitive
|
||||
description:
|
||||
@ -499,14 +539,22 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.2.1"
|
||||
flutter_plugin_android_lifecycle:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: flutter_plugin_android_lifecycle
|
||||
sha256: f185ac890306b5779ecbd611f52502d8d4d63d27703ef73161ca0407e815f02c
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.0.16"
|
||||
flutter_riverpod:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: flutter_riverpod
|
||||
sha256: "1bd39b04f1bcd217a969589777ca6bd642d116e3e5de65c3e6a8e8bdd8b178ec"
|
||||
sha256: fcea39b84b666649280f6f678bc0bb479253bf865abc0387a8b11dac6477bf92
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.4.0"
|
||||
version: "2.4.1"
|
||||
flutter_slidable:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -561,10 +609,10 @@ packages:
|
||||
dependency: "direct dev"
|
||||
description:
|
||||
name: freezed
|
||||
sha256: "83462cfc33dc9680533a7f3a4a6ab60aa94f287db5f4ee6511248c22833c497f"
|
||||
sha256: be7826ed5d87e98c924a839542674fc14edbcb3e4fc0adbc058d680f2b241837
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.4.2"
|
||||
version: "2.4.3"
|
||||
freezed_annotation:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -601,10 +649,10 @@ packages:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: go_router
|
||||
sha256: "24d89757552a78615d6e65c7bc206740f94ca95a12ecf189d883394d34c9d9bd"
|
||||
sha256: "4b58412b92bd7d588f904425ef6d41a017da1f097e5e9428d2c27d275777e16e"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "11.0.0"
|
||||
version: "11.1.1"
|
||||
graphs:
|
||||
dependency: transitive
|
||||
description:
|
||||
@ -617,10 +665,10 @@ packages:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: hooks_riverpod
|
||||
sha256: ad7b877c3687e38764633d221a1f65491bc7a540e724101e9a404a84db2a4276
|
||||
sha256: a5242fee89736eaf7e5565c271e2d87b0aeb9953ee936de819339366aebc6882
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.4.0"
|
||||
version: "2.4.1"
|
||||
html:
|
||||
dependency: transitive
|
||||
description:
|
||||
@ -657,18 +705,18 @@ packages:
|
||||
dependency: "direct dev"
|
||||
description:
|
||||
name: icons_launcher
|
||||
sha256: af05397792f6d82b93375a8a0253b8db0d3f816ef1dd1bf5c35cbab55321d327
|
||||
sha256: "69de6373013966ea033f4cefbbbae258ccbfe790a6cfc69796cb33fda996298a"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.1.3"
|
||||
version: "2.1.4"
|
||||
image:
|
||||
dependency: transitive
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: image
|
||||
sha256: a72242c9a0ffb65d03de1b7113bc4e189686fc07c7147b8b41811d0dd0e0d9bf
|
||||
sha256: "028f61960d56f26414eb616b48b04eb37d700cbe477b7fb09bf1d7ce57fd9271"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "4.0.17"
|
||||
version: "4.1.3"
|
||||
intl:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -773,14 +821,22 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.0.4"
|
||||
mobile_scanner:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: mobile_scanner
|
||||
sha256: "2fbc3914fe625e196c64ea8ffc4084cd36781d2be276d4d5923b11af3b5d44ff"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "3.4.1"
|
||||
motion_toast:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: motion_toast
|
||||
sha256: f27cfcd39c6a0c433670fb20e4add55c42f925a5382b25f58e917c054d47a624
|
||||
sha256: "5742e33ec2f11210f5269294304fb9bd0f30eace78ad23925eb9306dce7763c9"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.7.8"
|
||||
version: "2.7.9"
|
||||
mutex:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -793,10 +849,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: octo_image
|
||||
sha256: "107f3ed1330006a3bea63615e81cf637433f5135a52466c7caa0e7152bca9143"
|
||||
sha256: "45b40f99622f11901238e18d48f5f12ea36426d8eced9f4cbf58479c7aa2430d"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.0.2"
|
||||
version: "2.0.0"
|
||||
package_config:
|
||||
dependency: transitive
|
||||
description:
|
||||
@ -805,6 +861,14 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.1.0"
|
||||
pasteboard:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: pasteboard
|
||||
sha256: "1c8b6a8b3f1d12e55d4e9404433cda1b4abe66db6b17bc2d2fb5965772c04674"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.2.0"
|
||||
path:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -965,6 +1029,14 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "3.0.1"
|
||||
qr_code_dart_scan:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: qr_code_dart_scan
|
||||
sha256: "4b5222c044700f9ecb3d1c39ca9c5cf433b508f81a0649b768628d3b5ee2ffc4"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.7.2"
|
||||
qr_flutter:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -981,6 +1053,14 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.0.2"
|
||||
quiver:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: quiver
|
||||
sha256: b1c1ac5ce6688d77f65f3375a9abb9319b3cb32486bdc7a1e0fdf004d7ba4e47
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "3.2.1"
|
||||
radix_colors:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -993,42 +1073,42 @@ packages:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: reorderable_grid
|
||||
sha256: e482ecb05c0a8c45a383d19b39cdc5c3c02f16339c6699c81d5978e602409fff
|
||||
sha256: a1322139ec59134e2180acb1b84fe436ea927ce2712ae01da511614131a07d85
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "1.0.7"
|
||||
version: "1.0.8"
|
||||
riverpod:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: riverpod
|
||||
sha256: a600120d6f213a9922860eea1abc32597436edd5b2c4e73b91410f8c2af67d22
|
||||
sha256: ff676bd8a715c7085692fe4919564f78fb90d33b10a1c5c14e740581857cc914
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.4.0"
|
||||
version: "2.4.1"
|
||||
riverpod_analyzer_utils:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: riverpod_analyzer_utils
|
||||
sha256: aa216069d72f5478126029fa555874b4b38119f17e3f0f6c93fd63365f74502d
|
||||
sha256: d72d7096964baf288b55619fe48100001fc4564ab7923ed0a7f5c7650e03c0d6
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.3.3"
|
||||
version: "0.3.4"
|
||||
riverpod_annotation:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: riverpod_annotation
|
||||
sha256: "6294fe7e7d1875f32bdf04c8fce7620e718070273703097847df8f3bf16995ea"
|
||||
sha256: aeeb1eb6ccf2d779f2ef730e6d96d560316b677662222316779a8cf0a94ee317
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.1.5"
|
||||
version: "2.1.6"
|
||||
riverpod_generator:
|
||||
dependency: "direct dev"
|
||||
description:
|
||||
name: riverpod_generator
|
||||
sha256: d132b1ccb476e60f99989caa6ba9b1c4d88409806c93d880d1633c60c382454d
|
||||
sha256: "5b36ad2f2b562cffb37212e8d59390b25499bf045b732276e30a207b16a25f61"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.3.2"
|
||||
version: "2.3.3"
|
||||
rxdart:
|
||||
dependency: transitive
|
||||
description:
|
||||
@ -1057,10 +1137,10 @@ packages:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: searchable_listview
|
||||
sha256: "5de53276af125e5889e9b1d10128f90a0ad0db56c877c2664d8dd3b1aeab5379"
|
||||
sha256: e1ba75eda1460c24648e54c543843a7142811ea4966c2106e0cc6792128b7127
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "2.7.0"
|
||||
version: "2.7.1"
|
||||
share_plus:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -1485,10 +1565,10 @@ packages:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: win32
|
||||
sha256: c97defd418eef4ec88c0d1652cdce84b9f7b63dd7198e266d06ac1710d527067
|
||||
sha256: "350a11abd2d1d97e0cc7a28a81b781c08002aa2864d9e3f192ca0ffa18b06ed3"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "5.0.8"
|
||||
version: "5.0.9"
|
||||
window_manager:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
@ -1521,6 +1601,22 @@ packages:
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "3.1.2"
|
||||
zxing2:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: zxing2
|
||||
sha256: "1e141568c9646bc262fa75aacf739bc151ef6ad0226997c0016cc3da358a1bbc"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.2.0"
|
||||
zxing_lib:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: zxing_lib
|
||||
sha256: "84f6ec19b04dd54bc0b25c539c7c3567a5f9e872e3feb23763df027a1f855c11"
|
||||
url: "https://pub.dev"
|
||||
source: hosted
|
||||
version: "0.9.0"
|
||||
sdks:
|
||||
dart: ">=3.1.0 <4.0.0"
|
||||
flutter: ">=3.13.0"
|
||||
|
@ -40,16 +40,20 @@ dependencies:
|
||||
freezed_annotation: ^2.2.0
|
||||
go_router: ^11.0.0
|
||||
hooks_riverpod: ^2.1.3
|
||||
image: ^4.1.3
|
||||
intl: ^0.18.0
|
||||
json_annotation: ^4.8.1
|
||||
loggy: ^2.0.3
|
||||
mobile_scanner: ^3.4.1
|
||||
motion_toast: ^2.7.8
|
||||
mutex: ^3.0.1
|
||||
pasteboard: ^0.2.0
|
||||
path: ^1.8.2
|
||||
path_provider: ^2.0.11
|
||||
pinput: ^3.0.1
|
||||
preload_page_view: ^0.2.0
|
||||
protobuf: ^3.0.0
|
||||
qr_code_dart_scan: ^0.7.2
|
||||
qr_flutter: ^4.1.0
|
||||
quickalert: ^1.0.1
|
||||
radix_colors: ^1.0.4
|
||||
@ -66,6 +70,7 @@ dependencies:
|
||||
# veilid: ^0.0.1
|
||||
path: ../veilid/veilid-flutter
|
||||
window_manager: ^0.3.5
|
||||
zxing2: ^0.2.0
|
||||
|
||||
dev_dependencies:
|
||||
build_runner: ^2.4.6
|
||||
|
@ -6,6 +6,7 @@
|
||||
|
||||
#include "generated_plugin_registrant.h"
|
||||
|
||||
#include <pasteboard/pasteboard_plugin.h>
|
||||
#include <screen_retriever/screen_retriever_plugin.h>
|
||||
#include <share_plus/share_plus_windows_plugin_c_api.h>
|
||||
#include <smart_auth/smart_auth_plugin.h>
|
||||
@ -14,6 +15,8 @@
|
||||
#include <window_manager/window_manager_plugin.h>
|
||||
|
||||
void RegisterPlugins(flutter::PluginRegistry* registry) {
|
||||
PasteboardPluginRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("PasteboardPlugin"));
|
||||
ScreenRetrieverPluginRegisterWithRegistrar(
|
||||
registry->GetRegistrarForPlugin("ScreenRetrieverPlugin"));
|
||||
SharePlusWindowsPluginCApiRegisterWithRegistrar(
|
||||
|
@ -3,6 +3,7 @@
|
||||
#
|
||||
|
||||
list(APPEND FLUTTER_PLUGIN_LIST
|
||||
pasteboard
|
||||
screen_retriever
|
||||
share_plus
|
||||
smart_auth
|
||||
|
Loading…
Reference in New Issue
Block a user