-
Notifications
You must be signed in to change notification settings - Fork 15
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
Input actions
#166
Comments
* Nav inputs may trigger nav panes with the `targets` argument (#166)
actions
I have revised the API. The argument is now Implicit
|
* The targetting feature is now better named `actions`. (#166)
* Use `showNavTarget()` and `hideNavTarget()` with a reactive input to change nav panes anywhere in an application (#166)
To make calling the correct plugin much easier I have switched from |
I am unsure how actions will interact with updating an input. I think selecting new values must trigger any corresponding actions or an application could quickly get out of sync. |
* Nav inputs may trigger nav panes with the `targets` argument (#166)
* The targetting feature is now better named `actions`. (#166)
* Use `showNavTarget()` and `hideNavTarget()` with a reactive input to change nav panes anywhere in an application (#166)
Description
@jcheng5, after describing the current system of showing nav panes and based on my work thus far with {yonder}, I have started implementing a new approach. I agree freezing the layout of an application during a long running process is sub-optimal. The new approach allows inputs to target elements with bootstrap plugins (navs, alerts, modals, etc.) and makes use of the
data-target
attributes (as you brought up) to trigger these plugin elements.For now only
navInput()
has been updated. Below are some potential uses of the newtargets
argument.targets
is a character stringIf
targets
is a character string the input's values are assumed as id's of plugin elements, i.e. the id of anavPane()
. For now, the value"pages"
is actually ignored and I am considering usingTRUE
instead. (The values of an input if not specified default to the choices)targets
is a character vectorIf
targets
is a character vector each value is considered a corresponding id target for each choice/value of the input. The targets and values are matched by index.targets
is a named vector or listIf
targets
is a named character vector or list the names are used to match input values to a target id. ANULL
value may be used to prevent a certain input value from triggering any effect.targets
is a list and includes multi-length itemsThis case allows a single input value to trigger two targets.
Demo
If you install the feat/input-targets branch you can try out the following demo.
The text was updated successfully, but these errors were encountered: