added fetching of source

This commit is contained in:
sm
2015-08-30 01:48:35 -07:00
parent 33f94af784
commit 6bad869501
2 changed files with 39 additions and 123 deletions
+14 -21
View File
@@ -10,13 +10,12 @@
<body>
<div class="container">
<div id="error" class="alert alert-danger">
<div class="container"></div>
<div class="container">Placeholder...</div>
</div>
</div>
<div style="float:right; text-align:right;">
<strong><a href="/ui">HackerBots</a>&nbsp&nbsp</strong>
<br>{{ server.hostname }}&nbsp&nbsp{{game}}&nbsp&nbsp
<strong><a href="/ui">Game Center</a>&nbsp&nbsp</strong>
</div>
<ul class="nav nav-tabs" id='tabs'>
<li><a href="#code" data-toggle="tab" class='active'>Code</a></li>
@@ -32,26 +31,20 @@
<div style="float:left; padding:20px">
<div id="starters">
<button id='starter' class="btn btn-primary" style="width:100px;">Play</button><br><br>
<button id='watch' class="btn btn-success" style="width:100px;">Watch</button><br><br>
</div>
<br>
<div>
<select id="robot_picker" class="form-control" style='width:100px'>
{% for bot in bots %}
<option value="{{bot.id}}">{{bot.name}}</option>
{% endfor %}
</select><br>
<button class='btn bt-primary' id='save' style="width:100px;">Save Bot</button><br>
<span class='under-button' id='lastsave'></span><br><br>
<button class='btn bt-primary' id='new' style="width:100px;">New Bot</button><br><br>
<div id='rename-block' style='display:none;'>
<input type='text' id='newname' style="width:100px; "><br><br>
</div>
<button class='btn bt-primary' id='rename' style="width:100px;">Rename Bot</button><br><br>
<br><br>
<button id='watch' class="btn btn-success" style="width:100px;">Watch</button><br><br>
</div>
</div>
<pre id="editor" class="center"></pre>
<div id="fetch-area">
<label for="fetch-url">Source URI:</label>
<div class="input-group">
<span class="input-group-addon">@</span>
<input type="url" class="form-control" id="fetch-url" placeholder="https://gist.github.com/...">
<span class="input-group-btn">
<button id="fetch-button" class="btn btn-default" type="button">fetch</button>
</span>
</div>
</div>
<pre id="editor" style="display: none;" class="center"></pre>
</div>
<div class="tab-pane" id="arena">