diff options
| author | Benjamin Vray <bvr@odoo.com> | 2021-01-13 10:09:32 +0000 |
|---|---|---|
| committer | qsm-odoo <qsm@odoo.com> | 2021-02-04 14:44:09 +0000 |
| commit | 36db3d06e1899b84f74328adef537fed3644f099 (patch) | |
| tree | a4452fd161c7cf278ab5efccd91cd1a8051ac422 | |
| parent | 462abcf742df8a669513f42b29f467f4baef1580 (diff) | |
[FIX] web_editor: allow to center button with summernote
Before this commit, it was not possible to center a button using the
editor option 'align center'.
It is because, using document.execCommand(), the Chrome browser doesnt
want apply 'text-align: center' on nodes with centered children. And
the buttons have the boostrap class '.btn' which adds text-align:
center.
So the hack here is disabling the text-align property from the '.btn'
class during the execution of document.execCommand().
task-2423935
closes odoo/odoo#65544
X-original-commit: d4f38c344360713287eed22872614f46dec7e0f6
Signed-off-by: Quentin Smetz (qsm) <qsm@odoo.com>
| -rw-r--r-- | addons/web_editor/static/src/scss/wysiwyg.scss | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/addons/web_editor/static/src/scss/wysiwyg.scss b/addons/web_editor/static/src/scss/wysiwyg.scss index 529edec6dd5..623420927dc 100644 --- a/addons/web_editor/static/src/scss/wysiwyg.scss +++ b/addons/web_editor/static/src/scss/wysiwyg.scss @@ -16,6 +16,9 @@ $o-we-zindex: $o-we-overlay-zindex + 1 !default; * { font-weight: inherit !important; } + .btn { + text-align: unset !important; + } } // EDITOR TOP BAR AND POPOVER |
