"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
const xml_components_1 = require("../docx/xml-components");
const level_1 = require("./level");
const multi_level_type_1 = require("./multi-level-type");
class AbstractNumberingAttributes extends xml_components_1.XmlAttributeComponent {
    constructor() {
        super(...arguments);
        this.xmlKeys = {
            abstractNumId: "w:abstractNumId",
            restartNumberingAfterBreak: "w15:restartNumberingAfterBreak",
        };
    }
}
class AbstractNumbering extends xml_components_1.XmlComponent {
    constructor(id) {
        super("w:abstractNum");
        this.root.push(new AbstractNumberingAttributes({
            abstractNumId: id,
            restartNumberingAfterBreak: 0,
        }));
        this.root.push(new multi_level_type_1.MultiLevelType("hybridMultilevel"));
        this.id = id;
    }
    addLevel(level) {
        this.root.push(level);
    }
    createLevel(num, format, text, align = "start") {
        const level = new level_1.Level(num, format, text, align);
        this.addLevel(level);
        return level;
    }
}
exports.AbstractNumbering = AbstractNumbering;
//# sourceMappingURL=abstract-numbering.js.map