Skip to content

Commit

Permalink
fixed auth pages and config
Browse files Browse the repository at this point in the history
  • Loading branch information
hexpit committed May 14, 2023
1 parent 3ed6aad commit d571e7e
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 12 deletions.
4 changes: 2 additions & 2 deletions app/Providers/FortifyServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -48,10 +48,10 @@ public function boot()
}
});
Fortify::registerView(function () {
if (config('quickstart.access.user.login')) {
if (config('quickstart.access.user.login') && config('quickstart.access.user.registration')) {
return view('auth.register');
} else {
return (abort(404));
abort(404);
}
});
Fortify::requestPasswordResetLinkView(function () {
Expand Down
4 changes: 2 additions & 2 deletions resources/views/auth/confirm-password.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
@include('includes.partials.lang')
@include('includes.partials.switch')
</div>
<h1 class="font-bold text-2xl my-3">{{ __('headings.confirm-password') }}</h1>
<p>{{ __('You need to confirm your password to complete this action.') }}</p>
<h1 class="font-bold text-2xl my-3 dark:text-white">{{ __('headings.confirm-password') }}</h1>
<p class="dark:text-white">{{ __('You need to confirm your password to complete this action.') }}</p>
@include('includes.partials.messages')
<x-forms.post :action="route('password.confirm')">
<div class="my-3">
Expand Down
4 changes: 2 additions & 2 deletions resources/views/auth/forgot-password.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
@include('includes.partials.lang')
@include('includes.partials.switch')
</div>
<h1 class="font-bold text-2xl my-3">{{ __('headings.password-reset') }}</h1>
<p>{{ __('Reset your forgotten password') }}</p>
<h1 class="font-bold text-2xl my-3 dark:text-white">{{ __('headings.password-reset') }}</h1>
<p class="dark:text-white">{{ __('Reset your forgotten password') }}</p>
@include('includes.partials.messages')
<x-forms.post :action="route('password.email')">
<div class="my-2">
Expand Down
8 changes: 5 additions & 3 deletions resources/views/auth/login.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,11 @@
</button>
<a href="{{ route('password.request') }}">Forgot password?</a>
</div>
<div>
<p>Don't have an account yet? <a href="{{ route('register') }}" class="font-bold">Register Now</a></p>
</div>
@if(config('quickstart.access.user.registration'))
<div>
<p>Don't have an account yet? <a href="{{ route('register') }}" class="font-bold">Register Now</a></p>
</div>
@endif
</x-forms.post>
<div class="divider my-6">
<span class="px-2 py-1 rounded-xl bg-gray-800 dark:bg-gray-200 text-gray-200 dark:text-gray-800">or use social login</span>
Expand Down
8 changes: 5 additions & 3 deletions resources/views/auth/register.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,9 +60,11 @@
</button>
</div>
</x-forms.post>
<div>
<p>Already have an account? <a href="{{ route('login') }}" class="font-bold">Login Now</a></p>
</div>
@if(config('quickstart.access.user.login'))
<div>
<p>Already have an account? <a href="{{ route('login') }}" class="font-bold">Login Now</a></p>
</div>
@endif
<div class="divider my-4">
<span class="px-2 py-1 rounded-xl bg-gray-800 dark:bg-gray-200 text-gray-200 dark:text-gray-800">or use social login</span>
</div>
Expand Down

0 comments on commit d571e7e

Please sign in to comment.