Skip to content

Commit

Permalink
Sprite sheet and CSS generation
Browse files Browse the repository at this point in the history
  • Loading branch information
James Allardice committed Jul 5, 2013
1 parent 6603298 commit d8538e9
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 2 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
node_modules
.DS_Store
.DS_Store
dist
23 changes: 23 additions & 0 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,32 @@ module.exports = function (grunt) {
]
}
}
},
spritesheet: {
compile: {
options: {
outputCss: "emoji.css",
selector: ".emoji",
downsampling: "LanczosSharp",
output: {
"normal": {
pixelRatio: 1,
outputImage: "emoji.png"
},
"64": {
pixelRatio: 2,
outputImage: "[email protected]"
}
}
},
files: {
dist: "res/emoji/*.png"
}
}
}
});

grunt.loadNpmTasks("grunt-contrib-jshint");
grunt.loadNpmTasks("node-spritesheet");

};
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
"private": true,
"devDependencies": {
"grunt": "0.4.x",
"grunt-contrib-jshint": "0.6.x"
"grunt-contrib-jshint": "0.6.x",
"node-spritesheet": "0.4.x"
}
}

0 comments on commit d8538e9

Please sign in to comment.