You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
2 lines
1.1 KiB
2 lines
1.1 KiB
"use strict";const t=require("../../common/vendor.js"),a=require("./provider/wechat/index.js"),p=require("./provider/apple/index.js"),u=require("./share.js"),h=require("./pay.js"),r=t.index.getSystemInfoSync(),f=r.platform;let o="",n="",s="",d=!0;o="WechatMiniProgram";s="miniProgram";n="wechat";t.lodashExports.isEmpty(o)&&t.index.showToast({title:"暂不支持该平台",icon:"none"});const m=()=>{n==="wechat"&&a.wechat.load()},c=(e="")=>{if(e===""&&(e=n),e==="wechat")return a.wechat;if(e==="apple")return p.apple},g=(e,i,l)=>new h.SheepPay(e,i,l),w=(e=!1)=>{c().checkUpdate(e)};async function _(){return(await t.index.getNetworkType()).networkType=="none"?Promise.resolve(!1):Promise.resolve(!0)}const y=()=>{let e=t.index.getMenuButtonBoundingClientRect();return e||(e={bottom:56,height:32,left:278,right:365,top:24,width:87}),e},k=y(),P=()=>r.statusBarHeight+44,v=P();function x(){return""}const q=x(),S={name:o,device:r,os:f,provider:n,platform:s,useProvider:c,checkUpdate:w,checkNetwork:_,pay:g,share:u.$share,load:m,capsule:k,navbar:v,landingPage:q,isWechatInstalled:d};exports._platform=S;
|