From f783891bb8a2813bc7336669e068ee90bd810257 Mon Sep 17 00:00:00 2001 From: RadoslavDimchev Date: Tue, 8 Aug 2023 10:56:02 +0300 Subject: [PATCH] refactor: convert PageWrapper to tsx --- .../{PageWrapper.jsx => PageWrapper.tsx} | 19 ++++++++++++------- 1 file changed, 12 insertions(+), 7 deletions(-) rename src/components/{PageWrapper.jsx => PageWrapper.tsx} (67%) diff --git a/src/components/PageWrapper.jsx b/src/components/PageWrapper.tsx similarity index 67% rename from src/components/PageWrapper.jsx rename to src/components/PageWrapper.tsx index daf7b7ff..6b409a07 100644 --- a/src/components/PageWrapper.jsx +++ b/src/components/PageWrapper.tsx @@ -1,22 +1,27 @@ -import { XStack, YStack, styled } from 'tamagui' -import { TopBar } from './TopBar' +import { Stack, XStack, YStack, styled } from 'tamagui' +import TopBar from './TopBar' +import { ReactNode } from 'react' -const Background = styled('div', { +const Background = styled(Stack, { display: 'flex', justifyContent: 'center', backgroundColor: 'white', width: '100vw', }) -const PageWrapper = ({ children }) => { +type PageWrapperProps = { + children: ReactNode +} + +const PageWrapper = ({ children }: PageWrapperProps) => { return (