Skip to content

Commit 9499a1a

Browse files
Fix blog links error
1 parent c4ad5ef commit 9499a1a

File tree

2 files changed

+94
-94
lines changed

2 files changed

+94
-94
lines changed

src/components/Blog.jsx

Lines changed: 86 additions & 86 deletions
Original file line numberDiff line numberDiff line change
@@ -1,95 +1,95 @@
11
import { motion } from "framer-motion";
22

3-
import blog1 from "../assets/images/blog1.png";
4-
import blog2 from "../assets/images/blog2.png";
5-
import blog3 from "../assets/images/blog3.png";
3+
import blog1 from "../assets/images/template/blog1.jpg";
4+
import blog2 from "../assets/images/template/blog2.png";
5+
import blog3 from "../assets/images/template/blog3.png";
66

77
const blogData = [
8-
{
9-
title: "AI and Machine Learning",
10-
subtitle:
11-
"Discover insights and trends in the world of data analytics. Delve into how AI and machine learning are revolutionizing industries",
12-
image: blog1.src,
13-
},
14-
{
15-
title: "Data-Driven Analytics",
16-
subtitle: "Explore the impact of AI and ML on data analytics.",
17-
image: blog2.src,
18-
},
19-
{
20-
title: "Real-Time Data Processing",
21-
subtitle: "Learn about the importance of processing real-time.",
22-
image: blog3.src,
23-
},
8+
{
9+
title: "AI and Machine Learning",
10+
subtitle:
11+
"Discover insights and trends in the world of data analytics. Delve into how AI and machine learning are revolutionizing industries",
12+
image: blog1.src,
13+
},
14+
{
15+
title: "Data-Driven Analytics",
16+
subtitle: "Explore the impact of AI and ML on data analytics.",
17+
image: blog2.src,
18+
},
19+
{
20+
title: "Real-Time Data Processing",
21+
subtitle: "Learn about the importance of processing real-time.",
22+
image: blog3.src,
23+
},
2424
];
2525

