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
Merge branch 'dev' into 53810-update-pageheaders-subheaders-in-the-rails-project-pages
Behrokh Satarnejadbd3fb3e07d90
diff --cc app/views/forums/show.html.erbindex 67bebc2b1be,576da3808a9..0d7e4a48b97--- a/app/views/forums/show.html.erb+++ b/app/views/forums/show.html.erb@@@ -46,38 -49,24 +49,39 @@@ See COPYRIGHT and LICENSE files for mor<% end %></div>-<%= toolbar title: @forum.name, subtitle: format_text(@forum.description) do %>- <% if authorize_for(:messages, :new) %>- <li class="toolbar-item">- <%= link_to({ controller: '/messages', action: 'new', forum_id: @forum },- { class: 'add-message-button button -primary',- aria: { label: t(:label_message_new) },- title: t(:label_message_new) }) do %>- <%= op_icon('button--icon icon-add') %>- <span class="button--text"><%= t(:label_message) %></span>- <% end %>- <% csp_onclick('jQuery("#add-message").show(); jQuery("#message_subject").focus();', '.add-message-button') %>- </li>- <% end %>- <% unless User.current.anonymous? %>- <li class="toolbar-item">- <%= watcher_link(@forum, User.current) %>- </li>- <% end %>+++<%=+ render(Primer::OpenProject::PageHeader.new) do |header|+ header.with_title { @forum.name }+ header.with_description { @forum.description }+ header.with_breadcrumbs([{ href: project_overview_path(@project.id), text: @project.name },+ { href: project_forums_path(@project), text: t(:label_forum_plural) },+ @forum.name])+ unless User.current.anonymous?+ watcher_button_args = watcher_button_arguments(@forum, User.current)+ header.with_action_button(**watcher_button_args) do |button|+ button.with_leading_visual_icon(icon: watcher_button_args[:mobile_icon])+ watcher_button_args[:mobile_label]+ end+ end+ end+%>+<% if authorize_for(:messages, :new) %>+ <%=+ render(Primer::OpenProject::SubHeader.new) do |subheader|+ if authorize_for(:messages, :new)+ subheader.with_action_button(scheme: :primary,+ aria: { label: t(:label_message_new) },+ title: t(:label_message_new),+ tag: :a,+ class: 'add-message-button',+ href: url_for({controller: '/messages', action: 'new', forum_id: @forum})) do |button|+ button.with_leading_visual_icon(icon: :plus)+ t(:label_message)+ end+ end+ end+ %><% end %><% if @topics.any? %>diff --cc app/views/messages/edit.html.erbindex fa2fad4d8bc,503d85c27e5..3900b636238--- a/app/views/messages/edit.html.erb+++ b/app/views/messages/edit.html.erb@@@ -27,14 -27,7 +27,14 @@@ See COPYRIGHT and LICENSE files for mor++#%>-<h2><%= link_to h(@forum.name), controller: '/forums', action: 'show', project_id: @project, id: @forum %> » <%= h @message.subject %></h2>+<%=+ render Primer::OpenProject::PageHeader.new do |header|+ header.with_title { @message.subject }+ header.with_breadcrumbs( [{ href: project_overview_path(@project.id), text: @project.name },+ { href: project_forums_path(@project), text: t(:label_forum_plural) },+ { href: project_forum_path(@project, @forum), text: @forum.name },+ "#{ @message.subject }: <b>#{t(:label_edit)}</b>".html_safe], selected_item_font_weight: :normal)- end %>++ end %><%= labelled_tabular_form_for @message,url: topic_path(@message),diff --cc app/views/messages/new.html.erbindex 9a278618e1c,58fed5b4008..3b6e0879f52--- a/app/views/messages/new.html.erb+++ b/app/views/messages/new.html.erb@@@ -27,23 -27,19 +27,26 @@@ See COPYRIGHT and LICENSE files for mor++#%>-<h2><%= link_to h(@forum.name), controller: '/forums', action: 'show', project_id: @project, id: @forum %> » <%= t(:label_message_new) %></h2>-+<%=+ render(Primer::OpenProject::PageHeader.new) do |header|+ header.with_title { t(:label_message_new) }+ header.with_breadcrumbs([{ href: project_overview_path(@project.id), text: @project.name },+ { href: project_forums_path(@project), text: t(:label_forum_plural) },+ { href: url_for(controller: '/forums', action: 'show', project_id: @project, id: @forum), text: @forum.name },+ t(:label_message_new)])+ end+%><%= labelled_tabular_form_for @message,url: forum_topics_path(@forum),- html: { multipart: true,- id: 'message-form',- class: 'form' } do |f| %>+ html: {+ multipart: true,+ id: 'message-form',+ class: 'form',+ data: { turbo: false }+ } do |f| %><%= render partial: 'messages/form', locals: { f: f } %>- <hr class="form--separator" />+ <hr class="form--separator"/><%= f.button t(:button_create), class: 'button -primary -with-icon icon-checkmark' %><%= link_to t(:button_cancel), project_forum_path(@project, @forum), class: 'button -with-icon icon-cancel' %>diff --cc app/views/projects/destroy_info.html.erbindex d9dedd01181,30f0d06cd67..c9ad867ce15--- a/app/views/projects/destroy_info.html.erb+++ b/app/views/projects/destroy_info.html.erb@@@ -26,15 -26,9 +26,16 @@@ Foundation, Inc., 51 Franklin Street, FSee COPYRIGHT and LICENSE files for more details.++#%>+<%=+ render Primer::OpenProject::PageHeader.new do |header|+ header.with_title { t('project.destroy.title', name: @project_to_destroy) }+ header.with_breadcrumbs([{ href: project_overview_path(@project_to_destroy.id), text: @project_to_destroy.name },+ { href: project_settings_general_path(@project_to_destroy.id), text: I18n.t("label_project_settings") },+ t('project.destroy.title', name: @project_to_destroy)]) end %>+<%= styled_form_tag(project_path(@project_to_destroy),class: 'danger-zone',+ data: { turbo: false },method: :delete) do %><section class="form--section"><h3 class="form--section-title">diff --cc modules/boards/app/views/boards/boards/new.html.erbindex 9ee4af3a1a6,acaea1c006d..cc500c5c5b6--- a/modules/boards/app/views/boards/boards/new.html.erb+++ b/modules/boards/app/views/boards/boards/new.html.erb@@@ -28,19 -28,13 +28,25 @@@ See COPYRIGHT and LICENSE files for mor++#%><% html_title t('boards.label_create_new_board') %>-<%= toolbar title: t('boards.label_create_new_board') %>++<%=+ render Primer::OpenProject::PageHeader.new do |header|+ header.with_title { t('boards.label_create_new_board') }+ header.with_breadcrumbs( [*([ href: home_path, text: organization_name ] unless @project),+ *([ href: project_overview_path(@project.id), text: @project.name ] if @project),+ *([ href: project_work_package_boards_path(@project.id), text: t("boards.label_boards") ] if @project),+ t('boards.label_create_new_board')+ ])+ end+%>+- <%= labelled_tabular_form_for @board_grid, url: { controller: '/boards/boards', action: 'create', project_id: @project }, :html => {:id => 'board-form'} do |f| -%>+ <%= labelled_tabular_form_for @board_grid,+ url: { controller: '/boards/boards', action: 'create', project_id: @project },+ html: {+ id: 'board-form',+ data: { turbo: false }+ } do |f| -%>++<%= render :partial => 'form', :locals => {:f => f} %><%= styled_button_tag t(:button_create), class: '-primary' %><%= link_to t(:button_cancel), { controller: 'boards/boards', action: :index },