Comparing version 0.9.2 to 0.10.0
{ | ||
"name": "rework", | ||
"version": "0.9.2", | ||
"version": "0.10.0", | ||
"description": "CSS manipulations built on CSSOM", | ||
@@ -8,2 +8,3 @@ "keywords": ["css", "manipulation", "preprocess", "transform"], | ||
"visionmedia/css": "1.0.7", | ||
"visionmedia/debug": "*", | ||
"component/path": "*" | ||
@@ -26,2 +27,2 @@ }, | ||
] | ||
} | ||
} |
0.10.0 2012-12-10 | ||
================== | ||
* add .mixin -> .mixins alias | ||
* add debug to component.json | ||
* add `extends` support | ||
0.9.2 / 2012-12-05 | ||
@@ -3,0 +10,0 @@ ================== |
@@ -13,2 +13,3 @@ | ||
module.exports = function(mixins) { | ||
if (!mixins) throw new Error('mixins object required'); | ||
return function(style, rework){ | ||
@@ -15,0 +16,0 @@ style.rules.forEach(function(rule){ |
@@ -82,5 +82,6 @@ | ||
exports.media = require('./plugins/media'); | ||
exports.mixin = require('./plugins/mixin'); | ||
exports.mixin = exports.mixins = require('./plugins/mixin'); | ||
exports.prefix = require('./plugins/prefix'); | ||
exports.colors = require('./plugins/colors'); | ||
exports.extend = require('./plugins/extend'); | ||
exports.references = require('./plugins/references'); | ||
@@ -87,0 +88,0 @@ exports.prefixValue = require('./plugins/prefix-value'); |
{ | ||
"name": "rework", | ||
"version": "0.9.2", | ||
"version": "0.10.0", | ||
"description": "CSS manipulations built on CSSOM", | ||
@@ -13,3 +13,4 @@ "keywords": ["css", "manipulation", "preprocess", "transform"], | ||
"commander": "1.0.4", | ||
"color-parser": "0.0.1" | ||
"color-parser": "0.0.1", | ||
"debug": "*" | ||
}, | ||
@@ -16,0 +17,0 @@ "devDependencies": { |
@@ -85,3 +85,54 @@ # rework | ||
- [mixin](#mixinobjects) — add custom property logic with mixing | ||
- [extend](#extend) — add `extend: selector` support | ||
### .extend() | ||
Add support for extending existing rulesets: | ||
```css | ||
button { | ||
padding: 5px 10px; | ||
border: 1px solid #eee; | ||
border-bottom-color: #ddd; | ||
} | ||
.green { | ||
background: green; | ||
padding: 10px 15px | ||
} | ||
a.join { | ||
extend: button; | ||
extend: .green; | ||
} | ||
a.button | ||
input[type='submit'], | ||
input[type='button'] { | ||
extend: button | ||
} | ||
``` | ||
yields: | ||
```css | ||
button, | ||
a.button, | ||
input[type='submit'], | ||
input[type='button'], | ||
a.join { | ||
padding: 5px 10px; | ||
border: 1px solid #eee; | ||
border-bottom-color: #ddd; | ||
} | ||
.green, | ||
a.join { | ||
background: green; | ||
padding: 10px 15px | ||
} | ||
``` | ||
### .media(obj) | ||
@@ -167,4 +218,6 @@ | ||
```css | ||
logo { | ||
background-image: url('/public/images/logo.png') | ||
.logo { | ||
background-image: url('component.png'); | ||
width: 289px; | ||
height: 113px | ||
} | ||
@@ -176,4 +229,6 @@ ``` | ||
```css | ||
logo { | ||
background-image: url('/public/images/logo.png') | ||
.logo { | ||
background-image: url('component.png'); | ||
width: 289px; | ||
height: 113px | ||
} | ||
@@ -183,3 +238,4 @@ | ||
.logo { | ||
background-image: url("/public/images/logo@2x.png") | ||
background-image: url("component@2x.png"); | ||
background-size: contain | ||
} | ||
@@ -186,0 +242,0 @@ } |
Wildcard dependency
QualityPackage has a dependency with a floating version range. This can cause issues if the dependency publishes a new major version.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
38776
26
816
748
4
1
2
+ Addeddebug@*
+ Addeddebug@4.3.7(transitive)
+ Addedms@2.1.3(transitive)