File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -23,7 +23,7 @@ class Test extends React.Component {
2323
2424 onVcode2Change ( v ) {
2525 console . log ( '触发回调onChange' , v ) ;
26- if ( v ) {
26+ if ( v ) {
2727 this . setState ( {
2828 vcode2 : v ,
2929 } ) ;
@@ -35,7 +35,7 @@ class Test extends React.Component {
3535 this . setState ( {
3636 img : imgindex ,
3737 code : imgindex === 1 ? ImgTest1 : ImgTest2 ,
38- vcode2 : '1234'
38+ vcode2 : '1234' ,
3939 } ) ;
4040 }
4141 onChangeStr ( ) {
@@ -53,19 +53,19 @@ class Test extends React.Component {
5353 onVcodeClick ( ) {
5454 this . onChangeStr ( ) ;
5555 }
56- onChangeWidth ( ) {
56+ onChangeWidth ( ) {
5757 const l = Math . round ( Math . random ( ) * 800 + 400 ) ;
5858 console . log ( '改变width:' , l ) ;
5959 this . setState ( {
60- width : l
60+ width : l ,
6161 } ) ;
6262 }
6363 render ( ) {
6464 return (
6565 < div >
6666 < div >
6767 < input type = "text" placeholder = "请输入正确的验证码" value = { this . state . input2 } onChange = { e => this . onInput2Change ( e ) } maxLength = { 20 } />
68- < Vcode onChange = { ( v ) => this . onVcode2Change ( v ) } value = { this . state . code } width = { this . state . width } />
68+ < Vcode onChange = { v => this . onVcode2Change ( v ) } value = { this . state . code } width = { this . state . width } />
6969 < span > { this . state . input2 === this . state . vcode2 ? '输入正确' : '输入错误' } </ span >
7070 </ div >
7171 < hr />
You can’t perform that action at this time.
0 commit comments