88 {% blocktrans with workspace_title=workspace.title %}{{ workspace_title }} projects - Projectify{% endblocktrans %}
99{% endblock title %}
1010{% block workspace_settings_content %}
11- < section class ="flex flex-col gap-4 ">
12- < h2 > {% translate "Projects" %}</ h2 >
13- < table class ="grid w-full grid-cols-4 ">
11+ < section class ="flex flex-col gap-2 ">
12+ < h2 class =" font-bold text-lg " > {% translate "Projects" %}</ h2 >
13+ < table class ="grid w-full gap-x-2 gap-y-3 grid-cols-[3fr_max-content] ">
1414 < thead class ="contents ">
1515 < tr class ="contents ">
16- < th class ="text-left col-span-2 "> {% translate "Project name" %}</ th >
17- < th > </ th >
16+ < th class ="text-left "> {% translate "Project name" %}</ th >
1817 < th > </ th >
1918 </ tr >
2019 </ thead >
2120 < tbody class ="contents ">
2221 {% for project in projects %}
2322 < tr class ="contents ">
24- < td class =" col-span-2 " > {{ project }}</ td >
25- < td >
23+ < td > {{ project }}</ td >
24+ < td class =" flex gap-4 items-center " >
2625 {% has_perm "workspace.update_project" user project as can_update_project %}
2726 {% if can_update_project %}
2827 {% url 'dashboard:projects:update' project_uuid=project.uuid as update_url %}
2928 {% anchor href=update_url label=_("Update") %}
30- {% endif %}
31- </ td >
32- < td >
33- {% has_perm "workspace.update_project" user project as can_update_project %}
34- {# XXX limitation: This only works if javascript is enabled #}
35- {% if can_update_project %}
29+ {# XXX limitation: This only works if javascript is enabled #}
3630 < button hx-post ="{% url 'dashboard:projects:archive' project_uuid=project.uuid %} "
37- hx-confirm ="{% translate ' Are you sure you want to archive this project?' %} "
31+ hx-confirm ="{% blocktranslate with project=project.title %} Are you sure you want to archive the '{{ project }}' project?{% endblocktranslate %} "
3832 hx-target ="closest tr "
3933 hx-swap ="outerHTML "
4034 class ="text-red-600 hover:text-red-800 "> {% translate "Archive" %}</ button >
@@ -45,35 +39,32 @@ <h2>{% translate "Projects" %}</h2>
4539 </ tbody >
4640 </ table >
4741 </ section >
48- < section class ="flex flex-col gap-4 ">
49- < h2 > {% translate "Archived projects" %}</ h2 >
50- < table class ="grid w-full grid-cols-4 ">
42+ < section class ="flex flex-col gap-2 ">
43+ < h2 class =" font-bold text-lg " > {% translate "Archived projects" %}</ h2 >
44+ < table class ="grid w-full gap-x-2 gap-y-3 grid-cols-[3fr_max-content] ">
5145 < thead class ="contents ">
5246 < tr class ="contents ">
53- < th class ="text-left col-span-2 "> {% translate "Project name" %}</ th >
54- < th > </ th >
47+ < th class ="text-left "> {% translate "Project name" %}</ th >
5548 < th > </ th >
5649 </ tr >
5750 </ thead >
5851 < tbody class ="contents ">
5952 {% for archived_project in archived_projects %}
6053 < tr class ="contents ">
61- < td class =" col-span-2 " > {{ archived_project }}</ td >
62- < td >
54+ < td > {{ archived_project }}</ td >
55+ < td class =" flex gap-4 items-center " >
6356 {% has_perm "workspace.update_project" user project as can_update_project %}
6457 {% if can_update_project %}
6558 < button hx-post ="{% url 'dashboard:projects:recover' project_uuid=archived_project.uuid %} "
66- hx-confirm ="{% translate ' Are you sure you want to recover this project?' %} "
59+ hx-confirm ="{% blocktranslate with project=archived_project.title %} Are you sure you want to recover the '{{ project }}' project?{% endblocktranslate %} "
6760 hx-target ="closest tr "
6861 hx-swap ="outerHTML "
6962 class ="text-green-600 hover:text-green-800 "> {% translate "Recover" %}</ button >
7063 {% endif %}
71- </ td >
72- < td >
73- {% has_perm "workspace.update_project" user project as can_update_project %}
74- {% if can_update_project %}
64+ {% has_perm "workspace.delete_project" user project as can_delete_project %}
65+ {% if can_delete_project %}
7566 < button hx-post ="{% url 'dashboard:projects:delete' project_uuid=archived_project.uuid %} "
76- hx-confirm ="{% translate ' Are you sure you want to permanently delete this project? This action cannot be undone.' %} "
67+ hx-confirm ="{% blocktranslate with project=archived_project.title %} Are you sure you want to permanently delete the '{{ project }}' project ? This action cannot be undone. {% endblocktranslate %} "
7768 hx-target ="closest tr "
7869 hx-swap ="outerHTML "
7970 class ="text-red-600 hover:text-red-800 "> {% translate "Delete" %}</ button >
@@ -84,4 +75,13 @@ <h2>{% translate "Archived projects" %}</h2>
8475 </ tbody >
8576 </ table >
8677 </ section >
78+ < hr >
79+ < section class ="flex flex-col gap-2 ">
80+ < strong > {% trans "Help" %}</ strong >
81+ < ul class ="flex list-inside list-disc flex-col gap-2 ">
82+ < li >
83+ {% url 'help:detail' page='projects' as help_url %}{% anchor href=help_url label=_("About projects") external=True %}
84+ </ li >
85+ </ ul >
86+ </ section >
8787{% endblock workspace_settings_content %}
0 commit comments