Skip to content

Commit 6552e00

Browse files
authored
Merge pull request #209 from matorral-project/full-i18n-support
Complete i18n coverage: wrap remaining hardcoded strings & fix locale catalog
2 parents 5322c8f + 48c8409 commit 6552e00

8 files changed

Lines changed: 48 additions & 20 deletions

File tree

‎apps/landing_pages/views.py‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
from django.http import Http404, HttpResponse, HttpResponseRedirect
33
from django.shortcuts import render
44
from django.templatetags.static import static
5+
from django.utils.translation import gettext_lazy as _
56
from django.views.decorators.cache import cache_control
67
from django.views.decorators.http import require_GET
78

@@ -12,8 +13,8 @@
1213

1314
def home(request):
1415
context = {
15-
"page_title": "Open Source Project Management tool",
16-
"page_description": (
16+
"page_title": _("Open Source Project Management tool"),
17+
"page_description": _(
1718
"Project management made simple, built with Django + HTMX + Tailwind. "
1819
"Open Source. Matorral gives your team a clear, flexible way to plan and deliver software."
1920
),

‎locale/en/LC_MESSAGES/django.mo‎

-27 Bytes
Binary file not shown.

‎locale/en/LC_MESSAGES/django.po‎

Lines changed: 33 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
1-
# SOME DESCRIPTIVE TITLE.
2-
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
3-
# This file is distributed under the same license as the PACKAGE package.
4-
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
1+
# Matorral
2+
# Copyright (C) 2026 Matorral Project
3+
# This file is distributed under the same license as the Matorral package.
54
#
6-
#, fuzzy
75
msgid ""
86
msgstr ""
9-
"Project-Id-Version: PACKAGE VERSION\n"
7+
"Project-Id-Version: matorral\n"
108
"Report-Msgid-Bugs-To: \n"
11-
"POT-Creation-Date: 2026-04-13 21:45+0000\n"
12-
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
13-
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14-
"Language-Team: LANGUAGE <LL@li.org>\n"
15-
"Language: \n"
9+
"POT-Creation-Date: 2026-04-18 12:40+0000\n"
10+
"PO-Revision-Date: 2026-04-18 00:00+0000\n"
11+
"Last-Translator: Matorral Project\n"
12+
"Language-Team: English\n"
13+
"Language: en\n"
1614
"MIME-Version: 1.0\n"
1715
"Content-Type: text/plain; charset=UTF-8\n"
1816
"Content-Transfer-Encoding: 8bit\n"
@@ -747,6 +745,7 @@ msgstr ""
747745
#: apps/sprints/registry.py:238 apps/sprints/registry.py:282
748746
#: apps/sprints/templates/sprints/sprint_confirm_delete.html:25
749747
#: apps/sprints/templates/sprints/sprint_list.html:144
748+
#: templates/attachments/delete.html:6 templates/attachments/delete_link.html:2
750749
#: templates/includes/delete_confirm_modal.html:5
751750
msgid "Delete"
752751
msgstr ""
@@ -2475,6 +2474,17 @@ msgid ""
24752474
"through the %(name)s platform."
24762475
msgstr ""
24772476

2477+
#: apps/landing_pages/views.py:16
2478+
msgid "Open Source Project Management tool"
2479+
msgstr ""
2480+
2481+
#: apps/landing_pages/views.py:18
2482+
msgid ""
2483+
"Project management made simple, built with Django + HTMX + Tailwind. Open "
2484+
"Source. Matorral gives your team a clear, flexible way to plan and deliver "
2485+
"software."
2486+
msgstr ""
2487+
24782488
#: apps/projects/admin.py:39
24792489
msgid "Status & Assignment"
24802490
msgstr ""
@@ -4620,6 +4630,18 @@ msgstr ""
46204630
msgid "The project management tool that doesn't get in your way."
46214631
msgstr ""
46224632

4633+
#: templates/apps/base.html:11
4634+
msgid "open sidebar"
4635+
msgstr ""
4636+
4637+
#: templates/apps/base.html:25
4638+
msgid "close sidebar"
4639+
msgstr ""
4640+
4641+
#: templates/attachments/add.html:8
4642+
msgid "Upload"
4643+
msgstr ""
4644+
46234645
#: templates/attachments/add_form.html:9
46244646
msgid "Add"
46254647
msgstr ""

‎templates/apps/base.html‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
{% extends "base.html" %}
2+
{% load i18n %}
23
{% block top_nav %}{% endblock %}
34
{% block body %}
45
<div class="drawer lg:drawer-open">
@@ -7,7 +8,7 @@
78
<div class="drawer-content flex flex-col h-dvh">
89
<!-- Mobile-only top bar with toggle (hidden on lg+) -->
910
<div class="navbar bg-primary text-primary-content sticky top-0 z-10 lg:hidden">
10-
<label for="sidebar-drawer" aria-label="open sidebar" class="btn btn-square btn-ghost text-primary-content">
11+
<label for="sidebar-drawer" aria-label="{% translate "open sidebar" %}" class="btn btn-square btn-ghost text-primary-content">
1112
<i class="fa fa-bars"></i>
1213
</label>
1314
<a href="{% url 'landing_pages:home' %}" class="text-lg font-semibold text-primary-content">{{ site.name }}</a>
@@ -21,7 +22,7 @@
2122
</div>
2223

2324
<div class="drawer-side is-drawer-close:overflow-visible z-40">
24-
<label for="sidebar-drawer" aria-label="close sidebar" class="drawer-overlay"></label>
25+
<label for="sidebar-drawer" aria-label="{% translate "close sidebar" %}" class="drawer-overlay"></label>
2526
{% include "includes/sidebar_app.html" %}
2627
</div>
2728
</div>

‎templates/attachments/add.html‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
1+
{% load i18n %}
12
{% if form_url %}
23
<form method="post" action="{{ form_url }}" enctype="multipart/form-data">
34
{% csrf_token %}
45
<input type="hidden" name="next" value="{{ next }}">
56
<div class="flex items-center gap-3">
67
<input type="file" name="attachment_file" class="file-input file-input-sm file-input-bordered flex-1">
7-
<button type="submit" class="btn btn-sm btn-primary">Upload</button>
8+
<button type="submit" class="btn btn-sm btn-primary">{% translate "Upload" %}</button>
89
</div>
910
</form>
1011
{% endif %}

‎templates/attachments/delete.html‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1+
{% load i18n %}
12
{% if delete_url %}
23
<form method="post" action="{{ delete_url }}" style="display:inline">
34
{% csrf_token %}
45
<input type="hidden" name="next" value="{{ next }}">
5-
<button type="submit" class="btn btn-xs btn-error btn-outline">Delete</button>
6+
<button type="submit" class="btn btn-xs btn-error btn-outline">{% translate "Delete" %}</button>
67
</form>
78
{% endif %}
Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
{% if delete_url %}<a class="delete-attachment" href="{{ delete_url }}?next={{ next }}">Delete</a>{% endif %}
1+
{% load i18n %}
2+
{% if delete_url %}<a class="delete-attachment" href="{{ delete_url }}?next={{ next }}">{% translate "Delete" %}</a>{% endif %}

‎templates/base.html‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
{% load static django_vite %}
1+
{% load static django_vite i18n %}
2+
{% get_current_language as LANGUAGE_CODE %}
23
<!DOCTYPE html>
3-
<html lang="en" data-theme="light">
4+
<html lang="{{ LANGUAGE_CODE }}" data-theme="light">
45
<head>
56
<meta charset="utf-8">
67
<meta http-equiv="X-UA-Compatible" content="IE=edge">

0 commit comments

Comments
 (0)