2 Commits

Author SHA1 Message Date
cat-shark d74fcb9c41 feat(N/A):配置环境 2025-10-26 12:45:36 +08:00
cat-shark 44d5311c98 feat(N/A): 优化UI界面,尝试移除element-plus,自行实现UI 2025-10-03 09:09:31 +08:00
12 changed files with 143 additions and 73 deletions
+1 -1
View File
@@ -1 +1 @@
VITE_BASE_URL = 'http://localhost:5157' VITE_BASE_URL = 'http://192.168.123.199:5155'
+1
View File
@@ -0,0 +1 @@
VITE_BASE_URL = 'http://192.168.123.199:5156'
+7 -37
View File
@@ -1,50 +1,20 @@
<script setup lang="ts"> <script setup lang="ts">
import '@/components/css/app.css'
import MyHead from "@/components/MyHead.vue"; import MyHead from "@/components/MyHead.vue";
import MyFooter from "@/components/MyFooter.vue"; import MyFooter from "@/components/MyFooter.vue";
</script> </script>
<template> <template>
<div class="login"> <div class="common-layout">
<el-container class="common-layout"> <my-head/>
<el-header class="header"> <div class="router-view">
<MyHead />
</el-header>
<el-main class="main-content">
<RouterView/> <RouterView/>
</el-main>
<el-footer class="footer">
<MyFooter/>
</el-footer>
</el-container>
</div> </div>
<my-footer/>
</div>
</template> </template>
<style scoped> <style scoped>
#app {
margin: 0px 0px;
}
*{
padding:0px
}
.login {
display: flex;
justify-content: center;
align-items: center;
height: 100%;
background-size: cover;
}
.common-layout {
min-width: 100vw;
min-height: 100vh;
}
.main-content {
margin: 0 auto;
display: flex;
flex-direction: column;
}
</style> </style>
Binary file not shown.

After

Width:  |  Height:  |  Size: 5.1 MiB

