From d392cc63f7e4d63a999db1fd551709452bfbe8b4 Mon Sep 17 00:00:00 2001 From: Martin Kagamino Lehoux Date: Thu, 29 Jan 2026 07:54:19 +0100 Subject: CSS reset --- README.md | 1 + assets/css/reset.css | 145 ++++++++++++++++++++++++++++++++++++++ layouts/partials/head/styles.html | 6 +- 3 files changed, 150 insertions(+), 2 deletions(-) create mode 100644 assets/css/reset.css diff --git a/README.md b/README.md index d62bb6e..e5bf6e6 100644 --- a/README.md +++ b/README.md @@ -12,6 +12,7 @@ - [ ] Table of content: `tableOfContents: true` - [ ] Unified CSS reset - [ ] Use minify in production? +- [ ] Multi parts series ## Guidelines diff --git a/assets/css/reset.css b/assets/css/reset.css new file mode 100644 index 0000000..6b39b0e --- /dev/null +++ b/assets/css/reset.css @@ -0,0 +1,145 @@ +/* http://meyerweb.com/eric/tools/css/reset/ + v2.0 | 20110126 + License: none (public domain) +*/ + +html, +body, +div, +span, +applet, +object, +iframe, +h1, +h2, +h3, +h4, +h5, +h6, +p, +blockquote, +pre, +a, +abbr, +acronym, +address, +big, +cite, +code, +del, +dfn, +em, +img, +ins, +kbd, +q, +s, +samp, +small, +strike, +strong, +sub, +sup, +tt, +var, +b, +u, +i, +center, +dl, +dt, +dd, +ol, +ul, +li, +fieldset, +form, +label, +legend, +table, +caption, +tbody, +tfoot, +thead, +tr, +th, +td, +article, +aside, +canvas, +details, +embed, +figure, +figcaption, +footer, +header, +hgroup, +menu, +nav, +output, +ruby, +section, +summary, +time, +mark, +audio, +video { + margin: 0; + padding: 0; + border: 0; + font-size: 100%; + font: inherit; + vertical-align: baseline; + box-sizing: border-box; + +} + +/* HTML5 display-role reset for older browsers */ +article, +aside, +details, +figcaption, +figure, +footer, +header, +hgroup, +menu, +nav, +section { + display: block; +} + +body { + line-height: 1; +} + +ol, +ul { + list-style: none; +} + +blockquote, +q { + quotes: none; +} + +blockquote:before, +blockquote:after, +q:before, +q:after { + content: ''; + content: none; +} + +table { + border-collapse: collapse; + border-spacing: 0; +} + +:link { + text-decoration: inherit; +} + +:visited { + color: inherit; +} \ No newline at end of file diff --git a/layouts/partials/head/styles.html b/layouts/partials/head/styles.html index 03f336b..6f6c5b0 100644 --- a/layouts/partials/head/styles.html +++ b/layouts/partials/head/styles.html @@ -1,5 +1,7 @@ {{/* Resources */}} -{{- $styles := resources.Get "css/main.css" -}} +{{- $reset := resources.Get "css/reset.css" -}} +{{- $main := resources.Get "css/main.css" -}} +{{- $styles := slice $reset $main | resources.Concat "css/bundle.css" -}} {{/* MathJax */}} @@ -13,6 +15,6 @@ document.addEventListener('DOMContentLoaded', function () { {{- if eq hugo.Environment "development" -}} {{- else -}} - {{- $styles := $styles | minify | fingerprint | resources.PostProcess -}} + {{- $styles := $styles | minify | fingerprint -}} {{- end -}} -- cgit v1.3