defmodule LokalWeb.Components.UserCard do @moduledoc """ Display card for a user """ use LokalWeb, :component def user_card(assigns) do ~H"""
<%= if @user.confirmed_at do %> <%= gettext( "User was confirmed at%{confirmed_datetime}", confirmed_datetime: "" ) %> <.datetime datetime={@user.confirmed_at} /> <% else %> <%= gettext("Email unconfirmed") %> <% end %>
<%= gettext( "User registered on%{registered_datetime}", registered_datetime: "" ) %> <.datetime datetime={@user.inserted_at} />