MOBILE-4616 format-text: Avoid image treatment if it comes form tex

main
Pau Ferrer Ocaña 2024-09-03 14:48:33 +02:00
parent 48f73468e0
commit c609330cce
1 changed files with 4 additions and 0 deletions

View File

@ -221,6 +221,10 @@ export class CoreFormatTextDirective implements OnChanges, OnDestroy, AsyncDirec
* @param img Image to adapt.
*/
protected adaptImage(img: HTMLElement): void {
if (img.classList.contains('texrender')) {
return;
}
// Element to wrap the image.
const container = document.createElement('span');
const originalWidth = img.attributes.getNamedItem('width');