Fix style
This commit is contained in:
@ -297,7 +297,9 @@ describe("AbstractNumbering", () => {
|
|||||||
const level = abstractNumbering.createLevel(0, "lowerRoman", "%0.").font("Times");
|
const level = abstractNumbering.createLevel(0, "lowerRoman", "%0.").font("Times");
|
||||||
const tree = new Formatter().format(level);
|
const tree = new Formatter().format(level);
|
||||||
expect(tree["w:lvl"]).to.include({
|
expect(tree["w:lvl"]).to.include({
|
||||||
"w:rPr": [{ "w:rFonts": [{ _attr: { "w:ascii": "Times", "w:cs": "Times", "w:eastAsia": "Times", "w:hAnsi": "Times" } }] }],
|
"w:rPr": [
|
||||||
|
{ "w:rFonts": [{ _attr: { "w:ascii": "Times", "w:cs": "Times", "w:eastAsia": "Times", "w:hAnsi": "Times" } }] },
|
||||||
|
],
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -15,7 +15,9 @@ describe("RunFonts", () => {
|
|||||||
it("uses hint if given", () => {
|
it("uses hint if given", () => {
|
||||||
const tree = new Formatter().format(new RunFonts("Times", "default"));
|
const tree = new Formatter().format(new RunFonts("Times", "default"));
|
||||||
expect(tree).to.deep.equal({
|
expect(tree).to.deep.equal({
|
||||||
"w:rFonts": [{ _attr: { "w:ascii": "Times", "w:cs": "Times", "w:eastAsia": "Times", "w:hAnsi": "Times", "w:hint": "default" } }],
|
"w:rFonts": [
|
||||||
|
{ _attr: { "w:ascii": "Times", "w:cs": "Times", "w:eastAsia": "Times", "w:hAnsi": "Times", "w:hint": "default" } },
|
||||||
|
],
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -108,7 +108,13 @@ describe("Run", () => {
|
|||||||
run.font("Times");
|
run.font("Times");
|
||||||
const tree = new Formatter().format(run);
|
const tree = new Formatter().format(run);
|
||||||
expect(tree).to.deep.equal({
|
expect(tree).to.deep.equal({
|
||||||
"w:r": [{ "w:rPr": [{ "w:rFonts": [{ _attr: { "w:ascii": "Times", "w:cs": "Times", "w:eastAsia": "Times", "w:hAnsi": "Times" } }] }] }],
|
"w:r": [
|
||||||
|
{
|
||||||
|
"w:rPr": [
|
||||||
|
{ "w:rFonts": [{ _attr: { "w:ascii": "Times", "w:cs": "Times", "w:eastAsia": "Times", "w:hAnsi": "Times" } }] },
|
||||||
|
],
|
||||||
|
},
|
||||||
|
],
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
@ -459,7 +459,11 @@ describe("ParagraphStyle", () => {
|
|||||||
"w:style": [
|
"w:style": [
|
||||||
{ _attr: { "w:type": "paragraph", "w:styleId": "myStyleId" } },
|
{ _attr: { "w:type": "paragraph", "w:styleId": "myStyleId" } },
|
||||||
{ "w:pPr": [] },
|
{ "w:pPr": [] },
|
||||||
{ "w:rPr": [{ "w:rFonts": [{ _attr: { "w:ascii": "Times", "w:cs": "Times", "w:eastAsia": "Times", "w:hAnsi": "Times" } }] }] },
|
{
|
||||||
|
"w:rPr": [
|
||||||
|
{ "w:rFonts": [{ _attr: { "w:ascii": "Times", "w:cs": "Times", "w:eastAsia": "Times", "w:hAnsi": "Times" } }] },
|
||||||
|
],
|
||||||
|
},
|
||||||
],
|
],
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
Reference in New Issue
Block a user