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
Ruby agile-developmentangularbcfboardsbug-trackerganttgantt-chartifcissue-trackerjira-alternativekanbanopenprojectproduct-managementproject-managementproject-planningroadmaprubyscrumtimelineworkflows
Replace wp-status with our own component
Oliver Günther7b9688209591
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.htmlindex 1a52d46f35b..c76c9b544f9 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@@ -67,9 +67,7 @@<divclass="op-ian-item--status">- <wp-status-button- [workPackage]="workPackage">- </wp-status-button>+ <op-in-app-notification-status [status]="workPackage.status"></op-in-app-notification-status></div><divdiff --git a/frontend/src/app/features/in-app-notifications/entry/status/in-app-notification-status.component.html b/frontend/src/app/features/in-app-notifications/entry/status/in-app-notification-status.component.htmlnew file mode 100644index 00000000000..05e0e39cdc4--- /dev/null+++ b/frontend/src/app/features/in-app-notifications/entry/status/in-app-notification-status.component.html@@ -0,0 +1,9 @@+<span+ class="op-ian-wp-status"+ [ngClass]="highlightClass"+>+ <span+ class="op-ian-wp-status--text"+ [textContent]="status.name"+ ></span>+</span>diff --git a/frontend/src/app/features/in-app-notifications/entry/status/in-app-notification-status.component.sass b/frontend/src/app/features/in-app-notifications/entry/status/in-app-notification-status.component.sassnew file mode 100644index 00000000000..f7b965a1285--- /dev/null+++ b/frontend/src/app/features/in-app-notifications/entry/status/in-app-notification-status.component.sass@@ -0,0 +1,13 @@+@import "helpers"++.op-ian-wp-status+ @include text-shortener(false)+ padding: 5px+ margin-bottom: 0+ border: none+ border-radius: 2px+ color: white+ max-width: 100%++ &--text+ margin: 0 5pxdiff --git a/frontend/src/app/features/in-app-notifications/entry/status/in-app-notification-status.component.ts b/frontend/src/app/features/in-app-notifications/entry/status/in-app-notification-status.component.tsnew file mode 100644index 00000000000..296ef8721d4--- /dev/null+++ b/frontend/src/app/features/in-app-notifications/entry/status/in-app-notification-status.component.ts@@ -0,0 +1,28 @@+import {+ ChangeDetectionStrategy,+ Component,+ Input,+ OnChanges,+ SimpleChanges,+} from '@angular/core';+import { Highlighting } from 'core-app/features/work-packages/components/wp-fast-table/builders/highlighting/highlighting.functions';+import { StatusResource } from 'core-app/features/hal/resources/status-resource';++@Component({+ selector: 'op-in-app-notification-status',+ styleUrls: ['./in-app-notification-status.component.sass'],+ templateUrl: './in-app-notification-status.component.html',+ changeDetection: ChangeDetectionStrategy.OnPush,+})+export class InAppNotificationStatusComponent implements OnChanges {+ @Input() status:StatusResource;++ highlightClass:string;++ ngOnChanges(changes:SimpleChanges):void {+ if (changes.status) {+ const status = changes.status as { currentValue:StatusResource };+ this.highlightClass = Highlighting.backgroundClass('status', status.currentValue.id || '');+ }+ }+}diff --git a/frontend/src/app/features/in-app-notifications/in-app-notifications.module.ts b/frontend/src/app/features/in-app-notifications/in-app-notifications.module.tsindex 221dfb363ae..6ddbb281f52 100644--- a/frontend/src/app/features/in-app-notifications/in-app-notifications.module.ts+++ b/frontend/src/app/features/in-app-notifications/in-app-notifications.module.ts@@ -12,6 +12,7 @@ import { InAppNotificationToolbarComponent } from 'core-app/features/in-app-notiimport { InAppNotificationCenterPageComponent } from 'core-app/features/in-app-notifications/center/in-app-notification-center-page.component';import { OpenprojectWorkPackagesModule } from 'core-app/features/work-packages/openproject-work-packages.module';import { DynamicModule } from 'ng-dynamic-component';+import { InAppNotificationStatusComponent } from './entry/status/in-app-notification-status.component';@NgModule({declarations: [@@ -20,6 +21,7 @@ import { DynamicModule } from 'ng-dynamic-component';InAppNotificationEntryComponent,InAppNotificationToolbarComponent,InAppNotificationCenterPageComponent,+ InAppNotificationStatusComponent,],imports: [// Routes for /backlogs