Skip to content

Commit

Permalink
fix sync message for Vue 3
Browse files Browse the repository at this point in the history
  • Loading branch information
hhaensel committed Oct 7, 2024
1 parent 25ea269 commit 3b0b26c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions assets/js/syncplot.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ function watchGraphDiv(gd, model, prefix) {
}
return cursor
}

console.info('Syncing plot of class \'' + gd.className + '\' to ' + model.$el.id + '.' + prefix)
var id = model.$el.id || model.$el.parentElement.id // Vue-2 / Vue-3 compatibility
console.info('Syncing plot of class \'' + gd.className + '\' to ' + id + '.' + prefix)
gd.on("plotly_selected", function (data) {
var filteredEventData = filterEventData(gd, data, 'selected')
if (!filteredEventData.isNil) { model[prefix + '_selected'] = filteredEventData.out }
Expand Down

0 comments on commit 3b0b26c

Please sign in to comment.