diff --git a/Gruntfile.js b/Gruntfile.js index 0946ae8..132eb5f 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -1,6 +1,6 @@ module.exports = function(grunt){ 'use strict'; - + // banner grunt.log.writeln(""); grunt.log.writeln(" <<<<<<<<<<<<<<<<<<<<<<<<<<<<<>>>>>>>>>>>>>>>>>>>>>>>>>>"); @@ -9,11 +9,11 @@ module.exports = function(grunt){ grunt.log.writeln(""); grunt.log.writeln(" <<<<<<<<<<<<<<<<<<<<<<<<<<<<<>>>>>>>>>>>>>>>>>>>>>>>>>>"); grunt.log.writeln(""); - + // Grunt config grunt.initConfig({ pkg: grunt.file.readJSON('package.json'), - + // less less: { dist: { @@ -29,10 +29,10 @@ module.exports = function(grunt){ }, }, }, - + // image optimization imagemin: { - assets: { + dist: { options: { optimizationLevel: 7 }, @@ -40,13 +40,39 @@ module.exports = function(grunt){ { expand: true, cwd: 'badged/admin/assets/img/', - src: ['**/*.{png,jpg,jpeg,gif,svg}'], + src: ['**/*.{png,jpg,jpeg,gif}'], dest: 'badged/admin/assets/img/' + }, + { + expand: true, + cwd: 'assets/', + src: ['**/*.{png,jpg,jpeg,gif}'], + dest: 'assets/' } ] - }, + } }, + // svg optimization + svgmin: { + dist: { + files: [ + { + expand: true, + cwd: 'badged/admin/assets/img/', + src: ['**/*.svg'], + dest: 'badged/admin/assets/img/' + }, + { + expand: true, + cwd: 'assets/', + src: ['**/*.svg'], + dest: 'assets/' + } + ] + } + }, + // watch watch: { less: { @@ -54,30 +80,31 @@ module.exports = function(grunt){ tasks: ['less'] } } - + }); - + // Load NPM Tasks, smart code stolen from @bluemaex require('fs').readdirSync('node_modules').filter(function (file) { return file && file.indexOf('grunt-') > -1; }).forEach(function (file) { grunt.loadNpmTasks(file); }); - + // Default Task grunt.registerTask('default', [ 'watch' ]); - + // Dev server grunt.registerTask('server', [ 'less', 'watch' ]); - + // Production build grunt.registerTask('build', [ 'imagemin', + 'svgmin', 'less' ]); diff --git a/assets/banner-1544x500.png b/assets/banner-1544x500.png index 8d431b3..0a2fdc8 100644 Binary files a/assets/banner-1544x500.png and b/assets/banner-1544x500.png differ diff --git a/assets/banner-772x250.png b/assets/banner-772x250.png index 484defd..ecc0d86 100644 Binary files a/assets/banner-772x250.png and b/assets/banner-772x250.png differ diff --git a/assets/icon.svg b/assets/icon.svg index 6f5f599..955367d 100644 --- a/assets/icon.svg +++ b/assets/icon.svg @@ -1,18 +1 @@ - - - - - - - - - + \ No newline at end of file diff --git a/assets/screenshot-1.png b/assets/screenshot-1.png index 10455aa..0a107ab 100644 Binary files a/assets/screenshot-1.png and b/assets/screenshot-1.png differ diff --git a/assets/screenshot-2.png b/assets/screenshot-2.png index 02a2052..558fe5d 100644 Binary files a/assets/screenshot-2.png and b/assets/screenshot-2.png differ diff --git a/assets/screenshot-3.png b/assets/screenshot-3.png index c76170e..a0e5b44 100644 Binary files a/assets/screenshot-3.png and b/assets/screenshot-3.png differ diff --git a/badged/admin/assets/img/kremalicious-cloud.svg b/badged/admin/assets/img/kremalicious-cloud.svg index 5838cce..3edf193 100644 --- a/badged/admin/assets/img/kremalicious-cloud.svg +++ b/badged/admin/assets/img/kremalicious-cloud.svg @@ -1,18 +1 @@ - - - - - - - - - - + \ No newline at end of file diff --git a/design/Badged Icon.psd b/design/Badged Icon.psd index 145d039..06574d3 100644 Binary files a/design/Badged Icon.psd and b/design/Badged Icon.psd differ diff --git a/package.json b/package.json index 13fade9..2df65ba 100644 --- a/package.json +++ b/package.json @@ -2,14 +2,15 @@ "name": "Badged", "author": "Matthias Kretschmann ", "description": "iOS Style Notification Badges for WordPress", - "version": "1.0.0", + "version": "1.0.1", "main": "Gruntfile.js", "dependencies": {}, "devDependencies": { "grunt": "~0.4.1", + "grunt-contrib-imagemin": "~0.1.4", "grunt-contrib-less": "~0.6.4", "grunt-contrib-watch": "~0.5.3", - "grunt-contrib-imagemin": "~0.1.4" + "grunt-svgmin": "~1.0.0" }, "repository": { "type": "git",