django-unfold 0.33.0__py3-none-any.whl → 0.35.0__py3-none-any.whl

Sign up to get free protection for your applications and to get access to all the features.
Files changed (74) hide show
  1. {django_unfold-0.33.0.dist-info → django_unfold-0.35.0.dist-info}/METADATA +33 -5
  2. {django_unfold-0.33.0.dist-info → django_unfold-0.35.0.dist-info}/RECORD +74 -73
  3. unfold/admin.py +12 -14
  4. unfold/contrib/filters/admin.py +34 -1
  5. unfold/contrib/filters/forms.py +36 -3
  6. unfold/contrib/filters/templates/unfold/filters/filters_date_range.html +1 -1
  7. unfold/contrib/filters/templates/unfold/filters/filters_datetime_range.html +1 -1
  8. unfold/contrib/filters/templates/unfold/filters/filters_numeric_range.html +1 -1
  9. unfold/contrib/filters/templates/unfold/filters/filters_numeric_single.html +1 -1
  10. unfold/contrib/filters/templates/unfold/filters/filters_numeric_slider.html +1 -1
  11. unfold/contrib/guardian/templates/unfold/guardian/group_form.html +10 -10
  12. unfold/contrib/guardian/templates/unfold/guardian/user_form.html +10 -10
  13. unfold/contrib/import_export/templates/admin/import_export/import_confirm.html +1 -1
  14. unfold/contrib/import_export/templates/admin/import_export/import_errors.html +3 -3
  15. unfold/contrib/import_export/templates/admin/import_export/import_preview.html +6 -6
  16. unfold/contrib/import_export/templates/admin/import_export/import_validation.html +8 -8
  17. unfold/contrib/simple_history/templates/simple_history/object_history_list.html +18 -18
  18. unfold/decorators.py +2 -2
  19. unfold/fields.py +2 -2
  20. unfold/forms.py +2 -1
  21. unfold/static/unfold/css/styles.css +1 -1
  22. unfold/static/unfold/js/app.js +23 -0
  23. unfold/static/unfold/js/select2.init.js +15 -0
  24. unfold/styles.css +6 -10
  25. unfold/templates/admin/actions.html +14 -12
  26. unfold/templates/admin/app_list.html +3 -5
  27. unfold/templates/admin/change_form.html +1 -1
  28. unfold/templates/admin/change_list.html +4 -4
  29. unfold/templates/admin/change_list_results.html +4 -4
  30. unfold/templates/admin/delete_confirmation.html +9 -9
  31. unfold/templates/admin/delete_selected_confirmation.html +9 -9
  32. unfold/templates/admin/edit_inline/stacked.html +64 -58
  33. unfold/templates/admin/edit_inline/tabular.html +11 -11
  34. unfold/templates/admin/filter.html +5 -5
  35. unfold/templates/admin/includes/object_delete_summary.html +2 -2
  36. unfold/templates/admin/object_history.html +9 -9
  37. unfold/templates/admin/pagination.html +3 -3
  38. unfold/templates/admin/submit_line.html +7 -7
  39. unfold/templates/unfold/change_list_filter.html +3 -3
  40. unfold/templates/unfold/components/progress.html +1 -1
  41. unfold/templates/unfold/components/table.html +4 -4
  42. unfold/templates/unfold/components/title.html +1 -1
  43. unfold/templates/unfold/helpers/account_links.html +2 -2
  44. unfold/templates/unfold/helpers/actions_row.html +14 -12
  45. unfold/templates/unfold/helpers/add_link.html +2 -2
  46. unfold/templates/unfold/helpers/app_list.html +7 -7
  47. unfold/templates/unfold/helpers/app_list_default.html +7 -7
  48. unfold/templates/unfold/helpers/breadcrumb_item.html +1 -1
  49. unfold/templates/unfold/helpers/display_header.html +4 -2
  50. unfold/templates/unfold/helpers/field_readonly_value.html +1 -1
  51. unfold/templates/unfold/helpers/fieldset_row.html +1 -1
  52. unfold/templates/unfold/helpers/fieldsets_tabs.html +1 -1
  53. unfold/templates/unfold/helpers/help_text.html +1 -1
  54. unfold/templates/unfold/helpers/history.html +3 -3
  55. unfold/templates/unfold/helpers/label.html +6 -6
  56. unfold/templates/unfold/helpers/messages.html +12 -1
  57. unfold/templates/unfold/helpers/navigation.html +1 -1
  58. unfold/templates/unfold/helpers/search_results.html +2 -2
  59. unfold/templates/unfold/helpers/site_icon.html +1 -1
  60. unfold/templates/unfold/helpers/tab_action.html +1 -1
  61. unfold/templates/unfold/helpers/tab_list.html +9 -5
  62. unfold/templates/unfold/helpers/theme_switch.html +2 -2
  63. unfold/templates/unfold/helpers/welcomemsg.html +5 -3
  64. unfold/templates/unfold/layouts/skeleton.html +2 -2
  65. unfold/templates/unfold/widgets/clearable_file_input.html +2 -2
  66. unfold/templates/unfold/widgets/clearable_file_input_small.html +2 -2
  67. unfold/templates/unfold/widgets/foreign_key_raw_id.html +8 -4
  68. unfold/templates/unfold/widgets/radio_option.html +1 -1
  69. unfold/templates/unfold/widgets/split_datetime.html +2 -2
  70. unfold/templates/unfold/widgets/split_datetime_vertical.html +2 -2
  71. unfold/templatetags/unfold_list.py +6 -7
  72. unfold/widgets.py +21 -6
  73. {django_unfold-0.33.0.dist-info → django_unfold-0.35.0.dist-info}/LICENSE.md +0 -0
  74. {django_unfold-0.33.0.dist-info → django_unfold-0.35.0.dist-info}/WHEEL +0 -0
@@ -8,11 +8,11 @@
8
8
  {% if app.models and not app.hidden %}
9
9
  <li>
10
10
  {% if app.name %}
