From d5c7ca7b7b7932c0f9482d6ba494de4741cad12a Mon Sep 17 00:00:00 2001 From: tiago-bacelar Date: Mon, 5 Jun 2023 14:24:55 +0100 Subject: [PATCH 1/4] Add location to schedule --- data/schedule.json | 5 +++++ .../live/landing/home_live/index.html.heex | 22 +++++++++++++++---- .../landing/schedule_live/index.html.heex | 14 ++++++++++++ 3 files changed, 37 insertions(+), 4 deletions(-) diff --git a/data/schedule.json b/data/schedule.json index eb9c6966..15a8fb2e 100644 --- a/data/schedule.json +++ b/data/schedule.json @@ -3,6 +3,7 @@ { "title": "Acreditação", "hours": "05/06/2023 9:30 AM", + "location": "location", "speaker": null, "company": null, "href": null @@ -10,6 +11,7 @@ { "title": "Sessão de abertura", "hours": "05/06/2023 10:00 AM", + "location": "location", "speaker": null, "company": null, "href": null @@ -17,6 +19,7 @@ { "title": "☕ Coffee break", "hours": "05/06/2023 11:00 AM", + "location": "location", "speaker": null, "company": null, "href": null @@ -24,6 +27,7 @@ { "title": "[Talk] Do algoritmo ao impacto: uma viagem pela disrupção da IA", "hours": "05/06/2023 11:30 AM", + "location": "location", "speaker": "Michel Ozzello", "company": "Agentifai", "href": null @@ -59,6 +63,7 @@ { "title": "[Talk] Web and Mobile Development in 2023", "hours": "05/06/2023 03:20 PM", + "location": "location", "speaker": "Nuno Pereira", "company": "Bliss", "href": null diff --git a/lib/parzival_web/live/landing/home_live/index.html.heex b/lib/parzival_web/live/landing/home_live/index.html.heex index 5589c411..a8711a8c 100644 --- a/lib/parzival_web/live/landing/home_live/index.html.heex +++ b/lib/parzival_web/live/landing/home_live/index.html.heex @@ -58,7 +58,7 @@
= '#{hd(Map.get(@schedule, "monday"))["hours"]}.to_iso8601!()' && new Date().toISOString() <= '#{List.last(Map.get(@schedule, "wednesday"))["hours"]}.to_iso8601!()' ? new Date().getDay() +1 : 2 }"} + x-data={"{ date: new Date().toISOString() >= '#{hd(Map.get(@schedule, "monday"))["hours"]}.to_iso8601!()' && new Date().toISOString() <= '#{List.last(Map.get(@schedule, "wednesday"))["hours"]}.to_iso8601!()' ? new Date().getDay() + 1 : 2 }"} class="flex flex-row mt-10 h-auto sm:mt-20 lg:mt-48 1.5xl:h-[1000px]" >