Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

translate-compiler

Package Overview
Dependencies
Maintainers
1
Versions
28
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

translate-compiler - npm Package Compare versions

Comparing version 0.9.0-beta to 0.9.5-beta

2

main/index.js
#! /usr/bin/env node
const a0_0x3bc47f=a0_0x4222;function a0_0x4222(_0x4efb16,_0xb3d830){const _0x3cfe87=a0_0x3cfe();return a0_0x4222=function(_0x4222f9,_0x141d74){_0x4222f9=_0x4222f9-0x11d;let _0x1636de=_0x3cfe87[_0x4222f9];return _0x1636de;},a0_0x4222(_0x4efb16,_0xb3d830);}(function(_0x4f60f7,_0x5ba882){const _0x1da6be=a0_0x4222,_0x4f6367=_0x4f60f7();while(!![]){try{const _0x178b26=-parseInt(_0x1da6be(0x131))/0x1+-parseInt(_0x1da6be(0x184))/0x2*(-parseInt(_0x1da6be(0x123))/0x3)+-parseInt(_0x1da6be(0x17b))/0x4+-parseInt(_0x1da6be(0x153))/0x5+parseInt(_0x1da6be(0x15e))/0x6*(parseInt(_0x1da6be(0x12f))/0x7)+parseInt(_0x1da6be(0x18c))/0x8+-parseInt(_0x1da6be(0x16a))/0x9*(-parseInt(_0x1da6be(0x185))/0xa);if(_0x178b26===_0x5ba882)break;else _0x4f6367['push'](_0x4f6367['shift']());}catch(_0x178272){_0x4f6367['push'](_0x4f6367['shift']());}}}(a0_0x3cfe,0x52c94));const fs=require('fs'),path=require('path'),{program}=require('commander'),{pinyin}=require(a0_0x3bc47f(0x166)),{translater}=require(a0_0x3bc47f(0x176)),{parseHTML}=require(a0_0x3bc47f(0x17e)),_path=process[a0_0x3bc47f(0x129)]();function hasChinese(_0x362d8f){const _0xbc8ae8=a0_0x3bc47f;return/[\u4e00-\u9fa5]/g[_0xbc8ae8(0x18e)](_0x362d8f);}let customLang={},config={'env':'dev','locals':[],'excludes':[],'translate':[],'channel':a0_0x3bc47f(0x148),'appKey':'','secretKey':'','suffix':a0_0x3bc47f(0x150),'output':a0_0x3bc47f(0x180)};getConfig();function getConfig(){const _0x598849=a0_0x3bc47f;program[_0x598849(0x14d)]('<env>',_0x598849(0x145))['requiredOption'](_0x598849(0x174),_0x598849(0x16c))[_0x598849(0x146)](_0x598849(0x149),'需要生成的地区语言(语种代码)如:zh等')[_0x598849(0x146)](_0x598849(0x183),_0x598849(0x15f))[_0x598849(0x146)](_0x598849(0x127),'翻译api\x20应用key')[_0x598849(0x146)](_0x598849(0x169),_0x598849(0x16e))['option'](_0x598849(0x14f),_0x598849(0x168))['option'](_0x598849(0x190),'翻译的文件名后缀,默认.vue')[_0x598849(0x146)](_0x598849(0x142),_0x598849(0x120))['option'](_0x598849(0x121),_0x598849(0x16b))[_0x598849(0x146)](_0x598849(0x14a),_0x598849(0x164)),program[_0x598849(0x14e)]();const _0x3e74cc=program[_0x598849(0x11d)]();config=Object['assign'](config,_0x3e74cc,{'env':program[_0x598849(0x138)][0x0]}),getFileContent(path['join'](_path,'/translate.json'),_0x42f638=>{const _0x59d72f=_0x598849;customLang=_0x42f638,console[_0x59d72f(0x133)](new Array(0x50)[_0x59d72f(0x134)]('-')),console[_0x59d72f(0x133)](_0x59d72f(0x13d)),console[_0x59d72f(0x133)](new Array(0x50)[_0x59d72f(0x134)]('-'));},()=>{const _0x394dbb=_0x598849;console['log'](new Array(0x50)['join']('-')),console['log'](_0x394dbb(0x13a)),console[_0x394dbb(0x133)](new Array(0x50)['join']('-'));});}function a0_0x3cfe(){const _0x1e3f8f=[':\x20\x22','$t(','writeFileSync','forEach','3382400zbFtYO','.lang.$1','test','isDirectory','-s,\x20--suffix\x20<value>','existsSync','opts','parseInt','-\x20执行文件:','排除翻译的文件,可指定多个','-o,\x20--output\x20<file>','utf-8','15TFqUbv','split','attrs','mkdirSync','--appKey\x20<value>','strict','cwd','$t($key)','map','basename','substring','this.$t($key)','49mdcKzR','translate','217249BXibZL','读取文件失败','log','join','readFileSync','.js','zh_cn','args','exports.__esModule\x20=\x20true;\x0dexports.default\x20=\x20{\x0d','-\x20读取字典:\x20未读取到自定义字典translate.json!','\x27)\x20}}','keys','-\x20读取字典:\x20读取自定义字典\x27translate.json\x27成功!','value','extname','fill','\x27,\x20[','-e,\x20--excludes\x20<value...>','dirname','stringify','指定环境:dev(开发)/test(测试)/prod(生产),默认为开发环境','option','content','youdao','-l,\x20--locals\x20<value...>','--strict','name','none','argument','parse','-t,\x20--translate\x20<value...>','.vue','values','first','353485eNVTKu','\x22:\x20\x22','sort','readdirSync','.json','array','replace','-\x20统计:------\x20中文字段统计频率排行榜','dir','push','suffix','166134IidvfS','翻译渠道\x20baidu百度,youdao有道','.lang','??????FILE_NAME_TO_LONG','start','prod','是否严格模式,\x20严格模式只提取$t()内中文,否则全局','{{\x20$t(\x27','pinyin-pro','reduce','需要翻译的语言,对应locals','--secretKey\x20<value>','9fbZErO','翻译结果写入路径,默认locals/local.json','翻译的文件夹','env','翻译api\x20密钥','target','toLowerCase','文件不存在','assign','lstatSync','-d,\x20--dir\x20<dir>','this.$t(','./parser/translater','-\x20统计:------\x20中文字段统计频率排行榜,频率过高建议加入自定义key!','locals','end','obj','2005812oImWDI','includes','match','./parser/html-parser','local.json','locals/local.json','length','filter','-c,\x20--channel\x20<value>','148402yjvqzF','1408630hfjIEz','this.$t(\x27','entries'];a0_0x3cfe=function(){return _0x1e3f8f;};return a0_0x3cfe();}function getFileContent(_0x581820,_0x4621b1,_0xb04635){const _0x52276c=a0_0x3bc47f;if(fs[_0x52276c(0x191)](_0x581820))try{let _0xed00b3=fs[_0x52276c(0x135)](_0x581820,{'encoding':_0x52276c(0x122)});const _0x5cc626=path['extname'](_0x581820);if(_0x5cc626==_0x52276c(0x157))_0x4621b1&&_0x4621b1(JSON['parse'](_0xed00b3));else{let _0x2ce7af={};_0xed00b3[_0x52276c(0x159)](/['"]*(\w+)['"]*:\s*"([^"]+)"/g,(_0x4c599b,_0x3b3abe,_0x3a3746)=>{_0x2ce7af[_0x3b3abe]=_0x3a3746;}),_0x4621b1&&_0x4621b1(_0x2ce7af);}}catch(_0x40849e){_0xb04635&&_0xb04635(_0x52276c(0x132));}else _0xb04635&&_0xb04635(_0x52276c(0x171));}function getSuffixFiles(_0x3b5028,_0x4355ed,_0x4a7ddd){const _0x332216=a0_0x3bc47f,_0x35ce99=fs[_0x332216(0x156)](_0x3b5028),_0x11cfa1=[];return _0x35ce99[_0x332216(0x18b)]((_0x4385a8,_0xca4c7e)=>{const _0x32b3f6=_0x332216,_0x39e66e=path[_0x32b3f6(0x134)](_0x3b5028,_0x4385a8),_0x333407=fs[_0x32b3f6(0x173)](_0x39e66e);if(_0x333407[_0x32b3f6(0x18f)]())_0x11cfa1[_0x32b3f6(0x15c)](...getSuffixFiles(_0x39e66e,_0x4355ed,_0x4a7ddd));else path[_0x32b3f6(0x13f)](_0x4385a8)==_0x4355ed&&!_0x4a7ddd[_0x32b3f6(0x17c)](path['extname'](_0x4385a8))&&_0x11cfa1['push'](_0x39e66e);}),_0x11cfa1;}function delSuffixFiles(_0x2cff68,_0x3ce0dd,_0xa81eec){const _0x21edbb=a0_0x3bc47f,_0x643e7b=fs[_0x21edbb(0x156)](_0x2cff68);_0x643e7b[_0x21edbb(0x18b)]((_0x49329d,_0x45733e)=>{const _0x5bf1a2=_0x21edbb,_0x4c3da1=path[_0x5bf1a2(0x134)](_0x2cff68,_0x49329d),_0x3e6037=fs[_0x5bf1a2(0x173)](_0x4c3da1),_0x177958=new RegExp(_0x5bf1a2(0x160)+_0x3ce0dd+'$');if(_0x3e6037[_0x5bf1a2(0x18f)]())delSuffixFiles(_0x4c3da1,_0x3ce0dd,_0xa81eec);else _0x177958['test'](_0x49329d)&&!_0xa81eec[_0x5bf1a2(0x17c)](path['extname'](_0x49329d))&&fs['unlinkSync'](_0x4c3da1);});}function getTranslateKey(_0x3ff06c,_0x36d338){const _0x244175=a0_0x3bc47f;if(_0x36d338[_0x244175(0x181)]>0x28)return _0x244175(0x161);const _0x44e5e1=/^(['"`])|['"`]$/g,_0x1d43ab=/\$*\{(.*?)\}/g;let _0x426180=_0x3ff06c[_0x244175(0x159)](_0x44e5e1,'');const _0x30d79a=(_0x426180[_0x244175(0x17d)](_0x1d43ab)||[])[_0x244175(0x167)]((_0x300b99,_0x15a550,_0x728b48)=>_0x300b99['replace'](_0x15a550,'{'+_0x728b48+'}'),_0x426180),_0xace3b7=Object[_0x244175(0x151)](customLang)['indexOf'](_0x30d79a);if(_0xace3b7!==-0x1)return Object['keys'](customLang)[_0xace3b7];_0x426180=_0x426180[_0x244175(0x159)](_0x1d43ab,'o'),_0x426180=_0x426180[_0x244175(0x159)](/[^\u4e00-\u9fa5\w]/g,'');let _0x50b20a=_0x426180[_0x244175(0x159)](/([\u4e00-\u9fa5]+)/g,_0x212254=>{const _0x5507e3=_0x244175;return pinyin(_0x212254,{'toneType':_0x5507e3(0x14c),'type':_0x5507e3(0x158)})[_0x5507e3(0x134)]('_');}),_0x3de59b=_0x36d338+'_'+_0x50b20a;if(_0x3de59b[_0x244175(0x181)]>0x1e){_0x50b20a=_0x426180[_0x244175(0x159)](/([\u4e00-\u9fa5]+)/g,_0x268d93=>{const _0x4a8ac8=_0x244175;return pinyin(_0x268d93,{'pattern':_0x4a8ac8(0x152),'toneType':_0x4a8ac8(0x14c),'type':'array'})['join']('');}),_0x3de59b=_0x36d338+'_'+_0x50b20a;if(_0x3de59b[_0x244175(0x181)]>0x32){const _0x154d94=Number[_0x244175(0x11e)](_0x50b20a[_0x244175(0x181)]/(0x31-_0x36d338[_0x244175(0x181)]))+0x1;_0x50b20a=new Array(_0x50b20a[_0x244175(0x181)])[_0x244175(0x140)]('')[_0x244175(0x167)]((_0x202b16,_0x32579e,_0x4f4d72)=>''+_0x202b16+(_0x4f4d72%_0x154d94==0x0?_0x50b20a[_0x4f4d72]:''));}_0x3de59b=_0x36d338+'_'+_0x50b20a;}return _0x3de59b;}translate();function translate(){const _0x45e340=a0_0x3bc47f;delSuffixFiles(path[_0x45e340(0x134)](_path,config[_0x45e340(0x15b)]),config[_0x45e340(0x15d)],config['excludes']);const _0x49d896=getSuffixFiles(path[_0x45e340(0x134)](_path,config[_0x45e340(0x15b)]),config[_0x45e340(0x15d)],config['excludes']);let _0x1ae3ed={};console[_0x45e340(0x133)](new Array(0x50)[_0x45e340(0x134)]('-')),_0x49d896[_0x45e340(0x18b)](function(_0x176c27,_0x3ea748){const _0x50bccf=_0x45e340;console[_0x50bccf(0x133)](_0x50bccf(0x11f)+_0x176c27);let _0x1f0c35=fs[_0x50bccf(0x135)](_0x176c27,{'encoding':_0x50bccf(0x122)})+'';const _0x25b651=path[_0x50bccf(0x12c)](_0x176c27)[_0x50bccf(0x124)]('.')[0x0],_0x194b78=/\<template\>(.|\n|\r)*\<\/template\>/g,_0x18f274=/<!--[\s\S]*?-->/g,_0x2017d0=/\<script\>(.|\n|\r)*\<\/script\>/g,_0x4ef676=/(?<=\s|\;|^|\{|\})\/\/[^\r\n]*/g,_0x4ba0c5=/\/\*[\s\S]*?\*\//g;_0x1f0c35=_0x1f0c35['replace'](_0x194b78,_0x314cee=>_0x314cee[_0x50bccf(0x159)](_0x18f274,'')),_0x1f0c35=_0x1f0c35[_0x50bccf(0x159)](_0x2017d0,_0x287c2b=>_0x287c2b['replace'](_0x4ef676,'')['replace'](_0x4ba0c5,''));const _0x106db0=/(?<=\$t\()(['"])(.*?)\1/g;_0x1f0c35=_0x1f0c35[_0x50bccf(0x159)](_0x106db0,(_0x16937a,_0x2900ba,_0x36be29)=>{if(hasChinese(_0x16937a)){const _0x439cbb=getTranslateKey(_0x16937a,_0x25b651);return _0x1ae3ed[_0x439cbb]=_0x36be29,'\x27'+_0x439cbb+'\x27';}return _0x16937a;}),_0x1f0c35=_0x1f0c35[_0x50bccf(0x159)](_0x194b78,_0x412d56=>{const _0x51dd51=_0x50bccf,_0x486594=handleTemplate(_0x412d56,_0x25b651);return _0x1ae3ed=Object[_0x51dd51(0x172)](_0x1ae3ed,_0x486594[_0x51dd51(0x17a)]),_0x486594[_0x51dd51(0x147)];}),_0x1f0c35=_0x1f0c35['replace'](_0x2017d0,_0x13be6e=>{const _0x2f369f=_0x50bccf,_0x4cbda0=handleScript(_0x13be6e,_0x25b651);return _0x1ae3ed=Object[_0x2f369f(0x172)](_0x1ae3ed,_0x4cbda0[_0x2f369f(0x17a)]),_0x4cbda0['content'];}),outputLangFile(_0x176c27,_0x1f0c35);}),console[_0x45e340(0x133)](new Array(0x50)['join']('-')),outputLocalFile(_0x1ae3ed);}function handleTemplate(_0x15f93c,_0x237186){const _0x3a6c33=a0_0x3bc47f,_0x4343f6=handleStringTpl(_0x15f93c,_0x237186,!![]);_0x15f93c=_0x4343f6[_0x3a6c33(0x147)];let _0x2ca34a=_0x4343f6['obj'];if(!config[_0x3a6c33(0x128)]){const _0x1eb8bb=_0x15f93c;let _0x2edbd4=0x0;parseHTML(_0x1eb8bb,_0x321fed=>{const _0x26c506=_0x3a6c33;hasChinese(_0x321fed[_0x26c506(0x13e)])&&_0x321fed[_0x26c506(0x13e)][_0x26c506(0x159)](/^\s*([\w\W]*?)\s*$/,(_0x553f74,_0x1de9d7)=>{const _0x5ee416=_0x26c506;if(/\{\{(.*?)\}\}/g['test'](_0x553f74)){const _0x4de37e=handleDoubleBrace(_0x1de9d7,_0x237186,_0x5ee416(0x12a),!![]);return _0x2ca34a=Object[_0x5ee416(0x172)](_0x2ca34a,_0x4de37e[_0x5ee416(0x17a)]),_0x15f93c=replaceStringFromTo(_0x15f93c,_0x321fed[_0x5ee416(0x162)]+_0x2edbd4,_0x321fed[_0x5ee416(0x179)]+_0x2edbd4,_0x553f74[_0x5ee416(0x159)](_0x1de9d7,_0x4de37e[_0x5ee416(0x147)])),_0x2edbd4=_0x2edbd4+(_0x4de37e[_0x5ee416(0x147)][_0x5ee416(0x181)]-_0x1de9d7[_0x5ee416(0x181)]),_0x553f74;}const _0x441d59=getTranslateKey(_0x1de9d7,_0x237186);_0x2ca34a[_0x441d59]=_0x1de9d7;const _0x4c9fd9=_0x5ee416(0x165)+_0x441d59+_0x5ee416(0x13b);return _0x15f93c=replaceStringFromTo(_0x15f93c,_0x321fed[_0x5ee416(0x162)]+_0x2edbd4,_0x321fed[_0x5ee416(0x179)]+_0x2edbd4,_0x553f74[_0x5ee416(0x159)](_0x1de9d7,_0x4c9fd9)),_0x2edbd4=_0x2edbd4+(_0x4c9fd9[_0x5ee416(0x181)]-_0x1de9d7[_0x5ee416(0x181)]),_0x553f74;});},_0x44dcd1=>{const _0x5cf3f8=_0x3a6c33;for(let _0x2f01f7=0x0;_0x2f01f7<_0x44dcd1[_0x5cf3f8(0x125)][_0x5cf3f8(0x181)];_0x2f01f7++){const _0x1cb045=_0x44dcd1[_0x5cf3f8(0x125)][_0x2f01f7];if(hasChinese(_0x1cb045[_0x5cf3f8(0x13e)])){const _0x7319db=getTranslateKey(_0x1cb045['value'],_0x237186);_0x2ca34a[_0x7319db]=_0x1cb045[_0x5cf3f8(0x13e)];const _0x3c30c8='$t(\x27'+_0x7319db+'\x27)';_0x15f93c=replaceStringFromTo(_0x15f93c,_0x1cb045['start']+_0x2edbd4,_0x1cb045['end']+_0x2edbd4,_0x1cb045[_0x5cf3f8(0x16f)][_0x5cf3f8(0x159)](_0x1cb045[_0x5cf3f8(0x13e)],_0x3c30c8)[_0x5cf3f8(0x159)](_0x1cb045[_0x5cf3f8(0x14b)],':'+_0x1cb045['name'])),_0x2edbd4=_0x2edbd4+(_0x3c30c8['length']-_0x1cb045[_0x5cf3f8(0x13e)][_0x5cf3f8(0x181)])+0x1;}}});}return{'content':_0x15f93c,'obj':_0x2ca34a};}function handleScript(_0x581870,_0x6df618){const _0x595d7b=a0_0x3bc47f,_0x40f7b6=/(?<!\$t\(\s*)(['"])(.*?)(\1)/g,_0xfa3e50=handleStringTpl(_0x581870,_0x6df618);_0x581870=_0xfa3e50['content'];let _0x467d19=_0xfa3e50[_0x595d7b(0x17a)];return!config[_0x595d7b(0x128)]&&(_0x581870=_0x581870['replace'](_0x40f7b6,(_0x101924,_0x96b591,_0x29d506)=>{const _0x46ad3b=_0x595d7b;if(hasChinese(_0x101924)){const _0x2734b0=getTranslateKey(_0x101924,_0x6df618);return _0x467d19[_0x2734b0]=_0x29d506,_0x46ad3b(0x186)+_0x2734b0+'\x27)';}return _0x101924;})),{'content':_0x581870,'obj':_0x467d19};}function handleStringTpl(_0x35f669,_0x5f12c6,_0x2b851d){const _0x3f0af8=a0_0x3bc47f,_0x53fd38=/(?<!\$t\(\s*)`(.*?)`/g,_0x28b174=/(?<=\$t\()`(.*?)`/g,_0x599f6b=/\${(.*?)}/g;let _0x1288f3={};const _0x558971=function(_0x39ddc8,_0x13bb62,_0x3e9a4e){const _0x31238e=a0_0x4222,_0x114c29=_0x39ddc8['replace'](_0x599f6b,'');if(hasChinese(_0x114c29)){const _0x4538d1=getTranslateKey(_0x39ddc8,_0x5f12c6),_0xaf46f1=_0x39ddc8[_0x31238e(0x17d)](_0x599f6b);if(_0xaf46f1){const _0x2e26ac=_0xaf46f1[_0x31238e(0x167)]((_0x5bb966,_0x1f9b3d,_0x1b5439)=>_0x5bb966[_0x31238e(0x159)](_0x1f9b3d,'{'+_0x1b5439+'}'),_0x13bb62),_0x272c86=_0xaf46f1[_0x31238e(0x12b)](_0x2de7a9=>{const _0x4cbf53=_0x31238e,_0x280efa=_0x2de7a9[_0x4cbf53(0x159)](_0x599f6b,'$1'),_0x5b9e9c=handleDoubleBrace(_0x280efa,_0x5f12c6,_0x2b851d?'$t($key)':_0x4cbf53(0x12e));return _0x1288f3=Object[_0x4cbf53(0x172)](_0x1288f3,_0x5b9e9c[_0x4cbf53(0x17a)]),_0x5b9e9c[_0x4cbf53(0x147)];});return _0x1288f3[_0x4538d1]=_0x2e26ac,_0x3e9a4e('\x27'+_0x4538d1+_0x31238e(0x141)+_0x272c86[_0x31238e(0x134)](',\x20')+']');}return _0x1288f3[_0x4538d1]=_0x13bb62,_0x3e9a4e('\x27'+_0x4538d1+'\x27');}return _0x39ddc8;};return _0x35f669=_0x35f669['replace'](_0x28b174,(_0x57da50,_0x1973d0)=>{return _0x558971(_0x57da50,_0x1973d0,_0x317b00=>_0x317b00);}),!config[_0x3f0af8(0x128)]&&(_0x35f669=_0x35f669['replace'](_0x53fd38,(_0x551af4,_0x4a9f7a)=>{const _0x2a809b=_0x3f0af8;return _0x558971(_0x551af4,_0x4a9f7a,_0x39c7dd=>_0x2b851d?_0x2a809b(0x189)+_0x39c7dd+')':_0x2a809b(0x175)+_0x39c7dd+')');})),{'content':_0x35f669,'obj':_0x1288f3};}function handleDoubleBrace(_0x5b117a,_0x2c91e0,_0x486425='$key',_0x253701=![]){const _0x136f90=a0_0x3bc47f,_0x8a8094=/(['"])(.*?)(\1)/g;let _0x185879={};if(_0x253701){const _0x2c02d0=(_0x5b117a[_0x136f90(0x124)](/{{.*?}}/)||[])['filter'](_0x4ed6a7=>hasChinese(_0x4ed6a7));_0x2c02d0[_0x136f90(0x18b)](_0x423e2e=>{const _0x136c64=_0x136f90,_0x2df28a=getTranslateKey(_0x423e2e,_0x2c91e0);_0x5b117a=_0x5b117a[_0x136c64(0x159)](_0x423e2e,_0x136c64(0x165)+_0x2df28a+_0x136c64(0x13b)),_0x185879[_0x2df28a]=_0x423e2e;});}const _0x1aa151=(_0x5b117a['match'](_0x8a8094)||[])['filter'](_0x5a617c=>hasChinese(_0x5a617c));return _0x1aa151[_0x136f90(0x18b)](_0x2ff3fa=>{const _0x49e226=_0x136f90,_0x572cff=getTranslateKey(_0x2ff3fa,_0x2c91e0);_0x5b117a=_0x5b117a['replace'](_0x2ff3fa,_0x486425['replace']('$key','\x27'+_0x572cff+'\x27')),_0x185879[_0x572cff]=_0x2ff3fa[_0x49e226(0x159)](/^['"]|['"]$/g,'');}),{'content':_0x5b117a,'obj':_0x185879};}function outputLangFile(_0x59fb3c,_0x54eb1b){const _0x205a59=a0_0x3bc47f;if(config['env']=='test'){const _0x4b7a13=_0x59fb3c[_0x205a59(0x159)](/\.(\w+)$/,_0x205a59(0x18d));fs[_0x205a59(0x18a)](_0x4b7a13,_0x54eb1b);}else config[_0x205a59(0x16d)]==_0x205a59(0x163)&&fs[_0x205a59(0x18a)](_0x59fb3c,_0x54eb1b);}async function outputLocalFile(_0x300a2b){const _0x243cab=a0_0x3bc47f,_0x46f472=path[_0x243cab(0x134)](_path,config['output']);if(/\.\w+$/g[_0x243cab(0x18e)](_0x46f472)){const _0x47e69d=path[_0x243cab(0x143)](_0x46f472);!fs[_0x243cab(0x191)](_0x47e69d)&&fs[_0x243cab(0x126)](_0x47e69d,{'recursive':!![]});const _0x3975c7=path[_0x243cab(0x13f)](_0x46f472);handleLocalFile(_0x300a2b,_0x46f472);for(let _0x179ab0=0x0;_0x179ab0<config[_0x243cab(0x178)][_0x243cab(0x181)];_0x179ab0++){const _0x693e4b=config['locals'][_0x179ab0];_0x693e4b=='zh'||_0x693e4b[_0x243cab(0x170)]()==_0x243cab(0x137)?await handleLocalFile(_0x300a2b,path[_0x243cab(0x134)](path[_0x243cab(0x143)](_0x46f472),''+_0x693e4b+_0x3975c7)):await handleLocalFile(_0x300a2b,path[_0x243cab(0x134)](path[_0x243cab(0x143)](_0x46f472),''+_0x693e4b+_0x3975c7),_0x693e4b,config[_0x243cab(0x130)][_0x243cab(0x17c)](_0x693e4b));}statisticalSort(_0x300a2b);}else{!fs[_0x243cab(0x191)](_0x46f472)&&fs[_0x243cab(0x126)](_0x46f472,{'recursive':!![]});handleLocalFile(_0x300a2b,path[_0x243cab(0x134)](_0x46f472,_0x243cab(0x17f)));for(let _0x116c61=0x0;_0x116c61<config[_0x243cab(0x178)][_0x243cab(0x181)];_0x116c61++){const _0xbaf925=config[_0x243cab(0x178)][_0x116c61];_0xbaf925=='zh'||_0xbaf925[_0x243cab(0x170)]()==_0x243cab(0x137)?await handleLocalFile(_0x300a2b,path[_0x243cab(0x134)](_0x46f472,_0xbaf925+'.json')):await handleLocalFile(_0x300a2b,path[_0x243cab(0x134)](_0x46f472,_0xbaf925+'.json'),_0xbaf925,config[_0x243cab(0x130)][_0x243cab(0x17c)](_0xbaf925));}statisticalSort(_0x300a2b);}}async function handleLocalFile(_0x29d71a,_0x28dd1f,_0x2f7a1a,_0x22bad7){const _0x45a7b2=function(_0x422310){const _0x437d80=a0_0x4222,_0x204030=path[_0x437d80(0x13f)](_0x28dd1f);if(_0x204030==_0x437d80(0x136)){let _0x51392e=Object[_0x437d80(0x13c)](_0x422310)[_0x437d80(0x12b)](_0x7a6b6a=>'\x20\x20'+_0x7a6b6a+_0x437d80(0x188)+_0x422310[_0x7a6b6a]+'\x22')['join'](',\x0d');fs['writeFileSync'](_0x28dd1f,_0x437d80(0x139)+_0x51392e+'\x0d}');}else{let _0x5f3063=Object[_0x437d80(0x13c)](_0x422310)[_0x437d80(0x12b)](_0x2c9295=>'\x20\x20\x22'+_0x2c9295+_0x437d80(0x154)+_0x422310[_0x2c9295]+'\x22')['join'](',\x0d');fs[_0x437d80(0x18a)](_0x28dd1f,'{\x0d'+_0x5f3063+'\x0d}');}};let _0x44af1f,_0x1b0cc1;getFileContent(_0x28dd1f,_0x3d84bf=>{const _0x462157=a0_0x4222;_0x44af1f=Object[_0x462157(0x172)]({},_0x29d71a,_0x3d84bf),_0x1b0cc1=getExtraValues(_0x29d71a,_0x3d84bf);},()=>{const _0x3a7e8b=a0_0x4222;_0x44af1f=JSON['parse'](JSON[_0x3a7e8b(0x144)](_0x29d71a)),_0x1b0cc1=JSON['parse'](JSON[_0x3a7e8b(0x144)](_0x29d71a));}),_0x22bad7?await translater(_0x1b0cc1,_0x2f7a1a,config,_0x251482=>{const _0x33cf5e=a0_0x4222;_0x44af1f=Object[_0x33cf5e(0x172)](_0x44af1f,_0x251482),_0x45a7b2(_0x44af1f);}):_0x45a7b2(_0x44af1f);}function getExtraValues(_0x371f99,_0x32e75c){const _0xc310aa=a0_0x3bc47f,_0x21ef27=Object[_0xc310aa(0x13c)](_0x371f99)[_0xc310aa(0x182)](_0x1a1f4d=>!_0x32e75c['hasOwnProperty'](_0x1a1f4d)),_0x138234={};return _0x21ef27[_0xc310aa(0x18b)](_0x3e6b69=>{_0x138234[_0x3e6b69]=_0x371f99[_0x3e6b69];}),_0x138234;}function replaceStringFromTo(_0x1b2b71,_0x185007,_0x3a0937,_0x50ca5b){const _0x1dc10f=a0_0x3bc47f;return _0x1b2b71[_0x1dc10f(0x12d)](0x0,_0x185007)+_0x50ca5b+_0x1b2b71[_0x1dc10f(0x12d)](_0x3a0937);}function statisticalSort(_0x399045){const _0x423556=a0_0x3bc47f,_0x4df912=Object[_0x423556(0x151)](_0x399045);let _0x4a88f5={};for(let _0x36acc5=0x0;_0x36acc5<_0x4df912[_0x423556(0x181)];_0x36acc5++){const _0x552ca3=_0x4df912[_0x36acc5];_0x4a88f5[_0x552ca3]?_0x4a88f5[_0x552ca3]++:_0x4a88f5[_0x552ca3]=0x1;}const _0x2d6a11=Object[_0x423556(0x187)](_0x4a88f5)[_0x423556(0x155)]((_0x22a788,_0x41d551)=>_0x41d551[0x1]-_0x22a788[0x1]);console[_0x423556(0x133)](new Array(0x50)[_0x423556(0x134)]('-')),console[_0x423556(0x133)](_0x423556(0x177));for(let _0xd1c00e=0x0;_0xd1c00e<_0x2d6a11[_0x423556(0x181)];_0xd1c00e++){const _0x414bef=_0x2d6a11[_0xd1c00e];console[_0x423556(0x133)]('-\x20统计:------\x20\x20第'+(_0xd1c00e+0x1)+'名('+_0x414bef[0x1]+'):'+_0x414bef[0x0]);if(_0xd1c00e>=0x9)break;}console['log'](_0x423556(0x15a)),console['log'](new Array(0x50)[_0x423556(0x134)]('-'));}
const a0_0x20805d=a0_0x5ebd;(function(_0xd36a14,_0x5e9d3c){const _0x24dd29=a0_0x5ebd,_0x1234b9=_0xd36a14();while(!![]){try{const _0x350b05=parseInt(_0x24dd29(0x102))/0x1+parseInt(_0x24dd29(0x15b))/0x2+parseInt(_0x24dd29(0x12c))/0x3+parseInt(_0x24dd29(0x15a))/0x4*(parseInt(_0x24dd29(0x133))/0x5)+-parseInt(_0x24dd29(0x123))/0x6*(-parseInt(_0x24dd29(0x148))/0x7)+-parseInt(_0x24dd29(0xfd))/0x8+-parseInt(_0x24dd29(0x136))/0x9*(parseInt(_0x24dd29(0x14d))/0xa);if(_0x350b05===_0x5e9d3c)break;else _0x1234b9['push'](_0x1234b9['shift']());}catch(_0x2a4793){_0x1234b9['push'](_0x1234b9['shift']());}}}(a0_0x6248,0x78013));const fs=require('fs'),path=require(a0_0x20805d(0x15d)),{program}=require('commander'),{pinyin}=require(a0_0x20805d(0x113)),{translater}=require(a0_0x20805d(0x143)),{parseHTML}=require('./parser/html-parser'),_path=process[a0_0x20805d(0x146)]();function hasChinese(_0x3387bb){const _0xf835d1=a0_0x20805d;return/[\u4e00-\u9fa5]/g[_0xf835d1(0x104)](_0x3387bb);}let customLang={},addCount=0x0,delCount=0x0,config={'env':a0_0x20805d(0x16a),'locals':[],'excludes':[],'translate':[],'channel':a0_0x20805d(0x111),'appKey':'','secretKey':'','suffix':a0_0x20805d(0x164),'output':a0_0x20805d(0x12e)};getConfig();function getConfig(){const _0x43133e=a0_0x20805d;program['argument'](_0x43133e(0x163),'指定环境:dev(开发)/test(测试)/prod(生产),默认为开发环境')[_0x43133e(0x141)](_0x43133e(0x12a),'翻译的文件夹')['option'](_0x43133e(0x127),_0x43133e(0x154))[_0x43133e(0x12d)](_0x43133e(0x166),_0x43133e(0x100))['option'](_0x43133e(0x162),_0x43133e(0x151))[_0x43133e(0x12d)](_0x43133e(0x16c),_0x43133e(0x14a))[_0x43133e(0x12d)](_0x43133e(0x12f),'需要翻译的语言,对应locals')[_0x43133e(0x12d)]('-s,\x20--suffix\x20<value>',_0x43133e(0x11a))[_0x43133e(0x12d)]('-e,\x20--excludes\x20<value...>','排除翻译的文件,可指定多个')[_0x43133e(0x12d)](_0x43133e(0x149),_0x43133e(0x14e))[_0x43133e(0x12d)](_0x43133e(0x14f),'是否严格模式,\x20严格模式只提取$t()内中文,否则全局'),program[_0x43133e(0x13b)]();const _0x1b9c98=program[_0x43133e(0x159)]();config=Object['assign'](config,_0x1b9c98,{'env':program[_0x43133e(0x10f)][0x0]}),getFileContent(path['join'](_path,_0x43133e(0x13e)),_0x59965c=>{const _0x28a3c7=_0x43133e;customLang=_0x59965c,console[_0x28a3c7(0x147)](new Array(0x50)['join']('-')),console['log'](_0x28a3c7(0x14c)),console[_0x28a3c7(0x147)](new Array(0x50)['join']('-'));},()=>{const _0x5e2790=_0x43133e;console['log'](new Array(0x50)[_0x5e2790(0x144)]('-')),console['log'](_0x5e2790(0x10a)),console['log'](new Array(0x50)[_0x5e2790(0x144)]('-'));});}function getFileContent(_0x4fab31,_0x470181,_0x3ccfb4){const _0x2c53e8=a0_0x20805d;if(fs[_0x2c53e8(0x13f)](_0x4fab31))try{let _0x45b044=fs[_0x2c53e8(0xff)](_0x4fab31,{'encoding':_0x2c53e8(0x134)});const _0x1b664d=path[_0x2c53e8(0x105)](_0x4fab31);if(_0x1b664d==_0x2c53e8(0x135))_0x470181&&_0x470181(JSON[_0x2c53e8(0x13b)](_0x45b044));else{let _0x246544={};_0x45b044[_0x2c53e8(0x106)](/(['"])*(\w+?)\1*:\s*(['"])([^\3]*?)\3/gm,(_0x2d34fe,_0x5d1537,_0x24d65d,_0x211e03,_0x1e6c4c)=>{_0x246544[_0x24d65d]=_0x1e6c4c;}),_0x470181&&_0x470181(_0x246544);}}catch(_0xe0a425){_0x3ccfb4&&_0x3ccfb4(_0x2c53e8(0x165));}else _0x3ccfb4&&_0x3ccfb4(_0x2c53e8(0x13c));}function getSuffixFiles(_0x25818c,_0x239aaf,_0x49b72b){const _0x15b38f=a0_0x20805d,_0x51006a=fs[_0x15b38f(0x11d)](_0x25818c),_0x4674f0=[];return _0x51006a[_0x15b38f(0x124)]((_0x3ed7b6,_0x2561ba)=>{const _0x1cefbc=_0x15b38f,_0x1698ef=path['join'](_0x25818c,_0x3ed7b6),_0x33df1b=fs['lstatSync'](_0x1698ef);if(_0x33df1b[_0x1cefbc(0x11b)]())_0x4674f0[_0x1cefbc(0x15c)](...getSuffixFiles(_0x1698ef,_0x239aaf,_0x49b72b));else path['extname'](_0x3ed7b6)==_0x239aaf&&!_0x49b72b[_0x1cefbc(0x10c)](path[_0x1cefbc(0x105)](_0x3ed7b6))&&_0x4674f0['push'](_0x1698ef);}),_0x4674f0;}function a0_0x6248(){const _0x426554=['\x20条、删除\x20','翻译的文件名后缀,默认.vue','isDirectory','{{\x20$t(\x27','readdirSync','values','entries','\x20条,本次新增\x20','length','\x20条。','5023974uBSIwi','forEach','filter','map','-l,\x20--locals\x20<value...>','hasOwnProperty','writeFileSync','-d,\x20--dir\x20<dir>','.js','1455615gpdVPl','option','locals/local.js','-t,\x20--translate\x20<value...>','locals','dir','\x22:\x20\x22','5aDihZs','utf-8','.json','203382hvKoHq','dirname','start','content','$t($key)','parse','文件不存在','keys','/translate.json','existsSync','-\x20执行文件:','requiredOption','-\x20统计:------\x20\x20第','./parser/translater','join','translate','cwd','log','7sKkJIE','-o,\x20--output\x20<file>','翻译api\x20密钥','value','-\x20读取字典:\x20读取自定义key字典\x27translate.json\x27成功!','1060iJmyFr','翻译结果写入路径,默认locals/local.js','--strict','local.js','翻译api\x20应用key','substring','indexOf','需要生成的地区语言(语种代码)如:zh等','zh_cn','\x20\x20\x22','suffix','\x27,\x20[','opts','3602828wQdDBA','1042240pMLtzS','push','path','mkdirSync','this.$t(\x27','\x27)\x20}}','exports.__esModule\x20=\x20true;\x0dexports.default\x20=\x20{\x0d','--appKey\x20<value>','<env>','.vue','读取文件失败','-c,\x20--channel\x20<value>','none',':\x20\x22','array','dev','attrs','--secretKey\x20<value>','reduce','457480oIKhOw','assign','readFileSync','翻译渠道\x20baidu百度,youdao有道','lstatSync','199751OzzguB','??????FILE_NAME_TO_LONG','test','extname','replace','sort','strict','$key','-\x20读取字典:\x20未读取到自定义字典translate.json!','end','includes','$t(','$t(\x27','args','excludes','baidu','prod','pinyin-pro','obj','toLowerCase','match','split','env'];a0_0x6248=function(){return _0x426554;};return a0_0x6248();}function delSuffixFiles(_0x51d7eb,_0x40dfcb,_0x1118e4){const _0x1aeffc=a0_0x20805d,_0x1b61e1=fs[_0x1aeffc(0x11d)](_0x51d7eb);_0x1b61e1[_0x1aeffc(0x124)]((_0xec1613,_0x253ffd)=>{const _0x2ea091=_0x1aeffc,_0x150148=path[_0x2ea091(0x144)](_0x51d7eb,_0xec1613),_0x3d1f63=fs[_0x2ea091(0x101)](_0x150148),_0x5417db=new RegExp('.lang'+_0x40dfcb+'$');if(_0x3d1f63['isDirectory']())delSuffixFiles(_0x150148,_0x40dfcb,_0x1118e4);else _0x5417db['test'](_0xec1613)&&!_0x1118e4[_0x2ea091(0x10c)](path['extname'](_0xec1613))&&fs['unlinkSync'](_0x150148);});}function getTranslateKey(_0x4c5c67,_0x1bbeaf){const _0x2ac2b6=a0_0x20805d;if(_0x1bbeaf[_0x2ac2b6(0x121)]>0x28)return _0x2ac2b6(0x103);const _0x3ecee8=/^(['"`])|['"`]$/g,_0x14d272=/\$*\{(.*?)\}/g;let _0x31c778=_0x4c5c67[_0x2ac2b6(0x106)](_0x3ecee8,'');const _0x4db031=(_0x31c778[_0x2ac2b6(0x116)](_0x14d272)||[])[_0x2ac2b6(0xfc)]((_0x2bfbf5,_0x41e22f,_0x1d1b18)=>_0x2bfbf5[_0x2ac2b6(0x106)](_0x41e22f,'{'+_0x1d1b18+'}'),_0x31c778),_0x12a8fc=Object[_0x2ac2b6(0x11e)](customLang)[_0x2ac2b6(0x153)](_0x4db031);if(_0x12a8fc!==-0x1)return Object[_0x2ac2b6(0x13d)](customLang)[_0x12a8fc];_0x31c778=_0x31c778[_0x2ac2b6(0x106)](_0x14d272,'o'),_0x31c778=_0x31c778[_0x2ac2b6(0x106)](/[^\u4e00-\u9fa5\w]/g,'');let _0x32f486=_0x31c778[_0x2ac2b6(0x106)](/([\u4e00-\u9fa5]+)/g,_0x3dbc5b=>{const _0x46f6b3=_0x2ac2b6;return pinyin(_0x3dbc5b,{'toneType':_0x46f6b3(0x167),'type':_0x46f6b3(0x169),'v':!![]})[_0x46f6b3(0x144)]('_');}),_0x4d9d43=_0x1bbeaf+'_'+_0x32f486;if(_0x4d9d43[_0x2ac2b6(0x121)]>0x1e){_0x32f486=_0x31c778['replace'](/([\u4e00-\u9fa5]+)/g,_0x5ae0b5=>{const _0x13b4f7=_0x2ac2b6;return pinyin(_0x5ae0b5,{'pattern':'first','toneType':_0x13b4f7(0x167),'type':_0x13b4f7(0x169),'v':!![]})[_0x13b4f7(0x144)]('');}),_0x4d9d43=_0x1bbeaf+'_'+_0x32f486;if(_0x4d9d43[_0x2ac2b6(0x121)]>0x32){const _0x52d11b=Number['parseInt'](_0x32f486['length']/(0x31-_0x1bbeaf[_0x2ac2b6(0x121)]))+0x1;_0x32f486=new Array(_0x32f486[_0x2ac2b6(0x121)])['fill']('')[_0x2ac2b6(0xfc)]((_0x300f20,_0x379af1,_0x120498)=>''+_0x300f20+(_0x120498%_0x52d11b==0x0?_0x32f486[_0x120498]:''));}_0x4d9d43=_0x1bbeaf+'_'+_0x32f486;}return _0x4d9d43;}translate();function translate(){const _0x5e9b74=a0_0x20805d;delSuffixFiles(path['join'](_path,config[_0x5e9b74(0x131)]),config[_0x5e9b74(0x157)],config[_0x5e9b74(0x110)]);const _0x497f6e=getSuffixFiles(path[_0x5e9b74(0x144)](_path,config['dir']),config[_0x5e9b74(0x157)],config[_0x5e9b74(0x110)]);let _0x460fd2={};console[_0x5e9b74(0x147)](new Array(0x50)[_0x5e9b74(0x144)]('-')),_0x497f6e[_0x5e9b74(0x124)](function(_0x55048d,_0x5dd57e){const _0x2c165b=_0x5e9b74;console[_0x2c165b(0x147)](_0x2c165b(0x140)+_0x55048d);let _0x1e7db7=fs[_0x2c165b(0xff)](_0x55048d,{'encoding':_0x2c165b(0x134)})+'';const _0x57931=path['basename'](_0x55048d)['split']('.')[0x0],_0x522928=/\<template\>(.|\n|\r)*\<\/template\>/g,_0x2251d3=/<!--[\s\S]*?-->/g,_0x5f062a=/\<script\>(.|\n|\r)*\<\/script\>/g,_0x1506bf=/(?<=\s|\;|^|\{|\})\/\/[^\r\n]*/g,_0x8331ac=/\/\*[\s\S]*?\*\//g;_0x1e7db7=_0x1e7db7[_0x2c165b(0x106)](_0x522928,_0x5182f3=>_0x5182f3[_0x2c165b(0x106)](_0x2251d3,'')),_0x1e7db7=_0x1e7db7[_0x2c165b(0x106)](_0x5f062a,_0x37e8c2=>_0x37e8c2[_0x2c165b(0x106)](_0x1506bf,'')[_0x2c165b(0x106)](_0x8331ac,''));const _0x1ed26e=/(?<=\$t\()(['"])(.*?)\1/g;_0x1e7db7=_0x1e7db7[_0x2c165b(0x106)](_0x1ed26e,(_0x323956,_0x276376,_0x1554f9)=>{if(hasChinese(_0x323956)){const _0x41ebbd=getTranslateKey(_0x323956,_0x57931);return _0x460fd2[_0x41ebbd]=_0x1554f9,'\x27'+_0x41ebbd+'\x27';}return _0x323956;}),_0x1e7db7=_0x1e7db7[_0x2c165b(0x106)](_0x522928,_0x402e26=>{const _0x43ed5b=handleTemplate(_0x402e26,_0x57931);return _0x460fd2=Object['assign'](_0x460fd2,_0x43ed5b['obj']),_0x43ed5b['content'];}),_0x1e7db7=_0x1e7db7[_0x2c165b(0x106)](_0x5f062a,_0x55f799=>{const _0x51ca83=_0x2c165b,_0x5707d5=handleScript(_0x55f799,_0x57931);return _0x460fd2=Object['assign'](_0x460fd2,_0x5707d5[_0x51ca83(0x114)]),_0x5707d5[_0x51ca83(0x139)];}),outputLangFile(_0x55048d,_0x1e7db7);}),console[_0x5e9b74(0x147)](new Array(0x50)['join']('-')),outputLocalFile(_0x460fd2);}function handleTemplate(_0x4250c3,_0x8bfdf8){const _0x9df12d=a0_0x20805d,_0x46214c=handleStringTpl(_0x4250c3,_0x8bfdf8,!![]);_0x4250c3=_0x46214c[_0x9df12d(0x139)];let _0x14cf7c=_0x46214c[_0x9df12d(0x114)];if(!config[_0x9df12d(0x108)]){const _0x1f36ff=_0x4250c3;let _0x411c98=0x0;parseHTML(_0x1f36ff,_0x287e85=>{const _0x4a7a4e=_0x9df12d;hasChinese(_0x287e85[_0x4a7a4e(0x14b)])&&_0x287e85[_0x4a7a4e(0x14b)][_0x4a7a4e(0x106)](/^\s*([\w\W]*?)\s*$/,(_0x3014fc,_0x5475aa)=>{const _0x5e5b4d=_0x4a7a4e;if(/\{\{(.*?)\}\}/g['test'](_0x3014fc)){const _0x270ed0=handleDoubleBrace(_0x5475aa,_0x8bfdf8,_0x5e5b4d(0x13a),!![]);return _0x14cf7c=Object['assign'](_0x14cf7c,_0x270ed0['obj']),_0x4250c3=replaceStringFromTo(_0x4250c3,_0x287e85[_0x5e5b4d(0x138)]+_0x411c98,_0x287e85[_0x5e5b4d(0x10b)]+_0x411c98,_0x3014fc[_0x5e5b4d(0x106)](_0x5475aa,_0x270ed0[_0x5e5b4d(0x139)])),_0x411c98=_0x411c98+(_0x270ed0['content']['length']-_0x5475aa['length']),_0x3014fc;}const _0x555fba=getTranslateKey(_0x5475aa,_0x8bfdf8);_0x14cf7c[_0x555fba]=_0x5475aa[_0x5e5b4d(0x106)](/\n/g,'\x5cn');const _0x237b98=_0x5e5b4d(0x11c)+_0x555fba+_0x5e5b4d(0x160);return _0x4250c3=replaceStringFromTo(_0x4250c3,_0x287e85[_0x5e5b4d(0x138)]+_0x411c98,_0x287e85[_0x5e5b4d(0x10b)]+_0x411c98,_0x3014fc['replace'](_0x5475aa,_0x237b98)),_0x411c98=_0x411c98+(_0x237b98[_0x5e5b4d(0x121)]-_0x5475aa[_0x5e5b4d(0x121)]),_0x3014fc;});},_0x4e7c08=>{const _0x28d90b=_0x9df12d;for(let _0x5a8c66=0x0;_0x5a8c66<_0x4e7c08[_0x28d90b(0x16b)]['length'];_0x5a8c66++){const _0x48720d=_0x4e7c08[_0x28d90b(0x16b)][_0x5a8c66];if(hasChinese(_0x48720d[_0x28d90b(0x14b)])){if(/^:/['test'](_0x48720d['name'])){const _0x38c8b8=handleDoubleBrace(_0x48720d[_0x28d90b(0x14b)],_0x8bfdf8,_0x28d90b(0x13a),![]);_0x14cf7c=Object[_0x28d90b(0xfe)](_0x14cf7c,_0x38c8b8[_0x28d90b(0x114)]),_0x4250c3=replaceStringFromTo(_0x4250c3,_0x48720d[_0x28d90b(0x138)]+_0x411c98,_0x48720d[_0x28d90b(0x10b)]+_0x411c98,_0x48720d['target'][_0x28d90b(0x106)](_0x48720d[_0x28d90b(0x14b)],_0x38c8b8[_0x28d90b(0x139)])),_0x411c98=_0x411c98+(_0x38c8b8[_0x28d90b(0x139)][_0x28d90b(0x121)]-_0x48720d[_0x28d90b(0x14b)][_0x28d90b(0x121)]);return;}const _0xd0dd14=getTranslateKey(_0x48720d['value'],_0x8bfdf8);_0x14cf7c[_0xd0dd14]=_0x48720d['value'];const _0x41b079=_0x28d90b(0x10e)+_0xd0dd14+'\x27)';_0x4250c3=replaceStringFromTo(_0x4250c3,_0x48720d['start']+_0x411c98,_0x48720d[_0x28d90b(0x10b)]+_0x411c98,_0x48720d['target'][_0x28d90b(0x106)](_0x48720d[_0x28d90b(0x14b)],_0x41b079)[_0x28d90b(0x106)](_0x48720d['name'],':'+_0x48720d['name'])),_0x411c98=_0x411c98+(_0x41b079[_0x28d90b(0x121)]-_0x48720d['value'][_0x28d90b(0x121)])+0x1;}}});}return{'content':_0x4250c3,'obj':_0x14cf7c};}function handleScript(_0x4eba61,_0x14bc7a){const _0x4c36ca=a0_0x20805d,_0x11908c=/(?<!\$t\(\s*)(['"])(.*?)(\1)/g,_0x2af86f=handleStringTpl(_0x4eba61,_0x14bc7a);_0x4eba61=_0x2af86f[_0x4c36ca(0x139)];let _0x623968=_0x2af86f['obj'];return!config[_0x4c36ca(0x108)]&&(_0x4eba61=_0x4eba61[_0x4c36ca(0x106)](_0x11908c,(_0x478cf2,_0x12e070,_0x52b9bb)=>{const _0x4577bf=_0x4c36ca;if(hasChinese(_0x478cf2)){const _0x476693=getTranslateKey(_0x478cf2,_0x14bc7a);return _0x623968[_0x476693]=_0x52b9bb,_0x4577bf(0x15f)+_0x476693+'\x27)';}return _0x478cf2;})),{'content':_0x4eba61,'obj':_0x623968};}function handleStringTpl(_0x5c9db8,_0x3664a8,_0x598c55){const _0x14dbcc=a0_0x20805d,_0x8c0e10=/(?<!\$t\(\s*)`((.|(\${[^}]*?}))*?)`/g,_0x3554da=/(?<=\$t\()`([^`]+?)`/g,_0x5b77fe=/\${\s*(.*?)\s*}/g;let _0x3f89c2={};const _0x4b41e2=function(_0x1144d5,_0x3e4506,_0x4dd96e){const _0x4ff794=a0_0x5ebd,_0xc1775f=_0x1144d5[_0x4ff794(0x106)](_0x5b77fe,'');if(hasChinese(_0xc1775f)){const _0x43f21c=getTranslateKey(_0x1144d5,_0x3664a8),_0x4599be=_0x1144d5[_0x4ff794(0x116)](_0x5b77fe);if(_0x4599be){const _0x1cecd6=_0x4599be[_0x4ff794(0xfc)]((_0x20ab1a,_0x57310c,_0x349e25)=>_0x20ab1a[_0x4ff794(0x106)](_0x57310c,'{'+_0x349e25+'}'),_0x3e4506),_0x35d10c=_0x4599be[_0x4ff794(0x126)](_0x2a7500=>{const _0x5e8608=_0x4ff794,_0x48db03=_0x2a7500['replace'](_0x5b77fe,'$1'),_0x1caf55=handleDoubleBrace(_0x48db03,_0x3664a8,_0x598c55?_0x5e8608(0x13a):'this.$t($key)');return _0x3f89c2=Object[_0x5e8608(0xfe)](_0x3f89c2,_0x1caf55[_0x5e8608(0x114)]),_0x1caf55['content'];});return _0x3f89c2[_0x43f21c]=_0x1cecd6,_0x4dd96e('\x27'+_0x43f21c+_0x4ff794(0x158)+_0x35d10c['join'](',\x20')+']');}return _0x3f89c2[_0x43f21c]=_0x3e4506,_0x4dd96e('\x27'+_0x43f21c+'\x27');}return _0x1144d5;};return _0x5c9db8=_0x5c9db8['replace'](_0x3554da,(_0x4a90d5,_0x1415e6)=>{return _0x4b41e2(_0x4a90d5,_0x1415e6,_0xcbbcc2=>_0xcbbcc2);}),!config[_0x14dbcc(0x108)]&&(_0x5c9db8=_0x5c9db8['replace'](_0x8c0e10,(_0x4dd8dd,_0xc273d4)=>{const _0x48c5f6=_0x14dbcc;return _0x4b41e2(_0x4dd8dd,_0xc273d4,_0x487942=>_0x598c55?_0x48c5f6(0x10d)+_0x487942+')':'this.$t('+_0x487942+')');})),{'content':_0x5c9db8,'obj':_0x3f89c2};}function handleDoubleBrace(_0x5b8925,_0x44b1ae,_0x13a51f=a0_0x20805d(0x109),_0x2c0776=![]){const _0x4f4376=a0_0x20805d,_0x479224=/(['"])(.*?)(\1)/g;let _0x58e0df={};if(_0x2c0776){const _0x3318b5=(_0x5b8925[_0x4f4376(0x117)](/{{.*?}}/)||[])[_0x4f4376(0x125)](_0x50a1df=>hasChinese(_0x50a1df));_0x3318b5[_0x4f4376(0x124)](_0x4b0335=>{const _0x1823af=_0x4f4376,_0x2d76f8=getTranslateKey(_0x4b0335,_0x44b1ae);_0x5b8925=_0x5b8925[_0x1823af(0x106)](_0x4b0335,_0x1823af(0x11c)+_0x2d76f8+_0x1823af(0x160)),_0x58e0df[_0x2d76f8]=_0x4b0335;});}const _0x2e551b=(_0x5b8925[_0x4f4376(0x116)](_0x479224)||[])['filter'](_0x106c5b=>hasChinese(_0x106c5b));return _0x2e551b[_0x4f4376(0x124)](_0x2ff0d2=>{const _0x2e72e1=_0x4f4376,_0x2664c8=getTranslateKey(_0x2ff0d2,_0x44b1ae);_0x5b8925=_0x5b8925['replace'](_0x2ff0d2,_0x13a51f[_0x2e72e1(0x106)](_0x2e72e1(0x109),'\x27'+_0x2664c8+'\x27')),_0x58e0df[_0x2664c8]=_0x2ff0d2[_0x2e72e1(0x106)](/^['"]|['"]$/g,'');}),{'content':_0x5b8925,'obj':_0x58e0df};}function a0_0x5ebd(_0x296b81,_0x1786e5){const _0x6248fb=a0_0x6248();return a0_0x5ebd=function(_0x5ebdda,_0x407056){_0x5ebdda=_0x5ebdda-0xfc;let _0x44e880=_0x6248fb[_0x5ebdda];return _0x44e880;},a0_0x5ebd(_0x296b81,_0x1786e5);}function outputLangFile(_0x53643f,_0x37a71a){const _0x5144df=a0_0x20805d;if(config[_0x5144df(0x118)]==_0x5144df(0x104)){const _0x4c52c1=_0x53643f[_0x5144df(0x106)](/\.(\w+)$/,'.lang.$1');fs['writeFileSync'](_0x4c52c1,_0x37a71a);}else config[_0x5144df(0x118)]==_0x5144df(0x112)&&fs['writeFileSync'](_0x53643f,_0x37a71a);}async function outputLocalFile(_0x3a7a71){const _0x541fa8=a0_0x20805d,_0x3fa081=path[_0x541fa8(0x144)](_path,config['output']);if(/\.\w+$/g['test'](_0x3fa081)){const _0x528c1c=path[_0x541fa8(0x137)](_0x3fa081);!fs[_0x541fa8(0x13f)](_0x528c1c)&&fs[_0x541fa8(0x15e)](_0x528c1c,{'recursive':!![]});const _0x1d2af8=path[_0x541fa8(0x105)](_0x3fa081);handleLocalFile(_0x3a7a71,_0x3fa081,!![]);for(let _0x110507=0x0;_0x110507<config[_0x541fa8(0x130)]['length'];_0x110507++){const _0xbe5931=config[_0x541fa8(0x130)][_0x110507];_0xbe5931=='zh'||_0xbe5931[_0x541fa8(0x115)]()==_0x541fa8(0x155)?await handleLocalFile(_0x3a7a71,path[_0x541fa8(0x144)](path['dirname'](_0x3fa081),''+_0xbe5931+_0x1d2af8)):await handleLocalFile(_0x3a7a71,path[_0x541fa8(0x144)](path['dirname'](_0x3fa081),''+_0xbe5931+_0x1d2af8),![],config[_0x541fa8(0x145)][_0x541fa8(0x10c)](_0xbe5931),_0xbe5931);}statisticalSort(_0x3a7a71);}else{!fs[_0x541fa8(0x13f)](_0x3fa081)&&fs[_0x541fa8(0x15e)](_0x3fa081,{'recursive':!![]});handleLocalFile(_0x3a7a71,path[_0x541fa8(0x144)](_0x3fa081,_0x541fa8(0x150)),!![]);for(let _0x382be5=0x0;_0x382be5<config['locals'][_0x541fa8(0x121)];_0x382be5++){const _0x8e3a1b=config[_0x541fa8(0x130)][_0x382be5];_0x8e3a1b=='zh'||_0x8e3a1b[_0x541fa8(0x115)]()=='zh_cn'?await handleLocalFile(_0x3a7a71,path[_0x541fa8(0x144)](_0x3fa081,_0x8e3a1b+'.js')):await handleLocalFile(_0x3a7a71,path[_0x541fa8(0x144)](_0x3fa081,_0x8e3a1b+_0x541fa8(0x12b)),![],config[_0x541fa8(0x145)][_0x541fa8(0x10c)](_0x8e3a1b),_0x8e3a1b);}statisticalSort(_0x3a7a71);}}async function handleLocalFile(_0x19ab68,_0x240ad0,_0x1bf6a1,_0x1d8d76,_0x3a3e0b){const _0x56ead8=function(_0x396111){const _0x507387=a0_0x5ebd,_0x82edeb=path['extname'](_0x240ad0);if(_0x82edeb==_0x507387(0x12b)){let _0x1f7f8a=Object['keys'](_0x396111)[_0x507387(0x126)](_0x5d1044=>'\x20\x20'+_0x5d1044+_0x507387(0x168)+_0x396111[_0x5d1044]+'\x22')[_0x507387(0x144)](',\x0d');fs[_0x507387(0x129)](_0x240ad0,_0x507387(0x161)+_0x1f7f8a+'\x0d}',{'flag':'w'});}else{let _0x58fd34=Object[_0x507387(0x13d)](_0x396111)['map'](_0x3b8355=>_0x507387(0x156)+_0x3b8355+_0x507387(0x132)+_0x396111[_0x3b8355]+'\x22')['join'](',\x0d');fs[_0x507387(0x129)](_0x240ad0,'{\x0d'+_0x58fd34+'\x0d}',{'flag':'w'});}};let _0x38dd23,_0x3af742;getFileContent(_0x240ad0,_0x37c15f=>{const _0x2230a1=a0_0x5ebd,_0x32afbc=getExtraValues(_0x19ab68,_0x37c15f),_0x1dfb75=getExtraValues(_0x37c15f,_0x19ab68);_0x1bf6a1?(_0x38dd23={..._0x19ab68},addCount=Object[_0x2230a1(0x13d)](_0x32afbc)[_0x2230a1(0x121)],delCount=Object[_0x2230a1(0x13d)](_0x1dfb75)['length']):(_0x38dd23=Object[_0x2230a1(0xfe)]({},_0x19ab68,_0x37c15f),_0x3af742=_0x32afbc),Object['keys'](_0x1dfb75)[_0x2230a1(0x124)](_0x5dc7d1=>{delete _0x38dd23[_0x5dc7d1];});},()=>{const _0x1ad6ec=a0_0x5ebd;_0x1bf6a1&&(addCount=Object[_0x1ad6ec(0x13d)](_0x19ab68)[_0x1ad6ec(0x121)],delCount=0x0),_0x38dd23={..._0x19ab68},_0x3af742={..._0x19ab68};}),_0x1d8d76?await translater(_0x3af742,_0x3a3e0b,config,_0x2624ad=>{const _0xd5f85d=a0_0x5ebd;_0x38dd23=Object[_0xd5f85d(0xfe)](_0x38dd23,_0x2624ad),_0x56ead8(_0x38dd23);}):_0x56ead8(_0x38dd23);}function getExtraValues(_0x2e8c24,_0x10487c){const _0x2bfbd3=a0_0x20805d,_0x33f33d=Object['keys'](_0x2e8c24)[_0x2bfbd3(0x125)](_0x48a464=>!_0x10487c[_0x2bfbd3(0x128)](_0x48a464)),_0x42f34c={};return _0x33f33d[_0x2bfbd3(0x124)](_0x374373=>{_0x42f34c[_0x374373]=_0x2e8c24[_0x374373];}),_0x42f34c;}function replaceStringFromTo(_0x56e86b,_0x30eb01,_0x1afebc,_0x3de7f6){const _0x59f573=a0_0x20805d;return _0x56e86b['substring'](0x0,_0x30eb01)+_0x3de7f6+_0x56e86b[_0x59f573(0x152)](_0x1afebc);}function statisticalSort(_0x59949d){const _0x17f7c5=a0_0x20805d,_0x8dd1d1=Object[_0x17f7c5(0x11e)](_0x59949d);let _0x5c43ac={};for(let _0x20b6b7=0x0;_0x20b6b7<_0x8dd1d1[_0x17f7c5(0x121)];_0x20b6b7++){const _0x44a6c0=_0x8dd1d1[_0x20b6b7];_0x5c43ac[_0x44a6c0]?_0x5c43ac[_0x44a6c0]++:_0x5c43ac[_0x44a6c0]=0x1;}const _0x2931fb=Object[_0x17f7c5(0x11f)](_0x5c43ac)[_0x17f7c5(0x107)]((_0x3ff49b,_0x4fd5e9)=>_0x4fd5e9[0x1]-_0x3ff49b[0x1]);console['log'](new Array(0x50)[_0x17f7c5(0x144)]('-')),console[_0x17f7c5(0x147)]('-\x20统计:------\x20中文字段统计频率排行榜,总计\x20'+Object['keys'](_0x59949d)[_0x17f7c5(0x121)]+_0x17f7c5(0x120)+addCount+_0x17f7c5(0x119)+delCount+_0x17f7c5(0x122));for(let _0x523f43=0x0;_0x523f43<_0x2931fb[_0x17f7c5(0x121)];_0x523f43++){const _0x368b24=_0x2931fb[_0x523f43];console['log'](_0x17f7c5(0x142)+(_0x523f43+0x1)+'名('+_0x368b24[0x1]+'):'+_0x368b24[0x0]);if(_0x523f43>=0x9)break;}console[_0x17f7c5(0x147)]('-\x20统计:------\x20中文字段统计频率排行榜,频率过高建议加入自定义key!'),console[_0x17f7c5(0x147)](new Array(0x50)[_0x17f7c5(0x144)]('-'));}

@@ -1,1 +0,1 @@

(function(_0x3e53a4,_0x58ab41){const _0x40866c=a1_0x40c1,_0x36152f=_0x3e53a4();while(!![]){try{const _0x5399e6=parseInt(_0x40866c(0x166))/0x1+-parseInt(_0x40866c(0x147))/0x2*(parseInt(_0x40866c(0x150))/0x3)+-parseInt(_0x40866c(0x14a))/0x4*(-parseInt(_0x40866c(0x14f))/0x5)+-parseInt(_0x40866c(0x157))/0x6*(parseInt(_0x40866c(0x164))/0x7)+-parseInt(_0x40866c(0x165))/0x8*(parseInt(_0x40866c(0x169))/0x9)+parseInt(_0x40866c(0x163))/0xa*(-parseInt(_0x40866c(0x158))/0xb)+parseInt(_0x40866c(0x15b))/0xc*(parseInt(_0x40866c(0x16a))/0xd);if(_0x5399e6===_0x58ab41)break;else _0x36152f['push'](_0x36152f['shift']());}catch(_0x554dbb){_0x36152f['push'](_0x36152f['shift']());}}}(a1_0x10a8,0x4bb81));function makeMap(_0x57b26e,_0x116c9e){const _0x4a58ce=a1_0x40c1,_0x382df0=Object['create'](null),_0x5c1524=_0x57b26e[_0x4a58ce(0x15a)](',');for(let _0x3c7d01=0x0;_0x3c7d01<_0x5c1524[_0x4a58ce(0x14b)];_0x3c7d01++){_0x382df0[_0x5c1524[_0x3c7d01]]=!![];}return _0x116c9e?_0x4782db=>_0x382df0[_0x4782db['toLowerCase']()]:_0x3ba57e=>_0x382df0[_0x3ba57e];}const doctype=/^<!DOCTYPE [^>]+>/i,endTag=/^<\/([a-zA-Z_][\-\.0-9_a-zA-Z]*)[^>]*>/,startTagOpen=/^<([a-zA-Z_][\-\.0-9_a-zA-Z]*)/,attribute=/^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,dynamicArgAttribute=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+?\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,startTagClose=/^\s*(\/?)>/,isPlainTextElement=makeMap('script,style,textarea',!![]),isIgnoreNewlineTag=makeMap('pre,textarea',!![]),shouldIgnoreFirstNewline=(_0xdd1da1,_0x1254b9)=>_0xdd1da1&&isIgnoreNewlineTag(_0xdd1da1)&&_0x1254b9[0x0]==='\x0a',decodingMap={'&lt;':'<','&gt;':'>','&quot;':'\x22','&amp;':'&','&#10;':'\x0a','&#9;':'\x09','&#39;':'\x27'},encodedAttr=/&(?:lt|gt|quot|amp|#39);/g,encodedAttrWithNewLines=/&(?:lt|gt|quot|amp|#39|#10|#9);/g;function decodeAttr(_0x134db4,_0x408895){const _0x146f65=_0x408895?encodedAttrWithNewLines:encodedAttr;return _0x134db4['replace'](_0x146f65,_0x5d8d12=>decodingMap[_0x5d8d12]);}parseHTML('<div><span\x20class=\x22title\x22>测试</span><my-component/></div>');function a1_0x40c1(_0x69f1e3,_0x1e38c2){const _0x10a832=a1_0x10a8();return a1_0x40c1=function(_0x40c1cb,_0x28bcde){_0x40c1cb=_0x40c1cb-0x147;let _0x30de3b=_0x10a832[_0x40c1cb];return _0x30de3b;},a1_0x40c1(_0x69f1e3,_0x1e38c2);}function parseHTML(_0xa7d694,_0x3bf8fc={'shouldDecodeNewlines':!![],'shouldDecodeNewlinesForHref':!![]}){const _0x4b7fd7=a1_0x40c1,_0x530c27=[];let _0x46fae6=0x0,_0x782deb,_0x52946f;while(_0xa7d694){_0x782deb=_0xa7d694,console['log'](_0xa7d694);if(!_0x52946f||!isPlainTextElement(_0x52946f)){let _0x297b47=_0xa7d694['indexOf']('<');if(_0x297b47===0x0){const _0x1c37a5=_0xa7d694[_0x4b7fd7(0x155)](doctype);if(_0x1c37a5){_0x2a6937(_0x1c37a5[0x0][_0x4b7fd7(0x14b)]);continue;}const _0x479d62=_0xa7d694[_0x4b7fd7(0x155)](endTag);if(_0x479d62){console['log'](_0x4b7fd7(0x161)+_0x479d62[0x1]);const _0x8cfa99=_0x46fae6;_0x2a6937(_0x479d62[0x0][_0x4b7fd7(0x14b)]),_0x37efbe(_0x479d62[0x1],_0x8cfa99,_0x46fae6);continue;}const _0x4d9894=_0x178235();if(_0x4d9894){console[_0x4b7fd7(0x153)]('【'+(_0x4d9894[_0x4b7fd7(0x162)]?'闭合标签':'开始标签')+'】:'+_0x4d9894[_0x4b7fd7(0x14c)]);continue;}}let _0x344e4e,_0x27edac,_0x3f8741;if(_0x297b47>=0x0){_0x27edac=_0xa7d694[_0x4b7fd7(0x14e)](_0x297b47);while(!endTag[_0x4b7fd7(0x167)](_0x27edac)&&!startTagOpen['test'](_0x27edac)){_0x3f8741=_0x27edac[_0x4b7fd7(0x15d)]('<',0x1);if(_0x3f8741<0x0)break;_0x297b47+=_0x3f8741,_0x27edac=_0xa7d694[_0x4b7fd7(0x14e)](_0x297b47);}_0x344e4e=_0xa7d694[_0x4b7fd7(0x160)](0x0,_0x297b47),console[_0x4b7fd7(0x153)](_0x4b7fd7(0x14d)+_0x344e4e);}_0x297b47<0x0&&(_0x344e4e=_0xa7d694),_0x344e4e&&_0x2a6937(_0x344e4e[_0x4b7fd7(0x14b)]);}else{}if(_0xa7d694===_0x782deb){}}function _0x2a6937(_0x12ae47){const _0x81e687=_0x4b7fd7;_0x46fae6+=_0x12ae47,_0xa7d694=_0xa7d694[_0x81e687(0x160)](_0x12ae47);}function _0x178235(){const _0x41de00=_0x4b7fd7,_0xecaff8=_0xa7d694[_0x41de00(0x155)](startTagOpen);if(_0xecaff8){const _0xf8121d={'tagName':_0xecaff8[0x1],'attrs':[],'start':_0x46fae6};_0x2a6937(_0xecaff8[0x0][_0x41de00(0x14b)]);let _0x3682b2,_0x4d28eb;while(!(_0x3682b2=_0xa7d694['match'](startTagClose))&&(_0x4d28eb=_0xa7d694[_0x41de00(0x155)](dynamicArgAttribute)||_0xa7d694[_0x41de00(0x155)](attribute))){_0x4d28eb[_0x41de00(0x154)]=_0x46fae6,_0x2a6937(_0x4d28eb[0x0][_0x41de00(0x14b)]),_0x4d28eb[_0x41de00(0x168)]=_0x46fae6,_0xf8121d[_0x41de00(0x149)]['push'](_0x4d28eb);}if(_0x3682b2)return _0xf8121d[_0x41de00(0x162)]=_0x3682b2[0x1],_0x2a6937(_0x3682b2[0x0]['length']),_0xf8121d[_0x41de00(0x168)]=_0x46fae6,_0xf8121d;}}function _0xca2616(_0xf118e){const _0x49e14a=_0x4b7fd7,_0x57334a=_0xf118e[_0x49e14a(0x14c)],_0x5d26c0=!!_0xf118e[_0x49e14a(0x162)],_0x3d0a34=_0xf118e[_0x49e14a(0x149)][_0x49e14a(0x14b)],_0x2fd90d=new Array(_0x3d0a34);for(let _0x5c706c=0x0;_0x5c706c<_0x3d0a34;_0x5c706c++){const _0x41e557=_0xf118e['attrs'][_0x5c706c],_0x1a6096=_0x41e557[0x3]||_0x41e557[0x4]||_0x41e557[0x5]||'',_0x490f27=_0x57334a==='a'&&_0x41e557[0x1]==='href'?_0x3bf8fc['shouldDecodeNewlinesForHref']:_0x3bf8fc['shouldDecodeNewlines'];_0x2fd90d[_0x5c706c]={'name':_0x41e557[0x1],'value':decodeAttr(_0x1a6096,_0x490f27)};}!_0x5d26c0&&(_0x530c27[_0x49e14a(0x156)]({'tag':_0x57334a,'lowerCasedTag':_0x57334a[_0x49e14a(0x151)](),'attrs':_0x2fd90d,'start':_0xf118e[_0x49e14a(0x154)],'end':_0xf118e['end']}),_0x52946f=_0x57334a);}function _0x37efbe(_0x2a5221,_0x549b0f,_0x3f3fdb){const _0x299327=_0x4b7fd7;let _0x50ccc0,_0x58d58d;if(_0x549b0f==null)_0x549b0f=_0x46fae6;if(_0x3f3fdb==null)_0x3f3fdb=_0x46fae6;if(_0x2a5221){_0x58d58d=_0x2a5221[_0x299327(0x151)]();for(_0x50ccc0=_0x530c27[_0x299327(0x14b)]-0x1;_0x50ccc0>=0x0;_0x50ccc0--){if(_0x530c27[_0x50ccc0][_0x299327(0x152)]===_0x58d58d)break;}}else _0x50ccc0=0x0;console[_0x299327(0x153)](_0x299327(0x15c)+_0x50ccc0);if(_0x50ccc0>=0x0){for(let _0x59de9c=_0x530c27[_0x299327(0x14b)]-0x1;_0x59de9c>=_0x50ccc0;_0x59de9c--){(_0x59de9c>_0x50ccc0||!_0x2a5221)&&console[_0x299327(0x15e)](_0x299327(0x148)+_0x530c27[_0x59de9c]['tag']+_0x299327(0x15f));}_0x530c27[_0x299327(0x14b)]=_0x50ccc0,_0x52946f=_0x50ccc0&&_0x530c27[_0x50ccc0-0x1][_0x299327(0x159)];}}}function a1_0x10a8(){const _0x455beb=['288oiaHGY','13DZVrlS','1037182QdItwy','tag\x20<','attrs','8636BnVuHe','length','tagName','【文本内容】:','slice','875noxqiz','3ASnxyG','toLowerCase','lowerCasedTag','log','start','match','push','11082oHmckO','1932326ZVlLyG','tag','split','10993452JLNaHJ','ssss','indexOf','warn','>\x20has\x20no\x20matching\x20end\x20tag.','substring','【结束标签】:','unarySlash','10VoaATs','1673qatXqC','42248RlovFc','320881sHTbiF','test','end'];a1_0x10a8=function(){return _0x455beb;};return a1_0x10a8();}
const a1_0x12b562=a1_0x26d6;(function(_0x431677,_0x2e7fa3){const _0x336d6e=a1_0x26d6,_0x3bb96e=_0x431677();while(!![]){try{const _0x50e33d=parseInt(_0x336d6e(0x171))/0x1*(-parseInt(_0x336d6e(0x172))/0x2)+parseInt(_0x336d6e(0x165))/0x3*(-parseInt(_0x336d6e(0x16c))/0x4)+parseInt(_0x336d6e(0x16a))/0x5+-parseInt(_0x336d6e(0x14f))/0x6+parseInt(_0x336d6e(0x156))/0x7*(parseInt(_0x336d6e(0x14e))/0x8)+parseInt(_0x336d6e(0x167))/0x9*(-parseInt(_0x336d6e(0x15a))/0xa)+parseInt(_0x336d6e(0x174))/0xb*(parseInt(_0x336d6e(0x150))/0xc);if(_0x50e33d===_0x2e7fa3)break;else _0x3bb96e['push'](_0x3bb96e['shift']());}catch(_0x3a3c84){_0x3bb96e['push'](_0x3bb96e['shift']());}}}(a1_0x2570,0xbacdf));function makeMap(_0x4e313c,_0x3aa02a){const _0x466299=a1_0x26d6,_0x5a6ac1=Object[_0x466299(0x169)](null),_0x50000b=_0x4e313c[_0x466299(0x160)](',');for(let _0x490ccd=0x0;_0x490ccd<_0x50000b[_0x466299(0x170)];_0x490ccd++){_0x5a6ac1[_0x50000b[_0x490ccd]]=!![];}return _0x3aa02a?_0x15abeb=>_0x5a6ac1[_0x15abeb[_0x466299(0x16e)]()]:_0x268710=>_0x5a6ac1[_0x268710];}const doctype=/^<!DOCTYPE [^>]+>/i,endTag=/^<\/([a-zA-Z_][\-\.0-9_a-zA-Z]*)[^>]*>/,startTagOpen=/^<([a-zA-Z_][\-\.0-9_a-zA-Z]*)/,attribute=/^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,dynamicArgAttribute=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+?\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,startTagClose=/^\s*(\/?)>/,isPlainTextElement=makeMap(a1_0x12b562(0x159),!![]),isIgnoreNewlineTag=makeMap(a1_0x12b562(0x151),!![]),shouldIgnoreFirstNewline=(_0x15b269,_0x3f6389)=>_0x15b269&&isIgnoreNewlineTag(_0x15b269)&&_0x3f6389[0x0]==='\x0a',decodingMap={'&lt;':'<','&gt;':'>','&quot;':'\x22','&amp;':'&','&#10;':'\x0a','&#9;':'\x09','&#39;':'\x27'},encodedAttr=/&(?:lt|gt|quot|amp|#39);/g,encodedAttrWithNewLines=/&(?:lt|gt|quot|amp|#39|#10|#9);/g;function decodeAttr(_0x5dd894,_0x556832){const _0x476b84=a1_0x12b562,_0x288a93=_0x556832?encodedAttrWithNewLines:encodedAttr;return _0x5dd894[_0x476b84(0x162)](_0x288a93,_0x29db02=>decodingMap[_0x29db02]);}function a1_0x2570(){const _0x1100e8=['闭合标签','push','7diSusa','lowerCasedTag','tag\x20<','script,style,textarea','10KVGoJL','tagName','warn','href','slice','substring','split','shouldDecodeNewlines','replace','>\x20has\x20no\x20matching\x20end\x20tag.','unarySlash','6sOFhOq','tag','7993593XdfZer','end','create','306580yEOZmW','【结束标签】:','1871392TXUnNe','indexOf','toLowerCase','start','length','1072bBLnoL','988snNMNO','shouldDecodeNewlinesForHref','2255xyIoUm','开始标签','log','test','9442824tZKZEF','6235212bioRXy','170700iLQWoL','pre,textarea','match','<div><span\x20class=\x22title\x22>测试</span><my-component/></div>'];a1_0x2570=function(){return _0x1100e8;};return a1_0x2570();}function a1_0x26d6(_0x55311a,_0x149da3){const _0x2570c1=a1_0x2570();return a1_0x26d6=function(_0x26d65e,_0x22d9aa){_0x26d65e=_0x26d65e-0x14d;let _0x23a9ad=_0x2570c1[_0x26d65e];return _0x23a9ad;},a1_0x26d6(_0x55311a,_0x149da3);}parseHTML(a1_0x12b562(0x153));function parseHTML(_0x51f719,_0x8c3fa={'shouldDecodeNewlines':!![],'shouldDecodeNewlinesForHref':!![]}){const _0x29c954=a1_0x12b562,_0x900eff=[];let _0x4dd429=0x0,_0x344618,_0x58111b;while(_0x51f719){_0x344618=_0x51f719,console[_0x29c954(0x176)](_0x51f719);if(!_0x58111b||!isPlainTextElement(_0x58111b)){let _0x2dca3c=_0x51f719[_0x29c954(0x16d)]('<');if(_0x2dca3c===0x0){const _0x138ab2=_0x51f719[_0x29c954(0x152)](doctype);if(_0x138ab2){_0x5da432(_0x138ab2[0x0][_0x29c954(0x170)]);continue;}const _0x3df24d=_0x51f719['match'](endTag);if(_0x3df24d){console['log'](_0x29c954(0x16b)+_0x3df24d[0x1]);const _0x21bbe3=_0x4dd429;_0x5da432(_0x3df24d[0x0][_0x29c954(0x170)]),_0x58fc37(_0x3df24d[0x1],_0x21bbe3,_0x4dd429);continue;}const _0x4d2b3c=_0x44707e();if(_0x4d2b3c){console[_0x29c954(0x176)]('【'+(_0x4d2b3c[_0x29c954(0x164)]?_0x29c954(0x154):_0x29c954(0x175))+'】:'+_0x4d2b3c[_0x29c954(0x15b)]);continue;}}let _0x6f43e8,_0x45acb8,_0x200579;if(_0x2dca3c>=0x0){_0x45acb8=_0x51f719[_0x29c954(0x15e)](_0x2dca3c);while(!endTag[_0x29c954(0x14d)](_0x45acb8)&&!startTagOpen['test'](_0x45acb8)){_0x200579=_0x45acb8[_0x29c954(0x16d)]('<',0x1);if(_0x200579<0x0)break;_0x2dca3c+=_0x200579,_0x45acb8=_0x51f719[_0x29c954(0x15e)](_0x2dca3c);}_0x6f43e8=_0x51f719['substring'](0x0,_0x2dca3c),console[_0x29c954(0x176)]('【文本内容】:'+_0x6f43e8);}_0x2dca3c<0x0&&(_0x6f43e8=_0x51f719),_0x6f43e8&&_0x5da432(_0x6f43e8[_0x29c954(0x170)]);}else{}if(_0x51f719===_0x344618){}}function _0x5da432(_0x3dca16){const _0x26cd52=_0x29c954;_0x4dd429+=_0x3dca16,_0x51f719=_0x51f719[_0x26cd52(0x15f)](_0x3dca16);}function _0x44707e(){const _0x34d990=_0x29c954,_0x45065c=_0x51f719[_0x34d990(0x152)](startTagOpen);if(_0x45065c){const _0x50b95c={'tagName':_0x45065c[0x1],'attrs':[],'start':_0x4dd429};_0x5da432(_0x45065c[0x0][_0x34d990(0x170)]);let _0x43ba9f,_0x4c89ee;while(!(_0x43ba9f=_0x51f719['match'](startTagClose))&&(_0x4c89ee=_0x51f719[_0x34d990(0x152)](dynamicArgAttribute)||_0x51f719[_0x34d990(0x152)](attribute))){_0x4c89ee['start']=_0x4dd429,_0x5da432(_0x4c89ee[0x0][_0x34d990(0x170)]),_0x4c89ee[_0x34d990(0x168)]=_0x4dd429,_0x50b95c['attrs'][_0x34d990(0x155)](_0x4c89ee);}if(_0x43ba9f)return _0x50b95c[_0x34d990(0x164)]=_0x43ba9f[0x1],_0x5da432(_0x43ba9f[0x0]['length']),_0x50b95c[_0x34d990(0x168)]=_0x4dd429,_0x50b95c;}}function _0x55ee31(_0x3145e9){const _0x31bf51=_0x29c954,_0x173456=_0x3145e9[_0x31bf51(0x15b)],_0x549715=!!_0x3145e9[_0x31bf51(0x164)],_0x3894b0=_0x3145e9['attrs']['length'],_0x396f22=new Array(_0x3894b0);for(let _0x25f0e7=0x0;_0x25f0e7<_0x3894b0;_0x25f0e7++){const _0x140a24=_0x3145e9['attrs'][_0x25f0e7],_0x41196d=_0x140a24[0x3]||_0x140a24[0x4]||_0x140a24[0x5]||'',_0x1ce298=_0x173456==='a'&&_0x140a24[0x1]===_0x31bf51(0x15d)?_0x8c3fa[_0x31bf51(0x173)]:_0x8c3fa[_0x31bf51(0x161)];_0x396f22[_0x25f0e7]={'name':_0x140a24[0x1],'value':decodeAttr(_0x41196d,_0x1ce298)};}!_0x549715&&(_0x900eff['push']({'tag':_0x173456,'lowerCasedTag':_0x173456['toLowerCase'](),'attrs':_0x396f22,'start':_0x3145e9[_0x31bf51(0x16f)],'end':_0x3145e9[_0x31bf51(0x168)]}),_0x58111b=_0x173456);}function _0x58fc37(_0x778e5f,_0x16e964,_0x5430e0){const _0x330d87=_0x29c954;let _0x53dff9,_0x27f521;if(_0x16e964==null)_0x16e964=_0x4dd429;if(_0x5430e0==null)_0x5430e0=_0x4dd429;if(_0x778e5f){_0x27f521=_0x778e5f[_0x330d87(0x16e)]();for(_0x53dff9=_0x900eff['length']-0x1;_0x53dff9>=0x0;_0x53dff9--){if(_0x900eff[_0x53dff9][_0x330d87(0x157)]===_0x27f521)break;}}else _0x53dff9=0x0;console[_0x330d87(0x176)]('ssss'+_0x53dff9);if(_0x53dff9>=0x0){for(let _0x639da1=_0x900eff[_0x330d87(0x170)]-0x1;_0x639da1>=_0x53dff9;_0x639da1--){(_0x639da1>_0x53dff9||!_0x778e5f)&&console[_0x330d87(0x15c)](_0x330d87(0x158)+_0x900eff[_0x639da1][_0x330d87(0x166)]+_0x330d87(0x163));}_0x900eff[_0x330d87(0x170)]=_0x53dff9,_0x58111b=_0x53dff9&&_0x900eff[_0x53dff9-0x1]['tag'];}}}

@@ -1,1 +0,1 @@

function a2_0x5aa5(_0xaf2042,_0x21682f){const _0x266983=a2_0x2669();return a2_0x5aa5=function(_0x5aa540,_0x2bbcb3){_0x5aa540=_0x5aa540-0x1df;let _0x1374f7=_0x266983[_0x5aa540];return _0x1374f7;},a2_0x5aa5(_0xaf2042,_0x21682f);}(function(_0x219567,_0x5d23d0){const _0x59264d=a2_0x5aa5,_0x285c68=_0x219567();while(!![]){try{const _0x5ce9cc=-parseInt(_0x59264d(0x1ea))/0x1*(parseInt(_0x59264d(0x1f0))/0x2)+-parseInt(_0x59264d(0x1f4))/0x3+parseInt(_0x59264d(0x1ee))/0x4*(parseInt(_0x59264d(0x1e0))/0x5)+parseInt(_0x59264d(0x1ec))/0x6+parseInt(_0x59264d(0x1e5))/0x7*(parseInt(_0x59264d(0x1f7))/0x8)+-parseInt(_0x59264d(0x1e3))/0x9*(parseInt(_0x59264d(0x1eb))/0xa)+-parseInt(_0x59264d(0x1f3))/0xb*(-parseInt(_0x59264d(0x1e9))/0xc);if(_0x5ce9cc===_0x5d23d0)break;else _0x285c68['push'](_0x285c68['shift']());}catch(_0xc80bad){_0x285c68['push'](_0x285c68['shift']());}}}(a2_0x2669,0x35965));const endTag=/^<\/([a-zA-Z_][\-\.0-9_a-zA-Z]*)[^>]*>/,startTagOpen=/^<([a-zA-Z_][\-\.0-9_a-zA-Z]*)/,attribute=/^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,dynamicArgAttribute=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+?\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,startTagClose=/^\s*(\/?)>/;exports['parseHTML']=function(_0xcbfd60,_0x5db151,_0x2444be){const _0x5eccda=a2_0x5aa5,_0x22345b=[];let _0x35c091=0x0,_0x1f81fb,_0x44cec0;while(_0xcbfd60){_0x1f81fb=_0xcbfd60;let _0x5d0080=_0xcbfd60[_0x5eccda(0x1e1)]('<');if(_0x5d0080===0x0){const _0x394d7d=_0xcbfd60[_0x5eccda(0x1e2)](endTag);if(_0x394d7d){const _0x443363=_0x35c091;_0x3928e6(_0x394d7d[0x0][_0x5eccda(0x1f1)]),_0x2e4ced(_0x394d7d[0x1],_0x443363,_0x35c091);continue;}const _0x3a2de3=_0x3f904();if(_0x3a2de3){_0x1a5a28(_0x3a2de3);continue;}}let _0x29fe01,_0x281dd9,_0x44ea38;if(_0x5d0080>=0x0){_0x281dd9=_0xcbfd60[_0x5eccda(0x1e8)](_0x5d0080);while(!endTag['test'](_0x281dd9)&&!startTagOpen['test'](_0x281dd9)){_0x44ea38=_0x281dd9[_0x5eccda(0x1e1)]('<',0x1);if(_0x44ea38<0x0)break;_0x5d0080+=_0x44ea38,_0x281dd9=_0xcbfd60[_0x5eccda(0x1e8)](_0x5d0080);}_0x29fe01=_0xcbfd60[_0x5eccda(0x1e7)](0x0,_0x5d0080);}_0x5d0080<0x0&&(_0x29fe01=_0xcbfd60);if(_0x29fe01){const _0x7a603b=_0x35c091;_0x3928e6(_0x29fe01[_0x5eccda(0x1f1)]),_0x5db151({'value':_0x29fe01,'start':_0x7a603b,'end':_0x35c091});}}function _0x3928e6(_0x369ce9){const _0x457741=_0x5eccda;_0x35c091+=_0x369ce9,_0xcbfd60=_0xcbfd60[_0x457741(0x1e7)](_0x369ce9);}function _0x3f904(){const _0x123f03=_0x5eccda,_0x5851fb=_0xcbfd60['match'](startTagOpen);if(_0x5851fb){const _0x13b06e={'tagName':_0x5851fb[0x1],'attrs':[],'start':_0x35c091};_0x3928e6(_0x5851fb[0x0][_0x123f03(0x1f1)]);let _0x404c6a,_0x2a6d69;while(!(_0x404c6a=_0xcbfd60['match'](startTagClose))&&(_0x2a6d69=_0xcbfd60[_0x123f03(0x1e2)](dynamicArgAttribute)||_0xcbfd60[_0x123f03(0x1e2)](attribute))){_0x2a6d69['start']=_0x35c091,_0x3928e6(_0x2a6d69[0x0][_0x123f03(0x1f1)]),_0x2a6d69[_0x123f03(0x1ed)]=_0x35c091,_0x13b06e[_0x123f03(0x1f5)][_0x123f03(0x1e4)](_0x2a6d69);}if(_0x404c6a)return _0x13b06e['unarySlash']=_0x404c6a[0x1],_0x3928e6(_0x404c6a[0x0][_0x123f03(0x1f1)]),_0x13b06e[_0x123f03(0x1ed)]=_0x35c091,_0x13b06e;}}function _0x1a5a28(_0x124910){const _0x5a0b87=_0x5eccda,_0x5e6d2c=_0x124910['tagName'],_0x25669c=!!_0x124910[_0x5a0b87(0x1e6)],_0x52606c=_0x124910[_0x5a0b87(0x1f5)]['length'],_0x325cb0=new Array(_0x52606c);for(let _0x259eba=0x0;_0x259eba<_0x52606c;_0x259eba++){const _0x280b8f=_0x124910[_0x5a0b87(0x1f5)][_0x259eba],_0x41b4c1=_0x280b8f[0x3]||_0x280b8f[0x4]||_0x280b8f[0x5]||'';_0x325cb0[_0x259eba]={'name':_0x280b8f[0x1],'value':_0x41b4c1,'target':_0x280b8f[0x0],'start':_0x280b8f[_0x5a0b87(0x1ef)],'end':_0x280b8f['end']};}!_0x25669c&&(_0x22345b[_0x5a0b87(0x1e4)]({'tag':_0x5e6d2c,'lowerCasedTag':_0x5e6d2c[_0x5a0b87(0x1df)](),'attrs':_0x325cb0,'start':_0x124910[_0x5a0b87(0x1ef)],'end':_0x124910[_0x5a0b87(0x1ed)]}),_0x2444be({'attrs':_0x325cb0,'start':_0x124910[_0x5a0b87(0x1ef)],'end':_0x124910[_0x5a0b87(0x1ed)]}),_0x44cec0=_0x5e6d2c);}_0x2e4ced();function _0x2e4ced(_0x4b6186,_0x29d54e,_0x3bb7f1){const _0x5803d6=_0x5eccda;let _0x715fc6,_0x593d98;if(_0x29d54e==null)_0x29d54e=_0x35c091;if(_0x3bb7f1==null)_0x3bb7f1=_0x35c091;if(_0x4b6186){_0x593d98=_0x4b6186[_0x5803d6(0x1df)]();for(_0x715fc6=_0x22345b[_0x5803d6(0x1f1)]-0x1;_0x715fc6>=0x0;_0x715fc6--){if(_0x22345b[_0x715fc6][_0x5803d6(0x1f6)]===_0x593d98)break;}}else _0x715fc6=0x0;if(_0x715fc6>=0x0){for(let _0x5a6a32=_0x22345b[_0x5803d6(0x1f1)]-0x1;_0x5a6a32>=_0x715fc6;_0x5a6a32--){if(_0x5a6a32>_0x715fc6||!_0x4b6186){}}_0x22345b[_0x5803d6(0x1f1)]=_0x715fc6,_0x44cec0=_0x715fc6&&_0x22345b[_0x715fc6-0x1][_0x5803d6(0x1f2)];}}};function a2_0x2669(){const _0x2f33ff=['10fJjnhY','357012RHrusw','end','735608AavUyb','start','2TUhxkl','length','tag','462TdIrBi','1093980MCZuqi','attrs','lowerCasedTag','16SaxFhQ','toLowerCase','10wxRixB','indexOf','match','3950847TgedxT','push','1202663fvsuLH','unarySlash','substring','slice','122676WcYsUg','177154DjDBFt'];a2_0x2669=function(){return _0x2f33ff;};return a2_0x2669();}
const a2_0x32e57f=a2_0x3e08;function a2_0x2762(){const _0xd1ab=['2183682dNeTdS','attrs','2029573HxUPlB','lowerCasedTag','tag','tagName','toLowerCase','end','5125aYxkyJ','indexOf','length','parseHTML','push','1101001nguGNv','match','substring','unarySlash','start','2198376pMRJlb','1990152REZfAK','test','1066506dOIjXu','slice','2472JxfHQa'];a2_0x2762=function(){return _0xd1ab;};return a2_0x2762();}function a2_0x3e08(_0x4f65cd,_0x2ff3fd){const _0x276281=a2_0x2762();return a2_0x3e08=function(_0x3e08e4,_0x2f5666){_0x3e08e4=_0x3e08e4-0x115;let _0x3f9661=_0x276281[_0x3e08e4];return _0x3f9661;},a2_0x3e08(_0x4f65cd,_0x2ff3fd);}(function(_0x443e16,_0x20c1bf){const _0x5c8ef1=a2_0x3e08,_0x3a432a=_0x443e16();while(!![]){try{const _0x31f603=parseInt(_0x5c8ef1(0x124))/0x1+-parseInt(_0x5c8ef1(0x117))/0x2+parseInt(_0x5c8ef1(0x12a))/0x3+parseInt(_0x5c8ef1(0x116))/0x4*(parseInt(_0x5c8ef1(0x11f))/0x5)+-parseInt(_0x5c8ef1(0x12c))/0x6+-parseInt(_0x5c8ef1(0x119))/0x7+-parseInt(_0x5c8ef1(0x129))/0x8;if(_0x31f603===_0x20c1bf)break;else _0x3a432a['push'](_0x3a432a['shift']());}catch(_0x824f37){_0x3a432a['push'](_0x3a432a['shift']());}}}(a2_0x2762,0x89933));const endTag=/^<\/([a-zA-Z_][\-\.0-9_a-zA-Z]*)[^>]*>/,startTagOpen=/^<([a-zA-Z_][\-\.0-9_a-zA-Z]*)/,attribute=/^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,dynamicArgAttribute=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+?\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,startTagClose=/^\s*(\/?)>/;exports[a2_0x32e57f(0x122)]=function(_0x48276f,_0x566f97,_0x3f33da){const _0x495b0a=a2_0x32e57f,_0x30db26=[];let _0x5dfee2=0x0,_0x435ef5,_0x2b036d;while(_0x48276f){_0x435ef5=_0x48276f;let _0x2ee5cd=_0x48276f['indexOf']('<');if(_0x2ee5cd===0x0){const _0x1bc54b=_0x48276f[_0x495b0a(0x125)](endTag);if(_0x1bc54b){const _0x4cc3ec=_0x5dfee2;_0xf8868d(_0x1bc54b[0x0]['length']),_0x28b630(_0x1bc54b[0x1],_0x4cc3ec,_0x5dfee2);continue;}const _0x17009c=_0x4b4f4a();if(_0x17009c){_0x310c4d(_0x17009c);continue;}}let _0x48a73f,_0x46aab5,_0x360524;if(_0x2ee5cd>=0x0){_0x46aab5=_0x48276f[_0x495b0a(0x115)](_0x2ee5cd);while(!endTag[_0x495b0a(0x12b)](_0x46aab5)&&!startTagOpen[_0x495b0a(0x12b)](_0x46aab5)){_0x360524=_0x46aab5[_0x495b0a(0x120)]('<',0x1);if(_0x360524<0x0)break;_0x2ee5cd+=_0x360524,_0x46aab5=_0x48276f[_0x495b0a(0x115)](_0x2ee5cd);}_0x48a73f=_0x48276f[_0x495b0a(0x126)](0x0,_0x2ee5cd);}_0x2ee5cd<0x0&&(_0x48a73f=_0x48276f);if(_0x48a73f){const _0x25160a=_0x5dfee2;_0xf8868d(_0x48a73f[_0x495b0a(0x121)]),_0x566f97({'value':_0x48a73f,'start':_0x25160a,'end':_0x5dfee2});}}function _0xf8868d(_0x79c1d6){const _0x3fda1d=_0x495b0a;_0x5dfee2+=_0x79c1d6,_0x48276f=_0x48276f[_0x3fda1d(0x126)](_0x79c1d6);}function _0x4b4f4a(){const _0x367c61=_0x495b0a,_0x3cc82d=_0x48276f[_0x367c61(0x125)](startTagOpen);if(_0x3cc82d){const _0x57f1de={'tagName':_0x3cc82d[0x1],'attrs':[],'start':_0x5dfee2};_0xf8868d(_0x3cc82d[0x0]['length']);let _0x4cfc01,_0x3fb2dc;while(!(_0x4cfc01=_0x48276f[_0x367c61(0x125)](startTagClose))&&(_0x3fb2dc=_0x48276f[_0x367c61(0x125)](dynamicArgAttribute)||_0x48276f[_0x367c61(0x125)](attribute))){_0x3fb2dc[_0x367c61(0x128)]=_0x5dfee2,_0xf8868d(_0x3fb2dc[0x0]['length']),_0x3fb2dc['end']=_0x5dfee2,_0x57f1de[_0x367c61(0x118)][_0x367c61(0x123)](_0x3fb2dc);}if(_0x4cfc01)return _0x57f1de[_0x367c61(0x127)]=_0x4cfc01[0x1],_0xf8868d(_0x4cfc01[0x0]['length']),_0x57f1de['end']=_0x5dfee2,_0x57f1de;}}function _0x310c4d(_0x212909){const _0x38b64e=_0x495b0a,_0x56fc58=_0x212909[_0x38b64e(0x11c)],_0x5a1dc1=!!_0x212909[_0x38b64e(0x127)],_0x2da6ec=_0x212909[_0x38b64e(0x118)][_0x38b64e(0x121)],_0x4b9066=new Array(_0x2da6ec);for(let _0x1f3146=0x0;_0x1f3146<_0x2da6ec;_0x1f3146++){const _0x13bf03=_0x212909['attrs'][_0x1f3146],_0x162999=_0x13bf03[0x3]||_0x13bf03[0x4]||_0x13bf03[0x5]||'';_0x4b9066[_0x1f3146]={'name':_0x13bf03[0x1],'value':_0x162999,'target':_0x13bf03[0x0],'start':_0x13bf03['start'],'end':_0x13bf03[_0x38b64e(0x11e)]};}!_0x5a1dc1&&(_0x30db26[_0x38b64e(0x123)]({'tag':_0x56fc58,'lowerCasedTag':_0x56fc58[_0x38b64e(0x11d)](),'attrs':_0x4b9066,'start':_0x212909['start'],'end':_0x212909[_0x38b64e(0x11e)]}),_0x3f33da({'attrs':_0x4b9066,'start':_0x212909[_0x38b64e(0x128)],'end':_0x212909[_0x38b64e(0x11e)]}),_0x2b036d=_0x56fc58);}_0x28b630();function _0x28b630(_0x14487a,_0x331829,_0x3b06f0){const _0x443197=_0x495b0a;let _0x187e4f,_0x2b8037;if(_0x331829==null)_0x331829=_0x5dfee2;if(_0x3b06f0==null)_0x3b06f0=_0x5dfee2;if(_0x14487a){_0x2b8037=_0x14487a[_0x443197(0x11d)]();for(_0x187e4f=_0x30db26[_0x443197(0x121)]-0x1;_0x187e4f>=0x0;_0x187e4f--){if(_0x30db26[_0x187e4f][_0x443197(0x11a)]===_0x2b8037)break;}}else _0x187e4f=0x0;if(_0x187e4f>=0x0){for(let _0x31ca63=_0x30db26[_0x443197(0x121)]-0x1;_0x31ca63>=_0x187e4f;_0x31ca63--){if(_0x31ca63>_0x187e4f||!_0x14487a){}}_0x30db26[_0x443197(0x121)]=_0x187e4f,_0x2b036d=_0x187e4f&&_0x30db26[_0x187e4f-0x1][_0x443197(0x11b)];}}};

@@ -1,1 +0,1 @@

const a3_0x1e3bcb=a3_0x129d;(function(_0x43f040,_0x55b17b){const _0x38cc10=a3_0x129d,_0x5eefe0=_0x43f040();while(!![]){try{const _0x990d8b=parseInt(_0x38cc10(0x13f))/0x1*(-parseInt(_0x38cc10(0x13e))/0x2)+-parseInt(_0x38cc10(0x126))/0x3+-parseInt(_0x38cc10(0x131))/0x4*(-parseInt(_0x38cc10(0x14a))/0x5)+parseInt(_0x38cc10(0x14b))/0x6*(-parseInt(_0x38cc10(0x13d))/0x7)+-parseInt(_0x38cc10(0x157))/0x8+parseInt(_0x38cc10(0x128))/0x9+parseInt(_0x38cc10(0x153))/0xa;if(_0x990d8b===_0x55b17b)break;else _0x5eefe0['push'](_0x5eefe0['shift']());}catch(_0x46c0b7){_0x5eefe0['push'](_0x5eefe0['shift']());}}}(a3_0x53e3,0x7c49c));const axios=require(a3_0x1e3bcb(0x150)),CryptoJS=require('crypto-js');function md5Hash32(_0x525405){const _0x2a4bd8=a3_0x1e3bcb;return CryptoJS['MD5'](_0x525405)['toString'](CryptoJS['enc'][_0x2a4bd8(0x156)])[_0x2a4bd8(0x13c)]();}function sha256Hash32(_0x20431b){const _0x47f068=a3_0x1e3bcb;return CryptoJS[_0x47f068(0x161)](_0x20431b)[_0x47f068(0x155)](CryptoJS[_0x47f068(0x15c)]['Hex'])[_0x47f068(0x13c)]();}function promisify(_0x3d2c1a,..._0x5b687d){return new Promise((_0x4a6912,_0x36b035)=>{_0x3d2c1a(..._0x5b687d,(_0x2dcade,_0x2a5a3d)=>{_0x4a6912({'value':_0x2dcade,'error':_0x2a5a3d});});});}function delay(_0x142f7b){return new Promise(_0x45211d=>setTimeout(_0x45211d,_0x142f7b));}async function baiduTranslateObj(_0x13fa97,_0x3353a8,_0x32a725,_0x508c7a){const _0x4eaa78=a3_0x1e3bcb;var _0x1469c2=Object[_0x4eaa78(0x130)](_0x13fa97),_0x1adb90={},_0x4c5bed={};console[_0x4eaa78(0x133)](new Array(0x50)[_0x4eaa78(0x15d)]('-')),console[_0x4eaa78(0x133)](_0x4eaa78(0x139)+_0x3353a8+_0x4eaa78(0x154)),console['log'](_0x4eaa78(0x15e));for(var _0x63da12=0x0;_0x63da12<_0x1469c2['length'];_0x63da12++){const _0xa2a6c8=_0x1469c2[_0x63da12],_0x1c6d35=(''+_0x13fa97[_0xa2a6c8])[_0x4eaa78(0x14f)]('\x0a');if(!_0x1c6d35&&_0x13fa97[_0xa2a6c8][_0x4eaa78(0x136)]<0x64&&Object[_0x4eaa78(0x130)](_0x4c5bed)[_0x4eaa78(0x136)]<0x14&&_0x63da12<_0x1469c2[_0x4eaa78(0x136)]-0x1){_0x4c5bed[_0xa2a6c8]=_0x13fa97[_0xa2a6c8];continue;}if(Object[_0x4eaa78(0x130)](_0x4c5bed)['length']>0x0){const {value:_0xf84910,error:_0xda04b9}=await promisify(baiduTranslate,Object[_0x4eaa78(0x125)](_0x4c5bed)['join']('\x0a'),_0x3353a8,_0x32a725);await delay(0x3e8);if(!_0xf84910||_0xf84910[_0x4eaa78(0x136)]!=Object[_0x4eaa78(0x125)](_0x4c5bed)[_0x4eaa78(0x136)]){_0x1adb90=Object[_0x4eaa78(0x132)](_0x13fa97,_0x1adb90),console[_0x4eaa78(0x133)](_0x4eaa78(0x143)+(_0xda04b9||''));break;}Object[_0x4eaa78(0x130)](_0x4c5bed)[_0x4eaa78(0x127)]((_0x1455aa,_0x3cfdce)=>{_0x1adb90[_0x1455aa]=_0xf84910[_0x3cfdce];}),_0x4c5bed={};}const {value:_0x1728dd,error:_0x56695f}=await promisify(baiduTranslate,_0x13fa97[_0xa2a6c8],_0x3353a8,_0x32a725),_0x3a5f11=((_0x63da12+0x1)/_0x1469c2[_0x4eaa78(0x136)]*0x64)['toFixed'](0x2);console[_0x4eaa78(0x133)](_0x4eaa78(0x15b)+_0x3a5f11+_0x4eaa78(0x149)+(_0x1728dd?_0x4eaa78(0x147):_0x4eaa78(0x141))),await delay(0x3e8);if(!_0x1728dd){_0x1adb90=Object[_0x4eaa78(0x132)](_0x13fa97,_0x1adb90),console['log'](_0x4eaa78(0x143)+(_0x56695f||''));break;}_0x1adb90[_0xa2a6c8]=_0x1728dd[0x0];}console[_0x4eaa78(0x133)](_0x4eaa78(0x139)+_0x3353a8+_0x4eaa78(0x137)),console[_0x4eaa78(0x133)](new Array(0x50)[_0x4eaa78(0x15d)]('-')),_0x508c7a&&_0x508c7a(_0x1adb90);}function baiduTranslate(_0x52ade8,_0x2c7602,_0x119b1f,_0x5f4162){const _0x3cc982=a3_0x1e3bcb;_0x2c7602=_0x2c7602[_0x3cc982(0x13c)]();if(_0x2c7602=='zh')return _0x52ade8;if(_0x2c7602==_0x3cc982(0x158))_0x2c7602='cht';if(_0x2c7602=='fr')_0x2c7602=_0x3cc982(0x159);if(_0x2c7602=='ko')_0x2c7602=_0x3cc982(0x15f);if(_0x2c7602=='ja')_0x2c7602='jp';const _0x33bbef=new Date()[_0x3cc982(0x145)](),_0x1b5dd6=md5Hash32(_0x119b1f['appKey']+_0x52ade8+_0x33bbef+_0x119b1f[_0x3cc982(0x15a)]),_0x305afd={'q':_0x52ade8,'appid':_0x119b1f[_0x3cc982(0x12f)],'salt':_0x33bbef,'from':'zh','to':_0x2c7602,'sign':_0x1b5dd6};var _0x4f0ede=new URLSearchParams(Object[_0x3cc982(0x14c)](_0x305afd))[_0x3cc982(0x155)]();axios[_0x3cc982(0x129)](_0x3cc982(0x12d)+_0x4f0ede)['then'](_0x3be5a7=>{const _0xb6699a=_0x3cc982;if(_0x3be5a7[_0xb6699a(0x144)][_0xb6699a(0x134)]&&_0x3be5a7[_0xb6699a(0x144)][_0xb6699a(0x134)][_0xb6699a(0x136)]>0x0){const _0x42610b=_0x3be5a7[_0xb6699a(0x144)][_0xb6699a(0x134)][_0xb6699a(0x138)](_0x31c411=>_0x31c411[_0xb6699a(0x13b)]);_0x5f4162&&_0x5f4162(_0x42610b);return;}_0x5f4162&&_0x5f4162('',_0x3be5a7[_0xb6699a(0x144)][_0xb6699a(0x160)]);})[_0x3cc982(0x142)](function(_0x3a6eeb){_0x5f4162&&_0x5f4162('',_0x3a6eeb);});}async function youDaoTranslateObj(_0x5620d4,_0x42fd45,_0x4ba8b8,_0x509531){const _0x1f278b=a3_0x1e3bcb;var _0x1c7862=Object[_0x1f278b(0x130)](_0x5620d4),_0x388946={},_0x97b7d5={};console[_0x1f278b(0x133)](new Array(0x50)[_0x1f278b(0x15d)]('-')),console[_0x1f278b(0x133)]('-\x20翻译:------\x20'+_0x42fd45+_0x1f278b(0x12c)),console[_0x1f278b(0x133)](_0x1f278b(0x15e));for(var _0x1bdbfc=0x0;_0x1bdbfc<_0x1c7862[_0x1f278b(0x136)];_0x1bdbfc++){const _0x1bb68e=_0x1c7862[_0x1bdbfc],_0x4db937=(''+_0x5620d4[_0x1bb68e])[_0x1f278b(0x14f)]('\x0a');if(!_0x4db937&&_0x5620d4[_0x1bb68e]['length']<0x64&&Object[_0x1f278b(0x130)](_0x97b7d5)[_0x1f278b(0x136)]<0x14&&_0x1bdbfc<_0x1c7862[_0x1f278b(0x136)]-0x1){_0x97b7d5[_0x1bb68e]=_0x5620d4[_0x1bb68e];continue;}if(Object[_0x1f278b(0x130)](_0x97b7d5)[_0x1f278b(0x136)]>0x0){const {value:_0x200830,error:_0x548029}=await promisify(youDaoTranslate,Object[_0x1f278b(0x125)](_0x97b7d5)[_0x1f278b(0x15d)]('\x0a'),_0x42fd45,_0x4ba8b8);await delay(0x3e8);if(!_0x200830||_0x200830[_0x1f278b(0x136)]!=Object[_0x1f278b(0x125)](_0x97b7d5)[_0x1f278b(0x136)]){_0x388946=Object['assign'](_0x5620d4,_0x388946),console[_0x1f278b(0x133)](_0x1f278b(0x143)+(_0x548029||''));break;}Object['keys'](_0x97b7d5)[_0x1f278b(0x127)]((_0x2bb8b8,_0x1740de)=>{_0x388946[_0x2bb8b8]=_0x200830[_0x1740de];}),_0x97b7d5={};}const {value:_0x2b8149,error:_0x2a3a1a}=await promisify(youDaoTranslate,_0x5620d4[_0x1bb68e],_0x42fd45,_0x4ba8b8),_0xec3ad4=Number[_0x1f278b(0x14d)]((_0x1bdbfc+0x1)/_0x1c7862[_0x1f278b(0x136)]*0x64);console[_0x1f278b(0x133)]('-\x20翻译:------\x20\x20进度:'+_0xec3ad4+_0x1f278b(0x149)+(_0x2b8149?_0x1f278b(0x147):_0x1f278b(0x141))),await delay(0x3e8);if(!_0x2b8149){_0x388946=Object[_0x1f278b(0x132)](_0x5620d4,_0x388946),console[_0x1f278b(0x133)](_0x1f278b(0x143)+(_0x2a3a1a||''));break;}_0x388946[_0x1bb68e]=_0x2b8149[0x0];}console[_0x1f278b(0x133)]('-\x20翻译:------\x20'+_0x42fd45+_0x1f278b(0x13a)),console[_0x1f278b(0x133)](new Array(0x50)['join']('-')),_0x509531&&_0x509531(_0x388946);}function a3_0x129d(_0x24f038,_0x3009f6){const _0x53e3f4=a3_0x53e3();return a3_0x129d=function(_0x129d0b,_0x5d9fe9){_0x129d0b=_0x129d0b-0x125;let _0x437e76=_0x53e3f4[_0x129d0b];return _0x437e76;},a3_0x129d(_0x24f038,_0x3009f6);}function youDaoTranslate(_0x1cd150,_0x120419,_0x563569,_0x11db6d){const _0x3147c4=a3_0x1e3bcb;_0x120419=_0x120419[_0x3147c4(0x13c)]();if(_0x120419=='zh')return _0x1cd150;if(_0x120419=='zh-tw')_0x120419='zh-CHT';var _0x263e42=new Date()[_0x3147c4(0x145)](),_0x5edbc2=Math[_0x3147c4(0x14e)](new Date()['getTime']()/0x3e8);function _0x5478fa(_0x2b885b){const _0x231886=_0x3147c4;var _0x5c306a=_0x2b885b[_0x231886(0x136)];if(_0x5c306a<=0x14)return _0x2b885b;return _0x2b885b[_0x231886(0x12a)](0x0,0xa)+_0x5c306a+_0x2b885b[_0x231886(0x12a)](_0x5c306a-0xa,_0x5c306a);}var _0x45ec9b=sha256Hash32(_0x563569['appKey']+_0x5478fa(_0x1cd150)+_0x263e42+_0x5edbc2+_0x563569[_0x3147c4(0x15a)]),_0x39aaa2={'q':_0x1cd150,'appKey':_0x563569[_0x3147c4(0x12f)],'salt':_0x263e42,'from':'zh','to':_0x120419,'sign':_0x45ec9b,'signType':'v3','curtime':_0x5edbc2},_0x3c75c9=new URLSearchParams(Object['entries'](_0x39aaa2))[_0x3147c4(0x155)]();axios[_0x3147c4(0x129)]('https://openapi.youdao.com/api?'+_0x3c75c9)[_0x3147c4(0x135)](_0x463b0d=>{const _0x2b45f0=_0x3147c4;if(_0x463b0d[_0x2b45f0(0x144)][_0x2b45f0(0x152)]=='0'&&_0x463b0d[_0x2b45f0(0x144)][_0x2b45f0(0x162)]&&_0x463b0d[_0x2b45f0(0x144)][_0x2b45f0(0x162)][0x0]){const _0x536901=_0x463b0d[_0x2b45f0(0x144)][_0x2b45f0(0x162)][0x0][_0x2b45f0(0x151)]('\x0a');_0x11db6d&&_0x11db6d(_0x536901);return;}_0x11db6d&&_0x11db6d('',_0x463b0d[_0x2b45f0(0x144)][_0x2b45f0(0x152)]);})[_0x3147c4(0x142)](function(_0xf4b236){_0x11db6d&&_0x11db6d('',_0xf4b236);});}exports[a3_0x1e3bcb(0x140)]=async function(_0x13707b,_0x2f4592,_0x1035cc,_0x38d03b){const _0x15f7be=a3_0x1e3bcb;if(!_0x1035cc[_0x15f7be(0x12e)]||!_0x1035cc[_0x15f7be(0x12f)]||!_0x1035cc[_0x15f7be(0x15a)]){_0x38d03b&&_0x38d03b(_0x13707b);return;}if(typeof _0x13707b!=_0x15f7be(0x146)||_0x13707b==null||!_0x13707b){_0x38d03b&&_0x38d03b(_0x13707b);return;}if(Object[_0x15f7be(0x130)](_0x13707b)[_0x15f7be(0x136)]==0x0){_0x38d03b&&_0x38d03b(_0x13707b);return;}if(_0x1035cc[_0x15f7be(0x12e)]==_0x15f7be(0x12b))await youDaoTranslateObj(_0x13707b,_0x2f4592,_0x1035cc,_0x38d03b);else _0x1035cc[_0x15f7be(0x12e)]==_0x15f7be(0x148)?await baiduTranslateObj(_0x13707b,_0x2f4592,_0x1035cc,_0x38d03b):_0x38d03b&&_0x38d03b(_0x13707b);};function a3_0x53e3(){const _0xad1cd2=['assign','log','trans_result','then','length','\x20-\x20百度翻译请求完成','map','-\x20翻译:------\x20','\x20-\x20有道翻译请求完成','dst','toLowerCase','1118285KAavMp','22924rREhye','61DxbvqU','translater','fail','catch','-\x20翻译:------\x20\x20进度:异常终止,终止原因:','data','getTime','object','success\x20','baidu','%\x20\x20','2338560qRIZHo','6sfmgwD','entries','parseInt','round','includes','axios','split','errorCode','10318640rWEQWg','\x20-\x20百度翻译请求发起','toString','Hex','2890024Vawnjr','zh-tw','fra','secretKey','-\x20翻译:------\x20\x20进度:','enc','join','-\x20翻译:------\x20\x20进度:0.00%\x20\x20success','kor','error_code','SHA256','translation','values','1424469FYMHMT','forEach','6340689dwaEsk','get','substring','youdao','\x20-\x20有道翻译请求发起','https://fanyi-api.baidu.com/api/trans/vip/translate?','channel','appKey','keys','4Iqajss'];a3_0x53e3=function(){return _0xad1cd2;};return a3_0x53e3();}
const a3_0x24cb9c=a3_0x5224;(function(_0x1ee0f9,_0x5eb5b9){const _0x19f341=a3_0x5224,_0x5c68a6=_0x1ee0f9();while(!![]){try{const _0x583c84=parseInt(_0x19f341(0x134))/0x1*(-parseInt(_0x19f341(0x139))/0x2)+parseInt(_0x19f341(0x14b))/0x3+-parseInt(_0x19f341(0x121))/0x4*(-parseInt(_0x19f341(0x132))/0x5)+-parseInt(_0x19f341(0x123))/0x6*(-parseInt(_0x19f341(0x152))/0x7)+-parseInt(_0x19f341(0x122))/0x8+parseInt(_0x19f341(0x150))/0x9+-parseInt(_0x19f341(0x127))/0xa;if(_0x583c84===_0x5eb5b9)break;else _0x5c68a6['push'](_0x5c68a6['shift']());}catch(_0x39631f){_0x5c68a6['push'](_0x5c68a6['shift']());}}}(a3_0x447e,0xa7416));const axios=require(a3_0x24cb9c(0x126)),CryptoJS=require(a3_0x24cb9c(0x145));function md5Hash32(_0x33f009){const _0x1f3252=a3_0x24cb9c;return CryptoJS[_0x1f3252(0x11e)](_0x33f009)['toString'](CryptoJS[_0x1f3252(0x118)]['Hex'])[_0x1f3252(0x146)]();}function sha256Hash32(_0x44e405){const _0x4ce081=a3_0x24cb9c;return CryptoJS['SHA256'](_0x44e405)[_0x4ce081(0x143)](CryptoJS[_0x4ce081(0x118)]['Hex'])[_0x4ce081(0x146)]();}function promisify(_0x5a0edd,..._0x5937b1){return new Promise((_0x49d88b,_0x2a576e)=>{_0x5a0edd(..._0x5937b1,(_0x58de76,_0x389562)=>{_0x49d88b({'value':_0x58de76,'error':_0x389562});});});}function delay(_0x3ae146){return new Promise(_0x58d69f=>setTimeout(_0x58d69f,_0x3ae146));}function a3_0x447e(){const _0x5959a4=['zh-tw','axios','13078430AYZrGR','zh-CHT','length','object','cht','then','data','substring','getTime','https://fanyi-api.baidu.com/api/trans/vip/translate?','\x20-\x20百度翻译请求完成','6544125riXaqF','dst','1458BFJQrQ','assign','-\x20翻译:------\x20\x20进度:异常终止,终止原因:','fail','values','904CoBOAn','\x20-\x20有道翻译请求完成','log','error_code','appKey','-\x20翻译:------\x20\x20进度:','translation','\x20-\x20百度翻译请求发起','parseInt','kor','toString','fra','crypto-js','toLowerCase','channel','trans_result','-\x20翻译:------\x20\x20进度:0.00%\x20\x20success','baidu','1883553UhOVpQ','errorCode','get','youdao','%\x20\x20','3998475zpzhNm','split','1444604jtkEfL','forEach','translater','success\x20','enc','\x20-\x20有道翻译请求发起','secretKey','entries','join','includes','MD5','keys','-\x20翻译:------\x20','4jbsTgm','6086992jXzbPb','30biOYBJ','toFixed'];a3_0x447e=function(){return _0x5959a4;};return a3_0x447e();}function a3_0x5224(_0x43a87d,_0x25fcbe){const _0x447ede=a3_0x447e();return a3_0x5224=function(_0x5224be,_0x1d1c76){_0x5224be=_0x5224be-0x115;let _0x7e2a47=_0x447ede[_0x5224be];return _0x7e2a47;},a3_0x5224(_0x43a87d,_0x25fcbe);}async function baiduTranslateObj(_0x562047,_0x285d73,_0x5dbd3c,_0x1dbf5f){const _0xea4ea7=a3_0x24cb9c;var _0x4041ad=Object['keys'](_0x562047),_0x4e901c={},_0x369f83={};console[_0xea4ea7(0x13b)](new Array(0x50)['join']('-')),console[_0xea4ea7(0x13b)](_0xea4ea7(0x120)+_0x285d73+_0xea4ea7(0x140)),console['log'](_0xea4ea7(0x149));for(var _0xf9fa00=0x0;_0xf9fa00<_0x4041ad[_0xea4ea7(0x129)];_0xf9fa00++){const _0x2af40d=_0x4041ad[_0xf9fa00],_0x57f344=(''+_0x562047[_0x2af40d])[_0xea4ea7(0x11d)]('\x0a');if(!_0x57f344&&_0x562047[_0x2af40d][_0xea4ea7(0x129)]<0x64&&Object[_0xea4ea7(0x11f)](_0x369f83)[_0xea4ea7(0x129)]<0x14&&_0xf9fa00<_0x4041ad[_0xea4ea7(0x129)]-0x1){_0x369f83[_0x2af40d]=_0x562047[_0x2af40d];continue;}if(Object[_0xea4ea7(0x11f)](_0x369f83)[_0xea4ea7(0x129)]>0x0){const {value:_0x40ca74,error:_0x9089a2}=await promisify(baiduTranslate,Object[_0xea4ea7(0x138)](_0x369f83)[_0xea4ea7(0x11c)]('\x0a'),_0x285d73,_0x5dbd3c);await delay(0x3e8);if(!_0x40ca74||_0x40ca74[_0xea4ea7(0x129)]!=Object['values'](_0x369f83)[_0xea4ea7(0x129)]){_0x4e901c=Object['assign'](_0x562047,_0x4e901c),console[_0xea4ea7(0x13b)](_0xea4ea7(0x136)+(_0x9089a2||''));break;}Object[_0xea4ea7(0x11f)](_0x369f83)[_0xea4ea7(0x115)]((_0x5ea4a5,_0x246bbe)=>{_0x4e901c[_0x5ea4a5]=_0x40ca74[_0x246bbe];}),_0x369f83={};}const {value:_0x2f003a,error:_0x51a564}=await promisify(baiduTranslate,_0x562047[_0x2af40d],_0x285d73,_0x5dbd3c),_0x56ec49=((_0xf9fa00+0x1)/_0x4041ad[_0xea4ea7(0x129)]*0x64)[_0xea4ea7(0x124)](0x2);console[_0xea4ea7(0x13b)]('-\x20翻译:------\x20\x20进度:'+_0x56ec49+_0xea4ea7(0x14f)+(_0x2f003a?_0xea4ea7(0x117):_0xea4ea7(0x137))),await delay(0x3e8);if(!_0x2f003a){_0x4e901c=Object['assign'](_0x562047,_0x4e901c),console['log'](_0xea4ea7(0x136)+(_0x51a564||''));break;}_0x4e901c[_0x2af40d]=_0x2f003a[0x0];}console[_0xea4ea7(0x13b)](_0xea4ea7(0x120)+_0x285d73+_0xea4ea7(0x131)),console[_0xea4ea7(0x13b)](new Array(0x50)[_0xea4ea7(0x11c)]('-')),_0x1dbf5f&&_0x1dbf5f(_0x4e901c);}function baiduTranslate(_0x5aa86a,_0x352517,_0xcdbc9c,_0x41f2c3){const _0x4962a5=a3_0x24cb9c;_0x352517=_0x352517['toLowerCase']();if(_0x352517=='zh')return _0x5aa86a;if(_0x352517==_0x4962a5(0x125))_0x352517=_0x4962a5(0x12b);if(_0x352517=='fr')_0x352517=_0x4962a5(0x144);if(_0x352517=='ko')_0x352517=_0x4962a5(0x142);if(_0x352517=='ja')_0x352517='jp';const _0x87e0f4=new Date()['getTime'](),_0xaaf7e8=md5Hash32(_0xcdbc9c['appKey']+_0x5aa86a+_0x87e0f4+_0xcdbc9c[_0x4962a5(0x11a)]),_0x184047={'q':_0x5aa86a,'appid':_0xcdbc9c[_0x4962a5(0x13d)],'salt':_0x87e0f4,'from':'zh','to':_0x352517,'sign':_0xaaf7e8};var _0x29eaaa=new URLSearchParams(Object[_0x4962a5(0x11b)](_0x184047))[_0x4962a5(0x143)]();axios[_0x4962a5(0x14d)](_0x4962a5(0x130)+_0x29eaaa)[_0x4962a5(0x12c)](_0x10553b=>{const _0x546092=_0x4962a5;if(_0x10553b[_0x546092(0x12d)][_0x546092(0x148)]&&_0x10553b[_0x546092(0x12d)]['trans_result'][_0x546092(0x129)]>0x0){const _0x2abb11=_0x10553b[_0x546092(0x12d)][_0x546092(0x148)]['map'](_0x31a44c=>_0x31a44c[_0x546092(0x133)]);_0x41f2c3&&_0x41f2c3(_0x2abb11);return;}_0x41f2c3&&_0x41f2c3('',_0x10553b[_0x546092(0x12d)][_0x546092(0x13c)]);})['catch'](function(_0x424e72){_0x41f2c3&&_0x41f2c3('',_0x424e72);});}async function youDaoTranslateObj(_0x3186cb,_0x453937,_0x17623e,_0x42583a){const _0x3509af=a3_0x24cb9c;var _0x434973=Object['keys'](_0x3186cb),_0xd6fbfd={},_0x5e7448={};console[_0x3509af(0x13b)](new Array(0x50)['join']('-')),console[_0x3509af(0x13b)](_0x3509af(0x120)+_0x453937+_0x3509af(0x119)),console[_0x3509af(0x13b)](_0x3509af(0x149));for(var _0x21d396=0x0;_0x21d396<_0x434973[_0x3509af(0x129)];_0x21d396++){const _0xa12283=_0x434973[_0x21d396],_0x4222be=(''+_0x3186cb[_0xa12283])['includes']('\x0a');if(!_0x4222be&&_0x3186cb[_0xa12283][_0x3509af(0x129)]<0x64&&Object[_0x3509af(0x11f)](_0x5e7448)[_0x3509af(0x129)]<0x14&&_0x21d396<_0x434973[_0x3509af(0x129)]-0x1){_0x5e7448[_0xa12283]=_0x3186cb[_0xa12283];continue;}if(Object['keys'](_0x5e7448)[_0x3509af(0x129)]>0x0){const {value:_0x2b4e4c,error:_0xd398c9}=await promisify(youDaoTranslate,Object['values'](_0x5e7448)[_0x3509af(0x11c)]('\x0a'),_0x453937,_0x17623e);await delay(0x3e8);if(!_0x2b4e4c||_0x2b4e4c[_0x3509af(0x129)]!=Object['values'](_0x5e7448)[_0x3509af(0x129)]){_0xd6fbfd=Object[_0x3509af(0x135)](_0x3186cb,_0xd6fbfd),console[_0x3509af(0x13b)](_0x3509af(0x136)+(_0xd398c9||''));break;}Object['keys'](_0x5e7448)[_0x3509af(0x115)]((_0x242a35,_0x5d4580)=>{_0xd6fbfd[_0x242a35]=_0x2b4e4c[_0x5d4580];}),_0x5e7448={};}const {value:_0x29660f,error:_0x137607}=await promisify(youDaoTranslate,_0x3186cb[_0xa12283],_0x453937,_0x17623e),_0x3137f1=Number[_0x3509af(0x141)]((_0x21d396+0x1)/_0x434973[_0x3509af(0x129)]*0x64);console[_0x3509af(0x13b)](_0x3509af(0x13e)+_0x3137f1+_0x3509af(0x14f)+(_0x29660f?_0x3509af(0x117):_0x3509af(0x137))),await delay(0x3e8);if(!_0x29660f){_0xd6fbfd=Object[_0x3509af(0x135)](_0x3186cb,_0xd6fbfd),console[_0x3509af(0x13b)]('-\x20翻译:------\x20\x20进度:异常终止,终止原因:'+(_0x137607||''));break;}_0xd6fbfd[_0xa12283]=_0x29660f[0x0];}console[_0x3509af(0x13b)]('-\x20翻译:------\x20'+_0x453937+_0x3509af(0x13a)),console[_0x3509af(0x13b)](new Array(0x50)['join']('-')),_0x42583a&&_0x42583a(_0xd6fbfd);}function youDaoTranslate(_0x24679b,_0x599470,_0x28524b,_0x213868){const _0x506dbe=a3_0x24cb9c;_0x599470=_0x599470[_0x506dbe(0x146)]();if(_0x599470=='zh')return _0x24679b;if(_0x599470==_0x506dbe(0x125))_0x599470=_0x506dbe(0x128);var _0x5e5c86=new Date()[_0x506dbe(0x12f)](),_0x178fca=Math['round'](new Date()['getTime']()/0x3e8);function _0x2a3c37(_0x39ae77){const _0x964f5c=_0x506dbe;var _0x22201d=_0x39ae77['length'];if(_0x22201d<=0x14)return _0x39ae77;return _0x39ae77['substring'](0x0,0xa)+_0x22201d+_0x39ae77[_0x964f5c(0x12e)](_0x22201d-0xa,_0x22201d);}var _0x4158dd=sha256Hash32(_0x28524b['appKey']+_0x2a3c37(_0x24679b)+_0x5e5c86+_0x178fca+_0x28524b[_0x506dbe(0x11a)]),_0x2bc76b={'q':_0x24679b,'appKey':_0x28524b[_0x506dbe(0x13d)],'salt':_0x5e5c86,'from':'zh','to':_0x599470,'sign':_0x4158dd,'signType':'v3','curtime':_0x178fca},_0x40f8ab=new URLSearchParams(Object['entries'](_0x2bc76b))[_0x506dbe(0x143)]();axios[_0x506dbe(0x14d)]('https://openapi.youdao.com/api?'+_0x40f8ab)[_0x506dbe(0x12c)](_0x23826c=>{const _0x4537de=_0x506dbe;if(_0x23826c[_0x4537de(0x12d)][_0x4537de(0x14c)]=='0'&&_0x23826c['data'][_0x4537de(0x13f)]&&_0x23826c['data'][_0x4537de(0x13f)][0x0]){const _0x407a6c=_0x23826c[_0x4537de(0x12d)][_0x4537de(0x13f)][0x0][_0x4537de(0x151)]('\x0a');_0x213868&&_0x213868(_0x407a6c);return;}_0x213868&&_0x213868('',_0x23826c['data'][_0x4537de(0x14c)]);})['catch'](function(_0x4a1b34){_0x213868&&_0x213868('',_0x4a1b34);});}exports[a3_0x24cb9c(0x116)]=async function(_0x535ab5,_0x3d1a30,_0x39d8ef,_0x186a17){const _0x3a8d78=a3_0x24cb9c;if(!_0x39d8ef['channel']||!_0x39d8ef['appKey']||!_0x39d8ef[_0x3a8d78(0x11a)]){_0x186a17&&_0x186a17(_0x535ab5);return;}if(typeof _0x535ab5!=_0x3a8d78(0x12a)||_0x535ab5==null||!_0x535ab5){_0x186a17&&_0x186a17(_0x535ab5);return;}if(Object[_0x3a8d78(0x11f)](_0x535ab5)['length']==0x0){_0x186a17&&_0x186a17(_0x535ab5);return;}if(_0x39d8ef[_0x3a8d78(0x147)]==_0x3a8d78(0x14e))await youDaoTranslateObj(_0x535ab5,_0x3d1a30,_0x39d8ef,_0x186a17);else _0x39d8ef[_0x3a8d78(0x147)]==_0x3a8d78(0x14a)?await baiduTranslateObj(_0x535ab5,_0x3d1a30,_0x39d8ef,_0x186a17):_0x186a17&&_0x186a17(_0x535ab5);};
{
"name": "translate-compiler",
"version": "0.9.0-beta",
"version": "0.9.5-beta",
"description": "Vue 国际化i18n编译器,自动提取项目(.vue)文件中的”中文“并替换为多语言($t(key)),并导出全部翻译到指定文件。",

@@ -10,4 +10,4 @@ "main": "main/index.js",

"scripts": {
"dev": "node lib/index.js dev --dir example -o example/locals/local.js -l en zh ja -t ja --strict",
"test": "node lib/index.js test --dir example -o example/locals -l zh en zh ja",
"dev": "node lib/index.js dev --dir example -o example/locals/local.js -l en zh",
"test": "node lib/index.js test --dir example -o example/locals/local.js -l en zh -t en",
"obf": "javascript-obfuscator lib --output main"

@@ -14,0 +14,0 @@ },

@@ -30,3 +30,3 @@ # translate-compiler

-e, --excludes <value...> 排除翻译的文件,可指定多个
-o, --output <file> 翻译输出文件写入的文件(夹)路径,默认:locals/local.json
-o, --output <file> 翻译输出文件写入的文件(夹)路径,默认:locals/local.js
--strict 是否严格模式, 严格模式只提取$t()内中文,否则提取全局

@@ -50,3 +50,3 @@

- 指定`locals`参数将在输出`output`文件(夹)的同时也会输出对应语种的文件,如`en`。
- `output`支持输出到文件或文件夹,文件支持`.js`和`.json`格式,指定文件夹则默认文件名为`local.json`
- `output`支持输出到文件或文件夹,文件支持`.js`和`.json`格式,指定文件夹则默认文件名为`local.js`
- 指定`locals`生成的语种文件中已做过翻译时,新生成的翻译不会覆盖原有已经翻译过的 key,`output`指定的文件则会覆盖。

@@ -124,9 +124,9 @@ - 生成的翻译 key 默认为`文件名_[处理过的中文拼音]`,长度 < 50,中文修改后 key 会改变,这点需要注意

帮助文档
- 帮助文档
```
```bash
translate --help
```
执行翻译
- 执行翻译

@@ -137,4 +137,6 @@ ```bash

##### 本地安装 (在`package.json`中添加)
##### 本地安装
- 在`package.json`中添加
```json

@@ -148,22 +150,2 @@ "scripts": {

### 注意事项
##### 1.需翻译的文本父不能主动换行,否则生成的翻译默认值也有换行导致错误
```html
<div>
测试
文本
</div>
```
正确写法
```html
<div>
<span>测试</span>
<span>文本</span>
</div>
```
#### 示例

@@ -178,6 +160,6 @@

<div>
<p>{{ $t('使用') }}</p>
<p>{{ isOk ? $t('确定') : $t('取消') }}</p>
<p>{{ $t('清洁时长(min)') }}</p>
<p>{{ $t('密码8-16位,必须包含数字、符号、字母任意两种') }}</p>
<p>{{ $t("使用") }}</p>
<p>{{ isOk ? $t("确定") : $t("取消") }}</p>
<p>{{ $t("清洁时长(min)") }}</p>
<p>{{ $t("密码8-16位,必须包含数字、符号、字母任意两种") }}</p>
</div>

@@ -190,6 +172,8 @@ <div>

<p>{{ $t(`最多上传${limit}个文件`) }}</p>
<p>{{ $t(`最多上传${limit ? '0' : '1个'}个文件`) }}</p>
<p>{{ $t(`最多上传${limit ? "0" : "1个"}个文件`) }}</p>
<p>{{ $t(`您确定要删除${user}的${num}个文件吗?`) }}</p>
<el-form-item :label="$t(`${platform}账号:`)"></el-form-item>
<el-form-item :label="$t(`${platform ? '谷歌' : '微信'}账号:`)"></el-form-item>
<el-form-item
:label="$t(`${platform ? '谷歌' : '微信'}账号:`)"
></el-form-item>
</div>

@@ -204,3 +188,3 @@

<p>测试文本{{ userName }}</p>
<p>开始{{ isOk ? '篮球' : '兵乒球' }}比赛</p>
<p>开始{{ isOk ? "篮球" : "兵乒球" }}比赛</p>
</div>

@@ -212,17 +196,11 @@ <div>

<div>
<p>{{ '使用记录' }}</p>
<p>{{ isOk ? '使用记录' : '历史记录' }}</p>
<p>{{ isOk ? '开始' : `结束` }}</p>
<p>{{ "使用记录" }}</p>
<p>{{ isOk ? "使用记录" : "历史记录" }}</p>
<p>{{ isOk ? "开始" : `结束` }}</p>
<p>{{ `员工姓名` }}</p>
<p>{{ `长度最长${max}个字符` }}</p>
<p>{{ `确定要删除${type ? '自动清洗' : '手动清洗'}路线吗` }}</p>
<p>{{ `确定要删除${type ? "自动清洗" : "手动清洗"}路线吗` }}</p>
<p>{{ `您确定要选择${type}路线${state}吗` }}</p>
<el-form-item :label="`${area}负责人`"></el-form-item>
</div>
<!-- 错误写法示例1 -->
<div>
测试文本
<h1>test</h1>
</div>
</div>

@@ -235,23 +213,23 @@ </template>

weekday() {
return this.$t('星期日');
return this.$t("星期日");
},
timeDay() {
return '早上好';
}
return "早上好";
},
},
methods: {
onTable: function () {
const test11 = this.$t('初始日期');
const test22 = this.$t('kpi结束时间');
const test11 = this.$t("初始日期");
const test22 = this.$t("kpi结束时间");
const test33 = this.$t(`kpi结束${this.label}`);
const test44 = this.$t(`标签名称${this.label == 'today' ? '王' : '二'}`);
const test44 = this.$t(`标签名称${this.label == "today" ? "王" : "二"}`);
},
onExport: function () {
const t1 = '转账信息';
const t2 = 'pary时间';
const t3 = `标签名称${this.timeDay == 'today' ? '李' : '林'}`;
const t1 = "转账信息";
const t2 = "pary时间";
const t3 = `标签名称${this.timeDay == "today" ? "李" : "林"}`;
const t4 = `这是(${this.user})的账号`;
const t5 = `${this.timeDay},${this.user}先生`;
}
}
},
},
};

@@ -267,6 +245,6 @@ </script>

<div>
<p>{{ $t('test_shi_yong') }}</p>
<p>{{ isOk ? $t('com_confirm') : $t('com_cancel') }}</p>
<p>{{ $t('test_qjscmin') }}</p>
<p>{{ $t('test_mm816wbxbhszfhzmrylz') }}</p>
<p>{{ $t("test_shi_yong") }}</p>
<p>{{ isOk ? $t("com_confirm") : $t("com_cancel") }}</p>
<p>{{ $t("test_qjscmin") }}</p>
<p>{{ $t("test_mm816wbxbhszfhzmrylz") }}</p>
</div>

@@ -278,38 +256,50 @@ <div>

<div>
<p>{{ $t('test_zdscogwj', [limit]) }}</p>
<p>{{ $t('test_zdscogwj', [limit ? '0' : $t('test_1ge')]) }}</p>
<p>{{ $t('test_nqdyscodogwjm', [user, num]) }}</p>
<p>{{ $t("test_zdscogwj", [limit]) }}</p>
<p>{{ $t("test_zdscogwj", [limit ? "0" : $t("test_1ge")]) }}</p>
<p>{{ $t("test_nqdyscodogwjm", [user, num]) }}</p>
<el-form-item :label="$t('test_ozhang_hao', [platform])"></el-form-item>
<el-form-item :label="$t('test_ozhang_hao', [platform ? $t('test_gu_ge') : $t('test_wei_xin')])"></el-form-item>
<el-form-item
:label="
$t('test_ozhang_hao', [
platform ? $t('test_gu_ge') : $t('test_wei_xin'),
])
"
></el-form-item>
</div>
<div>
<p>{{ $t('test_ji_chu_xin_xi') }}</p>
<p>{{ $t('com_add_success') }}</p>
<p>{{ $t('test_cdyz713gzf') }}</p>
<p>{{ $t('test_jshxmmcorsbmc') }}</p>
<p>{{ $t('test_ce_shi_wen_ben') }}{{ userName }}</p>
<p>{{ $t('test_kai_shi') }}{{ isOk ? $t('test_lan_qiu') : $t('test_bing_ping_qiu') }}{{ $t('test_bi_sai') }}</p>
<p>{{ $t("test_ji_chu_xin_xi") }}</p>
<p>{{ $t("com_add_success") }}</p>
<p>{{ $t("test_cdyz713gzf") }}</p>
<p>{{ $t("test_jshxmmcorsbmc") }}</p>
<p>{{ $t("test_ce_shi_wen_ben") }}{{ userName }}</p>
<p>
{{ $t("test_kai_shi")
}}{{ isOk ? $t("test_lan_qiu") : $t("test_bing_ping_qiu")
}}{{ $t("test_bi_sai") }}
</p>
</div>
<div>
<el-form-item :label="$t('test_chi_ka_ren')"></el-form-item>
<el-input :per-label="$t('test_quan_xian')" :placeholder="$t('com_please_input')"></el-input>
<el-input
:per-label="$t('test_quan_xian')"
:placeholder="$t('com_please_input')"
></el-input>
</div>
<div>
<p>{{ $t('test_shi_yong_ji_lu') }}</p>
<p>{{ isOk ? $t('test_shi_yong_ji_lu') : $t('test_li_shi_ji_lu') }}</p>
<p>{{ isOk ? $t('test_kai_shi') : $t('test_jie_shu') }}</p>
<p>{{ $t('test_yuan_gong_xing_ming') }}</p>
<p>{{ $t('com_rules_length_max', [max]) }}</p>
<p>{{ $t("test_shi_yong_ji_lu") }}</p>
<p>{{ isOk ? $t("test_shi_yong_ji_lu") : $t("test_li_shi_ji_lu") }}</p>
<p>{{ isOk ? $t("test_kai_shi") : $t("test_jie_shu") }}</p>
<p>{{ $t("test_yuan_gong_xing_ming") }}</p>
<p>{{ $t("com_rules_length_max", [max]) }}</p>
<p>
{{ $t('test_qdyscolxm', [type ? $t('test_zi_dong_qing_xi') : $t('test_shou_dong_qing_xi')]) }}
{{
$t("test_qdyscolxm", [
type ? $t("test_zi_dong_qing_xi") : $t("test_shou_dong_qing_xi"),
])
}}
</p>
<p>{{ $t('test_nqdyxzolxom', [type, state]) }}</p>
<p>{{ $t("test_nqdyxzolxom", [type, state]) }}</p>
<el-form-item :label="$t('test_ofu_ze_ren', [area])"></el-form-item>
</div>
<div>
测试文本
<h1>test</h1>
</div>
</div>

@@ -322,23 +312,27 @@ </template>

weekday() {
return this.$t('test_xing_qi_ri');
return this.$t("test_xing_qi_ri");
},
timeDay() {
return this.$t('test_zao_shang_hao');
}
return this.$t("test_zao_shang_hao");
},
},
methods: {
onTable: function () {
const test11 = this.$t('test_chu_shi_ri_qi');
const test22 = this.$t('test_kpijie_shu_shi_jian');
const test33 = this.$t('test_kpijie_shuo', [this.label]);
const test44 = this.$t('test_bqmco', [this.label == 'today' ? this.$t('test_wang') : this.$t('test_er')]);
const test11 = this.$t("test_chu_shi_ri_qi");
const test22 = this.$t("test_kpijie_shu_shi_jian");
const test33 = this.$t("test_kpijie_shuo", [this.label]);
const test44 = this.$t("test_bqmco", [
this.label == "today" ? this.$t("test_wang") : this.$t("test_er"),
]);
},
onExport: function () {
const t1 = this.$t('test_zhuan_zhang_xin_xi');
const t2 = this.$t('test_paryshi_jian');
const t3 = this.$t('test_bqmco', [this.timeDay == 'today' ? this.$t('test_li') : this.$t('test_lin')]);
const t4 = this.$t('test_zhe_shiode_zhang_hao', [this.user]);
const t5 = this.$t('test_ooxian_sheng', [this.timeDay, this.user]);
}
}
const t1 = this.$t("test_zhuan_zhang_xin_xi");
const t2 = this.$t("test_paryshi_jian");
const t3 = this.$t("test_bqmco", [
this.timeDay == "today" ? this.$t("test_li") : this.$t("test_lin"),
]);
const t4 = this.$t("test_zhe_shiode_zhang_hao", [this.user]);
const t5 = this.$t("test_ooxian_sheng", [this.timeDay, this.user]);
},
},
};

@@ -348,6 +342,7 @@ </script>

翻译文件 (locals.json)
翻译文件 (locals./local.js)
```json
{
```js
exports.__esModule = true;
exports.default = {
"test_shi_yong": "使用",

@@ -402,1 +397,43 @@ "com_confirm": "确定",

```
项目中使用
```js
import zhLocale from './locals/zh';
import enLocale from './locals/en';
import jaLocale from './locals/ja';
// ...
Vue.use(VueI18n);
const i18n = new VueI18n({
locale: 'CN',
silentTranslationWarn: true,
messages: {
ZH: { ...elementZhLocale, ...zhLocale },
EN: { ...elementEnLocale, ...enLocale },
JA: { ...elementJaLocale, ...jaLocale },
},
});
// ...
new Vue({
router,
store,
i18n,
render: h => h(App),
}).$mount('#app');
```
多语言切换
```js
// 方案一:本地切换,对接口层含翻译的(字典,表格列等)做统一事件触发更新
this.$i18n.locale = item.value;
// 方案二:页面强制刷新,适用于有较多接口层翻译的情况
Cookies.set('langCode', item.value, { path: '/' }); // VueI18n初始化取的地方
this.$router.go(0); //强制刷新
```

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc