-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
38 lines (38 loc) · 1.28 KB
/
index.html
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
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>WebRTC chat</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="icon" href="https://luiscastro193.github.io/favicon.svg" type="image/svg+xml">
<link href="https://fonts.googleapis.com/css2?family=Lexend:wght@400;700&display=swap" rel="stylesheet">
<link rel="stylesheet" href="styles.css">
<script type="module" src="main.js"></script>
<link rel="modulepreload" href="webrtc.js">
</head>
<body>
<h3>WebRTC chat</h3>
<button id="create-button" disabled>Create room</button>
<button id="join-button" disabled>Join room</button>
<form id="name-form" hidden>
<br>
<label>Enter your name:
<input name="name" type="text" onmouseenter="this.focus()" required>
</label>
<input type="submit" value="Send">
</form>
<form id="room-form" autocomplete="off" hidden>
<br>
<label>Enter the room code:
<input name="code" type="text" inputmode="numeric" pattern="[0-9]{4}" onmouseenter="this.focus()" required>
</label>
<input type="submit" value="Send">
</form>
<p id="info"></p>
<ul id="messages"></ul>
<form id="message-form" autocomplete="off" hidden>
<input name="message" type="text" onmouseenter="this.focus()" required>
<input type="submit" value="Send">
</form>
</body>
</html>