feat(desktop): traffic rate monitor support #1795
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
PR Checklist
If you have any questions, you can refer to the Contributing Guide
What is the new behavior?
This pull request includes significant updates to the chart components, traffic monitoring, and utility functions. The changes introduce new features, improve functionality, and enhance code readability. Below are the most important changes:
Chart Components
AreaLine.vue
toLineChartExtent.vue
and added a newtype
prop to switch between 'area' and 'line' chart types. Updated the chart rendering logic to handle the newtype
prop. [1] [2] [3]NumberCard.vue
component to display numerical values with optional icons and labels.Traffic Monitoring
TrafficMonitor.vue
to include rate calculation and display for received and sent traffic. Added new methods to handle metrics updates and chart initialization. [1] [2] [3]Utility Functions
systemTopic.ts
to merge received and sent metrics, calculate traffic rates, and transform traffic messages. Removed unused functions related to system topics.formatter.ts
to handle byte formatting more accurately and added handling for values less than one byte.Miscellaneous
viewer.ts
to include new translations for traffic rate labels.TopicTree.vue
to reflect the new file paths forTreeView.vue
andTreeNodeInfo.vue
.