File tree Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Expand file tree Collapse file tree 1 file changed +13
-2
lines changed Original file line number Diff line number Diff line change 16
16
.js-validate-error-label {
17
17
margin-top : 5px ;
18
18
}
19
+
20
+ .form__radio , .form__checkbox {
21
+ margin-right : 7px !important ;
22
+ }
19
23
</ style >
20
24
</ head >
21
25
< body class ="container ">
@@ -46,7 +50,11 @@ <h2>Classic validation</h2>
46
50
< div class ="form-group ">
47
51
< label > < input type ="checkbox " class ="form__checkbox " data-validate-field ="checkbox2 " checked > I agree</ label >
48
52
</ div >
49
-
53
+ < div class ="form-group ">
54
+ < label > < input type ="radio " name ="radio " class ="form__radio " data-validate-field ="radio "> Male</ label >
55
+ < br >
56
+ < label > < input type ="radio " name ="radio " class ="form__radio " data-validate-field ="radio "> Female</ label >
57
+ </ div >
50
58
< button class ="form__btn btn btn-primary "> SUBMIT</ button >
51
59
</ form >
52
60
< br >
@@ -81,6 +89,9 @@ <h2>Remote validation with custom messages</h2>
81
89
< script >
82
90
new window . JustValidate ( '.js-form' , {
83
91
rules : {
92
+ radio : {
93
+ required : true
94
+ } ,
84
95
checkbox : {
85
96
required : true
86
97
} ,
@@ -146,4 +157,4 @@ <h2>Remote validation with custom messages</h2>
146
157
</ script >
147
158
148
159
</ body >
149
- </ html >
160
+ </ html >
You can’t perform that action at this time.
0 commit comments