added rules on ReFound
This commit is contained in:
@@ -13,6 +13,7 @@ export default function Sidebar({
|
||||
isAuthenticated,
|
||||
onLogout,
|
||||
onLoginClick,
|
||||
onRulesClick,
|
||||
}) {
|
||||
return (
|
||||
<>
|
||||
@@ -48,11 +49,20 @@ export default function Sidebar({
|
||||
<div className="f-sb-bottom">
|
||||
{NAV_BOTTOM.map(({ icon, label }) => {
|
||||
const Ic = NavIcons[icon];
|
||||
const handleBottomClick = () => {
|
||||
if (label === "Правила площадки") {
|
||||
onRulesClick?.();
|
||||
onClose();
|
||||
return;
|
||||
}
|
||||
onNavClick(label);
|
||||
onClose();
|
||||
};
|
||||
return (
|
||||
<div
|
||||
key={label}
|
||||
className={`f-sb-item${activeNav === label ? " active" : ""}`}
|
||||
onClick={() => { onNavClick(label); onClose(); }}
|
||||
onClick={handleBottomClick}
|
||||
>
|
||||
<Ic /> {label}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user