more fixes
This commit is contained in:
29
app/Http/Requests/Settings/UpdateProfileSectionRequest.php
Normal file
29
app/Http/Requests/Settings/UpdateProfileSectionRequest.php
Normal file
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace App\Http\Requests\Settings;
|
||||
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
|
||||
class UpdateProfileSectionRequest extends FormRequest
|
||||
{
|
||||
public function authorize(): bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
public function rules(): array
|
||||
{
|
||||
return [
|
||||
'display_name' => ['required', 'string', 'max:60'],
|
||||
'website' => ['nullable', 'url', 'max:255'],
|
||||
'bio' => ['nullable', 'string', 'max:200'],
|
||||
'signature' => ['nullable', 'string', 'max:1000'],
|
||||
'description' => ['nullable', 'string', 'max:1000'],
|
||||
'avatar' => ['nullable', 'file', 'image', 'max:2048', 'mimes:jpg,jpeg,png,webp', 'mimetypes:image/jpeg,image/png,image/webp'],
|
||||
'remove_avatar' => ['nullable', 'boolean'],
|
||||
'avatar_position' => ['nullable', 'in:top-left,top,top-right,left,center,right,bottom-left,bottom,bottom-right'],
|
||||
];
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user