Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Correct all READMEs related to the hasDisabledAnimation prop #150

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion packages/react-collapsed/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ const { getCollapseProps, getToggleProps, isExpanded, setExpanded } =
collapsedHeight: 0,
easing: string,
duration: number,
hasDisabledAnimation: boolean,
onTransitionStateChange: func,
})
```
Expand All @@ -99,8 +100,8 @@ The following are optional properties passed into `useCollapse({ })`:
| collapsedHeight | number | `0` | The height of the content when collapsed |
| easing | string | `cubic-bezier(0.4, 0, 0.2, 1)` | The transition timing function for the animation |
| duration | number | `undefined` | The duration of the animation in milliseconds. By default, the duration is programmatically calculated based on the height of the collapsed element |
| hasDisabledAnimation | boolean | `undefined` | If true, will disable the animation. If `undefined`, will fallback to media `prefers-reduced-animation` setting. |
| onTransitionStateChange | function | no-op | Handler called with at each stage of the transition animation |
| hasDisabledAnimation | boolean | false | If true, will disable the animation |

### What you get

Expand Down
3 changes: 2 additions & 1 deletion packages/react/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,7 @@ const { getCollapseProps, getToggleProps, isExpanded, setExpanded } =
collapsedHeight: 0,
easing: string,
duration: number,
hasDisabledAnimation: boolean,
onCollapseStart: func,
onCollapseEnd: func,
onExpandStart: func,
Expand All @@ -112,11 +113,11 @@ The following are optional properties passed into `useCollapse({ })`:
| collapsedHeight | number | `0` | The height of the content when collapsed |
| easing | string | `cubic-bezier(0.4, 0, 0.2, 1)` | The transition timing function for the animation |
| duration | number | `undefined` | The duration of the animation in milliseconds. By default, the duration is programmatically calculated based on the height of the collapsed element |
| hasDisabledAnimation | boolean | `undefined` | If true, will disable the animation. If `undefined`, will fallback to media `prefers-reduced-animation` setting. |
| onCollapseStart | function | no-op | Handler called when the collapse animation begins |
| onCollapseEnd | function | no-op | Handler called when the collapse animation ends |
| onExpandStart | function | no-op | Handler called when the expand animation begins |
| onExpandEnd | function | no-op | Handler called when the expand animation ends |
| hasDisabledAnimation | boolean | `undefined` | If true, will disable the animation. If `undefined`, will fallback to media `prefers-reduced-animation` setting. |

### What you get

Expand Down