Skip to content
Snippets Groups Projects
Commit 603880a0 authored by sandeepsajan0's avatar sandeepsajan0 Committed by Fredrik Jonsson
Browse files

Fix buttons sizes, text and css issues

parent ddbb7520
No related branches found
No related tags found
No related merge requests found
...@@ -17,10 +17,10 @@ ...@@ -17,10 +17,10 @@
</ul> </ul>
<p>{% blocktrans %}You should now download, or print these codes, <p>{% blocktrans %}You should now download, or print these codes,
and keep them somewhere safe.{% endblocktrans %}</p> and keep them somewhere safe.{% endblocktrans %}</p>
<p><a class="btn btn-link" href="data:text/plain;charset=UTF-8,{% tokens_text device.token_set.all %}" download="backup_codes.txt">
{% trans "Save Codes" %}</a></p>
<form method="post">{% csrf_token %}{{ form }} <form method="post">{% csrf_token %}{{ form }}
<button class="btn btn-primary" type="submit">{% trans "Regenerate Codes" %}</button> <button class="btn btn-primary" type="submit">{% trans "Regenerate Codes" %}</button>
<a class="btn btn-link link--left-space" href="data:text/plain;charset=UTF-8,{% tokens_text device.token_set.all %}" download="backup_codes.txt">
{% trans "Save Codes" %}</a>
</form> </form>
{% else %} {% else %}
<p>{% trans "You don't have any backup codes yet." %}</p> <p>{% trans "You don't have any backup codes yet." %}</p>
......
...@@ -49,6 +49,8 @@ ...@@ -49,6 +49,8 @@
<form action="" method="post">{% csrf_token %} <form action="" method="post">{% csrf_token %}
{% include "two_factor/_wizard_forms.html" %} {% include "two_factor/_wizard_forms.html" %}
<!-- Add empty p tag to add some space in between wizard form fields and wizard actions buttons. -->
<p></p>
{# hidden submit button to enable [enter] key #} {# hidden submit button to enable [enter] key #}
<input type="submit" value="" class="d-none" /> <input type="submit" value="" class="d-none" />
......
...@@ -2,9 +2,7 @@ ...@@ -2,9 +2,7 @@
{% load i18n %} {% load i18n %}
{% block content %} {% block content %}
<p><a href="{% url 'users:account' %}" <h1>{% block title %}{% trans "Two-Factor Authentication(2FA)" %}{% endblock %}</h1>
class="btn btn-link">{% trans "Back to Account" %}</a></p>
<h1>{% block title %}{% trans "Enable Two-Factor Authentication" %}{% endblock %}</h1>
<p>{% blocktrans trimmed %}Congratulations, you've successfully enabled two-factor <p>{% blocktrans trimmed %}Congratulations, you've successfully enabled two-factor
authentication.{% endblocktrans %}</p> authentication.{% endblocktrans %}</p>
...@@ -12,7 +10,8 @@ ...@@ -12,7 +10,8 @@
To get the backup codes you can continue to Show Codes.{% endblocktrans %}</p> To get the backup codes you can continue to Show Codes.{% endblocktrans %}</p>
{% if not phone_methods %} {% if not phone_methods %}
<p><a href="{% url 'users:backup_tokens_password' %}" class="btn btn-link">Show Codes</a></p> <a href="{% url 'users:backup_tokens_password' %}" class="btn btn-link">Show Codes</a>
<a href="{% url 'users:account' %}" class="link link--bold link--left-space">{% trans "Back to Account" %}</a>
{% else %} {% else %}
<p>{% blocktrans trimmed %}However, it might happen that you don't have access to <p>{% blocktrans trimmed %}However, it might happen that you don't have access to
your primary token device. To enable account recovery, add a phone your primary token device. To enable account recovery, add a phone
......
...@@ -7,16 +7,16 @@ ...@@ -7,16 +7,16 @@
<h1>{% block title %}{% trans "Permission Denied" %}{% endblock %}</h1> <h1>{% block title %}{% trans "Permission Denied" %}{% endblock %}</h1>
<p>{% blocktrans trimmed %}The page you requested, enforces users to verify using <p>{% blocktrans trimmed %}The page you requested, enforces users to verify using
two-factor authentication for security reasons. You need to enable these two-factor authentication for security reasons. You need to set up these
security features in order to access this page. Without enabling these security features, security features in order to access this page. Without setting up these security features,
You can only access the account(Profile section) or can logout from the system.{% endblocktrans %}</p> You can only access the account(Profile section) or can logout from the system.{% endblocktrans %}</p>
<p>{% blocktrans trimmed %}Two-factor authentication is not enabled for your <p>{% blocktrans trimmed %}Two-factor authentication is not already set up for your
account. Enable two-factor authentication for enhanced account account. Set up two-factor authentication for enhanced account
security.{% endblocktrans %}</p> security.{% endblocktrans %}</p>
<p> <p>
<a href="{% url 'two_factor:setup' %}" class="btn btn-primary"> <a href="{% url 'two_factor:setup' %}" class="btn btn-primary">
{% trans "Enable Two-Factor Authentication" %}</a> {% trans "Set up Two-Factor Authentication (2FA)" %}</a>
</p> </p>
{% endblock %} {% endblock %}
...@@ -24,11 +24,12 @@ ...@@ -24,11 +24,12 @@
{% endfor %} {% endfor %}
<button class="button button--primary" type="submit">{% trans "Update Profile" %}</button> <button class="button button--primary" type="submit">{% trans "Update Profile" %}</button>
</form> </form>
</div>
{% if show_change_password and user.has_usable_password and not backends.associated %} {% if show_change_password and user.has_usable_password and not backends.associated %}
<br> <br>
<hr> <hr>
<div> <div class="profile__column">
<h3>{% trans "Account Security" %}</h3> <h3>{% trans "Account Security" %}</h3>
<h4>{% trans "Password" %}</h4> <h4>{% trans "Password" %}</h4>
<p><a class="button button--primary" href="{% url 'users:password_change' %}">{% trans "Update password" %}</a></p> <p><a class="button button--primary" href="{% url 'users:password_change' %}">{% trans "Update password" %}</a></p>
...@@ -36,15 +37,14 @@ ...@@ -36,15 +37,14 @@
<h4>{% trans "Two-Factor Authentication (2FA)" %}</h4> <h4>{% trans "Two-Factor Authentication (2FA)" %}</h4>
{% if default_device %} {% if default_device %}
<div> <div>
<p><a class="link link--button link--button--narrow" href="{% url 'users:backup_tokens_password' %}">{% trans "Show backup codes" %}</a></p> <p><a class="button button--primary" href="{% url 'users:backup_tokens_password' %}">{% trans "Show backup codes" %}</a></p>
<p><a class="link link--button link--button--narrow" href="{% url 'two_factor:disable' %}">{% trans "Disable 2FA" %}</a></p> <p><a class="button button--primary" href="{% url 'two_factor:disable' %}">{% trans "Disable 2FA" %}</a></p>
</div> </div>
{% else %} {% else %}
<p><a class="link link--button link--button--narrow" href="{% url 'two_factor:setup' %}">{% trans "Enable 2FA" %}</a></p> <p><a class="button button--primary" href="{% url 'two_factor:setup' %}">{% trans "Enable 2FA" %}</a></p>
{% endif %} {% endif %}
</div> </div>
{% endif %} {% endif %}
</div>
<div class="profile__column"> <div class="profile__column">
......
...@@ -5,6 +5,7 @@ ...@@ -5,6 +5,7 @@
background-image: none; background-image: none;
border: 0; border: 0;
box-shadow: none; box-shadow: none;
line-height: 1.15;
&:hover { &:hover {
cursor: pointer; cursor: pointer;
......
...@@ -26,6 +26,9 @@ label[for='id_generator-token'] { ...@@ -26,6 +26,9 @@ label[for='id_generator-token'] {
// stylelint-disable property-no-vendor-prefix, selector-id-pattern, selector-max-id // stylelint-disable property-no-vendor-prefix, selector-id-pattern, selector-max-id
#id_generator-token { #id_generator-token {
-moz-appearance: textfield; -moz-appearance: textfield;
border: 2px solid #2166b6;
line-height: 1.35;
width: 20%;
&::-webkit-outer-spin-button, &::-webkit-outer-spin-button,
&::-webkit-inner-spin-button { &::-webkit-inner-spin-button {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment