Skip to content

Commit

Permalink
language fix
Browse files Browse the repository at this point in the history
  • Loading branch information
JesseWebDotCom committed Jul 7, 2023
1 parent 6a76683 commit 49ad7de
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 6 deletions.
12 changes: 11 additions & 1 deletion resources/lang/de.po
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,18 @@ msgid "SETTINGS"
msgstr "INSTELLINGEN"

# RELATION
msgid "you"
msgctxt "modern-relation"
msgid "himself"
msgstr "du"

msgctxt "modern-relation"
msgid "herself"
msgstr "du"

msgctxt "modern-relation"
msgid "themself"
msgstr "du"

msgctxt "modern-relation"
msgid "your"
msgstr "dein"
13 changes: 11 additions & 2 deletions resources/lang/en-US.po
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,19 @@ msgstr "MAIN MENU"
msgid "SETTINGS"
msgstr "SETTINGS"


# RELATION
msgid "you"
msgctxt "modern-relation"
msgid "himself"
msgstr "you"

msgctxt "modern-relation"
msgid "herself"
msgstr "you"

msgctxt "modern-relation"
msgid "themself"
msgstr "you"

msgctxt "modern-relation"
msgid "your"
msgstr "your"
17 changes: 17 additions & 0 deletions resources/lang/nl.po
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,20 @@ msgstr "HOOFDMENU"

msgid "SETTINGS"
msgstr "INSTELLINGEN"

# RELATION
msgctxt "modern-relation"
msgid "himself"
msgstr "jij"

msgctxt "modern-relation"
msgid "herself"
msgstr "jij"

msgctxt "modern-relation"
msgid "themself"
msgstr "jij"

msgctxt "modern-relation"
msgid "your"
msgstr "jouw"
8 changes: 5 additions & 3 deletions resources/views/individual-page.phtml
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,12 @@ if ($user !== null) {
$relationship = $relationship_service->getCloseRelationshipName($individual1, $record);

if (!empty($relationship)) {
if ($relationship === 'himself' || $relationship === 'herself' || $relationship === 'themself') {
$relationship = I18N::translate('you');
$translated = I18N::translateContext('modern-relation', $relationship);

if ($translated === I18N::translateContext('modern-relation', 'himself') || $relationship === I18N::translateContext('modern-relation', 'herself') || $relationship === I18N::translateContext('modern-relation', 'themself')) {
$relationship = $translated;
} else {
$relationship = I18N::translate('your') . ' ' . I18N::translate($relationship);
$relationship = I18N::translateContext('modern-relation', 'your') . ' ' . $translated;
}
}
}
Expand Down

0 comments on commit 49ad7de

Please sign in to comment.