_mixins.scss
1.2 KB
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
47
48
49
50
51
52
53
54
55
56
/*
| @header mixins
| @author wangzhixiang (zhixiang.wang@yoho.cn)
| @abstract
*/
@mixin font-face($font-family,$file-path,$font-weight:normal,$font-style:normal){
@font-face {
font: {
family: $font-family;
weight: $font-weight;
style: $font-style;
}
src: url("#{$file-path}.eot");
src: url("#{$file-path}.eot?#iefix") format("embedded-opentype"),
url("#{$file-path}.woff") format("woff"),
url("#{$file-path}.ttf") format("truetype"),
url("#{$file-path}.svg##{$font-family}") format("svg");
}
}
@mixin size($width, $height){
width: $width;
height: $height;
}
@mixin text-overflow(){
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
@mixin hide-text(){
font: 0/0 a;
color: transparent;
text-shadow: 0;
background-color: transparent;
border: 0;
}
@mixin placeholder($color: $placeholder){
&:-moz-placeholder {
color: $color;
}
&:-ms-input-placeholder {
color: $color;
}
&:-webkit-input-placeholder {
color: $color;
}
}
@mixin arrow($type, $width ,$size) {
.YOHOBUY-arrow-#{$type} {
position: relative;
}
}