File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -166,6 +166,7 @@ const Base = defineComponent({
166166 } ) ;
167167 onMounted ( ( ) => {
168168 state . clientRendered = true ;
169+ syncEllipsis ( ) ;
169170 } ) ;
170171
171172 onBeforeUnmount ( ( ) => {
@@ -180,7 +181,7 @@ const Base = defineComponent({
180181 resizeOnNextFrame ( ) ;
181182 } ) ;
182183 } ,
183- { flush : 'post' , deep : true , immediate : true } ,
184+ { flush : 'post' , deep : true } ,
184185 ) ;
185186
186187 watchEffect ( ( ) => {
@@ -296,7 +297,12 @@ const Base = defineComponent({
296297 ) ;
297298
298299 // ============== Ellipsis ==============
299- function resizeOnNextFrame ( ) {
300+ function resizeOnNextFrame ( sizeInfo ?: { width : number ; height : number } ) {
301+ if ( sizeInfo ) {
302+ const { width, height } = sizeInfo ;
303+ if ( ! width || ! height ) return ;
304+ }
305+
300306 raf . cancel ( state . rafId ) ;
301307 state . rafId = raf ( ( ) => {
302308 // Do not bind `syncEllipsis`. It need for test usage on prototype
You can’t perform that action at this time.
0 commit comments