-
Notifications
You must be signed in to change notification settings - Fork 812
fix: Connect Device screen #2923
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
base: flutter
Are you sure you want to change the base?
Conversation
Reviewer's GuideThis PR adds initialization of the board connection and refines navigation when the 'Connect Device' button is pressed, centers the layout of the Connect Device screen, and applies copy updates and bulk localization key additions across supported locales. Sequence diagram for Connect Device button interactionsequenceDiagram
actor User
participant "Connect Device Button"
participant Provider
participant Navigator
User->>"Connect Device Button": Click
"Connect Device Button"->>Provider: initialize()
alt On /connectDevice route
"Connect Device Button"->>Navigator: popUntil('/connectDevice')
else Not on /connectDevice route
"Connect Device Button"->>Navigator: pushNamedAndRemoveUntil('/connectDevice', isFirst)
end
File-Level Changes
Assessment against linked issues
Possibly linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey there - I've reviewed your changes - here's some feedback:
- After calling provider.initialize in the Connect Device button handler, consider showing a loading indicator or error feedback so users know when the connection is in progress or has failed.
- The push/pop navigation logic in main_scaffold_widget’s onPressed is a bit dense—extract it into a reusable helper function or service to improve readability and centralize route management.
- In ConnectDeviceScreen, you have several similarly styled, centered Text widgets—consider creating a small helper widget or iterating over a list of steps to reduce duplication.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- After calling provider.initialize in the Connect Device button handler, consider showing a loading indicator or error feedback so users know when the connection is in progress or has failed.
- The push/pop navigation logic in main_scaffold_widget’s onPressed is a bit dense—extract it into a reusable helper function or service to improve readability and centralize route management.
- In ConnectDeviceScreen, you have several similarly styled, centered Text widgets—consider creating a small helper widget or iterating over a list of steps to reduce duplication.
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
Build StatusBuild successful. APKs to test: https://github.com/fossasia/pslab-app/actions/runs/17895290592/artifacts/4066271503. Screenshots |
f80868a
to
58e120e
Compare
cf1e97d
to
32a2671
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update the description on the connection screen, e.g. use USB instead of Micro-USB and add the info that it is possible to connect via Bluetooth if the PSLab has the Bluetooth option.
Also note that the top bar has a black font color instead of white. I think this should probably be solved in a separate PR. |
@mariobehling I'll check this for all instruments and solve separately. |
307c4bc
to
49bb79d
Compare
@mariobehling Made the changes as follows: |
1a2724d
to
0a17a66
Compare
0a17a66
to
431d370
Compare
Fixes #2911
Adds initialization of connection to the board upon clicking the 'Connect Device' button.
Copy changes in the Connect Device screen.
Screenshots / Recordings
untitled.webm
Summary by Sourcery
Initialize device connection on 'Connect Device' action, refine navigation and UI alignment on the Connect Device screen, and bulk-expand localization with updated copy and new keys for control labels, barometer experiments, and playback controls.
New Features:
Bug Fixes:
Enhancements: