-
Notifications
You must be signed in to change notification settings - Fork 737
use CopyableText (click-to-copy) in GUI for instance info #3878
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
Conversation
ddf482a to
8ff9e3e
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.
Looks good! I can copy things that are copyable! Just a small comment on simplifying Tooltip building.
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3878 +/- ##
==========================================
+ Coverage 89.03% 89.10% +0.07%
==========================================
Files 255 255
Lines 14577 14600 +23
==========================================
+ Hits 12978 13010 +32
+ Misses 1599 1590 -9 ☔ View full report in Codecov by Sentry. |
a17ceed to
e4e0678
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.
Thanks, @levkropp! It works great, as expected, but there are some things in the code that could be changed.
c132468 to
4a48812
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.
just a few cosmetic things
4a48812 to
2f58580
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.
Perfect!
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.
LGTM!
closes #3821
This pull request introduces a new
CopyableTextwidget and updates several components to use this widget for improved text copy functionality. Additionally, it modifies theTooltipwidget to be stateful to handle dynamic changes in the tooltip message.New
CopyableTextwidget:src/client/gui/lib/copyable_text.dart: Created a newCopyableTextwidget that allows text to be copied to the clipboard with a click and displays a tooltip indicating the copy status.Updates to
Tooltipwidget:src/client/gui/lib/tooltip.dart: ChangedTooltipfrom a stateless to a stateful widget to handle updates to the tooltip message dynamically.Integration of
CopyableTextwidget:src/client/gui/lib/vm_details/ip_addresses.dart: Updated theIpAddresseswidget to optionally useCopyableTextfor IP addresses, enabling copy functionality.src/client/gui/lib/vm_details/vm_details_general.dart: Replaced several instances ofTextwithCopyableTextin theVmDetailsHeaderandGeneralDetailswidgets to allow copying of VM details such as name, release, and IP addresses.src/client/gui/lib/vm_table/vm_table_headers.dart: Updated the VM table headers to useCopyableTextfor displaying and copying VM image and IP addresses.Screencast_20250115_121606.webm