less 1.2.2 → 1.3.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.npmignore +1 -0
- package/CHANGELOG.md +118 -0
- package/CONTRIBUTING.md +50 -0
- package/Makefile +14 -2
- package/benchmark/benchmark.less +11 -11
- package/benchmark/less-benchmark.js +1 -1
- package/bin/lessc +77 -21
- package/build/amd.js +6 -0
- package/build/ecma-5.js +120 -0
- package/build/header.js +7 -0
- package/build/require-rhino.js +7 -0
- package/build/require.js +7 -0
- package/lib/less/browser.js +192 -53
- package/lib/less/colors.js +1 -0
- package/lib/less/functions.js +159 -10
- package/lib/less/index.js +125 -56
- package/lib/less/lessc_helper.js +62 -0
- package/lib/less/parser.js +391 -154
- package/lib/less/rhino.js +84 -23
- package/lib/less/tree/anonymous.js +15 -1
- package/lib/less/tree/assignment.js +3 -1
- package/lib/less/tree/call.js +12 -6
- package/lib/less/tree/color.js +10 -0
- package/lib/less/tree/dimension.js +3 -1
- package/lib/less/tree/directive.js +10 -10
- package/lib/less/tree/element.js +8 -7
- package/lib/less/tree/import.js +17 -14
- package/lib/less/tree/media.js +121 -0
- package/lib/less/tree/mixin.js +133 -45
- package/lib/less/tree/operation.js +5 -0
- package/lib/less/tree/quoted.js +15 -1
- package/lib/less/tree/ratio.js +13 -0
- package/lib/less/tree/rule.js +7 -0
- package/lib/less/tree/ruleset.js +236 -37
- package/lib/less/tree/selector.js +21 -11
- package/lib/less/tree/unicode-descriptor.js +13 -0
- package/lib/less/tree/url.js +16 -14
- package/lib/less/tree/variable.js +13 -1
- package/lib/less/tree.js +28 -0
- package/package.json +13 -3
- package/test/browser/common.js +74 -0
- package/test/browser/css/relative-urls/urls.css +36 -0
- package/test/browser/css/rootpath/urls.css +36 -0
- package/test/browser/css/rootpath-relative/urls.css +36 -0
- package/test/browser/css/urls.css +36 -0
- package/test/browser/jasmine-html.js +681 -0
- package/test/browser/jasmine.css +82 -0
- package/test/browser/jasmine.js +2600 -0
- package/test/browser/less/imports/urls.less +4 -0
- package/test/browser/less/imports/urls2.less +4 -0
- package/test/browser/less/relative-urls/urls.less +33 -0
- package/test/browser/less/rootpath/urls.less +33 -0
- package/test/browser/less/rootpath-relative/urls.less +33 -0
- package/test/browser/less/urls.less +33 -0
- package/test/browser/phantom-runner.js +139 -0
- package/test/browser/runner-browser.js +3 -0
- package/test/browser/runner-main.js +15 -0
- package/test/browser/runner-relative-urls.js +4 -0
- package/test/browser/runner-rootpath-relative.js +5 -0
- package/test/browser/runner-rootpath.js +4 -0
- package/test/browser/template.htm +10 -0
- package/test/browser-test-prepare.js +29 -0
- package/test/css/charsets.css +1 -0
- package/test/css/colors.css +22 -0
- package/test/css/comments.css +7 -0
- package/test/css/css-3.css +57 -2
- package/test/css/css-escapes.css +4 -0
- package/test/css/css.css +11 -11
- package/test/css/debug/linenumbers-all.css +43 -0
- package/test/css/debug/linenumbers-comments.css +35 -0
- package/test/css/debug/linenumbers-mediaquery.css +35 -0
- package/test/css/functions.css +59 -2
- package/test/css/ie-filters.css +7 -3
- package/test/css/import-once.css +3 -0
- package/test/css/import.css +7 -9
- package/test/css/javascript.css +3 -2
- package/test/css/media.css +168 -0
- package/test/css/mixins-args.css +35 -4
- package/test/css/mixins-guards.css +13 -0
- package/test/css/mixins-important.css +21 -0
- package/test/css/mixins-named-args.css +27 -0
- package/test/css/mixins-pattern.css +4 -6
- package/test/css/mixins.css +50 -0
- package/test/css/scope.css +20 -0
- package/test/css/selectors.css +76 -0
- package/test/css/static-urls/urls.css +42 -0
- package/test/css/strings.css +2 -2
- package/test/css/urls.css +42 -0
- package/test/css/variables.css +0 -1
- package/test/css/whitespace.css +4 -0
- package/test/less/charsets.less +3 -0
- package/test/less/colors.less +27 -0
- package/test/less/comments.less +12 -0
- package/test/less/css-3.less +54 -6
- package/test/less/css-escapes.less +6 -1
- package/test/less/css.less +14 -12
- package/test/less/debug/import/test.less +25 -0
- package/test/less/debug/linenumbers.less +23 -0
- package/test/less/errors/bad-variable-declaration1.less +1 -0
- package/test/less/errors/bad-variable-declaration1.txt +2 -0
- package/test/less/errors/comment-in-selector.less +1 -0
- package/test/less/errors/comment-in-selector.txt +2 -0
- package/test/less/errors/import-missing.less +1 -0
- package/test/less/errors/import-missing.txt +3 -0
- package/test/less/errors/import-no-semi.less +1 -0
- package/test/less/errors/import-no-semi.txt +2 -0
- package/test/less/errors/import-subfolder1.less +1 -0
- package/test/less/errors/import-subfolder1.txt +3 -0
- package/test/less/errors/import-subfolder2.less +1 -0
- package/test/less/errors/import-subfolder2.txt +2 -0
- package/test/less/errors/imports/import-subfolder1.less +1 -0
- package/test/less/errors/imports/import-subfolder2.less +1 -0
- package/test/less/errors/imports/import-test.less +4 -0
- package/test/less/errors/imports/subfolder/mixin-not-defined.less +1 -0
- package/test/less/errors/imports/subfolder/parse-error-curly-bracket.less +1 -0
- package/test/less/errors/javascript-error.less +3 -0
- package/test/less/errors/javascript-error.txt +4 -0
- package/test/less/errors/mixed-mixin-definition-args-1.less +6 -0
- package/test/less/errors/mixed-mixin-definition-args-1.txt +4 -0
- package/test/less/errors/mixed-mixin-definition-args-2.less +6 -0
- package/test/less/errors/mixed-mixin-definition-args-2.txt +4 -0
- package/test/less/errors/mixin-not-defined.less +11 -0
- package/test/less/errors/mixin-not-defined.txt +3 -0
- package/test/less/errors/mixin-not-matched.less +6 -0
- package/test/less/errors/mixin-not-matched.txt +3 -0
- package/test/less/errors/mixin-not-matched2.less +6 -0
- package/test/less/errors/mixin-not-matched2.txt +3 -0
- package/test/less/errors/parse-error-curly-bracket.less +1 -0
- package/test/less/errors/parse-error-curly-bracket.txt +2 -0
- package/test/less/errors/parse-error-missing-bracket.less +2 -0
- package/test/less/errors/parse-error-missing-bracket.txt +2 -0
- package/test/less/errors/parse-error-with-import.less +13 -0
- package/test/less/errors/parse-error-with-import.txt +4 -0
- package/test/less/errors/property-ie5-hack.less +3 -0
- package/test/less/errors/property-ie5-hack.txt +4 -0
- package/test/less/errors/recursive-variable.less +1 -0
- package/test/less/errors/recursive-variable.txt +2 -0
- package/test/less/functions.less +64 -2
- package/test/less/ie-filters.less +7 -0
- package/test/less/import/deeper/import-once-test-a.less +1 -0
- package/test/less/import/import-and-relative-paths-test.less +6 -0
- package/test/less/import/import-charset-test.less +1 -0
- package/test/less/import/import-once-test-c.less +6 -0
- package/test/less/import/import-test-a.less +1 -0
- package/test/less/import/import-test-c.less +0 -1
- package/test/less/import/imports/font.less +8 -0
- package/test/less/import/imports/logo.less +5 -0
- package/test/less/import/urls.less +1 -0
- package/test/less/import-once.less +4 -0
- package/test/less/import.less +2 -1
- package/test/less/javascript.less +4 -2
- package/test/less/media.less +169 -1
- package/test/less/mixins-args.less +54 -11
- package/test/less/mixins-guards.less +30 -0
- package/test/less/mixins-important.less +4 -0
- package/test/less/mixins-named-args.less +36 -0
- package/test/less/mixins-pattern.less +3 -0
- package/test/less/mixins.less +47 -0
- package/test/less/scope.less +48 -1
- package/test/less/selectors.less +88 -0
- package/test/less/static-urls/urls.less +33 -0
- package/test/less/strings.less +1 -1
- package/test/less/urls.less +33 -0
- package/test/less/variables.less +0 -1
- package/test/less/whitespace.less +7 -0
- package/test/less-test.js +145 -36
- package/bench.css +0 -5943
- package/benchmark/b1.less +0 -3980
- package/dist/less-1.1.0.js +0 -2695
- package/dist/less-1.1.0.min.js +0 -16
- package/dist/less-1.1.1.js +0 -2710
- package/dist/less-1.1.1.min.js +0 -16
- package/dist/less-1.1.2.js +0 -2712
- package/dist/less-1.1.2.min.js +0 -16
- package/dist/less-1.1.3.js +0 -2721
- package/dist/less-1.1.3.min.js +0 -16
- package/dist/less-1.1.4.js +0 -2769
- package/dist/less-1.1.4.min.js +0 -16
- package/dist/less-1.1.5.js +0 -2805
- package/dist/less-1.1.5.min.js +0 -9
- package/dist/less-1.1.6.js +0 -3004
- package/dist/less-1.1.6.min.js +0 -9
- package/dist/less-1.2.0.js +0 -3293
- package/dist/less-1.2.0.min.js +0 -9
- package/dist/less-1.2.1.js +0 -3318
- package/dist/less-1.2.1.min.js +0 -9
- package/dist/less-1.2.2.js +0 -3337
- package/dist/less-1.2.2.min.js +0 -9
- package/dist/less-rhino-1.1.3.js +0 -2460
- package/dist/less-rhino-1.1.5.js +0 -2481
- package/foo.less +0 -2
- package/lib/less/cssmin.js +0 -355
- package/test/html/index.html +0 -10
- package/test/html/less.js +0 -3333
- package/test/html/lib.less +0 -2
- package/test/html/styles.less +0 -8
- package/x.less +0 -4
|
@@ -2,20 +2,22 @@
|
|
|
2
2
|
|
|
3
3
|
tree.Selector = function (elements) {
|
|
4
4
|
this.elements = elements;
|
|
5
|
-
if (this.elements[0].combinator.value === "") {
|
|
6
|
-
this.elements[0].combinator.value = ' ';
|
|
7
|
-
}
|
|
8
5
|
};
|
|
9
6
|
tree.Selector.prototype.match = function (other) {
|
|
10
|
-
var
|
|
11
|
-
|
|
12
|
-
|
|
7
|
+
var elements = this.elements,
|
|
8
|
+
len = elements.length,
|
|
9
|
+
oelements, olen, max, i;
|
|
13
10
|
|
|
14
|
-
|
|
11
|
+
oelements = other.elements.slice(
|
|
12
|
+
(other.elements.length && other.elements[0].value === "&") ? 1 : 0);
|
|
13
|
+
olen = oelements.length;
|
|
14
|
+
max = Math.min(len, olen)
|
|
15
|
+
|
|
16
|
+
if (olen === 0 || len < olen) {
|
|
15
17
|
return false;
|
|
16
18
|
} else {
|
|
17
|
-
for (
|
|
18
|
-
if (
|
|
19
|
+
for (i = 0; i < max; i++) {
|
|
20
|
+
if (elements[i].value !== oelements[i].value) {
|
|
19
21
|
return false;
|
|
20
22
|
}
|
|
21
23
|
}
|
|
@@ -29,14 +31,22 @@ tree.Selector.prototype.eval = function (env) {
|
|
|
29
31
|
};
|
|
30
32
|
tree.Selector.prototype.toCSS = function (env) {
|
|
31
33
|
if (this._css) { return this._css }
|
|
32
|
-
|
|
33
|
-
|
|
34
|
+
|
|
35
|
+
if (this.elements[0].combinator.value === "") {
|
|
36
|
+
this._css = ' ';
|
|
37
|
+
} else {
|
|
38
|
+
this._css = '';
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
this._css += this.elements.map(function (e) {
|
|
34
42
|
if (typeof(e) === 'string') {
|
|
35
43
|
return ' ' + e.trim();
|
|
36
44
|
} else {
|
|
37
45
|
return e.toCSS(env);
|
|
38
46
|
}
|
|
39
47
|
}).join('');
|
|
48
|
+
|
|
49
|
+
return this._css;
|
|
40
50
|
};
|
|
41
51
|
|
|
42
52
|
})(require('../tree'));
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
(function (tree) {
|
|
2
|
+
|
|
3
|
+
tree.UnicodeDescriptor = function (value) {
|
|
4
|
+
this.value = value;
|
|
5
|
+
};
|
|
6
|
+
tree.UnicodeDescriptor.prototype = {
|
|
7
|
+
toCSS: function (env) {
|
|
8
|
+
return this.value;
|
|
9
|
+
},
|
|
10
|
+
eval: function () { return this }
|
|
11
|
+
};
|
|
12
|
+
|
|
13
|
+
})(require('../tree'));
|
package/lib/less/tree/url.js
CHANGED
|
@@ -1,24 +1,26 @@
|
|
|
1
1
|
(function (tree) {
|
|
2
2
|
|
|
3
|
-
tree.URL = function (val,
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
} else {
|
|
7
|
-
// Add the base path if the URL is relative and we are in the browser
|
|
8
|
-
if (typeof(window) !== 'undefined' && !/^(?:https?:\/\/|file:\/\/|data:|\/)/.test(val.value) && paths.length > 0) {
|
|
9
|
-
val.value = paths[0] + (val.value.charAt(0) === '/' ? val.value.slice(1) : val.value);
|
|
10
|
-
}
|
|
11
|
-
this.value = val;
|
|
12
|
-
this.paths = paths;
|
|
13
|
-
}
|
|
3
|
+
tree.URL = function (val, rootpath) {
|
|
4
|
+
this.value = val;
|
|
5
|
+
this.rootpath = rootpath;
|
|
14
6
|
};
|
|
15
7
|
tree.URL.prototype = {
|
|
16
8
|
toCSS: function () {
|
|
17
|
-
return "url(" +
|
|
18
|
-
: this.value.toCSS()) + ")";
|
|
9
|
+
return "url(" + this.value.toCSS() + ")";
|
|
19
10
|
},
|
|
20
11
|
eval: function (ctx) {
|
|
21
|
-
|
|
12
|
+
var val = this.value.eval(ctx), rootpath;
|
|
13
|
+
|
|
14
|
+
// Add the base path if the URL is relative
|
|
15
|
+
if (typeof val.value === "string" && !/^(?:[a-z-]+:|\/)/.test(val.value)) {
|
|
16
|
+
rootpath = this.rootpath;
|
|
17
|
+
if (!val.quote) {
|
|
18
|
+
rootpath = rootpath.replace(/[\(\)'"\s]/g, function(match) { return "\\"+match; });
|
|
19
|
+
}
|
|
20
|
+
val.value = rootpath + val.value;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
return new(tree.URL)(val, this.rootpath);
|
|
22
24
|
}
|
|
23
25
|
};
|
|
24
26
|
|
|
@@ -8,12 +8,24 @@ tree.Variable.prototype = {
|
|
|
8
8
|
if (name.indexOf('@@') == 0) {
|
|
9
9
|
name = '@' + new(tree.Variable)(name.slice(1)).eval(env).value;
|
|
10
10
|
}
|
|
11
|
+
|
|
12
|
+
if (this.evaluating) {
|
|
13
|
+
throw { type: 'Name',
|
|
14
|
+
message: "Recursive variable definition for " + name,
|
|
15
|
+
filename: this.file,
|
|
16
|
+
index: this.index };
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
this.evaluating = true;
|
|
11
20
|
|
|
12
21
|
if (variable = tree.find(env.frames, function (frame) {
|
|
13
22
|
if (v = frame.variable(name)) {
|
|
14
23
|
return v.value.eval(env);
|
|
15
24
|
}
|
|
16
|
-
})) {
|
|
25
|
+
})) {
|
|
26
|
+
this.evaluating = false;
|
|
27
|
+
return variable;
|
|
28
|
+
}
|
|
17
29
|
else {
|
|
18
30
|
throw { type: 'Name',
|
|
19
31
|
message: "variable " + name + " is undefined",
|
package/lib/less/tree.js
CHANGED
|
@@ -1,5 +1,33 @@
|
|
|
1
1
|
(function (tree) {
|
|
2
2
|
|
|
3
|
+
tree.debugInfo = function(env, ctx) {
|
|
4
|
+
var result="";
|
|
5
|
+
if (env.dumpLineNumbers && !env.compress) {
|
|
6
|
+
switch(env.dumpLineNumbers) {
|
|
7
|
+
case 'comments':
|
|
8
|
+
result = tree.debugInfo.asComment(ctx);
|
|
9
|
+
break;
|
|
10
|
+
case 'mediaquery':
|
|
11
|
+
result = tree.debugInfo.asMediaQuery(ctx);
|
|
12
|
+
break;
|
|
13
|
+
case 'all':
|
|
14
|
+
result = tree.debugInfo.asComment(ctx)+tree.debugInfo.asMediaQuery(ctx);
|
|
15
|
+
break;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
return result;
|
|
19
|
+
};
|
|
20
|
+
|
|
21
|
+
tree.debugInfo.asComment = function(ctx) {
|
|
22
|
+
return '/* line ' + ctx.debugInfo.lineNumber + ', ' + ctx.debugInfo.fileName + ' */\n';
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
tree.debugInfo.asMediaQuery = function(ctx) {
|
|
26
|
+
return '@media -sass-debug-info{filename{font-family:' +
|
|
27
|
+
('file://' + ctx.debugInfo.fileName).replace(/[\/:.]/g, '\\$&') +
|
|
28
|
+
'}line{font-family:\\00003' + ctx.debugInfo.lineNumber + '}}\n';
|
|
29
|
+
};
|
|
30
|
+
|
|
3
31
|
tree.find = function (obj, fun) {
|
|
4
32
|
for (var i = 0, r; i < obj.length; i++) {
|
|
5
33
|
if (r = fun.call(obj, obj[i])) { return r }
|
package/package.json
CHANGED
|
@@ -1,13 +1,23 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name" : "less",
|
|
3
3
|
"description" : "Leaner CSS",
|
|
4
|
-
"
|
|
4
|
+
"homepage" : "http://lesscss.org",
|
|
5
5
|
"keywords" : ["css", "parser", "lesscss", "browser"],
|
|
6
6
|
"author" : "Alexis Sellier <self@cloudhead.net>",
|
|
7
7
|
"contributors" : [],
|
|
8
|
-
"version" : "1.
|
|
8
|
+
"version" : "1.3.3",
|
|
9
9
|
"bin" : { "lessc": "./bin/lessc" },
|
|
10
10
|
"main" : "./lib/less/index",
|
|
11
11
|
"directories" : { "test": "./test" },
|
|
12
|
-
"engines" : { "node": ">=0.4.
|
|
12
|
+
"engines" : { "node": ">=0.4.2" },
|
|
13
|
+
"optionalDependencies" : { "ycssmin": ">=1.0.1" },
|
|
14
|
+
"devDependencies" : { "diff": "~1.0" },
|
|
15
|
+
"scripts": {
|
|
16
|
+
"test": "make test"
|
|
17
|
+
},
|
|
18
|
+
"bugs": { "url" : "https://github.com/cloudhead/less.js/issues"},
|
|
19
|
+
"repository" :
|
|
20
|
+
{ "type" : "git",
|
|
21
|
+
"url" : "https://github.com/cloudhead/less.js.git"
|
|
22
|
+
}
|
|
13
23
|
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
/*if not async then phantomjs fails to run the webserver and the test concurrently*/
|
|
2
|
+
var less = { async: true };
|
|
3
|
+
|
|
4
|
+
var testLessEqualsInDocument = function() {
|
|
5
|
+
var links = document.getElementsByTagName('link'),
|
|
6
|
+
typePattern = /^text\/(x-)?less$/;
|
|
7
|
+
|
|
8
|
+
for (var i = 0; i < links.length; i++) {
|
|
9
|
+
if (links[i].rel === 'stylesheet/less' || (links[i].rel.match(/stylesheet/) &&
|
|
10
|
+
(links[i].type.match(typePattern)))) {
|
|
11
|
+
testSheet(links[i]);
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
};
|
|
15
|
+
|
|
16
|
+
var testSheet = function(sheet) {
|
|
17
|
+
it(sheet.id + " should match the expected output", function() {
|
|
18
|
+
var lessOutputId = sheet.id.replace("original-", ""),
|
|
19
|
+
expectedOutputId = "expected-" + lessOutputId,
|
|
20
|
+
lessOutput = document.getElementById(lessOutputId).innerText,
|
|
21
|
+
expectedOutputHref = document.getElementById(expectedOutputId).href,
|
|
22
|
+
expectedOutput = loadFile(expectedOutputHref);
|
|
23
|
+
|
|
24
|
+
waitsFor(function() {
|
|
25
|
+
return expectedOutput.loaded;
|
|
26
|
+
}, "failed to load expected outout", 10000);
|
|
27
|
+
|
|
28
|
+
runs(function() {
|
|
29
|
+
// use sheet to do testing
|
|
30
|
+
expect(lessOutput).toEqual(expectedOutput.text);
|
|
31
|
+
});
|
|
32
|
+
});
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
var loadFile = function(href) {
|
|
36
|
+
var request = new XMLHttpRequest(),
|
|
37
|
+
response = { loaded: false, text: ""};
|
|
38
|
+
request.open('GET', href, true);
|
|
39
|
+
request.onload = function(e) {
|
|
40
|
+
response.text = request.response;
|
|
41
|
+
response.loaded = true;
|
|
42
|
+
}
|
|
43
|
+
request.send();
|
|
44
|
+
return response;
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
(function() {
|
|
48
|
+
var jasmineEnv = jasmine.getEnv();
|
|
49
|
+
jasmineEnv.updateInterval = 1000;
|
|
50
|
+
|
|
51
|
+
var htmlReporter = new jasmine.HtmlReporter();
|
|
52
|
+
|
|
53
|
+
jasmineEnv.addReporter(htmlReporter);
|
|
54
|
+
|
|
55
|
+
jasmineEnv.specFilter = function(spec) {
|
|
56
|
+
return htmlReporter.specFilter(spec);
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
var currentWindowOnload = window.onload;
|
|
60
|
+
|
|
61
|
+
window.onload = function() {
|
|
62
|
+
if (currentWindowOnload) {
|
|
63
|
+
currentWindowOnload();
|
|
64
|
+
}
|
|
65
|
+
execJasmine();
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
function execJasmine() {
|
|
69
|
+
setTimeout(function() {
|
|
70
|
+
jasmineEnv.execute();
|
|
71
|
+
}, 3000);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
})();
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
@import "http://localhost:8081/browser/less/imports/modify-this.css";
|
|
2
|
+
|
|
3
|
+
@import "http://localhost:8081/browser/less/imports/modify-again.css";
|
|
4
|
+
.modify {
|
|
5
|
+
my-url: url("http://localhost:8081/browser/less/imports/a.png");
|
|
6
|
+
}
|
|
7
|
+
.modify {
|
|
8
|
+
my-url: url("http://localhost:8081/browser/less/imports/b.png");
|
|
9
|
+
}
|
|
10
|
+
@font-face {
|
|
11
|
+
src: url("/fonts/garamond-pro.ttf");
|
|
12
|
+
src: local(Futura-Medium), url(http://localhost:8081/browser/less/relative-urls/fonts.svg#MyGeometricModern) format("svg");
|
|
13
|
+
}
|
|
14
|
+
#shorthands {
|
|
15
|
+
background: url("http://www.lesscss.org/spec.html") no-repeat 0 4px;
|
|
16
|
+
}
|
|
17
|
+
#misc {
|
|
18
|
+
background-image: url(http://localhost:8081/browser/less/relative-urls/images/image.jpg);
|
|
19
|
+
}
|
|
20
|
+
#data-uri {
|
|
21
|
+
background: url(data:image/png;charset=utf-8;base64,
|
|
22
|
+
kiVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAD/
|
|
23
|
+
k//+l2Z/dAAAAM0lEQVR4nGP4/5/h/1+G/58ZDrAz3D/McH8yw83NDDeNGe4U
|
|
24
|
+
kg9C9zwz3gVLMDA/A6P9/AFGGFyjOXZtQAAAAAElFTkSuQmCC);
|
|
25
|
+
background-image: url(data:image/x-png,f9difSSFIIGFIFJD1f982FSDKAA9==);
|
|
26
|
+
background-image: url(http://fonts.googleapis.com/css?family=\"Rokkitt\":\(400\),700);
|
|
27
|
+
}
|
|
28
|
+
#svg-data-uri {
|
|
29
|
+
background: transparent url('data:image/svg+xml, <svg version="1.1"><g></g></svg>');
|
|
30
|
+
}
|
|
31
|
+
.comma-delimited {
|
|
32
|
+
background: url(http://localhost:8081/browser/less/relative-urls/bg.jpg) no-repeat, url(http://localhost:8081/browser/less/relative-urls/bg.png) repeat-x top left, url(http://localhost:8081/browser/less/relative-urls/bg);
|
|
33
|
+
}
|
|
34
|
+
.values {
|
|
35
|
+
url: url('http://localhost:8081/browser/less/relative-urls/Trebuchet');
|
|
36
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
@import "https://www.github.com/modify-this.css";
|
|
2
|
+
|
|
3
|
+
@import "https://www.github.com/modify-again.css";
|
|
4
|
+
.modify {
|
|
5
|
+
my-url: url("https://www.github.com/a.png");
|
|
6
|
+
}
|
|
7
|
+
.modify {
|
|
8
|
+
my-url: url("https://www.github.com/b.png");
|
|
9
|
+
}
|
|
10
|
+
@font-face {
|
|
11
|
+
src: url("/fonts/garamond-pro.ttf");
|
|
12
|
+
src: local(Futura-Medium), url(https://www.github.com/fonts.svg#MyGeometricModern) format("svg");
|
|
13
|
+
}
|
|
14
|
+
#shorthands {
|
|
15
|
+
background: url("http://www.lesscss.org/spec.html") no-repeat 0 4px;
|
|
16
|
+
}
|
|
17
|
+
#misc {
|
|
18
|
+
background-image: url(https://www.github.com/images/image.jpg);
|
|
19
|
+
}
|
|
20
|
+
#data-uri {
|
|
21
|
+
background: url(data:image/png;charset=utf-8;base64,
|
|
22
|
+
kiVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAD/
|
|
23
|
+
k//+l2Z/dAAAAM0lEQVR4nGP4/5/h/1+G/58ZDrAz3D/McH8yw83NDDeNGe4U
|
|
24
|
+
kg9C9zwz3gVLMDA/A6P9/AFGGFyjOXZtQAAAAAElFTkSuQmCC);
|
|
25
|
+
background-image: url(data:image/x-png,f9difSSFIIGFIFJD1f982FSDKAA9==);
|
|
26
|
+
background-image: url(http://fonts.googleapis.com/css?family=\"Rokkitt\":\(400\),700);
|
|
27
|
+
}
|
|
28
|
+
#svg-data-uri {
|
|
29
|
+
background: transparent url('data:image/svg+xml, <svg version="1.1"><g></g></svg>');
|
|
30
|
+
}
|
|
31
|
+
.comma-delimited {
|
|
32
|
+
background: url(https://www.github.com/bg.jpg) no-repeat, url(https://www.github.com/bg.png) repeat-x top left, url(https://www.github.com/bg);
|
|
33
|
+
}
|
|
34
|
+
.values {
|
|
35
|
+
url: url('https://www.github.com/Trebuchet');
|
|
36
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
@import "https://www.github.com/cloudhead/imports/modify-this.css";
|
|
2
|
+
|
|
3
|
+
@import "https://www.github.com/cloudhead/imports/modify-again.css";
|
|
4
|
+
.modify {
|
|
5
|
+
my-url: url("https://www.github.com/cloudhead/imports/a.png");
|
|
6
|
+
}
|
|
7
|
+
.modify {
|
|
8
|
+
my-url: url("https://www.github.com/cloudhead/imports/b.png");
|
|
9
|
+
}
|
|
10
|
+
@font-face {
|
|
11
|
+
src: url("/fonts/garamond-pro.ttf");
|
|
12
|
+
src: local(Futura-Medium), url(https://www.github.com/cloudhead/less.js/fonts.svg#MyGeometricModern) format("svg");
|
|
13
|
+
}
|
|
14
|
+
#shorthands {
|
|
15
|
+
background: url("http://www.lesscss.org/spec.html") no-repeat 0 4px;
|
|
16
|
+
}
|
|
17
|
+
#misc {
|
|
18
|
+
background-image: url(https://www.github.com/cloudhead/less.js/images/image.jpg);
|
|
19
|
+
}
|
|
20
|
+
#data-uri {
|
|
21
|
+
background: url(data:image/png;charset=utf-8;base64,
|
|
22
|
+
kiVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAD/
|
|
23
|
+
k//+l2Z/dAAAAM0lEQVR4nGP4/5/h/1+G/58ZDrAz3D/McH8yw83NDDeNGe4U
|
|
24
|
+
kg9C9zwz3gVLMDA/A6P9/AFGGFyjOXZtQAAAAAElFTkSuQmCC);
|
|
25
|
+
background-image: url(data:image/x-png,f9difSSFIIGFIFJD1f982FSDKAA9==);
|
|
26
|
+
background-image: url(http://fonts.googleapis.com/css?family=\"Rokkitt\":\(400\),700);
|
|
27
|
+
}
|
|
28
|
+
#svg-data-uri {
|
|
29
|
+
background: transparent url('data:image/svg+xml, <svg version="1.1"><g></g></svg>');
|
|
30
|
+
}
|
|
31
|
+
.comma-delimited {
|
|
32
|
+
background: url(https://www.github.com/cloudhead/less.js/bg.jpg) no-repeat, url(https://www.github.com/cloudhead/less.js/bg.png) repeat-x top left, url(https://www.github.com/cloudhead/less.js/bg);
|
|
33
|
+
}
|
|
34
|
+
.values {
|
|
35
|
+
url: url('https://www.github.com/cloudhead/less.js/Trebuchet');
|
|
36
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
@import "http://localhost:8081/browser/less/modify-this.css";
|
|
2
|
+
|
|
3
|
+
@import "http://localhost:8081/browser/less/modify-again.css";
|
|
4
|
+
.modify {
|
|
5
|
+
my-url: url("http://localhost:8081/browser/less/a.png");
|
|
6
|
+
}
|
|
7
|
+
.modify {
|
|
8
|
+
my-url: url("http://localhost:8081/browser/less/b.png");
|
|
9
|
+
}
|
|
10
|
+
@font-face {
|
|
11
|
+
src: url("/fonts/garamond-pro.ttf");
|
|
12
|
+
src: local(Futura-Medium), url(http://localhost:8081/browser/less/fonts.svg#MyGeometricModern) format("svg");
|
|
13
|
+
}
|
|
14
|
+
#shorthands {
|
|
15
|
+
background: url("http://www.lesscss.org/spec.html") no-repeat 0 4px;
|
|
16
|
+
}
|
|
17
|
+
#misc {
|
|
18
|
+
background-image: url(http://localhost:8081/browser/less/images/image.jpg);
|
|
19
|
+
}
|
|
20
|
+
#data-uri {
|
|
21
|
+
background: url(data:image/png;charset=utf-8;base64,
|
|
22
|
+
kiVBORw0KGgoAAAANSUhEUgAAABAAAAAQAQMAAAAlPW0iAAAABlBMVEUAAAD/
|
|
23
|
+
k//+l2Z/dAAAAM0lEQVR4nGP4/5/h/1+G/58ZDrAz3D/McH8yw83NDDeNGe4U
|
|
24
|
+
kg9C9zwz3gVLMDA/A6P9/AFGGFyjOXZtQAAAAAElFTkSuQmCC);
|
|
25
|
+
background-image: url(data:image/x-png,f9difSSFIIGFIFJD1f982FSDKAA9==);
|
|
26
|
+
background-image: url(http://fonts.googleapis.com/css?family=\"Rokkitt\":\(400\),700);
|
|
27
|
+
}
|
|
28
|
+
#svg-data-uri {
|
|
29
|
+
background: transparent url('data:image/svg+xml, <svg version="1.1"><g></g></svg>');
|
|
30
|
+
}
|
|
31
|
+
.comma-delimited {
|
|
32
|
+
background: url(http://localhost:8081/browser/less/bg.jpg) no-repeat, url(http://localhost:8081/browser/less/bg.png) repeat-x top left, url(http://localhost:8081/browser/less/bg);
|
|
33
|
+
}
|
|
34
|
+
.values {
|
|
35
|
+
url: url('http://localhost:8081/browser/less/Trebuchet');
|
|
36
|
+
}
|