mirror of
https://github.com/less/less.js.git
synced 2026-01-23 06:07:56 -05:00
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.
3 lines
213 B
Plaintext
3 lines
213 B
Plaintext
@import url("import/import-test-c.less");// import inline should not float above this #1954
|
|
@import (inline) url("import/import-test-d.css") (min-width:600px);
|
|
@import (inline, css) url("import/invalid-css.less"); |