Giter VIP home page Giter VIP logo

animateto's Introduction

AnimateTo

Create animation for Css3 2D-transforms. Available transforms includes: rotate / translate / scale

Margin is used to handle offset in CSS2. BE CALEFUL to change them after applying transform in this case.

preview

Sample: http://www.rendxx.com/Lib/Sample/12
Download: AnimateTo v0.2.3

Install

Download the package from bower

bower install animateTo--save

Including the file in your webpage

<script type="text/javascript" src="/node_modules/animateTo/js/AnimateTo.js"></script>

API

API Document

Dependency

Code Sample

JavaScript:

$("#sample").animateTo({ rotate: "-=90" }, 1000, 'easeInOutQuart', null); 
$("#sample").animateTo({ scaleX: "+=0.2", scaleY: "+=0.2" }, 500);
$("#sample").animateTo({
    transform: {
        rotate: 0,
        scaleX: 1,
        scaleY: 1,
        translateX: 0,
        translateY: 0
    },
    duration: 700,
    onComplete: function () {
        msg.text("RESET!");
    }
});

Compatibility

Chrome Fire Fox Safari Edge IE 9-11 IE 7,8

License

Copyright © 2015, Rendxx. (MIT License)
See LICENSE for more info.

animateto's People

Contributors

rendxx avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.