From 67c376afead5ba4d2b4c3908411dcedf016e833f Mon Sep 17 00:00:00 2001 From: Leonid Chelakhov Date: Tue, 17 Dec 2024 11:47:49 +0300 Subject: [PATCH] deleted unnecessary functions --- FrontEnd/src/pages/ProfileList/ProfileListPage.jsx | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/FrontEnd/src/pages/ProfileList/ProfileListPage.jsx b/FrontEnd/src/pages/ProfileList/ProfileListPage.jsx index 4be87222..032a247f 100644 --- a/FrontEnd/src/pages/ProfileList/ProfileListPage.jsx +++ b/FrontEnd/src/pages/ProfileList/ProfileListPage.jsx @@ -165,14 +165,6 @@ export default function ProfileListPage({ isAuthorized, isSaved }) { updateQueryParams(page); }; - const handleActiveTab = (activeTab) => { - setActiveTab(activeTab); - }; - - const handleActiveBtn = (activeBtn) => { - setActiveBtn(activeBtn); - }; - return (
{error && error.response.status !==401 ? ( @@ -193,7 +185,7 @@ export default function ProfileListPage({ isAuthorized, isSaved }) { className={activeTab === item.key ? css['company-list__tabs--element--active'] : css['company-list__tabs--element']} - onClick={() => (handleFilters(item.value, activity), handleActiveTab(item.key))} + onClick={() => (handleFilters(item.value, activity))} > {item.title === 'Усі підприємства' ? linkText : item.title} @@ -213,7 +205,7 @@ export default function ProfileListPage({ isAuthorized, isSaved }) { className={activeBtn === item.key ? css['company-list__btns--element--active'] : css['company-list__btns--element']} - onClick={() => (handleFilters(companyType, item.value), handleActiveBtn(item.key))} + onClick={() => (handleFilters(companyType, item.value))} > {item.title}