revise 2.0.0 → 2.0.1
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.
- package/CHANGELOG.md +27 -0
- package/assets/{historyMaterializeWorker-CoAX9ZAi.js → historyMaterializeWorker-C4uxcZEh.js} +1 -1
- package/backend.d.ts +22 -0
- package/backend.js +1 -1
- package/chunks/AgentPageRenderer-BIf_Fza8.js +1 -0
- package/chunks/AgentPageRenderer-DT9sNxEn.js +1 -0
- package/chunks/{AttachmentDocumentImporter-dNMtkxrv.js → AttachmentDocumentImporter-BUavYRxO.js} +1 -1
- package/chunks/{AttachmentDocumentImporter-DSic_6At.js → AttachmentDocumentImporter-DGwfDJSH.js} +1 -1
- package/chunks/{BidiText-B4Hzrjg9.js → BidiText-D7LYTAUL.js} +1 -1
- package/chunks/DocumentMutator-CjN7Kk-X.js +31 -0
- package/chunks/DocumentScrubber-C9ZZEcYW.js +1 -0
- package/chunks/DocumentScrubber-DrgzBlx4.js +1 -0
- package/chunks/DocumentScrubber-W0EfGmL-.js +1 -0
- package/chunks/{DocxConverter-COV6CjUM.js → DocxConverter-Be3uPNcD.js} +3 -3
- package/chunks/{DocxConverter-B7P52lw7.js → DocxConverter-CGYMfz-j.js} +6 -6
- package/chunks/{DocxConverter-Cq_zCEJC.js → DocxConverter-DabDLfsu.js} +6 -6
- package/chunks/{DocxGraft-CJ12C9WP.js → DocxGraft-B6W7fbh4.js} +1 -1
- package/chunks/{DocxGraft-DcmFuUkd.js → DocxGraft-Cj7v78BO.js} +1 -1
- package/chunks/DocxGraft-Duvo2cpy.js +1 -0
- package/chunks/FileImporter-CjUX2S4s.js +1 -0
- package/chunks/FileImporter-DtkbI6rF.js +1 -0
- package/chunks/{HtmlConverter-JvRlkQM3.js → HtmlConverter-ikXImzTY.js} +1 -1
- package/chunks/{MarkdownConverter-B-tPY7X3.js → MarkdownConverter-CFrcLyO_.js} +2 -2
- package/chunks/{OdtConverter-DYHnR4E8.js → OdtConverter-BFT_P8SI.js} +1 -1
- package/chunks/OdtConverter-Cnda9T0q.js +1 -0
- package/chunks/OdtConverter-WdwwXKVM.js +1 -0
- package/chunks/PdfConverter-D7UM58vc.js +21 -0
- package/chunks/PdfConverter-TB-QPw29.js +21 -0
- package/chunks/PdfConverter-wVP63986.js +21 -0
- package/chunks/PdfImportService-Dj1-3L2B.js +2 -0
- package/chunks/PdfImportService-OE9G383I.js +2 -0
- package/chunks/{RtfConverter-oIwzoqCD.js → RtfConverter-D-oqPWNl.js} +5 -5
- package/chunks/{RtfConverter-BQGge3K-.js → RtfConverter-D9zhE07-.js} +5 -5
- package/chunks/{RtfConverter-CMfZ4olw.js → RtfConverter-DZgwU-_R.js} +1 -1
- package/chunks/{TableBorders-BLkZYt1k.js → TableBorders-BorZS8aZ.js} +1 -1
- package/chunks/{TxtConverter-C1lp6dBS.js → TxtConverter-BYazsp6P.js} +3 -3
- package/chunks/ar-C8zx2RwP.js +8 -0
- package/chunks/backend-MFpDFVrD.js +1 -0
- package/chunks/base64-BNMNG-lN.js +1 -0
- package/chunks/{browser-module-6b2Fq-5C.js → browser-module-BbaxnHNK.js} +1 -1
- package/chunks/{browser-module-CkO57IPL.js → browser-module-D2ixluMg.js} +1 -1
- package/chunks/capture-qC26xmfy.js +1 -0
- package/chunks/{carrier-WgcRSu7a.js → carrier-BWONvrA7.js} +1 -1
- package/chunks/de-ByQFqecF.js +8 -0
- package/chunks/es-PHpJXv5S.js +8 -0
- package/chunks/{footnoteFlatten-CW-DUcgK.js → footnoteFlatten-Bdnn_bz1.js} +1 -1
- package/chunks/{graftExport-CVg7PO2A.js → graftExport-CP3h2T88.js} +1 -1
- package/chunks/index-CjeGoI2g.js +351 -0
- package/chunks/index-D7V8zn4w.js +36 -0
- package/chunks/index-DyOcu9mD.js +351 -0
- package/chunks/{index.es-DOqegDGr.js → index.es-B97tjxvW.js} +1 -1
- package/chunks/{index.es-tXDO0RMv.js → index.es-mTU7Sl3w.js} +1 -1
- package/chunks/{jspdf.es.min-CzYti8jo.js → jspdf.es.min-DGiD4mlU.js} +1 -1
- package/chunks/{jspdf.es.min-ejWOGhkJ.js → jspdf.es.min-Mykp4BZO.js} +1 -1
- package/chunks/{pseudoLocale-CdBtPHRi.js → pseudoLocale-C90lXrPg.js} +1 -1
- package/chunks/{pseudoLocale-DEVWLkGC.js → pseudoLocale-UA_TkGrH.js} +1 -1
- package/chunks/serverDocumentSession-CRZSb5SO.js +11 -0
- package/chunks/signatures-CsL_TjvW.js +1 -0
- package/full.js +1 -1
- package/index.d.ts +27 -4
- package/index.js +1 -1
- package/package.json +2 -2
- package/root.js +2 -2
- package/style.css +1 -1
- package/chunks/AgentPageRenderer-C0n4EnuW.js +0 -1
- package/chunks/AgentPageRenderer-DURfmiu0.js +0 -1
- package/chunks/DocxGraft-CQpvFcYb.js +0 -1
- package/chunks/FileImporter-DVnYOJHp.js +0 -1
- package/chunks/FileImporter-q9mCch0J.js +0 -1
- package/chunks/OdtConverter-Br81BSoJ.js +0 -1
- package/chunks/OdtConverter-CQjh0vlo.js +0 -1
- package/chunks/PdfConverter-D26rXumc.js +0 -21
- package/chunks/PdfConverter-DGZpUSVf.js +0 -21
- package/chunks/PdfConverter-DZzVP0-B.js +0 -21
- package/chunks/PdfImportService-CBD8TL1k.js +0 -2
- package/chunks/PdfImportService-D6uUKGMf.js +0 -2
- package/chunks/ar-kgSWdrXF.js +0 -8
- package/chunks/backend-Cq-khfdG.js +0 -1
- package/chunks/base64-CfDUyGi8.js +0 -36
- package/chunks/capture-DU3MC7tb.js +0 -1
- package/chunks/de-C2QTHrqo.js +0 -8
- package/chunks/es-BKboUn4q.js +0 -8
- package/chunks/index-CLw_BlSL.js +0 -353
- package/chunks/index-F-kHIwWT.js +0 -353
- package/chunks/serverDocumentSession-DZrYbdpk.js +0 -42
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{D as p}from"./DocumentMutator-CjN7Kk-X.js";import{d as N}from"./backend-MFpDFVrD.js";const i="Author",h=o=>{const n=[o.children];o.notes&&n.push(o.notes),o.chrome&&n.push(o.chrome);for(const e of[o.headers,o.footers])if(e)for(const c of Object.values(e))Array.isArray(c)&&n.push(c);return n},g=(o,n)=>{n(o);for(const e of o)e&&Array.isArray(e.children)&&g(e.children,n)},l=(o,n)=>{for(const e of h(o))g(e,c=>{for(const a of c)a?.type==="text"&&n(a)})},y=o=>{o.marks&&Object.keys(o.marks).length===0&&delete o.marks},A=o=>{const n=new Set,e=c=>{typeof c=="string"&&c.length>0&&n.add(c)};for(const c of h(o))g(c,a=>{for(const t of a){if(!t||typeof t!="object")continue;e(t.suggestionId),e(t.structuralSuggestionId);for(const s of["structuralSuggestionRecord","structuralSuggestionRecords"]){const u=t[s];if(typeof u=="string")try{const f=JSON.parse(u),m=Array.isArray(f)?f:[f];for(const d of m)e(d?.id)}catch{}}const r=t.marks;if(r&&(e(r.suggestionId),typeof r.layeredInsertion=="string"))try{e(JSON.parse(r.layeredInsertion)?.id)}catch{}}});return n},S=(o,n)=>{const e=N(o);try{const c=p.createSuggestionProjectionFromYDoc(e,n);try{const a=c.doc,t={...o,children:a.children};return a.notes?t.notes=a.notes:delete t.notes,t}finally{c.ydoc.destroy()}}finally{e.destroy()}},k=(o,n)=>{o.author&&o.author!==i&&(n.add(o.author),o.author=i),delete o.initials,delete o.authorId,delete o.authorImageUrl,o.agentName&&(n.add(o.agentName),delete o.agentName)};function v(o,n){let e=structuredClone(o);const c={commentsRemoved:0,suggestionsResolved:0,hiddenRemoved:0,authorsAnonymized:0,corePropsCleared:!1};if(n.resolveSuggestions){const a=A(e);a.size>0&&(e=S(e,n.resolveSuggestions),c.suggestionsResolved=a.size)}if(n.removeComments){const a=new Set((e.comments??[]).map(t=>t.id));l(e,t=>{if(t.marks?.comment){for(const r of t.marks.comment.split(","))r&&a.add(r);delete t.marks.comment,y(t)}}),delete e.comments,c.commentsRemoved=a.size}if(n.removeHiddenText)for(const a of h(e))g(a,t=>{const r=[];for(const s of t){if(s?.type==="text"&&s.marks?.hidden){c.hiddenRemoved+=1,s.marks.footnoteRef&&(delete s.marks.hidden,y(s),r.push(s));continue}r.push(s)}r.length!==t.length&&(t.length=0,t.push(...r))});if(n.anonymizeAuthors){const a=new Set;l(e,t=>{const r=t.marks;if(r){if(r.suggestionAuthorName&&r.suggestionAuthorName!==i&&(a.add(r.suggestionAuthorName),r.suggestionAuthorName=i),typeof r.layeredInsertion=="string")try{const s=JSON.parse(r.layeredInsertion);s&&typeof s=="object"&&s.authorName&&s.authorName!==i&&(a.add(s.authorName),s.authorName=i,r.layeredInsertion=JSON.stringify(s))}catch{}if(typeof r.docxMove=="string")try{const s=JSON.parse(r.docxMove);s&&typeof s=="object"&&s.rangeAuthor&&s.rangeAuthor!==i&&(a.add(s.rangeAuthor),s.rangeAuthor=i,r.docxMove=JSON.stringify(s))}catch{}}});for(const t of h(e))g(t,r=>{for(const s of r)for(const u of["structuralSuggestionRecord","structuralSuggestionRecords"])if(typeof s?.[u]=="string")try{const f=JSON.parse(s[u]),m=Array.isArray(f)?f:[f];for(const d of m)d&&typeof d=="object"&&typeof d.agentName=="string"&&d.agentName.length>0&&d.agentName!==i&&(a.add(d.agentName),d.agentName=i);s[u]=JSON.stringify(Array.isArray(f)?m:m[0])}catch{}});for(const t of e.comments??[])k(t,a);if(e.coreProperties)for(const t of["creator","lastModifiedBy"]){const r=e.coreProperties[t];r&&r!==i&&(a.add(r),e.coreProperties[t]=i)}c.authorsAnonymized=a.size}return n.clearCoreProperties&&(e.coreProperties&&Object.keys(e.coreProperties).length>0&&(c.corePropsCleared=!0),delete e.coreProperties),{doc:e,summary:c}}export{i as SCRUBBED_AUTHOR_NAME,v as scrubDocument};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{y as p,z as N}from"./index-CjeGoI2g.js";const i="Author",h=o=>{const n=[o.children];o.notes&&n.push(o.notes),o.chrome&&n.push(o.chrome);for(const e of[o.headers,o.footers])if(e)for(const c of Object.values(e))Array.isArray(c)&&n.push(c);return n},g=(o,n)=>{n(o);for(const e of o)e&&Array.isArray(e.children)&&g(e.children,n)},y=(o,n)=>{for(const e of h(o))g(e,c=>{for(const a of c)a?.type==="text"&&n(a)})},l=o=>{o.marks&&Object.keys(o.marks).length===0&&delete o.marks},A=o=>{const n=new Set,e=c=>{typeof c=="string"&&c.length>0&&n.add(c)};for(const c of h(o))g(c,a=>{for(const t of a){if(!t||typeof t!="object")continue;e(t.suggestionId),e(t.structuralSuggestionId);for(const s of["structuralSuggestionRecord","structuralSuggestionRecords"]){const u=t[s];if(typeof u=="string")try{const f=JSON.parse(u),m=Array.isArray(f)?f:[f];for(const d of m)e(d?.id)}catch{}}const r=t.marks;if(r&&(e(r.suggestionId),typeof r.layeredInsertion=="string"))try{e(JSON.parse(r.layeredInsertion)?.id)}catch{}}});return n},S=(o,n)=>{const e=p(o);try{const c=N.createSuggestionProjectionFromYDoc(e,n);try{const a=c.doc,t={...o,children:a.children};return a.notes?t.notes=a.notes:delete t.notes,t}finally{c.ydoc.destroy()}}finally{e.destroy()}},k=(o,n)=>{o.author&&o.author!==i&&(n.add(o.author),o.author=i),delete o.initials,delete o.authorId,delete o.authorImageUrl,o.agentName&&(n.add(o.agentName),delete o.agentName)};function v(o,n){let e=structuredClone(o);const c={commentsRemoved:0,suggestionsResolved:0,hiddenRemoved:0,authorsAnonymized:0,corePropsCleared:!1};if(n.resolveSuggestions){const a=A(e);a.size>0&&(e=S(e,n.resolveSuggestions),c.suggestionsResolved=a.size)}if(n.removeComments){const a=new Set((e.comments??[]).map(t=>t.id));y(e,t=>{if(t.marks?.comment){for(const r of t.marks.comment.split(","))r&&a.add(r);delete t.marks.comment,l(t)}}),delete e.comments,c.commentsRemoved=a.size}if(n.removeHiddenText)for(const a of h(e))g(a,t=>{const r=[];for(const s of t){if(s?.type==="text"&&s.marks?.hidden){c.hiddenRemoved+=1,s.marks.footnoteRef&&(delete s.marks.hidden,l(s),r.push(s));continue}r.push(s)}r.length!==t.length&&(t.length=0,t.push(...r))});if(n.anonymizeAuthors){const a=new Set;y(e,t=>{const r=t.marks;if(r){if(r.suggestionAuthorName&&r.suggestionAuthorName!==i&&(a.add(r.suggestionAuthorName),r.suggestionAuthorName=i),typeof r.layeredInsertion=="string")try{const s=JSON.parse(r.layeredInsertion);s&&typeof s=="object"&&s.authorName&&s.authorName!==i&&(a.add(s.authorName),s.authorName=i,r.layeredInsertion=JSON.stringify(s))}catch{}if(typeof r.docxMove=="string")try{const s=JSON.parse(r.docxMove);s&&typeof s=="object"&&s.rangeAuthor&&s.rangeAuthor!==i&&(a.add(s.rangeAuthor),s.rangeAuthor=i,r.docxMove=JSON.stringify(s))}catch{}}});for(const t of h(e))g(t,r=>{for(const s of r)for(const u of["structuralSuggestionRecord","structuralSuggestionRecords"])if(typeof s?.[u]=="string")try{const f=JSON.parse(s[u]),m=Array.isArray(f)?f:[f];for(const d of m)d&&typeof d=="object"&&typeof d.agentName=="string"&&d.agentName.length>0&&d.agentName!==i&&(a.add(d.agentName),d.agentName=i);s[u]=JSON.stringify(Array.isArray(f)?m:m[0])}catch{}});for(const t of e.comments??[])k(t,a);if(e.coreProperties)for(const t of["creator","lastModifiedBy"]){const r=e.coreProperties[t];r&&r!==i&&(a.add(r),e.coreProperties[t]=i)}c.authorsAnonymized=a.size}return n.clearCoreProperties&&(e.coreProperties&&Object.keys(e.coreProperties).length>0&&(c.corePropsCleared=!0),delete e.coreProperties),{doc:e,summary:c}}export{i as SCRUBBED_AUTHOR_NAME,v as scrubDocument};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{y as p,z as N}from"./index-DyOcu9mD.js";const i="Author",h=o=>{const n=[o.children];o.notes&&n.push(o.notes),o.chrome&&n.push(o.chrome);for(const e of[o.headers,o.footers])if(e)for(const c of Object.values(e))Array.isArray(c)&&n.push(c);return n},g=(o,n)=>{n(o);for(const e of o)e&&Array.isArray(e.children)&&g(e.children,n)},y=(o,n)=>{for(const e of h(o))g(e,c=>{for(const a of c)a?.type==="text"&&n(a)})},l=o=>{o.marks&&Object.keys(o.marks).length===0&&delete o.marks},A=o=>{const n=new Set,e=c=>{typeof c=="string"&&c.length>0&&n.add(c)};for(const c of h(o))g(c,a=>{for(const t of a){if(!t||typeof t!="object")continue;e(t.suggestionId),e(t.structuralSuggestionId);for(const s of["structuralSuggestionRecord","structuralSuggestionRecords"]){const u=t[s];if(typeof u=="string")try{const f=JSON.parse(u),m=Array.isArray(f)?f:[f];for(const d of m)e(d?.id)}catch{}}const r=t.marks;if(r&&(e(r.suggestionId),typeof r.layeredInsertion=="string"))try{e(JSON.parse(r.layeredInsertion)?.id)}catch{}}});return n},S=(o,n)=>{const e=p(o);try{const c=N.createSuggestionProjectionFromYDoc(e,n);try{const a=c.doc,t={...o,children:a.children};return a.notes?t.notes=a.notes:delete t.notes,t}finally{c.ydoc.destroy()}}finally{e.destroy()}},k=(o,n)=>{o.author&&o.author!==i&&(n.add(o.author),o.author=i),delete o.initials,delete o.authorId,delete o.authorImageUrl,o.agentName&&(n.add(o.agentName),delete o.agentName)};function v(o,n){let e=structuredClone(o);const c={commentsRemoved:0,suggestionsResolved:0,hiddenRemoved:0,authorsAnonymized:0,corePropsCleared:!1};if(n.resolveSuggestions){const a=A(e);a.size>0&&(e=S(e,n.resolveSuggestions),c.suggestionsResolved=a.size)}if(n.removeComments){const a=new Set((e.comments??[]).map(t=>t.id));y(e,t=>{if(t.marks?.comment){for(const r of t.marks.comment.split(","))r&&a.add(r);delete t.marks.comment,l(t)}}),delete e.comments,c.commentsRemoved=a.size}if(n.removeHiddenText)for(const a of h(e))g(a,t=>{const r=[];for(const s of t){if(s?.type==="text"&&s.marks?.hidden){c.hiddenRemoved+=1,s.marks.footnoteRef&&(delete s.marks.hidden,l(s),r.push(s));continue}r.push(s)}r.length!==t.length&&(t.length=0,t.push(...r))});if(n.anonymizeAuthors){const a=new Set;y(e,t=>{const r=t.marks;if(r){if(r.suggestionAuthorName&&r.suggestionAuthorName!==i&&(a.add(r.suggestionAuthorName),r.suggestionAuthorName=i),typeof r.layeredInsertion=="string")try{const s=JSON.parse(r.layeredInsertion);s&&typeof s=="object"&&s.authorName&&s.authorName!==i&&(a.add(s.authorName),s.authorName=i,r.layeredInsertion=JSON.stringify(s))}catch{}if(typeof r.docxMove=="string")try{const s=JSON.parse(r.docxMove);s&&typeof s=="object"&&s.rangeAuthor&&s.rangeAuthor!==i&&(a.add(s.rangeAuthor),s.rangeAuthor=i,r.docxMove=JSON.stringify(s))}catch{}}});for(const t of h(e))g(t,r=>{for(const s of r)for(const u of["structuralSuggestionRecord","structuralSuggestionRecords"])if(typeof s?.[u]=="string")try{const f=JSON.parse(s[u]),m=Array.isArray(f)?f:[f];for(const d of m)d&&typeof d=="object"&&typeof d.agentName=="string"&&d.agentName.length>0&&d.agentName!==i&&(a.add(d.agentName),d.agentName=i);s[u]=JSON.stringify(Array.isArray(f)?m:m[0])}catch{}});for(const t of e.comments??[])k(t,a);if(e.coreProperties)for(const t of["creator","lastModifiedBy"]){const r=e.coreProperties[t];r&&r!==i&&(a.add(r),e.coreProperties[t]=i)}c.authorsAnonymized=a.size}return n.clearCoreProperties&&(e.coreProperties&&Object.keys(e.coreProperties).length>0&&(c.corePropsCleared=!0),delete e.coreProperties),{doc:e,summary:c}}export{i as SCRUBBED_AUTHOR_NAME,v as scrubDocument};
|