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
when the screen is not wide to show details and activity tab, it won't scroll to unread notification
bsatarnejad851622f00480
diff --git a/frontend/src/app/core/browser/device.service.ts b/frontend/src/app/core/browser/device.service.tsindex f89c9167aa4..418328a5794 100644--- a/frontend/src/app/core/browser/device.service.ts+++ b/frontend/src/app/core/browser/device.service.ts@@ -3,8 +3,13 @@ import { Injectable } from '@angular/core';@Injectable({ providedIn: 'root' })export class DeviceService {public mobileWidthTreshold = 680;+ public tabletWidthTreshold = 1249;public get isMobile():boolean {return (window.innerWidth < this.mobileWidthTreshold);}++ public get isTablet():boolean {+ return (window.innerWidth < this.tabletWidthTreshold);+ }}diff --git a/frontend/src/app/features/work-packages/components/wp-single-view-tabs/activity-panel/activity-base.controller.ts b/frontend/src/app/features/work-packages/components/wp-single-view-tabs/activity-panel/activity-base.controller.tsindex 4bf2af7b760..8e90f224278 100644--- a/frontend/src/app/features/work-packages/components/wp-single-view-tabs/activity-panel/activity-base.controller.ts+++ b/frontend/src/app/features/work-packages/components/wp-single-view-tabs/activity-panel/activity-base.controller.ts@@ -39,6 +39,7 @@ import { InAppNotification } from 'core-app/features/in-app-notifications/store/import { InAppNotificationsService } from 'core-app/features/in-app-notifications/store/in-app-notifications.service';import { Observable } from 'rxjs';import { map } from 'rxjs/operators';+import { DeviceService } from 'core-app/core/browser/device.service';@Directive()export class ActivityPanelBaseController extends UntilDestroyedMixin implements OnInit {@@ -74,6 +75,7 @@ export class ActivityPanelBaseController extends UntilDestroyedMixin implementsreadonly $transition:Transition,readonly wpActivity:WorkPackagesActivityService,readonly ianService:InAppNotificationsService,+ readonly deviceService:DeviceService,) {super();@@ -145,7 +147,7 @@ export class ActivityPanelBaseController extends UntilDestroyedMixin implementsprotected scrollToUnreadNotification():void {// scroll to the unread notification only if there is no deep link- if (window.location.href.indexOf('activity#') > -1) {+ if (window.location.href.indexOf('activity#') > -1 || this.deviceService.isTablet) {return;}const unreadNotifications = document.querySelectorAll('.comments-number--bubble');