diff --git a/poetry.lock b/poetry.lock index 5fba1b224..f7d90f86f 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,4 +1,4 @@ -# This file is automatically @generated by Poetry 2.3.1 and should not be changed by hand. +# This file is automatically @generated by Poetry 2.4.3 and should not be changed by hand. [[package]] name = "asgiref" @@ -684,8 +684,8 @@ files = [ google-auth = ">=2.14.1,<3.0.dev0" googleapis-common-protos = ">=1.56.2,<2.0.dev0" proto-plus = [ - {version = ">=1.25.0,<2.0.0.dev0", markers = "python_version >= \"3.13\""}, {version = ">=1.22.3,<2.0.0.dev0", markers = "python_version < \"3.13\""}, + {version = ">=1.25.0,<2.0.0.dev0", markers = "python_version >= \"3.13\""}, ] protobuf = ">=3.19.5,<3.20.0 || >3.20.0,<3.20.1 || >3.20.1,<4.21.0 || >4.21.0,<4.21.1 || >4.21.1,<4.21.2 || >4.21.2,<4.21.3 || >4.21.3,<4.21.4 || >4.21.4,<4.21.5 || >4.21.5,<6.0.0.dev0" requests = ">=2.18.0,<3.0.0.dev0" @@ -1317,6 +1317,24 @@ files = [ {file = "pycparser-2.22.tar.gz", hash = "sha256:491c8be9c040f5390f5bf44a5b07752bd07f56edf992381b05c701439eec10f6"}, ] +[[package]] +name = "pyjwt" +version = "2.13.0" +description = "JSON Web Token implementation in Python" +optional = false +python-versions = ">=3.9" +groups = ["main"] +files = [ + {file = "pyjwt-2.13.0-py3-none-any.whl", hash = "sha256:66adcc2aff09b3f1bbd95fc1e1577df8ac8723c978552fd43304c8a290ac5728"}, + {file = "pyjwt-2.13.0.tar.gz", hash = "sha256:41571c89ca91598c79e8ef18a2d07367d4810fbbd6f637794879baf1b7703423"}, +] + +[package.dependencies] +typing_extensions = {version = ">=4.0", markers = "python_version < \"3.11\""} + +[package.extras] +crypto = ["cryptography (>=3.4.0)"] + [[package]] name = "pyopenssl" version = "25.0.0" @@ -1951,4 +1969,4 @@ brotli = ["brotli"] [metadata] lock-version = "2.1" python-versions = "^3.10" -content-hash = "637c808ca7e717a872f26b077fadf360e774dccb1b2944f66ee1c8ce2c5ec656" +content-hash = "f30ab3336495c6158fd82fe6a6402f1ed4a04984b77e75c99c55058d0e8a812a" diff --git a/poetry.toml b/poetry.toml index 084377a03..3b549d6c8 100644 --- a/poetry.toml +++ b/poetry.toml @@ -1,2 +1,2 @@ [virtualenvs] -create = false +create = true diff --git a/pyproject.toml b/pyproject.toml index fde77eafb..e217e82b2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -39,6 +39,7 @@ django-redis = "^5.4.0" redis = "^6.4.0" mysqlclient = "^2.2.4" psutil = "^7.1.3" +pyjwt = "^2.13.0" [tool.poetry.group.dev.dependencies] djlint = "^1.34.1" diff --git a/web/settings.py b/web/settings.py index 4ddcae8bb..e3cbcdc60 100644 --- a/web/settings.py +++ b/web/settings.py @@ -142,6 +142,8 @@ "channels", "allauth", "allauth.account", + "allauth.socialaccount", + "allauth.socialaccount.providers.google", "captcha", "markdownx", "web", diff --git a/web/templates/account/login.html b/web/templates/account/login.html index 38ac4da1e..4e7028d98 100644 --- a/web/templates/account/login.html +++ b/web/templates/account/login.html @@ -1,7 +1,7 @@ {% extends "allauth/layouts/base.html" %} {% load static %} -{% load account %} +{% load account socialaccount %} {% block extra_head %} {{ block.super }} @@ -87,6 +87,27 @@

+
+
+
+
+
+ + Or continue with + +
+
+ + + + Continue with Google + + + +

Don't have an account? @@ -249,6 +251,27 @@

+
+
+
+
+
+ + Or continue with + +
+
+ +
+ + Continue with Google + + + + {% endblock content %} diff --git a/web/templates/base.html b/web/templates/base.html index 7afa700a9..850da8790 100644 --- a/web/templates/base.html +++ b/web/templates/base.html @@ -855,33 +855,70 @@ - {% if messages %} -
- {% for message in messages %} -
-
- {% if message.tags == 'error' %} - - {% elif message.tags == 'success' %} - - {% elif message.tags == 'warning' %} - - {% else %} - - {% endif %} -
-

{{ message }}

- -
- {% endfor %} + + + +{% if messages %} +
+ {% for message in messages %} +
+ +
+ {% if message.tags == 'error' %} + + {% elif message.tags == 'success' %} + + {% elif message.tags == 'warning' %} + + {% else %} + + {% endif %} +
+ +

{{ message }}

+ + +
- {% endif %} - {% block extra_body %} - {% block content %} - {% endblock content %} - {% endblock extra_body %} + {% endfor %} +
+{% endif %} + + + + + +{% block extra_body %} + {% block content %} + {% endblock content %} +{% endblock extra_body %} +