Skip to content

Commit

Permalink
Starting with styles in main pages
Browse files Browse the repository at this point in the history
  • Loading branch information
frasanz committed Feb 4, 2025
1 parent f8bf8a2 commit d769ca7
Show file tree
Hide file tree
Showing 3 changed files with 68 additions and 2 deletions.
7 changes: 6 additions & 1 deletion frontend/static/css/main.css
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* CSS of the main page */
/* CSS of the main page, (login, etc) */
body, html {
font-family: 'Open Sans';
overflow: hidden;
Expand Down Expand Up @@ -48,4 +48,9 @@ button {
.small-img{
width: 10px !important;
margin: 1em !important;
}
label{
display: block !important;
font-size: 0.8em !important;

}
2 changes: 1 addition & 1 deletion frontend/static/js/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -599,7 +599,7 @@ $(document).ready(function () {
});

//const mapBox = L.tileLayer('https://api.mapbox.com/styles/v1/frasanz/cm2cdt26700t301pghdcsc7b0/tiles/256/{z}/{x}/{y}?access_token=pk.eyJ1IjoiZnJhc2FueiIsImEiOiJjbTF4bHE2MHIwdzRmMmpxd3g1cGZkbjR3In0.6B49yUgKNVhYOCy7ibw5ww', {
const mapBox = L.tileLayer('https://api.mapbox.com/styles/v1/germangil/cm2x26xaf00ns01qw9jooe6wm/tiles/256/{z}/{x}/{y}?access_token=pk.eyJ1IjoiZ2VybWFuZ2lsIiwiYSI6ImNsbXQxbDBoNTAwbjkybGxvcngxNDBhYzgifQ.kcRn3hE1wUpA1KpdxiG23g',{
const mapBox = L.tileLayer('https://api.mapbox.com/styles/v1/germangil/cm2x26xaf00ns01qw9jooe6wm/tiles/256/{z}/{x}/{y}?access_token=pk.eyJ1IjoiZnJhc2FueiIsImEiOiJjbTF4bHE2MHIwdzRmMmpxd3g1cGZkbjR3In0.6B49yUgKNVhYOCy7ibw5ww',{
maxZoom: 18,
tileSize: 256,
attribution: '&copy; <a href="https://www.mapbox.com/about/maps/">Mapbox</a> &copy; <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors'
Expand Down
61 changes: 61 additions & 0 deletions templates/account/login.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
{% extends "account/base_entrance.html" %}
{% load i18n %}
{% load allauth account %}
{% block head_title %}
{% trans "Welcome back!" %}
{% endblock head_title %}
{% block content %}
{% element h1 %}
{% trans "Welcome back!" %}
{% endelement %}
{% if not SOCIALACCOUNT_ONLY %}
{% setvar link %}
<a href="{{ signup_url }}">
{% endsetvar %}
{% setvar end_link %}
</a>
{% endsetvar %}
{% element p %}
{% blocktranslate %}If you have not created an account yet, then please {{ link }}sign up{{ end_link }} first.{% endblocktranslate %}
{% endelement %}
{% url 'account_login' as login_url %}
{% element form form=form method="post" action=login_url tags="entrance,login" %}
{% slot body %}
{% csrf_token %}
{% element fields form=form unlabeled=True %}
{% endelement %}
{{ redirect_field }}
{% endslot %}
{% slot actions %}
{% element button type="submit" tags="prominent,login" %}
{% trans "Sign In" %}
{% endelement %}
{% endslot %}
{% endelement %}
{% endif %}
{% if LOGIN_BY_CODE_ENABLED or PASSKEY_LOGIN_ENABLED %}
{% element hr %}
{% endelement %}
{% element button_group vertical=True %}
{% if PASSKEY_LOGIN_ENABLED %}
{% element button type="submit" form="mfa_login" id="passkey_login" tags="prominent,login,outline,primary" %}
{% trans "Sign in with a passkey" %}
{% endelement %}
{% endif %}
{% if LOGIN_BY_CODE_ENABLED %}
{% element button href=request_login_code_url tags="prominent,login,outline,primary" %}
{% trans "Mail me a sign-in code" %}
{% endelement %}
{% endif %}
{% endelement %}
{% endif %}
{% if SOCIALACCOUNT_ENABLED %}
{% include "socialaccount/snippets/login.html" with page_layout="entrance" %}
{% endif %}
{% endblock content %}
{% block extra_body %}
{{ block.super }}
{% if PASSKEY_LOGIN_ENABLED %}
{% include "mfa/webauthn/snippets/login_script.html" with button_id="passkey_login" %}
{% endif %}
{% endblock %}

0 comments on commit d769ca7

Please sign in to comment.