MCPcopy Create free account
hub / github.com/TruthHun/BookStack / havingBaseStyle

Method havingBaseStyle

static/katex/katex.mjs:4916–4928  ·  view source on GitHub ↗

* Like `this.havingSize(BASESIZE).havingStyle(style)`. If `style` is omitted, * changes to at least `\textstyle`.

(style)

Source from the content-addressed store, hash-verified

4914
4915
4916 havingBaseStyle(style) {
4917 style = style || this.style.text();
4918 const wantSize = sizeAtStyle(Options.BASESIZE, style);
4919
4920 if (this.size === wantSize && this.textSize === Options.BASESIZE && this.style === style) {
4921 return this;
4922 } else {
4923 return this.extend({
4924 style: style,
4925 size: wantSize
4926 });
4927 }
4928 }
4929 /**
4930 * Remove the effect of sizing changes such as \Huge.
4931 * Keep the effect of the current style, such as \scriptstyle.

Callers 15

delimiter_styleWrapFunction · 0.80
centerSpanFunction · 0.80
traverseSequenceFunction · 0.80
horizBrace_htmlBuilderFunction · 0.80
styleWrapFunction · 0.80
centerSpanFunction · 0.80
makeStackedDelimFunction · 0.80
traverseSequenceFunction · 0.80
htmlBuilder$7Function · 0.80
DeFunction · 0.80
HeFunction · 0.80

Calls 3

extendMethod · 0.95
textMethod · 0.80
sizeAtStyleFunction · 0.70

Tested by

no test coverage detected