ffi
This commit is contained in:
parent
df34a7c282
commit
60ffee77cf
@ -98,7 +98,9 @@ onUnmounted(() => {
|
||||
.banner-boder {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
height: 79px;
|
||||
right: 0;
|
||||
width: 100%;
|
||||
// height: 79px;
|
||||
bottom: -1px;
|
||||
}
|
||||
.introduction-bg {
|
||||
|
@ -91,6 +91,7 @@ import Slogan from "./Slogan.vue";
|
||||
.download-item-andriod {
|
||||
width:207px;
|
||||
height: 62px;
|
||||
opacity: 0.9;
|
||||
background-color: #161515;
|
||||
cursor: pointer;
|
||||
position: relative;
|
||||
|
@ -122,16 +122,15 @@ const showNavMenu = ref(false);
|
||||
const activeIndex = ref(0);
|
||||
const navList = reactive([
|
||||
{ id: 0, name: "HOME", path: "/home" },
|
||||
{ id: 1, name: "PRE-ORDER", path: "/pre" },
|
||||
{ id: 2, name: "ABOUT", path: "/about" },
|
||||
{ id: 1, name: "ABOUT", path: "/about" },
|
||||
{
|
||||
id: 3,
|
||||
id: 2,
|
||||
name: "MARKETPLACE",
|
||||
path: "/marketpalce",
|
||||
submenu: [{ label: "Coming soon", link: "/products/1" }],
|
||||
},
|
||||
{
|
||||
id: 4,
|
||||
id: 3,
|
||||
name: "COMMUNITY",
|
||||
path: "/contact",
|
||||
submenu: [
|
||||
@ -149,12 +148,12 @@ const navList = reactive([
|
||||
{ label: "Discord", link: "https://discord.com/invite/fNSn2NHUvf" },
|
||||
],
|
||||
},
|
||||
{ id: 5, name: "BETA TEST II", path: "/" },
|
||||
{ id: 4, name: "BETA TEST II", path: "/" },
|
||||
]);
|
||||
|
||||
function handNavCurent(nav) {
|
||||
activeIndex.value = nav.id;
|
||||
if (nav.id === 0 || nav.id === 1 || nav.id === 2 ||nav.id === 5 ) {
|
||||
if (nav.id === 0 || nav.id === 1 || nav.id === 4 ) {
|
||||
router.push(nav.path);
|
||||
}
|
||||
}
|
||||
|
@ -1,21 +1,23 @@
|
||||
import { createRouter, createWebHistory } from 'vue-router';
|
||||
import Home from '../views/HomeView.vue';
|
||||
import GamePromotionEvent from '../views/GamePromotionEvent.vue';
|
||||
|
||||
const routes = [
|
||||
{
|
||||
path: '/',
|
||||
name: 'game',
|
||||
component: () => import(/* webpackChunkName "game" */ '../views/GamePromotionEvent.vue'),
|
||||
},
|
||||
{
|
||||
path: '/pre',
|
||||
name: 'pre',
|
||||
component: () => import(/* webpackChunkName "pre" */ '../views/GameEventBookingView.vue'),
|
||||
component:GamePromotionEvent,
|
||||
},
|
||||
{
|
||||
path: '/home',
|
||||
name: 'home',
|
||||
component: () => import(/* webpackChunkName "home" */ '../views/HomeView.vue'),
|
||||
component: Home,
|
||||
},
|
||||
// {
|
||||
// path: '/pre',
|
||||
// name: 'pre',
|
||||
// component: () => import(/* webpackChunkName "pre" */ '../views/GameEventBookingView.vue'),
|
||||
// },
|
||||
{
|
||||
path: '/about',
|
||||
name: 'about',
|
||||
|
@ -1,34 +1,32 @@
|
||||
<template>
|
||||
<div class="container">
|
||||
<div class="background"></div>
|
||||
<div class="content" @scroll="handleScroll">
|
||||
<div class="right-content" v-show="activeDiv === 0">
|
||||
<p v-for="i in 50" :key="'A' + i">这是 A 段落 {{ i }}</p>
|
||||
</div>
|
||||
<div class="right-content" v-show="activeDiv === 1">
|
||||
<p v-for="i in 50" :key="'B' + i">这是 B 段落 {{ i }}</p>
|
||||
</div>
|
||||
<div class="content pt-40 pl-10 pr-10 pb-10" @wheel="handleScroll">
|
||||
<div class="left">左边的内容</div>
|
||||
<div class="right">
|
||||
<div v-show="isContentA">内容a</div>
|
||||
<div v-show="!isContentA">内容b</div>
|
||||
</div>
|
||||
<div class="background"></div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref, computed, onMounted, onUnmounted } from "vue";
|
||||
const activeDiv = ref(0);
|
||||
import { ref } from "vue";
|
||||
|
||||
function handleScroll(e) {
|
||||
const scrollTop = e.target.scrollTop;
|
||||
activeDiv.value = scrollTop >= window.innerHeight ? 1 : 0;
|
||||
}
|
||||
const isContentA = ref(true);
|
||||
|
||||
const handleScroll = (event) => {
|
||||
if (event.deltaY !== 0) {
|
||||
isContentA.value = !isContentA.value;
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped>
|
||||
.container {
|
||||
position: relative;
|
||||
<style scoped>
|
||||
.content {
|
||||
display: flex;
|
||||
height: 100vh;
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.background {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
@ -42,18 +40,11 @@ function handleScroll(e) {
|
||||
background-size: cover;
|
||||
}
|
||||
|
||||
.content {
|
||||
position: relative;
|
||||
height: 100%;
|
||||
overflow-y: auto;
|
||||
padding: 1rem;
|
||||
.left {
|
||||
width: 50%;
|
||||
}
|
||||
|
||||
.right-content {
|
||||
display: none;
|
||||
}
|
||||
|
||||
.right-content {
|
||||
display: block;
|
||||
.right {
|
||||
width: 50%;
|
||||
}
|
||||
</style>
|
||||
|
@ -1,6 +1,5 @@
|
||||
/** @type {import('tailwindcss').Config} */
|
||||
export default {
|
||||
darkMode: false, // or 'media' or 'class',
|
||||
content: ["./index.html", "./src/**/*.{vue,js,ts,jsx,tsx}"],
|
||||
theme: {
|
||||
extend: {},
|
||||
|
Loading…
x
Reference in New Issue
Block a user