feat: unify page titles
This commit is contained in:
parent
e8ec620d57
commit
c933144920
37 changed files with 309 additions and 200 deletions
|
|
@ -70,9 +70,11 @@ defmodule MvWeb.GroupLive.Show do
|
|||
{:ok, group} ->
|
||||
open_delete = params["confirm_delete"] == "1" && can?(actor, :destroy, group)
|
||||
|
||||
content_title = gettext("Group %{name}", name: group.name)
|
||||
|
||||
socket =
|
||||
socket
|
||||
|> assign(:page_title, group.name)
|
||||
|> Layouts.assign_page_title(content_title)
|
||||
|> assign(:group, group)
|
||||
|> assign(:show_delete_modal, open_delete)
|
||||
|> assign(:name_confirmation, "")
|
||||
|
|
@ -102,7 +104,7 @@ defmodule MvWeb.GroupLive.Show do
|
|||
{gettext("Back")}
|
||||
</.button>
|
||||
</:leading>
|
||||
{@group.name}
|
||||
{@content_title}
|
||||
<:actions>
|
||||
<%= if can?(@current_user, :update, @group) do %>
|
||||
<.button
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue