<%!
from django.utils.translation import ugettext as _
from xmodule.util.date_utils import get_time_display
from django.conf import settings
%>

<%namespace name='static' file='static_content.html'/>
<h2 class="problem-header">
  ${ problem['name'] }
</h2>

<div class="problem-progress"></div>

% if problem_is_timed:
  <div class="time_limit">
    <p>
      ${_("At {start_time}, you started this exam.").format(
          start_time=get_time_display(start_time, coerce_tz=settings.TIME_ZONE))}
      <br />
      <b>
      ${_("By {end_time}, you must manually click the 'Final Submit' button below!").format(
          end_time=get_time_display(end_time_to_display, coerce_tz=settings.TIME_ZONE))}
      </b>
    </p>
  </div>
% endif

<div class="problem">
  ${ problem['html'] }

  <div class="action">
    <input type="hidden" name="problem_id" value="${ problem['name'] }" />

    % if reset_button:
    <input class="reset" type="button" value="${_('Reset')}" />
    % endif
    % if save_button:
    <input class="save" type="button" value="${_('Save')}" />
    % endif
    % if check_button:
    <input class="check ${ check_button } primary-button" type="button" value="${ check_button }" />
    % endif
    % if answer_available:
    <button class="show"><span class="show-label">${_('Show Answer(s)')}</span> <span class="sr">${_("(for question(s) above - adjacent to each field)")}</span></button>
    % endif
    % if attempts_allowed :
    <div class="submission_feedback">
      ${_("You have used {num_used} of {num_total} submissions").format(num_used=attempts_used, num_total=attempts_allowed)}
    </div>
    % endif
  </div>
</div>
