Dev #1
28
.idea/workspace.xml
generated
28
.idea/workspace.xml
generated
@@ -5,18 +5,20 @@
|
||||
</component>
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="2a96f817-9dc2-4f3c-893a-c4974c750774" name="Changes" comment="">
|
||||
<change afterPath="$PROJECT_DIR$/src/app/privacy-policy/page.tsx" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/shared/lib/phoneBeautify/phoneBeautify.ts" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/views/privacy-policy/index.ts" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/views/privacy-policy/styles.module.scss" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/views/privacy-policy/ui.tsx" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/app/cookie/page.tsx" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/views/cookie/index.ts" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/views/cookie/styles.module.scss" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/views/cookie/ui.tsx" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/widgets/cookie-notice/index.ts" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/widgets/cookie-notice/styles.module.scss" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/src/widgets/cookie-notice/ui.tsx" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/app/api/sendform/route.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/app/api/sendform/route.ts" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/entities/base-menu/ui.tsx" beforeDir="false" afterPath="$PROJECT_DIR$/src/entities/base-menu/ui.tsx" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/entities/top-menu/ui.tsx" beforeDir="false" afterPath="$PROJECT_DIR$/src/entities/top-menu/ui.tsx" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/shared/const/contacts.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/shared/const/contacts.ts" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/app/layout.tsx" beforeDir="false" afterPath="$PROJECT_DIR$/src/app/layout.tsx" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/entities/beauty-button/ui.tsx" beforeDir="false" afterPath="$PROJECT_DIR$/src/entities/beauty-button/ui.tsx" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/views/index.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/views/index.ts" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/widgets/footer/ui.tsx" beforeDir="false" afterPath="$PROJECT_DIR$/src/widgets/footer/ui.tsx" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/widgets/index.ts" beforeDir="false" afterPath="$PROJECT_DIR$/src/widgets/index.ts" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/widgets/mobile-callback/ui.tsx" beforeDir="false" afterPath="$PROJECT_DIR$/src/widgets/mobile-callback/ui.tsx" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/src/widgets/scroll-to-top/styles.module.scss" beforeDir="false" afterPath="$PROJECT_DIR$/src/widgets/scroll-to-top/styles.module.scss" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
@@ -24,16 +26,16 @@
|
||||
<option name="LAST_RESOLUTION" value="IGNORE" />
|
||||
</component>
|
||||
<component name="DarkyenusTimeTracker">
|
||||
<option name="totalTimeSeconds" value="197124" />
|
||||
<option name="totalTimeSeconds" value="199383" />
|
||||
<option name="gitIntegration" value="true" />
|
||||
<option name="naggedAbout" value="1" />
|
||||
</component>
|
||||
<component name="FileTemplateManagerImpl">
|
||||
<option name="RECENT_TEMPLATES">
|
||||
<list>
|
||||
<option value="TypeScript File" />
|
||||
<option value="TypeScript JSX File" />
|
||||
<option value="SCSS File" />
|
||||
<option value="TypeScript File" />
|
||||
</list>
|
||||
</option>
|
||||
</component>
|
||||
@@ -119,7 +121,7 @@
|
||||
<workItem from="1764591867512" duration="4332000" />
|
||||
<workItem from="1764657017067" duration="21490000" />
|
||||
<workItem from="1764741053553" duration="18011000" />
|
||||
<workItem from="1764825390464" duration="5046000" />
|
||||
<workItem from="1764825390464" duration="8920000" />
|
||||
</task>
|
||||
<servers />
|
||||
</component>
|
||||
|
||||
5
src/app/cookie/page.tsx
Normal file
5
src/app/cookie/page.tsx
Normal file
@@ -0,0 +1,5 @@
|
||||
import { Cookie } from '@/views';
|
||||
|
||||
export default function Page() {
|
||||
return <Cookie />;
|
||||
}
|
||||
@@ -3,7 +3,13 @@ import { ReactNode } from 'react';
|
||||
import { Montserrat, Roboto } from 'next/font/google';
|
||||
import '@core/styles/globals.scss';
|
||||
import '@core/styles/reset.scss';
|
||||
import { Footer, Header, MobileCallback, ScrollToTop } from '@/widgets';
|
||||
import {
|
||||
CookieNotice,
|
||||
Footer,
|
||||
Header,
|
||||
MobileCallback,
|
||||
ScrollToTop,
|
||||
} from '@/widgets';
|
||||
import { ModalProvider } from '@core/providers/modal-provider';
|
||||
|
||||
const roboto = Roboto({
|
||||
@@ -35,8 +41,9 @@ export default function RootLayout({
|
||||
<main>{children}</main>
|
||||
<Footer />
|
||||
<MobileCallback />
|
||||
<ScrollToTop />
|
||||
</ModalProvider>
|
||||
<ScrollToTop />
|
||||
<CookieNotice />
|
||||
</body>
|
||||
</html>
|
||||
);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
'use client';
|
||||
|
||||
import s from './styles.module.scss';
|
||||
import type { ReactNode, SVGProps } from 'react';
|
||||
import type { ReactNode } from 'react';
|
||||
import { useModal } from '@core/providers/modal-provider';
|
||||
import { ConsultationModal } from '@/feature/article';
|
||||
import { Icons } from '@/shared/ui/icon';
|
||||
|
||||
1
src/views/cookie/index.ts
Normal file
1
src/views/cookie/index.ts
Normal file
@@ -0,0 +1 @@
|
||||
export * from './ui';
|
||||
55
src/views/cookie/styles.module.scss
Normal file
55
src/views/cookie/styles.module.scss
Normal file
@@ -0,0 +1,55 @@
|
||||
.Cookie {
|
||||
position: relative;
|
||||
margin: rem(60px) auto rem(20px);
|
||||
width: rem(360px);
|
||||
background: #EEE;
|
||||
padding: rem(20px);
|
||||
border-radius: rem(28px);
|
||||
|
||||
@include iftablet{
|
||||
width: rem(600px);
|
||||
margin: rem(40px) auto rem(20px);
|
||||
padding: rem(20px);
|
||||
}
|
||||
|
||||
@include iflaptop{
|
||||
width: rem(800px);
|
||||
margin: rem(60px) auto rem(20px);
|
||||
padding: rem(60px);
|
||||
}
|
||||
|
||||
@include ifdesktop{
|
||||
width: rem(1200px);
|
||||
margin: rem(60px) auto rem(20px);
|
||||
padding: rem(60px);
|
||||
}
|
||||
|
||||
h2 {
|
||||
font-family: $font-roboto;
|
||||
font-weight: 500;
|
||||
font-size: rem(20px);
|
||||
line-height: 130%;
|
||||
color: $color-text;
|
||||
|
||||
@include iftablet{
|
||||
font-size: rem(24px);
|
||||
}
|
||||
}
|
||||
|
||||
p {
|
||||
font-family: $font-roboto;
|
||||
font-weight: 400;
|
||||
font-size: rem(14px);
|
||||
line-height: 130%;
|
||||
color: $color-text;
|
||||
margin: 8px 0;
|
||||
|
||||
@include iftablet{
|
||||
font-size: rem(16px);
|
||||
}
|
||||
}
|
||||
|
||||
a {
|
||||
color: $color-green;
|
||||
}
|
||||
}
|
||||
46
src/views/cookie/ui.tsx
Normal file
46
src/views/cookie/ui.tsx
Normal file
@@ -0,0 +1,46 @@
|
||||
import s from './styles.module.scss';
|
||||
import Link from 'next/link';
|
||||
import { CONTACTS } from '@shared/const/contacts';
|
||||
import { ROUTES } from '@shared/const/route';
|
||||
|
||||
function Cookie() {
|
||||
return (
|
||||
<section className={s.Cookie}>
|
||||
<h2>Мы используем cookie</h2>
|
||||
<p>
|
||||
Когда вы посещаете сайт {CONTACTS.WEB}, наша компания может использовать
|
||||
общеотраслевую технологию, называемую cookie. Файлы cookie представляют
|
||||
собой небольшие фрагменты данных, которые временно сохраняются на вашем
|
||||
компьютере или мобильном устройстве и обеспечивают более эффективную
|
||||
работу сайта.
|
||||
</p>
|
||||
<p>
|
||||
Сайт {CONTACTS.WEB} использует метрические системы для сбора статистики:
|
||||
«Яндекс.Метрика». На основе этих данных мы делаем наш сайт лучше и
|
||||
эффективнее для пользователей.
|
||||
</p>
|
||||
<p>
|
||||
Продолжая пользоваться этим сайтом, вы соглашаетесь на использование
|
||||
cookie и обработку данных в соответствии с Политикой сайта в области
|
||||
обработки и защиты персональных данных.
|
||||
</p>
|
||||
<p>
|
||||
<Link href={ROUTES.PRIVACY_POLICY}>
|
||||
Согласие на обработку персональных данных посетителей сайта
|
||||
</Link>
|
||||
</p>
|
||||
<p>
|
||||
Если вы не хотите использовать cookie, вы можете отключить их в
|
||||
настройках безопасности вашего браузера. Отключение cookie следует
|
||||
выполнить для каждого браузера и устройства, с помощью которого
|
||||
осуществляется вход на сайт.
|
||||
</p>
|
||||
<p>
|
||||
Обратите внимание, что в случае, если использование сайтом файлов cookie
|
||||
отключено, некоторые возможности и услуги сайта могут быть недоступны.
|
||||
</p>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
|
||||
export { Cookie };
|
||||
@@ -1,6 +1,7 @@
|
||||
export * from './home';
|
||||
export * from './contacts';
|
||||
export * from './privacy-policy';
|
||||
export * from './cookie';
|
||||
|
||||
//Expertise
|
||||
export * from './expertise/category';
|
||||
|
||||
1
src/widgets/cookie-notice/index.ts
Normal file
1
src/widgets/cookie-notice/index.ts
Normal file
@@ -0,0 +1 @@
|
||||
export * from './ui';
|
||||
98
src/widgets/cookie-notice/styles.module.scss
Normal file
98
src/widgets/cookie-notice/styles.module.scss
Normal file
@@ -0,0 +1,98 @@
|
||||
.Cookies {
|
||||
position: fixed;
|
||||
z-index: 10;
|
||||
width: rem(360px);
|
||||
bottom: rem(60px);
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
will-change: transform;
|
||||
|
||||
background-color: #eee;
|
||||
|
||||
transition: opacity 0.25s ease-in-out;
|
||||
border: 1px solid $color-lightgray;
|
||||
border-radius: 28px;
|
||||
box-shadow: 1px 1px 2px 0 #aaa;
|
||||
|
||||
@include iftablet {
|
||||
width: rem(700px);
|
||||
bottom: rem(60px);
|
||||
}
|
||||
@include iflaptop {
|
||||
width: rem(1000px);
|
||||
}
|
||||
@include ifdesktop {
|
||||
width: rem(1200px);
|
||||
}
|
||||
}
|
||||
|
||||
.Container {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: rem(20px);
|
||||
padding: rem(20px);
|
||||
|
||||
@include iftablet {
|
||||
justify-content: space-between;
|
||||
flex-direction: row;
|
||||
align-items: center;
|
||||
gap: rem(25px);
|
||||
padding: rem(20px) rem(40px);
|
||||
}
|
||||
}
|
||||
|
||||
.Text {
|
||||
font-family: $font-roboto;
|
||||
font-weight: 400;
|
||||
font-size: rem(16px);
|
||||
line-height: 130%;
|
||||
opacity: 1;
|
||||
|
||||
@include iftablet {
|
||||
max-width: rem(350px);
|
||||
}
|
||||
|
||||
@include iflaptop {
|
||||
max-width: unset;
|
||||
}
|
||||
|
||||
@include ifdesktop {
|
||||
font-size: rem(18px);
|
||||
}
|
||||
|
||||
a {
|
||||
color: $color-green;
|
||||
|
||||
&:hover {
|
||||
color: $color-green-hover;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.ButtonBox {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
gap: rem(32px);
|
||||
|
||||
@include iftablet {
|
||||
flex-direction: column-reverse;
|
||||
gap: rem(20px);
|
||||
max-width: max-content;
|
||||
}
|
||||
|
||||
@include iflaptop {
|
||||
flex-direction: row;
|
||||
justify-content: flex-end;
|
||||
max-width: unset;
|
||||
}
|
||||
|
||||
@include ifdesktop {
|
||||
}
|
||||
}
|
||||
|
||||
.Hide {
|
||||
opacity: 0;
|
||||
user-select: none;
|
||||
pointer-events: none;
|
||||
}
|
||||
52
src/widgets/cookie-notice/ui.tsx
Normal file
52
src/widgets/cookie-notice/ui.tsx
Normal file
@@ -0,0 +1,52 @@
|
||||
'use client';
|
||||
|
||||
import s from './styles.module.scss';
|
||||
import { useEffect, useState } from 'react';
|
||||
import { Button } from '@shared/ui';
|
||||
import { clsx } from 'clsx';
|
||||
import Link from 'next/link';
|
||||
import { ROUTES } from '@shared/const/route';
|
||||
|
||||
function CookieNotice() {
|
||||
const [seenCookie, setSeenCookie] = useState(true);
|
||||
const [clicked, setClicked] = useState(false);
|
||||
|
||||
useEffect(() => {
|
||||
const seenCookie = localStorage.getItem('seen_cookie');
|
||||
if (!seenCookie) setSeenCookie(false);
|
||||
}, []);
|
||||
|
||||
const handleClickAgree = () => {
|
||||
localStorage.setItem('seen_cookie', 'true');
|
||||
setClicked(true);
|
||||
};
|
||||
|
||||
const handleClickCancel = () => {
|
||||
setClicked(true);
|
||||
};
|
||||
|
||||
return seenCookie ? null : (
|
||||
<div className={clsx(s.Cookies, clicked && s.Hide)}>
|
||||
<div className={s.Container}>
|
||||
<span className={s.Text}>
|
||||
Мы используем cookie. <br /> Во время посещения этого сайта вы
|
||||
соглашаетесь с тем, что мы обрабатываем ваши персональные данные с
|
||||
использованием систем для сбора статистики. <br />
|
||||
<Link href={ROUTES.COOKIES}>Подробнее</Link>
|
||||
</span>
|
||||
|
||||
<div className={s.ButtonBox}>
|
||||
<Button onClick={handleClickCancel} fullWidth>
|
||||
Отмена
|
||||
</Button>
|
||||
|
||||
<Button onClick={handleClickAgree} fullWidth>
|
||||
Согласиться
|
||||
</Button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
|
||||
export { CookieNotice };
|
||||
@@ -4,3 +4,4 @@ export * from './breadcrumbs';
|
||||
export * from './mobile-callback';
|
||||
export * from './sidebar';
|
||||
export * from './scroll-to-top';
|
||||
export * from './cookie-notice';
|
||||
|
||||
@@ -1,16 +1,28 @@
|
||||
'use client';
|
||||
|
||||
import s from './styles.module.scss';
|
||||
import { Icons } from '@shared/ui';
|
||||
import { phoneBeautify } from '@shared/lib/phoneBeautify/phoneBeautify';
|
||||
import { CONTACTS } from '@shared/const/contacts';
|
||||
import { useModal } from '@core/providers/modal-provider';
|
||||
import { ConsultationModal } from '@/feature/article';
|
||||
|
||||
function MobileCallback() {
|
||||
const modal = useModal();
|
||||
const openModal = () => modal.showModal(<ConsultationModal />);
|
||||
|
||||
const handlePhoneClick = () => {
|
||||
window.open(`tel:${CONTACTS.PHONE}`, '_self');
|
||||
};
|
||||
return (
|
||||
<div className={s.Root}>
|
||||
<button className={s.Button}>
|
||||
<button className={s.Button} onClick={openModal}>
|
||||
<Icons.MobileContact className={s.Icon} />
|
||||
<span className={s.Text}>Записаться</span>
|
||||
</button>
|
||||
<button className={s.Button}>
|
||||
<button className={s.Button} onClick={handlePhoneClick}>
|
||||
<Icons.MobilePhone className={s.Icon} />
|
||||
<span className={s.Text}>+7 (900) 241-34-34</span>
|
||||
<span className={s.Text}>{phoneBeautify(CONTACTS.PHONE)}</span>
|
||||
</button>
|
||||
</div>
|
||||
);
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
.Scroll {
|
||||
position: fixed;
|
||||
right: rem(20px);
|
||||
bottom: rem(50px);
|
||||
bottom: rem(60px);
|
||||
|
||||
width: rem(64px);
|
||||
height: rem(64px);
|
||||
@@ -23,6 +23,10 @@
|
||||
pointer-events: none;
|
||||
transition: opacity 0.3s ease, transform 0.3s ease;
|
||||
|
||||
@include iflaptop{
|
||||
bottom: rem(40px);
|
||||
}
|
||||
|
||||
&.Visible {
|
||||
opacity: 1;
|
||||
transform: translateY(0);
|
||||
|
||||
Reference in New Issue
Block a user