From 3a8cb66157b6cf21233441a89323355fb6541c48 Mon Sep 17 00:00:00 2001 From: Samuel Rowe Date: Fri, 12 Aug 2022 10:47:35 +0530 Subject: [PATCH] feat: updated `Tabs` component --- services/frontend/src/components/Tabs.tsx | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/services/frontend/src/components/Tabs.tsx b/services/frontend/src/components/Tabs.tsx index 0b59706..e464a00 100644 --- a/services/frontend/src/components/Tabs.tsx +++ b/services/frontend/src/components/Tabs.tsx @@ -1,7 +1,10 @@ import { styled } from "@mui/joy"; import { FunctionComponent, ReactElement, ReactNode } from "react"; +import { TabContext } from "../contexts"; export interface ITabsProps { + value: string; + onChange: (newValue: string) => void; children: ReactNode; } @@ -30,11 +33,15 @@ const Nav = styled("nav")` const Tabs: FunctionComponent = ( props: ITabsProps ): ReactElement => { - const { children } = props; + const { children, value, onChange } = props; return ( - + ); };