diff --git a/CHANGELOG.md b/CHANGELOG.md index 92a9e37..0dfc7c2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,6 @@ +# v0.5.0 +- Add German translation: Thank you [Kaia](https://shitposter.club/users/kaia)! + # v0.4.1 - Fix button and tag text wrapping - Code quality fixes diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 32cf536..8a5f465 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -141,3 +141,4 @@ In `prod` mode (or in the Docker container), Cannery will listen for the same en Thank you so much for your contributions! - shibao (https://misskey.bubbletea.dev/@shibao) +- kaia (https://shitposter.club/users/kaia) diff --git a/config/runtime.exs b/config/runtime.exs index bced437..aa43ee6 100644 --- a/config/runtime.exs +++ b/config/runtime.exs @@ -14,8 +14,8 @@ end config :cannery, CanneryWeb.ViewHelpers, shibao_mode: System.get_env("SHIBAO_MODE") == "true" -# Set locale -Gettext.put_locale(System.get_env("LOCALE") || "en_US") +# Set default locale +config :gettext, :default_locale, System.get_env("LOCALE") || "en_US" maybe_ipv6 = if System.get_env("ECTO_IPV6") == "true", do: [:inet6], else: [] diff --git a/lib/cannery_web/live/home_live.ex b/lib/cannery_web/live/home_live.ex index 8b21073..827f06a 100644 --- a/lib/cannery_web/live/home_live.ex +++ b/lib/cannery_web/live/home_live.ex @@ -133,7 +133,7 @@ defmodule CanneryWeb.HomeLive do to: "https://gitea.bubbletea.dev/shibao/cannery/src/branch/stable/CHANGELOG.md", target: "_blank", rel: "noopener noreferrer" do %> -

0.4.1

+

0.5.0

<% end %> diff --git a/lib/cannery_web/router.ex b/lib/cannery_web/router.ex index 9e704df..88acf06 100644 --- a/lib/cannery_web/router.ex +++ b/lib/cannery_web/router.ex @@ -11,6 +11,8 @@ defmodule CanneryWeb.Router do plug :protect_from_forgery plug :put_secure_browser_headers plug :fetch_current_user + + Gettext.put_locale(Application.get_env(:gettext, :default_locale, "en_US")) end pipeline :require_admin do