-
Notifications
You must be signed in to change notification settings - Fork 0
/
Command_Result_Page.html
212 lines (187 loc) · 6.77 KB
/
Command_Result_Page.html
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
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Command Result</title>
<style>
body, html {
margin: 0;
padding: 0;
height: 100%;
overflow: hidden;
background-color: #000;
color: #f00; /* Change text color to red */
font-family: 'Courier New', monospace;
}
#matrix-rain {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
z-index: 1;
}
#terminal {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
overflow-y: auto;
padding: 20px;
box-sizing: border-box;
z-index: 2;
}
#command-output {
white-space: pre-wrap;
word-wrap: break-word;
animation: glow 1s infinite alternate; /* Add glow animation */
}
#input-line {
display: flex;
align-items: center;
margin-top: 10px;
}
.prompt {
color: #f00; /* Change prompt color to red */
margin-right: 5px;
animation: glow 1s infinite alternate; /* Add glow animation */
}
#input {
background-color: transparent;
border: none;
color: #f00; /* Change input text color to red */
font-family: 'Courier New', monospace;
font-size: 16px;
flex-grow: 1;
caret-color: #f00; /* Change caret color to red */
outline: none;
animation: glow 1s infinite alternate; /* Add glow animation */
}
::-webkit-scrollbar {
width: 10px;
}
::-webkit-scrollbar-track {
background: #000;
}
::-webkit-scrollbar-thumb {
background: #f00; /* Change scrollbar thumb color to red */
border: 2px solid #000;
}
@keyframes glow {
0% { text-shadow: 0 0 5px #f00; }
100% { text-shadow: 0 0 20px #f00; }
}
</style>
</head>
<body>
<canvas id="matrix-rain"></canvas>
<div id="terminal">
<div id="command-output"></div>
<div id="input-line">
<span class="prompt">>>></span>
<span id="input" contenteditable="true" spellcheck="false"></span>
</div>
</div>
<script>
document.addEventListener('DOMContentLoaded', function() {
const input = document.getElementById('input');
const commandOutput = document.getElementById('command-output');
const canvas = document.getElementById('matrix-rain');
const ctx = canvas.getContext('2d');
// Set canvas size
canvas.width = window.innerWidth;
canvas.height = window.innerHeight;
// Matrix rain effect
const letters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ123456789@#$%^&*()*&^%';
const fontSize = 10;
const columns = canvas.width / fontSize;
const drops = [];
for (let i = 0; i < columns; i++) {
drops[i] = 1;
}
function draw() {
ctx.fillStyle = 'rgba(0, 0, 0, 0.05)';
ctx.fillRect(0, 0, canvas.width, canvas.height);
ctx.fillStyle = '#0f0'; // Matrix rain color remains green
ctx.font = fontSize + 'px monospace';
for (let i = 0; i < drops.length; i++) {
const text = letters[Math.floor(Math.random() * letters.length)];
ctx.fillText(text, i * fontSize, drops[i] * fontSize);
if (drops[i] * fontSize > canvas.height && Math.random() > 0.975) {
drops[i] = 0;
}
drops[i]++;
}
}
// Start matrix rain immediately
setInterval(draw, 33);
// Handle input
input.addEventListener('keydown', function(e) {
if (e.key === 'Enter') {
e.preventDefault();
const command = this.textContent.trim();
processCommand(command);
this.textContent = '';
}
});
function escapeHTML(str) {
return str.replace(/[&<>"']/g, function(match) {
const escapeMap = {
'&': '&',
'<': '<',
'>': '>',
'"': '"',
"'": '''
};
return escapeMap[match];
});
}
function processCommand(command) {
const safeCommand = escapeHTML(command);
commandOutput.innerHTML += `>>>> ${safeCommand}\n`;
switch(command.toLowerCase()) {
case 'stop':
window.location.href = 'index.html';
break;
case 'help':
commandOutput.innerHTML += 'Available commands: help, about, skills, projects, contact, clear, stop, glory to mankind, neonnexus\n';
break;
case 'about':
commandOutput.innerHTML += 'I am a technomancer, weaving code and magic into digital reality.\n';
break;
case 'skills':
commandOutput.innerHTML += 'My skills include: JavaScript, Python, Quantum Computing, Linux, Operating systems, Rust, loyalty Marketing, Data Structures ' +
' Algorithms, Github/Github Actions, Automation, PQC, Cybersecurity, Encryption, RSA security, Fine Tuning, LLMs, Embedded systems, Network Engineering, Networking Design' +
'IOT, Logistics Management , Supply Chain Management, Software Development, Software Architecture, Customer Service, Retail, Sales, Applied Research, Cloud dev, ' +
'Computational Physics, Writing, Presentation skills, Digital transformation, IT, Communication, SOLID Software Dev, ML Engineering, Applied Quantum computing, Operations research' +
'Debate\n';
break;
case 'projects':
commandOutput.innerHTML += 'Some of my projects: QSolvers, Emergent Neural Nets, Math Programming \n';
break;
case 'contact':
commandOutput.innerHTML += 'Contact me at: [email protected]\n';
break;
case 'clear':
commandOutput.innerHTML = '';
break;
case 'glory to mankind':
window.location.href = 'YoRHa_Matrix.html';
break;
case 'neonnexus':
window.location.href = 'Neon_Nexus.html';
break;
default:
commandOutput.innerHTML += `Command not recognized: ${safeCommand}\n`;
}
// Scroll to the bottom of the output
commandOutput.scrollTop = commandOutput.scrollHeight;
}
// Focus on input when the page loads
input.focus();
});
</script>
</body>
</html>