feat:app分享
This commit is contained in:
@@ -7,19 +7,22 @@
|
|||||||
<view class="share-btn-view">
|
<view class="share-btn-view">
|
||||||
<!-- #ifndef APP-PLUS || H5 -->
|
<!-- #ifndef APP-PLUS || H5 -->
|
||||||
<block v-for="(item, index) in btnList" :key="index">
|
<block v-for="(item, index) in btnList" :key="index">
|
||||||
<button v-if="index === 0" open-type="share" hover-class="none" class="share-box share-btn-clean" @click="onBtn(index)">
|
<button v-if="index === 0" open-type="share" hover-class="none" class="share-box share-btn-clean"
|
||||||
<image :src="`https://static.tbmall.xin/static/new/share_${index}.png`" class="share-img"></image>
|
@click="onBtn(index)">
|
||||||
|
<image :src="`https://static.tbmall.xin/static/new/share_${index}.png`" class="share-img">
|
||||||
|
</image>
|
||||||
<text class="text-24 text-gray">{{ item }}</text>
|
<text class="text-24 text-gray">{{ item }}</text>
|
||||||
</button>
|
</button>
|
||||||
<view v-else class="share-box" @click="onBtn(index)">
|
<view v-else class="share-box" @click="onBtn(index)">
|
||||||
<image :src="`https://static.tbmall.xin/static/new/share_${index}.png`" class="share-img"></image>
|
<image :src="`https://static.tbmall.xin/static/new/share_${index}.png`" class="share-img">
|
||||||
|
</image>
|
||||||
<text class="text-24 text-gray">{{ item }}</text>
|
<text class="text-24 text-gray">{{ item }}</text>
|
||||||
</view>
|
</view>
|
||||||
</block>
|
</block>
|
||||||
<!-- #endif -->
|
<!-- #endif -->
|
||||||
|
|
||||||
<!-- #ifdef APP-PLUS || H5 -->
|
<!-- #ifdef APP-PLUS || H5 -->
|
||||||
<view class="share-box" @click="onBtn(index)" v-for="(item, index) in appBtnList" :key="index">
|
<view class="share-box" @click="onShare(index)" v-for="(item, index) in appBtnList" :key="index">
|
||||||
<image :src="`https://cex-pub.s3.ap-southeast-1.amazonaws.com/static/new/share_${index}.png`"
|
<image :src="`https://cex-pub.s3.ap-southeast-1.amazonaws.com/static/new/share_${index}.png`"
|
||||||
class="share-img"></image>
|
class="share-img"></image>
|
||||||
<text class="text-24 text-gray">{{ item }}</text>
|
<text class="text-24 text-gray">{{ item }}</text>
|
||||||
@@ -93,6 +96,10 @@ export default {
|
|||||||
console.log('微信分享', index);
|
console.log('微信分享', index);
|
||||||
this.$emit('wxShare', index)
|
this.$emit('wxShare', index)
|
||||||
},
|
},
|
||||||
|
onShare(index) {
|
||||||
|
|
||||||
|
this.$emit('share', index)
|
||||||
|
},
|
||||||
|
|
||||||
onClose() {
|
onClose() {
|
||||||
this.$emit('close');
|
this.$emit('close');
|
||||||
|
|||||||
Reference in New Issue
Block a user