feat: add translation
This commit is contained in:
parent
ddf9348eb8
commit
2a6f1ccf80
12 changed files with 260 additions and 38 deletions
|
|
@ -1,5 +1,6 @@
|
|||
defmodule MvWeb.AuthOverrides do
|
||||
use AshAuthentication.Phoenix.Overrides
|
||||
use Gettext, backend: MvWeb.Gettext
|
||||
|
||||
# configure your UI overrides here
|
||||
|
||||
|
|
@ -14,12 +15,22 @@ defmodule MvWeb.AuthOverrides do
|
|||
# set :text_class, "bg-red-500"
|
||||
# end
|
||||
|
||||
override AshAuthentication.Phoenix.Components.SignIn do
|
||||
# Avoid full-width for the Sign In Form
|
||||
override AshAuthentication.Phoenix.Components.SignIn do
|
||||
set :root_class, "min-w-md"
|
||||
end
|
||||
end
|
||||
|
||||
override AshAuthentication.Phoenix.Components.Banner do
|
||||
# Replace banner logo with text
|
||||
override AshAuthentication.Phoenix.Components.Banner do
|
||||
set :text, "Mitgliederverwaltung"
|
||||
set :image_url, nil
|
||||
end
|
||||
end
|
||||
|
||||
# Translate the or in the horizontal rule to German
|
||||
override AshAuthentication.Phoenix.Components.HorizontalRule do
|
||||
set :text,
|
||||
Gettext.with_locale(MvWeb.Gettext, "de", fn ->
|
||||
Gettext.gettext(MvWeb.Gettext, "or")
|
||||
end)
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue