[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:
@@ -171,3 +171,12 @@ $o-gray-color-palettes-compatibility-indexes: (
|
||||
5: 'kiddo-5',
|
||||
6: 'kiddo-6',
|
||||
);
|
||||
|
||||
//------------------------------------------------------------------------------
|
||||
// Shapes
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
$o-bg-shapes: change-shape-colors-mapping('web_editor', 'Wavy/13', (4: 4));
|
||||
$o-bg-shapes: add-extra-shape-colors-mapping('web_editor', 'Wavy/13', 'second', (4: 3));
|
||||
$o-bg-shapes: change-shape-colors-mapping('web_editor', 'Wavy/19', (5: 4));
|
||||
$o-bg-shapes: add-footer-shape-colors-mapping('web_editor', 'Wavy/22', (3: 'footer'));
|
||||
|
||||
@@ -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">
|
||||
|
||||
@@ -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">
|
||||
|
||||
Reference in New Issue
Block a user