19 lines
614 B
TypeScript
19 lines
614 B
TypeScript
'use client';
|
||
|
||
/**
|
||
* auth-context.tsx — 向下兼容层
|
||
*
|
||
* Auth 状态已迁移至 Zustand store(src/store/zustand/auth.store.ts)。
|
||
* 此文件保留 AuthProvider 和 useAuth 导出,确保现有页面无需修改。
|
||
*
|
||
* 新代码应直接从 @/store/zustand/auth.store 引入 useAuth / useAuthStore。
|
||
*/
|
||
|
||
import React from 'react';
|
||
export { useAuth, useAuthStore } from '@/store/zustand/auth.store';
|
||
|
||
/** @deprecated 无需 Provider,Zustand 自管理状态。保留仅为向下兼容。 */
|
||
export function AuthProvider({ children }: { children: React.ReactNode }) {
|
||
return <>{children}</>;
|
||
}
|