import React, { useState, ChangeEvent } from "react"; import { Tab, Tabs as MuiTabs, TabsProps as MuiTabsProps } from "@mui/material"; import './tab.scss'; export interface TabsProps extends MuiTabsProps { } export const Tabs = ({ variant, textColor, indicatorColor, scrollButtons, ...rest }: MuiTabsProps) => { const [value, setValue] = useState(0); const handleChange = (event: ChangeEvent<{}>, newValue: number) => { setValue(newValue) }; return (
{value === 0 &&
This is the content of Tab 1.
} {value === 1 &&
This is the content of Tab 2.
} {value === 2 &&
This is the content of Tab 3.
}
); };