|
|
|
|
@ -1,11 +1,13 @@
@@ -1,11 +1,13 @@
|
|
|
|
|
{% extends 'basic_template.html' %}{% block 'body' %} |
|
|
|
|
<nav class="navbar navbar-light"> |
|
|
|
|
{% extends 'basic_template.html' %}{% block 'extra_css' %}{% load static %} |
|
|
|
|
<link href="{% static '/quiz_atomes/nav_padding.css' %}" rel="stylesheet" type="text/css"> |
|
|
|
|
{% endblock %}{% block 'body' %} |
|
|
|
|
<nav class="navbar navbar-light fixed-top bg-light"> |
|
|
|
|
<div class="container"> |
|
|
|
|
<a class="navbar-brand text-primary" href="{% url "home" %}"> |
|
|
|
|
<i class="fa fa-home"></i> |
|
|
|
|
</a> |
|
|
|
|
<div class="navbar-brand text-primary"> |
|
|
|
|
<b>{{pseudo}}</b> |
|
|
|
|
<div class="navbar-brand"> |
|
|
|
|
<time>00m 00s</time> |
|
|
|
|
</div> |
|
|
|
|
<a class="navbar-brand text-primary" href="{% url "settings" %}"> |
|
|
|
|
<i class="fa fa-gear"></i> |
|
|
|
|
@ -33,4 +35,37 @@
@@ -33,4 +35,37 @@
|
|
|
|
|
</tbody> |
|
|
|
|
</table> |
|
|
|
|
</form> |
|
|
|
|
</div>{% endblock %} |
|
|
|
|
</div>{% endblock %}{% block 'extra_scripts' %}{% load static %} |
|
|
|
|
<script> |
|
|
|
|
var chrono = document.getElementsByTagName('time')[0]; |
|
|
|
|
var sec = 0; |
|
|
|
|
var min = 0; |
|
|
|
|
var t; |
|
|
|
|
|
|
|
|
|
function tick(){ |
|
|
|
|
sec++; |
|
|
|
|
if (sec >= 60) { |
|
|
|
|
sec = 0; |
|
|
|
|
min++; |
|
|
|
|
if (min >= 60) { |
|
|
|
|
min = 0; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
function add() { |
|
|
|
|
tick(); |
|
|
|
|
chrono.textContent = (min > 9 ? min : "0" + min) |
|
|
|
|
+ "m " + (sec > 9 ? sec : "0" + sec) +"s"; |
|
|
|
|
timer(); |
|
|
|
|
} |
|
|
|
|
function timer() { |
|
|
|
|
t = setTimeout(add, 1000); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
timer(); |
|
|
|
|
|
|
|
|
|
$(document).ready(function() { |
|
|
|
|
timer; |
|
|
|
|
}); |
|
|
|
|
</script> |
|
|
|
|
{% endblock %} |
|
|
|
|
|