@eigenpal/docx-editor-core 1.0.1 → 1.0.3

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.
Files changed (217) hide show
  1. package/README.md +1 -1
  2. package/dist/agent/index.d.mts +4 -4
  3. package/dist/agent/index.d.ts +4 -4
  4. package/dist/agent/index.js +1 -1
  5. package/dist/agent/index.mjs +1 -1
  6. package/dist/chunk-2IE6UDHJ.mjs +2 -0
  7. package/dist/chunk-3AZWLVLC.js +1 -0
  8. package/dist/chunk-3JXR6YU4.mjs +1 -0
  9. package/dist/{chunk-WNTT4MGC.js → chunk-3NLVHZMT.js} +3 -3
  10. package/dist/chunk-5SU4HPQS.mjs +1 -0
  11. package/dist/{chunk-LDAOONXZ.mjs → chunk-7PX32GLB.mjs} +1 -1
  12. package/dist/{chunk-AFMMYLPX.js → chunk-ABBG4WD2.js} +2 -2
  13. package/dist/chunk-AHXPHBMT.js +1 -0
  14. package/dist/chunk-B6LYBJ4H.mjs +1 -0
  15. package/dist/chunk-BFB4PRS4.mjs +1 -0
  16. package/dist/chunk-BRHHK4MG.mjs +2 -0
  17. package/dist/chunk-C2BAPYGJ.js +1 -0
  18. package/dist/chunk-CUXXRGPQ.mjs +1 -0
  19. package/dist/chunk-D536HC5M.js +2 -0
  20. package/dist/{chunk-GH5N36F7.js → chunk-D5E5TA74.js} +1 -1
  21. package/dist/chunk-EPX7BBJD.js +2 -0
  22. package/dist/chunk-EQVNAHL7.mjs +1 -0
  23. package/dist/{chunk-N3GIC2UI.mjs → chunk-EV6W6KXG.mjs} +1 -1
  24. package/dist/chunk-FCJWLEKT.mjs +1 -0
  25. package/dist/{chunk-DWFWYHM5.mjs → chunk-G7AKYAKU.mjs} +1 -1
  26. package/dist/{chunk-AGNZEOVL.mjs → chunk-GHQS3I2W.mjs} +1 -1
  27. package/dist/chunk-HAAMO2Z2.mjs +1 -0
  28. package/dist/chunk-HL5PQT3A.mjs +2 -0
  29. package/dist/chunk-IMKU4O3P.js +1 -0
  30. package/dist/chunk-IN6IYQ2X.js +1 -0
  31. package/dist/chunk-IO6HZ7KR.js +2 -0
  32. package/dist/{chunk-ZYESB4KC.mjs → chunk-LDKESXXK.mjs} +1 -1
  33. package/dist/chunk-LE67NTCN.mjs +1 -0
  34. package/dist/{chunk-WLQEPVDR.js → chunk-N3EIZN65.js} +1 -1
  35. package/dist/chunk-NO5LW2DQ.mjs +1 -0
  36. package/dist/chunk-OTDF6PZK.js +1 -0
  37. package/dist/chunk-QMLIXLZJ.mjs +4 -0
  38. package/dist/chunk-QVEAQOMR.mjs +2 -0
  39. package/dist/{chunk-GXW7YSFL.mjs → chunk-QXHL67FG.mjs} +1 -1
  40. package/dist/{chunk-UDPROEUK.js → chunk-SAFW7UQZ.js} +1 -1
  41. package/dist/chunk-TGPS3SRR.mjs +1 -0
  42. package/dist/chunk-TMISJEGL.js +1 -0
  43. package/dist/chunk-TRQN2SFW.mjs +59 -0
  44. package/dist/chunk-UGXSKZVM.js +1 -0
  45. package/dist/{chunk-CCWOLPZE.js → chunk-V435QKZB.js} +2 -2
  46. package/dist/chunk-V6SWUCTS.js +2 -0
  47. package/dist/chunk-X3NB7STJ.js +1 -0
  48. package/dist/{chunk-62NPHRTF.js → chunk-XBHF5Q2F.js} +1 -1
  49. package/dist/chunk-XBIKSAH6.js +1 -0
  50. package/dist/{chunk-SYJAAHUK.js → chunk-XOH7YAYL.js} +1 -1
  51. package/dist/{chunk-YUKBAAB5.mjs → chunk-XWQB6APW.mjs} +1 -1
  52. package/dist/chunk-Y7I5QDCN.mjs +1 -0
  53. package/dist/chunk-YCDB5TA6.js +4 -0
  54. package/dist/chunk-YVYB4YCI.js +1 -0
  55. package/dist/{chunk-KSYEBTYE.js → chunk-Z4SJCSTS.js} +1 -1
  56. package/dist/{colorResolver-CVsPLsw1.d.ts → colorResolver-BZ_yScf4.d.ts} +1 -1
  57. package/dist/{colorResolver-C3q7MLLD.d.mts → colorResolver-C6DtsoFI.d.mts} +1 -1
  58. package/dist/core-plugins.d.mts +3 -3
  59. package/dist/core-plugins.d.ts +3 -3
  60. package/dist/core-plugins.js +1 -1
  61. package/dist/core-plugins.mjs +1 -1
  62. package/dist/core.d.mts +6 -6
  63. package/dist/core.d.ts +6 -6
  64. package/dist/core.js +1 -1
  65. package/dist/core.mjs +1 -1
  66. package/dist/docx/index.d.mts +3 -3
  67. package/dist/docx/index.d.ts +3 -3
  68. package/dist/docx/index.js +1 -1
  69. package/dist/docx/index.mjs +1 -1
  70. package/dist/docx/parser.d.mts +3 -3
  71. package/dist/docx/parser.d.ts +3 -3
  72. package/dist/docx/parser.js +1 -1
  73. package/dist/docx/parser.mjs +1 -1
  74. package/dist/docx/rezip.d.mts +3 -3
  75. package/dist/docx/rezip.d.ts +3 -3
  76. package/dist/docx/rezip.js +1 -1
  77. package/dist/docx/rezip.mjs +1 -1
  78. package/dist/docx/serializer/index.d.mts +3 -3
  79. package/dist/docx/serializer/index.d.ts +3 -3
  80. package/dist/docx/serializer/index.js +1 -1
  81. package/dist/docx/serializer/index.mjs +1 -1
  82. package/dist/{formatting-D9I-lFS4.d.mts → formatting-BH4hcZiq.d.mts} +1 -1
  83. package/dist/{formatting-BwpZWdGi.d.ts → formatting-_OXU8gLB.d.ts} +1 -1
  84. package/dist/{headerFooterLayout-B3QVg556.d.ts → headerFooterLayout-B5LyDpSM.d.ts} +20 -1
  85. package/dist/{headerFooterLayout-DkclHZ0Z.d.mts → headerFooterLayout-DVFcJ832.d.mts} +20 -1
  86. package/dist/headless.d.mts +5 -5
  87. package/dist/headless.d.ts +5 -5
  88. package/dist/headless.js +1 -1
  89. package/dist/headless.mjs +1 -1
  90. package/dist/layout-bridge/index.d.mts +5 -5
  91. package/dist/layout-bridge/index.d.ts +5 -5
  92. package/dist/layout-bridge/index.js +1 -1
  93. package/dist/layout-bridge/index.mjs +1 -1
  94. package/dist/layout-bridge/measuring/index.d.mts +39 -2
  95. package/dist/layout-bridge/measuring/index.d.ts +39 -2
  96. package/dist/layout-bridge/measuring/index.js +1 -1
  97. package/dist/layout-bridge/measuring/index.mjs +1 -1
  98. package/dist/layout-bridge/tableInsertHover.js +1 -1
  99. package/dist/layout-bridge/tableInsertHover.mjs +1 -1
  100. package/dist/layout-bridge/toFlowBlocks.d.mts +10 -3
  101. package/dist/layout-bridge/toFlowBlocks.d.ts +10 -3
  102. package/dist/layout-bridge/toFlowBlocks.js +1 -1
  103. package/dist/layout-bridge/toFlowBlocks.mjs +1 -1
  104. package/dist/layout-engine/index.d.mts +30 -3
  105. package/dist/layout-engine/index.d.ts +30 -3
  106. package/dist/layout-engine/index.js +1 -1
  107. package/dist/layout-engine/index.mjs +1 -1
  108. package/dist/layout-engine/types.d.mts +9 -0
  109. package/dist/layout-engine/types.d.ts +9 -0
  110. package/dist/layout-painter/index.d.mts +4 -4
  111. package/dist/layout-painter/index.d.ts +4 -4
  112. package/dist/layout-painter/index.js +1 -1
  113. package/dist/layout-painter/index.mjs +1 -1
  114. package/dist/layout-painter/renderPage.d.mts +4 -4
  115. package/dist/layout-painter/renderPage.d.ts +4 -4
  116. package/dist/layout-painter/renderPage.js +1 -1
  117. package/dist/layout-painter/renderPage.mjs +1 -1
  118. package/dist/{lists-JDB80qyP.d.mts → lists-CvG_iVK3.d.mts} +8 -2
  119. package/dist/{lists-CdiIk_c1.d.ts → lists-UTp_tk7B.d.ts} +8 -2
  120. package/dist/managers/AutoSaveManager.d.mts +3 -3
  121. package/dist/managers/AutoSaveManager.d.ts +3 -3
  122. package/dist/managers/TableSelectionManager.d.mts +3 -3
  123. package/dist/managers/TableSelectionManager.d.ts +3 -3
  124. package/dist/managers/types.d.mts +3 -3
  125. package/dist/managers/types.d.ts +3 -3
  126. package/dist/{marks-CCPVlQzL.d.mts → marks-BY573yZn.d.mts} +1 -1
  127. package/dist/{marks-BujVxYP4.d.ts → marks-CjC9tF5k.d.ts} +1 -1
  128. package/dist/mcp-cli.mjs +23 -23
  129. package/dist/mcp.d.mts +3 -3
  130. package/dist/mcp.d.ts +3 -3
  131. package/dist/mcp.js +3 -3
  132. package/dist/mcp.mjs +1 -1
  133. package/dist/{nodes-BXi1Uu3e.d.mts → nodes-CL8M0L-a.d.mts} +4 -2
  134. package/dist/{nodes-DfKj9kUA.d.ts → nodes-D7PTUJ2N.d.ts} +4 -2
  135. package/dist/prosemirror/commands/formatting.d.mts +2 -2
  136. package/dist/prosemirror/commands/formatting.d.ts +2 -2
  137. package/dist/prosemirror/commands/formatting.js +1 -1
  138. package/dist/prosemirror/commands/formatting.mjs +1 -1
  139. package/dist/prosemirror/commands/index.d.mts +2 -2
  140. package/dist/prosemirror/commands/index.d.ts +2 -2
  141. package/dist/prosemirror/commands/index.js +1 -1
  142. package/dist/prosemirror/commands/index.mjs +1 -1
  143. package/dist/prosemirror/commands/paragraph.d.mts +1 -1
  144. package/dist/prosemirror/commands/paragraph.d.ts +1 -1
  145. package/dist/prosemirror/commands/paragraph.js +1 -1
  146. package/dist/prosemirror/commands/paragraph.mjs +1 -1
  147. package/dist/prosemirror/conversion/fromProseDoc.d.mts +3 -3
  148. package/dist/prosemirror/conversion/fromProseDoc.d.ts +3 -3
  149. package/dist/prosemirror/conversion/fromProseDoc.js +1 -1
  150. package/dist/prosemirror/conversion/fromProseDoc.mjs +1 -1
  151. package/dist/prosemirror/conversion/index.d.mts +11 -3
  152. package/dist/prosemirror/conversion/index.d.ts +11 -3
  153. package/dist/prosemirror/conversion/index.js +1 -1
  154. package/dist/prosemirror/conversion/index.mjs +1 -1
  155. package/dist/prosemirror/extensions/index.d.mts +1 -1
  156. package/dist/prosemirror/extensions/index.d.ts +1 -1
  157. package/dist/prosemirror/extensions/index.js +1 -1
  158. package/dist/prosemirror/extensions/index.mjs +1 -1
  159. package/dist/prosemirror/index.d.mts +5 -5
  160. package/dist/prosemirror/index.d.ts +5 -5
  161. package/dist/prosemirror/index.js +1 -1
  162. package/dist/prosemirror/index.mjs +1 -1
  163. package/dist/prosemirror/plugins/index.d.mts +1 -1
  164. package/dist/prosemirror/plugins/index.d.ts +1 -1
  165. package/dist/prosemirror/plugins/selectionTracker.d.mts +1 -1
  166. package/dist/prosemirror/plugins/selectionTracker.d.ts +1 -1
  167. package/dist/prosemirror/schema/index.d.mts +4 -4
  168. package/dist/prosemirror/schema/index.d.ts +4 -4
  169. package/dist/prosemirror/schema/index.js +1 -1
  170. package/dist/prosemirror/schema/index.mjs +1 -1
  171. package/dist/prosemirror/styles/index.d.mts +2 -2
  172. package/dist/prosemirror/styles/index.d.ts +2 -2
  173. package/dist/prosemirror/utils/extractTrackedChanges.d.mts +2 -2
  174. package/dist/prosemirror/utils/extractTrackedChanges.d.ts +2 -2
  175. package/dist/{selectionContext-85CE0f7a.d.ts → selectionContext-BPAqgNgk.d.ts} +1 -1
  176. package/dist/{selectionContext-Xq3AY7pn.d.mts → selectionContext-CoZat7QZ.d.mts} +1 -1
  177. package/dist/{styles-jqO45PSq.d.ts → styles-BBv7doYK.d.ts} +1 -1
  178. package/dist/{styles-BBoqh07F.d.mts → styles-EI2lxeEN.d.mts} +1 -1
  179. package/dist/types/agentApi.d.mts +1 -1
  180. package/dist/types/agentApi.d.ts +1 -1
  181. package/dist/types/content.d.mts +2 -2
  182. package/dist/types/content.d.ts +2 -2
  183. package/dist/types/document.d.mts +25 -6
  184. package/dist/types/document.d.ts +25 -6
  185. package/dist/utils/comments.d.mts +2 -2
  186. package/dist/utils/comments.d.ts +2 -2
  187. package/dist/utils/index.d.mts +4 -4
  188. package/dist/utils/index.d.ts +4 -4
  189. package/package.json +1 -1
  190. package/dist/chunk-3GNIP6IX.mjs +0 -4
  191. package/dist/chunk-44RUAQA2.js +0 -1
  192. package/dist/chunk-4EHBV73E.mjs +0 -59
  193. package/dist/chunk-5N5DBQJV.mjs +0 -1
  194. package/dist/chunk-6LOYA7G5.mjs +0 -2
  195. package/dist/chunk-6VUYFDHY.mjs +0 -1
  196. package/dist/chunk-7UTXBQKF.mjs +0 -1
  197. package/dist/chunk-7VCMJCBY.js +0 -2
  198. package/dist/chunk-BD4CYYFB.js +0 -1
  199. package/dist/chunk-C6GSFUV2.js +0 -2
  200. package/dist/chunk-DFZTUQ7O.js +0 -2
  201. package/dist/chunk-DN36K5JU.mjs +0 -1
  202. package/dist/chunk-DV6IEOP5.js +0 -4
  203. package/dist/chunk-GNPLUGUG.mjs +0 -1
  204. package/dist/chunk-HVZMO3BU.js +0 -1
  205. package/dist/chunk-IBNUQL57.mjs +0 -2
  206. package/dist/chunk-ITVXBQGR.mjs +0 -1
  207. package/dist/chunk-JKVXID22.mjs +0 -1
  208. package/dist/chunk-LVD6HXRF.mjs +0 -2
  209. package/dist/chunk-NFYCMDM5.js +0 -1
  210. package/dist/chunk-O5X22KZ6.mjs +0 -1
  211. package/dist/chunk-PK4PDRTA.js +0 -1
  212. package/dist/chunk-R7RR6M4A.mjs +0 -2
  213. package/dist/chunk-RSMS6OTE.mjs +0 -1
  214. package/dist/chunk-SUXJX72X.js +0 -1
  215. package/dist/chunk-T4CPTPRP.js +0 -1
  216. package/dist/chunk-TZJUO3NW.js +0 -1
  217. package/dist/chunk-YGHHSCPR.js +0 -2
