Fix more spelling rules
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
export * from "./math-accent-character";
|
||||
export * from "./math-base";
|
||||
export * from "./math-limit-location";
|
||||
export * from "./math-naray-properties";
|
||||
export * from "./math-n-ary-properties";
|
||||
export * from "./math-sub-script";
|
||||
export * from "./math-sum";
|
||||
export * from "./math-super-script";
|
||||
|
@ -2,14 +2,14 @@ import { expect } from "chai";
|
||||
|
||||
import { Formatter } from "@export/formatter";
|
||||
|
||||
import { MathNArayProperties } from "./math-naray-properties";
|
||||
import { MathNAryProperties } from "./math-n-ary-properties";
|
||||
|
||||
describe("MathNArayProperties", () => {
|
||||
describe("MathNAryProperties", () => {
|
||||
describe("#constructor()", () => {
|
||||
it("should create a MathNArayProperties with correct root key", () => {
|
||||
const mathNArayProperties = new MathNArayProperties("∑", true, true);
|
||||
it("should create a MathNAryProperties with correct root key", () => {
|
||||
const mathNAryProperties = new MathNAryProperties("∑", true, true);
|
||||
|
||||
const tree = new Formatter().format(mathNArayProperties);
|
||||
const tree = new Formatter().format(mathNAryProperties);
|
||||
expect(tree).to.deep.equal({
|
||||
"m:naryPr": [
|
||||
{
|
||||
@ -31,9 +31,9 @@ describe("MathNArayProperties", () => {
|
||||
});
|
||||
|
||||
it("should add super-script hide attributes", () => {
|
||||
const mathNArayProperties = new MathNArayProperties("∑", false, true);
|
||||
const mathNAryProperties = new MathNAryProperties("∑", false, true);
|
||||
|
||||
const tree = new Formatter().format(mathNArayProperties);
|
||||
const tree = new Formatter().format(mathNAryProperties);
|
||||
expect(tree).to.deep.equal({
|
||||
"m:naryPr": [
|
||||
{
|
||||
@ -62,9 +62,9 @@ describe("MathNArayProperties", () => {
|
||||
});
|
||||
|
||||
it("should add sub-script hide attributes", () => {
|
||||
const mathNArayProperties = new MathNArayProperties("∑", true, false);
|
||||
const mathNAryProperties = new MathNAryProperties("∑", true, false);
|
||||
|
||||
const tree = new Formatter().format(mathNArayProperties);
|
||||
const tree = new Formatter().format(mathNAryProperties);
|
||||
expect(tree).to.deep.equal({
|
||||
"m:naryPr": [
|
||||
{
|
||||
@ -93,9 +93,9 @@ describe("MathNArayProperties", () => {
|
||||
});
|
||||
|
||||
it("should add both super-script and sub-script hide attributes", () => {
|
||||
const mathNArayProperties = new MathNArayProperties("∑", false, false);
|
||||
const mathNAryProperties = new MathNAryProperties("∑", false, false);
|
||||
|
||||
const tree = new Formatter().format(mathNArayProperties);
|
||||
const tree = new Formatter().format(mathNAryProperties);
|
||||
expect(tree).to.deep.equal({
|
||||
"m:naryPr": [
|
||||
{
|
@ -6,7 +6,7 @@ import { MathLimitLocation } from "./math-limit-location";
|
||||
import { MathSubScriptHide } from "./math-sub-script-hide";
|
||||
import { MathSuperScriptHide } from "./math-super-script-hide";
|
||||
|
||||
export class MathNArayProperties extends XmlComponent {
|
||||
export class MathNAryProperties extends XmlComponent {
|
||||
constructor(accent: string, hasSuperScript: boolean, hasSubScript: boolean) {
|
||||
super("m:naryPr");
|
||||
|
@ -3,7 +3,7 @@ import { XmlComponent } from "@file/xml-components";
|
||||
|
||||
import { MathComponent } from "../math-component";
|
||||
import { MathBase } from "./math-base";
|
||||
import { MathNArayProperties } from "./math-naray-properties";
|
||||
import { MathNAryProperties } from "./math-n-ary-properties";
|
||||
import { MathSubScriptElement } from "./math-sub-script";
|
||||
import { MathSuperScriptElement } from "./math-super-script";
|
||||
|
||||
@ -17,7 +17,7 @@ export class MathSum extends XmlComponent {
|
||||
constructor(options: IMathSumOptions) {
|
||||
super("m:nary");
|
||||
|
||||
this.root.push(new MathNArayProperties("∑", !!options.superScript, !!options.subScript));
|
||||
this.root.push(new MathNAryProperties("∑", !!options.superScript, !!options.subScript));
|
||||
|
||||
if (!!options.subScript) {
|
||||
this.root.push(new MathSubScriptElement(options.subScript));
|
||||
|
Reference in New Issue
Block a user