Coder Social home page Coder Social logo

bounce.js's People

Contributors

cranesandcaff avatar joelbesada avatar ryanseddon avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

bounce.js's Issues

Feature Request: the ability to reverse the current animation

I am often using your tool to create "open" and "close" animations. I love the ease of use by the way. But it would be great to use your online editor to get the "open" animation just the way I want it, and then be able to push a button or something and generate the reverse "close" animation, which would be the exact same, but in the opposite direction. Do you think that would be possible?

Translations in percentages

As far as I can tell it currently only supports fixed pixel values, is it possible to allow percentages as well?

[FEATURE REQUEST] Allow percentages in from/to for components in applyTo

The general idea is to allow something like this:

$elements = $('#foo') # assume <div> element with width and height equal to 100px

animation = new Bounce()

animation.translate(
  from: { x: 0, y: 0 },
  to: { x: 0, y: '100%' }, # Translate up 100% (at time of evaluation, 100px)
  easing: 'bounce',
  duration: 1500,
  delay: 0,
  bounces: 2,
  stiffness: 5
).translate(
  from: { x: 0, y: 0 },
  to: { x: '100%', y: 0 }, # Translate right 100% (at time of evaluation, 100px)
  easing: 'bounce',
  duration: 1500,
  delay: 0,
  bounces: 2,
  stiffness: 5
)

animation.applyTo($elements)

The reason is that it makes bounce animations much more dynamic with respect to either the current DOM properties of the applied elements (and could be even more flexible if we could interpolate with the current values established by previous components in the chain).

EDIT: After further thought and inspection, I'm wondering - is this even possible with the usage of matrices?

Let me know. Thanks, cheers.

Naming animations

Great project! To make copying and pasting the exported css easier, it would be nice to add a field to set the animation name so you don't have to change that in your code every time. Also omit the .animation-target {} rule from the output and put that in some documentation instead. This would make the workflow super efficient. Thanks again, great job.

Multiple animations in one page

Hi, thanks for creating great tool. Is it possible to add multiple animation into one page? I tried to create two different classes, but its only applying the last animation style.

Thanks

Opacity support

Is it possible to add opacity support? It is useful in animations (without bounce) :)

Starting Points of Animations

Is it possible to have starting points for the animations? for example, if I'm using the "jelly" preset, the animated elements animation starts at coordinates center center. Can I change them to start top left for example. x:0 and y:0?

Simplify

Very nice tool, but many animations gets quite a lot of CSS-code for most of the presets. A "simplify" button would be nice, so the code maybe do the animation in fever steps and therefore saves some kb. Maybe a slider, so the user can find the perfect point between smooth animation and an acceptable number of CSS-lines.

Difficult to setup

Hi, it is difficult for me to locate the files required to use Bounce. I want to know how large the files are, and how to include it in the browser using script and link tags.

If you can make it a little more straightforward that would be nice.

Thanks.

Naming in bounce.js

Hey! Great project!
Im new to GitHub so I hope this is the correct place to post this. Love the webapp but Bounce.js is so crunk. Again, props bro.

I was experimenting with saving multiple instances of Bounce & then reapplying them to other elements. The object automatically gets renamed because in "Bounce.prototype.applyTo" the "this.define()" is passed without a name, so if you did have a name it gets ignored/reset.

I was kind of wondering if there was a reason behind this? Thanks.

Bounce.prototype.define = function(name) {
    this.name = name || Bounce.generateName();
    this.styleElement = document.createElement("style");
    this.styleElement.innerHTML = this.getKeyframeCSS({
      name: this.name,
      prefix: true
    });
    document.body.appendChild(this.styleElement);
    return this;
  };

  Bounce.prototype.applyTo = function(elements, options) {
    var css, deferred, element, prefix, prefixes, _i, _j, _len, _len1, _ref;
    if (options == null) {
      options = {};
    }
    this.define();
    if (!elements.length) {
      elements = [elements];
    }
    prefixes = this.getPrefixes();
    deferred = null;
...

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.