cloudhead/less.js — pull request #527 by hokaccha (2011-12-15 02:23:38+00:00)
Title: Add function `percentage`

Before, percentage calculated by self.

@page: 960px;
@column: 300px;

.responsive(@count:1){
@percent: (@column / @page * @count) * 100;
width: ~'@{percent}%';
}

[role="main"] {
.responsive(2);
}
[role="navigation"] {
.responsive(1);
}

so added percetage function.

@page: 960px;
@column: 300px;

.responsive(@count:1){
width: percentage(@column / @page * @count);
}

[role="main"] {
.responsive(2);
}
[role="navigation"] {
.responsive(1);
}