From 72be8ec829582a3ae2f6fc28ec68f0c8764df9a7 Mon Sep 17 00:00:00 2001 From: Don Jayamanne Date: Tue, 29 Oct 2024 23:42:11 +1100 Subject: [PATCH] Update lables even without MatJax/TypeSetter --- packages/controls/src/widget_description.ts | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/packages/controls/src/widget_description.ts b/packages/controls/src/widget_description.ts index 2b0ccdcf7f..afc6556f6e 100644 --- a/packages/controls/src/widget_description.ts +++ b/packages/controls/src/widget_description.ts @@ -67,9 +67,6 @@ export class DescriptionView extends DOMWidgetView { typeset(element: HTMLElement, text?: string): void { this.displayed.then(() => { - if ((window as any).MathJax?.Hub?.Queue) { - return typeset(element, text); - } const widget_manager: any = this.model.widget_manager; const latexTypesetter = widget_manager._rendermime?.latexTypesetter; if (latexTypesetter) { @@ -77,6 +74,8 @@ export class DescriptionView extends DOMWidgetView { element.textContent = text; } latexTypesetter.typeset(element); + } else { + return typeset(element, text); } }); }