-
-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug]: TealAppDriver
setting numeric filter state
#1151
Comments
Are you sure you don't want to pass a |
That's a nice idea passing a app$set_active_filter_selection(
teal_slice("iris", "Sepal.Length", selected = c(4, 5))
) The operations that this call triggers would still be UI/input-based, but this would allow us to keep consistency. Care to give insights on reasons to keep current formals @vedhav ? ps. this would be a separate issue though as potential follow-up to this one. |
The I was able to do it via javascript (#1152), but if someone knows how to hint the handler via Shiny API, please chip in. The caveat of doing it this way is that the input boxes still hold the previous values. Side quest: The range input does not work out of the box with |
Yeah, |
For that we need access to the |
Oh, I see. I misunderstood the problem. Sorry. |
I wasn't totally explicit in the description. The issue here is that
So the downstream javascript call needs to be Which is what the PR does skipping all middle layers of |
# Pull Request <!--- Replace `#nnn` with your issue link for reference. --> Fixes #1151 #### Changes description - `shinyWidgets::numericRangeInput` uses a custom handler and seems to require a `js: Shiny.setInputValue` call - ~Change of explicit arguments in `{s,g}et_active_filter_selection` to `type` to reflect this logic and allow for further extensions.~ - Removed `is_numeric` argument in favor of auto-detection of slice type (categorical / numerical range) - from `{s,g}et_active_filter_selection` --------- Co-authored-by: 27856297+dependabot-preview[bot]@users.noreply.github.com <27856297+dependabot-preview[bot]@users.noreply.github.com> Co-authored-by: Vedha Viyash <[email protected]>
TealAppDriver$set_active_filter_selection
only works for categorical variables. It should also work for numeric ranges.Example below of test that should work
The text was updated successfully, but these errors were encountered: