From eeebf93eb3709ec6195436c7e20deb9e958de548 Mon Sep 17 00:00:00 2001 From: Elisabeth Dickinson Date: Fri, 26 Feb 2021 16:34:58 +0100 Subject: [PATCH] [DESIGN] update font-sizes : now base size is 16px and secondary font size is 14px --- .../odoo_theme/static/scss/_mixins.scss | 2 +- .../odoo_theme/static/scss/_variables.scss | 1 + .../static/scss/bootstrap_overridden.scss | 23 +++++-------------- extensions/odoo_theme/static/style.scss | 7 +++--- 4 files changed, 12 insertions(+), 21 deletions(-) diff --git a/extensions/odoo_theme/static/scss/_mixins.scss b/extensions/odoo_theme/static/scss/_mixins.scss index 918b5e2ac..ec05f79bd 100644 --- a/extensions/odoo_theme/static/scss/_mixins.scss +++ b/extensions/odoo_theme/static/scss/_mixins.scss @@ -112,7 +112,7 @@ @mixin inline-icomoon($icon-content, $margin) { content: '#{$icon-content}'; font-family: '#{$icomoon-font-family}' !important; - font-size: 1.5rem; + @include font-size(1.5rem); font-weight: $fw_regular; vertical-align: middle; margin: $margin; diff --git a/extensions/odoo_theme/static/scss/_variables.scss b/extensions/odoo_theme/static/scss/_variables.scss index a6b795129..1484789f6 100644 --- a/extensions/odoo_theme/static/scss/_variables.scss +++ b/extensions/odoo_theme/static/scss/_variables.scss @@ -241,6 +241,7 @@ $website-2x-prefix: "2x_"; // Animations and Transitions $o-ease: cubic-bezier(.55,0,.1,1); +$font-size-secondary: .875rem; //------------------------------------------------------------------------------ // icomoon icons //------------------------------------------------------------------------------ diff --git a/extensions/odoo_theme/static/scss/bootstrap_overridden.scss b/extensions/odoo_theme/static/scss/bootstrap_overridden.scss index 6ddb6c608..0f6a79ddb 100644 --- a/extensions/odoo_theme/static/scss/bootstrap_overridden.scss +++ b/extensions/odoo_theme/static/scss/bootstrap_overridden.scss @@ -20,23 +20,12 @@ $border-radius-sm: 1rem / 16 !default; // // Font, line-height, and color for body text, headings, and more. -$font-size-base: 0.875rem; -$line-height-base: 1.45 !default; - - -$h1-font-size: $font-size-base * 2.5 !default; -$h2-font-size: $font-size-base * 2 !default; -$h3-font-size: $font-size-base * 1.75 !default; -$h4-font-size: $font-size-base * 1.5 !default; -$h5-font-size: $font-size-base * 1.25 !default; -$h6-font-size: $font-size-base !default; - -/* $h1-font-size: $font-size-base * (39 / 15) !default; -$h2-font-size: $font-size-base * (32 / 15) !default; -$h3-font-size: $font-size-base * (26 / 15) !default; -$h4-font-size: $font-size-base * (19 / 15) !default; -$h5-font-size: $font-size-base * (15 / 15) !default; -$h6-font-size: $font-size-base * (13 / 15) !default; */ +$h1-font-size: 1.875rem; +$h2-font-size: 1.5rem; +$h3-font-size: 1.125rem; +$h4-font-size: 1rem; +$h5-font-size: 1rem; +$h6-font-size: $font-size-secondary; /* $headings-font-weight: $fw_semibold !default; */ diff --git a/extensions/odoo_theme/static/style.scss b/extensions/odoo_theme/static/style.scss index dacb370f0..9ce963c19 100644 --- a/extensions/odoo_theme/static/style.scss +++ b/extensions/odoo_theme/static/style.scss @@ -11,7 +11,6 @@ div[aria-label="related navigation"] { } body { - font-size: $font-size-base; a { text-decoration: none !important; } @@ -86,6 +85,7 @@ header.o_main_header{ padding-left: 3rem; background-color: lighten($o-violet-dark, 70%) ; z-index: 10; + @include font-size($font-size-secondary); > ul { padding-left: 30px !important; @@ -205,7 +205,7 @@ header.o_main_header{ &:before { @include inline-icomoon($i-o-services , 0 1rem 0 0); display: block; - font-size: 50px; + @include font-size(50px); margin: 0 auto 20px; } &.o_title_start:before { @@ -359,6 +359,7 @@ header.o_main_header{ .o_git_link { color: $gray; @include o-position-absolute($top: 0, $right: 1rem); + @include font-size($font-size-secondary); i { font-size: 1.2rem; margin-right: .2rem; @@ -391,6 +392,7 @@ header.o_main_header{ visibility: hidden !important; &:after { @include inline-icomoon($i-link, 0 1rem 0 0); + @include font-size($font-size-base); visibility: hidden; font-size: 1rem; color: $gray-light; @@ -460,7 +462,6 @@ header.o_main_header{ } > h3, > .alert-title { - font-size: 1.642857143em; line-height: 1em; margin: 0 0 10px 0; font-size: 1rem;