@@ -0,0 +1 @@
1
+ import {a as a$1,b as b$2}from'./chunk-LBKMYD3M.mjs';import {b}from'./chunk-NBLJPT54.mjs';import {b as b$4}from'./chunk-QPFJJPIC.mjs';import {a}from'./chunk-ILJUDEZ5.mjs';import {b as b$1}from'./chunk-TGPS3SRR.mjs';import {b as b$3}from'./chunk-67LVRQIR.mjs';import {e}from'./chunk-VW22RZ6C.mjs';function _(e){if(!e)return [];let n=[];return e.bold&&n.push(b$1.mark("bold")),e.italic&&n.push(b$1.mark("italic")),e.underline&&e.underline.style!=="none"&&n.push(b$1.mark("underline",{style:e.underline.style,color:e.underline.color})),(e.strike||e.doubleStrike)&&n.push(b$1.mark("strike",{double:e.doubleStrike||false})),e.color&&!e.color.auto&&n.push(b$1.mark("textColor",{rgb:e.color.rgb,themeColor:e.color.themeColor,themeTint:e.color.themeTint,themeShade:e.color.themeShade})),e.highlight&&e.highlight!=="none"&&n.push(b$1.mark("highlight",{color:e.highlight})),e.fontSize&&n.push(b$1.mark("fontSize",{size:e.fontSize})),e.fontFamily&&n.push(b$1.mark("fontFamily",{ascii:e.fontFamily.ascii,hAnsi:e.fontFamily.hAnsi,eastAsia:e.fontFamily.eastAsia,cs:e.fontFamily.cs,asciiTheme:e.fontFamily.asciiTheme,hAnsiTheme:e.fontFamily.hAnsiTheme,eastAsiaTheme:e.fontFamily.eastAsiaTheme,csTheme:e.fontFamily.csTheme})),e.vertAlign==="superscript"?n.push(b$1.mark("superscript")):e.vertAlign==="subscript"&&n.push(b$1.mark("subscript")),e.allCaps&&n.push(b$1.mark("allCaps")),e.smallCaps&&n.push(b$1.mark("smallCaps")),(e.spacing!=null||e.position!=null||e.scale!=null||e.kerning!=null)&&n.push(b$1.mark("characterSpacing",{spacing:e.spacing??null,position:e.position??null,scale:e.scale??null,kerning:e.kerning??null})),e.emboss&&n.push(b$1.mark("emboss")),e.imprint&&n.push(b$1.mark("imprint")),e.shadow&&n.push(b$1.mark("textShadow")),e.emphasisMark&&e.emphasisMark!=="none"&&n.push(b$1.mark("emphasisMark",{type:e.emphasisMark})),e.outline&&n.push(b$1.mark("textOutline")),e.hidden&&n.push(b$1.mark("hidden")),e.rtl&&n.push(b$1.mark("rtl")),e.effect&&e.effect!=="none"&&n.push(b$1.mark("textEffect",{effect:e.effect})),n}function A(e,n){if(!e)return;if(!n)return e;let r=n.resolveRunStyle(e.styleId);return r?a(r,e):e}function ee(e,n){let r="",i,t=e.type==="simpleField"?e.content:e.fieldResult;if(t){for(let s of t)if(s.type==="run"){for(let f of s.content)f.type==="text"&&(r+=f.text);!i&&s.formatting&&(i=s.formatting);}}let l=a(n,i),o=_(l);return b$1.node("field",{fieldType:e.fieldType,instruction:e.instruction,displayText:r,fieldKind:e.type==="simpleField"?"simple":"complex",fldLock:e.fldLock??false,dirty:e.dirty??false},void 0,o)}function te(e){return b$1.node("math",{display:e.display,ommlXml:e.ommlXml,plainText:e.plainText||""})}function q(e,n,r){let i=[],t=e.formatting?.styleId?r?.getRunStyleOwnProperties(e.formatting.styleId):void 0,l=a(a(n,t),e.formatting),o=_(l);for(let s of e.content){let f=fe(s,o);i.push(...f);}return i}function fe(e,n){switch(e.type){case "text":return e.text?[b$1.text(e.text,n)]:[];case "break":return e.breakType==="textWrapping"||!e.breakType?[b$1.node("hardBreak",null,void 0,n)]:[];case "tab":return [b$1.node("tab",null,void 0,n)];case "drawing":return e.image?[Te(e.image)]:[];case "shape":{let t=e.shape;return t.textBody&&t.textBody.content.length>0?[]:[be(t)]}case "footnoteRef":let r=b$1.mark("footnoteRef",{id:e.id.toString(),noteType:"footnote"});return [b$1.text(e.id.toString(),[...n,r])];case "endnoteRef":let i=b$1.mark("footnoteRef",{id:e.id.toString(),noteType:"endnote"});return [b$1.text(e.id.toString(),[...n,i])];default:return []}}function Te(e$1){let n=e$1.size?.width?e(e$1.size.width):void 0,r=e$1.size?.height?e(e$1.size.height):void 0,i=e$1.wrap.type,t=e$1.wrap.wrapText,l=e$1.position?.horizontal?.alignment,o;i==="inline"||i==="topAndBottom"?o="none":i==="square"||i==="tight"||i==="through"?t==="left"?o="right":t==="right"||l==="left"?o="left":l==="right"?o="right":o="none":o="none";let s="inline";i==="inline"?s="inline":i==="topAndBottom"?s="block":b$4(i)||o&&o!=="none"?s="float":s="block";let f;if(e$1.transform){let P=[];e$1.transform.rotation&&P.push(`rotate(${e$1.transform.rotation}deg)`),e$1.transform.flipH&&P.push("scaleX(-1)"),e$1.transform.flipV&&P.push("scaleY(-1)"),P.length>0&&(f=P.join(" "));}let p=e$1.wrap.distT?e(e$1.wrap.distT):void 0,c=e$1.wrap.distB?e(e$1.wrap.distB):void 0,d=e$1.wrap.distL?e(e$1.wrap.distL):void 0,m=e$1.wrap.distR?e(e$1.wrap.distR):void 0,u;e$1.position&&(u={horizontal:e$1.position.horizontal?{relativeTo:e$1.position.horizontal.relativeTo,posOffset:e$1.position.horizontal.posOffset,align:e$1.position.horizontal.alignment}:void 0,vertical:e$1.position.vertical?{relativeTo:e$1.position.vertical.relativeTo,posOffset:e$1.position.vertical.posOffset,align:e$1.position.vertical.alignment}:void 0});let w,k,v;if(e$1.outline&&e$1.outline.width){w=Math.round(e$1.outline.width/914400*96*100)/100,e$1.outline.color?.rgb&&(k=`#${e$1.outline.color.rgb}`);let P={solid:"solid",dot:"dotted",dash:"dashed",lgDash:"dashed",dashDot:"dashed",lgDashDot:"dashed",lgDashDotDot:"dashed",sysDot:"dotted",sysDash:"dashed",sysDashDot:"dashed",sysDashDotDot:"dashed"};v=e$1.outline.style&&P[e$1.outline.style]||"solid";}let N=e$1.padding?.top?e(e$1.padding.top):void 0,R=e$1.padding?.bottom?e(e$1.padding.bottom):void 0,B=e$1.padding?.left?e(e$1.padding.left):void 0,h=e$1.padding?.right?e(e$1.padding.right):void 0;return b$1.node("image",{src:e$1.src||"",alt:e$1.alt,title:e$1.title,width:n,height:r,rId:e$1.rId,wrapType:i,displayMode:s,cssFloat:o,transform:f,distTop:p,distBottom:c,distLeft:d,distRight:m,position:u,borderWidth:w,borderColor:k,borderStyle:v,wrapText:t,hlinkHref:e$1.hlinkHref,cropTop:e$1.crop?.top,cropRight:e$1.crop?.right,cropBottom:e$1.crop?.bottom,cropLeft:e$1.crop?.left,opacity:e$1.opacity,effectExtentTop:N,effectExtentBottom:R,effectExtentLeft:B,effectExtentRight:h,layoutInCell:e$1.layoutInCell,allowOverlap:e$1.allowOverlap})}function j(e,n,r){let i=[],t=e.href||(e.anchor?`#${e.anchor}`:""),l=b$1.mark("hyperlink",{href:t,tooltip:e.tooltip,rId:e.rId});for(let o of e.children)if(o.type==="run"){let s=o.formatting?.styleId?r?.getRunStyleOwnProperties(o.formatting.styleId):void 0,f=a(a(n,s),o.formatting),c=[..._(f),l];for(let d of o.content)i.push(...fe(d,c));}return i}function be(e$1){let n=e$1.size?.width?e(e$1.size.width):100,r=e$1.size?.height?e(e$1.size.height):80,i,t="solid",l,o,s;if(e$1.fill&&(t=e$1.fill.type,e$1.fill.color?.rgb&&(i=`#${e$1.fill.color.rgb}`),e$1.fill.type==="gradient"&&e$1.fill.gradient)){let m=e$1.fill.gradient;l=m.type,o=m.angle,s=JSON.stringify(m.stops.map(u=>({position:u.position,color:u.color.rgb?`#${u.color.rgb}`:"#000000"})));}let f,p,c;e$1.outline&&(e$1.outline.width&&(f=Math.round(e$1.outline.width/914400*96*100)/100),e$1.outline.color?.rgb&&(p=`#${e$1.outline.color.rgb}`),c=e$1.outline.style||"solid");let d;if(e$1.transform){let m=[];e$1.transform.rotation&&m.push(`rotate(${e$1.transform.rotation}deg)`),e$1.transform.flipH&&m.push("scaleX(-1)"),e$1.transform.flipV&&m.push("scaleY(-1)"),m.length>0&&(d=m.join(" "));}return b$1.node("shape",{shapeType:e$1.shapeType||"rect",shapeId:e$1.id,width:n,height:r,fillColor:i,fillType:t,gradientType:l,gradientAngle:o,gradientStops:s,outlineWidth:f,outlineColor:p,outlineStyle:c,transform:d})}function E(e,n,r,i){let t=Pe(e,n),l=[],o,s=new Set,f;n&&(f=n.resolveParagraphStyle(e.formatting?.styleId).runFormatting);let p=a(f,i);for(let c of e.content){if(c.type==="commentRangeStart")s.add(c.id);else if(c.type==="commentRangeEnd")s.delete(c.id);else if(c.type==="run"){let d=q(c,p,n);s.size>0&&(d=D(d,s)),l.push(...d);}else if(c.type==="hyperlink"){let d=j(c,p,n);l.push(...d);}else if(c.type==="simpleField"||c.type==="complexField"){let d=ee(c,p);d&&l.push(d);}else if(c.type==="inlineSdt"){let d=ce(c,p,n);d&&l.push(d);}else if(c.type==="insertion"){let d=X(c,"insertion",p,n);s.size>0&&(d=D(d,s)),l.push(...d);}else if(c.type==="deletion"){let d=X(c,"deletion",p,n);s.size>0&&(d=D(d,s)),l.push(...d);}else if(c.type==="moveFrom"){let d=X(c,"deletion",p,n);s.size>0&&(d=D(d,s)),l.push(...d);}else if(c.type==="moveTo"){let d=X(c,"insertion",p,n);s.size>0&&(d=D(d,s)),l.push(...d);}else if(c.type==="mathEquation"){let d=te(c);d&&l.push(d);}c.type==="bookmarkStart"&&(o||(o=[]),o.push({id:c.id,name:c.name}));}return o&&(t.bookmarks=o),b$1.node("paragraph",t,l)}function D(e,n){if(n.size===0)return e;let r=[...n][0],i=b$1.marks.comment.create({commentId:r});return e.map(t=>t.isText?t.mark(i.addToSet(t.marks)):t)}function X(e,n,r,i){let t=[];for(let o of e.content)o.type==="run"?t.push(...q(o,r,i)):o.type==="hyperlink"&&t.push(...j(o,r,i));let l=b$1.marks[n].create({revisionId:e.info.id,author:e.info.author,date:e.info.date??null});return t.map(o=>o.isText?o.mark(l.addToSet(o.marks)):o)}function Pe(e,n){let r=e.formatting,i=r?.styleId,t={paraId:e.paraId??void 0,textId:e.textId??void 0,styleId:i,numPr:r?.numPr,listNumFmt:e.listRendering?.numFmt,listIsBullet:e.listRendering?.isBullet,listMarker:e.listRendering?.marker,listMarkerHidden:e.listRendering?.markerHidden||void 0,listMarkerFontFamily:e.listRendering?.markerFontFamily||void 0,listMarkerFontSize:e.listRendering?.markerFontSize||void 0,listMarkerSuffix:e.listRendering?.markerSuffix||void 0,listLevelNumFmts:e.listRendering?.levelNumFmts||void 0,listAbstractNumId:e.listRendering?.abstractNumId,listStartOverride:e.listRendering?.startOverride,_originalFormatting:r||void 0};if(n){let l=n.resolveParagraphStyle(i),o=l.paragraphFormatting,s=l.runFormatting;t.alignment=r?.alignment??o?.alignment,t.spaceBefore=r?.spaceBefore??o?.spaceBefore,t.spaceAfter=r?.spaceAfter??o?.spaceAfter,t.lineSpacing=r?.lineSpacing??o?.lineSpacing,t.lineSpacingRule=r?.lineSpacingRule??o?.lineSpacingRule,r?.spacingExplicit&&(t.spacingExplicit=r.spacingExplicit),t.indentLeft=r?.indentLeft??o?.indentLeft,t.indentRight=r?.indentRight??o?.indentRight,t.indentFirstLine=r?.indentFirstLine??o?.indentFirstLine,t.hangingIndent=r?.hangingIndent??o?.hangingIndent,t.borders=r?.borders??o?.borders,t.shading=r?.shading??o?.shading,t.tabs=r?.tabs??o?.tabs,t.pageBreakBefore=r?.pageBreakBefore??o?.pageBreakBefore,t.keepNext=r?.keepNext??o?.keepNext,t.keepLines=r?.keepLines??o?.keepLines,t.contextualSpacing=r?.contextualSpacing??o?.contextualSpacing,t.outlineLevel=r?.outlineLevel??o?.outlineLevel,t.bidi=r?.bidi??o?.bidi;let f=n.getDefaultCharacterStyle()?.rPr,p=f?a(s,f):s,c=A(r?.runProperties,n);t.defaultTextFormatting=a(p,c),!r?.numPr&&o?.numPr&&o.numPr.numId!==0&&(t.numPr=o.numPr);}else t.alignment=r?.alignment,t.spaceBefore=r?.spaceBefore,t.spaceAfter=r?.spaceAfter,t.lineSpacing=r?.lineSpacing,t.lineSpacingRule=r?.lineSpacingRule,r?.spacingExplicit&&(t.spacingExplicit=r.spacingExplicit),t.indentLeft=r?.indentLeft,t.indentRight=r?.indentRight,t.indentFirstLine=r?.indentFirstLine,t.hangingIndent=r?.hangingIndent,t.borders=r?.borders,t.shading=r?.shading,t.tabs=r?.tabs,t.pageBreakBefore=r?.pageBreakBefore,t.keepNext=r?.keepNext,t.keepLines=r?.keepLines,t.outlineLevel=r?.outlineLevel,t.bidi=r?.bidi,t.defaultTextFormatting=A(r?.runProperties,n);if(e.sectionProperties){t._sectionProperties=e.sectionProperties;let l=e.sectionProperties.sectionStart;(l==="nextPage"||l==="continuous"||l==="oddPage"||l==="evenPage")&&(t.sectionBreakType=l);}return e.renderedPageBreakBefore&&(t.renderedPageBreakBefore=true),t}function ce(e,n,r){let i=e.properties,t=[];for(let l of e.content)if(l.type==="run"){let o=q(l,n,r);t.push(...o);}else if(l.type==="hyperlink"){let o=j(l,n,r);t.push(...o);}else if(l.type==="simpleField"||l.type==="complexField"){let o=ee(l,n);o&&t.push(o);}else if(l.type==="inlineSdt"){let o=ce(l,n,r);o&&t.push(o);}else if(l.type==="mathEquation"){let o=te(l);o&&t.push(o);}return b$1.node("sdt",{sdtType:i.sdtType,alias:i.alias??null,tag:i.tag??null,lock:i.lock??null,placeholder:i.placeholder??null,showingPlaceholder:i.showingPlaceholder??false,dateFormat:i.dateFormat??null,listItems:i.listItems?JSON.stringify(i.listItems):null,checked:i.checked??null},t.length>0?t:void 0)}function ue(e){function n(i){return i.type==="break"&&i.breakType==="page"}function r(i){if(i.type==="run"){for(let t of i.content)if(n(t))return true;return false}if(i.type==="hyperlink"){for(let t of i.children)if(t.type==="run"&&r(t))return true;return false}if(i.type==="insertion"||i.type==="deletion"){let t=i;for(let l of t.content)if(r(l))return true;return false}return false}for(let i of e.content)if(r(i))return true;return false}function x(e,n,r){if(!e||!n)return;let i=e.getStyle(n);if(!i?.tblStylePr)return;let t=i.tblStylePr.find(f=>f.type===r);if(!t)return;let l=A(t.pPr?.runProperties,e),o=A(t.rPr,e),s=a(l,o);return {tcPr:t.tcPr,rPr:s}}function M(e,n){if(!e&&!n)return;if(!e)return n;if(!n)return e;let r={},i=e.tcPr,t=n.tcPr;if(i||t){let l={...i??{},...t??{}};(i?.borders||t?.borders)&&(l.borders={...i?.borders??{},...t?.borders??{}}),(i?.shading||t?.shading)&&(l.shading={...i?.shading??{},...t?.shading??{}}),(i?.margins||t?.margins)&&(l.margins={...i?.margins??{},...t?.margins??{}}),r.tcPr=l;}return r.rPr=a(e.rPr,n.rPr),r}function ye(e){let n=new Map,r=e.rows.length,i=new Map;for(let t=0;t<r;t++){let l=e.rows[t],o=0;for(let s=0;s<l.cells.length;s++){let f=l.cells[s],p=f.formatting?.gridSpan??1,c=f.formatting?.vMerge,d=`${t}-${o}`;if(c==="restart")i.set(o,t),n.set(d,{rowSpan:1,skip:false});else if(c==="continue"){let m=i.get(o);if(m!==void 0){let u=`${m}-${o}`,w=n.get(u);w&&w.rowSpan++;}n.set(d,{rowSpan:1,skip:true});}else i.delete(o),n.set(d,{rowSpan:1,skip:false});o+=p;}}return n}function K(e,n,r){let i=ye(e),t=e.columnWidths,l=t?.reduce((P,S)=>P+S,0)??0,o=e.formatting?.styleId,s=e.formatting?.look,f=o?n?.getStyle(o):void 0,p=n?.getDefaultTableStyle(),c=e.formatting?.borders??f?.tblPr?.borders??p?.tblPr?.borders,d=e.formatting?.cellMargins??f?.tblPr?.cellMargins??p?.tblPr?.cellMargins??void 0,m=d?{top:d.top?.value,bottom:d.bottom?.value,left:d.left?.value,right:d.right?.value}:void 0,u={styleId:e.formatting?.styleId,width:e.formatting?.width?.value,widthType:e.formatting?.width?.type,justification:e.formatting?.justification,columnWidths:t,floating:e.formatting?.floating,cellMargins:m,look:e.formatting?.look,_originalFormatting:e.formatting||void 0},w={wholeTable:x(n,o,"wholeTable"),firstRow:x(n,o,"firstRow"),lastRow:x(n,o,"lastRow"),firstCol:x(n,o,"firstCol"),lastCol:x(n,o,"lastCol"),band1Horz:x(n,o,"band1Horz"),band2Horz:x(n,o,"band2Horz"),band1Vert:x(n,o,"band1Vert"),band2Vert:x(n,o,"band2Vert"),nwCell:x(n,o,"nwCell"),neCell:x(n,o,"neCell"),swCell:x(n,o,"swCell"),seCell:x(n,o,"seCell")},k=s?.noHBand!==true,v=s?.noVBand!==true,N=0,R=e.rows.length,B=t?.length??Math.max(0,...e.rows.map(P=>P.cells.reduce((S,F)=>S+(F.formatting?.gridSpan??1),0))),h=e.rows.map((P,S)=>{let F=S===0&&!!s?.firstRow,C=S===R-1&&!!s?.lastRow,I=k&&!F&&!C?N%2===0?w.band1Horz:w.band2Horz:void 0;return k&&!F&&!C&&N++,we(P,n,F,t,l,w,I,v,s,c,S,R,B,i,m,r)});return b$1.node("table",u,h)}function we(e,n,r,i,t,l,o,s,f,p,c,d,m,u,w,k){let v={height:e.formatting?.height?.value,heightRule:e.formatting?.heightRule,isHeader:!!e.formatting?.header,_originalFormatting:e.formatting||void 0},N=e.cells.length,R=c===0,B=c===(d??1)-1,h=e.formatting?.conditionalFormat,P=h?.firstRow??R,S=h?.lastRow??B,F=m??N,C=0,I=[];for(let J=0;J<e.cells.length;J++){let Y=e.cells[J],L=Y.formatting?.gridSpan??1,me=`${c??0}-${C}`,oe=u?.get(me),he=oe?.skip??false,ge=oe?.rowSpan??1,re;if(i&&t&&t>0){let W=0;for(let z=0;z<L&&C+z<i.length;z++)W+=i[C+z];re=Math.round(W/t*100);}if(C+=L,he)continue;let ie=C-L===0,le=C===F,T=Y.formatting?.conditionalFormat,G=T?.firstRow??P,Q=T?.lastRow??S,O=T?.firstColumn??ie,V=T?.lastColumn??le,$;if(s){let W=f?.firstColumn?1:0,z=C-L-W;z>=0&&!(f?.lastColumn&&V)&&!(f?.firstColumn&&O)&&($=z%2===0?l?.band1Vert:l?.band2Vert);}T?.oddVBand?$=l?.band1Vert:T?.evenVBand&&($=l?.band2Vert);let H=o;h?.oddHBand?H=l?.band1Horz:h?.evenHBand&&(H=l?.band2Horz),T?.oddHBand?H=l?.band1Horz:T?.evenHBand&&(H=l?.band2Horz);let g=l?.wholeTable;g=M(g,H),g=M(g,$),G&&(f?.firstRow||h?.firstRow||T?.firstRow)&&(g=M(g,l?.firstRow)),Q&&(f?.lastRow||h?.lastRow||T?.lastRow)&&(g=M(g,l?.lastRow)),O&&(f?.firstColumn||h?.firstColumn||T?.firstColumn)&&(g=M(g,l?.firstCol)),V&&(f?.lastColumn||h?.lastColumn||T?.lastColumn)&&(g=M(g,l?.lastCol)),G&&O&&(f?.firstRow||h?.firstRow||T?.firstRow)&&(f?.firstColumn||h?.firstColumn||T?.firstColumn)&&(g=M(g,l?.nwCell)),G&&V&&(f?.firstRow||h?.firstRow||T?.firstRow)&&(f?.lastColumn||h?.lastColumn||T?.lastColumn)&&(g=M(g,l?.neCell)),Q&&O&&(f?.lastRow||h?.lastRow||T?.lastRow)&&(f?.firstColumn||h?.firstColumn||T?.firstColumn)&&(g=M(g,l?.swCell)),Q&&V&&(f?.lastRow||h?.lastRow||T?.lastRow)&&(f?.lastColumn||h?.lastColumn||T?.lastColumn)&&(g=M(g,l?.seCell)),I.push(Ce(Y,n,r,re,g,p,R,B,ie,le,ge,w,k));}return b$1.node("tableRow",v,I)}var Fe=["top","bottom","left","right","insideH","insideV"];function xe(e,n){if(!e)return e;let r;for(let i of Fe){let t=e[i];if(!t?.color?.themeColor||t.color.auto)continue;let l=b$3(t.color,n);l&&(r??(r={...e}),r[i]={...t,color:{rgb:l}});}return r??e}function Ce(e,n,r,i,t,l,o,s,f,p,c,d,m){let u=e.formatting,w=c??1,k=u?.width?.value,v=u?.width?.type;k===void 0&&i!==void 0&&(k=i,v="pct");let N=b$3(u?.shading?.fill??t?.tcPr?.shading?.fill,m),R=l?{top:o?l.top:l.insideH,bottom:s?l.bottom:l.insideH,left:f?l.left:l.insideV,right:p?l.right:l.insideV}:void 0,B=t?.tcPr?.borders,h=u?.borders,P=xe(R||B||h?{...R??{},...B??{},...h??{}}:void 0,m),S={colspan:u?.gridSpan??1,rowspan:w,width:k,widthType:v,verticalAlign:u?.verticalAlign,backgroundColor:N,textDirection:u?.textDirection,noWrap:u?.noWrap,borders:P,margins:u?.margins?{top:u.margins.top?.value,bottom:u.margins.bottom?.value,left:u.margins.left?.value,right:u.margins.right?.value}:t?.tcPr?.margins?{top:t.tcPr.margins.top?.value,bottom:t.tcPr.margins.bottom?.value,left:t.tcPr.margins.left?.value,right:t.tcPr.margins.right?.value}:d,_originalFormatting:u||void 0,_originalResolvedFill:N},F=[];for(let I of e.content)I.type==="paragraph"?F.push(E(I,n,void 0,t?.rPr)):I.type==="table"&&F.push(K(I,n));F.length===0&&F.push(b$1.node("paragraph",{},[]));let C=r?"tableHeader":"tableCell";return b$1.node(C,S,F)}function ne(e,n){let r=Se(e),i=E(e,n),t=[],l=r.length>0&&i.content.size===0,{anchored:o,inFlow:s}=ke(r);for(let f of o)t.push(pe(f,n));l||t.push(i);for(let f of s)t.push(pe(f,n));return t}function ke(e){let n=[],r=[];for(let i of e)a$1(i)?n.push(i):r.push(i);return {anchored:n,inFlow:r}}function Se(e){let n=[];for(let r of e.content)if(r.type==="run"){for(let i of r.content)if(i.type==="shape"&&"shape"in i){let t=i.shape;t.textBody&&t.textBody.content.length>0&&n.push({type:"textBox",id:t.id,size:t.size,position:t.position,wrap:t.wrap,fill:t.fill,outline:t.outline,content:t.textBody.content,margins:t.textBody.margins});}}return n}function pe(e$1,n){let r=e$1.size?.width?e(e$1.size.width):200,i=e$1.size?.height?e(e$1.size.height):void 0,t;e$1.fill?.color?.rgb&&(t=`#${e$1.fill.color.rgb}`);let l,o,s;e$1.outline&&e$1.outline.width&&(l=Math.round(e$1.outline.width/914400*96*100)/100,e$1.outline.color?.rgb&&(o=`#${e$1.outline.color.rgb}`),s=e$1.outline.style||"solid");let f=e$1.margins?.top!=null?e(e$1.margins.top):4,p=e$1.margins?.bottom!=null?e(e$1.margins.bottom):4,c=e$1.margins?.left!=null?e(e$1.margins.left):7,d=e$1.margins?.right!=null?e(e$1.margins.right):7,m=[];for(let u of e$1.content)m.push(E(u,n));return m.length===0&&m.push(b$1.node("paragraph",{},[])),b$1.node("textBox",{width:r,height:i,textBoxId:e$1.id,fillColor:t,outlineWidth:l,outlineColor:o,outlineStyle:s,marginTop:f,marginBottom:p,marginLeft:c,marginRight:d,...b$2(e$1)},m)}function it(e,n){let r=e.package.document.content,i=[],t=e.package.theme??null,l=n?.styles?b(n.styles):null;for(let o of r)if(o.type==="paragraph")i.push(...ne(o,l)),ue(o)&&i.push(b$1.node("pageBreak"));else if(o.type==="table"){let s=K(o,l,t);i.push(s);}return i.length===0&&i.push(b$1.node("paragraph",{},[])),b$1.node("doc",{defaultTabStopTwips:e.package.settings?.defaultTabStop??null},i)}function Re(e,n){let r=[],i=n?.styles?b(n.styles):null,t=n?.theme??null;for(let l of e)l.type==="paragraph"?r.push(...ne(l,i)):l.type==="table"&&r.push(K(l,i,t));return r.length===0&&r.push(b$1.node("paragraph",{},[])),b$1.node("doc",{defaultTabStopTwips:n?.defaultTabStopTwips??null},r)}function lt(e,n){return Re(e,n)}function st(){return b$1.node("doc",null,[b$1.node("paragraph",{},[])])}export{it as a,Re as b,lt as c,st as d};
@@ -0,0 +1 @@
1
+ 'use strict';var chunk3AZWLVLC_js=require('./chunk-3AZWLVLC.js'),chunkUGXSKZVM_js=require('./chunk-UGXSKZVM.js'),chunkXBIKSAH6_js=require('./chunk-XBIKSAH6.js'),chunkDROCYKAR_js=require('./chunk-DROCYKAR.js'),chunkYCDB5TA6_js=require('./chunk-YCDB5TA6.js'),chunkX3NB7STJ_js=require('./chunk-X3NB7STJ.js'),chunkBHBOAP6Z_js=require('./chunk-BHBOAP6Z.js'),chunkN3Y5BUKV_js=require('./chunk-N3Y5BUKV.js'),chunk4Q2IP5FW_js=require('./chunk-4Q2IP5FW.js');var K={fragment:"layout-fragment",paragraph:"layout-fragment-paragraph",table:"layout-fragment-table",image:"layout-fragment-image",line:"layout-line",run:"layout-run"};function dt(e){return e.kind==="paragraph"}function pt(e){return e.kind==="table"}function ct(e){return e.kind==="image"}function le(e){e.style.position="absolute",e.style.overflow="hidden";}function gt(e,t,n){let o=n.createElement("div");return o.className=`${K.fragment} ${K.paragraph}`,le(o),o.dataset.blockId=String(e.blockId),o.dataset.fromLine=String(e.fromLine),o.dataset.toLine=String(e.toLine),e.pmStart!==void 0&&(o.dataset.pmStart=String(e.pmStart)),e.pmEnd!==void 0&&(o.dataset.pmEnd=String(e.pmEnd)),e.continuesFromPrev&&(o.dataset.continuesFromPrev="true"),e.continuesOnNext&&(o.dataset.continuesOnNext="true"),o}function ft(e,t,n){let o=n.createElement("div");return o.className=`${K.fragment} ${K.table}`,le(o),o.dataset.blockId=String(e.blockId),o.dataset.fromRow=String(e.fromRow),o.dataset.toRow=String(e.toRow),e.pmStart!==void 0&&(o.dataset.pmStart=String(e.pmStart)),e.pmEnd!==void 0&&(o.dataset.pmEnd=String(e.pmEnd)),o}function mt(e,t,n){let o=n.createElement("div");return o.className=`${K.fragment} ${K.image}`,le(o),o.dataset.blockId=String(e.blockId),e.pmStart!==void 0&&(o.dataset.pmStart=String(e.pmStart)),e.pmEnd!==void 0&&(o.dataset.pmEnd=String(e.pmEnd)),e.isAnchored&&(o.dataset.anchored="true"),e.zIndex!==void 0&&(o.style.zIndex=String(e.zIndex)),o}function Te(e,t,n={}){let o=n.document??document;if(dt(e))return gt(e,t,o);if(pt(e))return ft(e,t,o);if(ct(e))return mt(e,t,o);let r=o.createElement("div");r.className=K.fragment,le(r);let i=e;return i.blockId!==void 0&&(r.dataset.blockId=String(i.blockId)),i.kind&&(r.dataset.kind=i.kind),r}var P={fragment:"layout-paragraph",line:"layout-line",run:"layout-run",text:"layout-run-text",tab:"layout-run-tab",image:"layout-run-image",lineBreak:"layout-run-linebreak"};function A(e){return e.kind==="text"}function z(e){return e.kind==="tab"}function W(e){return e.kind==="image"}function G(e){return e.kind==="lineBreak"}function Y(e){return e.kind==="field"}var je={image:"layout-image",imageAnchored:"layout-image-anchored"};function ee(e){return !!(e.cropTop||e.cropRight||e.cropBottom||e.cropLeft||e.opacity!=null&&e.opacity<1)}function te(e,t){let n=t.cropTop??0,o=t.cropRight??0,r=t.cropBottom??0,i=t.cropLeft??0;(n||o||r||i)&&(e.style.clipPath=`inset(${n*100}% ${o*100}% ${r*100}% ${i*100}%)`),t.opacity!=null&&t.opacity<1&&(e.style.opacity=String(Math.max(0,t.opacity)));}function Z(e,t,n,o,r={}){let i=r.document??document,a=i.createElement("div");a.className=je.image,e.isAnchored&&a.classList.add(je.imageAnchored),a.style.position="absolute",a.style.width=`${e.width}px`,a.style.height=`${e.height}px`,a.style.overflow="hidden",e.zIndex!==void 0&&(a.style.zIndex=String(e.zIndex)),t.anchor?.behindDoc&&(a.style.zIndex="-1"),a.dataset.blockId=String(e.blockId),e.pmStart!==void 0&&(a.dataset.pmStart=String(e.pmStart)),e.pmEnd!==void 0&&(a.dataset.pmEnd=String(e.pmEnd));let l=i.createElement("img");if(l.src=t.src,l.alt=t.alt??"",l.style.width="100%",l.style.height="100%",l.style.objectFit="contain",l.style.display="block",t.transform&&(l.style.transform=t.transform),l.draggable=false,t.hlinkHref){let d=i.createElement("a");d.href=t.hlinkHref,d.target="_blank",d.rel="noopener noreferrer",d.style.display="block",d.style.width="100%",d.style.height="100%",d.appendChild(l),a.appendChild(d);}else a.appendChild(l);return a}function ht(e,t,n){if(t.fontFamily&&(e.style.fontFamily=chunkN3Y5BUKV_js.a(t.fontFamily).cssFallback),t.fontSize){let r=t.fontSize*96/72;e.style.fontSize=`${r}px`;}if(t.bold&&(e.style.fontWeight="bold"),t.italic&&(e.style.fontStyle="italic"),t.color&&(e.style.color=t.color),t.letterSpacing&&(e.style.letterSpacing=`${t.letterSpacing}px`),t.allCaps&&(e.style.textTransform="uppercase"),t.smallCaps&&(e.style.fontVariant="small-caps"),t.positionPx&&(e.style.verticalAlign=`${t.positionPx}px`),t.horizontalScale&&t.horizontalScale!==100&&(e.style.display="inline-block",e.style.transform=`scaleX(${t.horizontalScale/100})`,e.style.transformOrigin="left center"),t.kerningMinPt&&t.kerningMinPt>0&&(t.fontSize??11)>=t.kerningMinPt&&(e.style.fontKerning="normal"),t.emboss&&(e.style.textShadow="1px 1px 1px rgba(255,255,255,0.5), -1px -1px 1px rgba(0,0,0,0.3)"),t.imprint&&(e.style.textShadow="-1px -1px 1px rgba(255,255,255,0.5), 1px 1px 1px rgba(0,0,0,0.3)"),t.textShadow&&!t.emboss&&!t.imprint&&(e.style.textShadow="1px 1px 2px rgba(0,0,0,0.3)"),t.textOutline&&(e.style.webkitTextStroke="1px currentColor",e.style.webkitTextFillColor="transparent"),t.emphasisMark){let r=t.emphasisMark==="comma"?"filled sesame":t.emphasisMark==="circle"?"filled circle":"filled dot",i=t.emphasisMark==="underDot"?"under right":"over right";e.style.textEmphasis=`${r}`,e.style.textEmphasisPosition=i,e.style.webkitTextEmphasis=r,e.style.webkitTextEmphasisPosition=i;}t.highlight&&(e.style.backgroundColor=t.highlight);let o=[];if(t.underline&&(o.push("underline"),typeof t.underline=="object"&&(t.underline.style&&(e.style.textDecorationStyle=t.underline.style),t.underline.color&&(e.style.textDecorationColor=t.underline.color))),t.strike&&o.push("line-through"),t.commentIds&&t.commentIds.length>0){let r=t.commentIds.find(i=>!n||!n.has(i));r!=null&&(e.style.backgroundColor="rgba(255, 212, 0, 0.15)",e.style.borderBottom="1px solid rgba(255, 212, 0, 0.4)",e.dataset.commentId=String(r));}t.isInsertion&&(e.style.backgroundColor="rgba(52, 168, 83, 0.08)",e.style.borderBottom="2px dashed #2e7d32",e.style.paddingBottom="1px",e.classList.add("docx-insertion"),t.changeAuthor&&(e.dataset.changeAuthor=t.changeAuthor),t.changeDate&&(e.dataset.changeDate=t.changeDate),t.changeRevisionId!=null&&(e.dataset.revisionId=String(t.changeRevisionId))),t.isDeletion&&(e.style.backgroundColor="rgba(211, 47, 47, 0.08)",e.style.color="#c62828",o.includes("line-through")||o.push("line-through"),e.style.textDecorationColor="#c62828",e.classList.add("docx-deletion"),t.changeAuthor&&(e.dataset.changeAuthor=t.changeAuthor),t.changeDate&&(e.dataset.changeDate=t.changeDate),t.changeRevisionId!=null&&(e.dataset.revisionId=String(t.changeRevisionId))),o.length>0&&(e.style.textDecorationLine=o.join(" ")),t.superscript&&(e.style.verticalAlign="super",e.style.fontSize="0.75em"),t.subscript&&(e.style.verticalAlign="sub",e.style.fontSize="0.75em"),t.hidden&&(e.classList.add("docx-hidden"),e.style.opacity="0.4",e.style.textDecoration="underline dotted"),t.rtl&&e.setAttribute("dir","rtl"),t.textEffect&&(e.classList.add("docx-text-effect",`docx-text-effect-${t.textEffect}`),e.dataset.effect=t.textEffect);}function j(e,t,n){t!==void 0&&(e.dataset.pmStart=String(t)),n!==void 0&&(e.dataset.pmEnd=String(n));}function ne(e,t,n){let o=t.createElement("span");if(o.className=`${P.run} ${P.text}`,ht(o,e,n),j(o,e.pmStart,e.pmEnd),e.hyperlink){let r=t.createElement("a");r.href=e.hyperlink.href,e.hyperlink.href.startsWith("#")||(r.target="_blank",r.rel="noopener noreferrer"),e.hyperlink.tooltip&&(r.title=e.hyperlink.tooltip),r.textContent=e.text,r.style.color="inherit",r.style.textDecoration="inherit",e.hyperlink.noDefaultStyle||(e.color||(r.style.color="#0563c1",o.style.color="#0563c1"),e.underline||(r.style.textDecoration="underline")),o.appendChild(r);}else o.textContent=e.text;return o}var ut=1e3;function de(e,t,n,o){let r=t.createElement("span");r.className=`${P.run} ${P.tab}`,r.style.display="inline-block",r.style.width=`${n}px`,j(r,e.pmStart,e.pmEnd);let i=o&&o!=="none"?yt(o):null;if(i){r.style.position="relative",r.textContent="\u200B";let a=t.createElement("span");a.style.position="absolute",a.style.left="0",a.style.right="0",a.style.top="0",a.style.bottom="0",a.style.overflow="hidden",a.style.whiteSpace="nowrap",a.textContent=i.repeat(ut),r.appendChild(a);}else r.textContent="\xA0";return r}function yt(e){switch(e){case "dot":return ".";case "hyphen":return "-";case "underscore":return "_";case "middleDot":return "\xB7";case "heavy":return "_";default:return null}}function Ye(e){if(!e)return 0;let t=e.match(/rotate\(([-\d.]+)deg\)/);return t?(parseFloat(t[1])%360+360)%360:0}function Ue(e,t,n){if(n===0||n===180)return {w:e,h:t};if(n===90||n===270)return {w:t,h:e};let o=n*Math.PI/180,r=Math.abs(Math.sin(o)),i=Math.abs(Math.cos(o));return {w:e*i+t*r,h:e*r+t*i}}function Ve(e,t){t.distTop&&(e.style.marginTop=`${t.distTop}px`),t.distBottom&&(e.style.marginBottom=`${t.distBottom}px`);}function bt(e,t){let n=t.createElement("img");n.className=`${P.run} ${P.image}`,n.src=e.src,n.width=e.width,n.height=e.height,n.style.width=`${e.width}px`,n.style.height=`${e.height}px`,e.alt&&(n.alt=e.alt),e.transform&&(n.style.transform=e.transform,n.style.transformOrigin="center center"),ee(e)&&te(n,e);let o=Ye(e.transform);if(o!==0){let r=Ue(e.width,e.height,o),i=t.createElement("span");return i.style.display="inline-block",i.style.position="relative",i.style.width=`${r.w}px`,i.style.height=`${r.h}px`,i.style.verticalAlign="middle",n.style.position="absolute",n.style.left=`${(r.w-e.width)/2}px`,n.style.top=`${(r.h-e.height)/2}px`,Ve(i,e),j(i,e.pmStart,e.pmEnd),i.appendChild(n),i}return n.style.display="inline-block",n.style.verticalAlign="middle",Ve(n,e),j(n,e.pmStart,e.pmEnd),n}function Ke(e,t){let n=t.createElement("div");n.className="layout-block-image",n.style.display="block",n.style.textAlign="center",n.style.marginTop=`${e.distTop??6}px`,n.style.marginBottom=`${e.distBottom??6}px`;let o=t.createElement("img");o.src=e.src,o.width=e.width,o.height=e.height,o.style.marginLeft="auto",o.style.marginRight="auto",e.alt&&(o.alt=e.alt),e.transform&&(o.style.transform=e.transform,o.style.transformOrigin="center center"),ee(e)&&te(o,e);let r=Ye(e.transform);if(r!==0){let i=Ue(e.width,e.height,r);n.style.height=`${i.h}px`,n.style.position="relative",o.style.position="absolute",o.style.left="50%",o.style.top="50%",o.style.marginLeft=`${-e.width/2}px`,o.style.marginRight="0",o.style.marginTop=`${-e.height/2}px`;}return j(n,e.pmStart,e.pmEnd),n.appendChild(o),n}function pe(e,t){return chunkUGXSKZVM_js.f(e)||e.displayMode==="block"||e.wrapType==="topAndBottom"?Ke(e,t):bt(e,t)}function we(e,t){let n=t.createElement("br");return n.className=`${P.run} ${P.lineBreak}`,j(n,e.pmStart,e.pmEnd),n}function ce(e,t,n){let o=e.fallback??"";switch(e.fieldType){case "PAGE":o=String(n.pageNumber);break;case "NUMPAGES":o=String(n.totalPages);break;case "DATE":o=new Date().toLocaleDateString();break;case "TIME":o=new Date().toLocaleTimeString();break}let r={...e,text:o};return ne(r,t,n?.resolvedCommentIds)}function Fe(e,t,n){if(A(e))return ne(e,t,n?.resolvedCommentIds);if(z(e))return de(e,t,48,void 0);if(W(e))return pe(e,t);if(G(e))return we(e,t);if(Y(e)&&n)return ce(e,t,n);let o=t.createElement("span");return o.className=P.run,o}function qe(e,t){let n=[],o=e.runs;for(let r=t.fromRun;r<=t.toRun;r++){let i=o[r];if(i)if(A(i)){let a=r===t.fromRun?t.fromChar:0,l=r===t.toRun?t.toChar:i.text.length;if(a>0||l<i.text.length){let d=i.text.slice(a,l);n.push({...i,text:d,pmStart:i.pmStart!==void 0?i.pmStart+a:void 0,pmEnd:i.pmStart!==void 0?i.pmStart+l:void 0});}else n.push(i);}else n.push(i);}return n}function Xe(e){return e==="center"?"center":e==="right"?"flex-end":"flex-start"}function Ze(e){return [e.pmStart??"no-start",e.pmEnd??"no-end",e.src,e.width,e.height,e.displayMode??"inline",e.wrapType??"none"].join("|")}function xt(e){return {val:e.val,pos:e.pos,leader:e.leader}}function St(e,t,n){let o="";for(let r=t+1;r<e.length;r++){let i=e[r];if(A(i))o+=i.text;else if(Y(i))i.fieldType==="PAGE"&&n?o+=String(n.pageNumber):i.fieldType==="NUMPAGES"&&n?o+=String(n.totalPages):o+=i.fallback??"";else if(z(i)||G(i))break}return o}var kt=.5;function Tt(e,t,n,o){let r=0;for(let i=t+1;i<e.length;i++){let a=e[i];if(z(a)||G(a))break;if(A(a))r+=n(a.text||"",a.fontSize,a.fontFamily,a.bold,a.italic);else if(Y(a)){let l;a.fieldType==="PAGE"&&o?l=String(o.pageNumber):a.fieldType==="NUMPAGES"&&o?l=String(o.totalPages):l=a.fallback??"",r+=n(l,a.fontSize,a.fontFamily,a.bold,a.italic);}else W(a)&&!chunkUGXSKZVM_js.f(a)&&(r+=a.width||0);}return r}function wt(e){let n=e.createElement("canvas").getContext("2d");return (o,r=11,i="Calibri",a=false,l=false)=>{if(!n)return o.length*7;let d=chunkN3Y5BUKV_js.a(i).cssFallback,f=r*96/72,s=[];return l&&s.push("italic"),a&&s.push("bold"),s.push(`${f}px`,d),n.font=s.join(" "),n.measureText(o).width}}function ge(e,t,n,o,r){let i=o.createElement("div");i.className=P.line,i.style.height=`${t.lineHeight}px`,i.style.lineHeight=`${t.lineHeight}px`;let a=qe(e,t);if(a.length===1&&W(a[0])){let p=a[0].position?.horizontal?.align??n;i.style.display="flex",i.style.alignItems="center",i.style.justifyContent=Xe(p),i.dataset.flexLine="true";}else a.some(W)&&(i.style.display="flex",i.style.alignItems="baseline",i.style.justifyContent=Xe(n),i.style.lineHeight="normal",i.dataset.flexLine="true");if(a.length===0){let h=o.createElement("span");return h.className=`${P.run} layout-empty-run`,h.innerHTML="&nbsp;",i.appendChild(h),i}let l=n==="justify",d=false;l&&r&&(d=!r.isLastLine||r.paragraphEndsWithLineBreak,d&&(i.style.textAlign="justify",i.style.textAlignLast="justify",i.style.width=`${r.availableWidth}px`)),i.style.whiteSpace="pre";let f=a.some(h=>A(h)&&h.highlight);i.style.overflow=f?"hidden":"visible";let s=a.some(z),g,F=wt(o);if(s){let h=r?.tabStops?.map(xt),c=r?.leftIndentPx?Math.round(r.leftIndentPx*15):0;g={explicitStops:h,leftIndent:c};}let y=0,m=r?.leftIndentPx??0;if(r?.isFirstLine){let h=r?.firstLineIndentPx??0;y=m+h;}else y=m;for(let h=0;h<a.length;h++){let c=a[h];if(z(c)&&g){let p=Tt(a,h,F,r?.context),b=St(a,h,r?.context),u=b.indexOf("."),T=u>=0?F(b.slice(0,u)):0,k=chunkXBIKSAH6_js.r(y,g,{followingWidth:p,decimalPrefixWidth:T}),x=r?.lineRightEdgePx,C=p,I=false;for(let R=h+1;R<a.length&&!G(a[R]);R++)if(z(a[R])){I=true;break}if(x!==void 0&&k.alignment==="end"&&!I&&y+k.width+C>=x-kt){i.style.display="flex",i.style.alignItems="baseline",i.style.whiteSpace="nowrap",i.style.textIndent="0",i.dataset.flexLine="true",r?.isFirstLine&&r.firstLineIndentPx&&r.firstLineIndentPx<0&&i.firstElementChild instanceof HTMLElement&&(i.firstElementChild.style.marginLeft=`${r.firstLineIndentPx}px`);let R=de(c,o,0,k.leader);R.style.flex="1 1 0",R.style.minWidth="0",R.style.width="auto",i.appendChild(R);for(let X=h+1;X<a.length;X++){let L=a[X];if(z(L)||G(L))break;if(A(L))i.appendChild(ne(L,o,r?.context?.resolvedCommentIds));else if(Y(L)&&r?.context)i.appendChild(ce(L,o,r.context));else if(W(L)){if(chunkUGXSKZVM_js.f(L))continue;let ie=Ze(L);r?.renderedInlineImageKeys?.has(ie)||(r?.renderedInlineImageKeys?.add(ie),i.appendChild(pe(L,o)));}else i.appendChild(Fe(L,o,r?.context));}break}let w=k.width;x!==void 0&&y+w+C>x&&(w=Math.max(1,x-y-C));let E=de(c,o,w,k.leader);i.appendChild(E),y+=w;}else if(A(c)){let p=ne(c,o,r?.context?.resolvedCommentIds);if(c.highlight){let k=(c.fontSize?c.fontSize*96/72:14.67)*1.2,x=Math.max(0,t.lineHeight-k);if(x>0){let C=x/2;p.style.paddingTop=`${C}px`,p.style.paddingBottom=`${C}px`;}}i.appendChild(p);let b=c.fontSize||11,u=c.fontFamily||"Calibri";y+=F(c.text,b,u,c.bold,c.italic);}else if(W(c)){if(chunkUGXSKZVM_js.f(c))continue;let p=Ze(c);if(r?.renderedInlineImageKeys?.has(p))continue;r?.renderedInlineImageKeys?.add(p);let b=pe(c,o);i.appendChild(b),c.displayMode!=="block"&&c.wrapType!=="topAndBottom"&&(y+=c.width);}else if(G(c)){let p=we(c,o);i.appendChild(p);}else if(Y(c)&&r?.context){let p=ce(c,o,r.context);i.appendChild(p);let b=c.fallback??"";c.fieldType==="PAGE"?b=String(r.context.pageNumber):c.fieldType==="NUMPAGES"&&(b=String(r.context.totalPages));let u=c.fontSize||11,T=c.fontFamily||"Calibri";y+=F(b,u,T,c.bold,c.italic);}else {let p=Fe(c,o,r?.context);i.appendChild(p);}}return i}function oe(e,t){return !e&&!t?true:!e||!t?false:e.style===t.style&&e.width===t.width&&e.color===t.color}function Je(e,t){return !e&&!t||!e||!t?false:oe(e.top,t.top)&&oe(e.bottom,t.bottom)&&oe(e.left,t.left)&&oe(e.right,t.right)&&oe(e.between,t.between)}function H(e,t,n,o,r={}){let i=r.document??document,a=i.createElement("div");a.className=P.fragment,a.style.position=o.positioning==="absolute"?"absolute":"relative",a.dataset.blockId=String(e.blockId),a.dataset.fromLine=String(e.fromLine),a.dataset.toLine=String(e.toLine),j(a,e.pmStart,e.pmEnd),e.continuesFromPrev&&(a.dataset.continuesFromPrev="true"),e.continuesOnNext&&(a.dataset.continuesOnNext="true");let l=n.lines.slice(e.fromLine,e.toLine),d=t.attrs?.alignment;t.attrs?.styleId&&(a.dataset.styleId=t.attrs.styleId);let f=t.attrs?.bidi;f&&(a.dir="rtl"),d?d==="center"?a.style.textAlign="center":d==="right"?a.style.textAlign="right":d==="left"?a.style.textAlign="left":a.style.textAlign=f?"right":"left":f&&(a.style.textAlign="right");let s=t.attrs?.indent,g=0,F=0;s&&(f?(s.left&&s.left>0&&(F=s.left),s.right&&s.right>0&&(g=s.right)):(s.left&&s.left>0&&(g=s.left),s.right&&s.right>0&&(F=s.right)));let y=t.attrs?.borders;if(y){let T=R=>{switch(R){case "single":return "solid";case "double":return "double";case "dotted":return "dotted";case "dashed":return "dashed";case "thick":return "solid";case "wave":return "wavy";case "dashSmallGap":return "dashed";case "nil":case "none":return "none";default:return "solid"}};a.style.boxSizing="border-box";let k=R=>`${R.width}px ${T(R.style)} ${R.color}`,x=Je(r.prevBorders,y),C=Je(y,r.nextBorders),I=x?y.between:y.top,S=C?void 0:y.bottom,w=i.createElement("div");if(w.className="layout-paragraph-border",w.style.position="absolute",w.style.pointerEvents="none",w.style.boxSizing="border-box",w.style.left=`${g-(y.left?.space??0)}px`,w.style.right=`${F-(y.right?.space??0)}px`,w.style.top=`${-(I?.space??0)}px`,w.style.bottom=`${-(S?.space??0)}px`,I&&(w.style.borderTop=k(I)),S&&(w.style.borderBottom=k(S)),y.left&&(w.style.borderLeft=k(y.left)),y.right&&(w.style.borderRight=k(y.right)),(I||S||y.left||y.right)&&a.appendChild(w),y.bar){let R=i.createElement("div");R.style.position="absolute",R.style.left="-8px",R.style.top="0",R.style.bottom="0",R.style.borderLeft=k(y.bar),a.style.position="relative",a.appendChild(R);}}t.attrs?.shading&&(a.style.backgroundColor=t.attrs.shading);let m=e.width-g-F,c=t.runs[t.runs.length-1]?.kind==="lineBreak",p=n.lines.length,b=0;s?.hanging&&s.hanging>0?b=-s.hanging:s?.firstLine&&s.firstLine>0&&(b=s.firstLine);let u=r.renderedInlineImageKeys??new Set;for(let T=0;T<l.length;T++){let k=l[T],x=e.fromLine+T,C=x===p-1,I=x===0&&!e.continuesFromPrev,S=k.leftOffset??0,w=k.rightOffset??0,E=m;if(I){let B=s?.hanging&&s.hanging>0,M=s?.firstLine&&s.firstLine>0;B&&s?.hanging?E=m+s.hanging:M&&s?.firstLine&&(E=m-s.firstLine);}if(Ft(k,t)){let B=i.createElement("div");B.className=`${P.line} layout-line-split`,B.style.position="relative",B.style.height=`${k.lineHeight}px`,B.style.lineHeight=`${k.lineHeight}px`;for(let M of k.segments){let Se={fromRun:M.fromRun,fromChar:M.fromChar,toRun:M.toRun,toChar:M.toChar,width:M.width,ascent:k.ascent,descent:k.descent,lineHeight:k.lineHeight},D=ge(t,Se,d,i,{availableWidth:M.availableWidth,isLastLine:C,isFirstLine:I,paragraphEndsWithLineBreak:c,tabStops:t.attrs?.tabs,leftIndentPx:g,firstLineIndentPx:I?b:0,context:o,renderedInlineImageKeys:u});D.className+=" layout-line-segment",D.style.position="absolute",D.style.left=`${M.leftOffset}px`,D.style.top="0",D.style.width=`${M.availableWidth}px`,B.appendChild(D);}a.appendChild(B);continue}let R=ge(t,k,d,i,{availableWidth:E-S-w,isLastLine:C,isFirstLine:I,paragraphEndsWithLineBreak:c,tabStops:t.attrs?.tabs,leftIndentPx:g,firstLineIndentPx:I?b:0,context:o,renderedInlineImageKeys:u,lineRightEdgePx:e.width-F-w});if(S>0||w>0){S>0&&(R.style.marginLeft=`${S}px`),w>0&&(R.style.marginRight=`${w}px`);let B=E-S-w;B>0&&(R.style.width=`${B}px`);}k.floatSkipBefore&&k.floatSkipBefore>0&&(R.style.marginTop=`${k.floatSkipBefore}px`);let X=s?.hanging&&s.hanging>0,L=s?.firstLine&&s.firstLine>0,ie=R.dataset.flexLine==="true";if(I?g>0&&X?(R.style.paddingLeft=`${g}px`,ie||(R.style.textIndent=`-${s.hanging}px`)):g>0&&L?(R.style.paddingLeft=`${g}px`,R.style.textIndent=`${s.firstLine}px`):g>0?R.style.paddingLeft=`${g}px`:L&&(R.style.textIndent=`${s.firstLine}px`):g>0?R.style.paddingLeft=`${g}px`:X&&(R.style.paddingLeft=`${s.hanging}px`),F>0&&(R.style.paddingRight=`${F}px`),I&&t.attrs?.listMarker&&!t.attrs?.listMarkerHidden){let B=s?.hanging??0,M=s?.firstLine??0,Se=B>0?Math.max(0,g-B):g+M;R.style.paddingLeft=`${Se}px`,R.style.textIndent="0";let{fontFamily:D,fontSize:st}=chunkXBIKSAH6_js.s(t),lt=Ct(t.attrs.listMarker,chunkXBIKSAH6_js.t(t),i,D,st);R.insertBefore(lt,R.firstChild);}a.appendChild(R);}return a}function Ft(e,t){return (e.segments?.length??0)>1&&!t.attrs?.listMarker}function Ct(e,t,n,o,r){let i=n.createElement("span");return i.className="layout-list-marker",i.style.fontFamily=chunkN3Y5BUKV_js.a(o).cssFallback,i.style.fontSize=`${r*96/72}px`,i.style.textAlign="left",i.style.boxSizing="border-box",i.style.display="inline-block",i.style.minWidth=`${t}px`,i.textContent=e,i}function U(e,t,n){let o=t.createElement("div");o.className=n.layerClass,o.style.position="absolute",o.style.top="0",o.style.left="0",n.sizing==="inset0"?(o.style.right="0",o.style.bottom="0"):(o.style.width="100%",o.style.height="100%",o.style.overflow="hidden"),o.style.pointerEvents="none",n.layerMode==="front"&&(o.style.zIndex="10");for(let r of e){let i=t.createElement("div");i.className=n.itemClass,i.style.position="absolute",i.style.pointerEvents="auto",i.style.top=`${r.y}px`,i.style.left=`${r.x}px`,r.pmStart!==void 0&&(i.dataset.pmStart=String(r.pmStart)),r.pmEnd!==void 0&&(i.dataset.pmEnd=String(r.pmEnd));let a=t.createElement("img");a.src=r.src,a.style.width=`${r.width}px`,a.style.height=`${r.height}px`,a.style.display="block",r.alt&&(a.alt=r.alt),r.transform&&(a.style.transform=r.transform,a.style.transformOrigin="center center"),ee(r)&&te(a,r),i.appendChild(a),o.appendChild(i);}return o}var O={table:"layout-table",row:"layout-table-row",cell:"layout-table-cell",cellContent:"layout-table-cell-content",resizeHandle:"layout-table-resize-handle",rowResizeHandle:"layout-table-row-resize-handle",tableEdgeHandleBottom:"layout-table-edge-handle-bottom",tableEdgeHandleRight:"layout-table-edge-handle-right"};function Rt(e,t,n){let o=[],r=0;for(let i=0;i<e.blocks.length;i++){let a=e.blocks[i];if(a?.kind!=="paragraph"){let f=t.blocks[i];f&&f.kind==="table"&&(r+=f.totalHeight??0);continue}let l=a;for(let f of l.runs){if(f.kind!=="image")continue;let s=f;if(!chunkUGXSKZVM_js.f(s))continue;let g=s.position,F=s.distTop??0,y=s.distBottom??0,m=s.distLeft??12,h=s.distRight??12,c="left",p=0;if(g?.horizontal){let u=g.horizontal;u.align==="right"?(c="right",p=n-s.width):u.align==="left"?p=0:u.align==="center"?p=(n-s.width)/2:u.posOffset!==void 0&&(p=chunk4Q2IP5FW_js.e(u.posOffset),c=p>n/2?"right":"left");}else s.cssFloat==="right"&&(c="right",p=n-s.width);let b=r;if(g?.vertical){let u=g.vertical;u.posOffset!==void 0?b=r+chunk4Q2IP5FW_js.e(u.posOffset):u.align==="top"&&(b=0);}p=Math.max(0,Math.min(p,n-s.width)),o.push({src:s.src,width:s.width,height:s.height,alt:s.alt,transform:s.transform,x:p,y:b,side:c,distTop:F,distBottom:y,distLeft:m,distRight:h,wrapText:chunkUGXSKZVM_js.h(s.cssFloat),wrapType:s.wrapType,pmStart:s.pmStart,pmEnd:s.pmEnd});}let d=t.blocks[i];d&&d.kind==="paragraph"&&(r+=d.totalHeight);}return o}function It(e,t,n,o){let r=o.createElement("div");r.className=O.cellContent,r.style.position="relative";let i=e.padding?.left??7,a=e.padding?.right??7,l=Math.max(0,t.width-i-a);r.style.width=`${l}px`;let d=Rt(e,t,l),f;if(d.length>0){f=d.filter(chunkUGXSKZVM_js.d).map(m=>{let h=m.x+m.width+m.distRight,c=m.y-m.distTop,p=m.y+m.height+m.distBottom,b=0,u=0,T=m.wrapText??"bothSides";return T==="right"?b=h:T==="left"?u=l-(m.x-m.distLeft):m.side==="left"?b=h:u=l-(m.x-m.distLeft),{leftMargin:b,rightMargin:u,topY:c,bottomY:p}});let y=d.filter(chunkUGXSKZVM_js.e);y.length>0&&r.appendChild(U(y,o,{layerClass:"layout-cell-floating-images-layer",itemClass:"layout-cell-floating-image",sizing:"fullSize",layerMode:"behind"}));}let s=0,g=0;for(let y=0;y<e.blocks.length;y++){let m=e.blocks[y],h=t.blocks[y];if(m?.kind==="paragraph"&&h?.kind==="paragraph"){let c=m,p=h,b=c.attrs?.spacing,u=Math.max(g,b?.before??0);s+=u,f&&f.length>0&&(p=chunkXBIKSAH6_js.v(c,l,{floatingZones:f,paragraphYOffset:s}));let T={blockId:c.id,width:l,height:p.totalHeight,fromLine:0,toLine:p.lines.length,pmStart:c.pmStart,pmEnd:c.pmEnd},k={...n,insideTableCell:true},x=H(T,c,p,k,{document:o});x.style.position="relative",u>0&&(x.style.marginTop=`${u}px`),r.appendChild(x),s+=p.totalHeight,g=b?.after??0;}else if(m?.kind==="table"&&h?.kind==="table"){let c=m,p=h,b=g,u=Et(c,p,n,o);u.style.position="relative",b>0&&(u.style.marginTop=`${b}px`),r.appendChild(u),s+=b+(h.totalHeight??0),g=0;}}g>0&&(r.style.paddingBottom=`${g}px`);let F=d.filter(y=>!chunkUGXSKZVM_js.e(y));return F.length>0&&r.appendChild(U(F,o,{layerClass:"layout-cell-floating-images-layer",itemClass:"layout-cell-floating-image",sizing:"fullSize",layerMode:"front"})),r}function Et(e,t,n,o){let r=o.createElement("div");r.className=`${O.table} layout-nested-table`,r.style.position="relative",r.style.width=`${t.totalWidth}px`,r.style.display="block",e.justification==="center"?(r.style.marginLeft="auto",r.style.marginRight="auto"):e.justification==="right"?r.style.marginLeft="auto":e.indent&&(r.style.marginLeft=`${e.indent}px`),r.dataset.blockId=String(e.id),e.pmStart!==void 0&&(r.dataset.pmStart=String(e.pmStart)),e.pmEnd!==void 0&&(r.dataset.pmEnd=String(e.pmEnd));let i=[],a=0;for(let f=0;f<t.rows.length;f++)i.push(a),a+=t.rows[f]?.height??0;i.push(a);let l=new Map,d=0;for(let f=0;f<e.rows.length;f++){let s=e.rows[f],g=t.rows[f];if(!s||!g)continue;let F=Ce(s,g,f,d,t.columnWidths,e.rows.length,n,o,l,i);r.appendChild(F),d+=g.height;}return r.style.height=`${d}px`,r}function fe(e,t,n){let o=`border${t.charAt(0).toUpperCase()+t.slice(1)}`;if(!n||n.style==="none"||n.style==="nil"||n.width===0)e.style[o]="none";else {let r=n.width??1,i=n.color??"#000000",a=n.style??"solid";e.style[o]=`${r}px ${a} ${i}`;}}function Pt(e,t,n,o,r,i,a){let l=a.createElement("div");l.className=O.cell,l.style.position="absolute",l.style.left=`${n}px`,l.style.top="0",l.style.width=`${t.width}px`,l.style.height=`${o}px`,l.style.overflow="hidden",l.style.boxSizing="border-box";let d=e.padding?.top??1,f=e.padding?.right??7,s=e.padding?.bottom??1,g=e.padding?.left??7;if(l.style.padding=`${d}px ${f}px ${s}px ${g}px`,e.borders&&(r.isFirstRow&&fe(l,"top",e.borders.top),fe(l,"right",e.borders.right),fe(l,"bottom",e.borders.bottom),r.isFirstCol&&fe(l,"left",e.borders.left)),e.background&&(l.style.backgroundColor=e.background),e.noWrap&&(l.style.whiteSpace="nowrap"),e.verticalAlign)switch(l.style.display="flex",l.style.flexDirection="column",e.verticalAlign){case "top":l.style.justifyContent="flex-start";break;case "center":l.style.justifyContent="center";break;case "bottom":l.style.justifyContent="flex-end";break}let F=It(e,t,i,a);if(l.appendChild(F),e.blocks.length>0){let y=e.blocks[0],m=e.blocks[e.blocks.length-1];y&&"pmStart"in y&&y.pmStart!==void 0&&(l.dataset.pmStart=String(y.pmStart)),m&&"pmEnd"in m&&m.pmEnd!==void 0&&(l.dataset.pmEnd=String(m.pmEnd));}return l}function Ce(e,t,n,o,r,i,a,l,d,f,s){let g=l.createElement("div");g.className=O.row,g.style.position="absolute",g.style.left="0",g.style.top=`${o}px`,g.style.width="100%",g.style.height=`${t.height}px`,g.dataset.rowIndex=String(n);let F=new Set;if(d){for(let[,h]of d)if(h.startRow<n&&h.startRow+h.rowSpan>n)for(let c=0;c<h.colSpan;c++)F.add(h.columnIndex+c);}let y=0,m=0;for(;F.has(m);)y+=r[m]??0,m++;for(let h=0;h<e.cells.length;h++){let c=e.cells[h],p=t.cells[h];if(!c||!p)continue;let b=c.colSpan??1,u=c.rowSpan??1,T=t.height;if(u>1&&f){T=0;for(let w=n;w<n+u&&w<f.length-1;w++)T+=(f[w+1]??0)-(f[w]??0);T===0&&(T=t.height*u);}let k=n===0||s===true,C=m===0;m+b>=r.length;let S=Pt(c,p,y,T,{isFirstRow:k,isFirstCol:C},a,l);if(S.dataset.cellIndex=String(h),S.dataset.columnIndex=String(m),u>1&&(S.dataset.rowSpan=String(u)),g.appendChild(S),u>1&&d){let w=`${n}-${m}`;d.set(w,{cell:c,cellMeasure:p,columnIndex:m,startRow:n,rowSpan:u,colSpan:b,x:y,totalHeight:T});}for(let w=0;w<b&&m+w<r.length;w++)y+=r[m+w]??0;for(m+=b;F.has(m);)y+=r[m]??0,m++;}return g}function q(e,t,n,o,r={}){let i=r.document??document,a=i.createElement("div");a.className=O.table,a.style.position=o.positioning==="flow"?"relative":"absolute",a.style.width=`${e.width}px`,a.style.height=`${e.height}px`,a.style.overflow="hidden",a.dataset.blockId=String(e.blockId),a.dataset.fromRow=String(e.fromRow),a.dataset.toRow=String(e.toRow),e.pmStart!==void 0&&(a.dataset.pmStart=String(e.pmStart)),e.pmEnd!==void 0&&(a.dataset.pmEnd=String(e.pmEnd));let l=0;for(let m=0;m<n.columnWidths.length-1;m++){l+=n.columnWidths[m]??0;let h=i.createElement("div");h.className=O.resizeHandle,h.style.position="absolute",h.style.left=`${l-3}px`,h.style.top="0",h.style.width="6px",h.style.height="100%",h.style.cursor="col-resize",h.style.zIndex="10",h.dataset.columnIndex=String(m),h.dataset.tableBlockId=String(e.blockId),e.pmStart!==void 0&&(h.dataset.tablePmStart=String(e.pmStart)),a.appendChild(h);}let d=[],f=0;for(let m=0;m<n.rows.length;m++)d.push(f),f+=n.rows[m]?.height??0;d.push(f);let s=new Map,g=e.headerRowCount??0,F=0;if(g>0&&e.continuesFromPrev)for(let m=0;m<g;m++){let h=t.rows[m],c=n.rows[m];if(!h||!c)continue;let p=Ce(h,c,m,F,n.columnWidths,t.rows.length,o,i,s,d,m===0);p.dataset.repeatedHeader="true",a.appendChild(p),F+=c.height;}for(let m=e.fromRow;m<e.toRow;m++){let h=t.rows[m],c=n.rows[m];if(!h||!c)continue;let p=g>0&&e.continuesFromPrev?false:e.continuesFromPrev&&m===e.fromRow,b=Ce(h,c,m,F,n.columnWidths,t.rows.length,o,i,s,d,p);a.appendChild(b),F+=c.height;}let y=0;for(let m=e.fromRow;m<e.toRow;m++)if(y+=n.rows[m]?.height??0,m<e.toRow-1){let h=i.createElement("div");h.className=O.rowResizeHandle,h.style.position="absolute",h.style.left="0",h.style.top=`${y-3}px`,h.style.width="100%",h.style.height="6px",h.style.cursor="row-resize",h.style.zIndex="10",h.dataset.rowIndex=String(m),h.dataset.tableBlockId=String(e.blockId),e.pmStart!==void 0&&(h.dataset.tablePmStart=String(e.pmStart)),a.appendChild(h);}if(e.toRow===t.rows.length){let m=i.createElement("div");m.className=O.tableEdgeHandleBottom,m.style.position="absolute",m.style.left="0",m.style.top=`${y-3}px`,m.style.width="100%",m.style.height="6px",m.style.cursor="row-resize",m.style.zIndex="10",m.dataset.rowIndex=String(t.rows.length-1),m.dataset.tableBlockId=String(e.blockId),m.dataset.isEdge="bottom",e.pmStart!==void 0&&(m.dataset.tablePmStart=String(e.pmStart)),a.appendChild(m);}if(e.toRow===t.rows.length){let m=n.columnWidths.reduce((c,p)=>c+p,0),h=i.createElement("div");h.className=O.tableEdgeHandleRight,h.style.position="absolute",h.style.left=`${m-3}px`,h.style.top="0",h.style.width="6px",h.style.height="100%",h.style.cursor="col-resize",h.style.zIndex="10",h.dataset.columnIndex=String(n.columnWidths.length-1),h.dataset.tableBlockId=String(e.blockId),h.dataset.isEdge="right",e.pmStart!==void 0&&(h.dataset.tablePmStart=String(e.pmStart)),a.appendChild(h);}return a}var Lt={textBox:"layout-textbox"};function J(e,t,n,o,r={}){let i=r.document??document,a=i.createElement("div");if(a.className=Lt.textBox,a.style.position="absolute",a.style.width=`${e.width}px`,a.style.height=`${e.height}px`,a.style.overflow="hidden",a.style.boxSizing="border-box",Bt(a,e),t.fillColor&&(a.style.backgroundColor=t.fillColor),t.outlineWidth&&t.outlineWidth>0){let s=t.outlineStyle||"solid",g=t.outlineColor||"#000000";a.style.border=`${t.outlineWidth}px ${s} ${g}`;}let l=t.margins??chunkDROCYKAR_js.a;a.style.padding=`${l.top}px ${l.right}px ${l.bottom}px ${l.left}px`,a.dataset.blockId=String(e.blockId),e.pmStart!==void 0&&(a.dataset.pmStart=String(e.pmStart)),e.pmEnd!==void 0&&(a.dataset.pmEnd=String(e.pmEnd));let d=e.width-l.left-l.right,f=0;for(let s=0;s<t.content.length;s++){let g=t.content[s],F=n.innerMeasures[s];if(!F)continue;let y={blockId:g.id,width:d,height:F.totalHeight,pmStart:g.pmStart,pmEnd:g.pmEnd,fromLine:0,toLine:F.lines.length},m=H(y,g,F,{...o,positioning:"flow"},{document:i});a.appendChild(m),f+=F.totalHeight;}return a}function Bt(e,t){!t.isFloating&&t.zIndex===void 0||(e.style.zIndex=String(t.zIndex??10));}function Qe(e){return {pageWidth:e.size.w,pageHeight:e.size.h,marginLeft:e.margins.left,marginTop:e.margins.top,contentWidth:e.size.w-e.margins.left-e.margins.right,contentHeight:e.size.h-e.margins.top-e.margins.bottom}}function Re(e,t,n,o){let{x:r,side:i}=Mt(e,n,o),a=$t(e,t,o);return {x:r,y:a,side:i}}function Mt(e,t,n){let o=e.position?.horizontal;if(!o)return e.cssFloat==="right"?{x:t-e.width,side:"right"}:{x:0,side:"left"};let r=vt(o.relativeTo,t,n);if(o.align==="right")return {x:r.size?r.base+r.size-e.width:0,side:"right"};if(o.align==="left")return {x:r.base,side:"left"};if(o.align==="center")return {x:r.size?r.base+(r.size-e.width)/2:0,side:"left"};if(o.posOffset!==void 0){let i=r.base+chunk4Q2IP5FW_js.e(o.posOffset);return {x:i,side:i>t/2?"right":"left"}}return {x:r.base,side:"left"}}function vt(e,t,n){let o=n?.pageWidth??0,r=n?.marginLeft??0;switch(e){case "page":return {base:-r,size:o};case "leftMargin":return {base:-r,size:r};case "rightMargin":return {base:t,size:r};case "character":return {base:0,size:0};default:return {base:0,size:t}}}function $t(e,t,n){let o=e.position?.vertical;if(!o)return t;let r=Ht(o.relativeTo,t,n);return o.align==="top"?r.base:o.align==="center"?r.size?r.base+(r.size-e.height)/2:t:o.align==="bottom"?r.size?r.base+r.size-e.height:t:o.posOffset!==void 0?r.base+chunk4Q2IP5FW_js.e(o.posOffset):o.relativeTo==="paragraph"||o.relativeTo==="line"?t:r.base}function Ht(e,t,n){let o=n?.pageHeight??0,r=n?.marginTop??0,i=n?.contentHeight??0;switch(e){case "paragraph":case "line":return {base:t,size:0};case "page":return {base:-r,size:o};case "topMargin":return {base:-r,size:r};case "bottomMargin":return {base:i,size:r};default:return {base:0,size:i}}}function et(e){return e?.align??e?.alignment}function At(e,t){let n=e.position.vertical;if(!n)return e.paragraphY;let o=et(n),r=n.posOffset!==void 0?chunk4Q2IP5FW_js.e(n.posOffset):void 0;if(n.relativeTo==="page"){if(r!==void 0)return r-t.flowTop;if(o==="top")return -t.flowTop;if(o==="bottom")return t.pageHeight-e.height-t.flowTop;if(o==="center")return (t.pageHeight-e.height)/2-t.flowTop}if(n.relativeTo==="margin"){let i=t.margins.top,a=t.pageHeight-t.margins.top-t.margins.bottom;if(r!==void 0)return i+r-t.flowTop;if(o==="top")return i-t.flowTop;if(o==="bottom")return i+a-e.height-t.flowTop;if(o==="center")return i+(a-e.height)/2-t.flowTop}return r!==void 0?e.paragraphY+r:e.paragraphY}function zt(e,t,n){let o=t.position.horizontal;if(!o){e.style.left="0";return}let r=et(o);if(o.relativeTo==="page"){if(o.posOffset!==void 0){e.style.left=`${chunk4Q2IP5FW_js.e(o.posOffset)-n.flowLeft}px`;return}if(r==="right"){e.style.left=`${n.pageWidth-t.width-n.flowLeft}px`;return}if(r==="center"){e.style.left=`${(n.pageWidth-t.width)/2-n.flowLeft}px`;return}if(r==="left"){e.style.left=`${-n.flowLeft}px`;return}}if(o.posOffset!==void 0){e.style.left=`${chunk4Q2IP5FW_js.e(o.posOffset)}px`;return}if(r==="right"){e.style.left=`${n.contentWidth-t.width}px`;return}if(r==="center"){e.style.left=`${(n.contentWidth-t.width)/2}px`;return}e.style.left="0";}function tt(e,t){let n=e.tblpY??0;e.vertAnchor==="page"?n-=t.flowTop:e.vertAnchor==="margin"&&(n+=t.margins.top-t.flowTop);let o=e.tblpX??0;return e.horzAnchor==="page"?o-=t.flowLeft:e.horzAnchor==="margin"&&(o+=t.margins.left-t.flowLeft),{left:o,top:n}}function Ie(e,t,n,o){let r=n.document??document,i=r.createElement("div");i.style.position="relative";let a=t.contentWidth??600,l=[],d=0;for(let f=0;f<e.blocks.length;f++){let s=e.blocks[f],g=e.measures[f];if(!(!s||!g))if(s.kind==="paragraph"){if(g.kind!=="paragraph")continue;let F=s,y=g,m=F.attrs?.spacing?.before??0,h=d,c=[];for(let T of F.runs)if(T.kind==="image"&&"position"in T&&T.position){let k=T;l.push({src:k.src,width:k.width,height:k.height,alt:k.alt,paragraphY:h,position:k.position});}else c.push(T);let p={...F,runs:c},b={blockId:F.id,width:a,height:y.totalHeight,fromLine:0,toLine:y.lines.length},u=H(b,p,y,{...t,positioning:"absolute"},{document:r});u.style.top=`${d+m}px`,u.style.left="0",u.style.width=`${a}px`,i.appendChild(u),d+=y.totalHeight;}else if(s.kind==="table"){if(g.kind!=="table")continue;let F={blockId:s.id,width:g.totalWidth,height:g.totalHeight,fromRow:0,toRow:g.rows.length,pmStart:s.pmStart,pmEnd:s.pmEnd},y=q(F,s,g,{...t,positioning:"absolute"},{document:r});if(s.floating){let{left:m,top:h}=tt(s.floating,o);y.style.top=`${h}px`,y.style.left=`${m}px`,i.appendChild(y);}else y.style.top=`${d}px`,y.style.left="0",i.appendChild(y),d+=g.totalHeight;}else if(s.kind==="image"){if(g.kind!=="image")continue;let F={blockId:s.id,width:g.width,height:g.height,pmStart:s.pmStart,pmEnd:s.pmEnd},y=Z(F,s,g,{...t},{document:r});y.style.top=`${d}px`,y.style.left="0",i.appendChild(y),d+=g.height;}else if(s.kind==="textBox"){if(g.kind!=="textBox")continue;let F={blockId:s.id,width:g.width,height:g.height,pmStart:s.pmStart,pmEnd:s.pmEnd},y=J(F,s,g,{...t,positioning:"absolute"},{document:r});y.style.top=`${d}px`,y.style.left="0",i.appendChild(y),d+=g.height;}else s.kind==="sectionBreak"||s.kind==="pageBreak"||s.kind==="columnBreak"||chunkDROCYKAR_js.c(s,"renderHeaderFooterContent");}for(let f of l){let s=r.createElement("img");s.src=f.src,s.width=f.width,s.height=f.height,f.alt&&(s.alt=f.alt),s.style.position="absolute",s.style.display="block",s.style.width=`${f.width}px`,s.style.height=`${f.height}px`,s.style.maxWidth="none",s.style.maxHeight="none",zt(s,f,o),s.style.top=`${At(f,o)}px`,i.appendChild(s);}return i}var me=12,nt=6;function Ot(e,t){if(e.size!==t.size)return false;for(let[n,o]of e)if(t.get(n)!==o)return false;return true}var Ee=8;function Kn(e){let t=[],n=o=>{for(let r of o)if(r.kind==="paragraph")for(let i of r.runs)i.kind==="text"&&i.footnoteRefId!=null&&t.push({footnoteId:i.footnoteRefId,pmPos:i.pmStart??0});else if(r.kind==="table")for(let i of r.rows)for(let a of i.cells)n(a.blocks);else r.kind==="textBox"&&n(r.content);};return n(e),t}function Pe(e,t){let n=new Map;if(t.length===0)return n;for(let o of t)for(let r of e){let i=false;for(let a of r.fragments){let l=a.pmStart??-1,d=a.pmEnd??-1;if(l>=0&&d>=0&&o.pmPos>=l&&o.pmPos<d){let f=n.get(r.number)??[];f.includes(o.footnoteId)||f.push(o.footnoteId),n.set(r.number,f),i=true;break}}if(i)break}return n}function Nt(e,t){if(e.length===0)return [{kind:"paragraph",id:`fn-empty-${t}`,runs:[{kind:"text",text:`${t} `,fontSize:Ee,superscript:true}]}];let n=e.map(r=>{if(r.kind!=="paragraph")return r;let i=r;return {...i,runs:i.runs.map(a=>(a.kind==="text"||a.kind==="tab")&&a.fontSize==null?{...a,fontSize:Ee}:a)}}),o=n[0];if(o.kind==="paragraph"){let r={kind:"text",text:`${t} `,fontSize:Ee,superscript:true};n[0]={...o,runs:[r,...o.runs]};}return n}function Dt(e,t,n,o){let r=chunkX3NB7STJ_js.c(e.content,{styles:o.styles??void 0,theme:o.theme??null,defaultTabStopTwips:o.defaultTabStopTwips??null}),i=chunk3AZWLVLC_js.c(r,{theme:o.theme??void 0}),a=Nt(i,t),l=o.measureBlocks(a,n),d=l.reduce((f,s)=>s.kind==="paragraph"||s.kind==="table"?f+s.totalHeight:s.kind==="image"||s.kind==="textBox"?f+s.height:f,0);return {id:e.id,displayNumber:t,blocks:a,measures:l,height:d}}function Yn(e,t,n,o){let r=new Map,i=new Map;for(let d of e)(d.noteType==="normal"||d.noteType==null)&&i.set(d.id,d);let a=1,l=new Set;for(let d of t){if(l.has(d.footnoteId))continue;l.add(d.footnoteId);let f=i.get(d.footnoteId);f&&(r.set(d.footnoteId,Dt(f,a,n,o)),a++);}return r}function ot(e,t){let n=new Map;for(let[o,r]of e){let i=0;for(let a of r){let l=t.get(a);l&&(i+=l.height);}i>0&&(i+=me,n.set(o,i));}return n}function Un(e){let{blocks:t,measures:n,layoutOpts:o,footnoteRefs:r,footnoteContentMap:i,initialLayout:a}=e,l=Pe(a.pages,r),d=ot(l,i);if(d.size===0)return {layout:a,pageFootnoteMap:l,converged:true};let f=a,s=false;for(let g=0;g<nt;g++){f=chunkXBIKSAH6_js.O(t,n,{...o,footnoteReservedHeights:d});let F=Pe(f.pages,r),y=ot(F,i);if(l=F,Ot(d,y)){d=y,s=true;break}d=y;}s||(f=chunkXBIKSAH6_js.O(t,n,{...o,footnoteReservedHeights:d}),l=Pe(f.pages,r),console.warn(`[docx-editor] footnote layout did not stabilize within ${nt} passes; settling with best-effort reservation. If footnotes appear misplaced, please file a bug with the document.`));for(let[g,F]of l){let y=f.pages.find(m=>m.number===g);y&&(y.footnoteIds=F);}return {layout:f,pageFootnoteMap:l,converged:s}}function Xn(e,t,n){let o=new Map;if(!n?.package?.footnotes)return o;let r=new Map;for(let i of n.package.footnotes)i.noteType&&i.noteType!=="normal"||r.set(i.id,i);for(let[i,a]of e){let l=[];for(let d of a){let f=r.get(d);if(!f)continue;let s=t.get(d),g=s?.displayNumber??0;l.push({displayNumber:String(g),text:chunkYCDB5TA6_js.x(f),content:s});}l.length>0&&o.set(i,l);}return o}function _t(e,t,n,o){let r=o.createElement("div");r.className="layout-footnote-content",r.style.position="relative",r.style.width=`${t}px`,r.style.height=`${e.height}px`;let i=0;for(let a=0;a<e.blocks.length;a++){let l=e.blocks[a],d=e.measures[a];if(!(!l||!d)){if(l.kind==="paragraph"&&d.kind==="paragraph"){let f=l.attrs?.spacing?.before??0,s={blockId:l.id,width:t,height:d.totalHeight,pmStart:l.pmStart,pmEnd:l.pmEnd,fromLine:0,toLine:d.lines.length},g=H(s,l,d,{...n,section:"body",contentWidth:t,positioning:"absolute"},{document:o});g.style.top=`${i+f}px`,g.style.left="0",g.style.width=`${t}px`,g.style.height=`${d.totalHeight}px`,r.appendChild(g),i+=d.totalHeight;}else if(l.kind==="table"&&d.kind==="table"){let f={blockId:l.id,width:d.totalWidth,height:d.totalHeight,pmStart:l.pmStart,pmEnd:l.pmEnd,fromRow:0,toRow:d.rows.length},s=q(f,l,d,{...n,section:"body",contentWidth:t,positioning:"absolute"},{document:o});s.style.top=`${i}px`,s.style.left="0",r.appendChild(s),i+=d.totalHeight;}else if(l.kind==="image"&&d.kind==="image"){let f={blockId:l.id,width:d.width,height:d.height,pmStart:l.pmStart,pmEnd:l.pmEnd},s=Z(f,l,d,{...n},{document:o});s.style.top=`${i}px`,s.style.left="0",r.appendChild(s),i+=d.height;}else if(l.kind==="textBox"&&d.kind==="textBox"){let f={blockId:l.id,width:d.width,height:d.height,pmStart:l.pmStart,pmEnd:l.pmEnd},s=J(f,l,d,{...n,section:"body",contentWidth:t,positioning:"absolute"},{document:o});s.style.top=`${i}px`,s.style.left="0",r.appendChild(s),i+=d.height;}}}return r}function Wt(e,t){let n=t.createElement("div");n.style.fontSize="10px",n.style.lineHeight="1.3",n.style.marginBottom="4px",n.style.color="#000";let o=t.createElement("sup");o.textContent=e.displayNumber,o.style.fontSize="7px",o.style.marginRight="2px",n.appendChild(o);let r=t.createTextNode(" "+e.text);return n.appendChild(r),n}function rt(e){let t=me;for(let n of e)n.content&&(t+=n.content.height);return t}function it(e,t,n,o){let r=o.createElement("div");r.className="layout-footnote-area",r.style.width=`${t}px`;let i=o.createElement("div"),a=.5,l=(me-a)/2;i.style.width="33%",i.style.height=`${a}px`,i.style.backgroundColor="#000",i.style.marginBottom=`${l}px`,i.style.marginTop=`${l}px`,r.appendChild(i);for(let d of e)r.appendChild(d.content?_t(d.content,t,n,o):Wt(d,o));return r}function Le(e,t,n){let o={pageNumber:e.number,totalPages:t,section:"body",resolvedCommentIds:n.resolvedCommentIds},r={...n};if(n.titlePg&&e.number===1&&(r.headerContent=n.firstPageHeaderContent,r.footerContent=n.firstPageFooterContent),n.footnotesByPage){let i=n.footnotesByPage.get(e.number);i&&i.length>0&&(r.footnoteArea=i);}return {context:o,pageOptions:r}}function at(e){let t=[];t.push(`s:${e.size.w},${e.size.h}`),t.push(`m:${e.margins.top},${e.margins.right},${e.margins.bottom},${e.margins.left}`),t.push(`n:${e.number}`),e.footnoteReservedHeight&&t.push(`fn:${e.footnoteReservedHeight}`);for(let n of e.fragments){let o=`${n.kind}:${n.blockId},${n.x},${n.y},${n.width},${n.height}`;n.pmStart!==void 0&&(o+=`,ps:${n.pmStart}`),n.pmEnd!==void 0&&(o+=`,pe:${n.pmEnd}`),n.kind==="paragraph"?o+=`,fl:${n.fromLine},tl:${n.toLine}`:n.kind==="table"&&(o+=`,fr:${n.fromRow},tr:${n.toRow}`),t.push(o);}return t.join("|")}function Gt(e){let t=[];return e.headerContent&&t.push(`hdr:${e.headerContent.blocks.length},${e.headerContent.height},${e.headerContent.visualTop??0},${e.headerContent.visualBottom??e.headerContent.height}`),e.footerContent&&t.push(`ftr:${e.footerContent.blocks.length},${e.footerContent.height},${e.footerContent.visualTop??0},${e.footerContent.visualBottom??e.footerContent.height}`),e.firstPageHeaderContent&&t.push(`fp-hdr:${e.firstPageHeaderContent.blocks.length},${e.firstPageHeaderContent.height}`),e.firstPageFooterContent&&t.push(`fp-ftr:${e.firstPageFooterContent.blocks.length},${e.firstPageFooterContent.height}`),e.titlePg&&t.push("titlePg"),e.theme&&t.push(`thm:${e.theme.name??"default"}`),e.pageBorders&&t.push(`pb:${JSON.stringify(e.pageBorders)}`),e.headerDistance!==void 0&&t.push(`hd:${e.headerDistance}`),e.footerDistance!==void 0&&t.push(`fd:${e.footerDistance}`),t.join("|")}function jt(e,t){e.style.display="flex",e.style.flexDirection="column",e.style.alignItems="center",e.style.gap=`${t}px`,e.style.padding=`${t}px`,e.style.backgroundColor="var(--doc-bg, #f8f9fa)";}var he=2,Vt=8;function Kt(e,t,n={}){let o=e.length,r=n.pageGap??24,i=t,a=i.__pageRenderState,l=Gt(n),d=o>=Vt;if(a&&a.optionsHash===l&&d){let c=a.pageStates,p=a.pageDataMap,b=i.__pageObserver,u=[];for(let x of e)u.push(at(x));let T=a.totalPages!==o,k=Math.min(c.length,e.length);for(let x=0;x<k;x++){let C=c[x],I=u[x];if(C.fingerprint===I&&!T){let E=p.get(C.element);E&&(E.page=e[x]);continue}let S=C.element,w=p.get(S);w&&(w.page=e[x],w.rendered&&Yt(S,p,o,n)),C.fingerprint=I,re(S,e[x].size.w,e[x].size.h,n),S.dataset.pageNumber=String(e[x].number);}if(e.length>c.length){let x=n.document??document;for(let C=c.length;C<e.length;C++){let I=e[C],S=x.createElement("div");S.className=n.pageClassName??N.page,S.dataset.pageNumber=String(I.number),S.dataset.pageIndex=String(C),re(S,I.size.w,I.size.h,n),t.appendChild(S),c.push({element:S,fingerprint:u[C]}),p.set(S,{page:I,index:C,rendered:false}),b&&b.observe(S);}}if(e.length<c.length){for(let x=c.length-1;x>=e.length;x--){let C=c[x].element;b&&b.unobserve(C),p.delete(C),t.removeChild(C);}c.length=e.length;}for(let x=0;x<c.length;x++){let C=p.get(c[x].element);C&&(C.index=x);}return a.totalPages=o,a.currentOptions=n,"incremental"}let s=i.__pageObserver;s&&(s.disconnect(),i.__pageObserver=void 0),t.innerHTML="",i.__pageRenderState=void 0,jt(t,r);let g=[],F=[];for(let c=0;c<e.length;c++){let p=e[c];if(F.push(at(p)),d){let u=(n.document??document).createElement("div");u.className=n.pageClassName??N.page,u.dataset.pageNumber=String(p.number),u.dataset.pageIndex=String(c),re(u,p.size.w,p.size.h,n),t.appendChild(u),g.push(u);}else {let{context:b,pageOptions:u}=Le(p,o,n),T=ye(p,b,u);t.appendChild(T),g.push(T);}}if(!d)return "full";let y=new Map;for(let c=0;c<e.length;c++)y.set(g[c],{page:e[c],index:c,rendered:false});let m=new IntersectionObserver(c=>{let p=i.__pageRenderState;if(!p)return;let{currentOptions:b,totalPages:u,pageDataMap:T}=p;for(let I of c){let S=I.target,w=T.get(S);if(w&&I.isIntersecting){ue(S,T,u,b);for(let E=-he;E<=he;E++){let R=w.index+E;R>=0&&R<p.pageStates.length&&R!==w.index&&ue(p.pageStates[R].element,T,u,b);}}}let k=window.innerHeight,x=k*3,C=new Set;for(let[I,S]of T){if(!S.rendered)continue;let w=I.getBoundingClientRect();w.bottom>-x&&w.top<k+x&&C.add(S.index);}for(let[I,S]of T){if(!S.rendered)continue;let w=false;for(let E of C)if(Math.abs(S.index-E)<=he+1){w=true;break}!w&&C.size>0&&Ut(I,T);}},{root:null,rootMargin:"1500px 0px 1500px 0px"});for(let c of g)m.observe(c);i.__pageObserver=m,i.__pageRenderState={pageStates:g.map((c,p)=>({element:c,fingerprint:F[p]})),totalPages:o,optionsHash:l,pageDataMap:y,currentOptions:n};let h=Math.min(e.length,he+3);for(let c=0;c<h;c++)ue(g[c],y,o,n);return "full"}function ue(e,t,n,o){let r=t.get(e);if(!r||r.rendered)return;let{context:i,pageOptions:a}=Le(r.page,n,o),l=ye(r.page,i,a);for(;l.firstChild;)e.appendChild(l.firstChild);r.rendered=true;}function Yt(e,t,n,o){let r=t.get(e);if(!r)return;let{context:i,pageOptions:a}=Le(r.page,n,o),d=ye(r.page,i,a).querySelector(`.${N.content}`),f=e.querySelector(`.${N.content}`);d&&f?e.replaceChild(d,f):(e.innerHTML="",r.rendered=false,ue(e,t,n,o));}function Ut(e,t){let n=t.get(e);!n||!n.rendered||(e.innerHTML="",n.rendered=false);}var N={page:"layout-page",content:"layout-page-content",header:"layout-page-header",footer:"layout-page-footer"};function re(e,t,n,o){e.style.position="relative",e.style.width=`${t}px`,e.style.height=`${n}px`,e.style.backgroundColor=o.backgroundColor??"#ffffff",e.style.overflow="hidden",e.style.fontFamily=chunkN3Y5BUKV_js.a("Calibri").cssFallback,e.style.fontSize=`${1056/72}px`,e.style.color="#000000",o.showBorders&&(e.style.border="1px solid #ccc"),o.showShadow&&(e.style.boxShadow="0 2px 8px rgba(0, 0, 0, 0.15)");}function Xt(e,t){switch(t??"allPages"){case "firstPage":return e===1;case "notFirstPage":return e!==1;default:return true}}function be(e){return e?.space!==void 0?chunk4Q2IP5FW_js.i(e.space):0}function xe(e,t,n,o){if(!t||t.style==="none"||t.style==="nil")return;let r=chunkBHBOAP6Z_js.c(t,n,o);for(let[d,f]of Object.entries(r))e.style[d]=String(f);let i=`border${n}Style`,a=`border${n}Width`;if(e.style[i]==="double"){let d=parseFloat(e.style[a]);(!Number.isFinite(d)||d<3)&&(e.style[a]="3px");}}function Zt(e,t,n){let o=t.pageBorders;if(!o||!Xt(e.number,o.display)||![o.top,o.bottom,o.left,o.right].some(g=>g&&g.style!=="none"&&g.style!=="nil"))return null;let i=o.offsetFrom??"text",a=be(o.top),l=be(o.right),d=be(o.bottom),f=be(o.left),s=n.createElement("div");return s.className="layout-page-border",s.style.position="absolute",s.style.pointerEvents="none",s.style.boxSizing="border-box",s.style.zIndex=o.zOrder==="back"?"0":"20",i==="page"?(s.style.top=`${a}px`,s.style.right=`${l}px`,s.style.bottom=`${d}px`,s.style.left=`${f}px`):(s.style.top=`${Math.max(0,e.margins.top-a)}px`,s.style.right=`${Math.max(0,e.margins.right-l)}px`,s.style.bottom=`${Math.max(0,e.margins.bottom-d)}px`,s.style.left=`${Math.max(0,e.margins.left-f)}px`),xe(s,o.top,"Top",t.theme),xe(s,o.bottom,"Bottom",t.theme),xe(s,o.left,"Left",t.theme),xe(s,o.right,"Right",t.theme),s}function qt(e,t){let n=t.margins;e.style.position="absolute",e.style.top=`${n.top}px`,e.style.left=`${n.left}px`,e.style.right=`${n.right}px`,e.style.bottom=`${n.bottom}px`,e.style.overflow="visible";}function Jt(e,t,n){e.style.position="absolute",e.style.left=`${t.x-n.left}px`,e.style.top=`${t.y-n.top}px`,e.style.width=`${t.width}px`,"height"in t&&(e.style.height=`${t.height}px`);}function Qt(e,t,n,o){let r=[];for(let i of e.runs){if(i.kind!=="image")continue;let a=i;if(!chunkUGXSKZVM_js.f(a))continue;let l=a.distTop??0,d=a.distBottom??0,f=a.distLeft??12,s=a.distRight??12,{x:g,y:F,side:y}=Re(a,t,n,o);r.push({src:a.src,width:a.width,height:a.height,alt:a.alt,transform:a.transform,side:y,x:g,y:F,distTop:l,distBottom:d,distLeft:f,distRight:s,pmStart:a.pmStart,pmEnd:a.pmEnd,wrapText:chunkUGXSKZVM_js.h(a.cssFloat),wrapType:a.wrapType,cropTop:a.cropTop,cropRight:a.cropRight,cropBottom:a.cropBottom,cropLeft:a.cropLeft,opacity:a.opacity});}return r}function ye(e,t,n={}){let o=n.document??document,r=o.createElement("div");r.className=n.pageClassName??N.page,r.dataset.pageNumber=String(e.number),re(r,e.size.w,e.size.h,n);let i=Zt(e,n,o);i&&n.pageBorders?.zOrder==="back"&&r.appendChild(i);let a=o.createElement("div");a.className=N.content,qt(a,e);let l=Qe(e),d=l.contentWidth,f=[],s=[];for(let p of e.fragments)if(p.kind==="paragraph"&&n.blockLookup){let b=n.blockLookup.get(String(p.blockId));if(b?.block.kind==="paragraph"){let u=b.block,T=p.y-e.margins.top,k=Qt(u,T,d,l);f.push(...k);}}for(let p of f)chunkUGXSKZVM_js.d(p)&&s.push({side:p.side,x:p.x,y:p.y,width:p.width,height:p.height,distTop:p.distTop,distBottom:p.distBottom,distLeft:p.distLeft,distRight:p.distRight,wrapText:p.wrapText,wrapType:p.wrapType});if(n.blockLookup)for(let p of e.fragments){if(p.kind!=="table")continue;let b=n.blockLookup.get(String(p.blockId));if(b?.block.kind!=="table")continue;let T=b.block.floating;if(!T)continue;let k=p.x-e.margins.left,x=p.y-e.margins.top,C=T.topFromText??0,I=T.bottomFromText??0,S=T.leftFromText??12,w=T.rightFromText??12,E=k<d/2?"left":"right";s.push({side:E,x:k,y:x,width:p.width,height:p.height,distTop:C,distBottom:I,distLeft:S,distRight:w});}if(n.blockLookup)for(let p of e.fragments){if(p.kind!=="textBox")continue;let b=n.blockLookup.get(String(p.blockId));if(b?.block.kind!=="textBox")continue;let u=b.block;if(!chunkXBIKSAH6_js.E(u))continue;let T=p.y-e.margins.top,k=Re({width:p.width,height:p.height,position:u.position,cssFloat:u.cssFloat},T,d,l);p.x=e.margins.left+k.x,p.y=e.margins.top+k.y,chunkXBIKSAH6_js.F(u)&&s.push({side:k.side,x:k.x,y:k.y,width:p.width,height:p.height,distTop:u.distTop??0,distBottom:u.distBottom??0,distLeft:u.distLeft??12,distRight:u.distRight??12,wrapText:u.wrapText,wrapType:u.wrapType});}let g=s.length>0?chunkXBIKSAH6_js.p(s,d):[],F=f.filter(chunkUGXSKZVM_js.e),y=f.filter(p=>!chunkUGXSKZVM_js.e(p));if(F.length>0){let p=U(F,o,{layerClass:"layout-floating-images-layer",itemClass:"layout-page-floating-image",sizing:"inset0",layerMode:"behind"});a.appendChild(p);}let m=p=>{if(p.kind!=="paragraph"||!n.blockLookup||!p.blockId)return;let b=n.blockLookup.get(String(p.blockId));if(b?.block.kind==="paragraph")return b.block.attrs?.borders},h,c=new Map;for(let p=0;p<e.fragments.length;p++){let b=e.fragments[p],u,T={...t,section:"body",contentWidth:d},k=b.y-e.margins.top;if(n.blockLookup&&b.blockId){let x=n.blockLookup.get(String(b.blockId));if(b.kind==="paragraph"&&x?.block.kind==="paragraph"&&x?.measure.kind==="paragraph"){let C=x.block,I=p+1<e.fragments.length?m(e.fragments[p+1]):void 0,S=String(b.blockId),w=c.get(S);w||(w=new Set,c.set(S,w));let E=x.measure;g.length>0&&(E=chunkXBIKSAH6_js.v(C,d,{floatingZones:g,paragraphYOffset:k})),u=H(b,C,E,T,{document:o,prevBorders:h,nextBorders:I,renderedInlineImageKeys:w}),h=C.attrs?.borders;}else b.kind==="table"&&x?.block.kind==="table"&&x?.measure.kind==="table"?(u=q(b,x.block,x.measure,T,{document:o}),h=void 0):b.kind==="image"&&x?.block.kind==="image"&&x?.measure.kind==="image"?(u=Z(b,x.block,x.measure,T,{document:o}),h=void 0):b.kind==="textBox"&&x?.block.kind==="textBox"&&x?.measure.kind==="textBox"?(u=J(b,x.block,x.measure,T,{document:o}),h=void 0):(u=Te(b,T,{document:o}),h=void 0);}else u=Te(b,T,{document:o}),h=void 0;Jt(u,b,{left:e.margins.left,top:e.margins.top}),a.appendChild(u);}if(y.length>0){let p=U(y,o,{layerClass:"layout-floating-images-layer",itemClass:"layout-page-floating-image",sizing:"inset0",layerMode:"front"});a.appendChild(p);}if(e.columns&&e.columns.separator&&e.columns.count>1){let p=e.columns.count,b=e.columns.gap,u=(d-(p-1)*b)/p,T=e.size.h-e.margins.top-e.margins.bottom;for(let k=0;k<p-1;k++){let x=(k+1)*u+k*b+b/2,C=o.createElement("div");C.style.position="absolute",C.style.left=`${x}px`,C.style.top="0",C.style.height=`${T}px`,C.style.width="0.5px",C.style.backgroundColor="#000",C.style.pointerEvents="none",a.appendChild(C);}}if(n.footnoteArea&&n.footnoteArea.length>0){let p=it(n.footnoteArea,d,t,o);p.style.position="absolute";let b=Math.max(e.footnoteReservedHeight??0,rt(n.footnoteArea)),u=e.size.h-e.margins.bottom-e.margins.top;p.style.top=`${Math.max(-e.margins.top,u-b)}px`,p.style.left="0",p.style.right="0",a.appendChild(p);}r.appendChild(a);{let b=n.headerDistance??e.margins.header??48,u=e.size.w-e.margins.left-e.margins.right,T=Math.max(e.margins.top-b,48),k=n.headerContent?.visualTop??0,x=n.headerContent?.visualBottom??n.headerContent?.height??0,C=Math.max(x-k,24),I=x>T,S=o.createElement("div");S.className=N.header,S.style.position="absolute",S.style.top=`${b+k}px`,S.style.left=`${e.margins.left}px`,S.style.right=`${e.margins.right}px`,S.style.width=`${u}px`,S.style.height=`${C}px`,S.style.minHeight=`${C}px`;let w=!I;if(n.headerContent&&n.headerContent.blocks.length>0){let E={flowTop:b,flowLeft:e.margins.left,contentWidth:u,pageWidth:e.size.w,pageHeight:e.size.h,margins:e.margins},R=Ie(n.headerContent,{...t,section:"header",contentWidth:u},n,E);R.style.top=`${-k}px`,R.querySelector("img")&&(w=false),S.appendChild(R);}w&&(S.style.maxHeight=`${T}px`,S.style.overflow="hidden"),r.appendChild(S);}{let b=n.footerDistance??e.margins.footer??48,u=e.size.w-e.margins.left-e.margins.right,T=Math.max(e.margins.bottom-b,48),k=n.footerContent?.visualTop??0,x=n.footerContent?.visualBottom??n.footerContent?.height??0,C=Math.max(x-k,24),I=C>T,S=o.createElement("div");S.className=N.footer,S.style.position="absolute",S.style.top=`${e.size.h-b-C}px`,S.style.left=`${e.margins.left}px`,S.style.right=`${e.margins.right}px`,S.style.width=`${u}px`,S.style.height=`${C}px`,S.style.minHeight=`${C}px`;let w=!I;if(n.footerContent&&n.footerContent.blocks.length>0){let E={flowTop:e.size.h-b-(n.footerContent?.height??0),flowLeft:e.margins.left,contentWidth:u,pageWidth:e.size.w,pageHeight:e.size.h,margins:e.margins},R=Ie(n.footerContent,{...t,section:"footer",contentWidth:u},n,E);R.style.top=`${-k}px`,R.querySelector("img")&&(w=false),S.appendChild(R);}w&&(S.style.maxHeight=`${T}px`,S.style.overflow="hidden"),r.appendChild(S);}return i&&n.pageBorders?.zOrder!=="back"&&r.appendChild(i),r}exports.A=re;exports.B=ye;exports.a=me;exports.b=nt;exports.c=Ot;exports.d=Kn;exports.e=Pe;exports.f=Nt;exports.g=Dt;exports.h=Yn;exports.i=ot;exports.j=Un;exports.k=Xn;exports.l=K;exports.m=Te;exports.n=je;exports.o=Z;exports.p=qe;exports.q=ge;exports.r=H;exports.s=U;exports.t=O;exports.u=q;exports.v=Lt;exports.w=J;exports.x=tt;exports.y=Kt;exports.z=N;
@@ -0,0 +1,4 @@
1
+ import {h,j as j$2,k,g,z}from'./chunk-QVEAQOMR.mjs';import {c as c$1}from'./chunk-HL5PQT3A.mjs';import {c,j as j$1,e,l,i,a,f,m,d,b,n,k as k$1}from'./chunk-B6LYBJ4H.mjs';var He={dk1:"000000",lt1:"FFFFFF",dk2:"44546A",lt2:"E7E6E6",accent1:"4472C4",accent2:"ED7D31",accent3:"A5A5A5",accent4:"FFC000",accent5:"5B9BD5",accent6:"70AD47",hlink:"0563C1",folHlink:"954F72"},Q={majorFont:{latin:"Calibri Light",ea:"",cs:"",fonts:{}},minorFont:{latin:"Calibri",ea:"",cs:"",fonts:{}}},me={name:"Office Theme",colorScheme:He,fontScheme:Q},ut=["dk1","lt1","dk2","lt2","accent1","accent2","accent3","accent4","accent5","accent6","hlink","folHlink"];function ft(e){if(!e)return null;switch(d(e.name||"")){case "srgbClr":return j$1(e,"a","val")??j$1(e,null,"val")??null;case "sysClr":{let n=j$1(e,"a","lastClr")??j$1(e,null,"lastClr");if(n)return n;switch(j$1(e,"a","val")??j$1(e,null,"val")){case "windowText":case "menuText":case "captionText":case "btnText":return "000000";case "window":case "menu":case "btnFace":case "btnHighlight":return "FFFFFF";case "highlight":return "0078D7";case "highlightText":return "FFFFFF";case "grayText":return "808080";default:return null}}case "schemeClr":{j$1(e,"a","val")??j$1(e,null,"val");return null}default:return null}}function ct(e$1){let t={...He};if(!e$1)return t;for(let n of ut){let r=e(e$1,"a",n);if(r){let o=i(r);if(o.length>0){let a=ft(o[0]);a&&(t[n]=a);}}}return t}function Be(e$1){let t={latin:"",ea:"",cs:"",fonts:{}};if(!e$1)return t;let n=e(e$1,"a","latin");n&&(t.latin=j$1(n,"a","typeface")??j$1(n,null,"typeface")??"");let r=e(e$1,"a","ea");r&&(t.ea=j$1(r,"a","typeface")??j$1(r,null,"typeface")??"");let o=e(e$1,"a","cs");o&&(t.cs=j$1(o,"a","typeface")??j$1(o,null,"typeface")??"");let a=f(e$1,"a","font");for(let u of a){let l=j$1(u,"a","script")??j$1(u,null,"script"),f=j$1(u,"a","typeface")??j$1(u,null,"typeface");l&&f&&(t.fonts=t.fonts||{},t.fonts[l]=f);}return t}function pt(e$1){let t={...Q};if(!e$1)return t;let n=e(e$1,"a","majorFont");n&&(t.majorFont=Be(n));let r=e(e$1,"a","minorFont");return r&&(t.minorFont=Be(r)),t}function xn(e$1){if(!e$1)return {...me};try{let t=c(e$1);if(!t)return {...me};let n=j$1(t,"a","name")??j$1(t,null,"name")??"Office Theme",r=e(t,"a","themeElements"),o=e(r,"a","clrScheme"),a=ct(o),u=e(r,"a","fontScheme"),l=pt(u);return {name:n,colorScheme:a,fontScheme:l}}catch(t){return console.warn("Failed to parse theme:",t),{...me}}}function dt(e,t="latin"){if(!e?.fontScheme?.majorFont)return Q.majorFont?.latin??"Calibri Light";let n=e.fontScheme.majorFont;return t==="latin"?n.latin||"Calibri Light":t==="ea"?n.ea||"":t==="cs"?n.cs||"":n.fonts?.[t]?n.fonts[t]:n.latin||"Calibri Light"}function ve(e,t="latin"){if(!e?.fontScheme?.minorFont)return Q.minorFont?.latin??"Calibri";let n=e.fontScheme.minorFont;return t==="latin"?n.latin||"Calibri":t==="ea"?n.ea||"":t==="cs"?n.cs||"":n.fonts?.[t]?n.fonts[t]:n.latin||"Calibri"}function _(e,t){if(!t)return "Calibri";let n=t.toLowerCase().includes("major"),r=t.toLowerCase().includes("minor"),o="latin",a=t.toLowerCase();return a.includes("eastasia")?o="ea":(a.includes("bidi")||a.includes("cs"))&&(o="cs"),n?dt(e,o):r?ve(e,o):ve(e,"latin")}function Ae(e){if(!e)return;let t=l(e,"w","w")??0,n=j$1(e,"w","type")??"dxa",r="dxa";return (n==="auto"||n==="dxa"||n==="nil"||n==="pct")&&(r=n),{value:t,type:r}}function X(e){return Ae(e)}function W(e){let t=j$1(e,"w","id"),n=t?parseInt(t,10):0,r=(j$1(e,"w","author")??"").trim(),o=(j$1(e,"w","date")??"").trim();return {id:Number.isInteger(n)&&n>=0?n:0,author:r.length>0?r:"Unknown",date:o.length>0?o:void 0}}function J(e){let t=W(e),n=(j$1(e,"w","rsid")??"").trim();return n.length>0?{...t,rsid:n}:t}function D(e){if(!e)return;let r={style:j$1(e,"w","val")??"none"},o=l(e,"w","sz");o!==void 0&&(r.size=o);let a=l(e,"w","space");a!==void 0&&(r.space=a);let u=j$1(e,"w","color"),l$1=j$1(e,"w","themeColor"),f=j$1(e,"w","themeTint"),c=j$1(e,"w","themeShade");(u||l$1||f||c)&&(r.color={rgb:u??void 0,themeColor:l$1,themeTint:f??void 0,themeShade:c??void 0});let p=j$1(e,"w","shadow");(p==="1"||p==="true")&&(r.shadow=true);let d=j$1(e,"w","frame");return (d==="1"||d==="true")&&(r.frame=true),r}function ee(e$1){if(!e$1)return;let t={},n=D(e(e$1,"w","top"));n&&(t.top=n);let r=D(e(e$1,"w","bottom"));r&&(t.bottom=r);let o=D(e(e$1,"w","left")??e(e$1,"w","start"));o&&(t.left=o);let a=D(e(e$1,"w","right")??e(e$1,"w","end"));a&&(t.right=a);let u=D(e(e$1,"w","insideH"));u&&(t.insideH=u);let l=D(e(e$1,"w","insideV"));if(l&&(t.insideV=l),Object.keys(t).length!==0)return t}function te(e$1){if(!e$1)return;let t={},n=X(e(e$1,"w","top"));n&&(t.top=n);let r=X(e(e$1,"w","bottom"));r&&(t.bottom=r);let o=X(e(e$1,"w","left")??e(e$1,"w","start"));o&&(t.left=o);let a=X(e(e$1,"w","right")??e(e$1,"w","end"));if(a&&(t.right=a),Object.keys(t).length!==0)return t}function ne(e){if(!e)return;let t={},n=j$1(e,"w","fill");n&&n!=="auto"&&(t.fill={rgb:n});let r=j$1(e,"w","themeFill");if(r){t.fill={themeColor:r};let u=j$1(e,"w","themeFillTint");u&&t.fill&&(t.fill.themeTint=u);let l=j$1(e,"w","themeFillShade");l&&t.fill&&(t.fill.themeShade=l);}let o=j$1(e,"w","color");o&&o!=="auto"&&(t.color={rgb:o});let a=j$1(e,"w","val");if(a&&(t.pattern=a),Object.keys(t).length!==0)return t}function ge(e){if(!e)return;let t={},n=j$1(e,"w","firstRow");(n==="1"||n==="true")&&(t.firstRow=true);let r=j$1(e,"w","lastRow");(r==="1"||r==="true")&&(t.lastRow=true);let o=j$1(e,"w","firstColumn");(o==="1"||o==="true")&&(t.firstColumn=true);let a=j$1(e,"w","lastColumn");(a==="1"||a==="true")&&(t.lastColumn=true);let u=j$1(e,"w","noHBand");(u==="1"||u==="true")&&(t.noHBand=true);let l=j$1(e,"w","noVBand");(l==="1"||l==="true")&&(t.noVBand=true);let f=j$1(e,"w","val");if(f){let c=parseInt(f,16);isNaN(c)||(c&32&&(t.firstRow=true),c&64&&(t.lastRow=true),c&128&&(t.firstColumn=true),c&256&&(t.lastColumn=true),c&512&&(t.noHBand=true),c&1024&&(t.noVBand=true));}if(Object.keys(t).length!==0)return t}function he(e){if(!e)return;let t={},n=j$1(e,"w","horzAnchor");(n==="margin"||n==="page"||n==="text")&&(t.horzAnchor=n);let r=j$1(e,"w","vertAnchor");(r==="margin"||r==="page"||r==="text")&&(t.vertAnchor=r);let o=l(e,"w","tblpX");o!==void 0&&(t.tblpX=o);let a=j$1(e,"w","tblpXSpec");a&&(t.tblpXSpec=a);let u=l(e,"w","tblpY");u!==void 0&&(t.tblpY=u);let l$1=j$1(e,"w","tblpYSpec");l$1&&(t.tblpYSpec=l$1);let f=l(e,"w","topFromText");f!==void 0&&(t.topFromText=f);let c=l(e,"w","bottomFromText");c!==void 0&&(t.bottomFromText=c);let p=l(e,"w","leftFromText");p!==void 0&&(t.leftFromText=p);let d=l(e,"w","rightFromText");if(d!==void 0&&(t.rightFromText=d),Object.keys(t).length!==0)return t}function mt(e){return e.columnWidths&&e.columnWidths.length>0?e.columnWidths.length:e.rows.length===0?0:e.rows[0].cells.reduce((t,n)=>t+(n.formatting?.gridSpan??1),0)}function gt(e){return e.rows.length}function ht(e){return e.formatting?.vMerge==="continue"}function wt(e){return e.formatting?.vMerge==="restart"}function yt(e){return e.rows.length===0?false:e.rows[0].formatting?.header===true}var Ne={183:"\u2022",111:"\u25CB",167:"\u25A0",252:"\u2713",110:"\u25A0",113:"\u25CB",117:"\u25C6",118:"\u2756",168:"\u2713",251:"\u2713",254:"\u2713",61623:"\u2022",61550:"\u25A0",61551:"\u25CB",61607:"\u25A0",61692:"\u2713",8226:"\u2022",9679:"\u25CF",9675:"\u25CB",9632:"\u25A0",9633:"\u25A1",9670:"\u25C6",9671:"\u25C7",8211:"\u2013",8212:"\u2014",62:">",45:"-"};function bt(e){if(!e||e.trim()==="")return "\u2022";let t=e.charCodeAt(0);return Ne[t]?Ne[t]:t>=57344&&t<=63743||t<32||t>=127&&t<160?"\u2022":e}function Tt(e){let t=e.listRendering;t&&t.isBullet&&(t.marker=bt(t.marker||""));}function Ft(e,t,n$1,r,o,a,u){if(e.content.length===0)return;let l=i(t),f=0;function c(p){if(!h(p))return;let d=j$2(p);if(!d)return;let b=n(p,"wps","wsp");if(b){let C=k(b);C&&(d.content=g(C,j,null,n$1,r,o,a??void 0,u??void 0));}let F={type:"shape",shapeType:"rect",size:d.size,position:d.position,wrap:d.wrap,fill:d.fill,outline:d.outline,textBody:{content:d.content,margins:d.margins}};d.id&&(F.id=d.id);let y={type:"shape",shape:F},h$1=f;if(h$1>=e.content.length){h$1=-1;for(let C=e.content.length-1;C>=0;C--)if(e.content[C].type==="run"){h$1=C;break}}if(h$1>=0){let C=e.content[h$1];C.type==="run"&&C.content.push(y);}}for(let p of l){if(d(p.name??"")!=="r")continue;let d$1=i(p);for(let b of d$1){let F=d(b.name??"");if(F==="drawing")c(b);else if(F==="AlternateContent"){let y=i(b),C=y.find(A=>d(A.name??"")==="Choice")??y.find(A=>d(A.name??"")==="Fallback");if(C)for(let A of i(C))d(A.name??"")==="drawing"&&c(A);}}f++;}}function re(e,t,n,r,o,a,u){let l=[],f=i(e);for(let c of f){let p=c.name??"";if(p==="w:p"||p.endsWith(":p")){let d=j(c,t,n,r,o,a,u);Ft(d,c,t,n,r,o,a),Tt(d),l.push(d);}else if(p==="w:tbl"||p.endsWith(":tbl")){let d=Y(c,t,n,r,o,a,u);l.push(d);}else if(p==="w:sdt"||p.endsWith(":sdt")){let d=(c.elements??[]).find(b=>b.type==="element"&&(b.name==="w:sdtContent"||b.name?.endsWith(":sdtContent")));d&&l.push(...re(d,t,n,r,o,a,u));}}return l}function Ie(e){switch(e){case "first":return "first";case "even":return "even";default:return "default"}}function Le(e){let t=j$1(e,"w","type"),n=j$1(e,"r","id")??"";return {type:Ie(t),rId:n}}function Xe(e){let t=j$1(e,"w","type"),n=j$1(e,"r","id")??"";return {type:Ie(t),rId:n}}function In(e,t="default",n=null,r=null,o=null,a$1=null,u=null){let l={type:"header",hdrFtrType:t,content:[]};if(!e)return l;let f=a(e);if(!f)return l;let c=f.elements?.find(p=>p.type==="element"&&(p.name==="w:hdr"||p.name?.endsWith(":hdr")));return c&&(l.content=re(c,n,r,o,a$1,u,{inHeaderFooter:true})),l}function Ln(e,t="default",n=null,r=null,o=null,a$1=null,u=null){let l={type:"footer",hdrFtrType:t,content:[]};if(!e)return l;let f=a(e);if(!f)return l;let c=f.elements?.find(p=>p.type==="element"&&(p.name==="w:ftr"||p.name?.endsWith(":ftr")));return c&&(l.content=re(c,n,r,o,a$1,u,{inHeaderFooter:true})),l}function Oe(e){switch(e){case "separator":return "separator";case "continuationSeparator":return "continuationSeparator";case "continuationNotice":return "continuationNotice";default:return "normal"}}function De(e,t,n,r,o,a){let u=[];for(let l of i(e)){let f=l.name??"";f==="w:p"?u.push(j(l,t,n,r,o)):f==="w:tbl"&&u.push(Y(l,t,n,r,o,a));}return u}function Ct(e,t,n,r,o,a){let u=l(e,"w","id")??0,l$1=j$1(e,"w","type"),f=Oe(l$1),c=De(e,t,n,r,o,a);return {type:"footnote",id:u,noteType:f,content:c}}function jn(e,t=null,n=null,r=null,o=null,a$1=null){let u=new Map,l=[];if(!e)return oe(u,l);let f$1=a(e);if(!f$1)return oe(u,l);let c=f$1.elements?.find(d=>d.type==="element"&&(d.name==="w:footnotes"||d.name?.endsWith(":footnotes")));if(!c)return oe(u,l);let p=f(c,"w","footnote");for(let d of p){let b=Ct(d,t,n,r,o,a$1);u.set(b.id,b),l.push(b);}return oe(u,l)}function oe(e,t){return {byId:e,footnotes:t,getFootnote(n){return e.get(n)},hasFootnote(n){return e.has(n)},getNormalFootnotes(){return t.filter(n=>n.noteType==="normal")},getSeparator(){return t.find(n=>n.noteType==="separator")},getContinuationSeparator(){return t.find(n=>n.noteType==="continuationSeparator")}}}function xt(e,t,n,r,o,a){let u=l(e,"w","id")??0,l$1=j$1(e,"w","type"),f=Oe(l$1),c=De(e,t,n,r,o,a);return {type:"endnote",id:u,noteType:f,content:c}}function Vn(e,t=null,n=null,r=null,o=null,a$1=null){let u=new Map,l=[];if(!e)return ie(u,l);let f$1=a(e);if(!f$1)return ie(u,l);let c=f$1.elements?.find(d=>d.type==="element"&&(d.name==="w:endnotes"||d.name?.endsWith(":endnotes")));if(!c)return ie(u,l);let p=f(c,"w","endnote");for(let d of p){let b=xt(d,t,n,r,o,a$1);u.set(b.id,b),l.push(b);}return ie(u,l)}function ie(e,t){return {byId:e,endnotes:t,getEndnote(n){return e.get(n)},hasEndnote(n){return e.has(n)},getNormalEndnotes(){return t.filter(n=>n.noteType==="normal")},getSeparator(){return t.find(n=>n.noteType==="separator")},getContinuationSeparator(){return t.find(n=>n.noteType==="continuationSeparator")}}}function We(e){return e?{decimal:"decimal",upperRoman:"upperRoman",lowerRoman:"lowerRoman",upperLetter:"upperLetter",lowerLetter:"lowerLetter",ordinal:"ordinal",cardinalText:"cardinalText",ordinalText:"ordinalText",bullet:"bullet",chicago:"chicago",none:"none"}[e]:void 0}function St(e){switch(e){case "pageBottom":return "pageBottom";case "beneathText":return "beneathText";case "sectEnd":return "sectEnd";case "docEnd":return "docEnd";default:return}}function kt(e){switch(e){case "sectEnd":return "sectEnd";case "docEnd":return "docEnd";default:return}}function je(e){switch(e){case "continuous":return "continuous";case "eachSect":return "eachSect";case "eachPage":return "eachPage";default:return}}function Ve(e$1){let t={};if(!e$1)return t;let n=e(e$1,"w","pos");if(n){let u=j$1(n,"w","val");t.position=St(u);}let r=e(e$1,"w","numFmt");if(r){let u=j$1(r,"w","val");t.numFmt=We(u);}let o=e(e$1,"w","numStart");o&&(t.numStart=l(o,"w","val")??void 0);let a=e(e$1,"w","numRestart");if(a){let u=j$1(a,"w","val");t.numRestart=je(u);}return t}function ze(e$1){let t={};if(!e$1)return t;let n=e(e$1,"w","pos");if(n){let u=j$1(n,"w","val");t.position=kt(u);}let r=e(e$1,"w","numFmt");if(r){let u=j$1(r,"w","val");t.numFmt=We(u);}let o=e(e$1,"w","numStart");o&&(t.numStart=l(o,"w","val")??void 0);let a=e(e$1,"w","numRestart");if(a){let u=j$1(a,"w","val");t.numRestart=je(u);}return t}function zn(e){let t=[];for(let n of e.content){if(n.type!=="paragraph")continue;let r=[];for(let o of n.content)if(o.type==="run")for(let a of o.content)a.type==="text"&&r.push(a.text);t.push(r.join(""));}return t.join(`
2
+ `)}function Un(e){let t=[];for(let n of e.content){if(n.type!=="paragraph")continue;let r=[];for(let o of n.content)if(o.type==="run")for(let a of o.content)a.type==="text"&&r.push(a.text);t.push(r.join(""));}return t.join(`
3
+ `)}function Gn(e){return e.noteType==="separator"||e.noteType==="continuationSeparator"||e.noteType==="continuationNotice"}function qn(e){return e.noteType==="separator"||e.noteType==="continuationSeparator"||e.noteType==="continuationNotice"}function Rt(e,t,n,r){if(!e&&!t)return;let o={};return e&&e!=="auto"?o.rgb=e:e==="auto"&&(o.auto=true),t&&(o.themeColor=t),n&&(o.themeTint=n),r&&(o.themeShade=r),Object.keys(o).length>0?o:void 0}function ae(e){if(!e)return;let r={style:j$1(e,"w","val")??"none"},o=l(e,"w","sz");o!==void 0&&(r.size=o);let a=l(e,"w","space");a!==void 0&&(r.space=a);let u=j$1(e,"w","color"),l$1=j$1(e,"w","themeColor"),f=j$1(e,"w","themeTint"),c=j$1(e,"w","themeShade"),p=Rt(u,l$1,f,c);p&&(r.color=p);let d=j$1(e,"w","shadow");(d==="1"||d==="true")&&(r.shadow=true);let b=j$1(e,"w","frame");return (b==="1"||b==="true")&&(r.frame=true),r}function Mt(e){switch(e){case "landscape":return "landscape";case "portrait":return "portrait";default:return}}function Et(e){switch(e){case "continuous":return "continuous";case "nextPage":return "nextPage";case "oddPage":return "oddPage";case "evenPage":return "evenPage";case "nextColumn":return "nextColumn";default:return}}function Pt(e){switch(e){case "top":return "top";case "center":return "center";case "both":return "both";case "bottom":return "bottom";default:return}}function Bt(e){switch(e){case "continuous":return "continuous";case "newPage":return "newPage";case "newSection":return "newSection";default:return}}function Ge(e$1,t){let n={};if(!e$1)return n;let r=e(e$1,"w","pgSz");if(r){let m=l(r,"w","w");m!==void 0&&(n.pageWidth=m);let T=l(r,"w","h");T!==void 0&&(n.pageHeight=T);let E=j$1(r,"w","orient"),w=Mt(E);w&&(n.orientation=w);}let o=e(e$1,"w","pgMar");if(o){let m=l(o,"w","top");m!==void 0&&(n.marginTop=m);let T=l(o,"w","bottom");T!==void 0&&(n.marginBottom=T);let E=l(o,"w","left");E!==void 0&&(n.marginLeft=E);let w=l(o,"w","right");w!==void 0&&(n.marginRight=w);let x=l(o,"w","header");x!==void 0&&(n.headerDistance=x);let P=l(o,"w","footer");P!==void 0&&(n.footerDistance=P);let B=l(o,"w","gutter");B!==void 0&&(n.gutter=B);}let a=e(e$1,"w","cols");if(a){let m=l(a,"w","num");m!==void 0&&(n.columnCount=m);let T=l(a,"w","space");T!==void 0&&(n.columnSpace=T);let E=j$1(a,"w","equalWidth");E==="1"||E==="true"?n.equalWidth=true:(E==="0"||E==="false")&&(n.equalWidth=false);let w=j$1(a,"w","sep");(w==="1"||w==="true")&&(n.separator=true);let x=f(a,"w","col");if(x.length>0){n.columns=[];for(let P of x){let B={},I=l(P,"w","w");I!==void 0&&(B.width=I);let N=l(P,"w","space");N!==void 0&&(B.space=N),n.columns.push(B);}n.columnCount===void 0&&(n.columnCount=x.length);}}let u=e(e$1,"w","type");if(u){let m=j$1(u,"w","val"),T=Et(m);T&&(n.sectionStart=T);}let l$1=e(e$1,"w","vAlign");if(l$1){let m=j$1(l$1,"w","val"),T=Pt(m);T&&(n.verticalAlign=T);}let f$1=e(e$1,"w","bidi");f$1&&(n.bidi=m(f$1));let c=f(e$1,"w","headerReference");c.length>0&&(n.headerReferences=c.map(m=>Le(m)));let p=f(e$1,"w","footerReference");p.length>0&&(n.footerReferences=p.map(m=>Xe(m)));let d=e(e$1,"w","titlePg");d&&(n.titlePg=m(d));let b=e(e$1,"w","evenAndOddHeaders");b&&(n.evenAndOddHeaders=m(b));let F=e(e$1,"w","lnNumType");if(F){n.lineNumbers={};let m=l(F,"w","start");m!==void 0&&(n.lineNumbers.start=m);let T=l(F,"w","countBy");T!==void 0&&(n.lineNumbers.countBy=T);let E=l(F,"w","distance");E!==void 0&&(n.lineNumbers.distance=E);let w=j$1(F,"w","restart"),x=Bt(w);x&&(n.lineNumbers.restart=x);}let y=e(e$1,"w","pgBorders");if(y){n.pageBorders={};let m=ae(e(y,"w","top"));m&&(n.pageBorders.top=m);let T=ae(e(y,"w","bottom"));T&&(n.pageBorders.bottom=T);let E=ae(e(y,"w","left"));E&&(n.pageBorders.left=E);let w=ae(e(y,"w","right"));w&&(n.pageBorders.right=w);let x=j$1(y,"w","display");(x==="allPages"||x==="firstPage"||x==="notFirstPage")&&(n.pageBorders.display=x);let P=j$1(y,"w","offsetFrom");(P==="page"||P==="text")&&(n.pageBorders.offsetFrom=P);let B=j$1(y,"w","zOrder");(B==="front"||B==="back")&&(n.pageBorders.zOrder=B);}let h=e(e$1,"w","background");if(h){n.background={};let m=j$1(h,"w","color");m&&m!=="auto"&&(n.background.color={rgb:m});let T=j$1(h,"w","themeColor");T&&(n.background.themeColor=T);let E=j$1(h,"w","themeTint");E&&(n.background.themeTint=E);let w=j$1(h,"w","themeShade");w&&(n.background.themeShade=w);}let C=e(e$1,"w","footnotePr");if(C){let m=Ve(C);Object.keys(m).length>0&&(n.footnotePr=m);}let A=e(e$1,"w","endnotePr");if(A){let m=ze(A);Object.keys(m).length>0&&(n.endnotePr=m);}let R=e(e$1,"w","docGrid");if(R){n.docGrid={};let m=j$1(R,"w","type");(m==="default"||m==="lines"||m==="linesAndChars"||m==="snapToChars")&&(n.docGrid.type=m);let T=l(R,"w","linePitch");T!==void 0&&(n.docGrid.linePitch=T);let E=l(R,"w","charSpace");E!==void 0&&(n.docGrid.charSpace=E);}let S=e(e$1,"w","paperSrc");if(S){let m=l(S,"w","first");m!==void 0&&(n.paperSrcFirst=m);let T=l(S,"w","other");T!==void 0&&(n.paperSrcOther=T);}return n}function Kn(){return {pageWidth:12240,pageHeight:15840,orientation:"portrait",marginTop:1440,marginBottom:1440,marginLeft:1440,marginRight:1440,headerDistance:720,footerDistance:720,gutter:0,columnCount:1,columnSpace:720,equalWidth:true,sectionStart:"nextPage",verticalAlign:"top"}}function Ue(e,t){if(!t||t.length===0)return e;let n=new Set((e??[]).map(o=>o.type)),r=t.filter(o=>!n.has(o.type));return r.length===0?e:[...e??[],...r]}function Qn(e){if(e.length<2)return e;let t=[e[0]];for(let n=1;n<e.length;n++){let r=t[n-1].properties,o=e[n].properties,a=Ue(o.headerReferences,r.headerReferences),u=Ue(o.footerReferences,r.footerReferences),l=o.titlePg!==void 0?o.titlePg:r.titlePg;if(a===o.headerReferences&&u===o.footerReferences&&l===o.titlePg){t.push(e[n]);continue}t.push({...e[n],properties:{...o,headerReferences:a,footerReferences:u,titlePg:l}});}return t}function vt(e,t){return !e&&!t?true:!(!e||!t||e.bold!==t.bold||e.boldCs!==t.boldCs||e.italic!==t.italic||e.italicCs!==t.italicCs||e.strike!==t.strike||e.doubleStrike!==t.doubleStrike||e.smallCaps!==t.smallCaps||e.allCaps!==t.allCaps||e.hidden!==t.hidden||e.emboss!==t.emboss||e.imprint!==t.imprint||e.outline!==t.outline||e.shadow!==t.shadow||e.rtl!==t.rtl||e.cs!==t.cs||e.fontSize!==t.fontSize||e.fontSizeCs!==t.fontSizeCs||e.spacing!==t.spacing||e.position!==t.position||e.scale!==t.scale||e.kerning!==t.kerning||e.vertAlign!==t.vertAlign||e.highlight!==t.highlight||e.effect!==t.effect||e.emphasisMark!==t.emphasisMark||e.styleId!==t.styleId||!Ht(e.underline,t.underline)||!le(e.color,t.color)||!At(e.shading,t.shading)||!Nt(e.fontFamily,t.fontFamily))}function Ht(e,t){return !e&&!t?true:!e||!t||e.style!==t.style?false:le(e.color,t.color)}function le(e,t){return !e&&!t?true:!e||!t?false:e.rgb===t.rgb&&e.auto===t.auto&&e.themeColor===t.themeColor&&e.themeTint===t.themeTint&&e.themeShade===t.themeShade}function At(e,t){return !e&&!t?true:!(!e||!t||e.pattern!==t.pattern||!le(e.color,t.color)||!le(e.fill,t.fill))}function Nt(e,t){return !e&&!t?true:!e||!t?false:e.ascii===t.ascii&&e.hAnsi===t.hAnsi&&e.eastAsia===t.eastAsia&&e.cs===t.cs&&e.asciiTheme===t.asciiTheme&&e.hAnsiTheme===t.hAnsiTheme&&e.eastAsiaTheme===t.eastAsiaTheme&&e.csTheme===t.csTheme}function It(e){return e.type==="text"||e.type==="softHyphen"||e.type==="noBreakHyphen"}function qe(e){return e.content.length===0?true:e.content.every(It)}function Lt(e,t){let n=[];for(let r of e)n.push(r);if(n.length>0&&t.length>0&&n[n.length-1].type==="text"&&t[0].type==="text"){let r=n[n.length-1],o=t[0];n[n.length-1]={type:"text",text:r.text+o.text,preserveSpace:r.preserveSpace||o.preserveSpace||void 0};for(let a=1;a<t.length;a++)n.push(t[a]);}else for(let r of t)n.push(r);return n}function Xt(e){if(e.length<=1)return e;let t=[],n=null;for(let r of e)if(r.content.length!==0){if(n===null){n={...r,content:[...r.content]};continue}qe(n)&&qe(r)&&vt(n.formatting,r.formatting)?n={type:"run",formatting:n.formatting,content:Lt(n.content,r.content)}:(t.push(n),n={...r,content:[...r.content]});}return n!==null&&t.push(n),t}function we(e){if(e.length<=1)return e;let t=[],n=[];function r(){if(n.length>0){let o=Xt(n);t.push(...o),n.length=0;}}for(let o of e)if(o.type==="run")n.push(o);else if(r(),o.type==="hyperlink"){let a={...o,children:we(o.children)};t.push(a);}else t.push(o);return r(),t}function _e(e,t,n,r){let o={};return e&&e!=="auto"?o.rgb=e:e==="auto"&&(o.auto=true),t&&(o.themeColor=t),n&&(o.themeTint=n),r&&(o.themeShade=r),o}function Ot(e){if(!e)return;let t={},n=j$1(e,"w","color");n&&n!=="auto"&&(t.color={rgb:n});let r=j$1(e,"w","fill");r&&r!=="auto"&&(t.fill={rgb:r});let o=j$1(e,"w","themeFill");o&&(t.fill=t.fill||{},t.fill.themeColor=o);let a=j$1(e,"w","themeFillTint");a&&t.fill&&(t.fill.themeTint=a);let u=j$1(e,"w","themeFillShade");u&&t.fill&&(t.fill.themeShade=u);let l=j$1(e,"w","val");return l&&(t.pattern=l),Object.keys(t).length>0?t:void 0}function ue(e$1,t,n){if(!e$1)return;let r={},o=e(e$1,"w","b");o&&(r.bold=m(o));let a=e(e$1,"w","bCs");a&&(r.boldCs=m(a));let u=e(e$1,"w","i");u&&(r.italic=m(u));let l$1=e(e$1,"w","iCs");l$1&&(r.italicCs=m(l$1));let f=e(e$1,"w","u");if(f){let k=j$1(f,"w","val");if(k){r.underline={style:k};let z=j$1(f,"w","color"),U=j$1(f,"w","themeColor");(z||U)&&(r.underline.color=_e(z,U,j$1(f,"w","themeTint"),j$1(f,"w","themeShade")));}}let c=e(e$1,"w","strike");c&&(r.strike=m(c));let p=e(e$1,"w","dstrike");p&&(r.doubleStrike=m(p));let d=e(e$1,"w","vertAlign");if(d){let k=j$1(d,"w","val");(k==="superscript"||k==="subscript"||k==="baseline")&&(r.vertAlign=k);}let b=e(e$1,"w","smallCaps");b&&(r.smallCaps=m(b));let F=e(e$1,"w","caps");F&&(r.allCaps=m(F));let y=e(e$1,"w","vanish");y&&(r.hidden=m(y));let h=e(e$1,"w","color");h&&(r.color=_e(j$1(h,"w","val"),j$1(h,"w","themeColor"),j$1(h,"w","themeTint"),j$1(h,"w","themeShade")));let C=e(e$1,"w","highlight");if(C){let k=j$1(C,"w","val");k&&(r.highlight=k);}let A=e(e$1,"w","shd");A&&(r.shading=Ot(A));let R=e(e$1,"w","sz");if(R){let k=l(R,"w","val");k!==void 0&&(r.fontSize=k);}let S=e(e$1,"w","szCs");if(S){let k=l(S,"w","val");k!==void 0&&(r.fontSizeCs=k);}let m$1=e(e$1,"w","rFonts");if(m$1){r.fontFamily={ascii:j$1(m$1,"w","ascii")??void 0,hAnsi:j$1(m$1,"w","hAnsi")??void 0,eastAsia:j$1(m$1,"w","eastAsia")??void 0,cs:j$1(m$1,"w","cs")??void 0};let k=j$1(m$1,"w","asciiTheme");k&&(r.fontFamily.asciiTheme=k,t&&!r.fontFamily.ascii&&(r.fontFamily.ascii=_(t,k)));let z=j$1(m$1,"w","hAnsiTheme");z&&(r.fontFamily.hAnsiTheme=z,t&&!r.fontFamily.hAnsi&&(r.fontFamily.hAnsi=_(t,z)));let U=j$1(m$1,"w","eastAsiaTheme");U&&(r.fontFamily.eastAsiaTheme=U,t&&!r.fontFamily.eastAsia&&(r.fontFamily.eastAsia=_(t,U)));let ce=j$1(m$1,"w","cstheme");ce&&(r.fontFamily.csTheme=ce,t&&!r.fontFamily.cs&&(r.fontFamily.cs=_(t,ce)));}let T=e(e$1,"w","spacing");if(T){let k=l(T,"w","val");k!==void 0&&(r.spacing=k);}let E=e(e$1,"w","position");if(E){let k=l(E,"w","val");k!==void 0&&(r.position=k);}let w=e(e$1,"w","w");if(w){let k=l(w,"w","val");k!==void 0&&(r.scale=k);}let x=e(e$1,"w","kern");if(x){let k=l(x,"w","val");k!==void 0&&(r.kerning=k);}let P=e(e$1,"w","effect");if(P){let k=j$1(P,"w","val");k&&(r.effect=k);}let B=e(e$1,"w","em");if(B){let k=j$1(B,"w","val");k&&(r.emphasisMark=k);}let I=e(e$1,"w","emboss");I&&(r.emboss=m(I));let N=e(e$1,"w","imprint");N&&(r.imprint=m(N));let L=e(e$1,"w","outline");L&&(r.outline=m(L));let ye=e(e$1,"w","shadow");ye&&(r.shadow=m(ye));let be=e(e$1,"w","rtl");be&&(r.rtl=m(be));let Te=e(e$1,"w","cs");Te&&(r.cs=m(Te));let Fe=e(e$1,"w","rStyle");if(Fe){let k=j$1(Fe,"w","val");k&&(r.styleId=k);}return Object.keys(r).length>0?r:void 0}function Dt(e){let t=j$1(e,"w","id"),n=t?parseInt(t,10):0,r=(j$1(e,"w","author")??"").trim(),o=(j$1(e,"w","date")??"").trim(),a=(j$1(e,"w","rsid")??"").trim();return {id:Number.isInteger(n)&&n>=0?n:0,author:r.length>0?r:"Unknown",date:o.length>0?o:void 0,rsid:a.length>0?a:void 0}}function Wt(e$1,t,n,r){if(!e$1)return;let o=f(e$1,"w","rPrChange").map(a=>{let u=e(a,"w","rPr");return {type:"runPropertyChange",info:Dt(a),previousFormatting:ue(u,t),currentFormatting:r}}).filter(a=>a.previousFormatting||a.currentFormatting);return o.length>0?o:void 0}function jt(e){let t=k$1(e),n=j$1(e,"xml","space")==="preserve";return {type:"text",text:t,preserveSpace:n||void 0}}function Vt(){return {type:"tab"}}function zt(e){let t=j$1(e,"w","type"),n=j$1(e,"w","clear"),r={type:"break"};return (t==="page"||t==="column"||t==="textWrapping")&&(r.breakType=t),(n==="none"||n==="left"||n==="right"||n==="all")&&(r.clear=n),r}function Ut(e){let t=j$1(e,"w","font")??"",n=j$1(e,"w","char")??"";return {type:"symbol",font:t,char:n}}function Gt(e){return {type:"footnoteRef",id:l(e,"w","id")??0}}function qt(e){return {type:"endnoteRef",id:l(e,"w","id")??0}}function _t(e){let t=j$1(e,"w","fldCharType"),n=j$1(e,"w","fldLock")==="true"||j$1(e,"w","fldLock")==="1",r=j$1(e,"w","dirty")==="true"||j$1(e,"w","dirty")==="1",o="begin";return t==="separate"?o="separate":t==="end"&&(o="end"),{type:"fieldChar",charType:o,fldLock:n||void 0,dirty:r||void 0}}function Yt(e){return {type:"instrText",text:k$1(e)}}function Ye(e,t,n){let r=z(e,t??void 0,n??void 0);return r?{type:"drawing",image:r}:null}function se(e){if(!e)return "";let t=e.indexOf(":");return t>=0?e.substring(t+1):e}function $t(e,t,n){let r=[],o=i(e);for(let a of o)switch(se(a.name)){case "t":r.push(jt(a));break;case "tab":r.push(Vt());break;case "br":r.push(zt(a));break;case "sym":r.push(Ut(a));break;case "footnoteReference":r.push(Gt(a));break;case "endnoteReference":r.push(qt(a));break;case "fldChar":r.push(_t(a));break;case "instrText":r.push(Yt(a));break;case "softHyphen":r.push({type:"softHyphen"});break;case "noBreakHyphen":r.push({type:"noBreakHyphen"});break;case "drawing":let l=Ye(a,t,n);l&&r.push(l);break;case "pict":case "object":break;case "rPr":break;case "lastRenderedPageBreak":break;case "cr":r.push({type:"break",breakType:"textWrapping"});break;case "AlternateContent":{let c=i(a).find(p=>se(p.name)==="Choice")??i(a).find(p=>se(p.name)==="Fallback");if(c){for(let p of i(c))if(se(p.name)==="drawing"){let b=Ye(p,t,n);b?.image?.src&&r.push(b);}}break}}return r}function $(e$1,t,n,r=null,o=null){let a={type:"run",content:[]},u=e(e$1,"w","rPr");return u&&(a.formatting=ue(u,n),a.propertyChanges=Wt(u,n,t,a.formatting)),a.content=$t(e$1,r,o),a}function Zt(e,t,n,r){let o={};return e&&e!=="auto"?o.rgb=e:e==="auto"&&(o.auto=true),t&&(o.themeColor=t),n&&(o.themeTint=n),r&&(o.themeShade=r),o}function Kt(e){if(!e)return;let t={},n=j$1(e,"w","color");n&&n!=="auto"&&(t.color={rgb:n});let r=j$1(e,"w","fill");r&&r!=="auto"&&(t.fill={rgb:r});let o=j$1(e,"w","themeFill");o&&(t.fill=t.fill||{},t.fill.themeColor=o);let a=j$1(e,"w","themeFillTint");a&&t.fill&&(t.fill.themeTint=a);let u=j$1(e,"w","themeFillShade");u&&t.fill&&(t.fill.themeShade=u);let l=j$1(e,"w","val");return l&&(t.pattern=l),Object.keys(t).length>0?t:void 0}function q(e){if(!e)return;let t=j$1(e,"w","val");if(!t)return;let n={style:t},r=j$1(e,"w","color"),o=j$1(e,"w","themeColor");(r||o)&&(n.color=Zt(r,o,j$1(e,"w","themeTint"),j$1(e,"w","themeShade")));let a=l(e,"w","sz");a!==void 0&&(n.size=a);let u=l(e,"w","space");u!==void 0&&(n.space=u);let l$1=j$1(e,"w","shadow");l$1&&(n.shadow=l$1==="1"||l$1==="true");let f=j$1(e,"w","frame");return f&&(n.frame=f==="1"||f==="true"),n}function Qt(e){if(!e)return;let t=f(e,"w","tab");if(t.length===0)return;let n=[];for(let r of t){let o=l(r,"w","pos"),a=j$1(r,"w","val");if(o!==void 0&&a){let u={position:o,alignment:a},l=j$1(r,"w","leader");l&&(u.leader=l),n.push(u);}}return n.length>0?n:void 0}function Jt(e){if(!e)return;let t={},n=l(e,"w","w");n!==void 0&&(t.width=n);let r=l(e,"w","h");r!==void 0&&(t.height=r);let o=j$1(e,"w","hAnchor");(o==="text"||o==="margin"||o==="page")&&(t.hAnchor=o);let a=j$1(e,"w","vAnchor");(a==="text"||a==="margin"||a==="page")&&(t.vAnchor=a);let u=l(e,"w","x");u!==void 0&&(t.x=u);let l$1=l(e,"w","y");l$1!==void 0&&(t.y=l$1);let f=j$1(e,"w","xAlign");f&&(t.xAlign=f);let c=j$1(e,"w","yAlign");c&&(t.yAlign=c);let p=j$1(e,"w","wrap");return p&&(t.wrap=p),Object.keys(t).length>0?t:void 0}function fe(e$1,t,n){if(!e$1)return;let r={},o=e(e$1,"w","jc");if(o){let w=j$1(o,"w","val");w&&(r.alignment=w);}let a=e(e$1,"w","bidi");a&&(r.bidi=m(a));let u=e(e$1,"w","spacing");if(u){let w=l(u,"w","before");w!==void 0&&(r.spaceBefore=w);let x=l(u,"w","after");x!==void 0&&(r.spaceAfter=x);let P=l(u,"w","line");P!==void 0&&(r.lineSpacing=P);let B={};w!==void 0&&(B.before=true),x!==void 0&&(B.after=true),(B.before||B.after)&&(r.spacingExplicit=B);let I=j$1(u,"w","lineRule");I&&(r.lineSpacingRule=I);let N=j$1(u,"w","beforeAutospacing");N&&(r.beforeAutospacing=N==="1"||N==="true");let L=j$1(u,"w","afterAutospacing");L&&(r.afterAutospacing=L==="1"||L==="true");}let l$1=e(e$1,"w","ind");if(l$1){let w=l(l$1,"w","left");w!==void 0&&(r.indentLeft=w);let x=l(l$1,"w","right");x!==void 0&&(r.indentRight=x);let P=l(l$1,"w","firstLine");P!==void 0&&(r.indentFirstLine=P);let B=l(l$1,"w","hanging");B!==void 0&&(r.indentFirstLine=-B,r.hangingIndent=true);let I=l(l$1,"w","start");I!==void 0&&r.indentLeft===void 0&&(r.indentLeft=I);let N=l(l$1,"w","end");N!==void 0&&r.indentRight===void 0&&(r.indentRight=N);}let f=e(e$1,"w","pBdr");if(f){let w={},x=q(e(f,"w","top"));x&&(w.top=x);let P=q(e(f,"w","bottom"));P&&(w.bottom=P);let B=q(e(f,"w","left"));B&&(w.left=B);let I=q(e(f,"w","right"));I&&(w.right=I);let N=q(e(f,"w","between"));N&&(w.between=N);let L=q(e(f,"w","bar"));L&&(w.bar=L),Object.keys(w).length>0&&(r.borders=w);}let c=e(e$1,"w","shd");c&&(r.shading=Kt(c));let p=e(e$1,"w","tabs");p&&(r.tabs=Qt(p));let d=e(e$1,"w","keepNext");d&&(r.keepNext=m(d));let b=e(e$1,"w","keepLines");b&&(r.keepLines=m(b));let F=e(e$1,"w","widowControl");F&&(r.widowControl=m(F));let y=e(e$1,"w","pageBreakBefore");y&&(r.pageBreakBefore=m(y));let h=e(e$1,"w","contextualSpacing");h&&(r.contextualSpacing=m(h));let C=e(e$1,"w","numPr");if(C){let w=e(C,"w","numId"),x=e(C,"w","ilvl");if(w||x){if(r.numPr={},w){let P=l(w,"w","val");P!==void 0&&(r.numPr.numId=P);}if(x){let P=l(x,"w","val");P!==void 0&&(r.numPr.ilvl=P);}}}let A=e(e$1,"w","outlineLvl");if(A){let w=l(A,"w","val");w!==void 0&&(r.outlineLevel=w);}let R=e(e$1,"w","pStyle");if(R){let w=j$1(R,"w","val");w&&(r.styleId=w);}let S=e(e$1,"w","framePr");S&&(r.frame=Jt(S));let m$1=e(e$1,"w","suppressLineNumbers");m$1&&(r.suppressLineNumbers=m(m$1));let T=e(e$1,"w","suppressAutoHyphens");T&&(r.suppressAutoHyphens=m(T));let E=e(e$1,"w","rPr");return E&&(r.runProperties=ue(E,t)),Object.keys(r).length>0?r:void 0}function en(e){if(!e)return "";let t=e.indexOf(":");return t>=0?e.substring(t+1):e}function tn(e){let t=l(e,"w","id")??0,n=j$1(e,"w","name")??"",r={type:"bookmarkStart",id:t,name:n},o=l(e,"w","colFirst");o!==void 0&&(r.colFirst=o);let a=l(e,"w","colLast");return a!==void 0&&(r.colLast=a),r}function nn(e){return {type:"bookmarkEnd",id:l(e,"w","id")??0}}function $e(e,t,n=null,r=null,o=null){let a={type:"hyperlink",children:[]},u=j$1(e,"r","id");if(u&&(a.rId=u,t)){let F=t.get(u);F&&(c$1(F),a.href=F.target);}let l=j$1(e,"w","anchor");l&&(a.anchor=l,a.href||(a.href=`#${l}`));let f=j$1(e,"w","tooltip");f&&(a.tooltip=f);let c=j$1(e,"w","tgtFrame");c&&(a.target=c);let p=j$1(e,"w","history");(p==="1"||p==="true")&&(a.history=true);let d=j$1(e,"w","docLocation");d&&(a.docLocation=d);let b=i(e);for(let F of b)switch(en(F.name)){case "r":a.children.push($(F,n,r,t,o));break;case "bookmarkStart":a.children.push(tn(F));break;case "bookmarkEnd":a.children.push(nn(F));break}return a}function cr(e){let t="";for(let n of e.children)if(n.type==="run")for(let r of n.content)r.type==="text"?t+=r.text:r.type==="tab"&&(t+=" ");return t}function pr(e){return e.href?/^https?:\/\/|^mailto:|^tel:|^ftp:/i.test(e.href):!!e.rId&&!e.anchor}function dr(e){return !!e.anchor}function mr(e){return e.href}function gr(e){return e.children.some(t=>t.type==="run")}function hr(e){return e.children.filter(t=>t.type==="run")}function wr(e,t){if(e.rId){let n=t.get(e.rId);if(n)return c$1(n),e.href=n.target,e.href}return e.anchor&&!e.href&&(e.href=`#${e.anchor}`),e.href}function Ze(e){let t=l(e,"w","id")??0,n=j$1(e,"w","name")??"",r={type:"bookmarkStart",id:t,name:n},o=l(e,"w","colFirst");o!==void 0&&(r.colFirst=o);let a=l(e,"w","colLast");return a!==void 0&&(r.colLast=a),r}function Ke(e){return {type:"bookmarkEnd",id:l(e,"w","id")??0}}function rn(e$1){let t={sdtType:"richText"};if(!e$1||!e$1.elements)return t;for(let n of e$1.elements){if(n.type!=="element")continue;switch(n.name?.replace(/^w:/,"")??""){case "alias":t.alias=j$1(n,"w","val")??void 0;break;case "tag":t.tag=j$1(n,"w","val")??void 0;break;case "lock":t.lock=j$1(n,"w","val")??"unlocked";break;case "placeholder":{let o=e(n,"w","docPart");if(o){let a=e(o,"w","val");t.placeholder=a?j$1(a,"w","val")??void 0:void 0;}break}case "showingPlcHdr":t.showingPlaceholder=true;break;case "text":t.sdtType="plainText";break;case "date":t.sdtType="date",t.dateFormat=j$1(n,"w","fullDate")??void 0;break;case "dropDownList":t.sdtType="dropdown",t.listItems=Qe(n);break;case "comboBox":t.sdtType="comboBox",t.listItems=Qe(n);break;case "checkbox":{t.sdtType="checkbox";let o=e(n,"w14","checked")??e(n,"w","checked");t.checked=o?j$1(o,"w14","val")==="1"||j$1(o,"w","val")==="1":false;break}case "picture":t.sdtType="picture";break;case "docPartObj":t.sdtType="buildingBlockGallery";break;case "group":t.sdtType="group";break}}return t}function Qe(e){let t=[];for(let n of e.elements??[])n.type==="element"&&(n.name==="w:listItem"||n.name?.endsWith(":listItem"))&&t.push({displayText:j$1(n,"w","displayText")??"",value:j$1(n,"w","value")??""});return t}function et(e){let t="";if(e.type==="text"&&typeof e.text=="string")return e.text;if(e.elements)for(let n of e.elements)if((n.name?.replace(/^.*:/,"")??"")==="t"&&n.elements)for(let o of n.elements)o.type==="text"&&typeof o.text=="string"&&(t+=o.text);else t+=et(n);return t}function K(e){if(!e)return "";let t=e.indexOf(":");return t>=0?e.substring(t+1):e}function tt(e){let t=new Set(["hyperlink","smartTag","sdt","sdtContent","fldSimple","customXml","ins","del","moveFrom","moveTo"]),n=new Set(["pPr","proofErr","bookmarkStart","bookmarkEnd","commentRangeStart","commentRangeEnd","commentReference","permStart","permEnd","rsidR"]),r=new Set(["t","tab","br","cr","sym","drawing","pict","object","softHyphen","noBreakHyphen","fldChar","instrText","pgNum","separator","continuationSeparator","footnoteRef","endnoteRef","footnoteReference","endnoteReference","ptab","monthShort","monthLong","yearShort","yearLong","dayShort","dayLong"]),o=false;function a(l){for(let f of i(l)){let c=K(f.name);if(!n.has(c)){if(c==="lastRenderedPageBreak"){o=true;continue}if(c==="r"){for(let p of i(f)){let d=K(p.name);if(d!=="rPr"){if(d==="lastRenderedPageBreak"){o=true;continue}if(d==="br"&&j$1(p,"w","type")==="page")return "forced";if(r.has(d))return "visible"}}continue}if(t.has(c)){let p=a(f);if(p!=="continue")return p;continue}return "continue"}}return "continue"}let u=a(e);return u==="forced"?true:u==="visible"?o:false}function Je(e,t){if(!e)return `w:${t}`;let n=e.indexOf(":");return n<0?t:`${e.substring(0,n+1)}${t}`}function nt(e){if(e.type!=="element")return e;let t=K(e.name),n=e.name;return t==="delText"?n=Je(e.name,"t"):t==="delInstrText"&&(n=Je(e.name,"instrText")),{...e,name:n,elements:e.elements?.map(nt)}}function Z(e){let t=j$1(e,"w","id"),n=t?parseInt(t,10):0,r=j$1(e,"w","author"),o=j$1(e,"w","date"),a=r?.trim()??"",u=o?.trim()??"";return {id:Number.isInteger(n)&&n>=0?n:0,author:a.length>0?a:"Unknown",date:u.length>0?u:void 0}}function on(e){let t=Z(e),n=(j$1(e,"w","rsid")??"").trim();return n.length>0?{...t,rsid:n}:t}function rt(e$1,t,n,r){if(!e$1)return;let o=f(e$1,"w","pPrChange").map(a=>{let u=e(a,"w","pPr");return {type:"paragraphPropertyChange",info:on(a),previousFormatting:fe(u,t),currentFormatting:r}}).filter(a=>a.previousFormatting||a.currentFormatting);return o.length>0?o:void 0}function an(e,t,n,r,o){return $e(e,t,n,r,o)}function ln(e){return Ze(e)}function sn(e){return Ke(e)}function ot(e){let t=e.trim().match(/^\\?([A-Z]+)/i);if(!t)return "UNKNOWN";let n=t[1].toUpperCase();return ["PAGE","NUMPAGES","NUMWORDS","NUMCHARS","DATE","TIME","CREATEDATE","SAVEDATE","PRINTDATE","AUTHOR","TITLE","SUBJECT","KEYWORDS","COMMENTS","FILENAME","FILESIZE","TEMPLATE","DOCPROPERTY","DOCVARIABLE","REF","PAGEREF","NOTEREF","HYPERLINK","TOC","TOA","INDEX","SEQ","STYLEREF","AUTONUM","AUTONUMLGL","AUTONUMOUT","IF","MERGEFIELD","NEXT","NEXTIF","ASK","SET","QUOTE","INCLUDETEXT","INCLUDEPICTURE","SYMBOL","ADVANCE","EDITTIME","REVNUM","SECTION","SECTIONPAGES","USERADDRESS","USERNAME","USERINITIALS"].includes(n)?n:"UNKNOWN"}function un(e,t,n,r,o){let a=j$1(e,"w","instr")??"",u=ot(a),l={type:"simpleField",instruction:a,fieldType:u,content:[]},f=j$1(e,"w","fldLock");(f==="1"||f==="true")&&(l.fldLock=true);let c=j$1(e,"w","dirty");(c==="1"||c==="true")&&(l.dirty=true);let p=i(e);for(let d of p)K(d.name)==="r"&&l.content.push($(d,t,n,r,o));return l}function V(e,t,n,r,o,a,u="default"){let l=[],f=i(e),c=false,p="",d=[],b$1=[],F=false,y=false,h=false;for(let C of f){let A=K(C.name);switch(A){case "r":{let R=u==="deletion"?nt(C):C,S=$(R,t,n,o,a),m=false,T=false,E=false,w="";for(let x of S.content)x.type==="fieldChar"?x.charType==="begin"?(m=true,x.fldLock&&(y=true),x.dirty&&(h=true)):x.charType==="separate"?T=true:x.charType==="end"&&(E=true):x.type==="instrText"&&(w+=x.text);if(m&&(c=true,F=false,p="",d=[],b$1=[],y=false,h=false),c){if(w&&(p+=w),T&&(F=true),F&&!E?T||b$1.push(S):!F&&!m&&d.push(S),E){let x={type:"complexField",instruction:p.trim(),fieldType:ot(p),fieldCode:d,fieldResult:b$1};y&&(x.fldLock=true),h&&(x.dirty=true),l.push(x),c=false;}}else l.push(S);break}case "hyperlink":l.push(an(C,o,t,n,a));break;case "bookmarkStart":l.push(ln(C));break;case "bookmarkEnd":l.push(sn(C));break;case "fldSimple":l.push(un(C,t,n,o,a));break;case "pPr":break;case "proofErr":case "permStart":case "permEnd":case "customXml":break;case "sdt":{let R=(C.elements??[]).find(m=>m.type==="element"&&(m.name==="w:sdtPr"||m.name?.endsWith(":sdtPr"))),S=(C.elements??[]).find(m=>m.type==="element"&&(m.name==="w:sdtContent"||m.name?.endsWith(":sdtContent")));if(S){let m=V(S,t,n,null,o,a,u),E={type:"inlineSdt",properties:rn(R??null),content:m.filter(w=>w.type==="run"||w.type==="hyperlink"||w.type==="simpleField"||w.type==="complexField"||w.type==="inlineSdt"||w.type==="mathEquation")};l.push(E);}break}case "ins":{let R=Z(C),S=V(C,t,n,null,o,a),m={type:"insertion",info:R,content:S.filter(T=>T.type==="run"||T.type==="hyperlink")};l.push(m);break}case "del":{let R=Z(C),S=V(C,t,n,null,o,a,"deletion"),m={type:"deletion",info:R,content:S.filter(T=>T.type==="run"||T.type==="hyperlink")};l.push(m);break}case "moveFrom":{let R=Z(C),S=V(C,t,n,null,o,a,"deletion"),m={type:"moveFrom",info:R,content:S.filter(T=>T.type==="run"||T.type==="hyperlink")};l.push(m);break}case "moveTo":{let R=Z(C),S=V(C,t,n,null,o,a),m={type:"moveTo",info:R,content:S.filter(T=>T.type==="run"||T.type==="hyperlink")};l.push(m);break}case "smartTag":break;case "moveFromRangeStart":{let R=parseInt(j$1(C,"w","id")??"0",10),S=j$1(C,"w","name")??"";l.push({type:"moveFromRangeStart",id:R,name:S});break}case "moveFromRangeEnd":{let R=parseInt(j$1(C,"w","id")??"0",10);l.push({type:"moveFromRangeEnd",id:R});break}case "moveToRangeStart":{let R=parseInt(j$1(C,"w","id")??"0",10),S=j$1(C,"w","name")??"";l.push({type:"moveToRangeStart",id:R,name:S});break}case "moveToRangeEnd":{let R=parseInt(j$1(C,"w","id")??"0",10);l.push({type:"moveToRangeEnd",id:R});break}case "commentRangeStart":{let R=parseInt(j$1(C,"w","id")??"0",10);l.push({type:"commentRangeStart",id:R});break}case "commentRangeEnd":{let R=parseInt(j$1(C,"w","id")??"0",10);l.push({type:"commentRangeEnd",id:R});break}case "oMath":case "oMathPara":{let R=A==="oMathPara",S=b(C),m=et(C),T={type:"mathEquation",display:R?"block":"inline",ommlXml:S,plainText:m||void 0};l.push(T);break}}}return l}function fn(e){let t="";for(let n of e.content)if(n.type==="run")for(let r of n.content)r.type==="text"?t+=r.text:r.type==="tab"?t+=" ":r.type==="break"&&(r.breakType==="page"?t+="\f":t+=`
4
+ `);else if(n.type==="hyperlink"){for(let r of n.children)if(r.type==="run")for(let o of r.content)o.type==="text"&&(t+=o.text);}else if(n.type==="simpleField"){for(let r of n.content)if(r.type==="run")for(let o of r.content)o.type==="text"&&(t+=o.text);}else if(n.type==="complexField")for(let r of n.fieldResult)for(let o of r.content)o.type==="text"&&(t+=o.text);return t}function j(e$1,t,n,r,o=null,a=null,u){let l={type:"paragraph",content:[]},f=j$1(e$1,"w14","paraId")??j$1(e$1,"w","paraId");f&&(l.paraId=f);let c=j$1(e$1,"w14","textId")??j$1(e$1,"w","textId");c&&(l.textId=c),!u?.inHeaderFooter&&tt(e$1)&&(l.renderedPageBreakBefore=true);let p=e(e$1,"w","pPr");if(p){l.formatting=fe(p,n),l.propertyChanges=rt(p,n,t,l.formatting);let F=e(p,"w","sectPr");F&&(l.sectionProperties=Ge(F));}let d=V(e$1,t,n,r,o,a);l.content=we(d);let b=l.formatting?.numPr;if(!b&&l.formatting?.styleId&&t){let F=t.get(l.formatting.styleId);F?.pPr?.numPr&&(b=F.pPr.numPr,l.formatting||(l.formatting={}),l.formatting.numPr=b);}if(b&&r){let{numId:F,ilvl:y=0}=b;if(F!==void 0&&F!==0){let h=r.getLevel(F,y);if(h){let C=[];for(let S=0;S<=y;S+=1){let m=r.getLevel(F,S);C.push(m?.numFmt??"decimal");}let A=r.getInstance(F),R=A?.levelOverrides?.find(S=>S.ilvl===y);if(l.listRendering={level:y,numId:F,marker:h.lvlText,isBullet:h.numFmt==="bullet",numFmt:h.numFmt,markerHidden:h.rPr?.hidden||void 0,markerFontFamily:h.rPr?.fontFamily?.ascii||h.rPr?.fontFamily?.hAnsi||void 0,markerFontSize:h.rPr?.fontSize?h.rPr.fontSize/2:void 0,markerSuffix:h.suffix,levelNumFmts:C,abstractNumId:A?.abstractNumId,startOverride:R?.startOverride},h.pPr){l.formatting||(l.formatting={});let S=p?e(p,"w","ind"):null,m=S!=null&&(j$1(S,"w","left")!==null||j$1(S,"w","start")!==null),T=w=>{let x=S?j$1(S,"w",w):null;if(x===null)return false;let P=parseInt(x,10);return Number.isNaN(P)||P!==0},E=S!=null&&(T("firstLine")||T("hanging"));!m&&h.pPr.indentLeft!==void 0&&(l.formatting.indentLeft=h.pPr.indentLeft),E||(h.pPr.indentFirstLine!==void 0&&(l.formatting.indentFirstLine=h.pPr.indentFirstLine),h.pPr.hangingIndent!==void 0&&(l.formatting.hangingIndent=h.pPr.hangingIndent));}}}}return l}function it(e$1){if(!e$1)return;let t={},n=X(e(e$1,"w","tblW"));n&&(t.width=n);let r=e(e$1,"w","jc");if(r){let h=j$1(r,"w","val");(h==="left"||h==="center"||h==="right"||h==="start")&&(t.justification=h==="start"?"left":h);}let o=X(e(e$1,"w","tblCellSpacing"));o&&(t.cellSpacing=o);let a=X(e(e$1,"w","tblInd"));a&&(t.indent=a);let u=ee(e(e$1,"w","tblBorders"));u&&(t.borders=u);let l=te(e(e$1,"w","tblCellMar"));l&&(t.cellMargins=l);let f=e(e$1,"w","tblLayout");if(f){let h=j$1(f,"w","type");(h==="fixed"||h==="autofit")&&(t.layout=h);}let c=e(e$1,"w","tblStyle");if(c){let h=j$1(c,"w","val");h&&(t.styleId=h);}let p=ge(e(e$1,"w","tblLook"));p&&(t.look=p);let d=ne(e(e$1,"w","shd"));d&&(t.shading=d);let b=e(e$1,"w","tblOverlap");if(b){let h=j$1(b,"w","val");(h==="never"||h==="overlap")&&(t.overlap=h);}let F=he(e(e$1,"w","tblpPr"));if(F&&(t.floating=F),m(e(e$1,"w","bidiVisual"))&&(t.bidi=true),Object.keys(t).length!==0)return t}function cn(e$1,t){if(!e$1)return;let n=f(e$1,"w","tblPrChange").map(r=>{let o=e(r,"w","tblPr");return {type:"tablePropertyChange",info:J(r),previousFormatting:it(o),currentFormatting:t}}).filter(r=>r.previousFormatting||r.currentFormatting);return n.length>0?n:void 0}function pn(e$1,t){if(!e$1)return;let n=f(e$1,"w","trPrChange").map(r=>{let o=e(r,"w","trPr");return {type:"tableRowPropertyChange",info:J(r),previousFormatting:at(o),currentFormatting:t}}).filter(r=>r.previousFormatting||r.currentFormatting);return n.length>0?n:void 0}function dn(e$1,t){if(!e$1)return;let n=f(e$1,"w","tcPrChange").map(r=>{let o=e(r,"w","tcPr");return {type:"tableCellPropertyChange",info:J(r),previousFormatting:st(o),currentFormatting:t}}).filter(r=>r.previousFormatting||r.currentFormatting);return n.length>0?n:void 0}function mn(e$1){if(!e$1)return;let t=e(e$1,"w","ins");if(t)return {type:"tableRowInsertion",info:W(t)};let n=e(e$1,"w","del");if(n)return {type:"tableRowDeletion",info:W(n)}}function gn(e$1){if(!e$1)return;let t=e(e$1,"w","cellIns");if(t)return {type:"tableCellInsertion",info:W(t)};let n=e(e$1,"w","cellDel");if(n)return {type:"tableCellDeletion",info:W(n)};let r=e(e$1,"w","cellMerge");if(r)return {type:"tableCellMerge",info:W(r)}}function at(e$1){if(!e$1)return;let t={},n=e(e$1,"w","trHeight");if(n){let f=l(n,"w","val");f!==void 0&&f>0&&(t.height={value:f,type:"dxa"});let c=j$1(n,"w","hRule");(c==="auto"||c==="atLeast"||c==="exact")&&(t.heightRule=c);}m(e(e$1,"w","tblHeader"))&&(t.header=true),m(e(e$1,"w","cantSplit"))&&(t.cantSplit=true);let a=e(e$1,"w","jc");if(a){let f=j$1(a,"w","val");(f==="left"||f==="center"||f==="right")&&(t.justification=f);}m(e(e$1,"w","hidden"))&&(t.hidden=true);let l$1=lt(e(e$1,"w","cnfStyle"));if(l$1&&(t.conditionalFormat=l$1),Object.keys(t).length!==0)return t}function lt(e){if(!e)return;let t={},n=j$1(e,"w","firstRow");(n==="1"||n==="true")&&(t.firstRow=true);let r=j$1(e,"w","lastRow");(r==="1"||r==="true")&&(t.lastRow=true);let o=j$1(e,"w","firstColumn");(o==="1"||o==="true")&&(t.firstColumn=true);let a=j$1(e,"w","lastColumn");(a==="1"||a==="true")&&(t.lastColumn=true);let u=j$1(e,"w","oddHBand");(u==="1"||u==="true")&&(t.oddHBand=true);let l=j$1(e,"w","evenHBand");(l==="1"||l==="true")&&(t.evenHBand=true);let f=j$1(e,"w","oddVBand");(f==="1"||f==="true")&&(t.oddVBand=true);let c=j$1(e,"w","evenVBand");(c==="1"||c==="true")&&(t.evenVBand=true);let p=j$1(e,"w","firstRowFirstColumn");(p==="1"||p==="true")&&(t.nwCell=true);let d=j$1(e,"w","firstRowLastColumn");(d==="1"||d==="true")&&(t.neCell=true);let b=j$1(e,"w","lastRowFirstColumn");(b==="1"||b==="true")&&(t.swCell=true);let F=j$1(e,"w","lastRowLastColumn");(F==="1"||F==="true")&&(t.seCell=true);let y=j$1(e,"w","val");if(y&&y.length===12&&(y[0]==="1"&&(t.firstRow=true),y[1]==="1"&&(t.lastRow=true),y[2]==="1"&&(t.firstColumn=true),y[3]==="1"&&(t.lastColumn=true),y[4]==="1"&&(t.oddVBand=true),y[5]==="1"&&(t.evenVBand=true),y[6]==="1"&&(t.oddHBand=true),y[7]==="1"&&(t.evenHBand=true),y[8]==="1"&&(t.nwCell=true),y[9]==="1"&&(t.neCell=true),y[10]==="1"&&(t.swCell=true),y[11]==="1"&&(t.seCell=true)),Object.keys(t).length!==0)return t}function st(e$1){if(!e$1)return;let t={},n=X(e(e$1,"w","tcW"));n&&(t.width=n);let r=ee(e(e$1,"w","tcBorders"));r&&(t.borders=r);let o=te(e(e$1,"w","tcMar"));o&&(t.margins=o);let a=ne(e(e$1,"w","shd"));a&&(t.shading=a);let u=e(e$1,"w","vAlign");if(u){let y=j$1(u,"w","val");(y==="top"||y==="center"||y==="bottom")&&(t.verticalAlign=y);}let l$1=e(e$1,"w","textDirection");if(l$1){let y=j$1(l$1,"w","val");y&&(t.textDirection=y);}let f=e(e$1,"w","gridSpan");if(f){let y=l(f,"w","val");y!==void 0&&y>1&&(t.gridSpan=y);}let c=e(e$1,"w","vMerge");c&&(j$1(c,"w","val")==="restart"?t.vMerge="restart":t.vMerge="continue"),m(e(e$1,"w","tcFitText"))&&(t.fitText=true),m(e(e$1,"w","noWrap"))&&(t.noWrap=true),m(e(e$1,"w","hideMark"))&&(t.hideMark=true);let F=lt(e(e$1,"w","cnfStyle"));if(F&&(t.conditionalFormat=F),Object.keys(t).length!==0)return t}function hn(e,t,n,r,o,a,u){let l=[],f=e.elements||[];for(let c of f){if(!c.name)continue;let p=c.name.split(":").pop();if(p==="p"){let d=j(c,t,n,r,o,a,u);l.push(d);}else if(p==="tbl"){let d=Y(c,t,n,r,o,a,u);l.push(d);}}return l.length===0&&l.push({type:"paragraph",content:[]}),l}function wn(e$1,t,n,r,o,a,u){let l={type:"tableCell",content:[]},f=e(e$1,"w","tcPr"),c=st(f);return c&&(l.formatting=c),l.propertyChanges=dn(f,c),l.structuralChange=gn(f),l.content=hn(e$1,t,n,r,o,a,u),l}function yn(e$1,t,n,r,o,a,u){let l={type:"tableRow",cells:[]},f$1=e(e$1,"w","trPr"),c=at(f$1);c&&(l.formatting=c),l.propertyChanges=pn(f$1,c),l.structuralChange=mn(f$1);let p=f(e$1,"w","tc");for(let d of p){let b=wn(d,t,n,r,o,a,u);l.cells.push(b);}return l}function bn(e){if(!e)return;let t=[],n=f(e,"w","gridCol");for(let r of n){let o=l(r,"w","w")??0;t.push(o);}if(!(t.length>0&&t.every(r=>r<=0)))return t.length>0?t:void 0}function Tn(e){return e.cells.reduce((t,n)=>t+(n.formatting?.gridSpan??1),0)}function Fn(e){let t=Math.max(e.columnWidths?.length??0,...e.rows.map(n=>Tn(n)));if(!(t<=1))for(let n of e.rows){if(n.cells.length!==1)continue;let r=n.cells[0];(r.formatting?.gridSpan??1)>=t||r.formatting?.vMerge||r.formatting?.gridSpan==null&&(r.formatting={...r.formatting??{},gridSpan:t});}}function Y(e$1,t,n,r,o,a,u){let l={type:"table",rows:[]},f$1=e(e$1,"w","tblPr"),c=it(f$1);c&&(l.formatting=c),l.propertyChanges=cn(f$1,c);let p=bn(e(e$1,"w","tblGrid"));p&&(l.columnWidths=p);let d=f(e$1,"w","tr");for(let b of d){let F=yn(b,t,n,r,o,a,u);l.rows.push(F);}return Fn(l),l}export{qn as A,Ge as B,Kn as C,Qn as D,$ as E,$e as F,cr as G,pr as H,dr as I,mr as J,gr as K,hr as L,wr as M,fn as N,j as O,xn as a,_ as b,Ae as c,D as d,ee as e,te as f,ne as g,ge as h,he as i,mt as j,gt as k,ht as l,wt as m,yt as n,it as o,bt as p,re as q,In as r,Ln as s,jn as t,Vn as u,Ve as v,ze as w,zn as x,Un as y,Gn as z};
@@ -0,0 +1,2 @@
1
+ import {d}from'./chunk-HL5PQT3A.mjs';import {i,j,h,l,g,k as k$1,e as e$1}from'./chunk-B6LYBJ4H.mjs';import {e}from'./chunk-VW22RZ6C.mjs';var pe={accent1:"accent1",accent2:"accent2",accent3:"accent3",accent4:"accent4",accent5:"accent5",accent6:"accent6",dk1:"dk1",lt1:"lt1",dk2:"dk2",lt2:"lt2",tx1:"text1",tx2:"text2",bg1:"background1",bg2:"background2",hlink:"hlink",folHlink:"folHlink"},G={black:"000000",white:"FFFFFF",red:"FF0000",green:"00FF00",blue:"0000FF",yellow:"FFFF00",cyan:"00FFFF",magenta:"FF00FF"};function J(e,n){let t=i(n),i$1=t.find(r=>r.name==="a:shade");if(i$1){let r=j(i$1,null,"val");r&&(e.themeShade=Math.round(parseInt(r,10)/1e5*255).toString(16).padStart(2,"0").toUpperCase());}let o=t.find(r=>r.name==="a:tint");if(o){let r=j(o,null,"val");r&&(e.themeTint=Math.round(parseInt(r,10)/1e5*255).toString(16).padStart(2,"0").toUpperCase());}return e}function K(e){if(!e)return;let n=i(e),t=n.find(l=>l.name==="a:srgbClr");if(t){let l=j(t,null,"val");if(l)return J({rgb:l},t)}let i$1=n.find(l=>l.name==="a:schemeClr");if(i$1){let l=j(i$1,null,"val");if(l){let u={themeColor:pe[l]??"dk1"};return J(u,i$1)}}let o=n.find(l=>l.name==="a:sysClr");if(o)return {rgb:j(o,null,"lastClr")??"000000"};let r=n.find(l=>l.name==="a:prstClr");if(r){let l=j(r,null,"val");if(l&&G[l])return {rgb:G[l]}}}function N(e){if(!e)return;let n=i(e);if(n.find(i=>i.name==="a:noFill"))return {type:"none"};let t=n.find(i=>i.name==="a:solidFill");if(t)return {type:"solid",color:K(t)};if(n.find(i=>i.name==="a:gradFill"))return {type:"gradient"}}function S(e){let n=e?h(e,"a:ln"):null;if(!n)return;let t=i(n);if(t.find(u=>u.name==="a:noFill"))return;let i$1={},o=j(n,null,"w");o&&(i$1.width=parseInt(o,10));let r=t.find(u=>u.name==="a:solidFill");r&&(i$1.color=K(r));let l=t.find(u=>u.name==="a:prstDash");if(l){let u=j(l,null,"val");u&&(i$1.style=u);}return i$1}function L(e){if(!e)return;let n=j(e,null,"relativeFrom")??"column",t=h(e,"wp:align");if(t){let o=k$1(t);return {relativeTo:n,alignment:o}}let i=h(e,"wp:posOffset");if(i){let o=k$1(i),r=parseInt(o,10);return {relativeTo:n,posOffset:isNaN(r)?0:r}}return {relativeTo:n}}function z(e){if(!e)return;let n=j(e,null,"relativeFrom")??"paragraph",t=h(e,"wp:align");if(t){let o=k$1(t);return {relativeTo:n,alignment:o}}let i=h(e,"wp:posOffset");if(i){let o=k$1(i),r=parseInt(o,10);return {relativeTo:n,posOffset:isNaN(r)?0:r}}return {relativeTo:n}}function Q(e){let n=h(e,"wp:positionH"),t=h(e,"wp:positionV");if(!(!n&&!t))return {horizontal:L(n)??{relativeTo:"column"},vertical:z(t)??{relativeTo:"paragraph"}}}var W=["wp:wrapNone","wp:wrapSquare","wp:wrapTight","wp:wrapThrough","wp:wrapTopAndBottom"];function D(e,n,t){if(!e){let p={type:n?"behind":"inFront"};return t?.distT!==void 0&&(p.distT=t.distT),t?.distB!==void 0&&(p.distB=t.distB),t?.distL!==void 0&&(p.distL=t.distL),t?.distR!==void 0&&(p.distR=t.distR),p}let o=(e.name||"").replace("wp:",""),r;switch(o){case "wrapNone":r=n?"behind":"inFront";break;case "wrapSquare":r="square";break;case "wrapTight":r="tight";break;case "wrapThrough":r="through";break;case "wrapTopAndBottom":r="topAndBottom";break;default:r="square";}let l$1={type:r},u=j(e,null,"wrapText");u&&(l$1.wrapText=u);let s=l(e,null,"distT")??t?.distT,c=l(e,null,"distB")??t?.distB,m=l(e,null,"distL")??t?.distL,g=l(e,null,"distR")??t?.distR;return s!==void 0&&(l$1.distT=s),c!==void 0&&(l$1.distB=c),m!==void 0&&(l$1.distL=m),g!==void 0&&(l$1.distR=g),l$1}function Y(e){let n=i(e),t=j(e,null,"behindDoc")==="1",i$1=n.find(r=>W.includes(r.name??"")),o={distT:l(e,null,"distT")??void 0,distB:l(e,null,"distB")??void 0,distL:l(e,null,"distL")??void 0,distR:l(e,null,"distR")??void 0};return D(i$1??null,t,o)}var ce={accent1:"5B9BD5",accent2:"ED7D31",accent3:"A5A5A5",accent4:"FFC000",accent5:"4472C4",accent6:"70AD47",dk1:"000000",lt1:"FFFFFF",dk2:"1F497D",lt2:"EEECE1",text1:"000000",text2:"1F497D",background1:"FFFFFF",background2:"EEECE1",hlink:"0563C1",folHlink:"954F72"};function H(e){if(e){if(e.rgb)return `#${e.rgb}`;if(e.themeColor)return `#${ce[e.themeColor]??"000000"}`}}var k=91440;function Z(e){if(!e)return {};let n={},t=l(e,null,"lIns"),i=l(e,null,"rIns"),o=l(e,null,"tIns"),r=l(e,null,"bIns");return (t!==void 0||i!==void 0||o!==void 0||r!==void 0)&&(n.margins={left:t,right:i,top:o,bottom:r}),n}function ve(e){if(!e)return {paragraphElements:[],tableElements:[]};let n=g(e,"p"),t=g(e,"tbl");return {paragraphElements:n,tableElements:t}}function Be(e,n,t,i$1,o,r,l,u){if(!e)return [];let s=[],c=i(e);for(let m of c){let g=m.name||"",p=g.indexOf(":"),T=p>=0?g.substring(p+1):g;if(T==="p"){let b=n(m,i$1,o,r,l);s.push(b);}}return s}function ee(e){let t=i(e).find(u=>u.name==="wp:inline"||u.name==="wp:anchor");if(!t)return false;let i$1=h(t,"a:graphic");if(!i$1)return false;let o=h(i$1,"a:graphicData");if(!o)return false;let r=h(o,"wps:wsp");return r?h(r,"wps:txbx")!==null:false}function Ce(e){return h(e,"wps:txbx")!==null}function Me(e){let t=i(e).find(x=>x.name==="wp:inline"||x.name==="wp:anchor");if(!t)return null;let i$1=t.name==="wp:anchor",o=h(t,"a:graphic");if(!o)return null;let r=h(o,"a:graphicData");if(!r)return null;let l$1=h(r,"wps:wsp");if(!l$1||!h(l$1,"wps:txbx"))return null;let s=i(l$1),c=s.find(x=>x.name==="wps:spPr"),m=s.find(x=>x.name==="wps:bodyPr"),g=h(t,"wp:extent"),p=l(g,null,"cx")??0,T=l(g,null,"cy")??0,b={width:p,height:T},C=h(t,"wp:docPr"),P=C?j(C,null,"id")??void 0:void 0,v=N(c??null),B=S(c??null),E=Z(m??null),y={type:"textBox",size:b,content:[]};if(P&&(y.id=P),v&&(y.fill=v),B&&(y.outline=B),E.margins&&(y.margins=E.margins),i$1){let x=Q(t);x&&(y.position=x);let h=Y(t);h&&(y.wrap=h);}return y}function Re(e){let n=h(e,"wps:txbx");return n?h(n,"w:txbxContent"):null}function Xe(e,n,t,i$1){if(!h(e,"wps:txbx"))return null;let r=i(e),l=r.find(b=>b.name==="wps:spPr"),u=r.find(b=>b.name==="wps:bodyPr"),s=r.find(b=>b.name==="wps:cNvPr"),c=s?j(s,null,"id")??void 0:void 0,m=N(l??null),g=S(l??null),p=Z(u??null),T={type:"textBox",size:n,content:[]};return c&&(T.id=c),m&&(T.fill=m),g&&(T.outline=g),p.margins&&(T.margins=p.margins),t&&(T.position=t),i$1&&(T.wrap=i$1),T}function ke(e$1){return e(e$1.size.width)}function Ae(e$1){return e(e$1.size.height)}function Oe(e$1){return {width:e(e$1.size.width),height:e(e$1.size.height)}}function Ne(e$1){let n=e$1.margins;return {top:e(n?.top??k),bottom:e(n?.bottom??k),left:e(n?.left??k),right:e(n?.right??k)}}function Se(e){return e.position!==void 0||e.wrap!==void 0}function Le(e){return e.fill!==void 0&&e.fill.type!=="none"}function ze(e){return e.outline!==void 0}function We(e){return e.content.length>0}function De(e){let n=[];for(let t of e.content){let i=[];for(let o of t.content)if(o.type==="run")for(let r of o.content)r.type==="text"&&i.push(r.text);n.push(i.join(""));}return n.join(`
2
+ `)}function He(e){if(!(!e.fill||e.fill.type!=="solid"))return H(e.fill.color)}function Ve(e){if(e.outline?.color)return H(e.outline.color)}function _e(e$1){return e$1.outline?.width?e(e$1.outline.width):0}function me(e){if(!e)return;let n=parseInt(e,10);if(!isNaN(n))return n/6e4}function ge(e,n){let t=i(e);for(let i of t)if(n.includes(i.name||""))return i;return null}function ne(e){if(!e)return {width:0,height:0};let n=l(e,null,"cx")??0,t=l(e,null,"cy")??0;return {width:n,height:t}}function te(e){if(!e)return;let n=l(e,null,"l")??0,t=l(e,null,"t")??0,i=l(e,null,"r")??0,o=l(e,null,"b")??0;if(!(n===0&&t===0&&i===0&&o===0))return {left:n,top:t,right:i,bottom:o}}function ie(e){if(!e)return {};let n=j(e,null,"id")??void 0,t=j(e,null,"name")??void 0,i=j(e,null,"descr")??void 0,o=j(e,null,"title")??void 0,r=j(e,null,"decorative")==="1",l=e$1(e,"a","hlinkClick"),u=l?j(l,"r","id")??void 0:void 0;return {id:n,name:t,alt:i,title:o,decorative:r||void 0,hlinkRId:u}}function re(e){if(!e)return;let n=j(e,null,"rot"),t=j(e,null,"flipH")==="1",i=j(e,null,"flipV")==="1",o=me(n);if(o===void 0&&!t&&!i)return;let r={};return o!==void 0&&(r.rotation=o),t&&(r.flipH=true),i&&(r.flipV=true),r}function oe(e){let n=h(e,"a:graphic");if(!n)return {blipFill:null,blip:null};let t=h(n,"a:graphicData");if(!t)return {blipFill:null,blip:null};let i=h(t,"pic:pic");if(!i)return {blipFill:null,blip:null};let o=h(i,"pic:blipFill");return o?{blipFill:o,blip:h(o,"a:blip")}:{blipFill:null,blip:null}}function le(e){if(!e)return;let n=h(e,"a:srcRect");if(!n)return;let t=s=>{let c=l(n,null,s);if(!(c===void 0||c===0))return c/1e5},i=t("l"),o=t("t"),r=t("r"),l$1=t("b");if(i===void 0&&o===void 0&&r===void 0&&l$1===void 0)return;let u={};return i!==void 0&&(u.left=i),o!==void 0&&(u.top=o),r!==void 0&&(u.right=r),l$1!==void 0&&(u.bottom=l$1),u}function ae(e){if(!e)return;let n=h(e,"a:alphaModFix");if(!n)return;let t=l(n,null,"amt");if(!(t===void 0||t>=1e5))return Math.max(0,Math.min(1,t/1e5))}function se(e){if(!e)return "";let n=j(e,"r","embed");if(n)return n;let t=j(e,null,"embed");if(t)return t;let i=j(e,"r","link");return i||""}function ue(e){let n=h(e,"a:graphic");if(!n)return null;let t=h(n,"a:graphicData");if(!t)return null;let i=h(t,"pic:pic");if(!i)return null;let o=h(i,"pic:spPr");return o?h(o,"a:xfrm"):null}function xe(e){if(!e)return e;let n=e.replace(/^\/+/,"");return n.startsWith("media/")?n=`word/${n}`:n.startsWith("word/")||(n=`word/${n}`),n}function he(e){let n=e.split(".").pop()?.toLowerCase()??"";return {png:"image/png",jpg:"image/jpeg",jpeg:"image/jpeg",gif:"image/gif",bmp:"image/bmp",tiff:"image/tiff",tif:"image/tiff",webp:"image/webp",svg:"image/svg+xml",emf:"image/x-emf",wmf:"image/x-wmf"}[n]??"application/octet-stream"}function de(e,n,t){if(!e||!n)return {};let i=n.get(e);if(!i)return {};let o=i.target;if(!o)return {};let r=xe(o),l=o.split("/").pop(),u=(s,c)=>{let m=c.toLowerCase();for(let[g,p]of s.entries())if(g.toLowerCase()===m)return p};if(t){let s=u(t,r);if(s)return {src:s.dataUrl||s.base64,mimeType:s.mimeType,filename:l};let c=o.replace(/^\/+/,""),m=u(t,c);if(m)return {src:m.dataUrl||m.base64,mimeType:m.mimeType,filename:l};let g=`word/${c}`,p=u(t,g);if(p)return {src:p.dataUrl||p.base64,mimeType:p.mimeType,filename:l}}return {mimeType:he(o),filename:l}}function Te(e,n,t){let i=h(e,"wp:extent"),o=ne(i),r=h(e,"wp:effectExtent"),l$1=te(r),u=h(e,"wp:docPr"),s=ie(u),{blip:c,blipFill:m}=oe(e),g=se(c),p=le(m),T=ae(c),b=de(g,n,t),C=ue(e),P=re(C),v=l(e,null,"distT")??void 0,B=l(e,null,"distB")??void 0,E=l(e,null,"distL")??void 0,y=l(e,null,"distR")??void 0,x={type:"inline"};v!==void 0&&(x.distT=v),B!==void 0&&(x.distB=B),E!==void 0&&(x.distL=E),y!==void 0&&(x.distR=y);let h$1={type:"image",rId:g,size:o,wrap:x};if(s.id&&(h$1.id=s.id),s.alt&&(h$1.alt=s.alt),s.title&&(h$1.title=s.title),s.decorative&&(h$1.decorative=true),b.src&&(h$1.src=b.src),b.mimeType&&(h$1.mimeType=b.mimeType),b.filename&&(h$1.filename=b.filename),l$1&&(h$1.padding=l$1),P&&(h$1.transform=P),p&&(h$1.crop=p),T!==void 0&&(h$1.opacity=T),s.hlinkRId&&n){let X=d(n,s.hlinkRId);X&&(h$1.hlinkHref=X);}return h$1}function be(e,n,t){let i=h(e,"wp:extent"),o=ne(i),r=h(e,"wp:effectExtent"),l$1=te(r),u=h(e,"wp:docPr"),s=ie(u),c=j(e,null,"behindDoc")==="1",m=j(e,null,"layoutInCell"),g=m===null?void 0:m==="1",p=j(e,null,"allowOverlap"),T=p===null?void 0:p==="1",b={distT:l(e,null,"distT")??void 0,distB:l(e,null,"distB")??void 0,distL:l(e,null,"distL")??void 0,distR:l(e,null,"distR")??void 0},C=ge(e,W),P=D(C,c,b),v=h(e,"wp:positionH"),B=h(e,"wp:positionV"),E=L(v),y=z(B),x;(E||y)&&(x={horizontal:E??{relativeTo:"column"},vertical:y??{relativeTo:"paragraph"}});let{blip:h$1,blipFill:X}=oe(e),V=se(h$1),_=le(X),U=ae(h$1),M=de(V,n,t),fe=ue(e),j$1=re(fe),I={type:"image",rId:V,size:o,wrap:P};if(s.id&&(I.id=s.id),s.alt&&(I.alt=s.alt),s.title&&(I.title=s.title),s.decorative&&(I.decorative=true),M.src&&(I.src=M.src),M.mimeType&&(I.mimeType=M.mimeType),M.filename&&(I.filename=M.filename),x&&(I.position=x),l$1&&(I.padding=l$1),j$1&&(I.transform=j$1),_&&(I.crop=_),U!==void 0&&(I.opacity=U),g!==void 0&&(I.layoutInCell=g),T!==void 0&&(I.allowOverlap=T),s.hlinkRId&&n){let q=d(n,s.hlinkRId);q&&(I.hlinkHref=q);}return I}function we(e,n,t){if(ee(e))return null;let i$1=i(e);for(let o of i$1){let r=o.name||"";if(r==="wp:inline"||r==="wp:anchor")return r==="wp:inline"?Te(o,n,t):be(o,n,t)}return null}function Qe(e,n,t){return we(e,n,t)}function Ye(e){return e.wrap.type==="inline"}function Ze(e){return e.wrap.type!=="inline"}function en(e){return e.wrap.type==="behind"}function nn(e){return e.wrap.type==="inFront"}function tn(e$1){return e(e$1.size.width)}function rn(e$1){return e(e$1.size.height)}function on(e){return e.decorative===true}function ln(e$1){return {top:e(e$1.wrap.distT),bottom:e(e$1.wrap.distB),left:e(e$1.wrap.distL),right:e(e$1.wrap.distR)}}export{Ye as A,Ze as B,en as C,nn as D,tn as E,rn as F,on as G,ln as H,K as a,N as b,Q as c,Y as d,H as e,ve as f,Be as g,ee as h,Ce as i,Me as j,Re as k,Xe as l,ke as m,Ae as n,Oe as o,Ne as p,Se as q,Le as r,ze as s,We as t,De as u,He as v,Ve as w,_e as x,we as y,Qe as z};
@@ -1 +1 @@
1
- import {e,b,c,a as a$1}from'./chunk-KQTB5Y7P.mjs';import {a}from'./chunk-JKVXID22.mjs';import {TextSelection}from'prosemirror-state';function M(e){let{$from:t}=e.selection,o=null,i=null,a=null,l=-1,n=-1;for(let r=t.depth;r>0;r--){let u=t.node(r);if(u.type.name==="tableCell"||u.type.name==="tableHeader"){a=u;let p=t.node(r-1);if(p?.type.name==="tableRow"){let m=0;p.forEach((f,b,g)=>{if(n===-1){if(g===t.index(r-1)){n=m;return}m+=f.attrs.colspan||1;}});}}else if(u.type.name==="tableRow")t.node(r-1)?.type.name==="table"&&(l=t.index(r-1));else if(u.type.name==="table"){o=u,i=t.before(r);break}}return !o||i==null||!a||l<0||n<0?null:{table:o,tablePos:i,cell:a,row:l,col:n,rowspan:a.attrs.rowspan||1,colspan:a.attrs.colspan||1}}function k(e){let t=[],o=[],i=0;for(let a=0;a<e.childCount;a++){let l=e.child(a),n=0;l.forEach(r=>{for(;t[a]?.[n];)n++;let u=r.attrs.rowspan||1,p=r.attrs.colspan||1;o.push({data:r,row:a,col:n,rowspan:u,colspan:p});for(let m=a;m<a+u;m++){let f=t[m]??[];t[m]=f;for(let b=n;b<n+p;b++)f[b]=true;}n+=p,i=Math.max(i,n);});}return {anchors:o,totalCols:i}}function B(e,t,o,i,a){let l={...e.attrs},n=a.reduce((p,m)=>p+m,0),r=a$1(a,t,o),u=o!==(e.attrs.colspan||1)||i!==(e.attrs.rowspan||1);return l.colspan=o,l.rowspan=i,l.colwidth=null,n>0&&(l.width=Math.round(r/n*5e3),l.widthType="pct"),u&&(l._originalFormatting=null),l}function D(e,t,o,i){let a=t+1;for(let l=0;l<e.childCount;l++){let n=e.child(l),r=a+1,u=0;for(let p=0;p<n.childCount;p++){let m=n.child(p);if(l===o&&u===i)return r;u+=m.attrs.colspan||1,r+=m.nodeSize;}a+=n.nodeSize;}return null}function O(e,t){let o=e.attrs.width??9360;return Array.isArray(e.attrs.columnWidths)&&e.attrs.columnWidths.length>0?[...e.attrs.columnWidths]:Array.from({length:t},()=>Math.floor(o/Math.max(t,1)))}function j(e$1){let t=M(e$1);return t?{...e(t.rowspan,t.colspan),capturedCellRow:t.row,capturedCellCol:t.col}:null}function V(e,t,o,i,a,l){if(o<1||i<1)return false;let n=M(e);if(!n||!t)return false;let r=n;if(a!=null&&l!=null&&(a!==n.row||l!==n.col)){let{anchors:c}=k(n.table),d=c.find(x=>x.row===a&&x.col===l);if(!d)return false;r={...n,cell:d.data,row:d.row,col:d.col,rowspan:d.rowspan,colspan:d.colspan};}if(o<r.rowspan||i<r.colspan||o===1&&i===1)return false;let{anchors:u,totalCols:p}=k(r.table),m=O(r.table,p),f=b(m,r.col,r.colspan,i),b$1=u.find(c=>c.row===r.row&&c.col===r.col);if(!b$1)return false;let g=c(u,b$1,o,i,r.table.childCount,c=>{if(c)return b$1.data;let d=b$1.data.type.schema.nodes.paragraph.create(),x=B(b$1.data,0,1,1,f);return b$1.data.type.create(x,d)}),T=r.row+r.rowspan,y=Array.from({length:g.newRowCount},(c,d)=>d<T?{...r.table.child(d)?.attrs??{}}:d<r.row+o?{...r.table.child(T-1)?.attrs??{}}:{...r.table.child(d-g.deltaRows)?.attrs??{}}),C=Array.from({length:g.newRowCount},()=>[]);g.anchors.sort((c,d)=>c.row===d.row?c.col-d.col:c.row-d.row).forEach(c=>{let d=B(c.data,c.col,c.colspan,c.rowspan,f);C[c.row].push(c.data.type.create(d,c.data.content));});let z=C.map((c,d)=>r.table.type.schema.nodes.tableRow.create(y[d],c)),F=r.table.type.create({...r.table.attrs,columnWidths:f},z),h=e.tr.replaceWith(r.tablePos,r.tablePos+r.table.nodeSize,F),w=h.doc.nodeAt(r.tablePos);if(w){let c=D(w,r.tablePos,r.row,r.col);c!=null&&(h=h.setSelection(TextSelection.near(h.doc.resolve(c+1))));}return t(h.scrollIntoView()),true}var s=a.getCommands();function J(e,t){return s.insertTable(e,t)}function $(e,t){return s.addRowAbove()(e,t)}function q(e,t){return s.addRowBelow()(e,t)}function G(e,t){return s.deleteRow()(e,t)}function K(e,t){return s.addColumnLeft()(e,t)}function Q(e,t){return s.addColumnRight()(e,t)}function X(e,t){return s.deleteColumn()(e,t)}function Y(e,t){return s.deleteTable()(e,t)}function Z(e,t){return s.selectTable()(e,t)}function ee(e,t){return s.selectRow()(e,t)}function te(e,t){return s.selectColumn()(e,t)}function re(e,t){return s.mergeCells()(e,t)}function oe(e,t){return s.splitCell()(e,t)}function ne(e,t,o){return s.setCellBorder(e,t,o)}function ae(e,t){return s.setTableBorders(e,t)}function le(e,t){return s.removeTableBorders()(e,t)}function ie(e,t,o){return s.setAllTableBorders(o)(e,t)}function se(e,t,o){return s.setOutsideTableBorders(o)(e,t)}function ce(e,t,o){return s.setInsideTableBorders(o)(e,t)}function de(e){return s.setCellVerticalAlign(e)}function ue(e){return s.setCellMargins(e)}function pe(e){return s.setCellTextDirection(e)}function me(){return s.toggleNoWrap()}function fe(e,t){return s.setRowHeight(e,t)}function be(){return s.toggleHeaderRow()}function ge(){return s.distributeColumns()}function Ce(){return s.autoFitContents()}function Te(e){return s.setTableProperties(e)}function he(e){return s.applyTableStyle(e)}function ye(e){return s.setCellFillColor(e)}function xe(e){return s.setTableBorderColor(e)}function Se(e){return s.setTableBorderWidth(e)}var we=a.getCommands();function ve(e,t,o){return we.setImageWrapType(e,t,o)}function Ee(e){return (t,o)=>{let{from:i,to:a,empty:l}=t.selection;if(l)return false;let n=t.schema.marks.comment;if(!n)return false;if(o){let r=t.tr.addMark(i,a,n.create({commentId:e}));o(r);}return true}}function Ae(e){return (t,o)=>{let i=t.schema.marks.comment;if(!i)return false;if(o){let a=t.tr;t.doc.descendants((l,n)=>{if(l.isText)for(let r of l.marks)r.type===i&&r.attrs.commentId===e&&a.removeMark(n,n+l.nodeSize,r);}),a.steps.length>0&&o(a);}return true}}function I(e,t,o){return (i,a)=>{let l=i.schema.marks.insertion,n=i.schema.marks.deletion;if(!l&&!n)return false;let r=o==="accept"?l:n,u=o==="accept"?n:l;if(a){let p=i.tr,m=[];i.doc.nodesBetween(e,t,(f,b)=>{if(!f.isText)return;let g=b+f.nodeSize,T=Math.max(e,b),y=Math.min(t,g);u&&f.marks.some(C=>C.type===u)&&m.push({from:T,to:y}),r&&f.marks.some(C=>C.type===r)&&p.removeMark(T,y,r);});for(let f of m.reverse())p.delete(f.from,f.to);p.steps.length>0&&a(p);}return true}}function P(e,t){return I(e,t,"accept")}function W(e,t){return I(e,t,"reject")}function Re(){return (e,t)=>P(0,e.doc.content.size)(e,t)}function ke(){return (e,t)=>W(0,e.doc.content.size)(e,t)}function L(e,t){let o=e.schema.marks.insertion,i=e.schema.marks.deletion;if(!o&&!i)return null;let a=null;return e.doc.descendants((l,n)=>{if(a)return false;if(l.isText&&!(n+l.nodeSize<=t)){for(let r of l.marks)if(r.type===o||r.type===i)return a={from:Math.max(n,t),to:n+l.nodeSize,type:r.type===o?"insertion":"deletion"},false}}),!a&&t>0?L(e,0):a}function N(e,t){let o=e.schema.marks.insertion,i=e.schema.marks.deletion;if(!o&&!i)return null;let a=null;return e.doc.descendants((l,n)=>{if(l.isText){if(n>=t)return false;for(let r of l.marks)(r.type===o||r.type===i)&&(a={from:n,to:n+l.nodeSize,type:r.type===o?"insertion":"deletion"});}}),!a&&t<e.doc.content.size?N(e,e.doc.content.size):a}export{be as A,ge as B,Ce as C,Te as D,he as E,ye as F,xe as G,Se as H,ve as I,Ee as J,Ae as K,P as L,W as M,Re as N,ke as O,L as P,N as Q,j as a,V as b,J as c,$ as d,q as e,G as f,K as g,Q as h,X as i,Y as j,Z as k,ee as l,te as m,re as n,oe as o,ne as p,ae as q,le as r,ie as s,se as t,ce as u,de as v,ue as w,pe as x,me as y,fe as z};
1
+ import {e,b,c,a as a$1}from'./chunk-KQTB5Y7P.mjs';import {a}from'./chunk-TGPS3SRR.mjs';import {TextSelection}from'prosemirror-state';function M(e){let{$from:t}=e.selection,o=null,i=null,a=null,l=-1,n=-1;for(let r=t.depth;r>0;r--){let u=t.node(r);if(u.type.name==="tableCell"||u.type.name==="tableHeader"){a=u;let p=t.node(r-1);if(p?.type.name==="tableRow"){let m=0;p.forEach((f,b,g)=>{if(n===-1){if(g===t.index(r-1)){n=m;return}m+=f.attrs.colspan||1;}});}}else if(u.type.name==="tableRow")t.node(r-1)?.type.name==="table"&&(l=t.index(r-1));else if(u.type.name==="table"){o=u,i=t.before(r);break}}return !o||i==null||!a||l<0||n<0?null:{table:o,tablePos:i,cell:a,row:l,col:n,rowspan:a.attrs.rowspan||1,colspan:a.attrs.colspan||1}}function k(e){let t=[],o=[],i=0;for(let a=0;a<e.childCount;a++){let l=e.child(a),n=0;l.forEach(r=>{for(;t[a]?.[n];)n++;let u=r.attrs.rowspan||1,p=r.attrs.colspan||1;o.push({data:r,row:a,col:n,rowspan:u,colspan:p});for(let m=a;m<a+u;m++){let f=t[m]??[];t[m]=f;for(let b=n;b<n+p;b++)f[b]=true;}n+=p,i=Math.max(i,n);});}return {anchors:o,totalCols:i}}function B(e,t,o,i,a){let l={...e.attrs},n=a.reduce((p,m)=>p+m,0),r=a$1(a,t,o),u=o!==(e.attrs.colspan||1)||i!==(e.attrs.rowspan||1);return l.colspan=o,l.rowspan=i,l.colwidth=null,n>0&&(l.width=Math.round(r/n*5e3),l.widthType="pct"),u&&(l._originalFormatting=null),l}function D(e,t,o,i){let a=t+1;for(let l=0;l<e.childCount;l++){let n=e.child(l),r=a+1,u=0;for(let p=0;p<n.childCount;p++){let m=n.child(p);if(l===o&&u===i)return r;u+=m.attrs.colspan||1,r+=m.nodeSize;}a+=n.nodeSize;}return null}function O(e,t){let o=e.attrs.width??9360;return Array.isArray(e.attrs.columnWidths)&&e.attrs.columnWidths.length>0?[...e.attrs.columnWidths]:Array.from({length:t},()=>Math.floor(o/Math.max(t,1)))}function j(e$1){let t=M(e$1);return t?{...e(t.rowspan,t.colspan),capturedCellRow:t.row,capturedCellCol:t.col}:null}function V(e,t,o,i,a,l){if(o<1||i<1)return false;let n=M(e);if(!n||!t)return false;let r=n;if(a!=null&&l!=null&&(a!==n.row||l!==n.col)){let{anchors:c}=k(n.table),d=c.find(x=>x.row===a&&x.col===l);if(!d)return false;r={...n,cell:d.data,row:d.row,col:d.col,rowspan:d.rowspan,colspan:d.colspan};}if(o<r.rowspan||i<r.colspan||o===1&&i===1)return false;let{anchors:u,totalCols:p}=k(r.table),m=O(r.table,p),f=b(m,r.col,r.colspan,i),b$1=u.find(c=>c.row===r.row&&c.col===r.col);if(!b$1)return false;let g=c(u,b$1,o,i,r.table.childCount,c=>{if(c)return b$1.data;let d=b$1.data.type.schema.nodes.paragraph.create(),x=B(b$1.data,0,1,1,f);return b$1.data.type.create(x,d)}),T=r.row+r.rowspan,y=Array.from({length:g.newRowCount},(c,d)=>d<T?{...r.table.child(d)?.attrs??{}}:d<r.row+o?{...r.table.child(T-1)?.attrs??{}}:{...r.table.child(d-g.deltaRows)?.attrs??{}}),C=Array.from({length:g.newRowCount},()=>[]);g.anchors.sort((c,d)=>c.row===d.row?c.col-d.col:c.row-d.row).forEach(c=>{let d=B(c.data,c.col,c.colspan,c.rowspan,f);C[c.row].push(c.data.type.create(d,c.data.content));});let z=C.map((c,d)=>r.table.type.schema.nodes.tableRow.create(y[d],c)),F=r.table.type.create({...r.table.attrs,columnWidths:f},z),h=e.tr.replaceWith(r.tablePos,r.tablePos+r.table.nodeSize,F),w=h.doc.nodeAt(r.tablePos);if(w){let c=D(w,r.tablePos,r.row,r.col);c!=null&&(h=h.setSelection(TextSelection.near(h.doc.resolve(c+1))));}return t(h.scrollIntoView()),true}var s=a.getCommands();function J(e,t){return s.insertTable(e,t)}function $(e,t){return s.addRowAbove()(e,t)}function q(e,t){return s.addRowBelow()(e,t)}function G(e,t){return s.deleteRow()(e,t)}function K(e,t){return s.addColumnLeft()(e,t)}function Q(e,t){return s.addColumnRight()(e,t)}function X(e,t){return s.deleteColumn()(e,t)}function Y(e,t){return s.deleteTable()(e,t)}function Z(e,t){return s.selectTable()(e,t)}function ee(e,t){return s.selectRow()(e,t)}function te(e,t){return s.selectColumn()(e,t)}function re(e,t){return s.mergeCells()(e,t)}function oe(e,t){return s.splitCell()(e,t)}function ne(e,t,o){return s.setCellBorder(e,t,o)}function ae(e,t){return s.setTableBorders(e,t)}function le(e,t){return s.removeTableBorders()(e,t)}function ie(e,t,o){return s.setAllTableBorders(o)(e,t)}function se(e,t,o){return s.setOutsideTableBorders(o)(e,t)}function ce(e,t,o){return s.setInsideTableBorders(o)(e,t)}function de(e){return s.setCellVerticalAlign(e)}function ue(e){return s.setCellMargins(e)}function pe(e){return s.setCellTextDirection(e)}function me(){return s.toggleNoWrap()}function fe(e,t){return s.setRowHeight(e,t)}function be(){return s.toggleHeaderRow()}function ge(){return s.distributeColumns()}function Ce(){return s.autoFitContents()}function Te(e){return s.setTableProperties(e)}function he(e){return s.applyTableStyle(e)}function ye(e){return s.setCellFillColor(e)}function xe(e){return s.setTableBorderColor(e)}function Se(e){return s.setTableBorderWidth(e)}var we=a.getCommands();function ve(e,t,o){return we.setImageWrapType(e,t,o)}function Ee(e){return (t,o)=>{let{from:i,to:a,empty:l}=t.selection;if(l)return false;let n=t.schema.marks.comment;if(!n)return false;if(o){let r=t.tr.addMark(i,a,n.create({commentId:e}));o(r);}return true}}function Ae(e){return (t,o)=>{let i=t.schema.marks.comment;if(!i)return false;if(o){let a=t.tr;t.doc.descendants((l,n)=>{if(l.isText)for(let r of l.marks)r.type===i&&r.attrs.commentId===e&&a.removeMark(n,n+l.nodeSize,r);}),a.steps.length>0&&o(a);}return true}}function I(e,t,o){return (i,a)=>{let l=i.schema.marks.insertion,n=i.schema.marks.deletion;if(!l&&!n)return false;let r=o==="accept"?l:n,u=o==="accept"?n:l;if(a){let p=i.tr,m=[];i.doc.nodesBetween(e,t,(f,b)=>{if(!f.isText)return;let g=b+f.nodeSize,T=Math.max(e,b),y=Math.min(t,g);u&&f.marks.some(C=>C.type===u)&&m.push({from:T,to:y}),r&&f.marks.some(C=>C.type===r)&&p.removeMark(T,y,r);});for(let f of m.reverse())p.delete(f.from,f.to);p.steps.length>0&&a(p);}return true}}function P(e,t){return I(e,t,"accept")}function W(e,t){return I(e,t,"reject")}function Re(){return (e,t)=>P(0,e.doc.content.size)(e,t)}function ke(){return (e,t)=>W(0,e.doc.content.size)(e,t)}function L(e,t){let o=e.schema.marks.insertion,i=e.schema.marks.deletion;if(!o&&!i)return null;let a=null;return e.doc.descendants((l,n)=>{if(a)return false;if(l.isText&&!(n+l.nodeSize<=t)){for(let r of l.marks)if(r.type===o||r.type===i)return a={from:Math.max(n,t),to:n+l.nodeSize,type:r.type===o?"insertion":"deletion"},false}}),!a&&t>0?L(e,0):a}function N(e,t){let o=e.schema.marks.insertion,i=e.schema.marks.deletion;if(!o&&!i)return null;let a=null;return e.doc.descendants((l,n)=>{if(l.isText){if(n>=t)return false;for(let r of l.marks)(r.type===o||r.type===i)&&(a={from:n,to:n+l.nodeSize,type:r.type===o?"insertion":"deletion"});}}),!a&&t<e.doc.content.size?N(e,e.doc.content.size):a}export{be as A,ge as B,Ce as C,Te as D,he as E,ye as F,xe as G,Se as H,ve as I,Ee as J,Ae as K,P as L,W as M,Re as N,ke as O,L as P,N as Q,j as a,V as b,J as c,$ as d,q as e,G as f,K as g,Q as h,X as i,Y as j,Z as k,ee as l,te as m,re as n,oe as o,ne as p,ae as q,le as r,ie as s,se as t,ce as u,de as v,ue as w,pe as x,me as y,fe as z};
@@ -1 +1 @@
1
- 'use strict';var chunkSUXJX72X_js=require('./chunk-SUXJX72X.js'),chunkDFZTUQ7O_js=require('./chunk-DFZTUQ7O.js');function y(e){return chunkDFZTUQ7O_js.g(e,chunkSUXJX72X_js.b)}var t=chunkSUXJX72X_js.a.getCommands(),F=t.toggleBold(),f=t.toggleItalic(),S=t.toggleUnderline(),H=t.toggleStrike(),T=t.toggleSuperscript(),h=t.toggleSubscript();function M(e){return t.setTextColor(e)}var A=t.clearTextColor();function v(e){return t.setHighlight(e)}var z=t.clearHighlight();function U(e){return t.setFontSize(e)}var b=t.clearFontSize();function B(e){return t.setFontFamily(e)}var I=t.clearFontFamily();function R(e,o){return t.setUnderlineStyle(e,o)}function _(e,o){return t.setHyperlink(e,o)}var j=t.removeHyperlink();function q(e,o,i){return t.insertHyperlink(e,o,i)}exports.a=y;exports.b=F;exports.c=f;exports.d=S;exports.e=H;exports.f=T;exports.g=h;exports.h=M;exports.i=A;exports.j=v;exports.k=z;exports.l=U;exports.m=b;exports.n=B;exports.o=I;exports.p=R;exports.q=_;exports.r=j;exports.s=q;
1
+ 'use strict';var chunkYVYB4YCI_js=require('./chunk-YVYB4YCI.js'),chunkIO6HZ7KR_js=require('./chunk-IO6HZ7KR.js');function y(e){return chunkIO6HZ7KR_js.g(e,chunkYVYB4YCI_js.b)}var t=chunkYVYB4YCI_js.a.getCommands(),F=t.toggleBold(),f=t.toggleItalic(),S=t.toggleUnderline(),H=t.toggleStrike(),T=t.toggleSuperscript(),h=t.toggleSubscript();function M(e){return t.setTextColor(e)}var A=t.clearTextColor();function v(e){return t.setHighlight(e)}var z=t.clearHighlight();function U(e){return t.setFontSize(e)}var b=t.clearFontSize();function B(e){return t.setFontFamily(e)}var I=t.clearFontFamily();function R(e,o){return t.setUnderlineStyle(e,o)}function _(e,o){return t.setHyperlink(e,o)}var j=t.removeHyperlink();function q(e,o,i){return t.insertHyperlink(e,o,i)}exports.a=y;exports.b=F;exports.c=f;exports.d=S;exports.e=H;exports.f=T;exports.g=h;exports.h=M;exports.i=A;exports.j=v;exports.k=z;exports.l=U;exports.m=b;exports.n=B;exports.o=I;exports.p=R;exports.q=_;exports.r=j;exports.s=q;
@@ -0,0 +1 @@
1
+ import {w,v}from'./chunk-BRHHK4MG.mjs';var t=new w(v());t.buildSchema();t.initializeRuntime();var s=t,n=t.getSchema();export{s as a,n as b};
@@ -0,0 +1 @@
1
+ 'use strict';var xmlJs=require('xml-js');function f(e){return xmlJs.xml2js(e,{compact:false,ignoreComment:true,ignoreInstruction:true,ignoreDoctype:true,alwaysArray:false,trim:false,captureSpacesBetweenElements:true,attributesKey:"attributes",textKey:"text"})}function g(e){return xmlJs.js2xml({elements:[e]},{compact:false,spaces:0})}function h(e){try{let t=f(e);return t.elements&&t.elements.length>0?t.elements.find(n=>n.type==="element")??null:t}catch(t){return console.warn("Failed to parse XML:",t),null}}function s(e){let t=e.indexOf(":");return t>=0?e.substring(t+1):e}function c(e,t,n){if(!e.name)return false;let l=`${t}:${n}`;return e.name===l||s(e.name)===n}function x(e,t,n){if(!e||!e.elements)return null;let l=`${t}:${n}`;for(let r of e.elements)if(r.type==="element"&&(r.name===l||s(r.name||"")===n))return r;return null}function E(e,t,n){if(!e||!e.elements)return [];let l=`${t}:${n}`,r=[];for(let i of e.elements)i.type==="element"&&(i.name===l||s(i.name||"")===n)&&r.push(i);return r}function X(e,t){return !e||!e.elements?[]:e.elements.filter(n=>n.type==="element"&&s(n.name||"")===t)}function w(e,t){if(!e||!e.elements)return null;for(let n of e.elements)if(n.type==="element"&&n.name===t)return n;return null}function y(e){return !e||!e.elements?[]:e.elements.filter(t=>t.type==="element")}function o(e,t,n){if(!e||!e.attributes)return null;let l=e.attributes;if(t){let r=`${t}:${n}`;if(r in l)return l[r]}return n in l?l[n]:null}function a(e){if(!e)return "";if("text"in e&&typeof e.text=="string")return e.text;if(!e.elements)return "";let t="";for(let n of e.elements)n.type==="text"&&"text"in n?t+=n.text??"":n.type==="element"&&(t+=a(n));return t}function b(e,t,n,l=1){let r=o(e,t,n);if(r===null)return;let i=parseInt(r,10);if(!isNaN(i))return i*l}function C(e,t="w"){if(!e)return false;let n=o(e,t,"val");return n===null?true:!(n==="0"||n==="false"||n==="off")}function d(e,t,n){if(!e)return null;if(c(e,t,n))return e;if(e.elements)for(let l of e.elements){if(l.type!=="element")continue;let r=d(l,t,n);if(r)return r}return null}exports.a=f;exports.b=g;exports.c=h;exports.d=s;exports.e=x;exports.f=E;exports.g=X;exports.h=w;exports.i=y;exports.j=o;exports.k=a;exports.l=b;exports.m=C;exports.n=d;
@@ -0,0 +1,59 @@
1
+ import {h,g as g$1,a as a$1,i,k as k$1,l,m}from'./chunk-LDKESXXK.mjs';import {a}from'./chunk-HL5PQT3A.mjs';import y from'jszip';var j=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2
+ <Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships"></Relationships>`;function E(r){return r.startsWith("/")?r.slice(1):`word/${r}`}function P(r){let e=[{relsPath:"word/_rels/document.xml.rels",blocks:r.package.document.content}],t=r.package.relationships;if(!t)return e;let o=(n,c)=>{if(n)for(let[a,s]of n.entries()){let i=t.get(a);if(!i||i.type!==c||!i.target)continue;let l=E(i.target).replace(/^word\//,"");e.push({relsPath:`word/_rels/${l}.rels`,blocks:s.content});}};return o(r.package.headers,a.header),o(r.package.footers,a.footer),e}async function T(r,e){let t=r.file(e);return (t?await t.async("text"):j).replace(/<Relationships([^>]*)\/>/,"<Relationships$1></Relationships>")}function g(r){let e=0;for(let t of r.matchAll(/Id="rId(\d+)"/g)){let o=parseInt(t[1],10);o>e&&(e=o);}return e}function D(r,e){return e||{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"}[r]||"application/octet-stream"}function k(r){let e=[];for(let t of r)if(t.type==="paragraph"){for(let o of t.content)if(o.type==="run")for(let n of o.content)n.type==="drawing"&&n.image.src?.startsWith("data:")&&e.push(n.image);}else if(t.type==="table")for(let o of t.rows)for(let n of o.cells)e.push(...k(n.content));return e}var W={"image/png":"png","image/jpeg":"jpeg","image/gif":"gif","image/bmp":"bmp","image/tiff":"tiff","image/webp":"webp","image/svg+xml":"svg"};function z(r){let e=r.match(/^data:([^;]+);base64,(.+)$/);if(!e)throw new Error("Invalid data URL");let t=atob(e[2]),o=new Uint8Array(t.length);for(let n=0;n<t.length;n++)o[n]=t.charCodeAt(n);return {data:o.buffer,extension:W[e[1]]||"png"}}async function q(r,e,t){if(e.size===0)return;let o=r.file("[Content_Types].xml");if(!o)return;let n=await o.async("text"),c=false;for(let a of e)if(!n.includes(`Extension="${a}"`)){let s=D(a,"");n=n.replace("</Types>",`<Default Extension="${a}" ContentType="${s}"/></Types>`),c=true;}c&&r.file("[Content_Types].xml",n,{compression:"DEFLATE",compressionOptions:{level:t}});}function V(r){let e=0;return r.forEach(t=>{let o=t.match(/^word\/media\/image(\d+)\./);if(o){let n=parseInt(o[1],10);n>e&&(e=n);}}),e}async function A(r,e,t){let o=V(e),n=new Set;for(let{relsPath:c,blocks:a$1}of r){let s=k(a$1);if(s.length===0)continue;let i=await T(e,c),p=g(i),l=[];for(let d of s){let{data:u,extension:x}=z(d.src);o++,p++;let v=`image${o}.${x}`,R=`rId${p}`;e.file(`word/media/${v}`,u,{compression:"DEFLATE",compressionOptions:{level:t}}),l.push(`<Relationship Id="${R}" Type="${a.image}" Target="media/${v}"/>`),n.add(x),d.rId=R;}let m=i.replace("</Relationships>",l.join("")+"</Relationships>");e.file(c,m,{compression:"DEFLATE",compressionOptions:{level:t}});}await q(e,n,t);}function S(r){let e=[];for(let t of r)if(t.type==="paragraph")for(let o of t.content)o.type==="hyperlink"&&o.href&&!o.rId&&!o.anchor&&e.push(o);else if(t.type==="table")for(let o of t.rows)for(let n of o.cells)e.push(...S(n.content));return e}async function I(r,e,t){for(let{relsPath:o,blocks:n}of r){let c=S(n);if(c.length===0)continue;let a$2=await T(e,o),s=g(a$2),i=[];for(let l of c){s++;let m=`rId${s}`;i.push(`<Relationship Id="${m}" Type="${a.hyperlink}" Target="${a$1(l.href)}" TargetMode="External"/>`),l.rId=m;}let p=a$2.replace("</Relationships>",i.join("")+"</Relationships>");e.file(o,p,{compression:"DEFLATE",compressionOptions:{level:t}});}}var G="application/vnd.openxmlformats-officedocument.wordprocessingml.header+xml",K="application/vnd.openxmlformats-officedocument.wordprocessingml.footer+xml",L="application/vnd.openxmlformats-officedocument.wordprocessingml.comments+xml",X="application/vnd.openxmlformats-officedocument.wordprocessingml.commentsExtended+xml",Z="application/vnd.openxmlformats-officedocument.wordprocessingml.commentsIds+xml",H="application/vnd.openxmlformats-officedocument.wordprocessingml.commentsExtensible+xml";async function O(r,e,t){let o=r.package.relationships;if(!o)return;let n=[];for(let[p,l]of o){if(!l.target)continue;let m=l.type===a.header?G:l.type===a.footer?K:null;m&&n.push({rId:p,target:l.target.replace(/^(\/?word\/)/,""),contentType:m,relType:l.type});}if(n.length===0)return;let c=e.file("[Content_Types].xml");if(c){let p=await c.async("text"),l=false;for(let{target:m,contentType:d}of n){let u=`/word/${m}`;p.includes(`PartName="${u}"`)||(p=p.replace("</Types>",`<Override PartName="${u}" ContentType="${d}"/></Types>`),l=true);}l&&e.file("[Content_Types].xml",p,{compression:"DEFLATE",compressionOptions:{level:t}});}let a$1="word/_rels/document.xml.rels",s=await T(e,a$1),i=false;for(let{rId:p,relType:l,target:m}of n)s.includes(`Id="${p}"`)||(s=s.replace("</Relationships>",`<Relationship Id="${p}" Type="${l}" Target="${m}"/></Relationships>`),i=true);i&&e.file(a$1,s,{compression:"DEFLATE",compressionOptions:{level:t}});}async function Q(r,e){let t=[{partName:"/word/comments.xml",contentType:L,target:"comments.xml",relType:a.comments},{partName:"/word/commentsExtended.xml",contentType:X,target:"commentsExtended.xml",relType:a.commentsExtended},{partName:"/word/commentsIds.xml",contentType:Z,target:"commentsIds.xml",relType:a.commentsIds},{partName:"/word/commentsExtensible.xml",contentType:H,target:"commentsExtensible.xml",relType:a.commentsExtensible}],o=r.file("[Content_Types].xml");if(o){let a=await o.async("text"),s=false;for(let{partName:i,contentType:p}of t)a.includes(i)||(a=a.replace("</Types>",`<Override PartName="${i}" ContentType="${p}"/></Types>`),s=true);s&&r.file("[Content_Types].xml",a,{compression:"DEFLATE",compressionOptions:{level:e}});}let n="word/_rels/document.xml.rels",c=r.file(n);if(c){let a=await c.async("text"),s=false;for(let{target:i,relType:p}of t)if(!a.includes(i)){let l=`rId${g(a)+1}`;a=a.replace("</Relationships>",`<Relationship Id="${l}" Type="${p}" Target="${i}"/></Relationships>`),s=true;}s&&r.file(n,a,{compression:"DEFLATE",compressionOptions:{level:e}});}}async function b(r,e,t){let o=r.package.document.comments;if(!o||o.length===0)return;let{xml:n,paraInfos:c}=i(o);e.file("word/comments.xml",n,{compression:"DEFLATE",compressionOptions:{level:t}});let a=k$1(c);a&&e.file("word/commentsExtended.xml",a,{compression:"DEFLATE",compressionOptions:{level:t}});let s=l(c);s&&e.file("word/commentsIds.xml",s,{compression:"DEFLATE",compressionOptions:{level:t}});let i$1=m(c,o);i$1&&e.file("word/commentsExtensible.xml",i$1,{compression:"DEFLATE",compressionOptions:{level:t}}),await Q(e,t);}function U(r){let e=new Map,t=r.package.relationships;if(!t)return e;let o=[{map:r.package.headers,type:a.header},{map:r.package.footers,type:a.footer}];for(let{map:n,type:c}of o)if(n)for(let[a,s]of n.entries()){let i=t.get(a);i&&i.type===c&&i.target&&e.set(E(i.target),h(s));}return e}function F(r,e,t){let o={level:t};for(let[n,c]of U(r))e.file(n,c,{compression:"DEFLATE",compressionOptions:o});}async function C(){let r=new y;r.file("[Content_Types].xml",`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
3
+ <Types xmlns="http://schemas.openxmlformats.org/package/2006/content-types">
4
+ <Default Extension="rels" ContentType="application/vnd.openxmlformats-package.relationships+xml"/>
5
+ <Default Extension="xml" ContentType="application/xml"/>
6
+ <Override PartName="/word/document.xml" ContentType="application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml"/>
7
+ <Override PartName="/word/styles.xml" ContentType="application/vnd.openxmlformats-officedocument.wordprocessingml.styles+xml"/>
8
+ <Override PartName="/docProps/core.xml" ContentType="application/vnd.openxmlformats-package.core-properties+xml"/>
9
+ <Override PartName="/docProps/app.xml" ContentType="application/vnd.openxmlformats-officedocument.extended-properties+xml"/>
10
+ </Types>`),r.file("_rels/.rels",`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
11
+ <Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">
12
+ <Relationship Id="rId1" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument" Target="word/document.xml"/>
13
+ <Relationship Id="rId2" Type="http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties" Target="docProps/core.xml"/>
14
+ <Relationship Id="rId3" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties" Target="docProps/app.xml"/>
15
+ </Relationships>`),r.file("word/_rels/document.xml.rels",`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
16
+ <Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">
17
+ <Relationship Id="rId1" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles" Target="styles.xml"/>
18
+ </Relationships>`),r.file("word/document.xml",`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
19
+ <w:document xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main" xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships">
20
+ <w:body>
21
+ <w:p>
22
+ <w:r>
23
+ <w:t></w:t>
24
+ </w:r>
25
+ </w:p>
26
+ <w:sectPr>
27
+ <w:pgSz w:w="12240" w:h="15840"/>
28
+ <w:pgMar w:top="1440" w:right="1440" w:bottom="1440" w:left="1440" w:header="720" w:footer="720" w:gutter="0"/>
29
+ </w:sectPr>
30
+ </w:body>
31
+ </w:document>`),r.file("word/styles.xml",`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
32
+ <w:styles xmlns:w="http://schemas.openxmlformats.org/wordprocessingml/2006/main">
33
+ <w:docDefaults>
34
+ <w:rPrDefault>
35
+ <w:rPr>
36
+ <w:rFonts w:ascii="Calibri" w:hAnsi="Calibri"/>
37
+ <w:sz w:val="22"/>
38
+ </w:rPr>
39
+ </w:rPrDefault>
40
+ <w:pPrDefault>
41
+ <w:pPr>
42
+ <w:spacing w:after="200" w:line="276" w:lineRule="auto"/>
43
+ </w:pPr>
44
+ </w:pPrDefault>
45
+ </w:docDefaults>
46
+ <w:style w:type="paragraph" w:default="1" w:styleId="Normal">
47
+ <w:name w:val="Normal"/>
48
+ </w:style>
49
+ </w:styles>`);let e=new Date().toISOString();return r.file("docProps/core.xml",`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
50
+ <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">
51
+ <dc:creator>EigenPal DOCX Editor</dc:creator>
52
+ <dcterms:created xsi:type="dcterms:W3CDTF">${e}</dcterms:created>
53
+ <dcterms:modified xsi:type="dcterms:W3CDTF">${e}</dcterms:modified>
54
+ </cp:coreProperties>`),r.file("docProps/app.xml",`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
55
+ <Properties xmlns="http://schemas.openxmlformats.org/officeDocument/2006/extended-properties">
56
+ <Application>EigenPal DOCX Editor</Application>
57
+ <AppVersion>1.0.0</AppVersion>
58
+ </Properties>`),r.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:6}})}async function J(r,e={}){if(!r.originalBuffer)throw new Error("Cannot repack document: no original buffer for round-trip. Use createDocx() for new documents.");let{compressionLevel:t=6,updateModifiedDate:o=true,modifiedBy:n}=e,c=r,a=await y.loadAsync(r.originalBuffer),s=new y;for(let[m,d]of Object.entries(a.files)){if(d.dir){s.folder(m.replace(/\/$/,""));continue}let u=await d.async("arraybuffer");s.file(m,u,{compression:"DEFLATE",compressionOptions:{level:t}});}let i=P(c);await A(i,s,t),await I(i,s,t);let p=g$1(c);if(s.file("word/document.xml",p,{compression:"DEFLATE",compressionOptions:{level:t}}),F(c,s,t),await O(c,s,t),await b(c,s,t),o){let m="docProps/core.xml",d=a.file(m);if(d){let u=await d.async("text"),x=Y(u,{updateModifiedDate:o,modifiedBy:n});s.file(m,x,{compression:"DEFLATE",compressionOptions:{level:t}});}}return await s.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:t}})}async function be(r,e,t={}){let{compressionLevel:o=6,updateModifiedDate:n=true,modifiedBy:c}=t,a=r,s=new y;for(let[m,d]of Object.entries(e.originalZip.files)){if(d.dir){s.folder(m.replace(/\/$/,""));continue}let u=await d.async("arraybuffer");s.file(m,u,{compression:"DEFLATE",compressionOptions:{level:o}});}let i=P(a);await A(i,s,o),await I(i,s,o);let p=g$1(a);if(s.file("word/document.xml",p,{compression:"DEFLATE",compressionOptions:{level:o}}),F(a,s,o),await O(a,s,o),await b(a,s,o),n&&e.corePropsXml){let m=Y(e.corePropsXml,{updateModifiedDate:n,modifiedBy:c});s.file("docProps/core.xml",m,{compression:"DEFLATE",compressionOptions:{level:o}});}return await s.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:o}})}async function Fe(r,e,t={}){let{compressionLevel:o=6}=t,n=await y.loadAsync(r);return n.file("word/document.xml",e,{compression:"DEFLATE",compressionOptions:{level:o}}),n.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:o}})}async function Ce(r,e,t,o={}){let{compressionLevel:n=6}=o,c=await y.loadAsync(r);return c.file(e,t,{compression:"DEFLATE",compressionOptions:{level:n}}),c.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:n}})}async function ve(r,e,t={}){let o=await y.loadAsync(r);return te(o,e,t)}async function te(r,e,t={}){let{compressionLevel:o=6}=t;for(let[n,c]of e)r.file(n,c,{compression:"DEFLATE",compressionOptions:{level:o}});return r.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:o}})}async function oe(r,e){let t=await y.loadAsync(r),o="word/_rels/document.xml.rels",n=t.file(o);if(!n)throw new Error("document.xml.rels not found in DOCX");let c=await n.async("text"),a=`rId${g(c)+1}`,s=e.targetMode==="External"?' TargetMode="External"':"",i=`<Relationship Id="${a}" Type="${e.type}" Target="${a$1(e.target)}"${s}/>`,p=c.replace("</Relationships>",`${i}</Relationships>`);return t.file(o,p),{buffer:await t.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:6}}),rId:a}}async function Re(r,e,t,o){let n=await y.loadAsync(r),c=`word/media/${e}`;n.file(c,t);let a=await oe(await n.generateAsync({type:"arraybuffer"}),{type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",target:`media/${e}`}),s=n.file("[Content_Types].xml");if(s){let i=await s.async("text"),p=e.split(".").pop()?.toLowerCase()||"";if(!i.includes(`Extension="${p}"`)&&p){let m=D(p,o),d=`<Default Extension="${p}" ContentType="${m}"/>`,u=i.replace("</Types>",`${d}</Types>`),x=await y.loadAsync(a.buffer);return x.file("[Content_Types].xml",u),{buffer:await x.generateAsync({type:"arraybuffer",compression:"DEFLATE",compressionOptions:{level:6}}),rId:a.rId,path:c}}}return {buffer:a.buffer,rId:a.rId,path:c}}function Y(r,e){let t=r;if(e.updateModifiedDate){let o=new Date().toISOString();t.includes("<dcterms:modified")?t=t.replace(/<dcterms:modified[^>]*>[^<]*<\/dcterms:modified>/,`<dcterms:modified xsi:type="dcterms:W3CDTF">${o}</dcterms:modified>`):t=t.replace("</cp:coreProperties>",`<dcterms:modified xsi:type="dcterms:W3CDTF">${o}</dcterms:modified></cp:coreProperties>`);}return e.modifiedBy&&(t.includes("<cp:lastModifiedBy")?t=t.replace(/<cp:lastModifiedBy>[^<]*<\/cp:lastModifiedBy>/,`<cp:lastModifiedBy>${a$1(e.modifiedBy)}</cp:lastModifiedBy>`):t=t.replace("</cp:coreProperties>",`<cp:lastModifiedBy>${a$1(e.modifiedBy)}</cp:lastModifiedBy></cp:coreProperties>`)),t}async function Me(r){let e=[],t=[];try{let o=await y.loadAsync(r),n=["[Content_Types].xml","word/document.xml"];for(let i of n)o.file(i)||e.push(`Missing required file: ${i}`);let c=["_rels/.rels","word/_rels/document.xml.rels","word/styles.xml"];for(let i of c)o.file(i)||t.push(`Missing recommended file: ${i}`);let a=o.file("word/document.xml");if(a){let i=await a.async("text");i.includes("<?xml")||t.push("document.xml missing XML declaration"),i.includes("<w:document")||e.push("document.xml missing w:document element"),i.includes("<w:body>")||e.push("document.xml missing w:body element");}let s=o.file("[Content_Types].xml");if(s){let i=await s.async("text");!i.includes("word/document.xml")&&!i.includes("application/vnd.openxmlformats-officedocument.wordprocessingml.document.main+xml")&&t.push("Content_Types.xml may be missing document.xml type declaration");}}catch(o){e.push(`Failed to read as ZIP: ${o instanceof Error?o.message:"Unknown error"}`);}return {valid:e.length===0,errors:e,warnings:t}}function Ne(r){if(r.byteLength<4)return false;let e=new Uint8Array(r);return e[0]===80&&e[1]===75}async function _e(r){let e=await C(),t={...r,originalBuffer:e};return J(t)}var $e=J;
59
+ export{g as a,L as b,X as c,Z as d,H as e,U as f,C as g,J as h,be as i,Fe as j,Ce as k,ve as l,te as m,oe as n,Re as o,Y as p,Me as q,Ne as r,_e as s,$e as t};