Commit Graph

13 Commits

Author SHA1 Message Date
jurcovicovam
864c63d27b Fix ordering of @import and @charset rules #1954 #2013
The genCss method of ruleset.js splits child nodes into two groups:
* rules,
* rulesets.

Rules are always printed first and have special handling for last rule.
Rulesets are always printed second. Wrong ordering was caused by the
condition that determined what is rule and what is ruleset.

Issue #2013: The condition made no difference between @charset and @page,
because both are compiled into tree.Directive nodes. I added isRulesetLike
method to the tree.Directive to differentiate between them.

Issue #1954: The condition treated all tree.Anonymous types as rules and
caused them to float up. That is incorrect, because `@import (inline)` is
compiled into tree.Anonymous too, but should be treated as ruleset and
stay where it is.
2014-07-22 14:46:58 +02:00
seven-phases-max
7a1c534e1b Fixes e(""). 2014-05-17 21:29:10 +04:00
Luke Page
07841b3860 Fix issue with unqouted urls in mixins having their context evaluated twice. Fix sourcemap test output 2013-12-18 19:42:32 +00:00
Luke Page
62751c917c support inline css files in the sourcemaps 2013-09-17 19:37:00 +01:00
Luke Page
4db7c883cf start refactoring toCSS so we will be able to collect sourcemap information at the same time 2013-07-11 22:08:38 +01:00
Luke Page
c56db94b7d Add modified (self altering) visitor pattern and class 2013-03-01 13:40:00 +00:00
Luke Page
a702b282e6 Allow comparing colors and strings. Fix a bug whereby sometimes a mixin-call or import would disappear. This makes the import test fail consistently instead of once out of 8 times depending on async order I think. 2012-08-05 22:47:05 +01:00
Alexis Sellier
c290c48b3f node 0.5.x compatibility 2011-11-12 13:13:36 +01:00
cloudhead
4399c9c965 make strings behave like other nodes.
- rename 'content' to 'value'
2010-07-25 16:41:05 -04:00
cloudhead
a72966fa6a removed constructor names 2010-06-19 01:51:26 -04:00
cloudhead
7768d41050 better cross-environment handling. stub out require() in browser. 2010-06-15 18:44:59 -04:00
cloudhead
a4d4d55693 Evaluate function calls properly.
- `fun(f())` is now possible
- Anonymous can take normal strings
- Tests for `%()`
2010-04-30 14:07:05 -04:00
cloudhead
904d997730 the e() LESS function
used to escape strings in values.
Added Anonymous node to handle things like this.
2010-04-22 19:42:02 -04:00