[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 Related: odoo/odoo#71665 Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
This commit is contained in:
@@ -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'));
|
||||
|
||||
@@ -4,11 +4,11 @@
|
||||
<!-- Section -->
|
||||
<xpath expr="//section" position="attributes">
|
||||
<attribute name="class" add="pb152 pt64" remove="pb24 pt48" separator=" "/>
|
||||
<attribute name="data-oe-shape-data">{"shape":"web_editor/Airy/12","colors":{"c1":"#ab44ff","c3":"o-color-5"},"flip":["y"]}</attribute>
|
||||
<attribute name="data-oe-shape-data">{"shape":"web_editor/Airy/12","flip":["y"]}</attribute>
|
||||
</xpath>
|
||||
<!-- Shape -->
|
||||
<xpath expr="//div[hasclass('container')]" position="before">
|
||||
<div class="o_we_shape o_web_editor_Airy_12 o_we_flip_y" style="background-image: url('/web_editor/shape/web_editor/Airy/12.svg?c1=%23ab44ff&c3=%23000000');"/>
|
||||
<div class="o_we_shape o_web_editor_Airy_12 o_we_flip_y"/>
|
||||
</xpath>
|
||||
<!-- Paragraph -->
|
||||
<xpath expr="//h3" position="replace">
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<template id="s_parallax" inherit_id="website.s_parallax">
|
||||
<!-- Section -->
|
||||
<xpath expr="//section" position="attributes">
|
||||
<attribute name="data-oe-shape-data">{"shape":"web_editor/Airy/12","colors":{"c1":"#ab44ff","c3":"o-color-2"},"flip":["y"]}</attribute>
|
||||
<attribute name="data-oe-shape-data">{"shape":"web_editor/Airy/12","flip":["y"]}</attribute>
|
||||
</xpath>
|
||||
<!-- Bg Image -->
|
||||
<xpath expr="//span[hasclass('s_parallax_bg')]" position="replace">
|
||||
@@ -11,7 +11,7 @@
|
||||
</xpath>
|
||||
<!-- Shape -->
|
||||
<xpath expr="//section/*[last()]" position="before">
|
||||
<div class="o_we_shape o_web_editor_Airy_12 o_we_flip_y" style="background-image: url('/web_editor/shape/web_editor/Airy/12.svg?c1=%23ab44ff&c3=%233A3A3A');"/>
|
||||
<div class="o_we_shape o_web_editor_Airy_12 o_we_flip_y"/>
|
||||
</xpath>
|
||||
</template>
|
||||
</odoo>
|
||||
|
||||
@@ -3,12 +3,12 @@
|
||||
<template id="s_text_image" inherit_id="website.s_text_image">
|
||||
<!-- Section -->
|
||||
<xpath expr="//section" position="attributes">
|
||||
<attribute name="class" add="o_cc o_cc3" separator=" "/>
|
||||
<attribute name="data-oe-shape-data">{"shape":"web_editor/Airy/12","colors":{"c1":"#ab44ff","c3":"o-color-1"},"flip":["y"]}</attribute>
|
||||
<attribute name="class" add="o_cc o_cc3 pb128" separator=" "/>
|
||||
<attribute name="data-oe-shape-data">{"shape":"web_editor/Wavy/04"}</attribute>
|
||||
</xpath>
|
||||
<!-- Shape -->
|
||||
<xpath expr="//div[hasclass('container')]" position="before">
|
||||
<div class="o_we_shape o_web_editor_Airy_12 o_we_flip_y" style="background-image: url('/web_editor/shape/web_editor/Airy/12.svg?c1=%23ab44ff&c3=%23AB44FF');"/>
|
||||
<div class="o_we_shape o_web_editor_Wavy_04" />
|
||||
</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_cc o_cc4" remove="bg-200" separator=" "/>
|
||||
<attribute name="data-oe-shape-data">{"shape":"web_editor/Airy/12","colors":{"c1":"#ab44ff","c3":"o-color-2"},"flip":["y"]}</attribute>
|
||||
<attribute name="data-oe-shape-data">{"shape":"web_editor/Airy/12","flip":["y"]}</attribute>
|
||||
</xpath>
|
||||
<!-- Shape -->
|
||||
<xpath expr="//div[hasclass('container')]" position="before">
|
||||
<div class="o_we_shape o_web_editor_Airy_12 o_we_flip_y" style="background-image: url('/web_editor/shape/web_editor/Airy/12.svg?c1=%23ab44ff&c3=%233A3A3A');"/>
|
||||
<div class="o_we_shape o_web_editor_Airy_12 o_we_flip_y"/>
|
||||
</xpath>
|
||||
<!-- Column 1 -->
|
||||
<xpath expr="//div[hasclass('card')]" position="attributes">
|
||||
|
||||
Reference in New Issue
Block a user