summaryrefslogtreecommitdiff
path: root/app/views/layouts/application.html.erb
blob: 7ae44a987230c9368ee07f40894f1ce2e1223bb8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
<!DOCTYPE html>
<html lang="en">
  <head>
    <title>Esoterra</title>
    <meta name="viewport" content="width=device-width,initial-scale=1">
    <meta name="turbolinks-cache-control" content="no-cache">
    <%= csrf_meta_tags %>
    <%= csp_meta_tag %>

    <%= stylesheet_pack_tag 'application', media: 'all', 'data-turbolinks-track': 'reload' %>
    <%= javascript_pack_tag 'application', 'data-turbolinks-track': 'reload' %>
  </head>

  <body class="flex flex-col min-h-screen text-base text-gray-400 bg-gray-800">
    <%= render "header" %>

    <div class="main-wrapper flex-1 bg-gray-900 rounded flex-grow">
      <div class="game-container mx-auto p-2 grid gap-2 grid-cols-12 px-2"
           style="max-width: 1800px;">
        <% if user_signed_in? %>
          <%= render "navbar" %>
        <% end %>
        <div id="world_box" class="game-container-box col-span-12 sm:col-span-8">
          <p><%= notice %></p>
          <p><%= alert %></p>
          <%= yield %>
        </div>
        <% if user_signed_in? %>
          <div id="chat_box" class="game-container-box side-box col-span-12 sm:col-span-4"
               data-turbolinks-permanent>
            <%= render "chat" %>
          </div>
          </div>
        <% else %>
          <div id="game_info_box" class="game-container-box side-box col-span-12 sm:col-span-4"
               data-turbolinks-permanent>
            <%= render "game_info" %>
          </div>
        <% end %>
      </div>
    </div>

    <div class="flex-shrink bg-gray-800 p-2 text-display text-center text-xs text-gray-400">
      Esoterra &copy; 2020-2021
    </div>
  </body>
</html>