Skip to content

Commit 210d610

Browse files
authored
Merge branch 'master' into help_pages_add_improve_german_translations
2 parents 02fb272 + 2cb7675 commit 210d610

File tree

55 files changed

+1211
-308
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

55 files changed

+1211
-308
lines changed

CHANGES.rst

Lines changed: 89 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,102 @@
22
Copyright (C) 2019-2025 CERN.
33
Copyright (C) 2019-2024 Northwestern University.
44
Copyright (C) 2021-2024 TU Wien.
5-
Copyright (C) 2021-2025 Graz University of Technology.
5+
Copyright (C) 2021-2026 Graz University of Technology.
66
77
Invenio App RDM is free software; you can redistribute it and/or modify
88
it under the terms of the MIT License; see LICENSE file for more details.
99

1010
Changes
1111
=======
1212

13+
Version v14.0.0b5.dev0 (released 2026-02-03)
14+
15+
- fix(chore): DeprecationWarning stdlib
16+
- chore(setup): bump dependencies
17+
- fix: manage record link functionality for all versions
18+
- feat(css): styles for deep-linked request comment replies
19+
- style: collapsible messages style
20+
- Fix regex search example URL
21+
- Fix regex search example
22+
- search guide: fix regex example in swedish translation
23+
- search guide: fix regex example
24+
25+
Version v14.0.0b4.dev6 released 2026-01-22)
26+
27+
- fix(ExportDropdown): Fix css spacing and responsiveness
28+
29+
Version v14.0.0b4.dev5 (released 2026-01-21)
30+
31+
- feat(CopyButton): Pass remaining props to customize UI & functionality
32+
- refactor(RecordVersionsList): Make version items overridable
33+
34+
Version v14.0.0b4.dev4 (released 2026-01-15)
35+
36+
- refactor(ui): support custom file display name resolver
37+
- fix: use UUID type for request identifiers
38+
- feat(comment-replies): add single threading on comments
39+
- fix(moderation.requests): handle empty payload key not in request
40+
- feat(previewer): show message for outdated records
41+
42+
Version v14.0.0b4.dev3 (released 2025-12-18)
43+
44+
- fix(feed): styling for disabled reply input
45+
46+
Version v14.0.0b4.dev2 (released 2025-12-16)
47+
48+
- semantic-ui: feed.overrides: Add placeholder css
49+
- fix: css padding for preview msg
50+
51+
Version v14.0.0b4.dev1 (released 2025-12-13)
52+
53+
- feat(css): styles for threaded replies
54+
- feat(views-request): include `can_reply_comment` in template permissions dict
55+
56+
Version v14.0.0b4.dev0 (released 2025-12-12)
57+
58+
- chore(setup): bump major versions
59+
- feat: add empty Overridable container before and after the files accordion
60+
- assets: added css for hidden comment line and last page first comment
61+
62+
Version v14.0.0b3.dev4 (released 2025-12-08)
63+
64+
- fix: ensure that pages render if accessed via secret link
65+
- UI: change button icon and text
66+
- chore: drill recordRequests into the modal
67+
- fix: restrict to only community sub/inc reqs
68+
- frontend: add direct link to request if user has access
69+
- feat(css): styles for quote replies
70+
- fix(requests_ui): Inject lock_request and create_comment permissions
71+
- fix: correct types
72+
73+
Version v14.0.0b3.dev3 (released 2025-11-21)
74+
75+
- feat(css): request comment deep links
76+
77+
Version v14.0.0b3.dev2 (released 2025-11-21)
78+
79+
- fix: revert mapping.js symlink
80+
81+
Version v14.0.0b3.dev1 (released 2025-11-21)
82+
83+
- UI: add info message about remaining days to publish changes
84+
- request: add file mod request template
85+
- fix: set files_locked to `bucket.locked` rather than permission
86+
* currently the permission is whether you can unlock the files
87+
* but the files are only unlocked when you create the draft
88+
* as such as an admin when you edit a published draft, if it was
89+
created by a user it will look like the files are unlocked but
90+
this is false
91+
- feat: pass file modification eval to deposit form
92+
- fix: align selector with semantic-ui
93+
- fix(views): pass API record to evaluate record deletion
94+
- fix(record-ui): do not sanitize additional description in template
95+
- admin: requests details view improvements
96+
- Replace `Record deletion` by `Deletion request for "Record name"`
97+
- Link showing all requests for a given user
98+
- tombstone: add deletion policy
99+
- Update release date for version v14.0.0b3.dev0
100+
13101
Version v14.0.0b3.dev0 (released 2025-11-12)
14102

