commit e29b92887303025b74112c5cb0cee334b12a9721 Author: Jeremy Thomas Date: Fri Aug 26 13:50:08 2016 +0200 Init diff --git a/LICENSE b/LICENSE new file mode 100644 index 0000000..c322f1d --- /dev/null +++ b/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright © 2016 Jeremy Thomas + +Permission is hereby granted, free of charge, to any person obtaining a copy of +this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to +use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies +of the Software, and to permit persons to whom the Software is furnished to do +so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/README.md b/README.md new file mode 100644 index 0000000..3e989b2 --- /dev/null +++ b/README.md @@ -0,0 +1,22 @@ +# MiniReset.css + +A tiny modern CSS reset that covers the basics: + +* **resets the font sizes**: so that using semantic markup doesn't affect the styling +* **resets the block margins**: so that the spacing is only applied when you need it +* **preserves the inline margins**: so that buttons and inputs keep their default layout +* **sets the border-box box sizing**: so that borders and paddings don't affect the set dimensions +* **sets responsive media elements**: so that images and embeds scale with the browser width +* **resets tables**: so that tabular data only takes the space it needs + +## Install + +```sh +npm install minireset.css +``` + +Or download/clone the repo. + +## Copyright and license + +Code copyright 2016 Jeremy Thomas. Code released under [the MIT license](https://github.com/jgthms/minireset.css/blob/master/LICENSE). \ No newline at end of file diff --git a/minireset.css b/minireset.css new file mode 100644 index 0000000..8762915 --- /dev/null +++ b/minireset.css @@ -0,0 +1,79 @@ +/* minireset.css v0.0.1 | MIT License | github.com/jgthms/minireset.css */ +html, +body, +p, +ol, +ul, +li, +dl, +dt, +dd, +blockquote, +figure, +fieldset, +legend, +textarea, +pre, +iframe, +hr, +h1, +h2, +h3, +h4, +h5, +h6 { + margin: 0; + padding: 0; +} + +h1, +h2, +h3, +h4, +h5, +h6 { + font-size: 100%; + font-weight: normal; +} + +button, +input, +select, +textarea { + margin: 0; +} + +html { + box-sizing: border-box; +} + +* { + box-sizing: inherit; +} +*:before, *:after { + box-sizing: inherit; +} + +img, +embed, +object, +audio, +video { + height: auto; + max-width: 100%; +} + +iframe { + border: 0; +} + +table { + border-collapse: collapse; + border-spacing: 0; +} + +td, +th { + padding: 0; + text-align: left; +} diff --git a/minireset.min.css b/minireset.min.css new file mode 100644 index 0000000..0914ddc --- /dev/null +++ b/minireset.min.css @@ -0,0 +1 @@ +/* minireset.css v0.0.1 | MIT License | github.com/jgthms/minireset.css */html,body,p,ol,ul,li,dl,dt,dd,blockquote,figure,fieldset,legend,textarea,pre,iframe,hr,h1,h2,h3,h4,h5,h6{margin:0;padding:0}h1,h2,h3,h4,h5,h6{font-size:100%;font-weight:normal}button,input,select,textarea{margin:0}html{box-sizing:border-box}*{box-sizing:inherit}*:before,*:after{box-sizing:inherit}img,embed,object,audio,video{height:auto;max-width:100%}iframe{border:0}table{border-collapse:collapse;border-spacing:0}td,th{padding:0;text-align:left} \ No newline at end of file diff --git a/minireset.sass b/minireset.sass new file mode 100644 index 0000000..a1794f0 --- /dev/null +++ b/minireset.sass @@ -0,0 +1,77 @@ +// minireset.css v0.0.1 | MIT License | github.com/jgthms/minireset.css +// Blocks +html, +body, +p, +ol, +ul, +li, +dl, +dt, +dd, +blockquote, +figure, +fieldset, +legend, +textarea, +pre, +iframe, +hr, +h1, +h2, +h3, +h4, +h5, +h6 + margin: 0 + padding: 0 + +// Headings +h1, +h2, +h3, +h4, +h5, +h6 + font-size: 100% + font-weight: normal + +// Form +button, +input, +select, +textarea + margin: 0 + +// Box sizing +html + box-sizing: border-box + +* + box-sizing: inherit + &:before, + &:after + box-sizing: inherit + +// Media +img, +embed, +object, +audio, +video + height: auto + max-width: 100% + +// Iframe +iframe + border: 0 + +// Table +table + border-collapse: collapse + border-spacing: 0 + +td, +th + padding: 0 + text-align: left diff --git a/package.json b/package.json new file mode 100644 index 0000000..8b874ff --- /dev/null +++ b/package.json @@ -0,0 +1,24 @@ +{ + "name": "minireset.css", + "version": "0.0.1", + "description": "A tiny modern CSS reset", + "main": "minireset.css", + "scripts": { + "test": "echo \"Error: no test specified\" && exit 1" + }, + "repository": { + "type": "git", + "url": "git+https://github.com/jgthms/minireset.css.git" + }, + "keywords": [ + "css", + "reset", + "mini" + ], + "author": "Jeremy Thomas (http://jgthms.com)", + "license": "MIT", + "bugs": { + "url": "https://github.com/jgthms/minireset.css/issues" + }, + "homepage": "https://github.com/jgthms/minireset.css#readme" +}