Skip to content

Commit

Permalink
Merge branch 'release-1.10.5'
Browse files Browse the repository at this point in the history
  • Loading branch information
abidibo committed Aug 5, 2020
2 parents f71dec4 + 7a94035 commit b996510
Show file tree
Hide file tree
Showing 10 changed files with 49 additions and 11 deletions.
8 changes: 4 additions & 4 deletions baton/static/baton/app/dist/baton.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion baton/static/baton/app/dist/baton.min.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion baton/static/baton/app/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion baton/static/baton/app/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "baton",
"version": "1.10.4",
"version": "1.10.5",
"description": "Django Baton App",
"main": "index.js",
"scripts": {
Expand Down
30 changes: 30 additions & 0 deletions baton/static/baton/app/src/core/Login.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
import $ from 'jquery'

const Login = {
init: function () {
let inputUsername = $('#id_username')
let inputPassword = $('#id_password')

const usernameField = $('<div />', { class: 'input-group mb-2' })
.append(
$('<div />', { class: 'input-group-prepend' }).append(
'<div class="input-group-text"><i class="fa fa-user"></i></div>'
)
)
.append(inputUsername.clone())

inputUsername.replaceWith(usernameField)

const passwordField = $('<div />', { class: 'input-group mb-2' })
.append(
$('<div />', { class: 'input-group-prepend' }).append(
'<div class="input-group-text"><i class="fa fa-key"></i></div>'
)
)
.append(inputPassword.clone())

inputPassword.replaceWith(passwordField)
}
}

export default Login
5 changes: 4 additions & 1 deletion baton/static/baton/app/src/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ import Analytics from './core/Analytics'
import Tabs from './core/Tabs'
import ChangeList from './core/ChangeList'
import ChangeForm from './core/ChangeForm'
import Login from './core/Login'
import Filer from './core/Filer'

window.Baton = {
Expand All @@ -28,7 +29,9 @@ window.Baton = {
if (page !== 'login' && page !== 'logout' && !/_popup/.test(location.search)) {
Menu.init(config, Dispatcher)
}
if (page === 'logout' || page === 'password_change_success') {
if (page === 'login') {
Login.init()
} else if (page === 'logout' || page === 'password_change_success') {
ActionResult.init()
} else if (page === 'password_change') {
PasswordChange.init()
Expand Down
5 changes: 5 additions & 0 deletions baton/static/baton/app/src/styles/_login.scss
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,11 @@ body.login {

form {
padding: 1rem;

.input-group-text {
justify-content: center;
width: 42px;
}
}

input[type='text'],
Expand Down
4 changes: 2 additions & 2 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,9 +54,9 @@
# built documents.
#
# The short X.Y version.
version = u'1.10.4'
version = u'1.10.5'
# The full version, including alpha/beta/rc tags.
release = u'1.10.4'
release = u'1.10.5'

# The language for content autogenerated by Sphinx. Refer to documentation
# for a list of supported languages.
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

setup(
name='django-baton',
version='1.10.4',
version='1.10.5',
packages=['baton', 'baton.autodiscover', 'baton.templatetags'],
include_package_data=True,
license='MIT License',
Expand Down
Binary file modified testapp/app/db.sqlite3
Binary file not shown.

0 comments on commit b996510

Please sign in to comment.