add more code, fix pre width
This commit is contained in:
parent
a25cae0e76
commit
42f1e93c29
|
@ -17,6 +17,7 @@ code {
|
|||
}
|
||||
|
||||
pre {
|
||||
min-width: 42em;
|
||||
color: #5cb85c;
|
||||
text-align: left;
|
||||
line-height: 1.2em;
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
<link rel="stylesheet" href="css/style.css">
|
||||
</head>
|
||||
<body>
|
||||
<h1>telnet 10.r3.at</h1>
|
||||
<div>
|
||||
<pre><code>$ telnet 10.r3.at</code></pre>
|
||||
<pre><code class="output">...loading...</code></pre>
|
||||
<pre><code class="output2"></code></pre>
|
||||
<pre><code class="output3"></code></pre>
|
||||
|
|
|
@ -21,7 +21,7 @@ function overwriteLine(element, text, delay) {
|
|||
function() {
|
||||
element.text(text + '\n');
|
||||
//console.log(text);
|
||||
window.scrollTo(0,document.body.scrollHeight);
|
||||
//window.scrollTo(0,document.body.scrollHeight);
|
||||
},
|
||||
globalDelay
|
||||
)
|
||||
|
@ -72,6 +72,9 @@ $(function () {
|
|||
var $output = $('.output');
|
||||
$output.text('');
|
||||
|
||||
printLine($output, 'Trying 2a02:3e0:4000:1::56...');
|
||||
printLine($output, 'Connected to entrance.realraum.at.');
|
||||
printLine($output, 'Escape character is \'^]\'.');
|
||||
|
||||
printLine($output, '');
|
||||
printLine($output, '');
|
||||
|
@ -114,7 +117,8 @@ $(function () {
|
|||
setTimeout(
|
||||
function() {
|
||||
$body.on('keypress', function (event) {
|
||||
console.log(event.which);
|
||||
globalDelay = 0;
|
||||
//console.log(event.which);
|
||||
if (event.which === 121 && input === '') {
|
||||
input += 'y';
|
||||
}
|
||||
|
@ -130,11 +134,9 @@ $(function () {
|
|||
if (event.which === 111 && input === 'n') {
|
||||
input += 'o';
|
||||
}
|
||||
$output.text(' are you coming? ' + input + '_\n');
|
||||
window.scrollTo(0,document.body.scrollHeight);
|
||||
overwriteLine($output, ' are you coming? ' + input + '_');
|
||||
if (event.which === 13 && (input === 'y' || input === 'yes')) {
|
||||
$body.off('keypress');
|
||||
globalDelay = 0;
|
||||
$output = $('.output4');
|
||||
printLine($output, ' Great! We\'ll see you at the party then.');
|
||||
|
||||
|
|
Loading…
Reference in New Issue