fileBrowserInput {psichomics} | R Documentation |
Input to interactively select a file or directory on the server
fileBrowserInput(id, label, value = NULL, placeholder = NULL, info = FALSE, infoFUN = NULL, infoPlacement = "right", infoTitle = "", infoContent = "")
id |
Character: input identifier |
label |
Character: input label (NULL to show no label) |
value |
Character: initial value (paths are expanded via
|
placeholder |
Character: placeholder when no file or folder is selected |
info |
Boolean: add information icon for tooltips and popovers |
infoFUN |
Function to use to provide information (e.g.
|
infoPlacement |
Character: placement of the information (top, bottom, right or left) |
infoTitle |
Character: text to show as title of information |
infoContent |
Character: text to show as content of information |
To show the dialog for file input, the prepareFileBrowser
function needs to be included in the server logic.
This widget relies on fileBrowser
to present an interactive
dialogue to users for selecting a directory on the local filesystem.
Therefore, this widget is intended for shiny apps that are run locally - i.e.
on the same system that files/directories are to be accessed - and not from
hosted applications (e.g. from https://www.shinyapps.io).
HTML elements for a file browser input
Original code by wleepang: https://github.com/wleepang/shiny-directory-input
updateFileBrowserInput
and prepareFileBrowser