[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#14

Related: odoo/odoo#71665
Related: odoo/odoo#71768
X-original-commit: 845b969555
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
This commit is contained in:
qsm-odoo
2021-05-12 10:29:54 +00:00
parent 5cbf95db80
commit 8e181539a5
42 changed files with 161 additions and 79 deletions
+2 -2
View File
@@ -3,11 +3,11 @@
<template id="s_banner" inherit_id="website.s_banner">
<!-- Section -->
<xpath expr="//section" position="attributes">
<attribute name="data-oe-shape-data">{"shape":"web_editor/Wavy/13","colors":{"c4":"o-color-1"},"flip":[]}</attribute>
<attribute name="data-oe-shape-data">{"shape":"web_editor/Wavy/13","flip":[]}</attribute>
</xpath>
<!-- Shape -->
<xpath expr="//section/*[last()]" position="after">
<div class="o_we_shape o_web_editor_Wavy_13" style="background-image: url('/web_editor/shape/web_editor/Wavy/13.svg?c4=%23F3997B');"/>
<div class="o_we_shape o_web_editor_Wavy_13"/>
</xpath>
<!-- Paragraph -->
<xpath expr="//div[hasclass('col-lg-6')]" position="replace">
@@ -4,11 +4,11 @@
<!-- Section -->
<xpath expr="//section" position="attributes">
<attribute name="class" add="o_half_screen_height" separator=" "/>
<attribute name="data-oe-shape-data">{"shape":"web_editor/Wavy/22","colors":{"c3":"o-color-1"},"flip":[]}</attribute>
<attribute name="data-oe-shape-data">{"shape":"web_editor/Wavy/22","flip":[]}</attribute>
</xpath>
<!-- Shape -->
<xpath expr="//div[hasclass('container')]" position="before">
<div class="o_we_shape o_web_editor_Wavy_22" style='background-image: url("/web_editor/shape/web_editor/Wavy/22.svg?c3=%23F3997B");'/>
<div class="o_we_shape o_web_editor_Wavy_22"/>
</xpath>
<!-- Paragraph -->
<xpath expr="//div[hasclass('col-lg-9')]" position="replace">
+2 -2
View File
@@ -4,11 +4,11 @@
<!-- Section -->
<xpath expr="//section" position="attributes">
<attribute name="class" add="o_cc o_cc4 pb72" remove="pb32" separator=" "/>
<attribute name="data-oe-shape-data">{"shape":"web_editor/Wavy/13","colors":{"c4":"o-color-2"},"flip":["x"]}</attribute>
<attribute name="data-oe-shape-data">{"shape":"web_editor/Wavy/13","flip":["x"]}</attribute>
</xpath>
<!-- Shape -->
<xpath expr="//div[hasclass('container')]" position="before">
<div class="o_we_shape o_web_editor_Wavy_13 o_we_flip_x" style='background-image: url("/web_editor/shape/web_editor/Wavy/13.svg?c4=%2399869E");'/>
<div class="o_we_shape o_web_editor_Wavy_13 o_we_flip_x o_second_extra_shape_mapping"/>
</xpath>
<!-- Image -->
<xpath expr="//img" position="attributes">
@@ -4,11 +4,11 @@
<!-- Section -->
<xpath expr="//section" position="attributes">
<attribute name="class" add="o_cc o_cc3 pb152" remove="bg-200 pb32" separator=" "/>
<attribute name="data-oe-shape-data">{"shape":"web_editor/Wavy/19","colors":{"c5":"o-color-1"},"flip":[]}</attribute>
<attribute name="data-oe-shape-data">{"shape":"web_editor/Wavy/19","flip":[]}</attribute>
</xpath>
<!-- Shape -->
<xpath expr="//div[hasclass('container')]" position="before">
<div class="o_we_shape o_web_editor_Wavy_19" style='background-image: url("/web_editor/shape/web_editor/Wavy/19.svg?c5=%23F3997B");'/>
<div class="o_we_shape o_web_editor_Wavy_19"/>
</xpath>
<!-- Column 1 -->
<xpath expr="//div[hasclass('card')]" position="attributes">