Skip to content

Commit 685cd91

Browse files
Merge pull request #48 from bylogos-io/seo
feat: add SEO to all pages
2 parents e53c3ac + defadc1 commit 685cd91

File tree

15 files changed

+1733
-1687
lines changed

15 files changed

+1733
-1687
lines changed

src/app/chat/page.tsx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,12 @@
1-
import Chat from "@/sections/chat/Chat";
1+
import type { Metadata } from 'next';
2+
import Chat from '@/sections/chat/Chat';
3+
4+
export const metadata: Metadata = {
5+
title: 'Asistente AI',
6+
description:
7+
'Interactúa con nuestra inteligencia artificial para resolver dudas sobre SCADA, BMS y AIIoT.',
8+
};
29

310
export default async function Index() {
4-
return <Chat />;
11+
return <Chat />;
512
}

src/app/industrias/page.tsx

Lines changed: 20 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,23 @@
1-
import { Box } from "@mui/material";
2-
import { IndustrySlider } from "@/sections/industries/IndustrySlider";
3-
import { IndustryCards } from "@/sections/industries/IndustryCards";
4-
import { IndustryTitle } from "@/sections/industries/IndustryTitle";
5-
import { IndustryFooter } from "@/sections/industries/IndustryFooter";
1+
import type { Metadata } from 'next';
2+
import { Box } from '@mui/material';
3+
import { IndustrySlider } from '@/sections/industries/IndustrySlider';
4+
import { IndustryCards } from '@/sections/industries/IndustryCards';
5+
import { IndustryTitle } from '@/sections/industries/IndustryTitle';
6+
import { IndustryFooter } from '@/sections/industries/IndustryFooter';
7+
8+
export const metadata: Metadata = {
9+
title: 'Soluciones por Industria',
10+
description:
11+
'Descubre cómo LogOS optimiza operaciones en Smart Cities, gestión de edificios y entornos industriales.',
12+
};
613

714
export default function Industrias() {
8-
return (
9-
<Box component="main">
10-
<IndustryTitle />
11-
<IndustrySlider />
12-
<IndustryCards />
13-
<IndustryFooter />
14-
</Box>
15-
);
15+
return (
16+
<Box component='main'>
17+
<IndustryTitle />
18+
<IndustrySlider />
19+
<IndustryCards />
20+
<IndustryFooter />
21+
</Box>
22+
);
1623
}

src/app/layout.tsx

Lines changed: 60 additions & 77 deletions
Original file line numberDiff line numberDiff line change
@@ -1,91 +1,74 @@
1-
import { MuiRootProvider } from "@/providers/MuiRootProvider";
2-
import type { Metadata } from "next";
3-
import { Geist, Geist_Mono } from "next/font/google";
4-
import InitColorSchemeScript from "@mui/material/InitColorSchemeScript";
1+
import { MuiRootProvider } from '@/providers/MuiRootProvider';
2+
import type { Metadata } from 'next';
3+
import { Geist, Geist_Mono } from 'next/font/google';
4+
import InitColorSchemeScript from '@mui/material/InitColorSchemeScript';
55
const geistSans = Geist({
6-
variable: "--font-geist-sans",
7-
subsets: ["latin"],
6+
variable: '--font-geist-sans',
7+
subsets: ['latin'],
88
});
99

1010
const geistMono = Geist_Mono({
11-
variable: "--font-geist-mono",
12-
subsets: ["latin"],
11+
variable: '--font-geist-mono',
12+
subsets: ['latin'],
1313
});
1414

1515
export const metadata: Metadata = {
16-
title: "LogOS",
17-
description:
18-
"Mejora tu eficiencia usando nuestro sistema de gestión inteligente. SCADA, BMS, AIIoT",
19-
applicationName: "LogOS",
20-
keywords: [
21-
"SCADA",
22-
"industrial",
23-
"AIIoT",
24-
"AI",
25-
"IIoT",
26-
"BMS",
27-
"HMI",
28-
"SEEED",
29-
"KUNBUS",
30-
"Smart Cities",
31-
"Smart City",
32-
"Building Management System",
33-
"Building",
34-
"Management",
35-
"System",
36-
"events",
37-
"alarms",
38-
"bylogosio",
39-
"logosia",
40-
"bylogosia",
41-
"bylogosiot",
42-
"logosio",
43-
"logosiot",
44-
"IoT",
45-
"automatización",
46-
"LogOS",
47-
"ByLogos",
48-
"IA",
49-
"Logos",
50-
"monitorización",
51-
"solución",
52-
"local-first",
53-
"software",
54-
"hardware",
55-
],
56-
robots: {
57-
googleBot: {
58-
index: true,
59-
follow: true,
60-
},
61-
},
62-
authors: [
63-
{ name: "LogOS", url: "https://www.linkedin.com/company/bylogos/" },
64-
],
65-
creator: "Javier Vargas",
66-
metadataBase: new URL("https://bylogos.io"),
16+
title: {
17+
default: 'Inteligencia Industrial SCADA, BMS, AIIoT | LogOS',
18+
template: '%s | LogOS',
19+
},
20+
description:
21+
'LogOS: Sistema de gestión inteligente para SCADA, BMS y AIIoT. Mejora la eficiencia operacional en Smart Cities e industria.',
22+
applicationName: 'LogOS',
23+
keywords: [
24+
'LogOS',
25+
'SCADA',
26+
'BMS',
27+
'AIIoT',
28+
'IIoT',
29+
'Industrial AI',
30+
'Smart Cities',
31+
'Automatización Industrial',
32+
'Monitorización en Tiempo Real',
33+
'Gestión de Edificios',
34+
'HMI',
35+
'ByLogos',
36+
],
37+
robots: {
38+
index: true,
39+
follow: true,
40+
googleBot: {
41+
index: true,
42+
follow: true,
43+
},
44+
},
45+
authors: [
46+
{ name: 'LogOS', url: 'https://www.linkedin.com/company/bylogos/' },
47+
],
48+
creator: 'Javier Vargas',
49+
metadataBase: new URL('https://bylogos.io'),
6750
};
6851

