@univer-cli/content-execution 1.2.0 → 1.3.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.
Files changed (2) hide show
  1. package/dist/index.mjs +1 -1
  2. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -1 +1 @@
1
- const _0x4a05a5=_0x3c7d;(function(_0x45c8d8,_0x2c7078){const _0x2a5ea0=_0x3c7d,_0x1a7c93=_0x45c8d8();while(!![]){try{const _0x1e1d94=parseInt(_0x2a5ea0(0x12b))/0x1*(-parseInt(_0x2a5ea0(0x137))/0x2)+-parseInt(_0x2a5ea0(0x13a))/0x3+-parseInt(_0x2a5ea0(0x11e))/0x4+parseInt(_0x2a5ea0(0x122))/0x5+parseInt(_0x2a5ea0(0x13f))/0x6*(-parseInt(_0x2a5ea0(0x140))/0x7)+parseInt(_0x2a5ea0(0x121))/0x8*(parseInt(_0x2a5ea0(0x127))/0x9)+parseInt(_0x2a5ea0(0x141))/0xa*(parseInt(_0x2a5ea0(0x13e))/0xb);if(_0x1e1d94===_0x2c7078)break;else _0x1a7c93['push'](_0x1a7c93['shift']());}catch(_0x5c27fe){_0x1a7c93['push'](_0x1a7c93['shift']());}}}(_0x2fae,0x4e6bb));var e=class extends Error{[_0x4a05a5(0x143)];[_0x4a05a5(0x14a)];constructor(_0x2d43c8,_0x1c2252,_0x249bbc){const _0x48cc79=_0x4a05a5;super(_0x1c2252),this[_0x48cc79(0x143)]=_0x2d43c8,this['details']=_0x249bbc,this[_0x48cc79(0x148)]=_0x48cc79(0x132);}},t=[_0x4a05a5(0x146),_0x4a05a5(0x133),_0x4a05a5(0x14c),_0x4a05a5(0x125),_0x4a05a5(0x12a)];function n(_0x36c448){const _0x5e7c87=_0x4a05a5;if(typeof _0x36c448[_0x5e7c87(0x143)]!=_0x5e7c87(0x138))throw new e('CONTENT_EXECUTION_INVALID_INPUT',_0x5e7c87(0x139));if(typeof _0x36c448['unitId']!=_0x5e7c87(0x138)||_0x36c448[_0x5e7c87(0x11d)][_0x5e7c87(0x13d)]()[_0x5e7c87(0x144)]===0x0)throw new e(_0x5e7c87(0x150),_0x5e7c87(0x14e),{'unitId':_0x36c448['unitId']});if(!c(_0x36c448[_0x5e7c87(0x11f)]))throw new e(_0x5e7c87(0x131),_0x5e7c87(0x14f)+String(_0x36c448[_0x5e7c87(0x11f)]),{'supportedUnitTypes':t,'unitType':_0x36c448['unitType']});let _0x1b4f88=i(_0x36c448['unitType']);return o(_0x36c448[_0x5e7c87(0x143)],_0x36c448['unitType'],_0x1b4f88),r(_0x36c448[_0x5e7c87(0x11f)],_0x36c448['unitId'])+'\x0a'+_0x36c448[_0x5e7c87(0x143)];}function r(_0x217207,_0x2a9da3){const _0x3df4d6=_0x4a05a5;let _0x1a8385=JSON[_0x3df4d6(0x12e)](_0x2a9da3);return _0x217207==='sheet'?[_0x3df4d6(0x11c),_0x3df4d6(0x145)+_0x1a8385+');','if\x20(!workbook)\x20throw\x20new\x20Error('+JSON[_0x3df4d6(0x12e)](_0x3df4d6(0x14b)+_0x2a9da3)+');']['join']('\x0a'):_0x217207==='doc'?[_0x3df4d6(0x11c),_0x3df4d6(0x12f)+_0x1a8385+');',_0x3df4d6(0x130)+JSON['stringify']('Cannot\x20find\x20doc\x20'+_0x2a9da3)+');']['join']('\x0a'):_0x217207===_0x3df4d6(0x14c)?[_0x3df4d6(0x11c),_0x3df4d6(0x142)+_0x1a8385+');','if\x20(!presentation)\x20throw\x20new\x20Error('+JSON['stringify'](_0x3df4d6(0x134)+_0x2a9da3)+');'][_0x3df4d6(0x123)]('\x0a'):_0x217207===_0x3df4d6(0x125)?[_0x3df4d6(0x11c),_0x3df4d6(0x147)+_0x1a8385+');',_0x3df4d6(0x129)+JSON[_0x3df4d6(0x12e)](_0x3df4d6(0x12c)+_0x2a9da3)+');']['join']('\x0a'):_0x217207==='board'?[_0x3df4d6(0x11c),_0x3df4d6(0x128)+_0x1a8385+');','if\x20(!board)\x20throw\x20new\x20Error('+JSON[_0x3df4d6(0x12e)]('Cannot\x20find\x20board\x20'+_0x2a9da3)+');']['join']('\x0a'):a(_0x217207);}function i(_0x1c166f){const _0x2d3248=_0x4a05a5;return _0x1c166f===_0x2d3248(0x146)?['univerAPI',_0x2d3248(0x135),_0x2d3248(0x14d)]:_0x1c166f===_0x2d3248(0x133)?[_0x2d3248(0x13c),_0x2d3248(0x135),'doc']:_0x1c166f===_0x2d3248(0x14c)?[_0x2d3248(0x13c),_0x2d3248(0x135),'presentation']:_0x1c166f==='base'?['univerAPI',_0x2d3248(0x135),'base']:_0x1c166f===_0x2d3248(0x12a)?[_0x2d3248(0x13c),_0x2d3248(0x135),_0x2d3248(0x12a)]:a(_0x1c166f);}function a(_0x1d1281){const _0x2505f4=_0x4a05a5;throw Error(_0x2505f4(0x149)+String(_0x1d1281));}function o(_0x4d20e1,_0x1dd526,_0x22cdc4){const _0x47a01e=_0x4a05a5;if(s(_0x4d20e1)){for(let _0x42f7f7 of _0x22cdc4)if(!s(_0x47a01e(0x124)+_0x42f7f7+_0x47a01e(0x12d)+_0x4d20e1))throw new e(_0x47a01e(0x126),'`'+_0x42f7f7+'`\x20is\x20reserved\x20by\x20the\x20'+_0x1dd526+'\x20content\x20execution\x20prelude',{'binding':_0x42f7f7,'reservedBindings':_0x22cdc4,'unitType':_0x1dd526});}}function s(_0x19e4d6){const _0x5c78ae=_0x4a05a5;try{return Function(_0x5c78ae(0x13c),_0x5c78ae(0x13b)+_0x19e4d6+_0x5c78ae(0x120)),!0x0;}catch{return!0x1;}}function c(_0xe573ef){const _0x2834d2=_0x4a05a5;return t[_0x2834d2(0x136)](_0x333ef2=>_0x333ef2===_0xe573ef);}function _0x3c7d(_0x3310cf,_0xb9b0fc){_0x3310cf=_0x3310cf-0x11c;const _0x2faede=_0x2fae();let _0x3c7d11=_0x2faede[_0x3310cf];return _0x3c7d11;}export{e as ContentExecutionError,n as prepareContentExecutionProgram};function _0x2fae(){const _0x1b2ef3=['const\x20','base','CONTENT_EXECUTION_RESERVED_BINDING','27rEjFDe','const\x20board\x20=\x20api.getBoard(','if\x20(!base)\x20throw\x20new\x20Error(','board','1063fPhfmA','Cannot\x20find\x20base\x20','\x20=\x20undefined;\x0a','stringify','const\x20doc\x20=\x20api.getDocument(','if\x20(!doc)\x20throw\x20new\x20Error(','CONTENT_EXECUTION_UNIT_TYPE_UNSUPPORTED','ContentExecutionError','doc','Cannot\x20find\x20presentation\x20','api','some','326CpRmdA','string','Content\x20execution\x20code\x20must\x20be\x20a\x20string','1663416qmfubA','return\x20(async\x20()\x20=>\x20{\x20','univerAPI','trim','6639611avDQxu','637446bYUxWr','14WnTsWh','10nwbtpt','const\x20presentation\x20=\x20api.getPresentation(','code','length','const\x20workbook\x20=\x20api.getWorkbook(','sheet','const\x20base\x20=\x20api.getBase(','name','Unexpected\x20content\x20execution\x20Unit\x20type:\x20','details','Cannot\x20find\x20workbook\x20','slide','workbook','Content\x20execution\x20Unit\x20ID\x20must\x20not\x20be\x20empty','Content\x20execution\x20does\x20not\x20support\x20Unit\x20type\x20','CONTENT_EXECUTION_INVALID_INPUT','const\x20api\x20=\x20univerAPI;','unitId','390120iPAwel','unitType','\x0a})();','465032cMcGpg','2904880loEKJY','join'];_0x2fae=function(){return _0x1b2ef3;};return _0x2fae();}
1
+ const _0x579d9f=_0x21e0;(function(_0x59e898,_0x54bd29){const _0x2dac0c=_0x21e0,_0x5224f8=_0x59e898();while(!![]){try{const _0x23c76d=parseInt(_0x2dac0c(0x1ef))/0x1+-parseInt(_0x2dac0c(0x205))/0x2*(parseInt(_0x2dac0c(0x1fd))/0x3)+-parseInt(_0x2dac0c(0x210))/0x4+parseInt(_0x2dac0c(0x1f6))/0x5*(-parseInt(_0x2dac0c(0x1f5))/0x6)+parseInt(_0x2dac0c(0x1e5))/0x7*(parseInt(_0x2dac0c(0x1e9))/0x8)+-parseInt(_0x2dac0c(0x200))/0x9+parseInt(_0x2dac0c(0x1f3))/0xa;if(_0x23c76d===_0x54bd29)break;else _0x5224f8['push'](_0x5224f8['shift']());}catch(_0x376303){_0x5224f8['push'](_0x5224f8['shift']());}}}(_0x5d5f,0xd24e8));var e=class extends Error{[_0x579d9f(0x1f7)];[_0x579d9f(0x20d)];constructor(_0x3a676d,_0x7f3213,_0x26eb6a){const _0x4922cf=_0x579d9f;super(_0x7f3213),this['code']=_0x3a676d,this[_0x4922cf(0x20d)]=_0x26eb6a,this[_0x4922cf(0x1e8)]='ContentExecutionError';}},t=[_0x579d9f(0x1ee),_0x579d9f(0x1f1),_0x579d9f(0x20b),_0x579d9f(0x1e1),_0x579d9f(0x20f)];function n(_0x3f3b00){const _0x446667=_0x579d9f;if(typeof _0x3f3b00['code']!=_0x446667(0x1e2))throw new e(_0x446667(0x1f8),_0x446667(0x201));if(typeof _0x3f3b00[_0x446667(0x1f0)]!='string'||_0x3f3b00[_0x446667(0x1f0)]['trim']()[_0x446667(0x1fc)]===0x0)throw new e('CONTENT_EXECUTION_INVALID_INPUT',_0x446667(0x1f4),{'unitId':_0x3f3b00[_0x446667(0x1f0)]});if(!c(_0x3f3b00['unitType']))throw new e('CONTENT_EXECUTION_UNIT_TYPE_UNSUPPORTED','Content\x20execution\x20does\x20not\x20support\x20Unit\x20type\x20'+String(_0x3f3b00[_0x446667(0x1ed)]),{'supportedUnitTypes':t,'unitType':_0x3f3b00[_0x446667(0x1ed)]});let _0x6f1005=i(_0x3f3b00[_0x446667(0x1ed)]);return o(_0x3f3b00[_0x446667(0x1f7)],_0x3f3b00[_0x446667(0x1ed)],_0x6f1005),r(_0x3f3b00['unitType'],_0x3f3b00[_0x446667(0x1f0)])+'\x0a'+_0x3f3b00[_0x446667(0x1f7)];}function _0x21e0(_0x71bc91,_0x2a62cc){_0x71bc91=_0x71bc91-0x1e1;const _0x5d5f7d=_0x5d5f();let _0x21e0c8=_0x5d5f7d[_0x71bc91];return _0x21e0c8;}function r(_0x2ff64c,_0x17c6a3){const _0x20defa=_0x579d9f;let _0x19134b=JSON[_0x20defa(0x206)](_0x17c6a3);return _0x2ff64c===_0x20defa(0x1ee)?[_0x20defa(0x1e7),'const\x20workbook\x20=\x20api.getWorkbook('+_0x19134b+');','if\x20(!workbook)\x20throw\x20new\x20Error('+JSON['stringify'](_0x20defa(0x209)+_0x17c6a3)+');'][_0x20defa(0x1fe)]('\x0a'):_0x2ff64c===_0x20defa(0x1f1)?[_0x20defa(0x1e7),_0x20defa(0x1e3)+_0x19134b+');',_0x20defa(0x1ea)+JSON[_0x20defa(0x206)](_0x20defa(0x1fa)+_0x17c6a3)+');'][_0x20defa(0x1fe)]('\x0a'):_0x2ff64c===_0x20defa(0x20b)?[_0x20defa(0x1e7),'const\x20presentation\x20=\x20api.getPresentation('+_0x19134b+');',_0x20defa(0x20a)+JSON[_0x20defa(0x206)]('Cannot\x20find\x20presentation\x20'+_0x17c6a3)+');'][_0x20defa(0x1fe)]('\x0a'):_0x2ff64c===_0x20defa(0x1e1)?[_0x20defa(0x1e7),_0x20defa(0x20c)+_0x19134b+');',_0x20defa(0x1e6)+JSON[_0x20defa(0x206)]('Cannot\x20find\x20base\x20'+_0x17c6a3)+');']['join']('\x0a'):_0x2ff64c===_0x20defa(0x20f)?[_0x20defa(0x1e7),_0x20defa(0x1e4)+_0x19134b+');',_0x20defa(0x202)+JSON[_0x20defa(0x206)](_0x20defa(0x208)+_0x17c6a3)+');'][_0x20defa(0x1fe)]('\x0a'):a(_0x2ff64c);}function i(_0x2dfab2){const _0x309afd=_0x579d9f;return _0x2dfab2===_0x309afd(0x1ee)?[_0x309afd(0x20e),'api','workbook']:_0x2dfab2===_0x309afd(0x1f1)?['univerAPI',_0x309afd(0x1ff),_0x309afd(0x1f1)]:_0x2dfab2===_0x309afd(0x20b)?[_0x309afd(0x20e),_0x309afd(0x1ff),_0x309afd(0x203)]:_0x2dfab2===_0x309afd(0x1e1)?[_0x309afd(0x20e),_0x309afd(0x1ff),_0x309afd(0x1e1)]:_0x2dfab2===_0x309afd(0x20f)?[_0x309afd(0x20e),_0x309afd(0x1ff),'board']:a(_0x2dfab2);}function a(_0x78f90a){const _0x1b4244=_0x579d9f;throw Error(_0x1b4244(0x207)+String(_0x78f90a));}function o(_0x492112,_0x3f4c5f,_0x506d85){const _0x4cb7a8=_0x579d9f;if(s(_0x492112)){for(let _0x488e4f of _0x506d85)if(!s(_0x4cb7a8(0x1ec)+_0x488e4f+_0x4cb7a8(0x1f2)+_0x492112))throw new e(_0x4cb7a8(0x1f9),'`'+_0x488e4f+_0x4cb7a8(0x1eb)+_0x3f4c5f+_0x4cb7a8(0x204),{'binding':_0x488e4f,'reservedBindings':_0x506d85,'unitType':_0x3f4c5f});}}function s(_0x408774){const _0x160899=_0x579d9f;try{return Function('univerAPI','return\x20(async\x20()\x20=>\x20{\x20'+_0x408774+_0x160899(0x1fb)),!0x0;}catch{return!0x1;}}function c(_0x18cd75){return t['some'](_0x3bc427=>_0x3bc427===_0x18cd75);}function _0x5d5f(){const _0x22bd97=['base','string','const\x20doc\x20=\x20api.getDocument(','const\x20board\x20=\x20api.getBoard(','7kQywJR','if\x20(!base)\x20throw\x20new\x20Error(','const\x20api\x20=\x20univerAPI;','name','11062488ZHQtGo','if\x20(!doc)\x20throw\x20new\x20Error(','`\x20is\x20reserved\x20by\x20the\x20','const\x20','unitType','sheet','269780msPMad','unitId','doc','\x20=\x20undefined;\x0a','26236960xpAjqy','Content\x20execution\x20Unit\x20ID\x20must\x20not\x20be\x20empty','800502BCRdeH','5inlibq','code','CONTENT_EXECUTION_INVALID_INPUT','CONTENT_EXECUTION_RESERVED_BINDING','Cannot\x20find\x20doc\x20','\x0a})();','length','2251227nZspPw','join','api','9719523CoXGwB','Content\x20execution\x20code\x20must\x20be\x20a\x20string','if\x20(!board)\x20throw\x20new\x20Error(','presentation','\x20content\x20execution\x20prelude','2RpaLxh','stringify','Unexpected\x20content\x20execution\x20Unit\x20type:\x20','Cannot\x20find\x20board\x20','Cannot\x20find\x20workbook\x20','if\x20(!presentation)\x20throw\x20new\x20Error(','slide','const\x20base\x20=\x20api.getBase(','details','univerAPI','board','5804392XVsPRd'];_0x5d5f=function(){return _0x22bd97;};return _0x5d5f();}export{e as ContentExecutionError,n as prepareContentExecutionProgram};
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@univer-cli/content-execution",
3
3
  "type": "module",
4
- "version": "1.2.0",
4
+ "version": "1.3.1",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.mjs",
7
7
  "types": "./dist/index.d.ts",