Commit 20b3186f by 李伟康

增加分享朋友圈

1 parent a62b3bb7
...@@ -4,8 +4,5 @@ ...@@ -4,8 +4,5 @@
"vas-toast": "./components/likeToast/likeToast", "vas-toast": "./components/likeToast/likeToast",
"chat":"./components/chat/chat" "chat":"./components/chat/chat"
}, },
"navigationStyle": "custom", "navigationStyle": "custom"
"onReachBottomDistance": 10,
"backgroundColor": "#FC5B32",
"enablePullDownRefresh": true
} }
...@@ -27,7 +27,7 @@ class Share { ...@@ -27,7 +27,7 @@ class Share {
/**设置全局分享 */ /**设置全局分享 */
pageLeaveProxy(page) { pageLeaveProxy(page) {
if (page.onShareAppMessage) { if (page.onShareAppMessage) {
page.onShareAppMessage = function () { page.onShareAppMessage = () => {
let { let {
shareTitle, shareTitle,
sharePath, sharePath,
...@@ -48,6 +48,22 @@ class Share { ...@@ -48,6 +48,22 @@ class Share {
} }
} }
} }
if (page.onShareTimeline) {
page.onShareTimeline = () => {
let {
shareTitle,
shareImage,
shareQuery,
shareFun
} = this
if (shareFun) shareFun()
return {
query: shareQuery,
title: shareTitle,
imageUrl: shareImage
}
}
}
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!