diff --git a/.gitignore b/.gitignore index e43b0f98..75d570df 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,26 @@ .DS_Store + +# Python +__pycache__/ +*.py[cod] +.pytest_cache/ +.coverage +.venv/ +backend/venv/ + +# Environment files +.env +backend/.env + +# Node / frontend +node_modules/ +front-end/node_modules/ +playwright-report/ +test-results/ + +# Database data +db/pg_data/ + +# Editor / OS files +.idea/ +.vscode/ diff --git a/front-end/views/hashtag.mjs b/front-end/views/hashtag.mjs index 7b7e9969..1ce38dd5 100644 --- a/front-end/views/hashtag.mjs +++ b/front-end/views/hashtag.mjs @@ -35,8 +35,8 @@ function hashtagView(hashtag) { createLogin ); document - .querySelector("[data-action='login']") - ?.addEventListener("click", handleLogin); + .querySelector("[data-form='login']") + ?.addEventListener("submit", handleLogin); renderOne( state.currentHashtag, diff --git a/front-end/views/profile.mjs b/front-end/views/profile.mjs index dd2b92af..31139a9f 100644 --- a/front-end/views/profile.mjs +++ b/front-end/views/profile.mjs @@ -39,8 +39,8 @@ function profileView(username) { createLogin ); document - .querySelector("[data-action='login']") - ?.addEventListener("click", handleLogin); + .querySelector("[data-form='login']") + ?.addEventListener("submit", handleLogin); const profileData = state.profiles.find((p) => p.username === username); if (profileData) {