%
# Copyright (C) 2011 - present Instructure, Inc.
#
# This file is part of Canvas.
#
# Canvas is free software: you can redistribute it and/or modify it under
# the terms of the GNU Affero General Public License as published by the Free
# Software Foundation, version 3 of the License.
#
# Canvas 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 Affero General Public License for more
# details.
#
# You should have received a copy of the GNU Affero General Public License along
# with this program. If not, see .
%>
<%
course_home ||= false
js_env({
:COLLAPSED_MODULES => @collapsed_modules,
:IS_STUDENT => can_do(@context, @current_user, :participate_as_student),
:COURSE_ID => @context.id,
:PUBLISH_MENU_PROGRESS_ID => @progress&.id,
:NO_MODULE_PROGRESSIONS => @context.large_roster,
})
%>
<% js_bundle :module_student_view_peer_reviews %>
<% js_bundle :module_dnd %>
<% css_bundle :react_files %>
<% if @can_edit %>
<%= t('modules_keyboard_hint_updated',
'Warning: For improved accessibility in reordering Modules (or Module items), please use the Move To Dialog option found in the menu.') %>
<% if @can_view_grades %>
<%= t('links.student_progress', 'View Progress') %>
<% end %>
<% if @allow_web_export_download %>
<%= form_tag(context_url(@context, :context_start_offline_web_export_url)) do %>
<% end %>
<% end %>
<% if @context.grants_any_right?(@current_user, session, :manage_content, :manage_course_content_edit) %>
<% end %>
<% if @can_add %>
<% end %>
<% if @context.grants_any_right?(@current_user, session, :manage_content, :manage_course_content_add) && (@menu_tools[:module_index_menu].present? || @menu_tools[:module_index_menu_modal].present?) %>
<%= f.check_box :new_tab %>
<%= f.label :new_tab, :en => "Load in a new tab" %>
<% end %>
<%= t 'headings.add_prerequisite', 'Add Prerequisite to %{name}', :name => ''.html_safe %>
<%= t('select_prerequisite', %{Select the type of prerequisite. Students cannot see a module until all prerequisites are satisfied.}) %>
<%= t 'module_details', %{Modules are shown in sequential order, so only modules that are above %{name} can be set as prerequisites.}, :name => ''.html_safe %>
<%= image_tag "flagged_question_dim.png", :id => "criterion_image_min_score", :class => "image not_blank", :alt => t('images.alt.min_score', "minimum score"), :title => t('images.title.min_score', "Students must get at least a %{min_score} on this item before the module is considered complete", :min_score => "{{ min_score }}") %>
<%= image_tag "preview_dim.png", :id => "criterion_image_must_view", :class => "image not_blank", :alt => t('images.alt.must_view', "must view"), :title => t('images.title.must_view', "Students must view this item before the module is considered complete") %>
<%= image_tag "text_entry_dim.png", :id => "criterion_image_must_submit", :class => "image not_blank", :alt => t('images.alt.must_submit', "must submit"), :title => t('images.title.must_submit', "Students must submit this assignment before the module is considered complete") %>
<%= image_tag "text_entry_dim.png", :id => "criterion_image_must_contribute", :class => "image not_blank", :alt => t('images.alt.must_contribute', "must contribute"), :title => t('images.title.must_contribute', "Students must contribute to this item before the module is considered complete") %>
<%= image_tag "blank.png", :id => "criterion_image_blank", :class => "image", :alt => "" %>