From aa6a3320f58aa3b080fe2ccc2cd91b9e1228e5d2 Mon Sep 17 00:00:00 2001 From: hugogogo Date: Fri, 26 Feb 2021 11:39:18 +0100 Subject: [PATCH] ajout de quelques regles generales de css, encore messy --- styles/global.css | 39 +++++++++++++++++++++++++++++++++++++++ styles/reset.css | 6 ++++++ styles/style.css | 28 +++++----------------------- styles/text.css | 29 ++++++++++++++++++++++------- 4 files changed, 72 insertions(+), 30 deletions(-) create mode 100644 styles/global.css diff --git a/styles/global.css b/styles/global.css new file mode 100644 index 0000000..f08237b --- /dev/null +++ b/styles/global.css @@ -0,0 +1,39 @@ +/*/////////////////////////////////////////////*/ +/*GLOBAL VARIABLE*/ +:root { +} + +/*elements are flex, vertical, and to the left, by default*/ +body *:not(script) { + display: flex; + flex-direction: column; + margin: 20px 0px; +} +/*default*/ +.vertical { + display: flex; + flex-direction: column; +} +.vertical > * { + margin: 20px 0px; +} +.left > * { + margin-left: 0px; +} +/*special*/ +.horizontal { + flex-direction: row; +} +.horizontal > * { + margin: 0px 20px; +} +.right { + margin-right: 0px; + margin-left: auto; + text-align: right; +} +.center { + margin: auto; + text-align: center; +} + diff --git a/styles/reset.css b/styles/reset.css index 71f4d70..48bc571 100644 --- a/styles/reset.css +++ b/styles/reset.css @@ -1,9 +1,15 @@ /*/////////////////////////////////////////////*/ /*RESET*/ +/* body *:not(script) { display: block; } +*/ +body *:not(script) { + display: flex; + flex-direction: column; +} html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, diff --git a/styles/style.css b/styles/style.css index 943a0c5..5ef3790 100644 --- a/styles/style.css +++ b/styles/style.css @@ -2,11 +2,12 @@ /*/////////////////////////////////////////////*/ /*IMPORT CSS*/ @import url(./reset.css); +@import url(./global.css); @import url(./fonts.css); +@import url(./text.css); @import url(./header.css); @import url(./footer.css); @import url(./images.css); -@import url(./text.css); @@ -31,36 +32,17 @@ } - - /*/////////////////////////////////////////////*/ -/*GENERAL SETTINGS*/ +/*INITIAL SETTINGS*/ html { scroll-behavior: smooth; + font-size: 10px; } +/*to keep a blank space between the content and the edges of the page*/ body { - display: flex; - flex-direction: column; - margin: 0px; padding: var(--screen-gap); width: calc(100% - 2 * var(screen-gap)); } main { min-height: calc(100vh - 70px); } -.horizontal { - display: flex; - flex-direction: row; -} -.horizontal > * { - margin: 20px; -} -.vertical { - display: flex; - flex-direction: column; -} -.vertical > * { - margin: 20px 0px; -} - - diff --git a/styles/text.css b/styles/text.css index 3d12f6d..4920ade 100644 --- a/styles/text.css +++ b/styles/text.css @@ -40,22 +40,37 @@ a:active { p, var { color: var(--color-texts); } +/*sizes*/ +p { + font-size: 1.8rem; + line-height: 3rem; +} +h1 { + font-size: 2.5rem; +} +h2 { + font-size: 2rem; +} +.mini_text { + font-size: 1.5rem; +} /*specials settings*/ +body p, body p *, body h1, body h1 *, body h2, body h2 * { + display: inline; +} a, a > * { cursor: pointer; } -li *, li p, article b, article em, -article i, article a, article var { +li *, li p, b, em, i, a, var, span { display: inline; } i { font-style: italic; } -b { +b, em { font-weight: 600; - color: var(--article-medium); } -em { - font-weight: 600; - color: var(--article-em); +p br, h1 br, h2 br { + margin: 0px; } +