11
- <h3>
11
+ <h2>
12
12
  <a href="{{ app.app_url }}" class="block font-semibold mb-2 mt-4 text-gray-700 text-sm truncate dark:text-gray-200" title="{% blocktranslate with name=app.name %}Models in the {{ name }} application{% endblocktranslate %}">
13
13
  {{ app.name }}
14
14
  </a>
15
- </h3>
15
+ </h2>
16
16
  {% endif %}
17
17
 
18
18
  <ol>
@@ -27,10 +27,8 @@
27
27
 
28
28
  {% if model.admin_url %}
29
29
  <a href="{{ model.admin_url }}" id="link-{{ app.app_label }}-{{ model.object_name|lower }}"
30
- class="border border-transparent flex h-11 items-center -mx-3 px-3 py-2 rounded-md transition-all truncate {% if model.admin_url in request.path|urlencode %}bg-gray-100 font-semibold text-primary-600 dark:border dark:border-gray-800 dark:bg-white/[.02] dark:text-primary-500{% else %}text-gray-500 hover:text-gray-700 dark:text-gray-300 dark:hover:text-gray-200{% endif %}">
31
- <span class="text-sm">
30
+ class="block -mx-3 px-3 py-3 rounded-md truncate {% if model.admin_url in request.path|urlencode %}bg-gray-100 font-semibold text-primary-600 dark:bg-white/[.06] dark:text-primary-500{% else %} hover:text-gray-700 dark:hover:text-gray-200{% endif %}">
32
31
  {{ model.name }}
33
- </span>
34
32
  </a>
35
33
  {% else %}
36
34
  {{ model.name }}
@@ -59,7 +59,7 @@
59
59
 
60
60
  {% block content %}
61
61
  <div id="content-main">
62
- <form {% if has_file_field %}enctype="multipart/form-data" {% endif %}{% if form_url %}action="{{ form_url }}" {% endif %}method="post" id="{{ opts.model_name }}_form" novalidate>
62
+ <form {% if has_file_field %}enctype="multipart/form-data" {% endif %}{% if form_url %}action="{{ form_url }}" {% endif %}method="post" id="{{ opts.model_name }}_form" {% if adminform.model_admin.warn_unsaved_form %}class="warn-unsaved-form"{% endif %} novalidate>
63
63
  {% csrf_token %}
64
64
 
65
65
  {% block form_top %}{% endblock %}
@@ -50,11 +50,11 @@
50
50
 
51
51
  {% block nav-global-side %}
52
52
  {% block object-tools %}
53
- <ul class="object-tools">
53
+ <div class="object-tools">
54
54
  {% block object-tools-items %}
55
55
  {% change_list_object_tools %}
56
56
  {% endblock %}
57
- </ul>
57
+ </div>
58
58
  {% endblock %}
59
59
  {% endblock %}
60
60
 
@@ -95,10 +95,10 @@
95
95
 
96
96
  {% block filters %}
97
97
  {% if cl.has_filters %}
98
- <a class="{% if cl.has_active_filters %}bg-primary-600 border-primary-600 text-white{% else %}bg-white text-gray-500 hover:text-gray-700 dark:bg-gray-900 dark:border-gray-700 dark:hover:text-gray-200 dark:text-gray-300{% endif %} border cursor-pointer flex font-medium group items-center px-3 py-2 rounded-md shadow-sm text-sm lg:ml-auto md:mt-0" x-on:click="filterOpen = true" x-on:keydown.escape.window="filterOpen = false">
98
+ <a class="{% if cl.has_active_filters %}bg-primary-600 border-primary-600 text-white{% else %}bg-white hover:text-gray-700 dark:bg-gray-900 dark:border-gray-700 dark:hover:text-gray-200{% endif %} border cursor-pointer flex font-medium group items-center px-3 py-2 rounded-md shadow-sm text-sm lg:ml-auto md:mt-0" x-on:click="filterOpen = true" x-on:keydown.escape.window="filterOpen = false">
99
99
  {% trans "Filters" %}
100
100
 
101
- <span class="material-symbols-outlined md-18 ml-auto -mr-1 pl-4 {% if cl.has_active_filters %}text-white{% else %}text-gray-400 group-hover:text-gray-700 dark:group-hover:text-gray-200 dark:text-gray-500{% endif %}">filter_list</span>
101
+ <span class="material-symbols-outlined md-18 ml-auto -mr-1 pl-4 {% if cl.has_active_filters %}text-white{% else %}text-gray-400 group-hover:text-gray-500 dark:group-hover:text-gray-400 dark:text-gray-500{% endif %}">filter_list</span>
102
102
  </a>
103
103
  {% endif %}
104
104
  {% endblock %}
@@ -8,11 +8,11 @@
8
8
 
9
9
  {% if results %}
10
10
  <div class="overflow-x-auto lg:border lg:rounded-md lg:shadow-sm lg:dark:border-gray-800 {% if cl.model_admin.list_horizontal_scrollbar_top %}simplebar-horizontal-scrollbar-top{% endif %}" data-simplebar data-simplebar-auto-hide="false">
11
- <table id="result_list" class="block border-gray-200 border-spacing-none border-separate text-gray-700 w-full dark:text-gray-300 lg:table">
11
+ <table id="result_list" class="block border-gray-200 border-spacing-none border-separate w-full lg:table">
12
12
  <thead>
13
13
  <tr>
14
14
  {% for header in result_headers %}
15
- <th class="align-middle font-medium py-2 text-left text-gray-400 text-sm whitespace-nowrap {{ header.class_attrib }} {% if "action-toggle" in header.text and forloop.counter == 1 %}lg:px-3 lg:w-10{% else %}hidden px-3 lg:table-cell{% endif %}" scope="col">
15
+ <th class="align-middle font-semibold py-2 text-left text-gray-900 dark:text-gray-100 text-sm whitespace-nowrap {{ header.class_attrib }} {% if "action-toggle" in header.text and forloop.counter == 1 %}lg:px-3 lg:w-10{% else %}hidden px-3 lg:table-cell{% endif %}" scope="col">
16
16
  <div class="flex items-center">
17
17
  <div class="text">
18
18
  {% if header.sortable %}
@@ -39,7 +39,7 @@
39
39
  {% if header.sortable %}
