Skip to content

Commit 56995b6

Browse files
author
Edward Xiao
authored
Update README.md
1 parent 5d2a34b commit 56995b6

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ import 'react-inputs-validation/lib/react-inputs-validation.min.css';
3131

3232
[Textarea](#Textarea)
3333

34-
[Custom Error Message Guid(can be multiple locales)](#CustomErrorMessage)
34+
[Custom Error Message Guid(can be multiple locales)](#custom-error-message)
3535

3636
[Phone and email validation example](#phone-email-validation-example)(Since the phone and email validation are no longer handled internally after v1.4.0.)
3737

@@ -85,7 +85,7 @@ Tested on IE9+ and Chrome and Safari(10.0.3)
8585
|**<a name="customFunc"></a>validationOption.customFunc** |**Opt**|**Func**|**Custom function. Returns true or err message.**| **none** |
8686
|**validationOption.reg** |**Opt**|**Bool**|**Custom regex.**|**""** |
8787
|**validationOption.regMsg** |**Opt**|**Str** |**Custom regex error message.**|**""** |
88-
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#CustomErrorMessage)' section, which provides the extensibility for your own locale.**|**"en-US"** |
88+
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#custom-error-message)' section, which provides the extensibility for your own locale.**|**"en-US"** |
8989
|~~**validationOption.phoneCountry**~~|~~**Opt**~~|~~**Str**~~|~~**Useful when the validationOption['type'] is phone. Check if the phone number matchs en-US phone number format.**~~ <br><br>**No longer support after v1.4.0. For phone or email address validation please reffer to '[Phone and email validation example](#phone-email-validation-example)'**|~~**"en-US"**~~|
9090
|**validationOption.msgOnError** |**Opt**|**Str** |**Show your custom error message no matter what when it has error if it is provied.**|**""** |
9191
|**validationOption.msgOnSuccess** |**Opt**|**Str** |**Show your custom success message no matter what when it has error if it is provied.**|**""** |
@@ -177,7 +177,7 @@ import 'react-inputs-validation/lib/react-inputs-validation.min.css';
177177
|**validationOption.check** |**Opt**|**Bool**|**To determin if you need to validate.**|**true** |
178178
|**validationOption.required** |**Opt**|**Bool**|**To determin if it is a required field.**|**true** |
179179
|**validationOption.showMsg** |**Opt**|**Bool**|**To determin display the error message or not.**|**true** |
180-
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#CustomErrorMessage)' section, which provides the extensibility for your own locale.**|**"en-US"** |
180+
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#custom-error-message)' section, which provides the extensibility for your own locale.**|**"en-US"** |
181181
|**validationOption.msgOnError** |**Opt**|**Str** |**Show your custom error message no matter what when it has error if it is provied.**|**""** |
182182
|**validationOption.msgOnSuccess** |**Opt**|**Str** |**Show your custom success message no matter what when it has error if it is provied.**|**""** |
183183

@@ -259,7 +259,7 @@ import 'react-inputs-validation/lib/react-inputs-validation.min.css';
259259
|**validationOption.check** |**Opt**|**Bool**|**To determin if you need to validate.**|**true** |
260260
|**validationOption.required** |**Opt**|**Bool**|**To determin if it is a required field.**|**true** |
261261
|**validationOption.showMsg** |**Opt**|**Bool**|**To determin display the error message or not.**|**true** |
262-
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#CustomErrorMessage)' section, which provides the extensibility for your own locale.**|**"en-US"** |
262+
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#custom-error-message)' section, which provides the extensibility for your own locale.**|**"en-US"** |
263263
|**validationOption.msgOnError** |**Opt**|**Str** |**Show your custom error message no matter what when it has error if it is provied.**|**""** |
264264
|**validationOption.msgOnSuccess** |**Opt**|**Str** |**Show your custom success message no matter what when it has error if it is provied.**|**""** |
265265
```js
@@ -346,7 +346,7 @@ import 'react-inputs-validation/lib/react-inputs-validation.min.css';
346346
|**validationOption.check** |**Opt**|**Bool**|**To determin if you need to validate.**|**true** |
347347
|**validationOption.required** |**Opt**|**Bool**|**To determin if it is a required field.**|**true** |
348348
|**validationOption.showMsg** |**Opt**|**Bool**|**To determin display the error message or not.**|**true** |
349-
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#CustomErrorMessage)' section, which provides the extensibility for your own locale.**|**"en-US"** |
349+
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#custom-error-message)' section, which provides the extensibility for your own locale.**|**"en-US"** |
350350
|**validationOption.msgOnError** |**Opt**|**Str** |**Show your custom error message no matter what when it has error if it is provied.**|**""** |
351351
|**validationOption.msgOnSuccess** |**Opt**|**Str** |**Show your custom success message no matter what when it has error if it is provied.**|**""** |
352352
@@ -452,7 +452,7 @@ import 'react-inputs-validation/lib/react-inputs-validation.min.css';
452452
|**validationOption.customFunc** |**Opt**|**Func**|**Custom function. Returns true or err message.**| **none** |
453453
|**validationOption.reg** |**Opt**|**Bool**|**Custom regex.**|**""** |
454454
|**validationOption.regMsg** |**Opt**|**Str** |**Custom regex error message.**|**""** |
455-
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#CustomErrorMessage)' section, which provides the extensibility for your own locale.**|**"en-US"** |
455+
|**validationOption.locale** |**Opt**|**Str** |**For error message display. Current options are ['zh-CN', 'en-US']; Default is 'en-US'. If your are looking for more options, you can take a look at '[window.REACT_INPUTS_VALIDATION](#custom-error-message)' section, which provides the extensibility for your own locale.**|**"en-US"** |
456456
|**validationOption.msgOnError** |**Opt**|**Str** |**Show your custom error message no matter what when it has error if it is provied.**|**""** |
457457
|**validationOption.msgOnSuccess** |**Opt**|**Str** |**Show your custom success message no matter what when it has error if it is provied.**|**""** |
458458
@@ -552,7 +552,7 @@ import 'react-inputs-validation/lib/react-inputs-validation.min.css';
552552
/>
553553
```
554554
555-
### <a name="CustomErrorMessage"></a>Custom Error Message (can be multiple locales)
555+
### <a name="custom-error-message"></a>Custom Error Message (can be multiple locales)
556556
By providing ```window.REACT_INPUTS_VALIDATION['customErrorMessage']```, you can overwrite the error message.
557557
558558
**IMPORTANT NOTE: YOU WILL NEED TO PLACE window.REACT_INPUTS_VALIDATION BEFORE YOUR JS SCRIPT**

0 commit comments

Comments
 (0)