From 2db21c8b69367b2673c97d5d5e4cb5b659144689 Mon Sep 17 00:00:00 2001 From: shibao Date: Thu, 2 Sep 2021 23:31:15 -0400 Subject: [PATCH] add index links to topbar --- lib/cannery_web/live/component/topbar.ex | 78 ---------------- .../live/component/topbar.html.leex | 90 +++++++++++++++++++ 2 files changed, 90 insertions(+), 78 deletions(-) create mode 100644 lib/cannery_web/live/component/topbar.html.leex diff --git a/lib/cannery_web/live/component/topbar.ex b/lib/cannery_web/live/component/topbar.ex index d82fae2..0bde2cc 100644 --- a/lib/cannery_web/live/component/topbar.ex +++ b/lib/cannery_web/live/component/topbar.ex @@ -10,82 +10,4 @@ defmodule CanneryWeb.Live.Component.Topbar do def update(assigns, socket) do {:ok, socket |> assign(assigns)} end - - def render(assigns) do - ~L""" -
- - - <%= if live_flash(@flash, :info) do %> - - <% end %> - - <%= if live_flash(@flash, :error) do %> - - <% end %> -
- """ - end end diff --git a/lib/cannery_web/live/component/topbar.html.leex b/lib/cannery_web/live/component/topbar.html.leex new file mode 100644 index 0000000..63642d3 --- /dev/null +++ b/lib/cannery_web/live/component/topbar.html.leex @@ -0,0 +1,90 @@ +
+ + + <%= if live_flash(@flash, :info) do %> + + <% end %> + + <%= if live_flash(@flash, :error) do %> + + <% end %> +
\ No newline at end of file