40
40
  {% if header.sort_priority > 0 %}
41
41
  <div class="sortoptions flex items-center ml-2">
42
- <a href="{{ header.url_toggle }}" class="flex items-center leading-none text-gray-400 hover:text-gray-700 dark:hover:text-gray-200 toggle {% if header.ascending %}ascending{% else %}descending{% endif %}" title="{% translate "Toggle sorting" %}">
42
+ <a href="{{ header.url_toggle }}" class="flex items-center leading-none text-gray-400 hover:text-gray-500 dark:text-gray-500 dark:hover:text-gray-400 toggle {% if header.ascending %}ascending{% else %}descending{% endif %}" title="{% translate "Toggle sorting" %}">
43
43
  {% if header.ascending %}
44
44
  <span class="block material-symbols-outlined">arrow_circle_down</span>
45
45
  {% else %}
@@ -47,7 +47,7 @@
47
47
  {% endif %}
48
48
  </a>
49
49
 
50
- <a class="sortremove flex items-center leading-none ml-1 text-gray-400 transition-all hover:text-red-700 dark:hover:text-red-500" href="{{ header.url_remove }}" title="{% translate "Remove from sorting" %}">
50
+ <a class="sortremove flex items-center leading-none ml-1 text-gray-400 dark:text-gray-500 transition-all hover:text-red-700 dark:hover:text-red-500" href="{{ header.url_remove }}" title="{% translate "Remove from sorting" %}">
51
51
  <span class="block material-symbols-outlined">cancel</span>
52
52
  </a>
53
53
  </div>
@@ -33,12 +33,12 @@
33
33
  {% block content %}
34
34
  {% if perms_lacking %}
35
35
  <div class="border border-gray-200 rounded-md shadow-sm dark:border-gray-800">
36
- <p class="font-medium p-4 text-gray-700 text-sm dark:text-gray-200">
36
+ <p class="font-semibold p-4 text-gray-900 dark:text-gray-100">
37
37
  {% blocktranslate with escaped_object=object %}Deleting the {{ object_name }} '{{ escaped_object }}' would result in deleting related objects, but your account doesn't have permission to delete the following types of objects:{% endblocktranslate %}
38
38
  </p>
39
39
 
40
40
  <div class="border-gray-200 border-t p-4 dark:border-gray-800">
41
- <ul class="leading-relaxed text-gray-500 text-sm dark:text-gray-300">
41
+ <ul class="leading-relaxed">
42
42
  {% for obj in perms_lacking %}
43
43
  <li>
44
44
  {{ obj }}
@@ -49,12 +49,12 @@
49
49
  </div>
50
50
  {% elif protected %}
51
51
  <div class="border border-gray-200 rounded-md shadow-sm dark:border-gray-800">
52
- <p class="font-medium p-4 text-gray-700 text-sm dark:text-gray-200">
52
+ <p class="font-semibold p-4 text-gray-900 dark:text-gray-100">
53
53
  {% blocktranslate with escaped_object=object %}Deleting the {{ object_name }} '{{ escaped_object }}' would require deleting the following protected related objects:{% endblocktranslate %}
54
54
  </p>
55
55
 
56
56
  <div class="border-t border-gray-200 order-t p-4 dark:border-gray-800">
57
- <ul class="leading-relaxed text-gray-500 text-sm dark:text-gray-300">
57
+ <ul class="leading-relaxed">
58
58
  {% for obj in protected %}
59
59
  <li>
60
60
  {{ obj }}
@@ -65,18 +65,18 @@
65
65
  </div>
66
66
  {% else %}
67
67
  <div class="border border-gray-200 rounded-md shadow-sm dark:border-gray-800">
68
- <p class="font-medium p-4 text-gray-700 text-sm dark:text-gray-200">
68
+ <p class="font-semibold p-4 text-gray-900 dark:text-gray-100">
69
69
  {% blocktranslate with escaped_object=object %}Are you sure you want to delete the {{ object_name }} "{{ escaped_object }}"? All of the following related items will be deleted:{% endblocktranslate %}
70
70
  </p>
71
71
 
72
72
  {% include "admin/includes/object_delete_summary.html" %}
73
73
 
74
74
  <div class="border-gray-200 border-t p-4 dark:border-gray-800">
75
- <h2 class="font-medium mb-2 text-gray-700 text-sm dark:text-gray-200">
75
+ <h2 class="font-semibold mb-2 text-gray-900 dark:text-gray-100">
76
76
  {% translate "Objects" %}
77
77
  </h2>
78
78
 
79
- <ul class="leading-relaxed text-gray-500 text-sm dark:text-gray-300">
79
+ <ul class="leading-relaxed text-sm">
80
80
  {{ deleted_objects|unordered_list }}
81
81
  </ul>
82
82
  </div>
@@ -96,11 +96,11 @@
96
96
  {% endif %}
97
97
 
98
98
 
99
- <a href="#" class="border cancel-link font-medium hidden mb-3 px-3 py-2 rounded-md text-sm text-gray-500 transition-all w-full hover:bg-gray-50 lg:block lg:mb-0 lg:mr-3 lg:w-auto dark:border-gray-700 dark:text-gray-300 dark:hover:text-gray-200 dark:hover:bg-gray-900">
99
+ <a href="#" class="border cancel-link font-medium hidden mb-3 px-3 py-2 rounded-md w-full hover:bg-gray-50 lg:block lg:mb-0 lg:mr-3 lg:w-auto dark:border-gray-700 dark:text-gray-300 dark:hover:text-gray-200 dark:hover:bg-gray-900">
100
100
  {% translate "No, take me back" %}
101
101
  </a>
102
102
 
103
- <input type="submit" value="{% translate 'Yes, I’m sure' %}" class="bg-red-600 cursor-pointer font-medium ml-auto px-3 py-2 rounded-md text-sm text-white dark:bg-red-500/20 dark:text-red-500">
103
+ <input type="submit" value="{% translate 'Yes, I’m sure' %}" class="bg-red-600 cursor-pointer font-medium ml-auto px-3 py-2 rounded-md text-white dark:bg-red-500/20 dark:text-red-500">
104
104
  </div>
