diff --git a/assets/js/function.js b/assets/js/function.js index 4d313d1..689fe87 100644 --- a/assets/js/function.js +++ b/assets/js/function.js @@ -311,7 +311,7 @@ document.getElementById("name").innerHTML = finaltitle; document.getElementById("description").innerHTML = finalsub; // Copyright console log copied from https://github.com/MoePlayer/APlayer/. Thank you. -console.log(`${'\n'} %c Merger 0.21.1 %c https://github.com/hifocus/merger ${'\n'}`, 'color: #fadfa3; background: #030307; padding:5px 0;', 'background: #fadfa3; padding:5px 0;'); +console.log(`${'\n'} %c Merger 0.26.1 %c https://github.com/hifocus/merger ${'\n'}`, 'color: #fadfa3; background: #030307; padding:5px 0;', 'background: #fadfa3; padding:5px 0;'); function showqrcode() { if (location.href.substr(location.href.lastIndexOf('#') + 1) == "showqrcode" && selected == "yes") document.getElementById('showqrcode').style.display = "flex"; diff --git a/assets/js/function.min.js b/assets/js/function.min.js index 9af9c99..85d54af 100644 --- a/assets/js/function.min.js +++ b/assets/js/function.min.js @@ -1 +1 @@ -function openwechat(){selected="yes",document.getElementById("titleinfo").innerHTML=wechatscan+payto,client=wechat,showqrcode()}function openalipay(){selected="yes",document.getElementById("titleinfo").innerHTML=alipayscan+payto,client=alipay,showqrcode()}function opentenpay(){selected="yes",document.getElementById("titleinfo").innerHTML=tenpayscan+payto,client=tenpay,showqrcode()}function removal(){document.getElementById("h").removeChild(document.getElementById("i")),document.getElementById("pending").removeChild(document.getElementById("depends")),document.getElementById("btncontainer").removeChild(document.getElementById("qrcodeclose"))}function urlencode(e){return encodeURIComponent(e).replace(/'/g,"%27").replace(/"/g,"%22")}function showqrcode(){"showqrcode"==location.href.substr(location.href.lastIndexOf("#")+1)&&"yes"==selected&&(document.getElementById("showqrcode").style.display="flex"),document.getElementById("currentqrcode").innerHTML.includes("img")&&(document.getElementById("currentqrcode").getElementsByTagName("img")[0].setAttribute("id","todel"),document.getElementById("currentqrcode").removeChild(document.getElementById("todel"))),$("#currentqrcode").qrcode({render:"image",size:300*scale,text:client})}var client,selected,scale=window.devicePixelRatio;if(profile_error=0,"undefined"==typeof profile||null===profile||""===profile)profile_error=1;else if(profile.includes("@")&&!profile.includes("http")){var email=profile.split("@"),suffix=email[1];if(suffix.includes("."))var profile_url=gravatar_url+md5(profile)+"?s=96",profile_lg=profile_url.replace("96","500");else console.log("%c Email address invaild, please entre a vaild email or image url! ","color: red"),console.log("%c Email 无效,请输入有效 Email 或者图片 url ","color: red"),profile_error=1}else profile_url=profile_lg=profile;profile_error>0&&(profile_url=profile_lg="https://ae01.alicdn.com/kf/Udaba9d58fade4a3e921c0ceba62db2b7n.png"),document.getElementById("i").style.background="url('"+profile_lg+"') no-repeat center/cover",$("#favicon").attr("href",profile_url);var userLang=navigator.language||navigator.userLanguage;if(!1!==multilingual)if(/zh-CN|zh-cn|zh-Hans|zh-hans|cn/i.test(userLang)){if("string"==typeof myname_hans)var myname=myname_hans}else if(/zh-TW|zh-HK|zh-tw|zh-hk|zh-Hant|zh-hant|tw|hk/i.test(userLang)){if("string"==typeof myname_hant)myname=myname_hant}else if("string"==typeof myname_eng)myname=myname_eng;var firstchar=myname.charAt(0),lastchar=myname.charAt(myname.length-1),english=/^[A-Za-z0-9]*$/;if(english.test(firstchar)||english.test(lastchar))var finalname=" "+myname+" ",finalsub=subtitle.replace(myname,finalname),spacing=!0;else finalname=myname;var finalname_eng=" "+myname;if(null==usage||""===usage||"payment"!==usage&&"donate"!==usage){var usage="payment";console.log("%c The usage variable is not defined correctly","color: red")}if("undefined"==typeof branding||null===branding||""===branding||!0!==branding&&"true"!==branding)var aftertitle="";else if(!0===branding||"true"===branding)aftertitle=" | Merger";if(!1===multilingual)var finaltitle=title,wechatscan="微信扫一扫 向"+finalname+"支付",tenpayscan="手机QQ扫一扫 向"+finalname+"支付",alipayscan="支付宝扫一扫 向"+finalname+"支付",payto="",presshold="长按识别二维码 向"+finalname+"支付",notavail="🚫 目前没有可用的支付方式",myname_hant=myname,myname_hans=myname,myname_eng=myname;else if(/zh-CN|zh-cn|zh-Hans|zh-hans|cn/i.test(userLang)){if(document.write(""),"payment"===usage)var method="付款";if("donate"===usage)method="捐赠";document.title="向"+finalname+method+aftertitle;var trans_wx="微信",trans_ali="支付宝",trans_tp="QQ手机版",scan=(finaltitle="向"+finalname+method,finalsub="从下方选择"+method+"方式",trans_wx="微信","扫一扫");presshold="长按识别二维码",payto=" 向"+finalname+method,notavail="🚫 目前没有可用的"+method+"方式",wechatscan=trans_wx+scan,tenpayscan=trans_tp+scan,alipayscan=trans_ali+scan}else if(/zh-TW|zh-HK|zh-tw|zh-hk|zh-Hant|zh-hant|tw|hk/i.test(userLang)){if(document.write(""),"payment"===usage)method="付款";if("donate"===usage)method="捐贈";document.title="向"+finalname+method+aftertitle;trans_wx="WeChat ",trans_ali="支付寶",trans_tp="QQ手機版",finaltitle="向"+finalname+method,finalsub="從下方選擇"+method+"方式",scan="掃一掃",notavail="🚫 目前沒有可用的"+method+"方式",wechatscan=trans_wx+scan,tenpayscan=trans_tp+scan,alipayscan=trans_ali+scan,presshold="長按識別二維碼",payto=" 向"+finalname+method}else{if("payment"===usage){method="Pay";var method_t="Payment"}if("donate"===usage)method="Donate",method_t="Donation";var method_lc=method.charAt(0).toLowerCase();document.title=method+" to"+finalname_eng+aftertitle,document.write("");trans_wx="WeChat",trans_ali="AliPay",trans_tp="QQ Mobile",finaltitle=method+" to"+finalname_eng,finalsub="Select a "+method_t.replace(method_t.charAt(0),method_t.charAt(0).toLowerCase())+" method from below";var scanhint="Scan the QR Code to "+method+finalname_eng;presshold=method.replace(method.charAt(5),"")+method.charAt(5).replace("e","")+"ing to"+finalname_eng+":
Press and hold to recognise the QR Code",scan="Scan the QR Code with ",payto="",notavail="🚫 Currently no "+method_t.replace(method_t.charAt(0),method_t.charAt(0).toLowerCase())+" method available",wechatscan=scan+trans_wx,tenpayscan=scan+trans_tp,alipayscan=scan+trans_ali}var error_num=0;if("undefined"==typeof tenpay||null===tenpay||""===tenpay){document.getElementById("depends").removeChild(document.getElementById("tenpaybtn")),error_num+=1;var notenpay=!0}if("undefined"==typeof wechat||null===wechat||""===wechat){document.getElementById("depends").removeChild(document.getElementById("toclick")),error_num+=1;var nowechat=!0}if("undefined"==typeof alipay||null===alipay||""===alipay){document.getElementById("depends").removeChild(document.getElementById("alipaybtn")),error_num+=1;var noalipay=!0}if("undefined"==typeof paypal||null===paypal||""===paypal)document.getElementById("depends").removeChild(document.getElementById("paypalbtn")),error_num+=1;else function openbox(){function e(e,n,t){var a=null!=window.screenLeft?window.screenLeft:window.screenX,o=null!=window.screenTop?window.screenTop:window.screenY,i=window.innerWidth?window.innerWidth:document.documentElement.clientWidth?document.documentElement.clientWidth:screen.width,l=window.innerHeight?window.innerHeight:document.documentElement.clientHeight?document.documentElement.clientHeight:screen.height,r=i/window.screen.availWidth,d=(i-n)/2/r+a,s=(l-t)/2/r+o,c=window.open(e,"_blank","width="+n/r+", height="+t/r+", top="+s+", left="+d);window.focus&&c.focus()}selected="yes",window.innerHeight0&&(profile_url=profile_lg="https://ae01.alicdn.com/kf/Udaba9d58fade4a3e921c0ceba62db2b7n.png"),document.getElementById("i").style.background="url('"+profile_lg+"') no-repeat center/cover",$("#favicon").attr("href",profile_url);var userLang=navigator.language||navigator.userLanguage;if(!1!==multilingual)if(/zh-CN|zh-cn|zh-Hans|zh-hans|cn/i.test(userLang)){if("string"==typeof myname_hans)var myname=myname_hans}else if(/zh-TW|zh-HK|zh-tw|zh-hk|zh-Hant|zh-hant|tw|hk/i.test(userLang)){if("string"==typeof myname_hant)myname=myname_hant}else if("string"==typeof myname_eng)myname=myname_eng;var firstchar=myname.charAt(0),lastchar=myname.charAt(myname.length-1),english=/^[A-Za-z0-9]*$/;if(english.test(firstchar)||english.test(lastchar))var finalname=" "+myname+" ",finalsub=subtitle.replace(myname,finalname),spacing=!0;else finalname=myname;var finalname_eng=" "+myname;if(null==usage||""===usage||"payment"!==usage&&"donate"!==usage){var usage="payment";console.log("%c The usage variable is not defined correctly","color: red")}if("undefined"==typeof branding||null===branding||""===branding||!0!==branding&&"true"!==branding)var aftertitle="";else if(!0===branding||"true"===branding)aftertitle=" | Merger";if(!1===multilingual)var finaltitle=title,wechatscan="微信扫一扫 向"+finalname+"支付",tenpayscan="手机QQ扫一扫 向"+finalname+"支付",alipayscan="支付宝扫一扫 向"+finalname+"支付",payto="",presshold="长按识别二维码 向"+finalname+"支付",notavail="🚫 目前没有可用的支付方式",myname_hant=myname,myname_hans=myname,myname_eng=myname;else if(/zh-CN|zh-cn|zh-Hans|zh-hans|cn/i.test(userLang)){if(document.write(""),"payment"===usage)var method="付款";if("donate"===usage)method="捐赠";document.title="向"+finalname+method+aftertitle;var trans_wx="微信",trans_ali="支付宝",trans_tp="QQ手机版",scan=(finaltitle="向"+finalname+method,finalsub="从下方选择"+method+"方式",trans_wx="微信","扫一扫");presshold="长按识别二维码",payto=" 向"+finalname+method,notavail="🚫 目前没有可用的"+method+"方式",wechatscan=trans_wx+scan,tenpayscan=trans_tp+scan,alipayscan=trans_ali+scan}else if(/zh-TW|zh-HK|zh-tw|zh-hk|zh-Hant|zh-hant|tw|hk/i.test(userLang)){if(document.write(""),"payment"===usage)method="付款";if("donate"===usage)method="捐贈";document.title="向"+finalname+method+aftertitle;trans_wx="WeChat ",trans_ali="支付寶",trans_tp="QQ手機版",finaltitle="向"+finalname+method,finalsub="從下方選擇"+method+"方式",scan="掃一掃",notavail="🚫 目前沒有可用的"+method+"方式",wechatscan=trans_wx+scan,tenpayscan=trans_tp+scan,alipayscan=trans_ali+scan,presshold="長按識別二維碼",payto=" 向"+finalname+method}else{if("payment"===usage){method="Pay";var method_t="Payment"}if("donate"===usage)method="Donate",method_t="Donation";var method_lc=method.charAt(0).toLowerCase();document.title=method+" to"+finalname_eng+aftertitle,document.write("");trans_wx="WeChat",trans_ali="AliPay",trans_tp="QQ Mobile",finaltitle=method+" to"+finalname_eng,finalsub="Select a "+method_t.replace(method_t.charAt(0),method_t.charAt(0).toLowerCase())+" method from below";var scanhint="Scan the QR Code to "+method+finalname_eng;presshold=method.replace(method.charAt(5),"")+method.charAt(5).replace("e","")+"ing to"+finalname_eng+":
Press and hold to recognise the QR Code",scan="Scan the QR Code with ",payto="",notavail="🚫 Currently no "+method_t.replace(method_t.charAt(0),method_t.charAt(0).toLowerCase())+" method available",wechatscan=scan+trans_wx,tenpayscan=scan+trans_tp,alipayscan=scan+trans_ali}var error_num=0;if("undefined"==typeof tenpay||null===tenpay||""===tenpay){document.getElementById("depends").removeChild(document.getElementById("tenpaybtn")),error_num+=1;var notenpay=!0}if("undefined"==typeof wechat||null===wechat||""===wechat){document.getElementById("depends").removeChild(document.getElementById("toclick")),error_num+=1;var nowechat=!0}if("undefined"==typeof alipay||null===alipay||""===alipay){document.getElementById("depends").removeChild(document.getElementById("alipaybtn")),error_num+=1;var noalipay=!0}if("undefined"==typeof paypal||null===paypal||""===paypal)document.getElementById("depends").removeChild(document.getElementById("paypalbtn")),error_num+=1;else function openbox(){function e(e,n,t){var a=null!=window.screenLeft?window.screenLeft:window.screenX,o=null!=window.screenTop?window.screenTop:window.screenY,i=window.innerWidth?window.innerWidth:document.documentElement.clientWidth?document.documentElement.clientWidth:screen.width,l=window.innerHeight?window.innerHeight:document.documentElement.clientHeight?document.documentElement.clientHeight:screen.height,r=i/window.screen.availWidth,d=(i-n)/2/r+a,s=(l-t)/2/r+o,c=window.open(e,"_blank","width="+n/r+", height="+t/r+", top="+s+", left="+d);window.focus&&c.focus()}selected="yes",window.innerHeight - + +