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

The subjects span is now wider, thus it always catches the click events. Because of this we need to specify the condition in the click handlers.

Henriette Dinger21ea2ca79946
diff --git a/frontend/src/app/components/wp-fast-table/handlers/row/click-handler.ts b/frontend/src/app/components/wp-fast-table/handlers/row/click-handler.ts
index 6154f820c0d..9842fefb3e2 100644
--- a/frontend/src/app/components/wp-fast-table/handlers/row/click-handler.ts
+++ b/frontend/src/app/components/wp-fast-table/handlers/row/click-handler.ts
@@ -9,6 +9,8 @@ import {tableRowClassName} from '../../builders/rows/single-row-builder';
import {WorkPackageTable} from '../../wp-fast-table';
import {TableEventHandler} from '../table-handler-registry';
import {WorkPackageViewSelectionService} from "core-app/modules/work_packages/routing/wp-view-base/view-services/wp-view-selection.service";
+import {displayClassName} from "core-components/wp-edit-form/display-field-renderer";
+import {activeFieldClassName} from "core-app/modules/fields/edit/edit-form/edit-form";
export class RowClickHandler implements TableEventHandler {
@@ -45,7 +47,7 @@ export class RowClickHandler implements TableEventHandler {
// Shortcut to any clicks within a cell
// We don't want to handle these.
- if (target.parents(`.${tdClassName}`).length) {
+ if (target.hasClass(`${displayClassName}`) || target.hasClass(`${activeFieldClassName}`)) {
debugLog('Skipping click on inner cell');
return true;
}
diff --git a/frontend/src/app/components/wp-fast-table/handlers/row/double-click-handler.ts b/frontend/src/app/components/wp-fast-table/handlers/row/double-click-handler.ts
index eb0b4f7f2fe..9764ce1b3f6 100644
--- a/frontend/src/app/components/wp-fast-table/handlers/row/double-click-handler.ts
+++ b/frontend/src/app/components/wp-fast-table/handlers/row/double-click-handler.ts
@@ -9,6 +9,8 @@ import {WorkPackageTable} from '../../wp-fast-table';
import {TableEventHandler} from '../table-handler-registry';
import {LinkHandling} from "core-app/modules/common/link-handling/link-handling";
import {WorkPackageViewSelectionService} from "core-app/modules/work_packages/routing/wp-view-base/view-services/wp-view-selection.service";
+import {displayClassName} from "core-components/wp-edit-form/display-field-renderer";
+import {activeFieldClassName} from "core-app/modules/fields/edit/edit-form/edit-form";
export class RowDoubleClickHandler implements TableEventHandler {
@@ -44,7 +46,7 @@ export class RowDoubleClickHandler implements TableEventHandler {
// Shortcut to any clicks within a cell
// We don't want to handle these.
- if (target.parents(`.${tdClassName}`).length) {
+ if (target.hasClass(`${displayClassName}`) || target.hasClass(`${activeFieldClassName}`)) {
debugLog('Skipping click on inner cell');
return true;
}