Skip to content

Commit

Permalink
update props table of Transition component
Browse files Browse the repository at this point in the history
  • Loading branch information
RobinMalfait committed Oct 8, 2020
1 parent d4b5de4 commit 126f2c5
Showing 1 changed file with 15 additions and 11 deletions.
26 changes: 15 additions & 11 deletions packages/@headlessui-react/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -312,17 +312,21 @@ function MyComponent({ isShowing }) {

##### Props

| Prop | Type | Description |
| ----------- | ------------------------------------- | ------------------------------------------------------------------------------------- |
| `show` | Boolean | Whether the children should be shown or hidden. |
| `as` | String Component _(Default: `'div'`)_ | The element or component to render in place of the `Transition` itself. |
| `appear` | Boolean _(Default: `false`)_ | Whether the transition should run on initial mount. |
| `enter` | String _(Default: '')_ | Classes to add to the transitioning element during the entire enter phase. |
| `enterFrom` | String _(Default: '')_ | Classes to add to the transitioning element before the enter phase starts. |
| `enterTo` | String _(Default: '')_ | Classes to add to the transitioning element immediately after the enter phase starts. |
| `leave` | String _(Default: '')_ | Classes to add to the transitioning element during the entire leave phase. |
| `leaveFrom` | String _(Default: '')_ | Classes to add to the transitioning element before the leave phase starts. |
| `leaveTo` | String _(Default: '')_ | Classes to add to the transitioning element immediately after the leave phase starts. |
| Prop | Type | Description |
| ------------- | ------------------------------------- | ------------------------------------------------------------------------------------- |
| `show` | Boolean | Whether the children should be shown or hidden. |
| `as` | String Component _(Default: `'div'`)_ | The element or component to render in place of the `Transition` itself. |
| `appear` | Boolean _(Default: `false`)_ | Whether the transition should run on initial mount. |
| `enter` | String _(Default: '')_ | Classes to add to the transitioning element during the entire enter phase. |
| `enterFrom` | String _(Default: '')_ | Classes to add to the transitioning element before the enter phase starts. |
| `enterTo` | String _(Default: '')_ | Classes to add to the transitioning element immediately after the enter phase starts. |
| `leave` | String _(Default: '')_ | Classes to add to the transitioning element during the entire leave phase. |
| `leaveFrom` | String _(Default: '')_ | Classes to add to the transitioning element before the leave phase starts. |
| `leaveTo` | String _(Default: '')_ | Classes to add to the transitioning element immediately after the leave phase starts. |
| `beforeEnter` | Function | Callback which is called before we start the enter transition. |
| `afterEnter` | Function | Callback which is called after we finished the enter transition. |
| `beforeLeave` | Function | Callback which is called before we start the leave transition. |
| `afterLeave` | Function | Callback which is called after we finished the leave transition. |

##### Render prop arguments

Expand Down

0 comments on commit 126f2c5

Please sign in to comment.