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

[38878] Fix condition in scrolling to wiki element nav

Oliver Günther68289ff84998
diff --git a/frontend/src/app/globals/tree-menu.ts b/frontend/src/app/globals/tree-menu.ts
index 0767294bb1c..59ce13ffc15 100644
--- a/frontend/src/app/globals/tree-menu.ts
+++ b/frontend/src/app/globals/tree-menu.ts
@@ -37,7 +37,7 @@
if (selectedPage) {
const selected = $('[slug="' + selectedPage + '"]', tree);
selected.toggleClass('-selected', true);
- if (selected.length > 1) {
+ if (selected.length > 0) {
selected[0].scrollIntoView();
}
}