From 52abba5f4fd7ff09eca11623293367e78d0c4fe8 Mon Sep 17 00:00:00 2001 From: David Colon <38386583+Da-Colon@users.noreply.github.com> Date: Thu, 15 Feb 2024 22:34:00 -0500 Subject: [PATCH] remove ClientOnly --- app/create/page.tsx | 13 +- app/daos/[daoAddress]/hierarchy/page.tsx | 5 +- app/daos/[daoAddress]/layout.tsx | 7 +- app/daos/[daoAddress]/new/page.tsx | 15 +- app/daos/[daoAddress]/page.tsx | 6 +- .../proposal-templates/new/page.tsx | 223 +++++++------- .../[daoAddress]/proposal-templates/page.tsx | 5 +- .../proposals/[proposalId]/page.tsx | 5 +- app/daos/[daoAddress]/proposals/new/page.tsx | 203 +++++++------ app/daos/[daoAddress]/proposals/page.tsx | 5 +- app/daos/[daoAddress]/settings/page.tsx | 7 +- app/daos/[daoAddress]/treasury/page.tsx | 7 +- app/page.tsx | 283 +++++++++--------- src/components/ui/utils/ClientOnly.tsx | 19 -- 14 files changed, 381 insertions(+), 422 deletions(-) delete mode 100644 src/components/ui/utils/ClientOnly.tsx diff --git a/app/create/page.tsx b/app/create/page.tsx index 2fe1bd9925..37dd6c358a 100644 --- a/app/create/page.tsx +++ b/app/create/page.tsx @@ -7,7 +7,6 @@ import { useTranslation } from 'react-i18next'; import { toast } from 'react-toastify'; import DaoCreator from '../../src/components/DaoCreator'; import { DAOCreateMode } from '../../src/components/DaoCreator/formComponents/EstablishEssentials'; -import ClientOnly from '../../src/components/ui/utils/ClientOnly'; import { BASE_ROUTES, DAO_ROUTES } from '../../src/constants/routes'; import { useAccountFavorites } from '../../src/hooks/DAO/loaders/useFavorites'; import useDeployDAO from '../../src/hooks/DAO/useDeployDAO'; @@ -55,12 +54,10 @@ export default function DaoCreatePage() { }; return ( - - - + ); } diff --git a/app/daos/[daoAddress]/hierarchy/page.tsx b/app/daos/[daoAddress]/hierarchy/page.tsx index c148044bcb..6e66e5d7af 100644 --- a/app/daos/[daoAddress]/hierarchy/page.tsx +++ b/app/daos/[daoAddress]/hierarchy/page.tsx @@ -5,7 +5,6 @@ import { useTranslation } from 'react-i18next'; import { DaoNode } from '../../../../src/components/pages/DaoHierarchy/DaoNode'; import { BarLoader } from '../../../../src/components/ui/loaders/BarLoader'; import PageHeader from '../../../../src/components/ui/page/Header/PageHeader'; -import ClientOnly from '../../../../src/components/ui/utils/ClientOnly'; import { HEADER_HEIGHT } from '../../../../src/constants/common'; import { useFractal } from '../../../../src/providers/App/AppProvider'; @@ -24,7 +23,7 @@ export default function HierarchyPage() { } return ( - + <> - + ); } diff --git a/app/daos/[daoAddress]/layout.tsx b/app/daos/[daoAddress]/layout.tsx index 4f0f1a59f8..cf9577d046 100644 --- a/app/daos/[daoAddress]/layout.tsx +++ b/app/daos/[daoAddress]/layout.tsx @@ -1,12 +1,11 @@ 'use client'; -import { Button, Center, Text, VStack, ChakraProvider, extendTheme } from '@chakra-ui/react'; +import { Button, Center, Text, VStack, ChakraProvider, extendTheme, Box } from '@chakra-ui/react'; import { theme } from '@decent-org/fractal-ui'; import Script from 'next/script'; import { ReactNode, useMemo } from 'react'; import { useTranslation } from 'react-i18next'; import { useChainId, useClient } from 'wagmi'; -import ClientOnly from '../../../src/components/ui/utils/ClientOnly'; import { APP_NAME } from '../../../src/constants/common'; import useDAOController from '../../../src/hooks/DAO/useDAOController'; import useDAOMetadata from '../../../src/hooks/DAO/useDAOMetadata'; @@ -125,7 +124,7 @@ export default function DaoPageLayout({ } return ( - + {node?.daoName ? `${node.daoName} | ${APP_NAME}` : APP_NAME} {node && node.daoAddress === '0x167bE4073f52aD2Aa0D6d6FeddF0F1f79a82B98e' && (