105
105
  </form>
106
106
  </div>
@@ -33,12 +33,12 @@
33
33
 
34
34
  {% block content %}
35
35
  {% if perms_lacking %}
36
- <p class="font-medium p-4 text-sm text-gray-700 dark:text-gray-200">
36
+ <p class="font-semibold p-4 text-gray-900 dark:text-gray-100">
37
37
  {% blocktranslate %}Deleting the selected {{ objects_name }} would result in deleting related objects, but your account doesn't have permission to delete the following types of objects:{% endblocktranslate %}
38
38
  </p>
39
39
 
40
40
  <div class="border-t border-gray-200 p-4 dark:border-gray-800">
41
- <ul class="leading-relaxed text-gray-500 text-sm dark:border-gray-800 dark:text-gray-300">
41
+ <ul class="leading-relaxed dark:border-gray-800">
42
42
  {% for obj in perms_lacking %}
43
43
  <li>{{ obj }}</li>
44
44
  {% endfor %}
@@ -46,12 +46,12 @@
46
46
  </div>
47
47
  {% elif protected %}
48
48
  <div class="border border-gray-200 rounded-md shadow-sm dark:border-gray-800">
49
- <p class="font-medium p-4 text-sm text-gray-700 dark:text-gray-200">
49
+ <p class="font-semibold p-4 text-gray-900 dark:text-gray-100">
50
50
  {% blocktranslate %}Deleting the selected {{ objects_name }} would require deleting the following protected related objects:{% endblocktranslate %}
51
51
  </p>
52
52
 
53
53
  <div class="border-t border-gray-200 p-4 dark:border-gray-800">
54
- <ul class="leading-relaxed text-gray-500 text-sm dark:text-gray-300">
54
+ <ul class="leading-relaxed">
55
55
  {% for obj in protected %}
56
56
  <li>{{ obj }}</li>
57
57
  {% endfor %}
@@ -60,19 +60,19 @@
60
60
  </div>
61
61
  {% else %}
62
62
  <div class="border border-gray-200 rounded-md shadow-sm dark:border-gray-800">
63
- <p class="font-medium p-4 text-sm text-gray-700 dark:text-gray-200">
63
+ <p class="font-semibold p-4 text-gray-900 dark:text-gray-100">
64
64
  {% blocktranslate %}Are you sure you want to delete the selected {{ objects_name }}? All of the following objects and their related items will be deleted:{% endblocktranslate %}
65
65
  </p>
66
66
 
67
67
  {% include "admin/includes/object_delete_summary.html" %}
68
68
 
69
69
  <div class="border-t border-gray-200 p-4 dark:border-gray-800">
70
- <h2 class="font-medium mb-2 text-gray-700 text-sm dark:text-gray-200">
70
+ <h2 class="font-semibold mb-2 text-gray-900 dark:text-gray-100">
71
71
  {% translate "Objects" %}
72
72
  </h2>
73
73
 
74
74
  {% for deletable_object in deletable_objects %}
75
- <ul class="leading-relaxed text-gray-500 text-sm dark:text-gray-300">
75
+ <ul class="leading-relaxed">
76
76
  {{ deletable_object|unordered_list }}
77
77
  </ul>
78
78
  {% endfor %}
@@ -89,11 +89,11 @@
89
89
  <input type="hidden" name="action" value="delete_selected">
90
90
  <input type="hidden" name="post" value="yes">
91
91
 
92
- <a href="#" class="border cancel-link font-medium hidden mb-3 px-3 py-2 rounded-md text-sm text-gray-500 transition-all w-full hover:bg-gray-50 lg:block lg:mb-0 lg:mr-3 lg:w-auto dark:border-gray-700 dark:text-gray-300 dark:hover:text-gray-200 dark:hover:bg-gray-900">
92
+ <a href="#" class="border cancel-link font-medium hidden mb-3 px-3 py-2 rounded-md transition-all w-full hover:bg-gray-50 lg:block lg:mb-0 lg:mr-3 lg:w-auto dark:border-gray-700 dark:text-gray-300 dark:hover:text-gray-200 dark:hover:bg-gray-900">
93
93
  {% translate "No, take me back" %}
94
94
  </a>
95
95
 
96
- <input type="submit" value="{% translate 'Yes, I’m sure' %}" class="bg-red-600 cursor-pointer font-medium ml-auto px-3 py-2 rounded-md text-sm text-white dark:bg-red-500/20 dark:text-red-500">
96
+ <input type="submit" value="{% translate 'Yes, I’m sure' %}" class="bg-red-600 cursor-pointer font-medium ml-auto px-3 py-2 rounded-md text-white dark:bg-red-500/20 dark:text-red-500">
97
97
  </div>
98
98
  </form>
99
99
  </div>
@@ -13,74 +13,80 @@
13
13
  {{ inline_admin_formset.formset.management_form }}
14
14
  {% include "unfold/helpers/messages/error.html" with errors=inline_admin_formset.formset.non_form_errors %}
15
15
 
