@@ -10,17 +10,17 @@ import utils from "../../core/utils";
1010import registry from "../../core/registry" ;
1111
1212const logger = logging . getLogger ( "pat-validation" ) ;
13- //logger.setLevel(logging.Level.DEBUG);
13+
1414
1515export const parser = new Parser ( "validation" ) ;
1616parser . addArgument ( "disable-selector" , "[type=submit], button:not([type=button])" ) ; // Elements which must be disabled if there are errors
17- parser . addArgument ( "message-date" , "" ) ; // "This value must be a valid date");
18- parser . addArgument ( "message-datetime" , "" ) ; // "This value must be a valid date and time");
19- parser . addArgument ( "message-email" , "" ) ; // "This value must be a valid email address");
20- parser . addArgument ( "message-max" , "" ) ; // "This value must be less than or equal to %{count}");
21- parser . addArgument ( "message-min" , "" ) ; // "This value must be greater than or equal to %{count}"); // prettier-ignore
22- parser . addArgument ( "message-number" , "" ) ; // "This value must be a number");
23- parser . addArgument ( "message-required" , "" ) ; // "This field is required");
17+ parser . addArgument ( "message-date" , "" ) ; // "This value must be a valid date"
18+ parser . addArgument ( "message-datetime" , "" ) ; // "This value must be a valid date and time"
19+ parser . addArgument ( "message-email" , "" ) ; // "This value must be a valid email address"
20+ parser . addArgument ( "message-max" , "" ) ; // "This value must be less than or equal to %{count}"
21+ parser . addArgument ( "message-min" , "" ) ; // "This value must be greater than or equal to %{count}"
22+ parser . addArgument ( "message-number" , "" ) ; // "This value must be a number"
23+ parser . addArgument ( "message-required" , "" ) ; // "This field is required"
2424parser . addArgument ( "message-equality" , "is not equal to %{attribute}." ) ;
2525parser . addArgument ( "not-after" , null ) ;
2626parser . addArgument ( "not-before" , null ) ;
@@ -121,19 +121,7 @@ class Pattern extends BasePattern {
121121 return ;
122122 }
123123
124- logger . debug ( `
125- validity_state.badInput ${ validity_state . badInput }
126- validity_state.customError ${ validity_state . customError }
127- validity_state.patternMismatch ${ validity_state . patternMismatch }
128- validity_state.rangeOverflow ${ validity_state . rangeOverflow }
129- validity_state.rangeUnderflow ${ validity_state . rangeUnderflow }
130- validity_state.stepMismatch ${ validity_state . stepMismatch }
131- validity_state.tooLong ${ validity_state . tooLong }
132- validity_state.tooShort ${ validity_state . tooShort }
133- validity_state.typeMismatch ${ validity_state . typeMismatch }
134- validity_state.valid ${ validity_state . valid }
135- validity_state.valueMissing ${ validity_state . valueMissing }
136- ` ) ;
124+ logger . debug ( `validity_state: ` , validity_state ) ;
137125
138126 const input_options = parser . parse ( input ) ;
139127
0 commit comments