mirror of
https://github.com/nextcloud/spreed.git
synced 2025-08-16 15:27:59 +00:00
fix(dashboard): throttle events to update with Home button
Signed-off-by: Maksim Sukharev <antreesy.web@gmail.com>
This commit is contained in:
@ -328,6 +328,8 @@ const FILTER_LABELS = {
|
|||||||
default: '',
|
default: '',
|
||||||
}
|
}
|
||||||
|
|
||||||
|
let actualizeDataTimeout = null
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'LeftSidebar',
|
name: 'LeftSidebar',
|
||||||
|
|
||||||
@ -956,6 +958,14 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
refreshTalkDashboard() {
|
refreshTalkDashboard() {
|
||||||
|
// Throttle click and keyboard events
|
||||||
|
if (actualizeDataTimeout) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
actualizeDataTimeout = setTimeout(() => {
|
||||||
|
actualizeDataTimeout = null
|
||||||
|
}, 5_000)
|
||||||
|
|
||||||
if (this.isInDashboard) {
|
if (this.isInDashboard) {
|
||||||
EventBus.emit('refresh-talk-dashboard')
|
EventBus.emit('refresh-talk-dashboard')
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user