Skip to content
Snippets Groups Projects
Verified Commit 41fb2d2b authored by Defendi Alberto's avatar Defendi Alberto
Browse files

New role.

parent c0e43b77
No related branches found
No related tags found
2 merge requests!56Refined auth flow and new website pages.,!43Move back cookie fetch to SignInForm. Role fetched and saved into a Context. Small refactorings.
export enum Roles {
visitor = 'visitor',
senior = 'senior',
admin = 'admin',
operator = 'operator',
......
import { Roles } from 'api/userRoles';
import { createContext } from 'react';
export type AuthData = {
......@@ -6,7 +7,7 @@ export type AuthData = {
};
export const AuthContext = createContext<AuthData>({
role: '',
role: Roles.visitor,
setRole: () => {
// Do nothing
},
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment