A free open source IT asset/license management system
Added better visual cues for login (#9051)
sniped14b1e3825d7
diff --git a/resources/lang/en/auth/general.php b/resources/lang/en/auth/general.phpindex cabb5f8bec..33630310d4 100644--- a/resources/lang/en/auth/general.php+++ b/resources/lang/en/auth/general.php@@ -9,5 +9,7 @@ return ['login_prompt' => 'Please Login','forgot_password' => 'I forgot my password','remember_me' => 'Remember Me',+ 'username_help_top' => 'Enter your <strong>username</strong> to be emailed a password reset link.',+ 'username_help_bottom' => 'Your username and email address <em>may</em> be the same, but may not be, depending on your configuration. If you cannot remember your username, contact your administrator. <br><br><strong>Usernames without an associated email address will not be emailed a password reset link.</strong> ',];diff --git a/resources/lang/en/general.php b/resources/lang/en/general.phpindex ed624b9ccf..539a01a13f 100644--- a/resources/lang/en/general.php+++ b/resources/lang/en/general.php@@ -243,5 +243,7 @@'i_accept' => 'I accept','i_decline' => 'I decline','sign_tos' => 'Sign below to indicate that you agree to the terms of service:',- 'clear_signature' => 'Clear Signature'+ 'clear_signature' => 'Clear Signature',+ 'show_help' => 'Show help',+ 'hide_help' => 'Hide help',];diff --git a/resources/views/auth/login.blade.php b/resources/views/auth/login.blade.phpindex b424bee501..00b2ecbc60 100755--- a/resources/views/auth/login.blade.php+++ b/resources/views/auth/login.blade.php@@ -17,7 +17,7 @@<div class="col-md-4 col-md-offset-4"><div class="box login-box">- <div class="box-header">+ <div class="box-header with-border"><h1 class="box-title"> {{ trans('auth/general.login_prompt') }}</h1></div>@@ -43,18 +43,18 @@<fieldset><div class="form-group{{ $errors->has('username') ? ' has-error' : '' }}">- <label for="username">{{ trans('admin/users/table.username') }}</label>+ <label for="username"><i class="fa fa-user" aria-hidden="true"></i> {{ trans('admin/users/table.username') }}</label><input class="form-control" placeholder="{{ trans('admin/users/table.username') }}" name="username" type="text" id="username" autocomplete="off" autofocus>{!! $errors->first('username', '<span class="alert-msg" aria-hidden="true"><i class="fa fa-times" aria-hidden="true"></i> :message</span>') !!}</div><div class="form-group{{ $errors->has('password') ? ' has-error' : '' }}">- <label for="password">{{ trans('admin/users/table.password') }}</label>+ <label for="password"><i class="fa fa-key" aria-hidden="true"></i> {{ trans('admin/users/table.password') }}</label><input class="form-control" placeholder="{{ trans('admin/users/table.password') }}" name="password" type="password" id="password" autocomplete="off">{!! $errors->first('password', '<span class="alert-msg" aria-hidden="true"><i class="fa fa-times" aria-hidden="true"></i> :message</span>') !!}</div><div class="checkbox">- <label>- <input name="remember" type="checkbox" value="1">{{ trans('auth/general.remember_me') }}+ <label style="margin-left: -20px;">+ <input name="remember" type="checkbox" value="1" class="minimal"> {{ trans('auth/general.remember_me') }}</label></div></fieldset>diff --git a/resources/views/auth/passwords/email.blade.php b/resources/views/auth/passwords/email.blade.phpindex a916d4c37e..3f858f471b 100644--- a/resources/views/auth/passwords/email.blade.php+++ b/resources/views/auth/passwords/email.blade.php@@ -5,7 +5,9 @@@section('content')@if ($snipeSettings->custom_forgot_pass_url)- <a href="{{ $snipeSettings->custom_forgot_pass_url }}" rel="noopener">{{ trans('auth/general.forgot_password') }}</a>+ <a href="{{ $snipeSettings->custom_forgot_pass_url }}" rel="noopener">+ {{ trans('auth/general.forgot_password') }}+ </a>@else<form class="form" role="form" method="POST" action="{{ url('/password/email') }}">@@ -13,19 +15,28 @@<div class="container"><div class="row">--<div class="col-md-4 col-md-offset-4"><div class="box login-box" style="width: 100%">- <div class="box-header">+ <div class="box-header with-border"><h2 class="box-title"> {{ trans('auth/general.send_password_link') }}</h2></div><div class="login-box-body">+ <div class="row">+ <div class="col-md-12">+ <div class="alert alert-info">+ <i class="fa fa-info-circle" aria-hidden="true"></i>+ {!! trans('auth/general.username_help_top') !!}+ </div>+ </div>+++ </div><div class="row">+<!-- Notifications -->@include('notifications')@@ -34,20 +45,41 @@<div class="form-group{{ $errors->has('username') ? ' has-error' : '' }}"><div class="col-md-12">- <label for="username">{{ trans('admin/users/table.username') }}: </label>+ <label for="username"><i class="fa fa-user" aria-hidden="true"></i> {{ trans('admin/users/table.username') }} </label><input type="text" class="form-control" name="username" value="{{ old('username') }}" placeholder="{{ trans('admin/users/table.username') }}" aria-label="username">{!! $errors->first('username', '<span class="alert-msg"><i class="fa fa-times"></i> :message</span>') !!}</div></div>+ </div>--+ <div class="row">+ <div class="col-md-12">+ <br>+ <!-- show help text toggle -->+ <a href="#" id="show">+ <i class="fa fa-caret-right"></i>+ {{ trans('general.show_help') }}+ </a>++ <!-- hide help text toggle -->+ <a href="#" id="hide" style="display:none">+ <i class="fa fa-caret-up"></i>+ {{ trans('general.hide_help') }}+ </a>++ <!-- help text -->+ <p class="help-block" id="help-text" style="display:none">+ {!! trans('auth/general.username_help_bottom') !!}+ </p>++ </div></div></div>+<div class="box-footer"><button type="submit" class="btn btn-lg btn-primary btn-block">{{ trans('auth/general.email_reset_password') }}- </button>+ </button></div></div>@@ -60,3 +92,21 @@@endif@stop+@push('js')+ <script nonce="{{ csrf_token() }}">+ $(document).ready(function () {+ $("#show").click(function(){+ $("#help-text").show();+ $("#show").hide();+ $("#hide").show();+ });++ $("#hide").click(function(){+ $("#help-text").hide();+ $("#show").show();+ $("#hide").hide();+ });+ });+ </script>+@endpush+diff --git a/resources/views/auth/passwords/reset.blade.php b/resources/views/auth/passwords/reset.blade.phpindex 763a0de0cb..1f310e018f 100644--- a/resources/views/auth/passwords/reset.blade.php+++ b/resources/views/auth/passwords/reset.blade.php@@ -16,7 +16,7 @@<div class="col-md-6 col-md-offset-3"><div class="box login-box" style="width: 100%">- <div class="box-header">+ <div class="box-header with-border"><h2 class="box-title"> {{ trans('auth/general.reset_password') }}</h2></div>@@ -32,7 +32,7 @@<input type="hidden" name="token" value="{{ $token }}"><div class="form-group{{ $errors->has('username') ? ' has-error' : '' }}">- <label class="col-md-4 control-label">{{ trans('admin/users/table.username') }}</label>+ <label class="col-md-4 control-label"><i class="fa fa-user" aria-hidden="true"></i> {{ trans('admin/users/table.username') }}</label><div class="col-md-6"><input type="text" class="form-control" name="username" value="{{ old('username', $username) }}">@@ -42,7 +42,7 @@</div><div class="form-group{{ $errors->has('password') ? ' has-error' : '' }}">- <label class="col-md-4 control-label" for="password">{{ trans('admin/users/table.password') }}</label>+ <label class="col-md-4 control-label" for="password"><i class="fa fa-key" aria-hidden="true"></i> {{ trans('admin/users/table.password') }}</label><div class="col-md-6"><input type="password" class="form-control" name="password" aria-label="password">@@ -51,7 +51,7 @@</div><div class="form-group{{ $errors->has('password_confirmation') ? ' has-error' : '' }}">- <label class="col-md-4 control-label" for="password_confirmation">{{ trans('admin/users/table.password_confirm') }}</label>+ <label class="col-md-4 control-label" for="password_confirmation"><i class="fa fa-key" aria-hidden="true"></i> {{ trans('admin/users/table.password_confirm') }}</label><div class="col-md-6"><input type="password" class="form-control" name="password_confirmation" aria-label="password_confirmation">{!! $errors->first('password_confirmation', '<span class="alert-msg" aria-hidden="true"><i class="fa fa-times" aria-hidden="true"></i> :message</span>') !!}diff --git a/resources/views/layouts/basic.blade.php b/resources/views/layouts/basic.blade.phpindex 2c3277f1de..2c781264b3 100644--- a/resources/views/layouts/basic.blade.php+++ b/resources/views/layouts/basic.blade.php@@ -11,11 +11,16 @@<link rel="shortcut icon" type="image/ico" href="{{ ($snipeSettings) && ($snipeSettings->favicon!='') ? Storage::disk('public')->url('').e($snipeSettings->favicon) : 'favicon.ico' }} ">{{-- stylesheets --}}<link rel="stylesheet" href="{{ url(mix('css/dist/all.css')) }}">--- <link rel="stylesheet" href="{{ url('css/dist/all.css') }}"><link rel="shortcut icon" type="image/ico" href="{{ url(asset('favicon.ico')) }}">+ <script nonce="{{ csrf_token() }}">+ window.snipeit = {+ settings: {+ "per_page": 50+ }+ };+ </script>+@if (($snipeSettings) && ($snipeSettings->header_color))<style>@@ -64,6 +69,11 @@@endif</div>+ {{-- Javascript files --}}+ <script src="{{ url(mix('js/dist/all.js')) }}" nonce="{{ csrf_token() }}"></script>+++ @stack('js')</body></html>