16
- <div class="border border-gray-200 mb-6 overflow-hidden rounded-md shadow-sm text-gray-700 w-full dark:border-gray-800">
17
- {% for inline_admin_form in inline_admin_formset %}
18
- <div class="inline-related group inline-stacked {% if inline_admin_form.original or inline_admin_form.show_url %} has_original{% endif %}{% if forloop.last and inline_admin_formset.has_add_permission %} empty-form last-related{% endif %}" id="{{ inline_admin_formset.formset.prefix }}-{% if not forloop.last %}{{ forloop.counter0 }}{% else %}empty{% endif %}">
19
- {% if not inline_admin_formset.opts.hide_title or inline_admin_formset.formset.can_delete and inline_admin_formset.has_delete_permission %}
20
- <h3 class="bg-gray-50 border-b {% if not forloop.first %}border-t{% endif %} border-gray-200 flex font-medium items-center mb-3 px-3 py-2 text-gray-400 text-sm dark:bg-white/[.02] dark:border-gray-800">
21
- <span class="mr-2">
22
- {{ inline_admin_formset.opts.verbose_name|capfirst }}:
23
- </span>
24
-
25
- <span class="inline_label font-semibold text-gray-900 dark:text-gray-200">
26
- {% if inline_admin_form.original and inline_admin_form.model_admin.show_change_link and inline_admin_form.model_admin.has_registered_model %}
27
- <a href="{% url inline_admin_form.model_admin.opts|admin_urlname:'change' inline_admin_form.original.pk|admin_urlquote %}" class="{% if inline_admin_formset.has_change_permission %}inlinechangelink{% else %}inlineviewlink{% endif %} font-medium text-primary-600 underline">
28
- {{ inline_admin_form.original }}
29
- </a>
30
- {% else %}
31
- {% if inline_admin_form.original %}
32
- {% with inline_title=inline_admin_form.original.get_inline_title %}
33
- {% if inline_title %}
34
- {{ inline_title }}
35
- {% else %}
36
- {{ inline_admin_form.original }}
37
- {% endif %}
38
- {% endwith %}
16
+ {% if inline_admin_formset.forms|length == 0 %}
17
+ <p class="mb-6 text-sm">
18
+ {% trans "No records found." %}
19
+ </p>
20
+ {% else %}
21
+ <div class="border border-gray-200 mb-6 overflow-hidden rounded-md shadow-sm w-full dark:border-gray-800">
22
+ {% for inline_admin_form in inline_admin_formset %}
23
+ <div class="inline-related group inline-stacked {% if inline_admin_form.original or inline_admin_form.show_url %} has_original{% endif %}{% if forloop.last and inline_admin_formset.has_add_permission %} empty-form last-related{% endif %}" id="{{ inline_admin_formset.formset.prefix }}-{% if not forloop.last %}{{ forloop.counter0 }}{% else %}empty{% endif %}">
24
+ {% if not inline_admin_formset.opts.hide_title or inline_admin_formset.formset.can_delete and inline_admin_formset.has_delete_permission %}
25
+ <h3 class="bg-gray-50 border-b {% if not forloop.first %}border-t{% endif %} border-gray-200 flex font-medium items-center mb-3 px-3 py-2 text-sm dark:bg-white/[.02] dark:border-gray-800">
26
+ <span class="mr-2">
27
+ {{ inline_admin_formset.opts.verbose_name|capfirst }}:
28
+ </span>
39
29
 
40
- {% if inline_admin_form.model_admin.show_change_link and inline_admin_form.model_admin.has_registered_model %}
41
- <a href="{% url inline_admin_form.model_admin.opts|admin_urlname:'change' inline_admin_form.original.pk|admin_urlquote %}" class="{{ inline_admin_formset.has_change_permission|yesno:'inlinechangelink,inlineviewlink' }} font-medium ml-2 text-primary-600 underline dark:text-primary-500">
42
- {% if inline_admin_formset.has_change_permission %}
43
- {% translate "Change" %}
30
+ <span class="inline_label font-semibold text-gray-900 dark:text-gray-200">
31
+ {% if inline_admin_form.original and inline_admin_form.model_admin.show_change_link and inline_admin_form.model_admin.has_registered_model %}
32
+ <a href="{% url inline_admin_form.model_admin.opts|admin_urlname:'change' inline_admin_form.original.pk|admin_urlquote %}" class="{% if inline_admin_formset.has_change_permission %}inlinechangelink{% else %}inlineviewlink{% endif %} font-medium text-primary-600 dark:text-primary-500">
33
+ {{ inline_admin_form.original }}
34
+ </a>
35
+ {% else %}
36
+ {% if inline_admin_form.original %}
37
+ {% with inline_title=inline_admin_form.original.get_inline_title %}
38
+ {% if inline_title %}
39
+ {{ inline_title }}
44
40
  {% else %}
45
- {% translate "View" %}
41
+ {{ inline_admin_form.original }}
46
42
  {% endif %}
47
- </a>
43
+ {% endwith %}
44
+
45
+ {% if inline_admin_form.model_admin.show_change_link and inline_admin_form.model_admin.has_registered_model %}
46
+ <a href="{% url inline_admin_form.model_admin.opts|admin_urlname:'change' inline_admin_form.original.pk|admin_urlquote %}" class="{{ inline_admin_formset.has_change_permission|yesno:'inlinechangelink,inlineviewlink' }} font-medium ml-2 text-primary-600 dark:text-primary-500">
47
+ {% if inline_admin_formset.has_change_permission %}
48
+ {% translate "Change" %}
49
+ {% else %}
50
+ {% translate "View" %}
51
+ {% endif %}
52
+ </a>
53
+ {% endif %}
54
+ {% else %}
55
+ #{{ forloop.counter }}
48
56
  {% endif %}
49
- {% else %}
50
- #{{ forloop.counter }}
51
57
  {% endif %}
52
- {% endif %}
53
- </span>
58
+ </span>
54
59
 
55
- {% if inline_admin_form.show_url %}
56
- <a href="{{ inline_admin_form.absolute_url }}" class="font-medium ml-2 text-primary-600 underline dark:text-primary-500">
57
- {% trans "View on site" %}
58
- </a>
59
- {% endif %}
60
+ {% if inline_admin_form.show_url %}
61
+ <a href="{{ inline_admin_form.absolute_url }}" class="font-medium ml-2 text-primary-600 dark:text-primary-500">
62
+ {% trans "View on site" %}
63
+ </a>
64
+ {% endif %}
60
65
 
61
- {% if inline_admin_formset.formset.can_delete and inline_admin_formset.has_delete_permission and inline_admin_form.original %}
62
- <span class="delete flex gap-2 items-center ml-auto text-gray-500">
63
- {{ inline_admin_form.deletion_field.field|add_css_class:form_classes.checkbox }} {{ inline_admin_form.deletion_field.label_tag }}
64
- </span>
65
- {% endif %}
66
- </h3>
67
- {% endif %}
66
+ {% if inline_admin_formset.formset.can_delete and inline_admin_formset.has_delete_permission and inline_admin_form.original %}
67
+ <span class="delete flex gap-2 items-center ml-auto">
68
+ {{ inline_admin_form.deletion_field.field|add_css_class:form_classes.checkbox }} {{ inline_admin_form.deletion_field.label_tag }}
69
+ </span>
70
+ {% endif %}
71
+ </h3>
72
+ {% endif %}
68
73
 
69
- {% include "unfold/helpers/messages/error.html" with errors=inline_admin_form.form.non_field_errors %}
74
+ {% include "unfold/helpers/messages/error.html" with errors=inline_admin_form.form.non_field_errors %}
70
75
 
71
- {% for fieldset in inline_admin_form %}
72
- <div class="px-3 -mb-5 {% if inline_admin_formset.opts.hide_title %}{% if not inline_admin_formset.formset.can_delete or not inline_admin_formset.has_delete_permission %}pt-3{% endif %}{% endif %}">
73
- {% include 'admin/includes/fieldset.html' with stacked=1 %}
74
- </div>
75
- {% endfor %}
76
+ {% for fieldset in inline_admin_form %}
77
+ <div class="px-3 -mb-5 {% if inline_admin_formset.opts.hide_title %}{% if not inline_admin_formset.formset.can_delete or not inline_admin_formset.has_delete_permission %}pt-3{% endif %}{% endif %}">
78
+ {% include 'admin/includes/fieldset.html' with stacked=1 %}
79
+ </div>
80
+ {% endfor %}
76
81
 
77
- {% if inline_admin_form.needs_explicit_pk_field %}
78
- {{ inline_admin_form.pk_field.field }}
79
- {% endif %}
82
+ {% if inline_admin_form.needs_explicit_pk_field %}
83
+ {{ inline_admin_form.pk_field.field }}
84
+ {% endif %}
80
85
 
81
- {% if inline_admin_form.fk_field %}{{ inline_admin_form.fk_field.field }}{% endif %}
82
- </div>
83
- {% endfor %}
84
- </div>
86
+ {% if inline_admin_form.fk_field %}{{ inline_admin_form.fk_field.field }}{% endif %}
87
+ </div>
88
+ {% endfor %}
89
+ </div>
90
+ {% endif %}
85
91
  </fieldset>
86
92
  </div>
@@ -17,22 +17,22 @@
17
17
 
18
18
  <div>
19
19
  {% if not inline_admin_formset.has_add_permission and inline_admin_formset.forms|length == 0 %}
20
- <p class="mb-6 text-gray-500 text-sm dark:text-gray-300">
20
+ <p class="mb-6">
21
21
  {% trans "No records found." %}
22
22
  </p>
23
23
  {% else %}
24
24
  <div class="border border-gray-200 mb-6 overflow-x-auto rounded-md shadow-sm dark:border-gray-800" data-simplebar data-simplebar-auto-hide="false">
25
- <table class="border-spacing-none border-separate text-gray-700 w-full">
25
+ <table class="border-spacing-none border-separate w-full">
26
26
  <thead class="hidden lg:table-header-group">
27
27
  <tr>
28
28
  {% for field in inline_admin_formset.fields %}
29
29
  {% if not field.widget.is_hidden %}
30
- <th class="column-{{ field.name }}{% if field.required %} required{% endif %} align-middle border-b border-gray-200 font-medium px-3 py-2 text-left text-gray-400 text-sm whitespace-nowrap dark:border-gray-800">
30
+ <th class="column-{{ field.name }}{% if field.required %} required{% endif %} align-middle border-b border-gray-200 font-medium px-3 py-2 text-left text-gray-900 text-sm whitespace-nowrap dark:text-gray-200 dark:border-gray-800">
31
31
  <span class="flex flex-row items-center">
32
32
  {{ field.label|capfirst }}
33
33
 
34
34
  {% if field.help_text %}
35
- <span class="cursor-pointer material-symbols-outlined ml-2" title="{{ field.help_text|striptags }}">help</span>
35
+ <span class="cursor-pointer material-symbols-outlined ml-2 text-gray-400 dark:text-gray-500" title="{{ field.help_text|striptags }}">help</span>
36
36
  {% endif %}
37
37
  </span>
38
38
  </th>
@@ -40,7 +40,7 @@
40
40
  {% endfor %}
41
41
 
42
42
  {% if inline_admin_formset.formset.can_delete and inline_admin_formset.has_delete_permission %}
43
- <th class="align-middle border-b border-gray-200 font-medium px-3 py-2 text-left text-gray-400 text-sm whitespace-nowrap lg:w-px dark:border-gray-800">
43
+ <th class="align-middle border-b border-gray-200 font-medium px-3 py-2 text-left text-gray-900 text-sm whitespace-nowrap lg:w-px dark:border-gray-800 dark:text-gray-200">
44
44
  {% translate "Delete?" %}
45
45
  </th>
46
46
  {% endif %}
@@ -59,12 +59,12 @@
59
59
 
60
60
  {% if inline_admin_form.original or inline_admin_form.show_url %}
61
61
  <tr>
62
- <td class="original {% if not inline_admin_formset.opts.hide_title %}{% if inline_admin_form.original or inline_admin_form.show_url %}border-b border-gray-200 dark:border-gray-800 bg-gray-50 dark:bg-white/[.02]{% endif %}{% endif %}" colspan="{{ inline_admin_form|cell_count }}">
62
+ <td class="original" colspan="{{ inline_admin_form|cell_count }}">
63
63
  {% if not inline_admin_formset.opts.hide_title %}
64
64
  {% if inline_admin_form.original or inline_admin_form.show_url %}
65
- <p class="bg-gray-50 flex font-medium items-center px-3 py-2 text-gray-400 text-sm dark:bg-white/[.02] ">
65
+ <p class="flex font-medium items-center px-3 pt-2 text-xs">
66
66
  {% if inline_admin_form.original %}
67
- <span class="font-semibold text-gray-900 dark:text-gray-200">
67
+ <span>
68
68
  {% with inline_title=inline_admin_form.original.get_inline_title %}
69
69
  {% if inline_title %}
70
70
  {{ inline_title }}
