Skip to main content

Animations

note

Animations overrides are applicable to Checkbox and Radio only

In terms of basic concepts we're at the end of the road folks. We've learned a lot about what PCR can do, now it's time to explore the crown jewel of the library: animations.

adevnture time

Animations are broken into two categories:

  1. Animations that only work with images
  2. Animations that work without images as well (i.e. universal animations)

Possible values: smooth, pulse, tada, jelly, and rotate.

Universal Animations#

Universal, or basic, animations work with all configurations of Checkbox and Radio (including with icons). Out of the list of five, there are two that can be used universally:

  • smooth
  • pulse
Live Editor
Result
SyntaxError: Unexpected token (1:8)
1 : return ()
            ^

Icon Animations#

Icons animations are intended to be used when the icon prop is defined. There are three new animations that can be used:

  • tada
  • jelly
  • rotate
Live Editor
Result
SyntaxError: Unexpected token (1:8)
1 : return ()
            ^