Preserve newlines in delete & redraft and desktop notifications (#7750)
Fix #7748
This commit is contained in:
1 parent
b7b331ad0d
commit
c75493755f
2 files changed
+5
-5
No files matched your search
@@ -1,6 +1,5 @@
|
||||
export const unescapeHTML = (html) => {
|
||||
const wrapper = document.createElement('div');
|
||||
html = html.replace(/<br \/>|<br>|\n/g, ' ');
|
||||
wrapper.innerHTML = html;
|
||||
wrapper.innerHTML = html.replace(/<br\s*\/?>/g, '\n').replace(/<\/p><p>/g, '\n\n').replace(/<[^>]*>/g, '');
|
||||
return wrapper.textContent;
|
||||
};
|
||||
Reference in new issue
Block a user