@poe-platform/safe-bash 0.1.813 → 0.1.814

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 (516) hide show
  1. package/dist/image-ast/index.js +1 -1
  2. package/dist/mp4-ast/index.d.ts +2 -0
  3. package/dist/mp4-ast/mp4-sample-source.d.ts +52 -0
  4. package/dist/mp4-ast/mp4-source.d.ts +32 -0
  5. package/dist/office-xml/retained-xml-document.d.ts +6 -0
  6. package/dist/pdf-ast/content/evaluator.d.ts +4 -0
  7. package/dist/pdf-ast/cos/object-reader.d.ts +7 -0
  8. package/dist/pdf-ast/cos/value-parser.d.ts +1 -0
  9. package/dist/pdf-ast/edit/retained-form-appearances.d.ts +10 -0
  10. package/dist/pdf-ast/edit/retained-graph.d.ts +6 -0
  11. package/dist/pdf-ast/edit/retained-info-updates.d.ts +33 -0
  12. package/dist/pdf-ast/index.d.ts +1 -1
  13. package/dist/pdf-ast/index.js +460 -125
  14. package/dist/pdf-ast/retained-document.d.ts +5 -0
  15. package/dist/safe-bash/command-chunks/biff-KRHJ63K3-VQPJCVIL.js +5309 -0
  16. package/dist/safe-bash/command-chunks/{chunk-34G2SQX2.js → chunk-2BLTUQNK.js} +2 -2
  17. package/dist/safe-bash/command-chunks/{chunk-LLU2IQEJ.js → chunk-2BNGPR6Z.js} +2 -2
  18. package/dist/safe-bash/command-chunks/{chunk-IHSOOSNC.js → chunk-2ETEJOYX.js} +17 -17
  19. package/dist/safe-bash/command-chunks/{chunk-XIDGHIGB.js → chunk-2PKBXGXD.js} +5 -5
  20. package/dist/safe-bash/command-chunks/{chunk-6SRHWVEB.js → chunk-2VVJRVYM.js} +1 -1
  21. package/dist/safe-bash/command-chunks/{chunk-G5QVZQCO.js → chunk-3EASXF5D.js} +5 -5
  22. package/dist/safe-bash/command-chunks/{chunk-U3SBHEKH.js → chunk-3EB2FSAN.js} +9 -9
  23. package/dist/safe-bash/command-chunks/{chunk-VB2TUPO2.js → chunk-3EW7GYHM.js} +9 -9
  24. package/dist/safe-bash/command-chunks/{chunk-GVWVRPG6.js → chunk-3GRMU7TM.js} +6 -6
  25. package/dist/safe-bash/command-chunks/{chunk-63EMPQ7Z.js → chunk-3JM7E42I.js} +94 -12
  26. package/dist/safe-bash/command-chunks/{chunk-6L4IYQAT.js → chunk-3MG5EAMX.js} +4 -4
  27. package/dist/safe-bash/command-chunks/{chunk-RASQPOSV.js → chunk-3SPLP2DB.js} +1 -1
  28. package/dist/safe-bash/command-chunks/{chunk-K5COUQAQ.js → chunk-3VGQTLO6.js} +1 -1
  29. package/dist/safe-bash/command-chunks/{chunk-K7CV55K5.js → chunk-3YEQI5B7.js} +10 -10
  30. package/dist/safe-bash/command-chunks/{chunk-KCE5D4Z4.js → chunk-3ZRCL756.js} +3 -3
  31. package/dist/safe-bash/command-chunks/{chunk-SOFM3GPG.js → chunk-42MEXZBJ.js} +1 -1
  32. package/dist/safe-bash/command-chunks/{chunk-GQ2ZSPZ3.js → chunk-46AMTJPE.js} +10 -10
  33. package/dist/safe-bash/command-chunks/{chunk-MTWZEPAR.js → chunk-47IAU25U.js} +2 -2
  34. package/dist/safe-bash/command-chunks/{chunk-6GI3NTCW.js → chunk-4B2ZUGLT.js} +4 -4
  35. package/dist/safe-bash/command-chunks/{chunk-X64XGIXZ.js → chunk-4EHY6J2Z.js} +5 -5
  36. package/dist/safe-bash/command-chunks/{chunk-QQVACHZA.js → chunk-4EZJV4FZ.js} +1 -1
  37. package/dist/safe-bash/command-chunks/{chunk-SSKMPDN4.js → chunk-4GQKCUS5.js} +15 -15
  38. package/dist/safe-bash/command-chunks/{chunk-UOBW5K3M.js → chunk-4RRYWHED.js} +7 -7
  39. package/dist/safe-bash/command-chunks/{chunk-PINR7QET.js → chunk-4UPKVQWH.js} +8 -8
  40. package/dist/safe-bash/command-chunks/{chunk-I4GMCWAT.js → chunk-4YLACJHE.js} +6 -6
  41. package/dist/safe-bash/command-chunks/{chunk-PK36TVXB.js → chunk-5BIQWWLB.js} +1 -1
  42. package/dist/safe-bash/command-chunks/{chunk-P3WU3PSL.js → chunk-5L4YGRQU.js} +3 -3
  43. package/dist/safe-bash/command-chunks/{chunk-WPVBUVFK.js → chunk-5LFGXN3D.js} +6 -6
  44. package/dist/safe-bash/command-chunks/{chunk-YXD6VGVG.js → chunk-5OM3UIK3.js} +3 -3
  45. package/dist/safe-bash/command-chunks/{chunk-C5QDEB3I.js → chunk-6LPSKLLD.js} +3 -3
  46. package/dist/safe-bash/command-chunks/{chunk-XLYIVBAR.js → chunk-6QYSF7I2.js} +7 -7
  47. package/dist/safe-bash/command-chunks/{chunk-6IWE7PTK.js → chunk-6VBDJC6V.js} +6 -6
  48. package/dist/safe-bash/command-chunks/{chunk-6N5GHM72.js → chunk-6WNVGCXD.js} +8 -8
  49. package/dist/safe-bash/command-chunks/{chunk-PSCOXGCA.js → chunk-6XES7Z4G.js} +12 -12
  50. package/dist/safe-bash/command-chunks/{chunk-AFROLW6S.js → chunk-6XGDWFNQ.js} +4 -4
  51. package/dist/safe-bash/command-chunks/{chunk-WTE23QXN.js → chunk-6ZGCKUAM.js} +3 -3
  52. package/dist/safe-bash/command-chunks/{chunk-RIV6XN7K.js → chunk-7DOLY7IV.js} +2 -2
  53. package/dist/safe-bash/command-chunks/{chunk-ET2VPDUA.js → chunk-7KZ5LWV2.js} +1 -1
  54. package/dist/safe-bash/command-chunks/{chunk-NGR5KOPQ.js → chunk-A347DLRB.js} +3 -3
  55. package/dist/safe-bash/command-chunks/{chunk-ZM2Y4Z3C.js → chunk-A45UG4KT.js} +4 -4
  56. package/dist/safe-bash/command-chunks/{chunk-2Z3WRRFT.js → chunk-ADHFF2IM.js} +9 -9
  57. package/dist/safe-bash/command-chunks/{chunk-ATI464W3.js → chunk-AG2SNMP5.js} +1 -1
  58. package/dist/safe-bash/command-chunks/{chunk-HCKYUQ3L.js → chunk-AM5LANIE.js} +7 -7
  59. package/dist/safe-bash/command-chunks/{chunk-PKLJRB7W.js → chunk-AVGXFWEB.js} +48 -40
  60. package/dist/safe-bash/command-chunks/{chunk-RBTC7OFT.js → chunk-AVOGFREX.js} +5 -5
  61. package/dist/safe-bash/command-chunks/{chunk-G3RUXKVY.js → chunk-AWPI4DZR.js} +3 -3
  62. package/dist/safe-bash/command-chunks/{chunk-FYMNHG7R.js → chunk-AXXZNB7U.js} +13 -13
  63. package/dist/safe-bash/command-chunks/{chunk-2E2H7MBH.js → chunk-AY3KQ4EN.js} +7 -7
  64. package/dist/safe-bash/command-chunks/{chunk-DMCI6T6N.js → chunk-BLGGAHQW.js} +1 -1
  65. package/dist/safe-bash/command-chunks/{chunk-CU4DLVME.js → chunk-BLIFGBIO.js} +2 -2
  66. package/dist/safe-bash/command-chunks/{chunk-2V6FOLXV.js → chunk-BS3ZEQGT.js} +14 -14
  67. package/dist/safe-bash/command-chunks/{chunk-WFVSUXJL.js → chunk-BS5JEUEW.js} +8 -8
  68. package/dist/safe-bash/command-chunks/{chunk-X53AEG36.js → chunk-BZMNC7Q5.js} +7 -7
  69. package/dist/safe-bash/command-chunks/{chunk-5KGEZ3RW.js → chunk-CCMAHM3I.js} +2 -2
  70. package/dist/safe-bash/command-chunks/{chunk-3LJAXFH5.js → chunk-CIRDVCAZ.js} +7 -7
  71. package/dist/safe-bash/command-chunks/{chunk-73NYFNAS.js → chunk-CK2WFJZN.js} +5 -0
  72. package/dist/safe-bash/command-chunks/{chunk-UZL7G57V.js → chunk-CKEMZUE3.js} +7 -7
  73. package/dist/safe-bash/command-chunks/{chunk-S2N2V5U4.js → chunk-CQBACD2V.js} +2 -2
  74. package/dist/safe-bash/command-chunks/{chunk-G7NENPYV.js → chunk-CSE4VQKG.js} +12 -1
  75. package/dist/safe-bash/command-chunks/{chunk-X6RHJ6YN.js → chunk-CXME4YHU.js} +23 -0
  76. package/dist/safe-bash/command-chunks/{chunk-FTLDRH47.js → chunk-CZ5K2YPU.js} +16 -16
  77. package/dist/safe-bash/command-chunks/{chunk-7PRL6RJ6.js → chunk-DBLQUZGN.js} +2 -2
  78. package/dist/safe-bash/command-chunks/{chunk-5VQVZPP3.js → chunk-DBNJEXHK.js} +3 -3
  79. package/dist/safe-bash/command-chunks/{chunk-ZO5WBWLL.js → chunk-DN6MSXY7.js} +2 -2
  80. package/dist/safe-bash/command-chunks/{chunk-GXLXWZWH.js → chunk-DZH54L3F.js} +3 -3
  81. package/dist/safe-bash/command-chunks/{chunk-6CY5BHBS.js → chunk-EBHOZIBS.js} +6 -6
  82. package/dist/safe-bash/command-chunks/{chunk-3Y5EME26.js → chunk-ENEIE44W.js} +2 -2
  83. package/dist/safe-bash/command-chunks/{chunk-TKRLZIFI.js → chunk-EQWFKNHJ.js} +17 -17
  84. package/dist/safe-bash/command-chunks/{chunk-YV72XQKL.js → chunk-ETXPMVR6.js} +13 -13
  85. package/dist/safe-bash/command-chunks/{chunk-4Z6W5EOC.js → chunk-EV5G535P.js} +8 -8
  86. package/dist/safe-bash/command-chunks/{chunk-PZMU3Z4L.js → chunk-EVYKV3QI.js} +5 -5
  87. package/dist/safe-bash/command-chunks/{chunk-D6UMSC45.js → chunk-F4YFTO2K.js} +11 -11
  88. package/dist/safe-bash/command-chunks/{chunk-QM2HZJSJ.js → chunk-F762XDNG.js} +3 -3
  89. package/dist/safe-bash/command-chunks/{chunk-GOBUDKZ3.js → chunk-FF7UGJWS.js} +4 -4
  90. package/dist/safe-bash/command-chunks/{chunk-SGPCXAG7.js → chunk-FOONI6BD.js} +7 -7
  91. package/dist/safe-bash/command-chunks/{chunk-DYLNU57U.js → chunk-FSVJ67G5.js} +1 -1
  92. package/dist/safe-bash/command-chunks/{chunk-CLKOGAR3.js → chunk-FSYMSWJU.js} +8 -8
  93. package/dist/safe-bash/command-chunks/{chunk-FWPVQGYK.js → chunk-FUQMEUAT.js} +6 -6
  94. package/dist/safe-bash/command-chunks/{chunk-KXPCSVAT.js → chunk-FXCSPPYE.js} +20 -20
  95. package/dist/safe-bash/command-chunks/{chunk-7QZ2HP2F.js → chunk-FYYFV6PW.js} +6 -6
  96. package/dist/safe-bash/command-chunks/{chunk-3OETVNJA.js → chunk-G2COZLXX.js} +9 -9
  97. package/dist/safe-bash/command-chunks/{chunk-T6C5QP7T.js → chunk-G3TAX3CV.js} +5963 -5953
  98. package/dist/safe-bash/command-chunks/{chunk-MKX4JAZ6.js → chunk-GCHB7VNX.js} +17 -17
  99. package/dist/safe-bash/command-chunks/{chunk-4Y6O2K35.js → chunk-GLAF45M7.js} +1 -1
  100. package/dist/safe-bash/command-chunks/{chunk-7UC2Q6Z6.js → chunk-GQGMQMIM.js} +5 -5
  101. package/dist/safe-bash/command-chunks/{chunk-PI6MOMHA.js → chunk-GXMPXMDP.js} +11 -11
  102. package/dist/safe-bash/command-chunks/{chunk-57DDYKE5.js → chunk-GYM5ICK4.js} +7 -7
  103. package/dist/safe-bash/command-chunks/{chunk-5MFDRSGG.js → chunk-H33D4R26.js} +4 -4
  104. package/dist/safe-bash/command-chunks/{chunk-3ZDANXIC.js → chunk-HELAVGZH.js} +3 -3
  105. package/dist/safe-bash/command-chunks/{chunk-S4QH5BXZ.js → chunk-HGIMFVI2.js} +4 -4
  106. package/dist/safe-bash/command-chunks/{chunk-35IPOBWL.js → chunk-HI6ZYH3W.js} +10 -10
  107. package/dist/safe-bash/command-chunks/{chunk-RGOQKIG6.js → chunk-HK6MSB7Z.js} +5 -5
  108. package/dist/safe-bash/command-chunks/{chunk-7ZE3VIAN.js → chunk-IB5QP4LF.js} +2 -2
  109. package/dist/safe-bash/command-chunks/{chunk-UCR5YDV3.js → chunk-IBYMPAUW.js} +1 -1
  110. package/dist/safe-bash/command-chunks/{chunk-LABOWPFB.js → chunk-IHXZMAMY.js} +9 -9
  111. package/dist/safe-bash/command-chunks/{chunk-PVGZMLC6.js → chunk-IWHNRYER.js} +3 -3
  112. package/dist/safe-bash/command-chunks/{chunk-PPO7YUZF.js → chunk-JGKSWDGP.js} +1 -1
  113. package/dist/safe-bash/command-chunks/{chunk-GKILM4HZ.js → chunk-JR3Q6QNL.js} +7 -7
  114. package/dist/safe-bash/command-chunks/{chunk-D55REQA3.js → chunk-JUHOL5KB.js} +1 -1
  115. package/dist/safe-bash/command-chunks/{chunk-3O2YEI47.js → chunk-JVKE7YZN.js} +3 -3
  116. package/dist/safe-bash/command-chunks/{chunk-6NATRKUJ.js → chunk-JW6WVNTM.js} +1 -1
  117. package/dist/safe-bash/command-chunks/{chunk-IK6K2HCG.js → chunk-JWORWL72.js} +1 -1
  118. package/dist/safe-bash/command-chunks/{chunk-N32GSM3J.js → chunk-K2WOMJOQ.js} +1 -1
  119. package/dist/safe-bash/command-chunks/{chunk-TQEB4DH4.js → chunk-K4XNUJVJ.js} +1 -1
  120. package/dist/safe-bash/command-chunks/{chunk-HKOMXGJS.js → chunk-KBAQHE5Y.js} +2 -2
  121. package/dist/safe-bash/command-chunks/{chunk-T3E5RV3U.js → chunk-KCLJGRU7.js} +12 -12
  122. package/dist/safe-bash/command-chunks/{chunk-TUDFMNPP.js → chunk-KINIV2SV.js} +1 -1
  123. package/dist/safe-bash/command-chunks/{chunk-43TRBJ2N.js → chunk-KPHLESD4.js} +4 -4
  124. package/dist/safe-bash/command-chunks/{chunk-C5KLFZGT.js → chunk-KSBNZTAZ.js} +6 -6
  125. package/dist/safe-bash/command-chunks/{chunk-4Y34ZG4T.js → chunk-KUOCGGEU.js} +11 -11
  126. package/dist/safe-bash/command-chunks/{chunk-ML5R5JML.js → chunk-KY4LCHUF.js} +1 -1
  127. package/dist/safe-bash/command-chunks/{chunk-7NXTEWPR.js → chunk-LAPOMHGY.js} +132 -195
  128. package/dist/safe-bash/command-chunks/{chunk-KBUBSMCQ.js → chunk-LDW3RF7Y.js} +12 -12
  129. package/dist/safe-bash/command-chunks/{chunk-U27XPNLP.js → chunk-LEO4VRIN.js} +2 -2
  130. package/dist/safe-bash/command-chunks/{chunk-GZ3VIWNN.js → chunk-LKGTH2Q7.js} +7 -7
  131. package/dist/safe-bash/command-chunks/{chunk-TODWFDYB.js → chunk-LNTEV56A.js} +2 -2
  132. package/dist/safe-bash/command-chunks/{chunk-DVGXLBUW.js → chunk-LZ2JFMKT.js} +10 -10
  133. package/dist/safe-bash/command-chunks/{chunk-6D2BMAF4.js → chunk-MEM2ZPMI.js} +2 -2
  134. package/dist/safe-bash/command-chunks/{chunk-GNXTMSYN.js → chunk-MGMTRGKM.js} +4 -4
  135. package/dist/safe-bash/command-chunks/{chunk-B3NLITWP.js → chunk-MKK6FM5H.js} +7 -7
  136. package/dist/safe-bash/command-chunks/{chunk-BK7ISUJL.js → chunk-MKOIPOXX.js} +3 -3
  137. package/dist/safe-bash/command-chunks/chunk-MLOYUXUV.js +244 -0
  138. package/dist/safe-bash/command-chunks/{chunk-CBNKHBLD.js → chunk-MNK3DDH6.js} +2 -2
  139. package/dist/safe-bash/command-chunks/{chunk-JVGUVHWI.js → chunk-MPXMRTMY.js} +10 -10
  140. package/dist/safe-bash/command-chunks/{chunk-EJTNVXWF.js → chunk-MVLVIMJ6.js} +6 -6
  141. package/dist/safe-bash/command-chunks/{chunk-TY4WDAHM.js → chunk-MYZ46FQL.js} +1 -1
  142. package/dist/safe-bash/command-chunks/{chunk-TBAIMDGL.js → chunk-N4MUBJCT.js} +1 -1
  143. package/dist/safe-bash/command-chunks/{chunk-NPLVFAD6.js → chunk-N6G3345Q.js} +8 -8
  144. package/dist/safe-bash/command-chunks/{chunk-4PBNMKAT.js → chunk-NEMUPUUB.js} +7 -7
  145. package/dist/safe-bash/command-chunks/{chunk-MUUWBZIC.js → chunk-NEVQWOU6.js} +10 -10
  146. package/dist/safe-bash/command-chunks/{chunk-KZ5ODST6.js → chunk-NFGCBQN3.js} +2 -2
  147. package/dist/safe-bash/command-chunks/{chunk-LD7BONZY.js → chunk-NFII726L.js} +2 -2
  148. package/dist/safe-bash/command-chunks/{chunk-JQPNA77Y.js → chunk-NHNZYWPW.js} +2 -2
  149. package/dist/safe-bash/command-chunks/{chunk-ZYLGNIGA.js → chunk-NQINS4XY.js} +1 -1
  150. package/dist/safe-bash/command-chunks/{chunk-UAF4IX5H.js → chunk-NRFTYZ2R.js} +6 -6
  151. package/dist/safe-bash/command-chunks/{chunk-THMZLJQD.js → chunk-NYFYTL5G.js} +18 -18
  152. package/dist/safe-bash/command-chunks/{chunk-SMSGLRIH.js → chunk-OTF2AJ5M.js} +6 -6
  153. package/dist/safe-bash/command-chunks/{chunk-NPFHUS4X.js → chunk-OVQP6KH5.js} +6 -6
  154. package/dist/safe-bash/command-chunks/{chunk-QFF5KBOM.js → chunk-P2LT6TGR.js} +9 -9
  155. package/dist/safe-bash/command-chunks/{chunk-RLCQ7BN3.js → chunk-PIVH35EQ.js} +3 -3
  156. package/dist/safe-bash/command-chunks/{chunk-BEHUSUOY.js → chunk-PLMF35XK.js} +4 -4
  157. package/dist/safe-bash/command-chunks/{chunk-PXWS3Q7L.js → chunk-PLR5IULU.js} +5 -5
  158. package/dist/safe-bash/command-chunks/{chunk-DBLHCJJU.js → chunk-PS5GDFIP.js} +2 -2
  159. package/dist/safe-bash/command-chunks/{chunk-P7EL2FWW.js → chunk-Q5PWYPQV.js} +7 -7
  160. package/dist/safe-bash/command-chunks/{chunk-AJI55RS7.js → chunk-Q7TVCBU2.js} +1 -1
  161. package/dist/safe-bash/command-chunks/{chunk-EHTOHOTR.js → chunk-QB72X7FF.js} +9 -9
  162. package/dist/safe-bash/command-chunks/{chunk-F3GP3EXE.js → chunk-RGDOYWOD.js} +2 -2
  163. package/dist/safe-bash/command-chunks/{chunk-MNHBQBF6.js → chunk-RHDERFMR.js} +5 -5
  164. package/dist/safe-bash/command-chunks/{chunk-3KMOXEGH.js → chunk-RHU44OMN.js} +2 -2
  165. package/dist/safe-bash/command-chunks/{chunk-XG6UWQV5.js → chunk-RIVKF77R.js} +6 -6
  166. package/dist/safe-bash/command-chunks/{chunk-UOR6PXZZ.js → chunk-ROL5AEX6.js} +1 -1
  167. package/dist/safe-bash/command-chunks/{chunk-3TYDSGAH.js → chunk-RQYPFLZJ.js} +6 -6
  168. package/dist/safe-bash/command-chunks/{chunk-3Y4XZB24.js → chunk-RTNI47C5.js} +4 -4
  169. package/dist/safe-bash/command-chunks/{chunk-W5LLKV5H.js → chunk-RV5AGXOV.js} +2 -2
  170. package/dist/safe-bash/command-chunks/{chunk-JUJHYPYL.js → chunk-RXQ2G2YK.js} +9 -9
  171. package/dist/safe-bash/command-chunks/{chunk-EVU7FLDA.js → chunk-S2QNBAN6.js} +7 -7
  172. package/dist/safe-bash/command-chunks/{chunk-YE6OAKK7.js → chunk-S43QRKDC.js} +7 -7
  173. package/dist/safe-bash/command-chunks/{chunk-774GLJAO.js → chunk-S7HIOT7Z.js} +4 -4
  174. package/dist/safe-bash/command-chunks/{chunk-3D24WDND.js → chunk-SEPUP6TZ.js} +1 -1
  175. package/dist/safe-bash/command-chunks/{chunk-JPMYPOYZ.js → chunk-SUTHGUD3.js} +28 -28
  176. package/dist/safe-bash/command-chunks/{chunk-CTDC4LJT.js → chunk-SW37YCBW.js} +15 -10
  177. package/dist/safe-bash/command-chunks/{chunk-D6WJY6QO.js → chunk-SWAKALDJ.js} +10 -10
  178. package/dist/safe-bash/command-chunks/{chunk-WGH3RLJY.js → chunk-T5S4SJGO.js} +9 -9
  179. package/dist/safe-bash/command-chunks/{chunk-7JEIWA3A.js → chunk-TID5TSQW.js} +5 -5
  180. package/dist/safe-bash/command-chunks/{chunk-EZ4NQIPL.js → chunk-TJLXSENN.js} +1 -1
  181. package/dist/safe-bash/command-chunks/{chunk-HVW53ARH.js → chunk-TKCUGMRZ.js} +24 -20
  182. package/dist/safe-bash/command-chunks/{chunk-5P6I2T63.js → chunk-TXPDKEGY.js} +8 -8
  183. package/dist/safe-bash/command-chunks/{chunk-MPKY37QR.js → chunk-UJERQEJB.js} +1 -1
  184. package/dist/safe-bash/command-chunks/{chunk-V37D6AHO.js → chunk-USGZN2KE.js} +5 -5
  185. package/dist/safe-bash/command-chunks/{chunk-JAHJWVGF.js → chunk-UYGQEQIP.js} +5 -5
  186. package/dist/safe-bash/command-chunks/{chunk-MPORWUTU.js → chunk-V5XC43BX.js} +8 -8
  187. package/dist/safe-bash/command-chunks/{chunk-AIMSZBWP.js → chunk-V7E3PZOK.js} +9 -9
  188. package/dist/safe-bash/command-chunks/{chunk-CNHRVUHA.js → chunk-VDTFVRYX.js} +1 -1
  189. package/dist/safe-bash/command-chunks/{chunk-M3Z5PU2M.js → chunk-VT2PHQ63.js} +15 -15
  190. package/dist/safe-bash/command-chunks/{chunk-JORIVUPM.js → chunk-VT7UBPAE.js} +15 -8
  191. package/dist/safe-bash/command-chunks/{chunk-QDVI2YB6.js → chunk-VUWXLH3E.js} +2 -2
  192. package/dist/safe-bash/command-chunks/{chunk-O675URF4.js → chunk-W3ZSWK76.js} +8 -8
  193. package/dist/safe-bash/command-chunks/{chunk-JPA2PUYI.js → chunk-WBKB7HBZ.js} +8 -8
  194. package/dist/safe-bash/command-chunks/{chunk-6244HYJY.js → chunk-WJ2ERUCQ.js} +1 -1
  195. package/dist/safe-bash/command-chunks/{chunk-U5TWQFZY.js → chunk-WTVJLHMG.js} +1 -1
  196. package/dist/safe-bash/command-chunks/{chunk-SLQWQKXP.js → chunk-WWHMI4S3.js} +9 -9
  197. package/dist/safe-bash/command-chunks/{chunk-2UBZALAK.js → chunk-WYZG3DRR.js} +1 -1
  198. package/dist/safe-bash/command-chunks/{chunk-T5ERNELL.js → chunk-WZRFS5OY.js} +4 -4
  199. package/dist/safe-bash/command-chunks/{chunk-2DGJOOXM.js → chunk-X6OHFKBL.js} +8 -8
  200. package/dist/safe-bash/command-chunks/{chunk-S6ZTBXYO.js → chunk-XKAUKLF7.js} +13 -13
  201. package/dist/safe-bash/command-chunks/{chunk-NKTULXVD.js → chunk-XM5QJCPD.js} +8 -8
  202. package/dist/safe-bash/command-chunks/{chunk-BBAB7LC4.js → chunk-XMTR7QGL.js} +4 -4
  203. package/dist/safe-bash/command-chunks/{chunk-5IFRAI7Y.js → chunk-XNGM3W5R.js} +1 -1
  204. package/dist/safe-bash/command-chunks/{chunk-Z5BIM5B7.js → chunk-XTEIT5CI.js} +1 -1
  205. package/dist/safe-bash/command-chunks/{chunk-4DLIUTQV.js → chunk-XU6S3XUZ.js} +11 -11
  206. package/dist/safe-bash/command-chunks/{chunk-EXOQGXEU.js → chunk-XUJAQA3S.js} +30 -30
  207. package/dist/safe-bash/command-chunks/{chunk-VVWXY6IA.js → chunk-Y42KSX63.js} +6 -6
  208. package/dist/safe-bash/command-chunks/{chunk-R2BMZAHG.js → chunk-Y54L4P4J.js} +5 -5
  209. package/dist/safe-bash/command-chunks/{chunk-6WQD7LRA.js → chunk-YAD7EV4N.js} +14 -14
  210. package/dist/safe-bash/command-chunks/{chunk-YUXTK3XA.js → chunk-YRPXBGRX.js} +3 -3
  211. package/dist/safe-bash/command-chunks/{chunk-NMPED6L5.js → chunk-Z2WNYEPD.js} +4 -4
  212. package/dist/safe-bash/command-chunks/{chunk-7PZHWMK6.js → chunk-Z7QOSXQC.js} +7 -7
  213. package/dist/safe-bash/command-chunks/{chunk-VQOINPVF.js → chunk-ZQM37BGE.js} +2 -2
  214. package/dist/safe-bash/command-chunks/{chunk-W3HV45CI.js → chunk-ZSQZHFWS.js} +9 -9
  215. package/dist/safe-bash/command-chunks/{chunk-IDJQP3A6.js → chunk-ZTMZO4IT.js} +1 -1
  216. package/dist/safe-bash/command-chunks/{chunk-V6XBEYPC.js → chunk-ZU2KJMXO.js} +8 -8
  217. package/dist/safe-bash/command-chunks/{chunk-YXKNJ6EM.js → chunk-ZXELXF2H.js} +5 -5
  218. package/dist/safe-bash/command-chunks/{clipboard-BBDK33GP-VB22F7GI.js → clipboard-BBDK33GP-QZ4ERNQX.js} +2 -2
  219. package/dist/safe-bash/command-chunks/{command-engine-X3OLN7N6.js → command-engine-7V6PZR7G.js} +931 -680
  220. package/dist/safe-bash/command-chunks/{engine-XUCIFZ7V-LJFGZM6O.js → engine-UYJENSWK-VSCGKSQV.js} +1 -1
  221. package/dist/safe-bash/command-chunks/{gnumeric-UJPXWBVR-YPXTNEDZ.js → gnumeric-UJPXWBVR-7VOHQAPM.js} +2 -2
  222. package/dist/safe-bash/command-chunks/{model-store-E7BHBFJC.js → model-store-UB5DWMAP.js} +24 -24
  223. package/dist/safe-bash-command-awk/awk-runtime.js +3 -3
  224. package/dist/safe-bash-command-awk/awk.js +4 -4
  225. package/dist/safe-bash-command-awk/index.js +4 -4
  226. package/dist/safe-bash-command-diff/diff.js +2 -2
  227. package/dist/safe-bash-command-diff/index.js +3 -3
  228. package/dist/safe-bash-command-diff/sync.js +2 -2
  229. package/dist/safe-bash-command-du/du.js +2 -2
  230. package/dist/safe-bash-command-du/index.js +2 -2
  231. package/dist/safe-bash-command-ffmpeg/index.js +1 -1
  232. package/dist/safe-bash-command-ffprobe/index.js +2 -2
  233. package/dist/safe-bash-command-ffprobe/media.js +2 -2
  234. package/dist/safe-bash-command-html-to-markdown/index.js +3 -234
  235. package/dist/safe-bash-command-html-to-markdown/stored-text.d.ts +50 -0
  236. package/dist/safe-bash-command-html-to-markdown/stored-text.js +12 -0
  237. package/dist/safe-bash-command-htmlq/contracts.d.ts +5 -0
  238. package/dist/safe-bash-command-htmlq/index.js +1715 -292
  239. package/dist/safe-bash-command-htmlq/selectors.d.ts +38 -1
  240. package/dist/safe-bash-command-htmlq/serializer.d.ts +1 -0
  241. package/dist/safe-bash-command-htmlq/tree.d.ts +1 -0
  242. package/dist/safe-bash-command-iconv/command.js +2 -2
  243. package/dist/safe-bash-command-iconv/index.js +2 -2
  244. package/dist/safe-bash-command-llm/command.js +3 -3
  245. package/dist/safe-bash-command-llm/index.js +9 -9
  246. package/dist/safe-bash-command-llm/openai.js +2 -2
  247. package/dist/safe-bash-command-llm/providers/index.js +2 -2
  248. package/dist/safe-bash-command-llm/providers/openai.js +2 -2
  249. package/dist/safe-bash-command-node/commands/node/browser.js +2 -2
  250. package/dist/safe-bash-command-node/commands/node/default-runtime.js +2 -2
  251. package/dist/safe-bash-command-node/commands/node/safejs.js +2 -2
  252. package/dist/safe-bash-command-pandoc/command.js +4 -4
  253. package/dist/safe-bash-command-pandoc/index.js +39 -39
  254. package/dist/safe-bash-command-patch/index.js +6 -6
  255. package/dist/safe-bash-command-patch/patch-formats.d.ts +6 -1
  256. package/dist/safe-bash-command-patch/patch-formats.js +6 -4
  257. package/dist/safe-bash-command-patch/patch-gnu-paths.d.ts +7 -7
  258. package/dist/safe-bash-command-patch/patch-gnu-reject.d.ts +2 -2
  259. package/dist/safe-bash-command-patch/patch-gnu-reject.js +2 -2
  260. package/dist/safe-bash-command-patch/patch-publication.js +2 -2
  261. package/dist/safe-bash-command-patch/patch.js +6 -6
  262. package/dist/safe-bash-command-patch/stored-patch.d.ts +26 -0
  263. package/dist/safe-bash-command-patch/stored-target.d.ts +40 -0
  264. package/dist/safe-bash-command-patch/unified.d.ts +13 -8
  265. package/dist/safe-bash-command-patch/unified.js +3 -1
  266. package/dist/safe-bash-command-pdftk/index.js +741 -426
  267. package/dist/safe-bash-command-playwright-cli/index.js +26 -26
  268. package/dist/safe-bash-command-playwright-cli/playwright/abilities.js +10 -10
  269. package/dist/safe-bash-command-playwright-cli/playwright/controller.js +14 -14
  270. package/dist/safe-bash-command-playwright-cli/playwright/index.js +23 -23
  271. package/dist/safe-bash-command-playwright-cli/playwright/snapshot.js +2 -2
  272. package/dist/safe-bash-command-playwright-cli/playwright/standard-capabilities.js +6 -6
  273. package/dist/safe-bash-command-playwright-cli/playwright/storage-capabilities.js +4 -4
  274. package/dist/safe-bash-command-pptx/command-engine.d.ts +2 -1
  275. package/dist/safe-bash-command-pptx/engine.js +1 -1
  276. package/dist/safe-bash-command-pptx/index.d.ts +1 -1
  277. package/dist/safe-bash-command-pptx/index.js +163 -17
  278. package/dist/safe-bash-command-pptx/streaming-inputs.d.ts +7 -2
  279. package/dist/safe-bash-command-python/executor.js +5 -5
  280. package/dist/safe-bash-command-python/index.js +5 -5
  281. package/dist/safe-bash-command-python/jspi.js +2 -2
  282. package/dist/safe-bash-command-soffice/index.js +1 -1
  283. package/dist/safe-bash-command-sort/index.js +3 -3
  284. package/dist/safe-bash-command-ssconvert/index.js +2 -2
  285. package/dist/safe-bash-command-tar/create.js +2 -2
  286. package/dist/safe-bash-command-tar/extract.js +2 -2
  287. package/dist/safe-bash-command-tar/index.js +8 -8
  288. package/dist/safe-bash-command-tar/modes.js +4 -4
  289. package/dist/safe-bash-command-timeout/index.js +3 -3
  290. package/dist/safe-bash-command-tree/index.js +2 -2
  291. package/dist/safe-bash-command-tree/tree.js +2 -2
  292. package/dist/safe-bash-command-xz/index.js +5 -5
  293. package/dist/safe-bash-compression-engine/files.js +2 -2
  294. package/dist/safe-bash-compression-engine/operand.js +4 -4
  295. package/dist/safe-bash-contracts/diagnostics.js +3 -3
  296. package/dist/safe-bash-contracts/escaping.js +10 -10
  297. package/dist/safe-bash-contracts/filesystem-descriptor.js +1 -1
  298. package/dist/safe-bash-contracts/filesystem-output.js +6 -6
  299. package/dist/safe-bash-contracts/index.js +33 -33
  300. package/dist/safe-bash-contracts/io.js +2 -2
  301. package/dist/safe-bash-contracts/output.js +3 -3
  302. package/dist/safe-bash-docx-engine/ancillary-resources.js +5 -5
  303. package/dist/safe-bash-docx-engine/batch-operations.js +63 -63
  304. package/dist/safe-bash-docx-engine/batch-result-schema.js +74 -74
  305. package/dist/safe-bash-docx-engine/batch.js +74 -74
  306. package/dist/safe-bash-docx-engine/bookmarks.js +13 -13
  307. package/dist/safe-bash-docx-engine/charts.js +6 -6
  308. package/dist/safe-bash-docx-engine/command-option-rules.js +3 -3
  309. package/dist/safe-bash-docx-engine/comments.js +21 -21
  310. package/dist/safe-bash-docx-engine/control-bindings.js +16 -16
  311. package/dist/safe-bash-docx-engine/control-repeat.js +16 -16
  312. package/dist/safe-bash-docx-engine/controls.js +14 -14
  313. package/dist/safe-bash-docx-engine/create.js +8 -8
  314. package/dist/safe-bash-docx-engine/diagrams.js +6 -6
  315. package/dist/safe-bash-docx-engine/diff.js +8 -8
  316. package/dist/safe-bash-docx-engine/document-properties.js +12 -12
  317. package/dist/safe-bash-docx-engine/equations.js +12 -12
  318. package/dist/safe-bash-docx-engine/extract.js +9 -9
  319. package/dist/safe-bash-docx-engine/fields.js +18 -18
  320. package/dist/safe-bash-docx-engine/font-inventory.js +13 -13
  321. package/dist/safe-bash-docx-engine/font-resources.js +3 -3
  322. package/dist/safe-bash-docx-engine/image-batch-operations.js +11 -11
  323. package/dist/safe-bash-docx-engine/image-insertion.js +17 -17
  324. package/dist/safe-bash-docx-engine/image-layout.js +14 -14
  325. package/dist/safe-bash-docx-engine/image-replacement.js +19 -19
  326. package/dist/safe-bash-docx-engine/images.js +14 -14
  327. package/dist/safe-bash-docx-engine/index.js +102 -102
  328. package/dist/safe-bash-docx-engine/inspection.js +15 -15
  329. package/dist/safe-bash-docx-engine/invocation.js +4 -4
  330. package/dist/safe-bash-docx-engine/io.js +6 -6
  331. package/dist/safe-bash-docx-engine/links.js +17 -17
  332. package/dist/safe-bash-docx-engine/lists.js +16 -16
  333. package/dist/safe-bash-docx-engine/locations.js +10 -10
  334. package/dist/safe-bash-docx-engine/notes.js +18 -18
  335. package/dist/safe-bash-docx-engine/objects.js +14 -14
  336. package/dist/safe-bash-docx-engine/pack.js +9 -9
  337. package/dist/safe-bash-docx-engine/package-view-batch-operations.js +19 -19
  338. package/dist/safe-bash-docx-engine/pandoc-adapter.js +25 -25
  339. package/dist/safe-bash-docx-engine/paragraph-edit.js +21 -21
  340. package/dist/safe-bash-docx-engine/publication.js +6 -6
  341. package/dist/safe-bash-docx-engine/removal.js +16 -16
  342. package/dist/safe-bash-docx-engine/revision-decisions.js +16 -16
  343. package/dist/safe-bash-docx-engine/revision-edit.js +15 -15
  344. package/dist/safe-bash-docx-engine/revisions.js +12 -12
  345. package/dist/safe-bash-docx-engine/run-format.js +15 -15
  346. package/dist/safe-bash-docx-engine/sanitize.js +29 -29
  347. package/dist/safe-bash-docx-engine/sections.js +15 -15
  348. package/dist/safe-bash-docx-engine/settings.js +6 -6
  349. package/dist/safe-bash-docx-engine/shape-edit.js +16 -16
  350. package/dist/safe-bash-docx-engine/signatures.js +11 -11
  351. package/dist/safe-bash-docx-engine/stories.js +18 -18
  352. package/dist/safe-bash-docx-engine/structure-model-batch-operations.js +34 -34
  353. package/dist/safe-bash-docx-engine/style-model-batch-operations.js +24 -24
  354. package/dist/safe-bash-docx-engine/style-model-result-schema.js +39 -39
  355. package/dist/safe-bash-docx-engine/styles.js +14 -14
  356. package/dist/safe-bash-docx-engine/table-edit.js +23 -23
  357. package/dist/safe-bash-docx-engine/table-read.js +11 -11
  358. package/dist/safe-bash-docx-engine/template.js +17 -17
  359. package/dist/safe-bash-docx-engine/text-replace.js +15 -15
  360. package/dist/safe-bash-docx-engine/text-resource-read.js +11 -11
  361. package/dist/safe-bash-docx-engine/text.js +11 -11
  362. package/dist/safe-bash-docx-engine/validation.js +4 -4
  363. package/dist/safe-bash-docx-engine/xml-parts.js +17 -17
  364. package/dist/safe-bash-io-engine/commands/text-programs/shared.js +4 -4
  365. package/dist/safe-bash-line-ending-engine/command.js +3 -3
  366. package/dist/safe-bash-line-ending-engine/convert.js +2 -2
  367. package/dist/safe-bash-line-ending-engine/index.js +6 -6
  368. package/dist/safe-bash-line-ending-engine/info.js +2 -2
  369. package/dist/safe-bash-markdown-engine/commonmark-blocks.js +4 -4
  370. package/dist/safe-bash-markdown-engine/commonmark-inlines.js +4 -4
  371. package/dist/safe-bash-markdown-engine/commonmark-syntax.js +2 -2
  372. package/dist/safe-bash-markdown-engine/gfm-syntax.js +3 -3
  373. package/dist/safe-bash-markdown-engine/index.js +5 -5
  374. package/dist/safe-bash-network-engine/transfer.js +3 -3
  375. package/dist/safe-bash-presentation-engine/accessibility.js +30 -30
  376. package/dist/safe-bash-presentation-engine/animation-editing.js +15 -15
  377. package/dist/safe-bash-presentation-engine/animations.js +15 -15
  378. package/dist/safe-bash-presentation-engine/backgrounds.js +16 -16
  379. package/dist/safe-bash-presentation-engine/bytes.js +3 -3
  380. package/dist/safe-bash-presentation-engine/chart-editing.js +33 -33
  381. package/dist/safe-bash-presentation-engine/chart-object-operations.js +24 -24
  382. package/dist/safe-bash-presentation-engine/charts.js +30 -30
  383. package/dist/safe-bash-presentation-engine/command-placeholder.js +58 -58
  384. package/dist/safe-bash-presentation-engine/comments.js +16 -16
  385. package/dist/safe-bash-presentation-engine/connector-operations.js +31 -31
  386. package/dist/safe-bash-presentation-engine/connectors.js +28 -28
  387. package/dist/safe-bash-presentation-engine/content-types.js +4 -4
  388. package/dist/safe-bash-presentation-engine/creation.js +6 -6
  389. package/dist/safe-bash-presentation-engine/diff.js +31 -31
  390. package/dist/safe-bash-presentation-engine/drawing-format.js +19 -19
  391. package/dist/safe-bash-presentation-engine/drawing-operations.js +30 -30
  392. package/dist/safe-bash-presentation-engine/drawing-schema.js +20 -20
  393. package/dist/safe-bash-presentation-engine/equations.js +16 -16
  394. package/dist/safe-bash-presentation-engine/errors.js +2 -2
  395. package/dist/safe-bash-presentation-engine/fields.js +16 -16
  396. package/dist/safe-bash-presentation-engine/font-metrics.js +3 -3
  397. package/dist/safe-bash-presentation-engine/image-extraction.js +19 -19
  398. package/dist/safe-bash-presentation-engine/image-formatting.js +31 -31
  399. package/dist/safe-bash-presentation-engine/image-insertion.js +17 -17
  400. package/dist/safe-bash-presentation-engine/image-replacement.js +20 -20
  401. package/dist/safe-bash-presentation-engine/image-value.js +4 -4
  402. package/dist/safe-bash-presentation-engine/images.js +18 -18
  403. package/dist/safe-bash-presentation-engine/index.js +114 -114
  404. package/dist/safe-bash-presentation-engine/layouts.js +15 -15
  405. package/dist/safe-bash-presentation-engine/length.js +3 -3
  406. package/dist/safe-bash-presentation-engine/links.js +15 -15
  407. package/dist/safe-bash-presentation-engine/masters.js +14 -14
  408. package/dist/safe-bash-presentation-engine/media-editing.js +23 -23
  409. package/dist/safe-bash-presentation-engine/media-extraction.js +16 -16
  410. package/dist/safe-bash-presentation-engine/media.js +15 -15
  411. package/dist/safe-bash-presentation-engine/memberships.js +14 -14
  412. package/dist/safe-bash-presentation-engine/notes.js +15 -15
  413. package/dist/safe-bash-presentation-engine/ole-enum.js +4 -4
  414. package/dist/safe-bash-presentation-engine/ole-insertion.js +19 -19
  415. package/dist/safe-bash-presentation-engine/opaque-objects.js +9 -9
  416. package/dist/safe-bash-presentation-engine/package-reader.js +5 -5
  417. package/dist/safe-bash-presentation-engine/package-tools.js +18 -18
  418. package/dist/safe-bash-presentation-engine/package-uri.js +3 -3
  419. package/dist/safe-bash-presentation-engine/package-writer.js +4 -4
  420. package/dist/safe-bash-presentation-engine/presentation-model.js +57 -57
  421. package/dist/safe-bash-presentation-engine/presentation-settings.js +13 -13
  422. package/dist/safe-bash-presentation-engine/properties.js +15 -15
  423. package/dist/safe-bash-presentation-engine/relationships.js +4 -4
  424. package/dist/safe-bash-presentation-engine/resource-limits.js +1 -1
  425. package/dist/safe-bash-presentation-engine/retained-frame-formatting.d.ts +14 -0
  426. package/dist/safe-bash-presentation-engine/retained-inspection.js +13 -13
  427. package/dist/safe-bash-presentation-engine/retained-package.js +5 -5
  428. package/dist/safe-bash-presentation-engine/retained-text.d.ts +9 -2
  429. package/dist/safe-bash-presentation-engine/retained-text.js +130 -31
  430. package/dist/safe-bash-presentation-engine/retained-xml-document.d.ts +1 -0
  431. package/dist/safe-bash-presentation-engine/sanitize.js +16 -16
  432. package/dist/safe-bash-presentation-engine/selectors.js +10 -10
  433. package/dist/safe-bash-presentation-engine/shape-groups.js +30 -30
  434. package/dist/safe-bash-presentation-engine/shape-operations.js +29 -29
  435. package/dist/safe-bash-presentation-engine/shape-path-operations.js +31 -31
  436. package/dist/safe-bash-presentation-engine/shape-paths.js +15 -15
  437. package/dist/safe-bash-presentation-engine/shape-presets.js +3 -3
  438. package/dist/safe-bash-presentation-engine/shape-selection.js +30 -30
  439. package/dist/safe-bash-presentation-engine/shape-transforms.js +17 -17
  440. package/dist/safe-bash-presentation-engine/shapes.js +26 -26
  441. package/dist/safe-bash-presentation-engine/slide-copy.js +16 -16
  442. package/dist/safe-bash-presentation-engine/slide-import.js +17 -17
  443. package/dist/safe-bash-presentation-engine/slide-merge-split.js +19 -19
  444. package/dist/safe-bash-presentation-engine/slide-model.js +42 -42
  445. package/dist/safe-bash-presentation-engine/slide-removal.js +17 -17
  446. package/dist/safe-bash-presentation-engine/slide-transfer-budget.js +9 -9
  447. package/dist/safe-bash-presentation-engine/slides.js +18 -18
  448. package/dist/safe-bash-presentation-engine/table-operations.js +32 -32
  449. package/dist/safe-bash-presentation-engine/table-spans.js +31 -31
  450. package/dist/safe-bash-presentation-engine/tables.js +30 -30
  451. package/dist/safe-bash-presentation-engine/tags.js +15 -15
  452. package/dist/safe-bash-presentation-engine/template-bindings.js +32 -32
  453. package/dist/safe-bash-presentation-engine/template-repeat.js +39 -39
  454. package/dist/safe-bash-presentation-engine/text-fitting.js +26 -26
  455. package/dist/safe-bash-presentation-engine/text-frames.d.ts +13 -0
  456. package/dist/safe-bash-presentation-engine/text-frames.js +28 -26
  457. package/dist/safe-bash-presentation-engine/text-paragraphs.js +26 -26
  458. package/dist/safe-bash-presentation-engine/text-reading.js +11 -11
  459. package/dist/safe-bash-presentation-engine/text-replacement.js +16 -16
  460. package/dist/safe-bash-presentation-engine/text-runs.js +19 -19
  461. package/dist/safe-bash-presentation-engine/themes.js +15 -15
  462. package/dist/safe-bash-presentation-engine/transitions.js +15 -15
  463. package/dist/safe-bash-presentation-engine/validation.js +9 -9
  464. package/dist/safe-bash-presentation-engine/xml-parts.js +18 -18
  465. package/dist/safe-bash-presentation-engine/xml-view.js +3 -3
  466. package/dist/safe-bash-presentation-engine/xml.js +3 -3
  467. package/dist/safe-bash-query-engine/index.js +4 -4
  468. package/dist/safe-bash-query-engine/interpreter.js +2 -2
  469. package/dist/safe-bash-query-engine/query-core.js +4 -4
  470. package/dist/safe-bash-xml-engine/document.js +3 -3
  471. package/dist/safe-bash-xml-engine/evaluate.js +1 -1
  472. package/dist/safe-bash-xml-engine/index.js +6 -6
  473. package/dist/safe-bash-xml-engine/query.js +2 -2
  474. package/dist/safe-bash-xml-engine/stored-document.d.ts +2 -2
  475. package/dist/safe-bash-xml-engine/stored-document.js +1 -1
  476. package/dist/safe-bash-xml-engine/stored-evaluate.js +1 -1
  477. package/dist/safe-bash-zip-engine/zip/repair.js +3 -3
  478. package/dist/safe-bash-zip-engine/zip/volumes.js +3 -3
  479. package/dist/spreadsheet-engine/datasource.js +16 -2
  480. package/dist/spreadsheet-engine/formulas/diagnostics.d.ts +2 -1
  481. package/dist/spreadsheet-engine/formulas/diagnostics.js +2 -2
  482. package/dist/spreadsheet-engine/formulas/evaluator.d.ts +1 -1
  483. package/dist/spreadsheet-engine/formulas/evaluator.js +2 -1
  484. package/dist/spreadsheet-format-xls/biff-encrypted-properties.js +7 -6
  485. package/dist/spreadsheet-format-xls/biff-properties-merge.js +2 -2
  486. package/dist/spreadsheet-format-xls/biff-properties.js +94 -109
  487. package/dist/spreadsheet-format-xls/biff-property-dictionary.d.ts +5 -0
  488. package/dist/spreadsheet-format-xls/biff-property-dictionary.js +75 -0
  489. package/dist/spreadsheet-format-xls/biff-property-range.d.ts +17 -3
  490. package/dist/spreadsheet-format-xls/biff-property-range.js +178 -37
  491. package/package.json +4 -2
  492. package/dist/safe-bash/command-chunks/biff-4ALVARRF-7SRX6R6N.js +0 -5192
  493. package/dist/safe-bash/command-chunks/{chunk-X2HVVMTW.js → chunk-AW4Q3GZW.js} +6 -6
  494. package/dist/safe-bash/command-chunks/{chunk-JC2EV66U.js → chunk-BJXADHRT.js} +3 -3
  495. package/dist/safe-bash/command-chunks/{chunk-XI2LETBJ.js → chunk-BXU5Y7I5.js} +3 -3
  496. package/dist/safe-bash/command-chunks/{chunk-PVLPWVRH.js → chunk-D3HW7R2N.js} +3 -3
  497. package/dist/safe-bash/command-chunks/{chunk-OLK3DCJD.js → chunk-DYERIXPU.js} +3 -3
  498. package/dist/safe-bash/command-chunks/{chunk-WYBCSJFG.js → chunk-FWCUEZ3K.js} +3 -3
  499. package/dist/safe-bash/command-chunks/{chunk-FF2SQ2GP.js → chunk-GGH376XQ.js} +3 -3
  500. package/dist/safe-bash/command-chunks/{chunk-D66Q7QJ3.js → chunk-JRSZ5IGD.js} +6 -6
  501. package/dist/safe-bash/command-chunks/{chunk-3JST2Q7G.js → chunk-KRRG4MGH.js} +3 -3
  502. package/dist/safe-bash/command-chunks/{chunk-Z3YB4EVE.js → chunk-KSM5CCHT.js} +8 -8
  503. package/dist/safe-bash/command-chunks/{chunk-NJ4NTTCR.js → chunk-LNLACEAN.js} +8 -8
  504. package/dist/safe-bash/command-chunks/{chunk-NBTG6NF6.js → chunk-LTJRUMK6.js} +3 -3
  505. package/dist/safe-bash/command-chunks/{chunk-XCYTG7CR.js → chunk-NJGL5JQ6.js} +3 -3
  506. package/dist/safe-bash/command-chunks/{chunk-SZ66JC25.js → chunk-Q7J2NTH2.js} +3 -3
  507. package/dist/safe-bash/command-chunks/{chunk-MDV7W5AS.js → chunk-SKNI2XQA.js} +3 -3
  508. package/dist/safe-bash/command-chunks/{chunk-7ZWACKCG.js → chunk-T6OXG7QQ.js} +3 -3
  509. package/dist/safe-bash/command-chunks/{chunk-ECDEPKKW.js → chunk-W25EIKDJ.js} +3 -3
  510. package/dist/safe-bash/command-chunks/{chunk-4YSBUQPV.js → chunk-W2FKFEVY.js} +3 -3
  511. package/dist/safe-bash/command-chunks/{chunk-2CIDPOUV.js → chunk-WSNHJZQ5.js} +3 -3
  512. package/dist/safe-bash/command-chunks/{chunk-4H3TYOVC.js → chunk-Y7AXMCFV.js} +3 -3
  513. package/dist/safe-bash/command-chunks/{chunk-U6IEK2CI.js → chunk-YPG55QTP.js} +7 -7
  514. package/dist/safe-bash/command-chunks/{chunk-252L5YC5.js → chunk-Z37OM247.js} +6 -6
  515. package/dist/safe-bash/command-chunks/{pln-DFS7VLVS-JATX6FS7.js → pln-DFS7VLVS-OVOBS4QX.js} +3 -3
  516. package/dist/safe-bash/command-chunks/{psion-YBI6JEQI-6OMC2PGC.js → psion-YBI6JEQI-GY4S6ZLC.js} +3 -3
