diff options
| author | Nicolas Lempereur <nle@odoo.com> | 2018-01-29 15:05:02 +0100 |
|---|---|---|
| committer | Nicolas Lempereur <nle@odoo.com> | 2018-01-30 10:37:53 +0100 |
| commit | 109ecd5205ad684a3ba85e94ce419c326696ec34 (patch) | |
| tree | 2bc4e64ea11c024f22181c1f26c80f129708f41a /addons/web/static/src/js/fields/basic_fields.js | |
| parent | 622b1d23706aa5fdebeb0a6a467e0e993355efb6 (diff) | |
[FIX] web_editor: firefox RTEWidget if hidden
It seems that firefox has some difference of behavior from other
browsers as said in:
- https://bugzilla.mozilla.org/show_bug.cgi?id=548397
- https://github.com/whatwg/html/issues/1813
- https://github.com/w3c/csswg-drafts/issues/571
It seems that at least in one instance (a html field hidden on the pos
configuration), firefox fails because of something similar:
window.getComputedStyle(element) returns `null` instead of the element
styles.
In my tests, using the parent window (possible if current frame and
parent have the same origin which should be the case) worked in this
instance, this is examplified by this jsfiddle:
https://jsfiddle.net/Lpv898ve/2/
This work with window.parent and not using window directly.
So this commit adds fallback on doing getComputedStyle from the parent
window (when testing on chromium this gave exactly the same result that
before).
opw-813363
fixes #22211
closes #22610
Diffstat (limited to 'addons/web/static/src/js/fields/basic_fields.js')
0 files changed, 0 insertions, 0 deletions
