R/widget_solutionSettings_server.R
updateSolutionSettings.RdChange the settings for solution settings widget on the client. Specifically, change the settings for a theme or weight depicted in a solution settings widget.
updateSolutionSettings(
session = shiny::getDefaultReactiveDomain(),
inputId,
value
)| session | The |
|---|---|
| inputId |
|
| value |
|
The argument to value should be list object containing
the information necessary to update a theme or weight.
Broadly speaking, it should contain the following elements:
character value with the identifier for the theme or weight.
character value with the name of the setting to update.
ANY new value for the setting.
character value indicating if the setting is a theme
or weight.
Note that the value element in the list object should have a
class (i.e. numeric, logical, or character) that is relevant to the setting that should be updated. For example, if the settingelement is equal toname, then the valueelement should contain acharacter` value.
For reference, we provide examples detailing all the various settings that
can be updated below.
Here we detail all possible settings that can be updated for themes.
Update the name. This controls the bold text shown in the header of the theme.
"THEMEID"
"name"
"SPECIES"
"theme"
Update the status.
This controls the large switch shown in the header of theme.
Note that the value element must be a logical (TRUE or FALSE) value.
"THEMEID"
"status"
TRUE
"theme"
Update the feature current values. This controls the current expected amount for a feature.
"THEMEID"
"feature_current"
0.1
"theme"
Update the feature goals. This controls the slider used to specify goal for a feature.
"THEMEID"
"feature_goal"
0.8
"theme"
Update the feature maxima. This controls the maximum possible amount for each feature.
"THEMEID"
"feature_max"
34
"theme"
Here we detail all possible settings that can be updated for weights.
Update the name. This controls the bold text shown in the header.
"WEIGHTID"
"name"
"SPECIES"
"weight"
Update the factor. This controls the slider shown for the feature.
"WEIGHTID"
"factor"
0.1
"weight"
Here we detail all possible settings that can be updated for the parameter.
Update the parameter. This controls the highest possible value for the slider.
"PARAMETERID"
"value"
9999
"parameter"