Skip to content

Commit

Permalink
Merge pull request #34 from andrewdwallo/hotfix
Browse files Browse the repository at this point in the history
Hotfix
  • Loading branch information
andrewdwallo authored Feb 13, 2023
2 parents 76b9bb0 + 010c6e6 commit 9a11100
Show file tree
Hide file tree
Showing 94 changed files with 871 additions and 744 deletions.
7 changes: 4 additions & 3 deletions resources/views/auth/confirm-password.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,10 @@
@csrf

<div>
<x-filament-companies::label for="password" value="{{ __('filament-companies::default.fields.password') }}" />
<x-filament-companies::input id="password" class="mt-1 block w-full" type="password" name="password" required
autocomplete="current-password" autofocus />
<x-forms::field-wrapper id="password" statePath="password" required="true" label="{{ __('filament-companies::default.fields.password') }}">
<x-filament-companies::input id="password" type="password" name="password"
required autocomplete="current-password" autofocus="on" />
</x-forms::field-wrapper>
</div>

<div class="mt-4 flex justify-end">
Expand Down
7 changes: 4 additions & 3 deletions resources/views/auth/forgot-password.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@
@csrf

<div class="block">
<x-filament-companies::label for="email" value="{{ __('filament-companies::default.fields.email') }}" />
<x-filament-companies::input id="email" class="mt-1 block w-full" type="email" name="email"
:value="old('email')" required autofocus />
<x-forms::field-wrapper id="email" statePath="email" required="true" label="{{ __('filament-companies::default.fields.email') }}">
<x-filament-companies::input id="email" type="email" name="email"
:value="old('email')" autofocus="on" />
</x-forms::field-wrapper>
</div>

<div class="mt-4 flex items-center justify-end">
Expand Down
2 changes: 1 addition & 1 deletion resources/views/auth/register.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<div>
<x-forms::field-wrapper id="name" statePath="name" required="true" label="{{ __('filament-companies::default.fields.name') }}">
<x-filament-companies::input id="name" type="text" name="name"
:value="old('name')" required autofocus autocomplete="name" />
:value="old('name')" required autofocus autocomplete="on" />
</x-forms::field-wrapper>
</div>

Expand Down
2 changes: 1 addition & 1 deletion resources/views/auth/verify-email.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
{{ __('filament-companies::default.headings.auth.verify_email.verification_link_not_sent') }}
</div>

@if (session('status') == 'verification-link-sent')
@if (session('status') === 'verification-link-sent')
<div class="mb-4 text-sm font-medium text-green-600 dark:text-green-400">
{{ __('filament-companies::default.headings.auth.verify_email.verification_link_sent') }}
</div>
Expand Down
8 changes: 4 additions & 4 deletions resources/views/companies/company-employee-manager.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,11 @@ class="{{ isset($addCompanyEmployeeForm['role']) && $addCompanyEmployeeForm['rol
<!-- Role Name -->
<div class="flex items-center">
<div
class="{{ $addCompanyEmployeeForm['role'] == $role->key ? 'font-semibold' : '' }} text-sm text-gray-600 dark:text-gray-400">
class="{{ $addCompanyEmployeeForm['role'] === $role->key ? 'font-semibold' : '' }} text-sm text-gray-600 dark:text-gray-400">
{{ $role->name }}
</div>

@if ($addCompanyEmployeeForm['role'] == $role->key)
@if ($addCompanyEmployeeForm['role'] === $role->key)
<svg class="text-primary-500 ml-2 h-5 w-5"
xmlns="http://www.w3.org/2000/svg" fill="none"
viewBox="0 0 24 24" stroke-width="1.5"
Expand Down Expand Up @@ -209,11 +209,11 @@ class="{{ $index > 0 ? 'border-t border-gray-200 dark:border-gray-700 focus:bord
<!-- Role Name -->
<div class="flex items-center">
<div
class="{{ $currentRole == $role->key ? 'font-semibold' : '' }} text-sm text-gray-600 dark:text-gray-400">
class="{{ $currentRole === $role->key ? 'font-semibold' : '' }} text-sm text-gray-600 dark:text-gray-400">
{{ $role->name }}
</div>

