[FIX] web: fix oe_stat_button dropdown width and button alignment
In the stat buttons' dropdown under "More", if the text is too long a horizontal scroll appears. Fixed by removing the fixed `width` and the `w-100` class on the dropdown box. Because of `height: 100%` which is needed for the button to be aligned with the other buttons, the contents of the dropdown button are not centered. Fixed with a `d-flex` and `align-items-center`. task-3573807 Part-of: odoo/odoo#141163
This commit is contained in:
committed by
Pierre Paridans
parent
2172001cc9
commit
a01a6822dd
@@ -138,7 +138,6 @@
|
||||
}
|
||||
|
||||
.o_dropdown_more {
|
||||
width: 150px;
|
||||
|
||||
.oe_stat_button {
|
||||
height: auto;
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
<div class="o-form-buttonbox position-relative d-flex w-md-auto" t-attf-class="{{ visibleButtons.length >= getMaxButtons() ? 'o_full w-100' : 'o_not_full'}} {{this.props.class}}">
|
||||
<t t-slot="{{ button_value }}" t-foreach="visibleButtons" t-as="button" t-key="button_value"/>
|
||||
<t t-if="additionalButtons.length" >
|
||||
<Dropdown position="'bottom-end'" togglerClass="'o_button_more btn btn-outline-secondary'" menuClass="'o_dropdown_more position-absolute top-100 w-100 p-0 border-0'" class="'oe_stat_button btn position-relative p-0 border-0'">
|
||||
<Dropdown position="'bottom-end'" togglerClass="'o_button_more btn btn-outline-secondary d-flex justify-content-center align-items-center'" menuClass="'o_dropdown_more position-absolute top-100 p-0 border-0'" class="'oe_stat_button btn position-relative p-0 border-0'">
|
||||
<t t-set-slot="toggler"><span>More</span></t>
|
||||
<DropdownItem t-foreach="additionalButtons" t-as="button" t-key="button_value" class="'d-flex flex-column p-0'">
|
||||
<t t-slot="{{ button_value }}" />
|
||||
|
||||
Reference in New Issue
Block a user