From fdc674c6ddf928030758ff07037d034920214b61 Mon Sep 17 00:00:00 2001 From: PPsyrius <19505219+PPsyrius@users.noreply.github.com> Date: Mon, 23 Dec 2024 10:11:16 +0700 Subject: [PATCH 1/4] Add Ukraine holidays localization: th --- README.rst | 2 +- holidays/countries/ukraine.py | 2 +- holidays/locale/th/LC_MESSAGES/UA.po | 114 +++++++++++++++++++++++++++ tests/countries/test_ukraine.py | 24 ++++++ 4 files changed, 140 insertions(+), 2 deletions(-) create mode 100644 holidays/locale/th/LC_MESSAGES/UA.po diff --git a/README.rst b/README.rst index 6e1608f89..e4f499b90 100644 --- a/README.rst +++ b/README.rst @@ -888,7 +888,7 @@ All other default values are highlighted with bold: * - Ukraine - UA - - - ar, en_US, **uk** + - ar, en_US, th, **uk** - WORKDAY * - United Arab Emirates - AE diff --git a/holidays/countries/ukraine.py b/holidays/countries/ukraine.py index 8f4eca797..11881d253 100644 --- a/holidays/countries/ukraine.py +++ b/holidays/countries/ukraine.py @@ -34,7 +34,7 @@ class Ukraine(ObservedHolidayBase, ChristianHolidays, InternationalHolidays, Sta # %s (observed). observed_label = tr("%s (вихідний)") supported_categories = (PUBLIC, WORKDAY) - supported_languages = ("ar", "en_US", "uk") + supported_languages = ("ar", "en_US", "th", "uk") # The current set of holidays came into force in 1991. start_year = 1991 diff --git a/holidays/locale/th/LC_MESSAGES/UA.po b/holidays/locale/th/LC_MESSAGES/UA.po new file mode 100644 index 000000000..3ee64c80a --- /dev/null +++ b/holidays/locale/th/LC_MESSAGES/UA.po @@ -0,0 +1,114 @@ +# holidays +# -------- +# A fast, efficient Python library for generating country, province and state +# specific sets of holidays on the fly. It aims to make determining whether a +# specific date is a holiday as fast and flexible as possible. +# +# Authors: Vacanza Team and individual contributors (see AUTHORS file) +# dr-prodigy (c) 2017-2023 +# ryanss (c) 2014-2017 +# Website: https://github.com/vacanza/holidays +# License: MIT (see LICENSE file) +# +# Ukraine holidays. +# +msgid "" +msgstr "" +"Project-Id-Version: Holidays 0.55\n" +"POT-Creation-Date: 2023-07-08 19:40+0300\n" +"PO-Revision-Date: 2024-12-20 19:18+0700\n" +"Last-Translator: PPsyrius \n" +"Language-Team: Holidays Localization Team\n" +"Language: uk\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"Generated-By: Lingua 4.15.0\n" +"X-Generator: Poedit 3.5\n" + +#. %s (observed). +#, c-format +msgid "%s (вихідний)" +msgstr "ชดเชย%s" + +#. New Year's Day. +msgid "Новий рік" +msgstr "วันขึ้นปีใหม่" + +#. International Women's Day. +msgid "Міжнародний жіночий день" +msgstr "วันสตรีสากล" + +#. Easter Sunday (Pascha). +msgid "Великдень (Пасха)" +msgstr "วันอาทิตย์อีสเตอร์" + +#. Holy Trinity Day. +msgid "Трійця" +msgstr "วันสมโภชพระตรีเอกภาพ" + +#. Labor Day. +msgid "День праці" +msgstr "วันแรงงาน" + +#. International Workers' Solidarity Day. +msgid "День міжнародної солідарності трудящих" +msgstr "วันสมานฉันท์แรงงานสากล" + +#. Day of Remembrance and Victory over Nazism in World War II 1939-1945. +msgid "" +"День памʼяті та перемоги над нацизмом у Другій світовій війні 1939-1945 " +"років" +msgstr "" +"วันแห่งความทรงจำและชัยชนะเหนือระบอบชาติสังคมนิยมในสงครามโลกครั้งที่สอง " +"1939-1945" + +#. Day of Victory over Nazism in World War II (Victory Day). +msgid "День перемоги над нацизмом у Другій світовій війні (День перемоги)" +msgstr "" +"วันแห่งชัยชนะเหนือระบอบชาติสังคมนิยมในสงครามโลกครั้งที่สอง (วันแห่งชัยชนะ)" + +#. Victory Day. +msgid "День перемоги" +msgstr "วันแห่งชัยชนะ" + +#. Day of the Constitution of Ukraine. +msgid "День Конституції України" +msgstr "วันรัฐธรรมนูญยูเครน" + +#. Ukrainian Statehood Day. +msgid "День Української Державності" +msgstr "วันรัฐยูเครน" + +#. Independence Day. +msgid "День незалежності України" +msgstr "วันประกาศอิสรภาพยูเครน" + +#. Day of defenders of Ukraine. +msgid "День захисників і захисниць України" +msgstr "วันแห่งผู้พิทักษ์ยูเครน" + +#. Defender of Ukraine Day. +msgid "День захисника України" +msgstr "วันผู้พิทักษ์ยูเครน" + +#. Anniversary of the Great October Socialist Revolution. +msgid "Річниця Великої Жовтневої соціалістичної революції" +msgstr "วันครบรอบการปฏิวัติสังคมนิยมแห่งเดือนตุลาคมอันยิ่งใหญ่" + +#. Christmas Day. +msgid "Різдво Христове" +msgstr "วันคริสต์มาส" + +#. Date format (see strftime() Format Codes) +msgid "%d.%m.%Y" +msgstr "%d/%m/%Y" + +#. Day off (substituted from %s). +#, c-format +msgid "Вихідний день (перенесено з %s)" +msgstr "วันหยุด (แทน %s)" + +#. Presidential decree holiday. +msgid "Вихідний згідно указу Президента" +msgstr "วันหยุดตามประกาศคำสั่งประธานาธิบดี" diff --git a/tests/countries/test_ukraine.py b/tests/countries/test_ukraine.py index b4332e6b6..630b31bd3 100644 --- a/tests/countries/test_ukraine.py +++ b/tests/countries/test_ukraine.py @@ -574,3 +574,27 @@ def test_l10n_ar(self): ("2021-12-25", "عيد الميلاد"), ("2021-12-27", "(يوم عطلة) عيد الميلاد"), ) + + def test_l10n_th(self): + self.assertLocalizedHolidays( + "th", + ("2021-01-01", "วันขึ้นปีใหม่"), + ("2021-01-07", "วันคริสต์มาส"), + ("2021-01-08", "วันหยุด (แทน 16/01/2021)"), + ("2021-03-08", "วันสตรีสากล"), + ("2021-05-01", "วันแรงงาน"), + ("2021-05-02", "วันอาทิตย์อีสเตอร์"), + ("2021-05-03", "ชดเชยวันแรงงาน"), + ("2021-05-04", "ชดเชยวันอาทิตย์อีสเตอร์"), + ("2021-05-09", "วันแห่งชัยชนะเหนือระบอบชาติสังคมนิยมในสงครามโลกครั้งที่สอง (วันแห่งชัยชนะ)"), + ("2021-05-10", "ชดเชยวันแห่งชัยชนะเหนือระบอบชาติสังคมนิยมในสงครามโลกครั้งที่สอง (วันแห่งชัยชนะ)"), + ("2021-06-20", "วันสมโภชพระตรีเอกภาพ"), + ("2021-06-21", "ชดเชยวันสมโภชพระตรีเอกภาพ"), + ("2021-06-28", "วันรัฐธรรมนูญยูเครน"), + ("2021-08-23", "วันหยุด (แทน 28/08/2021)"), + ("2021-08-24", "วันประกาศอิสรภาพยูเครน"), + ("2021-10-14", "วันแห่งผู้พิทักษ์ยูเครน"), + ("2021-10-15", "วันหยุด (แทน 23/10/2021)"), + ("2021-12-25", "วันคริสต์มาส"), + ("2021-12-27", "ชดเชยวันคริสต์มาส"), + ) From 2509e5956fd2822af7a5a7407536da68146f9863 Mon Sep 17 00:00:00 2001 From: PPsyrius <19505219+PPsyrius@users.noreply.github.com> Date: Mon, 23 Dec 2024 14:10:38 +0700 Subject: [PATCH 2/4] Forgot to update .po file header --- holidays/locale/th/LC_MESSAGES/UA.po | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/holidays/locale/th/LC_MESSAGES/UA.po b/holidays/locale/th/LC_MESSAGES/UA.po index 3ee64c80a..1e9707a80 100644 --- a/holidays/locale/th/LC_MESSAGES/UA.po +++ b/holidays/locale/th/LC_MESSAGES/UA.po @@ -10,13 +10,13 @@ # Website: https://github.com/vacanza/holidays # License: MIT (see LICENSE file) # -# Ukraine holidays. +# Ukraine holidays th localization. # msgid "" msgstr "" "Project-Id-Version: Holidays 0.55\n" "POT-Creation-Date: 2023-07-08 19:40+0300\n" -"PO-Revision-Date: 2024-12-20 19:18+0700\n" +"PO-Revision-Date: 2024-12-23 14:10+0700\n" "Last-Translator: PPsyrius \n" "Language-Team: Holidays Localization Team\n" "Language: uk\n" From 861d60867fb289a3f8f80bc2ed5f611bdd3a09e6 Mon Sep 17 00:00:00 2001 From: PPsyrius <19505219+PPsyrius@users.noreply.github.com> Date: Mon, 23 Dec 2024 14:43:15 +0700 Subject: [PATCH 3/4] Forgot to update .po file header, again --- holidays/locale/th/LC_MESSAGES/UA.po | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/holidays/locale/th/LC_MESSAGES/UA.po b/holidays/locale/th/LC_MESSAGES/UA.po index 1e9707a80..505af2d19 100644 --- a/holidays/locale/th/LC_MESSAGES/UA.po +++ b/holidays/locale/th/LC_MESSAGES/UA.po @@ -19,7 +19,7 @@ msgstr "" "PO-Revision-Date: 2024-12-23 14:10+0700\n" "Last-Translator: PPsyrius \n" "Language-Team: Holidays Localization Team\n" -"Language: uk\n" +"Language: th\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" From b19e8e0a71ae8ee2f06c142c54fb58ab46b69249 Mon Sep 17 00:00:00 2001 From: Arkadii Yakovets <2201626+arkid15r@users.noreply.github.com> Date: Mon, 23 Dec 2024 12:00:31 -0800 Subject: [PATCH 4/4] Update holidays/locale/th/LC_MESSAGES/UA.po Co-authored-by: ~Jhellico --- holidays/locale/th/LC_MESSAGES/UA.po | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/holidays/locale/th/LC_MESSAGES/UA.po b/holidays/locale/th/LC_MESSAGES/UA.po index 505af2d19..1034127f6 100644 --- a/holidays/locale/th/LC_MESSAGES/UA.po +++ b/holidays/locale/th/LC_MESSAGES/UA.po @@ -14,7 +14,7 @@ # msgid "" msgstr "" -"Project-Id-Version: Holidays 0.55\n" +"Project-Id-Version: Holidays 0.64\n" "POT-Creation-Date: 2023-07-08 19:40+0300\n" "PO-Revision-Date: 2024-12-23 14:10+0700\n" "Last-Translator: PPsyrius \n"