From 48c61a1dfd485b8c7ab5058ac264696f9f0bb346 Mon Sep 17 00:00:00 2001 From: south-dakota Date: Mon, 12 Jan 2026 13:21:45 -0500 Subject: [PATCH] Party mode returns --- frontend/src/App.tsx | 18 ++++++++++++++++++ frontend/src/index.scss | 18 +++++++++++++++++- 2 files changed, 35 insertions(+), 1 deletion(-) diff --git a/frontend/src/App.tsx b/frontend/src/App.tsx index 7227efc..ff40a3b 100644 --- a/frontend/src/App.tsx +++ b/frontend/src/App.tsx @@ -25,6 +25,24 @@ const AboutUs = lazy(() => import('./components/AboutUs/AboutUs')); // import Register from './components/Forms/Register'; // import ComingSoon from './components/Home/ComingSoon'; +let partyMode: boolean = false; +const konamiCode = ['ArrowUp', 'ArrowUp', 'ArrowDown', 'ArrowDown', 'ArrowLeft', 'ArrowRight', 'ArrowLeft', 'ArrowRight', 'b', 'a', 'Enter']; +let pressedKeys: string[] = []; + +document.addEventListener('keydown', (event) => { + pressedKeys.push(event.key); + pressedKeys = pressedKeys.slice(-konamiCode.length); + if (JSON.stringify(pressedKeys) === JSON.stringify(konamiCode)) { + partyMode = !partyMode; + const all = document.querySelectorAll('*'); + all.forEach(element => { + if (partyMode) {element.classList.add('party-mode');} + else {element.classList.remove('party-mode');} + }) + } +}); + + export default function App() { const { isAuthenticated, user, setAuth } = useAuth(); diff --git a/frontend/src/index.scss b/frontend/src/index.scss index 21475f8..9ed4498 100644 --- a/frontend/src/index.scss +++ b/frontend/src/index.scss @@ -2,7 +2,6 @@ box-sizing: border-box; margin: 0; padding: 0; - overflow: hidden; } html, body { @@ -21,4 +20,21 @@ button { display: flex; flex-direction: column; position: relative; +} + +.party-mode { + width: 100px; + height: 100px; + animation: spin 3.4s linear infinite; +} + +@keyframes spin { + from { + transform: rotate(0deg); + filter: hue-rotate(0deg); + } + to { + transform: rotate(360deg); + filter: hue-rotate(360deg); + } } \ No newline at end of file