File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed
packages/vue/src/components Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -62,6 +62,7 @@ export const DiffSplitViewWrap = defineComponent(
62
62
63
63
useSubscribeDiffFile ( props , ( diffFile ) => {
64
64
lines . value = getSplitContentLines ( diffFile ) ;
65
+ maxText . value = diffFile . splitLineLength . toString ( ) ;
65
66
} ) ;
66
67
67
68
const width = useTextWidth ( { text : maxText , font } ) ;
Original file line number Diff line number Diff line change @@ -99,7 +99,7 @@ export const DiffView = defineComponent<
99
99
watch (
100
100
( ) => props . diffFile ,
101
101
( ) => {
102
- diffFile . value . _destroy ?.( ) ;
102
+ diffFile . value ? ._destroy ?.( ) ;
103
103
diffFile . value = getInstance ( ) ;
104
104
} ,
105
105
{ immediate : true }
@@ -108,7 +108,7 @@ export const DiffView = defineComponent<
108
108
watch (
109
109
( ) => props . data ,
110
110
( ) => {
111
- diffFile . value . _destroy ?.( ) ;
111
+ diffFile . value ? ._destroy ?.( ) ;
112
112
diffFile . value = getInstance ( ) ;
113
113
} ,
114
114
{ immediate : true , deep : true }
You can’t perform that action at this time.
0 commit comments