f-docx-editor 0.1.4 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1 @@
1
+ "use strict";(("undefined"!==typeof self?self:this)["webpackChunkFDocxEditor"]=("undefined"!==typeof self?self:this)["webpackChunkFDocxEditor"]||[]).push([[642],{1642:function(e,t,o){o.d(t,{createDocx:function(){return Ot},repackDocx:function(){return Bt}});o(4423),o(4114),o(6573),o(8100),o(7936),o(8111),o(7588),o(1701),o(5367),o(2731),o(7642),o(8004),o(3853),o(5876),o(2475),o(5024),o(1698),o(9577),o(6632),o(4226),o(9486),o(456),o(4979),o(116);var r=o(1213);function n(e){return e.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")}function i(e){return null!=e&&Number.isFinite(e)?String(Math.round(e)):"0"}function s(e,t){if(!e||"none"===e.style||"nil"===e.style)return"";let o=[`w:val="${e.style}"`];return void 0!==e.size&&o.push(`w:sz="${i(e.size)}"`),void 0!==e.space&&o.push(`w:space="${i(e.space)}"`),e.color&&(e.color.auto?o.push('w:color="auto"'):e.color.rgb&&o.push(`w:color="${e.color.rgb}"`),e.color.themeColor&&o.push(`w:themeColor="${e.color.themeColor}"`),e.color.themeTint&&o.push(`w:themeTint="${e.color.themeTint}"`),e.color.themeShade&&o.push(`w:themeShade="${e.color.themeShade}"`)),e.shadow&&o.push('w:shadow="true"'),e.frame&&o.push('w:frame="true"'),`<w:${t} ${o.join(" ")}/>`}var l=["top","left","bottom","right","between","bar"];function a(e){if(!e)return"";let t=[];for(let o of l){let r=s(e[o],o);r&&t.push(r)}return 0===t.length?"":`<w:pBdr>${t.join("")}</w:pBdr>`}function p(e){if(!e)return"";let t=[];return e.pattern?t.push(`w:val="${e.pattern}"`):t.push('w:val="clear"'),e.color?.rgb?t.push(`w:color="${e.color.rgb}"`):e.color?.auto&&t.push('w:color="auto"'),e.fill?.rgb?t.push(`w:fill="${e.fill.rgb}"`):e.fill?.auto&&t.push('w:fill="auto"'),e.fill?.themeColor&&t.push(`w:themeFill="${e.fill.themeColor}"`),e.fill?.themeTint&&t.push(`w:themeFillTint="${e.fill.themeTint}"`),e.fill?.themeShade&&t.push(`w:themeFillShade="${e.fill.themeShade}"`),0===t.length?"":`<w:shd ${t.join(" ")}/>`}function c(e){return e&&0!==e.length?`<w:tabs>${e.map(e=>{let t=[`w:val="${e.alignment}"`,`w:pos="${i(e.position)}"`];return e.leader&&"none"!==e.leader&&t.push(`w:leader="${e.leader}"`),`<w:tab ${t.join(" ")}/>`}).join("")}</w:tabs>`:""}function h(e){let t=[];return void 0!==e.spaceBefore&&t.push(`w:before="${i(e.spaceBefore)}"`),void 0!==e.spaceAfter&&t.push(`w:after="${i(e.spaceAfter)}"`),void 0!==e.lineSpacing&&t.push(`w:line="${i(e.lineSpacing)}"`),e.lineSpacingRule&&t.push(`w:lineRule="${e.lineSpacingRule}"`),e.beforeAutospacing&&t.push('w:beforeAutospacing="1"'),e.afterAutospacing&&t.push('w:afterAutospacing="1"'),0===t.length?"":`<w:spacing ${t.join(" ")}/>`}function m(e){let t=[];return void 0!==e.indentLeft&&t.push(`w:left="${i(e.indentLeft)}"`),void 0!==e.indentRight&&t.push(`w:right="${i(e.indentRight)}"`),void 0!==e.indentFirstLine&&(e.hangingIndent?t.push(`w:hanging="${i(Math.abs(e.indentFirstLine))}"`):0!==e.indentFirstLine&&t.push(`w:firstLine="${i(e.indentFirstLine)}"`)),0===t.length?"":`<w:ind ${t.join(" ")}/>`}function w(e){if(!e)return"";let t=[];return void 0!==e.ilvl&&t.push(`<w:ilvl w:val="${i(e.ilvl)}"/>`),void 0!==e.numId&&t.push(`<w:numId w:val="${i(e.numId)}"/>`),0===t.length?"":`<w:numPr>${t.join("")}</w:numPr>`}function u(e){if(!e)return"";let t=[];return void 0!==e.width&&t.push(`w:w="${i(e.width)}"`),void 0!==e.height&&t.push(`w:h="${i(e.height)}"`),e.hAnchor&&t.push(`w:hAnchor="${e.hAnchor}"`),e.vAnchor&&t.push(`w:vAnchor="${e.vAnchor}"`),void 0!==e.x&&t.push(`w:x="${i(e.x)}"`),void 0!==e.y&&t.push(`w:y="${i(e.y)}"`),e.xAlign&&t.push(`w:xAlign="${e.xAlign}"`),e.yAlign&&t.push(`w:yAlign="${e.yAlign}"`),e.wrap&&t.push(`w:wrap="${e.wrap}"`),0===t.length?"":`<w:framePr ${t.join(" ")}/>`}function d(e){let t=[`w:id="${e.id}"`,`w:name="${n(e.name)}"`];return void 0!==e.colFirst&&t.push(`w:colFirst="${e.colFirst}"`),void 0!==e.colLast&&t.push(`w:colLast="${e.colLast}"`),`<w:bookmarkStart ${t.join(" ")}/>`}function f(e){return`<w:bookmarkEnd w:id="${e.id}"/>`}function g(e){let t=[];e.rId&&t.push(`r:id="${e.rId}"`),e.anchor&&t.push(`w:anchor="${n(e.anchor)}"`),e.tooltip&&t.push(`w:tooltip="${n(e.tooltip)}"`),e.target&&t.push(`w:tgtFrame="${n(e.target)}"`),!1===e.history&&t.push('w:history="0"'),e.docLocation&&t.push(`w:docLocation="${n(e.docLocation)}"`);let o=e.children.map(e=>"run"===e.type?ne(e):"bookmarkStart"===e.type?d(e):"bookmarkEnd"===e.type?f(e):"").join("");return`<w:hyperlink${t.length>0?" "+t.join(" "):""}>${o}</w:hyperlink>`}function $(e){let t=[],o=e.content.find(e=>"run"===e.type),r=o?.formatting?G(o.formatting):"",i=['w:fldCharType="begin"'];e.fldLock&&i.push('w:fldLock="true"'),t.push(`<w:r>${r}<w:fldChar ${i.join(" ")}/></w:r>`);let s=e.instruction.startsWith(" ")||e.instruction.endsWith(" ")||e.instruction.includes(" ")?' xml:space="preserve"':"";t.push(`<w:r>${r}<w:instrText${s}>${n(e.instruction)}</w:instrText></w:r>`),t.push(`<w:r>${r}<w:fldChar w:fldCharType="separate"/></w:r>`);for(let n of e.content)"run"===n.type&&t.push(ne(n));return t.push(`<w:r>${r}<w:fldChar w:fldCharType="end"/></w:r>`),t.join("")}function x(e){let t=[],o=e.fieldResult?.[0]?.formatting,r=o?G(o):"",i=['w:fldCharType="begin"'];if(e.fldLock&&i.push('w:fldLock="true"'),t.push(`<w:r>${r}<w:fldChar ${i.join(" ")}/></w:r>`),e.fieldCode.length>0)t.push(...e.fieldCode.map(e=>ne(e)));else{let o=e.instruction.startsWith(" ")||e.instruction.endsWith(" ")||e.instruction.includes(" ")?' xml:space="preserve"':"";t.push(`<w:r>${r}<w:instrText${o}>${n(e.instruction)}</w:instrText></w:r>`)}return t.push(`<w:r>${r}<w:fldChar w:fldCharType="separate"/></w:r>`),t.push(...e.fieldResult.map(e=>ne(e))),t.push(`<w:r>${r}<w:fldChar w:fldCharType="end"/></w:r>`),t.join("")}function y(e){let t=e.properties,o=[];switch(t.alias&&o.push(`<w:alias w:val="${n(t.alias)}"/>`),t.tag&&o.push(`<w:tag w:val="${n(t.tag)}"/>`),t.lock&&"unlocked"!==t.lock&&o.push(`<w:lock w:val="${t.lock}"/>`),t.showingPlaceholder&&o.push("<w:showingPlcHdr/>"),t.sdtType){case"plainText":o.push("<w:text/>");break;case"date":t.dateFormat?o.push(`<w:date w:fullDate="${n(t.dateFormat)}"/>`):o.push("<w:date/>");break;case"dropdown":{let e=(t.listItems??[]).map(e=>`<w:listItem w:displayText="${n(e.displayText)}" w:value="${n(e.value)}"/>`).join("");o.push(`<w:dropDownList>${e}</w:dropDownList>`);break}case"comboBox":{let e=(t.listItems??[]).map(e=>`<w:listItem w:displayText="${n(e.displayText)}" w:value="${n(e.value)}"/>`).join("");o.push(`<w:comboBox>${e}</w:comboBox>`);break}case"checkbox":o.push(`<w14:checkbox><w14:checked w14:val="${t.checked?"1":"0"}"/></w14:checkbox>`);break;case"picture":o.push("<w:picture/>");break}let r=e.content.map(e=>{switch(e.type){case"run":return ne(e);case"hyperlink":return g(e);case"simpleField":return $(e);case"complexField":return x(e);case"inlineSdt":return y(e);case"mathEquation":return e.ommlXml||"";default:return e}}).join("");return`<w:sdt><w:sdtPr>${o.join("")}</w:sdtPr><w:sdtContent>${r}</w:sdtContent></w:sdt>`}function v(e,t){let o=[`w:id="${t.id}"`,`w:name="${n(t.name)}"`];return`<w:${e} ${o.join(" ")}/>`}function b(e,t){let o=t.info,r=Number.isInteger(o.id)&&o.id>=0?o.id:0,i="string"==typeof o.author?o.author.trim():"",s=i.length>0?i:"Unknown",l="string"==typeof o.date?o.date.trim():void 0,a=[`w:id="${r}"`,`w:author="${n(s)}"`];l&&a.push(`w:date="${n(l)}"`);let p=t.content.map(t=>"run"===t.type?"del"===e||"moveFrom"===e?ne(t).replace(/<w:t\b/g,"<w:delText").replace(/<\/w:t>/g,"</w:delText>").replace(/<w:instrText\b/g,"<w:delInstrText").replace(/<\/w:instrText>/g,"</w:delInstrText>"):ne(t):"hyperlink"===t.type?g(t):"").join("");return`<w:${e} ${a.join(" ")}>${p}</w:${e}>`}function T(e){switch(e.type){case"run":return ne(e);case"hyperlink":return g(e);case"bookmarkStart":return d(e);case"bookmarkEnd":return f(e);case"simpleField":return $(e);case"complexField":return x(e);case"inlineSdt":return y(e);case"commentRangeStart":return`<w:commentRangeStart w:id="${e.id}"/>`;case"commentRangeEnd":return`<w:commentRangeEnd w:id="${e.id}"/><w:r><w:rPr><w:rStyle w:val="CommentReference"/></w:rPr><w:commentReference w:id="${e.id}"/></w:r>`;case"insertion":return b("ins",e);case"deletion":return b("del",e);case"moveFrom":return b("moveFrom",e);case"moveTo":return b("moveTo",e);case"moveFromRangeStart":return v("moveFromRangeStart",e);case"moveFromRangeEnd":return`<w:moveFromRangeEnd w:id="${e.id}"/>`;case"moveToRangeStart":return v("moveToRangeStart",e);case"moveToRangeEnd":return`<w:moveToRangeEnd w:id="${e.id}"/>`;case"mathEquation":return e.ommlXml||"";default:return""}}function P(e,t){let o=[];if(e){e.styleId&&o.push(`<w:pStyle w:val="${n(e.styleId)}"/>`),e.keepNext&&o.push("<w:keepNext/>"),e.keepLines&&o.push("<w:keepLines/>"),e.contextualSpacing&&o.push("<w:contextualSpacing/>"),e.pageBreakBefore&&o.push("<w:pageBreakBefore/>");let t=u(e.frame);t&&o.push(t),!1===e.widowControl?o.push('<w:widowControl w:val="0"/>'):!0===e.widowControl&&o.push("<w:widowControl/>");let r=w(e.numPr);r&&o.push(r);let i=a(e.borders);i&&o.push(i);let s=p(e.shading);s&&o.push(s);let l=c(e.tabs);l&&o.push(l),e.suppressLineNumbers&&o.push("<w:suppressLineNumbers/>"),e.suppressAutoHyphens&&o.push("<w:suppressAutoHyphens/>");let d=h(e);d&&o.push(d);let f=m(e);if(f&&o.push(f),e.bidi&&o.push("<w:bidi/>"),e.alignment&&o.push(`<w:jc w:val="${e.alignment}"/>`),void 0!==e.outlineLevel&&o.push(`<w:outlineLvl w:val="${e.outlineLevel}"/>`),e.runProperties){let t=G(e.runProperties);t&&o.push(t)}}return t&&t.length>0&&o.push(...t.map(e=>F(e))),0===o.length?"":`<w:pPr>${o.join("")}</w:pPr>`}function C(e){return e.startsWith("<w:pPr>")&&e.endsWith("</w:pPr>")?e.slice(7,-8):""}function F(e){let t=Number.isInteger(e.info.id)&&e.info.id>=0?e.info.id:0,o="string"==typeof e.info.author?e.info.author.trim():"",r=o.length>0?o:"Unknown",i="string"==typeof e.info.date?e.info.date.trim():void 0,s="string"==typeof e.info.rsid?e.info.rsid.trim():void 0,l=[`w:id="${t}"`,`w:author="${n(r)}"`];i&&l.push(`w:date="${n(i)}"`),s&&l.push(`w:rsid="${n(s)}"`);let a=P(e.previousFormatting)||"<w:pPr/>",p=C(a),c=p.length>0?`<w:pPr>${p}</w:pPr>`:"<w:pPr/>";return`<w:pPrChange ${l.join(" ")}>${c}</w:pPrChange>`}function k(e){let t=[],o=[];e.paraId&&o.push(`w14:paraId="${e.paraId}"`),e.textId&&o.push(`w14:textId="${e.textId}"`);let r=o.length>0?" "+o.join(" "):"",n=P(e.formatting,e.propertyChanges);n&&t.push(n);let i=!!e.renderedPageBreakBefore;for(let s of e.content){let e=T(s);if(e){if(i){let t=j(e);t&&(e=t,i=!1)}t.push(e)}}return`<w:p${r}>${t.join("")}</w:p>`}function j(e){let t=/<w:r(?=[\s>/])[^>]*>/;return t.test(e)?e.replace(t,e=>`${e}<w:lastRenderedPageBreak/>`):null}var S=1e5;function I(){S=1e5}function E(e){return String(null!=e&&""!==e&&0!==e?e:S++)}function R(e){if(!e)return"";if(e.rgb)return`<a:srgbClr val="${e.rgb.replace("#","")}"/>`;if(e.themeColor){let t=`<a:schemeClr val="${e.themeColor}"`;return e.themeTint?t+=`><a:tint val="${e.themeTint}"/></a:schemeClr>`:e.themeShade?t+=`><a:shade val="${e.themeShade}"/></a:schemeClr>`:t+="/>",t}return""}function A(e){if(!e||"none"===e.type)return"<a:noFill/>";if("solid"===e.type&&e.color)return`<a:solidFill>${R(e.color)}</a:solidFill>`;if("gradient"===e.type&&e.gradient){let t=e.gradient,o=t.stops.map(e=>`<a:gs pos="${e.position}">${R(e.color)}</a:gs>`).join(""),r="linear"===t.type?`<a:lin ang="${6e4*(t.angle||0)}" scaled="1"/>`:"";return`<a:gradFill><a:gsLst>${o}</a:gsLst>${r}</a:gradFill>`}return""}function D(e){if(!e)return"";let t=[];null!=e.width&&t.push(`w="${e.width}"`),e.cap&&t.push(`cap="${e.cap}"`);let o=[];return e.color&&o.push(`<a:solidFill>${R(e.color)}</a:solidFill>`),e.style&&"solid"!==e.style&&o.push(`<a:prstDash val="${e.style}"/>`),e.headEnd&&o.push(`<a:headEnd type="${e.headEnd.type}"${e.headEnd.width?` w="${e.headEnd.width}"`:""}${e.headEnd.length?` len="${e.headEnd.length}"`:""}/>`),e.tailEnd&&o.push(`<a:tailEnd type="${e.tailEnd.type}"${e.tailEnd.width?` w="${e.tailEnd.width}"`:""}${e.tailEnd.length?` len="${e.tailEnd.length}"`:""}/>`),0===o.length&&0===t.length?"":`<a:ln${t.length?" "+t.join(" "):""}>${o.join("")}</a:ln>`}function B(e){let t=[],o=e.horizontal;t.push(`<wp:positionH relativeFrom="${o.relativeTo}">`),o.alignment?t.push(`<wp:align>${o.alignment}</wp:align>`):t.push(`<wp:posOffset>${i(o.posOffset)}</wp:posOffset>`),t.push("</wp:positionH>");let r=e.vertical;return t.push(`<wp:positionV relativeFrom="${r.relativeTo}">`),r.alignment?t.push(`<wp:align>${r.alignment}</wp:align>`):t.push(`<wp:posOffset>${i(r.posOffset)}</wp:posOffset>`),t.push("</wp:positionV>"),t.join("")}function L(e){let t=e.wrapText?` wrapText="${e.wrapText}"`:' wrapText="bothSides"';switch(e.type){case"square":return`<wp:wrapSquare${t}/>`;case"tight":return`<wp:wrapTight${t}><wp:wrapPolygon edited="0"><wp:start x="0" y="0"/><wp:lineTo x="0" y="21600"/><wp:lineTo x="21600" y="21600"/><wp:lineTo x="21600" y="0"/><wp:lineTo x="0" y="0"/></wp:wrapPolygon></wp:wrapTight>`;case"through":return`<wp:wrapThrough${t}><wp:wrapPolygon edited="0"><wp:start x="0" y="0"/><wp:lineTo x="0" y="21600"/><wp:lineTo x="21600" y="21600"/><wp:lineTo x="21600" y="0"/><wp:lineTo x="0" y="0"/></wp:wrapPolygon></wp:wrapThrough>`;case"topAndBottom":return"<wp:wrapTopAndBottom/>";case"behind":case"inFront":return"<wp:wrapNone/>";default:return"<wp:wrapNone/>"}}function O(e,t){let o=e.size.width,r=e.size.height,s=e.rId||"rId1",l=t,a=e.filename||`image${l}`,p="";e.transform?.rotation&&(p+=` rot="${Math.round(6e4*e.transform.rotation)}"`),e.transform?.flipH&&(p+=' flipH="1"'),e.transform?.flipV&&(p+=' flipV="1"');let c=void 0!==e.opacity&&e.opacity<1?`<a:alphaModFix amt="${Math.round(1e5*Math.max(0,Math.min(1,e.opacity)))}"/>`:"",h=c?`<a:blip r:embed="${s}">${c}</a:blip>`:`<a:blip r:embed="${s}"/>`,m=[];e.crop?.left&&m.push(`l="${Math.round(1e5*e.crop.left)}"`),e.crop?.top&&m.push(`t="${Math.round(1e5*e.crop.top)}"`),e.crop?.right&&m.push(`r="${Math.round(1e5*e.crop.right)}"`),e.crop?.bottom&&m.push(`b="${Math.round(1e5*e.crop.bottom)}"`);let w=m.length>0?`<a:srcRect ${m.join(" ")}/>`:"";return['<a:graphic xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main">','<a:graphicData uri="http://schemas.openxmlformats.org/drawingml/2006/picture">','<pic:pic xmlns:pic="http://schemas.openxmlformats.org/drawingml/2006/picture">',"<pic:nvPicPr>",`<pic:cNvPr id="${l}" name="${n(a)}"${e.alt?` descr="${n(e.alt)}"`:""}/>`,"<pic:cNvPicPr/>","</pic:nvPicPr>","<pic:blipFill>",h,w,"<a:stretch><a:fillRect/></a:stretch>","</pic:blipFill>","<pic:spPr>",`<a:xfrm${p}>`,'<a:off x="0" y="0"/>',`<a:ext cx="${i(o)}" cy="${i(r)}"/>`,"</a:xfrm>",'<a:prstGeom prst="rect"><a:avLst/></a:prstGeom>',e.outline?D(e.outline):"","</pic:spPr>","</pic:pic>","</a:graphicData>","</a:graphic>"].join("")}function M(e){let t=e.image,o="inline"!==t.wrap.type,r=t.size.width,s=t.size.height,l=t.wrap.distT??0,a=t.wrap.distB??0,p=t.wrap.distL??0,c=t.wrap.distR??0,h=t.padding?.left??0,m=t.padding?.top??0,w=t.padding?.right??0,u=t.padding?.bottom??0,d=`<wp:effectExtent l="${i(h)}" t="${i(m)}" r="${i(w)}" b="${i(u)}"/>`,f=E(t.id),g=t.title||t.filename||`Picture ${f}`,$=O(t,f);if(!o)return["<w:drawing>",`<wp:inline distT="${i(l)}" distB="${i(a)}" distL="${i(p)}" distR="${i(c)}">`,`<wp:extent cx="${i(r)}" cy="${i(s)}"/>`,d,`<wp:docPr id="${f}" name="${n(g)}"${t.alt?` descr="${n(t.alt)}"`:""}${t.decorative?' hidden="1"':""}/>`,'<wp:cNvGraphicFramePr><a:graphicFrameLocks xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main" noChangeAspect="1"/></wp:cNvGraphicFramePr>',$,"</wp:inline>","</w:drawing>"].join("");let x="behind"===t.wrap.type?"1":"0",y=t.position?B(t.position):'<wp:positionH relativeFrom="column"><wp:posOffset>0</wp:posOffset></wp:positionH><wp:positionV relativeFrom="paragraph"><wp:posOffset>0</wp:posOffset></wp:positionV>',v=L(t.wrap);return["<w:drawing>",`<wp:anchor distT="${i(l)}" distB="${i(a)}" distL="${i(p)}" distR="${i(c)}" simplePos="0" relativeHeight="251658240" behindDoc="${x}" locked="0" layoutInCell="${!1===t.layoutInCell?"0":"1"}" allowOverlap="${!1===t.allowOverlap?"0":"1"}">`,'<wp:simplePos x="0" y="0"/>',y,`<wp:extent cx="${i(r)}" cy="${i(s)}"/>`,d,v,`<wp:docPr id="${f}" name="${n(g)}"${t.alt?` descr="${n(t.alt)}"`:""}/>`,'<wp:cNvGraphicFramePr><a:graphicFrameLocks xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main" noChangeAspect="1"/></wp:cNvGraphicFramePr>',$,"</wp:anchor>","</w:drawing>"].join("")}function N(e){return e.map(e=>k(e)).join("")}function W(e){let t=e.shape,o=t.size.width,r=t.size.height,s="textBox"===t.shapeType,l=t.wrap&&"inline"!==t.wrap.type,a=t.wrap?.distT??0,p=t.wrap?.distB??0,c=t.wrap?.distL??0,h=t.wrap?.distR??0,m=E(t.id),w=t.name||(s?`TextBox ${m}`:`Shape ${m}`),u="";t.transform?.rotation&&(u+=` rot="${Math.round(6e4*t.transform.rotation)}"`),t.transform?.flipH&&(u+=' flipH="1"'),t.transform?.flipV&&(u+=' flipV="1"');let d=["<wps:spPr>",`<a:xfrm${u}>`,'<a:off x="0" y="0"/>',`<a:ext cx="${i(o)}" cy="${i(r)}"/>`,"</a:xfrm>",`<a:prstGeom prst="${"textBox"===t.shapeType?"rect":t.shapeType}"><a:avLst/></a:prstGeom>`,A(t.fill),D(t.outline),"</wps:spPr>"].join(""),f="";if(t.textBody){let e=t.textBody,o=['rot="0"','vert="horz"'];e.anchor&&o.push(`anchor="${"middle"===e.anchor?"ctr":e.anchor}"`),e.anchorCenter&&o.push('anchorCtr="1"'),e.margins&&(null!=e.margins.left&&o.push(`lIns="${i(e.margins.left)}"`),null!=e.margins.top&&o.push(`tIns="${i(e.margins.top)}"`),null!=e.margins.right&&o.push(`rIns="${i(e.margins.right)}"`),null!=e.margins.bottom&&o.push(`bIns="${i(e.margins.bottom)}"`)),f=s?["<wps:txbx><w:txbxContent>",N(e.content),"</w:txbxContent></wps:txbx>",`<wps:bodyPr ${o.join(" ")}/>`].join(""):[`<wps:bodyPr ${o.join(" ")}/>`].join("")}let g=['<a:graphic xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main">','<a:graphicData uri="http://schemas.microsoft.com/office/word/2010/wordprocessingShape">',["<wps:wsp>",`<wps:cNvSpPr${s?' txBox="1"':""}/>`,d,f,"</wps:wsp>"].join(""),"</a:graphicData>","</a:graphic>"].join("");if(!l)return["<w:drawing>",`<wp:inline distT="${i(a)}" distB="${i(p)}" distL="${i(c)}" distR="${i(h)}">`,`<wp:extent cx="${i(o)}" cy="${i(r)}"/>`,'<wp:effectExtent l="0" t="0" r="0" b="0"/>',`<wp:docPr id="${m}" name="${n(w)}"/>`,"<wp:cNvGraphicFramePr/>",g,"</wp:inline>","</w:drawing>"].join("");let $="behind"===t.wrap?.type?"1":"0",x=t.position?B(t.position):'<wp:positionH relativeFrom="column"><wp:posOffset>0</wp:posOffset></wp:positionH><wp:positionV relativeFrom="paragraph"><wp:posOffset>0</wp:posOffset></wp:positionV>',y=L(t.wrap);return["<w:drawing>",`<wp:anchor distT="${i(a)}" distB="${i(p)}" distL="${i(c)}" distR="${i(h)}" simplePos="0" relativeHeight="251658240" behindDoc="${$}" locked="0" layoutInCell="1" allowOverlap="1">`,'<wp:simplePos x="0" y="0"/>',x,`<wp:extent cx="${i(o)}" cy="${i(r)}"/>`,'<wp:effectExtent l="0" t="0" r="0" b="0"/>',y,`<wp:docPr id="${m}" name="${n(w)}"/>`,"<wp:cNvGraphicFramePr/>",g,"</wp:anchor>","</w:drawing>"].join("")}var z=new Set(["black","blue","cyan","darkBlue","darkCyan","darkGray","darkGreen","darkMagenta","darkRed","darkYellow","green","lightGray","magenta","red","white","yellow"]);function H(e){if(!e)return"";let t=[];return e.auto?t.push('w:val="auto"'):e.rgb&&t.push(`w:val="${e.rgb}"`),e.themeColor&&t.push(`w:themeColor="${e.themeColor}"`),e.themeTint&&t.push(`w:themeTint="${e.themeTint}"`),e.themeShade&&t.push(`w:themeShade="${e.themeShade}"`),0===t.length?"":`<w:color ${t.join(" ")}/>`}function U(e){if(!e)return"";let t=[];return e.pattern?t.push(`w:val="${e.pattern}"`):t.push('w:val="clear"'),e.color?.rgb?t.push(`w:color="${e.color.rgb}"`):e.color?.auto&&t.push('w:color="auto"'),e.fill?.rgb?t.push(`w:fill="${e.fill.rgb}"`):e.fill?.auto&&t.push('w:fill="auto"'),e.fill?.themeColor&&t.push(`w:themeFill="${e.fill.themeColor}"`),e.fill?.themeTint&&t.push(`w:themeFillTint="${e.fill.themeTint}"`),e.fill?.themeShade&&t.push(`w:themeFillShade="${e.fill.themeShade}"`),0===t.length?"":`<w:shd ${t.join(" ")}/>`}function G(e){if(!e)return"";let t=[];if(e.styleId&&t.push(`<w:rStyle w:val="${n(e.styleId)}"/>`),e.fontFamily){let o=[];e.fontFamily.ascii&&o.push(`w:ascii="${n(e.fontFamily.ascii)}"`),e.fontFamily.hAnsi&&o.push(`w:hAnsi="${n(e.fontFamily.hAnsi)}"`),e.fontFamily.eastAsia&&o.push(`w:eastAsia="${n(e.fontFamily.eastAsia)}"`),e.fontFamily.cs&&o.push(`w:cs="${n(e.fontFamily.cs)}"`),e.fontFamily.asciiTheme&&o.push(`w:asciiTheme="${e.fontFamily.asciiTheme}"`),e.fontFamily.hAnsiTheme&&o.push(`w:hAnsiTheme="${e.fontFamily.hAnsiTheme}"`),e.fontFamily.eastAsiaTheme&&o.push(`w:eastAsiaTheme="${e.fontFamily.eastAsiaTheme}"`),e.fontFamily.csTheme&&o.push(`w:csTheme="${e.fontFamily.csTheme}"`),o.length>0&&t.push(`<w:rFonts ${o.join(" ")}/>`)}!0===e.bold?t.push("<w:b/>"):!1===e.bold&&t.push('<w:b w:val="0"/>'),!0===e.boldCs?t.push("<w:bCs/>"):!1===e.boldCs&&t.push('<w:bCs w:val="0"/>'),!0===e.italic?t.push("<w:i/>"):!1===e.italic&&t.push('<w:i w:val="0"/>'),!0===e.italicCs?t.push("<w:iCs/>"):!1===e.italicCs&&t.push('<w:iCs w:val="0"/>'),e.allCaps&&t.push("<w:caps/>"),e.smallCaps&&t.push("<w:smallCaps/>"),e.strike&&t.push("<w:strike/>"),e.doubleStrike&&t.push("<w:dstrike/>"),e.outline&&t.push("<w:outline/>"),e.shadow&&t.push("<w:shadow/>"),e.emboss&&t.push("<w:emboss/>"),e.imprint&&t.push("<w:imprint/>"),e.hidden&&t.push("<w:vanish/>");let o=H(e.color);if(o&&t.push(o),void 0!==e.spacing&&t.push(`<w:spacing w:val="${i(e.spacing)}"/>`),void 0!==e.scale&&t.push(`<w:w w:val="${i(e.scale)}"/>`),void 0!==e.kerning&&t.push(`<w:kern w:val="${i(e.kerning)}"/>`),void 0!==e.position&&t.push(`<w:position w:val="${i(e.position)}"/>`),void 0!==e.fontSize&&t.push(`<w:sz w:val="${i(e.fontSize)}"/>`),void 0!==e.fontSizeCs&&t.push(`<w:szCs w:val="${i(e.fontSizeCs)}"/>`),e.highlight&&"none"!==e.highlight)if(z.has(e.highlight))t.push(`<w:highlight w:val="${e.highlight}"/>`);else if(!e.shading){let o=e.highlight.replace(/^#/,"");/^[0-9a-fA-F]{6}$/.test(o)&&t.push(`<w:shd w:val="clear" w:color="auto" w:fill="${o}"/>`)}if(e.underline){let o=[`w:val="${e.underline.style}"`];e.underline.color&&(e.underline.color.rgb&&o.push(`w:color="${e.underline.color.rgb}"`),e.underline.color.themeColor&&o.push(`w:themeColor="${e.underline.color.themeColor}"`),e.underline.color.themeTint&&o.push(`w:themeTint="${e.underline.color.themeTint}"`),e.underline.color.themeShade&&o.push(`w:themeShade="${e.underline.color.themeShade}"`)),t.push(`<w:u ${o.join(" ")}/>`)}e.effect&&"none"!==e.effect&&t.push(`<w:effect w:val="${e.effect}"/>`),e.emphasisMark&&"none"!==e.emphasisMark&&t.push(`<w:em w:val="${e.emphasisMark}"/>`);let r=U(e.shading);return r&&t.push(r),e.vertAlign&&"baseline"!==e.vertAlign&&t.push(`<w:vertAlign w:val="${e.vertAlign}"/>`),e.rtl&&t.push("<w:rtl/>"),e.cs&&t.push("<w:cs/>"),0===t.length?"":`<w:rPr>${t.join("")}</w:rPr>`}function V(e){return e.startsWith("<w:rPr>")&&e.endsWith("</w:rPr>")?e.slice(7,-8):""}function _(e){let t=Number.isInteger(e.info.id)&&e.info.id>=0?e.info.id:0,o="string"==typeof e.info.author?e.info.author.trim():"",r=o.length>0?o:"Unknown",i="string"==typeof e.info.date?e.info.date.trim():void 0,s="string"==typeof e.info.rsid?e.info.rsid.trim():void 0,l=[`w:id="${t}"`,`w:author="${n(r)}"`];i&&l.push(`w:date="${n(i)}"`),s&&l.push(`w:rsid="${n(s)}"`);let a=G(e.previousFormatting)||"<w:rPr/>";return`<w:rPrChange ${l.join(" ")}>${a}</w:rPrChange>`}function X(e,t){let o=G(e),r=o?V(o):"",n=(t??[]).map(_).join(""),i=`${r}${n}`;return i?`<w:rPr>${i}</w:rPr>`:""}function q(e){return`<w:t${e.preserveSpace||e.text.startsWith(" ")||e.text.endsWith(" ")||e.text.includes(" ")?' xml:space="preserve"':""}>${n(e.text)}</w:t>`}function Y(e){return"<w:tab/>"}function Z(e){let t=[];return"page"===e.breakType?t.push('w:type="page"'):"column"===e.breakType?t.push('w:type="column"'):"textWrapping"===e.breakType&&(t.push('w:type="textWrapping"'),e.clear&&"none"!==e.clear&&t.push(`w:clear="${e.clear}"`)),0===t.length?"<w:br/>":`<w:br ${t.join(" ")}/>`}function J(e){return`<w:sym w:font="${n(e.font)}" w:char="${n(e.char)}"/>`}function K(e){return"footnoteRef"===e.type?`<w:footnoteReference w:id="${e.id}"/>`:`<w:endnoteReference w:id="${e.id}"/>`}function Q(e){let t=[`w:fldCharType="${e.charType}"`];return e.fldLock&&t.push('w:fldLock="true"'),e.dirty&&t.push('w:dirty="true"'),`<w:fldChar ${t.join(" ")}/>`}function ee(e){return`<w:instrText${e.text.startsWith(" ")||e.text.endsWith(" ")||e.text.includes(" ")?' xml:space="preserve"':""}>${n(e.text)}</w:instrText>`}function te(e){return"<w:softHyphen/>"}function oe(e){return"<w:noBreakHyphen/>"}function re(e){switch(e.type){case"text":return q(e);case"tab":return Y();case"break":return Z(e);case"symbol":return J(e);case"footnoteRef":case"endnoteRef":return K(e);case"fieldChar":return Q(e);case"instrText":return ee(e);case"softHyphen":return te();case"noBreakHyphen":return oe();case"drawing":return M(e);case"shape":return W(e);default:return""}}function ne(e){let t=[],o=X(e.formatting,e.propertyChanges);o&&t.push(o);for(let r of e.content){let e=re(r);e&&t.push(e)}return`<w:r>${t.join("")}</w:r>`}function ie(e){let t=Number.isInteger(e.id)&&e.id>=0?e.id:0,o="string"==typeof e.author?e.author.trim():"",r=o.length>0?o:"Unknown",n="string"==typeof e.date?e.date.trim():void 0;return{id:t,author:r,date:n}}function se(e,t){let o=ie(e),r=[`w:id="${o.id}"`,`w:author="${n(o.author)}"`];return o.date&&r.push(`w:date="${n(o.date)}"`),t&&t.trim().length>0&&r.push(`w:rsid="${n(t.trim())}"`),r.join(" ")}function le(e,t){if(!e)return"";let o=[`w:w="${i(e.value)}"`,`w:type="${e.type}"`];return`<w:${t} ${o.join(" ")}/>`}function ae(e,t){if(!e||"none"===e.style||"nil"===e.style)return"";let o=[`w:val="${e.style}"`];return void 0!==e.size&&o.push(`w:sz="${i(e.size)}"`),void 0!==e.space&&o.push(`w:space="${i(e.space)}"`),e.color&&(e.color.auto?o.push('w:color="auto"'):e.color.rgb&&o.push(`w:color="${e.color.rgb}"`),e.color.themeColor&&o.push(`w:themeColor="${e.color.themeColor}"`),e.color.themeTint&&o.push(`w:themeTint="${e.color.themeTint}"`),e.color.themeShade&&o.push(`w:themeShade="${e.color.themeShade}"`)),e.shadow&&o.push('w:shadow="true"'),e.frame&&o.push('w:frame="true"'),`<w:${t} ${o.join(" ")}/>`}function pe(e,t){if(!e)return"";let o=[];if(e.top){let t=ae(e.top,"top");t&&o.push(t)}if(e.left){let t=ae(e.left,"left");t&&o.push(t)}if(e.bottom){let t=ae(e.bottom,"bottom");t&&o.push(t)}if(e.right){let t=ae(e.right,"right");t&&o.push(t)}if(e.insideH){let t=ae(e.insideH,"insideH");t&&o.push(t)}if(e.insideV){let t=ae(e.insideV,"insideV");t&&o.push(t)}return 0===o.length?"":`<w:${t}>${o.join("")}</w:${t}>`}function ce(e,t){if(!e)return"";let o=[];return e.top&&o.push(le(e.top,"top")),e.left&&o.push(le(e.left,"left")),e.bottom&&o.push(le(e.bottom,"bottom")),e.right&&o.push(le(e.right,"right")),0===o.length?"":`<w:${t}>${o.join("")}</w:${t}>`}function he(e){if(!e)return"";let t=[];return e.pattern?t.push(`w:val="${e.pattern}"`):t.push('w:val="clear"'),e.color?.rgb?t.push(`w:color="${e.color.rgb}"`):e.color?.auto&&t.push('w:color="auto"'),e.fill?.rgb?t.push(`w:fill="${e.fill.rgb}"`):e.fill?.auto&&t.push('w:fill="auto"'),e.fill?.themeColor&&t.push(`w:themeFill="${e.fill.themeColor}"`),e.fill?.themeTint&&t.push(`w:themeFillTint="${e.fill.themeTint}"`),e.fill?.themeShade&&t.push(`w:themeFillShade="${e.fill.themeShade}"`),0===t.length?"":`<w:shd ${t.join(" ")}/>`}function me(e){if(!e)return"";let t=[];return e.firstRow&&t.push('w:firstRow="1"'),e.lastRow&&t.push('w:lastRow="1"'),e.firstColumn&&t.push('w:firstColumn="1"'),e.lastColumn&&t.push('w:lastColumn="1"'),e.noHBand&&t.push('w:noHBand="1"'),e.noVBand&&t.push('w:noVBand="1"'),0===t.length?"":`<w:tblLook ${t.join(" ")}/>`}function we(e){if(!e)return"";let t=[];return e.horzAnchor&&t.push(`w:horzAnchor="${e.horzAnchor}"`),e.vertAnchor&&t.push(`w:vertAnchor="${e.vertAnchor}"`),void 0!==e.tblpX&&t.push(`w:tblpX="${i(e.tblpX)}"`),e.tblpXSpec&&t.push(`w:tblpXSpec="${e.tblpXSpec}"`),void 0!==e.tblpY&&t.push(`w:tblpY="${i(e.tblpY)}"`),e.tblpYSpec&&t.push(`w:tblpYSpec="${e.tblpYSpec}"`),void 0!==e.topFromText&&t.push(`w:topFromText="${i(e.topFromText)}"`),void 0!==e.bottomFromText&&t.push(`w:bottomFromText="${i(e.bottomFromText)}"`),void 0!==e.leftFromText&&t.push(`w:leftFromText="${i(e.leftFromText)}"`),void 0!==e.rightFromText&&t.push(`w:rightFromText="${i(e.rightFromText)}"`),0===t.length?"":`<w:tblpPr ${t.join(" ")}/>`}function ue(e,t){let o=[];if(e){e.styleId&&o.push(`<w:tblStyle w:val="${n(e.styleId)}"/>`);let t=we(e.floating);t&&o.push(t),e.bidi&&o.push("<w:bidiVisual/>");let r=le(e.width,"tblW");r&&o.push(r),e.justification&&o.push(`<w:jc w:val="${e.justification}"/>`);let i=le(e.cellSpacing,"tblCellSpacing");i&&o.push(i);let s=le(e.indent,"tblInd");s&&o.push(s);let l=pe(e.borders,"tblBorders");l&&o.push(l);let a=ce(e.cellMargins,"tblCellMar");a&&o.push(a),e.layout&&o.push(`<w:tblLayout w:type="${e.layout}"/>`);let p=he(e.shading);p&&o.push(p);let c=me(e.look);c&&o.push(c),e.overlap&&o.push(`<w:tblOverlap w:val="${e.overlap}"/>`)}return t&&t.length>0&&o.push(...t.map(e=>fe(e))),0===o.length?"":`<w:tblPr>${o.join("")}</w:tblPr>`}function de(e){return e.startsWith("<w:tblPr>")&&e.endsWith("</w:tblPr>")?e.slice(9,-10):""}function fe(e){let t=se(e.info,e.info.rsid),o=ue(e.previousFormatting)||"<w:tblPr/>",r=de(o),n=r.length>0?`<w:tblPr>${r}</w:tblPr>`:"<w:tblPr/>";return`<w:tblPrChange ${t}>${n}</w:tblPrChange>`}function ge(e,t,o){let r=[];if(e){if(e.cantSplit&&r.push("<w:cantSplit/>"),e.header&&r.push("<w:tblHeader/>"),e.height){let t=[`w:val="${i(e.height.value)}"`];e.heightRule&&t.push(`w:hRule="${e.heightRule}"`),r.push(`<w:trHeight ${t.join(" ")}/>`)}e.justification&&r.push(`<w:jc w:val="${e.justification}"/>`),e.hidden&&r.push("<w:hidden/>")}return o&&("tableRowInsertion"===o.type?r.push(`<w:ins ${se(o.info)}/>`):"tableRowDeletion"===o.type&&r.push(`<w:del ${se(o.info)}/>`)),t&&t.length>0&&r.push(...t.map(e=>xe(e))),0===r.length?"":`<w:trPr>${r.join("")}</w:trPr>`}function $e(e){return e.startsWith("<w:trPr>")&&e.endsWith("</w:trPr>")?e.slice(8,-9):""}function xe(e){let t=se(e.info,e.info.rsid),o=ge(e.previousFormatting)||"<w:trPr/>",r=$e(o),n=r.length>0?`<w:trPr>${r}</w:trPr>`:"<w:trPr/>";return`<w:trPrChange ${t}>${n}</w:trPrChange>`}function ye(e){if(!e)return"";let t=[e.firstRow?"1":"0",e.lastRow?"1":"0",e.firstColumn?"1":"0",e.lastColumn?"1":"0",e.oddVBand?"1":"0",e.evenVBand?"1":"0",e.oddHBand?"1":"0",e.evenHBand?"1":"0",e.nwCell?"1":"0",e.neCell?"1":"0",e.swCell?"1":"0",e.seCell?"1":"0"].join("");return"000000000000"===t?"":`<w:cnfStyle w:val="${t}"/>`}function ve(e,t,o){let r=[];if(e){let t=ye(e.conditionalFormat);t&&r.push(t);let o=le(e.width,"tcW");o&&r.push(o),e.gridSpan&&e.gridSpan>1&&r.push(`<w:gridSpan w:val="${i(e.gridSpan)}"/>`),e.vMerge&&("restart"===e.vMerge?r.push('<w:vMerge w:val="restart"/>'):r.push("<w:vMerge/>"));let n=pe(e.borders,"tcBorders");n&&r.push(n);let s=he(e.shading);s&&r.push(s),e.noWrap&&r.push("<w:noWrap/>");let l=ce(e.margins,"tcMar");l&&r.push(l),e.textDirection&&r.push(`<w:textDirection w:val="${e.textDirection}"/>`),e.fitText&&r.push("<w:tcFitText/>"),e.verticalAlign&&r.push(`<w:vAlign w:val="${e.verticalAlign}"/>`),e.hideMark&&r.push("<w:hideMark/>")}return o&&("tableCellInsertion"===o.type?r.push(`<w:cellIns ${se(o.info)}/>`):"tableCellDeletion"===o.type?r.push(`<w:cellDel ${se(o.info)}/>`):"tableCellMerge"===o.type&&r.push(`<w:cellMerge ${se(o.info)}/>`)),t&&t.length>0&&r.push(...t.map(e=>Te(e))),0===r.length?"":`<w:tcPr>${r.join("")}</w:tcPr>`}function be(e){return e.startsWith("<w:tcPr>")&&e.endsWith("</w:tcPr>")?e.slice(8,-9):""}function Te(e){let t=se(e.info,e.info.rsid),o=ve(e.previousFormatting)||"<w:tcPr/>",r=be(o),n=r.length>0?`<w:tcPr>${r}</w:tcPr>`:"<w:tcPr/>";return`<w:tcPrChange ${t}>${n}</w:tcPrChange>`}function Pe(e){return e&&0!==e.length?`<w:tblGrid>${e.map(e=>`<w:gridCol w:w="${i(e)}"/>`).join("")}</w:tblGrid>`:""}function Ce(e){let t=[];for(let o of e)"paragraph"===o.type?t.push(k(o)):"table"===o.type&&t.push(je(o));return 0===t.length&&t.push("<w:p/>"),t.join("")}function Fe(e){let t=[],o=ve(e.formatting,e.propertyChanges,e.structuralChange);return o&&t.push(o),t.push(Ce(e.content)),`<w:tc>${t.join("")}</w:tc>`}function ke(e){let t=[],o=ge(e.formatting,e.propertyChanges,e.structuralChange);o&&t.push(o);for(let r of e.cells)t.push(Fe(r));return`<w:tr>${t.join("")}</w:tr>`}function je(e){let t=[],o=ue(e.formatting,e.propertyChanges);o&&t.push(o);let r=Pe(e.columnWidths);r&&t.push(r);for(let n of e.rows)t.push(ke(n));return`<w:tbl>${t.join("")}</w:tbl>`}var Se={wpc:"http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas",mc:"http://schemas.openxmlformats.org/markup-compatibility/2006",o:"urn:schemas-microsoft-com:office:office",r:"http://schemas.openxmlformats.org/officeDocument/2006/relationships",m:"http://schemas.openxmlformats.org/officeDocument/2006/math",v:"urn:schemas-microsoft-com:vml",wp14:"http://schemas.microsoft.com/office/word/2010/wordprocessingDrawing",wp:"http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawing",w10:"urn:schemas-microsoft-com:office:word",w:"http://schemas.openxmlformats.org/wordprocessingml/2006/main",w14:"http://schemas.microsoft.com/office/word/2010/wordml",w15:"http://schemas.microsoft.com/office/word/2012/wordml",wpg:"http://schemas.microsoft.com/office/word/2010/wordprocessingGroup",wps:"http://schemas.microsoft.com/office/word/2010/wordprocessingShape"};function Ie(){let e={wpc:Se.wpc,mc:Se.mc,o:Se.o,r:Se.r,m:Se.m,v:Se.v,wp14:Se.wp14,wp:Se.wp,w10:Se.w10,w:Se.w,w14:Se.w14,w15:Se.w15,wpg:Se.wpg,wps:Se.wps};return Object.entries(e).map(([e,t])=>`xmlns:${e}="${t}"`).join(" ")}function Ee(e,t){if(!e||"none"===e.style||"nil"===e.style)return"";let o=[`w:val="${e.style}"`];return void 0!==e.size&&o.push(`w:sz="${i(e.size)}"`),void 0!==e.space&&o.push(`w:space="${i(e.space)}"`),e.color&&(e.color.auto?o.push('w:color="auto"'):e.color.rgb&&o.push(`w:color="${e.color.rgb}"`),e.color.themeColor&&o.push(`w:themeColor="${e.color.themeColor}"`),e.color.themeTint&&o.push(`w:themeTint="${e.color.themeTint}"`),e.color.themeShade&&o.push(`w:themeShade="${e.color.themeShade}"`)),e.shadow&&o.push('w:shadow="true"'),e.frame&&o.push('w:frame="true"'),`<w:${t} ${o.join(" ")}/>`}function Re(e){return`<w:headerReference ${[`w:type="${e.type}"`,`r:id="${e.rId}"`].join(" ")}/>`}function Ae(e){return`<w:footerReference ${[`w:type="${e.type}"`,`r:id="${e.rId}"`].join(" ")}/>`}function De(e){if(!e)return"";let t=[];return e.position&&t.push(`<w:pos w:val="${e.position}"/>`),e.numFmt&&t.push(`<w:numFmt w:val="${e.numFmt}"/>`),void 0!==e.numStart&&t.push(`<w:numStart w:val="${e.numStart}"/>`),e.numRestart&&t.push(`<w:numRestart w:val="${e.numRestart}"/>`),0===t.length?"":`<w:footnotePr>${t.join("")}</w:footnotePr>`}function Be(e){if(!e)return"";let t=[];return e.position&&t.push(`<w:pos w:val="${e.position}"/>`),e.numFmt&&t.push(`<w:numFmt w:val="${e.numFmt}"/>`),void 0!==e.numStart&&t.push(`<w:numStart w:val="${e.numStart}"/>`),e.numRestart&&t.push(`<w:numRestart w:val="${e.numRestart}"/>`),0===t.length?"":`<w:endnotePr>${t.join("")}</w:endnotePr>`}function Le(e){let t=[];return void 0!==e.pageWidth&&t.push(`w:w="${i(e.pageWidth)}"`),void 0!==e.pageHeight&&t.push(`w:h="${i(e.pageHeight)}"`),"landscape"===e.orientation&&t.push('w:orient="landscape"'),0===t.length?"":`<w:pgSz ${t.join(" ")}/>`}function Oe(e){let t=[];return void 0!==e.marginTop&&t.push(`w:top="${i(e.marginTop)}"`),void 0!==e.marginRight&&t.push(`w:right="${i(e.marginRight)}"`),void 0!==e.marginBottom&&t.push(`w:bottom="${i(e.marginBottom)}"`),void 0!==e.marginLeft&&t.push(`w:left="${i(e.marginLeft)}"`),void 0!==e.headerDistance&&t.push(`w:header="${i(e.headerDistance)}"`),void 0!==e.footerDistance&&t.push(`w:footer="${i(e.footerDistance)}"`),void 0!==e.gutter&&t.push(`w:gutter="${i(e.gutter)}"`),0===t.length?"":`<w:pgMar ${t.join(" ")}/>`}function Me(e){if(!e.columnCount&&!e.columns?.length)return"";let t=[];void 0!==e.columnCount&&e.columnCount>1&&t.push(`w:num="${i(e.columnCount)}"`),void 0!==e.columnSpace&&t.push(`w:space="${i(e.columnSpace)}"`),void 0!==e.equalWidth&&t.push(`w:equalWidth="${e.equalWidth?"1":"0"}"`),e.separator&&t.push('w:sep="1"');let o="";return e.columns&&e.columns.length>0&&(o=e.columns.map(e=>{let t=[];return void 0!==e.width&&t.push(`w:w="${i(e.width)}"`),void 0!==e.space&&t.push(`w:space="${i(e.space)}"`),`<w:col ${t.join(" ")}/>`}).join("")),0!==t.length||o?`<w:cols${t.length>0?" "+t.join(" "):""}>${o}</w:cols>`:""}function Ne(e){if(!e.lineNumbers)return"";let t=e.lineNumbers,o=[];return void 0!==t.countBy&&o.push(`w:countBy="${i(t.countBy)}"`),void 0!==t.start&&o.push(`w:start="${i(t.start)}"`),void 0!==t.distance&&o.push(`w:distance="${i(t.distance)}"`),t.restart&&o.push(`w:restart="${t.restart}"`),0===o.length?"":`<w:lnNumType ${o.join(" ")}/>`}function We(e){if(!e.pageBorders)return"";let t=e.pageBorders,o=[],r=[];if(t.display&&o.push(`w:display="${t.display}"`),t.offsetFrom&&o.push(`w:offsetFrom="${t.offsetFrom}"`),t.zOrder&&o.push(`w:zOrder="${t.zOrder}"`),t.top){let e=Ee(t.top,"top");e&&r.push(e)}if(t.left){let e=Ee(t.left,"left");e&&r.push(e)}if(t.bottom){let e=Ee(t.bottom,"bottom");e&&r.push(e)}if(t.right){let e=Ee(t.right,"right");e&&r.push(e)}return 0===r.length?"":`<w:pgBorders${o.length>0?" "+o.join(" "):""}>${r.join("")}</w:pgBorders>`}function ze(e){if(!e.docGrid)return"";let t=e.docGrid,o=[];return t.type&&o.push(`w:type="${t.type}"`),void 0!==t.linePitch&&o.push(`w:linePitch="${t.linePitch}"`),void 0!==t.charSpace&&o.push(`w:charSpace="${t.charSpace}"`),0===o.length?"":`<w:docGrid ${o.join(" ")}/>`}function He(e){if(!e)return"";let t=[];if(e.headerReferences)for(let c of e.headerReferences)t.push(Re(c));if(e.footerReferences)for(let c of e.footerReferences)t.push(Ae(c));let o=De(e.footnotePr);o&&t.push(o);let r=Be(e.endnotePr);r&&t.push(r),e.sectionStart&&t.push(`<w:type w:val="${e.sectionStart}"/>`);let n=Le(e);n&&t.push(n);let i=Oe(e);if(i&&t.push(i),void 0!==e.paperSrcFirst||void 0!==e.paperSrcOther){let o=[];void 0!==e.paperSrcFirst&&o.push(`w:first="${e.paperSrcFirst}"`),void 0!==e.paperSrcOther&&o.push(`w:other="${e.paperSrcOther}"`),t.push(`<w:paperSrc ${o.join(" ")}/>`)}let s=We(e);s&&t.push(s);let l=Ne(e);l&&t.push(l);let a=Me(e);a&&t.push(a);let p=ze(e);return p&&t.push(p),e.verticalAlign&&t.push(`<w:vAlign w:val="${e.verticalAlign}"/>`),e.bidi&&t.push("<w:bidi/>"),e.titlePg&&t.push("<w:titlePg/>"),e.evenAndOddHeaders&&t.push("<w:evenAndOddHeaders/>"),0===t.length?"":`<w:sectPr>${t.join("")}</w:sectPr>`}function Ue(e){if("paragraph"===e.type)return k(e);if("table"===e.type)return je(e);if("blockSdt"===e.type){let t=e.content.map(e=>Ue(e)).join(""),o=e.properties,r=[];return o.alias&&r.push(`<w:alias w:val="${o.alias}"/>`),o.tag&&r.push(`<w:tag w:val="${o.tag}"/>`),`<w:sdt><w:sdtPr>${r.join("")}</w:sdtPr><w:sdtContent>${t}</w:sdtContent></w:sdt>`}return""}function Ge(e){return e.map(e=>Ue(e)).join("")}function Ve(e){let t=[];return t.push(Ge(e.content)),e.finalSectionProperties&&t.push(He(e.finalSectionProperties)),t.join("")}function _e(e){I();let t=[];t.push('<?xml version="1.0" encoding="UTF-8" standalone="yes"?>');let o=Ie();return t.push(`<w:document ${o} mc:Ignorable="w14 w15 wp14">`),t.push("<w:body>"),t.push(Ve(e.package.document)),t.push("</w:body>"),t.push("</w:document>"),t.join("")}var Xe={wpc:"http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas",mc:"http://schemas.openxmlformats.org/markup-compatibility/2006",o:"urn:schemas-microsoft-com:office:office",r:"http://schemas.openxmlformats.org/officeDocument/2006/relationships",m:"http://schemas.openxmlformats.org/officeDocument/2006/math",v:"urn:schemas-microsoft-com:vml",wp14:"http://schemas.microsoft.com/office/word/2010/wordprocessingDrawing",wp:"http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawing",w10:"urn:schemas-microsoft-com:office:word",w:"http://schemas.openxmlformats.org/wordprocessingml/2006/main",w14:"http://schemas.microsoft.com/office/word/2010/wordml",w15:"http://schemas.microsoft.com/office/word/2012/wordml",wpg:"http://schemas.microsoft.com/office/word/2010/wordprocessingGroup",wps:"http://schemas.microsoft.com/office/word/2010/wordprocessingShape"};function qe(){return Object.entries(Xe).map(([e,t])=>`xmlns:${e}="${t}"`).join(" ")}function Ye(e){return"paragraph"===e.type?k(e):"table"===e.type?je(e):""}function Ze(e){let t="header"===e.type?"w:hdr":"w:ftr",o=qe(),r=e.content.map(e=>Ye(e)).join("");return r||(r="<w:p><w:pPr/></w:p>"),`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<${t} ${o}>${r}</${t}>`}var Je='xmlns:wpc="http://schemas.microsoft.com/office/word/2010/wordprocessingCanvas" xmlns:cx="http://schemas.microsoft.com/office/drawing/2014/chartex" xmlns:cx1="http://schemas.microsoft.com/office/drawing/2015/9/8/chartex" xmlns:cx2="http://schemas.microsoft.com/office/drawing/2015/10/21/chartex" xmlns:cx3="http://schemas.microsoft.com/office/drawing/2016/5/9/chartex" xmlns:cx4="http://schemas.microsoft.com/office/drawing/2016/5/10/chartex" xmlns:cx5="http://schemas.microsoft.com/office/drawing/2016/5/11/chartex" xmlns:cx6="http://schemas.microsoft.com/office/drawing/2016/5/12/chartex" xmlns:cx7="http://schemas.microsoft.com/office/drawing/2016/5/13/chartex" xmlns:cx8="http://schemas.microsoft.com/office/drawing/2016/5/14/chartex" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:aink="http://schemas.microsoft.com/office/drawing/2016/ink" xmlns:am3d="http://schemas.microsoft.com/office/drawing/2017/model3d" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:oel="http://schemas.microsoft.com/office/2019/extlst" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:m="http://schemas.openxmlformats.org/officeDocument/2006/math" xmlns:v="urn:schemas-microsoft-com:vml" xmlns:wp14="http://schemas.microsoft.com/office/word/2010/wordprocessingDrawing" xmlns:wp="http://schemas.openxmlformats.org/drawingml/2006/wordprocessingDrawing" xmlns:w10="urn:schemas-microsoft-com:office:word" xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main" xmlns:w14="http://schemas.microsoft.com/office/word/2010/wordml" xmlns:w15="http://schemas.microsoft.com/office/word/2012/wordml" xmlns:w16cex="http://schemas.microsoft.com/office/word/2018/wordml/cex" xmlns:w16cid="http://schemas.microsoft.com/office/word/2016/wordml/cid" xmlns:w16="http://schemas.microsoft.com/office/word/2018/wordml" xmlns:w16du="http://schemas.microsoft.com/office/word/2023/wordml/word16du" xmlns:w16sdtdh="http://schemas.microsoft.com/office/word/2020/wordml/sdtdatahash" xmlns:w16sdtfl="http://schemas.microsoft.com/office/word/2024/wordml/sdtformatlock" xmlns:w16se="http://schemas.microsoft.com/office/word/2015/wordml/symex" xmlns:wpg="http://schemas.microsoft.com/office/word/2010/wordprocessingGroup" xmlns:wpi="http://schemas.microsoft.com/office/word/2010/wordprocessingInk" xmlns:wne="http://schemas.microsoft.com/office/word/2006/wordml" xmlns:wps="http://schemas.microsoft.com/office/word/2010/wordprocessingShape"',Ke='mc:Ignorable="w14 w15 w16se w16cid w16 w16cex w16sdtdh w16sdtfl w16du wp14"';function Qe(e){let t="<w:r>",o=[];e.formatting?.bold&&o.push("<w:b/>"),e.formatting?.italic&&o.push("<w:i/>"),o.length>0&&(t+=`<w:rPr>${o.join("")}</w:rPr>`);for(let r of e.content)if("text"===r.type){let e=r.text!==r.text.trim()||r.text.includes(" ");t+=e?`<w:t xml:space="preserve">${n(r.text)}</w:t>`:`<w:t>${n(r.text)}</w:t>`}else"break"===r.type&&(t+="<w:br/>");return t+="</w:r>",t}function et(e,t){let o=t?`<w:p w14:paraId="${t}">`:"<w:p>";for(let r of e.content)"run"===r.type&&(o+=Qe(r));return o+="</w:p>",o}function tt(e,t){let o=t?`<w:p w14:paraId="${t}">`:"<w:p>";o+='<w:r><w:rPr><w:rStyle w:val="CommentReference"/></w:rPr><w:annotationRef/></w:r>';for(let r of e.content)"run"===r.type&&(o+=Qe(r));return o+="</w:p>",o}function ot(e,t){let o=(0,r.a)(),i=[`w:id="${e.id}"`];if(e.author&&i.push(`w:author="${n(e.author)}"`),e.initials?i.push(`w:initials="${n(e.initials)}"`):i.push('w:initials=""'),e.date){let t=e.date.replace(/\.\d{3}Z$/,"Z");i.push(`w:date="${n(t)}"`)}let s=`<w:comment ${i.join(" ")}>`;if(e.content&&e.content.length>0)if(1===e.content.length)s+=tt(e.content[0],o);else{s+=tt(e.content[0]);for(let t=1;t<e.content.length-1;t++)s+=et(e.content[t]);s+=et(e.content[e.content.length-1],o)}else s+=`<w:p w14:paraId="${o}"><w:r><w:rPr><w:rStyle w:val="CommentReference"/></w:rPr><w:annotationRef/></w:r></w:p>`;return s+="</w:comment>",t.push({commentId:e.id,lastParaId:o,durableId:(0,r.a)(),parentId:e.parentId,done:e.done}),s}function rt(e){if(!e||0===e.length)return{xml:"",paraInfos:[]};let t=[],o=[];for(let i of e)(null==i.parentId?t:o).push(i);let r=[],n=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?><w:comments ${Je} ${Ke}>`;for(let i of t)n+=ot(i,r);for(let i of o)n+=ot(i,r);return n+="</w:comments>",{xml:n,paraInfos:r}}function nt(e){if(0===e.length)return"";let t=new Map;for(let r of e)t.set(r.commentId,r.lastParaId);let o=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?><w15:commentsEx ${Je} ${Ke}>`;for(let r of e){let e=`w15:paraId="${r.lastParaId}" w15:done="${r.done?"1":"0"}"`;if(null!=r.parentId){let o=t.get(r.parentId);o&&(e+=` w15:paraIdParent="${o}"`)}o+=`<w15:commentEx ${e} />`}return o+="</w15:commentsEx>",o}function it(e){if(0===e.length)return"";let t=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?><w16cid:commentsIds ${Je} ${Ke}>`;for(let o of e)t+=`<w16cid:commentId w16cid:paraId="${o.lastParaId}" w16cid:durableId="${o.durableId}" />`;return t+="</w16cid:commentsIds>",t}function st(e,t){if(0===e.length)return"";let o=new Map;for(let n of t)o.set(n.id,n);let r=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?><w16cex:commentsExtensible ${Je} ${Ke}>`;for(let n of e){let e=o.get(n.commentId);if(!e?.date)continue;let t=n.durableId,i=(e.date.endsWith("Z")?e.date:e.date+"Z").replace(/\.\d{3}Z$/,"Z");r+=`<w16cex:commentExtensible w16cex:durableId="${t}" w16cex:dateUtc="${i}"/>`}return r+="</w16cex:commentsExtensible>",r}var lt=o(9970),at=o(8220),pt='<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships"></Relationships>';function ct(e){return e.startsWith("/")?e.slice(1):`word/${e}`}function ht(e){let t=[{relsPath:"word/_rels/document.xml.rels",blocks:e.package.document.content}],o=e.package.relationships;if(!o)return t;let r=(e,r)=>{if(e)for(let[n,i]of e.entries()){let e=o.get(n);if(!e||e.type!==r||!e.target)continue;let s=ct(e.target).replace(/^word\//,"");t.push({relsPath:`word/_rels/${s}.rels`,blocks:i.content})}};return r(e.package.headers,lt.o.header),r(e.package.footers,lt.o.footer),t}async function mt(e,t){let o=e.file(t);return(o?await o.async("text"):pt).replace(/<Relationships([^>]*)\/>/,"<Relationships$1></Relationships>")}function wt(e){let t=0;for(let o of e.matchAll(/Id="rId(\d+)"/g)){let e=parseInt(o[1],10);e>t&&(t=e)}return t}function ut(e,t){return t||{png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",bmp:"image/bmp",tif:"image/tiff",tiff:"image/tiff",svg:"image/svg+xml",webp:"image/webp",wmf:"image/x-wmf",emf:"image/x-emf"}[e]||"application/octet-stream"}function dt(e){let t=[];for(let o of e)if("paragraph"===o.type){for(let e of o.content)if("run"===e.type)for(let o of e.content)"drawing"===o.type&&o.image.src?.startsWith("data:")&&t.push(o.image)}else if("table"===o.type)for(let e of o.rows)for(let o of e.cells)t.push(...dt(o.content));return t}var ft={"image/png":"png","image/jpeg":"jpeg","image/gif":"gif","image/bmp":"bmp","image/tiff":"tiff","image/webp":"webp","image/svg+xml":"svg"};function gt(e){let t=e.match(/^data:([^;]+);base64,(.+)$/);if(!t)throw new Error("Invalid data URL");let o=atob(t[2]),r=new Uint8Array(o.length);for(let n=0;n<o.length;n++)r[n]=o.charCodeAt(n);return{data:r.buffer,extension:ft[t[1]]||"png"}}async function $t(e,t,o){if(0===t.size)return;let r=e.file("[Content_Types].xml");if(!r)return;let n=await r.async("text"),i=!1;for(let s of t)if(!n.includes(`Extension="${s}"`)){let e=ut(s,"");n=n.replace("</Types>",`<Default Extension="${s}" ContentType="${e}"/></Types>`),i=!0}i&&e.file("[Content_Types].xml",n,{compression:"DEFLATE",compressionOptions:{level:o}})}function xt(e){let t=0;return e.forEach(e=>{let o=e.match(/^word\/media\/image(\d+)\./);if(o){let e=parseInt(o[1],10);e>t&&(t=e)}}),t}async function yt(e,t,o){let r=xt(t),n=new Set;for(let{relsPath:i,blocks:s}of e){let e=dt(s);if(0===e.length)continue;let l=await mt(t,i),a=wt(l),p=[];for(let i of e){let{data:e,extension:s}=gt(i.src);r++,a++;let l=`image${r}.${s}`,c=`rId${a}`;t.file(`word/media/${l}`,e,{compression:"DEFLATE",compressionOptions:{level:o}}),p.push(`<Relationship Id="${c}" Type="${lt.o.image}" Target="media/${l}"/>`),n.add(s),i.rId=c}let c=l.replace("</Relationships>",p.join("")+"</Relationships>");t.file(i,c,{compression:"DEFLATE",compressionOptions:{level:o}})}await $t(t,n,o)}function vt(e){let t=[];for(let o of e)if("paragraph"===o.type)for(let e of o.content)"hyperlink"===e.type&&e.href&&!e.rId&&!e.anchor&&t.push(e);else if("table"===o.type)for(let e of o.rows)for(let o of e.cells)t.push(...vt(o.content));return t}async function bt(e,t,o){for(let{relsPath:r,blocks:i}of e){let e=vt(i);if(0===e.length)continue;let s=await mt(t,r),l=wt(s),a=[];for(let t of e){l++;let e=`rId${l}`;a.push(`<Relationship Id="${e}" Type="${lt.o.hyperlink}" Target="${n(t.href)}" TargetMode="External"/>`),t.rId=e}let p=s.replace("</Relationships>",a.join("")+"</Relationships>");t.file(r,p,{compression:"DEFLATE",compressionOptions:{level:o}})}}var Tt="application/vnd.openxmlformats-officedocument.wordprocessingml.header+xml",Pt="application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml",Ct="application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml",Ft="application/vnd.openxmlformats-officedocument.wordprocessingml.commentsExtended+xml",kt="application/vnd.openxmlformats-officedocument.wordprocessingml.commentsIds+xml",jt="application/vnd.openxmlformats-officedocument.wordprocessingml.commentsExtensible+xml";async function St(e,t,o){let r=e.package.relationships;if(!r)return;let n=[];for(let[p,c]of r){if(!c.target)continue;let e=c.type===lt.o.header?Tt:c.type===lt.o.footer?Pt:null;e&&n.push({rId:p,target:c.target.replace(/^(\/?word\/)/,""),contentType:e,relType:c.type})}if(0===n.length)return;let i=t.file("[Content_Types].xml");if(i){let e=await i.async("text"),r=!1;for(let{target:t,contentType:o}of n){let n=`/word/${t}`;e.includes(`PartName="${n}"`)||(e=e.replace("</Types>",`<Override PartName="${n}" ContentType="${o}"/></Types>`),r=!0)}r&&t.file("[Content_Types].xml",e,{compression:"DEFLATE",compressionOptions:{level:o}})}let s="word/_rels/document.xml.rels",l=await mt(t,s),a=!1;for(let{rId:p,relType:c,target:h}of n)l.includes(`Id="${p}"`)||(l=l.replace("</Relationships>",`<Relationship Id="${p}" Type="${c}" Target="${h}"/></Relationships>`),a=!0);a&&t.file(s,l,{compression:"DEFLATE",compressionOptions:{level:o}})}async function It(e,t){let o=[{partName:"/word/comments.xml",contentType:Ct,target:"comments.xml",relType:lt.o.comments},{partName:"/word/commentsExtended.xml",contentType:Ft,target:"commentsExtended.xml",relType:lt.o.commentsExtended},{partName:"/word/commentsIds.xml",contentType:kt,target:"commentsIds.xml",relType:lt.o.commentsIds},{partName:"/word/commentsExtensible.xml",contentType:jt,target:"commentsExtensible.xml",relType:lt.o.commentsExtensible}],r=e.file("[Content_Types].xml");if(r){let n=await r.async("text"),i=!1;for(let{partName:e,contentType:t}of o)n.includes(e)||(n=n.replace("</Types>",`<Override PartName="${e}" ContentType="${t}"/></Types>`),i=!0);i&&e.file("[Content_Types].xml",n,{compression:"DEFLATE",compressionOptions:{level:t}})}let n="word/_rels/document.xml.rels",i=e.file(n);if(i){let r=await i.async("text"),s=!1;for(let{target:e,relType:t}of o)if(!r.includes(e)){let o=`rId${wt(r)+1}`;r=r.replace("</Relationships>",`<Relationship Id="${o}" Type="${t}" Target="${e}"/></Relationships>`),s=!0}s&&e.file(n,r,{compression:"DEFLATE",compressionOptions:{level:t}})}}async function Et(e,t,o){let r=e.package.document.comments;if(!r||0===r.length)return;let{xml:n,paraInfos:i}=rt(r);t.file("word/comments.xml",n,{compression:"DEFLATE",compressionOptions:{level:o}});let s=nt(i);s&&t.file("word/commentsExtended.xml",s,{compression:"DEFLATE",compressionOptions:{level:o}});let l=it(i);l&&t.file("word/commentsIds.xml",l,{compression:"DEFLATE",compressionOptions:{level:o}});let a=st(i,r);a&&t.file("word/commentsExtensible.xml",a,{compression:"DEFLATE",compressionOptions:{level:o}}),await It(t,o)}function Rt(e){let t=new Map,o=e.package.relationships;if(!o)return t;let r=[{map:e.package.headers,type:lt.o.header},{map:e.package.footers,type:lt.o.footer}];for(let{map:n,type:i}of r)if(n)for(let[e,r]of n.entries()){let n=o.get(e);n&&n.type===i&&n.target&&t.set(ct(n.target),Ze(r))}return t}function At(e,t,o){let r={level:o};for(let[n,i]of Rt(e))t.file(n,i,{compression:"DEFLATE",compressionOptions:r})}async function Dt(){let e=new at;e.file("[Content_Types].xml",'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types">\n <Default Extension="rels" ContentType="application/vnd.openxmlformats-package.relationships+xml"/>\n <Default Extension="xml" ContentType="application/xml"/>\n <Override PartName="/word/document.xml" ContentType="application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml"/>\n <Override PartName="/word/styles.xml" ContentType="application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml"/>\n <Override PartName="/docProps/core.xml" ContentType="application/vnd.openxmlformats-package.core-properties+xml"/>\n <Override PartName="/docProps/app.xml" ContentType="application/vnd.openxmlformats-officedocument.extended-properties+xml"/>\n</Types>'),e.file("_rels/.rels",'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n <Relationship Id="rId1" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" Target="word/document.xml"/>\n <Relationship Id="rId2" Type="http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties" Target="docProps/core.xml"/>\n <Relationship Id="rId3" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties" Target="docProps/app.xml"/>\n</Relationships>'),e.file("word/_rels/document.xml.rels",'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n <Relationship Id="rId1" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles" Target="styles.xml"/>\n</Relationships>'),e.file("word/document.xml",'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships">\n <w:body>\n <w:p>\n <w:r>\n <w:t></w:t>\n </w:r>\n </w:p>\n <w:sectPr>\n <w:pgSz w:w="12240" w:h="15840"/>\n <w:pgMar w:top="1440" w:right="1440" w:bottom="1440" w:left="1440" w:header="720" w:footer="720" w:gutter="0"/>\n </w:sectPr>\n </w:body>\n</w:document>'),e.file("word/styles.xml",'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<w:styles xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">\n <w:docDefaults>\n <w:rPrDefault>\n <w:rPr>\n <w:rFonts w:ascii="Calibri" w:hAnsi="Calibri"/>\n <w:sz w:val="22"/>\n </w:rPr>\n </w:rPrDefault>\n <w:pPrDefault>\n <w:pPr>\n <w:spacing w:after="200" w:line="276" w:lineRule="auto"/>\n </w:pPr>\n </w:pPrDefault>\n </w:docDefaults>\n <w:style w:type="paragraph" w:default="1" w:styleId="Normal">\n <w:name w:val="Normal"/>\n </w:style>\n</w:styles>');let t=(new Date).toISOString();return e.file("docProps/core.xml",`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<cp:coreProperties xmlns:cp="http://schemas.openxmlformats.org/package/2006/metadata/core-properties" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:dcterms="http://purl.org/dc/terms/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">\n <dc:creator>EigenPal DOCX Editor</dc:creator>\n <dcterms:created xsi:type="dcterms:W3CDTF">${t}</dcterms:created>\n <dcterms:modified xsi:type="dcterms:W3CDTF">${t}</dcterms:modified>\n</cp:coreProperties>`),e.file("docProps/app.xml",'<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<Properties xmlns="http://schemas.openxmlformats.org/officeDocument/2006/extended-properties">\n <Application>EigenPal DOCX Editor</Application>\n <AppVersion>1.0.0</AppVersion>\n</Properties>'),e.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:6}})}async function Bt(e,t={}){if(!e.originalBuffer)throw new Error("Cannot repack document: no original buffer for round-trip. Use createDocx() for new documents.");let{compressionLevel:o=6,updateModifiedDate:r=!0,modifiedBy:n}=t,i=e,s=await at.loadAsync(e.originalBuffer),l=new at;for(let[c,h]of Object.entries(s.files)){if(h.dir){l.folder(c.replace(/\/$/,""));continue}let e=await h.async("arraybuffer");l.file(c,e,{compression:"DEFLATE",compressionOptions:{level:o}})}let a=ht(i);await yt(a,l,o),await bt(a,l,o);let p=_e(i);if(l.file("word/document.xml",p,{compression:"DEFLATE",compressionOptions:{level:o}}),At(i,l,o),await St(i,l,o),await Et(i,l,o),r){let e="docProps/core.xml",t=s.file(e);if(t){let i=await t.async("text"),s=Lt(i,{updateModifiedDate:r,modifiedBy:n});l.file(e,s,{compression:"DEFLATE",compressionOptions:{level:o}})}}return await l.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:o}})}function Lt(e,t){let o=e;if(t.updateModifiedDate){let e=(new Date).toISOString();o=o.includes("<dcterms:modified")?o.replace(/<dcterms:modified[^>]*>[^<]*<\/dcterms:modified>/,`<dcterms:modified xsi:type="dcterms:W3CDTF">${e}</dcterms:modified>`):o.replace("</cp:coreProperties>",`<dcterms:modified xsi:type="dcterms:W3CDTF">${e}</dcterms:modified></cp:coreProperties>`)}return t.modifiedBy&&(o=o.includes("<cp:lastModifiedBy")?o.replace(/<cp:lastModifiedBy>[^<]*<\/cp:lastModifiedBy>/,`<cp:lastModifiedBy>${n(t.modifiedBy)}</cp:lastModifiedBy>`):o.replace("</cp:coreProperties>",`<cp:lastModifiedBy>${n(t.modifiedBy)}</cp:lastModifiedBy></cp:coreProperties>`)),o}async function Ot(e){let t=await Dt(),o={...e,originalBuffer:t};return Bt(o)}}}]);
@@ -0,0 +1 @@
1
+ "use strict";(("undefined"!==typeof self?self:this)["webpackChunkFDocxEditor"]=("undefined"!==typeof self?self:this)["webpackChunkFDocxEditor"]||[]).push([[947],{1947:function(e,t,n){n.d(t,{injectReplyRangeMarkers:function(){return o},injectTCReplyRangeMarkers:function(){return f}});n(4423),n(4114),n(8111),n(2489),n(116),n(1701),n(3579),n(5367),n(2731),n(7642),n(8004),n(3853),n(5876),n(2475),n(5024),n(1698);function o(e,t){let n=t.filter(e=>null!=e.parentId);if(0===n.length)return;let o=new Map;for(let i of n){let e=o.get(i.parentId);e?e.push(i.id):o.set(i.parentId,[i.id])}function f(e){for(let t of e)if("paragraph"===t.type){if(!t.content.some(e=>"commentRangeStart"===e.type||"commentRangeEnd"===e.type))continue;let e=[];for(let n of t.content)if("commentRangeStart"===n.type){e.push(n);let t=o.get(n.id);if(t)for(let n of t)e.push({type:"commentRangeStart",id:n})}else if("commentRangeEnd"===n.type){e.push(n);let t=o.get(n.id);if(t)for(let n of t)e.push({type:"commentRangeEnd",id:n})}else e.push(n);t.content=e}else if("table"===t.type)for(let e of t.rows)for(let t of e.cells)f(t.content)}f(e)}function f(e,t){let n=new Set(t.map(e=>e.id)),o=t.filter(e=>null!=e.parentId&&!n.has(e.parentId));if(0===o.length)return;let f=new Map;for(let l of o){let e=f.get(l.parentId);e?e.push(l.id):f.set(l.parentId,[l.id])}function i(e){for(let t of e)if("paragraph"===t.type){if(!t.content.some(e=>("insertion"===e.type||"deletion"===e.type)&&f.has(e.info.id)))continue;let e=[],n=t.content;for(let t=0;t<n.length;t++){let o=n[t];if("insertion"!==o.type&&"deletion"!==o.type||!f.has(o.info.id))e.push(o);else{let i=f.get(o.info.id);for(let t of i)e.push({type:"commentRangeStart",id:t});e.push(o);let l=n[t+1];l&&("insertion"===l.type||"deletion"===l.type)&&l.type!==o.type&&l.info.author===o.info.author&&l.info.date===o.info.date&&(e.push(l),t++);for(let t of i)e.push({type:"commentRangeEnd",id:t})}}t.content=e}else if("table"===t.type)for(let e of t.rows)for(let t of e.cells)i(t.content)}i(e)}}}]);