From b4eee7f28096eec1a66f91629be433d1aaac96a9 Mon Sep 17 00:00:00 2001 From: "Davide P. Cervone" Date: Sat, 11 Nov 2023 08:58:08 -0500 Subject: [PATCH] Fix default option list to {}. (mathjax/MathJax#3128) --- ts/output/chtml.ts | 2 +- ts/output/common.ts | 2 +- ts/output/svg.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/ts/output/chtml.ts b/ts/output/chtml.ts index 9f41a5d15..92d63d859 100644 --- a/ts/output/chtml.ts +++ b/ts/output/chtml.ts @@ -155,7 +155,7 @@ CommonOutputJax< * @override * @constructor */ - constructor(options: OptionList = null) { + constructor(options: OptionList = {}) { super(options, ChtmlWrapperFactory as any, DefaultFont); this.font.adaptiveCSS(this.options.adaptiveCSS); this.wrapperUsage = new Usage(); diff --git a/ts/output/common.ts b/ts/output/common.ts index 290f4f008..d0f9a0f53 100644 --- a/ts/output/common.ts +++ b/ts/output/common.ts @@ -233,7 +233,7 @@ export abstract class CommonOutputJax< * @param {FC} defaultFont The default FontData constructor * @constructor */ - constructor(options: OptionList = null, + constructor(options: OptionList = {}, defaultFactory: typeof CommonWrapperFactory = null, defaultFont: FC = null) { const [fontClass, font] = (options.fontData instanceof FontData ? diff --git a/ts/output/svg.ts b/ts/output/svg.ts index fdd58ff54..b32a49348 100644 --- a/ts/output/svg.ts +++ b/ts/output/svg.ts @@ -140,7 +140,7 @@ CommonOutputJax< * @override * @constructor */ - constructor(options: OptionList = null) { + constructor(options: OptionList = {}) { super(options, SvgWrapperFactory as any, DefaultFont); this.fontCache = new FontCache(this); }