+13 -20
View File
@@ -1,4 +1,5 @@
<script setup lang="ts"> <script setup lang="ts">
import '@/components/css/login.css'
import {reactive, ref} from "vue"; import {reactive, ref} from "vue";
import {ElMessage, type FormInstance, type FormRules} from "element-plus"; import {ElMessage, type FormInstance, type FormRules} from "element-plus";
import type {InternalRuleItem, Value} from "async-validator"; import type {InternalRuleItem, Value} from "async-validator";
@@ -67,29 +68,21 @@ const submitForm = async (formEl: FormInstance | undefined) => {
<template> <template>
<div class="login"> <div class="login">
<el-form ref="loginForm" :model = "registerData"> <!-- <el-form ref="loginForm" :model = "registerData">-->
<el-form-item label="账号:" :rules="rules.username" :model="registerData.username" prop="username"> <!-- <el-form-item label="账号:" :rules="rules.username" :model="registerData.username" prop="username">-->
<el-input v-model= "registerData.username"/> <!-- <el-input v-model= "registerData.username"/>-->
</el-form-item> <!-- </el-form-item>-->
<el-form-item label="密码:" :rules="rules.password" :model="registerData.password" prop="password"> <!-- <el-form-item label="密码:" :rules="rules.password" :model="registerData.password" prop="password">-->
<el-input v-model= "registerData.password" type="password"/> <!-- <el-input v-model= "registerData.password" type="password"/>-->
</el-form-item> <!-- </el-form-item>-->
<el-form-item> <!-- <el-form-item>-->
<el-button type="primary" @click="submitForm(loginForm)" style="width: 100%;">登录</el-button> <!-- <el-button type="primary" @click="submitForm(loginForm)" style="width: 100%;">登录</el-button>-->
</el-form-item> <!-- </el-form-item>-->
</el-form> <!-- </el-form>-->
登录页面
</div> </div>
</template> </template>
<style scoped> <style scoped>
*{
margin: 0;
padding: 0;
}
.login {
min-height: 25vh;
min-width: 30vw;
background: #22b9fa;
}
</style> </style>
+4 -9
View File
@@ -5,13 +5,8 @@
</template> </template>
<style scoped> <style scoped>
*{
margin: 20px;
padding:0px;
}
.footer {
text-align: center;
min-height: 8vh;
background-color: green;
}
</style> </style>
<script setup lang="ts">
import '@/components/css/myFooter.css'
</script>
+2 -4
View File
@@ -5,6 +5,7 @@
</template> </template>
<script setup lang="ts"> <script setup lang="ts">
import '@/components/css/myHead.css'
import {computed} from "vue"; import {computed} from "vue";
import {useRoute} from "vue-router"; import {useRoute} from "vue-router";
@@ -15,9 +16,6 @@ const isLoginRoute = computed(()=>route.path === '/login');
<style scoped> <style scoped>
.head { .head {
font-size: 30px;
text-align: center;
background: green;
min-height: 7vh;
} }
</style> </style>
+11
View File
@@ -0,0 +1,11 @@
<script setup lang="ts">
</script>
<template>
test
</template>
<style scoped>
</style>
+23
View File
@@ -0,0 +1,23 @@
html, body, #app {
height: 100vh;
width: 100vw;
margin: 0;
}
.common-layout {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
min-height: 100vh;
width: 100vw;
background: url("@/assets/background.webp") center center / cover no-repeat;
}
.router-view {
display: flex;
justify-content: center;
align-items: center;
flex: 1 1 0;
/*background: #ebeef5;*/
}
+35
View File
@@ -0,0 +1,35 @@
*{
margin: 0;
padding: 0;
}
/* 玻璃+边缘羽化 */
.login {
display: flex;
justify-content: center;
align-items: center;
/* 建议给点内边距和圆角,效果更柔和 */
min-width: 20vw;
max-width: 40vw;
min-height: 40vh;
max-height: 80vh;
border-radius: 16px;
/* 半透明底色——要有透明度,backdrop-filter 才能生效 */
background: rgba(255, 255, 255, 0.12);
/* 背景虚化 + 略微提高饱和度,玻璃质感 */
backdrop-filter: blur(16px) saturate(130%);
-webkit-backdrop-filter: blur(16px) saturate(130%);
/* 玻璃边框细线,可选 */
border: 1px solid rgba(255, 255, 255, 0.25);
box-shadow: 0 10px 30px rgba(0,0,0,0.18);
/* 关键:对自身做“羽化”遮罩,让四周渐隐,看起来像边缘被柔化/模糊 */
/* 72% 可自行调节,越小羽化范围越大 */
mask-image: radial-gradient(100% 100% at 50% 50%, #000 72%, transparent 100%);
}
+21
View File
@@ -0,0 +1,21 @@
*{
margin: 0;
padding: 0;
width: 100vw;
}
.footer {
text-align: center;
/*min-height: 100%;*/
/*min-width: 100%;*/
/* 半透明底色——要有透明度,backdrop-filter 才能生效 */
background: rgba(255, 255, 255, 0.12);
/* 背景虚化 + 略微提高饱和度,玻璃质感 */
backdrop-filter: blur(16px) saturate(130%);
-webkit-backdrop-filter: blur(16px) saturate(130%);
/* 玻璃边框细线,可选 */
border: 1px solid rgba(255, 255, 255, 0.25);
box-shadow: 0 10px 30px rgba(0,0,0,0.18);
}
+23
View File
@@ -0,0 +1,23 @@
*{
margin: 0;
padding: 0;
width: 100vw;
}
.head {
font-size: 30px;
text-align: center;
/*background: green;*/
/*min-height: 7vh;*/
/* 半透明底色——要有透明度,backdrop-filter 才能生效 */
background: rgba(255, 255, 255, 0.12);
/* 背景虚化 + 略微提高饱和度,玻璃质感 */
backdrop-filter: blur(16px) saturate(130%);
/*-webkit-backdrop-filter: blur(16px) saturate(130%);*/
/* 玻璃边框细线,可选 */
border: 1px solid rgba(255, 255, 255, 0.25);
box-shadow: 0 10px 30px rgba(0,0,0,0.18);
}