fix(frontend)
This commit is contained in:
@@ -1,12 +1,12 @@
|
|||||||
import { useNavigate } from "react-router-dom";
|
import { useNavigate } from "react-router-dom";
|
||||||
import siteLogo from "../assets/Исходники/logo.png";
|
import siteLogo from "../assets/Исходники/logo.png";
|
||||||
|
|
||||||
export default function Header() {
|
export default function Footer() {
|
||||||
const navigate = useNavigate();
|
const navigate = useNavigate();
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<footer className="bg-light-blue w-full h-27.5 px-16 flex items-center justify-between ">
|
<footer className="bg-light-blue w-full h-27.5 px-16 flex items-center justify-between ">
|
||||||
<div className="flex flex-col items-center gap-2 text-lg tracking-widest text-gold">
|
<div className="flex flex-col items-center text-lg tracking-widest text-gold">
|
||||||
<img src={siteLogo} alt="Лого" className="w-12 h-12 object-contain" />
|
<img src={siteLogo} alt="Лого" className="w-12 h-12 object-contain" />
|
||||||
<span>FISH FISH</span>
|
<span>FISH FISH</span>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -0,0 +1,12 @@
|
|||||||
|
import Footer from "./Footer";
|
||||||
|
import Header from "./Header";
|
||||||
|
|
||||||
|
export default function PageLayout({ children }) {
|
||||||
|
return (
|
||||||
|
<body className="min-h-screen flex flex-col w-full">
|
||||||
|
<Header />
|
||||||
|
{children}
|
||||||
|
<Footer />
|
||||||
|
</body>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|||||||
@@ -27,4 +27,12 @@
|
|||||||
background-color: #051b26;
|
background-color: #051b26;
|
||||||
font-family: var(--font-sans);
|
font-family: var(--font-sans);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#root {
|
||||||
|
width: 100%;
|
||||||
|
min-height: 100dvh;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
background-color: #051b26;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
import { useEffect, useState } from "react";
|
import { useEffect, useState } from "react";
|
||||||
import * as api from "../api"; // Импортируем все функции из api/index.js
|
import * as api from "../api"; // Импортируем все функции из api/index.js
|
||||||
import Header from "../components/Header";
|
import PageLayout from "../components/PageLayout";
|
||||||
import Footer from "../components/Footer";
|
|
||||||
|
|
||||||
export default function Dashboard() {
|
export default function Dashboard() {
|
||||||
const [items, setItems] = useState([]);
|
const [items, setItems] = useState([]);
|
||||||
@@ -18,9 +17,8 @@ export default function Dashboard() {
|
|||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div>
|
<PageLayout>
|
||||||
<Header />
|
<main className="p-16 grow w-full gap-4">
|
||||||
<div className="p-4 flex flex-col w-full gap-4">
|
|
||||||
{Array.isArray(items) &&
|
{Array.isArray(items) &&
|
||||||
items.map((item) => (
|
items.map((item) => (
|
||||||
<div
|
<div
|
||||||
@@ -45,8 +43,7 @@ export default function Dashboard() {
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</main>
|
||||||
<Footer />
|
</PageLayout>
|
||||||
</div>
|
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user