15103
- setup: bump major version of `invenio-oauthclient`

invenio_app_rdm/__init__.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#
33
# Copyright (C) 2019-2025 CERN.
44
# Copyright (C) 2019-2022 Northwestern University.
5-
# Copyright (C) 2024-2025 Graz University of Technology.
5+
# Copyright (C) 2024-2026 Graz University of Technology.
66
#
77
# Invenio App RDM is free software; you can redistribute it and/or modify it
88
# under the terms of the MIT License; see LICENSE file for more details.
@@ -17,6 +17,6 @@
1717
#
1818
# See PEP 0440 for details - https://www.python.org/dev/peps/pep-0440
1919

20-
__version__ = "14.0.0b3.dev0"
20+
__version__ = "14.0.0b5.dev0"
2121

2222
__all__ = ("__version__",)

invenio_app_rdm/administration/audit_logs/audit_logs.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
# under the terms of the MIT License; see LICENSE file for more details.
77

88
"""Invenio administration view module for audit logs."""
9+
910
from flask import current_app
1011
from invenio_administration.views.base import AdminResourceListView
1112
from invenio_i18n import lazy_gettext as _

invenio_app_rdm/administration/moderation/requests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ def get_context(self, pid_value=None):
138138
g.identity, current_user
139139
)["avatar"]
140140
permissions = []
141-
if "reason" in request["payload"]:
141+
if "reason" in request.get("payload", {}):
142142
reason_title = vocabulary_service.read(
143143
g.identity,
144144
("removalreasons", request["payload"]["reason"]),

invenio_app_rdm/administration/templates/semantic-ui/invenio_app_rdm/administration/requests_details.html

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,14 @@
2929
)
3030
}}
3131

32-
<div class="twelve wide column mt-10">
33-
<p><strong>{{ _("Reason:") }}</strong> {{ invenio_request["payload"]["reason_label"] }}</p>
34-
{%- if invenio_request["payload"]["comment"] %}
35-
<p><strong>{{ _("Justification:") }}</strong> {{ invenio_request["payload"]["comment"] }}</p>
36-
{%- endif %}
37-
</div>
32+
{%- if "payload" in invenio_request %}
33+
<div class="twelve wide column mt-10">
34+
<p><strong>{{ _("Reason:") }}</strong> {{ invenio_request["payload"]["reason_label"] }}</p>
35+
{%- if invenio_request["payload"]["comment"] %}
36+
<p><strong>{{ _("Justification:") }}</strong> {{ invenio_request["payload"]["comment"] }}</p>
37+
{%- endif %}
38+
</div>
39+
{%- endif %}
3840

3941
<div class="ui divider"></div>
4042
{%- endblock request_header %}

invenio_app_rdm/config.py

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
# Copyright (C) 2019-2025 CERN.
44
# Copyright (C) 2019-2020 Northwestern University.
55
# Copyright (C) 2021-2025 Graz University of Technology.
6-
# Copyright (C) 2022-2024 KTH Royal Institute of Technology.
6+
# Copyright (C) 2022-2025 KTH Royal Institute of Technology.
77
# Copyright (C) 2023 TU Wien
88
#
99
# Invenio App RDM is free software; you can redistribute it and/or modify it
@@ -87,6 +87,7 @@
8787
from invenio_records_resources.references.entity_resolvers import ServiceResultResolver
8888
from invenio_requests.notifications.builders import (
8989
CommentRequestEventCreateNotificationBuilder,
90+
CommentRequestEventReplyNotificationBuilder,
9091
)
9192
from invenio_requests.resources.requests.config import request_error_handlers
9293
from invenio_requests.services.requests import facets
@@ -1074,9 +1075,9 @@ def github_link_render(record):
10741075
# ===================
10751076

