| Dialog.triggerId | R Documentation |
Custom Dialog bound to a DOM element by id. See 'js/src/MuiDialogTriggerId.jsx'. Open/close state is managed entirely client-side, so this works in Shiny apps, Quarto documents, and static HTML without server logic.
Dialog.triggerId(triggerId, ...)
triggerId |
HTML id of an existing DOM element that acts as the trigger to open the Dialog. |
... |
Named arguments forwarded as React props, plus children to render inside the component. |
Object with 'shiny.tag' class suitable for use in the UI of a Shiny app.
library(shiny)
library(muiMaterial)
ui <- muiMaterialPage(
Button(id = "openDialog", "Open dialog"),
Dialog.triggerId(
"openDialog",
DialogTitle("Hello"),
DialogContent("Open/close managed entirely client-side.")
)
)
shinyApp(ui, function(input, output, session) {})
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.