Observe glass_theme_toggle() buttons on the server
Source: R/glass-theme.R
observe_glass_theme_toggle.RdWires the three toggle inputs to update_glass_theme() so session state
stays aligned with the client (needed on some hosts that rewrite 'shiny'
messaging).
Arguments
- input
The server
inputobject.- session
The server
sessionobject.- inputId
Same base id passed to
glass_theme_toggle().
See also
glass_theme_toggle(), update_glass_theme(), observe_glass()
Other glass controls:
glass_accent_input(),
glass_intensity_slider(),
glass_plot_surface_input(),
glass_preset_input(),
glass_resolved_preset(),
glass_scene_input(),
glass_system_colors(),
glass_theme_toggle(),
observe_glass(),
observe_glass_accent(),
observe_glass_intensity(),
observe_glass_plot_surface(),
observe_glass_preset_input(),
observe_glass_scene()
Examples
if (interactive()) {
library(shiny)
ui <- fluidPage(
theme = glass_theme(),
glass_theme_toggle()
)
server <- function(input, output, session) {
observe_glass_theme_toggle(input, session)
}
shinyApp(ui, server)
}