ソースを参照

upd(ellipsis): add lineHeight props

suzigang 3 年 前
コミット
b09b11d515

+ 2 - 2
src/packages/__VUE/actionsheet/__test__/__snapshots__/index.spec.ts.snap

@@ -3,10 +3,10 @@
 exports[`should render sure actionsheet when use custom props 1`] = `
 "<view class=\\"nut-actionsheet\\">
   <view>
-    <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+    <transition-stub class=\\"\\">
       <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000;\\"></view>
     </transition-stub>
-    <transition-stub name=\\"popup-fade-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+    <transition-stub>
       <view class=\\"nut-popup round popup-bottom popclass\\" style=\\"z-index: 2000; animation-duration: 0.3s;\\">
         <view class=\\"nut-actionsheet-panel\\">
           <!--v-if-->

+ 72 - 72
src/packages/__VUE/cascader/__tests__/__snapshots__/cascader.spec.ts.snap

@@ -1,11 +1,11 @@
 // Jest Snapshot v1, https://goo.gl/fbAQLP
 
 exports[`Cascader change tab 1`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2002;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2002; animation-duration: 0.3s;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -66,11 +66,11 @@ exports[`Cascader change tab 1`] = `
 `;
 
 exports[`Cascader change tab 2`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2002;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2002; animation-duration: 0.3s;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -131,11 +131,11 @@ exports[`Cascader change tab 2`] = `
 `;
 
 exports[`Cascader change tab 3`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2002;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2002; animation-duration: 0.3s;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -196,11 +196,11 @@ exports[`Cascader change tab 3`] = `
 `;
 
 exports[`Cascader modelValue 1`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-fade-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -228,11 +228,11 @@ exports[`Cascader modelValue 1`] = `
 `;
 
 exports[`Cascader modelValue 2`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -293,11 +293,11 @@ exports[`Cascader modelValue 2`] = `
 `;
 
 exports[`Cascader modelValue 3`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -331,11 +331,11 @@ exports[`Cascader modelValue 3`] = `
 `;
 
 exports[`Cascader modelValue 4`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -369,11 +369,11 @@ exports[`Cascader modelValue 4`] = `
 `;
 
 exports[`Cascader modelValue with lazy 1`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -397,11 +397,11 @@ exports[`Cascader modelValue with lazy 1`] = `
 `;
 
 exports[`Cascader modelValue with lazy 2`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -465,11 +465,11 @@ exports[`Cascader modelValue with lazy 2`] = `
 `;
 
 exports[`Cascader options 1`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -530,11 +530,11 @@ exports[`Cascader options 1`] = `
 `;
 
 exports[`Cascader options with convertConfig 1`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -577,11 +577,11 @@ exports[`Cascader options with convertConfig 1`] = `
 `;
 
 exports[`Cascader options with valueKey/textKey/childrenKey 1`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -642,11 +642,11 @@ exports[`Cascader options with valueKey/textKey/childrenKey 1`] = `
 `;
 
 exports[`Cascader select 1`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -680,11 +680,11 @@ exports[`Cascader select 1`] = `
 `;
 
 exports[`Cascader select 2`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -745,11 +745,11 @@ exports[`Cascader select 2`] = `
 `;
 
 exports[`Cascader select 3`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -810,11 +810,11 @@ exports[`Cascader select 3`] = `
 `;
 
 exports[`Cascader select 4`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -848,11 +848,11 @@ exports[`Cascader select 4`] = `
 `;
 
 exports[`Cascader select with lazy 1`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-fade-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -870,11 +870,11 @@ exports[`Cascader select with lazy 1`] = `
 `;
 
 exports[`Cascader select with lazy 2`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -905,11 +905,11 @@ exports[`Cascader select with lazy 2`] = `
 `;
 
 exports[`Cascader select with lazy 3`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -955,11 +955,11 @@ exports[`Cascader select with lazy 3`] = `
 `;
 
 exports[`Cascader select with lazy 4`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -1020,11 +1020,11 @@ exports[`Cascader select with lazy 4`] = `
 `;
 
 exports[`Cascader select with lazy 5`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -1085,11 +1085,11 @@ exports[`Cascader select with lazy 5`] = `
 `;
 
 exports[`Cascader select with lazy 6`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -1120,11 +1120,11 @@ exports[`Cascader select with lazy 6`] = `
 `;
 
 exports[`Cascader select with lazy 7`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000; display: none;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2000; animation-duration: 0.3s; display: none;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">
@@ -1170,11 +1170,11 @@ exports[`Cascader select with lazy 7`] = `
 `;
 
 exports[`Cascader visible 1`] = `
