diff --git a/setup.template.js b/setup.template.js index 592cb5b..fef31f7 100644 --- a/setup.template.js +++ b/setup.template.js @@ -4,4 +4,5 @@ window.config = { ENVIRONMENT: '', BASE_API_URL: '', CSP_HEADER: '', + DISABLE_UNIVERSAL_AUTH: '' }; diff --git a/src/Pages/Dashboard/partials/DashboardHeader.module.scss b/src/Pages/Dashboard/partials/DashboardHeader.module.scss index d34bb49..ec5700e 100644 --- a/src/Pages/Dashboard/partials/DashboardHeader.module.scss +++ b/src/Pages/Dashboard/partials/DashboardHeader.module.scss @@ -68,6 +68,10 @@ gap: 12px; } +.icon { + transform: rotateX(180deg); +} + :export { filterSelectedIndicated: var(--navi-color-blue-base); } diff --git a/src/Pages/Dashboard/partials/DashboardHeader.tsx b/src/Pages/Dashboard/partials/DashboardHeader.tsx index 710129d..d3bb640 100644 --- a/src/Pages/Dashboard/partials/DashboardHeader.tsx +++ b/src/Pages/Dashboard/partials/DashboardHeader.tsx @@ -30,7 +30,7 @@ const DashboardHeader: FC = ({ fetchSessionData }) => { className={styles['severity-detail']} onClick={() => setDrawerState(true)} > - + More Info About Severity diff --git a/src/Pages/Team/Team.module.scss b/src/Pages/Team/Team.module.scss index fe8c96c..913d1d5 100644 --- a/src/Pages/Team/Team.module.scss +++ b/src/Pages/Team/Team.module.scss @@ -62,3 +62,8 @@ align-items: center; margin-top: 12px; } + +.vertical-line { + transform: rotateX(180deg); + border: 1px solid #e8e8e8; +} diff --git a/src/Pages/Team/partials/TeamForm.tsx b/src/Pages/Team/partials/TeamForm.tsx index 1137b73..3b0aaae 100644 --- a/src/Pages/Team/partials/TeamForm.tsx +++ b/src/Pages/Team/partials/TeamForm.tsx @@ -89,11 +89,12 @@ const TeamForm = (props: TeamFormProps) => { variant="p3" className={styles['team-deatils-wrapper']} > - -- + - )} +
{ fullWidth />
+
+ +
-
- -
); }; diff --git a/src/components/LeftNav/index.tsx b/src/components/LeftNav/index.tsx index a369197..7df5a0a 100644 --- a/src/components/LeftNav/index.tsx +++ b/src/components/LeftNav/index.tsx @@ -7,6 +7,7 @@ import DashboardIcon from '@navi/web-ui/lib/icons/DashboardIcon/DashboardIcon'; import ThreeDotVerticalIcon from '@navi/web-ui/lib/icons/ThreeDotVerticalIcon'; import { NavItemType } from '@navi/web-ui/lib/components/Navbar/types'; import { Typography } from '@navi/web-ui/lib/primitives'; +import { toast } from '@navi/web-ui/lib/primitives/Toast'; import NavLogoPlaceholder from '@src/assets/NavLogoPlaceholder'; @@ -60,7 +61,7 @@ const LeftNav: React.FC = ({ children }) => { }, ]; - const returnUserData = (): string => { + const returnUserData = () => { if (userDetails?.length) { try { const parsedUserData = JSON.parse(userDetails); @@ -68,8 +69,19 @@ const LeftNav: React.FC = ({ children }) => { } catch (error) { console.log(error); } + } else if (window.config.ENVIRONMENT === 'production') { + if (window.config.DISABLE_UNIVERSAL_AUTH === 'true') { + toast.error( + `You don't have permission to access, Please try with another account.`, + ); + localStorage.removeItem('react-token'); + setTimeout(() => { + window.location.reload(); + }, 2000); + } else { + return 'User'; + } } - return 'User'; }; const footerDetails = { diff --git a/src/types/index.d.ts b/src/types/index.d.ts index 5eae81d..308fe1b 100644 --- a/src/types/index.d.ts +++ b/src/types/index.d.ts @@ -5,6 +5,7 @@ interface AppConfig { AUTH_CLIENT_ID: string; ENVIRONMENT: string; BASE_API_URL: string; + DISABLE_UNIVERSAL_AUTH: string; } declare global {