Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

postcss-merge-rules

Package Overview
Dependencies
Maintainers
2
Versions
78
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

postcss-merge-rules - npm Package Compare versions

Comparing version 1.3.6 to 2.0.0

4

CHANGELOG.md

@@ -0,1 +1,5 @@

# 2.0.0
* Upgraded to PostCSS 5.
# 1.3.6

@@ -2,0 +6,0 @@

25

dist/index.js

@@ -102,4 +102,3 @@ 'use strict';

selector: joinSelectors(first, second),
nodes: [],
before: ''
nodes: []
});

@@ -121,8 +120,8 @@ var difference = different(getDecls(first), getDecls(second));

};
firstClone.eachDecl(moveDecl(function (decl) {
decl.removeSelf();
firstClone.walkDecls(moveDecl(function (decl) {
decl.remove();
recievingBlock.append(decl);
}));
secondClone.eachDecl(moveDecl(function (decl) {
return decl.removeSelf();
secondClone.walkDecls(moveDecl(function (decl) {
return decl.remove();
}));

@@ -136,3 +135,3 @@ var merged = ruleLength(firstClone, recievingBlock, secondClone);

if (!r.nodes.length) {
r.removeSelf();
r.remove();
}

@@ -145,3 +144,3 @@ });

} else {
recievingBlock.removeSelf();
recievingBlock.remove();
return second;

@@ -170,3 +169,3 @@ }

rule.selector = joinSelectors(cache, rule);
cache.removeSelf();
cache.remove();
cache = rule;

@@ -179,9 +178,9 @@ return;

var toString = String(cache);
rule.eachInside(function (decl) {
rule.walk(function (decl) {
if (~toString.indexOf(String(decl))) {
return decl.removeSelf();
return decl.remove();
}
decl.moveTo(cache);
});
rule.removeSelf();
rule.remove();
return;

@@ -197,5 +196,5 @@ }

return function (css) {
css.eachRule(selectorMerger());
css.walkRules(selectorMerger());
};
});
module.exports = exports['default'];
{
"name": "postcss-merge-rules",
"version": "1.3.6",
"version": "2.0.0",
"description": "Merge CSS rules with PostCSS.",

@@ -22,6 +22,6 @@ "main": "dist/index.js",

"devDependencies": {
"babel": "^5.8.21",
"babel": "^5.8.23",
"babel-tape-runner": "^1.2.0",
"tap-spec": "^4.0.2",
"tape": "^4.1.0"
"tap-spec": "^4.1.0",
"tape": "^4.2.0"
},

@@ -36,4 +36,4 @@ "homepage": "https://github.com/ben-eb/postcss-merge-rules",

"dependencies": {
"postcss": "^4.1.16"
"postcss": "^5.0.4"
}
}
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc