[IMP] test_themes, theme_*: ensure that grid options are properly set

This commit adds a test that highlights mismatches in grid-related
options (classes, grid-area style...).

It also fixes the remaining issues in themes about it.

task-4213996

closes odoo/design-themes#969

Related: odoo/odoo#182029
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
This commit is contained in:
Benoit Socias
2024-09-26 16:24:39 +02:00
committed by qsm-odoo
parent 04f90cd883
commit cf227cd139
3 changed files with 40 additions and 4 deletions
+6
View File
@@ -99,6 +99,9 @@
<attribute name="style" remove="--grid-item-padding-y: 16px;" add="--grid-item-padding-y: 24px;" separator=";"/>
</xpath>
<!-- Delete Row #2 -->
<xpath expr="//*[@data-row-count]" position="attributes">
<attribute name="data-row-count">3</attribute>
</xpath>
<xpath expr="(//div[hasclass('o_grid_item')])[5]" position="replace"/>
<xpath expr="(//div[hasclass('o_grid_item')])[5]" position="replace"/>
<xpath expr="(//div[hasclass('o_grid_item')])[5]" position="replace"/>
@@ -423,6 +426,9 @@
<attribute name="class" add="rounded" separator=" "/>
</xpath>
<!-- Remove Title / Paragraph / Button -->
<xpath expr="//*[@data-row-count]" position="attributes">
<attribute name="data-row-count">10</attribute>
</xpath>
<xpath expr="(//div[hasclass('o_grid_item')])[7]" position="replace"/>
<xpath expr="(//div[hasclass('o_grid_item')])[7]" position="replace"/>
</template>