Skip to content

Commit 8ff74b7

Browse files
committed
[IMP] theme_*: review s_picture snippet occurrences
The goal of this commit is to fix xpath after the `s_picture` snippet redesign, and eventually tweak some classes. task-4047748 closes #824 Related: odoo/odoo#172740 Signed-off-by: Arthur Detroux (ard) <[email protected]>
1 parent e3fc061 commit 8ff74b7

File tree

22 files changed

+39
-58
lines changed

22 files changed

+39
-58
lines changed

theme_artists/views/snippets/s_picture.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,10 @@
44
<template id="s_picture" inherit_id="website.s_picture">
55
<!-- Section -->
66
<xpath expr="//section" position="attributes">
7-
<attribute name="class" add="o_cc5" remove="o_cc2" separator=" "/>
7+
<attribute name="class" add="o_cc5" separator=" "/>
88
</xpath>
99
<!-- Image -->
1010
<xpath expr="//img" position="attributes">
11-
<attribute name="class" remove="img-thumbnail" separator=" "/>
1211
<attribute name="style">width: 100%;</attribute>
1312
</xpath>
1413
</template>

theme_avantgarde/views/customizations.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@
3131
<!-- ======== PICTURE ======== -->
3232
<template id="s_picture" inherit_id="website.s_picture" name="Avantgarde s_cover">
3333
<xpath expr="//section" position="attributes">
34-
<attribute name="class" add="pt144 pb128" remove="pt48 pb24" separator=" "/>
34+
<attribute name="class" add="pt144 pb128" remove="pt64 pb64" separator=" "/>
3535
</xpath>
3636
<xpath expr="//h2" position="attributes">
3737
<attribute name="style" remove="text-align: center;" separator=" "/>
@@ -48,7 +48,6 @@
4848
We combine a wide spectrum of technologies with a good portion of creativity.
4949
</xpath>
5050
<xpath expr="//img" position="attributes">
51-
<attribute name="class" remove="img-thumbnail" separator=" "/>
5251
<attribute name="src">/web_editor/image_shape/website.s_picture_default_image/web_editor/composition/composition_organic_line.svg?c2=o-color-2</attribute>
5352
<attribute name="data-shape">web_editor/composition/composition_organic_line</attribute>
5453
<attribute name="data-original-mimetype">image/jpeg</attribute>

theme_aviato/views/snippets/s_picture.xml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,16 @@
33

44
<template id="s_picture" inherit_id="website.s_picture">
55
<xpath expr="//section" position="attributes">
6-
<attribute name="class" add="pt72 overflow-hidden o_cc3 bg-o-color-3" remove="pt48 o_cc2" separator=" "/>
6+
<attribute name="class" add="pt72 overflow-hidden o_cc3 bg-o-color-3" remove="pt64" separator=" "/>
77
</xpath>
88
<xpath expr="//h2" position="replace" mode="inner">
99
Our travel agencies
1010
</xpath>
1111
<xpath expr="//img" position="attributes">
12-
<attribute name="class" remove="img-thumbnail" separator=" "/>
1312
<attribute name="style">width: 100%;</attribute>
1413
</xpath>
1514
<xpath expr="//figcaption" position="replace">
16-
<figcaption class="text-400"><em>Odoo Travel New York</em></figcaption>
15+
<figcaption class="figure-caption text-400"><em>Odoo Travel New York</em></figcaption>
1716
</xpath>
1817
</template>
1918

theme_beauty/views/snippets/s_picture.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44
<template id="s_picture" inherit_id="website.s_picture">
55
<!-- Section -->
66
<xpath expr="//section" position="attributes">
7-
<attribute name="class" add="o_cc1" remove="o_cc2" separator=" "/>
7+
<attribute name="class" add="o_cc1" separator=" "/>
88
<attribute name="data-oe-shape-data">{"shape":"web_editor/Rainy/06","flip":["x"]}</attribute>
99
</xpath>
1010
<!-- Shape -->
11-
<xpath expr="//div[hasclass('container')]" position="before">
11+
<xpath expr="//div[hasclass('o_container_small')]" position="before">
1212
<div class="o_we_shape o_web_editor_Rainy_06" style="background-image: url('/web_editor/shape/web_editor/Rainy/06.svg?c1=o-color-1&amp;c2=o-color-2&amp;c3=o-color-3&amp;flip=x'); background-position: 50% 100%;"/>
1313
</xpath>
1414
</template>

theme_bistro/views/new_page_template.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<attribute name="data-oe-shape-data">{"shape":"web_editor/Origins/04_001"}</attribute>
2020
</xpath>
2121
<!-- Shape -->
22-
<xpath expr="//div[hasclass('container')]" position="before">
22+
<xpath expr="//div[hasclass('o_container_small')]" position="before">
2323
<div class="o_we_shape o_web_editor_Origins_04_001"/>
2424
</xpath>
2525
</template>
@@ -76,7 +76,7 @@
7676
<attribute name="data-oe-shape-data">{"shape":"web_editor/Origins/04_001"}</attribute>
7777
</xpath>
7878
<!-- Shape -->
79-
<xpath expr="//div[hasclass('container')]" position="before">
79+
<xpath expr="//div[hasclass('o_container_small')]" position="before">
8080
<div class="o_we_shape o_web_editor_Origins_04_001"/>
8181
</xpath>
8282
</template>

