From 35702fbfc53b500a19a2efc614857f21edd2c552 Mon Sep 17 00:00:00 2001 From: stla Date: Sun, 5 Nov 2023 22:41:19 +0100 Subject: [PATCH] cleaning --- inst/htmlwidgets/jstreer.js | 21 +-------------------- 1 file changed, 1 insertion(+), 20 deletions(-) diff --git a/inst/htmlwidgets/jstreer.js b/inst/htmlwidgets/jstreer.js index 17a1054..c71b870 100644 --- a/inst/htmlwidgets/jstreer.js +++ b/inst/htmlwidgets/jstreer.js @@ -253,32 +253,13 @@ HTMLWidgets.widget({ var $searchFields = $searchBoxesSelector; var searchValues = {}; //create for each input a key value pair with the key in the name attribute of the input (also being the index of the column) - $searchFields.each(function(){ + $searchFields.each(function() { var field = $(this); searchValues[field.attr("name")] = field.val(); }); //use the new searchColumn method $el.jstree(true).searchColumn(searchValues); }); - - -/* var $div = $(gridSearchBoxes(el.id)); - var $midWrapper = $el.closest(".jstree-grid-midwrapper"); - $div.insertBefore($midWrapper); - var divSelector = "#" + el.id + "-searchFields"; - //add search functionality to the input fields - $(divSelector + " input").keyup(function(e) { - //get all input fields - var inputFields = $(divSelector + " input"); - var searchValues = {}; - //create for each input a key value pair with the key in the name attribute of the input (also being the index of the column) - inputFields.each(function(){ - var field = $(this); - searchValues[field.attr('name')] = field.val(); - }); - //use the new searchColumn method - $el.jstree(true).searchColumn(searchValues); - }); */ } else { var $input = $( "