diff --git a/frontend/src/pages/Home.tsx b/frontend/src/pages/Home.tsx index 07a264223a..78b06da9cd 100644 --- a/frontend/src/pages/Home.tsx +++ b/frontend/src/pages/Home.tsx @@ -17,7 +17,6 @@ import { AlgoliaResponseType } from 'types/algolia' import { ChapterTypeAlgolia } from 'types/chapter' import { EventType } from 'types/event' import { MainPageData } from 'types/home' -import { capitalize } from 'utils/capitalize' import { formatDate, formatDateRange } from 'utils/dateFormatter' import AnimatedCounter from 'components/AnimatedCounter' import ChapterMap from 'components/ChapterMap' @@ -111,170 +110,174 @@ export default function Home() { ] return ( -
-
-
-

- Welcome to OWASP Nest -

-

- Your gateway to OWASP. Discover, engage, and help shape the future! -

-
-
- -
-
- -
- {data.upcomingEvents.map((event: EventType) => ( -
-

- - {event.name} - -

-
-
- - {formatDateRange(event.startDate, event.endDate)} -
-
-
- ))} +
+
+
+
+

+ Welcome to OWASP Nest +

+

+ Your gateway to OWASP. Discover, engage, and help shape the future! +

+
+
+ +
- -
- -
- {data.recentChapters.map((chapter) => ( -
-

- - {chapter.name} + +
+ {data.upcomingEvents.map((event: EventType) => ( +
+

+ + {event.name}

- {formatDate(chapter.createdAt)} -
-
- - {chapter.suggestedLocation} + {formatDateRange(event.startDate, event.endDate)}
))}
- -
- {data.recentProjects.map((project) => ( -
-

- - {project.name} - -

-
-
- - {formatDate(project.createdAt)} +
+ +
+ {data.recentChapters.map((chapter) => ( +
+

+ + {chapter.name} + +

+
+
+ + {formatDate(chapter.createdAt)} +
+
+ + {chapter.suggestedLocation} +
-
- - {capitalize(project.type)} +
+ ))} +
+ + +
+ {data.recentProjects.map((project) => ( +
+

+ + {project.name} + +

+
+
+ + {formatDate(project.createdAt)} +
+
+ + + {project.type.charAt(0).toUpperCase() + project.type.slice(1).toLowerCase()} + +
-
- ))} -
-
-
-
-

OWASP Chapters Worldwide

- -
- -
- ( -
- - {formatDate(item.createdAt)} - - {item.commentsCount} comments + ))}
- )} - /> - ( -
- - {formatDate(item.publishedAt)} -
- - - {item.tagName} - + +
+
+

OWASP Chapters Worldwide

+ +
+ +
+ ( +
+ + {formatDate(item.createdAt)} + {item?.commentsCount ? ( + <> + + {item.commentsCount} comments + + ) : null}
-
- )} - /> -
+ )} + /> + ( +
+ + {formatDate(item.publishedAt)} + + {item.tagName} +
+ )} + /> +
+
+ {counterData.map((stat, index) => ( + +
+ + +
+
{stat.label}
+
+ ))} +
-
- {counterData.map((stat, index) => ( - -
- + -
-
{stat.label}
+
+ +

Ready to Make a Difference?

+

+ Join OWASP and be part of the global cybersecurity community. +

+ + Join OWASP Now +
- ))} -
- -
- -

Ready to Make a Difference?

-

- Join OWASP and be part of the global cybersecurity community. -

- - Join OWASP Now - -
- - - - + + + +
)