mirror of
https://gitee.com/vant-contrib/vant.git
synced 2025-04-06 03:57:59 +08:00
feat(ShareSheet): support weapp-qrcode (#7635)
This commit is contained in:
parent
89ce8345b4
commit
09c292aeb2
@ -69,6 +69,7 @@ export default {
|
|||||||
{ name: 'Link', icon: 'link' },
|
{ name: 'Link', icon: 'link' },
|
||||||
{ name: 'Poster', icon: 'poster' },
|
{ name: 'Poster', icon: 'poster' },
|
||||||
{ name: 'Qrcode', icon: 'qrcode' },
|
{ name: 'Qrcode', icon: 'qrcode' },
|
||||||
|
{ name: 'Weapp Qrcode', icon: 'weapp-qrcode' },
|
||||||
],
|
],
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
@ -129,7 +130,7 @@ export default {
|
|||||||
| --- | --- | --- |
|
| --- | --- | --- |
|
||||||
| name | Option name | _string_ |
|
| name | Option name | _string_ |
|
||||||
| description `v2.8.5` | Option description | _string_ |
|
| description `v2.8.5` | Option description | _string_ |
|
||||||
| icon | Option icon,can be set to `wechat` `weibo` `qq` `link` `qrcode` `poster` or image URL | _string_ |
|
| icon | Option icon,can be set to `wechat` `weibo` `qq` `link` `qrcode` `poster` `weapp-qrcode` or image URL | _string_ |
|
||||||
| className | Option className is used to set the class props to the share item | _string_ |
|
| className | Option className is used to set the class props to the share item | _string_ |
|
||||||
|
|
||||||
### Events
|
### Events
|
||||||
|
@ -81,6 +81,7 @@ export default {
|
|||||||
{ name: '复制链接', icon: 'link' },
|
{ name: '复制链接', icon: 'link' },
|
||||||
{ name: '分享海报', icon: 'poster' },
|
{ name: '分享海报', icon: 'poster' },
|
||||||
{ name: '二维码', icon: 'qrcode' },
|
{ name: '二维码', icon: 'qrcode' },
|
||||||
|
{ name: '小程序码', icon: 'weapp-qrcode' },
|
||||||
],
|
],
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
@ -177,7 +178,7 @@ export default {
|
|||||||
| --- | --- | --- |
|
| --- | --- | --- |
|
||||||
| name | 分享渠道名称 | _string_ |
|
| name | 分享渠道名称 | _string_ |
|
||||||
| description `v2.8.5` | 分享选项描述 | _string_ |
|
| description `v2.8.5` | 分享选项描述 | _string_ |
|
||||||
| icon | 图标,可选值为 `wechat` `weibo` `qq` `link` `qrcode` `poster`,支持传入图片 URL | _string_ |
|
| icon | 图标,可选值为 `wechat` `weibo` `qq` `link` `qrcode` `poster` `weapp-qrcode`,支持传入图片 URL | _string_ |
|
||||||
| className | 分享选项类名 | _string_ |
|
| className | 分享选项类名 | _string_ |
|
||||||
|
|
||||||
### Events
|
### Events
|
||||||
|
@ -67,6 +67,7 @@ export default {
|
|||||||
withDesc: '展示描述信息',
|
withDesc: '展示描述信息',
|
||||||
customIcon: '自定义图标',
|
customIcon: '自定义图标',
|
||||||
description: '描述信息',
|
description: '描述信息',
|
||||||
|
weappQrcode: '小程序码',
|
||||||
},
|
},
|
||||||
'en-US': {
|
'en-US': {
|
||||||
qq: 'QQ',
|
qq: 'QQ',
|
||||||
@ -82,6 +83,7 @@ export default {
|
|||||||
withDesc: 'Show Description',
|
withDesc: 'Show Description',
|
||||||
customIcon: 'Custom Icon',
|
customIcon: 'Custom Icon',
|
||||||
description: 'Description',
|
description: 'Description',
|
||||||
|
weappQrcode: 'Weapp Qrcode',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -118,6 +120,7 @@ export default {
|
|||||||
{ name: this.t('link'), icon: 'link' },
|
{ name: this.t('link'), icon: 'link' },
|
||||||
{ name: this.t('poster'), icon: 'poster' },
|
{ name: this.t('poster'), icon: 'poster' },
|
||||||
{ name: this.t('qrcode'), icon: 'qrcode' },
|
{ name: this.t('qrcode'), icon: 'qrcode' },
|
||||||
|
{ name: this.t('weappQrcode'), icon: 'weapp-qrcode' },
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
},
|
},
|
||||||
|
@ -7,7 +7,15 @@ import { popupMixinProps } from '../mixins/popup';
|
|||||||
// Components
|
// Components
|
||||||
import Popup from '../popup';
|
import Popup from '../popup';
|
||||||
|
|
||||||
const PRESET_ICONS = ['qq', 'weibo', 'wechat', 'link', 'qrcode', 'poster'];
|
const PRESET_ICONS = [
|
||||||
|
'qq',
|
||||||
|
'link',
|
||||||
|
'weibo',
|
||||||
|
'wechat',
|
||||||
|
'poster',
|
||||||
|
'qrcode',
|
||||||
|
'weapp-qrcode',
|
||||||
|
];
|
||||||
|
|
||||||
const [createComponent, bem, t] = createNamespace('share-sheet');
|
const [createComponent, bem, t] = createNamespace('share-sheet');
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user