Skip to content

Commit

Permalink
Update Transitions for unstyled Accordion in tailwinddoc.js (#6954)
Browse files Browse the repository at this point in the history
The old version did not work. Replaced with transitions found in lib/passthrough/tailwind/index.js
  • Loading branch information
samy-mssi authored Jul 31, 2024
1 parent 59098c8 commit c5f6f9f
Showing 1 changed file with 9 additions and 6 deletions.
15 changes: 9 additions & 6 deletions components/doc/accordion/theming/tailwinddoc.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,15 @@ export function TailwindDoc(props) {
basic: `
const TRANSITIONS = {
toggleable: {
enterFromClass: 'max-h-0',
enterActiveClass: 'overflow-hidden transition-all duration-500 ease-in-out',
enterToClass: 'max-h-40 ',
leaveFromClass: 'max-h-40',
leaveActiveClass: 'overflow-hidden transition-all duration-500 ease-in',
leaveToClass: 'max-h-0'
timeout: 500,
classNames: {
enter: 'max-h-0',
enterActive:
'!max-h-[1000px] overflow-hidden transition-[max-height] duration-500 ease-in',
exit: 'max-h-[1000px]',
exitActive:
'!max-h-0 overflow-hidden transition-[max-height] duration-500 ease-out',
}
}
};
Expand Down

0 comments on commit c5f6f9f

Please sign in to comment.