<%namespace name='static' file='static_content.html'/>

<!doctype html>
<html>
  <head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <title>
        <%block name="title"></%block> |
        % if context_course:
        <% ctx_loc = context_course.location %>
        ${context_course.display_name_with_default} |
        % endif
        edX Studio
    </title>

    <meta name="viewport" content="width=device-width,initial-scale=1">
    <meta name="path_prefix" content="${MITX_ROOT_URL}">

    <%static:css group='base-style'/>
    <link rel="stylesheet" type="text/css" href="${static.url('js/vendor/markitup/skins/simple/style.css')}" />
    <link rel="stylesheet" type="text/css" href="${static.url('js/vendor/markitup/sets/wiki/style.css')}" />
    <link rel="stylesheet" type="text/css" href="${static.url('css/vendor/symbolset.ss-symbolicons-block.css')}" />
    <link rel="stylesheet" type="text/css" href="${static.url('css/vendor/symbolset.ss-standard.css')}" />

    <%include file="widgets/segment-io.html" />

    <%block name="header_extras"></%block>
  </head>

  <body class="<%block name='bodyclass'></%block> hide-wip">
    <%include file="courseware_vendor_js.html"/>

    ## js templates
    <script id="alert-tpl" type="text/template">
      <%static:include path="js/alert.underscore" />
    </script>
    <script id="notification-tpl" type="text/template">
      <%static:include path="js/notification.underscore" />
    </script>
    <script id="prompt-tpl" type="text/template">
      <%static:include path="js/prompt.underscore" />
    </script>

    ## javascript
    <script type="text/javascript" src="/jsi18n/"></script>
    <script type="text/javascript" src="${static.url('js/vendor/json2.js')}"></script>
    <script type="text/javascript" src="${static.url('js/vendor/underscore-min.js')}"></script>
    <script type="text/javascript" src="${static.url('js/vendor/backbone-min.js')}"></script>
    <script type="text/javascript" src="${static.url('js/vendor/markitup/jquery.markitup.js')}"></script>
    <script type="text/javascript" src="${static.url('js/vendor/markitup/sets/wiki/set.js')}"></script>
    <script src="${static.url('js/vendor/symbolset.ss-standard.js')}"></script>
    <script src="${static.url('js/vendor/symbolset.ss-symbolicons.js')}"></script>

    <%static:js group='main'/>
    <%static:js group='module-js'/>
    <script src="${static.url('js/vendor/jquery.inlineedit.js')}"></script>
    <script src="${static.url('js/vendor/jquery.cookie.js')}"></script>
    <script src="${static.url('js/vendor/jquery.leanModal.min.js')}"></script>
    <script src="${static.url('js/vendor/jquery.tablednd.js')}"></script>
    <script src="${static.url('js/vendor/jquery.form.js')}"></script>
    <script src="${static.url('js/vendor/jquery.smooth-scroll.min.js')}"></script>
    <script type="text/javascript" src="${static.url('js/vendor/CodeMirror/htmlmixed.js')}"></script>
    <script type="text/javascript" src="${static.url('js/vendor/CodeMirror/css.js')}"></script>
    <script type="text/javascript" src="//www.youtube.com/player_api"></script>

    <script src="${static.url('js/models/feedback.js')}"></script>
    <script src="${static.url('js/views/feedback.js')}"></script>
    <script type="text/javascript">
$(document).ajaxError(function(event, jqXHR, ajaxSettings, thrownError) {
    var msg = new CMS.Models.ErrorMessage({
        "title": gettext("Server Error"),
        "message": jqXHR.responseText,
        "actions": {
            "primary": {
                "text": "Dismiss",
                "click": function(view) {
                    view.hide();
                }
            }
        }
    });
    new CMS.Views.Notification({model: msg});
    return msg;
})
    </script>

    <!-- view -->
    <div class="wrapper wrapper-view">
      <%include file="widgets/header.html" />

      <div id="page-alert"></div>

      <%block name="content"></%block>

      % if user.is_authenticated():
      <%include file="widgets/sock.html" />
      % endif

      <%include file="widgets/footer.html" />
      <%include file="widgets/tender.html" />

      <div id="page-notification"></div>
    </div>

    <div id="page-prompt"></div>
    <%block name="jsextra"></%block>
  </body>

  <%include file="widgets/qualaroo.html" />
</html>