2626
export const Blog = () => (
27-
<section className="w-screen flex justify-center bg-bgDark2 relative ">
28-
<div className="absolute -top-16" id="blog" />
29-
<div className="pb-0 pt-4 bg-bgDark2 2xl:w-[1200px] lg:w-[1000px] xl:w-[1150px] ">
30-
<motion.div
31-
initial={{ opacity: 0 }}
32-
whileInView={{ opacity: 1 }}
33-
viewport={{ once: true }}
34-
transition={{ duration: 0.5, delay: 0.2 }}
35-
>
36-
<div className="container px-4 mb-20">
37-
<div className="max-w-2xl text-center lg:text-left mb-16 mx-auto lg:ml-0 lg:mr-0">
38-
<span className="block-subtitle">Our Blog</span>
39-
<h2 className="mt-6 mb-6 text-4xl lg:text-5xl font-bold font-heading text-primaryText">
40-
Latest Insights
41-
</h2>
42-
<p className="mb-6 text-secondaryText">
43-
Stay updated with the latest trends and insights in our industry.
44-
</p>
45-
</div>
46-
<div className="flex 2xl:w-[1200px] lg:w-[1000px] xl:w-[1150px] flex-wrap -mx-4 items-start h-auto sm:h-[30rem] lg:h-[31rem] xl:h-[35rem]">
47-
<div className="flex sm:hidden lg:flex w-11/12 mx-auto sm:ml-0 sm:mr-0 lg:w-1/2 xl:w-3/5 px-4 mb-8 lg:mb-0 h-full">
48-
<a href="/blog/article">
49-
<div className="p-6 sm:p-10 bg-bgDark3 rounded-3xl h-full hover:bg-bgDark3Hover transition cursor-pointer">
50-
<img
51-
src={blogData[0].image}
52-
alt={blogData[0].title}
53-
className="rounded-3xl mb-6 w-full"
54-
aria-label={blogData[0].title}
55-
/>
56-
<h3 className="mb-4 text-2xl font-bold font-heading text-primaryText">
57-
{blogData[0].title}
58-
</h3>
59-
<p className="text-secondaryText leading-loose">
60-
{blogData[0].subtitle}
61-
</p>
62-
</div>
63-
</a>
64-
</div>
65-
<div className="hidden sm:flex mx-auto lg:ml-0 lg:mr-0 w-11/12 sm:w-4/5 lg:w-1/2 xl:w-2/5 px-4 flex-col justify-between h-full">
66-
{blogData.slice(1).map((post, index) => (
67-
<a
68-
href="/blog/article"
69-
key={`${post.title}-${index}`}
70-
className=" flex gap-4 p-10 bg-bgDark3 rounded-3xl min-h-1/2 h-1/2 max-h-[47%]
27+
<section className="w-screen flex justify-center bg-bgDark2 relative ">
28+
<div className="absolute -top-16" id="blog" />
29+
<div className="pb-0 pt-4 bg-bgDark2 2xl:w-[1200px] lg:w-[1000px] xl:w-[1150px] ">
30+
<motion.div
31+
initial={{ opacity: 0 }}
32+
whileInView={{ opacity: 1 }}
33+
viewport={{ once: true }}
34+
transition={{ duration: 0.5, delay: 0.2 }}
35+
>
36+
<div className="container px-4 mb-20">
37+
<div className="max-w-2xl text-center lg:text-left mb-16 mx-auto lg:ml-0 lg:mr-0">
38+
<span className="block-subtitle">Our Blog</span>
39+
<h2 className="mt-6 mb-6 text-4xl lg:text-5xl font-bold font-heading text-primaryText">
40+
Latest Insights
41+
</h2>
42+
<p className="mb-6 text-secondaryText">
43+
Stay updated with the latest trends and insights in our industry.
44+
</p>
45+
</div>
46+
<div className="flex 2xl:w-[1200px] lg:w-[1000px] xl:w-[1150px] flex-wrap -mx-4 items-start h-auto sm:h-[30rem] lg:h-[31rem] xl:h-[35rem]">
47+
<div className="flex sm:hidden lg:flex w-11/12 mx-auto sm:ml-0 sm:mr-0 lg:w-1/2 xl:w-3/5 px-4 mb-8 lg:mb-0 h-full">
48+
<a href="/blog/article">
49+
<div className="p-6 sm:p-10 bg-bgDark3 rounded-3xl h-full hover:bg-bgDark3Hover transition cursor-pointer">
50+
<img
51+
src={blogData[0].image}
52+
alt={blogData[0].title}
53+
className="rounded-3xl mb-6 w-full"
54+
aria-label={blogData[0].title}
55+
/>
56+
<h3 className="mb-4 text-2xl font-bold font-heading text-primaryText">
57+
{blogData[0].title}
58+
</h3>
59+
<p className="text-secondaryText leading-loose">
60+
{blogData[0].subtitle}
61+
</p>
62+
</div>
63+
</a>
64+
</div>
65+
<div className="hidden sm:flex mx-auto lg:ml-0 lg:mr-0 w-11/12 sm:w-4/5 lg:w-1/2 xl:w-2/5 px-4 flex-col justify-between h-full">
66+
{blogData.slice(1).map((post, index) => (
67+
<a
68+
href="/blog/article"
69+
key={`${post.title}-${index}`}
70+
className=" flex gap-4 p-10 bg-bgDark3 rounded-3xl min-h-1/2 h-1/2 max-h-[47%]
7171
hover:bg-bgDark3Hover transition cursor-pointer"
72-
>
73-
<div className="pt-2">
74-
<h3 className="mb-4 text-xl font-bold font-heading text-primaryText">
75-
{post.title}
76-
</h3>
77-
<p className="text-secondaryText leading-loose">
78-
{post.subtitle}
79-
</p>
80-
</div>
81-
<img
82-
src={post.image}
83-
alt={post.title}
84-
className="rounded-3xl mb-6 w-[9rem] h-[9rem] lg:w-auto lg:h-auto xl:w-full"
85-
aria-label={post.title}
86-
/>
87-
</a>
88-
))}
89-
</div>
90-
</div>
91-
</div>
92-
</motion.div>
93-
</div>
94-
</section>
72+
>
73+
<div className="pt-2">
74+
<h3 className="mb-4 text-xl font-bold font-heading text-primaryText">
75+
{post.title}
76+
</h3>
77+
<p className="text-secondaryText leading-loose">
78+
{post.subtitle}
79+
</p>
80+
</div>
81+
<img
82+
src={post.image}
83+
alt={post.title}
84+
className="rounded-3xl mb-6 w-[9rem] h-[9rem] lg:w-auto lg:h-auto xl:w-full"
85+
aria-label={post.title}
86+
/>
87+
</a>
88+
))}
89+
</div>
90+
</div>
91+
</div>
92+
</motion.div>
93+
</div>
94+
</section>
9595
);

src/pages/blog/article/index.astro

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
---
2-
import Layout from '../../../layouts/Layout.astro'
3-
import { Navbar } from '../../../components/Navbar.jsx'
4-
import { Article } from '../../../components/Article.jsx'
5-
import { Footer } from '../../../components/Footer.jsx'
6-
import blog1 from '../../../assets/images/blog1.jpg'
7-
import '../../../styles/Theme.css'
8-
import { ScrollUpButton } from '../../../components/ScrollUpButton'
2+
import Layout from "../../../layouts/Layout.astro";
3+
import { Navbar } from "../../../components/Navbar.jsx";
4+
import { Article } from "../../../components/Article.jsx";
5+
import { Footer } from "../../../components/Footer.jsx";
6+
import blog1 from "../../../assets/images/template/blog1.jpg";
7+
import "../../../styles/Theme.css";
8+
import { ScrollUpButton } from "../../../components/ScrollUpButton";
99
1010
const articleData = {
1111
title: "AI and Machine Learning",
@@ -26,7 +26,7 @@ const articleData = {
2626
<p>Stay tuned as we continue to explore the evolving landscape of AI and its transformative impact on business analytics and financing.</p>
2727
`,
2828
footer: "~ Duncan Idaho"
29-
}
29+
};
3030
---
3131

3232
<Layout title={articleData.title}>

0 commit comments

Comments
 (0)