From 82d1336a015e5e17312b0353df9c6a006763555f Mon Sep 17 00:00:00 2001 From: Shivangi Singh Date: Wed, 8 May 2024 20:08:57 +0530 Subject: [PATCH 1/9] SafariBrowserChanges --- styles/list.css | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/styles/list.css b/styles/list.css index 4bd9744..f22ac25 100644 --- a/styles/list.css +++ b/styles/list.css @@ -134,7 +134,7 @@ ul.keyword-list li:not(:last-of-type)::after { .list > .items > .item > .image img { max-width: 100%; - height: 100%; + height: auto; vertical-align: middle; border: 0; aspect-ratio: 16 / 16; From 94fcb8f13a02a775ea7c28a3d814ca4ae01d3e05 Mon Sep 17 00:00:00 2001 From: Shivangi Singh Date: Wed, 8 May 2024 23:42:19 +0530 Subject: [PATCH 2/9] bulet point changes --- styles/list.css | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/styles/list.css b/styles/list.css index f22ac25..f75259e 100644 --- a/styles/list.css +++ b/styles/list.css @@ -101,8 +101,8 @@ ul.keyword-list { list-style: none; } -ul li { - padding: 0 !important; +ul.keyword-list li { + padding: 0; } ul.keyword-list li { From 3d041c1b1e4ee20222dabb5a8543eff60ba9807d Mon Sep 17 00:00:00 2001 From: Shivangi Singh Date: Wed, 8 May 2024 23:44:51 +0530 Subject: [PATCH 3/9] lintChanges --- styles/list.css | 3 --- 1 file changed, 3 deletions(-) diff --git a/styles/list.css b/styles/list.css index f75259e..9ea49ff 100644 --- a/styles/list.css +++ b/styles/list.css @@ -103,9 +103,6 @@ ul.keyword-list { ul.keyword-list li { padding: 0; -} - -ul.keyword-list li { display: inline-block; margin-right: 10px; position: relative; From c8ecfb681ee793f5a01ffbe88bd691b582318135 Mon Sep 17 00:00:00 2001 From: Shivangi Singh Date: Thu, 9 May 2024 12:22:18 +0530 Subject: [PATCH 4/9] DateChanges in Events --- blocks/events/events.js | 3 ++- scripts/scripts.js | 8 +++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/blocks/events/events.js b/blocks/events/events.js index 875eee4..1270bc1 100644 --- a/blocks/events/events.js +++ b/blocks/events/events.js @@ -74,7 +74,8 @@ async function generateEventDetails(articles) { const articleElements = articles.map((art) => { let date = ''; if (art.startdate && art.enddate) { - const endDate = new Date(art.enddate * 1000).toLocaleDateString('en-Us', { month: 'short', day: '2-digit', year: 'numeric' }); + const endDate = new Date(art.enddate * 1000).toLocaleDateString('en-Us', { month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC' }); + console.log(endDate); const eventDate = art.startdate === art.enddate ? endDate : formatDateRange(art.startdate, art.enddate); date = (art.eventtime !== '') ? `${eventDate} ${art.eventtime}` : eventDate; diff --git a/scripts/scripts.js b/scripts/scripts.js index 58c29f2..4aa328d 100644 --- a/scripts/scripts.js +++ b/scripts/scripts.js @@ -341,9 +341,11 @@ function correctUTMFlow() { } export function formatDateRange(startdate, enddate) { - const options = { month: 'short', day: '2-digit', year: 'numeric' }; - const formattedStartDate = new Date(Number(startdate) * 1000).toLocaleDateString('en-us', options); - const formattedEndDate = new Date(Number(enddate) * 1000).toLocaleDateString('en-us', options); + const options = { month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC' }; + const startDate = new Date(Number(startdate) * 1000).toUTCString(); + const endDate = new Date(Number(enddate) * 1000).toUTCString(); + const formattedStartDate = new Date(startDate).toLocaleDateString('en-us', options); + const formattedEndDate = new Date(endDate).toLocaleDateString('en-us', options); const startYear = new Date(formattedStartDate).getFullYear(); const endYear = new Date(formattedEndDate).getFullYear(); const differentYear = startYear !== endYear; From 50284316e70fe9ab2d47953137fe7ad1ab36bda9 Mon Sep 17 00:00:00 2001 From: Shivangi Singh Date: Thu, 9 May 2024 12:27:46 +0530 Subject: [PATCH 5/9] lintchanges --- blocks/events/events.js | 4 ++-- scripts/scripts.js | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/blocks/events/events.js b/blocks/events/events.js index 1270bc1..d05ac21 100644 --- a/blocks/events/events.js +++ b/blocks/events/events.js @@ -73,9 +73,9 @@ function separateEventsByDate(events, currentDate, classParameter) { async function generateEventDetails(articles) { const articleElements = articles.map((art) => { let date = ''; + const options = {month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC'}; if (art.startdate && art.enddate) { - const endDate = new Date(art.enddate * 1000).toLocaleDateString('en-Us', { month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC' }); - console.log(endDate); + const endDate = new Date(art.enddate * 1000).toLocaleDateString('en-Us', options); const eventDate = art.startdate === art.enddate ? endDate : formatDateRange(art.startdate, art.enddate); date = (art.eventtime !== '') ? `${eventDate} ${art.eventtime}` : eventDate; diff --git a/scripts/scripts.js b/scripts/scripts.js index 4aa328d..dfe0a22 100644 --- a/scripts/scripts.js +++ b/scripts/scripts.js @@ -341,7 +341,7 @@ function correctUTMFlow() { } export function formatDateRange(startdate, enddate) { - const options = { month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC' }; + const options = {month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC'}; const startDate = new Date(Number(startdate) * 1000).toUTCString(); const endDate = new Date(Number(enddate) * 1000).toUTCString(); const formattedStartDate = new Date(startDate).toLocaleDateString('en-us', options); From 72d361c58f8aa1c862558ec828e00633aee6b8f0 Mon Sep 17 00:00:00 2001 From: Shivangi Singh Date: Thu, 9 May 2024 12:29:55 +0530 Subject: [PATCH 6/9] issues related to lint --- blocks/events/events.js | 4 +++- scripts/scripts.js | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/blocks/events/events.js b/blocks/events/events.js index d05ac21..d403dec 100644 --- a/blocks/events/events.js +++ b/blocks/events/events.js @@ -73,7 +73,9 @@ function separateEventsByDate(events, currentDate, classParameter) { async function generateEventDetails(articles) { const articleElements = articles.map((art) => { let date = ''; - const options = {month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC'}; + const options = { + month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC' + }; if (art.startdate && art.enddate) { const endDate = new Date(art.enddate * 1000).toLocaleDateString('en-Us', options); const eventDate = art.startdate === art.enddate diff --git a/scripts/scripts.js b/scripts/scripts.js index dfe0a22..764d1b0 100644 --- a/scripts/scripts.js +++ b/scripts/scripts.js @@ -341,7 +341,9 @@ function correctUTMFlow() { } export function formatDateRange(startdate, enddate) { - const options = {month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC'}; + const options = { + month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC' + }; const startDate = new Date(Number(startdate) * 1000).toUTCString(); const endDate = new Date(Number(enddate) * 1000).toUTCString(); const formattedStartDate = new Date(startDate).toLocaleDateString('en-us', options); From 7d9663a4cbcc21835d980cb8a439cfcba63c0a26 Mon Sep 17 00:00:00 2001 From: Shivangi Singh Date: Thu, 9 May 2024 12:38:52 +0530 Subject: [PATCH 7/9] issuechanges --- blocks/events/events.js | 2 +- scripts/scripts.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/blocks/events/events.js b/blocks/events/events.js index d403dec..63a5d87 100644 --- a/blocks/events/events.js +++ b/blocks/events/events.js @@ -74,7 +74,7 @@ async function generateEventDetails(articles) { const articleElements = articles.map((art) => { let date = ''; const options = { - month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC' + month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC', }; if (art.startdate && art.enddate) { const endDate = new Date(art.enddate * 1000).toLocaleDateString('en-Us', options); diff --git a/scripts/scripts.js b/scripts/scripts.js index 764d1b0..57353f1 100644 --- a/scripts/scripts.js +++ b/scripts/scripts.js @@ -342,7 +342,7 @@ function correctUTMFlow() { export function formatDateRange(startdate, enddate) { const options = { - month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC' + month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC', }; const startDate = new Date(Number(startdate) * 1000).toUTCString(); const endDate = new Date(Number(enddate) * 1000).toUTCString(); From d64c3552335a0e177c946bb710c5d1011f6f8a4f Mon Sep 17 00:00:00 2001 From: Shivangi Singh Date: Thu, 9 May 2024 13:13:35 +0530 Subject: [PATCH 8/9] Datetimezoneset Changes for events --- blocks/events/events.js | 6 +++--- scripts/scripts.js | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/blocks/events/events.js b/blocks/events/events.js index 63a5d87..f512bed 100644 --- a/blocks/events/events.js +++ b/blocks/events/events.js @@ -57,8 +57,8 @@ function separateEventsByDate(events, currentDate, classParameter) { const futureEvents = []; const archivedEvents = []; events.forEach((event) => { - const startDate = new Date(event.startdate * 1000); - const endDate = new Date(event.enddate * 1000); + const startDate = new Date((event.startdate- 25569) * 24 * 60 * 60 * 1000); + const endDate = new Date((event.enddate - 25569) * 24 * 60 * 60 * 1000); if (startDate > currentDate || endDate > currentDate) { futureEvents.push(event); @@ -77,7 +77,7 @@ async function generateEventDetails(articles) { month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC', }; if (art.startdate && art.enddate) { - const endDate = new Date(art.enddate * 1000).toLocaleDateString('en-Us', options); + const endDate = new Date((art.enddate - 25569) * 24 * 60 * 60 * 1000).toLocaleDateString('en-Us', options); const eventDate = art.startdate === art.enddate ? endDate : formatDateRange(art.startdate, art.enddate); date = (art.eventtime !== '') ? `${eventDate} ${art.eventtime}` : eventDate; diff --git a/scripts/scripts.js b/scripts/scripts.js index 57353f1..9ab1bbc 100644 --- a/scripts/scripts.js +++ b/scripts/scripts.js @@ -344,8 +344,8 @@ export function formatDateRange(startdate, enddate) { const options = { month: 'short', day: '2-digit', year: 'numeric', timeZone: 'UTC', }; - const startDate = new Date(Number(startdate) * 1000).toUTCString(); - const endDate = new Date(Number(enddate) * 1000).toUTCString(); + const startDate = new Date(Number(startdate - 25569) * 24 * 60 * 60 * 1000).toUTCString(); + const endDate = new Date(Number(enddate - 25569) * 24 * 60 * 60 * 1000).toUTCString(); const formattedStartDate = new Date(startDate).toLocaleDateString('en-us', options); const formattedEndDate = new Date(endDate).toLocaleDateString('en-us', options); const startYear = new Date(formattedStartDate).getFullYear(); From 1a443fdb703c1e2abc471907352150a0d9d151ce Mon Sep 17 00:00:00 2001 From: Shivangi Singh Date: Thu, 9 May 2024 13:18:19 +0530 Subject: [PATCH 9/9] lint --- blocks/events/events.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blocks/events/events.js b/blocks/events/events.js index f512bed..7431530 100644 --- a/blocks/events/events.js +++ b/blocks/events/events.js @@ -57,7 +57,7 @@ function separateEventsByDate(events, currentDate, classParameter) { const futureEvents = []; const archivedEvents = []; events.forEach((event) => { - const startDate = new Date((event.startdate- 25569) * 24 * 60 * 60 * 1000); + const startDate = new Date((event.startdate - 25569) * 24 * 60 * 60 * 1000); const endDate = new Date((event.enddate - 25569) * 24 * 60 * 60 * 1000); if (startDate > currentDate || endDate > currentDate) {