mirror of
https://github.com/wavetermdev/xterm.js.git
synced 2026-08-05 13:43:48 -07:00
Started new example page
This commit is contained in:
+12
-2
@@ -1,5 +1,15 @@
|
||||
<!doctype html>
|
||||
<html>
|
||||
<title>xterm.js demo</title>
|
||||
<script src="../src/xterm.js"></script>
|
||||
<head>
|
||||
<title>xterm.js demo</title>
|
||||
<link rel="stylesheet" href="style.css" />
|
||||
<script src="../src/xterm.js"></script>
|
||||
<script src="main.js" defer></script>
|
||||
</head>
|
||||
<body>
|
||||
<h1>
|
||||
xterm.js: xterm, in the browser
|
||||
</h1>
|
||||
<div id="terminal-container"></div>
|
||||
</body>
|
||||
</html>
|
||||
@@ -0,0 +1,8 @@
|
||||
var terminalContainer = document.getElementById('terminal-container'),
|
||||
term = new Terminal({geometry: [60, 37]});
|
||||
|
||||
term.open(terminalContainer);
|
||||
|
||||
term.on('data', function (data) {
|
||||
term.write(data);
|
||||
});
|
||||
@@ -0,0 +1,17 @@
|
||||
body {
|
||||
font-family: helvetica, sans-serif, arial;
|
||||
font-size: 1em;
|
||||
color: #111;
|
||||
}
|
||||
|
||||
h1 {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
#terminal-container {
|
||||
background-color: #111;
|
||||
color: #fafafa;
|
||||
width: 960px;
|
||||
height: 600px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
Reference in New Issue
Block a user