~ubuntu-branches/ubuntu/wily/phabricator/wily

« back to all changes in this revision

Viewing changes to src/lint/linter/__tests__/lessc/mixins-named-args.lint-test

  • Committer: Package Import Robot
  • Author(s): Richard Sellam
  • Date: 2014-11-01 23:20:06 UTC
  • mto: This revision was merged to the branch mainline in revision 4.
  • Revision ID: package-import@ubuntu.com-20141101232006-mvlnp0cil67tsboe
Tags: upstream-0~git20141101/arcanist
Import upstream version 0~git20141101, component arcanist

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
.mixin (@a: 1px, @b: 50%) {
 
2
  width: (@a * 5);
 
3
  height: (@b - 1%);
 
4
  args: @arguments;
 
5
}
 
6
.mixin (@a: 1px, @b: 50%) when (@b > 75%){
 
7
  text-align: center;
 
8
}
 
9
 
 
10
.named-arg {
 
11
  color: blue;
 
12
  .mixin(@b: 100%);
 
13
}
 
14
 
 
15
.class {
 
16
  @var: 20%;
 
17
  .mixin(@b: @var);
 
18
}
 
19
 
 
20
.all-args-wrong-args {
 
21
  .mixin(@b: 10%, @a: 2px);
 
22
}
 
23
 
 
24
.mixin2 (@a: 1px, @b: 50%, @c: 50) {
 
25
  width: (@a * 5);
 
26
  height: (@b - 1%);
 
27
  color: (#000000 + @c);
 
28
}
 
29
 
 
30
.named-args2 {
 
31
  .mixin2(3px, @c: 100);
 
32
}
 
33
 
 
34
.named-args3 {
 
35
  .mixin2(@b: 30%, @c: #123456);
 
36
}
 
37
~~~~~~~~~~