diff options
| author | qsm-odoo <qsm@odoo.com> | 2017-08-18 16:39:59 +0200 |
|---|---|---|
| committer | qsm-odoo <qsm@odoo.com> | 2017-08-21 10:57:28 +0200 |
| commit | 9af8d5e6dea52016ee4bd3dee1f06d1129dfa8d3 (patch) | |
| tree | 52136020df67bdb8d96fbda2258e1690616e7d1c /addons/web_editor/static/src/less/web_editor.ui.components.less | |
| parent | 9a58e95edf859895ce7c654f7ede6bf75d27b02c (diff) | |
[IMP] web_editor: make HTML editor select2 dropdown better
In saas-15, the LESS editor was introduced alongside the use of the
select2 library to style the <select/> element which allows to choose
the view / less file to edit. The problem is that the default behavior
of the select2 library is to open a dropdown with a max-height of 200px
and a width equals to the <select/> element (with no regards to the
dropdown content). In most cases, the dropdown was then displaying
only a few results, broken over multiple lines.
Now, the dropdown is restyled so that it has no maximum height, no set
width and more readable content.
Diffstat (limited to 'addons/web_editor/static/src/less/web_editor.ui.components.less')
| -rw-r--r-- | addons/web_editor/static/src/less/web_editor.ui.components.less | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/addons/web_editor/static/src/less/web_editor.ui.components.less b/addons/web_editor/static/src/less/web_editor.ui.components.less index c5f1f189b9b..4aab67deb79 100644 --- a/addons/web_editor/static/src/less/web_editor.ui.components.less +++ b/addons/web_editor/static/src/less/web_editor.ui.components.less @@ -207,6 +207,27 @@ } } } +.o_ace_select2_dropdown { + width: auto!important; + padding-top: 4px; + font-family: monospace!important; + + > .select2-results { + max-height: none; + max-height: 70vh; + + .select2-result-label { + padding-top: 1px; + padding-bottom: 2px; + + >.o_ace_select2_result { + padding: 0; + font-size: 12px; + white-space: nowrap; + } + } + } +} // MODALS body .modal { |
