Skip to content

Commit 1a32fc3

Browse files
authored
Merge pull request #84 from Scratch-Coding-Hut/revert-83-real-popups
Revert "Real Popups"
2 parents 5a24fbf + eb4c8a5 commit 1a32fc3

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

src/account.html

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html>
1+
<!DOCTYPE html>
22
<html lang="en">
33

44
<head>
@@ -171,7 +171,13 @@
171171
function registerScratchAuth() {
172172
const messageBox = document.getElementById("scratchMessage");
173173
const redirectLocation = btoa(window.location.href);
174-
javascript("window.open("https://scratch-id.onrender.com/?redirect=${redirectLocation}&name=Scratch%20Coding%20Hut", "popupWindow", "width=600,height=400,resizable=yes,scrollbars=yes");")
174+
const authUrl = `https://scratch-id.onrender.com/?redirect=${redirectLocation}&name=Scratch%20Coding%20Hut`;
175+
176+
messageBox.style.color = "green";
177+
messageBox.textContent = "Redirecting to ScratchID... Follow the steps there.";
178+
setTimeout(() => {
179+
window.location.href = authUrl;
180+
}, 2000);
175181
}
176182

177183
function logout() {

0 commit comments

Comments
 (0)