Skip to contents

Adds a button which triggers a modal dialog (popup) with specified content.

Usage

page_popup(text = "Popup", ..., title = text, footer = NULL,
  wraps = NA, sizes = NA, breakpoints = NA, conditions = "",
  id = NULL)

Arguments

text

Text in the triggering button.

...

Elements to appear in the popup's body area.

title

Content to appear in the popup's header area. Defaults to text.

footer

A list of elements to include in the footer.

wraps

The class of wrapper to place elements in; either "row", "col", or "" (to not wrap the element). Can specify 1 for every element, or a different class for each element.

sizes

The relative size of each wrapper, between 1 and 12, or "auto"; default is equal size.

breakpoints

Bootstrap breakpoint of each wrapper; one of "" (extra small), "sm", "md", "lg", "xl", or "xxl".

conditions

A character for each element representing the conditions in which that should be showing (e.g., c("", "input_a == a", "")); "" means the element's display is not conditional. Adding "lock: " before the condition will disable inputs rather than hide the element.

id

Unique ID of the section.

Value

A character vector of the content to be added.

Details

See the Bootstrap grid documentation.

Examples

if (FALSE) {
page_popup(
  "<h1>Title</h1>",
  "<p>body</p>",
)
}