<%
# Copyright (C) 2012 - 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 <http://www.gnu.org/licenses/>.
%>

<fieldset>
  <legend><%= t :select_quizzes, "Select Quizzes to Export" %></legend>
    <div style="overflow: auto; max-height: 200px">
    <%= check_box :copy, :all_quizzes, :class => "copy_all", :checked => true %><%= label :copy, :all_quizzes, t('labels.all_quizzes', "All Quizzes") %>
    <ul class="unstyled_list" style="margin-<%= direction('left') %>: 20px;">
      <% global_ids = @context.content_exports.temp_record.can_use_global_identifiers? %>
      <% @context.quizzes.active.each do |quiz| %>
        <li>
          <%= check_box "copy[quizzes]", mig_id(quiz, global: global_ids), :class => 'quiz_item', :checked => true %>
          <%= label "copy[quizzes]", mig_id(quiz, global: global_ids), quiz.title %>
        </li>
      <% end %>
    </ul>
  </div>
</fieldset>
