From 83b3bcdd3d6bbf7f0e016ba733dd29bca7508060 Mon Sep 17 00:00:00 2001 From: G Date: Tue, 7 May 2024 12:08:33 +0000 Subject: [PATCH] authenticationData state --- src/contexts/UserAuthenticationContext.tsx | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/contexts/UserAuthenticationContext.tsx b/src/contexts/UserAuthenticationContext.tsx index 8387feb..0add797 100644 --- a/src/contexts/UserAuthenticationContext.tsx +++ b/src/contexts/UserAuthenticationContext.tsx @@ -1,21 +1,27 @@ import { createContext, useContext, useState } from "react"; - +import type { IauthenticationData } from "./Types"; export interface UserAuthenticationContextProps { isAuthenticated: boolean; setIsAuthenticated: React.Dispatch>; + setAuthenticationData: React.Dispatch>; } export const UserAuthenticationContext = createContext({ isAuthenticated: false, setIsAuthenticated: () => {}, + setAuthenticationData: () => {}, }); export const UserAuthenticationContextProvider = ({ children }: { children: React.ReactNode }) => { const [isAuthenticated, setIsAuthenticated] = useState(false); + const [authenticationData, setAuthenticationData] = useState({ + access: "", + refresh: "", + }); return ( {children} -- libgit2 0.27.1