From 5ea84f0c5f2fe0c4fd2bb2464fd47198a659ea23 Mon Sep 17 00:00:00 2001 From: aixianling Date: Mon, 20 Mar 2023 09:28:05 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4=E8=AF=BB=E5=8F=96=E9=A1=BA?= =?UTF-8?q?=E5=BA=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/utils/PageBase.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/components/utils/PageBase.js b/src/components/utils/PageBase.js index ad7c600..acab687 100644 --- a/src/components/utils/PageBase.js +++ b/src/components/utils/PageBase.js @@ -6,6 +6,10 @@ class PageBase { } init(vue) { + if (/appName/.test(vue)) { + let appName = vue.replace(/[\s\S]*(appName:.+),[\s\S]*/gm, '$1') + this.label = appName.replace(/(appName:|["'])/g, '')?.trim() + } if (/customNavigation/.test(vue)) { this.style = {navigationStyle: "custom"} } else { @@ -27,10 +31,6 @@ class PageBase { // this.style.backgroundColor = vue.replace(/[\s\S]*(backgroundColor:.+),[\s\S]*/gm, '$1') // } } - if (/appName/.test(vue)) { - let appName = vue.replace(/[\s\S]*(appName:.+),[\s\S]*/gm, '$1') - this.label = appName.replace(/(appName:|["'])/g, '')?.trim() - } } setLabel(name) {