Skip to content

Commit 9604043

Browse files
Merge pull request steam-bell-92#1502 from Alvi24-hub/main
Fix: Overlapping Features(Bookmarked Projects and Recently Opened Projects) removed
2 parents d1987ad + b4c010a commit 9604043

1 file changed

Lines changed: 5 additions & 95 deletions

File tree

web-app/index.html

Lines changed: 5 additions & 95 deletions
Original file line numberDiff line numberDiff line change
@@ -433,58 +433,19 @@ <h3 class="timeline-title">Share</h3>
433433
</div>
434434
</div>
435435
</section>
436-
437-
<!-- Bookmarked Projects Section -->
438-
<section class="projects-section" id="bookmarkedProjectsSection">
436+
437+
<!-- Recently Viewed Section -->
438+
<section class="projects-section" id="recentlyViewedSection">
439439
<div class="container">
440440
<div class="section-header">
441441
<h2 class="section-heading">
442-
⭐ Bookmarked Projects
443-
<span id="bookmarkCountBadge"></span>
442+
Recently Viewed
444443
</h2>
445444
</div>
446-
447-
<div class="projects-grid" id="bookmarkedProjectsGrid"></div>
448-
449-
<div id="noBookmarksMessage" class="empty-state">
450-
<p>No bookmarked projects yet.</p>
451-
<p class="empty-state-hint">
452-
Click the ⭐ icon on any project to bookmark it.
453-
</p>
454-
</div>
445+
<div class="projects-grid" id="recentlyViewedGrid"></div>
455446
</div>
456447
</section>
457448

458-
<!-- Recently Viewed Section -->
459-
<div class="section-header">
460-
461-
<h2 class="section-heading">
462-
🕒 Recently Opened Projects
463-
<span id="historyCount"></span>
464-
</h2>
465-
466-
<div>
467-
468-
<input
469-
id="historySearch"
470-
type="text"
471-
placeholder="Search history...">
472-
473-
<button id="clearHistoryBtn">
474-
Clear History
475-
</button>
476-
477-
</div>
478-
479-
</div>
480-
<div class="container">
481-
<div class="section-header">
482-
<h2 class="section-heading">
483-
Recently Viewed
484-
</h2>
485-
</div>
486-
<div class="projects-grid" id="recentlyViewedGrid"></div>
487-
</div>
488449
</section>
489450

490451
<!-- Projects Section -->
@@ -760,16 +721,6 @@ <h3>Stay Updated</h3>
760721
(function () {
761722
const projectsGrid = document.getElementById("projectsGrid");
762723
if (!projectsGrid) return;
763-
764-
const bookmarkedGrid =
765-
document.getElementById("bookmarkedProjectsGrid");
766-
767-
const bookmarkBadge =
768-
document.getElementById("bookmarkCountBadge");
769-
770-
const noBookmarks =
771-
document.getElementById("noBookmarksMessage");
772-
773724
// ALL projects from your js/projects/ folder
774725
const projectsData = [
775726
// GAMES (20+)
@@ -1147,46 +1098,6 @@ <h3>Stay Updated</h3>
11471098
localStorage.setItem("favorites", JSON.stringify(favorites));
11481099
}
11491100

1150-
function renderBookmarkedProjects() {
1151-
1152-
if (!bookmarkedGrid) return;
1153-
1154-
bookmarkedGrid.innerHTML = "";
1155-
1156-
const favs =
1157-
JSON.parse(localStorage.getItem("favorites") || "[]");
1158-
1159-
bookmarkBadge.textContent =
1160-
"(" + favs.length + ")";
1161-
1162-
if (favs.length === 0) {
1163-
1164-
noBookmarks.style.display = "block";
1165-
1166-
return;
1167-
}
1168-
1169-
noBookmarks.style.display = "none";
1170-
1171-
favs.forEach(projectId => {
1172-
1173-
const card =
1174-
document.querySelector(
1175-
`.project-card[data-project="${projectId}"]`
1176-
);
1177-
1178-
if(card){
1179-
1180-
bookmarkedGrid.appendChild(
1181-
card.cloneNode(true)
1182-
);
1183-
1184-
}
1185-
1186-
});
1187-
1188-
}
1189-
11901101
projectsData.forEach((proj) => {
11911102
const card = document.createElement("div");
11921103
card.className = "project-card";
@@ -1293,7 +1204,6 @@ <h3>${proj.title}</h3>
12931204
console.log(
12941205
`✅ Loaded ${total} projects: ${games} games, ${math} math, ${utils} utilities`
12951206
);
1296-
renderBookmarkedProjects();
12971207

12981208
// Wire up buttons
12991209
setTimeout(() => {

0 commit comments

Comments
 (0)