diff --git a/app/layout/upcoming-changes/component.tsx b/app/layout/upcoming-changes/component.tsx new file mode 100644 index 0000000000..2dddc432ed --- /dev/null +++ b/app/layout/upcoming-changes/component.tsx @@ -0,0 +1,44 @@ +import { useCallback } from 'react'; + +import { useCookies } from 'react-cookie'; + +import { useFeatureFlags } from 'hooks/feature-flags'; + +import Button from 'components/button'; +import Wrapper from 'layout/wrapper'; + +export const UpcomingChangesBanner = (): JSX.Element => { + const [cookies, setCookie] = useCookies(['upcoming-changes']); + const { upcomingChanges } = useFeatureFlags(); + + const onAccept = useCallback(() => { + setCookie('upcoming-changes', 'true', { path: '/' }); + }, [setCookie]); + + if (cookies['upcoming-changes'] === 'true' || !upcomingChanges) return null; + + return ( +
+ +
+

+ MaPP is undergoing a transformation with an enhanced interface and new features released + by the end of January 2024! Your existing projects + will seamlessly transition to the new version. For any concerns, feel free to reach out + to us. Stay tuned for a better planning experience! +

+ +
+
+
+ ); +}; + +export default UpcomingChangesBanner; diff --git a/app/layout/upcoming-changes/index.ts b/app/layout/upcoming-changes/index.ts new file mode 100644 index 0000000000..b404d7fd44 --- /dev/null +++ b/app/layout/upcoming-changes/index.ts @@ -0,0 +1 @@ +export { default } from './component'; diff --git a/app/pages/index.tsx b/app/pages/index.tsx index d7f09ee928..306ed0078b 100644 --- a/app/pages/index.tsx +++ b/app/pages/index.tsx @@ -14,6 +14,7 @@ import PartnersList from 'layout/home/partners'; import Support from 'layout/home/support'; import MetaIcons from 'layout/meta-icons'; import MetaTags from 'layout/meta-tags'; +import UpcomingChanges from 'layout/upcoming-changes'; export const getServerSideProps = withUser(); @@ -39,6 +40,7 @@ const Home: React.FC = () => { className="overflow-x-hidden overflow-y-auto" >
+