From 9c506e7733c91da9f6589140e8fa07f2a95ada55 Mon Sep 17 00:00:00 2001 From: a111430 Date: Thu, 16 Apr 2026 19:11:24 +0100 Subject: [PATCH 1/2] feat: landing page --- lib/gallium_web.ex | 9 +++++++++ .../components/layouts/landing.html.heex | 8 ++++++++ lib/gallium_web/live/landing/index.ex | 6 +++++- lib/gallium_web/live/landing/index.html.heex | 16 ++++++++++++---- 4 files changed, 34 insertions(+), 5 deletions(-) create mode 100644 lib/gallium_web/components/layouts/landing.html.heex diff --git a/lib/gallium_web.ex b/lib/gallium_web.ex index 4cd7450..376c468 100644 --- a/lib/gallium_web.ex +++ b/lib/gallium_web.ex @@ -74,6 +74,15 @@ defmodule GalliumWeb do end end + def landing_view do + quote do + use Phoenix.LiveView, + layout: {GalliumWeb.Layouts, :landing} + + unquote(html_helpers()) + end + end + def component do quote do use Phoenix.Component diff --git a/lib/gallium_web/components/layouts/landing.html.heex b/lib/gallium_web/components/layouts/landing.html.heex new file mode 100644 index 0000000..0fe4f89 --- /dev/null +++ b/lib/gallium_web/components/layouts/landing.html.heex @@ -0,0 +1,8 @@ +
+ <.navbar current_scope={@current_scope} /> +
+ <.flash_group flash={@flash} /> + {@inner_content} +
+ <.footer /> +
diff --git a/lib/gallium_web/live/landing/index.ex b/lib/gallium_web/live/landing/index.ex index 6ad2ec5..b968c18 100644 --- a/lib/gallium_web/live/landing/index.ex +++ b/lib/gallium_web/live/landing/index.ex @@ -1,5 +1,9 @@ defmodule GalliumWeb.LandingLive.Index do - use GalliumWeb, :app_view + use GalliumWeb, :landing_view + + import GalliumWeb.Components.Hero + import GalliumWeb.Components.AboutSection + import GalliumWeb.Components.Forecast @impl true def mount(_params, _session, socket) do diff --git a/lib/gallium_web/live/landing/index.html.heex b/lib/gallium_web/live/landing/index.html.heex index 95ef0ea..fae85fe 100644 --- a/lib/gallium_web/live/landing/index.html.heex +++ b/lib/gallium_web/live/landing/index.html.heex @@ -1,5 +1,13 @@ -
-
-

Gallium

-
+
+ <.hero + date_info="30 | 05 • Quinta da Aldeia" + ticket_url="/bilhetes/comprar" + /> + + <.about_section + title="Uma Noite\nInesquecível" + description="Junta-te aos teus colegas para uma noite de elegancia, conexao e celebracao. O Jantar de Gala do CeSIUM reune a nossa comunidade num ambiente formal para honrar conquistas e criar memorias inesqueciveis." + /> + + <.forecast />
From 99322238d67c71b94f87f41a1317f31cea8bd20a Mon Sep 17 00:00:00 2001 From: a111430 Date: Fri, 17 Apr 2026 11:06:16 +0100 Subject: [PATCH 2/2] fix: imports --- lib/gallium_web/live/landing/index.ex | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/lib/gallium_web/live/landing/index.ex b/lib/gallium_web/live/landing/index.ex index b968c18..e23f44a 100644 --- a/lib/gallium_web/live/landing/index.ex +++ b/lib/gallium_web/live/landing/index.ex @@ -1,9 +1,7 @@ defmodule GalliumWeb.LandingLive.Index do use GalliumWeb, :landing_view - import GalliumWeb.Components.Hero - import GalliumWeb.Components.AboutSection - import GalliumWeb.Components.Forecast + import GalliumWeb.Components.{AboutSection, Forecast, Hero} @impl true def mount(_params, _session, socket) do