feat(固定排行榜): 顶部固定占位

This commit is contained in:
hzj 2026-02-27 14:38:37 +08:00
parent 790c1c38ef
commit 7197b28e19
4 changed files with 7 additions and 16 deletions

View File

@ -42,7 +42,7 @@
</itemCenter>
<!-- 状态栏占位区域仅在APP中显示 -->
<div v-if="isInAppEnvironment" style="height: 30px"></div>
<div style="height: 30px"></div>
<!-- 第一名 -->
<div style="display: flex; justify-content: center; margin-top: 11vw">
@ -747,7 +747,7 @@
<script setup>
import { computed, onMounted, onUnmounted, ref } from 'vue'
import { isInApp, viewUserInfo } from '@/utils/appBridge.js'
import { viewUserInfo } from '@/utils/appBridge.js'
import { connectToApp } from '@/utils/appConnector.js'
import { useLangStore } from '@/stores/lang'
import { getPngUrl, getWebpUrl } from '@/config/imagePaths.js'
@ -768,7 +768,6 @@ import itemCenter from '@/components/itemCenter.vue'
import TopUser from './components/topUser.vue'
import maskLayer from '@/components/MaskLayer.vue'
const isInAppEnvironment = ref(false) // APP
const gamesKingStore = useGamesKingStore()
//
@ -1104,7 +1103,6 @@ const connectToAppHandler = async () => {
onMounted(() => {
connectToAppHandler()
preloadOtherImages() //
isInAppEnvironment.value = isInApp()
checkShow() //

View File

@ -18,7 +18,7 @@
<div class="bg">
<!-- 状态栏占位区域仅在APP中显示 -->
<div v-if="isInAppEnvironment" style="height: 30px"></div>
<div style="height: 30px"></div>
<!-- 帮助按钮 -->
<img
@ -788,7 +788,7 @@
<script setup>
import { computed, onMounted, onUnmounted, ref } from 'vue'
import { isInApp, viewUserInfo } from '@/utils/appBridge.js'
import { viewUserInfo } from '@/utils/appBridge.js'
import { useLangStore } from '@/stores/lang'
import { useThrottle } from '@/utils/useDebounce'
import { connectToApp } from '@/utils/appConnector.js'
@ -837,8 +837,6 @@ const userInfo = ref({})
const visibleKingList = ref(true)
const isInAppEnvironment = ref(false) // APP
const historyList = ref([]) //
const showTopOne = computed(() => {
let topNew = []
@ -1172,7 +1170,6 @@ const completePreloading = async () => {
//
onMounted(() => {
isInAppEnvironment.value = isInApp()
connectToAppHandler()
getCountdown()

View File

@ -36,7 +36,7 @@
"
>
<!-- 状态栏占位区域仅在APP中显示 -->
<div v-if="isInAppEnvironment" style="height: 60px"></div>
<div style="height: 60px"></div>
<!-- 顶部导航栏 -->
<div style="padding: 4px 8%">

View File

@ -42,9 +42,7 @@
<div
style="min-height: 20.66vw; display: flex; justify-content: flex-end; width: 100%"
:style="{
marginTop: isInAppEnvironment
? 'calc(65vw - 30px - 10vw - 10vw - 20px)'
: 'calc(65vw - 10vw - 10vw - 20px)',
marginTop: 'calc(65vw - 30px - 10vw - 10vw - 20px)',
}"
>
<img
@ -852,7 +850,7 @@
<script setup>
import { computed, onMounted, onUnmounted, ref } from 'vue'
import { isInApp, viewUserInfo } from '@/utils/appBridge.js'
import { viewUserInfo } from '@/utils/appBridge.js'
import { useLangStore } from '@/stores/lang'
import { connectToApp } from '@/utils/appConnector.js'
import { useThrottle } from '@/utils/useDebounce'
@ -904,7 +902,6 @@ const connectToAppHandler = async () => {
const userInfo = ref({})
const isInAppEnvironment = ref(false) // APP
const helpInfoShow = ref(false) //
const historyShow = ref(false) //
const giftsShow = ref(false) //
@ -1280,7 +1277,6 @@ const completePreloading = async () => {
//
onMounted(() => {
connectToAppHandler()
isInAppEnvironment.value = isInApp()
getCountdown()
timer = setInterval(getCountdown, 1000) //