-"<teleport-stub to=\\"body\\">
-  <transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\" class=\\"\\">
+"<teleport-stub>
+  <transition-stub class=\\"\\">
     <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2001;\\"></view>
   </transition-stub>
-  <transition-stub name=\\"popup-slide-bottom\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+  <transition-stub>
     <view class=\\"nut-popup round popup-bottom nut-cascader__popup\\" style=\\"z-index: 2001; animation-duration: 0.3s;\\">
       <!--v-if-->
       <view class=\\"nut-tabs horizontal nut-cascader\\" id=\\"container\\">

+ 3 - 3
src/packages/__VUE/ellipsis/__tests__/__snapshots__/ellipsis.spec.ts.snap

@@ -4,7 +4,7 @@ exports[`Ellipsis Props Direction Middle 1`] = `
 "<view class=\\"nut-ellipsis\\">
   <!--v-if-->
   <view>NutUI3.0上线后我们研发团队...
-    <!--v-if-->...UI 中增加小程序多端适配的能力。
+    <!--v-if--> ...UI 中增加小程序多端适配的能力。
   </view>
   <!--v-if-->
 </view>"
@@ -14,7 +14,7 @@ exports[`Ellipsis Props Direction Start 1`] = `
 "<view class=\\"nut-ellipsis\\">
   <!--v-if-->
   <view>
-    <!--v-if-->...多的开发者带来便利,我们决定在 NutUI 中增加小程序多端适配的能力。
+    <!--v-if--> ...多的开发者带来便利,我们决定在 NutUI 中增加小程序多端适配的能力。
   </view>
   <!--v-if-->
 </view>"
