You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So in the initial state I assigned to searchString a value passed to props instead of empty string ('').
searchFocusIndex is still 0. and searchFoundCount is null.
Well.. the value is assigned and appears in the search textbox, and the highlighting border of the selected matching node appears as well. But the tree wan't expending to that node.
I need that expansion so that the matching node will not be hidden by father (like triggering onChange on normal searching).
fritz-c
changed the title
How to expend focused search result when assigning text in the search textbox using code?
How to expand focused search result when assigning text in the search textbox using code?
Jan 13, 2018
Hello again :)
I am trying to force-search a term in the tree by code.
In other words, I want some text to be assigned to the search textbox (as a value, not a placeholder) in the moment the tree is loading up for the first time. I also want that the search will work with the focus, highlighting and expending.
The code I am using for the search method is the code presented in Storybook:
https://fritz-c.github.io/react-sortable-tree/storybook/?selectedKind=Basics&selectedStory=Search&full=0&down=1&left=1&panelRight=0&downPanel=storybook%2Fnotes%2Fpanel
So in the initial state I assigned to searchString a value passed to props instead of empty string ('').
searchFocusIndex is still 0. and searchFoundCount is null.
Well.. the value is assigned and appears in the search textbox, and the highlighting border of the selected matching node appears as well. But the tree wan't expending to that node.
I need that expansion so that the matching node will not be hidden by father (like triggering onChange on normal searching).
My only changes in the code:
Thanks.
The text was updated successfully, but these errors were encountered: