-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathscript.js
More file actions
63 lines (58 loc) · 2.05 KB
/
Copy pathscript.js
File metadata and controls
63 lines (58 loc) · 2.05 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
// Light/Dark Mode Toggle
document.getElementById("theme-toggle").addEventListener("click", () => {
document.body.classList.toggle("dark");
const isDark = document.body.classList.contains("dark");
document.getElementById("theme-toggle").textContent = isDark
? "☀️ Light Mode"
: "🌙 Dark Mode";
});
// Project Data
const projects = [
{
title: "Heap Task Manager (C++)",
summary: "Priority-based task queue using heap logic in C++. Lightweight and CLI-driven.",
github: "https://github.com/ssaauudd22/heap-up-task-manager.git"
},
{
title: "Lottery Inventory System (Java)",
summary: "Simulates inventory and ticket tracking using OOP, classes, and dynamic reports.",
github: "https://github.com/ssaauudd22/Lottery-Inventory-System.git"
},
{
title: "To-Do Web App (FLASK | Python, HTML, CSS)",
summary: "A simple to-do list app with localStorage, task status, and priority tags.",
github: "https://github.com/ssaauudd22/To-Do-App/tree/main"
},
{
title: "Portfolio Website",
summary: "This very portfolio, built with responsive design and interactivity.",
github: "https://github.com/ssaauudd22/Web-Portfolio"
},
{
title: "Power Grid Simulation",
summary: "A simulation that mimics real-time monitoring of power grid nodes - with anomaly detection, logging, and graphs.",
github: "https://github.com/ssaauudd22/powerNode.git"
}
];
// Render Projects
const container = document.getElementById("projects-container");
projects.forEach(project => {
const card = document.createElement("div");
card.className = "project-card";
card.innerHTML = `
<h3>${project.title}</h3>
<p>${project.summary}</p>
<a href="${project.github}" target="_blank">GitHub →</a>
`;
container.appendChild(card);
});
// Header minimize on scroll
const header = document.querySelector("header");
window.addEventListener("scroll", () => {
const scrollTop = window.scrollY;
if (scrollTop > 50) {
header.classList.add("header-small");
} else {
header.classList.remove("header-small");
}
});