refactor: 移除愈心魔方页同级 cover-view,顶栏仅用 image logo(202608280)
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
@@ -3,14 +3,12 @@
|
|||||||
<view class="yxg-page">
|
<view class="yxg-page">
|
||||||
<view class="yxg-nav-bar" :style="navBarStyle">
|
<view class="yxg-nav-bar" :style="navBarStyle">
|
||||||
<view class="yxg-nav-row" :style="navRowStyle">
|
<view class="yxg-nav-row" :style="navRowStyle">
|
||||||
<!-- #ifndef MP-WEIXIN -->
|
|
||||||
<image
|
<image
|
||||||
class="yxg-nav-logo"
|
class="yxg-nav-logo"
|
||||||
:src="YXG_MP_LOGO_URL"
|
:src="YXG_MP_LOGO_URL"
|
||||||
mode="aspectFit"
|
mode="aspectFit"
|
||||||
:style="logoStyle"
|
:style="logoStyle"
|
||||||
/>
|
/>
|
||||||
<!-- #endif -->
|
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<web-view
|
<web-view
|
||||||
@@ -20,16 +18,6 @@
|
|||||||
@load="onWebLoad"
|
@load="onWebLoad"
|
||||||
@error="onWebError"
|
@error="onWebError"
|
||||||
/>
|
/>
|
||||||
<!-- #ifdef MP-WEIXIN -->
|
|
||||||
<!-- 同级 cover:仅承载 logo,不在 web-view 内;普通 image 会被 web-view 盖住 -->
|
|
||||||
<cover-view class="yxg-logo-cover" :style="logoCoverStyle">
|
|
||||||
<cover-image
|
|
||||||
class="yxg-nav-logo"
|
|
||||||
:src="YXG_MP_LOGO_URL"
|
|
||||||
:style="coverLogoStyle"
|
|
||||||
/>
|
|
||||||
</cover-view>
|
|
||||||
<!-- #endif -->
|
|
||||||
</view>
|
</view>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -69,15 +57,11 @@ const headH = statusBarH + navBarH
|
|||||||
const webviewH = windowH - headH
|
const webviewH = windowH - headH
|
||||||
const logoH = Math.min(menuH, 30)
|
const logoH = Math.min(menuH, 30)
|
||||||
const logoW = Math.min(Math.round((logoH * 598) / 130), Math.floor(screenW * 0.4))
|
const logoW = Math.min(Math.round((logoH * 598) / 130), Math.floor(screenW * 0.4))
|
||||||
const logoLeft = Math.floor((screenW - logoW) / 2)
|
|
||||||
const logoTop = Math.floor((navBarH - logoH) / 2)
|
|
||||||
|
|
||||||
const navBarStyle = `height:${headH}px;padding-top:${statusBarH}px;box-sizing:border-box;`
|
const navBarStyle = `height:${headH}px;padding-top:${statusBarH}px;box-sizing:border-box;`
|
||||||
const navRowStyle = `height:${navBarH}px;`
|
const navRowStyle = `height:${navBarH}px;`
|
||||||
const logoStyle = `width:${logoW}px;height:${logoH}px;`
|
const logoStyle = `width:${logoW}px;height:${logoH}px;`
|
||||||
const webviewStyle = `top:${headH}px;height:${webviewH}px;`
|
const webviewStyle = `top:${headH}px;height:${webviewH}px;`
|
||||||
const logoCoverStyle = `position:fixed;top:${statusBarH}px;left:0;width:${screenW}px;height:${navBarH}px;z-index:9999;`
|
|
||||||
const coverLogoStyle = `position:absolute;left:${logoLeft}px;top:${logoTop}px;width:${logoW}px;height:${logoH}px;`
|
|
||||||
|
|
||||||
const h5Url = computed(
|
const h5Url = computed(
|
||||||
() =>
|
() =>
|
||||||
|
|||||||
+1
-1
@@ -2,7 +2,7 @@
|
|||||||
import { LOCAL_H5_HOST, USE_LOCAL_H5 } from './yxgConfig.local.js'
|
import { LOCAL_H5_HOST, USE_LOCAL_H5 } from './yxgConfig.local.js'
|
||||||
|
|
||||||
const PROD_BASE = 'https://h5.yuxingu.com.cn/psy/'
|
const PROD_BASE = 'https://h5.yuxingu.com.cn/psy/'
|
||||||
const PROD_VERSION = '202608279'
|
const PROD_VERSION = '202608280'
|
||||||
/** 愈心魔方顶栏 logo(小程序包内 static,不请求外网) */
|
/** 愈心魔方顶栏 logo(小程序包内 static,不请求外网) */
|
||||||
export const YXG_MP_LOGO_URL = '/static/n-main/yxg-brand-logo.png'
|
export const YXG_MP_LOGO_URL = '/static/n-main/yxg-brand-logo.png'
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user