[FIX] web_editor: parallax effect in sanitized field

A sanitize fields by default remove all attributes outside of a
whitelist (if sanitize_attributes on field is not set to false).

This prevent to use parallax widget in Html sanitized field since
attribute "data-scroll-background-ratio" define parallax effect speed
but was not in whitelist.

note: also keep data-interval for gallery widget

opw-2053983
closes #35961

Signed-off-by: Nicolas Lempereur (nle) <nle@odoo.com>
This commit is contained in:
Nicolas Lempereur
2019-08-22 10:30:47 +00:00
parent 8443a74cd6
commit da474d0e87
+1 -1
View File
@@ -33,7 +33,7 @@ safe_attrs = clean.defs.safe_attrs | frozenset(
['style',
'data-o-mail-quote', # quote detection
'data-oe-model', 'data-oe-id', 'data-oe-field', 'data-oe-type', 'data-oe-expression', 'data-oe-translation-id', 'data-oe-nodeid',
'data-publish', 'data-id', 'data-res_id', 'data-member_id', 'data-view-id'
'data-publish', 'data-id', 'data-res_id', 'data-interval', 'data-member_id', 'data-scroll-background-ratio', 'data-view-id',
])