Add text input.
bulmaTextInput(inputId, label = NULL, placeholder = "", color = NULL)
bulmaTextAreaInput(
inputId,
label = NULL,
placeholder = "",
rows = 1,
color = NULL,
size = NULL,
disabled = FALSE,
readonly = FALSE
)
bulmaUpdateTextInput(session, inputId, value = NULL)
The input slot that will be used to access the value.
Input label.
Input placeholder.
A valid bulma color, e.g.:success
.
Number of rows of text.
A valid bulma text size, small
, medium
or large
.
Set to TRUE
to disable or set on read-only.
A shiny session.
Value to update.
if(interactive()){
library(shiny)
shinyApp(
ui = bulmaNavbarPage(
theme = "dark",
bulmaTextInput("txt", label = "Input text", placeholder = "Type here"),
verbatimTextOutput("txtOutput"),
bulmaTextAreaInput("txtArea", rows = 10, label = "Input text area",
color = "primary", size = "medium"),
verbatimTextOutput("txtAreaOutput"),
bulmaTextAreaInput("disabled", label = "disabled", disabled = TRUE,
placeholder = "disabled"),
bulmaActionButton("update", "Update text input")
),
server = function(input, output, session) {
output$txtOutput <- renderPrint({ input$txt })
output$txtAreaOutput <- renderPrint({ input$txtArea })
observeEvent( input$update, {
updateTextInput(session, "txt", value = "Updated")
})
}
)
}