From c609330cce4fa7509dfc66bac705404e6cd1d110 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Ferrer=20Oca=C3=B1a?= Date: Tue, 3 Sep 2024 14:48:33 +0200 Subject: [PATCH] MOBILE-4616 format-text: Avoid image treatment if it comes form tex --- src/core/directives/format-text.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/core/directives/format-text.ts b/src/core/directives/format-text.ts index f762b426e..b07e5ec39 100644 --- a/src/core/directives/format-text.ts +++ b/src/core/directives/format-text.ts @@ -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');