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

Let sidebar in hierarchy CF page grow full height

Henriette Dargec647c3bd2d39
diff --git a/app/views/admin/custom_fields/hierarchy/items/index.html.erb b/app/views/admin/custom_fields/hierarchy/items/index.html.erb
index 9d2f8e5f76e..a3c594e1347 100644
--- a/app/views/admin/custom_fields/hierarchy/items/index.html.erb
+++ b/app/views/admin/custom_fields/hierarchy/items/index.html.erb
@@ -32,12 +32,12 @@ See COPYRIGHT and LICENSE files for more details.
<%= render(Admin::CustomFields::EditFormHeaderComponent.new(custom_field: @custom_field, selected: :items)) %>
<%=
- render(Primer::Alpha::Layout.new(stacking_breakpoint: :md)) do |content|
+ render(Primer::Alpha::Layout.new(stacking_breakpoint: :md, classes: "custom-fields-hierarchy-page")) do |content|
content.with_main do
render(Admin::CustomFields::Hierarchy::ItemsComponent.new(item: @active_item))
end
- content.with_sidebar(row_placement: :start, col_placement: :start, border: true, border_radius: 2, p: 3) do
+ content.with_sidebar(row_placement: :start, col_placement: :start, border: true, border_bottom: 0, p: 3, classes: "custom-fields-hierarchy-page--sidebar") do
render(Admin::CustomFields::Hierarchy::TreeViewComponent.new(custom_field: @custom_field, active_item: @active_item))
end
end
diff --git a/frontend/src/global_styles/content/_hierachy_custom_field_layout.sass b/frontend/src/global_styles/content/_hierachy_custom_field_layout.sass
new file mode 100644
index 00000000000..c1c21beb64d
--- /dev/null
+++ b/frontend/src/global_styles/content/_hierachy_custom_field_layout.sass
@@ -0,0 +1,41 @@
+//-- copyright
+// OpenProject is an open source project management software.
+// Copyright (C) the OpenProject GmbH
+//
+// This program is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public License version 3.
+//
+// OpenProject is a fork of ChiliProject, which is a fork of Redmine. The copyright follows:
+// Copyright (C) 2006-2013 Jean-Philippe Lang
+// Copyright (C) 2010-2013 the ChiliProject Team
+//
+// This program is free software; you can redistribute it and/or
+// modify it under the terms of the GNU General Public License
+// as published by the Free Software Foundation; either version 2
+// of the License, or (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+//
+// You should have received a copy of the GNU General Public License
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+//
+// See COPYRIGHT and LICENSE files for more details.
+//++
+@import ../openproject/mixins
+
+body:has(.custom-fields-hierarchy-page)
+ @include extended-content--bottom
+ #content-body
+ display: flex
+ flex-direction: column
+
+.custom-fields-hierarchy-page
+ flex-grow: 1
+
+ &--sidebar
+ border-top-left-radius: var(--borderRadius-medium)
+ border-top-right-radius: var(--borderRadius-medium)
diff --git a/frontend/src/global_styles/content/_index.sass b/frontend/src/global_styles/content/_index.sass
index 9dc1ced64e8..02f9dc70042 100644
--- a/frontend/src/global_styles/content/_index.sass
+++ b/frontend/src/global_styles/content/_index.sass
@@ -76,6 +76,7 @@
@import project_status
@import activity_list
@import activity_days
+@import hierachy_custom_field_layout
@import menus/menu_blocks
@import editor/index