foundation / foundation/motion-ui

JavaScript API Changes

Open
#40 0 comments 0 reactions 0 assignees View on GitHub
🚀 feature javascript
Dominant language
SCSS
Stars
1.2k
Forks
169
PR merge metrics
No merged PRs in 30d

Description

Here are some things we want to add or change to the JavaScript API.

`animateIn` and `animateOut` would be renamed `transitionIn` and `transitionOut`, to make it less confusing that a function called "animate" only works with transitions.

Right now there's no method to add animations, because all you need to do is add a class. But we could write a wrapper that also handles removing the class for you, and giving you a callback that fires when the animation completes (if it has a finite number of loops).

It might look like this:

``` js
MotionUI.animate('#element', 'wiggle', function() {
// Animation done
});
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.