Compare commits

...

3 Commits

4 changed files with 54 additions and 8 deletions

View File

@ -6,7 +6,6 @@ import empty from "assets/images/emptyPage.svg";
import "./emptyBlock.scss"; import "./emptyBlock.scss";
export const EmptyBlock = () => { export const EmptyBlock = () => {
return ( return (
<> <>
<div className="empty-block"> <div className="empty-block">
@ -21,4 +20,3 @@ export const EmptyBlock = () => {
</> </>
); );
}; };

View File

@ -46,6 +46,7 @@ export const PartnerCategories = () => {
const theme = useTheme(getTheme()); const theme = useTheme(getTheme());
const [nodes, setNodes] = useState([]); const [nodes, setNodes] = useState([]);
const [initialNodes, setInitialNodes] = useState([]); const [initialNodes, setInitialNodes] = useState([]);
const [activeTab, setActiveTab] = useState("Все");
const [search, setSearch] = useState(""); const [search, setSearch] = useState("");
@ -308,10 +309,38 @@ export const PartnerCategories = () => {
/> />
</label> </label>
<div className="table__tabs"> <div className="table__tabs">
<div className="table__tab">Все</div> <div
onClick={() => {
setActiveTab("Все");
setNodes(initialNodes);
}}
className={
activeTab === "Все"
? "table__tab table__tab--active"
: "table__tab"
}
>
Все
</div>
{tabs.map((tab) => { {tabs.map((tab) => {
return ( return (
<div className="table__tab" key={tab.value}> <div
onClick={() => {
setActiveTab(tab.name);
setNodes(
initialNodes.filter(
(item) =>
item.resume.userCard.position_id === tab.value
)
);
}}
className={
activeTab === tab.name
? "table__tab table__tab--active"
: "table__tab"
}
key={tab.value}
>
{tab.name} {tab.name}
</div> </div>
); );

View File

@ -189,6 +189,25 @@
border-radius: 5px; border-radius: 5px;
} }
&__tab {
padding: 8px 12px;
cursor: pointer;
color: rgba(46, 58, 89, 1);
font-size: 15px;
&--active {
background: rgba(255, 255, 255, 1);
font-size: 16px;
border-radius: 5px;
border: 0;
}
&:nth-child(2) {
border-right: 1px solid rgba(224, 226, 229, 1);
border-left: 1px solid rgba(224, 226, 229, 1);
}
}
&__avatar { &__avatar {
width: 40px; width: 40px;
height: 40px; height: 40px;

View File

@ -1,10 +1,10 @@
import React from "react"; import React from "react";
import { Footer } from "@components/Common/Footer/Footer"; import { Footer } from "@components/Common/Footer/Footer";
import { Navigation } from "@components/Navigation/Navigation";
import { ProfileHeader } from "@components/ProfileHeader/ProfileHeader";
import { ProfileBreadcrumbs } from "@components/ProfileBreadcrumbs/ProfileBreadcrumbs";
import { EmptyBlock } from "@components/EmptyBlock/EmptyBlock"; import { EmptyBlock } from "@components/EmptyBlock/EmptyBlock";
import { Navigation } from "@components/Navigation/Navigation";
import { ProfileBreadcrumbs } from "@components/ProfileBreadcrumbs/ProfileBreadcrumbs";
import { ProfileHeader } from "@components/ProfileHeader/ProfileHeader";
import "./payouts.scss"; import "./payouts.scss";
@ -17,7 +17,7 @@ export const Payouts = () => {
<ProfileBreadcrumbs <ProfileBreadcrumbs
links={[ links={[
{ name: "Главная", link: "/profile" }, { name: "Главная", link: "/profile" },
{ name: "Выплаты и финансы ", link: "/profile/payouts" }, { name: "Выплаты и финансы ", link: "/profile/payouts" }
]} ]}
/> />
<h3 className="payouts__title">Выплаты и финансы </h3> <h3 className="payouts__title">Выплаты и финансы </h3>