From 8af4fd8e3ea47284c8ad6e93648edf01d527ec3d Mon Sep 17 00:00:00 2001 From: Vishnu Sreekumaran Nair <200557136@student.georgianc.on.ca> Date: Thu, 10 Apr 2025 17:41:54 -0400 Subject: [PATCH] change component name for clarity --- src/Components/Tab/index.jsx | 6 +++--- src/Pages/Account/index.jsx | 6 +++--- src/Pages/StatusPage/Create/Components/Tabs/index.jsx | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/Components/Tab/index.jsx b/src/Components/Tab/index.jsx index 40f075a5b..c2267de3d 100644 --- a/src/Components/Tab/index.jsx +++ b/src/Components/Tab/index.jsx @@ -2,7 +2,7 @@ import { Box, useTheme } from "@mui/material"; import { TabList } from "@mui/lab"; import PropTypes from "prop-types"; -const TabListWrapper = ({ value, onChange, children, ...props }) => { +const CustomTabList = ({ value, onChange, children, ...props }) => { const theme = useTheme(); return ( @@ -19,10 +19,10 @@ const TabListWrapper = ({ value, onChange, children, ...props }) => { ); }; -TabListWrapper.propTypes = { +CustomTabList.propTypes = { value: PropTypes.string, onChange: PropTypes.func, children: PropTypes.node, }; -export default TabListWrapper; +export default CustomTabList; diff --git a/src/Pages/Account/index.jsx b/src/Pages/Account/index.jsx index 429b8dd4d..d39d8c4cb 100644 --- a/src/Pages/Account/index.jsx +++ b/src/Pages/Account/index.jsx @@ -3,7 +3,7 @@ import PropTypes from "prop-types"; import { useNavigate } from "react-router"; import { useSelector } from "react-redux"; import { Box, Tab, useTheme } from "@mui/material"; -import TabListWrapper from "../../Components/Tab"; +import CustomTabList from "../../Components/Tab"; import TabContext from "@mui/lab/TabContext"; import TabList from "@mui/lab/TabList"; import ProfilePanel from "../../Components/TabPanels/Account/ProfilePanel"; @@ -60,7 +60,7 @@ const Account = ({ open = "profile" }) => { py={theme.spacing(12)} > - + {tabList.map((label, index) => ( { tabIndex={index} /> ))} - + {user.role.includes("superadmin") && } {!hideTeams && } diff --git a/src/Pages/StatusPage/Create/Components/Tabs/index.jsx b/src/Pages/StatusPage/Create/Components/Tabs/index.jsx index 32305f1af..7e54850eb 100644 --- a/src/Pages/StatusPage/Create/Components/Tabs/index.jsx +++ b/src/Pages/StatusPage/Create/Components/Tabs/index.jsx @@ -6,7 +6,7 @@ import Content from "./Content"; // Utils import PropTypes from "prop-types"; -import TabListWrapper from "../../../../../Components/Tab"; +import CustomTabList from "../../../../../Components/Tab"; const Tabs = ({ isCreate, @@ -27,7 +27,7 @@ const Tabs = ({ const theme = useTheme(); return ( - { setTab(TAB_LIST.indexOf(selected)); }} @@ -40,7 +40,7 @@ const Tabs = ({ value={tabLabel} /> ))} - + {tab === 0 ? (