gsap wrapper API
The goal is to create a function witch return a Interpol instance and takes params like gsap does.
const tween = itp(element, {
x: "10px", // will extract value from string and add unit after interpolation
y: 50, // will add px by default
opacity: { from: 0.1, to: 1 } // will accept Props
ease: "power3.out",
onComplete: ({x}, time, props, instance) => {
// access to same callbacks than Interpol.
}
})
- [x] get element and options params
- [ ] compute style for
fromproperties - [ ] make element (first param) optionnel
⚠️ No Changeset found
Latest commit: 2ebaf5b9da2f746174d05786ab57ba564a0aaa91
Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.
This PR includes no changesets
When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types
Click here to learn what changesets are, and how to add one.
Click here if you're a maintainer who wants to add a changeset to this PR
size-limit report 📦
| Path | Size |
|---|---|
| @wbe/interpol | 2.82 KB (0%) |
This pull request is automatically built and testable in CodeSandbox.
To see build info of the built libraries, click here or the icon next to each commit SHA.
Latest deployment of this branch, based on commit 2ebaf5b9da2f746174d05786ab57ba564a0aaa91:
| Sandbox | Source |
|---|---|
| interpol-basic | Configuration |
| interpol-colors | Configuration |
| interpol-dom-ondrag | Configuration |
| interpol-ease | Configuration |
| interpol-graphic | Configuration |
| interpol-menu | Configuration |
| interpol-object-el | Configuration |
| interpol-particles | Configuration |
| interpol-timeline | Configuration |
| interpol-offsets | Configuration |