-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.html
More file actions
143 lines (143 loc) · 3.48 KB
/
Copy pathindex.html
File metadata and controls
143 lines (143 loc) · 3.48 KB
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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>ATM CLI</title>
<script type="text/javascript" src="script.js"></script>
<style type="text/css">
body{
background: #ddd;
padding: 0 20px 0;
margin: 0;
position: relative;
height: 100%;
}
.machine{
background: #666;
margin: 0 auto;
width: 640px;
position: absolute;
height: 90vh;
top: 10vh;
left: 50%;
transform: translateX(-50%);
box-sizing: border-box;
padding: 20px;
}
h1{
background: #fff;
font-family: sans-serif;
display: inline-block;
font-size: 50px;
color: #00a1ff;
position: absolute;
left: 50%;
transform: translate(-50%, -100%);
padding: 10px;
border: 3px solid #3a3a3a;
}
.screen{
min-width: 100%;
min-height: 321px;
background: #00009d;
margin: 55px 0 0;
}
input#command{
width: 100%;
margin-top: 20px;
border: 1px solid #ddd;
font-size: 18px;
line-height: 18px;
height: 40px;
box-sizing: border-box;
padding: 10px 10px;
outline: none;
}
input#state{
display: none;
}
input#userlogin{
display: none;
}
.prompt{
color: #c7c7c7;
font-family: sans-serif;
padding: 20px;
box-sizing: border-box;
}
.prompt.menu, .prompt.exit{
display: none;
}
.error, .success{
display: none;
color: #c7c7c7;
font-family: sans-serif;
padding: 20px;
box-sizing: border-box;
}
</style>
</head>
<body>
<div class="machine">
<h1>ATM CLI</h1>
<div class="screen">
<div class="prompt home">
Welcome to ATM CLI
<br /><br />
Type "Login [Your Username]" to begin
</div>
<div class="prompt exit">
Goodbye!
</div>
<div class="prompt menu">
Hello, <span class="menu-username"></span><br /><br />
Your balance is $<span class="menu-balance">0</span><br /><br />
Menu:<br />
- Type "Deposit [Amount]" to save money<br />
- Type "Withdraw [Amount]" to take out money<br />
- Type "Transfer [Username] [Amount]" to send money<br />
- Type "Logout" to start from the beginning<br />
</div>
<div class="error not-found">
---
<br /><br />
ERROR! "<span class="error-message"></span>" command not found, please try again
</div>
<div class="error no-username">
---
<br /><br />
ERROR! Insert your username to login
</div>
<div class="error no-balance">
---
<br /><br />
ERROR! Your balance is not enough
</div>
<div class="error wrong-amount">
---
<br /><br />
ERROR! Amount is not a number
</div>
<div class="success saved">
---
<br /><br />
SUCCESS! $<span class="added-amount"></span> added to your balance
</div>
<div class="success withdrawn">
---
<br /><br />
SUCCESS! $<span class="withdrawn-amount"></span> withdrawn from your balance
</div>
<div class="success transfer">
---
<br /><br />
SUCCESS! $<span class="transfer-amount"></span> transfered to <span class="transfer-target"></span> account
</div>
</div>
<input type="text" id="command" name="command" onkeydown="getCommand(event)" placeholder="Type command here and hit enter..." autofocus />
<input type="text" id="state" name="state" value="1" readonly />
<input type="text" id="userlogin" name="userlogin" value="" readonly />
</div>
</body>
</html>