theme_bistro/views/snippets/s_picture.xml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<template id="s_picture" inherit_id="website.s_picture">
55
<!-- Section -->
66
<xpath expr="//section" position="attributes">
7-
<attribute name="class" add="o_cc3 pt64" remove="o_cc2 pt48 pb24" separator=" "/>
7+
<attribute name="class" add="o_cc3" remove="pb64" separator=" "/>
88
</xpath>
99
<!-- Size -->
1010
<xpath expr="//div[hasclass('col-lg-12')]" position="attributes">
@@ -30,7 +30,7 @@
3030
<attribute name="data-oe-shape-data">{"shape":"web_editor/Origins/04_001"}</attribute>
3131
</xpath>
3232
<!-- Shape -->
33-
<xpath expr="//div[hasclass('container')]" position="before">
33+
<xpath expr="//div[hasclass('o_container_small')]" position="before">
3434
<div class="o_we_shape o_web_editor_Origins_04_001"/>
3535
</xpath>
3636
</template>

theme_bookstore/views/snippets/s_picture.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<template id="s_picture" inherit_id="website.s_picture">
55
<!-- Section -->
66
<xpath expr="//section" position="attributes">
7-
<attribute name="class" add="o_cc5" remove="o_cc2" separator=" "/>
7+
<attribute name="class" add="o_cc5" separator=" "/>
88
</xpath>
99
<!-- Title -->
1010
<xpath expr="//h2" position="replace" mode="inner">

theme_cobalt/views/customizations.xml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -169,16 +169,13 @@
169169
<!-- ==== Picture ===== -->
170170
<template id="s_picture" inherit_id="website.s_picture" name="Cobalt s_picture">
171171
<xpath expr="//section" position="attributes">
172-
<attribute name="class" add="pt72 overflow-hidden" remove="o_cc o_cc2 pt48" separator=" "/>
172+
<attribute name="class" add="pt72 overflow-hidden" remove="pt64" separator=" "/>
173173
</xpath>
174-
<xpath expr="//div[hasclass('container')]" position="attributes">
175-
<attribute name="class" add="container-fluid px-5 px-lg-0" remove="container" separator=" "/>
176-
</xpath>
177-
<xpath expr="//img" position="attributes">
178-
<attribute name="class" remove="img-thumbnail padding-large" separator=" "/>
174+
<xpath expr="//div[hasclass('o_container_small')]" position="attributes">
175+
<attribute name="class" add="container-fluid px-5 px-lg-0" remove="o_container_small" separator=" "/>
179176
</xpath>
180177
<xpath expr="//figcaption" position="replace">
181-
<figcaption class="text-400"><em>Our office in Dhaka</em></figcaption>
178+
<figcaption class="figure-caption text-400"><em>Our office in Dhaka</em></figcaption>
182179
</xpath>
183180
</template>
184181

theme_enark/views/snippets/s_picture.xml

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,12 @@
44
<template id="s_picture" inherit_id="website.s_picture">
55
<!-- Section -->
66
<xpath expr="//section" position="attributes">
7-
<attribute name="class" add="pt80" remove="pt48 o_cc o_cc2" separator=" "/>
7+
<attribute name="class" add="pt80" remove="pt64" separator=" "/>
88
</xpath>
99
<!-- Title -->
1010
<xpath expr="//h2" position="replace" mode="inner">
1111
Creating places that enhance the human experience.
1212
</xpath>
13-
<!-- Paragraphs -->
14-
<xpath expr="//p[1]" position="replace" />
1513
<!-- Caption -->
1614
<xpath expr="//figcaption" position="replace" mode="inner">
1715
We always put people and nature at the center of our projects.

theme_graphene/views/customizations.xml

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -268,10 +268,10 @@
268268
<!-- ======== PICTURE ======== -->
269269
<template id="s_picture" inherit_id="website.s_picture" name="Graphene s_picture">
270270
<xpath expr="//section" position="attributes">
271-
<attribute name="class" add="pb0 pt48" remove="pb24 pt48" separator=" "/>
271+
<attribute name="class" add="pb0 pt48" remove="pb64 pt64" separator=" "/>
272272
<attribute name="data-oe-shape-data">{"shape":"web_editor/Zigs/01_001","flip":[]}</attribute>
273273
</xpath>
274-
<xpath expr="//section/div[hasclass('container')]" position="before">
274+
<xpath expr="//section/div[hasclass('o_container_small')]" position="before">
275275
<div class="o_we_shape o_web_editor_Zigs_01_001"/>
276276
</xpath>
277277
<!-- Content -->
@@ -281,9 +281,6 @@
281281
<xpath expr="//p" position="replace" mode="inner">
282282
Put your people at the heart of your marketing with tools that help you get to know your audience <br/>and see who you should be talking to.
283283
</xpath>
284-
<xpath expr="//img" position="attributes">
285-
<attribute name="class" add="p-0 border-0" remove="padding-large" separator=" " />
286-
</xpath>
287284
</template>
288285

289286
</odoo>

0 commit comments

Comments
 (0)