app/views/layouts/decidim/admin/question.html.erb in decidim-consultations-0.24.3 vs app/views/layouts/decidim/admin/question.html.erb in decidim-consultations-0.25.0.rc1

- old
+ new

@@ -1,87 +1,8 @@ -<% content_for :secondary_nav do %> - <div class="secondary-nav secondary-nav--subnav"> - <ul> - <%= public_page_link decidim_consultations.consultation_path(current_participatory_space.consultation) %> - <% if allowed_to?(:update, :consultation, consultation: current_participatory_space.consultation) %> - <li <% if is_active_link?(decidim_admin_consultations.edit_consultation_path(current_participatory_space.consultation)) %> class="is-active" <% end %>> - <%= aria_selected_link_to t("consultation", scope: "decidim.admin.menu.questions_submenu"), - decidim_admin_consultations.edit_consultation_path(current_participatory_space.consultation) %> - </li> - <% end %> - - <li <% if is_active_link?(decidim_admin_consultations.consultation_questions_path(current_participatory_space.consultation)) %> class="is-active" <% end %>> - <%= aria_selected_link_to t("questions", scope: "decidim.admin.menu.consultations_submenu"), - decidim_admin_consultations.consultation_questions_path(current_participatory_space.consultation) %> - - <ul> - <% if allowed_to?(:update, :question, question: current_participatory_space) %> - <li <% if is_active_link?(decidim_admin_consultations.edit_question_path(current_participatory_space)) %> class="is-active" <% end %>> - <%= aria_selected_link_to t("info", scope: "decidim.admin.menu.questions_submenu"), - decidim_admin_consultations.edit_question_path(current_participatory_space) %> - </li> - <% end %> - - <% if allowed_to?(:configure, :question, question: current_participatory_space) %> - <li <% if is_active_link?(decidim_admin_consultations.edit_question_configuration_path(current_participatory_space)) %> class="is-active" <% end %>> - <%= aria_selected_link_to t("configuration", scope: "decidim.admin.menu.questions_submenu"), - decidim_admin_consultations.edit_question_configuration_path(current_participatory_space) %> - </li> - <% end %> - - <% if allowed_to? :read, :response %> - <li <% if is_active_link?(decidim_admin_consultations.responses_path(current_participatory_space)) || is_active_link?(decidim_admin_consultations.response_groups_path(current_participatory_space)) %> class="is-active" <% end %>> - <%= aria_selected_link_to t("responses", scope: "decidim.admin.menu.questions_submenu"), - decidim_admin_consultations.responses_path(current_participatory_space) %> - </li> - <% end %> - - <% if allowed_to? :read, :component %> - <li <% if is_active_link?(decidim_admin_consultations.components_path(current_participatory_space)) %> class="is-active" <% end %>> - <%= aria_selected_link_to t("components", scope: "decidim.admin.menu.questions_submenu"), - decidim_admin_consultations.components_path(current_participatory_space) %> - <ul> - <% current_participatory_space.components.each do |component| %> - <% if component.manifest.admin_engine %> - <li <% if is_active_link?(manage_component_path(component)) || is_active_link?(decidim_admin_consultations.edit_component_path(current_participatory_space, component)) || is_active_link?(decidim_admin_consultations.edit_component_permissions_path(current_participatory_space, component)) %> class="is-active" <% end %>> - <%= link_to manage_component_path(component) do %> - <%= translated_attribute component.name %> - <% if component.primary_stat.present? %> - <span class="component-counter <%= "component-counter--off" if component.primary_stat.zero? %>"> - <%= component.primary_stat %> - </span> - <% end %> - <% end %> - </li> - <% end %> - <% end %> - </ul> - </li> - <% end %> - - <% if allowed_to? :read, :category %> - <li <% if is_active_link?(decidim_admin_consultations.categories_path(current_participatory_space)) %> class="is-active" <% end %>> - <%= aria_selected_link_to t(".categories"), - decidim_admin_consultations.categories_path(current_participatory_space) %> - </li> - <% end %> - - <% if allowed_to? :read, :attachment %> - <li <% if is_active_link?(decidim_admin_consultations.question_attachments_path(current_participatory_space)) %> class="is-active" <% end %>> - <%= aria_selected_link_to t(".attachments"), - decidim_admin_consultations.question_attachments_path(current_participatory_space) %> - </li> - <% end %> - </ul> - </li> - - <li <% if is_active_link?(decidim_admin_consultations.results_consultation_path(current_participatory_space.consultation)) %> class="is-active" <% end %>> - <%= aria_selected_link_to t("results", scope: "decidim.admin.menu.consultations_submenu"), - decidim_admin_consultations.results_consultation_path(current_participatory_space.consultation) %> - </li> - - </ul> - </div> +<% content_for :sidebar_menu_nav do %> + <%= sidebar_menu(:admin_question_menu).render do + public_page_link decidim_consultations.consultation_path(current_participatory_space.consultation) + end %> <% end %> <%= render "layouts/decidim/admin/application" do %> <div class="process-title"> <div class="process-title-content">