@if ($currentRole == $role->key)
@if ($currentRole === $role->key)
<svg class="text-primary-500 ml-2 h-5 w-5" xmlns="http://www.w3.org/2000/svg"
fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round"
Expand Down
2 changes: 1 addition & 1 deletion resources/views/companies/create-company-form.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

<div class="col-span-6 sm:col-span-4">
<x-forms::field-wrapper id="name" statePath="name" required="true" label="{{ __('filament-companies::default.labels.company_name') }}">
<x-filament-companies::input id="name" type="text" wire:model.defer="state.name" autofocus />
<x-filament-companies::input id="name" type="text" wire:model.defer="state.name" autofocus="on" />
</x-forms::field-wrapper>
</div>

Expand Down
37 changes: 23 additions & 14 deletions resources/views/components/banner.blade.php
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
@props(['style' => session('flash.bannerStyle', 'success'), 'message' => session('flash.banner')])

<div x-data="{{ json_encode(['show' => true, 'style' => $style, 'message' => $message]) }}"
:class="{ 'bg-primary-500': style == 'success', 'bg-red-700': style == 'danger', 'bg-gray-500': style != 'success' && style != 'danger' }"
style="display: none;"
x-show="show && message"
x-init="
<div x-data="{{ json_encode(['show' => true, 'style' => $style, 'message' => $message], JSON_THROW_ON_ERROR) }}"
:class="{ 'bg-primary-500': style == 'success', 'bg-red-700': style == 'danger', 'bg-gray-500': style != 'success' && style != 'danger' }"
style="display: none;"
x-show="show && message"
x-init="
document.addEventListener('banner-message', event => {
style = event.detail.style;
message = event.detail.message;
Expand All @@ -14,15 +14,23 @@
<div class="max-w-screen-xl mx-auto py-2 px-3 sm:px-6 lg:px-8">
<div class="flex items-center justify-between flex-wrap">
<div class="w-0 flex-1 flex items-center min-w-0">
<span class="flex p-2 rounded-lg" :class="{ 'bg-primary-600': style == 'success', 'bg-red-600': style == 'danger' }">
<svg x-show="style == 'success'" class="h-5 w-5 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" d="M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z" />
<span class="flex p-2 rounded-lg"
:class="{ 'bg-primary-600': style == 'success', 'bg-red-600': style == 'danger' }">
<svg x-show="style == 'success'" class="h-5 w-5 text-white" xmlns="http://www.w3.org/2000/svg"
fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round"
d="M9 12.75L11.25 15 15 9.75M21 12a9 9 0 11-18 0 9 9 0 0118 0z"/>
</svg>
<svg x-show="style == 'danger'" class="h-5 w-5 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" d="M12 9v3.75m9-.75a9 9 0 11-18 0 9 9 0 0118 0zm-9 3.75h.008v.008H12v-.008z" />
<svg x-show="style == 'danger'" class="h-5 w-5 text-white" xmlns="http://www.w3.org/2000/svg"
fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round"
d="M12 9v3.75m9-.75a9 9 0 11-18 0 9 9 0 0118 0zm-9 3.75h.008v.008H12v-.008z"/>
</svg>
<svg x-show="style != 'success' && style != 'danger'" class="h-5 w-5 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" d="M11.25 11.25l.041-.02a.75.75 0 011.063.852l-.708 2.836a.75.75 0 001.063.853l.041-.021M21 12a9 9 0 11-18 0 9 9 0 0118 0zm-9-3.75h.008v.008H12V8.25z" />
<svg x-show="style != 'success' && style != 'danger'" class="h-5 w-5 text-white"
xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5"
stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round"
d="M11.25 11.25l.041-.02a.75.75 0 011.063.852l-.708 2.836a.75.75 0 001.063.853l.041-.021M21 12a9 9 0 11-18 0 9 9 0 0118 0zm-9-3.75h.008v.008H12V8.25z"/>
</svg>
</span>

Expand All @@ -36,8 +44,9 @@ class="-mr-1 flex p-2 rounded-md focus:outline-none sm:-mr-2 transition"
:class="{ 'hover:bg-primary-600 focus:bg-primary-600': style == 'success', 'hover:bg-red-600 focus:bg-red-600': style == 'danger' }"
aria-label="Dismiss"
x-on:click="show = false">
<svg class="h-5 w-5 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24" stroke-width="1.5" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" d="M6 18L18 6M6 6l12 12" />
<svg class="h-5 w-5 text-white" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24"
stroke-width="1.5" stroke="currentColor">
<path stroke-linecap="round" stroke-linejoin="round" d="M6 18L18 6M6 6l12 12"/>
</svg>
</button>
</div>
Expand Down
2 changes: 1 addition & 1 deletion resources/views/components/modal.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
@endphp

<div
x-data="{show: @entangle($attributes->wire('model')).defer }",
x-data="{show: @entangle($attributes->wire('model')).defer }"
x-on:close.stop="show = false"
x-on:keydown.escape.window="show = false"
x-show="show"
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?xml version="1.0" encoding="utf-8"?><svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" class="h-6 w-6" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 122.88 113.2" style="enable-background:new 0 0 122.88 113.2" xml:space="preserve"><style type="text/css">.st0{fill:#EC672A;} .st1{fill:#DD3E2A;} .st2{fill:#F6A420;}</style><g><path class="st0" d="M122.65,64.72l-6.89-21.15L102.15,1.61c-0.7-2.15-3.74-2.15-4.47,0L84.06,43.54H38.81L25.19,1.61 c-0.7-2.15-3.74-2.15-4.47,0L7.13,43.54L0.24,64.72c-0.62,1.92,0.05,4.04,1.7,5.24l59.5,43.23l59.5-43.23 C122.58,68.77,123.28,66.65,122.65,64.72L122.65,64.72z"/><polygon class="st1" points="61.45,113.17 61.45,113.17 84.08,43.54 38.82,43.54 61.45,113.17 61.45,113.17"/><polygon class="st0" points="61.43,113.17 38.81,43.54 7.13,43.54 61.43,113.17 61.43,113.17"/><path class="st2" d="M7.11,43.56L7.11,43.56L0.23,64.72c-0.62,1.92,0.05,4.04,1.7,5.24l59.5,43.23L7.11,43.56L7.11,43.56 L7.11,43.56z"/><path class="st1" d="M7.12,43.56h31.71L25.18,1.63c-0.7-2.15-3.74-2.15-4.47,0L7.12,43.56L7.12,43.56L7.12,43.56z"/><polygon class="st0" points="61.45,113.17 84.08,43.54 115.79,43.54 61.45,113.17 61.45,113.17"/><path class="st2" d="M115.76,43.56L115.76,43.56l6.89,21.15c0.62,1.92-0.05,4.04-1.7,5.24l-59.5,43.21L115.76,43.56L115.76,43.56 L115.76,43.56z"/><path class="st1" d="M115.78,43.56H84.07L97.69,1.63c0.7-2.15,3.74-2.15,4.47,0L115.78,43.56L115.78,43.56L115.78,43.56z"/></g></svg>
<svg xmlns="http://www.w3.org/2000/svg" class="h-6 w-6" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" viewBox="0 0 122.88 113.2" style="enable-background:new 0 0 122.88 113.2" xml:space="preserve"><style type="text/css">.st0{fill:#EC672A;} .st1{fill:#DD3E2A;} .st2{fill:#F6A420;}</style><g><path class="st0" d="M122.65,64.72l-6.89-21.15L102.15,1.61c-0.7-2.15-3.74-2.15-4.47,0L84.06,43.54H38.81L25.19,1.61 c-0.7-2.15-3.74-2.15-4.47,0L7.13,43.54L0.24,64.72c-0.62,1.92,0.05,4.04,1.7,5.24l59.5,43.23l59.5-43.23 C122.58,68.77,123.28,66.65,122.65,64.72L122.65,64.72z"/><polygon class="st1" points="61.45,113.17 61.45,113.17 84.08,43.54 38.82,43.54 61.45,113.17 61.45,113.17"/><polygon class="st0" points="61.43,113.17 38.81,43.54 7.13,43.54 61.43,113.17 61.43,113.17"/><path class="st2" d="M7.11,43.56L7.11,43.56L0.23,64.72c-0.62,1.92,0.05,4.04,1.7,5.24l59.5,43.23L7.11,43.56L7.11,43.56 L7.11,43.56z"/><path class="st1" d="M7.12,43.56h31.71L25.18,1.63c-0.7-2.15-3.74-2.15-4.47,0L7.12,43.56L7.12,43.56L7.12,43.56z"/><polygon class="st0" points="61.45,113.17 84.08,43.54 115.79,43.54 61.45,113.17 61.45,113.17"/><path class="st2" d="M115.76,43.56L115.76,43.56l6.89,21.15c0.62,1.92-0.05,4.04-1.7,5.24l-59.5,43.21L115.76,43.56L115.76,43.56 L115.76,43.56z"/><path class="st1" d="M115.78,43.56H84.07L97.69,1.63c0.7-2.15,3.74-2.15,4.47,0L115.78,43.56L115.78,43.56L115.78,43.56z"/></g></svg>
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

<x-filament-companies::section-border />

@if (Gate::check('delete', $company) && !$company->personal_company)
@if (!$company->personal_company && Gate::check('delete', $company))
<div class="mt-10 sm:mt-0">
@livewire(\Wallo\FilamentCompanies\Http\Livewire\DeleteCompanyForm::class, ['company' => $company])
</div>
Expand Down
4 changes: 2 additions & 2 deletions resources/views/filament/pages/user/api-tokens.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ class="flex items-center justify-center space-x-2 rtl:space-x-reverse">
{{ __('filament-companies::default.modal_descriptions.api_token') }}
</div>

<x-filament-companies::input x-ref="plaintextToken" type="text" readonly :value="$plainTextToken"
class="mt-4 w-full rounded bg-gray-100 px-4 py-2 font-mono text-sm text-gray-500" autofocus
<x-filament-companies::input x-ref="plaintextToken" type="text" readonly="required" :value="$plainTextToken"
class="mt-4 w-full rounded bg-gray-100 px-4 py-2 font-mono text-sm text-gray-500" autofocus="on"
autocomplete="off" autocorrect="off" autocapitalize="off" spellcheck="false"
@showing-token-modal.window="setTimeout(() => $refs.plaintextToken.select(), 250)" />
</x-slot>
Expand Down
22 changes: 11 additions & 11 deletions resources/views/filament/pages/user/profile.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,48 +5,48 @@
@livewire(\Wallo\FilamentCompanies\Http\Livewire\UpdateProfileInformationForm::class)
</div>

<x-filament-companies::section-border />
<x-filament-companies::section-border />
@endif

@if (Laravel\Fortify\Features::enabled(Laravel\Fortify\Features::updatePasswords()) && !is_null($user->password))
@if (!is_null($user->password) && Laravel\Fortify\Features::enabled(Laravel\Fortify\Features::updatePasswords()))
<div class="mt-10 sm:mt-0">
@livewire(\Wallo\FilamentCompanies\Http\Livewire\UpdatePasswordForm::class)
</div>

<x-filament-companies::section-border />
<x-filament-companies::section-border />
@else
<div class="mt-10 sm:mt-0">
@livewire(\Wallo\FilamentCompanies\Http\Livewire\SetPasswordForm::class)
</div>

<x-filament-companies::section-border />
<x-filament-companies::section-border />
@endif

@if (Laravel\Fortify\Features::canManageTwoFactorAuthentication() && !is_null($user->password))
@if (!is_null($user->password) && Laravel\Fortify\Features::canManageTwoFactorAuthentication())
<div class="mt-10 sm:mt-0">
@livewire(\Wallo\FilamentCompanies\Http\Livewire\TwoFactorAuthenticationForm::class)
</div>

<x-filament-companies::section-border />
<x-filament-companies::section-border />
@endif

@if (Wallo\FilamentCompanies\Socialite::show())
<div class="mt-10 sm:mt-0">
@livewire(\Wallo\FilamentCompanies\Http\Livewire\ConnectedAccountsForm::class)
</div>

<x-filament-companies::section-border />
@endif

@if (!is_null($user->password))
<x-filament-companies::section-border />

<div class="mt-10 sm:mt-0">
@livewire(\Wallo\FilamentCompanies\Http\Livewire\LogoutOtherBrowserSessionsForm::class)
</div>
@endif

@if (Wallo\FilamentCompanies\FilamentCompanies::hasAccountDeletionFeatures() && is_null($user->password))
<x-filament-companies::section-border />
<x-filament-companies::section-border />
@endif

@if (!is_null($user->password) && Wallo\FilamentCompanies\FilamentCompanies::hasAccountDeletionFeatures())
<div class="mt-10 sm:mt-0">
@livewire(\Wallo\FilamentCompanies\Http\Livewire\DeleteUserForm::class)
</div>
Expand Down
7 changes: 3 additions & 4 deletions resources/views/profile/connected-accounts-form.blade.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<x-slot name="content">
<x-filament::card class="col-span-2 mt-5 sm:col-span-1 md:mt-0">
<h3 class="text-lg font-medium text-gray-900 dark:text-white">
@if (count($this->accounts) == 0)
@if (count($this->accounts) === 0)
{{ __('filament-companies::default.headings.profile.connected_accounts.no_connected_accounts') }}
@else
{{ __('filament-companies::default.headings.profile.connected_accounts.has_connected_accounts') }}
Expand All @@ -25,7 +25,6 @@
@foreach ($this->providers as $provider)
<x-filament::hr />
@php
$account = null;
$account = $this->accounts->where('provider', $provider)->first();
@endphp

Expand All @@ -35,15 +34,15 @@
<x-slot name="action">
@if (!is_null($account))
<div class="flex items-center justify-between">
@if (Wallo\FilamentCompanies\FilamentCompanies::managesProfilePhotos() && !is_null($account->avatar_path))
@if (!is_null($account->avatar_path) && Wallo\FilamentCompanies\FilamentCompanies::managesProfilePhotos())
<x-filament::button class="mr-3"
wire:click="setAvatarAsProfilePhoto({{ $account->id }})">
{{ __('filament-companies::default.buttons.use_avatar_as_profile_photo') }}

</x-filament::button>
@endif

@if ($this->accounts->count() > 1 || !is_null($this->user->password))
@if (!is_null($this->user->password) || $this->accounts->count() > 1)
<x-filament::button color="danger"
wire:click="confirmRemove({{ $account->id }})"
wire:loading.attr="disabled">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@

<div class="ml-3">
<div class="text-sm text-gray-600 dark:text-gray-400">
{{ $session->agent->platform() ? $session->agent->platform() : 'filament-companies::default.labels.unknown' }}
{{ $session->agent->platform() ?: 'filament-companies::default.labels.unknown' }}
-
{{ $session->agent->browser() ? $session->agent->browser() : 'filament-companies::default.labels.unknown' }}
{{ $session->agent->browser() ?: 'filament-companies::default.labels.unknown' }}
</div>

<div>
Expand Down
Loading

0 comments on commit 9a11100

Please sign in to comment.