[FIX] web: form statusbar margin
Prior this commit, there was an undesirable margin under `.o_form_statusbar` when on mobile part of task-3355071 Forward-port-of: https://github.com/odoo/odoo/pull/126646 Part-of: odoo/odoo#130616
This commit is contained in:
@@ -403,7 +403,7 @@ export class FormCompiler extends ViewCompiler {
|
||||
compileHeader(el, params) {
|
||||
const statusBar = createElement("div");
|
||||
statusBar.className =
|
||||
"o_form_statusbar position-relative d-flex justify-content-between mb-md-2 pb-2 pb-md-0";
|
||||
"o_form_statusbar position-relative d-flex justify-content-between mb-0 mb-md-2 pb-2 pb-md-0";
|
||||
const buttons = [];
|
||||
const others = [];
|
||||
for (const child of el.childNodes) {
|
||||
|
||||
@@ -184,7 +184,7 @@ QUnit.module("Form Compiler", (hooks) => {
|
||||
const expected = /*xml*/ `
|
||||
<t>
|
||||
<div class="o_form_renderer o_form_nosheet" t-att-class="__comp__.props.class" t-attf-class="{{__comp__.props.record.isInEdition ? 'o_form_editable' : 'o_form_readonly'}} d-block {{ __comp__.props.record.dirty ? 'o_form_dirty' : !__comp__.props.record.isNew ? 'o_form_saved' : '' }}" t-ref="compiled_view_root">
|
||||
<div class="o_form_statusbar position-relative d-flex justify-content-between mb-md-2 pb-2 pb-md-0"><StatusBarButtons/></div>
|
||||
<div class="o_form_statusbar position-relative d-flex justify-content-between mb-0 mb-md-2 pb-2 pb-md-0"><StatusBarButtons/></div>
|
||||
<div>someDiv</div>
|
||||
</div>
|
||||
</t>`;
|
||||
@@ -207,7 +207,7 @@ QUnit.module("Form Compiler", (hooks) => {
|
||||
<t>
|
||||
<div class="o_form_renderer" t-att-class="__comp__.props.class" t-attf-class="{{__comp__.props.record.isInEdition ? 'o_form_editable' : 'o_form_readonly'}} d-flex {{ __comp__.uiService.size < 6 ? "flex-column" : "flex-nowrap h-100" }} {{ __comp__.props.record.dirty ? 'o_form_dirty' : !__comp__.props.record.isNew ? 'o_form_saved' : '' }}" t-ref="compiled_view_root">
|
||||
<div class="o_form_sheet_bg">
|
||||
<div class="o_form_statusbar position-relative d-flex justify-content-between mb-md-2 pb-2 pb-md-0"><StatusBarButtons/></div>
|
||||
<div class="o_form_statusbar position-relative d-flex justify-content-between mb-0 mb-md-2 pb-2 pb-md-0"><StatusBarButtons/></div>
|
||||
<div>someDiv</div>
|
||||
<div class="o_form_sheet position-relative">
|
||||
<div>inside sheet</div>
|
||||
@@ -267,7 +267,7 @@ QUnit.module("Form Compiler", (hooks) => {
|
||||
</form>`;
|
||||
|
||||
const expected = /*xml*/ `
|
||||
<div class="o_form_statusbar position-relative d-flex justify-content-between mb-md-2 pb-2 pb-md-0">
|
||||
<div class="o_form_statusbar position-relative d-flex justify-content-between mb-0 mb-md-2 pb-2 pb-md-0">
|
||||
<StatusBarButtons>
|
||||
<t t-set-slot="button_0" isVisible="true">
|
||||
<div>someDiv</div>
|
||||
@@ -285,7 +285,7 @@ QUnit.module("Form Compiler", (hooks) => {
|
||||
</form>`;
|
||||
|
||||
const expected = /*xml*/ `
|
||||
<div class="o_form_statusbar position-relative d-flex justify-content-between mb-md-2 pb-2 pb-md-0">
|
||||
<div class="o_form_statusbar position-relative d-flex justify-content-between mb-0 mb-md-2 pb-2 pb-md-0">
|
||||
<StatusBarButtons/>
|
||||
</div>`;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user