#548 #508 Restart numbered lists

This commit is contained in:
Dolan
2021-03-12 03:58:05 +00:00
parent 9864cdea16
commit 0b88cb0ca5
20 changed files with 430 additions and 163 deletions

View File

@ -1,6 +1,6 @@
// http://officeopenxml.com/WPparagraph.php
import * as shortid from "shortid";
import { uniqueId } from "convenience-functions";
import { FootnoteReferenceRun } from "file/footnotes/footnote/run/reference-run";
import { IContext, IXmlableObject, XmlComponent } from "file/xml-components";
@ -79,7 +79,7 @@ export class Paragraph extends XmlComponent {
for (const element of this.root) {
if (element instanceof ExternalHyperlink) {
const index = this.root.indexOf(element);
const concreteHyperlink = new ConcreteHyperlink(element.options.child, shortid.generate().toLowerCase());
const concreteHyperlink = new ConcreteHyperlink(element.options.child, uniqueId());
context.viewWrapper.Relationships.createRelationship(
concreteHyperlink.linkId,
"http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",