Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit2856544

Browse files
committed
[build] 2.1.8
1 parentfcc98d5 commit2856544

File tree

10 files changed

+299
-117
lines changed

10 files changed

+299
-117
lines changed

‎dist/vue.common.js‎

Lines changed: 66 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* Vue.js v2.1.7
2+
* Vue.js v2.1.8
33
* (c) 2014-2016 Evan You
44
* Released under the MIT License.
55
*/
@@ -82,10 +82,10 @@ function isPrimitive (value) {
8282
*/
8383
functioncached(fn){
8484
varcache=Object.create(null);
85-
returnfunctioncachedFn(str){
85+
return(functioncachedFn(str){
8686
varhit=cache[str];
8787
returnhit||(cache[str]=fn(str))
88-
}
88+
})
8989
}
9090

9191
/**
@@ -1300,7 +1300,7 @@ function assertProp (
13001300
}
13011301
for(vari=0;i<type.length&&!valid;i++){
13021302
varassertedType=assertType(value,type[i]);
1303-
expectedTypes.push(assertedType.expectedType);
1303+
expectedTypes.push(assertedType.expectedType||'');
13041304
valid=assertedType.valid;
13051305
}
13061306
}
@@ -1791,9 +1791,8 @@ Watcher.prototype.teardown = function teardown () {
17911791
if(this.active){
17921792
// remove self from vm's watcher list
17931793
// this is a somewhat expensive operation so we skip it
1794-
// if the vm is being destroyed or is performing a v-for
1795-
// re-render (the watcher list is then filtered by v-for).
1796-
if(!this.vm._isBeingDestroyed&&!this.vm._vForRemoving){
1794+
// if the vm is being destroyed.
1795+
if(!this.vm._isBeingDestroyed){
17971796
remove$1(this.vm._watchers,this);
17981797
}
17991798
vari=this.deps.length;
@@ -1933,6 +1932,14 @@ var computedSharedDefinition = {
19331932

19341933
functioninitComputed(vm,computed){
19351934
for(varkeyincomputed){
1935+
/* istanbul ignore if */
1936+
if(process.env.NODE_ENV!=='production'&&keyinvm){
1937+
warn(
1938+
"existing instance property \""+key+"\" will be "+
1939+
"overwritten by a computed property with the same name.",
1940+
vm
1941+
);
1942+
}
19361943
varuserDef=computed[key];
19371944
if(typeofuserDef==='function'){
19381945
computedSharedDefinition.get=makeComputedGetter(userDef,vm);
@@ -3651,7 +3658,7 @@ Object.defineProperty(Vue$3.prototype, '$isServer', {
36513658
get:isServerRendering
36523659
});
36533660

3654-
Vue$3.version='2.1.7';
3661+
Vue$3.version='2.1.8';
36553662

36563663
/* */
36573664

@@ -4478,6 +4485,8 @@ function createPatchFunction (backend) {
44784485
}
44794486
}
44804487
}
4488+
}elseif(elm.data!==vnode.text){
4489+
elm.data=vnode.text;
44814490
}
44824491
returntrue
44834492
}
@@ -4489,7 +4498,7 @@ function createPatchFunction (backend) {
44894498
vnode.tag.toLowerCase()===(node.tagName&&node.tagName.toLowerCase())
44904499
)
44914500
}else{
4492-
return_toString(vnode.text)===node.data
4501+
returnnode.nodeType===(vnode.isComment ?8 :3)
44934502
}
44944503
}
44954504

