-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmixin.scss
84 lines (82 loc) · 1.87 KB
/
mixin.scss
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
@mixin justice-content ($_){
justify-content:$_ ;
-webkit-justify-content: $_;
}
@mixin align-items ($_){
align-items:$_ ;
-webkit-align-items: $_;
}
@mixin border-radius($_){
-webkit-border-radius:$_;
-moz-border-radius:$_;
border-radius:$_;
}
@mixin border-radius-($_, $__ ,$___){
border-#{$_}-#{$__}-radius: #{$___};
-webkit-border-#{$_}-#{$__}-radius: #{$___};
-moz-border-radius-#{$_}#{$__}: #{$___};
}
@mixin transition($_) {
-webkit-transition: $_ ;
-moz-transition: $_ ;
-ms-transition: $_ ;
-o-transition: $_ ;
transition: $_ ;
}
@mixin background-size-cover {
-webkit-background-size:cover;
background-size:cover;
}
@mixin background-size($_) {
-webkit-background-size:$_;
background-size:$_;
}
@mixin square_icon($pixel: 40px){
font-size:$pixel / 2;
color: $main_red;
background-color: #FFFFFF;
border-radius: $main_radius;
height: $pixel;
line-height: $pixel;
width: $pixel;
text-align: center;
}
@mixin flex{
display: -webkit-box;
display: -moz-box;
display: -ms-flexbox;
display: -webkit-flex;
display: flex;
}
@mixin flex_($vertical,$horizon){
@include flex;
-webkit-justify-content: $horizon;
justify-content: $horizon;
-webkit-align-items: $vertical;
align-items: $vertical;
}
@mixin calc($_,$__){
#{$_}:-moz-calc(#{$__});
#{$_}:-webkit-calc(#{$__});
#{$_}:calc(#{$__});
}
@mixin flex_wrap($_){
@include flex;
flex-wrap: $_;
-webkit-flex-wrap: $_;
-ms-flex-wrap: $_;
}
@mixin text_overflow($font-size,$line-height){
font-size: $font-size;
line-height: $line-height;
$lines-to-show: 3;
display: block; /* Fallback for non-webkit */
display: -webkit-box;
height: $font-size*$line-height*$lines-to-show; /* Fallback for non-webkit */
margin: 0 auto;
font-size: $font-size;
-webkit-line-clamp: $lines-to-show;
-webkit-box-orient: vertical;
overflow: hidden;
text-overflow: ellipsis;
}