<!DOCTYPE html>
<html>

<head>
  <meta charset='UTF-8'/>
  <link href='/base/base.css?<%=obj.nocache%>' rel='stylesheet' />
  <link href='/ext/mapbox.css?<%=obj.nocache%>' rel='stylesheet' />
  <link href='/app/app.css?<%=obj.nocache%>' rel='stylesheet' />
  <%= this.analytics(obj) %>
  <title>Error</title>
</head>

<body id='view' class='fill-blue pad8'>

<%
var title = 'Error';
var message = error.message || error.toString();
switch (error.code) {
case 'ENOENT':
  title = 'Not found';
  message = "Couldn't open file at <em>" + error.path + "</em>";
  break;
};
%>

<div class='clearfix limiter pad4y'>
  <div class='col6 margin3 dark'>
    <h2 class='center space-bottom'><%= title %></h2>
    <pre class='fill-darken0 pad2 unround space-bottom contain'><%= message.split(' ').map(function(v) { return v.length > 20 ? "<span class='long'>" + v + "</span>" : v; }).join(' ') %><!--
    --><a href='/authorize' class='button quiet round-right icon close pin-topright offcanvas-right'></a></pre>
    <div class='center small space'>
      <a href='https://github.com/mapbox/tm2/issues' class='icon quiet github' target='_blank'>Report on GitHub</a>
    </div>
  </div>
</div>

<style type='text/css'>
/* Error page */
.message .long { word-break:break-all };
</style>

</body>

</html>
