postcss-nesting
Advanced tools
Comparing version 2.0.1 to 2.0.2
@@ -0,1 +1,5 @@ | ||
## 2.0.2 (2015-09-16) | ||
- Fixed: Issue where the new rule’s children were not mapped to the parent internally | ||
## 2.0.1 (2015-09-16) | ||
@@ -2,0 +6,0 @@ |
13
index.js
@@ -5,2 +5,11 @@ var bubble = ['document', 'media', 'supports']; | ||
function normalizeNodes(node) { | ||
var index = -1; | ||
var child; | ||
while (child = node.nodes[++index]) { | ||
child.parent = node; | ||
} | ||
} | ||
function transpileSelectors(fromRule, toRule) { | ||
@@ -36,2 +45,4 @@ var selectors = []; | ||
normalizeNodes(toRule); | ||
parent.nodes.splice(++parent.nestedIndex, 0, toRule); | ||
@@ -53,2 +64,4 @@ } | ||
normalizeNodes(toRule); | ||
atRule.nodes = [toRule]; | ||
@@ -55,0 +68,0 @@ atRule.parent = parent; |
{ | ||
"name": "postcss-nesting", | ||
"version": "2.0.1", | ||
"version": "2.0.2", | ||
"description": "Transpiles nested rules according to CSS Nesting Module Level 3", | ||
@@ -5,0 +5,0 @@ "keywords": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
14492
87