FIX: restrict classes allowed for img tag in Markdown
This commit is contained in:
parent
52b33b448d
commit
9cb088e3f6
|
@ -240,4 +240,6 @@ export function setup(helper) {
|
||||||
state, (c,s)=>applyEmoji(c,s,md.options.discourse.emojiUnicodeReplacer))
|
state, (c,s)=>applyEmoji(c,s,md.options.discourse.emojiUnicodeReplacer))
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
helper.whiteList(['img[class=emoji]']);
|
||||||
}
|
}
|
||||||
|
|
|
@ -130,4 +130,6 @@ export function setup(helper) {
|
||||||
helper.registerPlugin(md=>{
|
helper.registerPlugin(md=>{
|
||||||
md.block.bbcode.ruler.push('quotes', rule);
|
md.block.bbcode.ruler.push('quotes', rule);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
helper.whiteList(['img[class=avatar]']);
|
||||||
}
|
}
|
||||||
|
|
|
@ -156,7 +156,6 @@ const DEFAULT_LIST = [
|
||||||
'iframe[marginwidth]',
|
'iframe[marginwidth]',
|
||||||
'iframe[width]',
|
'iframe[width]',
|
||||||
'img[alt]',
|
'img[alt]',
|
||||||
'img[class]',
|
|
||||||
'img[height]',
|
'img[height]',
|
||||||
'img[title]',
|
'img[title]',
|
||||||
'img[width]',
|
'img[width]',
|
||||||
|
|
Loading…
Reference in New Issue