miniTitleBar {miniUI} | R Documentation |
Create a title bar
Description
Creates a title bar for a Shiny app or Shiny Gadget. Intended to be used with
miniPage
. Title bars contain a title, and optionally, a
miniTitleBarButton
on the left and/or right sides.
Usage
miniTitleBar(title, left = NULL, right = NULL)
gadgetTitleBar(title, left = miniTitleBarCancelButton(),
right = miniTitleBarButton("done", "Done", primary = TRUE))
miniTitleBarButton(inputId, label, primary = FALSE)
miniTitleBarCancelButton(inputId = "cancel", label = "Cancel",
primary = FALSE)
Arguments
title |
The title of the gadget. If this needs to be dynamic, pass
|
left |
The |
right |
The |
inputId |
The |
label |
The text label to display on the button. |
primary |
If |
Details
gadgetTitleBar
is a miniTitleBar
with different
defaults: a Cancel button on the left and a Done button on the right. By
default, runGadget
will handle the Cancel button by
closing the gadget and raising an error, but the Done
button must be
handled by the gadget author using observeEvent(input$done, {...})
.
miniTitleBarCancelButton
is like miniTitleBarButton
,
but the user can also invoke it by hitting the Escape key.
See Also
For more information, see the Designing Gadget UI article on shiny.rstudio.com.
Examples
miniTitleBar("My App",
left = miniTitleBarButton("prev", "Previous"),
right = miniTitleBarButton("next", "Next")
)