UNPKG

1.32 kBTypeScriptView Raw
1/**
2 * @reach/visually-hidden v0.18.0
3 *
4 * Copyright (c) 2018-2022, React Training LLC
5 *
6 * This source code is licensed under the MIT license found in the
7 * LICENSE.md file in the root directory of this source tree.
8 *
9 * @license MIT
10 */
11
12import * as React from 'react';
13import * as Polymorphic from '@reach/polymorphic';
14
15/**
16 * Welcome to @reach/visually-hidden!
17 *
18 * Provides text for screen readers that is visually hidden.
19 * It is the logical opposite of the `aria-hidden` attribute.
20 *
21 * @see https://snook.ca/archives/html_and_css/hiding-content-for-accessibility
22 * @see https://a11yproject.com/posts/how-to-hide-content/
23 * @see Docs https://reach.tech/visually-hidden
24 * @see Source https://github.com/reach/reach-ui/tree/main/packages/visually-hidden
25 */
26
27/**
28 * VisuallyHidden
29 *
30 * Provides text for screen readers that is visually hidden.
31 * It is the logical opposite of the `aria-hidden` attribute.
32 */
33declare const VisuallyHidden: Polymorphic.ForwardRefComponent<"span", VisuallyHiddenProps>;
34/**
35 * @see Docs https://reach.tech/visually-hidden#visuallyhidden-props
36 */
37interface VisuallyHiddenProps {
38 /**
39 * @see Docs https://reach.tech/visually-hidden#visuallyhidden-children
40 */
41 children: React.ReactNode;
42}
43
44export { VisuallyHidden, VisuallyHiddenProps };