fix:打包报错

This commit is contained in:
小张 2025-08-22 17:11:28 +08:00
parent 1a11290c97
commit e18d5f610f
3 changed files with 81 additions and 37 deletions

View File

@ -91,12 +91,10 @@
<span>{{ t('header.management') }}</span>
</div>
<!-- 登录/注册按钮 -->
<!-- 登录按钮 -->
<div v-if="!userStore.isLoggedIn" class="auth-buttons">
<div class="auth-combined-btn">
<span class="auth-login" @click="showLoginModal">{{ t('header.login') }}</span>
<span class="auth-divider">|</span>
<span class="auth-register" @click="showRegisterModal">{{ t('header.register') }}</span>
</div>
</div>
@ -285,16 +283,11 @@ const showLoginModal = () => {
loginModalVisible.value = true
}
//
const showRegisterModal = () => {
//
// registerNoticeVisible
//
//
registerModalVisible.value = true
registerNoticeVisible.value = false
}
//
// const showRegisterModal = () => {
// registerModalVisible.value = true
// registerNoticeVisible.value = false
// }
//
const handleAuthSuccess = () => {
@ -659,9 +652,9 @@ onUnmounted(() => {
background: #0088D1;
color: white;
border-radius: 5px;
padding: 8px 10px;
font-size: 12px;
font-weight: 400;
padding: 6px 24px;
font-size: 15px;
font-weight: 500;
cursor: pointer;
transition: all 0.2s;
}
@ -670,16 +663,16 @@ onUnmounted(() => {
background: #40a9ff;
}
.auth-login,
.auth-register {
padding: 0 8px;
.auth-login {
padding: 0;
cursor: pointer;
transition: all 0.2s;
font-size: inherit;
font-weight: inherit;
}
.auth-login:hover,
.auth-register:hover {
opacity: 0.8;
.auth-login:hover {
opacity: 0.9;
}
.auth-divider {

View File

@ -128,14 +128,14 @@ const navigateToTeacherDetail = (teacherId: number) => {
router.push(`/teacher/${teacherId}`)
}
//
const toggleCourseInfo = (teacherId: number) => {
if (expandedTeacherId.value === teacherId) {
expandedTeacherId.value = null
} else {
expandedTeacherId.value = teacherId
}
}
//
// const toggleCourseInfo = (teacherId: number) => {
// if (expandedTeacherId.value === teacherId) {
// expandedTeacherId.value = null
// } else {
// expandedTeacherId.value = teacherId
// }
// }
//
const showCourseInfo = (teacherId: number) => {
@ -143,7 +143,7 @@ const showCourseInfo = (teacherId: number) => {
}
//
const hideCourseInfo = (teacherId: number) => {
const hideCourseInfo = (_teacherId: number) => {
expandedTeacherId.value = null
}

View File

@ -45,12 +45,25 @@ import { AlertCircleOutline } from '@vicons/ionicons5'
align-items: center;
justify-content: center;
background: #f8f9fa;
padding: 20px;
box-sizing: border-box;
}
.container {
width: 100%;
display: flex;
align-items: center;
justify-content: center;
}
.not-found-content {
text-align: center;
max-width: 500px;
width: 100%;
padding: 40px;
background: white;
border-radius: 12px;
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}
.error-image {
@ -121,21 +134,59 @@ p {
}
@media (max-width: 768px) {
.not-found-content {
padding: 20px;
.not-found {
padding: 15px;
}
.not-found-content {
padding: 30px 20px;
max-width: 400px;
}
h1 {
font-size: 4rem;
}
h2 {
font-size: 1.5rem;
}
.actions {
flex-direction: column;
align-items: center;
gap: 12px;
}
.actions .n-button {
width: 100%;
max-width: 200px;
}
}
@media (max-width: 480px) {
.not-found {
padding: 10px;
}
.not-found-content {
padding: 20px 15px;
max-width: 350px;
}
h1 {
font-size: 3rem;
}
h2 {
font-size: 1.3rem;
}
p {
font-size: 1rem;
}
.suggestions {
padding: 20px;
}
}
</style>