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 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112
|
.test(@a){
font: @a;
colors:red;
}
foo{
@a: 12px;
@b: normal;
.test(@a @b);
}
form {
dl {
+ p {
margin-bottom: 0;
}
}
}
.transform (@function) {
-webkit-transform: @function;
}
div{
.transform(rotate(90));
}
.grd {
background-size: @pw / @cols, @pw / @cols;
}
@-moz-keyframes flash {
0%, 50%, 100% {opacity: 1;}
25%, 75% {opacity: 0;}
}
@keyframes shake {
0%, 100% {transform: translateX(0);}
10%, 30%, 50%, 70%, 90% {transform: translateX(-10px);}
20%, 40%, 60%, 80% {transform: translateX(10px);}
}
.colourise (@image, @colour) {
background: -webkit-linear-gradient(left, @colour, @colour), url (@image);
}
.test{
.colourise('aaa.png', #444);
}
@var: `"hello".toUpperCase() + '!'`;
.test{
width: ~"100%";
}
@name: blocked;
.@{name} {
color: black;
}
@singleQuery: "(max-width: 500px)";
@media screen, @singleQuery {
set {
padding: 3 3 3 3;
}
}
.mixin(@val){
color: red
}
.important {
.mixin(2) !important;
}
.mixin (@a) when (lightness(@a) >= 50%) {
background-color: black;
}
.child, .sibling {
.parent & {
color: black;
}
& + & {
color: red;
}
}
@attr:1;
@name:1;
pre {
.test2(red);
}
@media screen and (max-width: 400px) {
h1 { color: green; }
}
.transition() {
h1 {
color: red;
}
}
.a,
.b {
width: 1050px;
}
.transition; //correct mixin call
.transition, div { //not a mixin call
}
.test2(@j){
color: @j;
font-size: @attr;
}
// comment on last line
|