简体   繁体   中英

jquery easeOutBounce horizontal

I'm trying to do a easeOutBounce horizontal animation, but all i succeed to do is vertical easeOutBounce, with this : $('#tester').slideToggle(1000,'easeOutBounce');

here is my jsfiddle : https://jsfiddle.net/newzy08/xpvt214o/372035/

I haven't seen any easeOutBounce effect with jquery slide() function...

What may i change in my code for switching from vertical to horizontal easeOutBounce ?

Thanks !

use this with a bit of change in your css

$('#tester').animate({
  width: '300px'
}, {
  duration: 1000,
  specialEasing: {
    width: "easeOutBounce"
  }
});

https://jsfiddle.net/hnpt4xgb/

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM