Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
atmonshi committed Sep 5, 2024
1 parent ea8acee commit 5fcaf8e
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
7 changes: 5 additions & 2 deletions app/Filament/Pages/App/Profile.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

use App\Filament\Actions\GeneratePasswordAction;
use Filament\Forms\Components\Section;
use Filament\Forms\Components\TextInput;
use Filament\Forms\Form;
use Filament\Pages\Auth\EditProfile;

Expand All @@ -19,14 +20,16 @@ public function getBreadcrumbs(): array

public function form(Form $form): Form
{
/** @var TextInput $passwordComponent */
$passwordComponent = $this->getPasswordFormComponent();

return $form->schema([
Section::make()
->inlineLabel(false)
->schema([
$this->getNameFormComponent(),
$this->getEmailFormComponent(),
$this->getPasswordFormComponent()
->suffixActions([
$passwordComponent->suffixActions([
GeneratePasswordAction::make(),
]),
$this->getPasswordConfirmationFormComponent(),
Expand Down
4 changes: 2 additions & 2 deletions app/Filament/Resources/UserResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ public static function getGloballySearchableAttributes(): array

public static function getGlobalSearchResultDetails(Model $record): array
{
/** @phpstan-ignore return.type */
return [$record->email];
/** @var User $record */
return ['email'=>$record->email];
}

public static function form(Form $form): Form
Expand Down
2 changes: 1 addition & 1 deletion app/Providers/AppServiceProvider.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
use Filament\Forms\Components\Field;
use Filament\Forms\Components\Placeholder;
use Filament\Infolists\Components\Entry;
use Filament\Support\Components\Component;
use Filament\Forms\Components\Component;
use Filament\Support\Concerns\Configurable;
use Filament\Tables\Columns\Column;
use Filament\Tables\Filters\BaseFilter;
Expand Down

0 comments on commit 5fcaf8e

Please sign in to comment.