File tree Expand file tree Collapse file tree 2 files changed +11
-5
lines changed Expand file tree Collapse file tree 2 files changed +11
-5
lines changed Original file line number Diff line number Diff line change @@ -21,8 +21,10 @@ export default {
2121 } ,
2222 watch : {
2323 href ( val , oldVal ) {
24- this . antAnchor . unregisterLink ( oldVal ) ;
25- this . antAnchor . registerLink ( val ) ;
24+ this . $nextTick ( ( ) => {
25+ this . antAnchor . unregisterLink ( oldVal ) ;
26+ this . antAnchor . registerLink ( val ) ;
27+ } ) ;
2628 } ,
2729 } ,
2830
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ export default {
66 props : {
77 prefixCls : {
88 type : String ,
9- default : 'ant-avatar' ,
9+ default : undefined ,
1010 } ,
1111 shape : {
1212 validator : val => [ 'circle' , 'square' ] . includes ( val ) ,
@@ -36,8 +36,12 @@ export default {
3636 } ,
3737 watch : {
3838 src ( ) {
39- this . isImgExist = true ;
40- this . scale = 1 ;
39+ this . $nextTick ( ( ) => {
40+ this . isImgExist = true ;
41+ this . scale = 1 ;
42+ // force uodate for position
43+ this . $forceUpdate ( ) ;
44+ } ) ;
4145 } ,
4246 } ,
4347 mounted ( ) {
You can’t perform that action at this time.
0 commit comments