Skip to content

Commit

Permalink
fix(dashboard): don't reload hidden widgets
Browse files Browse the repository at this point in the history
Signed-off-by: Richard Steinmetz <[email protected]>
  • Loading branch information
st3iny committed Jan 10, 2025
1 parent 3b97190 commit 11c5793
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
4 changes: 4 additions & 0 deletions apps/dashboard/src/DashboardApp.vue
Original file line number Diff line number Diff line change
Expand Up @@ -290,6 +290,10 @@ export default {
for (const widget of Object.values(this.apiWidgets)) {
if (widget.reload_interval > 0) {
setInterval(async () => {
if (!this.layout.includes(widget.id)) {
return
}
await this.fetchApiWidgetItems([widget.id], true)
}, widget.reload_interval * 1000)
}
Expand Down
4 changes: 2 additions & 2 deletions dist/dashboard-main.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/dashboard-main.js.map

Large diffs are not rendered by default.

0 comments on commit 11c5793

Please sign in to comment.