shiny icon indicating copy to clipboard operation
shiny copied to clipboard

Add input/output flag "disabled" (present, but not currently applicable or possible)

Open epruesse opened this issue 2 years ago • 0 comments

There are situations in which disabling input/output widgets is the best way to keep the user informed about possible actions, effective/applicable settings and possible outputs. This includes "graying out" the widget and making it non-reactive to events such as clicks or drag-drop.

One could argue that the need for this indicates bad UI design. Often that may be true, but it's still easier and shiny apps typically don't justify a month's worth of UX work. Disabled state is a simple and easy to understand way to convey that an input or output is in principle present, but at the current time not possible or not applicable.

Implementing this in third party extensions such as shinyjs is limited and difficult. Firstly, TypeScript widgets such as fileInput require deep meddling to turn off e.g. drag and drop features when they are disabled. Secondly, it's essential to have a universal visual for the disabled state (not so easy with things that are gray to start with).

It would be great to have this as a core feature, accessible via standard interfaces. E.g. fileInput(..., disabled=TRUE) and updateSelectize(..., disabled=TRUE).

epruesse avatar Apr 07 '22 17:04 epruesse