@@ -75,7 +75,7 @@
75
75
  </span>
76
76
 
77
77
  {% if inline_admin_form.model_admin.show_change_link and inline_admin_form.model_admin.has_registered_model %}
78
- <a href="{% url inline_admin_form.model_admin.opts|admin_urlname:'change' inline_admin_form.original.pk|admin_urlquote %}" class="{{ inline_admin_formset.has_change_permission|yesno:'inlinechangelink,inlineviewlink' }} font-medium ml-2 text-primary-600 underline dark:text-primary-500">
78
+ <a href="{% url inline_admin_form.model_admin.opts|admin_urlname:'change' inline_admin_form.original.pk|admin_urlquote %}" class="{{ inline_admin_formset.has_change_permission|yesno:'inlinechangelink,inlineviewlink' }} ml-2 text-primary-600 dark:text-primary-500">
79
79
  {% if inline_admin_formset.has_change_permission %}
80
80
  {% translate "Change" %}
81
81
  {% else %}
@@ -86,7 +86,7 @@
86
86
  {% endif %}
87
87
 
88
88
  {% if inline_admin_form.show_url %}
89
- <a href="{{ inline_admin_form.absolute_url }}" class="font-medium ml-2 text-primary-600 underline dark:text-primary-500">
89
+ <a href="{{ inline_admin_form.absolute_url }}" class="font-medium ml-2 text-primary-600 dark:text-primary-500">
90
90
  {% translate "View on site" %}
91
91
  </a>
92
92
  {% endif %}
@@ -146,7 +146,7 @@
146
146
  {% endfor %}
147
147
 
148
148
  {% if inline_admin_formset.formset.can_delete and inline_admin_formset.has_delete_permission %}
149
- <td class="delete {% if inline_admin_form.original %}p-3 lg:py-3{% else %}py-3{% endif %} text-left text-red-600 border-b border-gray-200 flex items-center before:capitalize before:content-[attr(data-label)] before:mr-auto before:text-gray-500 before:pr-4 lg:before:hidden font-normal px-3 text-sm lg:align-top lg:table-cell lg:underline lg:w-px dark:border-gray-800" data-label="{% trans "Remove" %}">
149
+ <td class="delete {% if inline_admin_form.original %}p-3 lg:py-3{% else %}py-3{% endif %} text-left text-red-600 border-b border-gray-200 flex items-center before:capitalize before:content-[attr(data-label)] before:mr-auto before:text-gray-500 before:pr-4 lg:before:hidden font-normal px-3 text-sm lg:align-top lg:table-cell lg:w-px dark:border-gray-800" data-label="{% trans "Remove" %}">
150
150
  {% if inline_admin_form.original %}
151
151
  <div class="flex flex-row lg:mt-3">
152
152
  <div class="ml-auto">
@@ -1,7 +1,7 @@
1
1
  {% load i18n unfold %}
2
2
 
3
3
  <div class="mb-6">
4
- <h3 class="font-medium mb-2 text-gray-700 text-sm dark:text-gray-200">
4
+ <h3 class="font-semibold mb-2 text-gray-900 dark:text-gray-100">
5
5
  {% blocktranslate with filter_title=title %} By {{ filter_title }} {% endblocktranslate %}
6
6
  </h3>
7
7
 
@@ -12,9 +12,9 @@
12
12
  {% endfor %}
13
13
 
14
14
  {% if spec|class_name == "BooleanFieldListFilter" %}
15
- <ul class="border-l-4 border-gray-200 flex pl-4 py-2 text-gray-500 text-sm dark:border-gray-700">
15
+ <ul class="border-l-4 border-gray-200 flex pl-4 py-2 dark:border-gray-700">
16
16
  {% for choice in choices %}
17
- <li class="{% if choice.selected %}font-medium text-primary-600 dark:text-primary-500 underline dark{% else %}text-gray-500 hover:text-gray-700 dark:text-gray-300 dark:hover:text-gray-200{% endif %} pr-4">
17
+ <li class="{% if choice.selected %}font-medium text-primary-600 dark:text-primary-500 dark{% else %}hover:text-gray-700 dark:hover:text-gray-200{% endif %} pr-4">
18
18
  <a href="{{ choice.query_string|iriencode }}" title="{{ choice.display }}">
19
19
  {{ choice.display }}
20
20
  </a>
@@ -22,9 +22,9 @@
22
22
  {% endfor %}
23
23
  </ul>
24
24
  {% else %}
25
- <ul class="border-l-4 border-gray-200 flex flex-col pl-4 py-4 text-gray-500 text-sm dark:border-gray-700">
25
+ <ul class="border-l-4 border-gray-200 flex flex-col pl-4 py-4 dark:border-gray-700">
26
26
  {% for choice in choices %}
27
- <li class="mb-4 last:mb-0 {% if choice.selected %}font-medium text-primary-600 dark:text-primary-500 underline {% else %}text-gray-500 hover:text-gray-700 dark:text-gray-300 dark:hover:text-gray-200{% endif %}">
27
+ <li class="mb-4 last:mb-0 {% if choice.selected %}font-medium text-primary-600 dark:text-primary-500 {% else %}hover:text-gray-700 dark:hover:text-gray-200{% endif %}">
28
28
  <a href="{{ choice.query_string|iriencode }}" title="{{ choice.display }}">
29
29
  {{ choice.display }}
30
30
  </a>
@@ -1,11 +1,11 @@
1
1
  {% load i18n %}
2
2
 
3
3
  <div class="border-gray-200 border-t p-4 dark:border-gray-800">
4
- <h2 class="font-medium mb-2 text-gray-700 text-sm dark:text-gray-200">
4
+ <h2 class="font-semibold mb-2 text-gray-900 dark:text-gray-100">
5
5
  {% translate "Summary" %}
6
6
  </h2>
7
7
 
8
- <ul class="leading-relaxed text-gray-500 text-sm dark:text-gray-300">
8
+ <ul class="leading-relaxed">
9
9
  {% for model_name, object_count in model_count %}
10
10
  <li>
11
11
  {{ model_name|capfirst }}: {{ object_count }}
