diff --git a/src/layouts/DefaultLayout/index.js b/src/layouts/DefaultLayout/index.js index e0686a7..ac5d1bd 100644 --- a/src/layouts/DefaultLayout/index.js +++ b/src/layouts/DefaultLayout/index.js @@ -1,4 +1,4 @@ -import React, { useEffect, useState } from 'react'; +import React, { useEffect } from 'react'; import { __ } from '@wordpress/i18n'; import { useLocation } from 'react-router-dom'; @@ -8,7 +8,6 @@ import { useStoreValue, storeSet } from '../../store'; // components import AppSidebar from './components/AppSidebar'; import AppTopbar from './components/AppTopbar'; -import { Dialog } from 'primereact/dialog'; import { pathOr } from 'ramda'; const DefaultLayout = ({ children }) => { @@ -16,18 +15,11 @@ const DefaultLayout = ({ children }) => { const location = useLocation(); const userData = useStoreValue('userData'); const role = pathOr('', ['role', 'roleType'], userData); - const [visible, setVisible] = useState(false); useEffect(() => { storeSet('isError404', false); }, [location]); - useEffect(() => { - if (['ROLE_BENEFICIARY', 'ROLE_CONFIDI'].includes(role)) { - setVisible(true); - } - }, [role]); - return (
@@ -37,15 +29,6 @@ const DefaultLayout = ({ children }) => { {isError404 ?

Error 404

: children} - - {if (!visible) return; setVisible(false); }}> -

- Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. - Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo - consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. - Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. -

-