File size: 3,987 Bytes
a07d36d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <link
      rel="icon"
      href="data:image/svg+xml,<svg xmlns=%22http://www.w3.org/2000/svg%22 viewBox=%220 0 100 100%22><text y=%22.9em%22 font-size=%2290%22>🎱</text></svg>"
    />
    <meta name="viewport" content="width=device-width, user-scalable=no" />
    <meta name="monetization" content="$ilp.uphold.com/JKriL7R2DZfa" />
    <style>
      :root {
        --inner-height: 100vh;
      }

      * {
        margin: 0;
        padding: 0;
        outline: none;
      }

      html,
      body {
        width: 100vw;
        height: var(--inner-height);
        overflow: hidden;
        background-color: #370000;
        touch-action: none;
      }

      img {
        display: none;
      }

      button {
        cursor: pointer;
      }

      #a {
        display: grid;
        width: 100%;
        height: 100%;
      }

      @media (orientation: landscape) {
        #a {
          grid-template-areas: "a1 a2";
          grid-template-columns: 300px 1fr;
        }

        #canvas {
          max-width: calc(100vw - 300px);
          max-height: var(--inner-height);
        }
      }

      @media (orientation: portrait) {
        #a {
          grid-template-areas:
            "a1"
            "a2";
          grid-template-rows: 200px 1fr;
        }

        #canvas {
          max-width: 100vw;
          max-height: calc(var(--inner-height) - 200px);
        }
      }

      #a1 {
        grid-area: a1;
      }

      #a2 {
        grid-area: a2;
      }

      #b {
        display: grid;
        width: 100%;
        height: 100%;
        max-height: var(--inner-height);
      }

      @media (orientation: landscape) {
        #b {
          grid-template-areas:
            "b1 b1"
            "b2 b2"
            "b3 b4";
          grid-template-columns: 1fr 56px;
          grid-template-rows: 1fr 2fr 36px;
        }
      }

      @media (orientation: portrait) {
        #b {
          grid-template-areas:
            "b2 b2 b1"
            "b3 b4 b1";
          grid-template-columns: 1fr 56px 1fr;
          grid-template-rows: 1fr 36px;
        }
      }

      #b1 {
        grid-area: b1;
      }

      #b2 {
        grid-area: b2;
      }

      #b1,
      #b2 {
        background-color: #550000;
        padding: 5px;
        border: 3px solid #aa0000;
      }

      #b3 {
        grid-area: b3;
        background-color: #550000;
        padding: 0 5px;
        border: 3px solid #aa0000;
      }

      #b4 {
        grid-area: b4;
        border: 3px solid #aa0000;
      }

      #b textarea,
      #b input,
      #b button {
        width: 100%;
        height: 100%;
        border: none;
        color: white;
        font-family: "Courier New", Courier, monospace;
        font-weight: bold;
      }

      #b input {
        background-color: #550000;
      }

      #b textarea {
        background-color: #550000;
        resize: none;
      }

      #b textarea:disabled {
        opacity: 1;
      }

      #b button {
        background-color: #55aa00;
        text-align: center;
        display: inline-block;
      }

      #b1 textarea {
        white-space: pre;
      }
    </style>
  </head>
  <body>
    <div id="a">
      <div id="a1">
        <div id="b">
          <div id="b1">
            <textarea disabled="disabled" wrap="off">CONNECTING...</textarea>
          </div>
          <div id="b2">
            <textarea disabled="disabled"></textarea>
          </div>
          <div id="b3">
            <input placeholder="Message" type="text" autocomplete="off" autocapitalize="off" />
          </div>
          <div id="b4">
            <button>Send</button>
          </div>
        </div>
      </div>
      <div id="a2">
        <canvas id="canvas"></canvas>
      </div>
    </div>
    <img src="table.webp" />
    <script src="socket.io/socket.io.js"></script>
    <script src="client.js"></script>
  </body>
</html>