Add Danish and Polish i18n support (#2586)

This commit is contained in:
kermieisinthehouse 2022-05-13 12:45:05 -07:00 committed by GitHub
parent c232372f0c
commit 55366fa66f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 11 additions and 2 deletions

View file

@ -45,9 +45,9 @@ Many community-maintained scrapers are available for download at the [Community
# Translation
[![Translate](https://translate.stashapp.cc/widgets/stash/-/stash-desktop-client/svg-badge.svg)](https://translate.stashapp.cc/engage/stash/)
🇧🇷 🇨🇳 🇳🇱 🇬🇧 🇫🇮 🇫🇷 🇩🇪 🇮🇹 🇯🇵 🇪🇸 🇸🇪 🇹🇼 🇹🇷
🇧🇷 🇨🇳 🇩🇰 🇳🇱 🇬🇧 🇫🇮 🇫🇷 🇩🇪 🇮🇹 🇯🇵 🇵🇱 🇪🇸 🇸🇪 🇹🇼 🇹🇷
Stash is available in 13 languages (so far!) and it could be in your language too. If you want to help us translate Stash into your language, you can make an account at [translate.stashapp.cc](https://translate.stashapp.cc/projects/stash/stash-desktop-client/) to get started contributing new languages or improving existing ones. Thanks!
Stash is available in 15 languages (so far!) and it could be in your language too. If you want to help us translate Stash into your language, you can make an account at [translate.stashapp.cc](https://translate.stashapp.cc/projects/stash/stash-desktop-client/) to get started contributing new languages or improving existing ones. Thanks!
# Support (FAQ)

View file

@ -23,6 +23,8 @@ var matcher = language.NewMatcher([]language.Tag{
language.MustParse("nl-NL"),
language.MustParse("ru-RU"),
language.MustParse("tr-TR"),
language.MustParse("da-DK"),
language.MustParse("pl-PL"),
})
// newCollator parses a locale into a collator

View file

@ -78,6 +78,7 @@ export const SettingsInterfacePanel: React.FC = () => {
if (error) return <h1>{error.message}</h1>;
if (loading) return <LoadingIndicator />;
// https://en.wikipedia.org/wiki/List_of_language_names
return (
<>
<SettingSection headingID="config.ui.basic_settings">
@ -87,6 +88,7 @@ export const SettingsInterfacePanel: React.FC = () => {
value={iface.language ?? undefined}
onChange={(v) => saveInterface({ language: v })}
>
<option value="da-DK">Dansk (Danmark)</option>
<option value="de-DE">Deutsch (Deutschland)</option>
<option value="en-GB">English (United Kingdom)</option>
<option value="en-US">English (United States)</option>
@ -97,6 +99,7 @@ export const SettingsInterfacePanel: React.FC = () => {
<option value="it-IT">Italiano</option>
<option value="ja-JP"> ()</option>
<option value="nl-NL">Nederlands (Nederland)</option>
<option value="pl-PL">Polski</option>
<option value="pt-BR">Português (Brasil)</option>
<option value="ru-RU">Русский (Россия) (Preview)</option>
<option value="sv-SE">Svenska</option>

View file

@ -14,6 +14,8 @@ import nlNL from "./nl-NL.json";
import ruRU from "./ru-RU.json";
import trTR from "./tr-TR.json";
import jaJP from "./ja-JP.json";
import plPL from "./pl-PL.json";
import daDK from "./da-DK.json";
export default {
deDE,
@ -32,4 +34,6 @@ export default {
ruRU,
trTR,
jaJP,
plPL,
daDK,
};