Skip to content

Commit

Permalink
Merge pull request #2 from TrySound/master
Browse files Browse the repository at this point in the history
Refactoring for more clear code
  • Loading branch information
markgoodyear committed Jun 24, 2015
2 parents a585e64 + 830945e commit f97cd50
Showing 1 changed file with 4 additions and 6 deletions.
10 changes: 4 additions & 6 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,10 @@ var postcss = require('postcss');
module.exports = postcss.plugin('postcss-pointer', function () {

return function (css) {
css.eachDecl(function transformDecl (decl) {
if (decl.prop === 'pointer') {
if (decl.value.indexOf('cursor') !== -1) {
decl.prop = 'cursor';
decl.value = 'pointer';
}
css.eachDecl('pointer', function (decl) {
if (decl.value.indexOf('cursor') !== -1) {
decl.prop = 'cursor';
decl.value = 'pointer';
}
});
};
Expand Down

0 comments on commit f97cd50

Please sign in to comment.