Browse Source

Merge branch 'v2' of https://github.com/jdf2e/nutui into v2

Frans 6 years ago
parent
commit
6fdd4e17b1

+ 1 - 1
src/packages/scroller/scroller.scss

@@ -10,7 +10,7 @@
     // overflow: hidden;
     .nut-hor-list{
         height: 100%;
-        display: flex;
+        display: inline-flex;
         flex-direction: row;
         box-orient: horizontal;
         box-direction: normal;

+ 2 - 1
src/packages/stepper/demo.vue

@@ -74,7 +74,8 @@ export default {
     blur(e, v) {
       console.log('blur,', e, v)
     },
-    add() {
+    add(v) {
+      console.log(v)
       this.val1 = Number(this.val1) + 1;
     },
     reduce() {

+ 8 - 6
src/packages/stepper/stepper.vue

@@ -180,10 +180,11 @@ export default {
                         this.animTranslate_add = 0;
                     });
                 };
+                this.$emit('update:value', this.num);
+                this.$emit('add', this.num); 
+                this.$emit('change', this.num); 
             }
-            this.$emit('update:value', this.num);
-            this.$emit('add', this.num); 
-            this.$emit('change', this.num); 
+            
         },
         animEnd() {
             // unbind
@@ -207,10 +208,11 @@ export default {
                         this.animTranslate_ = -100;
                     }); 
                 }    
+                this.$emit('update:value', this.num);
+                this.$emit('reduce', this.num);
+                this.$emit('change', this.num);
             }
-            this.$emit('update:value', this.num);
-            this.$emit('reduce', this.num);
-            this.$emit('change', this.num);
+            
         },
 
     }