Skip to content

Commit

Permalink
Bump version to 0.3.1
Browse files Browse the repository at this point in the history
  • Loading branch information
apih committed Apr 14, 2024
1 parent c6c5979 commit 8999404
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 12 deletions.
3 changes: 2 additions & 1 deletion dist/locales/en.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* quival v0.3.0 (https://github.com/apih/quival)
* quival v0.3.1 (https://github.com/apih/quival)
* (c) 2023 Mohd Hafizuddin M Marzuki <hafizuddin_83@yahoo.com>
* Released under the MIT License.
*/
Expand Down Expand Up @@ -132,6 +132,7 @@ this.quival.locales.en = (function () {
required_array_keys: 'The :attribute field must contain entries for: :values.',
required_if: 'The :attribute field is required when :other is :value.',
required_if_accepted: 'The :attribute field is required when :other is accepted.',
required_if_declined: 'The :attribute field is required when :other is declined.',
required_unless: 'The :attribute field is required unless :other is in :values.',
required_with: 'The :attribute field is required when :values is present.',
required_with_all: 'The :attribute field is required when :values are present.',
Expand Down
4 changes: 2 additions & 2 deletions dist/locales/en.min.js

Large diffs are not rendered by default.

3 changes: 2 additions & 1 deletion dist/locales/ms.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* quival v0.3.0 (https://github.com/apih/quival)
* quival v0.3.1 (https://github.com/apih/quival)
* (c) 2023 Mohd Hafizuddin M Marzuki <hafizuddin_83@yahoo.com>
* Released under the MIT License.
*/
Expand Down Expand Up @@ -132,6 +132,7 @@ this.quival.locales.ms = (function () {
required_array_keys: 'Medan :attribute mesti mengandungi entri untuk: :values.',
required_if: 'Medan :attribute diperlukan apabila :other adalah :value.',
required_if_accepted: 'Medan :attribute diperlukan apabila :other diterima.',
required_if_declined: 'Medan :attribute diperlukan apabila :other ditolak.',
required_unless: 'Medan :attribute diperlukan melainkan :other berada dalam :values.',
required_with: 'Medan :attribute diperlukan apabila :values wujud.',
required_with_all: 'Medan :attribute diperlukan apabila semua :values wujud.',
Expand Down
4 changes: 2 additions & 2 deletions dist/locales/ms.min.js

Large diffs are not rendered by default.

12 changes: 11 additions & 1 deletion dist/quival.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*!
* quival v0.3.0 (https://github.com/apih/quival)
* quival v0.3.1 (https://github.com/apih/quival)
* (c) 2023 Mohd Hafizuddin M Marzuki <hafizuddin_83@yahoo.com>
* Released under the MIT License.
*/
Expand Down Expand Up @@ -412,6 +412,12 @@ var quival = (function (exports) {
}
return true;
}
checkRequiredIfDeclined(attribute, value, parameters) {
if (this.checkDeclined(parameters[0], this.validator.getValue(parameters[0]))) {
return this.checkRequired(attribute, value);
}
return true;
}
checkRequiredUnless(attribute, value, parameters) {
if (!this.isDependent(parameters)) {
return this.checkRequired(attribute, value);
Expand Down Expand Up @@ -1030,6 +1036,9 @@ var quival = (function (exports) {
replaceRequiredIfAccepted(message, attribute, rule, parameters) {
return this.replaceAcceptedIf(message, attribute, rule, parameters);
}
replaceRequiredIfDeclined(message, attribute, rule, parameters) {
return this.replaceAcceptedIf(message, attribute, rule, parameters);
}
replaceRequiredUnless(message, attribute, rule, parameters) {
return this.replace(message, {
other: this.validator.getDisplayableAttribute(parameters[0]),
Expand Down Expand Up @@ -1234,6 +1243,7 @@ var quival = (function (exports) {
'required',
'required_if',
'required_if_accepted',
'required_if_declined',
'required_unless',
'required_with',
'required_with_all',
Expand Down
4 changes: 2 additions & 2 deletions dist/quival.min.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "quival",
"version": "0.3.0",
"version": "0.3.1",
"description": "Data validation à la Laravel Validation",
"author": "Mohd Hafizuddin M Marzuki <hafizuddin_83@yahoo.com>",
"license": "MIT",
Expand Down

0 comments on commit 8999404

Please sign in to comment.