[FIX] web_editor: allow copy-pasting link target
The `target` attribute for a link specifies where that link should open (for example, in a new tab). Previously, copy-pasting links in the website editor (within text blocks for example) would remove the `target` attribute. This implied loss of functionality. This commit whitelists the `target` attribute to fix that behavior. task-3184150 closes odoo/odoo#113908 X-original-commit: 1464752aca36198e5fed5dc8f5b5041244e6e4a9 Signed-off-by: David Monjoie (dmo) <dmo@odoo.com>
This commit is contained in:
@@ -166,7 +166,7 @@ export const CLIPBOARD_WHITELISTS = {
|
||||
/^btn/,
|
||||
/^fa/,
|
||||
],
|
||||
attributes: ['class', 'href', 'src'],
|
||||
attributes: ['class', 'href', 'src', 'target'],
|
||||
styledTags: ['SPAN', 'B', 'STRONG', 'I', 'S', 'U', 'FONT'],
|
||||
styles: {
|
||||
'text-decoration': { defaultValues: ['', 'none'] },
|
||||
|
||||
Reference in New Issue
Block a user