@@ -24,7 +24,7 @@ exports[`Ellipsis Props Rows 1`] = `
 "<view class=\\"nut-ellipsis\\">
   <!--v-if-->
   <view>
-    <!--v-if-->... 的相关组件,但是在跨端小程序的开发过程中,发现没有合适的组件库可以支持多端开发。为了填补这一空白,同时为了优化开发者体验,让 NutUI 能够为更多的开发者带来便利,我们决定在 NutUI 中增加小程序多端适配的能力。
+    <!--v-if--> ... 的相关组件,但是在跨端小程序的开发过程中,发现没有合适的组件库可以支持多端开发。为了填补这一空白,同时为了优化开发者体验,让 NutUI 能够为更多的开发者带来便利,我们决定在 NutUI 中增加小程序多端适配的能力。
   </view>
   <!--v-if-->
 </view>"

+ 1 - 0
src/packages/__VUE/ellipsis/doc.en-US.md

@@ -93,6 +93,7 @@ app.use(Ellipsis);
 | expand-text         | Expand text               | String | ''              |
 | collapse-text         | Collapse text               | String | ''               |
 | symbol         | Symbol     | String | '...'       |
+| line-height`v3.2.4`           | the row height of the container     | String、Number | 20       |
 
 ### Events
 

+ 1 - 0
src/packages/__VUE/ellipsis/doc.md

@@ -93,6 +93,7 @@ app.use(Ellipsis);
 | expand-text         | 展开操作的文案               | String | ''              |
 | collapse-text         | 收起操作的文案               | String | ''               |
 | symbol         | 省略的符号     | String | '...'       |
+| line-height`v3.2.4`           | 容器的行高     | String、Number | 20       |
 
 ### Events
 

+ 1 - 0
src/packages/__VUE/ellipsis/index.scss

@@ -1,4 +1,5 @@
 .nut-ellipsis {
+  display: flex;
   .nut-ellipsis-text {
     cursor: hand;
     color: $ellipsis-expand-collapse-color;

+ 26 - 22
src/packages/__VUE/ellipsis/index.taro.vue

@@ -1,26 +1,28 @@
 <template>
-  <view :class="classes" @click="handleClick" ref="root" :id="'root' + refRandomId">
-    <view v-if="!exceeded">{{ content }}</view>
+  <view>
+    <view :class="classes" @click="handleClick" ref="root" :id="'root' + refRandomId">
+      <view v-if="!exceeded">{{ content }}</view>
 
-    <view v-if="exceeded && !expanded">
-      {{ ellipsis.leading
-      }}<view class="nut-ellipsis-text" v-if="expandText" @click.stop="clickHandle(1)">{{ expandText }}</view
-      >{{ ellipsis.tailing }}
+      <view v-if="exceeded && !expanded">
+        {{ ellipsis.leading
+        }}<view class="nut-ellipsis-text" v-if="expandText" @click.stop="clickHandle(1)">{{ expandText }}</view
+        >{{ ellipsis.tailing }}
+      </view>
+      <view v-if="exceeded && expanded">
+        {{ content }}
+        <span class="nut-ellipsis-text" v-if="expandText" @click.stop="clickHandle(2)">{{ collapseText }}</span>
+      </view>
     </view>
-    <view v-if="exceeded && expanded">
-      {{ content }}
-      <span class="nut-ellipsis-text" v-if="expandText" @click.stop="clickHandle(2)">{{ collapseText }}</span>
-    </view>
-  </view>
 
-  <view
-    class="nut-ellipsis-copy"
-    @click="handleClick"
-    ref="rootContain"
-    :id="'rootContain' + refRandomId"
-    :style="{ width: widthRef }"
-  >
-    <view>{{ contantCopy }}</view>
+    <view
+      class="nut-ellipsis-copy"
+      @click="handleClick"
+      ref="rootContain"
+      :id="'rootContain' + refRandomId"
+      :style="{ width: widthRef }"
+    >
+      <view>{{ contantCopy }}</view>
+    </view>
   </view>
 </template>
 
@@ -62,6 +64,10 @@ export default create({
     symbol: {
       type: String,
       default: '...'
+    },
+    lineHeight: {
+      type: [Number, String],
+      default: '20'
     }
   },
   emits: ['click', 'change'],
@@ -119,7 +125,7 @@ export default create({
               computedStyle: ['width', 'height', 'lineHeight', 'paddingTop', 'paddingBottom']
             },
             (res) => {
-              lineHeight = pxToNumber(res.lineHeight);
+              lineHeight = pxToNumber(res.lineHeight === 'normal' ? props.lineHeight : res.lineHeight);
               maxHeight = Math.floor(
                 lineHeight * (Number(props.rows) + 0.5) + pxToNumber(res.paddingTop) + pxToNumber(res.paddingBottom)
               );
@@ -163,8 +169,6 @@ export default create({
     // 计算 start/end 省略
     const tailor = async (left: number, right: number) => {
       const actionText = state.expanded ? props.collapseText : props.expandText;
-
-      console.log(actionText);
       const end = props.content.length;
 
       if (right - left <= 1) {

+ 10 - 7
src/packages/__VUE/ellipsis/index.vue

@@ -2,9 +2,9 @@
   <view :class="classes" @click="handleClick" ref="root">
     <view v-if="!exceeded">{{ content }}</view>
     <view v-if="exceeded && !expanded">
-      {{ ellipsis.leading
-      }}<span class="nut-ellipsis-text" v-if="expandText" @click.stop="clickHandle(1)">{{ expandText }}</span
-      >{{ ellipsis.tailing }}
+      {{ ellipsis.leading }}
+      <span class="nut-ellipsis-text" v-if="expandText" @click.stop="clickHandle(1)">{{ expandText }}</span>
+      {{ ellipsis.tailing }}
     </view>
     <view v-if="exceeded && expanded">
       {{ content }}
@@ -48,6 +48,10 @@ export default create({
     symbol: {
       type: String,
       default: '...'
+    },
+    lineHeight: {
+      type: [Number, String],
+      default: '20'
     }
   },
   emits: ['click', 'change'],
@@ -105,7 +109,7 @@ export default create({
       container.style.whiteSpace = 'normal';
       container.style.webkitLineClamp = 'unset';
       container.style.display = 'block';
-      const lineHeight = pxToNumber(originStyle.lineHeight);
+      const lineHeight = pxToNumber(originStyle.lineHeight === 'normal' ? props.lineHeight : originStyle.lineHeight);
       maxHeight = Math.floor(
         lineHeight * (Number(props.rows) + 0.5) +
           pxToNumber(originStyle.paddingTop) +
@@ -114,7 +118,6 @@ export default create({
 
       container.innerText = props.content;
       document.body.appendChild(container);
-
       calcEllipse();
     };
 
@@ -202,9 +205,9 @@ export default create({
       }
     };
 
-    const pxToNumber = (value: string | null) => {
+    const pxToNumber = (value: string | null | number) => {
       if (!value) return 0;
-      const match = value.match(/^\d*(\.\d*)?/);
+      const match = (value as string).match(/^\d*(\.\d*)?/);
       return match ? Number(match[0]) : 0;
     };
 

+ 1 - 1
src/packages/__VUE/overlay/__tests__/__snapshots__/overlay.spec.ts.snap

@@ -1,7 +1,7 @@
 // Jest Snapshot v1, https://goo.gl/fbAQLP
 
 exports[`slots test 1`] = `
-"<transition-stub name=\\"overlay-fade\\" appear=\\"false\\" persisted=\\"true\\" css=\\"true\\">
+"<transition-stub>
   <view class=\\"nut-overlay\\" style=\\"animation-duration: 0.3s; z-index: 2000;\\">这里是正文</view>
 </transition-stub>"
 `;