2018-09-09 21:05:03 +00:00
|
|
|
<!-- *************************************************************************
|
|
|
|
TEMPLATE
|
|
|
|
************************************************************************* -->
|
|
|
|
|
|
|
|
<template lang="pug">
|
2018-09-09 21:41:06 +00:00
|
|
|
div(
|
|
|
|
:data-balloon="'Share on ' + network"
|
2018-09-09 21:05:03 +00:00
|
|
|
class="c-base-share"
|
2018-09-09 21:41:06 +00:00
|
|
|
data-balloon-pos="up"
|
|
|
|
data-balloon-type="mini"
|
2018-09-09 21:05:03 +00:00
|
|
|
)
|
2018-09-09 21:41:06 +00:00
|
|
|
img(
|
|
|
|
@click="onClick"
|
2018-09-09 21:57:04 +00:00
|
|
|
:src="baseUrl + '/images/components/BaseShare/' + network.toLowerCase() + '.svg'"
|
2018-09-09 21:41:06 +00:00
|
|
|
class="c-base-share__image"
|
|
|
|
)
|
2018-09-09 21:05:03 +00:00
|
|
|
</template>
|
|
|
|
|
|
|
|
<!-- *************************************************************************
|
|
|
|
SCRIPT
|
|
|
|
************************************************************************* -->
|
|
|
|
|
|
|
|
<script>
|
|
|
|
export default {
|
|
|
|
props: {
|
|
|
|
network: {
|
|
|
|
type: String,
|
|
|
|
required: true
|
|
|
|
}
|
|
|
|
},
|
|
|
|
|
2018-09-09 21:57:04 +00:00
|
|
|
data() {
|
|
|
|
return {
|
|
|
|
// --> STATE <--
|
|
|
|
baseUrl: process.env.baseUrl
|
|
|
|
};
|
|
|
|
},
|
|
|
|
|
2018-09-09 21:05:03 +00:00
|
|
|
methods: {
|
|
|
|
onClick() {
|
|
|
|
this.$emit("click", this.network);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
</script>
|
|
|
|
|
|
|
|
<!-- *************************************************************************
|
|
|
|
STYLE
|
|
|
|
************************************************************************* -->
|
|
|
|
|
|
|
|
<style lang="scss">
|
|
|
|
$c: ".c-base-share";
|
|
|
|
|
|
|
|
#{$c} {
|
2018-09-09 21:41:06 +00:00
|
|
|
display: inline-block;
|
|
|
|
|
|
|
|
#{$c}__image {
|
|
|
|
width: 32px;
|
|
|
|
height: 32px;
|
|
|
|
cursor: pointer;
|
|
|
|
}
|
2018-09-09 21:05:03 +00:00
|
|
|
}
|
|
|
|
</style>
|