优化前端
This commit is contained in:
1 parent
34f62a6bed
commit
85c7c7a683
8 files changed
+157
-71
No files matched your search
@@ -1,33 +1,12 @@
|
|||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { onMounted, ref } from 'vue'
|
|
||||||
import http from '../api/http'
|
|
||||||
|
|
||||||
interface SystemVersionResponse {
|
|
||||||
version: string
|
|
||||||
}
|
|
||||||
|
|
||||||
const backendVersion = ref('获取中')
|
|
||||||
const currentYear = new Date().getFullYear()
|
const currentYear = new Date().getFullYear()
|
||||||
const frontendVersion = __APP_VERSION__
|
|
||||||
|
|
||||||
onMounted(async () => {
|
|
||||||
try {
|
|
||||||
const { data } = await http.get<SystemVersionResponse>('/system/version')
|
|
||||||
backendVersion.value = data.version ? `v${data.version}` : '未知'
|
|
||||||
} catch {
|
|
||||||
backendVersion.value = '未知'
|
|
||||||
}
|
|
||||||
})
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
<footer class="site-footer" aria-label="网站版权与版本信息">
|
<footer class="site-footer" aria-label="网站版权信息">
|
||||||
<div class="site-footer-inner">
|
<div class="site-footer-inner">
|
||||||
<p>© {{ currentYear }} 明序教务 · 版权所有</p>
|
<p>© {{ currentYear }} 明序教务 · 版权所有</p>
|
||||||
<div class="version-list" aria-label="系统版本">
|
<span class="footer-note">教务管理与学业服务平台</span>
|
||||||
<span>前端版本 <b>v{{ frontendVersion }}</b></span>
|
|
||||||
<span>后端版本 <b>{{ backendVersion }}</b></span>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</footer>
|
</footer>
|
||||||
</template>
|
</template>
|
||||||
@@ -61,27 +40,7 @@ onMounted(async () => {
|
|||||||
letter-spacing: .04em;
|
letter-spacing: .04em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.version-list {
|
.footer-note { color: #aeb9d8; font-size: 11px; }
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 8px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.version-list span {
|
|
||||||
padding: 5px 9px;
|
|
||||||
border: 1px solid rgba(255, 255, 255, .14);
|
|
||||||
border-radius: 4px;
|
|
||||||
color: #aeb9d8;
|
|
||||||
background: rgba(255, 255, 255, .055);
|
|
||||||
font-size: 10px;
|
|
||||||
white-space: nowrap;
|
|
||||||
}
|
|
||||||
|
|
||||||
.version-list b {
|
|
||||||
margin-left: 5px;
|
|
||||||
color: #66d5c5;
|
|
||||||
font: 700 10px/1.2 Consolas, monospace;
|
|
||||||
}
|
|
||||||
|
|
||||||
@media (max-width: 600px) {
|
@media (max-width: 600px) {
|
||||||
.site-footer-inner {
|
.site-footer-inner {
|
||||||
@@ -93,13 +52,6 @@ onMounted(async () => {
|
|||||||
gap: 7px;
|
gap: 7px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.version-list {
|
.footer-note { font-size: 10px; }
|
||||||
width: 100%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.version-list span {
|
|
||||||
flex: 1;
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -53,7 +53,7 @@ onBeforeUnmount(() => {
|
|||||||
<div class="smart-launch-mark" aria-hidden="true">
|
<div class="smart-launch-mark" aria-hidden="true">
|
||||||
<i v-for="index in 9" :key="index" />
|
<i v-for="index in 9" :key="index" />
|
||||||
</div>
|
</div>
|
||||||
<span class="smart-launch-brand">MINGXU ACADEMIC</span>
|
<span class="smart-launch-brand">明序教务</span>
|
||||||
<p>{{ greeting.label }}</p>
|
<p>{{ greeting.label }}</p>
|
||||||
<h1>{{ greeting.title }}</h1>
|
<h1>{{ greeting.title }}</h1>
|
||||||
<small>{{ greeting.subtitle }}</small>
|
<small>{{ greeting.subtitle }}</small>
|
||||||
@@ -117,7 +117,7 @@ onBeforeUnmount(() => {
|
|||||||
color: #8fe4dc;
|
color: #8fe4dc;
|
||||||
font-size: 0.68rem;
|
font-size: 0.68rem;
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
letter-spacing: 0.28em;
|
letter-spacing: 0.16em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.smart-launch-content p {
|
.smart-launch-content p {
|
||||||
|
|||||||
@@ -329,7 +329,7 @@ onMounted(() => {
|
|||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<strong>明序教务</strong>
|
<strong>明序教务</strong>
|
||||||
<small>ACADEMIC OFFICE</small>
|
<small>教务管理与学业服务</small>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
@@ -394,7 +394,7 @@ onMounted(() => {
|
|||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<strong>明序教务</strong>
|
<strong>明序教务</strong>
|
||||||
<small>ACADEMIC OFFICE</small>
|
<small>教务管理与学业服务</small>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<button type="button" aria-label="关闭导航菜单" @click="mobileMenu = false">×</button>
|
<button type="button" aria-label="关闭导航菜单" @click="mobileMenu = false">×</button>
|
||||||
|
|||||||
Loaded 3 of 8 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user