69-
import { ConditionalHeader } from "@/sections/layout/ConditionalHeader";
70-
import { ConditionalFooter } from "@/sections/layout/ConditionalFooter";
52+
import { ConditionalHeader } from '@/sections/layout/ConditionalHeader';
53+
import { ConditionalFooter } from '@/sections/layout/ConditionalFooter';
7154

7255
export default function RootLayout({
73-
children,
56+
children,
7457
}: Readonly<{
75-
children: React.ReactNode;
58+
children: React.ReactNode;
7659
}>) {
77-
return (
78-
<html lang="en" suppressHydrationWarning>
79-
<body
80-
className={`${geistSans.variable} ${geistMono.variable} antialiased`}
81-
>
82-
<InitColorSchemeScript attribute="class" defaultMode="dark" />
83-
<MuiRootProvider>
84-
<ConditionalHeader />
85-
{children}
86-
<ConditionalFooter />
87-
</MuiRootProvider>
88-
</body>
89-
</html>
90-
);
60+
return (
61+
<html lang='en' suppressHydrationWarning>
62+
<body
63+
className={`${geistSans.variable} ${geistMono.variable} antialiased`}
64+
>
65+
<InitColorSchemeScript attribute='class' defaultMode='dark' />
66+
<MuiRootProvider>
67+
<ConditionalHeader />
68+
{children}
69+
<ConditionalFooter />
70+
</MuiRootProvider>
71+
</body>
72+
</html>
73+
);
9174
}

src/app/news/[slug]/page.tsx

Lines changed: 29 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,44 @@
1-
import { news } from "@/velite";
2-
import { notFound } from "next/navigation";
3-
import { Metadata } from "next";
4-
import { NewsPost } from "@/sections/news/NewsPost";
1+
import { news } from '@/velite';
2+
import { notFound } from 'next/navigation';
3+
import { Metadata } from 'next';
4+
import { NewsPost } from '@/sections/news/NewsPost';
55

66
interface PageProps {
7-
params: Promise<{ slug: string }>;
7+
params: Promise<{ slug: string }>;
88
}
99

1010
export async function generateStaticParams() {
11-
return news.map((post) => ({
12-
slug: post.slug.split("/").pop(), // "news/my-post" -> "my-post"
13-
}));
11+
return news.map((post) => ({
12+
slug: post.slug.split('/').pop(), // "news/my-post" -> "my-post"
13+
}));
1414
}
1515

1616
export async function generateMetadata({
17-
params,
17+
params,
1818
}: PageProps): Promise<Metadata> {
19-
const resolvedParams = await params;
20-
// Velite slug is "news/slug", params.slug is "slug"
21-
const post = news.find((p) => p.slug === `news/${resolvedParams.slug}`);
22-
23-
if (!post) {
24-
return {};
25-
}
26-
27-
return {
28-
title: `${post.title} | Logos News`,
29-
description: post.description,
30-
};
19+
const resolvedParams = await params;
20+
// Velite slug is 'news/slug', params.slug is 'slug'
21+
const post = news.find((p) => p.slug === `news/${resolvedParams.slug}`);
22+
23+
if (!post) {
24+
return {
25+
title: 'Noticia no encontrada',
26+
};
27+
}
28+
29+
return {
30+
title: post.title,
31+
description: post.description,
32+
};
3133
}
3234

