Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
菜鸟程序猿_c
uni-app
提交
b6ffe5d0
U
uni-app
项目概览
菜鸟程序猿_c
/
uni-app
与 Fork 源项目一致
Fork自
DCloud / uni-app
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
1
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
U
uni-app
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
1
Issue
1
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
b6ffe5d0
编写于
12月 16, 2019
作者:
fxy060608
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
chore(release): mp.runtime.esm.js(2.6.11)
上级
da64c2c0
变更
1
隐藏空白更改
内联
并排
Showing
1 changed file
with
67 addition
and
17 deletion
+67
-17
packages/vue-cli-plugin-uni/packages/mp-vue/dist/mp.runtime.esm.js
...vue-cli-plugin-uni/packages/mp-vue/dist/mp.runtime.esm.js
+67
-17
未找到文件。
packages/vue-cli-plugin-uni/packages/mp-vue/dist/mp.runtime.esm.js
浏览文件 @
b6ffe5d0
/*!
/*!
* Vue.js v2.6.1
0
* Vue.js v2.6.1
1
* (c) 2014-2019 Evan You
* (c) 2014-2019 Evan You
* Released under the MIT License.
* Released under the MIT License.
*/
*/
...
@@ -698,7 +698,13 @@ var uid = 0;
...
@@ -698,7 +698,13 @@ var uid = 0;
* directives subscribing to it.
* directives subscribing to it.
*/
*/
var
Dep
=
function
Dep
()
{
var
Dep
=
function
Dep
()
{
this
.
id
=
uid
++
;
// fixed by xxxxxx (nvue vuex)
/* eslint-disable no-undef */
if
(
typeof
SharedObject
!==
'
undefined
'
){
this
.
id
=
SharedObject
.
uid
++
;
}
else
{
this
.
id
=
uid
++
;
}
this
.
subs
=
[];
this
.
subs
=
[];
};
};
...
@@ -1964,7 +1970,7 @@ if (typeof Promise !== 'undefined' && isNative(Promise)) {
...
@@ -1964,7 +1970,7 @@ if (typeof Promise !== 'undefined' && isNative(Promise)) {
};
};
}
else
if
(
typeof
setImmediate
!==
'
undefined
'
&&
isNative
(
setImmediate
))
{
}
else
if
(
typeof
setImmediate
!==
'
undefined
'
&&
isNative
(
setImmediate
))
{
// Fallback to setImmediate.
// Fallback to setImmediate.
// Tech
i
nically it leverages the (macro) task queue,
// Technically it leverages the (macro) task queue,
// but it is still a better choice than setTimeout.
// but it is still a better choice than setTimeout.
timerFunc
=
function
()
{
timerFunc
=
function
()
{
setImmediate
(
flushCallbacks
);
setImmediate
(
flushCallbacks
);
...
@@ -2030,7 +2036,7 @@ if (process.env.NODE_ENV !== 'production') {
...
@@ -2030,7 +2036,7 @@ if (process.env.NODE_ENV !== 'production') {
warn
(
warn
(
"
Property
\"
"
+
key
+
"
\"
must be accessed with
\"
$data.
"
+
key
+
"
\"
because
"
+
"
Property
\"
"
+
key
+
"
\"
must be accessed with
\"
$data.
"
+
key
+
"
\"
because
"
+
'
properties starting with "$" or "_" are not proxied in the Vue instance to
'
+
'
properties starting with "$" or "_" are not proxied in the Vue instance to
'
+
'
prevent conflicts with Vue internals
'
+
'
prevent conflicts with Vue internals
.
'
+
'
See: https://vuejs.org/v2/api/#data
'
,
'
See: https://vuejs.org/v2/api/#data
'
,
target
target
);
);
...
@@ -2230,17 +2236,48 @@ function updateListeners (
...
@@ -2230,17 +2236,48 @@ function updateListeners (
/* */
/* */
// fixed by xxxxxx (mp properties)
function
extractPropertiesFromVNodeData
(
data
,
Ctor
,
res
,
context
)
{
var
propOptions
=
Ctor
.
options
.
mpOptions
&&
Ctor
.
options
.
mpOptions
.
properties
;
if
(
isUndef
(
propOptions
))
{
return
res
}
var
externalClasses
=
Ctor
.
options
.
mpOptions
.
externalClasses
||
[];
var
attrs
=
data
.
attrs
;
var
props
=
data
.
props
;
if
(
isDef
(
attrs
)
||
isDef
(
props
))
{
for
(
var
key
in
propOptions
)
{
var
altKey
=
hyphenate
(
key
);
var
result
=
checkProp
(
res
,
props
,
key
,
altKey
,
true
)
||
checkProp
(
res
,
attrs
,
key
,
altKey
,
false
);
// externalClass
if
(
result
&&
res
[
key
]
&&
externalClasses
.
indexOf
(
altKey
)
!==
-
1
&&
context
[
camelize
(
res
[
key
])]
)
{
// 赋值 externalClass 真正的值(模板里 externalClass 的值可能是字符串)
res
[
key
]
=
context
[
camelize
(
res
[
key
])];
}
}
}
return
res
}
function
extractPropsFromVNodeData
(
function
extractPropsFromVNodeData
(
data
,
data
,
Ctor
,
Ctor
,
tag
tag
,
context
// fixed by xxxxxx
)
{
)
{
// we are only extracting raw values here.
// we are only extracting raw values here.
// validation and default values are handled in the child
// validation and default values are handled in the child
// component itself.
// component itself.
var
propOptions
=
Ctor
.
options
.
props
;
var
propOptions
=
Ctor
.
options
.
props
;
if
(
isUndef
(
propOptions
))
{
if
(
isUndef
(
propOptions
))
{
return
// fixed by xxxxxx
return
extractPropertiesFromVNodeData
(
data
,
Ctor
,
{},
context
)
}
}
var
res
=
{};
var
res
=
{};
var
attrs
=
data
.
attrs
;
var
attrs
=
data
.
attrs
;
...
@@ -2268,7 +2305,8 @@ function extractPropsFromVNodeData (
...
@@ -2268,7 +2305,8 @@ function extractPropsFromVNodeData (
checkProp
(
res
,
attrs
,
key
,
altKey
,
false
);
checkProp
(
res
,
attrs
,
key
,
altKey
,
false
);
}
}
}
}
return
res
// fixed by xxxxxx
return
extractPropertiesFromVNodeData
(
data
,
Ctor
,
res
,
context
)
}
}
function
checkProp
(
function
checkProp
(
...
@@ -2603,12 +2641,12 @@ function renderList (
...
@@ -2603,12 +2641,12 @@ function renderList (
if
(
Array
.
isArray
(
val
)
||
typeof
val
===
'
string
'
)
{
if
(
Array
.
isArray
(
val
)
||
typeof
val
===
'
string
'
)
{
ret
=
new
Array
(
val
.
length
);
ret
=
new
Array
(
val
.
length
);
for
(
i
=
0
,
l
=
val
.
length
;
i
<
l
;
i
++
)
{
for
(
i
=
0
,
l
=
val
.
length
;
i
<
l
;
i
++
)
{
ret
[
i
]
=
render
(
val
[
i
],
i
);
ret
[
i
]
=
render
(
val
[
i
],
i
,
i
,
i
);
// fixed by xxxxxx
}
}
}
else
if
(
typeof
val
===
'
number
'
)
{
}
else
if
(
typeof
val
===
'
number
'
)
{
ret
=
new
Array
(
val
);
ret
=
new
Array
(
val
);
for
(
i
=
0
;
i
<
val
;
i
++
)
{
for
(
i
=
0
;
i
<
val
;
i
++
)
{
ret
[
i
]
=
render
(
i
+
1
,
i
);
ret
[
i
]
=
render
(
i
+
1
,
i
,
i
,
i
);
// fixed by xxxxxx
}
}
}
else
if
(
isObject
(
val
))
{
}
else
if
(
isObject
(
val
))
{
if
(
hasSymbol
&&
val
[
Symbol
.
iterator
])
{
if
(
hasSymbol
&&
val
[
Symbol
.
iterator
])
{
...
@@ -2616,7 +2654,7 @@ function renderList (
...
@@ -2616,7 +2654,7 @@ function renderList (
var
iterator
=
val
[
Symbol
.
iterator
]();
var
iterator
=
val
[
Symbol
.
iterator
]();
var
result
=
iterator
.
next
();
var
result
=
iterator
.
next
();
while
(
!
result
.
done
)
{
while
(
!
result
.
done
)
{
ret
.
push
(
render
(
result
.
value
,
ret
.
length
));
ret
.
push
(
render
(
result
.
value
,
ret
.
length
,
i
++
,
i
));
// fixed by xxxxxx
result
=
iterator
.
next
();
result
=
iterator
.
next
();
}
}
}
else
{
}
else
{
...
@@ -2624,7 +2662,7 @@ function renderList (
...
@@ -2624,7 +2662,7 @@ function renderList (
ret
=
new
Array
(
keys
.
length
);
ret
=
new
Array
(
keys
.
length
);
for
(
i
=
0
,
l
=
keys
.
length
;
i
<
l
;
i
++
)
{
for
(
i
=
0
,
l
=
keys
.
length
;
i
<
l
;
i
++
)
{
key
=
keys
[
i
];
key
=
keys
[
i
];
ret
[
i
]
=
render
(
val
[
key
],
key
,
i
);
ret
[
i
]
=
render
(
val
[
key
],
key
,
i
,
i
);
// fixed by xxxxxx
}
}
}
}
}
}
...
@@ -2659,7 +2697,8 @@ function renderSlot (
...
@@ -2659,7 +2697,8 @@ function renderSlot (
}
}
props
=
extend
(
extend
({},
bindObject
),
props
);
props
=
extend
(
extend
({},
bindObject
),
props
);
}
}
nodes
=
scopedSlotFn
(
props
)
||
fallback
;
// fixed by xxxxxx app-plus scopedSlot
nodes
=
scopedSlotFn
(
props
,
this
,
props
.
_i
)
||
fallback
;
}
else
{
}
else
{
nodes
=
this
.
$slots
[
name
]
||
fallback
;
nodes
=
this
.
$slots
[
name
]
||
fallback
;
}
}
...
@@ -2887,7 +2926,7 @@ function bindDynamicKeys (baseObj, values) {
...
@@ -2887,7 +2926,7 @@ function bindDynamicKeys (baseObj, values) {
if
(
typeof
key
===
'
string
'
&&
key
)
{
if
(
typeof
key
===
'
string
'
&&
key
)
{
baseObj
[
values
[
i
]]
=
values
[
i
+
1
];
baseObj
[
values
[
i
]]
=
values
[
i
+
1
];
}
else
if
(
process
.
env
.
NODE_ENV
!==
'
production
'
&&
key
!==
''
&&
key
!==
null
)
{
}
else
if
(
process
.
env
.
NODE_ENV
!==
'
production
'
&&
key
!==
''
&&
key
!==
null
)
{
// null is a spe
ic
al value for explicitly removing a binding
// null is a spe
ci
al value for explicitly removing a binding
warn
(
warn
(
(
"
Invalid value for dynamic directive argument (expected string or null):
"
+
key
),
(
"
Invalid value for dynamic directive argument (expected string or null):
"
+
key
),
this
this
...
@@ -3111,6 +3150,8 @@ var componentVNodeHooks = {
...
@@ -3111,6 +3150,8 @@ var componentVNodeHooks = {
var
context
=
vnode
.
context
;
var
context
=
vnode
.
context
;
var
componentInstance
=
vnode
.
componentInstance
;
var
componentInstance
=
vnode
.
componentInstance
;
if
(
!
componentInstance
.
_isMounted
)
{
if
(
!
componentInstance
.
_isMounted
)
{
callHook
(
componentInstance
,
'
onServiceCreated
'
);
callHook
(
componentInstance
,
'
onServiceAttached
'
);
componentInstance
.
_isMounted
=
true
;
componentInstance
.
_isMounted
=
true
;
callHook
(
componentInstance
,
'
mounted
'
);
callHook
(
componentInstance
,
'
mounted
'
);
}
}
...
@@ -3200,7 +3241,7 @@ function createComponent (
...
@@ -3200,7 +3241,7 @@ function createComponent (
}
}
// extract props
// extract props
var
propsData
=
extractPropsFromVNodeData
(
data
,
Ctor
,
tag
);
var
propsData
=
extractPropsFromVNodeData
(
data
,
Ctor
,
tag
,
context
);
// fixed by xxxxxx
// functional component
// functional component
if
(
isTrue
(
Ctor
.
options
.
functional
))
{
if
(
isTrue
(
Ctor
.
options
.
functional
))
{
...
@@ -3383,6 +3424,12 @@ function _createElement (
...
@@ -3383,6 +3424,12 @@ function _createElement (
ns
=
(
context
.
$vnode
&&
context
.
$vnode
.
ns
)
||
config
.
getTagNamespace
(
tag
);
ns
=
(
context
.
$vnode
&&
context
.
$vnode
.
ns
)
||
config
.
getTagNamespace
(
tag
);
if
(
config
.
isReservedTag
(
tag
))
{
if
(
config
.
isReservedTag
(
tag
))
{
// platform built-in elements
// platform built-in elements
if
(
process
.
env
.
NODE_ENV
!==
'
production
'
&&
isDef
(
data
)
&&
isDef
(
data
.
nativeOn
))
{
warn
(
(
"
The .native modifier for v-on is only valid on components but it was used on <
"
+
tag
+
"
>.
"
),
context
);
}
vnode
=
new
VNode
(
vnode
=
new
VNode
(
config
.
parsePlatformTagName
(
tag
),
data
,
children
,
config
.
parsePlatformTagName
(
tag
),
data
,
children
,
undefined
,
undefined
,
context
undefined
,
undefined
,
context
...
@@ -3511,7 +3558,7 @@ function renderMixin (Vue) {
...
@@ -3511,7 +3558,7 @@ function renderMixin (Vue) {
// render self
// render self
var
vnode
;
var
vnode
;
try
{
try
{
// There's no need to maintain a stack becau
es
all render fns are called
// There's no need to maintain a stack becau
se
all render fns are called
// separately from one another. Nested component's render fns are called
// separately from one another. Nested component's render fns are called
// when parent component is patched.
// when parent component is patched.
currentRenderingInstance
=
vm
;
currentRenderingInstance
=
vm
;
...
@@ -4046,7 +4093,10 @@ function updateChildComponent (
...
@@ -4046,7 +4093,10 @@ function updateChildComponent (
// keep a copy of raw propsData
// keep a copy of raw propsData
vm
.
$options
.
propsData
=
propsData
;
vm
.
$options
.
propsData
=
propsData
;
}
}
// fixed by xxxxxx update properties(mp runtime)
vm
.
_$updateProperties
&&
vm
.
_$updateProperties
(
vm
);
// update listeners
// update listeners
listeners
=
listeners
||
emptyObject
;
listeners
=
listeners
||
emptyObject
;
var
oldListeners
=
vm
.
$options
.
_parentListeners
;
var
oldListeners
=
vm
.
$options
.
_parentListeners
;
...
@@ -5369,7 +5419,7 @@ Object.defineProperty(Vue, 'FunctionalRenderContext', {
...
@@ -5369,7 +5419,7 @@ Object.defineProperty(Vue, 'FunctionalRenderContext', {
value
:
FunctionalRenderContext
value
:
FunctionalRenderContext
});
});
Vue
.
version
=
'
2.6.1
0
'
;
Vue
.
version
=
'
2.6.1
1
'
;
/**
/**
* https://raw.githubusercontent.com/Tencent/westore/master/packages/westore/utils/diff.js
* https://raw.githubusercontent.com/Tencent/westore/master/packages/westore/utils/diff.js
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录