<!doctype html>
<html>
  <head>
    <title>Chess using Amber</title>
    <meta charset="utf-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1" />
    <link rel="stylesheet" href="/dist/main.bundle.css">
    <link rel="apple-touch-icon" href="/favicon.png">
    <link rel="icon" href="/favicon.png">
    <link rel="icon" type="image/x-icon" href="/favicon.ico">
  </head>
  <body>
    <nav class="navbar navbar-expand navbar-dark bg-primary mb-3">
      <div class="container">
        <a href="/" class="navbar-brand">
          <img src="/dist/images/logo.svg" height="30" alt="Amber logo">
        </a>
        <ul class="navbar-nav mr-auto">
          <%= render(partial: "layouts/_nav.ecr") %>
        </ul>
        <ul class="navbar-nav">
          <%= render(partial: "layouts/_session.ecr") %>
        </ul>
      </div>
    </nav>

    <div class="container">
      <%- flash.each do |key, value| %>
        <div class="alert alert-<%= key %>" role="alert">
          <%= flash[key] %>
        </div>
      <%- end %>

      <div class="main">
        <%= content %>
      </div>
    </div>

    <script src="/dist/main.bundle.js"></script>

    <%- if Amber.settings.auto_reload? -%><script src="/js/client_reload.js"></script><%- end -%>
  </body>
</html>
