File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1212 color : whitesmoke;
1313 overflow : hidden;
1414 font-size : 25px ;
15-
1615}
1716
1817# shellinput {
2524
2625# shellinput : focus {
2726 outline : none;
27+ }
28+
29+ # uname-hname {
30+ color : whitesmoke;
31+ font-size : 25px ;
2832}
Original file line number Diff line number Diff line change 1111</ head >
1212< body >
1313 < div id ="terminal ">
14- < span > username@hostname: </ span > < input type ="text " name ="shell " id ="shellinput " onKeyPress ="detectEnter(event, this) " >
14+ < span id =" uname-hname " > </ span > < input type ="text " name ="shell " id ="shellinput " onKeyPress ="detectEnter(event, this) " >
1515 </ div >
1616</ body >
1717</ html >
Original file line number Diff line number Diff line change 11console . log ( "Welcome to the shell!" )
22window . onload = function ( ) {
3+ this . username = "username"
4+ this . hostname = "hostname"
35 document . getElementById ( "shellinput" ) . value = "" ;
6+ document . getElementById ( "uname-hname" ) . innerText = `${ username } @${ hostname } `
47}
58
69const commands = [
You can’t perform that action at this time.
0 commit comments