@atomicservice/ascf-toolkit 1.0.0
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/.editorconfig +15 -0
- package/LICENSE +201 -0
- package/README.md +22 -0
- package/lib/ascf-compiler/appjson-loader.js +1 -0
- package/lib/ascf-compiler/chalk/bundle.cjs.js +1 -0
- package/lib/ascf-compiler/common/appjson-validator.js +1 -0
- package/lib/ascf-compiler/common/css-runtime-api.js +1 -0
- package/lib/ascf-compiler/common/exp-utils.js +1 -0
- package/lib/ascf-compiler/common/extjson-validator.js +1 -0
- package/lib/ascf-compiler/common/fixComponentName.js +1 -0
- package/lib/ascf-compiler/common/hash-sum.js +1 -0
- package/lib/ascf-compiler/common/hjs-utils.js +1 -0
- package/lib/ascf-compiler/common/hxml-validator.js +1 -0
- package/lib/ascf-compiler/common/logUndefined.js +1 -0
- package/lib/ascf-compiler/common/packoptions-utils.js +1 -0
- package/lib/ascf-compiler/common/utils.js +1 -0
- package/lib/ascf-compiler/css-process-loader.js +1 -0
- package/lib/ascf-compiler/extract-loader.js +1 -0
- package/lib/ascf-compiler/hcss-loader.js +1 -0
- package/lib/ascf-compiler/hjs-loader.js +1 -0
- package/lib/ascf-compiler/hxml-loader.js +1 -0
- package/lib/ascf-compiler/loader-utils.js +1 -0
- package/lib/ascf-compiler/path-process-loader.js +1 -0
- package/lib/ascf-compiler/plugin/copy-bundle-plugin.js +1 -0
- package/lib/ascf-compiler/plugin/html-generator-plugin.js +1 -0
- package/lib/ascf-compiler/plugin/i18n-transform-plugin.js +1 -0
- package/lib/ascf-compiler/plugin/manifest-generator-plugin.js +1 -0
- package/lib/ascf-compiler/plugin/resource-plugin.js +1 -0
- package/lib/ascf-compiler/plugin/webpack-target/index.js +1 -0
- package/lib/ascf-compiler/plugin/webpack-target/jsonpChunkLoadingRuntimeModule.js +1 -0
- package/lib/ascf-compiler/plugin/webpack-target/jsonpHelpers.js +1 -0
- package/lib/ascf-compiler/plugin/webpack-target/jsonpTemplatePlugin.js +1 -0
- package/lib/ascf-compiler/template/attr-utils.js +1 -0
- package/lib/ascf-compiler/template/node-name-utils.js +1 -0
- package/lib/ascf-compiler/trustlist-hxml-verify-loader.js +1 -0
- package/lib/ascf-compiler/trustlist-js-verify-loader.js +1 -0
- package/lib/ascf-compiler/trustlist-verify/config.js +1 -0
- package/lib/ascf-compiler/trustlist-verify/utils.js +1 -0
- package/lib/ascf-compiler/vue-compiler/vue.bundle.js +1 -0
- package/lib/ascf-compiler/web.webpack.config.js +1 -0
- package/lib/ascf-converter/common/commonConfig.js +1 -0
- package/lib/ascf-converter/common/commonUtils.js +1 -0
- package/lib/ascf-converter/common/textDocument.js +1 -0
- package/lib/ascf-converter/compiler-utils/parse5.bundle.js +1 -0
- package/lib/ascf-converter/features/converter.js +1 -0
- package/lib/ascf-converter/features/fileHandle.js +1 -0
- package/lib/ascf-converter/features/transformReport.js +1 -0
- package/lib/ascf-converter/lib/apiadapter4alipay.js +1 -0
- package/lib/ascf-converter/lib/locale.json +214 -0
- package/lib/ascf-converter/parse/babelParser.js +1 -0
- package/lib/ascf-converter/parse/importVisitor.js +1 -0
- package/lib/ascf-converter/parse/wxssParser.js +1 -0
- package/lib/ascf-project-generator/templates/Index.ets +0 -0
- package/lib/ascf-project-generator/templates/build-profile.json5 +25 -0
- package/lib/ascf-project-generator/templates/hvigorfile.ts +6 -0
- package/lib/ascf-project-generator/templates/obfuscation-rules.txt +18 -0
- package/lib/ascf-project-generator/templates/oh-package.json5 +11 -0
- package/lib/ascf-project-generator/templates/src/main/module.json5 +13 -0
- package/lib/ascf-project-generator/templates/src/main/resources/base/element/string.json +8 -0
- package/lib/bin/ascf.js +2 -0
- package/lib/common/logger-plugin.js +1 -0
- package/lib/common/remove-strict-mode-plugin.js +1 -0
- package/lib/common/utils.js +1 -0
- package/notice/openSourceSoftwareNotice.html +5132 -0
- package/package.json +156 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var _0x58d34f=_0x510f;function _typeof(t){var e=_0x510f;return(_typeof="function"==typeof Symbol&&e(309)==typeof Symbol.iterator?function(t){return typeof t}:function(t){var r=e;return t&&r(320)==typeof Symbol&&t[r(243)]===Symbol&&t!==Symbol[r(207)]?r(309):typeof t})(t)}function _regeneratorRuntime(){var f=_0x510f;_regeneratorRuntime=function(){return c};var s,c={},t=Object[f(207)],h=t.hasOwnProperty,m=Object[f(269)]||function(t,r,e){t[r]=e.value},r="function"==typeof Symbol?Symbol:{},i=r[f(211)]||f(186),e=r[f(245)]||f(292),n=r[f(288)]||f(239);function o(t,r,e){return Object.defineProperty(t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}),t[r]}try{o({},"")}catch(t){o=function(t,r,e){return t[r]=e}}function u(t,r,e,n){var o,i,a,c,u=f,r=r&&r[u(207)]instanceof g?r:g,r=Object.create(r[u(207)]),u=new j(n||[]);return m(r,"_invoke",{value:(o=t,i=e,a=u,c=p,function(t,r){var e=_0x510f;if(c===_)throw Error("Generator is already running");if(c===d){if(e(206)===t)throw r;return{value:s,done:!0}}for(a[e(258)]=t,a.arg=r;;){var n=a[e(261)];if(n){n=function t(r,e){var n=f,o=e[n(258)],i=r[n(211)][o];if(i===s)return e[n(261)]=null,n(206)===o&&r[n(211)][n(325)]&&(e.method=n(325),e[n(254)]=s,t(r,e),n(206)===e[n(258)])||n(325)!==o&&(e[n(258)]="throw",e[n(254)]=new TypeError(n(300)+o+n(307))),y;o=l(i,r[n(211)],e[n(254)]);if(n(206)===o[n(278)])return e.method=n(206),e[n(254)]=o[n(254)],e.delegate=null,y;i=o[n(254)];return i?i[n(268)]?(e[r[n(271)]]=i.value,e[n(279)]=r[n(272)],n(325)!==e[n(258)]&&(e[n(258)]="next",e.arg=s),e.delegate=null,y):i:(e[n(258)]="throw",e[n(254)]=new TypeError(n(263)),e.delegate=null,y)}(n,a);if(n){if(n===y)continue;return n}}if(e(279)===a[e(258)])a[e(318)]=a._sent=a[e(254)];else if(e(206)===a[e(258)]){if(c===p)throw c=d,a.arg;a[e(299)](a.arg)}else e(325)===a[e(258)]&&a[e(198)](e(325),a.arg);c=_;n=l(o,i,a);if("normal"===n[e(278)]){if(c=a[e(268)]?d:v,n.arg===y)continue;return{value:n[e(254)],done:a.done}}"throw"===n[e(278)]&&(c=d,a.method="throw",a[e(254)]=n[e(254)])}})}),r}function l(t,r,e){var n=f;try{return{type:"normal",arg:t.call(r,e)}}catch(t){return{type:n(206),arg:t}}}c[f(301)]=u;var p=f(196),v=f(296),_=f(181),d="completed",y={};function g(){}function a(){}function x(){}var r={},b=(o(r,i,function(){return this}),Object[f(185)]),b=b&&b(b(O([]))),w=(b&&b!==t&&h.call(b,i)&&(r=b),x[f(207)]=g[f(207)]=Object[f(197)](r));function C(t){var r=f;["next",r(206),r(325)].forEach(function(r){o(t,r,function(t){return this[_0x510f(228)](r,t)})})}function P(c,u){var r;m(this,f(228),{value:function(e,n){function t(){return new u(function(t,r){!function r(t,e,n,o){var i,a=_0x510f,t=l(c[t],c,e);if("throw"!==t[a(278)])return(e=(i=t[a(254)]).value)&&a(221)==_typeof(e)&&h[a(280)](e,a(252))?u.resolve(e.__await)[a(249)](function(t){r(a(279),t,n,o)},function(t){r(a(206),t,n,o)}):u[a(262)](e)[a(249)](function(t){i.value=t,n(i)},function(t){return r("throw",t,n,o)});o(t.arg)}(e,n,t,r)})}return r=r?r.then(t,t):t()}})}function F(t){var r=f,e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e[r(306)]=t[2],e[r(294)]=t[3]),this.tryEntries[r(281)](e)}function S(t){var r=f,e=t[r(329)]||{};e[r(278)]=r(227),delete e[r(254)],t.completion=e}function j(t){var r=f;this.tryEntries=[{tryLoc:"root"}],t.forEach(F,this),this[r(276)](!0)}function O(e){var n=f;if(e||""===e){var o,t=e[i];if(t)return t[n(280)](e);if("function"==typeof e[n(279)])return e;if(!isNaN(e.length))return o=-1,(t=function t(){for(var r=n;++o<e[r(205)];)if(h.call(e,o))return t[r(220)]=e[o],t[r(268)]=!1,t;return t.value=s,t[r(268)]=!0,t})[n(279)]=t}throw new TypeError(_typeof(e)+n(202))}return a[f(207)]=x,m(w,f(243),{value:x,configurable:!0}),m(x,f(243),{value:a,configurable:!0}),a[f(187)]=o(x,n,f(247)),c[f(285)]=function(t){var r=f,t=r(320)==typeof t&&t[r(243)];return!!t&&(t===a||"GeneratorFunction"===(t[r(187)]||t[r(213)]))},c[f(304)]=function(t){var r=f;return Object[r(237)]?Object.setPrototypeOf(t,x):(t[r(216)]=x,o(t,n,r(247))),t[r(207)]=Object.create(w),t},c[f(222)]=function(t){return{__await:t}},C(P[f(207)]),o(P[f(207)],e,function(){return this}),c[f(234)]=P,c[f(260)]=function(t,r,e,n,o){var i=f,a=(void 0===o&&(o=Promise),new P(u(t,r,e,n),o));return c[i(285)](r)?a:a.next()[i(249)](function(t){var r=i;return t[r(268)]?t[r(220)]:a.next()})},C(w),o(w,n,f(225)),o(w,i,function(){return this}),o(w,f(328),function(){return"[object Generator]"}),c[f(224)]=function(t){var r,n=f,o=Object(t),i=[];for(r in o)i[n(281)](r);return i[n(251)](),function t(){for(var r=n;i[r(205)];){var e=i[r(209)]();if(e in o)return t[r(220)]=e,t[r(268)]=!1,t}return t[r(268)]=!0,t}},c[f(231)]=O,j[f(207)]={constructor:j,reset:function(t){var r=f;if(this.prev=0,this[r(279)]=0,this[r(318)]=this[r(248)]=s,this[r(268)]=!1,this[r(261)]=null,this[r(258)]="next",this[r(254)]=s,this[r(253)].forEach(S),!t)for(var e in this)"t"===e[r(289)](0)&&h[r(280)](this,e)&&!isNaN(+e[r(310)](1))&&(this[e]=s)},stop:function(){var t=f,r=(this[t(268)]=!0,this[t(253)][0].completion);if("throw"===r[t(278)])throw r.arg;return this[t(183)]},dispatchException:function(n){var o=f;if(this[o(268)])throw n;var i=this;function t(t,r){var e=o;return a[e(278)]="throw",a[e(254)]=n,i[e(279)]=t,r&&(i.method=e(279),i[e(254)]=s),!!r}for(var r=this[o(253)][o(205)]-1;0<=r;--r){var e=this[o(253)][r],a=e.completion;if(o(188)===e[o(195)])return t("end");if(e[o(195)]<=this.prev){var c=h[o(280)](e,o(266)),u=h.call(e,o(306));if(c&&u){if(this.prev<e.catchLoc)return t(e[o(266)],!0);if(this[o(210)]<e.finallyLoc)return t(e[o(306)])}else if(c){if(this.prev<e[o(266)])return t(e.catchLoc,!0)}else{if(!u)throw Error(o(273));if(this[o(210)]<e[o(306)])return t(e[o(306)])}}}},abrupt:function(t,r){for(var e=f,n=this[e(253)].length-1;0<=n;--n){var o=this[e(253)][n];if(o[e(195)]<=this[e(210)]&&h[e(280)](o,"finallyLoc")&&this[e(210)]<o[e(306)]){var i=o;break}}var a=(i=i&&(e(313)===t||e(240)===t)&&i[e(195)]<=r&&r<=i[e(306)]?null:i)?i.completion:{};return a[e(278)]=t,a[e(254)]=r,i?(this[e(258)]=e(279),this.next=i[e(306)],y):this[e(327)](a)},complete:function(t,r){var e=f;if(e(206)===t.type)throw t[e(254)];return"break"===t[e(278)]||"continue"===t[e(278)]?this[e(279)]=t[e(254)]:e(325)===t[e(278)]?(this.rval=this[e(254)]=t.arg,this.method=e(325),this[e(279)]=e(274)):e(227)===t.type&&r&&(this[e(279)]=r),y},finish:function(t){for(var r=f,e=this[r(253)].length-1;0<=e;--e){var n=this.tryEntries[e];if(n.finallyLoc===t)return this[r(327)](n[r(329)],n[r(294)]),S(n),y}},catch:function(t){for(var r=f,e=this[r(253)].length-1;0<=e;--e){var n,o,i=this[r(253)][e];if(i.tryLoc===t)return n=i[r(329)],r(206)===n.type&&(o=n[r(254)],S(i)),o}throw Error(r(308))},delegateYield:function(t,r,e){var n=f;return this[n(261)]={iterator:O(t),resultName:r,nextLoc:e},n(279)===this[n(258)]&&(this[n(254)]=s),y}},c}function _0x510f(t,r){var e=_0xd620();return(_0x510f=function(t,r){return e[t-=181]})(t,r)}function asyncGeneratorStep(t,r,e,n,o,i,a){var c=_0x510f;try{var u=t[i](a),f=u[c(220)]}catch(t){return void e(t)}u[c(268)]?r(f):Promise[c(262)](f)[c(249)](n,o)}function _asyncToGenerator(u){return function(){var t=this,c=arguments;return new Promise(function(r,e){var n=_0x510f,o=u[n(257)](t,c);function i(t){asyncGeneratorStep(o,r,e,i,a,n(279),t)}function a(t){asyncGeneratorStep(o,r,e,i,a,n(206),t)}i(void 0)})}}(()=>{for(var t=_0x510f,r=_0xd620();;)try{if(674932==+parseInt(t(267))*(-parseInt(t(199))/2)+-parseInt(t(295))/3+parseInt(t(315))/4+-parseInt(t(265))/5+parseInt(t(229))/6*(parseInt(t(242))/7)+-parseInt(t(223))/8+-parseInt(t(286))/9*(-parseInt(t(230))/10))break;r.push(r.shift())}catch(t){r.push(r.shift())}})(),Object[_0x58d34f(269)](exports,_0x58d34f(302),{value:!0}),exports[_0x58d34f(235)]=exports[_0x58d34f(305)]=exports[_0x58d34f(256)]=void 0;var commonConfig_1=require("../common/commonConfig"),path=require(_0x58d34f(290)),fs=require("fs"),commonUtils_1=require(_0x58d34f(311)),_require=require(_0x58d34f(189)),clearResource=_require.clearResource;function confirmConverterFun(t,r){return _confirmConverterFun[_0x58d34f(257)](this,arguments)}function _confirmConverterFun(){var r=_0x58d34f;return(_confirmConverterFun=_asyncToGenerator(_regeneratorRuntime()[r(304)](function t(e,n){var o,i,a=r;return _regeneratorRuntime()[a(301)](function(t){for(var r=a;;)switch(t.prev=t[r(279)]){case 0:if(t[r(210)]=0,o=path[r(262)](e[r(244)],r(208)),i=path[r(262)](e[r(244)],r(238)),fs[r(203)](i)||!fs[r(203)](o)||e[r(255)]){t.next=7;break}return t.abrupt(r(325),{command:r(303)});case 7:return t.next=9,doConvert(e,n);case 9:return t[r(198)](r(325),t[r(318)]);case 10:t[r(279)]=16;break;case 12:return t.prev=12,t.t0=t[r(316)](0),console.error(t.t0),t[r(198)](r(325),{command:"failedTransform",errorMessage:t.t0[r(201)]});case 16:case r(274):return t[r(214)]()}},t,null,[[0,12]])})))[r(257)](this,arguments)}function confirmConverterH5Fun(t,r){var e=_0x58d34f,n=path[e(215)](t[e(204)],t[e(298)]);try{return commonUtils_1.createDirs(n,e(326),!0),commonUtils_1[e(297)](path[e(215)](__filename,e(312),e(326)),path[e(215)](n,e(326)),!1,!0),commonUtils_1.handleConfigInfo(t,path[e(215)](n,e(326))),{command:e(283)}}catch(t){return console[e(330)](t),{command:e(317),errorMessage:t.message}}}function checkConvertOutput(t,r){var e=_0x58d34f;if(fs[e(203)](r))throw new Error("Output path ".concat(r,e(217)));if(r[e(192)](t))throw new Error("Output path is error, cannot be in the input directory .")}function doConvert(t,r){return _doConvert.apply(this,arguments)}function _doConvert(){return(_doConvert=_asyncToGenerator(_regeneratorRuntime().mark(function t(e,r){var n,o,i,a=_0x510f;return _regeneratorRuntime()[a(301)](function(t){for(var r=a;;)switch(t.prev=t.next){case 0:if(n=path[r(262)](e[r(204)],r(246)),process[r(233)][r(324)]===r(319))return t[r(279)]=4,clearResource([n]);t[r(279)]=4;break;case 4:return checkConvertOutput(e[r(244)],n),o=commonConfig_1[r(284)][r(200)],t[r(210)]=6,commonUtils_1.createDirs(n,o),commonUtils_1[r(184)](n,e[r(244)]),i=path[r(215)](n,o),"./"===o||""===o?(commonUtils_1[r(291)](e[r(244)],i),commonUtils_1[r(297)](e[r(244)],i)):(commonUtils_1[r(291)](path[r(215)](e.inputPath,o),i),commonUtils_1[r(297)](path[r(215)](e[r(244)],o),i),commonUtils_1[r(321)](path[r(215)](e[r(244)]),n)),commonUtils_1[r(194)](),commonUtils_1[r(314)](path[r(215)](n,o),e),commonUtils_1[r(241)](path[r(215)](n,o),e),commonUtils_1[r(264)](path[r(215)](n)),"my"===commonConfig_1[r(284)][r(218)]&&commonUtils_1[r(236)](n,path[r(215)](__filename,r(270))),t.abrupt("return",{command:r(283),folderUrl:n});case 19:return t.prev=19,t.t0=t.catch(6),console[r(330)](t.t0),removePromise(n)[r(322)](),t[r(198)](r(325),{command:r(317),errorMessage:t.t0[r(201)]});case 24:case r(274):return t[r(214)]()}},t,null,[[6,19]])}))).apply(this,arguments)}function removePromise(i){return new Promise(function(o,t){var e=_0x510f;fs[e(250)](i,function(t,r){var n=e;r[n(293)]()?fs[n(190)](i,function(t,r){var e=n,r=(r=r[e(277)](function(t){return path[e(215)](i,t)}))[e(277)](function(t){return removePromise(t)});Promise[e(282)](r)[e(249)](function(){fs[e(232)](i,o)})}):fs[n(323)](i,o)})})}function checkInputPathFun(t){var r=_0x58d34f,t=path[r(262)](t),e=checkMiniProgram(t);return{command:r(275),data:{returnCode:e,outPath:path.dirname(t)}}}function checkMiniProgram(t){var r=_0x58d34f,e=!0,n=path.join(t,r(208));return e=fs[r(203)](n)&&identifyProgram(t)?e:!1}function _0xd620(){var t=["catchLoc","366353bSPxqq","done","defineProperty","../../","resultName","nextLoc","try statement without catch or finally","end","postInputPath","reset","map","type","next","call","push","all","completeTransform","Applets","isGeneratorFunction","599607MDoLQK","miniprogramRoot","toStringTag","charAt","path","setOriginPtahObject","@@asyncIterator","isDirectory","afterLoc","4035504rJSCNP","suspendedYield","copyDir","packageName","dispatchException","The iterator does not provide a '","wrap","__esModule","notifyConfig","mark","confirmConverterH5Fun","finallyLoc","' method","illegal catch attempt","symbol","slice","../common/commonUtils","../lib","break","appJsonFile","1063620ZRILjF","catch","failedTransform","sent","yes","function","copyConfigFiles","finally","unlink","clearResource","return","src","complete","toString","completion","error","executing","readFileSync","rval","createTransformReportFile","getPrototypeOf","@@iterator","displayName","root","../../common/utils","readdir","pages","startsWith","configBasenameArray","transformNodeModuleComponent","tryLoc","suspendedStart","create","abrupt","2lpnvzm","srcRootPath","message"," is not iterable","existsSync","outPath","length","throw","prototype","app.json","pop","prev","iterator","hxml","name","stop","join","__proto__"," is exists. Use the -c parameter to clear.","appletType","smartProgramRoot","value","object","awrap","4636504vsoVoq","keys","Generator","isArray","normal","_invoke","4844406sgshZh","330AqBrfR","values","rmdir","env","AsyncIterator","checkInputPathFun","adaptApiFile","setPrototypeOf","project.config.json","@@toStringTag","continue","extJsonFile","7eYEmpI","constructor","inputPath","asyncIterator","ascf/ascf_src","GeneratorFunction","_sent","then","stat","reverse","__await","tryEntries","arg","confirmAddConfig","confirmConverterFun","apply","method","parse","async","delegate","resolve","iterator result is not an object","projectConfigFile","1529245Qiwhwu"];return(_0xd620=function(){return t})()}function identifyProgram(t){var r=_0x58d34f;try{var e=path[r(215)](t,r(208)),n=JSON[r(259)](fs.readFileSync(e).toString());if(n&&n[r(191)]&&Array[r(226)](n[r(191)])&&0<n.pages.length)for(var o=getSrcRootPath(t),i=0,a=Object[r(224)](commonConfig_1.projectFileSuffix);i<a[r(205)];i++){var c=a[i],u=path[r(215)](t,o,n[r(191)][0]+commonConfig_1.projectFileSuffix[c][r(212)]);if(fs[r(203)](u))return commonConfig_1[r(284)][r(218)]="wx"===c?"tt":c,!0}return!1}catch(t){return!1}}function getSrcRootPath(t){var r=_0x58d34f;commonConfig_1[r(284)][r(200)]="./";for(var e=0;e<commonConfig_1.configBasenameArray[r(205)];e++){var n=commonConfig_1[r(193)][e],n=path[r(215)](t,n);fs[r(203)](n)&&((n=JSON[r(259)](fs[r(182)](n)[r(328)]()))[r(287)]?commonConfig_1[r(284)][r(200)]=n[r(287)]:n[r(219)]?commonConfig_1.Applets[r(200)]=n.smartProgramRoot:commonConfig_1.Applets[r(200)]="./")}return commonConfig_1[r(284)][r(200)]}exports.confirmConverterFun=confirmConverterFun,exports.confirmConverterH5Fun=confirmConverterH5Fun,exports.checkInputPathFun=checkInputPathFun;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var globalDistanceCount,globalJsLine,_0x3df270=_0x1418,path=((()=>{for(var e=_0x1418,t=_0xbf7f();;)try{if(792574==-parseInt(e(303))+parseInt(e(339))/2+-parseInt(e(304))/3+parseInt(e(313))/4*(parseInt(e(317))/5)+parseInt(e(335))/6*(-parseInt(e(353))/7)+-parseInt(e(310))/8*(-parseInt(e(318))/9)+-parseInt(e(287))/10*(-parseInt(e(283))/11))break;t.push(t.shift())}catch(e){t.push(t.shift())}})(),Object[_0x3df270(288)](exports,_0x3df270(291),{value:!0}),exports[_0x3df270(356)]=exports[_0x3df270(328)]=exports[_0x3df270(295)]=exports[_0x3df270(326)]=exports[_0x3df270(284)]=void 0,require(_0x3df270(351))),fs=require("fs"),_require=require(_0x3df270(347)),create=_require[_0x3df270(349)],fileHandle_1=require(_0x3df270(337)),commonConfig_1=require("../common/commonConfig"),commonUtils_1=require(_0x3df270(308)),importVisitor_1=require("../parse/importVisitor"),wxssParser_1=require(_0x3df270(299)),commonConfig_2=require(_0x3df270(322)),TransformReport=require("./transformReport"),parse5=require(_0x3df270(289)),insertedApiObj={},insertedApiCountObj={},DEST_API_NAME="has",DEST_API_LEN=DEST_API_NAME[_0x3df270(332)];function handleWxssImport(e,n,r){var o=_0x3df270,a=commonConfig_1.projectFileSuffix[r],e=create(e,n),e=(n=e[o(331)](),wxssParser_1[o(338)](n,e,a[o(325)],r)),s=0;return e[o(324)](function(e){var t=o;e[t(330)]===t(354)?(n=commonUtils_1[t(316)](n,e[t(350)]-a[t(325)][t(332)]-s,e.endOffset-s,".css"),s+=a.css[t(332)]-4):(n=commonUtils_1[t(316)](n,e[t(282)]-s,e[t(282)]+r[t(332)]+1-s,""),s+=r[t(332)]+1)}),n}function handleWxmlFile(e,t,n,r){var o=_0x3df270,t=create(e,t),o=parse5[o(340)](t.getText(),{});return parse5.serialize(o,{convertOptions:{filePath:e,srcPath:n,appType:r,utils:{commonConfig:commonConfig_1,importVisitor:importVisitor_1,textDocument:{create:create},fileHandle:fileHandle_1}}})}function transformWxSchemas(e,t,n){var r=_0x3df270,o=e[r(307)][r(323)],t=t[r(344)]({line:o[r(333)]-1,character:o[r(302)]+1});return n=commonUtils_1[r(316)](n,t+globalDistanceCount,t+e[r(346)][r(332)]+globalDistanceCount,r(294)),globalDistanceCount-=e.module[r(332)]-4,n}function transformWxmlWxsFilePath(e,t,n){var r=_0x3df270,o=e[r(307)].start,t=t[r(344)]({line:o.line-1,character:o[r(302)]});return n=commonUtils_1.replacepos(n,t+globalDistanceCount,t+globalDistanceCount+e[r(346)][r(332)]-1,4===e.module.length?r(329):r(305))}function _0xbf7f(){var e=["transformJsFile","hjs","type","getText","length","line","api ","18498rQPcKo","setLanguage","../features/fileHandle","wxssParser","2614176wiMqJF","parseFragment","fileImport","uri","// ","offsetAt","property","module","../common/textDocument","writeInfo","create","endOffset","path","join","3017UazZgW","import","existsSync","transformJsPath","behaviors","startOffset","10384VnvRJw","handleWxssImport","invalidApis","interfacesForTransform","15680ovAVoc","defineProperty","../compiler-utils/parse5.bundle","projectFileSuffix","__esModule",".js","keys","has:","transformWxsFilePath","extname","insertStr","notSupport","../parse/wxssParser","filePath",' {"line":',"character","820535SgQxgt","4178349kkuuSa","hxml","startsWith","moduleRange","../common/commonUtils","wxInterface","1332696HBkdOR","indexOf","concat","12nFeGXT",',"column":',"getImportRules","replacepos","1468395qmLhKi","36iTCBKy","substring","../"," TODO\n","../common/commonConfig","start","forEach","css","handleWxmlFile","mixins"];return(_0xbf7f=function(){return e})()}function transformWxsFilePath(e,s,i,l,t){var c=_0x3df270,f=0,m=commonConfig_1[c(290)][t];return e.forEach(function(e){var t=c;if(path[t(296)](e[t(346)])===m.hjs){var n=e[t(346)],r=e[t(307)][t(323)],r=s[t(344)]({line:r.line-1,character:r[t(302)]-1})+f,o=e.module[t(319)](0,e[t(346)][t(332)]-(m.hjs[t(332)]-1))+t(329);if(n&&!n[t(306)]("./")&&!n[t(306)](t(320))){var a=path.join(l,"..",n);if(!path[t(296)](a))return;fs.existsSync(a)&&(a=".",n[t(306)]("/")?f+=1:(a="./",f+=2),o=a+o)}i=commonUtils_1[t(316)](i,r,r+e[t(346)][t(332)],o)}}),i}function transformWxInterface(e,t,n,r){var o,a,s=_0x3df270,i=e[s(307)][s(323)],l=t[s(342)]()+"-"+i[s(333)],c=t.offsetAt({line:i.line-1,character:i.character});return n=commonUtils_1[s(316)](n,c+globalDistanceCount,globalDistanceCount+c+r[s(332)],DEST_API_NAME),commonConfig_2[s(286)][e.property]?(globalDistanceCount-=r[s(332)]-DEST_API_LEN,n=commonUtils_1.replacepos(n,c+globalDistanceCount+r[s(332)]+1,c+globalDistanceCount+r[s(332)]+1+e.property.length,commonConfig_2[s(286)][e.property]),globalDistanceCount-=e[s(345)][s(332)]-commonConfig_2[s(286)][e[s(345)]].length):-1===commonConfig_2[s(285)].indexOf(e[s(345)])||-1!==Object[s(293)](insertedApiObj)[s(311)](l)&&insertedApiObj[l]===e.property?globalDistanceCount-=r[s(332)]-DEST_API_LEN:(c=t[s(344)]({line:i.line-1,character:0}),o=s(343)[s(312)](commonUtils_1[s(336)](s(298)),s(334))[s(312)](DEST_API_NAME,".")[s(312)](e[s(345)],s(321)),a=i.line+1,insertedApiCountObj[l]&&(a+=insertedApiCountObj[l]),t=t[s(342)]()+s(301)+(a+globalJsLine)+s(314)+i[s(302)]+"}",TransformReport[s(348)]("".concat(commonUtils_1[s(336)]("notSupport"),"api ").concat(DEST_API_NAME,".")[s(312)](e[s(345)]),t),n=commonUtils_1[s(297)](n,c+globalDistanceCount,o),globalJsLine++,globalDistanceCount=(globalDistanceCount+=o.length)-(r[s(332)]-DEST_API_LEN),insertedApiObj[l]=e[s(345)],insertedApiCountObj[l]?insertedApiCountObj[l]++:insertedApiCountObj[l]=1),n}function transformJsFile(e,n,r,o){var a=_0x3df270,s=create(e,r),e=(r=s[a(331)](),importVisitor_1[a(315)](r,null,null,o));return globalJsLine=globalDistanceCount=0,e[a(324)](function(e){var t=a;switch(e[t(330)]){case t(341):r=transformJsPath(e,n,r,s);break;case t(309):r=transformWxInterface(e,s,r,o);break;case t(300):r=transformWxmlWxsFilePath(e,s,r);break;case"wxSchema":r=transformWxSchemas(e,s,r);break;case t(327):r=transformComponentMixins(e,s,r)}}),r}function transformComponentMixins(e,t,n){var r=_0x3df270,o=e.moduleRange[r(323)],t=t[r(344)]({line:o.line-1,character:o[r(302)]});return n=commonUtils_1[r(316)](n,t+globalDistanceCount,t+e[r(346)][r(332)]+globalDistanceCount,r(281)),globalDistanceCount-=e.module.length-9,n}function _0x1418(e,t){var n=_0xbf7f();return(_0x1418=function(e,t){return n[e-=281]})(e,t)}function transformJsPath(e,t,n,r){var o=_0x3df270,a=e[o(346)];return!a||a.startsWith("./")||a.startsWith(o(320))||(t=path[o(352)](t,"..",a),path[o(296)](t)||(t+=o(292)),fs[o(355)](t)&&(t=e[o(307)].start,e=r.offsetAt({line:t[o(333)]-1,character:t[o(302)]-1})+globalDistanceCount,r=".",a[o(306)]("/")?globalDistanceCount+=1:(r="./",globalDistanceCount+=2),n=commonUtils_1.insertStr(n,e,r))),n}exports[_0x3df270(284)]=handleWxssImport,exports[_0x3df270(326)]=handleWxmlFile,exports[_0x3df270(295)]=transformWxsFilePath,exports.transformJsFile=transformJsFile,exports[_0x3df270(356)]=transformJsPath;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var _0x40da89=_0x5c6e;function _0x5c6e(t,r){var e=_0x8883();return(_0x5c6e=function(t,r){return e[t-=349]})(t,r)}function _0x8883(){var t=["insertInfo","\n\n\n","137406dgsltB","join","24BFCCUC","getGlobleOutPutPath","position","27UvbJuw","writeFileSync","7841190LygOkt","readFileSync","2434370reNOcK","defineProperty","3011655JrWDhn","13502VERYVS","writeInfo","354iFRIPp","1742223IQvNhE","../common/commonUtils","Error: ","4484656wFgvMP"];return(_0x8883=function(){return t})()}(()=>{for(var t=_0x5c6e,r=_0x8883();;)try{if(875318==-parseInt(t(358))+-parseInt(t(349))/2*(parseInt(t(351))/3)+parseInt(t(355))/4+-parseInt(t(369))/5+parseInt(t(365))/6+-parseInt(t(352))/7*(parseInt(t(360))/8)+parseInt(t(363))/9*(parseInt(t(367))/10))break;r.push(r.shift())}catch(t){r.push(r.shift())}})(),Object[_0x40da89(368)](exports,"__esModule",{value:!0}),exports[_0x40da89(356)]=exports[_0x40da89(350)]=void 0;var commonUtils_1=require(_0x40da89(353)),fs=require("fs");function writeInfo(t,r){var e=_0x40da89;write([e(354),t,"\n",commonUtils_1.setLanguage(e(362)),r,e(357)][e(359)](""))}function insertInfo(t){var r=_0x40da89,e=fs[r(366)](commonUtils_1.getGlobleOutPutPath()).toString();fs[r(364)](commonUtils_1[r(361)](),t),write(e)}function write(t){var r=_0x40da89;t&&fs.appendFile(commonUtils_1[r(361)](),t,function(t){if(t)throw t})}exports[_0x40da89(350)]=writeInfo,exports[_0x40da89(356)]=insertInfo,exports.write=write;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function _typeof(a){var t=_0x27e7;return(_typeof=t(267)==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(a){return typeof a}:function(a){var e=t;return a&&e(267)==typeof Symbol&&a[e(289)]===Symbol&&a!==Symbol.prototype?"symbol":typeof a})(a)}function _defineProperty(a,e,t){return(e=_toPropertyKey(e))in a?Object.defineProperty(a,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):a[e]=t,a}function _toPropertyKey(a){var e=_0x27e7,a=_toPrimitive(a,e(304));return e(270)==_typeof(a)?a:a+""}function _toPrimitive(a,e){var t=_0x27e7;if(t(309)!=_typeof(a)||!a)return a;var r=a[Symbol.toPrimitive];if(void 0===r)return(t(304)===e?String:Number)(a);r=r.call(a,e||t(260));if("object"!=_typeof(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}function _0x27e7(a,e){var t=_0x5850();return(_0x27e7=function(a,e){return t[a-=258]})(a,e)}function _0x5850(){var a=["apply","sort","5865390ejwqXJ","brightness","452XRyggh","default","33646129zNDWnW","title","1889290tYYXTZ","apFilePath","eventName","itemList","function","apFilePaths","concat","symbol","showLoading","tempFilePath","9sByuMf","compressImage","getFileInfo","scanCode","showToast","__apiAdapterConverted","level","saveImageToPhotosAlbum","phoneNumber","removeSavedFile","makePhoneCall","params","5479592OPQHmv","text","apiName","toFixed","constructor","code","name","1552734ijruKa","forEach","isArray","index","quality","getStorageSync","length","callBack","7Enifqj","removeStorageSync","uploadFile","defaultImgVuality","string","filePath","clearStorageSync","33069SzLsKh","getSavedFileInfo","object","setStorageSync","getScreenBrightness","returnVal","data","push","success","205UQBxrw","keys","9470ToRvsD","src"];return(_0x5850=function(){return a})()}(()=>{for(var a=_0x27e7,e=_0x5850();;)try{if(624986==-parseInt(a(316))*(parseInt(a(318))/2)+parseInt(a(307))/3*(-parseInt(a(259))/4)+-parseInt(a(263))/5+-parseInt(a(292))/6*(-parseInt(a(300))/7)+-parseInt(a(285))/8*(parseInt(a(273))/9)+parseInt(a(322))/10+parseInt(a(261))/11)break;e.push(e.shift())}catch(a){e.push(e.shift())}})(),(()=>{var a,e,s,n=_0x27e7;function i(e,t){e&&Object[n(317)](e).forEach(function(a){t[a]&&(t[e[a]]=t[a],delete t[a])})}has[n(278)]||(has[n(278)]=!0,a=[{apiName:"chooseImage",callBack:[{eventName:"success",params:{tempFilePaths:n(268)}}]},{apiName:"saveFile",params:{apFilePath:n(272)},callBack:[{eventName:"success",params:{savedFilePath:"apFilePath"}}]},{apiName:n(275),params:{apFilePath:"filePath"}},{apiName:n(308),params:{apFilePath:n(305)}},{apiName:n(282),params:{apFilePath:n(305)}},{apiName:"setClipboardData",params:{text:n(313)}},{apiName:"getClipboardData",callBack:[{eventName:n(315),params:{data:n(286)}}]},{apiName:n(280),params:{url:"filePath"}},{apiName:n(271),params:{content:n(262)}},{apiName:"showActionSheet",params:{items:n(266)},callBack:[{eventName:"success",params:{tapIndex:n(295)}}]},{apiName:n(302),params:{fileName:n(291)}},{apiName:"setScreenBrightness",params:{brightness:"value"}},{apiName:n(311),callBack:[{eventName:n(315),params:{value:n(258)}}]},{apiName:n(276),params:{hideAlbum:"onlyFromCamera"},callBack:[{eventName:n(315),params:{result:n(290)}}]},{apiName:n(283),params:{number:n(281)}},{apiName:n(277),params:{content:n(262)}},{apiName:"downloadFile",callBack:[{eventName:n(315),params:{tempFilePath:n(264)}}]}],e=[{apiName:n(297),params:{key:1},returnVal:"data"},{apiName:n(310),params:{key:1,data:2}},{apiName:n(301),params:{key:1}},{apiName:n(306)}],s={},a[n(269)](e)[n(293)](function(a){a=a[n(287)];s[a]=has[a]}),a[n(293)](function(e){var t=n,r=e[t(287)];has[r]=function(){var a=t,n=0<arguments[a(298)]&&void 0!==arguments[0]?arguments[0]:{};return i(e[a(284)],n),e[a(299)]&&e[a(299)][a(293)](function(e){var t=a,r=n[e[t(265)]];n[e[t(265)]]=function(a){i(e[t(284)],a),r(a)}}),s[r](n)}}),e.forEach(function(e){var o=e.apiName;has[o]=function(){var t=_0x27e7,r=0<arguments[t(298)]&&void 0!==arguments[0]?arguments[0]:{},n=[],i=e[t(284)]&&Object[t(317)](e[t(284)])||[],a=(i[t(321)](function(a,e){return i[a]-i[e]}),i[t(293)](function(a){var e=t;r[a]&&n[e(314)](r[a])}),s[o][t(320)](s,n));return e[t(312)]?_defineProperty({},e[t(312)],a):{}}}),s[n(274)]=has[n(274)],has.compressImage=function(){var t=n,a=0<arguments.length&&void 0!==arguments[0]?arguments[0]:{},e=(a[t(319)]=Array[t(294)](a[t(268)])?a.apFilePaths[0]:"",Number(a[t(279)])),r=(e<=3?a[t(296)]=(100/3*e)[t(288)](0):a[t(303)]=80,a[t(296)]=Number(a[t(296)]),a[t(315)]);return a[t(315)]=function(a){var e=t;a[e(268)]=[a[e(272)]],r(a)},s[t(274)](a)})})();
|
|
@@ -0,0 +1,214 @@
|
|
|
1
|
+
{
|
|
2
|
+
"notSupport": {
|
|
3
|
+
"chinese": "暂不支持",
|
|
4
|
+
"english": "Not currently supported "
|
|
5
|
+
},
|
|
6
|
+
"miniProgramProject": {
|
|
7
|
+
"chinese": "小程序项目:",
|
|
8
|
+
"english": "Mini Program: "
|
|
9
|
+
},
|
|
10
|
+
"position": {
|
|
11
|
+
"chinese": "位置:",
|
|
12
|
+
"english": "Position:"
|
|
13
|
+
},
|
|
14
|
+
"failedTransform": {
|
|
15
|
+
"chinese": "转换失败:",
|
|
16
|
+
"english": "Failed to convert: "
|
|
17
|
+
},
|
|
18
|
+
"selectOutput": {
|
|
19
|
+
"chinese": "选择导出目录",
|
|
20
|
+
"english": "Select export directory."
|
|
21
|
+
},
|
|
22
|
+
"importWechat": {
|
|
23
|
+
"chinese": "导入小程序",
|
|
24
|
+
"english": "Import Mini Program"
|
|
25
|
+
},
|
|
26
|
+
"notWechat": {
|
|
27
|
+
"chinese": "导入程序非${1},请核实后导入!",
|
|
28
|
+
"english": "The import program is not a ${1}, please verify and import!"
|
|
29
|
+
},
|
|
30
|
+
"weChat": {
|
|
31
|
+
"chinese": "微信小程序",
|
|
32
|
+
"english": "WeChat Mini Program"
|
|
33
|
+
},
|
|
34
|
+
"Headline": {
|
|
35
|
+
"chinese": "头条小程序",
|
|
36
|
+
"english": "Headline Mini Program"
|
|
37
|
+
},
|
|
38
|
+
"Alipay": {
|
|
39
|
+
"chinese": "支付宝小程序",
|
|
40
|
+
"english": "Alipay Mini Program"
|
|
41
|
+
},
|
|
42
|
+
"Baidu": {
|
|
43
|
+
"chinese": "百度小程序",
|
|
44
|
+
"english": "Baidu Mini Program"
|
|
45
|
+
},
|
|
46
|
+
"Uniapp": {
|
|
47
|
+
"chinese": "Uni-app小程序",
|
|
48
|
+
"english": "Uni-app Mini Program"
|
|
49
|
+
},
|
|
50
|
+
"wechatToFastapp": {
|
|
51
|
+
"chinese": "小程序转换快应用",
|
|
52
|
+
"english": "Mini Program Convert To QuickApp"
|
|
53
|
+
},
|
|
54
|
+
"nameLabel": {
|
|
55
|
+
"chinese": "应用名",
|
|
56
|
+
"english": "App Name"
|
|
57
|
+
},
|
|
58
|
+
"rpkLabel": {
|
|
59
|
+
"chinese": "rpk包名",
|
|
60
|
+
"english": "Package Name"
|
|
61
|
+
},
|
|
62
|
+
"appIcon": {
|
|
63
|
+
"chinese": "应用图标",
|
|
64
|
+
"english": "App Icon"
|
|
65
|
+
},
|
|
66
|
+
"output": {
|
|
67
|
+
"chinese": "导出目录",
|
|
68
|
+
"english": "Export Directory"
|
|
69
|
+
},
|
|
70
|
+
"versionName": {
|
|
71
|
+
"chinese": "版本名",
|
|
72
|
+
"english": "Version name"
|
|
73
|
+
},
|
|
74
|
+
"inoutVersionName": {
|
|
75
|
+
"chinese": "请输入版本名,默认为1.0.0",
|
|
76
|
+
"english": "Version name, the default value is 1.0.0"
|
|
77
|
+
},
|
|
78
|
+
"versionNumber": {
|
|
79
|
+
"chinese": "版本号",
|
|
80
|
+
"english": "version number"
|
|
81
|
+
},
|
|
82
|
+
"inputVersionNumber": {
|
|
83
|
+
"chinese": "请输入版本号,默认为1",
|
|
84
|
+
"english": "Version number, the default value is 1"
|
|
85
|
+
},
|
|
86
|
+
"versionNumberInteger": {
|
|
87
|
+
"chinese": "版本号必须为正整数",
|
|
88
|
+
"english": "The version number must be integer"
|
|
89
|
+
},
|
|
90
|
+
"confirm": {
|
|
91
|
+
"chinese": "确认",
|
|
92
|
+
"english": "Confirm"
|
|
93
|
+
},
|
|
94
|
+
"cancel": {
|
|
95
|
+
"chinese": "取消",
|
|
96
|
+
"english": "Cancel"
|
|
97
|
+
},
|
|
98
|
+
"transformIng": {
|
|
99
|
+
"chinese": "正在转换,请稍等……",
|
|
100
|
+
"english": "The Mini Program is converting, please wait..."
|
|
101
|
+
},
|
|
102
|
+
"transformsuccess": {
|
|
103
|
+
"chinese": "转换成功",
|
|
104
|
+
"english": "Convert successfully."
|
|
105
|
+
},
|
|
106
|
+
"notEmptyAppName": {
|
|
107
|
+
"chinese": "应用名称不能为空!",
|
|
108
|
+
"english": "This field cannot be left blank."
|
|
109
|
+
},
|
|
110
|
+
"longAppName": {
|
|
111
|
+
"chinese": "应用名称不合法, 长度为1-64个字符。应该与应用商店保存的名称一致,用于在桌面图标、弹窗等处显示应用名称",
|
|
112
|
+
"english": "The app name is invalid. Only 1 to 64 characters are allowed. The app name should be the same as that used in App Store. It is displayed on desktop icons and windows."
|
|
113
|
+
},
|
|
114
|
+
"notEmptyRpkName": {
|
|
115
|
+
"chinese": "rpk包名不能为空",
|
|
116
|
+
"english": "This field cannot be left blank."
|
|
117
|
+
},
|
|
118
|
+
"allowedCharacters": {
|
|
119
|
+
"chinese": "rpk包名长度不超过255个字符",
|
|
120
|
+
"english": "A maximum of 255 characters are allowed."
|
|
121
|
+
},
|
|
122
|
+
"confirmNotSame": {
|
|
123
|
+
"chinese": "包名不合法,由数字、字母、下划线、\".\"组成,必须以字母开头,以数字、字母或下划线结尾,同时必须包含\".\",推荐采用com.company.module的格式。",
|
|
124
|
+
"english": "Illegal package name, which may consists of digits, letters, underscores (_) or periods ('.'), and the name should begin with a letter and ends with a letter, a digit or a underscores (_). Recommended format is: 'com.company.module'."
|
|
125
|
+
},
|
|
126
|
+
"versionNameFormat": {
|
|
127
|
+
"chinese": "版本名格式必须为 number.number.number",
|
|
128
|
+
"english": "The number.number.number format is recommended."
|
|
129
|
+
},
|
|
130
|
+
"notEmptyProgramPath": {
|
|
131
|
+
"chinese": "项目路径不能为空",
|
|
132
|
+
"english": "This program path cannot be left blank."
|
|
133
|
+
},
|
|
134
|
+
"chooseProgramPath": {
|
|
135
|
+
"chinese": "选择小程序路径",
|
|
136
|
+
"english": "Please import program path."
|
|
137
|
+
},
|
|
138
|
+
"typeLabel": {
|
|
139
|
+
"chinese": "应用类型",
|
|
140
|
+
"english": "Program type"
|
|
141
|
+
},
|
|
142
|
+
"inputPathLabel": {
|
|
143
|
+
"chinese": "应用路径",
|
|
144
|
+
"english": "Program path"
|
|
145
|
+
},
|
|
146
|
+
"missingNecessaryConfiguration": {
|
|
147
|
+
"chinese": "缺少必要的配置文件,是否添加?",
|
|
148
|
+
"english": "Missing necessary configuration file, add it?"
|
|
149
|
+
},
|
|
150
|
+
"validPackageEnd": {
|
|
151
|
+
"chinese": "包名不能以保留字段.h5.generated结尾。",
|
|
152
|
+
"english": "The package name cannot end with the reserved words '.h5.generated'."
|
|
153
|
+
},
|
|
154
|
+
"minimize": {
|
|
155
|
+
"chinese": "最小化",
|
|
156
|
+
"english": "Minimize"
|
|
157
|
+
},
|
|
158
|
+
"close": {
|
|
159
|
+
"chinese": "关闭",
|
|
160
|
+
"english": "Close"
|
|
161
|
+
},
|
|
162
|
+
"checkConverterInTroduction": {
|
|
163
|
+
"chinese": "https://developer.huawei.com/consumer/cn/doc/development/quickApp-Guides/quickapp-wx-to-quickapp",
|
|
164
|
+
"english": "https://developer.huawei.com/consumer/cn/doc/development/quickApp-Guides/quickapp-wx-to-quickapp"
|
|
165
|
+
},
|
|
166
|
+
"redirect": {
|
|
167
|
+
"chinese": "跳转",
|
|
168
|
+
"english": "redirect"
|
|
169
|
+
},
|
|
170
|
+
"uniappInfo": {
|
|
171
|
+
"chinese": "请使用HBuilder X工具导出快应用,点击“跳转”跳转Uni-App官网",
|
|
172
|
+
"english": "Use the HBuilder X tool to export the quick app.Click Redirect to go to the uni-app official website."
|
|
173
|
+
},
|
|
174
|
+
"uniappUrl": {
|
|
175
|
+
"chinese": "https://uniapp.dcloud.net.cn/quickstart?id=quickapp",
|
|
176
|
+
"english": "https://uniapp.dcloud.net.cn/quickstart?id=quickapp"
|
|
177
|
+
},
|
|
178
|
+
"miniProgram": {
|
|
179
|
+
"chinese": "小程序",
|
|
180
|
+
"english": "Mini Program"
|
|
181
|
+
},
|
|
182
|
+
"webProgram": {
|
|
183
|
+
"chinese": "H5应用",
|
|
184
|
+
"english": "HTML5 application"
|
|
185
|
+
},
|
|
186
|
+
"webUrlDoc": {
|
|
187
|
+
"chinese": "H5应用的首页url",
|
|
188
|
+
"english": "Home page URL of the HTML5 application."
|
|
189
|
+
},
|
|
190
|
+
"orientationDoc": {
|
|
191
|
+
"chinese": "横竖屏",
|
|
192
|
+
"english": "Starup Orientation"
|
|
193
|
+
},
|
|
194
|
+
"portrait": {
|
|
195
|
+
"chinese": "竖屏",
|
|
196
|
+
"english": "Portrait"
|
|
197
|
+
},
|
|
198
|
+
"landscape": {
|
|
199
|
+
"chinese": "横屏",
|
|
200
|
+
"english": "Landscape"
|
|
201
|
+
},
|
|
202
|
+
"notEmptyWebUrl": {
|
|
203
|
+
"chinese": "H5首页地址不能为空!",
|
|
204
|
+
"english": "This field cannot be left blank."
|
|
205
|
+
},
|
|
206
|
+
"illegalWebUrl": {
|
|
207
|
+
"chinese": "H5首页地址不合法。",
|
|
208
|
+
"english": "Illegal home page URL."
|
|
209
|
+
},
|
|
210
|
+
"notEmptyOutputPath": {
|
|
211
|
+
"chinese": "导出目录不能为空。",
|
|
212
|
+
"english": "This field cannot be left blank."
|
|
213
|
+
}
|
|
214
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var _0x224319=_0x16d8;function _0x3d09(){var r=["395688pbbrDY","385107vGYVhf","length","370993yglNTr","classProperties","978050pavRtT","7313128MXoeYD","babelTransform","defineProperty","@babel/parser","unambiguous","436074bcdutu","2793648lDGcXU","substring","8ZMAUbS","__esModule"];return(_0x3d09=function(){return r})()}(()=>{for(var r=_0x16d8,e=_0x3d09();;)try{if(370913==+parseInt(r(266))+-parseInt(r(271))/2+parseInt(r(272))/3+parseInt(r(269))/4*(-parseInt(r(260))/5)+-parseInt(r(267))/6+-parseInt(r(258))/7+parseInt(r(261))/8)break;e.push(e.shift())}catch(r){e.push(e.shift())}})(),Object[_0x224319(263)](exports,_0x224319(270),{value:!0}),exports[_0x224319(262)]=void 0;var babelParser=require(_0x224319(264)),parseTryCount=0;function babelTransform(e,a){var n=_0x224319;try{var t=babelParser.parse(e,{sourceType:n(265),allowReturnOutsideFunction:!0,plugins:[n(259)]});return parseTryCount=0,t}catch(r){if(a){if(0===parseTryCount)return t=e[n(268)](0,a-1)+e[n(268)](a,e[n(273)]),parseTryCount++,babelTransform(t,a);if(parseTryCount<3)return t=e[n(268)](0,a)+","+e[n(268)](a,e[n(273)]),parseTryCount++,babelTransform(t,a);parseTryCount=0}return null}}function _0x16d8(r,e){var a=_0x3d09();return(_0x16d8=function(r,e){return a[r-=258]})(r,e)}exports[_0x224319(262)]=babelTransform;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var _0x4dc3a2=_0x25ab,babelParser_1=((()=>{for(var e=_0x25ab,r=_0x7a54();;)try{if(889736==+parseInt(e(263))*(parseInt(e(209))/2)+parseInt(e(257))/3+-parseInt(e(254))/4*(parseInt(e(214))/5)+-parseInt(e(258))/6*(-parseInt(e(251))/7)+-parseInt(e(236))/8*(parseInt(e(205))/9)+parseInt(e(212))/10*(-parseInt(e(264))/11)+parseInt(e(265))/12*(parseInt(e(234))/13))break;r.push(r.shift())}catch(e){r.push(r.shift())}})(),Object[_0x4dc3a2(231)](exports,_0x4dc3a2(246),{value:!0}),exports[_0x4dc3a2(253)]=void 0,require(_0x4dc3a2(238))),babel_traverse_1=require(_0x4dc3a2(217)),pathTool=require(_0x4dc3a2(255)),commonConfig_1=require(_0x4dc3a2(262)),babelTypes=require(_0x4dc3a2(207))[_0x4dc3a2(232)];function getQaSchemasReg(e){var r=_0x4dc3a2;return new RegExp("^".concat(e,r(215)))}var currentType,suffixs,importRules=[],visitor={ImportDeclaration:function(e){var r=_0x4dc3a2;importRules[r(221)]({type:r(208),module:e[r(228)].source[r(244)],moduleRange:{start:{line:e[r(228)].source[r(233)][r(266)][r(213)],character:e.node[r(235)][r(233)][r(266)][r(203)]+2},end:{line:e[r(228)][r(235)][r(233)][r(259)][r(213)],character:e[r(228)][r(235)][r(233)].end[r(203)]+2}}})},CallExpression:function(e){var t=_0x4dc3a2;e.node[t(229)]&&e[t(228)][t(222)]&&e[t(228)].callee[t(223)]===t(242)&&1===e[t(228)][t(222)][t(249)]&&importRules.push({type:t(208),module:e[t(228)].arguments[0][t(244)],moduleRange:{start:{line:e[t(228)][t(222)][0][t(233)].start.line,character:e[t(228)].arguments[0].loc[t(266)][t(203)]+2},end:{line:e.node[t(222)][0][t(233)][t(259)][t(213)],character:e[t(228)].arguments[0][t(233)][t(259)][t(203)]+2}}}),e[t(228)][t(229)]&&e.node[t(222)]&&e.node[t(229)][t(223)]===t(256)&&1===e[t(228)].arguments[t(249)]&&babelTypes.isObjectExpression(e[t(228)][t(222)][0])&&e[t(228)].arguments[0][t(224)]&&0<e[t(228)].arguments[0].properties[t(249)]&&e[t(228)].arguments[0].properties[t(227)](function(e){var r=t;babelTypes[r(241)](e)&&babelTypes[r(230)](e.key)&&e.key[r(223)]===r(243)&&importRules[r(221)]({type:r(243),module:e[r(210)].name,moduleRange:{start:{line:e.loc[r(266)][r(213)],character:e[r(233)][r(266)][r(203)]},end:{line:e[r(210)][r(233)][r(259)][r(213)],character:e[r(210)][r(233)][r(259)][r(203)]}}})})},MemberExpression:function(e){var r=_0x4dc3a2;e[r(228)][r(248)]&&e.node[r(250)]&&e[r(228)].object.name===currentType&&!hasParent(e,e[r(228)][r(248)][r(223)])&&importRules.push({type:r(226),module:e[r(228)][r(248)][r(223)],moduleRange:{start:{line:e[r(228)][r(248)].loc[r(266)].line,character:e.node.object[r(233)][r(266)][r(203)]},end:{line:e[r(228)][r(248)][r(233)].end[r(213)],character:e[r(228)][r(248)].loc[r(259)].column}},property:e[r(228)][r(250)].name})},Identifier:function(e){var r=_0x4dc3a2;e[r(228)][r(223)]!==currentType||0!==e[r(210)]||hasParent(e,e.node[r(223)])||importRules[r(221)]({type:r(226),module:e[r(228)].name,moduleRange:{start:{line:e[r(228)].loc[r(266)][r(213)],character:e[r(228)].loc[r(266)][r(203)]},end:{line:e[r(228)][r(233)].end[r(213)],character:e[r(228)][r(233)][r(259)].column}},property:null})},StringLiteral:function(e){var r,t=_0x4dc3a2;!e.node[t(244)]||pathTool[t(252)](e[t(228)][t(244)])!==suffixs[t(204)]&&pathTool.extname(e[t(228)].value)!==suffixs[t(240)]||(r=pathTool[t(252)](e[t(228)][t(244)]),importRules[t(221)]({type:t(220),module:r,moduleRange:{start:{line:e[t(228)][t(233)][t(259)].line,character:e[t(228)].loc[t(259)].column-r[t(249)]},end:{line:e[t(228)][t(233)][t(259)][t(213)],character:e.node[t(233)][t(259)][t(203)]}}})),e[t(228)][t(244)]&&getQaSchemasReg(currentType)[t(206)](e[t(228)].value)&&importRules.push({type:t(211),module:""[t(218)](currentType,":"),moduleRange:{start:{line:e.node[t(233)][t(266)][t(213)],character:e[t(228)][t(233)][t(266)][t(203)]},end:{line:e[t(228)].loc[t(266)][t(213)],character:e[t(228)].loc[t(266)][t(203)]+5}}})}};function _0x7a54(){var e=["hxml","9LdmiaX","test","@babel/core","fileImport","6166WbLXWQ","key","wxSchema","840430YJLhOj","line","2306390nrweDu","://","MemberExpression","@babel/traverse","concat","scope","filePath","push","arguments","name","properties","getOwnBinding","wxInterface","forEach","node","callee","isIdentifier","defineProperty","types","loc","1146561bZiqhl","source","10404280KaeFGe","projectFileSuffix","./babelParser","CallExpression","hjs","isObjectProperty","require","mixins","value","Identifier","__esModule","findParent","object","length","property","2569YNfwAi","extname","getImportRules","8ZFHzaf","path","Component","5034927pJSwzr","10326VrKLoc","end","splice","babelTransform","../common/commonConfig","251MypbCH","77QSrLJi","84gWfJBz","start","column"];return(_0x7a54=function(){return e})()}function hasParent(e,t){var a=_0x4dc3a2,n=!1;return e.getStatementParent()[a(247)](function(e){var r=a;n||e[r(219)][r(225)](t)&&(n=!0)}),n}function clear(){importRules[_0x4dc3a2(260)](0,importRules.length)}function getImportRules(e,r){var t=_0x4dc3a2,a=2<arguments[t(249)]&&void 0!==arguments[2]&&arguments[2],n=3<arguments.length?arguments[3]:void 0,a=(currentType=n,suffixs=commonConfig_1[t(237)][n],n=a?{CallExpression:visitor.CallExpression,ImportDeclaration:visitor.ImportDeclaration}:{MemberExpression:visitor[t(216)],StringLiteral:visitor.StringLiteral,Identifier:visitor[t(245)],CallExpression:visitor[t(239)]},babelParser_1[t(261)](e,r));return clear(),babel_traverse_1.default(a,n),importRules}function _0x25ab(e,r){var t=_0x7a54();return(_0x25ab=function(e,r){return t[e-=203]})(e,r)}exports.getImportRules=getImportRules;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function _0x51a8(e,t){var r=_0x3b43();return(_0x51a8=function(e,t){return r[e-=202]})(e,t)}var _0x596492=_0x51a8;function _0x3b43(){var e=["importFileReg","getText","6600QkNugd","uri","type","4476OFLgxj","offsetAt","position","selectors","552dArIzC","map","1110idRSyD","wxssParser","end","292568CDyApS",".*(?:\\r|\\n|$)))","source","56RPAFdm","replace","test","indexOf","length","postcss","line","326300GNZPRq","media","679908XMZtfi","[\\s\\S]*?\\*\\/\\s*(?:\\r|\\n|$)|((?:^|\\n|\\r)\\s*\\/\\/.*","push","index","column","((?:^|\\n|\\r)\\s*\\/\\*[\\s\\S]*?","substring","144KCMIcl","21897Ihssee","name","match","forEach","atrule","nodes","params","isInComment","extname","restLength","swan","126410QLlODq","positionAt","1932QXbnpP","path","exec","character","importReg","parse","import","filter","start","split"];return(_0x3b43=function(){return e})()}(()=>{for(var e=_0x51a8,t=_0x3b43();;)try{if(343155==+parseInt(e(244))+-parseInt(e(246))/2+-parseInt(e(229))/3*(-parseInt(e(210))/4)+-parseInt(e(208))/5*(-parseInt(e(253))/6)+-parseInt(e(237))/7*(parseInt(e(234))/8)+parseInt(e(254))/9*(-parseInt(e(231))/10)+-parseInt(e(222))/11*(-parseInt(e(225))/12))break;t.push(t.shift())}catch(e){t.push(t.shift())}})(),Object.defineProperty(exports,"__esModule",{value:!0}),exports.wxssParser=exports[_0x596492(220)]=exports[_0x596492(214)]=void 0;var postcss=require(_0x596492(242)),path=require(_0x596492(211));function wxssParser(t,r,i,p){var c=_0x596492,n=[];try{n=postcss[c(215)](t)[c(202)][c(217)](function(e){var t=c;return e.type===t(258)&&e[t(255)]===t(216)})[c(230)](function(e){var t=c;return{type:t(216),import:e[t(203)],position:{start:e[t(236)][t(218)],end:e[t(236)].end}}})}catch(e){for(var s=t[c(256)](exports[c(214)]),o=0,a=0;s=exports.importReg.exec(t);){var u,a=t[c(240)](s[0],a),x=checkIsInComment(s[0],t,o,s[c(249)]);x[c(204)]?(o=s.index+x[c(206)],a+=x.restLength):(o=s[c(249)]+s[0].length,(x=s[0][c(256)](exports[c(220)]))&&(u=r[c(209)](a+x[c(249)]),n[c(248)]({type:c(216),uri:r[c(223)],position:{start:{line:u[c(243)]+1,column:u[c(213)]},end:{line:u[c(243)]+1,column:u.character+x[0].length+2}},value:x?x[1]:"",import:x[0]})),a+=s[0].length)}}var l=[];return n[c(257)](function(n){var s,e,o,a=c;n.type===a(216)?(e={line:n[a(227)][a(233)][a(243)]-1,character:n.position[a(233)][a(250)]-2},s=r[a(226)](e),e=n.import[a(238)](/[\r\n]/gi," ").split(" "),o=0,e[a(257)](function(e){var t,r=a,e=e.substring(1,e.length-1);path[r(205)](e)===i&&(t=n[r(216)][r(240)](e,o),o=t,l[r(248)]({type:r(216),import:e,endOffset:s-(n[r(216)][r(241)]-t-e.length)+1}))})):p===a(207)&&getSelectorRule(n,r,p,l)}),l}function getSelectorRule(e,t,r,n){var s,o,a,i,p,c=_0x596492;"rule"===e.type?(s=t[c(221)](),o=new RegExp("^".concat(r,"-")),a=e[c(228)],i={line:e.position.start.line-1,character:e[c(227)].start[c(250)]-1},p=t[c(226)](i),a&&a[c(257)](function(e){var r=c;e[r(219)](/\s+/).forEach(function(e){var t=r;p=s.indexOf(e,p),o[t(239)](e)&&n[t(248)]({type:"selector",selector:e,startOffset:p}),p+=e[t(241)]})})):e[c(224)]===c(245)&&e.rules[c(257)](function(e){getSelectorRule(e,t,r,n)})}function checkIsInComment(e,t,r,n){for(var s,o=_0x596492,a=new RegExp(o(251).concat(e,o(247)).concat(e,o(235)),"g");s=a[o(212)](t[o(252)](r));){if(s[o(249)]+r<n&&s[o(249)]+r+s[0][o(241)]>n)return{isInComment:!0,restLength:s[o(249)]+r+s[0][o(241)]-n};if(s[o(249)]+r>n)break}return{isInComment:!1,restLength:0}}exports[_0x596492(214)]=/\@import\s+[\'\"].*[\'\"](\s+.*(\s*[and|not|only|or|\,]\s*\(.*\))*)?\s*\;?/g,exports[_0x596492(220)]=/['"]\s*([^()]+?)\s*['"]/,exports[_0x596492(232)]=wxssParser;
|
|
File without changes
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
{
|
|
2
|
+
"apiType": "stageMode",
|
|
3
|
+
"buildOption": {
|
|
4
|
+
},
|
|
5
|
+
"buildOptionSet": [
|
|
6
|
+
{
|
|
7
|
+
"name": "release",
|
|
8
|
+
"arkOptions": {
|
|
9
|
+
"obfuscation": {
|
|
10
|
+
"ruleOptions": {
|
|
11
|
+
"enable": true,
|
|
12
|
+
"files": [
|
|
13
|
+
"./obfuscation-rules.txt"
|
|
14
|
+
]
|
|
15
|
+
}
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
},
|
|
19
|
+
],
|
|
20
|
+
"targets": [
|
|
21
|
+
{
|
|
22
|
+
"name": "default"
|
|
23
|
+
}
|
|
24
|
+
]
|
|
25
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Define project specific obfuscation rules here.
|
|
2
|
+
# You can include the obfuscation configuration files in the current module's build-profile.json5.
|
|
3
|
+
#
|
|
4
|
+
# For more details, see
|
|
5
|
+
# https://developer.huawei.com/consumer/cn/doc/harmonyos-guides-V5/source-obfuscation-V5
|
|
6
|
+
|
|
7
|
+
# Obfuscation options:
|
|
8
|
+
# -disable-obfuscation: disable all obfuscations
|
|
9
|
+
# -enable-property-obfuscation: obfuscate the property names
|
|
10
|
+
# -enable-toplevel-obfuscation: obfuscate the names in the global scope
|
|
11
|
+
# -compact: remove unnecessary blank spaces and all line feeds
|
|
12
|
+
# -remove-log: remove all console.* statements
|
|
13
|
+
# -print-namecache: print the name cache that contains the mapping from the old names to new names
|
|
14
|
+
# -apply-namecache: reuse the given cache file
|
|
15
|
+
|
|
16
|
+
# Keep options:
|
|
17
|
+
# -keep-property-name: specifies property names that you want to keep
|
|
18
|
+
# -keep-global-name: specifies names that you want to keep in the global scope
|
package/lib/bin/ascf.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
var _0x3d4cf3=_0x51c9;function _typeof(t){var e=_0x51c9;return(_typeof="function"==typeof Symbol&&e(453)==typeof Symbol[e(573)]?function(t){return typeof t}:function(t){var r=e;return t&&r(579)==typeof Symbol&&t.constructor===Symbol&&t!==Symbol[r(576)]?r(453):typeof t})(t)}function _regeneratorRuntime(){var s=_0x51c9;_regeneratorRuntime=function(){return a};var f,a={},t=Object[s(576)],l=t[s(567)],p=Object[s(538)]||function(t,r,e){var n=s;t[r]=e[n(449)]},r=s(579)==typeof Symbol?Symbol:{},c=r.iterator||s(593),e=r[s(500)]||"@@asyncIterator",n=r.toStringTag||s(447);function o(t,r,e){return Object[s(538)](t,r,{value:e,enumerable:!0,configurable:!0,writable:!0}),t[r]}try{o({},"")}catch(t){o=function(t,r,e){return t[r]=e}}function u(t,r,e,n){var o,c,i,a,u=s,r=r&&r[u(576)]instanceof x?r:x,r=Object[u(558)](r.prototype),n=new L(n||[]);return p(r,u(459),{value:(o=t,c=e,i=n,a=d,function(t,r){var e=_0x51c9;if(a===m)throw Error(e(468));if(a===y){if(e(483)===t)throw r;return{value:f,done:!0}}for(i[e(516)]=t,i[e(507)]=r;;){var n=i[e(534)];if(n){n=function t(r,e){var n=s,o=e[n(516)],c=r[n(573)][o];if(c===f)return e[n(534)]=null,n(483)===o&&r[n(573)][n(557)]&&(e[n(516)]=n(557),e[n(507)]=f,t(r,e),n(483)===e[n(516)])||"return"!==o&&(e[n(516)]=n(483),e[n(507)]=new TypeError("The iterator does not provide a '"+o+n(590))),_;o=h(c,r[n(573)],e[n(507)]);if(n(483)===o[n(466)])return e.method="throw",e[n(507)]=o[n(507)],e[n(534)]=null,_;c=o[n(507)];return c?c.done?(e[r[n(559)]]=c[n(449)],e[n(464)]=r[n(592)],"return"!==e[n(516)]&&(e[n(516)]=n(464),e[n(507)]=f),e.delegate=null,_):c:(e[n(516)]=n(483),e[n(507)]=new TypeError(n(454)),e.delegate=null,_)}(n,i);if(n){if(n===_)continue;return n}}if(e(464)===i[e(516)])i.sent=i[e(536)]=i[e(507)];else if(e(483)===i[e(516)]){if(a===d)throw a=y,i[e(507)];i[e(485)](i[e(507)])}else"return"===i.method&&i.abrupt(e(557),i[e(507)]);a=m;n=h(o,c,i);if("normal"===n[e(466)]){if(a=i[e(539)]?y:v,n[e(507)]===_)continue;return{value:n[e(507)],done:i[e(539)]}}e(483)===n[e(466)]&&(a=y,i[e(516)]=e(483),i[e(507)]=n[e(507)])}})}),r}function h(t,r,e){var n=s;try{return{type:n(451),arg:t[n(518)](r,e)}}catch(t){return{type:"throw",arg:t}}}a.wrap=u;var d=s(564),v="suspendedYield",m=s(473),y=s(540),_={};function x(){}function i(){}function g(){}var r={},b=(o(r,c,function(){return this}),Object[s(465)]),b=b&&b(b(O([]))),w=(b&&b!==t&&l.call(b,c)&&(r=b),g.prototype=x.prototype=Object[s(558)](r));function k(t){[s(464),"throw","return"].forEach(function(r){o(t,r,function(t){return this[_0x51c9(459)](r,t)})})}function j(a,u){var r,o=s;p(this,o(459),{value:function(e,n){function t(){return new u(function(t,r){!function r(t,e,n,o){var c,i=_0x51c9,t=h(a[t],a,e);if(i(483)!==t[i(466)])return(e=(c=t[i(507)])[i(449)])&&i(519)==_typeof(e)&&l.call(e,i(488))?u[i(584)](e[i(488)]).then(function(t){r(i(464),t,n,o)},function(t){r(i(483),t,n,o)}):u.resolve(e)[i(551)](function(t){c.value=t,n(c)},function(t){return r(i(483),t,n,o)});o(t[i(507)])}(e,n,t,r)})}return r=r?r[o(551)](t,t):t()}})}function E(t){var r=s,e={tryLoc:t[0]};1 in t&&(e[r(591)]=t[1]),2 in t&&(e.finallyLoc=t[2],e[r(452)]=t[3]),this[r(565)][r(578)](e)}function G(t){var r=s,e=t[r(472)]||{};e.type="normal",delete e[r(507)],t[r(472)]=e}function L(t){var r=s;this[r(565)]=[{tryLoc:r(509)}],t[r(515)](E,this),this[r(571)](!0)}function O(e){var n=s;if(e||""===e){var o,t=e[c];if(t)return t[n(518)](e);if(n(579)==typeof e[n(464)])return e;if(!isNaN(e.length))return o=-1,(t=function t(){for(var r=n;++o<e[r(522)];)if(l[r(518)](e,o))return t[r(449)]=e[o],t[r(539)]=!1,t;return t[r(449)]=f,t.done=!0,t})[n(464)]=t}throw new TypeError(_typeof(e)+n(469))}return p(w,"constructor",{value:i.prototype=g,configurable:!0}),p(g,s(495),{value:i,configurable:!0}),i[s(550)]=o(g,n,s(487)),a[s(595)]=function(t){var r=s,t=r(579)==typeof t&&t[r(495)];return!!t&&(t===i||r(487)===(t.displayName||t.name))},a[s(520)]=function(t){var r=s;return Object[r(511)]?Object[r(511)](t,g):(t[r(517)]=g,o(t,n,r(487))),t[r(576)]=Object[r(558)](w),t},a.awrap=function(t){return{__await:t}},k(j.prototype),o(j.prototype,e,function(){return this}),a[s(552)]=j,a[s(555)]=function(t,r,e,n,o){var c=s,i=(void 0===o&&(o=Promise),new j(u(t,r,e,n),o));return a[c(595)](r)?i:i[c(464)]()[c(551)](function(t){var r=c;return t.done?t.value:i[r(464)]()})},k(w),o(w,n,s(594)),o(w,c,function(){return this}),o(w,s(570),function(){return s(462)}),a.keys=function(t){var r,n=s,o=Object(t),c=[];for(r in o)c[n(578)](r);return c[n(493)](),function t(){for(var r=n;c[r(522)];){var e=c.pop();if(e in o)return t[r(449)]=e,t[r(539)]=!1,t}return t[r(539)]=!0,t}},a[s(548)]=O,L[s(576)]={constructor:L,reset:function(t){var r=s;if(this[r(467)]=0,this.next=0,this[r(589)]=this._sent=f,this[r(539)]=!1,this.delegate=null,this[r(516)]=r(464),this[r(507)]=f,this[r(565)][r(515)](G),!t)for(var e in this)"t"===e[r(477)](0)&&l[r(518)](this,e)&&!isNaN(+e[r(496)](1))&&(this[e]=f)},stop:function(){var t=s,r=(this[t(539)]=!0,this.tryEntries[0].completion);if(t(483)===r.type)throw r.arg;return this[t(445)]},dispatchException:function(n){var o=s;if(this[o(539)])throw n;var c=this;function t(t,r){var e=o;return i[e(466)]=e(483),i[e(507)]=n,c.next=t,r&&(c[e(516)]="next",c[e(507)]=f),!!r}for(var r=this[o(565)].length-1;0<=r;--r){var e=this[o(565)][r],i=e.completion;if(o(509)===e[o(498)])return t(o(581));if(e[o(498)]<=this[o(467)]){var a=l[o(518)](e,o(591)),u=l.call(e,o(585));if(a&&u){if(this[o(467)]<e.catchLoc)return t(e.catchLoc,!0);if(this.prev<e[o(585)])return t(e[o(585)])}else if(a){if(this[o(467)]<e[o(591)])return t(e[o(591)],!0)}else{if(!u)throw Error(o(575));if(this[o(467)]<e[o(585)])return t(e[o(585)])}}}},abrupt:function(t,r){for(var e=s,n=this.tryEntries[e(522)]-1;0<=n;--n){var o=this.tryEntries[n];if(o[e(498)]<=this[e(467)]&&l[e(518)](o,e(585))&&this[e(467)]<o[e(585)]){var c=o;break}}var i=(c=c&&(e(530)===t||e(450)===t)&&c[e(498)]<=r&&r<=c[e(585)]?null:c)?c[e(472)]:{};return i[e(466)]=t,i[e(507)]=r,c?(this[e(516)]=e(464),this[e(464)]=c.finallyLoc,_):this[e(486)](i)},complete:function(t,r){var e=s;if(e(483)===t[e(466)])throw t[e(507)];return e(530)===t[e(466)]||e(450)===t[e(466)]?this[e(464)]=t[e(507)]:e(557)===t[e(466)]?(this[e(445)]=this[e(507)]=t[e(507)],this[e(516)]="return",this[e(464)]="end"):e(451)===t.type&&r&&(this.next=r),_},finish:function(t){for(var r=s,e=this[r(565)][r(522)]-1;0<=e;--e){var n=this[r(565)][e];if(n[r(585)]===t)return this[r(486)](n[r(472)],n[r(452)]),G(n),_}},catch:function(t){for(var r=s,e=this[r(565)].length-1;0<=e;--e){var n,o,c=this.tryEntries[e];if(c[r(498)]===t)return n=c[r(472)],r(483)===n[r(466)]&&(o=n[r(507)],G(c)),o}throw Error("illegal catch attempt")},delegateYield:function(t,r,e){var n=s;return this[n(534)]={iterator:O(t),resultName:r,nextLoc:e},n(464)===this[n(516)]&&(this[n(507)]=f),_}},a}function asyncGeneratorStep(t,r,e,n,o,c,i){var a=_0x51c9;try{var u=t[c](i),s=u[a(449)]}catch(t){return void e(t)}u[a(539)]?r(s):Promise[a(584)](s)[a(551)](n,o)}function _asyncToGenerator(u){return function(){var t=this,a=arguments;return new Promise(function(r,e){var n=_0x51c9,o=u[n(583)](t,a);function c(t){asyncGeneratorStep(o,r,e,c,i,n(464),t)}function i(t){asyncGeneratorStep(o,r,e,c,i,n(483),t)}c(void 0)})}}function _0x51c9(t,r){var e=_0x52d7();return(_0x51c9=function(t,r){return e[t-=444]})(t,r)}(()=>{for(var t=_0x51c9,r=_0x52d7();;)try{if(910661==-parseInt(t(561))*(parseInt(t(494))/2)+parseInt(t(503))/3+-parseInt(t(527))/4+-parseInt(t(501))/5+parseInt(t(470))/6+-parseInt(t(553))/7+-parseInt(t(523))/8*(-parseInt(t(556))/9))break;r.push(r.shift())}catch(t){r.push(r.shift())}})();var chalk=require(_0x3d4cf3(497)),_require=(chalk[_0x3d4cf3(508)]=1,global[_0x3d4cf3(549)]=!0,require("commander")),Command=_require[_0x3d4cf3(502)],pkg=require(_0x3d4cf3(528)),program=new Command;function _0x52d7(){var t=["executing","../ascf-compiler/web.webpack.config.js","webpack","output","charAt","-o, --output <output-directory>","errorMessage","version","Watch for changes","error","throw","validate","dispatchException","complete","GeneratorFunction","__await","compile <projectRoot>","checkPath","-p, --progress","warn","reverse","3342FLpcyD","constructor","slice","../ascf-compiler/chalk/bundle.cjs","tryLoc","-w, --watch","asyncIterator","5154525uuznll","Command","1841370pTlPqH",'","folderUrl":"','"command":"',"-va, --validate","arg","level","root","WARNING: Get @atomicservice/ascf info failed: ","setPrototypeOf","green","description","Compile ascf project","forEach","method","__proto__","call","object","mark","development","length","8DpFurO","../common/utils.js","parse","exit","1694992XvhBvK","../../package.json","run","break","yes","progress","production","delegate","-i, --input <input-directory>","_sent","EnvironmentPlugin","defineProperty","done","completed","Clear build resource","ProgressPlugin","command","-c, --clear","red","convert","yellow","values","_isAscfMode","displayName","then","AsyncIterator","7632849KjjTvQ","check","async","19444563pCWKko","return","create","resultName","clear","659HGpMYc","wrap","isLatestAscfToolkit","suspendedStart","tryEntries","concat","hasOwnProperty","confirmConverterFun","info","toString","reset","clearResource","iterator","existsVerifyLog","try statement without catch or finally","prototype","argv","push","function","env","end","NODE_ENV","apply","resolve","finallyLoc","checkInputPathFun","ascf toolkit convert and compile ascf project","input","sent","' method","catchLoc","nextLoc","@@iterator","Generator","isGeneratorFunction","requiredOption","-m, --mode","catch","rval","action","@@toStringTag","Convert miniprogram project to ascf project","value","continue","normal","afterLoc","symbol","iterator result is not an object","option","watch","Clear convert output path","plugins","_invoke","ascf/ascf_src","WARNING: Get @atomicservice/ascf-toolkit version failed: ","[object Generator]","Validate path","next","getPrototypeOf","type","prev","Generator is already running"," is not iterable","10695678rvuZtT","stop","completion"];return(_0x52d7=function(){return t})()}program[_0x3d4cf3(480)](pkg.version).description(_0x3d4cf3(587)),program.command(_0x3d4cf3(546))[_0x3d4cf3(513)](_0x3d4cf3(448)).requiredOption(_0x3d4cf3(535))[_0x3d4cf3(596)](_0x3d4cf3(478))[_0x3d4cf3(455)](_0x3d4cf3(544),_0x3d4cf3(457))[_0x3d4cf3(455)](_0x3d4cf3(506),_0x3d4cf3(463))[_0x3d4cf3(446)]((()=>{var e=_0x3d4cf3,r=_asyncToGenerator(_regeneratorRuntime()[e(520)](function t(r){var n,o,c,i=e;return _regeneratorRuntime()[i(562)](function(t){for(var e=i;;)switch(t[e(467)]=t[e(464)]){case 0:if(n=require("../ascf-converter/features/converter.js"),global._isMiniAppConvertMode=!0,global[e(549)]=!0,process[e(580)][e(572)]=r[e(560)]?"yes":"no",c=require(e(524)),o=c[e(563)],c=c[e(490)],r[e(484)]&&(c(r[e(588)],r.output),process[e(526)](0)),n[e(586)](r[e(588)]),r[e(554)]){t[e(464)]=12;break}return t[e(464)]=10,n[e(568)]({inputPath:r[e(588)],outPath:r[e(476)],confirmAddConfig:!0});case 10:(c=t[e(589)])[e(479)]?console[e(482)](chalk[e(545)](e(505)[e(566)](c[e(543)],'","errorMessage":"')[e(566)](c[e(479)],'"'))):console[e(569)](chalk[e(512)]('"command":"'[e(566)](c[e(543)],e(504))[e(566)](c.folderUrl,'"')));case 12:setTimeout(function(){var r=e;try{o()}catch(t){console[r(492)](chalk.yellow(r(461)[r(566)](t,".")))}});case 13:case e(581):return t[e(471)]()}},t)}));return function(t){return r.apply(this,arguments)}})()),program[_0x3d4cf3(543)](_0x3d4cf3(489)).description(_0x3d4cf3(514))[_0x3d4cf3(455)](_0x3d4cf3(491),"Show build progress")[_0x3d4cf3(455)](_0x3d4cf3(499),_0x3d4cf3(481))[_0x3d4cf3(455)](_0x3d4cf3(597),"Environment is development")[_0x3d4cf3(455)](_0x3d4cf3(544),_0x3d4cf3(541))[_0x3d4cf3(446)]((()=>{var e=_0x3d4cf3,n=_asyncToGenerator(_regeneratorRuntime()[e(520)](function t(r,n){var o,c,i=e;return _regeneratorRuntime()[i(562)](function(t){for(var e=i;;)switch(t[e(467)]=t.next){case 0:return o=require("path"),process[e(580)].projectRoot=o[e(584)](r),process.chdir(o[e(584)](r,e(460))),process[e(580)][e(582)]=n.mode?e(521):e(533),process[e(580)][e(572)]=n[e(560)]?e(531):"no",o=require(e(475)),t[e(467)]=6,c=require(e(474)),t[e(464)]=10,c();case 10:(c=t[e(589)])[e(458)]=c.plugins||[],c[e(458)][e(578)](new o[e(537)]({projectRoot:r})),n[e(532)]&&c[e(458)][e(578)](new o[e(542)]),n[e(456)]&&(c[e(456)]=!0),o(c)[e(529)](function(t,r){var n=e;t&&(console[n(482)](chalk[n(545)](t)),process[n(526)](1)),setTimeout(function(){var r=n,t=require("../common/utils.js"),e=t.isLatestAscfToolkit,t=t.isLatestAscfHar;try{t(global[r(574)])}catch(t){console[r(492)](chalk[r(547)](r(510)[r(566)](t,".")))}try{e(global[r(574)])}catch(t){console[r(492)](chalk.yellow("WARNING: Get @atomicservice/ascf-toolkit version failed: "[r(566)](t,".")))}})}),t[e(464)]=23;break;case 19:t[e(467)]=19,t.t0=t[e(444)](6),console[e(482)](chalk[e(545)](t.t0)),process[e(526)](1);case 23:case e(581):return t.stop()}},t,null,[[6,19]])}));return function(t,r){return n[e(583)](this,arguments)}})()),program[_0x3d4cf3(525)](process[_0x3d4cf3(577)]);
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var _0x4987e6=_0xa920;function _typeof(r){var t=_0xa920;return(_typeof=t(221)==typeof Symbol&&t(231)==typeof Symbol.iterator?function(r){return typeof r}:function(r){var e=t;return r&&e(221)==typeof Symbol&&r[e(216)]===Symbol&&r!==Symbol[e(239)]?e(231):typeof r})(r)}function _classCallCheck(r,e){var t=_0xa920;if(!(r instanceof e))throw new TypeError(t(181))}function _defineProperties(r,e){for(var t=_0xa920,n=0;n<e[t(176)];n++){var o=e[n];o[t(168)]=o[t(168)]||!1,o[t(232)]=!0,t(237)in o&&(o[t(250)]=!0),Object[t(233)](r,_toPropertyKey(o[t(164)]),o)}}function _createClass(r,e,t){return e&&_defineProperties(r[_0xa920(239)],e),t&&_defineProperties(r,t),Object.defineProperty(r,"prototype",{writable:!1}),r}function _toPropertyKey(r){var e=_0xa920,r=_toPrimitive(r,"string");return e(231)==_typeof(r)?r:r+""}function _toPrimitive(r,e){var t=_0xa920;if(t(159)!=_typeof(r)||!r)return r;var n=r[Symbol.toPrimitive];if(void 0===n)return(t(189)===e?String:Number)(r);n=n[t(248)](r,e||t(177));if(t(159)!=_typeof(n))return n;throw new TypeError(t(174))}function _toConsumableArray(r){return _arrayWithoutHoles(r)||_iterableToArray(r)||_unsupportedIterableToArray(r)||_nonIterableSpread()}function _nonIterableSpread(){throw new TypeError(_0xa920(211))}function _unsupportedIterableToArray(r,e){var t,n=_0xa920;if(r)return n(189)==typeof r?_arrayLikeToArray(r,e):(t={}[n(171)][n(248)](r)[n(228)](8,-1),n(238)===t&&r[n(216)]&&(t=r[n(216)][n(214)]),n(249)===t||n(165)===t?Array[n(182)](r):n(191)===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?_arrayLikeToArray(r,e):void 0)}function _0x2d71(){var r=["concat","ModuleBuildError","green","../ascf-compiler/chalk/bundle.cjs","25206wwgueD","warnCount","slice","formatters","hooks","symbol","configurable","defineProperty","showCompileTime","showtime","error","value","Object","prototype","noteCount","includes","info","184377mHsHmb","displayErrors","transformers","startTime","2udhRVl","call","Map","writable","Module not found","warnings","12502YsWlic","object","calculate","SUCCESS ","errors","FAIL ","key","Set","ERROR: ","extraInfo","enumerable","iterator","forEach","toString","dropRepeat"," ms","@@toPrimitive must return a primitive value.","warn","length","default","options","warning","272XrKznp","Cannot call a class as a function","from","printCompileResult","level","some","origin","@@iterator","23890MCRaQu","string","2048820zTsyWZ","Arguments","warningCount","replace","33xhXunc","1975365botNXT","apply","\nCOMPILE RESULT:SUCCESS","test","resource","assign","ModuleNotFoundError","\n@ ","message","Error: ","1318968iptgEU","compilation","\nCOMPILE RESULT:","map","errorCount","reduce","Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.","file","yellow","name","undefined","constructor","exports","hasErrors","231GCzrvT","isArray","function"];return(_0x2d71=function(){return r})()}function _iterableToArray(r){var e=_0xa920;if(e(215)!=typeof Symbol&&null!=r[Symbol[e(169)]]||null!=r[e(187)])return Array[e(182)](r)}function _arrayWithoutHoles(r){if(Array[_0xa920(220)](r))return _arrayLikeToArray(r)}function _arrayLikeToArray(r,e){var t=_0xa920;(null==e||e>r.length)&&(e=r[t(176)]);for(var n=0,o=Array(e);n<e;n++)o[n]=r[n];return o}(()=>{for(var r=_0xa920,e=_0x2d71();;)try{if(170456==+parseInt(r(253))*(parseInt(r(247))/2)+parseInt(r(243))/3+-parseInt(r(180))/4*(parseInt(r(188))/5)+-parseInt(r(226))/6*(parseInt(r(219))/7)+parseInt(r(205))/8+-parseInt(r(195))/9+-parseInt(r(190))/10*(-parseInt(r(194))/11))break;e.push(e.shift())}catch(r){e.push(e.shift())}})();var TYPE=_0x4987e6(251),chalk=require(_0x4987e6(225));function defaultFormatter(r,e){return r.reduce(function(r,e){var t=_0xa920;return[][t(222)](_toConsumableArray(r),["\n"[t(222)](e[t(203)])])},[])}function babelSyntaxError(r){var e=_0x4987e6;return isBabelSyntaxError(r)&&(r[e(203)]=cleanStackTrace(r[e(203)])),r}function isBabelSyntaxError(r){var e=_0x4987e6;return r[e(214)]===e(223)&&r[e(203)][e(241)]("SyntaxError")}function cleanStackTrace(r){var e=_0x4987e6;return r[e(193)](/^\s*at\s.*:\d+:\d+[\s\)]*\n/gm,"").replace(/^Module build failed.*:\s/,e(204))}function moduleNotFoundError(r){var e,t=_0x4987e6;return r.name===t(201)&&r.message.includes(TYPE)&&(r[t(203)]=r[t(203)].replace(TYPE,t(166)[t(222)](TYPE)),e=r[t(186)]&&r.origin[t(199)])&&(r[t(203)]+=t(202)[t(222)](e)),r}chalk[_0x4987e6(184)]=1;var defaultFormatters=[defaultFormatter],defaultTransformers=[babelSyntaxError,moduleNotFoundError];function extractError(r){var e=_0x4987e6;return{message:r[e(203)],file:r[e(212)],origin:r[e(186)],name:r[e(214)],severity:0,webpackError:r}}function cleanMessage(r){var e=_0x4987e6;return r[e(193)]("(Emitted value instead of an instance of Error) ","")[e(193)](/Module Warning[^\n]+\n/,"")[e(193)](/Module Error[^\n]+\n/,"")}function transformErrors(r,e){function t(r,e){return e(r)}return r[_0x4987e6(208)](extractError).map(function(r){return e[_0xa920(210)](t,r)})}function _0xa920(r,e){var t=_0x2d71();return(_0xa920=function(r,e){return t[r-=159]})(r,e)}function formatErrors(e,r,t){return r[_0x4987e6(208)](function(r){return r(e,t)||[]}).reduce(function(r,e){return r.concat(e)},[])}function getCompileTime(r){var e=_0x4987e6,t=r.endTime,r=r[e(246)];console[e(242)](chalk[e(224)]("compileTime: "[e(222)](t-r,e(173))))}function _dropRepeat(r){var e=_0x4987e6;return r[e(210)](function(r,t){var n=e;return r[n(185)](function(r){var e=n;return r.message===t[e(203)]})?r:r[n(222)](t)},[])}var BuildLogOutputPlugin=(()=>{var l=_0x4987e6;return _createClass(function r(){var e=_0xa920,t=0<arguments[e(176)]&&void 0!==arguments[0]?arguments[0]:{},n=t.showCompileTime,n=void 0!==n&&n,t=t[e(178)];_classCallCheck(this,r),this[e(209)]=0,this[e(192)]=0,this[e(240)]=0,this[e(234)]=n||"true"===process.env[e(235)],this[e(229)]=defaultFormatters,this[e(245)]=defaultTransformers,this[e(178)]=t},[{key:l(196),value:function(r){var u=l,s=this;r[u(230)].done.tap("BuildLogOutputPlugin",function(e){var t=u,r=(s.dropRepeat(e),e[t(206)]),n=r.errors,o=r[t(252)],a=e[t(218)](),i=e.hasWarnings();setTimeout(function(){var r=t;a&&s[r(244)](n,r(236)),i&&s.displayErrors(o,r(179)),s[r(160)](e,n,o),s[r(183)](),s[r(234)]&&getCompileTime(e)})})}},{key:l(172),value:function(r){var e=l;r.compilation[e(252)]=_dropRepeat(r[e(206)].warnings),r[e(206)][e(162)]=_dropRepeat(r.compilation[e(162)])}},{key:"calculate",value:function(r,e){var t=l,n=this,o=2<arguments[t(176)]&&void 0!==arguments[2]?arguments[2]:[],r=r.compilation[t(167)]||{},a=r[t(209)],a=void 0===a?0:a,i=r[t(227)],i=void 0===i?0:i,r=r[t(240)],r=void 0===r?0:r;this[t(209)]=e[t(176)]+a,this[t(192)]=i,this[t(240)]=r,o[t(170)](function(r){var e=t,r=r[e(203)];/^NOTE:/[e(198)](cleanMessage(r))?n[e(240)]++:n[e(192)]++})}},{key:l(183),value:function(){var r,e=l,t=this[e(209)],n=this[e(192)],o=this[e(240)];0<t+n+o?(r=e(t?163:161),t=Object[e(200)]({},t?{ERROR:t}:{},n?{WARN:n}:{},o?{NOTE:o}:{}),console[e(175)](chalk[e(213)](e(207).concat(r)[e(222)](JSON.stringify(t))))):console[e(242)](chalk[e(224)](e(197)))}},{key:l(244),value:function(r,t){var n=l;formatErrors(transformErrors(r,this[n(245)]),this[n(229)],t)[n(170)](function(r){var e=n;t===e(236)&&console[e(236)](chalk.red(cleanMessage(r))),t===e(179)&&console.warn(chalk.yellow(cleanMessage(r)))})}},{key:"getBuildMsg",value:function(r,e){var t=l;return formatErrors(transformErrors(r,this[t(245)]),this[t(229)],e)[t(208)](function(r){return cleanMessage(r)})}}])})();module[_0x4987e6(217)]=BuildLogOutputPlugin;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
function _0x25b4(){var r=["345616qqvvNx","5849665cCYNMC","use strict","value","4113912XKDlqA","36CMWPUW","15713712UxdMMV","splice","2370416IjNIyc","1191155CwakNk","512791IUehre","length","node","directives","exports"];return(_0x25b4=function(){return r})()}var _0x54aba0=_0x5718;function _0x5718(r,t){var e=_0x25b4();return(_0x5718=function(r,t){return e[r-=272]})(r,t)}(()=>{for(var r=_0x5718,t=_0x25b4();;)try{if(696588==-parseInt(r(286))+parseInt(r(276))/2+-parseInt(r(280))/3+parseInt(r(284))/4+-parseInt(r(277))/5+-parseInt(r(281))/6*(-parseInt(r(285))/7)+parseInt(r(282))/8)break;t.push(t.shift())}catch(r){t.push(t.shift())}})(),module[_0x54aba0(275)]=function(){return{visitor:{Program:{exit:function(r){for(var t=_0x5718,e=r[t(273)][t(274)],n=e[t(272)]-1;0<=n;n--)e[n].value[t(279)]===t(278)&&e[t(283)](n,1)}}}}};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var _0x4e20dd=_0xbca5,rimraf=((()=>{for(var e=_0xbca5,r=_0x213d();;)try{if(620729==-parseInt(e(250))+-parseInt(e(251))/2*(-parseInt(e(289))/3)+-parseInt(e(220))/4*(parseInt(e(242))/5)+-parseInt(e(228))/6*(-parseInt(e(245))/7)+parseInt(e(281))/8+-parseInt(e(290))/9*(-parseInt(e(305))/10)+-parseInt(e(248))/11)break;r.push(r.shift())}catch(e){r.push(r.shift())}})(),require(_0x4e20dd(303))),fs=require("fs"),path=require(_0x4e20dd(221)),_require=require(_0x4e20dd(223)),execSync=_require[_0x4e20dd(304)],_require2=require(_0x4e20dd(238)),satisfies=_require2[_0x4e20dd(258)],JSON5=require(_0x4e20dd(255)),chalk=require(_0x4e20dd(218)),projectPath=(chalk.level=1,process.env[_0x4e20dd(254)]||process[_0x4e20dd(277)]()),projectCfg=readProjectCfgJson(projectPath)||{},srcPath=path[_0x4e20dd(235)](projectPath,_0x4e20dd(276));function getJsonData(r){var t=_0x4e20dd;if(!fs.existsSync(r))return{};var e={};try{e=JSON[t(266)](fs.readFileSync(r,t(274)))}catch(e){throw t(293)[t(265)](r)}return e}function _0x213d(){var e=["execSync","4590310bfSsmm","Input path is not MiniProgram src.","ASCF_SRC_PATH","length","WARNING: ","ohpm info @atomicservice/ascf -ft 10000","dependencies","Check success.","call",'WARNING: @atomicservice/ascf-toolkit can be upgraded, execute command "npm update -g @atomicservice/ascf-toolkit ',"../ascf-compiler/chalk/bundle.cjs","includes","93116bkYHVH","path","beta","child_process","existsSync","ascf.config.json","_versionType","red","1548iIIAxd","NODE_ENV","join","map","versionType","returnCode","package.json","resolve","trim","env","semver","checkInputPathFun","name","info","5LupDeX","true","isPrivatePkg","4970FhsZXR","clearResource",'INFO: @atomicservice/ascf-toolkit can be upgraded, execute command "npm update -g @atomicservice/ascf-toolkit ',"13871957QakPOM","production","592403xWSbXR","100382RlPKGE","IS_PRD","@atomicservice/ascf","projectRoot","json5","ascf","ascfRoot","satisfies","PROJECT_PATH","isLatestAscfToolkit","prototype","checkPath","yellow","PROJECT_CONFIG","concat","parse","data","build-profile.json5","Output path is not an ASCF project.","isLatestAscfHar","warn","WARNING: ASCF Shared Library can be upgraded.","srcPath","utf-8","npm view @atomicservice/ascf-toolkit version","ascf/ascf_src","cwd","release","src/main/resources/rawfile","@atomicservice/ascf-toolkit","9622432xLezgX","modules","toLowerCase","error","INFO: ASCF Shared Library can be upgraded.","debug","latest[39m:","readFileSync","39zqAQdi","9zVmkWK","green","../ascf-converter/features/converter.js","ERROR: The file format is incorrect: ","oh-package.json5","latest","ERROR: build-profile.json5 file modules is null","toString","version","hasOwnProperty","./oh-package.json5","sync","split","rimraf"];return(_0x213d=function(){return e})()}function initVersionType(){var e=_0x4e20dd,r=[e(286),e(222),e(278)],t=process[e(237)][e(232)];global[e(226)]=e(286),t&&r[e(219)](t)?global._versionType=t:(r=process[e(237)].uglifyjs===e(243),global[e(226)]=e(r?278:286))}function readProjectCfgJson(e){var r,t=_0x4e20dd,e=path[t(230)](e,t(225));return r=fs.existsSync(e)?JSON.parse(fs[t(288)](e)[t(297)]()):r}function getEntryPackageName(){var e=_0x4e20dd,r=path[e(235)](projectPath,e(268)),r=JSON5[e(266)](fs[e(288)](r)[e(297)]());if(r[e(282)]&&0!==r[e(282)][e(308)])return r[e(282)][0][e(273)];throw e(296)}function _0xbca5(e,r){var t=_0x213d();return(_0xbca5=function(e,r){return t[e-=215]})(e,r)}function checkPath(e,r){var t=_0x4e20dd;require(t(292))[t(239)](e)[t(267)][t(233)]?(e=path.resolve(r,t(268)),fs[t(224)](e)&&(e=JSON5[t(266)](fs.readFileSync(e)[t(297)]()))[t(282)]&&0!==e[t(282)][t(308)]?(r=path[t(235)](r,e[t(282)][0][t(273)],t(300)),(e=JSON5[t(266)](fs[t(288)](r).toString()))[t(311)]&&Object[t(261)][t(299)][t(216)](e[t(311)],t(253))?console[t(241)](chalk[t(291)](t(215))):console.error(chalk.red(t(269)))):console[t(284)](chalk[t(227)](t(269)))):console[t(284)](chalk[t(227)](t(306)))}initVersionType(),exports[_0x4e20dd(252)]=process.env[_0x4e20dd(229)]===_0x4e20dd(249),exports[_0x4e20dd(259)]=projectPath,exports[_0x4e20dd(264)]=projectCfg,exports[_0x4e20dd(307)]=projectCfg.ascfRoot?path.resolve(srcPath,projectCfg[_0x4e20dd(257)]):srcPath,exports.ASCF_BUILD_PATH=path[_0x4e20dd(235)](projectPath,_0x4e20dd(256),"ascf_build"),exports.RAWFILE_DIR=_0x4e20dd(279),exports[_0x4e20dd(246)]=function(e){var a=_0x4e20dd;return Promise.all(e[a(231)](function(r){var t=a;if(fs[t(224)](r))return new Promise(function(e){rimraf[t(301)](r),e()})}))},exports[_0x4e20dd(244)]=function(){var e=_0x4e20dd,r=getJsonData(path[e(230)](__dirname,"..","..",e(234)))[e(240)];return r!==e(280)&&r[e(219)]("/")},exports[_0x4e20dd(260)]=function(){var e=_0x4e20dd,r=0<arguments.length&&void 0!==arguments[0]&&arguments[0],t=JSON.parse(fs.readFileSync(path[e(230)](__dirname,"..","..",e(234)),e(274))[e(297)]())[e(298)],a=execSync(e(275),{timeout:5e3})[e(297)]().trim();t!==a&&(r?console[e(271)](chalk.yellow(e(217).concat(a,'"'))):console[e(241)](chalk[e(291)](e(247).concat(a,'"'))))},exports[_0x4e20dd(270)]=function(){var e,r=_0x4e20dd,t=0<arguments[r(308)]&&void 0!==arguments[0]&&arguments[0],a=path.join(projectPath,getEntryPackageName(),r(294)),c=JSON5[r(266)](fs.readFileSync(a,"utf-8")[r(297)]())[r(311)]["@atomicservice/ascf"];c?(e=execSync(r(310),{timeout:5e3})[r(297)]()[r(302)](r(287))[1][r(302)]("\n")[0][r(236)](),satisfies(e,c)||c[r(283)]()===r(295)||(t?console[r(271)](chalk[r(263)](r(272))):console.info(chalk[r(291)](r(285))))):console.warn(chalk[r(263)](r(309).concat(a," does not depend on ASCF Shared Library. Select a project that does, or create a new one.")))},exports[_0x4e20dd(262)]=checkPath;
|