Component({ properties: { text: { type: String, value: '' }, variant: { type: String, value: 'primary' }, // primary | outline | danger | ghost size: { type: String, value: 'md' }, // sm | md | lg | xl block: { type: Boolean, value: false }, disabled: { type: Boolean, value: false }, iconSrc: { type: String, value: '' }, customStyle: { type: String, value: '' }, // 透传微信原生 button 的 open-type: // share — 触发 Page.onShareAppMessage(分享给朋友) // contact / feedback / shareToPhone … 等 // 设置后会在底层 button 上挂 open-type="{{openType}}",配合 Page 的 // onShareAppMessage 即可让自定义按钮真正调起原生分享面板。 openType: { type: String, value: '' } }, methods: { onTap() { this.triggerEvent('tap') } } })