diff --git a/lib/models/app.dart b/lib/models/app.dart index e6f2ae2..ff07953 100644 --- a/lib/models/app.dart +++ b/lib/models/app.dart @@ -10,7 +10,6 @@ import 'package:convert/convert.dart'; import 'package:crypto/crypto.dart'; import 'package:flutter_data/flutter_data.dart'; import 'package:install_plugin/install_plugin.dart'; -import 'package:json_annotation/json_annotation.dart'; import 'package:path_provider/path_provider.dart'; import 'package:permission_handler/permission_handler.dart'; import 'package:purplebase/purplebase.dart'; @@ -27,7 +26,6 @@ part 'app.g.dart'; const kAndroidMimeType = 'application/vnd.android.package-archive'; -@JsonSerializable() @DataAdapter([NostrAdapter, AppAdapter]) class App extends BaseApp with DataModelMixin { final HasMany releases; @@ -35,16 +33,24 @@ class App extends BaseApp with DataModelMixin { final BelongsTo developer; App( - {super.id, - super.pubkey, - super.createdAt, + {super.createdAt, super.content, super.tags, - super.signature, required this.developer, required this.releases, required this.signer}); + App.fromJson(super.map) + : developer = + BelongsTo.fromJson(map['developer'] as Map), + releases = + HasMany.fromJson(map['releases'] as Map), + signer = + BelongsTo.fromJson(map['signer'] as Map), + super.fromJson(); + + Map toJson() => super.toMap(); + String? get installedVersion => DataModel.adapterFor(this) .ref .read(installedAppProvider)[id!.toString()] @@ -59,7 +65,7 @@ class App extends BaseApp with DataModelMixin { return releases.ordered.firstOrNull?.artifacts .where((a) => a.mimeType == 'application/vnd.android.package-archive' && - a.architectures.contains('arm64-v8a')) + a.platforms.contains('android-arm64-v8a')) .firstOrNull; } @@ -220,8 +226,9 @@ mixin AppAdapter on Adapter { Future> loadAppModels(Map params) async { final includes = params.remove('includes') ?? false; final apps = await super.findAll(params: params); - final releases = - await ref.releases.findAll(params: {'#a': apps.map((app) => app.aTag)}); + final releases = await ref.releases.findAll(params: { + '#a': apps.map((app) => app.getReplaceableEventLink().formatted) + }); final metadataIds = releases.map((r) => r.tagMap['e']).nonNulls.expand((_) => _); @@ -250,18 +257,25 @@ mixin AppAdapter on Adapter { OnSuccessAll? onSuccess, OnErrorAll? onError, DataRequestLabel? label}) async { + final m1 = DateTime.now().millisecondsSinceEpoch; + print('enters findall'); final map = await getInstalledAppsMap(defer: true); + final m2 = DateTime.now().millisecondsSinceEpoch; if (params!.containsKey('installed')) { if (map.keys.isNotEmpty) { params['#d'] = map.keys; params.remove('installed'); print('filtering by installed ${params['#d']}'); - return await loadAppModels(params); + final z = await loadAppModels(params); + final m3 = DateTime.now().millisecondsSinceEpoch; + print('finish ${m3 - m1} ${m2 - m1}'); + return z; } } - - return await loadAppModels(params); + print('calling bottom loadappmodels'); + final loadedAppModels = await loadAppModels(params); + return loadedAppModels; } @override @@ -334,6 +348,13 @@ mixin AppAdapter on Adapter { } return super.deserialize(data); } + + @override + App deserializeLocal(map, {String? key}) { + return App.fromJson(map); + // map = transformDeserialize(map); + // return internalWrapStopInit(() => _$AppFromJson(map), key: key); + } } Future _isHashMismatch(String path, String hash) async { diff --git a/lib/models/app.g.dart b/lib/models/app.g.dart index 06aef3b..03549df 100644 --- a/lib/models/app.g.dart +++ b/lib/models/app.g.dart @@ -37,12 +37,12 @@ mixin _$AppAdapter on Adapter { @override App deserializeLocal(map, {String? key}) { map = transformDeserialize(map); - return internalWrapStopInit(() => _$AppFromJson(map), key: key); + return internalWrapStopInit(() => App.fromJson(map), key: key); } @override Map serializeLocal(model, {bool withRelationships = true}) { - final map = _$AppToJson(model); + final map = model.toJson(); return transformSerialize(map, withRelationships: withRelationships); } } @@ -82,39 +82,3 @@ extension AppRelationshipGraphNodeX on RelationshipGraphNode { parent: this is RelationshipMeta ? this as RelationshipMeta : null); } } - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -App _$AppFromJson(Map json) => App( - id: json['id'], - pubkey: json['pubkey'] as String?, - createdAt: json['createdAt'] == null - ? null - : DateTime.parse(json['createdAt'] as String), - content: json['content'] as String? ?? '', - tags: (json['tags'] as List?) - ?.map( - (e) => (e as List).map((e) => e as String).toList()) - .toList() ?? - const [], - signature: json['signature'] as String?, - developer: - BelongsTo.fromJson(json['developer'] as Map), - releases: - HasMany.fromJson(json['releases'] as Map), - signer: BelongsTo.fromJson(json['signer'] as Map), - ); - -Map _$AppToJson(App instance) => { - 'id': instance.id, - 'pubkey': instance.pubkey, - 'createdAt': instance.createdAt.toIso8601String(), - 'content': instance.content, - 'tags': instance.tags, - 'signature': instance.signature, - 'releases': instance.releases, - 'signer': instance.signer, - 'developer': instance.developer, - }; diff --git a/lib/models/app_curation_set.dart b/lib/models/app_curation_set.dart index 7240911..63c58ec 100644 --- a/lib/models/app_curation_set.dart +++ b/lib/models/app_curation_set.dart @@ -1,25 +1,22 @@ import 'package:flutter_data/flutter_data.dart'; -import 'package:json_annotation/json_annotation.dart'; import 'package:purplebase/purplebase.dart'; import 'package:zapstore/models/app.dart'; import 'package:zapstore/models/nostr_adapter.dart'; part 'app_curation_set.g.dart'; -@JsonSerializable() @DataAdapter([NostrAdapter, AppCurationSetAdapter]) class AppCurationSet extends BaseAppCurationSet with DataModelMixin { final HasMany apps; - AppCurationSet( - {super.id, - super.pubkey, - super.createdAt, - super.content, - super.tags, - super.signature, - required this.apps}); + AppCurationSet({required this.apps}); + + AppCurationSet.fromJson(super.map) + : apps = HasMany.fromJson(map['app'] as Map), + super.fromJson(); + + Map toJson() => super.toMap(); } mixin AppCurationSetAdapter on Adapter { diff --git a/lib/models/app_curation_set.g.dart b/lib/models/app_curation_set.g.dart index 3d72510..abf385e 100644 --- a/lib/models/app_curation_set.g.dart +++ b/lib/models/app_curation_set.g.dart @@ -26,12 +26,12 @@ mixin _$AppCurationSetAdapter on Adapter { @override AppCurationSet deserializeLocal(map, {String? key}) { map = transformDeserialize(map); - return internalWrapStopInit(() => _$AppCurationSetFromJson(map), key: key); + return internalWrapStopInit(() => AppCurationSet.fromJson(map), key: key); } @override Map serializeLocal(model, {bool withRelationships = true}) { - final map = _$AppCurationSetToJson(model); + final map = model.toJson(); return transformSerialize(map, withRelationships: withRelationships); } } @@ -64,35 +64,3 @@ extension AppCurationSetRelationshipGraphNodeX parent: this is RelationshipMeta ? this as RelationshipMeta : null); } } - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -AppCurationSet _$AppCurationSetFromJson(Map json) => - AppCurationSet( - id: json['id'], - pubkey: json['pubkey'] as String?, - createdAt: json['createdAt'] == null - ? null - : DateTime.parse(json['createdAt'] as String), - content: json['content'] as String? ?? '', - tags: (json['tags'] as List?) - ?.map( - (e) => (e as List).map((e) => e as String).toList()) - .toList() ?? - const [], - signature: json['signature'] as String?, - apps: HasMany.fromJson(json['apps'] as Map), - ); - -Map _$AppCurationSetToJson(AppCurationSet instance) => - { - 'id': instance.id, - 'pubkey': instance.pubkey, - 'createdAt': instance.createdAt.toIso8601String(), - 'content': instance.content, - 'tags': instance.tags, - 'signature': instance.signature, - 'apps': instance.apps, - }; diff --git a/lib/models/feedback.dart b/lib/models/feedback.dart index b411c09..eab3b66 100644 --- a/lib/models/feedback.dart +++ b/lib/models/feedback.dart @@ -1,11 +1,10 @@ import 'package:purplebase/purplebase.dart'; -class AppFeedback extends BaseEvent { +class AppFeedback extends BaseEvent { @override int get kind => 1011; AppFeedback({ - super.id, - super.content, - }); + required String content, + }) : super(content: content); } diff --git a/lib/models/file_metadata.dart b/lib/models/file_metadata.dart index 5cf02e4..2164554 100644 --- a/lib/models/file_metadata.dart +++ b/lib/models/file_metadata.dart @@ -1,5 +1,4 @@ import 'package:flutter_data/flutter_data.dart'; -import 'package:json_annotation/json_annotation.dart'; import 'package:purplebase/purplebase.dart'; import 'package:zapstore/models/nostr_adapter.dart'; import 'package:zapstore/models/release.dart'; @@ -7,7 +6,6 @@ import 'package:zapstore/models/user.dart'; part 'file_metadata.g.dart'; -@JsonSerializable() @DataAdapter([NostrAdapter, FileMetadataAdapter]) class FileMetadata extends BaseFileMetadata with DataModelMixin { final BelongsTo author; @@ -15,15 +13,28 @@ class FileMetadata extends BaseFileMetadata with DataModelMixin { final BelongsTo signer; FileMetadata( - {super.id, - super.pubkey, - super.createdAt, + {super.createdAt, super.content, super.tags, - super.signature, required this.author, required this.release, required this.signer}); + + FileMetadata.fromJson(super.map) + : author = + BelongsTo.fromJson(map['author'] as Map), + release = + BelongsTo.fromJson(map['release'] as Map), + signer = + BelongsTo.fromJson(map['signer'] as Map), + super.fromJson(); + + Map toJson() => super.toMap(); + + // String? get version => tagMap['version']?.firstOrNull; + int? get versionCode => + int.tryParse(tagMap['version_code']?.firstOrNull ?? ''); + String? get apkSignatureHash => tagMap['apk_signature_hash']?.firstOrNull; } mixin FileMetadataAdapter on Adapter { diff --git a/lib/models/file_metadata.g.dart b/lib/models/file_metadata.g.dart index 0701934..0fc4648 100644 --- a/lib/models/file_metadata.g.dart +++ b/lib/models/file_metadata.g.dart @@ -38,12 +38,12 @@ mixin _$FileMetadataAdapter on Adapter { @override FileMetadata deserializeLocal(map, {String? key}) { map = transformDeserialize(map); - return internalWrapStopInit(() => _$FileMetadataFromJson(map), key: key); + return internalWrapStopInit(() => FileMetadata.fromJson(map), key: key); } @override Map serializeLocal(model, {bool withRelationships = true}) { - final map = _$FileMetadataToJson(model); + final map = model.toJson(); return transformSerialize(map, withRelationships: withRelationships); } } @@ -86,39 +86,3 @@ extension FileMetadataRelationshipGraphNodeX parent: this is RelationshipMeta ? this as RelationshipMeta : null); } } - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -FileMetadata _$FileMetadataFromJson(Map json) => FileMetadata( - id: json['id'], - pubkey: json['pubkey'] as String?, - createdAt: json['createdAt'] == null - ? null - : DateTime.parse(json['createdAt'] as String), - content: json['content'] as String? ?? '', - tags: (json['tags'] as List?) - ?.map( - (e) => (e as List).map((e) => e as String).toList()) - .toList() ?? - const [], - signature: json['signature'] as String?, - author: BelongsTo.fromJson(json['author'] as Map), - release: - BelongsTo.fromJson(json['release'] as Map), - signer: BelongsTo.fromJson(json['signer'] as Map), - ); - -Map _$FileMetadataToJson(FileMetadata instance) => - { - 'id': instance.id, - 'pubkey': instance.pubkey, - 'createdAt': instance.createdAt.toIso8601String(), - 'content': instance.content, - 'tags': instance.tags, - 'signature': instance.signature, - 'author': instance.author, - 'release': instance.release, - 'signer': instance.signer, - }; diff --git a/lib/models/nostr_adapter.dart b/lib/models/nostr_adapter.dart index 93289c8..7c2de67 100644 --- a/lib/models/nostr_adapter.dart +++ b/lib/models/nostr_adapter.dart @@ -2,8 +2,9 @@ import 'package:flutter_data/flutter_data.dart'; import 'package:purplebase/purplebase.dart'; mixin NostrAdapter> on Adapter { - late final RelayMessageNotifier notifier = - ref.read(relayMessageNotifierProvider.notifier); + // NOTE: it is very important to use const in the argument to preserve equality + RelayMessageNotifier get relay => ref.read( + relayMessageNotifierProvider(const ['wss://relay.zap.store']).notifier); int get kind { return BaseEvent.kindForType(internalType)!; @@ -11,7 +12,6 @@ mixin NostrAdapter> on Adapter { @override DeserializedData deserialize(Object? data, {String? key}) { - // throw 'a'; final list = data is Iterable ? data : [data as Map]; final models = []; final included = []; @@ -32,7 +32,7 @@ mixin NostrAdapter> on Adapter { } // Collect models for current kind and included for others - final eventType = BaseEvent.kinds[kind]!; + final eventType = BaseEvent.typeForKind(kind)!; if (eventType == internalType) { final newData = super.deserialize(map); models.addAll(newData.models as Iterable); @@ -64,8 +64,7 @@ mixin NostrAdapter> on Adapter { tags: params ?? {}, ); - final result = - await notifier.query(req, relayUrls: ['wss://relay.zap.store']); + final result = await relay.queryRaw(req); final deserialized = await deserializeAsync(result, save: true); return deserialized.models; } diff --git a/lib/models/release.dart b/lib/models/release.dart index 81886ba..e7cbe29 100644 --- a/lib/models/release.dart +++ b/lib/models/release.dart @@ -1,6 +1,5 @@ import 'package:collection/collection.dart'; import 'package:flutter_data/flutter_data.dart'; -import 'package:json_annotation/json_annotation.dart'; import 'package:purplebase/purplebase.dart'; import 'package:zapstore/models/app.dart'; import 'package:zapstore/models/file_metadata.dart'; @@ -9,7 +8,6 @@ import 'package:zapstore/models/user.dart'; part 'release.g.dart'; -@JsonSerializable() @DataAdapter([NostrAdapter, ReleaseAdapter]) class Release extends BaseRelease with DataModelMixin { final HasMany artifacts; @@ -17,15 +15,22 @@ class Release extends BaseRelease with DataModelMixin { final BelongsTo signer; Release( - {super.id, - super.pubkey, - super.createdAt, + {super.createdAt, super.content, super.tags, - super.signature, required this.artifacts, required this.app, required this.signer}); + + Release.fromJson(super.map) + : app = BelongsTo.fromJson(map['app'] as Map), + artifacts = HasMany.fromJson( + map['artifacts'] as Map), + signer = + BelongsTo.fromJson(map['signer'] as Map), + super.fromJson(); + + Map toJson() => super.toMap(); } mixin ReleaseAdapter on Adapter { @@ -48,5 +53,5 @@ mixin ReleaseAdapter on Adapter { extension HasManyReleaseX on HasMany { List get ordered => - toList().sorted((a, b) => b.createdAt.compareTo(a.createdAt)); + toList().sorted((a, b) => b.createdAt!.compareTo(a.createdAt!)); } diff --git a/lib/models/release.g.dart b/lib/models/release.g.dart index f163855..ba92ea8 100644 --- a/lib/models/release.g.dart +++ b/lib/models/release.g.dart @@ -39,12 +39,12 @@ mixin _$ReleaseAdapter on Adapter { @override Release deserializeLocal(map, {String? key}) { map = transformDeserialize(map); - return internalWrapStopInit(() => _$ReleaseFromJson(map), key: key); + return internalWrapStopInit(() => Release.fromJson(map), key: key); } @override Map serializeLocal(model, {bool withRelationships = true}) { - final map = _$ReleaseToJson(model); + final map = model.toJson(); return transformSerialize(map, withRelationships: withRelationships); } } @@ -84,38 +84,3 @@ extension ReleaseRelationshipGraphNodeX on RelationshipGraphNode { parent: this is RelationshipMeta ? this as RelationshipMeta : null); } } - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -Release _$ReleaseFromJson(Map json) => Release( - id: json['id'], - pubkey: json['pubkey'] as String?, - createdAt: json['createdAt'] == null - ? null - : DateTime.parse(json['createdAt'] as String), - content: json['content'] as String? ?? '', - tags: (json['tags'] as List?) - ?.map( - (e) => (e as List).map((e) => e as String).toList()) - .toList() ?? - const [], - signature: json['signature'] as String?, - artifacts: HasMany.fromJson( - json['artifacts'] as Map), - app: BelongsTo.fromJson(json['app'] as Map), - signer: BelongsTo.fromJson(json['signer'] as Map), - ); - -Map _$ReleaseToJson(Release instance) => { - 'id': instance.id, - 'pubkey': instance.pubkey, - 'createdAt': instance.createdAt.toIso8601String(), - 'content': instance.content, - 'tags': instance.tags, - 'signature': instance.signature, - 'artifacts': instance.artifacts, - 'app': instance.app, - 'signer': instance.signer, - }; diff --git a/lib/models/user.dart b/lib/models/user.dart index 5d0fc69..730e3a7 100644 --- a/lib/models/user.dart +++ b/lib/models/user.dart @@ -2,25 +2,28 @@ import 'dart:convert'; import 'package:collection/collection.dart'; import 'package:flutter_data/flutter_data.dart'; -import 'package:json_annotation/json_annotation.dart'; import 'package:purplebase/purplebase.dart'; import 'package:zapstore/models/nostr_adapter.dart'; part 'user.g.dart'; -@JsonSerializable() @DataAdapter([NostrAdapter, UserAdapter]) class User extends BaseUser with DataModelMixin { User( - {super.id, - super.pubkey, - super.createdAt, - super.content, + {super.createdAt, super.tags, - super.signature, required this.followers, required this.following}); + User.fromJson(super.map) + : followers = + HasMany.fromJson(map['followers'] as Map), + following = + HasMany.fromJson(map['following'] as Map), + super.fromJson(); + + Map toJson() => super.toMap(); + @DataRelationship(inverse: 'followers') final HasMany following; @DataRelationship(inverse: 'following') @@ -105,13 +108,12 @@ mixin UserAdapter on NostrAdapter { if (authors.isEmpty) { return []; } - final req = RelayRequest( - authors: Set.from(authors), - kinds: {kind, if (params['contacts'] != null) 3}, - ); - final result = - await notifier.query(req, relayUrls: ['wss://relay.nostr.band']); + // TODO: was: kinds: {kind, if (params['contacts'] != null) 3}, + final result = await relay.query( + authors: Set.from(authors), + relayUrls: ['wss://relay.nostr.band']); + if (onSuccess != null) { return await onSuccess.call(DataResponse(statusCode: 200, body: result), label ?? DataRequestLabel('findAll', type: type), this); @@ -163,18 +165,16 @@ mixin UserAdapter on NostrAdapter { ); } - final req = RelayRequest( - authors: {publicKey}, - kinds: {kind, if (params?['contacts'] != null) 3}, - tags: params ?? {}, - ); - // trigger trust service indexing in the background // sendRequest( // Uri.parse('https://zap.store/api/trust/${publicKey.npub}/r')); - final result = - await notifier.query(req, relayUrls: ['wss://relay.nostr.band']); + // TODO: was: kinds: {kind, if (params?['contacts'] != null) 3}, + final result = await relay.query( + authors: {publicKey}, + tags: params ?? {}, + relayUrls: ['wss://relay.nostr.band']); + final data = await deserializeAsync(result, save: true); return data.models.firstWhere((e) { return e.id == publicKey; diff --git a/lib/models/user.g.dart b/lib/models/user.g.dart index b569788..bd412f0 100644 --- a/lib/models/user.g.dart +++ b/lib/models/user.g.dart @@ -33,12 +33,12 @@ mixin _$UserAdapter on Adapter { @override User deserializeLocal(map, {String? key}) { map = transformDeserialize(map); - return internalWrapStopInit(() => _$UserFromJson(map), key: key); + return internalWrapStopInit(() => User.fromJson(map), key: key); } @override Map serializeLocal(model, {bool withRelationships = true}) { - final map = _$UserToJson(model); + final map = model.toJson(); return transformSerialize(map, withRelationships: withRelationships); } } @@ -71,37 +71,3 @@ extension UserRelationshipGraphNodeX on RelationshipGraphNode { parent: this is RelationshipMeta ? this as RelationshipMeta : null); } } - -// ************************************************************************** -// JsonSerializableGenerator -// ************************************************************************** - -User _$UserFromJson(Map json) => User( - id: json['id'], - pubkey: json['pubkey'] as String?, - createdAt: json['createdAt'] == null - ? null - : DateTime.parse(json['createdAt'] as String), - content: json['content'] as String? ?? '', - tags: (json['tags'] as List?) - ?.map( - (e) => (e as List).map((e) => e as String).toList()) - .toList() ?? - const [], - signature: json['signature'] as String?, - followers: - HasMany.fromJson(json['followers'] as Map), - following: - HasMany.fromJson(json['following'] as Map), - ); - -Map _$UserToJson(User instance) => { - 'id': instance.id, - 'pubkey': instance.pubkey, - 'createdAt': instance.createdAt.toIso8601String(), - 'content': instance.content, - 'tags': instance.tags, - 'signature': instance.signature, - 'following': instance.following, - 'followers': instance.followers, - }; diff --git a/lib/navigation/router.dart b/lib/navigation/router.dart index 693dcb8..ebcf645 100644 --- a/lib/navigation/router.dart +++ b/lib/navigation/router.dart @@ -135,19 +135,13 @@ AppLifecycleListener? _lifecycleListener; final dataLibrariesInitializer = FutureProvider((ref) async { await ref.read(initializeFlutterData(adapterProvidersMap).future); - appLinks.uriLinkStream.listen((uri) async { - if (uri.scheme == "zapstore") { - final adapter = ref.apps.appAdapter; - final App? app = await adapter.findOne(uri.host); - if (app!=null) { - appRouter.go('/updates/details', extra: app); - } - } - }); - ref - .read(relayMessageNotifierProvider.notifier) - .initialize(['wss://relay.zap.store', 'wss://relay.nostr.band']); + // NOTE: it is very important to use const in the argument to preserve equality + final relay = ref.read( + relayMessageNotifierProvider(const ['wss://relay.zap.store']).notifier); + await relay.initialize(); + + // TODO: , 'wss://relay.nostr.band' _lifecycleListener = AppLifecycleListener( onStateChange: (state) async { @@ -159,8 +153,20 @@ final dataLibrariesInitializer = FutureProvider((ref) async { }, ); + // Handle deep links + final appLinksSub = appLinks.uriLinkStream.listen((uri) async { + if (uri.scheme == "zapstore") { + final adapter = ref.apps.appAdapter; + final App? app = await adapter.findOne(uri.host); + if (app != null) { + appRouter.go('/updates/details', extra: app); + } + } + }); + ref.onDispose(() { _lifecycleListener?.dispose(); + appLinksSub.cancel(); }); }); diff --git a/lib/screens/app_detail_screen.dart b/lib/screens/app_detail_screen.dart index ac8c1b2..21955b4 100644 --- a/lib/screens/app_detail_screen.dart +++ b/lib/screens/app_detail_screen.dart @@ -30,9 +30,12 @@ class AppDetailScreen extends HookConsumerWidget { final state = ref.apps.watchOne(model.id!, alsoWatch: (_) => {_.releases, _.releases.artifacts, _.signer, _.developer}); + + // TODO: Why this? and not remote just above? useFuture(useMemoized(() => ref.apps.findOne(model.id!, remote: true, params: {'includes': true}))); - // TODO fix - hack to refresh on install changes + + // TODO: Hack to refresh on install changes final _ = ref.watch(installedAppProvider); final app = state.model ?? model; @@ -135,30 +138,30 @@ class AppDetailScreen extends HookConsumerWidget { ], ), ), - if (app.githubStars != null) - Padding( - padding: const EdgeInsets.all(8), - child: Row( - mainAxisAlignment: - MainAxisAlignment.spaceBetween, - children: [ - Text('Github stars'), - Text(app.githubStars!) - ], - ), - ), - if (app.githubForks != null) - Padding( - padding: const EdgeInsets.all(8), - child: Row( - mainAxisAlignment: - MainAxisAlignment.spaceBetween, - children: [ - Text('Github forks'), - Text(app.githubForks!) - ], - ), - ), + // if (app.githubStars != null) + // Padding( + // padding: const EdgeInsets.all(8), + // child: Row( + // mainAxisAlignment: + // MainAxisAlignment.spaceBetween, + // children: [ + // Text('Github stars'), + // Text(app.githubStars!) + // ], + // ), + // ), + // if (app.githubForks != null) + // Padding( + // padding: const EdgeInsets.all(8), + // child: Row( + // mainAxisAlignment: + // MainAxisAlignment.spaceBetween, + // children: [ + // Text('Github forks'), + // Text(app.githubForks!) + // ], + // ), + // ), Padding( padding: const EdgeInsets.all(8), child: Row( @@ -180,7 +183,7 @@ class AppDetailScreen extends HookConsumerWidget { MainAxisAlignment.spaceBetween, children: [ Text('App ID'), - Text(app.identifier) + Text(app.identifier!) ], ), ), diff --git a/lib/screens/search_screen.dart b/lib/screens/search_screen.dart index 79846ea..fa494c2 100644 --- a/lib/screens/search_screen.dart +++ b/lib/screens/search_screen.dart @@ -110,9 +110,9 @@ class SearchScreen extends HookConsumerWidget { if (searchResultState.value?.isNotEmpty ?? false) for (final app in searchResultState.value!) AppCard(app: app), Gap(20), - CategoriesContainer(), + // const CategoriesContainer(), Gap(20), - LatestReleasesContainer(), + const LatestReleasesContainer(), Gap(10), ], ), diff --git a/lib/screens/settings_screen.dart b/lib/screens/settings_screen.dart index aaa379f..3d2b77d 100644 --- a/lib/screens/settings_screen.dart +++ b/lib/screens/settings_screen.dart @@ -8,9 +8,9 @@ import 'package:gap/gap.dart'; import 'package:go_router/go_router.dart'; import 'package:hooks_riverpod/hooks_riverpod.dart'; import 'package:intl/intl.dart'; -import 'package:purplebase/purplebase.dart'; import 'package:zapstore/main.data.dart'; import 'package:zapstore/models/app.dart'; +import 'package:zapstore/models/feedback.dart'; import 'package:zapstore/models/settings.dart'; import 'package:zapstore/utils/extensions.dart'; import 'package:zapstore/utils/system_info.dart'; @@ -60,9 +60,8 @@ class SettingsScreen extends HookConsumerWidget { if (controller.text.trim().isNotEmpty) { final text = '${controller.text.trim()} [from ${user.npub} on ${DateFormat('MMMM d, y').format(DateTime.now())}]'; - final event = BaseEvent(kind: 1011, content: text).sign(kI); - await ref.apps.nostrAdapter.notifier - .publish(event, relayUrls: ['wss://relay.zap.store']); + final event = AppFeedback(content: text).sign(kI); + await ref.apps.nostrAdapter.relay.publish(event); controller.clear(); } }, diff --git a/lib/widgets/error_container.dart b/lib/widgets/error_container.dart index 8f72f71..a56d712 100644 --- a/lib/widgets/error_container.dart +++ b/lib/widgets/error_container.dart @@ -7,7 +7,7 @@ import 'package:gap/gap.dart'; import 'package:http/http.dart' as http; import 'package:go_router/go_router.dart'; import 'package:hooks_riverpod/hooks_riverpod.dart'; -import 'package:purplebase/purplebase.dart'; +import 'package:zapstore/models/feedback.dart'; import 'package:zapstore/utils/extensions.dart'; import 'package:zapstore/utils/system_info.dart'; import 'package:zapstore/utils/theme.dart'; @@ -146,7 +146,7 @@ Future _sendErrorReport( }; final client = http.Client(); - final event = BaseEvent(kind: 1011, content: jsonEncode(map)).sign(kI); + final event = AppFeedback(content: jsonEncode(map)).sign(kI); await client.post(Uri.parse('https://relay.zap.store/'), body: jsonEncode(event.toMap()), headers: {'Content-Type': 'application/json'}); diff --git a/lib/widgets/install_button.dart b/lib/widgets/install_button.dart index 621d23f..1bb0762 100644 --- a/lib/widgets/install_button.dart +++ b/lib/widgets/install_button.dart @@ -26,7 +26,7 @@ class InstallButton extends ConsumerWidget { @override Widget build(BuildContext context, WidgetRef ref) { - final progress = ref.watch(installationProgressProvider(app.identifier)); + final progress = ref.watch(installationProgressProvider(app.identifier!)); return GestureDetector( onTap: switch (app.status) { diff --git a/lib/widgets/latest_releases_container.dart b/lib/widgets/latest_releases_container.dart index 4f27bc6..d440a0b 100644 --- a/lib/widgets/latest_releases_container.dart +++ b/lib/widgets/latest_releases_container.dart @@ -9,9 +9,7 @@ import 'package:zapstore/models/app.dart'; import 'package:zapstore/widgets/app_card.dart'; class LatestReleasesContainer extends HookConsumerWidget { - const LatestReleasesContainer({ - super.key, - }); + const LatestReleasesContainer({super.key}); @override Widget build(BuildContext context, WidgetRef ref) { @@ -46,7 +44,7 @@ class LatestReleasesAppNotifier extends AutoDisposeAsyncNotifier> { List localFetch() { return ref.releases .findAllLocal() - .sorted((a, b) => b.createdAt.compareTo(a.createdAt)) + .sorted((a, b) => b.createdAt!.compareTo(a.createdAt!)) .take(10) .map((r) => r.app.value) .nonNulls diff --git a/lib/widgets/release_card.dart b/lib/widgets/release_card.dart index f866f6e..30b8d48 100644 --- a/lib/widgets/release_card.dart +++ b/lib/widgets/release_card.dart @@ -54,7 +54,7 @@ class ReleaseCard extends StatelessWidget { mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ Text('Date'), - Text(formatter.format(release.createdAt)), + Text(formatter.format(release.createdAt!)), ], ), ), diff --git a/macos/Podfile.lock b/macos/Podfile.lock index 7fc24e9..081c155 100644 --- a/macos/Podfile.lock +++ b/macos/Podfile.lock @@ -10,18 +10,21 @@ PODS: - sqflite (0.0.3): - Flutter - FlutterMacOS - - "sqlite3 (3.45.3+1)": - - "sqlite3/common (= 3.45.3+1)" - - "sqlite3/common (3.45.3+1)" - - "sqlite3/fts5 (3.45.3+1)": + - "sqlite3 (3.46.1+1)": + - "sqlite3/common (= 3.46.1+1)" + - "sqlite3/common (3.46.1+1)" + - "sqlite3/dbstatvtab (3.46.1+1)": - sqlite3/common - - "sqlite3/perf-threadsafe (3.45.3+1)": + - "sqlite3/fts5 (3.46.1+1)": - sqlite3/common - - "sqlite3/rtree (3.45.3+1)": + - "sqlite3/perf-threadsafe (3.46.1+1)": + - sqlite3/common + - "sqlite3/rtree (3.46.1+1)": - sqlite3/common - sqlite3_flutter_libs (0.0.1): - FlutterMacOS - - "sqlite3 (~> 3.45.3+1)" + - "sqlite3 (~> 3.46.0+1)" + - sqlite3/dbstatvtab - sqlite3/fts5 - sqlite3/perf-threadsafe - sqlite3/rtree @@ -63,9 +66,9 @@ SPEC CHECKSUMS: FlutterMacOS: 8f6f14fa908a6fb3fba0cd85dbd81ec4b251fb24 path_provider_foundation: 2b6b4c569c0fb62ec74538f866245ac84301af46 sqflite: 673a0e54cc04b7d6dba8d24fb8095b31c3a99eec - sqlite3: 02d1f07eaaa01f80a1c16b4b31dfcbb3345ee01a - sqlite3_flutter_libs: 8d204ef443cf0d5c1c8b058044eab53f3943a9c5 - url_launcher_macos: d2691c7dd33ed713bf3544850a623080ec693d95 + sqlite3: 0bb0e6389d824e40296f531b858a2a0b71c0d2fb + sqlite3_flutter_libs: 5ca46c1a04eddfbeeb5b16566164aa7ad1616e7b + url_launcher_macos: c82c93949963e55b228a30115bd219499a6fe404 PODFILE CHECKSUM: 236401fc2c932af29a9fcf0e97baeeb2d750d367 diff --git a/pubspec.lock b/pubspec.lock index 81140f9..fb43f31 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -61,10 +61,10 @@ packages: dependency: transitive description: name: archive - sha256: ecf4273855368121b1caed0d10d4513c7241dfc813f7d3c8933b36622ae9b265 + sha256: cb6a278ef2dbb298455e1a713bda08524a175630ec643a242c399c932a0a1f7d url: "https://pub.dev" source: hosted - version: "3.5.1" + version: "3.6.1" args: dependency: transitive description: @@ -149,10 +149,10 @@ packages: dependency: transitive description: name: build_daemon - sha256: "0343061a33da9c5810b2d6cee51945127d8f4c060b7fbdd9d54917f0a3feaaa1" + sha256: "79b2aef6ac2ed00046867ed354c88778c9c0f029df8a20fe10b5436826721ef9" url: "https://pub.dev" source: hosted - version: "4.0.1" + version: "4.0.2" build_resolvers: dependency: transitive description: @@ -165,18 +165,18 @@ packages: dependency: "direct main" description: name: build_runner - sha256: "3ac61a79bfb6f6cc11f693591063a7f19a7af628dc52f141743edac5c16e8c22" + sha256: "644dc98a0f179b872f612d3eb627924b578897c629788e858157fa5e704ca0c7" url: "https://pub.dev" source: hosted - version: "2.4.9" + version: "2.4.11" build_runner_core: dependency: transitive description: name: build_runner_core - sha256: "4ae8ffe5ac758da294ecf1802f2aff01558d8b1b00616aa7538ea9a8a5d50799" + sha256: e3c79f69a64bdfcd8a776a3c28db4eb6e3fb5356d013ae5eb2e52007706d5dbe url: "https://pub.dev" source: hosted - version: "7.3.0" + version: "7.3.1" built_collection: dependency: transitive description: @@ -197,26 +197,26 @@ packages: dependency: "direct main" description: name: cached_network_image - sha256: "28ea9690a8207179c319965c13cd8df184d5ee721ae2ce60f398ced1219cea1f" + sha256: "7c1183e361e5c8b0a0f21a28401eecdbde252441106a9816400dd4c2b2424916" url: "https://pub.dev" source: hosted - version: "3.3.1" + version: "3.4.1" cached_network_image_platform_interface: dependency: transitive description: name: cached_network_image_platform_interface - sha256: "9e90e78ae72caa874a323d78fa6301b3fb8fa7ea76a8f96dc5b5bf79f283bf2f" + sha256: "35814b016e37fbdc91f7ae18c8caf49ba5c88501813f73ce8a07027a395e2829" url: "https://pub.dev" source: hosted - version: "4.0.0" + version: "4.1.1" cached_network_image_web: dependency: transitive description: name: cached_network_image_web - sha256: "205d6a9f1862de34b93184f22b9d2d94586b2f05c581d546695e3d8f6a805cd7" + sha256: "980842f4e8e2535b8dbd3d5ca0b1f0ba66bf61d14cc3a17a9b4788a3685ba062" url: "https://pub.dev" source: hosted - version: "1.2.0" + version: "1.3.1" characters: dependency: transitive description: @@ -277,10 +277,10 @@ packages: dependency: "direct main" description: name: crypto - sha256: ff625774173754681d66daaf4a448684fb04b78f902da9cb3d308c19cc5e8bab + sha256: ec30d999af904f33454ba22ed9a86162b35e52b44ac4807d1d93c288041d7d27 url: "https://pub.dev" source: hosted - version: "3.0.3" + version: "3.0.5" cupertino_icons: dependency: "direct main" description: @@ -317,18 +317,18 @@ packages: dependency: "direct main" description: name: device_info_plus - sha256: eead12d1a1ed83d8283ab4c2f3fca23ac4082f29f25f29dff0f758f57d06ec91 + sha256: a7fd703482b391a87d60b6061d04dfdeab07826b96f9abd8f5ed98068acc0074 url: "https://pub.dev" source: hosted - version: "10.1.0" + version: "10.1.2" device_info_plus_platform_interface: dependency: transitive description: name: device_info_plus_platform_interface - sha256: d3b01d5868b50ae571cd1dc6e502fc94d956b665756180f7b16ead09e836fd64 + sha256: "282d3cf731045a2feb66abfe61bbc40870ae50a3ed10a4d3d217556c35c8c2ba" url: "https://pub.dev" source: hosted - version: "7.0.0" + version: "7.0.1" equatable: dependency: transitive description: @@ -349,10 +349,10 @@ packages: dependency: transitive description: name: ffi - sha256: "493f37e7df1804778ff3a53bd691d8692ddf69702cf4c1c1096a2e41b4779e21" + sha256: "16ed7b077ef01ad6170a3d0c57caa4a112a38d7a2ed5602e0aca9ca6f3d98da6" url: "https://pub.dev" source: hosted - version: "2.1.2" + version: "2.1.3" file: dependency: transitive description: @@ -378,10 +378,10 @@ packages: dependency: transitive description: name: flutter_cache_manager - sha256: "395d6b7831f21f3b989ebedbb785545932adb9afe2622c1ffacf7f4b53a7e544" + sha256: "400b6592f16a4409a7f2bb929a9a7e38c72cceb8ffb99ee57bbf2cb2cecf8386" url: "https://pub.dev" source: hosted - version: "3.3.2" + version: "3.4.1" flutter_data: dependency: "direct main" description: @@ -411,10 +411,10 @@ packages: dependency: "direct main" description: name: flutter_layout_grid - sha256: "962a7ec8c7ea46c3b10606dac9c964f9143d10daa5ca28e40f4ce14eeef85b2a" + sha256: "88b4f8484a0874962e27c47733ad256aeb26acc694a9f029edbef771d301885a" url: "https://pub.dev" source: hosted - version: "2.0.6" + version: "2.0.7" flutter_lints: dependency: "direct dev" description: @@ -427,10 +427,10 @@ packages: dependency: "direct main" description: name: flutter_markdown - sha256: "9921f9deda326f8a885e202b1e35237eadfc1345239a0f6f0f1ff287e047547f" + sha256: e17575ca576a34b46c58c91f9948891117a1bd97815d2e661813c7f90c647a78 url: "https://pub.dev" source: hosted - version: "0.7.1" + version: "0.7.3+2" flutter_phoenix: dependency: "direct main" description: @@ -461,10 +461,10 @@ packages: dependency: transitive description: name: freezed_annotation - sha256: c3fd9336eb55a38cc1bbd79ab17573113a8deccd0ecbbf926cca3c62803b5c2d + sha256: c2e2d632dd9b8a2b7751117abcfc2b4888ecfe181bd9fca7170d9ef02e595fe2 url: "https://pub.dev" source: hosted - version: "2.4.1" + version: "2.4.4" frontend_server_client: dependency: transitive description: @@ -501,18 +501,18 @@ packages: dependency: "direct main" description: name: go_router - sha256: "81f94e16d7063b60f0da3a79f872e140d6518f306749303bf981abd7d6b46734" + sha256: "6f1b756f6e863259a99135ff3c95026c3cdca17d10ebef2bba2261a25ddc8bbc" url: "https://pub.dev" source: hosted - version: "14.1.0" + version: "14.3.0" graphs: dependency: transitive description: name: graphs - sha256: aedc5a15e78fc65a6e23bcd927f24c64dd995062bcd1ca6eda65a3cff92a4d19 + sha256: "741bbf84165310a68ff28fe9e727332eef1407342fca52759cb21ad8177bb8d0" url: "https://pub.dev" source: hosted - version: "2.3.1" + version: "2.3.2" gtk: dependency: transitive description: @@ -525,18 +525,18 @@ packages: dependency: "direct main" description: name: hooks_riverpod - sha256: "45b2030a18bcd6dbd680c2c91bc3b33e3fe7c323e3acb5ecec93a613e2fbaa8a" + sha256: "97266a91c994951a06ef0ff3a1c7fb261e52ec7f74e87f0614ea0b7411b859b2" url: "https://pub.dev" source: hosted - version: "2.5.1" + version: "2.5.2" http: dependency: "direct main" description: name: http - sha256: "761a297c042deedc1ffbb156d6e2af13886bb305c2a343a4d972504cd67dd938" + sha256: b9c29a161230ee03d3ccf545097fccd9b87a5264228c5d348202e0f0c28f9010 url: "https://pub.dev" source: hosted - version: "1.2.1" + version: "1.2.2" http_multi_server: dependency: transitive description: @@ -573,10 +573,10 @@ packages: dependency: transitive description: name: image - sha256: "4c68bfd5ae83e700b5204c1e74451e7bf3cf750e6843c6e158289cf56bda018e" + sha256: "2237616a36c0d69aef7549ab439b833fb7f9fb9fc861af2cc9ac3eedddd69ca8" url: "https://pub.dev" source: hosted - version: "4.1.7" + version: "4.2.0" inflection3: dependency: transitive description: @@ -709,18 +709,18 @@ packages: dependency: transitive description: name: mime - sha256: "2e123074287cc9fd6c09de8336dae606d1ddb88d9ac47358826db698c176a1f2" + sha256: "801fd0b26f14a4a58ccb09d5892c3fbdeff209594300a542492cf13fba9d247a" url: "https://pub.dev" source: hosted - version: "1.0.5" + version: "1.0.6" octo_image: dependency: transitive description: name: octo_image - sha256: "45b40f99622f11901238e18d48f5f12ea36426d8eced9f4cbf58479c7aa2430d" + sha256: "34faa6639a78c7e3cbe79be6f9f96535867e879748ade7d17c9b1ae7536293bd" url: "https://pub.dev" source: hosted - version: "2.0.0" + version: "2.1.0" package_config: dependency: transitive description: @@ -741,18 +741,18 @@ packages: dependency: "direct main" description: name: path_provider - sha256: c9e7d3a4cd1410877472158bee69963a4579f78b68c65a2b7d40d1a7a88bb161 + sha256: fec0d61223fba3154d87759e3cc27fe2c8dc498f6386c6d6fc80d1afdd1bf378 url: "https://pub.dev" source: hosted - version: "2.1.3" + version: "2.1.4" path_provider_android: dependency: transitive description: name: path_provider_android - sha256: a248d8146ee5983446bf03ed5ea8f6533129a12b11f12057ad1b4a67a2b3b41d + sha256: "6f01f8e37ec30b07bc424b4deabac37cacb1bc7e2e515ad74486039918a37eb7" url: "https://pub.dev" source: hosted - version: "2.2.4" + version: "2.2.10" path_provider_foundation: dependency: transitive description: @@ -781,10 +781,10 @@ packages: dependency: transitive description: name: path_provider_windows - sha256: "8bc9f22eee8690981c22aa7fc602f5c85b497a6fb2ceb35ee5a5e5ed85ad8170" + sha256: bd6f00dbd873bfb70d0761682da2b3a2c2fccc2b9e84c495821639601d81afe7 url: "https://pub.dev" source: hosted - version: "2.2.1" + version: "2.3.0" pausable_timer: dependency: transitive description: @@ -813,34 +813,34 @@ packages: dependency: transitive description: name: permission_handler_android - sha256: "8bb852cd759488893805c3161d0b2b5db55db52f773dbb014420b304055ba2c5" + sha256: "76e4ab092c1b240d31177bb64d2b0bea43f43d0e23541ec866151b9f7b2490fa" url: "https://pub.dev" source: hosted - version: "12.0.6" + version: "12.0.12" permission_handler_apple: dependency: transitive description: name: permission_handler_apple - sha256: e9ad66020b89ff1b63908f247c2c6f931c6e62699b756ef8b3c4569350cd8662 + sha256: e6f6d73b12438ef13e648c4ae56bd106ec60d17e90a59c4545db6781229082a0 url: "https://pub.dev" source: hosted - version: "9.4.4" + version: "9.4.5" permission_handler_html: dependency: transitive description: name: permission_handler_html - sha256: "54bf176b90f6eddd4ece307e2c06cf977fb3973719c35a93b85cc7093eb6070d" + sha256: af26edbbb1f2674af65a8f4b56e1a6f526156bc273d0e65dd8075fab51c78851 url: "https://pub.dev" source: hosted - version: "0.1.1" + version: "0.1.3+2" permission_handler_platform_interface: dependency: transitive description: name: permission_handler_platform_interface - sha256: "48d4fcf201a1dad93ee869ab0d4101d084f49136ec82a8a06ed9cfeacab9fd20" + sha256: e9c8eadee926c4532d0305dff94b85bf961f16759c3af791486613152af4b4f9 url: "https://pub.dev" source: hosted - version: "4.2.1" + version: "4.2.3" permission_handler_windows: dependency: transitive description: @@ -861,10 +861,10 @@ packages: dependency: transitive description: name: platform - sha256: "12220bb4b65720483f8fa9450b4332347737cf8213dd2840d8b2c823e47243ec" + sha256: "9b71283fc13df574056616011fb138fd3b793ea47cc509c189a6c3fa5f8a1a65" url: "https://pub.dev" source: hosted - version: "3.1.4" + version: "3.1.5" plugin_platform_interface: dependency: transitive description: @@ -901,35 +901,33 @@ packages: dependency: transitive description: name: pubspec_parse - sha256: c63b2876e58e194e4b0828fcb080ad0e06d051cb607a6be51a9e084f47cb9367 + sha256: c799b721d79eb6ee6fa56f00c04b472dcd44a30d258fac2174a6ec57302678f8 url: "https://pub.dev" source: hosted - version: "1.2.3" + version: "1.3.0" purplebase: dependency: "direct main" description: - path: "." - ref: "0.1.1" - resolved-ref: "510bc0b2a92d6f2519e5ee25506afd729e40089a" - url: "https://github.com/purplebase/purplebase" - source: git + path: "../purplebase" + relative: true + source: path version: "0.1.1" quiver: dependency: transitive description: name: quiver - sha256: b1c1ac5ce6688d77f65f3375a9abb9319b3cb32486bdc7a1e0fdf004d7ba4e47 + sha256: ea0b925899e64ecdfbf9c7becb60d5b50e706ade44a85b2363be2a22d88117d2 url: "https://pub.dev" source: hosted - version: "3.2.1" + version: "3.2.2" rational: dependency: transitive description: name: rational - sha256: ba58e9e18df9abde280e8b10051e4bce85091e41e8e7e411b6cde2e738d357cf + sha256: cb808fb6f1a839e6fc5f7d8cb3b0a10e1db48b3be102de73938c627f0b636336 url: "https://pub.dev" source: hosted - version: "2.2.2" + version: "2.2.3" riverpod: dependency: transitive description: @@ -942,10 +940,10 @@ packages: dependency: transitive description: name: rxdart - sha256: "0c7c0cedd93788d996e33041ffecda924cc54389199cde4e6a34b440f50044cb" + sha256: "5c3004a4a8dbb94bd4bf5412a4def4acdaa12e12f269737a5751369e12d1a962" url: "https://pub.dev" source: hosted - version: "0.27.7" + version: "0.28.0" shelf: dependency: transitive description: @@ -958,18 +956,18 @@ packages: dependency: transitive description: name: shelf_web_socket - sha256: "9ca081be41c60190ebcb4766b2486a7d50261db7bd0f5d9615f2d653637a84c1" + sha256: "073c147238594ecd0d193f3456a5fe91c4b0abbcc68bf5cd95b36c4e194ac611" url: "https://pub.dev" source: hosted - version: "1.0.4" + version: "2.0.0" skeletonizer: dependency: "direct main" description: name: skeletonizer - sha256: "50c3fdf3d1bf6182129c03b53bc7ff6dca10ca0b8e71ccdee148b9322caabdba" + sha256: "3b202e4fa9c49b017d368fb0e570d4952bcd19972b67b2face071bdd68abbfae" url: "https://pub.dev" source: hosted - version: "1.1.2+1" + version: "1.4.2" sky_engine: dependency: transitive description: flutter @@ -1027,18 +1025,18 @@ packages: dependency: transitive description: name: sqlite3 - sha256: "1abbeb84bf2b1a10e5e1138c913123c8aa9d83cd64e5f9a0dd847b3c83063202" + sha256: "45f168ae2213201b54e09429ed0c593dc2c88c924a1488d6f9c523a255d567cb" url: "https://pub.dev" source: hosted - version: "2.4.2" + version: "2.4.6" sqlite3_flutter_libs: dependency: "direct main" description: name: sqlite3_flutter_libs - sha256: fb2a106a2ea6042fe57de2c47074cc31539a941819c91e105b864744605da3f5 + sha256: "62bbb4073edbcdf53f40c80775f33eea01d301b7b81417e5b3fb7395416258c1" url: "https://pub.dev" source: hosted - version: "0.5.21" + version: "0.5.24" stack_trace: dependency: transitive description: @@ -1123,10 +1121,10 @@ packages: dependency: "direct main" description: name: toastification - sha256: "5e751acc2fb5b8d008138dac255d62290fde4e5a24824f29809ac098c3dfe395" + sha256: "4d97fbfa463dfe83691044cba9f37cb185a79bb9205cfecb655fa1f6be126a13" url: "https://pub.dev" source: hosted - version: "2.0.0" + version: "2.3.0" typed_data: dependency: transitive description: @@ -1139,42 +1137,42 @@ packages: dependency: "direct main" description: name: url_launcher - sha256: "6ce1e04375be4eed30548f10a315826fd933c1e493206eab82eed01f438c8d2e" + sha256: "21b704ce5fa560ea9f3b525b43601c678728ba46725bab9b01187b4831377ed3" url: "https://pub.dev" source: hosted - version: "6.2.6" + version: "6.3.0" url_launcher_android: dependency: transitive description: name: url_launcher_android - sha256: "360a6ed2027f18b73c8d98e159dda67a61b7f2e0f6ec26e86c3ada33b0621775" + sha256: f0c73347dfcfa5b3db8bc06e1502668265d39c08f310c29bff4e28eea9699f79 url: "https://pub.dev" source: hosted - version: "6.3.1" + version: "6.3.9" url_launcher_ios: dependency: transitive description: name: url_launcher_ios - sha256: "9149d493b075ed740901f3ee844a38a00b33116c7c5c10d7fb27df8987fb51d5" + sha256: e43b677296fadce447e987a2f519dcf5f6d1e527dc35d01ffab4fff5b8a7063e url: "https://pub.dev" source: hosted - version: "6.2.5" + version: "6.3.1" url_launcher_linux: dependency: transitive description: name: url_launcher_linux - sha256: ab360eb661f8879369acac07b6bb3ff09d9471155357da8443fd5d3cf7363811 + sha256: e2b9622b4007f97f504cd64c0128309dfb978ae66adbe944125ed9e1750f06af url: "https://pub.dev" source: hosted - version: "3.1.1" + version: "3.2.0" url_launcher_macos: dependency: transitive description: name: url_launcher_macos - sha256: b7244901ea3cf489c5335bdacda07264a6e960b1c1b1a9f91e4bc371d9e68234 + sha256: "769549c999acdb42b8bcfa7c43d72bf79a382ca7441ab18a808e101149daf672" url: "https://pub.dev" source: hosted - version: "3.1.0" + version: "3.2.1" url_launcher_platform_interface: dependency: transitive description: @@ -1187,26 +1185,26 @@ packages: dependency: transitive description: name: url_launcher_web - sha256: "8d9e750d8c9338601e709cd0885f95825086bd8b642547f26bda435aade95d8a" + sha256: "772638d3b34c779ede05ba3d38af34657a05ac55b06279ea6edd409e323dca8e" url: "https://pub.dev" source: hosted - version: "2.3.1" + version: "2.3.3" url_launcher_windows: dependency: transitive description: name: url_launcher_windows - sha256: ecf9725510600aa2bb6d7ddabe16357691b6d2805f66216a97d1b881e21beff7 + sha256: "49c10f879746271804767cb45551ec5592cdab00ee105c06dddde1a98f73b185" url: "https://pub.dev" source: hosted - version: "3.1.1" + version: "3.1.2" uuid: dependency: transitive description: name: uuid - sha256: "814e9e88f21a176ae1359149021870e87f7cddaf633ab678a5d2b0bff7fd1ba8" + sha256: a5be9ef6618a7ac1e964353ef476418026db906c4facdedaa299b7a2e71690ff url: "https://pub.dev" source: hosted - version: "4.4.0" + version: "4.5.1" vector_math: dependency: transitive description: @@ -1235,18 +1233,34 @@ packages: dependency: transitive description: name: web - sha256: "97da13628db363c635202ad97068d47c5b8aa555808e7a9411963c533b449b27" + sha256: cd3543bd5798f6ad290ea73d210f423502e71900302dde696f8bff84bf89a1cb url: "https://pub.dev" source: hosted - version: "0.5.1" + version: "1.1.0" + web_socket: + dependency: transitive + description: + name: web_socket + sha256: "3c12d96c0c9a4eec095246debcea7b86c0324f22df69893d538fcc6f1b8cce83" + url: "https://pub.dev" + source: hosted + version: "0.1.6" web_socket_channel: dependency: transitive description: name: web_socket_channel - sha256: "58c6666b342a38816b2e7e50ed0f1e261959630becd4c879c4f26bfa14aa5a42" + sha256: "9f187088ed104edd8662ca07af4b124465893caf063ba29758f97af57e61da8f" url: "https://pub.dev" source: hosted - version: "2.4.5" + version: "3.0.1" + web_socket_client: + dependency: transitive + description: + name: web_socket_client + sha256: "0ec5230852349191188c013112e4d2be03e3fc83dbe80139ead9bf3a136e53b5" + url: "https://pub.dev" + source: hosted + version: "0.1.5" win32: dependency: "direct overridden" description: @@ -1259,26 +1273,18 @@ packages: dependency: transitive description: name: win32_registry - sha256: "10589e0d7f4e053f2c61023a31c9ce01146656a70b7b7f0828c0b46d7da2a9bb" + sha256: "21ec76dfc731550fd3e2ce7a33a9ea90b828fdf19a5c3bcf556fa992cfa99852" url: "https://pub.dev" source: hosted - version: "1.1.3" - ws: - dependency: transitive - description: - name: ws - sha256: bb40a7b9219324ac285133c6b3c11bc16015d9cd5889e6555b76bd3e3a64b3e7 - url: "https://pub.dev" - source: hosted - version: "1.0.0" + version: "1.1.5" xdg_directories: dependency: transitive description: name: xdg_directories - sha256: faea9dee56b520b55a566385b84f2e8de55e7496104adada9962e0bd11bcff1d + sha256: "7a3f37b05d989967cdddcbb571f1ea834867ae2faa29725fd085180e0883aa15" url: "https://pub.dev" source: hosted - version: "1.0.4" + version: "1.1.0" xml: dependency: transitive description: @@ -1296,5 +1302,5 @@ packages: source: hosted version: "3.1.2" sdks: - dart: ">=3.3.0 <4.0.0" - flutter: ">=3.19.0" + dart: ">=3.4.0 <4.0.0" + flutter: ">=3.22.0" diff --git a/pubspec.yaml b/pubspec.yaml index 47fe0b4..61f80e4 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -49,14 +49,15 @@ dependencies: dependency_overrides: purplebase: - git: - url: https://github.com/purplebase/purplebase - ref: 0.1.1 + path: ../purplebase + # git: + # url: https://github.com/purplebase/purplebase + # ref: 0.1.1 flutter_data: git: url: https://github.com/zapstore/flutter_data ref: d7376cf1eac8e9c563d4c6eed8e567adc877415c - win32: 5.5.4 + win32: ^5.5.4 dev_dependencies: flutter_test: