From 4c8c8e6bcddb8f2f83a657d826cf315acf43bd4a Mon Sep 17 00:00:00 2001 From: shibao Date: Sat, 18 Mar 2023 00:46:03 -0400 Subject: [PATCH] use .link helpers --- lib/memex_web/live/home_live.html.heex | 4 ++-- lib/memex_web/live/invite_live/index.html.heex | 8 ++++---- lib/memex_web/templates/error/error.html.heex | 7 +++++-- priv/gettext/de/LC_MESSAGES/errors.po | 2 +- priv/gettext/en/LC_MESSAGES/errors.po | 2 +- priv/gettext/errors.pot | 2 +- 6 files changed, 14 insertions(+), 11 deletions(-) diff --git a/lib/memex_web/live/home_live.html.heex b/lib/memex_web/live/home_live.html.heex index eb5a954..c304391 100644 --- a/lib/memex_web/live/home_live.html.heex +++ b/lib/memex_web/live/home_live.html.heex @@ -90,9 +90,9 @@ <%= dgettext("prompts", "register to setup memEx") %> <% else %> - + <.link :for={%{email: email} <- @admins} class="link" href={"mailto:#{email}"}> <%= email %> - + <% end %>

diff --git a/lib/memex_web/live/invite_live/index.html.heex b/lib/memex_web/live/invite_live/index.html.heex index e452801..88de97f 100644 --- a/lib/memex_web/live/invite_live/index.html.heex +++ b/lib/memex_web/live/invite_live/index.html.heex @@ -56,16 +56,16 @@ - <%= if invite.disabled_at, do: gettext("enable"), else: gettext("disable") %> - + - is_nil() and not (invite.uses_left |> is_nil())} href="#" class="btn btn-secondary" @@ -78,7 +78,7 @@ } > <%= gettext("set unlimited") %> - + <.link diff --git a/lib/memex_web/templates/error/error.html.heex b/lib/memex_web/templates/error/error.html.heex index fdfe31d..18f86c7 100644 --- a/lib/memex_web/templates/error/error.html.heex +++ b/lib/memex_web/templates/error/error.html.heex @@ -24,9 +24,12 @@
- + <.link + href={Routes.live_path(Endpoint, HomeLive)} + class="link title text-primary-400 text-lg" + > <%= dgettext("errors", "go back home") %> - + diff --git a/priv/gettext/de/LC_MESSAGES/errors.po b/priv/gettext/de/LC_MESSAGES/errors.po index 8405abd..5f1e86a 100644 --- a/priv/gettext/de/LC_MESSAGES/errors.po +++ b/priv/gettext/de/LC_MESSAGES/errors.po @@ -83,7 +83,7 @@ msgstr "" msgid "invalid format: only numbers, letters and hyphen are accepted" msgstr "" -#: lib/memex_web/templates/error/error.html.heex:28 +#: lib/memex_web/templates/error/error.html.heex:31 #, elixir-autogen, elixir-format msgid "go back home" msgstr "" diff --git a/priv/gettext/en/LC_MESSAGES/errors.po b/priv/gettext/en/LC_MESSAGES/errors.po index 32f5595..9ece1fa 100644 --- a/priv/gettext/en/LC_MESSAGES/errors.po +++ b/priv/gettext/en/LC_MESSAGES/errors.po @@ -84,7 +84,7 @@ msgstr "" msgid "invalid format: only numbers, letters and hyphen are accepted" msgstr "" -#: lib/memex_web/templates/error/error.html.heex:28 +#: lib/memex_web/templates/error/error.html.heex:31 #, elixir-autogen, elixir-format msgid "go back home" msgstr "" diff --git a/priv/gettext/errors.pot b/priv/gettext/errors.pot index 2f6189d..8de15b7 100644 --- a/priv/gettext/errors.pot +++ b/priv/gettext/errors.pot @@ -83,7 +83,7 @@ msgstr "" msgid "invalid format: only numbers, letters and hyphen are accepted" msgstr "" -#: lib/memex_web/templates/error/error.html.heex:28 +#: lib/memex_web/templates/error/error.html.heex:31 #, elixir-autogen, elixir-format msgid "go back home" msgstr ""