10761077
RDM_REQUESTS_ROUTES = {
1077-
"user-dashboard-request-details": "/me/requests/<request_pid_value>",
1078-
"community-dashboard-request-details": "/communities/<pid_value>/requests/<request_pid_value>",
1079-
"community-dashboard-invitation-details": "/communities/<pid_value>/invitations/<request_pid_value>",
1078+
"user-dashboard-request-details": "/me/requests/<uuid:request_pid_value>",
1079+
"community-dashboard-request-details": "/communities/<pid_value>/requests/<uuid:request_pid_value>",
1080+
"community-dashboard-invitation-details": "/communities/<pid_value>/invitations/<uuid:request_pid_value>",
10801081
}
10811082

10821083
RDM_COMMUNITIES_ROUTES = {
@@ -1172,6 +1173,9 @@ def github_link_render(record):
11721173
]
11731174
"""Preferred previewers."""
11741175

1176+
PREVIEWER_ABSTRACT_TEMPLATE = "invenio_previewer/rdm_abstract_previewer.html"
1177+
"""Override the abstract template with an RDM-specific one."""
1178+
11751179
RECORDS_RESOURCES_IMAGE_FORMATS = ["." + ext for ext in IIIF_FORMATS.keys()]
11761180
"""RECORDS_RESOURCES_IMAGE_FORMATS must contain all possible IIIF formats to ensure their metadata is extracted."""
11771181

@@ -1404,6 +1408,7 @@ def github_link_render(record):
14041408
GrantUserAccessNotificationBuilder.type: GrantUserAccessNotificationBuilder,
14051409
# Comment request event
14061410
CommentRequestEventCreateNotificationBuilder.type: CommentRequestEventCreateNotificationBuilder,
1411+
CommentRequestEventReplyNotificationBuilder.type: CommentRequestEventReplyNotificationBuilder,
14071412
community_notifications.SubComReqCommentNotificationBuilder.type: community_notifications.SubComReqCommentNotificationBuilder,
14081413
community_notifications.SubComInvCommentNotificationBuilder.type: community_notifications.SubComInvCommentNotificationBuilder,
14091414
# Community inclusion

invenio_app_rdm/records_ui/templates/semantic-ui/invenio_app_rdm/records/deposit.html

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,9 @@
5151
{% if record_deletion %}
5252
<input type="hidden" name="deposits-record-deletion" value='{{ record_deletion | tojson }}'>
5353
{% endif %}
54+
{% if file_modification %}
55+
<input type="hidden" name="deposits-file-modification" value='{{ file_modification | tojson }}'>
56+
{% endif %}
5457
<input type="hidden" name="config-groups-enabled"
5558
value='{{ config.USERS_RESOURCES_GROUPS_ENABLED | tojson }}'>
5659
<input type="hidden" name="records-resources-allow-empty-files"

invenio_app_rdm/records_ui/templates/semantic-ui/invenio_app_rdm/records/detail.html

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
Copyright (C) 2021-2023 TU Wien.
55
Copyright (C) 2021 Graz University of Technology.
66
Copyright (C) 2021 New York University.
7-
Copyright (C) 2024 KTH Royal Institute of Technology.
7+
Copyright (C) 2024-2025 KTH Royal Institute of Technology.
88

99
Invenio RDM Records is free software; you can redistribute it and/or modify
1010
it under the terms of the MIT License; see LICENSE file for more details.
@@ -26,6 +26,9 @@
2626
{%- set title = record_ui["metadata"]["title"] %}
2727
{%- set metadata = record_ui["metadata"] %}
2828

29+
<!-- Shared namespace for files to allow overridability on child blocks while maintaining reference to parent values -->
30+
{% set files_ns = namespace(preview_file=None, files=[]) %}
31+
2932
{%- set can_curate_record = permissions is defined and (permissions.can_edit or permissions.can_review) %}
3033

3134
<!-- preview_submission_request is set to true when coming from a community submission request -->
@@ -107,7 +110,7 @@
107110

