Files
opnform-host-nginx/api/resources/lang/tr/validation.php
Chirag Chhatrala d7ce8536c8 Add reCAPTCHA support and update captcha provider handling (#647)
* Add reCAPTCHA support and update captcha provider handling

- Introduced reCAPTCHA as an additional captcha provider alongside hCaptcha.
- Updated form request validation to handle different captcha providers based on user selection.
- Added a new validation rule for reCAPTCHA.
- Modified the forms model to include a 'captcha_provider' field.
- Created a migration to add the 'captcha_provider' column to the forms table.
- Updated frontend components to support dynamic rendering of captcha based on the selected provider.
- Enhanced tests to cover scenarios for both hCaptcha and reCAPTCHA.

These changes improve the flexibility of captcha options available to users, enhancing form security and user experience.

* fix pint

* change comment text

* Refactor captcha implementation and integrate new captcha components

- Removed the old RecaptchaV2 component and replaced it with a new implementation that supports both reCAPTCHA and hCaptcha through a unified CaptchaInput component.
- Updated the OpenForm component to utilize the new CaptchaInput for dynamic captcha rendering based on user-selected provider.
- Cleaned up the package.json by removing the deprecated @hcaptcha/vue3-hcaptcha dependency.
- Enhanced form initialization to set a default captcha provider.
- Improved error handling and cleanup for both reCAPTCHA and hCaptcha scripts.

These changes streamline captcha integration, improve maintainability, and enhance user experience by providing a more flexible captcha solution.

* Refactor captcha error messages and localization support

* Refactor registration process to integrate reCAPTCHA

- Replaced hCaptcha implementation with reCAPTCHA in RegisterController and related test cases.
- Updated validation rules to utilize g-recaptcha-response instead of h-captcha-response.
- Modified RegisterForm component to support reCAPTCHA, including changes to the form data structure and component references.
- Enhanced test cases to reflect the new reCAPTCHA integration, ensuring proper validation and response handling.

These changes improve security and user experience during the registration process by adopting a more widely used captcha solution.

* Fix reCAPTCHA configuration and update RegisterForm styling

- Corrected the configuration key for reCAPTCHA in RegisterController from 'services.recaptcha.secret_key' to 'services.re_captcha.secret_key'.
- Updated the styling of the Captcha input section in RegisterForm.vue to improve layout consistency.

These changes ensure proper reCAPTCHA functionality and enhance the user interface during the registration process.

* Fix reCAPTCHA configuration in RegisterTest to use the correct key format

- Updated the configuration key for reCAPTCHA in RegisterTest from 'services.recaptcha.secret_key' to 'services.re_captcha.secret_key' to ensure proper functionality during tests.

This change aligns the test setup with the recent updates in the reCAPTCHA integration, improving the accuracy of the registration process tests.

---------

Co-authored-by: Julien Nahum <julien@nahum.net>
2024-12-18 16:35:09 +01:00

139 lines
7.6 KiB
PHP
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<?php
return [
'accepted' => ':attribute kabul edilmelidir.',
'accepted_if' => ':other :value olduğunda :attribute kabul edilmelidir.',
'active_url' => ':attribute geçerli bir URL olmalıdır.',
'after' => ':attribute, :date tarihinden sonra olmalıdır.',
'after_or_equal' => ':attribute, :date tarihinden sonra veya aynı tarihte olmalıdır.',
'alpha' => ':attribute sadece harflerden oluşmalıdır.',
'alpha_dash' => ':attribute sadece harfler, rakamlar, tireler ve alt çizgilerden oluşmalıdır.',
'alpha_num' => ':attribute sadece harfler ve rakamlardan oluşmalıdır.',
'array' => ':attribute bir dizi olmalıdır.',
'before' => ':attribute, :date tarihinden önce olmalıdır.',
'before_or_equal' => ':attribute, :date tarihinden önce veya aynı tarihte olmalıdır.',
'between' => [
'array' => ':attribute :min ile :max arasında öğe içermelidir.',
'file' => ':attribute :min ile :max kilobayt arasında olmalıdır.',
'numeric' => ':attribute :min ile :max arasında olmalıdır.',
'string' => ':attribute :min ile :max karakter arasında olmalıdır.',
],
'boolean' => ':attribute alanı doğru veya yanlış olmalıdır.',
'confirmed' => ':attribute doğrulaması eşleşmiyor.',
'current_password' => 'Şifre yanlış.',
'date' => ':attribute geçerli bir tarih olmalıdır.',
'date_equals' => ':attribute, :date ile aynı tarihte olmalıdır.',
'date_format' => ':attribute, :format formatına uygun olmalıdır.',
'declined' => ':attribute reddedilmelidir.',
'declined_if' => ':other :value olduğunda :attribute reddedilmelidir.',
'different' => ':attribute ve :other birbirinden farklı olmalıdır.',
'digits' => ':attribute :digits basamaklı olmalıdır.',
'digits_between' => ':attribute :min ile :max basamak arasında olmalıdır.',
'dimensions' => ':attribute geçersiz resim boyutlarına sahip.',
'distinct' => ':attribute alanı yinelenen bir değere sahip.',
'email' => ':attribute geçerli bir e-posta adresi olmalıdır.',
'ends_with' => ':attribute şunlardan biriyle bitmelidir: :values.',
'enum' => 'Seçilen :attribute geçersiz.',
'exists' => 'Seçilen :attribute geçersiz.',
'file' => ':attribute bir dosya olmalıdır.',
'filled' => ':attribute alanı doldurulmalıdır.',
'gt' => [
'array' => ':attribute, :value öğeden fazla olmalıdır.',
'file' => ':attribute, :value kilobayttan büyük olmalıdır.',
'numeric' => ':attribute, :value değerinden büyük olmalıdır.',
'string' => ':attribute, :value karakterden uzun olmalıdır.',
],
'gte' => [
'array' => ':attribute, :value veya daha fazla öğe içermelidir.',
'file' => ':attribute, :value kilobayt veya daha büyük olmalıdır.',
'numeric' => ':attribute, :value veya daha büyük olmalıdır.',
'string' => ':attribute, :value karakter veya daha uzun olmalıdır.',
],
'image' => ':attribute bir resim olmalıdır.',
'in' => 'Seçilen :attribute geçersiz.',
'in_array' => ':attribute alanı :other içinde mevcut değil.',
'integer' => ':attribute bir tamsayı olmalıdır.',
'ip' => ':attribute geçerli bir IP adresi olmalıdır.',
'ipv4' => ':attribute geçerli bir IPv4 adresi olmalıdır.',
'ipv6' => ':attribute geçerli bir IPv6 adresi olmalıdır.',
'json' => ':attribute geçerli bir JSON dizesi olmalıdır.',
'lt' => [
'array' => ':attribute, :value öğeden az olmalıdır.',
'file' => ':attribute, :value kilobayttan küçük olmalıdır.',
'numeric' => ':attribute, :value değerinden küçük olmalıdır.',
'string' => ':attribute, :value karakterden kısa olmalıdır.',
],
'lte' => [
'array' => ':attribute, :value öğeden fazla olmamalıdır.',
'file' => ':attribute, :value kilobayt veya daha küçük olmalıdır.',
'numeric' => ':attribute, :value veya daha küçük olmalıdır.',
'string' => ':attribute, :value karakter veya daha kısa olmalıdır.',
],
'mac_address' => ':attribute geçerli bir MAC adresi olmalıdır.',
'max' => [
'array' => ':attribute en fazla :max öğe içermelidir.',
'file' => ':attribute en fazla :max kilobayt olmalıdır.',
'numeric' => ':attribute en fazla :max olmalıdır.',
'string' => ':attribute en fazla :max karakter olmalıdır.',
],
'mimes' => ':attribute şu dosya türlerinden biri olmalıdır: :values.',
'mimetypes' => ':attribute şu dosya türlerinden biri olmalıdır: :values.',
'min' => [
'array' => ':attribute en az :min öğe içermelidir.',
'file' => ':attribute en az :min kilobayt olmalıdır.',
'numeric' => ':attribute en az :min olmalıdır.',
'string' => ':attribute en az :min karakter olmalıdır.',
],
'multiple_of' => ':attribute, :value\'nin katı olmalıdır.',
'not_in' => 'Seçilen :attribute geçersiz.',
'not_regex' => ':attribute formatı geçersiz.',
'numeric' => ':attribute bir sayı olmalıdır.',
'password' => [
'letters' => ':attribute en az bir harf içermelidir.',
'mixed' => ':attribute en az bir büyük harf ve bir küçük harf içermelidir.',
'numbers' => ':attribute en az bir rakam içermelidir.',
'symbols' => ':attribute en az bir sembol içermelidir.',
'uncompromised' => 'Verilen :attribute bir veri sızıntısında görünmüş. Lütfen farklı bir :attribute seçin.',
],
'present' => ':attribute alanı mevcut olmalıdır.',
'prohibited' => ':attribute alanı yasaktır.',
'prohibited_if' => ':other :value olduğunda :attribute alanı yasaktır.',
'prohibited_unless' => ':other :values içinde olmadığı sürece :attribute alanı yasaktır.',
'prohibits' => ':attribute alanı :other\'ın mevcut olmasını yasaklar.',
'regex' => ':attribute formatı geçersiz.',
'required' => ':attribute alanı gereklidir.',
'required_array_keys' => ':attribute alanı şu girişleri içermelidir: :values.',
'required_if' => ':other :value olduğunda :attribute alanı gereklidir.',
'required_unless' => ':other :values içinde olmadığı sürece :attribute alanı gereklidir.',
'required_with' => ':values mevcut olduğunda :attribute alanı gereklidir.',
'required_with_all' => ':values mevcut olduğunda :attribute alanı gereklidir.',
'required_without' => ':values mevcut olmadığında :attribute alanı gereklidir.',
'required_without_all' => ':values hiçbiri mevcut olmadığında :attribute alanı gereklidir.',
'same' => ':attribute ve :other eşleşmelidir.',
'size' => [
'array' => ':attribute :size öğe içermelidir.',
'file' => ':attribute :size kilobayt olmalıdır.',
'numeric' => ':attribute :size olmalıdır.',
'string' => ':attribute :size karakter olmalıdır.',
],
'starts_with' => ':attribute şunlardan biriyle başlamalıdır: :values.',
'string' => ':attribute bir metin olmalıdır.',
'timezone' => ':attribute geçerli bir saat dilimi olmalıdır.',
'unique' => ':attribute zaten alınmış.',
'uploaded' => ':attribute yüklenemedi.',
'url' => ':attribute geçerli bir URL olmalıdır.',
'uuid' => ':attribute geçerli bir UUID olmalıdır.',
'custom' => [
'attribute-name' => [
'rule-name' => 'custom-message',
],
],
'attributes' => [],
'invalid_json' => 'Geçersiz girdi. Lütfen düzeltin ve tekrar deneyin.',
'invalid_captcha' => 'Geçersiz CAPTCHA. Lütfen bot olmadığınızı gösterin.',
'complete_captcha' => 'Lütfen CAPTCHA\'yı tamamlayın.',
];