a11y_column: Accessible column

View source: R/layout.R

a11y_columnR Documentation

Accessible column

Description

A wrapper for shiny::column() with optional ARIA attributes according to BITV 2.0 and custom CSS class. Ensures responsive layout by validating that columns have appropriate widths.

Usage

a11y_column(width, ..., offset = NULL, id = NULL, aria_label = NULL)

Arguments

width

Column width (as in shiny::column(): 1–12)

...

Content for column

offset

(optional) Column offset (as in shiny::column(), 1–12)

id

(optional) Column ID

aria_label

(optional) aria-label for the column/region

Value

HTML ⁠<div>⁠ tag with classes for grid and a11y

Examples

# Simple column
a11y_column(6, htmltools::p("Half width content"))

# Column with offset and aria-label
a11y_column(4,
  offset = 2,
  aria_label = "Sidebar",
  htmltools::p("Offset column")
)

# Column with a descriptive aria-label for a form section
a11y_column(4,
  aria_label = "Histogram settings",
  htmltools::p("Configuration controls go here")
)


a11yShiny documentation built on April 1, 2026, 5:07 p.m.