- 博客(9)
- 资源 (2)
- 收藏
- 关注
原创 animation中的transform
css代码 #tra{ width: 100px; height: 100px; background: #ffff00; transform-style: preserve-3d; -webkit-transform: translate3d(10px,10px,10p
2016-05-01 20:47:32 358
原创 获取css样式属性
为了得到css的属性,通过style.属性名称,只能得到在style中设置的属性值,为了得到外联的css以及写在外部的css样式,可以用下面的代码var b=document.getElementById("b"); if(b.currentStyle) k=b.currentStyle["width"]; else k=window.get
2016-04-25 14:47:36 455
原创 stroke-width
今天在学习中发现了一个吓死宝宝的事情。就是这个stroke-width,它是以边界为中心,把值平分给两边。 再大一点还有更好玩的
2016-04-20 20:30:42 1043
转载 list动画
俩个有趣的动画 TweenMax.staggerFrom(".btn",2,{scale:0.5,opacity:0, delay:0.5, ease:Elastic.easeOut},0.2) TweenMax.staggerFrom(".b",2,{scale:0.5,opacity:0,cycle:{x:[-100,100]}, ease:Elastic.easeOut});
2016-03-21 22:14:04 369
转载 TweenMax page-hopper
这个好看动画归功于TweenMax,line的x1跟x2一样,stroke-linecap="round",就出现圆点,然后动态改变x1和x2来实现移动 var tl = new TimelineMax(); tl.to('#joinLine', 0.3, { attr:{ x1:target.getAttribute('cx') },
2016-03-21 21:52:55 366
原创 TweenMax的小用法
用 TweenMax制作炫酷魔性动画 html代码 JavaScript代码 window.onload=function(){ var d=document.getElementById("box"); var name=document.getElementById("name"); TweenMax.set(name, { position
2016-03-21 21:31:07 1264
转载 padding-bottom和 margin-bottom
通过设置margin-bottom跟padding-bottom绝对值相同 padding-bottom:200px; margin-bottom:-200px; 能达到同高 html代码 style="height:50px" style="height:100px"
2016-03-21 21:12:10 1768
转载 css百事可乐
用css打造这个图案 html代码 css代码 body { height: 100%; background: #34588e; display: flex; justify-content:center; align-items:center; } .an{ border-radius: 50%; background: #34588e; height:
2016-03-21 20:21:57 1925
通过js获取主要颜色
2016-06-26
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人