This is the configuration component library for managing app configurations
clearForm(input)
Clear all form elements. Triggered on form load or exit
input
TODO
TODO
configChoices()
This returns a list of 'config name – date created' with key configId the returned list is used to populate the options for the config select input
array of configId -> 'configname – date'
configSelectorUI()
The config select element.
select input with id=kb_config
configSettingsUI()
The main UI modal form
The config settings modal form
configs()
reactive wrapper around our config fetcher
list of app input configurations
deleteConfig(rowId)
Delete the configuration
rowId
id of the configuration row
resp will be TRUE if successful. otherwise an error will be thrown.
deleteConfigResultUI()
Actually performs the delete and returns a DOM element indicating operation status
DOM
getConfigs()
Get app configurations from the Shiny Bundle.
List of app configurations.
initialize(sapiClient, component, configId,
session = getDefaultReactiveDomain())
Constructor.
sapiClient
Storage API client.
bucket
Bucket where config table is stored.
shinyUrl
Shiny Bundle API home URL.
It will be read from command line argument.
loadConfigResultUI(callback)
Returns DOM element depending on the success/failure of the config load
callback
The method to be executed with the loaded config.
This method will generally be tasked with updating input elements with the values which were stored in the config.
DOM element
saveConfig()
This method stores the entire session$input object as a row in the app configuration. Note that inputs with prefix kb_ will be omitted because they are system elements.
TRUE, will throw an error if something goes wrong.
saveConfigResultUI()
Saves the app input configuration returns the UI depending on the success of the operation
list(UI elements)
saveConfigUI()
sets DOM for the save configuration form. text input and button
DOM
selectedConfig()
Uses the configId from the configuration select input to return the currently selected configuration
Currently selected app configuration
settingsModalButton()
the toolbar button that brings up the configuration settings modal dialog
list(button)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.