@univer-cli/unit-pdf-printer 1.0.1 → 1.0.2
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/dist/index.mjs +1 -1
- package/package.json +2 -2
package/dist/index.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
const
|
|
1
|
+
const _0x47b7c9=_0x1b2f;(function(_0x96b605,_0x20184a){const _0x443a19=_0x1b2f,_0x2a38f7=_0x96b605();while(!![]){try{const _0x329747=parseInt(_0x443a19(0xaf))/0x1*(parseInt(_0x443a19(0xa5))/0x2)+parseInt(_0x443a19(0xb3))/0x3+-parseInt(_0x443a19(0xa7))/0x4*(parseInt(_0x443a19(0xb7))/0x5)+-parseInt(_0x443a19(0xb5))/0x6*(-parseInt(_0x443a19(0xab))/0x7)+-parseInt(_0x443a19(0xba))/0x8+-parseInt(_0x443a19(0xac))/0x9*(parseInt(_0x443a19(0x99))/0xa)+parseInt(_0x443a19(0xa8))/0xb;if(_0x329747===_0x20184a)break;else _0x2a38f7['push'](_0x2a38f7['shift']());}catch(_0x747f46){_0x2a38f7['push'](_0x2a38f7['shift']());}}}(_0x1502,0xefb38));function _0x1502(){const _0x251fcb=['13358360YGRgZv','unit','code','160iQjNzL','maxPages\x20must\x20be\x20a\x20positive\x20integer','subarray','fromCharCode','length','application/pdf','name','unitType','operation\x20aborted','isSafeInteger','pageCount','aborted','70jtAQVb','UnitPdfPrinterError','212LMpnPG','16533770jwDvXu','trim','INVALID_INPUT','7asOEHy','653148TAMOtd','\x20pages,\x20over\x20the\x20','%PDF-','16231tipcFV','signal','string','bytes','1990764JADDbT','printPdf','11526546dEOHEf','reason','79535hfXuQF','unitData','runtime'];_0x1502=function(){return _0x251fcb;};return _0x1502();}function _0x1b2f(_0x537c83,_0x5c3b32){_0x537c83=_0x537c83-0x99;const _0x150255=_0x1502();let _0x1b2fab=_0x150255[_0x537c83];return _0x1b2fab;}var e=class extends Error{[_0x47b7c9(0xbc)];constructor(_0x38b712,_0x3f2e83){const _0x3f5eb8=_0x47b7c9;super(_0x3f2e83),this[_0x3f5eb8(0x9f)]=_0x3f5eb8(0xa6),this[_0x3f5eb8(0xbc)]=_0x38b712;}};function t(_0x33bb6a){return _0x33bb6a instanceof e;}var n=0x3e8;function r(_0x16ad74){const _0x30d4a2=_0x47b7c9;let _0x25d233=_0x16ad74['maxPages']??n;if(!Number[_0x30d4a2(0xa2)](_0x25d233)||_0x25d233<0x1)throw new e(_0x30d4a2(0xaa),_0x30d4a2(0x9a));return{async 'print'(_0x683832){const _0x4eb154=_0x30d4a2;c(_0x683832['signal']);let _0x59bdcd=i(_0x683832[_0x4eb154(0xb8)]),_0x2534df=await _0x16ad74[_0x4eb154(0xb9)][_0x4eb154(0xb4)](_0x683832);if(c(_0x683832[_0x4eb154(0xb0)]),_0x2534df['pageCount']>_0x25d233)throw new e(_0x4eb154(0xaa),'print\x20produced\x20'+_0x2534df[_0x4eb154(0xa3)]+_0x4eb154(0xad)+_0x25d233+'\x20page\x20limit');if(!s(_0x2534df[_0x4eb154(0xb2)]))throw new e(_0x4eb154(0xaa),'render\x20runtime\x20returned\x20invalid\x20PDF\x20bytes');return{'bytes':_0x2534df[_0x4eb154(0xb2)],'mediaType':_0x4eb154(0x9e),'name':o(a(_0x683832['unitData'])??_0x59bdcd)+'.pdf','pageCount':_0x2534df[_0x4eb154(0xa3)],'unitId':_0x59bdcd,'unitType':_0x683832[_0x4eb154(0xa0)]};}};}function i(_0x1bcc41){const _0x2488f7=_0x47b7c9;if(typeof _0x1bcc41['id']!=_0x2488f7(0xb1)||_0x1bcc41['id'][_0x2488f7(0x9d)]===0x0)throw new e('INVALID_INPUT','unitData.id\x20is\x20required');return _0x1bcc41['id'];}function a(_0x120030){const _0x41c4b9=_0x47b7c9;let _0x2ad0b1=_0x120030['name'];return typeof _0x2ad0b1==_0x41c4b9(0xb1)&&_0x2ad0b1[_0x41c4b9(0xa9)]()[_0x41c4b9(0x9d)]>0x0?_0x2ad0b1[_0x41c4b9(0xa9)]():void 0x0;}function o(_0x55e917){const _0x4d5972=_0x47b7c9;let _0xbe2a=_0x55e917['replaceAll'](/[\\/:*?"<>|]/gu,'-')[_0x4d5972(0xa9)]();return _0xbe2a[_0x4d5972(0x9d)]>0x0?_0xbe2a:_0x4d5972(0xbb);}function s(_0x31c507){const _0x6d6908=_0x47b7c9;return _0x31c507[_0x6d6908(0x9d)]>=0x5&&String[_0x6d6908(0x9c)](..._0x31c507[_0x6d6908(0x9b)](0x0,0x5))===_0x6d6908(0xae);}function c(_0xd132eb){const _0x4bba86=_0x47b7c9;if(_0xd132eb?.[_0x4bba86(0xa4)]===!0x0)throw _0xd132eb[_0x4bba86(0xb6)]instanceof Error?_0xd132eb[_0x4bba86(0xb6)]:Error(_0x4bba86(0xa1));}export{e as UnitPdfPrinterError,r as createUnitPdfPrinter,t as isUnitPdfPrinterError};
|
package/package.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "@univer-cli/unit-pdf-printer",
|
|
3
3
|
"description": "Print materialized Univer Units to PDF through the browser render runtime.",
|
|
4
4
|
"type": "module",
|
|
5
|
-
"version": "1.0.
|
|
5
|
+
"version": "1.0.2",
|
|
6
6
|
"main": "./dist/index.cjs",
|
|
7
7
|
"module": "./dist/index.mjs",
|
|
8
8
|
"types": "./dist/index.d.ts",
|
|
@@ -19,6 +19,6 @@
|
|
|
19
19
|
"README.zh-CN.md"
|
|
20
20
|
],
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@univer-cli/univer-render-runtime": "1.0.
|
|
22
|
+
"@univer-cli/univer-render-runtime": "1.0.2"
|
|
23
23
|
}
|
|
24
24
|
}
|