Skip to content

OpenProject is the leading open source project management software for product, project and portfolio management. A powerful Jira alternative with agile planning, issue tracking, roadmaps, Gantt charts, time tracking, collaboration features, and more. Available on premises or in the cloud. ⭐ Star us on GitHub

List more people on notification card

Oliver Günther43e6338da856
diff --git a/config/locales/js-en.yml b/config/locales/js-en.yml
index 19b8b9333ea..4d0d476ddc8 100644
--- a/config/locales/js-en.yml
+++ b/config/locales/js-en.yml
@@ -596,6 +596,7 @@ en:
all: 'All'
all_title: 'Show all'
center:
+ label_actor_and: 'and'
and_more_users:
one: 'and 1 other'
other: 'and %{count} others'
diff --git a/frontend/src/app/features/in-app-notifications/entry/in-app-notification-entry.component.html b/frontend/src/app/features/in-app-notifications/entry/in-app-notification-entry.component.html
index d45f065c03d..bbba1842ffa 100644
--- a/frontend/src/app/features/in-app-notifications/entry/in-app-notification-entry.component.html
+++ b/frontend/src/app/features/in-app-notifications/entry/in-app-notification-entry.component.html
@@ -93,17 +93,23 @@
[textContent]="relativeTime$ | async"
></div>
<div>
- <op-principal
- class="op-ian-item--actors"
- [principal]="actors[0]"
- [hideName]="false"
- [hideAvatar]="true"
- [link]="!isMobile()"
- ></op-principal>
+ <ng-container *ngFor ="let actor of actors | slice:0:3; let last = last">
+ <span *ngIf="last && actors.length > 1 && actors.length < 4">
+ {{ text.and }}
+ </span>
+ <op-principal
+ class="op-ian-item--actors"
+ [principal]="actor"
+ [hideName]="false"
+ [hideAvatar]="true"
+ [link]="!isMobile()"
+ ></op-principal>
+ <span *ngIf="!last && actors.length > 2" [textContent]="', '"></span>
+ </ng-container>
<span
- *ngIf="actors.length > 1"
+ *ngIf="actors.length > 3"
>
- {{ text_for_additional_authors(actors.length - 1) }}
+ {{ text_for_additional_authors(actors.length - 3) }}
</span>
</div>
</div>
diff --git a/frontend/src/app/features/in-app-notifications/entry/in-app-notification-entry.component.ts b/frontend/src/app/features/in-app-notifications/entry/in-app-notification-entry.component.ts
index 981f5237519..9ad81dcd917 100644
--- a/frontend/src/app/features/in-app-notifications/entry/in-app-notification-entry.component.ts
+++ b/frontend/src/app/features/in-app-notifications/entry/in-app-notification-entry.component.ts
@@ -63,6 +63,7 @@ export class InAppNotificationEntryComponent implements OnInit {
project?:{ href:string, title:string, showUrl:string };
text = {
+ and: this.I18n.t('js.notifications.center.label_actor_and'),
and_other_singular: this.I18n.t('js.notifications.center.and_more_users.one'),
and_other_plural: (count:number):string => this.I18n.t('js.notifications.center.and_more_users.other',
{ count }),