variable.less
1003 字节
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
.container(){
width:1024px;
margin:0px auto;
}
//圆角
.variable-border-radius(@radius:2px;){
-webkit-border-radius:@radius;
--moz-border-radius:@radius;
border-radius:@radius;
}
//盒子阴影
.variable-box-shadow(@x:0px;@y:0px;@xy:2px;@color:rgba(0,0,0,0.3);){
-webkit-box-shadow:@arguments;
--moz-box-shadow:@arguments;
box-shadow:@arguments;
};
//文字阴影
.variable-text-shadow(@x:0px;@y:0px;@xy:2px;@color:rgba(0,0,0,0.3);){
-webkit-text-shadow:@arguments;
--moz-text-shadow:@arguments;
text-shadow:@arguments;
};
//border-box
.border-box{
-webkit-box-sizing:border-box;
--moz-box-sizing:border-box;
box-sizing:border-box;
}
//clear float
.clear-float(){
clear:both;
height:0px;
visibility:hidden;
overflow:hidden;
content:'';
display:block;
}
//过渡效果
.css3-transition(@property:all;@time:0.3s;@fun:ease;){
-webkit-transition:@arguments;
--moz-transition:@arguments;
--ms-transition:@arguments;
--o-transition:@arguments;
transition:@arguments;
}
//渐变背景效果