Skip to content

Events

TypeDescription
onBeforeMatchfunction(optional) Is called after matching content inside a closed animation is opened using openOnFind. Use it to synchronize external open state and controls.
onOpenfunction(optional) Is called when fully opened or closed. Returns true or false depending on the state.
onAnimationStartfunction(optional) Is called when animation has started. The first parameter is a string. Depending on the state, the value can be opening, closing or adjusting.
onAnimationEndfunction(optional) Is called when animation is done and the full height is reached. The first parameter is a string. Depending on the state, the value can be opened, closed or adjusted.
onInitfunction(optional) Is called once before mounting the component (useLayoutEffect). Returns the instance of the internal animation class.
Edit on GitHub