mirror of
https://github.com/yangjian102621/geekai.git
synced 2025-11-15 05:33:44 +08:00
auto jump to mobile page when use mobile device access the page
This commit is contained in:
@@ -18,15 +18,8 @@
|
||||
|
||||
<script setup>
|
||||
import {ref, watch} from "vue";
|
||||
import {useRouter} from "vue-router";
|
||||
import {isMobile} from "@/utils/libs";
|
||||
import {useSharedStore} from "@/store/sharedata";
|
||||
|
||||
const router = useRouter()
|
||||
if (!isMobile()) {
|
||||
router.replace('/')
|
||||
}
|
||||
|
||||
const active = ref('home')
|
||||
const store = useSharedStore()
|
||||
const theme = ref(store.mobileTheme)
|
||||
|
||||
Reference in New Issue
Block a user