hide register/login links if registration is not open
This commit is contained in:
parent
5962f9eaee
commit
5b97348fb7
|
@ -9,7 +9,8 @@ import Config
|
|||
|
||||
config :poex,
|
||||
ecto_repos: [Poex.Repo],
|
||||
generators: [timestamp_type: :utc_datetime]
|
||||
generators: [timestamp_type: :utc_datetime],
|
||||
open_registration: false
|
||||
|
||||
# Configures the endpoint
|
||||
config :poex, PoexWeb.Endpoint,
|
||||
|
|
|
@ -13,7 +13,9 @@
|
|||
</script>
|
||||
</head>
|
||||
<body class="bg-white antialiased">
|
||||
<%= if Application.get_env(:poex, :open_registration, false) do %>
|
||||
<ul class="relative z-10 flex items-center gap-4 px-4 sm:px-6 lg:px-8 justify-end">
|
||||
|
||||
<%= if @current_user do %>
|
||||
<li class="text-[0.8125rem] leading-6 text-zinc-900">
|
||||
<%= @current_user.email %>
|
||||
|
@ -54,6 +56,7 @@
|
|||
</li>
|
||||
<% end %>
|
||||
</ul>
|
||||
<% end %>
|
||||
<%= @inner_content %>
|
||||
</body>
|
||||
</html>
|
||||
|
|
Loading…
Reference in New Issue