File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed
Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change 22
33namespace App \Models ;
44
5- // use Illuminate\Contracts\Auth\MustVerifyEmail;
65use Filament \Models \Contracts \FilamentUser ;
6+ use Filament \Models \Contracts \HasAvatar ;
77use Filament \Panel ;
88use Illuminate \Database \Eloquent \Factories \HasFactory ;
99use Illuminate \Foundation \Auth \User as Authenticatable ;
1010use Illuminate \Notifications \Notifiable ;
1111use Laravel \Sanctum \HasApiTokens ;
1212
13- class User extends Authenticatable implements FilamentUser
13+ class User extends Authenticatable implements FilamentUser, HasAvatar
1414{
1515 use HasApiTokens, HasFactory, Notifiable;
1616
@@ -50,4 +50,16 @@ public function canAccessPanel(Panel $panel): bool
5050 // TODO: limit to defined domains
5151 return $ this ->hasVerifiedEmail ();
5252 }
53+
54+ public function getFilamentAvatarUrl (): ?string
55+ {
56+ return 'data:image/svg+xml;utf8, ' . <<<HTML
57+ <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="gray" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
58+ <path stroke="none" d="M0 0h24v24H0z" fill="none"/>
59+ <path d="M12 12m-9 0a9 9 0 1 0 18 0a9 9 0 1 0 -18 0" />
60+ <path d="M12 10m-3 0a3 3 0 1 0 6 0a3 3 0 1 0 -6 0" />
61+ <path d="M6.168 18.849a4 4 0 0 1 3.832 -2.849h4a4 4 0 0 1 3.834 2.855" />
62+ </svg>
63+ HTML ;
64+ }
5365}
You can’t perform that action at this time.
0 commit comments