@@ -27,18 +27,18 @@
27
27
 
28
28
  {% block content %}
29
29
  {% if action_list %}
30
- <table class="border-gray-200 border-spacing-none border-separate mb-6 text-gray-700 w-full dark:text-gray-300 lg:border lg:rounded-md lg:shadow-sm lg:dark:border-gray-800">
31
- <thead class="hidden lg:table-header-group">
30
+ <table class="border-gray-200 border-spacing-none border-separate mb-6 w-full lg:border lg:rounded-md lg:shadow-sm lg:dark:border-gray-800">
31
+ <thead class="hidden lg:table-header-group text-gray-900 dark:text-gray-100">
32
32
  <tr>
33
- <th class="align-middle font-medium px-3 py-2 text-left text-gray-400 text-sm">
33
+ <th class="align-middle font-medium px-3 py-2 text-left">
34
34
  {% translate 'Date/time' %}
35
35
  </th>
36
36
 
37
- <th class="align-middle font-medium px-3 py-2 text-left text-gray-400 text-sm">
37
+ <th class="align-middle font-medium px-3 py-2 text-left">
38
38
  {% translate 'User' %}
39
39
  </th>
40
40
 
41
- <th class="align-middle font-medium px-3 py-2 text-left text-gray-400 text-sm">
41
+ <th class="align-middle font-medium px-3 py-2 text-left">
42
42
  {% translate 'Action' %}
43
43
  </th>
44
44
  </tr>
@@ -47,15 +47,15 @@
47
47
  <tbody>
48
48
  {% for action in action_list %}
49
49
  <tr class="block border mb-3 rounded-md shadow-sm lg:table-row lg:border-none lg:mb-0 lg:shadow-none dark:border-gray-800">
50
- <th class="align-middle flex border-t border-gray-200 font-normal px-3 py-2 text-left text-sm before:flex before:capitalize before:content-[attr(data-label)] before:items-center before:mr-auto before:text-gray-500 first:border-t-0 dark:before:text-gray-300 lg:before:hidden lg:first:border-t lg:py-3 lg:table-cell dark:border-gray-800" data-label="{% translate 'Date/time' %}">
50
+ <th class="align-middle flex border-t border-gray-200 font-normal px-3 py-2 text-left before:flex before:capitalize before:content-[attr(data-label)] before:items-center before:mr-auto first:border-t-0lg:before:hidden lg:first:border-t lg:py-3 lg:table-cell dark:border-gray-800" data-label="{% translate 'Date/time' %}">
51
51
  {{ action.action_time|date:"DATETIME_FORMAT" }}
52
52
  </th>
53
53
 
54
- <td class="align-middle flex border-t border-gray-200 font-normal px-3 py-2 text-left text-sm before:flex before:capitalize before:content-[attr(data-label)] before:items-center before:mr-auto before:text-gray-500 first:border-t-0 dark:before:text-gray-300 lg:before:hidden lg:first:border-t lg:py-3 lg:table-cell dark:border-gray-800" data-label="{% translate 'User' %}">
54
+ <td class="align-middle flex border-t border-gray-200 font-normal px-3 py-2 text-left before:flex before:capitalize before:content-[attr(data-label)] before:items-center before:mr-auto first:border-t-0lg:before:hidden lg:first:border-t lg:py-3 lg:table-cell dark:border-gray-800" data-label="{% translate 'User' %}">
55
55
  {{ action.user.get_username }}{% if action.user.get_full_name %} ({{ action.user.get_full_name }}){% endif %}
56
56
  </td>
57
57
 
58
- <td class="align-middle flex border-t border-gray-200 font-normal px-3 py-2 text-left text-sm before:flex before:capitalize before:content-[attr(data-label)] before:items-center before:mr-auto before:text-gray-500 first:border-t-0 dark:before:text-gray-300 lg:before:hidden lg:first:border-t lg:py-3 lg:table-cell dark:border-gray-800" data-label="{% translate 'Action' %}">
58
+ <td class="align-middle flex border-t border-gray-200 font-normal px-3 py-2 text-left before:flex before:capitalize before:content-[attr(data-label)] before:items-center before:mr-auto first:border-t-0lg:before:hidden lg:first:border-t lg:py-3 lg:table-cell dark:border-gray-800" data-label="{% translate 'Action' %}">
59
59
  {{ action.get_change_message }}
60
60
  </td>
61
61
  </tr>
@@ -63,7 +63,7 @@
63
63
  </tbody>
64
64
  </table>
65
65
 
66
- <div class="bg-gray-50 flex my-4 items-center p-3 rounded-md text-gray-400 text-sm dark:bg-gray-800">
66
+ <div class="bg-gray-50 flex my-4 items-center p-3 rounded-md dark:bg-gray-800">
67
67
  {% if pagination_required %}
68
68
  {% for i in page_range %}
69
69
  <span class="pr-4">
@@ -1,6 +1,6 @@
1
1
  {% load unfold_list i18n %}
2
2
 
3
- <div class="bg-gray-50 flex my-4 items-center p-3 rounded-md text-sm text-gray-700 dark:bg-gray-800 dark:text-gray-300">
3
+ <div class="bg-gray-50 flex my-4 items-center p-3 rounded-md text-sm dark:bg-gray-800">
4
4
  {% if pagination_required %}
5
5
  {% for i in page_range %}
6
6
  <div class="{% if forloop.last %}pr-2{% else %}pr-4{% endif %}">
@@ -9,7 +9,7 @@
9
9
  {% endfor %}
10
10
  {% endif %}
11
11
 
12
- <div class="text-gray-400">
12
+ <div>
13
13
  {% if pagination_required %}
14
14
  -
15
15
  {% endif %}
@@ -24,7 +24,7 @@
24
24
  </div>
25
25
 
26
26
  {% if show_all_url %}
27
- <a href="{{ show_all_url }}" class="showall ml-4 text-primary-600 underline">
27
+ <a href="{{ show_all_url }}" class="showall ml-4 text-primary-600 dark:text-primary-500">
28
28
  {% translate 'Show all' %}
29
29
  </a>
30
30
  {% endif %}