From 845b9695556c7548704f09d62a7dc696fbf7a40f Mon Sep 17 00:00:00 2001 From: qsm-odoo Date: Wed, 12 May 2021 10:29:54 +0000 Subject: [PATCH] [IMP] theme_*: remove hardcoded colors on shapes and snippets Instead now use another custom mapping for the default colors of the shapes which are used for the default homepage. This allows for the built page to work with any color palette (especially useful for built pages in the new configurator) and to handle footer/header connection. Also change some shapes and default background colors to match what the preview wanted directly (instead of relying on user asked change as that would not be handled when generating the page automatically with the configurator). Part of https://github.com/odoo/design-themes/pull/2 task-2491890 closes odoo/design-themes#12 closes odoo/design-themes#13 Related: odoo/odoo#71665 Related: odoo/odoo#71699 X-original-commit: c483cf271956d2100223e7e1ec1256d8191f9de2 Signed-off-by: Quentin Smetz (qsm) --- .../static/src/scss/primary_variables.scss | 8 ++++++++ .../views/snippets/s_call_to_action.xml | 4 ++-- theme_artists/views/snippets/s_parallax.xml | 4 ++-- theme_artists/views/snippets/s_text_image.xml | 6 +++--- .../views/snippets/s_three_columns.xml | 4 ++-- .../static/src/scss/primary_variables.scss | 6 ++++++ theme_avantgarde/views/customizations.xml | 4 ++-- .../static/src/scss/primary_variables.scss | 6 ++++++ theme_bewise/views/customizations.xml | 4 ++-- .../static/src/scss/primary_variables.scss | 7 +++++++ .../views/snippets/s_call_to_action.xml | 4 ++-- theme_clean/views/snippets/s_cover.xml | 4 ++-- theme_clean/views/snippets/s_text_image.xml | 4 ++-- .../static/src/scss/primary_variables.scss | 8 ++++++++ theme_cobalt/views/customizations.xml | 8 ++++---- .../static/src/scss/primary_variables.scss | 8 ++++++++ theme_kea/views/snippets/s_cover.xml | 4 ++-- theme_kea/views/snippets/s_image_text.xml | 4 ++-- theme_kea/views/snippets/s_references.xml | 4 ++-- .../static/src/scss/primary_variables.scss | 9 +++++++++ theme_kiddo/views/snippets/s_banner.xml | 4 ++-- .../views/snippets/s_call_to_action.xml | 4 ++-- theme_kiddo/views/snippets/s_image_text.xml | 4 ++-- theme_kiddo/views/snippets/s_three_columns.xml | 4 ++-- theme_monglia/views/customizations.xml | 4 ++-- .../static/src/scss/primary_variables.scss | 7 +++++++ theme_notes/views/snippets/s_carousel.xml | 6 +++--- theme_notes/views/snippets/s_company_team.xml | 4 ++-- theme_notes/views/snippets/s_image_text.xml | 6 +++--- theme_notes/views/snippets/s_media_list.xml | 10 +++++----- theme_odoo_experts/views/snippets/s_banner.xml | 2 +- .../static/src/scss/primary_variables.scss | 8 ++++++++ theme_orchid/views/snippets/s_image_text.xml | 4 ++-- theme_orchid/views/snippets/s_text_image.xml | 4 ++-- .../views/snippets/s_three_columns.xml | 2 +- .../static/src/scss/primary_variables.scss | 8 ++++++++ theme_paptic/views/customizations.xml | 18 +++++++++--------- .../static/src/scss/primary_variables.scss | 7 +++++++ theme_real_estate/views/snippets/s_banner.xml | 4 ++-- .../views/snippets/s_image_text.xml | 4 ++-- .../views/snippets/s_quotes_carousel.xml | 12 ++++++------ theme_vehicle/views/customizations.xml | 4 ++-- 42 files changed, 161 insertions(+), 79 deletions(-) diff --git a/theme_artists/static/src/scss/primary_variables.scss b/theme_artists/static/src/scss/primary_variables.scss index e9aa68e29..a7ffccbf9 100644 --- a/theme_artists/static/src/scss/primary_variables.scss +++ b/theme_artists/static/src/scss/primary_variables.scss @@ -119,3 +119,11 @@ $o-color-palettes-compatibility-indexes: ( 22: 'generic-16', 23: 'generic-17', ); + +//------------------------------------------------------------------------------ +// Shapes +//------------------------------------------------------------------------------ + +$o-bg-shapes: change-shape-colors-mapping('web_editor', 'Airy/12', (3: 3)); +$o-bg-shapes: change-shape-colors-mapping('web_editor', 'Wavy/04', (5: 4)); +$o-bg-shapes: add-footer-shape-colors-mapping('web_editor', 'Airy/12', (3: 'footer')); diff --git a/theme_artists/views/snippets/s_call_to_action.xml b/theme_artists/views/snippets/s_call_to_action.xml index 9f3e9a175..90ec9855a 100644 --- a/theme_artists/views/snippets/s_call_to_action.xml +++ b/theme_artists/views/snippets/s_call_to_action.xml @@ -4,11 +4,11 @@ - {"shape":"web_editor/Airy/12","colors":{"c1":"#ab44ff","c3":"o-color-5"},"flip":["y"]} + {"shape":"web_editor/Airy/12","flip":["y"]} -
+
diff --git a/theme_artists/views/snippets/s_parallax.xml b/theme_artists/views/snippets/s_parallax.xml index 9a679fbd9..20098e128 100644 --- a/theme_artists/views/snippets/s_parallax.xml +++ b/theme_artists/views/snippets/s_parallax.xml @@ -3,7 +3,7 @@ diff --git a/theme_artists/views/snippets/s_text_image.xml b/theme_artists/views/snippets/s_text_image.xml index 454dd5c80..0eb6511e3 100644 --- a/theme_artists/views/snippets/s_text_image.xml +++ b/theme_artists/views/snippets/s_text_image.xml @@ -3,12 +3,12 @@