jquery模仿360开机动画案例
2020-07-14 05:04
411 查看
代码
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title></title> <style type="text/css"> * { padding: 0; margin: 0; } .outer { width: 200px; position: fixed; bottom: 0; right: 0; display: none; } span { position: absolute; border: 1px solid black; cursor: pointer; } .topPart { width: 200px; height: 120px; background-color: yellow; } .downPart { width: 200px; height: 120px; background-color: yellowgreen; } </style> <script type="text/javascript" src="jQuery.js"></script> <script type="text/javascript"> $(function(){ //1.进场动画 $('.outer').fadeIn(1500); $('span').click(function(){ //2.下半部分高度慢慢变为0 $('.downPart').animate({ height:0 },500,function(){ //3.整个盒子宽度为0 $('.outer').animate({ width:0 },500); }); }); }); </script> </head> <body> <div class="outer"> <span>关</span> <div class="topPart"></div> <div class="downPart"></div> </div> </body> </html>
相关文章推荐
- 【分享】模仿jquery的animate(自定义动画)
- 模仿淘宝写一个商品动画加入购物车纯jQuery,没有引用插件
- 案例七 、jquery模仿微信聊天界面
- javascript原生360 开机小动画
- 【前端】javascript+jQuery实现360开机时间显示效果
- javascript+jQuery实现360开机时间显示效果
- jQuery中通过animate做一个简单的上下滑动的动画案例
- 模仿iPhone滑动开机动画
- 用jQuery和css3实现的一个模仿淘宝ued博客左边的菜单切换动画效果
- 1.1.10 JQuery高级:动画,遍历,事件绑定,插件,案例
- 模仿百度首页“元宵节汤圆”动图,并实现360°不停旋转(CSS3的animation动画效果)
- jQuery实现的模仿雨滴下落动画效果
- JQuery 自定义动画案例
- jQuery串行动画小案例
- Qt自定义圆周动画(360 10.0 的模仿作者写的)
- jQuery实现圣诞节礼物动画案例解析
- 前端案例:170行css制作Apple手机开机动画
- OmniROM 4.4.2安卓开机动画
- 安卓开机动画集合贴【自己做的哦~…
- jQuery实现图像旋转动画效果