"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./common/vendor.js");Math;const o={onLaunch:function(){console.log("App Launch");let o=e.index.getWindowInfo();e.provide("statusHeight",o.statusBarHeight),e.provide("windowWidth",o.windowWidth),e.provide("safeAreaTop",o.safeArea.top);var t=o.safeAreaInsets.bottom;let n=e.index.getMenuButtonBoundingClientRect();e.provide("navHeight",n.bottom+n.top-o.statusBarHeight),e.provide("menuTop",n.top),e.provide("menuHeight",n.height),e.provide("isiPhoneX",34==t)},onShow:function(){console.log("App Show"),this.updateManager()},onHide:function(){console.log("App Hide")},globalData:{mobileReg:/^1[3456789][0-9]{9}$/},methods:{updateManager(){const o=e.index.getUpdateManager();o.onCheckForUpdate((t=>{t.hasUpdate&&e.index.showModal({title:"更新提示",content:"检测到新版本，是否下载新版本并重启小程序？",success(t){t.confirm&&o.onUpdateReady((()=>{e.index.showModal({title:"更新提示",content:"新版本已经准备好，即将重启应用",showCancel:!1,success(e){e.confirm&&o.applyUpdate()}})}))},fail(e){}}),o.onUpdateFailed((()=>{e.index.showModal({title:"更新提示",content:"新版本下载失败",showCancel:!1})}))}))}}};function t(){return{app:e.createSSRApp(o)}}t().app.mount("#app"),exports.createApp=t;
