Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AIDAPP-407]: Improve the user experience for the login screen with helpful release and support information #381

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
55 changes: 33 additions & 22 deletions app-modules/authorization/resources/views/login.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -31,25 +31,36 @@

</COPYRIGHT>
--}}
<x-filament-panels::page.simple>
@if (filament()->hasRegistration())
<x-slot name="subheading">
{{ __('filament-panels::pages/auth/login.actions.register.before') }}

{{ $this->registerAction }}
</x-slot>
@endif

<x-filament-panels::form wire:submit="authenticate">
{{ $this->form }}

<x-filament-panels::form.actions
:actions="$this->getCachedFormActions()"
:full-width="$this->hasFullWidthFormActions()"
/>
<x-filament-panels::form.actions
:actions="$this->getSsoFormActions()"
:full-width="$this->hasFullWidthFormActions()"
/>
</x-filament-panels::form>
</x-filament-panels::page.simple>
<div class="flex w-full flex-col items-center justify-center gap-8 lg:flex-row">
<div class="w-full lg:w-1/2 lg:pr-8">
@if (filament()->hasRegistration())
<x-slot name="subheading">
{{ __('filament-panels::pages/auth/login.actions.register.before') }}

{{ $this->registerAction }}
</x-slot>
@endif

<x-filament-panels::form wire:submit="authenticate">
{{ $this->form }}

<x-filament-panels::form.actions
:actions="$this->getCachedFormActions()"
:full-width="$this->hasFullWidthFormActions()"
/>
@if (count($this->getSsoFormActions()) > 0)
<small class="text-gray-800 dark:text-gray-300">or log in with single sign-on</small>
@endif
<x-filament-panels::form.actions
:actions="$this->getSsoFormActions()"
:full-width="$this->hasFullWidthFormActions()"
/>
</x-filament-panels::form>
</div>

<div class="w-full lg:w-1/2">
<x-filament-panels::login-version-card />
<x-filament-panels::login-resource-portal-card />
</div>

</div>
2 changes: 2 additions & 0 deletions app-modules/authorization/src/Filament/Pages/Auth/Login.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ class Login extends FilamentLogin
{
protected static string $view = 'authorization::login';

protected static string $layout = 'filament-panels::components.layouts.login';

protected function getSsoFormActions(): array
{
$ssoActions = [];
Expand Down
11 changes: 11 additions & 0 deletions app/Providers/AppServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,17 @@ public function boot(): void
return null;
});

$this->app->singleton('current-version', function ($app) {
$gitVersion = Process::run('git describe --tags $(git rev-list --tags --max-count=1)');

if ($gitVersion->successful()) {
return rtrim($gitVersion->output());
}
report($gitVersion->errorOutput());

return null;
});

Feature::discover();
}
}
4 changes: 4 additions & 0 deletions resources/css/filament/admin/theme.css
Original file line number Diff line number Diff line change
Expand Up @@ -161,3 +161,7 @@ li[data-group-label=''] > ul > .fi-sidebar-item > .fi-sidebar-item-button > .fi-
.fi-section.fi-section-no-content-padding .fi-section-content {
@apply p-0;
}

.dark_button_border {
@apply dark:border dark:border-white dark:hover:border-white !important;
}
1 change: 1 addition & 0 deletions resources/images/changelog_image.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading