mirror of
https://github.com/Sagit-chu/flvx.git
synced 2026-10-04 01:06:36 +08:00
fix: migrate frontend to Vite 7 and resolve lint warnings
This commit is contained in:
@@ -260,9 +260,8 @@ export default function AdminLayout({
|
||||
} else {
|
||||
toast.error(response.msg || "密码修改失败");
|
||||
}
|
||||
} catch (error) {
|
||||
} catch {
|
||||
toast.error("修改密码时发生错误");
|
||||
console.error("修改密码错误:", error);
|
||||
} finally {
|
||||
setPasswordLoading(false);
|
||||
}
|
||||
@@ -289,8 +288,10 @@ export default function AdminLayout({
|
||||
>
|
||||
{/* 移动端遮罩层 */}
|
||||
{isMobile && mobileMenuVisible && (
|
||||
<div
|
||||
<button
|
||||
aria-label="关闭菜单"
|
||||
className="fixed inset-0 backdrop-blur-sm bg-white/50 dark:bg-black/30 z-40"
|
||||
type="button"
|
||||
onClick={hideMobileMenu}
|
||||
/>
|
||||
)}
|
||||
|
||||
@@ -17,7 +17,7 @@ export default function H5SimpleLayout({
|
||||
React.useEffect(() => {
|
||||
try {
|
||||
window.scrollTo({ top: 0, left: 0, behavior: "auto" });
|
||||
} catch (e) {
|
||||
} catch {
|
||||
window.scrollTo(0, 0);
|
||||
}
|
||||
document.body.scrollTop = 0;
|
||||
|
||||
@@ -108,7 +108,7 @@ export default function H5Layout({ children }: { children: React.ReactNode }) {
|
||||
useEffect(() => {
|
||||
try {
|
||||
window.scrollTo({ top: 0, left: 0, behavior: "auto" });
|
||||
} catch (e) {
|
||||
} catch {
|
||||
window.scrollTo(0, 0);
|
||||
}
|
||||
document.body.scrollTop = 0;
|
||||
|
||||
Reference in New Issue
Block a user