chore: add auth store placeholder for future use
This commit is contained in:
@@ -4,6 +4,7 @@ import type { UserRole } from "@/lib/types"
|
|||||||
interface AuthState {
|
interface AuthState {
|
||||||
isAuthenticated: boolean
|
isAuthenticated: boolean
|
||||||
currentRole: UserRole
|
currentRole: UserRole
|
||||||
|
verifiedRoles: UserRole[]
|
||||||
switchRole: (role: UserRole) => void
|
switchRole: (role: UserRole) => void
|
||||||
login: () => void
|
login: () => void
|
||||||
logout: () => void
|
logout: () => void
|
||||||
@@ -12,6 +13,7 @@ interface AuthState {
|
|||||||
export const useAuthStore = create<AuthState>((set) => ({
|
export const useAuthStore = create<AuthState>((set) => ({
|
||||||
isAuthenticated: false,
|
isAuthenticated: false,
|
||||||
currentRole: "consumer",
|
currentRole: "consumer",
|
||||||
|
verifiedRoles: ["consumer"],
|
||||||
switchRole: (role) => set({ currentRole: role }),
|
switchRole: (role) => set({ currentRole: role }),
|
||||||
login: () => set({ isAuthenticated: true }),
|
login: () => set({ isAuthenticated: true }),
|
||||||
logout: () => set({ isAuthenticated: false, currentRole: "consumer" }),
|
logout: () => set({ isAuthenticated: false, currentRole: "consumer" }),
|
||||||
|
|||||||
Reference in New Issue
Block a user