['required', 'file', 'mimes:'.implode(',', self::EXTENSIONS), 'max:'.self::MAX_KILOBYTES], ]; } // `label` is the admin-authored field label, only used as the // :attribute in the validation message shown next to that field. protected function validationAttributes(Request $request): array { return ['file' => (string) $request->input('label', 'file')]; } }