3335
export default async function NewsPostPage({ params }: PageProps) {
34-
const resolvedParams = await params;
35-
const post = news.find((p) => p.slug === `news/${resolvedParams.slug}`);
36+
const resolvedParams = await params;
37+
const post = news.find((p) => p.slug === `news/${resolvedParams.slug}`);
3638

37-
if (!post) {
38-
notFound();
39-
}
39+
if (!post) {
40+
notFound();
41+
}
4042

41-
return <NewsPost post={post} />;
43+
return <NewsPost post={post} />;
4244
}

src/app/news/page.tsx

Lines changed: 24 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
import { news } from "@/velite"; // Using alias
2-
import { Box } from "@mui/material";
3-
import { NewsTitle } from "@/sections/news/NewsTitle";
4-
import { NewsSlider } from "@/sections/news/NewsSlider";
5-
import { NewsPosts } from "@/sections/news/NewsPosts";
6-
import { IndustryFooter } from "@/sections/industries/IndustryFooter"; // Reusing footer as requested ('mismo footer') - actually prompt said "same header and footer as most sections" which usually means global layout, but Industry page has IndustryFooter.
1+
import { news } from '@/velite'; // Using alias
2+
import { Box } from '@mui/material';
3+
import { NewsTitle } from '@/sections/news/NewsTitle';
4+
import { NewsSlider } from '@/sections/news/NewsSlider';
5+
import { NewsPosts } from '@/sections/news/NewsPosts';
6+
import { IndustryFooter } from '@/sections/industries/IndustryFooter'; // Reusing footer as requested ('mismo footer') - actually prompt said "same header and footer as most sections" which usually means global layout, but Industry page has IndustryFooter.
7+
import { Metadata } from 'next';
78
// User said: "usará mismo header y footer que la mayoria de las secciones del website"
89
// Industry page uses `IndustryFooter`. Global layout likely handles Header/Footer if not overridden.
910
// Industries page explicitly imports `IndustryFooter`. I will check if I should use that or default.
@@ -52,26 +53,26 @@ export default function Industrias() {
5253
// Better yet, I'll just write the page without footer first, as that's safer for "most sections".
5354
// But I need to sort the news.
5455

55-
export const metadata = {
56-
title: "Noticias y Novedades | Logos",
57-
description:
58-
"Mantente informado con las últimas noticias sobre tecnología industrial, IA e IoT.",
56+
export const metadata: Metadata = {
57+
title: 'Noticias y Blog',
58+
description:
59+
'Mantente informado con las últimas noticias sobre tecnología industrial, IA e IoT de la mano de LogOS.',
5960
};
6061

6162
export default function NewsPage() {
62-
// Sort posts by date descending (newest first)
63-
const sortedPosts = news.sort((a, b) => {
64-
return new Date(b.date).getTime() - new Date(a.date).getTime();
65-
});
63+
// Sort posts by date descending (newest first)
64+
const sortedPosts = news.sort((a, b) => {
65+
return new Date(b.date).getTime() - new Date(a.date).getTime();
66+
});
6667

67-
// Top 5 for slider
68-
const sliderPosts = sortedPosts.slice(0, 5);
68+
// Top 5 for slider
69+
const sliderPosts = sortedPosts.slice(0, 5);
6970

70-
return (
71-
<Box component="main">
72-
<NewsTitle />
73-
<NewsSlider posts={sliderPosts} />
74-
<NewsPosts posts={sortedPosts} />
75-
</Box>
76-
);
71+
return (
72+
<Box component='main'>
73+
<NewsTitle />
74+
<NewsSlider posts={sliderPosts} />
75+
<NewsPosts posts={sortedPosts} />
76+
</Box>
77+
);
7778
}

src/app/nosotros/page.tsx

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,22 @@
1-
import { Container, Typography } from "@mui/material";
1+
import type { Metadata } from 'next';
2+
import { Container, Typography } from '@mui/material';
3+
4+
export const metadata: Metadata = {
5+
title: 'Sobre Nosotros',
6+
description:
7+
'Conoce al equipo detrás de LogOS y nuestra misión de transformar la gestión industrial mediante IA y AIIoT.',
8+
};
29

310
export default function Nosotros() {
4-
return (
5-
<Container sx={{ mt: 15, mb: 10, flex: 1 }}>
6-
<Typography variant="h2" fontWeight={800} gutterBottom>
7-
Nosotros
8-
</Typography>
9-
<Typography variant="h5" color="text.secondary">
10-
Esta página está en construcción. Pronto conocerás más sobre LogOS y
11-
nuestro equipo.
12-
</Typography>
13-
</Container>
14-
);
11+
return (
12+
<Container sx={{ mt: 15, mb: 10, flex: 1 }}>
13+
<Typography variant='h2' fontWeight={800} gutterBottom>
14+
Nosotros
15+
</Typography>
16+
<Typography variant='h5' color='text.secondary'>
17+
Esta página está en construcción. Pronto conocerás más sobre LogOS y
18+
nuestro equipo.
19+
</Typography>
20+
</Container>
21+
);
1522
}

0 commit comments

Comments
 (0)