@univerjs-pro/exchange-client 0.6.0-nightly.202502171606 → 0.6.0-nightly.202502191606
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/lib/cjs/facade.js +1 -1
- package/lib/cjs/index.js +2 -2
- package/lib/cjs/locale/en-US.js +1 -1
- package/lib/cjs/locale/fa-IR.js +1 -1
- package/lib/cjs/locale/fr-FR.js +1 -1
- package/lib/cjs/locale/ru-RU.js +1 -1
- package/lib/cjs/locale/vi-VN.js +1 -1
- package/lib/cjs/locale/zh-CN.js +1 -1
- package/lib/cjs/locale/zh-TW.js +1 -1
- package/lib/es/facade.js +1 -1
- package/lib/es/index.js +2 -2
- package/lib/es/locale/en-US.js +1 -1
- package/lib/es/locale/fa-IR.js +1 -1
- package/lib/es/locale/fr-FR.js +1 -1
- package/lib/es/locale/ru-RU.js +1 -1
- package/lib/es/locale/vi-VN.js +1 -1
- package/lib/es/locale/zh-CN.js +1 -1
- package/lib/es/locale/zh-TW.js +1 -1
- package/lib/types/locale/zh-CN.d.ts +1 -0
- package/lib/types/services/operate.service.d.ts +8 -0
- package/lib/types/services/utils/content-type.d.ts +16 -0
- package/lib/types/services/utils/tool.d.ts +6 -1
- package/lib/umd/facade.js +1 -1
- package/lib/umd/index.js +2 -2
- package/lib/umd/locale/en-US.js +1 -1
- package/lib/umd/locale/fa-IR.js +1 -1
- package/lib/umd/locale/fr-FR.js +1 -1
- package/lib/umd/locale/ru-RU.js +1 -1
- package/lib/umd/locale/vi-VN.js +1 -1
- package/lib/umd/locale/zh-CN.js +1 -1
- package/lib/umd/locale/zh-TW.js +1 -1
- package/package.json +6 -6
package/lib/es/locale/en-US.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
const
|
1
|
+
const _0x2d0922=_0x2f69;function _0x2f69(_0x153967,_0x9f6664){const _0x35d3fb=_0x35d3();return _0x2f69=function(_0x2f695d,_0x508128){_0x2f695d=_0x2f695d-0xc7;let _0x487e95=_0x35d3fb[_0x2f695d];return _0x487e95;},_0x2f69(_0x153967,_0x9f6664);}(function(_0x46d098,_0x555357){const _0x14ac45=_0x2f69,_0x572b15=_0x46d098();while(!![]){try{const _0x1ec867=parseInt(_0x14ac45(0xd2))/0x1+-parseInt(_0x14ac45(0xd4))/0x2*(-parseInt(_0x14ac45(0xd5))/0x3)+-parseInt(_0x14ac45(0xd8))/0x4*(-parseInt(_0x14ac45(0xce))/0x5)+parseInt(_0x14ac45(0xd3))/0x6+-parseInt(_0x14ac45(0xcd))/0x7+-parseInt(_0x14ac45(0xd7))/0x8+-parseInt(_0x14ac45(0xd9))/0x9;if(_0x1ec867===_0x555357)break;else _0x572b15['push'](_0x572b15['shift']());}catch(_0x59b01c){_0x572b15['push'](_0x572b15['shift']());}}}(_0x35d3,0xb492a));function _0x35d3(){const _0x1f74b4=['3315690OLnGug','Downloading','Upload\x20again','Network\x20error','Selected\x20file\x20[{0}]\x20is\x20not\x20supported\x20for\x20upload','Please\x20wait...','Data\x20is\x20too\x20large','Internal\x20unknown\x20error','2722482xzOQcH','5705fmVKNq','Cancel','Uploading','{0}\x20file(s)\x20uploaded\x20successfully','926476scjRYY','1325628SaRlhQ','166vceEne','17193NSdqOO','Download\x20success','6586208YAMxUC','2444MDAFUT'];_0x35d3=function(){return _0x1f74b4;};return _0x35d3();}const e={'exchange':{'file':'File','upload':'Open(File)','download':'Save\x20As','uploading':_0x2d0922(0xd0),'uploadSuccess':'File\x20uploaded\x20successfully','uploadSuccessTip':_0x2d0922(0xd1),'downloading':_0x2d0922(0xda),'downloadSuccess':_0x2d0922(0xd6),'unknownMistake':'Unknown\x20mistake','networkError':_0x2d0922(0xc8),'tooLarge':_0x2d0922(0xcb),'internalError':_0x2d0922(0xcc),'interrupt':'The\x20network\x20connection\x20was\x20interrupted\x20and\x20the\x20file\x20upload\x20failed','fileTypeError':_0x2d0922(0xc9),'wait':_0x2d0922(0xca),'cancel':_0x2d0922(0xcf),'uploadAgain':_0x2d0922(0xc7)}};export{e as default};
|
package/lib/es/locale/fa-IR.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
const
|
1
|
+
function _0x89bc(_0x56b872,_0x379baa){const _0x376082=_0x3760();return _0x89bc=function(_0x89bc4f,_0x4a8894){_0x89bc4f=_0x89bc4f-0x184;let _0x2ac010=_0x376082[_0x89bc4f];return _0x2ac010;},_0x89bc(_0x56b872,_0x379baa);}function _0x3760(){const _0x7a4a16=['1336071qqLdwd','خطای\x20داخلی\x20ناشناخته','بارگذاری\x20مجدد','{0}\x20فایل\x20با\x20موفقیت\x20بارگذاری\x20شد','288973TxFIFp','خطای\x20ناشناخته','اتصال\x20شبکه\x20قطع\x20شد\x20و\x20بارگذاری\x20فایل\x20ناموفق\x20بود.','200rLDbAv','1466830EwtvgL','بازکردن(فایل)','در\x20حال\x20بارگذاری','خطای\x20شبکه','4WeCzna','33228XdyMYu','لغو','فایل\x20با\x20موفقیت\x20بارگذاری\x20شد','674708JtbbZV','فایل\x20انتخاب\x20شده\x20[{0}]\x20برای\x20بارگذاری\x20پشتیبانی\x20نمیشود','6XuLlDO','ذخیره\x20به\x20عنوان','16875564nbDlRI','داده\x20خیلی\x20بزرگ\x20است','40myFCwe','دانلود\x20موفقیت\x20آمیز','3892469qmnhjm','3AfKPNJ'];_0x3760=function(){return _0x7a4a16;};return _0x3760();}const _0x35e3ba=_0x89bc;(function(_0x3dc3a3,_0x395eb2){const _0x281396=_0x89bc,_0x2e617e=_0x3dc3a3();while(!![]){try{const _0x678e07=parseInt(_0x281396(0x192))/0x1*(parseInt(_0x281396(0x19a))/0x2)+-parseInt(_0x281396(0x18d))/0x3*(-parseInt(_0x281396(0x184))/0x4)+parseInt(_0x281396(0x196))/0x5*(parseInt(_0x281396(0x186))/0x6)+parseInt(_0x281396(0x18c))/0x7+-parseInt(_0x281396(0x195))/0x8*(parseInt(_0x281396(0x19b))/0x9)+parseInt(_0x281396(0x18a))/0xa*(parseInt(_0x281396(0x18e))/0xb)+-parseInt(_0x281396(0x188))/0xc;if(_0x678e07===_0x395eb2)break;else _0x2e617e['push'](_0x2e617e['shift']());}catch(_0x309cb7){_0x2e617e['push'](_0x2e617e['shift']());}}}(_0x3760,0x8e687));const o={'exchange':{'file':'فایل','upload':_0x35e3ba(0x197),'download':_0x35e3ba(0x187),'uploading':_0x35e3ba(0x198),'uploadSuccess':_0x35e3ba(0x19d),'uploadSuccessTip':_0x35e3ba(0x191),'downloading':'در\x20حال\x20دانلود','downloadSuccess':_0x35e3ba(0x18b),'unknownMistake':_0x35e3ba(0x193),'networkError':_0x35e3ba(0x199),'tooLarge':_0x35e3ba(0x189),'internalError':_0x35e3ba(0x18f),'interrupt':_0x35e3ba(0x194),'fileTypeError':_0x35e3ba(0x185),'wait':'لطفا\x20صبر\x20کنید...','cancel':_0x35e3ba(0x19c),'uploadAgain':_0x35e3ba(0x190)}};export{o as default};
|
package/lib/es/locale/fr-FR.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
const
|
1
|
+
function _0x9e27(){const _0x346268=['1618398oezaie','Erreur\x20réseau','Les\x20données\x20sont\x20trop\x20volumineuses','833070bIDgEG','Erreur\x20inconnue','Le\x20fichier\x20sélectionné\x20[{0}]\x20n\x27est\x20pas\x20pris\x20en\x20charge\x20pour\x20le\x20téléchargement','Téléchargement\x20en\x20cours','4zgeOYC','Fichier','La\x20connexion\x20réseau\x20a\x20été\x20interrompue\x20et\x20le\x20téléchargement\x20du\x20fichier\x20a\x20échoué','Fichier\x20téléchargé\x20avec\x20succès','Annuler','Veuillez\x20patienter...','171472vmkXNj','258pszblP','2904141DJXkOk','Enregistrer\x20sous','7TzdJbX','{0}\x20fichier(s)\x20téléchargé(s)\x20avec\x20succès','Téléchargement\x20réussi','Ouvrir\x20(Fichier)','7464771vwTMmv','Téléchargement','Erreur\x20interne\x20inconnue','7445ZmMKBF','24502190qCfsPn'];_0x9e27=function(){return _0x346268;};return _0x9e27();}function _0x2e5c(_0x58df5d,_0x531c50){const _0x9e2721=_0x9e27();return _0x2e5c=function(_0x2e5c2b,_0x55847c){_0x2e5c2b=_0x2e5c2b-0xb9;let _0x343490=_0x9e2721[_0x2e5c2b];return _0x343490;},_0x2e5c(_0x58df5d,_0x531c50);}const _0x360ea1=_0x2e5c;(function(_0x5488b8,_0x42cf14){const _0x5f3c05=_0x2e5c,_0x140937=_0x5488b8();while(!![]){try{const _0x9f149a=-parseInt(_0x5f3c05(0xcb))/0x1+parseInt(_0x5f3c05(0xc8))/0x2+parseInt(_0x5f3c05(0xbd))/0x3*(-parseInt(_0x5f3c05(0xcf))/0x4)+parseInt(_0x5f3c05(0xc6))/0x5*(parseInt(_0x5f3c05(0xbc))/0x6)+-parseInt(_0x5f3c05(0xbf))/0x7*(parseInt(_0x5f3c05(0xbb))/0x8)+-parseInt(_0x5f3c05(0xc3))/0x9+parseInt(_0x5f3c05(0xc7))/0xa;if(_0x9f149a===_0x42cf14)break;else _0x140937['push'](_0x140937['shift']());}catch(_0x3c9f12){_0x140937['push'](_0x140937['shift']());}}}(_0x9e27,0xa3ef3));const e={'exchange':{'file':_0x360ea1(0xd0),'upload':_0x360ea1(0xc2),'download':_0x360ea1(0xbe),'uploading':_0x360ea1(0xce),'uploadSuccess':_0x360ea1(0xd2),'uploadSuccessTip':_0x360ea1(0xc0),'downloading':_0x360ea1(0xc4),'downloadSuccess':_0x360ea1(0xc1),'unknownMistake':_0x360ea1(0xcc),'networkError':_0x360ea1(0xc9),'tooLarge':_0x360ea1(0xca),'internalError':_0x360ea1(0xc5),'interrupt':_0x360ea1(0xd1),'fileTypeError':_0x360ea1(0xcd),'wait':_0x360ea1(0xba),'cancel':_0x360ea1(0xb9),'uploadAgain':'Télécharger\x20à\x20nouveau'}};export{e as default};
|
package/lib/es/locale/ru-RU.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
const
|
1
|
+
const _0x18429d=_0x1efc;function _0x1efc(_0x4f010d,_0x3efca2){const _0x5c43f1=_0x5c43();return _0x1efc=function(_0x1efc60,_0x1e8f33){_0x1efc60=_0x1efc60-0x1e2;let _0x5c93c8=_0x5c43f1[_0x1efc60];return _0x5c93c8;},_0x1efc(_0x4f010d,_0x3efca2);}(function(_0x4d51d6,_0x2fc1fd){const _0x146cc6=_0x1efc,_0x51d1d3=_0x4d51d6();while(!![]){try{const _0x5953c0=-parseInt(_0x146cc6(0x1f6))/0x1+-parseInt(_0x146cc6(0x1f4))/0x2+parseInt(_0x146cc6(0x1ef))/0x3+-parseInt(_0x146cc6(0x1e4))/0x4+parseInt(_0x146cc6(0x1ec))/0x5*(-parseInt(_0x146cc6(0x1e8))/0x6)+parseInt(_0x146cc6(0x1f3))/0x7+parseInt(_0x146cc6(0x1e6))/0x8;if(_0x5953c0===_0x2fc1fd)break;else _0x51d1d3['push'](_0x51d1d3['shift']());}catch(_0x4b424f){_0x51d1d3['push'](_0x51d1d3['shift']());}}}(_0x5c43,0xce63d));const o={'exchange':{'file':_0x18429d(0x1e3),'upload':_0x18429d(0x1e5),'download':_0x18429d(0x1ee),'uploading':'Загрузка','uploadSuccess':'Файл\x20успешно\x20загружен','uploadSuccessTip':_0x18429d(0x1ea),'downloading':_0x18429d(0x1eb),'downloadSuccess':'Скачивание\x20успешно','unknownMistake':'Неизвестная\x20ошибка','networkError':_0x18429d(0x1e9),'tooLarge':_0x18429d(0x1f0),'internalError':_0x18429d(0x1e2),'interrupt':_0x18429d(0x1f1),'fileTypeError':_0x18429d(0x1f2),'wait':_0x18429d(0x1ed),'cancel':_0x18429d(0x1f5),'uploadAgain':_0x18429d(0x1e7)}};export{o as default};function _0x5c43(){const _0x41654a=['Загрузить\x20снова','372hpzRNr','Сетевая\x20ошибка','{0}\x20файл(ов)\x20успешно\x20загружен(о)','Скачивание','4070nPnlzW','Пожалуйста,\x20подождите...','Сохранить\x20как','3521994dHpmSc','Данные\x20слишком\x20большие','Сетевое\x20соединение\x20было\x20прервано,\x20и\x20загрузка\x20файла\x20не\x20удалась','Выбранный\x20файл\x20[{0}]\x20не\x20поддерживается\x20для\x20загрузки','9785825HuiqPa','2689588Rlxfja','Отмена','766069ZxINCD','Внутренняя\x20неизвестная\x20ошибка','Файл','1372328sHTGJH','Открыть(Файл)','6222504RknYvF'];_0x5c43=function(){return _0x41654a;};return _0x5c43();}
|
package/lib/es/locale/vi-VN.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
const
|
1
|
+
const _0x3bf1e8=_0x5481;(function(_0x452a08,_0xaf11b0){const _0x40cf05=_0x5481,_0x509983=_0x452a08();while(!![]){try{const _0x53ce67=-parseInt(_0x40cf05(0x131))/0x1+-parseInt(_0x40cf05(0x125))/0x2+-parseInt(_0x40cf05(0x121))/0x3*(parseInt(_0x40cf05(0x11e))/0x4)+-parseInt(_0x40cf05(0x133))/0x5*(-parseInt(_0x40cf05(0x12f))/0x6)+-parseInt(_0x40cf05(0x129))/0x7+parseInt(_0x40cf05(0x124))/0x8*(-parseInt(_0x40cf05(0x132))/0x9)+parseInt(_0x40cf05(0x12a))/0xa;if(_0x53ce67===_0xaf11b0)break;else _0x509983['push'](_0x509983['shift']());}catch(_0x561a91){_0x509983['push'](_0x509983['shift']());}}}(_0x51d1,0x84b33));function _0x5481(_0x2ff8df,_0x37be44){const _0x51d1e6=_0x51d1();return _0x5481=function(_0x5481b5,_0x3c8beb){_0x5481b5=_0x5481b5-0x11e;let _0x27231b=_0x51d1e6[_0x5481b5];return _0x27231b;},_0x5481(_0x2ff8df,_0x37be44);}function _0x51d1(){const _0x1dc0f1=['Đang\x20tải\x20lên','Tệp','4kGzwpi','Tải\x20lên\x20lại','Đang\x20tải\x20xuống','2560251ulqBoE','Luồng\x20dữ\x20liệu\x20quá\x20lớn','Lỗi\x20mạng','1074704skTFHE','1234146NfUnsG','Tệp\x20được\x20chọn\x20[{0}]\x20không\x20được\x20hỗ\x20trợ\x20để\x20tải\x20lên','{0}\x20tệp\x20đã\x20được\x20tải\x20lên\x20thành\x20công','Kết\x20nối\x20mạng\x20bị\x20gián\x20đoạn,\x20tải\x20lên\x20tệp\x20thất\x20bại','2243997BhlFCl','33070860NQTDss','Mở\x20(Tệp)','Vui\x20lòng\x20đợi...','Tải\x20lên\x20tệp\x20thành\x20công','Lỗi\x20không\x20xác\x20định\x20bên\x20trong','6SkswTJ','Tải\x20xuống\x20thành\x20công','960179WHEIBz','18UGMTKM','1281845UjWfkZ'];_0x51d1=function(){return _0x1dc0f1;};return _0x51d1();}const n={'exchange':{'file':_0x3bf1e8(0x135),'upload':_0x3bf1e8(0x12b),'download':'Lưu\x20dưới\x20dạng','uploading':_0x3bf1e8(0x134),'uploadSuccess':_0x3bf1e8(0x12d),'uploadSuccessTip':_0x3bf1e8(0x127),'downloading':_0x3bf1e8(0x120),'downloadSuccess':_0x3bf1e8(0x130),'unknownMistake':'Lỗi\x20không\x20xác\x20định','networkError':_0x3bf1e8(0x123),'tooLarge':_0x3bf1e8(0x122),'internalError':_0x3bf1e8(0x12e),'interrupt':_0x3bf1e8(0x128),'fileTypeError':_0x3bf1e8(0x126),'wait':_0x3bf1e8(0x12c),'cancel':'Hủy\x20bỏ','uploadAgain':_0x3bf1e8(0x11f)}};export{n as default};
|
package/lib/es/locale/zh-CN.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
const
|
1
|
+
const _0x1eed1=_0x58a4;(function(_0x4f4bc6,_0x5131c8){const _0x4f8d71=_0x58a4,_0x367896=_0x4f4bc6();while(!![]){try{const _0xd147c3=-parseInt(_0x4f8d71(0x77))/0x1+-parseInt(_0x4f8d71(0x69))/0x2+-parseInt(_0x4f8d71(0x70))/0x3*(-parseInt(_0x4f8d71(0x76))/0x4)+parseInt(_0x4f8d71(0x7b))/0x5+-parseInt(_0x4f8d71(0x7d))/0x6+-parseInt(_0x4f8d71(0x71))/0x7+parseInt(_0x4f8d71(0x79))/0x8*(parseInt(_0x4f8d71(0x6f))/0x9);if(_0xd147c3===_0x5131c8)break;else _0x367896['push'](_0x367896['shift']());}catch(_0x10084b){_0x367896['push'](_0x367896['shift']());}}}(_0x922a,0x961d0));function _0x58a4(_0x1e11bd,_0x4a5c6e){const _0x922ab8=_0x922a();return _0x58a4=function(_0x58a41c,_0x503823){_0x58a41c=_0x58a41c-0x69;let _0x5311a7=_0x922ab8[_0x58a41c];return _0x5311a7;},_0x58a4(_0x1e11bd,_0x4a5c6e);}function _0x922a(){const _0x721b38=['{0}个文件上传成功','下载中','数据流过大','1530erIJau','118869vMmMAR','4332027kpTBrW','打开(文件)','未知错误','上传中','网络异常','124OAANlv','812778WhLKFg','请稍等...','37096NutBIY','所选文件\x20[{0}]\x20不支持上传','5774320QvIyuW','内部未知错误','3111408UKAnBP','1212792TYvMgp','下载成功','另存为'];_0x922a=function(){return _0x721b38;};return _0x922a();}const o={'exchange':{'file':'文件','upload':_0x1eed1(0x72),'download':_0x1eed1(0x6b),'uploading':_0x1eed1(0x74),'uploadSuccess':'文件上传成功','uploadSuccessTip':_0x1eed1(0x6c),'downloading':_0x1eed1(0x6d),'downloadSuccess':_0x1eed1(0x6a),'unknownMistake':_0x1eed1(0x73),'networkError':_0x1eed1(0x75),'tooLarge':_0x1eed1(0x6e),'internalError':_0x1eed1(0x7c),'interrupt':'网络连接中断,文件上传失败','fileTypeError':_0x1eed1(0x7a),'wait':_0x1eed1(0x78),'cancel':'取消','uploadAgain':'再次上传'}};export{o as default};
|
package/lib/es/locale/zh-TW.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
const
|
1
|
+
const _0x4c9d37=_0x138a;function _0x138a(_0x8c9879,_0x50ccb6){const _0x1f3968=_0x1f39();return _0x138a=function(_0x138adf,_0x2045f6){_0x138adf=_0x138adf-0xc1;let _0x3ccbaf=_0x1f3968[_0x138adf];return _0x3ccbaf;},_0x138a(_0x8c9879,_0x50ccb6);}(function(_0x309aae,_0xab5b2a){const _0x38a03f=_0x138a,_0x54d0b6=_0x309aae();while(!![]){try{const _0x1a8fbd=-parseInt(_0x38a03f(0xc2))/0x1+-parseInt(_0x38a03f(0xc1))/0x2*(-parseInt(_0x38a03f(0xc5))/0x3)+-parseInt(_0x38a03f(0xd1))/0x4+-parseInt(_0x38a03f(0xc7))/0x5+parseInt(_0x38a03f(0xd0))/0x6+parseInt(_0x38a03f(0xcf))/0x7*(-parseInt(_0x38a03f(0xc4))/0x8)+parseInt(_0x38a03f(0xc6))/0x9;if(_0x1a8fbd===_0xab5b2a)break;else _0x54d0b6['push'](_0x54d0b6['shift']());}catch(_0x4a4f5a){_0x54d0b6['push'](_0x54d0b6['shift']());}}}(_0x1f39,0xaf08b));function _0x1f39(){const _0x18ad14=['18417222meEToW','2732095OcSYBS','{0}個檔案上傳成功','所選檔案\x20[{0}]\x20不支援上傳','另存為','上傳中','開啟(檔案)','內部未知錯誤','資料流過大','4111849MqiGCa','5339676WXxnna','3410208sKhIPI','下載中','12EtgxhI','861187nFBNrl','檔案上傳成功','8QCtYIa','314100kfLzkM'];_0x1f39=function(){return _0x18ad14;};return _0x1f39();}const o={'exchange':{'file':'檔案','upload':_0x4c9d37(0xcc),'download':_0x4c9d37(0xca),'uploading':_0x4c9d37(0xcb),'uploadSuccess':_0x4c9d37(0xc3),'uploadSuccessTip':_0x4c9d37(0xc8),'downloading':_0x4c9d37(0xd2),'downloadSuccess':'下載成功','unknownMistake':'未知錯誤','networkError':'網路異常','tooLarge':_0x4c9d37(0xce),'internalError':_0x4c9d37(0xcd),'interrupt':'網路連線中斷,檔案上傳失敗','fileTypeError':_0x4c9d37(0xc9),'wait':'請稍等...','cancel':'取消','uploadAgain':'再次上傳'}};export{o as default};
|
@@ -118,4 +118,12 @@ export declare class ExchangeOperateService extends Disposable implements IExcha
|
|
118
118
|
private _addDoneTask;
|
119
119
|
private _completeProgress;
|
120
120
|
private _clearProgress;
|
121
|
+
/**
|
122
|
+
* Although we have specified the supported file types in advance, users can still switch to select all types of files.
|
123
|
+
In order to prevent such unsupported files from being transmitted to the server, they need to be intercepted in advance.
|
124
|
+
* @param fileList
|
125
|
+
* @param type
|
126
|
+
* @returns
|
127
|
+
*/
|
128
|
+
private _fileTypeError;
|
121
129
|
}
|
@@ -0,0 +1,16 @@
|
|
1
|
+
export declare const DOCX = "application/vnd.openxmlformats-officedocument.wordprocessingml.document";
|
2
|
+
export declare const XLSX = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
|
3
|
+
export declare const XLSM = "application/vnd.ms-excel.sheet.macroEnabled.12";
|
4
|
+
export declare const XLTX = "application/vnd.openxmlformats-officedocument.spreadsheetml.template";
|
5
|
+
export declare const PPTX = "application/vnd.openxmlformats-officedocument.presentationml.presentation";
|
6
|
+
export declare const UNIT_CONTENT_TYPE: {
|
7
|
+
0: string[];
|
8
|
+
1: string[];
|
9
|
+
2: string[];
|
10
|
+
3: string[];
|
11
|
+
4: string[];
|
12
|
+
[-1]: string[];
|
13
|
+
};
|
14
|
+
export declare const CONTENT_TYPE_EXTNAME: {
|
15
|
+
[key: string]: string;
|
16
|
+
};
|
@@ -6,7 +6,12 @@ export declare function downloadFileByURL(url: string, filename: string, fileExt
|
|
6
6
|
* @param {File} file - The File object to be downloaded.
|
7
7
|
*/
|
8
8
|
export declare function downloadFile(file: File | Blob, filename: string, fileExt: string): void;
|
9
|
-
|
9
|
+
/**
|
10
|
+
* Get the UniverType of a file based on its content type and extension.
|
11
|
+
* @param file
|
12
|
+
* @returns
|
13
|
+
*/
|
14
|
+
export declare function getUniverTypeByFile(file: File): UniverType.UNIVER_UNKNOWN;
|
10
15
|
export declare function getUploadFile(types: UniverType[], multiple?: boolean): Promise<FileList | null>;
|
11
16
|
export declare function getFileByURL(url: string): Promise<File | undefined>;
|
12
17
|
export declare function getFileNameFromURL(url: string): string | undefined;
|
package/lib/umd/facade.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
function
|
1
|
+
function _0x7b09(_0xdc1709,_0x3e2672){const _0x1d2d23=_0x1d2d();return _0x7b09=function(_0x7b09b8,_0x2dbcd6){_0x7b09b8=_0x7b09b8-0x15e;let _0x2472d1=_0x1d2d23[_0x7b09b8];return _0x2472d1;},_0x7b09(_0xdc1709,_0x3e2672);}function _0x1d2d(){const _0x4db3df=['importDOCXToSnapshot','29015rnchgt','237022iDidWA','importXLSXToSnapshotAsync','object','639XceGQI','4IVENJj','exportXLSXByUnitIdAsync','exportXLSXBySnapshot','3399wXoVZj','3JKGcIT','@univerjs-pro/exchange-client','importDOCXToUnitIdAsync','exportXLSXByUnitId','IExchangeService','UNRECOGNIZED','UniverProExchangeClient','UNIVER_SLIDE','28760rdsNtl','FUniver','importXLSXToUnitId','get','importDOCXToUnitId','53525tBmTIT','38885Cdctda','UNIVER_PROJECT','UNIVER_UNKNOWN','exportXLSXBySnapshotAsync','1509872DMtzbs','@univerjs/core/facade','138BHiWlX','amd','The\x20exchange\x20service\x20is\x20not\x20available','UNIVER_DOC','function','17376RxVHCW','importXLSXToSnapshot','importXLSXToUnitIdAsync','_injector','UniverCoreFacade','importDOCXToSnapshotAsync'];_0x1d2d=function(){return _0x4db3df;};return _0x1d2d();}(function(_0x1341cb,_0x3f6f43){const _0x408069=_0x7b09,_0x2ea7ce=_0x1341cb();while(!![]){try{const _0x4cc7dd=parseInt(_0x408069(0x178))/0x1+-parseInt(_0x408069(0x163))/0x2*(-parseInt(_0x408069(0x16b))/0x3)+-parseInt(_0x408069(0x167))/0x4*(parseInt(_0x408069(0x179))/0x5)+parseInt(_0x408069(0x17f))/0x6*(-parseInt(_0x408069(0x162))/0x7)+-parseInt(_0x408069(0x17d))/0x8+-parseInt(_0x408069(0x166))/0x9*(parseInt(_0x408069(0x173))/0xa)+parseInt(_0x408069(0x16a))/0xb*(parseInt(_0x408069(0x184))/0xc);if(_0x4cc7dd===_0x3f6f43)break;else _0x2ea7ce['push'](_0x2ea7ce['shift']());}catch(_0x156107){_0x2ea7ce['push'](_0x2ea7ce['shift']());}}}(_0x1d2d,0x1e222),function(_0x24b5ce,_0x2501c6){const _0x13be74=_0x7b09;typeof exports==_0x13be74(0x165)&&typeof module<'u'?_0x2501c6(require(_0x13be74(0x16c)),require(_0x13be74(0x17e))):typeof define==_0x13be74(0x183)&&define[_0x13be74(0x180)]?define(['@univerjs-pro/exchange-client','@univerjs/core/facade'],_0x2501c6):(_0x24b5ce=typeof globalThis<'u'?globalThis:_0x24b5ce||self,_0x2501c6(_0x24b5ce[_0x13be74(0x171)],_0x24b5ce[_0x13be74(0x15f)]));}(this,function(_0x3fb078,_0x1e139c){'use strict';const _0x364314=_0x7b09;var _0x38ff70=(_0xa28f80=>(_0xa28f80[_0xa28f80['UNIVER_UNKNOWN']=0x0]=_0x364314(0x17b),_0xa28f80[_0xa28f80[_0x364314(0x182)]=0x1]=_0x364314(0x182),_0xa28f80[_0xa28f80['UNIVER_SHEET']=0x2]='UNIVER_SHEET',_0xa28f80[_0xa28f80[_0x364314(0x172)]=0x3]=_0x364314(0x172),_0xa28f80[_0xa28f80[_0x364314(0x17a)]=0x4]=_0x364314(0x17a),_0xa28f80[_0xa28f80[_0x364314(0x170)]=-0x1]=_0x364314(0x170),_0xa28f80))(_0x38ff70||{});class _0xac6690 extends _0x1e139c[_0x364314(0x174)]{async[_0x364314(0x175)](_0x1f657e){const _0xcb7994=_0x364314;return this[_0xcb7994(0x186)](_0x1f657e);}async['importXLSXToUnitIdAsync'](_0x1631ed){const _0x4ece5a=_0x364314,_0x1276d9=this[_0x4ece5a(0x15e)][_0x4ece5a(0x176)](_0x3fb078[_0x4ece5a(0x16f)]);if(!_0x1276d9)throw new Error(_0x4ece5a(0x181));return _0x1276d9['importFileToUnitId'](_0x1631ed,_0x38ff70['UNIVER_SHEET']);}async[_0x364314(0x185)](_0x3cd2c8){const _0x2430f1=_0x364314;return this[_0x2430f1(0x164)](_0x3cd2c8);}async[_0x364314(0x164)](_0x17a44f){const _0x2d42d2=_0x364314,_0x2856ba=this['_injector'][_0x2d42d2(0x176)](_0x3fb078[_0x2d42d2(0x16f)]);if(!_0x2856ba)throw new Error('The\x20exchange\x20service\x20is\x20not\x20available');return _0x2856ba[_0x2d42d2(0x185)](_0x17a44f);}async[_0x364314(0x16e)](_0x16e5ec){const _0x89533d=_0x364314;return this[_0x89533d(0x168)](_0x16e5ec);}async['exportXLSXByUnitIdAsync'](_0x560d39){const _0xc90401=_0x364314,_0x19d55c=this[_0xc90401(0x15e)][_0xc90401(0x176)](_0x3fb078['IExchangeService']);if(!_0x19d55c)throw new Error('The\x20exchange\x20service\x20is\x20not\x20available');return _0x19d55c[_0xc90401(0x16e)](_0x560d39);}async[_0x364314(0x169)](_0x4e0cf2){const _0x37eb67=_0x364314;return this[_0x37eb67(0x17c)](_0x4e0cf2);}async[_0x364314(0x17c)](_0x21726e){const _0x271c08=_0x364314,_0x14e195=this[_0x271c08(0x15e)][_0x271c08(0x176)](_0x3fb078[_0x271c08(0x16f)]);if(!_0x14e195)throw new Error(_0x271c08(0x181));return _0x14e195[_0x271c08(0x169)](_0x21726e);}async[_0x364314(0x177)](_0x5120fb){const _0x2ebf6f=_0x364314;return this[_0x2ebf6f(0x16d)](_0x5120fb);}async[_0x364314(0x16d)](_0xbe2c1f){const _0x1c774c=_0x364314,_0x44f93a=this[_0x1c774c(0x15e)][_0x1c774c(0x176)](_0x3fb078[_0x1c774c(0x16f)]);if(!_0x44f93a)throw new Error(_0x1c774c(0x181));return _0x44f93a['importFileToUnitId'](_0xbe2c1f,_0x38ff70['UNIVER_DOC']);}async[_0x364314(0x161)](_0x18c5f3){return this['importDOCXToSnapshotAsync'](_0x18c5f3);}async[_0x364314(0x160)](_0x4c76f8){const _0x2cbb2f=_0x364314,_0x545760=this[_0x2cbb2f(0x15e)][_0x2cbb2f(0x176)](_0x3fb078[_0x2cbb2f(0x16f)]);if(!_0x545760)throw new Error(_0x2cbb2f(0x181));return _0x545760[_0x2cbb2f(0x161)](_0x4c76f8);}}_0x1e139c[_0x364314(0x174)]['extend'](_0xac6690);}));
|