forked from vedharish/ChatRTC
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
61 lines (54 loc) · 2.88 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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>ChatRTC</title>
<script src="assets/javascripts/adapter-latest.js" type="text/javascript"></script>
<script src="assets/javascripts/jquery-3.1.1.min.js" type="text/javascript"></script>
<script src="assets/javascripts/bootstrap.min.js" type="text/javascript"></script>
<script src="assets/javascripts/socket.io.min.js" type="text/javascript"></script>
<link href="assets/stylesheets/bootstrap.min.css" rel="stylesheet">
</head>
<body style="margin: 0 50px; position: fixed; top: 0; bottom: 0; right: 0; left: 0;">
<h1>ChatRTC</h1>
<div id="sourcePeer">
<div id="welcomePeer" class="hidden">
<h3 style="width: 80%; float: left; margin: 8px 0 16px;">Welcome <span id="sourceName"></span></h3>
<div style="float: right; width: 128px;">
<button class="btn btn-warning" onClick="User.change()">Edit</button>
<button class="btn btn-danger" onClick="User.logout()">Logout</button>
</div>
</div>
<div id="enterName" class="hidden">
<form class="form-inline" onSubmit="return ChatRTC.initName();" action="">
<input type="text" id="nameBox" placeholder="Type your name here" style="width: 200px; padding: 5.5px;">
<button type="submit" id="nameBtn" class="btn btn-success">Start</button>
</form>
</div>
</div>
<div id="messageContent" class="hidden" style="margin: 20px auto;">
<div class="pull-right" style="width: 24%; height: 40em;">
<fieldset class="well" style="margin-bottom: 8px;">
<div class="text-info" id="memberlog" style="height:40em; overflow:auto;"></div>
</fieldset>
<form class="form-inline" onSubmit="return ChatRTC.onMember();" action="">
<input type="text" id="memberBox" placeholder="Invite friend" style="width: 100%; padding: 5.5px;">
<button type="submit" class="hidden"></button>
</form>
</div>
<div style="width: 74%; height: 40em;">
<fieldset class="well" style="margin-bottom: 8px;">
<div class="text-info" id="chatlog" style="height:40em; overflow:auto;"></div>
</fieldset>
<form class="form-inline" onSubmit="return ChatRTC.onMessage();" action="">
<input type="text" id="messageBox" placeholder="Type your message here" style="width: 100%; padding: 5.5px;">
<button type="submit" class="hidden"></button>
</form>
</div>
</div>
<script type="text/javascript" src="assets/javascripts/user.js"></script>
<script type="text/javascript" src="assets/javascripts/webrtc.js"></script>
<script type="text/javascript" src="assets/javascripts/chatrtc.js"></script>
<script type="text/javascript" src="assets/javascripts/index.js"></script>
</body>
</html>