@univer-cli/doc-typst-facade-command 1.0.0 → 1.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.
Files changed (2) hide show
  1. package/dist/index.mjs +1 -1
  2. package/package.json +2 -2
package/dist/index.mjs CHANGED
@@ -1 +1 @@
1
- (function(_0xf9f7f5,_0x33c675){const _0x3618a0=_0x5f15,_0x1e34e4=_0xf9f7f5();while(!![]){try{const _0x1a1659=parseInt(_0x3618a0(0xd9))/0x1+-parseInt(_0x3618a0(0xfa))/0x2*(-parseInt(_0x3618a0(0xea))/0x3)+parseInt(_0x3618a0(0xdd))/0x4+-parseInt(_0x3618a0(0xe5))/0x5*(parseInt(_0x3618a0(0xef))/0x6)+parseInt(_0x3618a0(0xfc))/0x7*(-parseInt(_0x3618a0(0xed))/0x8)+-parseInt(_0x3618a0(0xf6))/0x9+parseInt(_0x3618a0(0xe3))/0xa;if(_0x1a1659===_0x33c675)break;else _0x1e34e4['push'](_0x1e34e4['shift']());}catch(_0x266d38){_0x1e34e4['push'](_0x1e34e4['shift']());}}}(_0x27bd,0x5aba3));import{mkdir as _0xe69c95,writeFile as _0x327faf}from'node:fs/promises';import{dirname as _0x430dbd,resolve as _0x4b45eb}from'node:path';import{compileDocTypstBundle as _0x7071fc,isDocTypstFacadeError as _0x309112}from'@univer-cli/doc-typst-facade';function _0x5f15(_0x490198,_0x2ae322){_0x490198=_0x490198-0xd4;const _0x27bd50=_0x27bd();let _0x5f154d=_0x27bd50[_0x490198];return _0x5f154d;}import{Command as _0x1e0f08}from'commander';function s(_0x42e95b={}){const _0x52cb8c=_0x5f15;let _0x327965=_0x42e95b['compile']??_0x7071fc,_0x422352=new _0x1e0f08(_0x52cb8c(0xfd))['description'](_0x52cb8c(0xf2))[_0x52cb8c(0xf1)](_0x52cb8c(0xf0),_0x52cb8c(0xf4))[_0x52cb8c(0xe9)](_0x52cb8c(0xdc),'write\x20the\x20generated\x20JavaScript\x20program')['option'](_0x52cb8c(0xec),_0x52cb8c(0xfb))[_0x52cb8c(0xe8)](_0x52cb8c(0xeb),_0x52cb8c(0xd8))[_0x52cb8c(0xe8)](_0x52cb8c(0xe7),_0x52cb8c(0xd5))[_0x52cb8c(0xe1)](async(_0x599520,_0x2f3d1a)=>{const _0x202db6=_0x52cb8c;try{let _0x48126c=_0x2f3d1a[_0x202db6(0xdf)]===void 0x0?{}:{'previewDir':_0x2f3d1a[_0x202db6(0xdf)]},_0x5ad126=await _0x327965(_0x599520,_0x48126c),_0x1750da=_0x4b45eb(_0x2f3d1a['out']);await _0xe69c95(_0x430dbd(_0x1750da),{'recursive':!0x0}),await _0x327faf(_0x1750da,_0x5ad126[_0x202db6(0xda)],_0x202db6(0xd4));let _0x27fcd2;_0x2f3d1a['diagnosticsOut']!==void 0x0&&(_0x27fcd2=_0x4b45eb(_0x2f3d1a[_0x202db6(0xee)]),await _0xe69c95(_0x430dbd(_0x27fcd2),{'recursive':!0x0}),await _0x327faf(_0x27fcd2,JSON[_0x202db6(0xf8)]({'schemaVersion':0x1,'diagnostics':_0x5ad126[_0x202db6(0xe6)]},null,0x2)+'\x0a',_0x202db6(0xd4)));let _0xcae6b9={'targetUnitId':_0x5ad126[_0x202db6(0xde)],'title':_0x5ad126['title'],'javascriptPath':_0x1750da,..._0x27fcd2===void 0x0?{}:{'diagnosticsPath':_0x27fcd2},'diagnostics':_0x5ad126[_0x202db6(0xe6)],'previews':_0x5ad126[_0x202db6(0xf7)]};_0x422352[_0x202db6(0xf3)]()['writeOut']?.(_0x2f3d1a['json']===!0x0?JSON[_0x202db6(0xf8)](_0xcae6b9,null,0x2)+'\x0a':_0x202db6(0xf9)+_0x5ad126[_0x202db6(0xde)]+_0x202db6(0xe0)+_0x1750da+'\x20('+String(_0x5ad126[_0x202db6(0xe6)][_0x202db6(0xd6)])+_0x202db6(0xe4));}catch(_0x488732){throw(_0x309112(_0x488732)||c(_0x488732))&&_0x422352[_0x202db6(0xe2)](_0x488732[_0x202db6(0xf5)]+':\x20'+_0x488732[_0x202db6(0xd7)],{'code':_0x202db6(0xdb),'exitCode':0x1}),_0x488732;}});return _0x422352;}function _0x27bd(){const _0x2170f9=['315820Tkfnjw','targetUnitId','previewDir','\x20to\x20','action','error','7177390RqANVy','\x20diagnostics)\x0a','3397840uzOghQ','diagnostics','--json','option','requiredOption','21807hGnNYK','--preview-dir\x20<directory>','--diagnostics-out\x20<file>','296CGBEwg','diagnosticsOut','6Esyyrm','<bundle>','argument','Compile\x20a\x20Typst\x20bundle\x20to\x20a\x20target-neutral\x20Univer\x20Facade\x20program','configureOutput','bundle\x20directory\x20or\x20typst.json\x20path','code','2744010RHZbPf','previews','stringify','Compiled\x20','50guZSlZ','write\x20structured\x20diagnostics\x20as\x20JSON','1351cfefmJ','compile-typst','utf8','write\x20the\x20structured\x20compile\x20result\x20as\x20JSON','length','message','render\x20PNG\x20previews\x20into\x20this\x20directory','384799rNSnMZ','javascript','compile-typst.failed','--out\x20<file>'];_0x27bd=function(){return _0x2170f9;};return _0x27bd();}function c(_0x40db67){const _0x758ff6=_0x5f15;return _0x40db67 instanceof Error&&typeof _0x40db67[_0x758ff6(0xf5)]=='string';}export{s as createCompileTypstCommand};
1
+ (function(_0x17dfd5,_0x20307b){const _0x3d69b1=_0x19a0,_0x3458e4=_0x17dfd5();while(!![]){try{const _0x24e6b1=-parseInt(_0x3d69b1(0xe2))/0x1*(parseInt(_0x3d69b1(0xd3))/0x2)+-parseInt(_0x3d69b1(0xec))/0x3+parseInt(_0x3d69b1(0xeb))/0x4+parseInt(_0x3d69b1(0xfc))/0x5+-parseInt(_0x3d69b1(0xf0))/0x6*(-parseInt(_0x3d69b1(0xf1))/0x7)+parseInt(_0x3d69b1(0xe1))/0x8*(-parseInt(_0x3d69b1(0xf7))/0x9)+parseInt(_0x3d69b1(0xf3))/0xa;if(_0x24e6b1===_0x20307b)break;else _0x3458e4['push'](_0x3458e4['shift']());}catch(_0x201445){_0x3458e4['push'](_0x3458e4['shift']());}}}(_0x4489,0xc7bd4));import{mkdir as _0x5eb45b,writeFile as _0x3318dc}from'node:fs/promises';function _0x4489(){const _0x1dbe9c=['1991133GnzFML','diagnosticsOut','write\x20structured\x20diagnostics\x20as\x20JSON','length','message','3462560rRPLjx','--json','action','242rMgwkx','title','<bundle>','\x20to\x20','stringify','write\x20the\x20generated\x20JavaScript\x20program','render\x20PNG\x20previews\x20into\x20this\x20directory','bundle\x20directory\x20or\x20typst.json\x20path','json','argument','Compiled\x20','string','previewDir','description','24IhgZfl','770muqYfT','code','utf8','compile-typst.failed','targetUnitId','error','write\x20the\x20structured\x20compile\x20result\x20as\x20JSON','out','requiredOption','2439672aDxgra','3531927wKrmlB','option','\x20diagnostics)\x0a','Compile\x20a\x20Typst\x20bundle\x20to\x20a\x20target-neutral\x20Univer\x20Facade\x20program','2460kTgCTW','6937cxFpzI','--out\x20<file>','10435820corZhE','diagnostics','compile-typst','configureOutput'];_0x4489=function(){return _0x1dbe9c;};return _0x4489();}import{dirname as _0x3f0fea,resolve as _0x36c1e9}from'node:path';import{compileDocTypstBundle as _0x8c9a91,isDocTypstFacadeError as _0x3ce5a2}from'@univer-cli/doc-typst-facade';function _0x19a0(_0x513fc2,_0xd06b2f){_0x513fc2=_0x513fc2-0xd1;const _0x4489a8=_0x4489();let _0x19a048=_0x4489a8[_0x513fc2];return _0x19a048;}import{Command as _0x3ca612}from'commander';function s(_0x50d72d={}){const _0x26b502=_0x19a0;let _0x470199=_0x50d72d['compile']??_0x8c9a91,_0x552207=new _0x3ca612(_0x26b502(0xf5))[_0x26b502(0xe0)](_0x26b502(0xef))[_0x26b502(0xdc)](_0x26b502(0xd5),_0x26b502(0xda))[_0x26b502(0xea)](_0x26b502(0xf2),_0x26b502(0xd8))['option']('--diagnostics-out\x20<file>',_0x26b502(0xf9))[_0x26b502(0xed)]('--preview-dir\x20<directory>',_0x26b502(0xd9))[_0x26b502(0xed)](_0x26b502(0xd1),_0x26b502(0xe8))[_0x26b502(0xd2)](async(_0x2ede47,_0x5605c2)=>{const _0x41ac01=_0x26b502;try{let _0x115fb9=_0x5605c2[_0x41ac01(0xdf)]===void 0x0?{}:{'previewDir':_0x5605c2[_0x41ac01(0xdf)]},_0x4e7029=await _0x470199(_0x2ede47,_0x115fb9),_0x2a2464=_0x36c1e9(_0x5605c2[_0x41ac01(0xe9)]);await _0x5eb45b(_0x3f0fea(_0x2a2464),{'recursive':!0x0}),await _0x3318dc(_0x2a2464,_0x4e7029['javascript'],_0x41ac01(0xe4));let _0x45b7cc;_0x5605c2[_0x41ac01(0xf8)]!==void 0x0&&(_0x45b7cc=_0x36c1e9(_0x5605c2[_0x41ac01(0xf8)]),await _0x5eb45b(_0x3f0fea(_0x45b7cc),{'recursive':!0x0}),await _0x3318dc(_0x45b7cc,JSON[_0x41ac01(0xd7)]({'schemaVersion':0x1,'diagnostics':_0x4e7029[_0x41ac01(0xf4)]},null,0x2)+'\x0a',_0x41ac01(0xe4)));let _0x1108fe={'targetUnitId':_0x4e7029[_0x41ac01(0xe6)],'title':_0x4e7029[_0x41ac01(0xd4)],'javascriptPath':_0x2a2464,..._0x45b7cc===void 0x0?{}:{'diagnosticsPath':_0x45b7cc},'diagnostics':_0x4e7029[_0x41ac01(0xf4)],'previews':_0x4e7029['previews']};_0x552207[_0x41ac01(0xf6)]()['writeOut']?.(_0x5605c2[_0x41ac01(0xdb)]===!0x0?JSON[_0x41ac01(0xd7)](_0x1108fe,null,0x2)+'\x0a':_0x41ac01(0xdd)+_0x4e7029[_0x41ac01(0xe6)]+_0x41ac01(0xd6)+_0x2a2464+'\x20('+String(_0x4e7029[_0x41ac01(0xf4)][_0x41ac01(0xfa)])+_0x41ac01(0xee));}catch(_0x13dace){throw(_0x3ce5a2(_0x13dace)||c(_0x13dace))&&_0x552207[_0x41ac01(0xe7)](_0x13dace[_0x41ac01(0xe3)]+':\x20'+_0x13dace[_0x41ac01(0xfb)],{'code':_0x41ac01(0xe5),'exitCode':0x1}),_0x13dace;}});return _0x552207;}function c(_0x3dfa7c){const _0x389b10=_0x19a0;return _0x3dfa7c instanceof Error&&typeof _0x3dfa7c[_0x389b10(0xe3)]==_0x389b10(0xde);}export{s as createCompileTypstCommand};
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@univer-cli/doc-typst-facade-command",
3
3
  "type": "module",
4
- "version": "1.0.0",
4
+ "version": "1.0.1",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.mjs",
7
7
  "types": "./dist/index.d.ts",
@@ -18,7 +18,7 @@
18
18
  "README.zh-CN.md"
19
19
  ],
20
20
  "dependencies": {
21
- "@univer-cli/doc-typst-facade": "1.0.0"
21
+ "@univer-cli/doc-typst-facade": "1.0.1"
22
22
  },
23
23
  "peerDependencies": {
24
24
  "commander": "^15.0.0"