File tree Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Expand file tree Collapse file tree 1 file changed +11
-1
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ A custom element that shows text as if it were being typed
5
5
## Installation
6
6
7
7
```
8
- $ npm install @github/typing-effect-element
8
+ npm install @github/typing-effect-element
9
9
```
10
10
11
11
## Usage
@@ -21,6 +21,16 @@ import '@github/typing-effect-element'
21
21
</typing-effect >
22
22
```
23
23
24
+ ## Accessibility
25
+
26
+ This component detects whether ` prefers-reduced-motion ` is set on the window
27
+
28
+ ``` js
29
+ window .matchMedia (' (prefers-reduced-motion)' ).matches === true
30
+ ```
31
+
32
+ If this evaluates to true, any content lines provided will be appended immediately rather than being typed out with a delay.
33
+
24
34
## Browser support
25
35
26
36
Browsers without native [ custom element support] [ support ] require a [ polyfill] [ ] .
You can’t perform that action at this time.
0 commit comments