describe_using {savonliquide}R Documentation

Describe an HTML element by another one

Description

Describe an HTML element by another one

Usage

describe_using(element, descID)

Arguments

element

the HTML element to describe

descID

one or a vector of many HTML elements' <IDs> that will be used to describe the 'element' parameter

Value

an HTML element described by another HTML element

Examples

if (interactive()) {
  ui <- fluidPage(
    h2("Using a screen reader
        hit Tab and Shift + Tab to
        navigate between the buttons
        and stop at button 2 to see the difference"),

    div(
      id = "paragraph",
      p("The following paragraph tag will be used as a descriptor")
    ),

    actionButton(
      inputId = "inp1",
      label = "button 1"
    ),
    actionButton(
      inputId = "inp2",
      label = "button 2"
    ) %>%
      describe_using(
        descID = "paragraph"
      )
  )

  server <- function(input, output, session) {}

  shinyApp(ui, server)
}

[Package savonliquide version 0.2.0 Index]