fix flashes
This commit is contained in:
parent
3907f9854a
commit
78f2464af3
@ -1,18 +1,21 @@
|
|||||||
<main class="container min-w-full">
|
<main class="container min-w-full">
|
||||||
<header>
|
<header>
|
||||||
<CanneryWeb.Component.Topbar.topbar current_user={assigns[:current_user]}></CanneryWeb.Component.Topbar.topbar>
|
<CanneryWeb.Component.Topbar.topbar current_user={assigns[:current_user]}></CanneryWeb.Component.Topbar.topbar>
|
||||||
|
|
||||||
<div class="mx-8 my-2 flex flex-col space-y-4 text-center">
|
<div class="mx-8 my-2 flex flex-col space-y-4 text-center">
|
||||||
<%= if @flash && @flash |> Map.has_key?(:info) do %>
|
<%= if @flash && @flash |> Map.has_key?("info") do %>
|
||||||
<p class="alert alert-info" role="alert" phx-click="lv:clear-flash" phx-value-key="info">
|
<p class="alert alert-info" role="alert" phx-click="lv:clear-flash" phx-value-key="info">
|
||||||
<%= live_flash(@flash, :info) %>
|
<%= live_flash(@flash, "info") %>
|
||||||
</p>
|
</p>
|
||||||
<% end %>
|
<% end %>
|
||||||
<%= if @flash && @flash |> Map.has_key?(:error) do %>
|
|
||||||
|
<%= if @flash && @flash |> Map.has_key?("error") do %>
|
||||||
<p class="alert alert-danger" role="alert" phx-click="lv:clear-flash" phx-value-key="error">
|
<p class="alert alert-danger" role="alert" phx-click="lv:clear-flash" phx-value-key="error">
|
||||||
<%= live_flash(@flash, :error) %>
|
<%= live_flash(@flash, "error") %>
|
||||||
</p>
|
</p>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
</header>
|
</header>
|
||||||
|
|
||||||
<%= @inner_content %>
|
<%= @inner_content %>
|
||||||
</main>
|
</main>
|
||||||
|
Loading…
Reference in New Issue
Block a user