blob: 000f3665f3da0fbd4399ebe3acdae9c35b735751 (
plain)
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
|
<!DOCTYPE html>
<html>
<head>
<title>TaSTT</title>
<script src="https://code.jquery.com/jquery-3.6.3.min.js"></script>
<link rel="stylesheet"
href="https://fonts.googleapis.com/css?family=Noto+Sans+Mono&display=swap">
</head>
<style>
body {
font-family: 'Noto Sans Mono', monospace;
font-size: 96px;
font-weight: 3200;
color: #000;
}
#transcript {
color: #89CFF0;
-webkit-text-stroke: 3.0px #000;
}
</style>
<body>
<div id="transcript"></div>
<script>
function scrollToBottom() {
window.scrollTo(0,document.body.scrollHeight);
}
function getTranscript() {
$.ajax({
url: 'http://localhost:%PORT%/api/transcript',
method: 'GET',
dataType: 'json',
success: function(data) {
var transcript = data.transcript;
$('#transcript').html(transcript);
$('#transcript').css("background-color", "#00000080");
},
error: function(jqXHR, textStatus, errorThrown) {
console.error('Error getting transcript: ', textStatus, errorThrown);
}
});
scrollToBottom();
}
setInterval(getTranscript, /*interval_ms=*/100);
</script>
</body>
</html>
|