-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathscript.js
More file actions
23 lines (22 loc) · 935 Bytes
/
script.js
File metadata and controls
23 lines (22 loc) · 935 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/**
* script.js — LearnSphere Landing Page Scripts
*
* Previously contained alert() calls on CTA buttons that blocked navigation:
*
* button.addEventListener("click", () => {
* alert(`You clicked on ${button.innerText}!`); // ← blocks <a> href!
* });
*
* This conflicted with <a> tags inside buttons. When a user clicked
* "Learners", an alert fired but the href navigation was suppressed.
*
* FIX: Removed the conflicting alert() event listeners entirely.
* Navigation now works purely through <a> tags inside .cta buttons.
*
* Login/Signup buttons also had alert() listeners that fired before the
* browser followed the <a href="log/login.html"> link — these are removed.
*
* The hamburger navbar logic has been extracted to navbar.js (shared).
*/
// No CTA alert listeners — they conflicted with href navigation.
// Navigation is handled by <a> tags inside the .cta and .login/.signup buttons.