text-input | R Documentation |
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)
inputId |
The input slot that will be used to access the value. |
label |
Input label. |
placeholder |
Input placeholder. |
color |
A valid bulma color, e.g.: |
rows |
Number of rows of text. |
size |
A valid bulma text size, |
disabled, readonly |
Set to |
session |
A shiny session. |
value |
Value to update. |
John Coene, jcoenep@gmail.com
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") }) } ) }
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.