glowing-bear/websockets.html

59 lines
2.1 KiB
HTML
Raw Normal View History

2013-02-16 19:18:14 +01:00
<!DOCTYPE html>
2013-02-18 00:49:42 +01:00
<html ng-app="weechat">
2013-02-16 18:49:20 +01:00
<head>
2013-02-16 19:18:14 +01:00
<link href="css/bootstrap.min.css" rel="stylesheet" media="screen">
<script type="text/javascript" src="js/angular.min.js"></script>
2013-07-28 05:59:12 +02:00
<script type="text/javascript" src="js/underscore.js"></script>
<script type="text/javascript" src="js/protocol.js"></script>
2013-02-16 19:18:14 +01:00
<script type="text/javascript" src="js/websockets.js"></script>
2013-02-16 18:49:20 +01:00
</head>
<body>
2013-02-16 19:18:14 +01:00
<div ng-controller="WeechatCtrl">
2013-02-18 00:49:42 +01:00
<div ng-hide="connected">
2013-02-16 19:18:14 +01:00
<form class="form-horizontal">
<legend>Connection</legend>
<div class="control-group">
<label class="control-label" for="hostport">Hostport</label>
<div class="controls">
<input type="text" id="hostport" ng-model="hostport" placeholder="Hostport">
</div>
</div>
<div class="control-group">
<label class="control-label" for="proto">Proto</label>
<div class="controls">
<input type="text" id="proto" ng-model="proto" placeholder="proto">
</div>
</div>
<div class="control-group">
<label class="control-label" for="password">Password</label>
<div class="controls">
<input type="text" id="password" ng-model="password" placeholder="Password">
</div>
</div>
<div class="control-group">
<div class="controls">
2013-02-18 00:49:42 +01:00
<button class="btn btn-primary" ng-click="connect()">Connect!</button>
2013-02-16 19:18:14 +01:00
</div>
</div>
</form>
</div>
2013-02-18 00:49:42 +01:00
<div ng-show="connected">
2013-07-30 15:01:08 +02:00
<div ng-repeat="(key, content) in buffers">
{{ content.full_name }}
</div>
<div ng-repeat="bufferline in buffer">
<p>
2013-07-28 06:01:35 +02:00
<span ng-repeat="part in bufferline" class="text">
{{ part.text }}
</span>
</p>
2013-02-18 00:49:42 +01:00
</div>
<form ng-submit="sendMessage()">
2013-02-18 00:49:42 +01:00
<input type="text" ng-model="command"></input>
<input type="submit" class="btn btn-primary"></button>
</form>
2013-02-16 19:18:14 +01:00
</div>
</div>
2013-02-16 18:49:20 +01:00
</body>
</html>