({ children, as: Tag = "span" }: VisuallyHiddenProps)
| 11 | * Use for icon-only buttons, supplemental context, etc. |
| 12 | */ |
| 13 | export function VisuallyHidden({ children, as: Tag = "span" }: VisuallyHiddenProps) { |
| 14 | return ( |
| 15 | <Tag |
| 16 | style={{ |
| 17 | position: "absolute", |
| 18 | width: "1px", |
| 19 | height: "1px", |
| 20 | padding: 0, |
| 21 | margin: "-1px", |
| 22 | overflow: "hidden", |
| 23 | clip: "rect(0, 0, 0, 0)", |
| 24 | whiteSpace: "nowrap", |
| 25 | borderWidth: 0, |
| 26 | }} |
| 27 | > |
| 28 | {children} |
| 29 | </Tag> |
| 30 | ); |
| 31 | } |
nothing calls this directly
no outgoing calls
no test coverage detected