mirror of
https://git.rdcenter.ru/RDCenter/skb-kit.git
synced 2026-12-05 04:19:45 +00:00
исправила футер и добавила картинки на задний план
This commit is contained in:
1 parent
a86f51a8eb
commit
79fc2eeb98
6 files changed
+258
-215
No files matched your search
@@ -1,130 +1,201 @@
|
||||
|
||||
#footer {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
|
||||
height: 192px;
|
||||
padding: 0 10%;
|
||||
margin: 2em 0 0;
|
||||
background: $bg-footer;
|
||||
|
||||
// Добавление SVG-фона
|
||||
background-image: url("../../assets/images/backround/bg_footer_gray_02.svg");
|
||||
background-repeat: no-repeat;
|
||||
background-position: center bottom;
|
||||
background-size: cover; // или `contain` в зависимости от эффекта
|
||||
|
||||
.container-fluid {
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.logo-container {
|
||||
height: 70%;
|
||||
max-width: 30%;
|
||||
|
||||
.logo {
|
||||
height: 100%;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
.contacts {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
//align-items: center;
|
||||
|
||||
max-height: 70%;
|
||||
height: 40%;
|
||||
height: 309px;
|
||||
padding: 45px 10%;
|
||||
margin: 2em 0 0;
|
||||
background: $bg-footer;
|
||||
|
||||
p {
|
||||
color: $text-secondary;
|
||||
font-size: 16px;
|
||||
font-weight: 400;
|
||||
line-height: 16px;
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.links {
|
||||
display: flex;
|
||||
gap: 20px;
|
||||
|
||||
.link {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
width: 60px;
|
||||
aspect-ratio: 1;
|
||||
border-radius: 100%;
|
||||
background-color: $bg-primary;
|
||||
|
||||
.icon {
|
||||
width: 80%;
|
||||
height: 80%;
|
||||
object-fit: contain;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 100vw;
|
||||
height: auto;
|
||||
padding: 1.5em 10%;
|
||||
position: relative;
|
||||
// Добавление SVG-фона
|
||||
background-image: url("../../shared/assets/images/backround/bg_footer_gray_02.svg");
|
||||
background-repeat: no-repeat;
|
||||
background-position: center bottom;
|
||||
background-size: cover; // или `contain` в зависимости от эффекта
|
||||
|
||||
.container-fluid {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
gap: 2rem;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
.logo-container {
|
||||
height: auto;
|
||||
max-width: 60%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
align-items: flex-start;
|
||||
height: 100%;
|
||||
|
||||
.logo {
|
||||
height: auto;
|
||||
width: 100%;
|
||||
}
|
||||
.logo {
|
||||
height: auto;
|
||||
width: 256px;
|
||||
}
|
||||
}
|
||||
|
||||
.contacts {
|
||||
text-align: center;
|
||||
gap: 0.5em;
|
||||
width: 100%;
|
||||
padding: 10px 0;
|
||||
p {
|
||||
font-size: 16px;
|
||||
}
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
justify-content: space-between;
|
||||
|
||||
max-height: 70%;
|
||||
height: 100%;
|
||||
|
||||
p {
|
||||
color: $text-secondary;
|
||||
//font-size: 16px;
|
||||
font-family: Montserrat, sans-serif;
|
||||
font-weight: 400;
|
||||
line-height: 20px;
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.links {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
gap: 10px;
|
||||
display: flex;
|
||||
gap: 17px;
|
||||
|
||||
.link {
|
||||
width: 45px;
|
||||
transition: background 0.3s ease;
|
||||
.link {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
|
||||
&:hover {
|
||||
background-color: darken($bg-primary, 10%); //
|
||||
width: 42px;
|
||||
aspect-ratio: 1;
|
||||
border-radius: 100%;
|
||||
background-color: $bg-primary;
|
||||
|
||||
.icon {
|
||||
width: 80%;
|
||||
height: 80%;
|
||||
object-fit: contain;
|
||||
}
|
||||
}
|
||||
|
||||
.icon {
|
||||
width: 65%;
|
||||
height: 65%;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.footer-content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
height: 100%;
|
||||
|
||||
gap: 32px;
|
||||
justify-content: center;
|
||||
}
|
||||
.copyright {
|
||||
display: none;
|
||||
}
|
||||
.visible {
|
||||
display: block;
|
||||
}
|
||||
|
||||
@media (max-width: 768px) {
|
||||
flex-direction: column;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
width: 100vw;
|
||||
height: auto;
|
||||
padding: 1.5em 10%;
|
||||
position: relative;
|
||||
gap: 20px;
|
||||
|
||||
.visible {
|
||||
display: none !important;
|
||||
}
|
||||
.copyright {
|
||||
display: block !important; // Показываем текст внизу только в мобильной версии
|
||||
text-align: center;
|
||||
font-size: 14px;
|
||||
color: white;
|
||||
margin-top: 10px;
|
||||
}
|
||||
|
||||
.container-fluid {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
gap: 2rem;
|
||||
}
|
||||
|
||||
.logo-container {
|
||||
height: auto;
|
||||
max-height: 100%;
|
||||
max-width: 100%;
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
gap: 20px;
|
||||
.logo {
|
||||
height: auto;
|
||||
width: 100%;
|
||||
}
|
||||
}
|
||||
|
||||
.logo-container label {
|
||||
display: none !important; // Скрываем текст в мобильной версии
|
||||
}
|
||||
|
||||
.contacts {
|
||||
text-align: center;
|
||||
gap: 0.5em;
|
||||
width: 100%;
|
||||
padding: 10px 0;
|
||||
|
||||
p {
|
||||
font-size: 16px;
|
||||
}
|
||||
}
|
||||
|
||||
.links {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
gap: 10px;
|
||||
|
||||
.link {
|
||||
width: 45px;
|
||||
transition: background 0.3s ease;
|
||||
|
||||
&:hover {
|
||||
background-color: darken($bg-primary, 10%); //
|
||||
}
|
||||
|
||||
.icon {
|
||||
width: 65%;
|
||||
height: 65%;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.footer-links-container {
|
||||
display: flex;
|
||||
flex-direction: column; /* Arrange links vertically */
|
||||
justify-content: space-between; /* Spread out the items */
|
||||
height: 100%; /* Make sure the container takes up full height */
|
||||
}
|
||||
|
||||
.footer-links {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
gap: 30px; // Между столбиками будет отступ
|
||||
|
||||
.footer-column {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 20px; // Расстояние между ссылками в одном столбике
|
||||
|
||||
a {
|
||||
color: white; // Белый цвет текста
|
||||
text-decoration: none; // Убираем подчеркивание
|
||||
font-size: 16px; // Размер текста
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.privacy-policy {
|
||||
align-self: flex-end; /* Align the "Политика конфиденциальности" link to the bottom */
|
||||
margin-top: auto; /* Ensure the link is pushed to the bottom */
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
#root:has(#mainpageheader) #footer {
|
||||
background-image: url("../../assets/images/backround/bg_footer_gray.svg");
|
||||
}
|
||||
background-image: url("../../assets/images/backround/bg_footer_gray.svg");
|
||||
}
|
||||
@@ -1,4 +1,5 @@
|
||||
import { useState } from "react";
|
||||
import { useState, useEffect } from "react";
|
||||
import { Link } from "react-router-dom";
|
||||
import FooterLink from "./FooterLink";
|
||||
import FooterContacts from "./FooterContacts";
|
||||
|
||||
@@ -8,35 +9,32 @@ import iconSfedu from "@/shared/assets/images/footer/iconSfedu.png";
|
||||
import iconVK from "@/shared/assets/images/footer/iconVK.svg";
|
||||
import "./Footer.styles.scss";
|
||||
|
||||
// Тип для ссылок
|
||||
interface LinkType {
|
||||
src: string;
|
||||
to: string;
|
||||
id?: string; // Добавляем опциональное поле id
|
||||
id?: string;
|
||||
}
|
||||
|
||||
// Тип для контактов
|
||||
interface ContactsType {
|
||||
email: JSX.Element;
|
||||
address: JSX.Element;
|
||||
phone: JSX.Element;
|
||||
}
|
||||
|
||||
// Тип для пропсов компонента Footer
|
||||
interface FooterProps {
|
||||
links?: Record<string, LinkType>; // Объект с ключами-строками и значениями типа LinkType
|
||||
links?: Record<string, LinkType>;
|
||||
contacts?: ContactsType;
|
||||
}
|
||||
|
||||
const mockLinks: Record<string, LinkType> = {
|
||||
ictis: {
|
||||
src: iconIctis,
|
||||
to: "https://ictis.sfedu.ru",
|
||||
},
|
||||
sfedu: {
|
||||
src: iconSfedu,
|
||||
to: "https://sfedu.ru",
|
||||
},
|
||||
ictis: {
|
||||
src: iconIctis,
|
||||
to: "https://ictis.sfedu.ru",
|
||||
},
|
||||
vk: {
|
||||
src: iconVK,
|
||||
to: "https://vk.com/skbkit",
|
||||
@@ -45,42 +43,75 @@ const mockLinks: Record<string, LinkType> = {
|
||||
|
||||
const mockContacts: ContactsType = {
|
||||
email: (
|
||||
<a style={{ color: "inherit" }} href="mailto:skb@sfedu.ru">
|
||||
<a style={{
|
||||
fontSize: "24px",
|
||||
color: "inherit",
|
||||
fontWeight: "500",
|
||||
}} href="mailto:skb@sfedu.ru">
|
||||
skb@sfedu.ru
|
||||
</a>
|
||||
),
|
||||
phone: (
|
||||
<a style={{ color: "inherit", fontSize: "24px", }} href="tel:+79780095480">
|
||||
+7 (978) 009-54-80
|
||||
</a>
|
||||
),
|
||||
address: (
|
||||
<a
|
||||
style={{ color: "inherit" }}
|
||||
style={{ color: "inherit", fontSize: "16px" }}
|
||||
href="https://yandex.ru/maps/?text=г.%20Таганрог,%20пер.%20Тургеневский,%2044"
|
||||
target="_blank"
|
||||
rel="noopener noreferrer"
|
||||
>
|
||||
г. Таганрог, пер. Тургеневский, 44
|
||||
</a>
|
||||
),
|
||||
phone: (
|
||||
<a style={{ color: "inherit" }} href="tel:+79780095480">
|
||||
+7 (978) 009-54-80
|
||||
<div style={{ marginBottom: "5px" }}>
|
||||
<span style={{ color: "#898989" }}>Таганрог</span>
|
||||
</div>
|
||||
пер. Тургеневский, 44
|
||||
|
||||
</a>
|
||||
),
|
||||
};
|
||||
|
||||
function Footer({ links = mockLinks, contacts = mockContacts }: FooterProps) {
|
||||
const [mediaList] = useState(links);
|
||||
const [mediaList, setMediaList] = useState(links);
|
||||
|
||||
return (
|
||||
<footer id="footer">
|
||||
<div className="logo-container">
|
||||
<img className="logo" alt="logo" src={logo} />
|
||||
<div className="logo-container" style={{ alignItems: 'flex-start' }}>
|
||||
<img className="logo" alt="logo" src={logo} />
|
||||
</div>
|
||||
<label style={{ color: 'white', fontSize: '14px', alignItems: 'flex-end', lineHeight: 'none' }}>©СКБ «КИТ» 2015–2025</label>
|
||||
</div>
|
||||
<FooterContacts contacts={contacts} />
|
||||
<div className="links">
|
||||
{Object.keys(mediaList).map((linkKey) => (
|
||||
<FooterLink link={mediaList[linkKey]} key={linkKey} />
|
||||
))}
|
||||
<div className="footer-links-container">
|
||||
<div className="footer-links">
|
||||
<div className="footer-column">
|
||||
<Link to="/news">НОВОСТИ</Link>
|
||||
<Link to="/projects">ПРОЕКТЫ</Link>
|
||||
<Link to="/labs">ЛАБОРАТОРИИ</Link>
|
||||
<Link to="/aboutus">О НАС</Link>
|
||||
</div>
|
||||
<div className="footer-column">
|
||||
<Link to="/contact" >НАША КОМАНДА</Link>
|
||||
<Link to="/contact">КОНТАКТЫ</Link>
|
||||
<Link to="https://ictis.sfedu.ru">ИКТИБ</Link>
|
||||
</div>
|
||||
</div>
|
||||
<Link className="visible" style={{ color: 'white', fontSize: '14px', alignItems: 'flex-end', lineHeight: 'none' }} to="https://www.study.sfedu.ru/privacypolicy?ysclid=m8anp507sz44008873">Политика конфиденциальности</Link>
|
||||
</div>
|
||||
</footer>
|
||||
|
||||
<div className="footer-content">
|
||||
<FooterContacts contacts={contacts} />
|
||||
<div className="links">
|
||||
{Object.keys(mediaList).map(link => <FooterLink link={mediaList[link]} key={mediaList[link].id} />)}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<Link className="copyright" style={{ color: 'white', fontSize: '14px', lineHeight: 'none' }} to="https://www.study.sfedu.ru/privacypolicy?ysclid=m8anp507sz44008873">Политика конфиденциальности</Link>
|
||||
<div className="copyright">
|
||||
©СКБ «КИТ» 2015–2025
|
||||
</div>
|
||||
</footer >
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -11,8 +11,8 @@ function FooterContacts({ contacts }: FooterContactsProps) {
|
||||
return (
|
||||
<div className="contacts">
|
||||
<p>{contacts.email}</p>
|
||||
<p>{contacts.address}</p>
|
||||
<p>{contacts.phone}</p>
|
||||
<p>{contacts.address}</p>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user