108111
<!-- PREVIEW HEADER -->
109112
{% if is_preview %}
110-
<div class="ui info flashed bottom attached manage message">
113+
<div class="ui info bottom attached manage message">
111114
<div class="ui container">
112115
<div class="header">
113116
<i class="eye icon"></i>
@@ -288,14 +291,19 @@
288291
aria-label="{{ _('Files') }}">
289292
{%- if permissions.can_read_files -%}
290293
{# record has files AND user can see files #}
291-
{%- set files = files | order_entries | selectattr("status", "==", "completed") | list %}
292-
{%- if files|length > 0 -%}
294+
{# Shared namespace for files (outside blocks) #}
295+
{%- set files_ns.files = files | order_entries | selectattr("status", "==", "completed") | list %}
296+
{%- if files_ns.files|length > 0 -%}
293297
<h2 id="files-heading">{{ _('Files') }}</h2>
294-
{%- if files|has_previewable_files -%}
295-
{%-set preview_file = files|select_preview_file(default_preview=record_ui["files"]["default_preview"]) %}
296-
{{ preview_file_box(preview_file, record_ui["id"], is_preview, record, include_deleted) }}
298+
{%- if files_ns.files|has_previewable_files -%}
299+
{%-set files_ns.preview_file = files_ns.files|select_preview_file(default_preview=record_ui["files"]["default_preview"]) %}
300+
{%- block record_file_preview -%}
301+
{{ preview_file_box(files_ns.preview_file, record_ui["id"], is_preview, record, include_deleted) }}
302+
{%- endblock record_file_preview -%}
297303
{%- endif -%}
298-
{{ file_list_box(files, record_ui["id"], is_preview, include_deleted, record, permissions) }}
304+
{%- block record_file_list -%}
305+
{{ file_list_box(files_ns.files, record_ui["id"], is_preview, include_deleted, record, permissions) }}
306+
{%- endblock record_file_list -%}
299307
{% endif %}
300308
{% else %}
301309
{# record has files BUT user does not have permission to see files #}

invenio_app_rdm/records_ui/templates/semantic-ui/invenio_app_rdm/records/details/side_bar/communities.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
data-pending-communities-search-config='{{ search_app_rdm_record_requests_config(app_id="InvenioAppRdm.RecordRequests", endpoint=record_ui["links"]["requests"]) | tojson }}'
1010
data-permissions='{{ permissions | tojson }}'
1111
data-record='{{ record_ui | tojson }}'
12+
data-record-requests='{{ record_requests | default({}) | tojson }}'
1213
class='sidebar-container'
1314
>
1415

invenio_app_rdm/records_ui/templates/semantic-ui/invenio_app_rdm/records/macros/files.html

Lines changed: 20 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,13 @@
3131
{%- endmacro %}
3232

3333

34-
{% macro preview_file_box(file, pid, is_preview, record, include_deleted) %}
34+
{% macro preview_file_box(file, pid, is_preview, record, include_deleted, display_name=None) %}
3535
{%- set is_remote_file = file.transfer.type == transfer_types.REMOTE %}
36+
{%- if display_name %}
37+
{%- set human_readable_file_name = display_name(file) or file.key %}
38+
{%- else %}
39+
{%- set human_readable_file_name = file.key %}
40+
{%- endif %}
3641
<div class="ui accordion panel mb-10 {{record.ui.access_status.id}}" href="#files-preview-accordion-panel">
3742
<h3 class="active title panel-heading {{ record.ui.access_status.id }} m-0">
3843
<div
@@ -44,7 +49,7 @@ <h3 class="active title panel-heading {{ record.ui.access_status.id }} m-0">
4449
class="trigger"
4550
aria-label="{{ _('File preview') }}"
4651
>
47-
<span id="preview-file-title">{{ file.key }}</span>
52+
<span id="preview-file-title">{{ human_readable_file_name }}</span>
4853
<i class="angle right icon" aria-hidden="true"></i>
4954
</div>
5055
</h3>
@@ -82,9 +87,10 @@ <h3 class="active title panel-heading {{ record.ui.access_status.id }} m-0">
8287
download_endpoint='invenio_app_rdm_records.record_file_download',
8388
preview_endpoint='invenio_app_rdm_records.record_file_preview',
8489
is_media=false,
85-
permissions=None
90+
permissions=None,
91+
display_name=None
8692
) %}
87-
<table class="ui striped table files fluid {{record.ui.access_status.id}}">
93+
<table id="file-list-table" class="ui striped table files fluid {{record.ui.access_status.id}}">
8894
<thead>
8995
<tr>
9096
<th>{{_('Name')}}</th>
@@ -108,6 +114,11 @@ <h3 class="active title panel-heading {{ record.ui.access_status.id }} m-0">
108114
{% for file in files %}
109115
{% if not file.access.hidden %}
110116
{%- set is_remote_file = file.transfer.type == transfer_types.REMOTE %}
117+
{%- if display_name %}
118+
{%- set human_readable_file_name = display_name(file) or file.key %}
119+
{%- else %}
120+
{%- set human_readable_file_name = file.key %}
121+
{%- endif %}
111122
{% if is_preview %}
112123
{%- set file_url_download = url_for(download_endpoint, pid_value=pid, filename=file.key, download=1, preview=1) %}
113124
{%- set file_url_preview = url_for(preview_endpoint, pid_value=pid, filename=file.key, preview=1, include_deleted=include_deleted_value) %}
@@ -120,7 +131,7 @@ <h3 class="active title panel-heading {{ record.ui.access_status.id }} m-0">
120131
<tr>
121132
<td class="ten wide">
122133
<div>
123-
<a href="{{ file_url_download }}">{{ file.key }}</a>
134+
<a href="{{ file_url_download }}">{{ human_readable_file_name }}</a>
124135
</div>
125136
{%- if not is_remote_file %}
126137
<small class="ui text-muted font-tiny">{{ file.checksum or _("Checksum not yet calculated.") }}
@@ -151,7 +162,7 @@ <h3 class="active title panel-heading {{ record.ui.access_status.id }} m-0">
151162
{%- endmacro %}
152163

153164

154-
{% macro file_list_box(files, pid, is_preview, include_deleted, record, permissions) %}
165+
{% macro file_list_box(files, pid, is_preview, include_deleted, record, permissions, display_name=None) %}
155166
{%- set binary_sizes = not config.APP_RDM_DISPLAY_DECIMAL_FILE_SIZES %}
156167
<div class="ui accordion panel mb-10 {{ record.ui.access_status.id }}" href="#files-list-accordion-panel">
157168
<h3 class="active title panel-heading {{ record.ui.access_status.id }} m-0">
@@ -174,13 +185,13 @@ <h4 class="inline">{{ record.ui.access_status.title_l10n }}</h4>
174185
</div>
175186
{% endif %}
176187
<div>
177-
{{ file_list(files, pid, is_preview, include_deleted, record=record,download_endpoint="invenio_app_rdm_records.record_file_download", permissions=permissions) }}
188+
{{ file_list(files, pid, is_preview, include_deleted, record=record,download_endpoint="invenio_app_rdm_records.record_file_download", permissions=permissions, display_name=display_name) }}
178189
</div>
179190
</div>
180191
</div>
181192
{%- endmacro %}
182193

183-
{% macro media_file_list_box(files, pid, is_preview, include_deleted, record, permissions) %}
194+
{% macro media_file_list_box(files, pid, is_preview, include_deleted, record, permissions, display_name=None) %}
184195
{%- set binary_sizes = not config.APP_RDM_DISPLAY_DECIMAL_FILE_SIZES %}
185196
<div class="ui accordion panel mb-10 {{ record.access.record }}" href="#media-files-preview-accordion-panel">
186197
<h3 class="active title panel-heading {{ record.access.record }} m-0">
@@ -204,7 +215,7 @@ <h4 class="inline">{{ record.ui.access_status.title_l10n }}</h4>
204215
</div>
205216
{% endif %}
206217
<div>
207-
{{ file_list(files, pid, is_preview, include_deleted, record=record, with_preview=false, download_endpoint="invenio_app_rdm_records.record_media_file_download", is_media=true, permissions=permissions) }}
218+
{{ file_list(files, pid, is_preview, include_deleted, record=record, with_preview=false, download_endpoint="invenio_app_rdm_records.record_media_file_download", is_media=true, permissions=permissions, display_name=display_name) }}
208219
</div>
209220
</div>
210221
</div>

0 commit comments

Comments
 (0)