-
Notifications
You must be signed in to change notification settings - Fork 88
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
Update networking widgets so they show a Raspberry Pi icon and arrows pointing towards/out of it. #3166
base: master
Are you sure you want to change the base?
Update networking widgets so they show a Raspberry Pi icon and arrows pointing towards/out of it. #3166
Conversation
Reviewer's Guide by SourceryThe pull request updates the networking widgets to display a Raspberry Pi icon and directional arrows, introduces a new WifiNetworking widget, and refactors bandwidth formatting into a utility function. Updated class diagram for Networking and WifiNetworking widgetsclassDiagram
class ETh0Widget {
+int timer
+OneMoreTime check_backend_status_task
+String image
+int upload()
+int download()
+void mounted()
+void beforeDestroy()
+String formatBandwidth(int bytesPerSecond)
+void loadImage()
}
class Wifi0Widget {
+int timer
+OneMoreTime check_backend_status_task
+String image
+int upload()
+int download()
+void mounted()
+void beforeDestroy()
+String formatBandwidth(int bytesPerSecond)
+void loadImage()
}
class Networking {
+ETh0Widget component
+String name
}
class WifiNetworking {
+Wifi0Widget component
+String name
}
class formatBandwidth {
+String formatBandwidth(int bytesPerSecond)
}
ETh0Widget --> formatBandwidth
Wifi0Widget --> formatBandwidth
Networking --> ETh0Widget
WifiNetworking --> Wifi0Widget
File-Level Changes
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 @Williangalvani - I've reviewed your changes - here's some feedback:
Overall Comments:
- Consider renaming the 'ETh0Widget' to 'Eth0Widget' for consistent casing in the component name.
- The 'loadImage' method is duplicated in both 'Networking.vue' and 'WifiNetworking.vue'; consider refactoring it into a shared utility function to avoid code duplication.
Here's what I looked at during the review
- 🟡 General issues: 2 issues found
- 🟢 Security: all looks good
- 🟢 Testing: all looks good
- 🟢 Complexity: all looks good
- 🟢 Documentation: all looks good
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
cbe98a3
to
437f1f5
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.
Did you forget to push? The new RX/TX arrows aren't included yet.
Also, could we add a widget for USB0 as well? And possibly UAP0 (if it's not included in the Wifi one)?
437f1f5
to
c8b121c
Compare
Frontend: allow showing bandwidth for wifi frontend: update networking widgets for using the a blueos-on-sbc with css colors
c8b121c
to
db6b26d
Compare
yep. oops. |
Arrow colours don't seem to be working properly in dark mode: Screen.Recording.2025-02-27.at.5.58.26.pm.movThe failsafe icon outlines look fine though, so not sure what's going on. Also, were you intending to add those extra widgets, or save that for a different PR? |
Also adds a wifi option as a bonus
(I bet sourcery will complain of the v-html)