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

Function optionsWithFont

static/katex/katex.mjs:12619–12631  ·  view source on GitHub ↗
(group, options)

Source from the content-addressed store, hash-verified

12617};
12618
12619const optionsWithFont = (group, options) => {
12620 const font = group.font; // Checks if the argument is a font family or a font style.
12621
12622 if (!font) {
12623 return options;
12624 } else if (textFontFamilies[font]) {
12625 return options.withTextFontFamily(textFontFamilies[font]);
12626 } else if (textFontWeights[font]) {
12627 return options.withTextFontWeight(textFontWeights[font]);
12628 } else {
12629 return options.withTextFontShape(textFontShapes[font]);
12630 }
12631};
12632
12633defineFunction({
12634 type: "text",

Callers 2

htmlBuilderFunction · 0.70
mathmlBuilderFunction · 0.70

Calls 3

withTextFontFamilyMethod · 0.80
withTextFontWeightMethod · 0.80
withTextFontShapeMethod · 0.80

Tested by

no test coverage detected