Files
Claper/lib/claper_web/templates/layout/_user_menu.html.heex
2025-11-20 10:44:06 +01:00

34 lines
927 B
Plaintext

<div class="py-1" role="none">
<a
href={~p"/users/settings"}
class="text-gray-700 block px-4 py-2 text-sm hover:bg-gray-100 hover:text-gray-900"
>
{gettext("My account")}
</a>
<a
:if={Claper.Accounts.user_has_role?(@user, "admin")}
href={~p"/admin"}
class="text-gray-700 block px-4 py-2 text-sm hover:bg-gray-100 hover:text-gray-900"
>
{gettext("Admin")}
</a>
<a
href="https://docs.claper.co"
class="text-gray-700 block px-4 py-2 text-sm hover:bg-gray-100 hover:text-gray-900"
>
{gettext("Documentation")}
</a>
</div>
<div class="py-1" role="none">
{link(gettext("Logout"),
to: ~p"/users/log_out",
method: :delete,
class: "text-gray-700 block px-4 py-2 text-sm hover:bg-gray-100 hover:text-gray-900"
)}
</div>
<div class="py-1" role="none">
<p class="text-gray-500 block px-4 text-xs py-1">
Version {Application.spec(:claper, :vsn)}
</p>
</div>