更新了部分样式

This commit is contained in:
Sky_ID 2022-05-23 18:17:53 +08:00
parent 3e44355e45
commit b6231eceab
13 changed files with 216 additions and 129 deletions

View File

@ -1,5 +1,10 @@
<!DOCTYPE html>
<html lang="en">
<style>
body{
margin: 0;
}
</style>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">

View File

@ -18,10 +18,6 @@ export default {
<style>
#app {
font-family: Avenir, Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-align: center;
color: #2c3e50;
margin-top: 60px;
}
</style>

BIN
src/assets/banner.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 711 KiB

30
src/assets/css/Footer.css Normal file
View File

@ -0,0 +1,30 @@
.footer{
position: fixed;
bottom: 0;
height:11.3vw;
width: 100%;
align-items: center;
background-color: #0a1d30;
}
.footer-content{
display: flex;
justify-content: center;
align-items: center;
margin: 3.2vw;
}
.logo{
width: 200px;
}
.text{
text-align: center;
align-items: center;
margin-left: 50px;
color: white;
font-size: 15px;
vertical-align: middle;
}

11
src/assets/css/Header.css Normal file
View File

@ -0,0 +1,11 @@
.nav{
text-align: center;
display: flex;
/*vertical-align: center;*/
justify-content: center;
}
.el-menu-item{
font-size: 1.1rem;
}

28
src/assets/logo-white.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 20 KiB

1
src/assets/logo.svg Normal file

File diff suppressed because one or more lines are too long

After

Width:  |  Height:  |  Size: 9.5 KiB

BIN
src/assets/logo/tel.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

30
src/components/Footer.vue Normal file
View File

@ -0,0 +1,30 @@
<template>
<div class="footer">
<div class="footer-content">
<el-image :src="logo" class="logo"></el-image>
<div class="text">
<div>
+86-010-66357650
osredm@163.com 北京市海淀区西三环北路72号</div>
<div style="margin-top: 10px">版权所有红山开源社区 京公网安备 11010802034576 京ICP备2021005060-1</div>
</div>
</div>
</div>
</template>
<script>
export default {
name: "Footer",
data(){
return{
logo: require("../assets/logo-white.svg")
}
}
}
</script>
<style src="./../assets/css/Footer.css" scoped>
</style>

55
src/components/Header.vue Normal file
View File

@ -0,0 +1,55 @@
<template>
<div>
<el-image :src="bannerLogo" style="width: 100%; height: auto"/>
<!--导航栏-->
<!--TODO: 需要根据设定动态更改-->
<el-menu :default-active="activeIndex" class="nav" mode="horizontal" @select="handleSelect">
<!-- <el-menu-item index="0"><el-image :src="logoImg" style="width: 120px"/></el-menu-item>-->
<el-image :src="logoImg" style="width: 120px; margin-right: 50px"/>
<el-menu-item index="1">首页</el-menu-item>
<!-- <el-submenu index="2">-->
<!-- <template slot="title">我的工作台</template>-->
<!-- <el-menu-item index="2-1">选项1</el-menu-item>-->
<!-- <el-menu-item index="2-2">选项2</el-menu-item>-->
<!-- <el-menu-item index="2-3">选项3</el-menu-item>-->
<!-- <el-submenu index="2-4">-->
<!-- <template slot="title">选项4</template>-->
<!-- <el-menu-item index="2-4-1">选项1</el-menu-item>-->
<!-- <el-menu-item index="2-4-2">选项2</el-menu-item>-->
<!-- <el-menu-item index="2-4-3">选项3</el-menu-item>-->
<!-- </el-submenu>-->
<!-- </el-submenu>-->
<el-menu-item index="2" >赛事指南</el-menu-item>
<el-menu-item index="3" >通知公告</el-menu-item>
<el-menu-item index="4" >参赛报名</el-menu-item>
<el-menu-item index="5" >提案提交</el-menu-item>
<el-menu-item index="6" >数据统计</el-menu-item>
<el-menu-item index="7" >交流互动</el-menu-item>
<el-menu-item index="8" >联系我们</el-menu-item>
<el-menu-item index="9">后台管理</el-menu-item>
</el-menu>
</div>
</template>
<script>
export default {
name: "Header",
data() {
return {
bannerLogo: require("../assets/banner.jpg"),
logoImg: require("../assets/logo.svg"),
activeIndex: '1',
activeIndex2: '1'
};
},
methods: {
handleSelect(key, keyPath) {
console.log(key, keyPath);
}
}
}
</script>
<style src="./../assets/css/Header.css" scoped>
</style>

