diff --git a/Gruntfile.js b/Gruntfile.js index 21a378f6b..85f1b1bee 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -6,19 +6,6 @@ grunt.initConfig({ nick : 'pure', pkg : grunt.file.readJSON('package.json'), - bower: grunt.file.readJSON('bower.json'), - - // -- bower.json Config --------------------------------------------------------- - - bower_json: { - release: { - values: { - main: 'pure.css' - }, - - dest: 'build/' - } - }, // -- Clean Config --------------------------------------------------------- @@ -50,7 +37,7 @@ grunt.initConfig({ build: { files: [ {'build/base.css': [ - 'bower_components/normalize-css/normalize.css', + 'node_modules/normalize.css/normalize.css', 'build/base.css' ]}, @@ -104,6 +91,19 @@ grunt.initConfig({ } }, + // -- PostCSS Config -------------------------------------------------------- + + postcss: { + options: { + processors: [ + require('autoprefixer')({browsers: ['last 2 versions', 'ie >= 8', 'iOS >= 6', 'Android >= 4']}) + ] + }, + dist: { + src: 'build/*.css' + } + }, + // -- CSSLint Config ------------------------------------------------------- csslint: { @@ -155,7 +155,7 @@ grunt.initConfig({ options: { banner: [ '/*!', - 'normalize.css v<%= bower.devDependencies["normalize-css"] %> | MIT License | git.io/normalize', + 'normalize.css | MIT License | git.io/normalize', 'Copyright (c) Nicolas Gallagher and Jonathan Neal', '*/\n' ].join('\n') @@ -258,14 +258,14 @@ grunt.loadNpmTasks('grunt-contrib-cssmin'); grunt.loadNpmTasks('grunt-contrib-compress'); grunt.loadNpmTasks('grunt-contrib-watch'); grunt.loadNpmTasks('grunt-css-selectors'); +grunt.loadNpmTasks('grunt-postcss'); grunt.loadNpmTasks('grunt-pure-grids'); grunt.loadNpmTasks('grunt-stripmq'); // Local tasks. grunt.loadTasks('tasks/'); -grunt.registerTask('default', ['import', 'test', 'build']); -grunt.registerTask('import', ['bower_install']); +grunt.registerTask('default', ['test', 'build']); grunt.registerTask('test', ['csslint']); grunt.registerTask('build', [ 'clean:build', @@ -275,6 +275,7 @@ grunt.registerTask('build', [ 'concat:build', 'clean:build_res', 'css_selectors:base', + 'postcss', 'cssmin', 'license' ]); @@ -287,7 +288,6 @@ grunt.registerTask('release', [ 'default', 'clean:release', 'copy:release', - 'bower_json:release', 'compress:release' ]); diff --git a/bower.json b/bower.json deleted file mode 100644 index f4bc6832b..000000000 --- a/bower.json +++ /dev/null @@ -1,8 +0,0 @@ -{ - "name": "pure", - "description": "Use Pure's ridiculously tiny CSS to start any web project.", - "main": "build/pure.css", - "devDependencies": { - "normalize-css": "^3.0" - } -} diff --git a/node_modules b/node_modules new file mode 120000 index 000000000..68a084add --- /dev/null +++ b/node_modules @@ -0,0 +1 @@ +../node_modules \ No newline at end of file diff --git a/package.json b/package.json index 29e9549ae..4583ce10a 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "purecss", - "version": "0.6.1-pre", + "version": "0.6.1", "repository": { "type": "git", "url": "git://github.com/yahoo/pure.git" @@ -11,7 +11,7 @@ }, "files": "build/", "devDependencies": { - "bower": "^1.3.7", + "autoprefixer": "^6.3.1", "grunt": "^0.4.5", "grunt-cli": "^0.1.13", "grunt-contrib-clean": "^0.5.0", @@ -22,8 +22,10 @@ "grunt-contrib-cssmin": "^0.6.2", "grunt-contrib-watch": "^0.6.1", "grunt-css-selectors": "^1.1.0", + "grunt-postcss": "^0.7.1", "grunt-pure-grids": "^1.0.0", - "grunt-stripmq": "0.0.6" + "grunt-stripmq": "0.0.6", + "normalize.css": "^4.0" }, "description": "Pure is a ridiculously tiny CSS library you can use to start any web project.", "bugs": { @@ -41,7 +43,9 @@ "ericf ", "tilomitra ", "msweeney ", - "jamesalley " + "jamesalley ", + "lkraav ", + "absalomedia ", ], "license": "BSD" } diff --git a/src/buttons/css/buttons-core.css b/src/buttons/css/buttons-core.css index f007c91b5..5ce5b0e5e 100644 --- a/src/buttons/css/buttons-core.css +++ b/src/buttons/css/buttons-core.css @@ -1,19 +1,13 @@ .pure-button { /* Structure */ display: inline-block; - zoom: 1; line-height: normal; white-space: nowrap; vertical-align: middle; text-align: center; cursor: pointer; -webkit-user-drag: none; - -webkit-user-select: none; - -moz-user-select: none; - -ms-user-select: none; user-select: none; - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; box-sizing: border-box; } diff --git a/src/buttons/css/buttons.css b/src/buttons/css/buttons.css index 92ed95238..4218df71d 100644 --- a/src/buttons/css/buttons.css +++ b/src/buttons/css/buttons.css @@ -16,12 +16,10 @@ .pure-button-hover, .pure-button:hover, .pure-button:focus { - filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#1a000000',GradientType=0); - background-image: -webkit-gradient(linear, 0 0, 0 100%, from(transparent), color-stop(40%, rgba(0,0,0, 0.05)), to(rgba(0,0,0, 0.10))); - background-image: -webkit-linear-gradient(transparent, rgba(0,0,0, 0.05) 40%, rgba(0,0,0, 0.10)); - background-image: -moz-linear-gradient(top, rgba(0,0,0, 0.05) 0%, rgba(0,0,0, 0.10)); - background-image: -o-linear-gradient(transparent, rgba(0,0,0, 0.05) 40%, rgba(0,0,0, 0.10)); - background-image: linear-gradient(transparent, rgba(0,0,0, 0.05) 40%, rgba(0,0,0, 0.10)); + filter: alpha(opacity=90); + -khtml-opacity: 0.90; + -moz-opacity: 0.90; + opacity: 0.90; } .pure-button:focus { outline: 0; @@ -29,7 +27,7 @@ .pure-button-active, .pure-button:active { box-shadow: 0 0 0 1px rgba(0,0,0, 0.15) inset, 0 0 6px rgba(0,0,0, 0.20) inset; - border-color: #000\9; + border-color: #000; } .pure-button[disabled], @@ -39,13 +37,13 @@ .pure-button-disabled:active { border: none; background-image: none; - filter: progid:DXImageTransform.Microsoft.gradient(enabled = false); filter: alpha(opacity=40); -khtml-opacity: 0.40; -moz-opacity: 0.40; opacity: 0.40; cursor: not-allowed; box-shadow: none; + pointer-events: none; } .pure-button-hidden { diff --git a/src/forms/css/forms.css b/src/forms/css/forms.css index 370d35033..83d7bf280 100644 --- a/src/forms/css/forms.css +++ b/src/forms/css/forms.css @@ -28,8 +28,6 @@ so we can ignore the csslint warning. box-shadow: inset 0 1px 3px #ddd; border-radius: 4px; vertical-align: middle; - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; box-sizing: border-box; } @@ -43,8 +41,6 @@ since IE8 won't execute CSS that contains a CSS3 selector. border: 1px solid #ccc; box-shadow: inset 0 1px 3px #ddd; border-radius: 4px; - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; box-sizing: border-box; } @@ -209,8 +205,6 @@ since IE8 won't execute CSS that contains a CSS3 selector. .pure-form-aligned .pure-help-inline, .pure-form-message-inline { display: inline-block; - *display: inline; - *zoom: 1; vertical-align: middle; } .pure-form-aligned textarea { diff --git a/src/grids/css/grids-core.css b/src/grids/css/grids-core.css index 10294237e..dd0c961ab 100644 --- a/src/grids/css/grids-core.css +++ b/src/grids/css/grids-core.css @@ -2,9 +2,6 @@ .pure-g { letter-spacing: -0.31em; /* Webkit: collapse white-space between units */ - *letter-spacing: normal; /* reset IE < 8 */ - *word-spacing: -0.43em; /* IE < 8: collapse white-space between units */ - text-rendering: optimizespeed; /* Webkit: fixes text-rendering: optimizeLegibility */ /* Sets the font stack to fonts known to work properly with the above letter @@ -24,26 +21,22 @@ */ font-family: FreeSans, Arimo, "Droid Sans", Helvetica, Arial, sans-serif; - /* - Use flexbox when possible to avoid `letter-spacing` side-effects. - - NOTE: Firefox (as of 25) does not currently support flex-wrap, so the - `-moz-` prefix version is omitted. - */ - - display: -webkit-flex; - -webkit-flex-flow: row wrap; + /* Use flexbox when possible to avoid `letter-spacing` side-effects. */ + display: flex; + flex-flow: row wrap; - /* IE10 uses display: flexbox */ - display: -ms-flexbox; - -ms-flex-flow: row wrap; - /* Prevents distributing space between rows */ - -ms-align-content: flex-start; - -webkit-align-content: flex-start; - align-content: flex-start; + align-content: flex-start; } +/* IE10 display: -ms-flexbox (and display: flex in IE 11) does not work inside a table; fall back to block and rely on font hack */ +@media all and (-ms-high-contrast: none), (-ms-high-contrast: active) { + table .pure-g { + display: block; + } +} + + /* Opera as of 12 on Windows needs word-spacing. The ".opera-only" selector is used to prevent actual prefocus styling and is not required in markup. @@ -55,12 +48,9 @@ .pure-u { display: inline-block; - *display: inline; /* IE < 8: fake inline-block */ - zoom: 1; letter-spacing: normal; word-spacing: normal; - vertical-align: top; - text-rendering: auto; + vertical-align: bottom; } /* diff --git a/src/menus/css/menus-core.css b/src/menus/css/menus-core.css index bfdc418c5..0ba775495 100644 --- a/src/menus/css/menus-core.css +++ b/src/menus/css/menus-core.css @@ -1,7 +1,5 @@ /*csslint adjoining-classes: false, box-model:false*/ .pure-menu { - -webkit-box-sizing: border-box; - -moz-box-sizing: border-box; box-sizing: border-box; } diff --git a/src/menus/css/menus-horizontal.css b/src/menus/css/menus-horizontal.css index de37fbf35..1bc755da8 100644 --- a/src/menus/css/menus-horizontal.css +++ b/src/menus/css/menus-horizontal.css @@ -13,7 +13,5 @@ .pure-menu-horizontal .pure-menu-heading, .pure-menu-horizontal .pure-menu-separator { display: inline-block; - *display: inline; - zoom: 1; vertical-align: middle; } diff --git a/src/tables/css/tables.css b/src/tables/css/tables.css index fdd0e7898..e1a5627b5 100644 --- a/src/tables/css/tables.css +++ b/src/tables/css/tables.css @@ -30,7 +30,7 @@ there's a rowspan on the first cell. Case added to the tests. issue#432 */ border-left-width: 0; } -.pure-table thead { +.pure-table thead, .pure-table tfoot { background-color: #e0e0e0; color: #000; text-align: left;