Debian Codegraph @

node/@patternfly/patternfly/docs/utilities/Accessibility/examples/Accessibility.md

raw
1 ---
2 id: Accessibility
3 section: foundations-and-styles
4 subsection: utility-classes
5 ---## Examples
6
7 ### Screen reader only
8
9 ```html
10 Content available only to screen reader, open inspector to investigate
11 <span
12 class="pf-v6-u-screen-reader"
13 >This content is intended to be announced by assistive technologies, but not visually presented.</span>
14
15 ```
16
17 ### Visible
18
19 ```html
20 <span
21 class="pf-v6-u-visible"
22 >This unsets .pf-v6-u-screen-reader and .pf-v6-screen-reader. It will be visible.</span>
23
24 ```
25
26 ### Hidden
27
28 ```html
29 The text underneath is hidden.
30 <span class="pf-v6-u-hidden">This text is hidden.</span>
31
32 ```
33
34 ## Documentation
35
36 ### Overview
37
38 [Breakpoints](/foundations-and-styles/design-tokens/all-design-tokens) are optional. Breakpoint options include: base (no breakpoint value), `-on-sm`, `-on-md`, `-on-lg`, and `-on-xl`. Example: `.pf-v6-u-screen-reader-on-lg`
39
40 ### Usage
41
42 | Class | Applied to | Outcome |
43 | -- | -- | -- |
44 | `.pf-v6-u-screen-reader{-on-[breakpoint]}` | `*` | Visually hides element, but leaves accessible to assistive technologies |
45 | `.pf-v6-u-visible{-on-[breakpoint]}` | `*` | Unsets `.pf-v6-u-screen-reader` and `.pf-v6-screen-reader` |