-
Notifications
You must be signed in to change notification settings - Fork 508
Add default class names while Anim
Dariel Noel edited this page Oct 1, 2014
·
4 revisions
Sometimes it can be necesary to add class names to know if an object it's being animated. In case of animate.css library the class name used is animated.
<div class="bounce animated"></div>
It would be bothersome add in the behaviors these class names.
<div data-anijs="if: click, do: animated bounce"></div>
That's why AniJS has an attribute classNamesWhenAnim that can be change through the method setClassNamesWhenAnim.
//Put #container as root travel scope
AniJS.setClassNamesWhenAnim('animated');
From now on, every time you need to animate an object with AniJS you will use this class too.
- Get started
- The AniJS Language
- Sentence and Definitions
- Playing with CSS classes
- Clone and remove html elements
- Selecting html elements
- Referring to the current element
- Emitting your own events is easy
- Browser Compatibility
- Registering new Helpers
- Animation Context Instance
- Writing before and after functions
- Remove animation after function
- Hold animation after function
- Listening events from document and window
- Add default class names while Anim
- Changing travel scope
- Creating Events Systems
- Custom Events Listening
- Purge Events
- Handling Animations Using JavaScript
- Running AniJS repeatedly
- JQuery Events System
- Using AMD