2
apps/web/next-env.d.ts
vendored
2
apps/web/next-env.d.ts
vendored
@@ -1,6 +1,6 @@
|
||||
/// <reference types="next" />
|
||||
/// <reference types="next/image-types/global" />
|
||||
import './.next/types/routes.d.ts';
|
||||
import "./.next/types/routes.d.ts";
|
||||
|
||||
// NOTE: This file should not be edited
|
||||
// see https://nextjs.org/docs/app/api-reference/config/typescript for more information.
|
||||
|
||||
53
apps/web/src/app/about/page.module.scss
Normal file
53
apps/web/src/app/about/page.module.scss
Normal file
@@ -0,0 +1,53 @@
|
||||
.container {
|
||||
max-width: 800px;
|
||||
margin: 0 auto;
|
||||
padding: var(--space-lg);
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 28px;
|
||||
font-weight: 700;
|
||||
color: var(--color-slate-900);
|
||||
margin-bottom: var(--space-xl);
|
||||
}
|
||||
|
||||
.content {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-md);
|
||||
font-size: 15px;
|
||||
line-height: 1.7;
|
||||
color: var(--color-slate-700);
|
||||
margin-bottom: var(--space-2xl);
|
||||
}
|
||||
|
||||
.stats {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
gap: var(--space-md);
|
||||
padding: var(--space-xl);
|
||||
background: var(--color-surface);
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-lg);
|
||||
margin-bottom: var(--space-2xl);
|
||||
|
||||
@media (max-width: 640px) {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
}
|
||||
}
|
||||
|
||||
.statItem {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.statNum {
|
||||
font-size: 28px;
|
||||
font-weight: 800;
|
||||
color: var(--color-orange-500);
|
||||
}
|
||||
|
||||
.statLabel {
|
||||
font-size: 12px;
|
||||
color: var(--color-text-muted);
|
||||
margin-top: 4px;
|
||||
}
|
||||
53
apps/web/src/app/about/page.tsx
Normal file
53
apps/web/src/app/about/page.tsx
Normal file
@@ -0,0 +1,53 @@
|
||||
import { Breadcrumb } from '@/components/Breadcrumb/Breadcrumb';
|
||||
import { TrustStrip } from '@/components/TrustStrip/TrustStrip';
|
||||
import styles from './page.module.scss';
|
||||
|
||||
export const metadata = {
|
||||
title: 'О компании | PAN-PROM',
|
||||
};
|
||||
|
||||
export default function AboutPage() {
|
||||
return (
|
||||
<>
|
||||
<div className={styles.container}>
|
||||
<Breadcrumb
|
||||
items={[{ label: 'Главная', href: '/' }, { label: 'О компании' }]}
|
||||
/>
|
||||
<h1 className={styles.title}>О компании PAN-PROM</h1>
|
||||
|
||||
<div className={styles.content}>
|
||||
<p>
|
||||
PAN-PROM — поставщик промышленного оборудования и комплектующих от
|
||||
ведущих европейских производителей. Мы специализируемся на
|
||||
гидравлике, пневматике, системах автоматизации (АСУ) и запасных
|
||||
частях.
|
||||
</p>
|
||||
<p>
|
||||
Наша компания работает напрямую с такими брендами, как Bosch Rexroth,
|
||||
Festo, Siemens, Parker, HYDAC, Beckhoff и многими другими. Это
|
||||
гарантирует оригинальность продукции и оптимальные сроки поставки.
|
||||
</p>
|
||||
<p>
|
||||
Склады в Берлине и Гуанчжоу позволяют нам обеспечивать быструю
|
||||
логистику и конкурентные цены для наших клиентов.
|
||||
</p>
|
||||
</div>
|
||||
|
||||
<div className={styles.stats}>
|
||||
{[
|
||||
{ num: '50+', label: 'Европейских брендов' },
|
||||
{ num: '10 000+', label: 'Позиций в каталоге' },
|
||||
{ num: '14 дней', label: 'Средний срок поставки' },
|
||||
{ num: '100%', label: 'Оригинальная продукция' },
|
||||
].map((s, i) => (
|
||||
<div key={i} className={styles.statItem}>
|
||||
<div className={styles.statNum}>{s.num}</div>
|
||||
<div className={styles.statLabel}>{s.label}</div>
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
<TrustStrip />
|
||||
</>
|
||||
);
|
||||
}
|
||||
67
apps/web/src/app/brand/[id]/page.module.scss
Normal file
67
apps/web/src/app/brand/[id]/page.module.scss
Normal file
@@ -0,0 +1,67 @@
|
||||
.container {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
padding: var(--space-lg);
|
||||
}
|
||||
|
||||
.brandHeader {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: var(--space-md);
|
||||
margin: var(--space-lg) 0;
|
||||
padding-bottom: var(--space-lg);
|
||||
border-bottom: 1px solid var(--color-border);
|
||||
}
|
||||
|
||||
.logoBox {
|
||||
width: 64px;
|
||||
height: 64px;
|
||||
border-radius: var(--border-radius-lg);
|
||||
background: var(--color-slate-100);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-weight: 800;
|
||||
font-size: 22px;
|
||||
color: var(--color-slate-600);
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.brandName {
|
||||
font-size: 28px;
|
||||
font-weight: 700;
|
||||
color: var(--color-slate-900);
|
||||
}
|
||||
|
||||
.brandMeta {
|
||||
font-size: 14px;
|
||||
color: var(--color-text-muted);
|
||||
margin-top: 4px;
|
||||
}
|
||||
|
||||
.sectionTitle {
|
||||
font-size: 18px;
|
||||
font-weight: 600;
|
||||
color: var(--color-slate-800);
|
||||
margin-bottom: var(--space-md);
|
||||
}
|
||||
|
||||
.grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
gap: var(--space-md);
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
.empty {
|
||||
text-align: center;
|
||||
color: var(--color-text-muted);
|
||||
padding: var(--space-2xl) 0;
|
||||
}
|
||||
71
apps/web/src/app/brand/[id]/page.tsx
Normal file
71
apps/web/src/app/brand/[id]/page.tsx
Normal file
@@ -0,0 +1,71 @@
|
||||
import { notFound } from 'next/navigation';
|
||||
import { brands } from '@/data/brands';
|
||||
import { products } from '@/data/products';
|
||||
import { Breadcrumb } from '@/components/Breadcrumb/Breadcrumb';
|
||||
import { ProductCard } from '@/components/ProductCard/ProductCard';
|
||||
import styles from './page.module.scss';
|
||||
|
||||
export function generateStaticParams() {
|
||||
return brands.map((b) => ({ id: String(b.id) }));
|
||||
}
|
||||
|
||||
export async function generateMetadata({
|
||||
params,
|
||||
}: {
|
||||
params: Promise<{ id: string }>;
|
||||
}) {
|
||||
const { id } = await params;
|
||||
const brand = brands.find((b) => b.id === Number(id));
|
||||
return {
|
||||
title: brand ? `${brand.name} | PAN-PROM` : 'Бренд | PAN-PROM',
|
||||
};
|
||||
}
|
||||
|
||||
export default async function BrandPage({
|
||||
params,
|
||||
}: {
|
||||
params: Promise<{ id: string }>;
|
||||
}) {
|
||||
const { id } = await params;
|
||||
const brand = brands.find((b) => b.id === Number(id));
|
||||
if (!brand) notFound();
|
||||
|
||||
const brandProducts = products.filter((p) => p.brand === brand.name);
|
||||
|
||||
return (
|
||||
<div className={styles.container}>
|
||||
<Breadcrumb
|
||||
items={[
|
||||
{ label: 'Главная', href: '/' },
|
||||
{ label: 'Каталог', href: '/catalog' },
|
||||
{ label: brand.name },
|
||||
]}
|
||||
/>
|
||||
|
||||
<div className={styles.brandHeader}>
|
||||
<div className={styles.logoBox}>{brand.logo}</div>
|
||||
<div>
|
||||
<h1 className={styles.brandName}>{brand.name}</h1>
|
||||
<div className={styles.brandMeta}>
|
||||
{brand.country} · {brand.category}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<h2 className={styles.sectionTitle}>
|
||||
Продукция ({brandProducts.length})
|
||||
</h2>
|
||||
<div className={styles.grid}>
|
||||
{brandProducts.map((p) => (
|
||||
<ProductCard key={p.id} product={p} />
|
||||
))}
|
||||
</div>
|
||||
|
||||
{brandProducts.length === 0 && (
|
||||
<p className={styles.empty}>
|
||||
Продукция этого бренда скоро появится в каталоге.
|
||||
</p>
|
||||
)}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
11
apps/web/src/app/cart/layout.tsx
Normal file
11
apps/web/src/app/cart/layout.tsx
Normal file
@@ -0,0 +1,11 @@
|
||||
export const metadata = {
|
||||
title: 'Корзина | PAN-PROM',
|
||||
};
|
||||
|
||||
export default function CartLayout({
|
||||
children,
|
||||
}: {
|
||||
children: React.ReactNode;
|
||||
}) {
|
||||
return children;
|
||||
}
|
||||
122
apps/web/src/app/cart/page.module.scss
Normal file
122
apps/web/src/app/cart/page.module.scss
Normal file
@@ -0,0 +1,122 @@
|
||||
.container {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
padding: var(--space-lg);
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 28px;
|
||||
font-weight: 700;
|
||||
color: var(--color-slate-900);
|
||||
margin-bottom: var(--space-lg);
|
||||
}
|
||||
|
||||
.empty {
|
||||
text-align: center;
|
||||
padding: var(--space-2xl) 0;
|
||||
color: var(--color-text-muted);
|
||||
|
||||
p {
|
||||
margin-bottom: var(--space-md);
|
||||
font-size: 16px;
|
||||
}
|
||||
}
|
||||
|
||||
.items {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 1px;
|
||||
background: var(--color-border);
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-lg);
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.item {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
padding: var(--space-md) var(--space-lg);
|
||||
background: var(--color-surface);
|
||||
}
|
||||
|
||||
.itemSku {
|
||||
font-family: var(--font-mono);
|
||||
font-size: 12px;
|
||||
color: var(--color-orange-500);
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.itemName {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
color: var(--color-slate-800);
|
||||
margin-top: 2px;
|
||||
}
|
||||
|
||||
.itemBrand {
|
||||
font-size: 12px;
|
||||
color: var(--color-text-muted);
|
||||
margin-top: 2px;
|
||||
}
|
||||
|
||||
.itemActions {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: var(--space-md);
|
||||
}
|
||||
|
||||
.qtyControl {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-sm);
|
||||
padding: 4px;
|
||||
}
|
||||
|
||||
.qtyBtn {
|
||||
background: none;
|
||||
border: none;
|
||||
padding: 4px;
|
||||
display: flex;
|
||||
cursor: pointer;
|
||||
color: var(--color-slate-500);
|
||||
|
||||
&:hover {
|
||||
color: var(--color-slate-800);
|
||||
}
|
||||
}
|
||||
|
||||
.qty {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
min-width: 24px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.removeBtn {
|
||||
background: none;
|
||||
border: none;
|
||||
padding: 4px;
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
opacity: 0.7;
|
||||
}
|
||||
}
|
||||
|
||||
.footer {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-top: var(--space-lg);
|
||||
padding-top: var(--space-lg);
|
||||
border-top: 1px solid var(--color-border);
|
||||
}
|
||||
|
||||
.totalLabel {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
color: var(--color-slate-600);
|
||||
}
|
||||
78
apps/web/src/app/cart/page.tsx
Normal file
78
apps/web/src/app/cart/page.tsx
Normal file
@@ -0,0 +1,78 @@
|
||||
'use client';
|
||||
|
||||
import Link from 'next/link';
|
||||
import { useCart } from '@/components/CartProvider/CartProvider';
|
||||
import { Icon } from '@/components/Icon/Icon';
|
||||
import { Button } from '@/components/ui/Button/Button';
|
||||
import { Breadcrumb } from '@/components/Breadcrumb/Breadcrumb';
|
||||
import styles from './page.module.scss';
|
||||
|
||||
export default function CartPage() {
|
||||
const { cart, removeFromCart, updateQuantity } = useCart();
|
||||
|
||||
return (
|
||||
<div className={styles.container}>
|
||||
<Breadcrumb
|
||||
items={[{ label: 'Главная', href: '/' }, { label: 'Корзина' }]}
|
||||
/>
|
||||
<h1 className={styles.title}>Корзина запроса</h1>
|
||||
|
||||
{cart.length === 0 ? (
|
||||
<div className={styles.empty}>
|
||||
<p>Корзина пуста</p>
|
||||
<Link href="/catalog">
|
||||
<Button>Перейти в каталог</Button>
|
||||
</Link>
|
||||
</div>
|
||||
) : (
|
||||
<>
|
||||
<div className={styles.items}>
|
||||
{cart.map((item) => (
|
||||
<div key={item.id} className={styles.item}>
|
||||
<div className={styles.itemInfo}>
|
||||
<div className={styles.itemSku}>{item.sku}</div>
|
||||
<div className={styles.itemName}>{item.name}</div>
|
||||
<div className={styles.itemBrand}>{item.brand}</div>
|
||||
</div>
|
||||
<div className={styles.itemActions}>
|
||||
<div className={styles.qtyControl}>
|
||||
<button
|
||||
className={styles.qtyBtn}
|
||||
onClick={() => updateQuantity(item.id, item.qty - 1)}
|
||||
aria-label="Уменьшить количество"
|
||||
>
|
||||
<Icon name="minus" size={14} />
|
||||
</button>
|
||||
<span className={styles.qty}>{item.qty}</span>
|
||||
<button
|
||||
className={styles.qtyBtn}
|
||||
onClick={() => updateQuantity(item.id, item.qty + 1)}
|
||||
aria-label="Увеличить количество"
|
||||
>
|
||||
<Icon name="plus" size={14} />
|
||||
</button>
|
||||
</div>
|
||||
<button
|
||||
className={styles.removeBtn}
|
||||
onClick={() => removeFromCart(item.id)}
|
||||
aria-label="Удалить из корзины"
|
||||
>
|
||||
<Icon name="x" size={16} color="var(--color-slate-400)" />
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
<div className={styles.footer}>
|
||||
<span className={styles.totalLabel}>
|
||||
Позиций: {cart.length}
|
||||
</span>
|
||||
<Link href="/rfq">
|
||||
<Button>Отправить запрос (RFQ)</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</>
|
||||
)}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
61
apps/web/src/app/catalog/[category]/page.tsx
Normal file
61
apps/web/src/app/catalog/[category]/page.tsx
Normal file
@@ -0,0 +1,61 @@
|
||||
import { Suspense } from 'react';
|
||||
import { notFound } from 'next/navigation';
|
||||
import { products } from '@/data/products';
|
||||
import { categories } from '@/data/categories';
|
||||
import { categoryNameMap, CategorySlug } from '@/types';
|
||||
import { Breadcrumb } from '@/components/Breadcrumb/Breadcrumb';
|
||||
import { CatalogSidebar } from '@/components/CatalogSidebar/CatalogSidebar';
|
||||
import { ProductCard } from '@/components/ProductCard/ProductCard';
|
||||
import styles from '../page.module.scss';
|
||||
|
||||
export function generateStaticParams() {
|
||||
return categories.map((c) => ({ category: c.slug }));
|
||||
}
|
||||
|
||||
export function generateMetadata({
|
||||
params,
|
||||
}: {
|
||||
params: Promise<{ category: string }>;
|
||||
}) {
|
||||
return params.then(({ category }) => {
|
||||
const name = categoryNameMap[category as CategorySlug];
|
||||
return { title: name ? `${name} | PAN-PROM` : 'Каталог | PAN-PROM' };
|
||||
});
|
||||
}
|
||||
|
||||
export default async function CategoryPage({
|
||||
params,
|
||||
}: {
|
||||
params: Promise<{ category: string }>;
|
||||
}) {
|
||||
const { category } = await params;
|
||||
const catName = categoryNameMap[category as CategorySlug];
|
||||
if (!catName) notFound();
|
||||
|
||||
const filtered = products.filter((p) => p.category === catName);
|
||||
|
||||
return (
|
||||
<div className={styles.layout}>
|
||||
<Suspense fallback={null}>
|
||||
<CatalogSidebar activeCategory={category} />
|
||||
</Suspense>
|
||||
<div className={styles.main}>
|
||||
<div className={styles.header}>
|
||||
<Breadcrumb
|
||||
items={[
|
||||
{ label: 'Главная', href: '/' },
|
||||
{ label: 'Каталог', href: '/catalog' },
|
||||
{ label: catName },
|
||||
]}
|
||||
/>
|
||||
<span className={styles.count}>{filtered.length} позиций</span>
|
||||
</div>
|
||||
<div className={styles.grid}>
|
||||
{filtered.map((p) => (
|
||||
<ProductCard key={p.id} product={p} />
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
37
apps/web/src/app/catalog/page.module.scss
Normal file
37
apps/web/src/app/catalog/page.module.scss
Normal file
@@ -0,0 +1,37 @@
|
||||
.layout {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
padding: var(--space-lg);
|
||||
display: flex;
|
||||
gap: var(--space-lg);
|
||||
}
|
||||
|
||||
.main {
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: var(--space-md);
|
||||
}
|
||||
|
||||
.count {
|
||||
font-size: 12px;
|
||||
color: var(--color-slate-400);
|
||||
}
|
||||
|
||||
.grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
gap: var(--space-md);
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
36
apps/web/src/app/catalog/page.tsx
Normal file
36
apps/web/src/app/catalog/page.tsx
Normal file
@@ -0,0 +1,36 @@
|
||||
import { Suspense } from 'react';
|
||||
import { products } from '@/data/products';
|
||||
import { Breadcrumb } from '@/components/Breadcrumb/Breadcrumb';
|
||||
import { CatalogSidebar } from '@/components/CatalogSidebar/CatalogSidebar';
|
||||
import { ProductCard } from '@/components/ProductCard/ProductCard';
|
||||
import styles from './page.module.scss';
|
||||
|
||||
export const metadata = {
|
||||
title: 'Каталог | PAN-PROM',
|
||||
};
|
||||
|
||||
export default function CatalogPage() {
|
||||
return (
|
||||
<div className={styles.layout}>
|
||||
<Suspense fallback={null}>
|
||||
<CatalogSidebar />
|
||||
</Suspense>
|
||||
<div className={styles.main}>
|
||||
<div className={styles.header}>
|
||||
<Breadcrumb
|
||||
items={[
|
||||
{ label: 'Главная', href: '/' },
|
||||
{ label: 'Каталог' },
|
||||
]}
|
||||
/>
|
||||
<span className={styles.count}>{products.length} позиций</span>
|
||||
</div>
|
||||
<div className={styles.grid}>
|
||||
{products.map((p) => (
|
||||
<ProductCard key={p.id} product={p} />
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
60
apps/web/src/app/contact/page.module.scss
Normal file
60
apps/web/src/app/contact/page.module.scss
Normal file
@@ -0,0 +1,60 @@
|
||||
.container {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
padding: var(--space-lg);
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 28px;
|
||||
font-weight: 700;
|
||||
color: var(--color-slate-900);
|
||||
margin-bottom: var(--space-xl);
|
||||
}
|
||||
|
||||
.grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(3, 1fr);
|
||||
gap: var(--space-lg);
|
||||
|
||||
@media (max-width: 768px) {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
.card {
|
||||
background: var(--color-surface);
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-lg);
|
||||
padding: var(--space-xl);
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.iconBox {
|
||||
width: 56px;
|
||||
height: 56px;
|
||||
border-radius: var(--border-radius-lg);
|
||||
background: var(--color-orange-50);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin: 0 auto var(--space-md);
|
||||
}
|
||||
|
||||
.cardTitle {
|
||||
font-size: 16px;
|
||||
font-weight: 600;
|
||||
color: var(--color-slate-800);
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
.cardText {
|
||||
font-size: 15px;
|
||||
color: var(--color-slate-700);
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.cardNote {
|
||||
font-size: 12px;
|
||||
color: var(--color-text-muted);
|
||||
margin-top: 4px;
|
||||
}
|
||||
47
apps/web/src/app/contact/page.tsx
Normal file
47
apps/web/src/app/contact/page.tsx
Normal file
@@ -0,0 +1,47 @@
|
||||
import { Icon } from '@/components/Icon/Icon';
|
||||
import { Breadcrumb } from '@/components/Breadcrumb/Breadcrumb';
|
||||
import styles from './page.module.scss';
|
||||
|
||||
export const metadata = {
|
||||
title: 'Контакты | PAN-PROM',
|
||||
};
|
||||
|
||||
export default function ContactPage() {
|
||||
return (
|
||||
<div className={styles.container}>
|
||||
<Breadcrumb
|
||||
items={[{ label: 'Главная', href: '/' }, { label: 'Контакты' }]}
|
||||
/>
|
||||
<h1 className={styles.title}>Контакты</h1>
|
||||
|
||||
<div className={styles.grid}>
|
||||
<div className={styles.card}>
|
||||
<div className={styles.iconBox}>
|
||||
<Icon name="phone" size={24} color="var(--color-orange-500)" />
|
||||
</div>
|
||||
<h3 className={styles.cardTitle}>Телефон</h3>
|
||||
<p className={styles.cardText}>+49 (0) 40 123-4567</p>
|
||||
<p className={styles.cardNote}>Пн-Пт: 09:00 - 18:00 CET</p>
|
||||
</div>
|
||||
|
||||
<div className={styles.card}>
|
||||
<div className={styles.iconBox}>
|
||||
<Icon name="mail" size={24} color="var(--color-orange-500)" />
|
||||
</div>
|
||||
<h3 className={styles.cardTitle}>Email</h3>
|
||||
<p className={styles.cardText}>info@pan-prom.eu</p>
|
||||
<p className={styles.cardNote}>Ответ в течение 24 часов</p>
|
||||
</div>
|
||||
|
||||
<div className={styles.card}>
|
||||
<div className={styles.iconBox}>
|
||||
<Icon name="map" size={24} color="var(--color-orange-500)" />
|
||||
</div>
|
||||
<h3 className={styles.cardTitle}>Офис</h3>
|
||||
<p className={styles.cardText}>Hamburg, Germany</p>
|
||||
<p className={styles.cardNote}>Склады: Берлин, Гуанчжоу</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
@@ -1,501 +1,122 @@
|
||||
html {
|
||||
-webkit-text-size-adjust: 100%;
|
||||
font-family:
|
||||
ui-sans-serif,
|
||||
system-ui,
|
||||
-apple-system,
|
||||
BlinkMacSystemFont,
|
||||
Segoe UI,
|
||||
Roboto,
|
||||
Helvetica Neue,
|
||||
Arial,
|
||||
Noto Sans,
|
||||
sans-serif,
|
||||
Apple Color Emoji,
|
||||
Segoe UI Emoji,
|
||||
Segoe UI Symbol,
|
||||
Noto Color Emoji;
|
||||
line-height: 1.5;
|
||||
tab-size: 4;
|
||||
scroll-behavior: smooth;
|
||||
}
|
||||
body {
|
||||
font-family: inherit;
|
||||
line-height: inherit;
|
||||
margin: 0;
|
||||
}
|
||||
h1,
|
||||
h2,
|
||||
p,
|
||||
pre {
|
||||
margin: 0;
|
||||
}
|
||||
/* Reset */
|
||||
*,
|
||||
::before,
|
||||
::after {
|
||||
*::before,
|
||||
*::after {
|
||||
box-sizing: border-box;
|
||||
border-width: 0;
|
||||
border-style: solid;
|
||||
border-color: currentColor;
|
||||
}
|
||||
h1,
|
||||
h2 {
|
||||
font-size: inherit;
|
||||
font-weight: inherit;
|
||||
}
|
||||
a {
|
||||
color: inherit;
|
||||
text-decoration: inherit;
|
||||
}
|
||||
pre {
|
||||
font-family:
|
||||
ui-monospace,
|
||||
SFMono-Regular,
|
||||
Menlo,
|
||||
Monaco,
|
||||
Consolas,
|
||||
Liberation Mono,
|
||||
Courier New,
|
||||
monospace;
|
||||
}
|
||||
svg {
|
||||
display: block;
|
||||
vertical-align: middle;
|
||||
shape-rendering: auto;
|
||||
text-rendering: optimizeLegibility;
|
||||
}
|
||||
pre {
|
||||
background-color: rgba(55, 65, 81, 1);
|
||||
border-radius: 0.25rem;
|
||||
color: rgba(229, 231, 235, 1);
|
||||
font-family:
|
||||
ui-monospace,
|
||||
SFMono-Regular,
|
||||
Menlo,
|
||||
Monaco,
|
||||
Consolas,
|
||||
Liberation Mono,
|
||||
Courier New,
|
||||
monospace;
|
||||
overflow: scroll;
|
||||
padding: 0.5rem 0.75rem;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
.shadow {
|
||||
box-shadow:
|
||||
0 0 #0000,
|
||||
0 0 #0000,
|
||||
0 10px 15px -3px rgba(0, 0, 0, 0.1),
|
||||
0 4px 6px -2px rgba(0, 0, 0, 0.05);
|
||||
html {
|
||||
-webkit-text-size-adjust: 100%;
|
||||
-webkit-font-smoothing: antialiased;
|
||||
-moz-osx-font-smoothing: grayscale;
|
||||
}
|
||||
.rounded {
|
||||
border-radius: 1.5rem;
|
||||
|
||||
body {
|
||||
min-height: 100vh;
|
||||
font-family: var(--font-sans);
|
||||
font-size: 14px;
|
||||
line-height: 1.5;
|
||||
color: var(--color-text);
|
||||
background: var(--color-bg);
|
||||
}
|
||||
.wrapper {
|
||||
width: 100%;
|
||||
|
||||
a {
|
||||
color: inherit;
|
||||
text-decoration: none;
|
||||
}
|
||||
.container {
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
max-width: 768px;
|
||||
padding-bottom: 3rem;
|
||||
padding-left: 1rem;
|
||||
padding-right: 1rem;
|
||||
color: rgba(55, 65, 81, 1);
|
||||
width: 100%;
|
||||
}
|
||||
#welcome {
|
||||
margin-top: 2.5rem;
|
||||
}
|
||||
#welcome h1 {
|
||||
font-size: 3rem;
|
||||
font-weight: 500;
|
||||
letter-spacing: -0.025em;
|
||||
line-height: 1;
|
||||
}
|
||||
#welcome span {
|
||||
display: block;
|
||||
font-size: 1.875rem;
|
||||
font-weight: 300;
|
||||
line-height: 2.25rem;
|
||||
margin-bottom: 0.5rem;
|
||||
}
|
||||
#hero {
|
||||
align-items: center;
|
||||
background-color: hsla(214, 62%, 21%, 1);
|
||||
border: none;
|
||||
box-sizing: border-box;
|
||||
color: rgba(55, 65, 81, 1);
|
||||
display: grid;
|
||||
grid-template-columns: 1fr;
|
||||
margin-top: 3.5rem;
|
||||
}
|
||||
#hero .text-container {
|
||||
color: rgba(255, 255, 255, 1);
|
||||
padding: 3rem 2rem;
|
||||
}
|
||||
#hero .text-container h2 {
|
||||
font-size: 1.5rem;
|
||||
line-height: 2rem;
|
||||
position: relative;
|
||||
}
|
||||
#hero .text-container h2 svg {
|
||||
color: hsla(162, 47%, 50%, 1);
|
||||
height: 2rem;
|
||||
left: -0.25rem;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
width: 2rem;
|
||||
}
|
||||
#hero .text-container h2 span {
|
||||
margin-left: 2.5rem;
|
||||
}
|
||||
#hero .text-container a {
|
||||
background-color: rgba(255, 255, 255, 1);
|
||||
border-radius: 0.75rem;
|
||||
color: rgba(55, 65, 81, 1);
|
||||
display: inline-block;
|
||||
margin-top: 1.5rem;
|
||||
padding: 1rem 2rem;
|
||||
text-decoration: inherit;
|
||||
}
|
||||
#hero .logo-container {
|
||||
display: none;
|
||||
justify-content: center;
|
||||
padding-left: 2rem;
|
||||
padding-right: 2rem;
|
||||
}
|
||||
#hero .logo-container svg {
|
||||
color: rgba(255, 255, 255, 1);
|
||||
width: 66.666667%;
|
||||
}
|
||||
#middle-content {
|
||||
align-items: flex-start;
|
||||
display: grid;
|
||||
gap: 4rem;
|
||||
grid-template-columns: 1fr;
|
||||
margin-top: 3.5rem;
|
||||
}
|
||||
#learning-materials {
|
||||
padding: 2.5rem 2rem;
|
||||
}
|
||||
#learning-materials h2 {
|
||||
font-weight: 500;
|
||||
font-size: 1.25rem;
|
||||
letter-spacing: -0.025em;
|
||||
line-height: 1.75rem;
|
||||
padding-left: 1rem;
|
||||
padding-right: 1rem;
|
||||
}
|
||||
.list-item-link {
|
||||
align-items: center;
|
||||
border-radius: 0.75rem;
|
||||
display: flex;
|
||||
margin-top: 1rem;
|
||||
padding: 1rem;
|
||||
transition-property:
|
||||
background-color,
|
||||
border-color,
|
||||
color,
|
||||
fill,
|
||||
stroke,
|
||||
opacity,
|
||||
box-shadow,
|
||||
transform,
|
||||
filter,
|
||||
backdrop-filter,
|
||||
-webkit-backdrop-filter;
|
||||
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||
transition-duration: 150ms;
|
||||
width: 100%;
|
||||
}
|
||||
.list-item-link svg:first-child {
|
||||
margin-right: 1rem;
|
||||
height: 1.5rem;
|
||||
transition-property:
|
||||
background-color,
|
||||
border-color,
|
||||
color,
|
||||
fill,
|
||||
stroke,
|
||||
opacity,
|
||||
box-shadow,
|
||||
transform,
|
||||
filter,
|
||||
backdrop-filter,
|
||||
-webkit-backdrop-filter;
|
||||
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||
transition-duration: 150ms;
|
||||
width: 1.5rem;
|
||||
}
|
||||
.list-item-link > span {
|
||||
flex-grow: 1;
|
||||
font-weight: 400;
|
||||
transition-property:
|
||||
background-color,
|
||||
border-color,
|
||||
color,
|
||||
fill,
|
||||
stroke,
|
||||
opacity,
|
||||
box-shadow,
|
||||
transform,
|
||||
filter,
|
||||
backdrop-filter,
|
||||
-webkit-backdrop-filter;
|
||||
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||
transition-duration: 150ms;
|
||||
}
|
||||
.list-item-link > span > span {
|
||||
color: rgba(107, 114, 128, 1);
|
||||
display: block;
|
||||
flex-grow: 1;
|
||||
font-size: 0.75rem;
|
||||
font-weight: 300;
|
||||
line-height: 1rem;
|
||||
transition-property:
|
||||
background-color,
|
||||
border-color,
|
||||
color,
|
||||
fill,
|
||||
stroke,
|
||||
opacity,
|
||||
box-shadow,
|
||||
transform,
|
||||
filter,
|
||||
backdrop-filter,
|
||||
-webkit-backdrop-filter;
|
||||
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||
transition-duration: 150ms;
|
||||
}
|
||||
.list-item-link svg:last-child {
|
||||
height: 1rem;
|
||||
transition-property: all;
|
||||
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||
transition-duration: 150ms;
|
||||
width: 1rem;
|
||||
}
|
||||
.list-item-link:hover {
|
||||
color: rgba(255, 255, 255, 1);
|
||||
background-color: hsla(162, 47%, 50%, 1);
|
||||
}
|
||||
.list-item-link:hover > span {
|
||||
}
|
||||
.list-item-link:hover > span > span {
|
||||
color: rgba(243, 244, 246, 1);
|
||||
}
|
||||
.list-item-link:hover svg:last-child {
|
||||
transform: translateX(0.25rem);
|
||||
}
|
||||
#other-links {
|
||||
}
|
||||
.button-pill {
|
||||
padding: 1.5rem 2rem;
|
||||
transition-duration: 300ms;
|
||||
transition-property:
|
||||
background-color,
|
||||
border-color,
|
||||
color,
|
||||
fill,
|
||||
stroke,
|
||||
opacity,
|
||||
box-shadow,
|
||||
transform,
|
||||
filter,
|
||||
backdrop-filter,
|
||||
-webkit-backdrop-filter;
|
||||
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||
align-items: center;
|
||||
display: flex;
|
||||
}
|
||||
.button-pill svg {
|
||||
transition-property:
|
||||
background-color,
|
||||
border-color,
|
||||
color,
|
||||
fill,
|
||||
stroke,
|
||||
opacity,
|
||||
box-shadow,
|
||||
transform,
|
||||
filter,
|
||||
backdrop-filter,
|
||||
-webkit-backdrop-filter;
|
||||
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||
transition-duration: 150ms;
|
||||
flex-shrink: 0;
|
||||
width: 3rem;
|
||||
}
|
||||
.button-pill > span {
|
||||
letter-spacing: -0.025em;
|
||||
font-weight: 400;
|
||||
font-size: 1.125rem;
|
||||
line-height: 1.75rem;
|
||||
padding-left: 1rem;
|
||||
padding-right: 1rem;
|
||||
}
|
||||
.button-pill span span {
|
||||
display: block;
|
||||
font-size: 0.875rem;
|
||||
font-weight: 300;
|
||||
line-height: 1.25rem;
|
||||
}
|
||||
.button-pill:hover svg,
|
||||
.button-pill:hover {
|
||||
color: rgba(255, 255, 255, 1) !important;
|
||||
}
|
||||
#nx-console:hover {
|
||||
background-color: rgba(0, 122, 204, 1);
|
||||
}
|
||||
#nx-console svg {
|
||||
color: rgba(0, 122, 204, 1);
|
||||
}
|
||||
#nx-console-jetbrains {
|
||||
margin-top: 2rem;
|
||||
}
|
||||
#nx-console-jetbrains:hover {
|
||||
background-color: rgba(255, 49, 140, 1);
|
||||
}
|
||||
#nx-console-jetbrains svg {
|
||||
color: rgba(255, 49, 140, 1);
|
||||
}
|
||||
#nx-repo:hover {
|
||||
background-color: rgba(24, 23, 23, 1);
|
||||
}
|
||||
#nx-repo svg {
|
||||
color: rgba(24, 23, 23, 1);
|
||||
}
|
||||
#nx-cloud {
|
||||
margin-bottom: 2rem;
|
||||
margin-top: 2rem;
|
||||
padding: 2.5rem 2rem;
|
||||
}
|
||||
#nx-cloud > div {
|
||||
align-items: center;
|
||||
display: flex;
|
||||
}
|
||||
#nx-cloud > div svg {
|
||||
border-radius: 0.375rem;
|
||||
flex-shrink: 0;
|
||||
width: 3rem;
|
||||
}
|
||||
#nx-cloud > div h2 {
|
||||
font-size: 1.125rem;
|
||||
font-weight: 400;
|
||||
letter-spacing: -0.025em;
|
||||
line-height: 1.75rem;
|
||||
padding-left: 1rem;
|
||||
padding-right: 1rem;
|
||||
}
|
||||
#nx-cloud > div h2 span {
|
||||
display: block;
|
||||
font-size: 0.875rem;
|
||||
font-weight: 300;
|
||||
line-height: 1.25rem;
|
||||
}
|
||||
#nx-cloud p {
|
||||
font-size: 1rem;
|
||||
line-height: 1.5rem;
|
||||
margin-top: 1rem;
|
||||
}
|
||||
#nx-cloud pre {
|
||||
margin-top: 1rem;
|
||||
}
|
||||
#nx-cloud a {
|
||||
color: rgba(107, 114, 128, 1);
|
||||
display: block;
|
||||
font-size: 0.875rem;
|
||||
line-height: 1.25rem;
|
||||
margin-top: 1.5rem;
|
||||
text-align: right;
|
||||
}
|
||||
#nx-cloud a:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
#commands {
|
||||
padding: 2.5rem 2rem;
|
||||
margin-top: 3.5rem;
|
||||
}
|
||||
#commands h2 {
|
||||
font-size: 1.25rem;
|
||||
font-weight: 400;
|
||||
letter-spacing: -0.025em;
|
||||
line-height: 1.75rem;
|
||||
padding-left: 1rem;
|
||||
padding-right: 1rem;
|
||||
}
|
||||
#commands p {
|
||||
font-size: 1rem;
|
||||
font-weight: 300;
|
||||
line-height: 1.5rem;
|
||||
margin-top: 1rem;
|
||||
padding-left: 1rem;
|
||||
padding-right: 1rem;
|
||||
}
|
||||
details {
|
||||
align-items: center;
|
||||
display: flex;
|
||||
margin-top: 1rem;
|
||||
padding-left: 1rem;
|
||||
padding-right: 1rem;
|
||||
width: 100%;
|
||||
}
|
||||
details pre > span {
|
||||
color: rgba(181, 181, 181, 1);
|
||||
|
||||
img {
|
||||
max-width: 100%;
|
||||
display: block;
|
||||
}
|
||||
summary {
|
||||
border-radius: 0.5rem;
|
||||
display: flex;
|
||||
font-weight: 400;
|
||||
padding: 0.5rem;
|
||||
|
||||
button {
|
||||
font-family: inherit;
|
||||
cursor: pointer;
|
||||
transition-property:
|
||||
background-color,
|
||||
border-color,
|
||||
color,
|
||||
fill,
|
||||
stroke,
|
||||
opacity,
|
||||
box-shadow,
|
||||
transform,
|
||||
filter,
|
||||
backdrop-filter,
|
||||
-webkit-backdrop-filter;
|
||||
transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
|
||||
transition-duration: 150ms;
|
||||
}
|
||||
summary:hover {
|
||||
background-color: rgba(243, 244, 246, 1);
|
||||
}
|
||||
summary svg {
|
||||
height: 1.5rem;
|
||||
margin-right: 1rem;
|
||||
width: 1.5rem;
|
||||
}
|
||||
#love {
|
||||
color: rgba(107, 114, 128, 1);
|
||||
font-size: 0.875rem;
|
||||
line-height: 1.25rem;
|
||||
margin-top: 3.5rem;
|
||||
opacity: 0.6;
|
||||
text-align: center;
|
||||
}
|
||||
#love svg {
|
||||
color: rgba(252, 165, 165, 1);
|
||||
width: 1.25rem;
|
||||
height: 1.25rem;
|
||||
display: inline;
|
||||
margin-top: -0.25rem;
|
||||
}
|
||||
@media screen and (min-width: 768px) {
|
||||
#hero {
|
||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
}
|
||||
#hero .logo-container {
|
||||
display: flex;
|
||||
}
|
||||
#middle-content {
|
||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
|
||||
input,
|
||||
textarea,
|
||||
select {
|
||||
font-family: inherit;
|
||||
font-size: inherit;
|
||||
}
|
||||
|
||||
/* Design Tokens */
|
||||
:root {
|
||||
/* Orange */
|
||||
--color-orange-50: #fff3e0;
|
||||
--color-orange-100: #ffe0b2;
|
||||
--color-orange-200: #ffcc80;
|
||||
--color-orange-400: #ffa726;
|
||||
--color-orange-500: #e8600a;
|
||||
--color-orange-600: #d4560a;
|
||||
--color-orange-700: #bf4d09;
|
||||
--color-orange-800: #993e07;
|
||||
--color-orange-900: #733006;
|
||||
|
||||
/* Navy */
|
||||
--color-navy-50: #e8eaf6;
|
||||
--color-navy-100: #c5cae9;
|
||||
--color-navy-200: #9fa8da;
|
||||
--color-navy-300: #7986cb;
|
||||
--color-navy-400: #5c6bc0;
|
||||
--color-navy-500: #1a237e;
|
||||
--color-navy-600: #151b6b;
|
||||
--color-navy-700: #101358;
|
||||
--color-navy-800: #0b0d45;
|
||||
--color-navy-900: #060732;
|
||||
|
||||
/* Teal */
|
||||
--color-teal-50: #e0f2f1;
|
||||
--color-teal-100: #b2dfdb;
|
||||
--color-teal-200: #80cbc4;
|
||||
--color-teal-300: #4db6ac;
|
||||
--color-teal-400: #26a69a;
|
||||
--color-teal-500: #00695c;
|
||||
|
||||
/* Slate */
|
||||
--color-slate-50: #f8fafc;
|
||||
--color-slate-100: #f1f5f9;
|
||||
--color-slate-200: #e2e8f0;
|
||||
--color-slate-300: #cbd5e1;
|
||||
--color-slate-400: #94a3b8;
|
||||
--color-slate-500: #64748b;
|
||||
--color-slate-600: #475569;
|
||||
--color-slate-700: #334155;
|
||||
--color-slate-800: #1e293b;
|
||||
--color-slate-900: #0f172a;
|
||||
|
||||
/* Semantic */
|
||||
--color-primary: var(--color-orange-500);
|
||||
--color-primary-hover: var(--color-orange-600);
|
||||
--color-bg: var(--color-slate-50);
|
||||
--color-surface: #ffffff;
|
||||
--color-text: var(--color-slate-800);
|
||||
--color-text-muted: var(--color-slate-500);
|
||||
--color-border: var(--color-slate-200);
|
||||
|
||||
/* Spacing */
|
||||
--space-xs: 4px;
|
||||
--space-sm: 8px;
|
||||
--space-md: 16px;
|
||||
--space-lg: 24px;
|
||||
--space-xl: 32px;
|
||||
--space-2xl: 48px;
|
||||
|
||||
/* Typography */
|
||||
--font-sans: -apple-system, 'Segoe UI', Arial, sans-serif;
|
||||
--font-mono: ui-monospace, SFMono-Regular, Menlo, monospace;
|
||||
|
||||
/* Layout */
|
||||
--max-width: 1280px;
|
||||
--header-height: 120px;
|
||||
|
||||
/* Border radius */
|
||||
--border-radius-sm: 6px;
|
||||
--border-radius-md: 10px;
|
||||
--border-radius-lg: 12px;
|
||||
--border-radius-xl: 16px;
|
||||
}
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
import './global.css';
|
||||
import { Header } from '@/components/Header/Header';
|
||||
import { Footer } from '@/components/Footer/Footer';
|
||||
import { CartProvider } from '@/components/CartProvider/CartProvider';
|
||||
|
||||
export const metadata = {
|
||||
title: 'Welcome to web',
|
||||
description: 'Generated by create-nx-workspace',
|
||||
title: 'PAN-PROM | Промышленное оборудование из Европы',
|
||||
description:
|
||||
'Гидравлика, пневматика, АСУ, запасные части. Прямые поставки оригинальных комплектующих от ведущих европейских производителей.',
|
||||
};
|
||||
|
||||
export default function RootLayout({
|
||||
@@ -11,8 +15,14 @@ export default function RootLayout({
|
||||
children: React.ReactNode;
|
||||
}) {
|
||||
return (
|
||||
<html lang="en">
|
||||
<body>{children}</body>
|
||||
<html lang="ru">
|
||||
<body>
|
||||
<CartProvider>
|
||||
<Header />
|
||||
<main>{children}</main>
|
||||
<Footer />
|
||||
</CartProvider>
|
||||
</body>
|
||||
</html>
|
||||
);
|
||||
}
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
.page {
|
||||
}
|
||||
/* Home page styles — currently handled by section components */
|
||||
|
||||
@@ -1,469 +1,15 @@
|
||||
import styles from './page.module.scss';
|
||||
import { Hero } from '@/components/Hero/Hero';
|
||||
import { Directions } from '@/components/Directions/Directions';
|
||||
import { TrustStrip } from '@/components/TrustStrip/TrustStrip';
|
||||
import { BrandLogos } from '@/components/BrandLogos/BrandLogos';
|
||||
|
||||
export default function Index() {
|
||||
/*
|
||||
* Replace the elements below with your own.
|
||||
*
|
||||
* Note: The corresponding styles are in the ./index.scss file.
|
||||
*/
|
||||
export default function HomePage() {
|
||||
return (
|
||||
<div className={styles.page}>
|
||||
<div className="wrapper">
|
||||
<div className="container">
|
||||
<div id="welcome">
|
||||
<h1>
|
||||
<span> Hello there, </span>
|
||||
Welcome @my-monorepo/web 👋
|
||||
</h1>
|
||||
</div>
|
||||
|
||||
<div id="hero" className="rounded">
|
||||
<div className="text-container">
|
||||
<h2>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M9 12l2 2 4-4M7.835 4.697a3.42 3.42 0 001.946-.806 3.42 3.42 0 014.438 0 3.42 3.42 0 001.946.806 3.42 3.42 0 013.138 3.138 3.42 3.42 0 00.806 1.946 3.42 3.42 0 010 4.438 3.42 3.42 0 00-.806 1.946 3.42 3.42 0 01-3.138 3.138 3.42 3.42 0 00-1.946.806 3.42 3.42 0 01-4.438 0 3.42 3.42 0 00-1.946-.806 3.42 3.42 0 01-3.138-3.138 3.42 3.42 0 00-.806-1.946 3.42 3.42 0 010-4.438 3.42 3.42 0 00.806-1.946 3.42 3.42 0 013.138-3.138z"
|
||||
/>
|
||||
</svg>
|
||||
<span>You're up and running</span>
|
||||
</h2>
|
||||
<a href="#commands"> What's next? </a>
|
||||
</div>
|
||||
<div className="logo-container">
|
||||
<svg
|
||||
fill="currentColor"
|
||||
role="img"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path d="M11.987 14.138l-3.132 4.923-5.193-8.427-.012 8.822H0V4.544h3.691l5.247 8.833.005-3.998 3.044 4.759zm.601-5.761c.024-.048 0-3.784.008-3.833h-3.65c.002.059-.005 3.776-.003 3.833h3.645zm5.634 4.134a2.061 2.061 0 0 0-1.969 1.336 1.963 1.963 0 0 1 2.343-.739c.396.161.917.422 1.33.283a2.1 2.1 0 0 0-1.704-.88zm3.39 1.061c-.375-.13-.8-.277-1.109-.681-.06-.08-.116-.17-.176-.265a2.143 2.143 0 0 0-.533-.642c-.294-.216-.68-.322-1.18-.322a2.482 2.482 0 0 0-2.294 1.536 2.325 2.325 0 0 1 4.002.388.75.75 0 0 0 .836.334c.493-.105.46.36 1.203.518v-.133c-.003-.446-.246-.55-.75-.733zm2.024 1.266a.723.723 0 0 0 .347-.638c-.01-2.957-2.41-5.487-5.37-5.487a5.364 5.364 0 0 0-4.487 2.418c-.01-.026-1.522-2.39-1.538-2.418H8.943l3.463 5.423-3.379 5.32h3.54l1.54-2.366 1.568 2.366h3.541l-3.21-5.052a.7.7 0 0 1-.084-.32 2.69 2.69 0 0 1 2.69-2.691h.001c1.488 0 1.736.89 2.057 1.308.634.826 1.9.464 1.9 1.541a.707.707 0 0 0 1.066.596zm.35.133c-.173.372-.56.338-.755.639-.176.271.114.412.114.412s.337.156.538-.311c.104-.231.14-.488.103-.74z" />
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="middle-content">
|
||||
<div id="learning-materials" className="rounded shadow">
|
||||
<h2>Learning materials</h2>
|
||||
<a
|
||||
href="https://nx.dev/getting-started/intro?utm_source=nx-project"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className="list-item-link"
|
||||
>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M12 6.253v13m0-13C10.832 5.477 9.246 5 7.5 5S4.168 5.477 3 6.253v13C4.168 18.477 5.754 18 7.5 18s3.332.477 4.5 1.253m0-13C13.168 5.477 14.754 5 16.5 5c1.747 0 3.332.477 4.5 1.253v13C19.832 18.477 18.247 18 16.5 18c-1.746 0-3.332.477-4.5 1.253"
|
||||
/>
|
||||
</svg>
|
||||
<span>
|
||||
Documentation
|
||||
<span> Everything is in there </span>
|
||||
</span>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M9 5l7 7-7 7"
|
||||
/>
|
||||
</svg>
|
||||
</a>
|
||||
<a
|
||||
href="https://nx.dev/blog/?utm_source=nx-project"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className="list-item-link"
|
||||
>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M19 20H5a2 2 0 01-2-2V6a2 2 0 012-2h10a2 2 0 012 2v1m2 13a2 2 0 01-2-2V7m2 13a2 2 0 002-2V9a2 2 0 00-2-2h-2m-4-3H9M7 16h6M7 8h6v4H7V8z"
|
||||
/>
|
||||
</svg>
|
||||
<span>
|
||||
Blog
|
||||
<span> Changelog, features & events </span>
|
||||
</span>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M9 5l7 7-7 7"
|
||||
/>
|
||||
</svg>
|
||||
</a>
|
||||
<a
|
||||
href="https://www.youtube.com/@NxDevtools/videos?utm_source=nx-project&sub_confirmation=1"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className="list-item-link"
|
||||
>
|
||||
<svg
|
||||
role="img"
|
||||
viewBox="0 0 24 24"
|
||||
fill="currentColor"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<title>YouTube</title>
|
||||
<path d="M23.498 6.186a3.016 3.016 0 0 0-2.122-2.136C19.505 3.545 12 3.545 12 3.545s-7.505 0-9.377.505A3.017 3.017 0 0 0 .502 6.186C0 8.07 0 12 0 12s0 3.93.502 5.814a3.016 3.016 0 0 0 2.122 2.136c1.871.505 9.376.505 9.376.505s7.505 0 9.377-.505a3.015 3.015 0 0 0 2.122-2.136C24 15.93 24 12 24 12s0-3.93-.502-5.814zM9.545 15.568V8.432L15.818 12l-6.273 3.568z" />
|
||||
</svg>
|
||||
<span>
|
||||
YouTube channel
|
||||
<span> Nx Show, talks & tutorials </span>
|
||||
</span>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M9 5l7 7-7 7"
|
||||
/>
|
||||
</svg>
|
||||
</a>
|
||||
<a
|
||||
href="https://nx.dev/react-tutorial/1-code-generation?utm_source=nx-project"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className="list-item-link"
|
||||
>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M15 15l-2 5L9 9l11 4-5 2zm0 0l5 5M7.188 2.239l.777 2.897M5.136 7.965l-2.898-.777M13.95 4.05l-2.122 2.122m-5.657 5.656l-2.12 2.122"
|
||||
/>
|
||||
</svg>
|
||||
<span>
|
||||
Interactive tutorials
|
||||
<span> Create an app, step-by-step </span>
|
||||
</span>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M9 5l7 7-7 7"
|
||||
/>
|
||||
</svg>
|
||||
</a>
|
||||
<a
|
||||
href="https://nxplaybook.com/?utm_source=nx-project"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
className="list-item-link"
|
||||
>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path d="M12 14l9-5-9-5-9 5 9 5z" />
|
||||
<path d="M12 14l6.16-3.422a12.083 12.083 0 01.665 6.479A11.952 11.952 0 0012 20.055a11.952 11.952 0 00-6.824-2.998 12.078 12.078 0 01.665-6.479L12 14z" />
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M12 14l9-5-9-5-9 5 9 5zm0 0l6.16-3.422a12.083 12.083 0 01.665 6.479A11.952 11.952 0 0012 20.055a11.952 11.952 0 00-6.824-2.998 12.078 12.078 0 01.665-6.479L12 14zm-4 6v-7.5l4-2.222"
|
||||
/>
|
||||
</svg>
|
||||
<span>
|
||||
Video courses
|
||||
<span> Nx custom courses </span>
|
||||
</span>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M9 5l7 7-7 7"
|
||||
/>
|
||||
</svg>
|
||||
</a>
|
||||
</div>
|
||||
<div id="other-links">
|
||||
<a
|
||||
id="nx-console"
|
||||
className="button-pill rounded shadow"
|
||||
href="https://marketplace.visualstudio.com/items?itemName=nrwl.angular-console&utm_source=nx-project"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
>
|
||||
<svg
|
||||
fill="currentColor"
|
||||
role="img"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<title>Visual Studio Code</title>
|
||||
<path d="M23.15 2.587L18.21.21a1.494 1.494 0 0 0-1.705.29l-9.46 8.63-4.12-3.128a.999.999 0 0 0-1.276.057L.327 7.261A1 1 0 0 0 .326 8.74L3.899 12 .326 15.26a1 1 0 0 0 .001 1.479L1.65 17.94a.999.999 0 0 0 1.276.057l4.12-3.128 9.46 8.63a1.492 1.492 0 0 0 1.704.29l4.942-2.377A1.5 1.5 0 0 0 24 20.06V3.939a1.5 1.5 0 0 0-.85-1.352zm-5.146 14.861L10.826 12l7.178-5.448v10.896z" />
|
||||
</svg>
|
||||
<span>
|
||||
Install Nx Console for VSCode
|
||||
<span>The official VSCode extension for Nx.</span>
|
||||
</span>
|
||||
</a>
|
||||
<a
|
||||
id="nx-console-jetbrains"
|
||||
className="button-pill rounded shadow"
|
||||
href="https://plugins.jetbrains.com/plugin/21060-nx-console"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
>
|
||||
<svg
|
||||
height="48"
|
||||
width="48"
|
||||
viewBox="20 20 60 60"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path d="m22.5 22.5h60v60h-60z" />
|
||||
<g fill="#fff">
|
||||
<path d="m29.03 71.25h22.5v3.75h-22.5z" />
|
||||
<path d="m28.09 38 1.67-1.58a1.88 1.88 0 0 0 1.47.87c.64 0 1.06-.44 1.06-1.31v-5.98h2.58v6a3.48 3.48 0 0 1 -.87 2.6 3.56 3.56 0 0 1 -2.57.95 3.84 3.84 0 0 1 -3.34-1.55z" />
|
||||
<path d="m36 30h7.53v2.19h-5v1.44h4.49v2h-4.42v1.49h5v2.21h-7.6z" />
|
||||
<path d="m47.23 32.29h-2.8v-2.29h8.21v2.27h-2.81v7.1h-2.6z" />
|
||||
<path d="m29.13 43.08h4.42a3.53 3.53 0 0 1 2.55.83 2.09 2.09 0 0 1 .6 1.53 2.16 2.16 0 0 1 -1.44 2.09 2.27 2.27 0 0 1 1.86 2.29c0 1.61-1.31 2.59-3.55 2.59h-4.44zm5 2.89c0-.52-.42-.8-1.18-.8h-1.29v1.64h1.24c.79 0 1.25-.26 1.25-.81zm-.9 2.66h-1.57v1.73h1.62c.8 0 1.24-.31 1.24-.86 0-.5-.4-.87-1.27-.87z" />
|
||||
<path d="m38 43.08h4.1a4.19 4.19 0 0 1 3 1 2.93 2.93 0 0 1 .9 2.19 3 3 0 0 1 -1.93 2.89l2.24 3.27h-3l-1.88-2.84h-.87v2.84h-2.56zm4 4.5c.87 0 1.39-.43 1.39-1.11 0-.75-.54-1.12-1.4-1.12h-1.44v2.26z" />
|
||||
<path d="m49.59 43h2.5l4 9.44h-2.79l-.67-1.69h-3.63l-.67 1.69h-2.71zm2.27 5.73-1-2.65-1.06 2.65z" />
|
||||
<path d="m56.46 43.05h2.6v9.37h-2.6z" />
|
||||
<path d="m60.06 43.05h2.42l3.37 5v-5h2.57v9.37h-2.26l-3.53-5.14v5.14h-2.57z" />
|
||||
<path d="m68.86 51 1.45-1.73a4.84 4.84 0 0 0 3 1.13c.71 0 1.08-.24 1.08-.65 0-.4-.31-.6-1.59-.91-2-.46-3.53-1-3.53-2.93 0-1.74 1.37-3 3.62-3a5.89 5.89 0 0 1 3.86 1.25l-1.26 1.84a4.63 4.63 0 0 0 -2.62-.92c-.63 0-.94.25-.94.6 0 .42.32.61 1.63.91 2.14.46 3.44 1.16 3.44 2.91 0 1.91-1.51 3-3.79 3a6.58 6.58 0 0 1 -4.35-1.5z" />
|
||||
</g>
|
||||
</svg>
|
||||
<span>
|
||||
Install Nx Console for JetBrains
|
||||
<span>
|
||||
Available for WebStorm, Intellij IDEA Ultimate and more!
|
||||
</span>
|
||||
</span>
|
||||
</a>
|
||||
<div id="nx-cloud" className="rounded shadow">
|
||||
<div>
|
||||
<svg
|
||||
id="nx-cloud-logo"
|
||||
role="img"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
stroke="currentColor"
|
||||
fill="transparent"
|
||||
viewBox="0 0 24 24"
|
||||
>
|
||||
<path
|
||||
strokeWidth="2"
|
||||
d="M23 3.75V6.5c-3.036 0-5.5 2.464-5.5 5.5s-2.464 5.5-5.5 5.5-5.5 2.464-5.5 5.5H3.75C2.232 23 1 21.768 1 20.25V3.75C1 2.232 2.232 1 3.75 1h16.5C21.768 1 23 2.232 23 3.75Z"
|
||||
/>
|
||||
<path
|
||||
strokeWidth="2"
|
||||
d="M23 6v14.1667C23 21.7307 21.7307 23 20.1667 23H6c0-3.128 2.53867-5.6667 5.6667-5.6667 3.128 0 5.6666-2.5386 5.6666-5.6666C17.3333 8.53867 19.872 6 23 6Z"
|
||||
/>
|
||||
</svg>
|
||||
<h2>
|
||||
Nx Cloud
|
||||
<span>Enable faster CI & better DX</span>
|
||||
</h2>
|
||||
</div>
|
||||
<p>
|
||||
You can activate distributed tasks executions and caching by
|
||||
running:
|
||||
</p>
|
||||
<pre>nx connect</pre>
|
||||
<a
|
||||
href="https://nx.app/?utm_source=nx-project"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
>
|
||||
{' '}
|
||||
What is Nx Cloud?{' '}
|
||||
</a>
|
||||
</div>
|
||||
<a
|
||||
id="nx-repo"
|
||||
className="button-pill rounded shadow"
|
||||
href="https://github.com/nrwl/nx?utm_source=nx-project"
|
||||
target="_blank"
|
||||
rel="noreferrer"
|
||||
>
|
||||
<svg
|
||||
fill="currentColor"
|
||||
role="img"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12" />
|
||||
</svg>
|
||||
<span>
|
||||
Nx is open source
|
||||
<span> Love Nx? Give us a star! </span>
|
||||
</span>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="commands" className="rounded shadow">
|
||||
<h2>Next steps</h2>
|
||||
<p>Here are some things you can do with Nx:</p>
|
||||
<details>
|
||||
<summary>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M8 9l3 3-3 3m5 0h3M5 20h14a2 2 0 002-2V6a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"
|
||||
/>
|
||||
</svg>
|
||||
Add UI library
|
||||
</summary>
|
||||
<pre>
|
||||
<span># Generate UI lib</span>
|
||||
nx g @nx/next:library ui
|
||||
<span># Add a component</span>
|
||||
nx g @nx/next:component ui/src/lib/button
|
||||
</pre>
|
||||
</details>
|
||||
<details>
|
||||
<summary>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M8 9l3 3-3 3m5 0h3M5 20h14a2 2 0 002-2V6a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"
|
||||
/>
|
||||
</svg>
|
||||
View project details
|
||||
</summary>
|
||||
<pre>nx show project @my-monorepo/web --web</pre>
|
||||
</details>
|
||||
<details>
|
||||
<summary>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M8 9l3 3-3 3m5 0h3M5 20h14a2 2 0 002-2V6a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"
|
||||
/>
|
||||
</svg>
|
||||
View interactive project graph
|
||||
</summary>
|
||||
<pre>nx graph</pre>
|
||||
</details>
|
||||
<details>
|
||||
<summary>
|
||||
<svg
|
||||
fill="none"
|
||||
stroke="currentColor"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M8 9l3 3-3 3m5 0h3M5 20h14a2 2 0 002-2V6a2 2 0 00-2-2H5a2 2 0 00-2 2v12a2 2 0 002 2z"
|
||||
/>
|
||||
</svg>
|
||||
Run affected commands
|
||||
</summary>
|
||||
<pre>
|
||||
<span># see what's been affected by changes</span>
|
||||
nx affected:graph
|
||||
<span># run tests for current changes</span>
|
||||
nx affected:test
|
||||
<span># run e2e tests for current changes</span>
|
||||
nx affected:e2e
|
||||
</pre>
|
||||
</details>
|
||||
</div>
|
||||
|
||||
<p id="love">
|
||||
Carefully crafted with
|
||||
<svg
|
||||
fill="currentColor"
|
||||
stroke="none"
|
||||
viewBox="0 0 24 24"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
strokeWidth="2"
|
||||
d="M4.318 6.318a4.5 4.5 0 000 6.364L12 20.364l7.682-7.682a4.5 4.5 0 00-6.364-6.364L12 7.636l-1.318-1.318a4.5 4.5 0 00-6.364 0z"
|
||||
/>
|
||||
</svg>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<>
|
||||
<Hero />
|
||||
<Directions />
|
||||
<TrustStrip />
|
||||
<BrandLogos />
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
105
apps/web/src/app/product/[sku]/page.module.scss
Normal file
105
apps/web/src/app/product/[sku]/page.module.scss
Normal file
@@ -0,0 +1,105 @@
|
||||
.container {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
padding: var(--space-lg);
|
||||
}
|
||||
|
||||
.layout {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: var(--space-xl);
|
||||
margin-top: var(--space-lg);
|
||||
|
||||
@media (max-width: 768px) {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
.imageArea {
|
||||
background: var(--color-slate-50);
|
||||
border-radius: var(--border-radius-lg);
|
||||
border: 1px solid var(--color-border);
|
||||
aspect-ratio: 1;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.imagePlaceholder {
|
||||
width: 120px;
|
||||
height: 120px;
|
||||
background: var(--color-slate-200);
|
||||
border-radius: var(--border-radius-md);
|
||||
}
|
||||
|
||||
.details {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-md);
|
||||
}
|
||||
|
||||
.brand {
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: var(--color-text-muted);
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 1px;
|
||||
}
|
||||
|
||||
.name {
|
||||
font-size: 28px;
|
||||
font-weight: 700;
|
||||
color: var(--color-slate-900);
|
||||
line-height: 1.2;
|
||||
}
|
||||
|
||||
.sku {
|
||||
font-size: 14px;
|
||||
color: var(--color-slate-500);
|
||||
|
||||
span {
|
||||
font-family: var(--font-mono);
|
||||
color: var(--color-orange-500);
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
|
||||
.meta {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 8px;
|
||||
padding: var(--space-md) 0;
|
||||
border-top: 1px solid var(--color-border);
|
||||
border-bottom: 1px solid var(--color-border);
|
||||
}
|
||||
|
||||
.metaItem {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
.metaLabel {
|
||||
color: var(--color-slate-400);
|
||||
}
|
||||
|
||||
.inStock {
|
||||
color: var(--color-teal-500);
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.outOfStock {
|
||||
color: var(--color-slate-400);
|
||||
}
|
||||
|
||||
.price {
|
||||
font-size: 22px;
|
||||
font-weight: 700;
|
||||
color: var(--color-navy-500);
|
||||
}
|
||||
|
||||
.actions {
|
||||
display: flex;
|
||||
gap: 12px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
45
apps/web/src/app/product/[sku]/page.tsx
Normal file
45
apps/web/src/app/product/[sku]/page.tsx
Normal file
@@ -0,0 +1,45 @@
|
||||
import { notFound } from 'next/navigation';
|
||||
import { products } from '@/data/products';
|
||||
import { Breadcrumb } from '@/components/Breadcrumb/Breadcrumb';
|
||||
import { ProductDetail } from '@/components/ProductDetail/ProductDetail';
|
||||
import styles from './page.module.scss';
|
||||
|
||||
export function generateStaticParams() {
|
||||
return products.map((p) => ({ sku: encodeURIComponent(p.sku) }));
|
||||
}
|
||||
|
||||
export async function generateMetadata({
|
||||
params,
|
||||
}: {
|
||||
params: Promise<{ sku: string }>;
|
||||
}) {
|
||||
const { sku } = await params;
|
||||
const product = products.find((p) => p.sku === decodeURIComponent(sku));
|
||||
return {
|
||||
title: product ? `${product.name} | PAN-PROM` : 'Продукт | PAN-PROM',
|
||||
};
|
||||
}
|
||||
|
||||
export default async function ProductPage({
|
||||
params,
|
||||
}: {
|
||||
params: Promise<{ sku: string }>;
|
||||
}) {
|
||||
const { sku } = await params;
|
||||
const product = products.find((p) => p.sku === decodeURIComponent(sku));
|
||||
|
||||
if (!product) notFound();
|
||||
|
||||
return (
|
||||
<div className={styles.container}>
|
||||
<Breadcrumb
|
||||
items={[
|
||||
{ label: 'Главная', href: '/' },
|
||||
{ label: 'Каталог', href: '/catalog' },
|
||||
{ label: product.name },
|
||||
]}
|
||||
/>
|
||||
<ProductDetail product={product} />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
90
apps/web/src/app/rfq/page.module.scss
Normal file
90
apps/web/src/app/rfq/page.module.scss
Normal file
@@ -0,0 +1,90 @@
|
||||
.container {
|
||||
max-width: 720px;
|
||||
margin: 0 auto;
|
||||
padding: var(--space-lg);
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 28px;
|
||||
font-weight: 700;
|
||||
color: var(--color-slate-900);
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
.subtitle {
|
||||
color: var(--color-text-muted);
|
||||
font-size: 15px;
|
||||
margin-bottom: var(--space-xl);
|
||||
}
|
||||
|
||||
.form {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-md);
|
||||
}
|
||||
|
||||
.row {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: var(--space-md);
|
||||
|
||||
@media (max-width: 640px) {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
.field {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
.label {
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: var(--color-slate-700);
|
||||
}
|
||||
|
||||
.input {
|
||||
padding: 10px 14px;
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-sm);
|
||||
font-size: 14px;
|
||||
outline: none;
|
||||
transition: border-color 0.2s;
|
||||
|
||||
&:focus {
|
||||
border-color: var(--color-orange-500);
|
||||
}
|
||||
}
|
||||
|
||||
.textarea {
|
||||
padding: 10px 14px;
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-sm);
|
||||
font-size: 14px;
|
||||
outline: none;
|
||||
resize: vertical;
|
||||
transition: border-color 0.2s;
|
||||
|
||||
&:focus {
|
||||
border-color: var(--color-orange-500);
|
||||
}
|
||||
}
|
||||
|
||||
.submit {
|
||||
background: var(--color-primary);
|
||||
color: #fff;
|
||||
border: none;
|
||||
padding: 14px 32px;
|
||||
border-radius: var(--border-radius-md);
|
||||
font-weight: 700;
|
||||
font-size: 15px;
|
||||
cursor: pointer;
|
||||
align-self: flex-start;
|
||||
transition: background-color 0.2s;
|
||||
|
||||
&:hover {
|
||||
background: var(--color-primary-hover);
|
||||
}
|
||||
}
|
||||
26
apps/web/src/app/rfq/page.tsx
Normal file
26
apps/web/src/app/rfq/page.tsx
Normal file
@@ -0,0 +1,26 @@
|
||||
import { Breadcrumb } from '@/components/Breadcrumb/Breadcrumb';
|
||||
import { RFQForm } from '@/components/RFQForm/RFQForm';
|
||||
import styles from './page.module.scss';
|
||||
|
||||
export const metadata = {
|
||||
title: 'Запрос цены (RFQ) | PAN-PROM',
|
||||
};
|
||||
|
||||
export default function RFQPage() {
|
||||
return (
|
||||
<div className={styles.container}>
|
||||
<Breadcrumb
|
||||
items={[
|
||||
{ label: 'Главная', href: '/' },
|
||||
{ label: 'Запрос цены (RFQ)' },
|
||||
]}
|
||||
/>
|
||||
<h1 className={styles.title}>Запрос коммерческого предложения</h1>
|
||||
<p className={styles.subtitle}>
|
||||
Заполните форму, и мы подготовим коммерческое предложение в течение 24
|
||||
часов.
|
||||
</p>
|
||||
<RFQForm />
|
||||
</div>
|
||||
);
|
||||
}
|
||||
90
apps/web/src/components/BrandLogos/BrandLogos.module.scss
Normal file
90
apps/web/src/components/BrandLogos/BrandLogos.module.scss
Normal file
@@ -0,0 +1,90 @@
|
||||
.section {
|
||||
padding: var(--space-2xl) var(--space-lg);
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.header {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 24px;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 22px;
|
||||
font-weight: 700;
|
||||
color: var(--color-navy-500);
|
||||
margin: 0;
|
||||
}
|
||||
|
||||
.allLink {
|
||||
background: none;
|
||||
border: none;
|
||||
color: var(--color-orange-500);
|
||||
font-weight: 600;
|
||||
font-size: 13px;
|
||||
cursor: pointer;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
|
||||
&:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
}
|
||||
|
||||
.grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(6, 1fr);
|
||||
gap: 12px;
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
}
|
||||
}
|
||||
|
||||
.card {
|
||||
background: var(--color-surface);
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-md);
|
||||
padding: 16px 12px;
|
||||
text-align: center;
|
||||
cursor: pointer;
|
||||
transition: box-shadow 0.2s;
|
||||
display: block;
|
||||
|
||||
&:hover {
|
||||
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
|
||||
}
|
||||
}
|
||||
|
||||
.logoBox {
|
||||
width: 48px;
|
||||
height: 48px;
|
||||
border-radius: var(--border-radius-md);
|
||||
background: var(--color-slate-100);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin: 0 auto 8px;
|
||||
font-weight: 800;
|
||||
font-size: 15px;
|
||||
color: var(--color-slate-600);
|
||||
}
|
||||
|
||||
.name {
|
||||
font-size: 12px;
|
||||
font-weight: 600;
|
||||
color: var(--color-slate-700);
|
||||
}
|
||||
|
||||
.meta {
|
||||
font-size: 10px;
|
||||
color: var(--color-slate-400);
|
||||
margin-top: 2px;
|
||||
}
|
||||
33
apps/web/src/components/BrandLogos/BrandLogos.tsx
Normal file
33
apps/web/src/components/BrandLogos/BrandLogos.tsx
Normal file
@@ -0,0 +1,33 @@
|
||||
import Link from 'next/link';
|
||||
import { Icon } from '@/components/Icon/Icon';
|
||||
import { brands } from '@/data/brands';
|
||||
import styles from './BrandLogos.module.scss';
|
||||
|
||||
export function BrandLogos() {
|
||||
return (
|
||||
<section className={styles.section}>
|
||||
<div className={styles.header}>
|
||||
<h2 className={styles.title}>Производители</h2>
|
||||
<Link href="/catalog" className={styles.allLink}>
|
||||
Все бренды
|
||||
<Icon name="chevronRight" size={14} color="var(--color-orange-500)" />
|
||||
</Link>
|
||||
</div>
|
||||
<div className={styles.grid}>
|
||||
{brands.map((b) => (
|
||||
<Link
|
||||
key={b.id}
|
||||
href={`/brand/${b.id}`}
|
||||
className={styles.card}
|
||||
>
|
||||
<div className={styles.logoBox}>{b.logo}</div>
|
||||
<div className={styles.name}>{b.name}</div>
|
||||
<div className={styles.meta}>
|
||||
{b.country} · {b.category}
|
||||
</div>
|
||||
</Link>
|
||||
))}
|
||||
</div>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
21
apps/web/src/components/Breadcrumb/Breadcrumb.module.scss
Normal file
21
apps/web/src/components/Breadcrumb/Breadcrumb.module.scss
Normal file
@@ -0,0 +1,21 @@
|
||||
.breadcrumb {
|
||||
font-size: 12px;
|
||||
color: var(--color-slate-400);
|
||||
margin-bottom: var(--space-md);
|
||||
}
|
||||
|
||||
.separator {
|
||||
margin: 0 6px;
|
||||
}
|
||||
|
||||
.link {
|
||||
color: var(--color-slate-400);
|
||||
|
||||
&:hover {
|
||||
color: var(--color-primary);
|
||||
}
|
||||
}
|
||||
|
||||
.current {
|
||||
color: var(--color-slate-600);
|
||||
}
|
||||
26
apps/web/src/components/Breadcrumb/Breadcrumb.tsx
Normal file
26
apps/web/src/components/Breadcrumb/Breadcrumb.tsx
Normal file
@@ -0,0 +1,26 @@
|
||||
import Link from 'next/link';
|
||||
import styles from './Breadcrumb.module.scss';
|
||||
|
||||
interface BreadcrumbItem {
|
||||
label: string;
|
||||
href?: string;
|
||||
}
|
||||
|
||||
export function Breadcrumb({ items }: { items: BreadcrumbItem[] }) {
|
||||
return (
|
||||
<nav className={styles.breadcrumb}>
|
||||
{items.map((item, i) => (
|
||||
<span key={i}>
|
||||
{i > 0 && <span className={styles.separator}>/</span>}
|
||||
{item.href ? (
|
||||
<Link href={item.href} className={styles.link}>
|
||||
{item.label}
|
||||
</Link>
|
||||
) : (
|
||||
<span className={styles.current}>{item.label}</span>
|
||||
)}
|
||||
</span>
|
||||
))}
|
||||
</nav>
|
||||
);
|
||||
}
|
||||
60
apps/web/src/components/CartProvider/CartProvider.tsx
Normal file
60
apps/web/src/components/CartProvider/CartProvider.tsx
Normal file
@@ -0,0 +1,60 @@
|
||||
'use client';
|
||||
|
||||
import {
|
||||
createContext,
|
||||
useContext,
|
||||
useState,
|
||||
useCallback,
|
||||
ReactNode,
|
||||
} from 'react';
|
||||
import { Product } from '@/types';
|
||||
|
||||
interface CartItem extends Product {
|
||||
qty: number;
|
||||
}
|
||||
|
||||
interface CartContextValue {
|
||||
cart: CartItem[];
|
||||
addToCart: (product: Product) => void;
|
||||
removeFromCart: (id: number) => void;
|
||||
updateQuantity: (id: number, qty: number) => void;
|
||||
}
|
||||
|
||||
const CartContext = createContext<CartContextValue | null>(null);
|
||||
|
||||
export function CartProvider({ children }: { children: ReactNode }) {
|
||||
const [cart, setCart] = useState<CartItem[]>([]);
|
||||
|
||||
const addToCart = useCallback((product: Product) => {
|
||||
setCart((prev) => {
|
||||
const exists = prev.find((i) => i.id === product.id);
|
||||
if (exists) return prev;
|
||||
return [...prev, { ...product, qty: 1 }];
|
||||
});
|
||||
}, []);
|
||||
|
||||
const removeFromCart = useCallback((id: number) => {
|
||||
setCart((prev) => prev.filter((i) => i.id !== id));
|
||||
}, []);
|
||||
|
||||
const updateQuantity = useCallback((id: number, qty: number) => {
|
||||
if (qty < 1) return;
|
||||
setCart((prev) =>
|
||||
prev.map((i) => (i.id === id ? { ...i, qty } : i))
|
||||
);
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<CartContext.Provider
|
||||
value={{ cart, addToCart, removeFromCart, updateQuantity }}
|
||||
>
|
||||
{children}
|
||||
</CartContext.Provider>
|
||||
);
|
||||
}
|
||||
|
||||
export function useCart() {
|
||||
const ctx = useContext(CartContext);
|
||||
if (!ctx) throw new Error('useCart must be used within CartProvider');
|
||||
return ctx;
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
.sidebar {
|
||||
width: 240px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.inner {
|
||||
background: var(--color-surface);
|
||||
border-radius: var(--border-radius-lg);
|
||||
border: 1px solid var(--color-border);
|
||||
padding: 20px;
|
||||
position: sticky;
|
||||
top: 140px;
|
||||
}
|
||||
|
||||
.sectionTitle {
|
||||
font-weight: 700;
|
||||
font-size: 14px;
|
||||
color: var(--color-slate-800);
|
||||
margin-bottom: var(--space-md);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
}
|
||||
|
||||
.filterGroup {
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.filterLabel {
|
||||
font-size: 12px;
|
||||
font-weight: 600;
|
||||
color: var(--color-text-muted);
|
||||
margin-bottom: 8px;
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 1px;
|
||||
}
|
||||
|
||||
.filterItem {
|
||||
padding: 8px 12px;
|
||||
border-radius: 8px;
|
||||
cursor: pointer;
|
||||
font-size: 13px;
|
||||
font-weight: 400;
|
||||
color: var(--color-slate-600);
|
||||
margin-bottom: 2px;
|
||||
transition: all 0.15s;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
width: 100%;
|
||||
border: none;
|
||||
background: none;
|
||||
text-align: left;
|
||||
|
||||
&:hover {
|
||||
background: var(--color-slate-50);
|
||||
}
|
||||
}
|
||||
|
||||
.filterItemActive {
|
||||
font-weight: 600;
|
||||
background: var(--color-orange-50);
|
||||
color: var(--color-orange-600);
|
||||
}
|
||||
|
||||
.brandCountry {
|
||||
font-size: 11px;
|
||||
color: var(--color-slate-400);
|
||||
}
|
||||
80
apps/web/src/components/CatalogSidebar/CatalogSidebar.tsx
Normal file
80
apps/web/src/components/CatalogSidebar/CatalogSidebar.tsx
Normal file
@@ -0,0 +1,80 @@
|
||||
'use client';
|
||||
|
||||
import { useRouter, useSearchParams } from 'next/navigation';
|
||||
import { Icon } from '@/components/Icon/Icon';
|
||||
import { categories } from '@/data/categories';
|
||||
import { brands } from '@/data/brands';
|
||||
import styles from './CatalogSidebar.module.scss';
|
||||
|
||||
interface CatalogSidebarProps {
|
||||
activeCategory?: string;
|
||||
}
|
||||
|
||||
export function CatalogSidebar({ activeCategory }: CatalogSidebarProps) {
|
||||
const router = useRouter();
|
||||
const searchParams = useSearchParams();
|
||||
const activeBrand = searchParams.get('brand');
|
||||
|
||||
const handleCategoryClick = (slug: string | null) => {
|
||||
if (slug) {
|
||||
router.push(`/catalog/${slug}`);
|
||||
} else {
|
||||
router.push('/catalog');
|
||||
}
|
||||
};
|
||||
|
||||
const handleBrandClick = (brandId: number) => {
|
||||
router.push(`/brand/${brandId}`);
|
||||
};
|
||||
|
||||
const filteredBrands = activeCategory
|
||||
? brands.filter((b) => {
|
||||
const cat = categories.find((c) => c.slug === activeCategory);
|
||||
return cat ? b.category === cat.name : true;
|
||||
})
|
||||
: brands;
|
||||
|
||||
return (
|
||||
<aside className={styles.sidebar}>
|
||||
<div className={styles.inner}>
|
||||
<div className={styles.sectionTitle}>
|
||||
<Icon name="filter" size={16} color="var(--color-orange-500)" />
|
||||
Фильтры
|
||||
</div>
|
||||
|
||||
<div className={styles.filterGroup}>
|
||||
<div className={styles.filterLabel}>Направление</div>
|
||||
<button
|
||||
className={`${styles.filterItem} ${!activeCategory ? styles.filterItemActive : ''}`}
|
||||
onClick={() => handleCategoryClick(null)}
|
||||
>
|
||||
Все
|
||||
</button>
|
||||
{categories.map((c) => (
|
||||
<button
|
||||
key={c.slug}
|
||||
className={`${styles.filterItem} ${activeCategory === c.slug ? styles.filterItemActive : ''}`}
|
||||
onClick={() => handleCategoryClick(c.slug)}
|
||||
>
|
||||
{c.name}
|
||||
</button>
|
||||
))}
|
||||
</div>
|
||||
|
||||
<div className={styles.filterGroup}>
|
||||
<div className={styles.filterLabel}>Бренд</div>
|
||||
{filteredBrands.slice(0, 6).map((b) => (
|
||||
<button
|
||||
key={b.id}
|
||||
className={`${styles.filterItem} ${activeBrand === String(b.id) ? styles.filterItemActive : ''}`}
|
||||
onClick={() => handleBrandClick(b.id)}
|
||||
>
|
||||
<span>{b.name}</span>
|
||||
<span className={styles.brandCountry}>{b.country}</span>
|
||||
</button>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</aside>
|
||||
);
|
||||
}
|
||||
76
apps/web/src/components/Directions/Directions.module.scss
Normal file
76
apps/web/src/components/Directions/Directions.module.scss
Normal file
@@ -0,0 +1,76 @@
|
||||
.section {
|
||||
padding: var(--space-2xl) var(--space-lg);
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 22px;
|
||||
font-weight: 700;
|
||||
color: var(--color-navy-500);
|
||||
margin: 0 0 8px;
|
||||
}
|
||||
|
||||
.subtitle {
|
||||
color: var(--color-text-muted);
|
||||
font-size: 14px;
|
||||
margin: 0 0 24px;
|
||||
}
|
||||
|
||||
.grid {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
gap: 16px;
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
.card {
|
||||
background: var(--color-surface);
|
||||
border-radius: var(--border-radius-lg);
|
||||
padding: 24px;
|
||||
cursor: pointer;
|
||||
border: 1px solid var(--color-border);
|
||||
transition: box-shadow 0.2s, transform 0.2s;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
display: block;
|
||||
|
||||
&:hover {
|
||||
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
|
||||
transform: translateY(-2px);
|
||||
}
|
||||
}
|
||||
|
||||
.cardAccent {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
height: 3px;
|
||||
}
|
||||
|
||||
.cardTitle {
|
||||
font-size: 17px;
|
||||
font-weight: 700;
|
||||
color: var(--color-slate-800);
|
||||
margin: 0 0 8px;
|
||||
}
|
||||
|
||||
.cardDesc {
|
||||
font-size: 13px;
|
||||
color: var(--color-text-muted);
|
||||
line-height: 1.5;
|
||||
margin: 0 0 12px;
|
||||
}
|
||||
|
||||
.cardBrands {
|
||||
font-size: 11px;
|
||||
color: var(--color-slate-400);
|
||||
}
|
||||
31
apps/web/src/components/Directions/Directions.tsx
Normal file
31
apps/web/src/components/Directions/Directions.tsx
Normal file
@@ -0,0 +1,31 @@
|
||||
import Link from 'next/link';
|
||||
import { categories } from '@/data/categories';
|
||||
import styles from './Directions.module.scss';
|
||||
|
||||
export function Directions() {
|
||||
return (
|
||||
<section className={styles.section}>
|
||||
<h2 className={styles.title}>Направления</h2>
|
||||
<p className={styles.subtitle}>
|
||||
Четыре ключевых направления поставок — выберите ваше
|
||||
</p>
|
||||
<div className={styles.grid}>
|
||||
{categories.map((d) => (
|
||||
<Link
|
||||
key={d.slug}
|
||||
href={`/catalog/${d.slug}`}
|
||||
className={styles.card}
|
||||
>
|
||||
<div
|
||||
className={styles.cardAccent}
|
||||
style={{ background: d.color }}
|
||||
/>
|
||||
<h3 className={styles.cardTitle}>{d.name}</h3>
|
||||
<p className={styles.cardDesc}>{d.description}</p>
|
||||
<div className={styles.cardBrands}>{d.brands}</div>
|
||||
</Link>
|
||||
))}
|
||||
</div>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
92
apps/web/src/components/Footer/Footer.module.scss
Normal file
92
apps/web/src/components/Footer/Footer.module.scss
Normal file
@@ -0,0 +1,92 @@
|
||||
.footer {
|
||||
background: var(--color-slate-900);
|
||||
color: var(--color-slate-300);
|
||||
padding: var(--space-2xl) var(--space-lg) 0;
|
||||
margin-top: auto;
|
||||
}
|
||||
|
||||
.inner {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
gap: var(--space-2xl);
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.brand {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 12px;
|
||||
}
|
||||
|
||||
.logoIcon {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
border-radius: 8px;
|
||||
background: linear-gradient(135deg, var(--color-orange-500), var(--color-orange-700));
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: #fff;
|
||||
font-weight: 900;
|
||||
font-size: 18px;
|
||||
letter-spacing: -1px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.logoTitle {
|
||||
font-weight: 700;
|
||||
font-size: 17px;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.logoSubtitle {
|
||||
font-size: 11px;
|
||||
color: var(--color-slate-400);
|
||||
}
|
||||
|
||||
.columns {
|
||||
display: flex;
|
||||
gap: var(--space-2xl);
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.column {
|
||||
min-width: 160px;
|
||||
}
|
||||
|
||||
.columnTitle {
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: var(--color-slate-400);
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 1px;
|
||||
margin-bottom: var(--space-md);
|
||||
}
|
||||
|
||||
.columnList {
|
||||
list-style: none;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-sm);
|
||||
}
|
||||
|
||||
.columnLink {
|
||||
font-size: 13px;
|
||||
color: var(--color-slate-300);
|
||||
transition: color 0.2s;
|
||||
|
||||
&:hover {
|
||||
color: var(--color-orange-400);
|
||||
}
|
||||
}
|
||||
|
||||
.bottom {
|
||||
max-width: var(--max-width);
|
||||
margin: var(--space-xl) auto 0;
|
||||
padding: var(--space-lg) 0;
|
||||
border-top: 1px solid var(--color-slate-700);
|
||||
font-size: 12px;
|
||||
color: var(--color-slate-500);
|
||||
}
|
||||
42
apps/web/src/components/Footer/Footer.tsx
Normal file
42
apps/web/src/components/Footer/Footer.tsx
Normal file
@@ -0,0 +1,42 @@
|
||||
import Link from 'next/link';
|
||||
import { footerColumns } from '@/data/navigation';
|
||||
import styles from './Footer.module.scss';
|
||||
|
||||
export function Footer() {
|
||||
return (
|
||||
<footer className={styles.footer}>
|
||||
<div className={styles.inner}>
|
||||
<div className={styles.brand}>
|
||||
<div className={styles.logoIcon}>PP</div>
|
||||
<div>
|
||||
<div className={styles.logoTitle}>PAN-PROM</div>
|
||||
<div className={styles.logoSubtitle}>
|
||||
Промышленное оборудование из Европы
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className={styles.columns}>
|
||||
{footerColumns.map((col) => (
|
||||
<div key={col.title} className={styles.column}>
|
||||
<h4 className={styles.columnTitle}>{col.title}</h4>
|
||||
<ul className={styles.columnList}>
|
||||
{col.links.map((link) => (
|
||||
<li key={link.label}>
|
||||
<Link href={link.href} className={styles.columnLink}>
|
||||
{link.label}
|
||||
</Link>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className={styles.bottom}>
|
||||
<span>© {new Date().getFullYear()} PAN-PROM. Все права защищены.</span>
|
||||
</div>
|
||||
</footer>
|
||||
);
|
||||
}
|
||||
292
apps/web/src/components/Header/Header.module.scss
Normal file
292
apps/web/src/components/Header/Header.module.scss
Normal file
@@ -0,0 +1,292 @@
|
||||
@use '../../styles/variables' as *;
|
||||
|
||||
.header {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
z-index: 100;
|
||||
background: var(--color-surface);
|
||||
border-bottom: 1px solid var(--color-border);
|
||||
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
|
||||
}
|
||||
|
||||
/* Top bar */
|
||||
.topBar {
|
||||
background: var(--color-navy-500);
|
||||
color: #fff;
|
||||
font-size: 12px;
|
||||
padding: 6px var(--space-lg);
|
||||
}
|
||||
|
||||
.topBarInner {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.topBarContacts {
|
||||
display: flex;
|
||||
gap: var(--space-md);
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.topBarItem {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
}
|
||||
|
||||
.langSwitcher {
|
||||
display: flex;
|
||||
gap: 12px;
|
||||
}
|
||||
|
||||
.langActive {
|
||||
opacity: 0.7;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.langInactive {
|
||||
opacity: 0.5;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.langDivider {
|
||||
opacity: 0.4;
|
||||
}
|
||||
|
||||
/* Main nav */
|
||||
.mainNav {
|
||||
padding: 12px var(--space-lg);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.logo {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 10px;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
.logoIcon {
|
||||
width: 40px;
|
||||
height: 40px;
|
||||
border-radius: 8px;
|
||||
background: linear-gradient(135deg, var(--color-orange-500), var(--color-orange-700));
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
color: #fff;
|
||||
font-weight: 900;
|
||||
font-size: 18px;
|
||||
letter-spacing: -1px;
|
||||
}
|
||||
|
||||
.logoTitle {
|
||||
font-weight: 700;
|
||||
font-size: 17px;
|
||||
color: var(--color-navy-500);
|
||||
line-height: 1.1;
|
||||
letter-spacing: 0.5px;
|
||||
}
|
||||
|
||||
.logoSubtitle {
|
||||
font-size: 10px;
|
||||
color: var(--color-slate-400);
|
||||
letter-spacing: 1.5px;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
/* Search */
|
||||
.searchWrapper {
|
||||
flex: 1;
|
||||
max-width: 520px;
|
||||
margin: 0 var(--space-xl);
|
||||
position: relative;
|
||||
|
||||
@media (max-width: $breakpoint-md) {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
.searchBar {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
border: 2px solid var(--color-border);
|
||||
border-radius: var(--border-radius-md);
|
||||
overflow: hidden;
|
||||
transition: border 0.2s;
|
||||
background: var(--color-slate-50);
|
||||
}
|
||||
|
||||
.searchFocused .searchBar {
|
||||
border-color: var(--color-orange-500);
|
||||
}
|
||||
|
||||
.searchInput {
|
||||
flex: 1;
|
||||
border: none;
|
||||
outline: none;
|
||||
padding: 10px 16px;
|
||||
font-size: 14px;
|
||||
background: transparent;
|
||||
color: var(--color-slate-800);
|
||||
}
|
||||
|
||||
.searchButton {
|
||||
background: var(--color-orange-500);
|
||||
border: none;
|
||||
padding: 10px 16px;
|
||||
cursor: pointer;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
.suggestions {
|
||||
position: absolute;
|
||||
top: 100%;
|
||||
left: 0;
|
||||
right: 0;
|
||||
margin-top: 4px;
|
||||
background: var(--color-surface);
|
||||
border-radius: var(--border-radius-md);
|
||||
box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
|
||||
border: 1px solid var(--color-border);
|
||||
overflow: hidden;
|
||||
z-index: 200;
|
||||
}
|
||||
|
||||
.suggestionItem {
|
||||
padding: 10px 16px;
|
||||
cursor: pointer;
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
border-bottom: 1px solid var(--color-slate-100);
|
||||
font-size: 13px;
|
||||
|
||||
&:hover {
|
||||
background: var(--color-slate-50);
|
||||
}
|
||||
}
|
||||
|
||||
.suggestionSku {
|
||||
color: var(--color-orange-500);
|
||||
font-weight: 600;
|
||||
font-family: var(--font-mono);
|
||||
}
|
||||
|
||||
.suggestionName {
|
||||
color: var(--color-text-muted);
|
||||
margin-left: var(--space-sm);
|
||||
}
|
||||
|
||||
.suggestionBrand {
|
||||
font-size: 11px;
|
||||
color: var(--color-slate-400);
|
||||
}
|
||||
|
||||
/* Actions */
|
||||
.actions {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 20px;
|
||||
}
|
||||
|
||||
.cartLink {
|
||||
position: relative;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
.cartBadge {
|
||||
position: absolute;
|
||||
top: -6px;
|
||||
right: -8px;
|
||||
background: var(--color-orange-500);
|
||||
color: #fff;
|
||||
font-size: 10px;
|
||||
font-weight: 700;
|
||||
width: 18px;
|
||||
height: 18px;
|
||||
border-radius: 9px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.rfqButton {
|
||||
background: var(--color-orange-500);
|
||||
color: #fff;
|
||||
border: none;
|
||||
padding: 8px 20px;
|
||||
border-radius: 8px;
|
||||
font-weight: 600;
|
||||
font-size: 13px;
|
||||
cursor: pointer;
|
||||
white-space: nowrap;
|
||||
letter-spacing: 0.3px;
|
||||
|
||||
@media (max-width: $breakpoint-md) {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
.menuToggle {
|
||||
display: none;
|
||||
background: none;
|
||||
border: none;
|
||||
padding: 4px;
|
||||
|
||||
@media (max-width: $breakpoint-md) {
|
||||
display: flex;
|
||||
}
|
||||
}
|
||||
|
||||
/* Nav tabs */
|
||||
.navTabs {
|
||||
border-top: 1px solid var(--color-slate-100);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0;
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
padding: 0 var(--space-lg);
|
||||
|
||||
@media (max-width: $breakpoint-md) {
|
||||
display: none;
|
||||
flex-direction: column;
|
||||
align-items: stretch;
|
||||
|
||||
&.navTabsOpen {
|
||||
display: flex;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.navTab {
|
||||
background: none;
|
||||
border: none;
|
||||
padding: 12px 20px;
|
||||
font-size: 13px;
|
||||
font-weight: 500;
|
||||
color: var(--color-slate-600);
|
||||
cursor: pointer;
|
||||
border-bottom: 2px solid transparent;
|
||||
transition: all 0.2s;
|
||||
|
||||
&:hover {
|
||||
color: var(--color-primary);
|
||||
}
|
||||
}
|
||||
|
||||
.navTabActive {
|
||||
border-bottom-color: var(--color-orange-500);
|
||||
color: var(--color-orange-500);
|
||||
}
|
||||
147
apps/web/src/components/Header/Header.tsx
Normal file
147
apps/web/src/components/Header/Header.tsx
Normal file
@@ -0,0 +1,147 @@
|
||||
'use client';
|
||||
|
||||
import { useState, useRef } from 'react';
|
||||
import Link from 'next/link';
|
||||
import { usePathname } from 'next/navigation';
|
||||
import { Icon } from '@/components/Icon/Icon';
|
||||
import { useCart } from '@/components/CartProvider/CartProvider';
|
||||
import { headerNav } from '@/data/navigation';
|
||||
import { products } from '@/data/products';
|
||||
import styles from './Header.module.scss';
|
||||
|
||||
export function Header() {
|
||||
const pathname = usePathname();
|
||||
const { cart } = useCart();
|
||||
const [searchQuery, setSearchQuery] = useState('');
|
||||
const [searchFocused, setSearchFocused] = useState(false);
|
||||
const [mobileMenu, setMobileMenu] = useState(false);
|
||||
const searchRef = useRef<HTMLDivElement>(null);
|
||||
|
||||
const suggestions =
|
||||
searchQuery.length > 1
|
||||
? products
|
||||
.filter(
|
||||
(p) =>
|
||||
p.sku.toLowerCase().includes(searchQuery.toLowerCase()) ||
|
||||
p.name.toLowerCase().includes(searchQuery.toLowerCase())
|
||||
)
|
||||
.slice(0, 5)
|
||||
: [];
|
||||
|
||||
return (
|
||||
<header className={styles.header}>
|
||||
{/* Top bar */}
|
||||
<div className={styles.topBar}>
|
||||
<div className={styles.topBarInner}>
|
||||
<div className={styles.topBarContacts}>
|
||||
<span className={styles.topBarItem}>
|
||||
<Icon name="phone" size={13} color="var(--color-orange-400)" />
|
||||
+49 (0) 40 123-4567
|
||||
</span>
|
||||
<span className={styles.topBarItem}>
|
||||
<Icon name="mail" size={13} color="var(--color-orange-400)" />
|
||||
info@pan-prom.eu
|
||||
</span>
|
||||
</div>
|
||||
<div className={styles.langSwitcher}>
|
||||
<span className={styles.langActive}>RU</span>
|
||||
<span className={styles.langDivider}>|</span>
|
||||
<span className={styles.langInactive}>EN</span>
|
||||
<span className={styles.langDivider}>|</span>
|
||||
<span className={styles.langInactive}>DE</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* Main nav */}
|
||||
<div className={styles.mainNav}>
|
||||
{/* Logo */}
|
||||
<Link href="/" className={styles.logo}>
|
||||
<div className={styles.logoIcon}>PP</div>
|
||||
<div>
|
||||
<div className={styles.logoTitle}>PAN-PROM</div>
|
||||
<div className={styles.logoSubtitle}>Выбор инженеров</div>
|
||||
</div>
|
||||
</Link>
|
||||
|
||||
{/* Search */}
|
||||
<div
|
||||
className={`${styles.searchWrapper} ${searchFocused ? styles.searchFocused : ''}`}
|
||||
ref={searchRef}
|
||||
>
|
||||
<div className={styles.searchBar}>
|
||||
<input
|
||||
placeholder="Артикул, название или бренд..."
|
||||
value={searchQuery}
|
||||
onChange={(e) => setSearchQuery(e.target.value)}
|
||||
onFocus={() => setSearchFocused(true)}
|
||||
onBlur={() => setTimeout(() => setSearchFocused(false), 200)}
|
||||
className={styles.searchInput}
|
||||
/>
|
||||
<Link
|
||||
href={searchQuery ? `/catalog?q=${encodeURIComponent(searchQuery)}` : '/catalog'}
|
||||
className={styles.searchButton}
|
||||
onClick={() => setSearchQuery('')}
|
||||
>
|
||||
<Icon name="search" size={18} color="#fff" />
|
||||
</Link>
|
||||
</div>
|
||||
|
||||
{searchFocused && suggestions.length > 0 && (
|
||||
<div className={styles.suggestions}>
|
||||
{suggestions.map((s) => (
|
||||
<Link
|
||||
key={s.id}
|
||||
href={`/product/${encodeURIComponent(s.sku)}`}
|
||||
className={styles.suggestionItem}
|
||||
onMouseDown={(e) => e.preventDefault()}
|
||||
onClick={() => setSearchQuery('')}
|
||||
>
|
||||
<div>
|
||||
<span className={styles.suggestionSku}>{s.sku}</span>
|
||||
<span className={styles.suggestionName}>{s.name}</span>
|
||||
</div>
|
||||
<span className={styles.suggestionBrand}>{s.brand}</span>
|
||||
</Link>
|
||||
))}
|
||||
</div>
|
||||
)}
|
||||
</div>
|
||||
|
||||
{/* Right actions */}
|
||||
<div className={styles.actions}>
|
||||
<Link href="/cart" className={styles.cartLink}>
|
||||
<Icon name="cart" size={22} color="var(--color-slate-700)" />
|
||||
{cart.length > 0 && (
|
||||
<span className={styles.cartBadge}>{cart.length}</span>
|
||||
)}
|
||||
</Link>
|
||||
<Link href="/rfq" className={styles.rfqButton}>
|
||||
Запрос цены (RFQ)
|
||||
</Link>
|
||||
<button
|
||||
className={styles.menuToggle}
|
||||
onClick={() => setMobileMenu(!mobileMenu)}
|
||||
aria-label={mobileMenu ? 'Закрыть меню' : 'Открыть меню'}
|
||||
>
|
||||
<Icon name={mobileMenu ? 'x' : 'menu'} size={24} />
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* Nav tabs */}
|
||||
<nav className={`${styles.navTabs} ${mobileMenu ? styles.navTabsOpen : ''}`}>
|
||||
{headerNav.map((item) => (
|
||||
<Link
|
||||
key={item.label}
|
||||
href={item.href}
|
||||
className={`${styles.navTab} ${pathname === item.href ? styles.navTabActive : ''}`}
|
||||
onClick={() => setMobileMenu(false)}
|
||||
>
|
||||
{item.label}
|
||||
</Link>
|
||||
))}
|
||||
</nav>
|
||||
</header>
|
||||
);
|
||||
}
|
||||
129
apps/web/src/components/Hero/Hero.module.scss
Normal file
129
apps/web/src/components/Hero/Hero.module.scss
Normal file
@@ -0,0 +1,129 @@
|
||||
.hero {
|
||||
background: linear-gradient(135deg, var(--color-navy-500) 0%, var(--color-navy-700) 50%, var(--color-navy-900) 100%);
|
||||
padding: 64px var(--space-lg);
|
||||
color: #fff;
|
||||
position: relative;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.pattern {
|
||||
position: absolute;
|
||||
inset: 0;
|
||||
opacity: 0.05;
|
||||
}
|
||||
|
||||
.circle {
|
||||
position: absolute;
|
||||
border: 1px solid var(--color-orange-400);
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.inner {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
position: relative;
|
||||
z-index: 1;
|
||||
}
|
||||
|
||||
.content {
|
||||
max-width: 640px;
|
||||
}
|
||||
|
||||
.badge {
|
||||
display: inline-block;
|
||||
background: rgba(232, 96, 10, 0.13);
|
||||
color: var(--color-orange-400);
|
||||
padding: 4px 12px;
|
||||
border-radius: 6px;
|
||||
font-size: 12px;
|
||||
font-weight: 600;
|
||||
margin-bottom: 16px;
|
||||
border: 1px solid rgba(232, 96, 10, 0.2);
|
||||
letter-spacing: 1px;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 40px;
|
||||
font-weight: 800;
|
||||
line-height: 1.15;
|
||||
margin: 0 0 16px;
|
||||
}
|
||||
|
||||
.titleAccent {
|
||||
color: var(--color-orange-400);
|
||||
}
|
||||
|
||||
.description {
|
||||
font-size: 17px;
|
||||
color: var(--color-slate-300);
|
||||
line-height: 1.6;
|
||||
margin: 0 0 32px;
|
||||
}
|
||||
|
||||
.cta {
|
||||
display: flex;
|
||||
gap: 12px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
|
||||
.ctaPrimary {
|
||||
background: var(--color-orange-500);
|
||||
color: #fff;
|
||||
border: none;
|
||||
padding: 14px 32px;
|
||||
border-radius: var(--border-radius-md);
|
||||
font-weight: 700;
|
||||
font-size: 15px;
|
||||
cursor: pointer;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 8px;
|
||||
|
||||
&:hover {
|
||||
background: var(--color-orange-600);
|
||||
}
|
||||
}
|
||||
|
||||
.ctaSecondary {
|
||||
background: transparent;
|
||||
color: #fff;
|
||||
border: 1px solid var(--color-slate-400);
|
||||
padding: 14px 32px;
|
||||
border-radius: var(--border-radius-md);
|
||||
font-weight: 600;
|
||||
font-size: 15px;
|
||||
cursor: pointer;
|
||||
|
||||
&:hover {
|
||||
background: rgba(255, 255, 255, 0.05);
|
||||
}
|
||||
}
|
||||
|
||||
.stats {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
gap: 16px;
|
||||
margin-top: 48px;
|
||||
background: rgba(255, 255, 255, 0.03);
|
||||
border-radius: var(--border-radius-lg);
|
||||
padding: 20px;
|
||||
backdrop-filter: blur(8px);
|
||||
border: 1px solid rgba(255, 255, 255, 0.06);
|
||||
}
|
||||
|
||||
.statItem {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.statNum {
|
||||
font-size: 28px;
|
||||
font-weight: 800;
|
||||
color: var(--color-orange-400);
|
||||
}
|
||||
|
||||
.statLabel {
|
||||
font-size: 12px;
|
||||
color: var(--color-slate-300);
|
||||
margin-top: 4px;
|
||||
}
|
||||
62
apps/web/src/components/Hero/Hero.tsx
Normal file
62
apps/web/src/components/Hero/Hero.tsx
Normal file
@@ -0,0 +1,62 @@
|
||||
import Link from 'next/link';
|
||||
import { Icon } from '@/components/Icon/Icon';
|
||||
import styles from './Hero.module.scss';
|
||||
|
||||
export function Hero() {
|
||||
return (
|
||||
<section className={styles.hero}>
|
||||
<div className={styles.pattern} aria-hidden="true">
|
||||
{Array.from({ length: 8 }).map((_, i) => (
|
||||
<div
|
||||
key={i}
|
||||
className={styles.circle}
|
||||
style={{
|
||||
width: 120 + i * 60,
|
||||
height: 120 + i * 60,
|
||||
top: `${10 + i * 5}%`,
|
||||
right: `${-5 + i * 3}%`,
|
||||
}}
|
||||
/>
|
||||
))}
|
||||
</div>
|
||||
|
||||
<div className={styles.inner}>
|
||||
<div className={styles.content}>
|
||||
<div className={styles.badge}>German Engineering. European Standards.</div>
|
||||
<h1 className={styles.title}>
|
||||
Промышленное оборудование
|
||||
<span className={styles.titleAccent}> из Европы</span>
|
||||
</h1>
|
||||
<p className={styles.description}>
|
||||
Гидравлика, пневматика, АСУ, запасные части. Прямые поставки
|
||||
оригинальных комплектующих от ведущих европейских производителей.
|
||||
Склады в Берлине и Гуанчжоу.
|
||||
</p>
|
||||
<div className={styles.cta}>
|
||||
<Link href="/catalog" className={styles.ctaPrimary}>
|
||||
Каталог оборудования
|
||||
<Icon name="chevronRight" size={16} color="#fff" />
|
||||
</Link>
|
||||
<Link href="/rfq" className={styles.ctaSecondary}>
|
||||
Отправить запрос (RFQ)
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className={styles.stats}>
|
||||
{[
|
||||
{ num: '50+', label: 'Европейских брендов' },
|
||||
{ num: '10 000+', label: 'Позиций в каталоге' },
|
||||
{ num: '14', label: 'Дней средняя поставка' },
|
||||
{ num: '100%', label: 'Оригинальная продукция' },
|
||||
].map((s, i) => (
|
||||
<div key={i} className={styles.statItem}>
|
||||
<div className={styles.statNum}>{s.num}</div>
|
||||
<div className={styles.statLabel}>{s.label}</div>
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
</div>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
31
apps/web/src/components/Icon/Icon.tsx
Normal file
31
apps/web/src/components/Icon/Icon.tsx
Normal file
@@ -0,0 +1,31 @@
|
||||
import { iconPaths, IconName } from './icons';
|
||||
|
||||
interface IconProps {
|
||||
name: IconName;
|
||||
size?: number;
|
||||
color?: string;
|
||||
className?: string;
|
||||
}
|
||||
|
||||
export function Icon({
|
||||
name,
|
||||
size = 20,
|
||||
color = 'currentColor',
|
||||
className,
|
||||
}: IconProps) {
|
||||
return (
|
||||
<svg
|
||||
width={size}
|
||||
height={size}
|
||||
viewBox="0 0 24 24"
|
||||
fill="none"
|
||||
stroke={color}
|
||||
strokeWidth="2"
|
||||
strokeLinecap="round"
|
||||
strokeLinejoin="round"
|
||||
className={className}
|
||||
>
|
||||
<path d={iconPaths[name]} />
|
||||
</svg>
|
||||
);
|
||||
}
|
||||
24
apps/web/src/components/Icon/icons.ts
Normal file
24
apps/web/src/components/Icon/icons.ts
Normal file
@@ -0,0 +1,24 @@
|
||||
export const iconPaths = {
|
||||
search: 'M21 21l-4.35-4.35M11 19a8 8 0 1 0 0-16 8 8 0 0 0 0 16z',
|
||||
cart: 'M6 2L3 6v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6l-3-4zM3 6h18M16 10a4 4 0 0 1-8 0',
|
||||
menu: 'M3 12h18M3 6h18M3 18h18',
|
||||
chevronRight: 'M9 18l6-6-6-6',
|
||||
phone:
|
||||
'M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6A19.79 19.79 0 0 1 2.12 4.18 2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72c.127.96.361 1.903.7 2.81a2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45c.907.339 1.85.573 2.81.7A2 2 0 0 1 22 16.92z',
|
||||
mail: 'M4 4h16c1.1 0 2 .9 2 2v12c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2zM22 6l-10 7L2 6',
|
||||
map: 'M21 10c0 7-9 13-9 13s-9-6-9-13a9 9 0 0 1 18 0zM12 13a3 3 0 1 0 0-6 3 3 0 0 0 0 6z',
|
||||
filter: 'M22 3H2l8 9.46V19l4 2v-8.54L22 3z',
|
||||
star: 'M12 2l3.09 6.26L22 9.27l-5 4.87L18.18 22 12 18.27 5.82 22 7 14.14 2 9.27l6.91-1.01L12 2z',
|
||||
truck:
|
||||
'M1 3h15v13H1zM16 8h4l3 3v5h-7V8zM5.5 21a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5zM18.5 21a2.5 2.5 0 1 0 0-5 2.5 2.5 0 0 0 0 5z',
|
||||
shield: 'M12 22s8-4 8-10V5l-8-3-8 3v7c0 6 8 10 8 10z',
|
||||
clock:
|
||||
'M12 22c5.523 0 10-4.477 10-10S17.523 2 12 2 2 6.477 2 12s4.477 10 10 10zM12 6v6l4 2',
|
||||
x: 'M18 6L6 18M6 6l12 12',
|
||||
arrowLeft: 'M19 12H5M12 19l-7-7 7-7',
|
||||
check: 'M20 6L9 17l-5-5',
|
||||
plus: 'M12 5v14M5 12h14',
|
||||
minus: 'M5 12h14',
|
||||
} as const;
|
||||
|
||||
export type IconName = keyof typeof iconPaths;
|
||||
73
apps/web/src/components/ProductCard/ProductCard.module.scss
Normal file
73
apps/web/src/components/ProductCard/ProductCard.module.scss
Normal file
@@ -0,0 +1,73 @@
|
||||
.card {
|
||||
background: var(--color-surface);
|
||||
border-radius: var(--border-radius-lg);
|
||||
border: 1px solid var(--color-border);
|
||||
overflow: hidden;
|
||||
cursor: pointer;
|
||||
transition: box-shadow 0.2s;
|
||||
display: block;
|
||||
|
||||
&:hover {
|
||||
box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
|
||||
}
|
||||
}
|
||||
|
||||
.imageArea {
|
||||
background: var(--color-slate-50);
|
||||
height: 140px;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
font-size: 40px;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.stockBadge {
|
||||
position: absolute;
|
||||
top: 8px;
|
||||
right: 8px;
|
||||
background: var(--color-teal-50);
|
||||
color: var(--color-teal-500);
|
||||
font-size: 10px;
|
||||
font-weight: 600;
|
||||
padding: 3px 8px;
|
||||
border-radius: 4px;
|
||||
}
|
||||
|
||||
.info {
|
||||
padding: var(--space-md);
|
||||
}
|
||||
|
||||
.sku {
|
||||
font-family: var(--font-mono);
|
||||
font-size: 12px;
|
||||
color: var(--color-orange-500);
|
||||
font-weight: 600;
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
|
||||
.name {
|
||||
font-size: 14px;
|
||||
font-weight: 600;
|
||||
color: var(--color-slate-800);
|
||||
margin-bottom: 8px;
|
||||
line-height: 1.3;
|
||||
}
|
||||
|
||||
.meta {
|
||||
display: flex;
|
||||
gap: 8px;
|
||||
font-size: 12px;
|
||||
color: var(--color-slate-400);
|
||||
margin-bottom: 8px;
|
||||
}
|
||||
|
||||
.brand {
|
||||
color: var(--color-slate-600);
|
||||
}
|
||||
|
||||
.price {
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: var(--color-navy-500);
|
||||
}
|
||||
25
apps/web/src/components/ProductCard/ProductCard.tsx
Normal file
25
apps/web/src/components/ProductCard/ProductCard.tsx
Normal file
@@ -0,0 +1,25 @@
|
||||
import Link from 'next/link';
|
||||
import { Product } from '@/types';
|
||||
import styles from './ProductCard.module.scss';
|
||||
|
||||
export function ProductCard({ product }: { product: Product }) {
|
||||
return (
|
||||
<Link
|
||||
href={`/product/${encodeURIComponent(product.sku)}`}
|
||||
className={styles.card}
|
||||
>
|
||||
<div className={styles.imageArea}>
|
||||
{product.inStock && <span className={styles.stockBadge}>В наличии</span>}
|
||||
</div>
|
||||
<div className={styles.info}>
|
||||
<div className={styles.sku}>{product.sku}</div>
|
||||
<div className={styles.name}>{product.name}</div>
|
||||
<div className={styles.meta}>
|
||||
<span className={styles.brand}>{product.brand}</span>
|
||||
<span className={styles.sub}>{product.subcategory}</span>
|
||||
</div>
|
||||
<div className={styles.price}>{product.price}</div>
|
||||
</div>
|
||||
</Link>
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,99 @@
|
||||
.layout {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: var(--space-xl);
|
||||
margin-top: var(--space-lg);
|
||||
|
||||
@media (max-width: 768px) {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
.imageArea {
|
||||
background: var(--color-slate-50);
|
||||
border-radius: var(--border-radius-lg);
|
||||
border: 1px solid var(--color-border);
|
||||
aspect-ratio: 1;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.imagePlaceholder {
|
||||
width: 120px;
|
||||
height: 120px;
|
||||
background: var(--color-slate-200);
|
||||
border-radius: var(--border-radius-md);
|
||||
}
|
||||
|
||||
.details {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-md);
|
||||
}
|
||||
|
||||
.brand {
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: var(--color-text-muted);
|
||||
text-transform: uppercase;
|
||||
letter-spacing: 1px;
|
||||
}
|
||||
|
||||
.name {
|
||||
font-size: 28px;
|
||||
font-weight: 700;
|
||||
color: var(--color-slate-900);
|
||||
line-height: 1.2;
|
||||
}
|
||||
|
||||
.sku {
|
||||
font-size: 14px;
|
||||
color: var(--color-slate-500);
|
||||
|
||||
span {
|
||||
font-family: var(--font-mono);
|
||||
color: var(--color-orange-500);
|
||||
font-weight: 600;
|
||||
}
|
||||
}
|
||||
|
||||
.meta {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 8px;
|
||||
padding: var(--space-md) 0;
|
||||
border-top: 1px solid var(--color-border);
|
||||
border-bottom: 1px solid var(--color-border);
|
||||
}
|
||||
|
||||
.metaItem {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
font-size: 13px;
|
||||
}
|
||||
|
||||
.metaLabel {
|
||||
color: var(--color-slate-400);
|
||||
}
|
||||
|
||||
.inStock {
|
||||
color: var(--color-teal-500);
|
||||
font-weight: 600;
|
||||
}
|
||||
|
||||
.outOfStock {
|
||||
color: var(--color-slate-400);
|
||||
}
|
||||
|
||||
.price {
|
||||
font-size: 22px;
|
||||
font-weight: 700;
|
||||
color: var(--color-navy-500);
|
||||
}
|
||||
|
||||
.actions {
|
||||
display: flex;
|
||||
gap: 12px;
|
||||
flex-wrap: wrap;
|
||||
}
|
||||
57
apps/web/src/components/ProductDetail/ProductDetail.tsx
Normal file
57
apps/web/src/components/ProductDetail/ProductDetail.tsx
Normal file
@@ -0,0 +1,57 @@
|
||||
'use client';
|
||||
|
||||
import Link from 'next/link';
|
||||
import { Product } from '@/types';
|
||||
import { useCart } from '@/components/CartProvider/CartProvider';
|
||||
import { Icon } from '@/components/Icon/Icon';
|
||||
import { Button } from '@/components/ui/Button/Button';
|
||||
import styles from './ProductDetail.module.scss';
|
||||
|
||||
export function ProductDetail({ product }: { product: Product }) {
|
||||
const { addToCart } = useCart();
|
||||
|
||||
return (
|
||||
<div className={styles.layout}>
|
||||
<div className={styles.imageArea}>
|
||||
<div className={styles.imagePlaceholder} />
|
||||
</div>
|
||||
|
||||
<div className={styles.details}>
|
||||
<div className={styles.brand}>{product.brand}</div>
|
||||
<h1 className={styles.name}>{product.name}</h1>
|
||||
<div className={styles.sku}>
|
||||
Артикул: <span>{product.sku}</span>
|
||||
</div>
|
||||
|
||||
<div className={styles.meta}>
|
||||
<div className={styles.metaItem}>
|
||||
<span className={styles.metaLabel}>Категория</span>
|
||||
<Link href="/catalog">{product.category}</Link>
|
||||
</div>
|
||||
<div className={styles.metaItem}>
|
||||
<span className={styles.metaLabel}>Подкатегория</span>
|
||||
<span>{product.subcategory}</span>
|
||||
</div>
|
||||
<div className={styles.metaItem}>
|
||||
<span className={styles.metaLabel}>Наличие</span>
|
||||
<span className={product.inStock ? styles.inStock : styles.outOfStock}>
|
||||
{product.inStock ? 'В наличии' : 'Под заказ'}
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div className={styles.price}>{product.price}</div>
|
||||
|
||||
<div className={styles.actions}>
|
||||
<Button onClick={() => addToCart(product)}>
|
||||
<Icon name="cart" size={16} color="#fff" />
|
||||
В корзину
|
||||
</Button>
|
||||
<Link href="/rfq">
|
||||
<Button variant="secondary">Запросить цену (RFQ)</Button>
|
||||
</Link>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
}
|
||||
71
apps/web/src/components/RFQForm/RFQForm.module.scss
Normal file
71
apps/web/src/components/RFQForm/RFQForm.module.scss
Normal file
@@ -0,0 +1,71 @@
|
||||
.form {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: var(--space-md);
|
||||
}
|
||||
|
||||
.row {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr 1fr;
|
||||
gap: var(--space-md);
|
||||
|
||||
@media (max-width: 640px) {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
.field {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 6px;
|
||||
}
|
||||
|
||||
.label {
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
color: var(--color-slate-700);
|
||||
}
|
||||
|
||||
.input {
|
||||
padding: 10px 14px;
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-sm);
|
||||
font-size: 14px;
|
||||
outline: none;
|
||||
transition: border-color 0.2s;
|
||||
|
||||
&:focus {
|
||||
border-color: var(--color-orange-500);
|
||||
}
|
||||
}
|
||||
|
||||
.textarea {
|
||||
padding: 10px 14px;
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-sm);
|
||||
font-size: 14px;
|
||||
outline: none;
|
||||
resize: vertical;
|
||||
transition: border-color 0.2s;
|
||||
|
||||
&:focus {
|
||||
border-color: var(--color-orange-500);
|
||||
}
|
||||
}
|
||||
|
||||
.submit {
|
||||
background: var(--color-primary);
|
||||
color: #fff;
|
||||
border: none;
|
||||
padding: 14px 32px;
|
||||
border-radius: var(--border-radius-md);
|
||||
font-weight: 700;
|
||||
font-size: 15px;
|
||||
cursor: pointer;
|
||||
align-self: flex-start;
|
||||
transition: background-color 0.2s;
|
||||
|
||||
&:hover {
|
||||
background: var(--color-primary-hover);
|
||||
}
|
||||
}
|
||||
79
apps/web/src/components/RFQForm/RFQForm.tsx
Normal file
79
apps/web/src/components/RFQForm/RFQForm.tsx
Normal file
@@ -0,0 +1,79 @@
|
||||
'use client';
|
||||
|
||||
import { FormEvent } from 'react';
|
||||
import styles from './RFQForm.module.scss';
|
||||
|
||||
export function RFQForm() {
|
||||
const handleSubmit = (e: FormEvent<HTMLFormElement>) => {
|
||||
e.preventDefault();
|
||||
// TODO: integrate with API
|
||||
};
|
||||
|
||||
return (
|
||||
<form className={styles.form} onSubmit={handleSubmit}>
|
||||
<div className={styles.row}>
|
||||
<div className={styles.field}>
|
||||
<label className={styles.label}>Имя *</label>
|
||||
<input
|
||||
className={styles.input}
|
||||
placeholder="Ваше имя"
|
||||
required
|
||||
name="name"
|
||||
/>
|
||||
</div>
|
||||
<div className={styles.field}>
|
||||
<label className={styles.label}>Компания</label>
|
||||
<input
|
||||
className={styles.input}
|
||||
placeholder="Название компании"
|
||||
name="company"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={styles.row}>
|
||||
<div className={styles.field}>
|
||||
<label className={styles.label}>Email *</label>
|
||||
<input
|
||||
className={styles.input}
|
||||
type="email"
|
||||
placeholder="email@company.com"
|
||||
required
|
||||
name="email"
|
||||
/>
|
||||
</div>
|
||||
<div className={styles.field}>
|
||||
<label className={styles.label}>Телефон</label>
|
||||
<input
|
||||
className={styles.input}
|
||||
placeholder="+7 (___) ___-__-__"
|
||||
name="phone"
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
<div className={styles.field}>
|
||||
<label className={styles.label}>
|
||||
Перечень оборудования / артикулы *
|
||||
</label>
|
||||
<textarea
|
||||
className={styles.textarea}
|
||||
rows={6}
|
||||
placeholder="Укажите артикулы, названия и количество необходимого оборудования"
|
||||
required
|
||||
name="equipment"
|
||||
/>
|
||||
</div>
|
||||
<div className={styles.field}>
|
||||
<label className={styles.label}>Комментарий</label>
|
||||
<textarea
|
||||
className={styles.textarea}
|
||||
rows={3}
|
||||
placeholder="Дополнительная информация, сроки, условия поставки"
|
||||
name="comment"
|
||||
/>
|
||||
</div>
|
||||
<button type="submit" className={styles.submit}>
|
||||
Отправить запрос
|
||||
</button>
|
||||
</form>
|
||||
);
|
||||
}
|
||||
49
apps/web/src/components/TrustStrip/TrustStrip.module.scss
Normal file
49
apps/web/src/components/TrustStrip/TrustStrip.module.scss
Normal file
@@ -0,0 +1,49 @@
|
||||
.section {
|
||||
background: var(--color-slate-50);
|
||||
padding: 40px var(--space-lg);
|
||||
}
|
||||
|
||||
.inner {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(4, 1fr);
|
||||
gap: 24px;
|
||||
|
||||
@media (max-width: 1024px) {
|
||||
grid-template-columns: repeat(2, 1fr);
|
||||
}
|
||||
|
||||
@media (max-width: 640px) {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
}
|
||||
|
||||
.item {
|
||||
display: flex;
|
||||
gap: 14px;
|
||||
align-items: flex-start;
|
||||
}
|
||||
|
||||
.iconBox {
|
||||
width: 44px;
|
||||
height: 44px;
|
||||
border-radius: var(--border-radius-md);
|
||||
background: var(--color-orange-50);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-weight: 600;
|
||||
font-size: 14px;
|
||||
color: var(--color-slate-800);
|
||||
}
|
||||
|
||||
.desc {
|
||||
font-size: 12px;
|
||||
color: var(--color-text-muted);
|
||||
margin-top: 2px;
|
||||
}
|
||||
30
apps/web/src/components/TrustStrip/TrustStrip.tsx
Normal file
30
apps/web/src/components/TrustStrip/TrustStrip.tsx
Normal file
@@ -0,0 +1,30 @@
|
||||
import { Icon } from '@/components/Icon/Icon';
|
||||
import { IconName } from '@/components/Icon/icons';
|
||||
import styles from './TrustStrip.module.scss';
|
||||
|
||||
const items: { icon: IconName; title: string; desc: string }[] = [
|
||||
{ icon: 'truck', title: 'Доставка по РФ', desc: 'Склады в Европе, логистика до вашего города' },
|
||||
{ icon: 'shield', title: 'Гарантия', desc: 'Оригинальная продукция с сертификатами' },
|
||||
{ icon: 'clock', title: 'Быстрый отклик', desc: 'КП в течение 24 часов после запроса' },
|
||||
{ icon: 'star', title: 'Экспертиза', desc: 'Подбор аналогов и техническая поддержка' },
|
||||
];
|
||||
|
||||
export function TrustStrip() {
|
||||
return (
|
||||
<section className={styles.section}>
|
||||
<div className={styles.inner}>
|
||||
{items.map((t, i) => (
|
||||
<div key={i} className={styles.item}>
|
||||
<div className={styles.iconBox}>
|
||||
<Icon name={t.icon} size={24} color="var(--color-orange-500)" />
|
||||
</div>
|
||||
<div>
|
||||
<div className={styles.title}>{t.title}</div>
|
||||
<div className={styles.desc}>{t.desc}</div>
|
||||
</div>
|
||||
</div>
|
||||
))}
|
||||
</div>
|
||||
</section>
|
||||
);
|
||||
}
|
||||
42
apps/web/src/components/ui/Button/Button.module.scss
Normal file
42
apps/web/src/components/ui/Button/Button.module.scss
Normal file
@@ -0,0 +1,42 @@
|
||||
.button {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: var(--space-sm);
|
||||
padding: 10px 24px;
|
||||
border: none;
|
||||
border-radius: var(--border-radius-md);
|
||||
font-weight: 600;
|
||||
font-size: 14px;
|
||||
cursor: pointer;
|
||||
transition: background-color 0.2s, color 0.2s;
|
||||
white-space: nowrap;
|
||||
}
|
||||
|
||||
.primary {
|
||||
background: var(--color-primary);
|
||||
color: #fff;
|
||||
|
||||
&:hover {
|
||||
background: var(--color-primary-hover);
|
||||
}
|
||||
}
|
||||
|
||||
.secondary {
|
||||
background: transparent;
|
||||
color: var(--color-text);
|
||||
border: 1px solid var(--color-border);
|
||||
|
||||
&:hover {
|
||||
background: var(--color-slate-100);
|
||||
}
|
||||
}
|
||||
|
||||
.ghost {
|
||||
background: transparent;
|
||||
color: var(--color-primary);
|
||||
padding: 10px 12px;
|
||||
|
||||
&:hover {
|
||||
background: var(--color-orange-50);
|
||||
}
|
||||
}
|
||||
22
apps/web/src/components/ui/Button/Button.tsx
Normal file
22
apps/web/src/components/ui/Button/Button.tsx
Normal file
@@ -0,0 +1,22 @@
|
||||
import { ButtonHTMLAttributes } from 'react';
|
||||
import styles from './Button.module.scss';
|
||||
|
||||
interface ButtonProps extends ButtonHTMLAttributes<HTMLButtonElement> {
|
||||
variant?: 'primary' | 'secondary' | 'ghost';
|
||||
}
|
||||
|
||||
export function Button({
|
||||
variant = 'primary',
|
||||
className,
|
||||
children,
|
||||
...props
|
||||
}: ButtonProps) {
|
||||
return (
|
||||
<button
|
||||
className={`${styles.button} ${styles[variant]} ${className ?? ''}`}
|
||||
{...props}
|
||||
>
|
||||
{children}
|
||||
</button>
|
||||
);
|
||||
}
|
||||
@@ -0,0 +1,5 @@
|
||||
.container {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
padding: 0 var(--space-lg);
|
||||
}
|
||||
13
apps/web/src/components/ui/Container/Container.tsx
Normal file
13
apps/web/src/components/ui/Container/Container.tsx
Normal file
@@ -0,0 +1,13 @@
|
||||
import { ReactNode } from 'react';
|
||||
import styles from './Container.module.scss';
|
||||
|
||||
interface ContainerProps {
|
||||
children: ReactNode;
|
||||
className?: string;
|
||||
}
|
||||
|
||||
export function Container({ children, className }: ContainerProps) {
|
||||
return (
|
||||
<div className={`${styles.container} ${className ?? ''}`}>{children}</div>
|
||||
);
|
||||
}
|
||||
16
apps/web/src/data/brands.ts
Normal file
16
apps/web/src/data/brands.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
import { Brand } from '@/types';
|
||||
|
||||
export const brands: Brand[] = [
|
||||
{ id: 1, name: 'Bosch Rexroth', country: 'DE', logo: 'BR', category: 'Гидравлика' },
|
||||
{ id: 2, name: 'Festo', country: 'DE', logo: 'FE', category: 'Пневматика' },
|
||||
{ id: 3, name: 'Siemens', country: 'DE', logo: 'SI', category: 'АСУ' },
|
||||
{ id: 4, name: 'Parker', country: 'US', logo: 'PK', category: 'Гидравлика' },
|
||||
{ id: 5, name: 'HYDAC', country: 'DE', logo: 'HY', category: 'Гидравлика' },
|
||||
{ id: 6, name: 'Camozzi', country: 'IT', logo: 'CZ', category: 'Пневматика' },
|
||||
{ id: 7, name: 'Beckhoff', country: 'DE', logo: 'BK', category: 'АСУ' },
|
||||
{ id: 8, name: 'IMI Norgren', country: 'UK', logo: 'IN', category: 'Пневматика' },
|
||||
{ id: 9, name: 'ABB', country: 'CH', logo: 'AB', category: 'АСУ' },
|
||||
{ id: 10, name: 'Danfoss', country: 'DK', logo: 'DF', category: 'Гидравлика' },
|
||||
{ id: 11, name: 'Schneider Electric', country: 'FR', logo: 'SE', category: 'АСУ' },
|
||||
{ id: 12, name: 'HAWE', country: 'DE', logo: 'HW', category: 'Гидравлика' },
|
||||
];
|
||||
38
apps/web/src/data/categories.ts
Normal file
38
apps/web/src/data/categories.ts
Normal file
@@ -0,0 +1,38 @@
|
||||
import { Category } from '@/types';
|
||||
|
||||
export const categories: Category[] = [
|
||||
{
|
||||
slug: 'gidravlika',
|
||||
name: 'Гидравлика',
|
||||
icon: 'hydraulic',
|
||||
description: 'Насосы, распределители, фильтры, цилиндры, гидростанции',
|
||||
brands: 'Bosch Rexroth · Parker · HYDAC · Danfoss',
|
||||
color: 'var(--color-orange-500)',
|
||||
},
|
||||
{
|
||||
slug: 'pnevmatika',
|
||||
name: 'Пневматика',
|
||||
icon: 'pneumatic',
|
||||
description: 'Цилиндры, клапаны, FRL-модули, фитинги, вакуум',
|
||||
brands: 'Festo · Camozzi · IMI Norgren · Metal Work',
|
||||
color: 'var(--color-teal-500)',
|
||||
},
|
||||
{
|
||||
slug: 'asu',
|
||||
name: 'АСУ',
|
||||
icon: 'automation',
|
||||
description: 'ПЛК, частотники, сервоприводы, датчики, HMI, энкодеры',
|
||||
brands: 'Siemens · Beckhoff · ABB · Pepperl+Fuchs',
|
||||
color: 'var(--color-navy-400)',
|
||||
},
|
||||
{
|
||||
slug: 'zip',
|
||||
name: 'ЗИП',
|
||||
icon: 'spares',
|
||||
description: 'Запасные части, контакторы, реле, вспомогательные компоненты',
|
||||
brands: 'Siemens · Schneider · Phoenix Contact · WAGO',
|
||||
color: '#7B1FA2',
|
||||
},
|
||||
];
|
||||
|
||||
export const allCategories = ['Все', ...categories.map((c) => c.name)];
|
||||
34
apps/web/src/data/navigation.ts
Normal file
34
apps/web/src/data/navigation.ts
Normal file
@@ -0,0 +1,34 @@
|
||||
export const headerNav = [
|
||||
{ label: 'Каталог', href: '/catalog' },
|
||||
{ label: 'Бренды', href: '/catalog' },
|
||||
{ label: 'О компании', href: '/about' },
|
||||
{ label: 'RFQ', href: '/rfq' },
|
||||
{ label: 'Контакты', href: '/contact' },
|
||||
];
|
||||
|
||||
export const footerColumns = [
|
||||
{
|
||||
title: 'Направления',
|
||||
links: [
|
||||
{ label: 'Гидравлика', href: '/catalog/gidravlika' },
|
||||
{ label: 'Пневматика', href: '/catalog/pnevmatika' },
|
||||
{ label: 'АСУ', href: '/catalog/asu' },
|
||||
{ label: 'ЗИП', href: '/catalog/zip' },
|
||||
],
|
||||
},
|
||||
{
|
||||
title: 'Компания',
|
||||
links: [
|
||||
{ label: 'О компании', href: '/about' },
|
||||
{ label: 'Контакты', href: '/contact' },
|
||||
{ label: 'Запрос цены (RFQ)', href: '/rfq' },
|
||||
],
|
||||
},
|
||||
{
|
||||
title: 'Контакты',
|
||||
links: [
|
||||
{ label: '+49 (0) 40 123-4567', href: 'tel:+494012345678' },
|
||||
{ label: 'info@pan-prom.eu', href: 'mailto:info@pan-prom.eu' },
|
||||
],
|
||||
},
|
||||
];
|
||||
14
apps/web/src/data/products.ts
Normal file
14
apps/web/src/data/products.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import { Product } from '@/types';
|
||||
|
||||
export const products: Product[] = [
|
||||
{ id: 1, sku: '4WRPEH 6 C3B12L', name: 'Пропорциональный распределитель', brand: 'Bosch Rexroth', category: 'Гидравлика', subcategory: 'Распределители', price: 'По запросу', image: '', inStock: true },
|
||||
{ id: 2, sku: 'DSBC-50-200-PA', name: 'Пневмоцилиндр стандартный ISO 15552', brand: 'Festo', category: 'Пневматика', subcategory: 'Цилиндры', price: 'По запросу', image: '', inStock: true },
|
||||
{ id: 3, sku: '6ES7 511-1AK02', name: 'CPU 1511-1 PN', brand: 'Siemens', category: 'АСУ', subcategory: 'Контроллеры', price: 'По запросу', image: '', inStock: false },
|
||||
{ id: 4, sku: 'D1VW020BNJW', name: 'Гидрораспределитель с электроуправлением', brand: 'Parker', category: 'Гидравлика', subcategory: 'Распределители', price: 'По запросу', image: '', inStock: true },
|
||||
{ id: 5, sku: '0160 D 010 BH4HC', name: 'Фильтроэлемент напорный', brand: 'HYDAC', category: 'Гидравлика', subcategory: 'Фильтры', price: 'По запросу', image: '', inStock: true },
|
||||
{ id: 6, sku: '61F-2H-060-T9', name: 'Пневмоцилиндр серии 61', brand: 'Camozzi', category: 'Пневматика', subcategory: 'Цилиндры', price: 'По запросу', image: '', inStock: false },
|
||||
{ id: 7, sku: 'CX2040-0135', name: 'Embedded PC', brand: 'Beckhoff', category: 'АСУ', subcategory: 'Контроллеры', price: 'По запросу', image: '', inStock: true },
|
||||
{ id: 8, sku: 'MVA-D-3-FES', name: 'Клапан управляющий', brand: 'HAWE', category: 'Гидравлика', subcategory: 'Клапаны', price: 'По запросу', image: '', inStock: true },
|
||||
{ id: 9, sku: 'ENI58IL-H12DA5-1024', name: 'Энкодер инкрементальный', brand: 'Pepperl+Fuchs', category: 'АСУ', subcategory: 'Энкодеры', price: 'По запросу', image: '', inStock: true },
|
||||
{ id: 10, sku: '3RH1921-1FA22', name: 'Блок вспомогательных контактов', brand: 'Siemens', category: 'ЗИП', subcategory: 'Контакторы', price: 'По запросу', image: '', inStock: true },
|
||||
];
|
||||
19
apps/web/src/styles/_mixins.scss
Normal file
19
apps/web/src/styles/_mixins.scss
Normal file
@@ -0,0 +1,19 @@
|
||||
@use 'variables' as *;
|
||||
|
||||
@mixin container {
|
||||
max-width: var(--max-width);
|
||||
margin: 0 auto;
|
||||
padding: 0 var(--space-lg);
|
||||
}
|
||||
|
||||
@mixin respond-to($bp) {
|
||||
@media (min-width: $bp) {
|
||||
@content;
|
||||
}
|
||||
}
|
||||
|
||||
@mixin card {
|
||||
background: var(--color-surface);
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: var(--border-radius-lg);
|
||||
}
|
||||
4
apps/web/src/styles/_variables.scss
Normal file
4
apps/web/src/styles/_variables.scss
Normal file
@@ -0,0 +1,4 @@
|
||||
$breakpoint-sm: 640px;
|
||||
$breakpoint-md: 768px;
|
||||
$breakpoint-lg: 1024px;
|
||||
$breakpoint-xl: 1280px;
|
||||
7
apps/web/src/types/brand.ts
Normal file
7
apps/web/src/types/brand.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
export interface Brand {
|
||||
id: number;
|
||||
name: string;
|
||||
country: string;
|
||||
logo: string;
|
||||
category: string;
|
||||
}
|
||||
24
apps/web/src/types/category.ts
Normal file
24
apps/web/src/types/category.ts
Normal file
@@ -0,0 +1,24 @@
|
||||
export type CategorySlug = 'gidravlika' | 'pnevmatika' | 'asu' | 'zip';
|
||||
|
||||
export interface Category {
|
||||
slug: CategorySlug;
|
||||
name: string;
|
||||
icon: string;
|
||||
description: string;
|
||||
brands: string;
|
||||
color: string;
|
||||
}
|
||||
|
||||
export const categorySlugMap: Record<string, CategorySlug> = {
|
||||
'Гидравлика': 'gidravlika',
|
||||
'Пневматика': 'pnevmatika',
|
||||
'АСУ': 'asu',
|
||||
'ЗИП': 'zip',
|
||||
};
|
||||
|
||||
export const categoryNameMap: Record<CategorySlug, string> = {
|
||||
gidravlika: 'Гидравлика',
|
||||
pnevmatika: 'Пневматика',
|
||||
asu: 'АСУ',
|
||||
zip: 'ЗИП',
|
||||
};
|
||||
4
apps/web/src/types/index.ts
Normal file
4
apps/web/src/types/index.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
export type { Brand } from './brand';
|
||||
export type { Product } from './product';
|
||||
export type { Category, CategorySlug } from './category';
|
||||
export { categorySlugMap, categoryNameMap } from './category';
|
||||
11
apps/web/src/types/product.ts
Normal file
11
apps/web/src/types/product.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
export interface Product {
|
||||
id: number;
|
||||
sku: string;
|
||||
name: string;
|
||||
brand: string;
|
||||
category: string;
|
||||
subcategory: string;
|
||||
price: string;
|
||||
image: string;
|
||||
inStock: boolean;
|
||||
}
|
||||
Reference in New Issue
Block a user