diff --git a/src/components/auth/EventAuth.ts b/src/components/auth/EventAuth.ts
index f76427a..f7bc1ee 100644
--- a/src/components/auth/EventAuth.ts
+++ b/src/components/auth/EventAuth.ts
@@ -412,15 +412,35 @@ export class EventAuth {
private splitDateTime(dateTimeStr: string): { date: string; time: string } {
if (!dateTimeStr) return { date: "", time: "" };
+
+ // Create a date object in local timezone
const dateTime = new Date(dateTimeStr);
- const date = dateTime.toISOString().split('T')[0];
- const time = dateTime.toTimeString().split(' ')[0].slice(0, 5);
+
+ // Format date as YYYY-MM-DD
+ const date = dateTime.toLocaleDateString('en-CA'); // en-CA gives YYYY-MM-DD format
+
+ // Format time as HH:mm
+ const time = dateTime.toLocaleTimeString('en-US', {
+ hour12: false,
+ hour: '2-digit',
+ minute: '2-digit'
+ });
+
return { date, time };
}
private combineDateTime(date: string, time: string): string {
if (!date || !time) return "";
- return `${date}T${time}:00`;
+
+ // Create a new Date object from the date and time strings
+ const [year, month, day] = date.split('-').map(Number);
+ const [hours, minutes] = time.split(':').map(Number);
+
+ // Create date in local timezone
+ const dateTime = new Date(year, month - 1, day, hours, minutes);
+
+ // Format the date to ISO string with timezone offset
+ return dateTime.toISOString();
}
private getFileNameFromUrl(url: string): string {
diff --git a/src/components/profile/DefaultProfileView.astro b/src/components/profile/DefaultProfileView.astro
index 0d3bf51..0af1d02 100644
--- a/src/components/profile/DefaultProfileView.astro
+++ b/src/components/profile/DefaultProfileView.astro
@@ -141,7 +141,7 @@
d="M11 3a1 1 0 100 2h2.586l-6.293 6.293a1 1 0 101.414 1.414L15 6.414V9a1 1 0 102 0V4a1 1 0 00-1-1h-5z"
>
Open in New Tab
@@ -163,6 +163,27 @@
+
+
+