From 5596d21fe04ca753784405cdea20127ac5a1d917 Mon Sep 17 00:00:00 2001 From: stla Date: Sat, 23 Mar 2024 13:51:36 +0100 Subject: [PATCH] closes #29 --- NEWS.md | 4 ++-- inst/htmlwidgets/jstreer.js | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/NEWS.md b/NEWS.md index c7c0102..3adc3a9 100644 --- a/NEWS.md +++ b/NEWS.md @@ -1,9 +1,9 @@ -# jsTreeR 2.6.0 (2024-02-15) +# jsTreeR 2.6.0 (2024-03-24) - The `jstree` function has a new argument `coreOptions`, allowing to pass a list of jsTree core options. For advanced usage. -- There was a JavaScript error occuring in Shiny apps when the browser window +- There was a JavaScript error occurring in Shiny apps when the browser window was resized while using a jsTree grid in the app. It has been fixed. diff --git a/inst/htmlwidgets/jstreer.js b/inst/htmlwidgets/jstreer.js index c367d12..208be86 100644 --- a/inst/htmlwidgets/jstreer.js +++ b/inst/htmlwidgets/jstreer.js @@ -331,7 +331,7 @@ HTMLWidgets.widget({ Shiny.setInputValue("jsTreeMoved:jsTreeR.copied", { from: { instance: oldInstanceId, path: oldPath }, to: { instance: newInstanceId, path: newPath } - }); + }, {priority: "event"}); if(data.is_multi) { // ?? setShinyValue(oldInstance, checkboxes); setShinyValue(newInstance, checkboxes); @@ -454,7 +454,7 @@ HTMLWidgets.widget({ Shiny.setInputValue("jsTreeDeleted:jsTreeR.path", { instance: instance.element.attr("id"), path: instance.get_path(data.node) - }); + }, {priority: "event"}); setShinyValue(instance, checkboxes); } });