@@ -1,6 +1,7 @@
1
+ import { visitBiffPropertyDictionary } from './biff-property-dictionary.js';
1
2
  import { SsconvertError } from "../spreadsheet-engine/contracts.js";
2
3
  import { invalidBiff } from "./biff-binary.js";
3
- import { propertyRange, readPropertySectionRanges, readPropertyValueRanges } from "./biff-property-range.js";
4
+ import { propertyRange, readPropertySectionRanges, withPropertyValueRanges } from "./biff-property-range.js";
4
5
  import { readBiffPropertyText } from "./biff-property-text.js";
5
6
  // OLE property-set layout and IDs: LibreOffice oleprops.cxx/.hxx at
6
7
  // bce0998afefdbc355585ca324285661a2170ba77; source receipts are in the gap ledger.
@@ -43,125 +44,109 @@ export async function readBiffProperties(streams, context, accountText, accountW
43
44
  continue;
44
45
  const file = propertyRange(bytes, context);
45
46
  accountWork(file.size);
46
- const sections = await readPropertySectionRanges(file, admit, accountWork);
47
+ const sections = readPropertySectionRanges(file, admit, accountWork, context);
47
48
  let unknown = false;
48
49
  const modeled = [];
49
- for (const { guid, offset, end } of sections) {
50
+ for await (const { guid, offset, end } of sections) {
50
51
  if (!biffPropertyFields.has(guid) && guid !== custom) {
51
52
  unknown = true;
52
53
  continue;
53
54
  }
54
- const values = await readPropertyValueRanges(file.slice(offset, end - offset), admit, accountWork);
55
- const cp = values.get(1);
56
- let codepage = 1252;
57
- if (cp) {
58
- if ((await cp.u32(0)) !== 2)
59
- invalidBiff("invalid property codepage type");
60
- codepage = await cp.u16(4);
61
- }
62
- const names = new Map(), dictionary = values.get(0);
63
- try {
64
- if (dictionary && guid === custom) {
65
- const length = await dictionary.u32(0);
66
- dictionary.check(4, length * 9);
67
- admit(length);
68
- let at = 4;
69
- for (let i = 0; i < length; i++) {
70
- const id = await dictionary.u32(at), entry = await readBiffPropertyText(dictionary, at + 4, codepage, context, accountText, accountWork);
71
- if (id < 2 || names.has(id) || !entry.value)
72
- invalidBiff("invalid property dictionary entry");
73
- names.set(id, entry.value);
74
- at = entry.end;
75
- }
55
+ await withPropertyValueRanges(file.slice(offset, end - offset), admit, accountWork, context, async (values) => {
56
+ const cp = await values.get(1);
57
+ let codepage = 1252;
58
+ if (cp) {
59
+ if ((await cp.u32(0)) !== 2)
60
+ invalidBiff("invalid property codepage type");
61
+ codepage = await cp.u16(4);
76
62
  }
77
- }
78
- catch (error) {
79
- if (!(error instanceof SsconvertError) || error.code !== "unsupported-feature")
80
- throw error;
81
- unknown = true;
82
- continue;
83
- }
84
- for (const [id, data] of values) {
85
- context.signal.throwIfAborted();
86
- if (id < 2)
87
- continue;
88
- const key = guid === custom ? names.get(id) : biffPropertyFields.get(guid)?.get(id);
89
- if (key === undefined || Object.hasOwn(properties, key)) {
90
- unknown = true;
91
- continue;
92
- }
93
- let value;
94
- const type = await data.u32(0);
95
- try {
96
- if (type === 30 || type === 31)
97
- value = (await readBiffPropertyText(data, 4, type === 31 ? 1200 : codepage, context, accountText, accountWork)).value;
98
- else if (type === 3)
99
- value = (await data.u32(4)) | 0;
100
- else if (type === 5) {
101
- value = await data.f64(4);
102
- if (!Number.isFinite(value))
103
- invalidBiff("nonfinite property value");
104
- }
105
- else if (type === 11)
106
- value = (await data.u16(4)) !== 0;
107
- else if (type === 64) {
108
- const ticks = BigInt(await data.u32(4)) + (BigInt(await data.u32(8)) << 32n);
109
- if (guid === summary && id === 10) {
110
- const fraction = (ticks % 10000000n).toString().padStart(7, "0");
111
- let end = fraction.length;
112
- while (end && fraction[end - 1] === "0")
113
- end--;
114
- value = `PT${ticks / 600000000n}M${ticks / 10000000n % 60n}${end ? "." + fraction.slice(0, end) : ""}S`;
63
+ const dictionary = guid === custom ? await values.get(0) : undefined;
64
+ const supported = await visitBiffPropertyDictionary(dictionary, codepage, context, admit, accountText, accountWork, async (getName) => {
65
+ for await (const [id, data] of values.entries()) {
66
+ context.signal.throwIfAborted();
67
+ if (id < 2)
68
+ continue;
69
+ const key = guid === custom ? await getName(id) : biffPropertyFields.get(guid)?.get(id);
70
+ if (key === undefined || Object.hasOwn(properties, key)) {
71
+ unknown = true;
72
+ continue;
115
73
  }
116
- else {
117
- value = new Date(Number(ticks / 10000n) - 11644473600000).toISOString();
118
- // The workbook model stores timestamps as strings; retain the
119
- // original property bytes when Date's millisecond precision loses ticks.
120
- if (ticks % 10000n)
121
- unknown = true;
74
+ let value;
75
+ const type = await data.u32(0);
76
+ try {
77
+ if (type === 30 || type === 31)
78
+ value = (await readBiffPropertyText(data, 4, type === 31 ? 1200 : codepage, context, accountText, accountWork)).value;
79
+ else if (type === 3)
80
+ value = (await data.u32(4)) | 0;
81
+ else if (type === 5) {
82
+ value = await data.f64(4);
83
+ if (!Number.isFinite(value))
84
+ invalidBiff("nonfinite property value");
85
+ }
86
+ else if (type === 11)
87
+ value = (await data.u16(4)) !== 0;
88
+ else if (type === 64) {
89
+ const ticks = BigInt(await data.u32(4)) + (BigInt(await data.u32(8)) << 32n);
90
+ if (guid === summary && id === 10) {
91
+ const fraction = (ticks % 10000000n).toString().padStart(7, "0");
92
+ let end = fraction.length;
93
+ while (end && fraction[end - 1] === "0")
94
+ end--;
95
+ value = `PT${ticks / 600000000n}M${ticks / 10000000n % 60n}${end ? "." + fraction.slice(0, end) : ""}S`;
96
+ }
97
+ else {
98
+ value = new Date(Number(ticks / 10000n) - 11644473600000).toISOString();
99
+ // The workbook model stores timestamps as strings; retain the
100
+ // original property bytes when Date's millisecond precision loses ticks.
101
+ if (ticks % 10000n)
102
+ unknown = true;
103
+ }
104
+ accountText(value);
105
+ }
106
+ else if (type === 7) {
107
+ const days = await data.f64(4);
108
+ if (!Number.isFinite(days) || days <= -657435 || days >= 2958466)
109
+ invalidBiff("invalid OLE property date");
110
+ // OLE Automation uses 1899-12-30 and the absolute fractional day.
111
+ // LibreOffice's oleprops DATE path truncates it and uses 1899-12-31;
112
+ // the documented Automation representation governs the stored value.
113
+ value = new Date(-2209161600000 + Math.round((Math.trunc(days) + Math.abs(days % 1)) * 86400000)).toISOString();
114
+ accountText(value);
115
+ }
122
116
  }
123
- accountText(value);
124
- }
125
- else if (type === 7) {
126
- const days = await data.f64(4);
127
- if (!Number.isFinite(days) || days <= -657435 || days >= 2958466)
128
- invalidBiff("invalid OLE property date");
129
- // OLE Automation uses 1899-12-30 and the absolute fractional day.
130
- // LibreOffice's oleprops DATE path truncates it and uses 1899-12-31;
131
- // the documented Automation representation governs the stored value.
132
- value = new Date(-2209161600000 + Math.round((Math.trunc(days) + Math.abs(days % 1)) * 86400000)).toISOString();
133
- accountText(value);
117
+ catch (error) {
118
+ if (!(error instanceof SsconvertError) || error.code !== "unsupported-feature")
119
+ throw error;
120
+ }
121
+ if (value === undefined) {
122
+ unknown = true;
123
+ continue;
124
+ }
125
+ if (guid === summary && id === 5 && typeof value === "string") {
126
+ let count = 1;
127
+ for (const character of value)
128
+ if (character === ",")
129
+ count++;
130
+ admit(count);
131
+ accountWork(value.length);
132
+ value = value.split(",").map(keyword => {
133
+ let start = 0, end = keyword.length;
134
+ while (start < end && isBiffKeywordSpace(keyword.charCodeAt(start)))
135
+ start++;
136
+ while (end > start && isBiffKeywordSpace(keyword.charCodeAt(end - 1)))
137
+ end--;
138
+ return keyword.slice(start, end);
139
+ }).filter(Boolean);
140
+ }
141
+ accountText(key);
142
+ properties[key] = value;
143
+ modeled.push([offset, id, key]);
144
+ observe?.({ stream: streamName, section: offset, id, key, value });
134
145
  }
135
- }
136
- catch (error) {
137
- if (!(error instanceof SsconvertError) || error.code !== "unsupported-feature")
138
- throw error;
139
- }
140
- if (value === undefined) {
146
+ });
147
+ if (!supported)
141
148
  unknown = true;
142
- continue;
143
- }
144
- if (guid === summary && id === 5 && typeof value === "string") {
145
- let count = 1;
146
- for (const character of value)
147
- if (character === ",")
148
- count++;
149
- admit(count);
150
- accountWork(value.length);
151
- value = value.split(",").map(keyword => {
152
- let start = 0, end = keyword.length;
153
- while (start < end && isBiffKeywordSpace(keyword.charCodeAt(start)))
154
- start++;
155
- while (end > start && isBiffKeywordSpace(keyword.charCodeAt(end - 1)))
156
- end--;
157
- return keyword.slice(start, end);
158
- }).filter(Boolean);
159
- }
160
- accountText(key);
161
- properties[key] = value;
162
- modeled.push([offset, id, key]);
163
- observe?.({ stream: streamName, section: offset, id, key, value });
164
- }
149
+ });
165
150
  }
166
151
  if (unknown && retained) {
167
152
  if (file.size * 2 > (context.limits.workbookTextBytes ?? context.limits.inputBytes * 2))
@@ -0,0 +1,5 @@
1
+ import { type CapabilityContext } from "../spreadsheet-engine/contracts.js";
2
+ import { type BiffPropertyRange } from './biff-property-range.js';
3
+ /** Validate/account names once, retain only coordinates, and decode on lookup.
4
+ * Unsupported dictionary codepages skip the visitor so the caller retains the section. */
5
+ export declare function visitBiffPropertyDictionary(data: BiffPropertyRange | undefined, codepage: number, context: CapabilityContext, admit: (count: number) => void, accountText: (text: string) => string, accountWork: (amount: number) => void, visit: (get: (id: number) => Promise<string | undefined>) => Promise<void>): Promise<boolean>;
@@ -0,0 +1,75 @@
1
+ import { IntegerTable } from "@poe-platform/safe-fs/storage";
2
+ import { SsconvertError } from "../spreadsheet-engine/contracts.js";
3
+ import { invalidBiff } from './biff-binary.js';
4
+ import { propertyIndexStorage } from './biff-property-range.js';
5
+ import { readBiffPropertyText } from './biff-property-text.js';
6
+ /** Validate/account names once, retain only coordinates, and decode on lookup.
7
+ * Unsupported dictionary codepages skip the visitor so the caller retains the section. */
8
+ export async function visitBiffPropertyDictionary(data, codepage, context, admit, accountText, accountWork, visit) {
9
+ const count = data ? await data.u32(0) : 0;
10
+ if (data) {
11
+ data.check(4, count * 9);
12
+ admit(count);
13
+ }
14
+ const storage = data && context.createWorkingStorage?.();
15
+ let active = true, supported = true;
16
+ const check = () => {
17
+ context.signal.throwIfAborted();
18
+ data?.check(0, 0);
19
+ if (!active)
20
+ throw new SsconvertError('invalid-request', 'BIFF property dictionary index is closed');
21
+ };
22
+ try {
23
+ const backing = storage && propertyIndexStorage(storage, data);
24
+ backing?.allocate(8);
25
+ const index = backing ? new IntegerTable(backing, 64) : new Map();
26
+ let at = 4;
27
+ for (let i = 0; i < count; i++) {
28
+ const id = await data.u32(at);
29
+ let entry;
30
+ try {
31
+ entry = await readBiffPropertyText(data, at + 4, codepage, context, accountText, accountWork);
32
+ }
33
+ catch (error) {
34
+ if (!(error instanceof SsconvertError) || error.code !== 'unsupported-feature')
35
+ throw error;
36
+ supported = false;
37
+ break;
38
+ }
39
+ if (id < 2 || await index.get(BigInt(id)) !== undefined || !entry.value)
40
+ invalidBiff('invalid property dictionary entry');
41
+ check();
42
+ await index.set(BigInt(id), BigInt(at + 4));
43
+ check();
44
+ at = entry.end;
45
+ }
46
+ if (supported)
47
+ await visit(async (id) => {
48
+ check();
49
+ const position = await index.get(BigInt(id));
50
+ check();
51
+ if (position === undefined)
52
+ return undefined;
53
+ const entry = await readBiffPropertyText(data, Number(position), codepage, context, text => text, accountWork);
54
+ check();
55
+ return entry.value;
56
+ });
57
+ check();
58
+ }
59
+ catch (error) {
60
+ try {
61
+ await storage?.close();
62
+ }
63
+ catch (cleanup) {
64
+ throw new AggregateError([error, cleanup], 'BIFF property dictionary and cleanup failed');
65
+ }
66
+ throw error;
67
+ }
68
+ finally {
69
+ active = false;
70
+ }
71
+ await storage?.close();
72
+ context.signal.throwIfAborted();
73
+ data?.check(0, 0);
74
+ return supported;
75
+ }
@@ -1,4 +1,4 @@
1
- import { type CapabilityContext, type RangeSource } from "../spreadsheet-engine/contracts.js";
1
+ import { type CapabilityContext, type RangeSource, type WorkingStorage } from "../spreadsheet-engine/contracts.js";
2
2
  import type { BiffPropertySection } from './biff-properties-layout.js';
3
3
  interface Root {
4
4
  read: RangeSource['read'];
@@ -20,6 +20,20 @@ export declare class BiffPropertyRange implements RangeSource {
20
20
  f64(at: number): Promise<number>;
21
21
  }
22
22
  export declare function propertyRange(input: Uint8Array | RangeSource, context: CapabilityContext): BiffPropertyRange;
23
- export declare function readPropertySectionRanges(file: BiffPropertyRange, admit: (count: number) => void, accountWork: (amount: number) => void): Promise<BiffPropertySection[]>;
24
- export declare function readPropertyValueRanges(section: BiffPropertyRange, admit: (count: number) => void, accountWork: (amount: number) => void): Promise<Map<number, BiffPropertyRange>>;
23
+ /** Index IO checks disposal around awaits and owns transient write buffers. */
24
+ export declare function propertyIndexStorage(storage: WorkingStorage, range: BiffPropertyRange): {
25
+ allocate(length: number): number;
26
+ read(at: number, length: number): Promise<Uint8Array<ArrayBufferLike>>;
27
+ write(at: number, bytes: Uint8Array): Promise<void>;
28
+ };
29
+ /** Validate all section intervals before replaying any descriptor. */
30
+ export declare function readPropertySectionRanges(file: BiffPropertyRange, admit: (count: number) => void, accountWork: (amount: number) => void, context: CapabilityContext): AsyncGenerator<BiffPropertySection>;
31
+ export interface BiffPropertyValues {
32
+ get(id: number): Promise<BiffPropertyRange | undefined>;
33
+ entries(): AsyncIterable<readonly [number, BiffPropertyRange]>;
34
+ }
35
+ /** The visitor owns the index lifetime; returned range views own only source coordinates. */
36
+ export declare function withPropertyValueRanges<T>(section: BiffPropertyRange, admit: (count: number) => void, accountWork: (amount: number) => void, context: CapabilityContext, visit: (values: BiffPropertyValues) => Promise<T>): Promise<T>;
37
+ /** Mutable convenience materialization for retained property merge edits. */
38
+ export declare function readPropertyValueRanges(section: BiffPropertyRange, admit: (count: number) => void, accountWork: (amount: number) => void, context: CapabilityContext): Promise<Map<number, BiffPropertyRange>>;
25
39
  export {};
@@ -1,3 +1,4 @@
1
+ import { IntegerTable } from "@poe-platform/safe-fs/storage";
1
2
  import { SsconvertError } from "../spreadsheet-engine/contracts.js";
2
3
  import { Binary, invalidBiff } from './biff-binary.js';
3
4
  /** Property subviews retain coordinates; even scalar reads own their borrowed input. */
@@ -75,7 +76,31 @@ export function propertyRange(input, context) {
75
76
  root.check();
76
77
  return new BiffPropertyRange(root, 0, size);
77
78
  }
78
- export async function readPropertySectionRanges(file, admit, accountWork) {
79
+ /** Index IO checks disposal around awaits and owns transient write buffers. */
80
+ export function propertyIndexStorage(storage, range) {
81
+ return {
82
+ allocate(length) { range.check(0, 0); return storage.allocate(length); },
83
+ async read(at, length) {
84
+ range.check(0, 0);
85
+ const bytes = await storage.read(at, length);
86
+ range.check(0, 0);
87
+ return bytes;
88
+ },
89
+ async write(at, bytes) {
90
+ range.check(0, 0);
91
+ const owned = new Uint8Array(bytes);
92
+ try {
93
+ await storage.write(at, owned);
94
+ range.check(0, 0);
95
+ }
96
+ finally {
97
+ owned.fill(0);
98
+ }
99
+ }
100
+ };
101
+ }
102
+ /** Validate all section intervals before replaying any descriptor. */
103
+ export async function* readPropertySectionRanges(file, admit, accountWork, context) {
79
104
  file.check(0, 28);
80
105
  const header = new Binary(await file.read(0, 28));
81
106
  if (header.u16(0) !== 0xfffe || header.u16(2) > 1)
@@ -83,47 +108,163 @@ export async function readPropertySectionRanges(file, admit, accountWork) {
83
108
  const count = header.u32(24), tableEnd = 28 + count * 20;
84
109
  file.check(28, count * 20);
85
110
  admit(count);
86
- const sections = [];
87
- for (let i = 0; i < count; i++) {
88
- const entry = new Binary(await file.read(28 + i * 20, 20)), offset = entry.u32(16);
89
- if (offset < tableEnd || offset % 4)
90
- invalidBiff('invalid property section offset');
91
- const size = await file.u32(offset);
92
- if (size < 8)
93
- invalidBiff('invalid property section size');
94
- file.check(offset, size);
95
- const guid = Array.from(entry.slice(0, 16), byte => byte.toString(16).padStart(2, '0')).join('');
96
- sections.push({ guid, offset, end: offset + size });
97
- }
98
111
  accountWork(count * Math.ceil(Math.log2(count + 1)));
99
- sections.sort((a, b) => a.offset - b.offset);
100
- for (let i = 1; i < sections.length; i++)
101
- if (sections[i].offset < sections[i - 1].end)
102
- invalidBiff('overlapping property sections');
103
- return sections;
112
+ const storage = context.createWorkingStorage?.();
113
+ let failed = false;
114
+ try {
115
+ const backing = storage && propertyIndexStorage(storage, file);
116
+ backing?.allocate(8);
117
+ const offsets = backing ? new IntegerTable(backing, 64) : new Map();
118
+ const records = backing ? undefined : new Map();
119
+ for (let i = 0; i < count; i++) {
120
+ const bytes = await file.read(28 + i * 20, 20), offset = new Binary(bytes).u32(16);
121
+ if (offset < tableEnd || offset % 4)
122
+ invalidBiff('invalid property section offset');
123
+ const size = await file.u32(offset);
124
+ if (size < 8)
125
+ invalidBiff('invalid property section size');
126
+ file.check(offset, size);
127
+ const record = new Uint8Array(24);
128
+ record.set(bytes);
129
+ new DataView(record.buffer).setUint32(20, size, true);
130
+ const position = backing ? backing.allocate(record.length) : i;
131
+ if (backing) {
132
+ try {
133
+ await backing.write(position, record);
134
+ }
135
+ finally {
136
+ record.fill(0);
137
+ }
138
+ }
139
+ else
140
+ records.set(position, record);
141
+ await offsets.set(BigInt(offset) << 32n | BigInt(i), BigInt(position));
142
+ file.check(0, 0);
143
+ }
144
+ const entries = async function* () {
145
+ const ordered = offsets instanceof Map ? [...offsets].sort(([a], [b]) => a < b ? -1 : a > b ? 1 : 0) : offsets.entries();
146
+ for await (const [, position] of ordered) {
147
+ file.check(0, 0);
148
+ const bytes = new Binary(backing ? await backing.read(Number(position), 24) : records.get(Number(position)));
149
+ bytes.check(0, 24);
150
+ const offset = bytes.u32(16), end = offset + bytes.u32(20);
151
+ const guid = Array.from(bytes.slice(0, 16), byte => byte.toString(16).padStart(2, '0')).join('');
152
+ yield { guid, offset, end };
153
+ }
154
+ };
155
+ let end = 0;
156
+ for await (const section of entries()) {
157
+ if (section.offset < end)
158
+ invalidBiff('overlapping property sections');
159
+ end = section.end;
160
+ }
161
+ yield* entries();
162
+ }
163
+ catch (error) {
164
+ failed = true;
165
+ try {
166
+ await storage?.close();
167
+ }
168
+ catch (cleanup) {
169
+ throw new AggregateError([error, cleanup], 'BIFF property section index and cleanup failed');
170
+ }
171
+ throw error;
172
+ }
173
+ finally {
174
+ if (!failed)
175
+ await storage?.close();
176
+ }
104
177
  }
105
- export async function readPropertyValueRanges(section, admit, accountWork) {
178
+ /** The visitor owns the index lifetime; returned range views own only source coordinates. */
179
+ export async function withPropertyValueRanges(section, admit, accountWork, context, visit) {
106
180
  const count = await section.u32(4);
107
181
  section.check(8, count * 8);
108
182
  admit(count);
109
- const pointers = [], ids = new Set();
110
- for (let i = 0; i < count; i++) {
111
- const entry = new Binary(await section.read(8 + i * 8, 8)), id = entry.u32(0), at = entry.u32(4);
112
- if (at < 8 + count * 8 || at > section.size - 4)
113
- invalidBiff('invalid property offset');
114
- if (ids.has(id))
115
- invalidBiff('duplicate property ID');
116
- ids.add(id);
117
- pointers.push({ id, at });
118
- }
119
183
  accountWork(count * Math.ceil(Math.log2(count + 1)));
120
- pointers.sort((a, b) => a.at - b.at);
121
- const values = new Map();
122
- for (let i = 0; i < count; i++) {
123
- const { id, at } = pointers[i], next = pointers[i + 1]?.at ?? section.size;
124
- if (next === at)
125
- invalidBiff('overlapping property values');
126
- values.set(id, section.slice(at, next - at));
184
+ const storage = context.createWorkingStorage?.();
185
+ let active = true, result;
186
+ const check = () => {
187
+ section.check(0, 0);
188
+ if (!active)
189
+ throw new SsconvertError('invalid-request', 'BIFF property value index is closed');
190
+ };
191
+ try {
192
+ const backing = storage && propertyIndexStorage(storage, section);
193
+ backing?.allocate(8);
194
+ const ids = backing ? new IntegerTable(backing, 64) : new Map();
195
+ const offsets = backing ? new IntegerTable(backing, 64) : new Map();
196
+ for (let i = 0; i < count; i++) {
197
+ const entry = new Binary(await section.read(8 + i * 8, 8)), id = BigInt(entry.u32(0)), at = entry.u32(4);
198
+ if (at < 8 + count * 8 || at > section.size - 4)
199
+ invalidBiff('invalid property offset');
200
+ if (await ids.get(id) !== undefined)
201
+ invalidBiff('duplicate property ID');
202
+ check();
203
+ await ids.set(id, BigInt(at));
204
+ check();
205
+ if (await offsets.get(BigInt(at)) !== undefined)
206
+ invalidBiff('overlapping property values');
207
+ check();
208
+ await offsets.set(BigInt(at), id);
209
+ check();
210
+ }
211
+ const ordered = (start = 0n) => offsets instanceof Map ? [...offsets].filter(([at]) => at >= start).sort(([a], [b]) => Number(a - b)) : offsets.entries(start);
212
+ result = await visit({
213
+ async get(id) {
214
+ check();
215
+ const at = await ids.get(BigInt(id));
216
+ check();
217
+ if (at === undefined)
218
+ return undefined;
219
+ let end = section.size;
220
+ for await (const [next] of ordered(at + 1n)) {
221
+ check();
222
+ end = Number(next);
223
+ break;
224
+ }
225
+ check();
226
+ return section.slice(Number(at), end - Number(at));
227
+ },
228
+ async *entries() {
229
+ check();
230
+ let previous;
231
+ for await (const [offset, id] of ordered()) {
232
+ check();
233
+ const at = Number(offset);
234
+ if (previous)
235
+ yield [previous.id, section.slice(previous.at, at - previous.at)];
236
+ previous = { id: Number(id), at };
237
+ }
238
+ check();
239
+ if (previous)
240
+ yield [previous.id, section.slice(previous.at, section.size - previous.at)];
241
+ check();
242
+ }
243
+ });
244
+ check();
127
245
  }
128
- return values;
246
+ catch (error) {
247
+ try {
248
+ await storage?.close();
249
+ }
250
+ catch (cleanup) {
251
+ throw new AggregateError([error, cleanup], 'BIFF property index and cleanup failed');
252
+ }
253
+ throw error;
254
+ }
255
+ finally {
256
+ active = false;
257
+ }
258
+ await storage?.close();
259
+ section.check(0, 0);
260
+ return result;
261
+ }
262
+ /** Mutable convenience materialization for retained property merge edits. */
263
+ export async function readPropertyValueRanges(section, admit, accountWork, context) {
264
+ return withPropertyValueRanges(section, admit, accountWork, context, async (source) => {
265
+ const values = new Map();
266
+ for await (const [id, value] of source.entries())
267
+ values.set(id, value);
268
+ return values;
269
+ });
129
270
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@poe-platform/safe-bash",
3
- "version": "0.1.813",
3
+ "version": "0.1.814",
4
4
  "description": "Extensible virtual shell with pluggable filesystems and streaming commands",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -1407,7 +1407,7 @@
1407
1407
  "access": "public"
1408
1408
  },
1409
1409
  "dependencies": {
1410
- "@poe-platform/safe-fs": "0.1.813",
1410
+ "@poe-platform/safe-fs": "0.1.814",
1411
1411
  "pdf-lib": "1.17.1",
1412
1412
  "@types/node": "^25.2.2",
1413
1413
  "@formatjs/intl-numberformat": "9.4.0",
@@ -1719,6 +1719,7 @@
1719
1719
  "./dist/safe-bash-command-html-to-markdown/options.js",
1720
1720
  "./dist/safe-bash-command-html-to-markdown/parser.js",
1721
1721
  "./dist/safe-bash-command-html-to-markdown/render.js",
1722
+ "./dist/safe-bash-command-html-to-markdown/stored-text.js",
1722
1723
  "./dist/safe-bash-command-html-to-markdown/text.js",
1723
1724
  "./dist/safe-bash-command-htmlq/index.js",
1724
1725
  "./dist/safe-bash-command-iconv/codec.js",
@@ -2838,6 +2839,7 @@
2838
2839
  "./dist/spreadsheet-format-xls/biff-properties-write.js",
2839
2840
  "./dist/spreadsheet-format-xls/biff-properties.js",
2840
2841
  "./dist/spreadsheet-format-xls/biff-property-bytes.js",
2842
+ "./dist/spreadsheet-format-xls/biff-property-dictionary.js",
2841
2843
  "./dist/spreadsheet-format-xls/biff-property-index.js",
2842
2844
  "./dist/spreadsheet-format-xls/biff-property-name.js",
2843
2845
  "./dist/spreadsheet-format-xls/biff-property-range.js",