diff --git a/app/events/page.tsx b/app/events/page.tsx
new file mode 100644
index 0000000..0548e6c
--- /dev/null
+++ b/app/events/page.tsx
@@ -0,0 +1,32 @@
+import { Button, EventsPartial, Section } from "@/components";
+import { loadEvents } from "@/lib/mdxParser/mdxParser";
+
+export default function Events({}: {}) {
+ return (
+
+
+ Events
+
+ Join us for various events focused on open source in the AECO
+ industry. From community calls to workshops and conferences, we bring
+ together practitioners and enthusiasts to share knowledge and drive
+ innovation.
+
+
+
+
+
+
+
+
+
+ );
+}
diff --git a/app/globals.css b/app/globals.css
index 5160eb1..0651699 100644
--- a/app/globals.css
+++ b/app/globals.css
@@ -14,3 +14,13 @@ svg:not(:root) {
overflow-clip-margin: content-box;
overflow: hidden;
}
+
+.transition-all {
+ transition-property: all;
+ transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
+ transition-duration: 300ms;
+}
+
+.section-transition {
+ transition: background-color 500ms ease-in-out;
+}
diff --git a/app/layout.tsx b/app/layout.tsx
index 6a994ea..f369d42 100644
--- a/app/layout.tsx
+++ b/app/layout.tsx
@@ -33,7 +33,7 @@ export const metadata: Metadata = {
const navItems = [
{ name: "Projects", target: "/projects" },
- { name: "Events", target: "/#events" },
+ { name: "Events", target: "/events" },
{ name: "Trainings", target: "/trainings" },
{ name: "About us", target: "/#who-is-behind-the-initiative" },
];
diff --git a/app/page.tsx b/app/page.tsx
index f078404..acb3dfe 100644
--- a/app/page.tsx
+++ b/app/page.tsx
@@ -11,6 +11,7 @@ import Image from "next/image";
import team from "../content/team.json";
import ContactCard from "@/components/src/contactCard";
import { PartnersPartial } from "@/components/src/partials/partners";
+import { EventsIndexPartial } from "@/components/src/partials/events";
export default function Home() {
const discordLink = process.env.DISCORD_LINK || "";
@@ -75,11 +76,11 @@ export default function Home() {
exchange – find them here + further events that we attend as well.
-
-
-
+ {/* */}
- {!es.length
- ? "No pending events"
- : es.map((e) => (
-
- ))}
+
+
+ {showPast ? "Past Events" : "Upcoming Events"}
+
+
+ {!es.length
+ ? "No pending events"
+ : es.map((e) => (
+
+ ))}
+
+
+ );
+}
+
+export function EventsIndexPartial() {
+ let eventsParsed = loadEvents();
+
+ const pastEvents = eventsParsed
+ .filter((e) => e.metadata.isPast)
+ .sort((a, b) => (a.metadata.start < b.metadata.start ? 1 : -1))
+ .slice(0, 3);
+
+ const futureEvents = eventsParsed
+ .filter((e) => !e.metadata.isPast)
+ .sort((a, b) => (a.metadata.start < b.metadata.start ? 1 : -1));
+
+ return (
+
+ {/* Upcoming Events Section */}
+
+
+ Upcoming Events
+
+
+ {futureEvents.length === 0 ? (
+
No upcoming events
+ ) : (
+ futureEvents.map((e) => (
+
+ ))
+ )}
+
+
+
+ {/* Past Events Section */}
+ {pastEvents.length > 0 && (
+
+
+ Past Events
+
+
+ {pastEvents.map((e) => (
+
+
+
+ ))}
+
+
+ Discover More
+
+
+ View our complete archive of past and upcoming events
+
+
+
+
+
+
+
+ )}
);
}
diff --git a/lib/mdxParser/mdxMappers.ts b/lib/mdxParser/mdxMappers.ts
index 79f8713..feef9e3 100644
--- a/lib/mdxParser/mdxMappers.ts
+++ b/lib/mdxParser/mdxMappers.ts
@@ -152,7 +152,6 @@ const metadataTransforms: MetadataTransformer = {
const isPast = eventEnd.getTime() < Date.now();
-
return {
...defaultContent.metadata,
start: eventStart,
diff --git a/vitest.config.ts b/vitest.config.ts
new file mode 100644
index 0000000..cbc92a0
--- /dev/null
+++ b/vitest.config.ts
@@ -0,0 +1,14 @@
+import { defineConfig } from 'vitest/config';
+import { resolve } from 'path';
+
+export default defineConfig({
+ test: {
+ // Other test configuration...
+ },
+ resolve: {
+ alias: {
+ '@': resolve(__dirname, './'),
+ '@lib': resolve(__dirname, './lib')
+ }
+ }
+});
\ No newline at end of file