1
1
/*!
2
- * Vue.js v2.5.0
2
+ * Vue.js v2.5.1
3
3
* (c) 2014-2017 Evan You
4
4
* Released under the MIT License.
5
5
*/
@@ -1470,7 +1470,7 @@ function normalizeProps (options, vm) {
1470
1470
? val
1471
1471
: { type : val } ;
1472
1472
}
1473
- } else if ( "development" !== 'production' && props ) {
1473
+ } else {
1474
1474
warn (
1475
1475
"Invalid value for option \"props\": expected an Array or an Object, " +
1476
1476
"but got " + ( toRawType ( props ) ) + "." ,
@@ -2099,14 +2099,16 @@ function normalizeArrayChildren (children, nestedIndex) {
2099
2099
lastIndex = res . length - 1 ;
2100
2100
last = res [ lastIndex ] ;
2101
2101
// nested
2102
- if ( Array . isArray ( c ) && c . length > 0 ) {
2103
- c = normalizeArrayChildren ( c , ( ( nestedIndex || '' ) + "_" + i ) ) ;
2104
- // merge adjacent text nodes
2105
- if ( isTextNode ( c [ 0 ] ) && isTextNode ( last ) ) {
2106
- res [ lastIndex ] = createTextVNode ( last . text + ( c [ 0 ] ) . text ) ;
2107
- c . shift ( ) ;
2108
- }
2109
- res . push . apply ( res , c ) ;
2102
+ if ( Array . isArray ( c ) ) {
2103
+ if ( c . length > 0 ) {
2104
+ c = normalizeArrayChildren ( c , ( ( nestedIndex || '' ) + "_" + i ) ) ;
2105
+ // merge adjacent text nodes
2106
+ if ( isTextNode ( c [ 0 ] ) && isTextNode ( last ) ) {
2107
+ res [ lastIndex ] = createTextVNode ( last . text + ( c [ 0 ] ) . text ) ;
2108
+ c . shift ( ) ;
2109
+ }
2110
+ res . push . apply ( res , c ) ;
2111
+ }
2110
2112
} else if ( isPrimitive ( c ) ) {
2111
2113
if ( isTextNode ( last ) ) {
2112
2114
// merge adjacent text nodes
@@ -3809,7 +3811,7 @@ function bindObjectListeners (data, value) {
3809
3811
for ( var key in value ) {
3810
3812
var existing = on [ key ] ;
3811
3813
var ours = value [ key ] ;
3812
- on [ key ] = existing ? [ ] . concat ( ours , existing ) : ours ;
3814
+ on [ key ] = existing ? [ ] . concat ( existing , ours ) : ours ;
3813
3815
}
3814
3816
}
3815
3817
}
@@ -4886,7 +4888,7 @@ Object.defineProperty(Vue$3.prototype, '$ssrContext', {
4886
4888
}
4887
4889
} ) ;
4888
4890
4889
- Vue$3 . version = '2.5.0 ' ;
4891
+ Vue$3 . version = '2.5.1 ' ;
4890
4892
4891
4893
/* */
4892
4894
@@ -6543,6 +6545,7 @@ var warn$1;
6543
6545
// in some cases, the event used has to be determined at runtime
6544
6546
// so we used some reserved tokens during compile.
6545
6547
var RANGE_TOKEN = '__r' ;
6548
+ var CHECKBOX_RADIO_TOKEN = '__c' ;
6546
6549
6547
6550
function model (
6548
6551
el ,
@@ -6706,6 +6709,13 @@ function normalizeEvents (on) {
6706
6709
on [ event ] = [ ] . concat ( on [ RANGE_TOKEN ] , on [ event ] || [ ] ) ;
6707
6710
delete on [ RANGE_TOKEN ] ;
6708
6711
}
6712
+ // This was originally intended to fix #4521 but no longer necessary
6713
+ // after 2.5. Keeping it for backwards compat with generated code from < 2.4
6714
+ /* istanbul ignore if */
6715
+ if ( isDef ( on [ CHECKBOX_RADIO_TOKEN ] ) ) {
6716
+ on . change = [ ] . concat ( on [ CHECKBOX_RADIO_TOKEN ] , on . change || [ ] ) ;
6717
+ delete on [ CHECKBOX_RADIO_TOKEN ] ;
6718
+ }
6709
6719
}
6710
6720
6711
6721
var target$1 ;
@@ -8064,6 +8074,10 @@ var TransitionGroup = {
8064
8074
children . forEach ( applyTranslation ) ;
8065
8075
8066
8076
// force reflow to put everything in position
8077
+ // assign to this to avoid being removed in tree-shaking
8078
+ // $flow-disable-line
8079
+ this . _reflow = document . body . offsetHeight ;
8080
+
8067
8081
children . forEach ( function ( c ) {
8068
8082
if ( c . data . moved ) {
8069
8083
var el = c . elm ;
@@ -9320,7 +9334,7 @@ function preTransformNode (el, options) {
9320
9334
addRawAttr ( branch0 , 'type' , 'checkbox' ) ;
9321
9335
processElement ( branch0 , options ) ;
9322
9336
branch0 . processed = true ; // prevent it from double-processed
9323
- branch0 . if = "type ==='checkbox'" + ifConditionExtra ;
9337
+ branch0 . if = "(" + typeBinding + ") ==='checkbox'" + ifConditionExtra ;
9324
9338
addIfCondition ( branch0 , {
9325
9339
exp : branch0 . if ,
9326
9340
block : branch0
@@ -9331,7 +9345,7 @@ function preTransformNode (el, options) {
9331
9345
addRawAttr ( branch1 , 'type' , 'radio' ) ;
9332
9346
processElement ( branch1 , options ) ;
9333
9347
addIfCondition ( branch0 , {
9334
- exp : "type ==='radio'" + ifConditionExtra ,
9348
+ exp : "(" + typeBinding + ") ==='radio'" + ifConditionExtra ,
9335
9349
block : branch1
9336
9350
} ) ;
9337
9351
// 3. other
0 commit comments