npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

framation

v1.1.8

Published

animate util using javascript and jquery

Downloads

1

Readme

framation

Build Status

Animation utility plugin using javascript or jquery

Install

  • using npm
# npm
npm install framation --save
# yarn
yarn add framation
  • dowonload source & import script
<!doctype html>
<html>
  <head>
    <script src="path/to/framation.min.js"></script>
  </head>
</html>

Usage

  • html
<div class="test"></div>
  • javascript
import Framation from 'framation';
// or
const Framation = require('framation');

var ani = new Framation();

ani
  .set(document.querySelector('.test'), {left: '100px', time: 2000})  // test element move left 100px during 2seconds
  .set(document.querySelector('.test'), {left: '200px', time: 2000})  // test element move left 200px during 2seconds after move left 100px

Framation

Kind: global class

new Framation()

Framation class

Animate.this.isIE : boolean

is IE browser

Kind: static property of Animate

Animate.this.isAnimation : boolean

animation operate

Kind: static property of Animate

Animate.this.enable : boolean

animation enable

Kind: static property of Animate

Animate.this.queue : Array

animation queue

Kind: static property of Animate

Animate.this.div : boolean

animation target div

Kind: static property of Animate

Animate.this.cssEase : Object

css ease object

Kind: static property of Animate Properties

| Name | Type | Description | | --- | --- | --- | | _default | string | ease | | in | string | ease-in | | out | string | ease-out | | in-out | string | ease-in-out | | snap | string | cubic-bezier(0,1,.5,1) | | easeOutCubic | string | cubic-bezier(.215,.61,.355,1) | | easeInOutCubic | string | cubic-bezier(.645,.045,.355,1) | | easeInCirc | string | cubic-bezier(.6,.04,.98,.335) | | easeOutCirc | string | cubic-bezier(.075,.82,.165,1) | | easeInOutCirc | string | cubic-bezier(.785,.135,.15,.86) | | easeInExpo | string | cubic-bezier(.95,.05,.795,.035) | | easeInOutExpo | string | cubic-bezier(1,0,0,1) | | easeInQuad | string | cubic-bezier(.55,.085,.68,.53) | | easeOutQuad | string | cubic-bezier(.25,.46,.45,.94) | | easeInOutQuad | string | cubic-bezier(.455,.03,.515,.955) | | easeInQuart | string | cubic-bezier(.895,.03,.685,.22) | | easeOutQuart | string | cubic-bezier(.165,.84,.44,1) | | easeInOutQuart | string | cubic-bezier(.77,0,.175,1) | | easeInQuint | string | cubic-bezier(.755,.05,.855,.06) | | easeOutQuint | string | cubic-bezier(.23,1,.32,1) | | easeInOutQuint | string | cubic-bezier(.86,0,.07,1) | | easeInSine | string | cubic-bezier(.47,0,.745,.715) | | easeOutSine | string | cubic-bezier(.39,.575,.565,1) | | easeInOutSine | string | cubic-bezier(.445,.05,.55,.95) | | easeInBack | string | cubic-bezier(.6,-.28,.735,.045) | | easeOutBack | string | cubic-bezier(.175, .885,.32,1.275) | | easeInOutBack | string | cubic-bezier(.68,-.55,.265,1.55) |

Animate.this.transform : string

transform

Kind: static property of Animate

Animate.this.transition : string

transition

Kind: static property of Animate

Animate.this.transitionDuration : string

transition duration

Kind: static property of Animate

Animate.this.transitionTimingFunction : string

transition timing function

Kind: static property of Animate

Animate.this.transform3d : boolean

transform 3d

Kind: static property of Animate

Animate.getVendorPropertyName() ⇒ string

return prop name using browser engine

Kind: static method of Animate Returns: string - prop name

Animate.checkTransform3dSupport() ⇒ boolean

return support 3d transform

Kind: static method of Animate Returns: boolean - transform3d support

Animate.getTransform(style) ⇒ Object

return target's transform to object

Kind: static method of Animate Returns: Object - transform object

| Param | Type | Description | | --- | --- | --- | | style | Object | style object |

Animate.clear() ⇒ Object

clear animation

Kind: static method of Animate Returns: Object - Ani Example

ani1
   .clear();

 ani
   .set(function () {
   });

Animate.pause() ⇒ Object

pause animation

Kind: static method of Animate Returns: Object - Ani Example

ani1
   .set({target, 'left', '50%'})
   .pause();

Animate.play() ⇒ Object

play animation

Kind: static method of Animate Returns: Object - Ani

Animate.set() ⇒ Object

animation set

Kind: static method of Animate Returns: Object - Ani Example

ani1
  .set(target, 'left', '50%') // move target element left 50%
  .set(target2, { time: 1000, left: '0%' }) // move target2 element left 0%
  .set(function () {  // animation pause and start after 2seconds
    var self = this,
        timer = null;

    this.pause();
    console.log('pause');

    timer = setTimeout(function () {
      self.play();
      console.log('play');
    }, 2000);
  })
  .set(target, {ease: 'easeInOutBack', time: 4000, left: '50%', top: '50%'})  // target element set ease and left 50%, top 50% during 4s
  .set(target, {  // target add test class maintain animation 1s
    time: 1000,
    func: function () {
      $(target).addClass('test');
    }
  })

Animate.destroy()

destory animate