vue-socials
Version:
Social media share buttons and counts for Vue.js
37 lines (33 loc) • 975 B
JavaScript
import { defineComponent } from 'vue';
import BaseSocials from '../../mixins/BaseSocial/BaseSocial.js';
import getSerialisedParams from '../../utils/getSerialisedParams.js';
/**
* Hey!
*
* SViber component used for Viber social network
* @link https://www.viber.com/
*/
/**
* Share parameters for link
* @link https://developers.viber.com/docs/tools/share-button/
*/
var SViber = /* #__PURE__ */defineComponent({
name: 'SViber',
mixins: [BaseSocials('Viber')],
computed: {
networkURL: function networkURL() {
var BASE_URL = 'viber://forward';
var shareOptions = this.shareOptions;
var text = shareOptions.text,
url = shareOptions.url;
var serialisedParams = getSerialisedParams({
text: "".concat(text, " ").concat(url)
});
return "".concat(BASE_URL).concat(serialisedParams);
}
},
render: function render() {
return this.generateComponent(this.networkURL);
}
});
export default SViber;