Skip to content

Commit c8da966

Browse files
KingGorrinalienc0dermaznnwell
authored
Release v0.2.2 (#130)
* Retry Web3WalletService init on SocketException * Retry wc init on socket and timeout * Update znn_ledger_dart dep (#121) * Update znn dependencies (#122) * Update zenon-node-database references * Update deprecated TextStyle properties * Ref znn deps by tag * Fix create project description typo * Add NotificationWidget to project details screen * Update icon assets * Fix incorrect icon sizes * Update MacOS icons with trans border * Update tray and linux icon * feat: Upgrade flutter_staggered_grid_view to 0.7.0 - along with other dependencies * feat: Remove unused dependency - screenshot * feat: Add the WidgetAnimator back * feat: Hide the TabBar divider * feat: Show a progress indicator until the splash screen lottie finished loading * fix: Override debug default target platform in debug mode * fix: Remove overriding the debug default target platform in debug mode * fix: Seed input fields * cicd: upgrade Flutter to `3.24.3` * Bumped version number to 0.2.2 --------- Co-authored-by: Alien Coder <[email protected]> Co-authored-by: maznnwell <[email protected]>
1 parent 9ac2b96 commit c8da966

31 files changed

+486
-308
lines changed

.github/workflows/syrius_builder.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99
workflow_dispatch:
1010

1111
env:
12-
FLUTTER_VERSION: "3.19.x"
12+
FLUTTER_VERSION: "3.24.3"
1313

1414
jobs:
1515
build-macos:
@@ -20,7 +20,7 @@ jobs:
2020
- name: Checkout zenon-node-database repository
2121
uses: actions/checkout@v4
2222
with:
23-
repository: HyperCore-One/zenon-node-database
23+
repository: zenon-network/zenon-node-database
2424
path: ./node-db
2525
ref: main
2626
- name: Copy community nodes
@@ -68,7 +68,7 @@ jobs:
6868
- name: Checkout zenon-node-database repository
6969
uses: actions/checkout@v4
7070
with:
71-
repository: HyperCore-One/zenon-node-database
71+
repository: zenon-network/zenon-node-database
7272
path: ./node-db
7373
ref: main
7474
- name: Copy community nodes
@@ -101,7 +101,7 @@ jobs:
101101
- name: Checkout zenon-node-database repository
102102
uses: actions/checkout@v4
103103
with:
104-
repository: HyperCore-One/zenon-node-database
104+
repository: zenon-network/zenon-node-database
105105
path: ./node-db
106106
ref: main
107107
- name: Copy community nodes

assets/images/tray_app_icon.ico

64.4 KB
Binary file not shown.

assets/images/tray_app_icon.png

-2.14 KB
Loading

lib/main.dart

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
1+
import 'dart:async';
12
import 'dart:io';
23
import 'dart:isolate';
34

4-
import 'package:flutter/foundation.dart'
5-
show debugDefaultTargetPlatformOverride, kDebugMode;
5+
import 'package:flutter/foundation.dart' show kDebugMode;
66
import 'package:flutter/gestures.dart';
77
import 'package:flutter/material.dart';
88
import 'package:get_it/get_it.dart';
@@ -13,6 +13,7 @@ import 'package:logging/logging.dart';
1313
import 'package:overlay_support/overlay_support.dart';
1414
import 'package:path/path.dart' as path;
1515
import 'package:provider/provider.dart';
16+
import 'package:retry/retry.dart';
1617
import 'package:tray_manager/tray_manager.dart';
1718
import 'package:window_manager/window_manager.dart';
1819
import 'package:zenon_syrius_wallet_flutter/blocs/auto_unlock_htlc_worker.dart';
@@ -36,17 +37,16 @@ import 'package:znn_sdk_dart/znn_sdk_dart.dart';
3637
Zenon? zenon;
3738
SharedPrefsService? sharedPrefsService;
3839
HtlcSwapsService? htlcSwapsService;
40+
IWeb3WalletService? web3WalletService;
3941

4042
final sl = GetIt.instance;
4143

42-
IWeb3WalletService? web3WalletService;
4344
final globalNavigatorKey = GlobalKey<NavigatorState>();
4445

4546
main() async {
4647
WidgetsFlutterBinding.ensureInitialized();
4748

4849
Provider.debugCheckInvalidValueType = null;
49-
debugDefaultTargetPlatformOverride = TargetPlatform.fuchsia;
5050

5151
ensureDirectoriesExist();
5252
Hive.init(znnDefaultPaths.cache.path.toString());
@@ -83,7 +83,9 @@ main() async {
8383
// Setup services
8484
setup();
8585

86-
await web3WalletService!.init();
86+
retry(() => web3WalletService!.init(),
87+
retryIf: (e) => e is SocketException || e is TimeoutException,
88+
maxAttempts: 0x7FFFFFFFFFFFFFFF);
8789

8890
// Setup local_notifier
8991
await localNotifier.setup(

lib/screens/onboarding/new_wallet/new_wallet_confirm_seed_screen.dart

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -243,6 +243,8 @@ class _NewWalletConfirmSeedScreenState
243243
fontSize: 12.0,
244244
),
245245
decoration: InputDecoration(
246+
contentPadding: EdgeInsets.all(8.0),
247+
isDense: true,
246248
filled: true,
247249
fillColor: Theme.of(context)
248250
.colorScheme

lib/screens/project_details_screen.dart

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,9 @@ class _ProjectDetailsScreenState extends State<ProjectDetailsScreen> {
4949
),
5050
],
5151
),
52+
NotificationWidget(
53+
onSeeMorePressed: widget.onStepperNotificationSeeMorePressed,
54+
),
5255
Expanded(
5356
child: _getStreamBuilder(),
5457
),

lib/screens/splash_screen.dart

Lines changed: 17 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -29,28 +29,32 @@ class SplashScreen extends StatefulWidget {
2929
State<SplashScreen> createState() => _SplashScreenState();
3030
}
3131

32-
class _SplashScreenState extends State<SplashScreen>
33-
with TickerProviderStateMixin {
34-
late AnimationController _controller;
32+
class _SplashScreenState extends State<SplashScreen> {
33+
late final Future<LottieComposition> _composition;
3534

3635
@override
3736
void initState() {
3837
super.initState();
39-
_controller = AnimationController(vsync: this);
38+
_composition = AssetLottie('assets/lottie/ic_anim_splash.json').load();
4039
}
4140

4241
@override
4342
Widget build(BuildContext context) {
44-
return Lottie.asset(
45-
'assets/lottie/ic_anim_splash.json',
46-
animate: true,
47-
controller: _controller,
48-
onLoaded: (composition) {
49-
_controller
50-
..duration = composition.duration
51-
..forward().whenComplete(
52-
() => _splashInits(),
43+
return FutureBuilder<LottieComposition>(
44+
future: _composition,
45+
builder: (context, snapshot) {
46+
var composition = snapshot.data;
47+
if (composition != null) {
48+
Future.delayed(composition.duration, () {
49+
_splashInits();
50+
});
51+
return Lottie(
52+
composition: composition,
53+
repeat: false,
5354
);
55+
} else {
56+
return const Center(child: CircularProgressIndicator());
57+
}
5458
},
5559
);
5660
}
@@ -73,7 +77,6 @@ class _SplashScreenState extends State<SplashScreen>
7377
}
7478

7579
void _navigateToNextScreen() {
76-
_controller.stop();
7780
return kWalletPath != null
7881
? _checkForDefaultNode()
7982
: Navigator.pushReplacementNamed(
@@ -149,7 +152,6 @@ class _SplashScreenState extends State<SplashScreen>
149152

150153
@override
151154
void dispose() {
152-
_controller.dispose();
153155
super.dispose();
154156
}
155157
}

lib/utils/constants.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ const SizedBox kSpacingBetweenActionButtons = SizedBox(
2828
const Size kAcceleratorProgressBarSize = Size(300.0, 10.0);
2929

3030
// Wallet version
31-
const String kWalletVersion = '0.2.1';
31+
const String kWalletVersion = '0.2.2';
3232

3333
// Boxes constants
3434
const String kFavoriteTokensBox = 'favourite_tokens_box';

lib/widgets/main_app_container.dart

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -245,6 +245,7 @@ class _MainAppContainerState extends State<MainAppContainer>
245245
width: 2.0,
246246
),
247247
),
248+
dividerHeight: 0.0,
248249
controller: _tabController,
249250
tabs: _getTabs(),
250251
),
@@ -753,7 +754,7 @@ class _MainAppContainerState extends State<MainAppContainer>
753754
void _handleIncomingLinks() async {
754755
if (!kIsWeb && !Platform.isLinux) {
755756
_incomingLinkSubscription =
756-
_appLinks.allUriLinkStream.listen((Uri? uri) async {
757+
_appLinks.uriLinkStream.listen((Uri? uri) async {
757758
if (!await windowManager.isFocused() ||
758759
!await windowManager.isVisible()) {
759760
windowManager.show();
@@ -1025,7 +1026,7 @@ class _MainAppContainerState extends State<MainAppContainer>
10251026
if (!_initialUriIsHandled) {
10261027
_initialUriIsHandled = true;
10271028
try {
1028-
final uri = await _appLinks.getInitialAppLink();
1029+
final uri = await _appLinks.getInitialLink();
10291030
if (uri != null) {
10301031
Logger('MainAppContainer').log(Level.INFO, '_handleInitialUri $uri');
10311032
}

lib/widgets/modular_widgets/accelerator_widgets/create_project.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ class CreateProject extends StatelessWidget {
1717
return CardScaffold(
1818
title: 'Create Project',
1919
childBuilder: () => _getWidgetBody(context),
20-
description: 'Innovate. Inspire. Buidl.',
20+
description: 'Innovate. Inspire. Build.',
2121
);
2222
}
2323

0 commit comments

Comments
 (0)