Skip to content

Commit 1f1118c

Browse files
authored
fix: fix localization for Earth and apsis (#275)
* fix: add missing string for Earth * fix: use more generic terms "apoapsis" and "periapsis" * chore: update messages file
1 parent 948619b commit 1f1118c

File tree

2 files changed

+16
-11
lines changed

2 files changed

+16
-11
lines changed

kosmorro/i18n/strings.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ def from_event(event: Event, with_description: bool = True) -> Union[None, str]:
1515
_("Elongation of %s is maximal"),
1616
lambda e: "{:.3n}°".format(e.details["deg"]),
1717
),
18-
EventType.PERIGEE: (_("%s is at its perigee"), None),
19-
EventType.APOGEE: (_("%s is at its apogee"), None),
18+
EventType.PERIGEE: (_("%s is at its periapsis"), None),
19+
EventType.APOGEE: (_("%s is at its apoapsis"), None),
2020
}.get(event.event_type, (None, None))
2121

2222
if string is None:
@@ -54,6 +54,7 @@ def from_object(identifier: ObjectIdentifier) -> str:
5454
ObjectIdentifier.MOON: _("Moon"),
5555
ObjectIdentifier.MERCURY: _("Mercury"),
5656
ObjectIdentifier.VENUS: _("Venus"),
57+
ObjectIdentifier.EARTH: _("Earth"),
5758
ObjectIdentifier.MARS: _("Mars"),
5859
ObjectIdentifier.JUPITER: _("Jupiter"),
5960
ObjectIdentifier.SATURN: _("Saturn"),

kosmorro/locales/messages.pot

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@ msgid ""
88
msgstr ""
99
"Project-Id-Version: PROJECT VERSION\n"
1010
"Report-Msgid-Bugs-To: EMAIL@ADDRESS\n"
11-
"POT-Creation-Date: 2022-06-15 13:19+0200\n"
11+
"POT-Creation-Date: 2022-07-07 13:10+0200\n"
1212
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
1313
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
1414
"Language-Team: LANGUAGE <LL@li.org>\n"
1515
"MIME-Version: 1.0\n"
1616
"Content-Type: text/plain; charset=utf-8\n"
1717
"Content-Transfer-Encoding: 8bit\n"
18-
"Generated-By: Babel 2.10.2\n"
18+
"Generated-By: Babel 2.10.3\n"
1919

2020
#: kosmorro/__main__.py:61
2121
msgid ""
@@ -233,12 +233,12 @@ msgstr ""
233233

234234
#: kosmorro/i18n/strings.py:18
235235
#, python-format
236-
msgid "%s is at its perigee"
236+
msgid "%s is at its periapsis"
237237
msgstr ""
238238

239239
#: kosmorro/i18n/strings.py:19
240240
#, python-format
241-
msgid "%s is at its apogee"
241+
msgid "%s is at its apoapsis"
242242
msgstr ""
243243

244244
#: kosmorro/i18n/strings.py:35
@@ -290,26 +290,30 @@ msgid "Venus"
290290
msgstr ""
291291

292292
#: kosmorro/i18n/strings.py:57
293-
msgid "Mars"
293+
msgid "Earth"
294294
msgstr ""
295295

296296
#: kosmorro/i18n/strings.py:58
297-
msgid "Jupiter"
297+
msgid "Mars"
298298
msgstr ""
299299

300300
#: kosmorro/i18n/strings.py:59
301-
msgid "Saturn"
301+
msgid "Jupiter"
302302
msgstr ""
303303

304304
#: kosmorro/i18n/strings.py:60
305-
msgid "Uranus"
305+
msgid "Saturn"
306306
msgstr ""
307307

308308
#: kosmorro/i18n/strings.py:61
309-
msgid "Neptune"
309+
msgid "Uranus"
310310
msgstr ""
311311

312312
#: kosmorro/i18n/strings.py:62
313+
msgid "Neptune"
314+
msgstr ""
315+
316+
#: kosmorro/i18n/strings.py:63
313317
msgid "Pluto"
314318
msgstr ""
315319

0 commit comments

Comments
 (0)