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 invisble button with a link as it matches the requirements better
Henriette Darge978006bc4df7
diff --git a/app/components/projects/index_page_header_component.html.erb b/app/components/projects/index_page_header_component.html.erbindex 3864dd6e94e..2e905fe89bd 100644--- a/app/components/projects/index_page_header_component.html.erb+++ b/app/components/projects/index_page_header_component.html.erb@@ -6,25 +6,30 @@<% if query_saveable? %><% header.with_action_text { t('lists.can_be_saved_as') } %>- <% header.with_action_button(mobile_icon: "op-save", mobile_label: t('button_save_as'),- scheme: :invisible,- size: :medium,- mr: BUTTON_MARGIN_RIGHT,- tag: :a,- href: new_projects_query_path,- data: {- controller: "params-from-query",- 'application-target': "dynamic",- 'params-from-query-allowed-value': '["filters", "columns"]'- },- classes: 'Button--invisibleOP') do |button|%>- <% button.with_leading_visual_icon(icon: "op-save") %>- t('button_save_as')+ <% header.with_action_link(mobile_icon: nil, # Do not show on mobile as it is already part of the menu+ mobile_label: nil,+ href: new_projects_query_path,+ data: {+ controller: "params-from-query",+ 'application-target': "dynamic",+ 'params-from-query-allowed-value': '["filters", "columns"]'+ }) do %>+ <% render(Primer::Beta::Octicon.new(icon: "op-save",+ align_self: :center,+ "aria-label": I18n.t("button_save_as"),+ mr: 1)+ ) + content_tag(:span, t("button_save_as")) %><% end %>-<% end %>- <%= header.with_action_menu(menu_arguments: { anchor_align: :end }, button_arguments: { icon: "op-kebab-vertical", "aria-label": t(:label_more), data: { 'test-selector': 'project-more-dropdown-menu' } }) do |menu, button|+ <%= header.with_action_menu(menu_arguments: {+ anchor_align: :end+ },+ button_arguments: {+ icon: "op-kebab-vertical",+ "aria-label": t(:label_more),+ data: { "test-selector": "project-more-dropdown-menu" }+ }) do |menu, button|if gantt_portfolio_project_ids.any?menu.with_item(tag: :a,diff --git a/frontend/src/global_styles/openproject/_primer-adjustments.sass b/frontend/src/global_styles/openproject/_primer-adjustments.sassindex aa4fee7f626..51a5ae4295c 100644--- a/frontend/src/global_styles/openproject/_primer-adjustments.sass+++ b/frontend/src/global_styles/openproject/_primer-adjustments.sass@@ -49,7 +49,8 @@ ul.tabnav-tabsmargin-left: 0/* Remove margin-left: 2rem from Breadcrumbs */-#breadcrumb,page-header+#breadcrumb,+page-headerolmargin-left: 0.breadcrumb-item.breadcrumb-item-selected@@ -63,20 +64,3 @@ ul.tabnav-tabs.Overlay&-body_autocomplete_heightmin-height: 300px--/* TODO: The actions within the PageHeader are currently not aligned correctly.- The pageHeader itself already uses center alignment but the actions themselves default to 'normal'.- Will be added to our primer repository */-.PageHeader-actions- align-items: center--/* Primer uses the fgColor (blue) for Buttons having the :invisible schema unless they receive an trailing/leading icon.- Then, the color changes to gray. This seems inconsistent. An issue has been opened with Primer to discuss this behavior.- Until then, we will override the fgColor for the invisible schema.- No all invisible schema buttons are overwritten though and need to apply this modifier themselves. */-.Button--invisibleOP,-.Button--invisibleOP:hover:not(:disabled,.Button--inactive)- color: var(--button-invisible-fgColor-rest,var(--color-btn-outline-text))-- .Button-visual- color: var(--button-invisible-fgColor-rest,var(--color-btn-outline-text))