1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-07-13 00:10:37 +02:00

Desktop: Fixes #8736: Fix images with SVG data URLs corrupted in the rich text editor (#9801)

This commit is contained in:
Henry Heino
2024-02-02 09:48:26 -08:00
committed by GitHub
parent 99e8818ba0
commit e71ec2bc49
7 changed files with 29 additions and 1 deletions

View File

@ -7,7 +7,7 @@ export default function(url: string) {
// url should be normalized at this point, and existing entities are decoded
const str = url.trim().toLowerCase();
if (str.indexOf('data:image/svg+xml,') === 0) {
if (str.startsWith('data:image/svg+xml,') || str.startsWith('data:image/svg+xml;utf8,')) {
return true;
}