Skip to content

Commit 4e8ffc1

Browse files
committed
Update auth forms with Bulma CSS
1 parent 8f95c9c commit 4e8ffc1

14 files changed

+60
-38
lines changed

Caddyfile

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1-
example.com
1+
example.com {
2+
reverse_proxy 127.0.0.1:1111
3+
}
24

3-
reverse_proxy 127.0.0.1:1111
5+
example2.com {
6+
reverse_proxy 127.0.0.1:1122
7+
}

README.MD

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,22 @@
11
# Django + Docker Template
2+
23
<img src=https://raw.githubusercontent.com/matacoder/matacoder/main/django-docker-sea.png>
34

45
This is a magic repository for everyone who wants to start developing and do not want to worry about initial django and docker setup.
56

6-
You can see deployed example here: [django-docker.matakov.com](https://django-docker.matakov.com)
7+
You can see deployed example here: [https://django-docker.matakov.com](https://django-docker.matakov.com)
8+
9+
Github link: [https://github.com/matacoder/django-docker](https://github.com/matacoder/django-docker)
10+
11+
## What's new in version 2.0
12+
13+
* All styles now are implemented with Bulma CSS framework.
14+
* Loguru logger
15+
* Dark mode (using OS toggle, supported in Safari/Chrome/Firefox)
16+
* Auto loading README to index page
17+
* More efficient Github workflow
18+
* Drop support of Bootstrap and Crispy Forms
19+
720

821
## What is included
922

@@ -15,14 +28,14 @@ You can see deployed example here: [django-docker.matakov.com](https://django-do
1528
- Docker Compose for production
1629
- Caddy config for fast SSL + domain deploy
1730
- Poetry dependency manager
31+
- Loguru logger
1832
- Initial entrypoint to take care of django and postgres setup
1933
- Black code formatter
2034
- Basic Workflow for GitHub Actions
21-
- Accounts app with all authorisation forms implemented on Bootstrap 5
35+
- Accounts app with all authorization forms implemented with Bulma CSS
2236
- Basic template to test login/logout
2337
- Sign up form
2438
- Main app to immediately start writing your first business logic
25-
- Django Crisp Forms installed and used in accounts app
2639
- Django Debug Toolbar! Analyze SQL on-the-fly
2740

2841
## Why project is named _settings?

_settings/settings.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@
4949
"django.contrib.staticfiles",
5050
"crispy_forms",
5151
"markdownify.apps.MarkdownifyConfig",
52+
"bulma",
5253
]
5354

5455
MIDDLEWARE = [

accounts/templates/registration/logged_out.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
{% block title %}Logged out{% endblock %}
33
{% block header %}Logged out{% endblock %}
44
{% block content %}
5-
<div class="alert alert-success" role="alert">
5+
<div class="notification is-info is-light">
66
Logged out
77
</div>
88

accounts/templates/registration/login.html

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
{% block title %}Login{% endblock %}
33
{% block header %}Login{% endblock %}
44
{% block content %}
5-
{% load crispy_forms_tags %}
6-
<div class="bg-light p-5 rounded">
5+
{% load bulma_tags %}
6+
<div class="content">
77
<form method="POST">
88
{% csrf_token %}
9-
{{ form|crispy }}
10-
<p><a href="{% url "password_reset" %}">Reset password</a></p>
11-
<button type="submit" class="btn btn-primary">
9+
{{ form|bulma }}
10+
<p class="block"><a href="{% url "password_reset" %}">Reset password</a></p>
11+
<button type="submit" class="button">
1212
Login
1313
</button>
1414
</form>

accounts/templates/registration/password_change_done.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
{% block title %}Success{% endblock %}
33
{% block header %}Success{% endblock %}
44
{% block content %}
5-
<div class="alert alert-success" role="alert">
5+
<div class="notification is-info is-light">
66
Success
77
</div>
88

accounts/templates/registration/password_change_form.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
{% block title %}Change password{% endblock %}
33
{% block header %}Change password{% endblock %}
44
{% block content %}
5-
{% load crispy_forms_tags %}
6-
<div class="bg-light p-5 rounded">
5+
{% load bulma_tags %}
6+
<div class="content">
77
<form method="POST">
88
{% csrf_token %}
9-
{{ form|crispy }}
9+
{{ form|bulma }}
1010
<br/>
11-
<button type="submit" class="btn btn-primary">
11+
<button type="submit" class="button">
1212
Change password
1313
</button>
1414
</form>

accounts/templates/registration/password_reset_confirm.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
{% block title %}Reset confirmation{% endblock %}
33
{% block header %}Reset confirmation{% endblock %}
44
{% block content %}
5-
{% load crispy_forms_tags %}
6-
<div class="bg-light p-5 rounded">
5+
{% load bulma_tags %}
6+
<div class="content">
77
<form method="POST">
88
{% csrf_token %}
9-
{{ form|crispy }}
9+
{{ form|bulma }}
1010
<br/>
11-
<button type="submit" class="btn btn-primary">
11+
<button type="submit" class="button">
1212
Reset
1313
</button>
1414
</form>

accounts/templates/registration/password_reset_done.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
{% block title %}Success{% endblock %}
33
{% block header %}Success{% endblock %}
44
{% block content %}
5-
<div class="alert alert-success" role="alert">
5+
<div class="notification is-info is-light">
66
Success
77
</div>
88

accounts/templates/registration/password_reset_form.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,13 @@
22
{% block title %}Reset password{% endblock %}
33
{% block header %}Reset password{% endblock %}
44
{% block content %}
5-
{% load crispy_forms_tags %}
6-
<div class="bg-light p-5 rounded">
5+
{% load bulma_tags %}
6+
<div class="content">
77
<form method="POST">
88
{% csrf_token %}
9-
{{ form|crispy }}
9+
{{ form|bulma }}
1010
<br/>
11-
<button type="submit" class="btn btn-primary">
11+
<button type="submit" class="button">
1212
Reset
1313
</button>
1414
</form>

0 commit comments

Comments
 (0)