Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: separate atkey upload to a service in at_onboarding_flutter #939

Draft
wants to merge 5 commits into
base: trunk
Choose a base branch
from

Conversation

XavierChanth
Copy link
Member

@XavierChanth XavierChanth commented Nov 14, 2024

- What I did

  • Extracted the file upload portion of the onboarding home screen to it's own service.
  • Moved everything from the root of the package to src/ so we have better grasp over our public API.
  • Added new export files, selectively exporting by context, and preserving the original exports.

- How I did it

- How to verify it

  • Review commit by commit, as there are a lot of faux changes due to the file renames:

CleanShot 2024-11-14 at 18 11 39@2x

  • Tested on macos / ios simulator

- Description for the changelog
chore: separate atkey upload to a service in at_onboarding_flutter

@XavierChanth XavierChanth marked this pull request as ready for review November 14, 2024 23:13
@@ -1,184 +1,5 @@
import 'dart:io';
library at_onboarding_legacy;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

moved to src/at_onboarding.dart

error, //Authenticate error
cancel, //User canceled
}
library at_onboarding_result_legacy;
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

moved to src/at_onboarding_result

import 'package:at_utils/at_logger.dart';
import 'package:file_picker/file_picker.dart';

class AtKeysFileUploadService {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The service extracted from the onboarding home screen

loading = false;
});
return;
Future<void> _uploadKeyFile() async {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This calls the new service, and listens to the progress stream, updating the UI accordingly. The actual logic behind when UI changes occur is the same

@XavierChanth
Copy link
Member Author

@gkc I originally planned to do a lot more, but I believe this service extraction is the minimum required changeset for us to make the planned improvements to the NoPorts desktop onboarding UX.

@XavierChanth
Copy link
Member Author

Setting back to draft, need to make a few more changes

@XavierChanth XavierChanth marked this pull request as draft November 15, 2024 00:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant