A
A
Alexander2018-10-13 20:44:57
css
Alexander, 2018-10-13 20:44:57

How to connect animation to block hiding?

Hello. There is a switch, it is also a checkbox, by clicking on which a block with text and animation pops up (animate.css). Switching back hides this block. How to do. in order for the hide to be animated, that is, you need to add a class, for example animated fadeOutUp. I ask for your help.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Arseny, 2018-10-13
@Marktolog

Do not use display:block\none. Since css animation will not be applied to.
Of the options:

  1. Use jQuery (IMHO, not worth dragging it around just for this)
  2. Make a state transition
  3. Fully describe animation in JS (There are experimental animates in the documentation, but I don’t undertake to use them yet)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question