23
src/layout/HomeLayout.vue Normal file
View File

@ -0,0 +1,23 @@
<template>
<div>
<Header></Header>
<router-view></router-view>
<Footer></Footer>
</div>
</template>
<script>
import Header from "@/components/Header.vue"
import Footer from "@/components/Footer.vue"
export default {
name: "HomeLayout",
components:{
Header,
Footer
}
}
</script>
<style scoped>
</style>

15
src/pages/Home.vue Normal file
View File

@ -0,0 +1,15 @@
<template>
<div>
</div>
</template>
<script>
export default {
name: "Home"
}
</script>
<style scoped>
</style>

View File

@ -4,136 +4,29 @@ import VueRouter from 'vue-router'
Vue.use(VueRouter)
let routes = [
{
//TODO:404
path: '*',
component: () => import('../views/develop.vue'),
},
// {
// //TODO:404
// path: '*',
// component: () => import('../views/develop.vue'),
// },
{
path: '/',
component: () => import("@/layout/HomeLayout"),
name: 'Home',
redirect: '/home',
},
{
path: '/dashboard',
name: 'Dashboard',
layout: "dashboard",
// route level code-splitting
// this generates a separate chunk (about.[hash].js) for this route
// which is lazy-loaded when the route is visited.
component: () => import(/* webpackChunkName: "dashboard" */ '../views/Dashboard.vue'),
},
{
path: '/info',
name: '信息版',
layout: "dashboard",
// route level code-splitting
// this generates a separate chunk (about.[hash].js) for this route
// which is lazy-loaded when the route is visited.
component: () => import(/* webpackChunkName: "dashboard" */ '../views/Info-Page.vue'),
children:[
{
// 首页
path: "/home",
component: () => import("@/pages/Home"),
meta: {
// 页面标题title
title: '红山开源社区'
}
},
]
},
{
path: '/tables',
name: 'Tables',
layout: "dashboard",
component: () => import('../views/Tables.vue'),
},
{
path: '/billing',
name: 'Billing',
layout: "dashboard",
component: () => import('../views/Billing.vue'),
},
{
path: '/rtl',
name: 'RTL',
layout: "dashboard-rtl",
meta: {
layoutClass: 'dashboard-rtl',
},
component: () => import('../views/RTL.vue'),
},
{
path: '/Profile',
name: '个人主页',
layout: "dashboard",
meta: {
layoutClass: 'layout-profile',
},
component: () => import('../views/Profile.vue'),
},
{
path: '/sign-in',
name: 'Sign-In',
component: () => import('../views/Sign-In.vue'),
},
{
path: '/activeAccount',
name: 'ActiveAccount',
component: () => import('../views/ActiveAccount.vue'),
},
{
path: '/sign-up',
name: 'Sign-Up',
meta: {
layoutClass: 'layout-sign-up',
},
component: () => import('../views/Sign-Up.vue'),
},
{
path: '/reviewApply',
name: '申请成为审核员',
layout: 'dashboard',
component: () => import('../views/ReviewApply.vue'),
},
{
path: '/home',
name: 'Home',
meta: {
layoutClass: 'layout-home',
},
component: () => import('../views/Home.vue'),
},
{
path: '/caseDetails',
name: 'CaseDetails',
component: () => import('../views/CaseDetails.vue'),
},
{
path: '/infoList',
name: '案例信息',
layout: "dashboard",
component: () => import('../views/InfoList.vue'),
},
{
path: '/authManage',
name: '认证审核',
layout: "manage",
component: () => import('../views/AuthManage.vue'),
},
{
path: '/userManage',
name: '用户管理',
layout: "manage",
component: () => import('../views/UserManage.vue'),
},
{
path: '/searchResult',
name: '搜索结果',
layout: "dashboard",
component: () => import('../views/SearchResult.vue'),
},
{
path: '/casePost',
name: 'CasePost',
component: () => import('../views/CasePost.vue'),
},
]
// Adding layout property from each route to the meta