added frame on posts
This commit is contained in:
@@ -2,6 +2,7 @@ import LogoIcon from "./icons/LogoIcon";
|
||||
import {NAV_BOTTOM, NAV_ITEMS} from "../config/feedConstants";
|
||||
import {NavIcons} from "./icons/NavIcons";
|
||||
import { useNavigate } from "react-router-dom";
|
||||
import { useTheme } from "../context/ThemeContext";
|
||||
|
||||
export default function Sidebar({
|
||||
open,
|
||||
@@ -14,6 +15,7 @@ export default function Sidebar({
|
||||
onReviewsClick,
|
||||
}) {
|
||||
const navigate = useNavigate();
|
||||
const { theme, toggle: toggleTheme } = useTheme();
|
||||
return (
|
||||
<>
|
||||
<div className={`f-overlay${open ? " show" : ""}`} onClick={onClose} />
|
||||
@@ -78,6 +80,20 @@ export default function Sidebar({
|
||||
</div>
|
||||
);
|
||||
})}
|
||||
<div className="f-sb-divider" />
|
||||
<div className="f-sb-item f-sb-theme-toggle" onClick={toggleTheme}>
|
||||
{theme === "dark" ? (
|
||||
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round">
|
||||
<circle cx="12" cy="12" r="5"/>
|
||||
<path d="M12 1v2M12 21v2M4.22 4.22l1.42 1.42M18.36 18.36l1.42 1.42M1 12h2M21 12h2M4.22 19.78l1.42-1.42M18.36 5.64l1.42-1.42"/>
|
||||
</svg>
|
||||
) : (
|
||||
<svg width="18" height="18" viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth="2" strokeLinecap="round" strokeLinejoin="round">
|
||||
<path d="M21 12.79A9 9 0 1 1 11.21 3 7 7 0 0 0 21 12.79z"/>
|
||||
</svg>
|
||||
)}
|
||||
{theme === "dark" ? "Светлая тема" : "Тёмная тема"}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
export default function MenuIcon () {
|
||||
return (
|
||||
<svg width={20} height={20} viewBox="0 0 24 24" fill="none" stroke="rgba(255,255,255,0.8)" strokeWidth={2.2} strokeLinecap="round">
|
||||
<svg width={20} height={20} viewBox="0 0 24 24" fill="none" stroke="currentColor" strokeWidth={2.2} strokeLinecap="round" opacity="0.8">
|
||||
<line x1="3" y1="6" x2="21" y2="6" />
|
||||
<line x1="3" y1="12" x2="21" y2="12" />
|
||||
<line x1="3" y1="18" x2="21" y2="18" />
|
||||
|
||||
Reference in New Issue
Block a user