@@ -5273,8 +5282,10 @@ function enter (vnode, toggleDisplay) {
52735282
varcss=data.css;
52745283
vartype=data.type;
52755284
varenterClass=data.enterClass;
5285+
varenterToClass=data.enterToClass;
52765286
varenterActiveClass=data.enterActiveClass;
52775287
varappearClass=data.appearClass;
5288+
varappearToClass=data.appearToClass;
52785289
varappearActiveClass=data.appearActiveClass;
52795290
varbeforeEnter=data.beforeEnter;
52805291
varenter=data.enter;
@@ -5304,6 +5315,7 @@ function enter (vnode, toggleDisplay) {
53045315

53055316
varstartClass=isAppear ?appearClass :enterClass;
53065317
varactiveClass=isAppear ?appearActiveClass :enterActiveClass;
5318+
vartoClass=isAppear ?appearToClass :enterToClass;
53075319
varbeforeEnterHook=isAppear ?(beforeAppear||beforeEnter) :beforeEnter;
53085320
varenterHook=isAppear ?(typeofappear==='function' ?appear :enter) :enter;
53095321
varafterEnterHook=isAppear ?(afterAppear||afterEnter) :afterEnter;
@@ -5318,6 +5330,7 @@ function enter (vnode, toggleDisplay) {
53185330

53195331
varcb=el._enterCb=once(function(){
53205332
if(expectsCSS){
5333+
removeTransitionClass(el,toClass);
53215334
removeTransitionClass(el,activeClass);
53225335
}
53235336
if(cb.cancelled){
@@ -5350,9 +5363,10 @@ function enter (vnode, toggleDisplay) {
53505363
beforeEnterHook&&beforeEnterHook(el);
53515364
if(expectsCSS){
53525365
addTransitionClass(el,startClass);
5366+
addTransitionClass(el,activeClass);
53535367
nextFrame(function(){
5368+
addTransitionClass(el,toClass);
53545369
removeTransitionClass(el,startClass);
5355-
addTransitionClass(el,activeClass);
53565370
if(!cb.cancelled&&!userWantsControl){
53575371
whenTransitionEnds(el,type,cb);
53585372
}
@@ -5391,6 +5405,7 @@ function leave (vnode, rm) {
53915405
varcss=data.css;
53925406
vartype=data.type;
53935407
varleaveClass=data.leaveClass;
5408+
varleaveToClass=data.leaveToClass;
53945409
varleaveActiveClass=data.leaveActiveClass;
53955410
varbeforeLeave=data.beforeLeave;
53965411
varleave=data.leave;
@@ -5410,6 +5425,7 @@ function leave (vnode, rm) {
54105425
el.parentNode._pending[vnode.key]=null;
54115426
}
54125427
if(expectsCSS){
5428+
removeTransitionClass(el,leaveToClass);
54135429
removeTransitionClass(el,leaveActiveClass);
54145430
}
54155431
if(cb.cancelled){
@@ -5442,9 +5458,10 @@ function leave (vnode, rm) {
54425458
beforeLeave&&beforeLeave(el);
54435459
if(expectsCSS){
54445460
addTransitionClass(el,leaveClass);
5461+
addTransitionClass(el,leaveActiveClass);
54455462
nextFrame(function(){
5463+
addTransitionClass(el,leaveToClass);
54465464
removeTransitionClass(el,leaveClass);
5447-
addTransitionClass(el,leaveActiveClass);
54485465
if(!cb.cancelled&&!userWantsControl){
54495466
whenTransitionEnds(el,type,cb);
54505467
}
@@ -5479,6 +5496,9 @@ var autoCssTransition = cached(function (name) {
54795496
enterClass:(name+"-enter"),
54805497
leaveClass:(name+"-leave"),
54815498
appearClass:(name+"-enter"),
5499+
enterToClass:(name+"-enter-to"),
5500+
leaveToClass:(name+"-leave-to"),
5501+
appearToClass:(name+"-enter-to"),
54825502
enterActiveClass:(name+"-enter-active"),
54835503
leaveActiveClass:(name+"-leave-active"),
54845504
appearActiveClass:(name+"-enter-active")
@@ -5746,10 +5766,13 @@ var transitionProps = {
57465766
type:String,
57475767
enterClass:String,
57485768
leaveClass:String,
5769+
enterToClass:String,
5770+
leaveToClass:String,
57495771
enterActiveClass:String,
57505772
leaveActiveClass:String,
57515773
appearClass:String,
5752-
appearActiveClass:String
5774+
appearActiveClass:String,
5775+
appearToClass:String
57535776
};
57545777

57555778
// in case the child is also an abstract component, e.g. <keep-alive>
@@ -5793,6 +5816,10 @@ function hasParentTransition (vnode) {
57935816
}
57945817
}
57955818

5819+
functionisSameChild(child,oldChild){
5820+
returnoldChild.key===child.key&&oldChild.tag===child.tag
5821+
}
5822+
57965823
varTransition={
57975824
name:'transition',
57985825
props:transitionProps,
@@ -5865,11 +5892,10 @@ var Transition = {
58655892
child.data.show=true;
58665893
}
58675894

5868-
if(oldChild&&oldChild.data&&oldChild.key!==key){
5895+
if(oldChild&&oldChild.data&&!isSameChild(child,oldChild)){
58695896
// replace old child transition data with fresh one
58705897
// important for dynamic transitions!
5871-
varoldData=oldChild.data.transition=extend({},data);
5872-
5898+
varoldData=oldChild&&(oldChild.data.transition=extend({},data));
58735899
// handle transition mode
58745900
if(mode==='out-in'){
58755901
// return placeholder node and queue update when leave finishes
@@ -6080,6 +6106,15 @@ Vue$3.prototype.$mount = function (
60806106
returnthis._mount(el,hydrating)
60816107
};
60826108

6109+
if(process.env.NODE_ENV!=='production'&&
6110+
inBrowser&&typeofconsole!=='undefined'){
6111+
console[console.info ?'info' :'log'](
6112+
"You are running Vue in development mode.\n"+
6113+
"Make sure to turn on production mode when deploying for production.\n"+
6114+
"See more tips at https://vuejs.org/guide/deployment.html"
6115+
);
6116+
}
6117+
60836118
// devtools global hook
60846119
/* istanbul ignore next */
60856120
setTimeout(function(){
@@ -6090,8 +6125,8 @@ setTimeout(function () {
60906125
process.env.NODE_ENV!=='production'&&
60916126
inBrowser&&!isEdge&&/Chrome\/\d+/.test(window.navigator.userAgent)
60926127
){
6093-
console.log(
6094-
'Download the Vue Devtools for a better development experience:\n'+
6128+
console[console.info ?'info' :'log'](
6129+
'Download the Vue Devtoolsextensionfor a better development experience:\n'+
60956130
'https://github.com/vuejs/vue-devtools'
60966131
);
60976132
}
@@ -7542,6 +7577,8 @@ function bind$2 (el, dir) {
75427577
};
75437578
}
75447579

7580+
/* */
7581+
75457582
varbaseDirectives={
75467583
bind:bind$2,
75477584
cloak:noop
@@ -7820,23 +7857,25 @@ function genChildren (el, checkSkip) {
78207857
}
78217858
}
78227859

7823-
// determine thenormalzation needed for the children array.
7860+
// determine thenormalization needed for the children array.
78247861
// 0: no normalization needed
78257862
// 1: simple normalization needed (possible 1-level deep nested array)
7826-
// 2: fullnomralization needed
7863+
// 2: fullnormalization needed
78277864
functiongetNormalizationType(children){
7865+
varres=0;
78287866
for(vari=0;i<children.length;i++){
78297867
varel=children[i];
78307868
if(needsNormalization(el)||
78317869
(el.if&&el.ifConditions.some(function(c){returnneedsNormalization(c.block);}))){
7832-
return2
7870+
res=2;
7871+
break
78337872
}
78347873
if(maybeComponent(el)||
78357874
(el.if&&el.ifConditions.some(function(c){returnmaybeComponent(c.block);}))){
7836-
return1
7875+
res=1;
78377876
}
78387877
}
7839-
return0
7878+
returnres
78407879
}
78417880

78427881
functionneedsNormalization(el){
@@ -8141,8 +8180,11 @@ function genCheckboxModel (
81418180
varfalseValueBinding=getBindingAttr(el,'false-value')||'false';
81428181
addProp(el,'checked',
81438182
"Array.isArray("+value+")"+
8144-
"?_i("+value+","+valueBinding+")>-1"+
8145-
":_q("+value+","+trueValueBinding+")"
8183+
"?_i("+value+","+valueBinding+")>-1"+(
8184+
trueValueBinding==='true'
8185+
?(":("+value+")")
8186+
:(":_q("+value+","+trueValueBinding+")")
8187+
)
81468188
);
81478189
addHandler(el,'change',
81488190
"var $$a="+value+","+

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp