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 {
21
21
} ,
22
22
watch : {
23
23
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
+ } ) ;
26
28
} ,
27
29
} ,
28
30
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ export default {
6
6
props : {
7
7
prefixCls : {
8
8
type : String ,
9
- default : 'ant-avatar' ,
9
+ default : undefined ,
10
10
} ,
11
11
shape : {
12
12
validator : val => [ 'circle' , 'square' ] . includes ( val ) ,
@@ -36,8 +36,12 @@ export default {
36
36
} ,
37
37
watch : {
38
38
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
+ } ) ;
41
45
} ,
42
46
} ,
43
47
mounted ( ) {
You can’t perform that action at this time.
0 commit comments