Template
1
0
mirror of https://github.com/un-pany/v3-admin-vite.git synced 2025-04-20 10:59:21 +08:00

fix: 修复登录页的主题切换按钮不能跟随配置 (#230)

Co-authored-by: pany <939630029@qq.com>
This commit is contained in:
mowangjuanzi 2024-12-10 10:24:27 +08:00 committed by GitHub
parent 63e3960465
commit 272642ec97
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1,6 +1,7 @@
<script lang="ts" setup>
import type { FormInstance, FormRules } from "element-plus"
import type { LoginRequestData } from "./apis/type"
import { useSettingsStore } from "@/pinia/stores/settings"
import { useUserStore } from "@/pinia/stores/user"
import ThemeSwitch from "@@/components/ThemeSwitch/index.vue"
import { Key, Loading, Lock, Picture, User } from "@element-plus/icons-vue"
@ -12,6 +13,8 @@ const router = useRouter()
const userStore = useUserStore()
const settingsStore = useSettingsStore()
const { isFocus, handleBlur, handleFocus } = useFocus()
/** 登录表单元素的引用 */
@ -82,7 +85,7 @@ createCode()
<template>
<div class="login-container">
<ThemeSwitch class="theme-switch" />
<ThemeSwitch v-if="settingsStore.showThemeSwitch" class="theme-switch" />
<Owl :close-eyes="isFocus" />
<div class="login-card">
<div class="title">