[FIX] web_editor, website: restore style of the autocomplete dropdown
Before this commit, the autocomplete dropdown no longer had a maximum height, which meant that when it contained a lot of elements, it hid the entire editor panel. Indeed, since the CSS of the menu snippet is no longer that of the "frontend", the 'max-height' CSS rule defined for the autocomplete dropdown in the frontend (introduced by this commit: [1]) was no longer applied on the autocomplete dropdown of the backend. In this commit, we therefore moved this css code of the 'ui-autocomplete' defined for the frontend into the common css file (backend + frontend) in order to return to a situation where this code was applied to all autocomplete dropdowns in Website. And thanks to that, we were able to remove the css file "edit_menu.scss" which copied/pasted the frontend 'ui-autocomplete' code for only one of the backend 'ui-autocomplete'. [1]: https://github.com/odoo/odoo/commit/032dd007157de00b683a9d753aa929741c107c01 task-2900529 closes odoo/odoo#102719 X-original-commit: cce26d7697c73326e0a6f2ec81e01b56b4156ad4 Signed-off-by: Romain Derie (rde) <rde@odoo.com>
This commit is contained in:
@@ -1002,3 +1002,25 @@ section, .oe_img_bg, [data-oe-shape-data] {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Autocomplete dropdowns
|
||||
.ui-autocomplete {
|
||||
max-height: 50vh;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
|
||||
.ui-menu-item {
|
||||
padding: 0;
|
||||
> .ui-state-active {
|
||||
border: none;
|
||||
font-weight: normal;
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
.fw-bold {
|
||||
// Needed because the font-family is not "system fonts everywhere" as
|
||||
// elements around it. TODO: use "system fonts everywhere" for
|
||||
// the 'ui-autocomplete' and remove this line.
|
||||
font-weight: 700 !important;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,20 +15,6 @@
|
||||
transform: translate(-50%, -50%)
|
||||
}
|
||||
|
||||
.ui-autocomplete {
|
||||
max-height: 50vh;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
|
||||
.ui-menu-item {
|
||||
padding: 0;
|
||||
> .ui-state-active {
|
||||
border: none;
|
||||
font-weight: normal;
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
@include media-breakpoint-down(md) {
|
||||
.o_we_shape {
|
||||
display: none;
|
||||
|
||||
@@ -1,16 +0,0 @@
|
||||
.ui-autocomplete.o_edit_menu_autocomplete {
|
||||
max-height: 50vh;
|
||||
overflow-y: auto;
|
||||
overflow-x: hidden;
|
||||
.ui-menu-item {
|
||||
padding: 0;
|
||||
> .ui-state-active {
|
||||
border: none;
|
||||
font-weight: normal;
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
.fw-bold {
|
||||
font-weight: 700 !important;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user