diff --git a/app/page.tsx b/app/page.tsx index 7b2d3cc..330706f 100644 --- a/app/page.tsx +++ b/app/page.tsx @@ -38,18 +38,23 @@ export default function Home() { + + + + + + {/* */} {/* */} - + {/* */} - - - + + {/* */} {/* */} - + {/* diff --git a/components/events/UpcomingEventData.jsx b/components/events/UpcomingEventData.jsx index 3731c7b..141b4e9 100644 --- a/components/events/UpcomingEventData.jsx +++ b/components/events/UpcomingEventData.jsx @@ -1,12 +1,109 @@ 'use client' import Link from 'next/link' +import moment from "moment"; import { useState } from "react" + export default function UpcomingEventData() { const [isTab, setIsTab] = useState(1) const handleTab = (i) => { setIsTab(i) } + + const [currentMonth, setCurrentMonth] = useState(moment()); + + const events = [ + { + id: 1, + date: "Sun Jan-14", + time: "05:30 PM", + title: "Thai Pongal 2024", + url: "#", + }, + { + + id: 2, + date: "Apr 14, 2024", + title: "AGM", + url: "#", + }, + + { + id: 3, + date: "Jun 22-23, 2024", + title: "KW Multicultural Festival", + url: "#", + }, + { + id: 4, + date: "Sun Jul 7, 2024", + time: "10:00 AM", + title: "TCA Picnic – Potlock", + url: "#", + }, + { + id: 5, + date: "Jul 27-28, 2024", + title: "South Asian Family Sports Day", + url: "#", + }, + { + id: 6, + date: "Aug 23, 2023", + time: "06:30-08:30 PM", + title: "Conestoga College Workshop", + url: "#", + }, + { + id: 7, + date: "Aug 23, 2023", + time: "06:30-08:30 PM", + title: "Conestoga College Workshop", + url: "#", + }, + { + id: 8, + date: "Sat Oct 26, 2024", + time: "1.00 PM-4.30 PM", + title: "TCA – WPL Deepavali Celebrations", + url: "#", + }, + + { + id: 9, + date: "Sat Dec 21, 2024", + time: "05:00 PM-09:00 PM", + title: "RIM Park", + url: "#", + }, + + +]; + + // Get the start and end of the current month + const startOfMonth = currentMonth.clone().startOf("month"); + const endOfMonth = currentMonth.clone().endOf("month"); + + // Generate the calendar days + const daysInMonth = []; + for (let i = 0; i < startOfMonth.day(); i++) { + daysInMonth.push(null); // Adding null for empty days before the start of the month + } + for (let i = 1; i <= endOfMonth.date(); i++) { + daysInMonth.push(moment(currentMonth).date(i)); + } + + // Function to check if a date has an event + const getEventForDate = (date) => { + const dateString = date?.format("YYYY-MM-DD"); + return events.filter(event => event.date === dateString); + }; + + // Function to navigate to the next/previous month + const handleMonthChange = (direction) => { + setCurrentMonth(currentMonth.clone().add(direction, "months")); + }; + return ( <> @@ -22,12 +119,86 @@ export default function UpcomingEventData() {
-
+
+ +
+ + + {currentMonth.format("MMMM YYYY")} + + +
+ + + + + {["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"].map((day, index) => ( + + ))} + + + + {Array.from({ length: Math.ceil(daysInMonth.length / 7) }, (_, rowIndex) => ( + + {daysInMonth.slice(rowIndex * 7, (rowIndex + 1) * 7).map((day, index) => ( + + ))} + + ))} + +
+ {day} +
0 ? "#eac768" : "white", // Highlight event dates + }} + > + {day ? ( +
+ {/* Align day number to the right */} + {day.date()} + + {/* Display event names if present */} + {/* {getEventForDate(day).map((event, eventIndex) => ( +
handleEventClick(event.id)} // Add click handler + style={{ + backgroundColor: "#007BFF", // Highlight event with a blue color + borderRadius: "5px", + cursor: "pointer" + }} + > + {event.title} +
+ ))} */} +
+ ) : ( + "" + )} +
+
+
+
+
diff --git a/components/home/HomePhotoGallerySection.tsx b/components/home/HomePhotoGallerySection.tsx index c0a7b66..d0819ab 100644 --- a/components/home/HomePhotoGallerySection.tsx +++ b/components/home/HomePhotoGallerySection.tsx @@ -76,7 +76,7 @@ export default function HomePhotoGallerySection() { return ( <> -
+
diff --git a/components/home/HomeUpcomingEvent.tsx b/components/home/HomeUpcomingEvent.tsx index 44bd630..cfc32f5 100644 --- a/components/home/HomeUpcomingEvent.tsx +++ b/components/home/HomeUpcomingEvent.tsx @@ -10,7 +10,7 @@ export default function HomeUpcomingEvent() { return ( <> -
+
diff --git a/package-lock.json b/package-lock.json index 0d85b35..d12d573 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,6 +11,7 @@ "aos": "^2.3.4", "axios": "^1.11.0", "gsap": "^3.12.5", + "moment": "^2.30.1", "next": "14.2.15", "react": "^18", "react-countup": "^6.5.3", @@ -4180,6 +4181,15 @@ "node": ">=16 || 14 >=14.17" } }, + "node_modules/moment": { + "version": "2.30.1", + "resolved": "https://registry.npmjs.org/moment/-/moment-2.30.1.tgz", + "integrity": "sha512-uEmtNhbDOrWPFS+hdjFCBfy9f2YoyzRpwcl+DqpC6taX21FzsTLQVbMV/W7PzNSX6x/bhC1zA3c2UQ5NzH6how==", + "license": "MIT", + "engines": { + "node": "*" + } + }, "node_modules/ms": { "version": "2.1.3", "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", diff --git a/package.json b/package.json index e059f4c..40d8e35 100644 --- a/package.json +++ b/package.json @@ -14,6 +14,7 @@ "aos": "^2.3.4", "axios": "^1.11.0", "gsap": "^3.12.5", + "moment": "^2.30.1", "next": "14.2.15", "react": "^18", "react-countup": "^6.5.3", diff --git a/public/assets/css/main.css b/public/assets/css/main.css index 1ce0a44..4424a79 100644 --- a/public/assets/css/main.css +++ b/public/assets/css/main.css @@ -1390,7 +1390,7 @@ Location: .vl-btn4 { color: var(--ztc-text-text-1); font-family: var(--grotesk); - font-size: var(--ztc-font-size-font-s20); + font-size: var(--ztc-font-size-font-s18); font-style: normal; font-weight: var(--ztc-weight-bold); line-height: 20px; @@ -1400,24 +1400,21 @@ Location: z-index: 1; display: inline-block; border-radius: 8px; - padding: 24px 26px; - background: var(--ztc-bg-bg-9); + padding: 16px 24px; + background: var(--ztc-bg-bg-15); overflow: hidden; } .vl-btn4::after { position: absolute; content: ""; - height: 100%; - width: 1px; - left: 50%; - top: 0; + height: 4px; + width: 100%; + left: 0; + bottom: 0; transition: all 0.4s; - background: var(--ztc-bg-bg-8); + background: #D60003; z-index: -1; - border-radius: 8px; - visibility: hidden; - opacity: 0; } .vl-btn4:hover { @@ -1429,10 +1426,7 @@ Location: width: 100%; height: 100%; transition: all 0.4s; - left: 0; - top: 0; - visibility: visible; - opacity: 1; + } .vl-btn5 { @@ -28477,6 +28471,9 @@ h2.custom-text.aos-init.aos-animate { } } +.fw-700{ + font-weight:700; +} @media (max-width: 1920px) and (min-width: 1440px) { .social-icons ul { display: flex; diff --git a/utility/constant.utils.js b/utility/constant.utils.js index 1a5a414..54340f6 100644 --- a/utility/constant.utils.js +++ b/utility/constant.utils.js @@ -4632,4 +4632,5 @@ export const heritageLanguage = [
` }, -]; \ No newline at end of file +]; +