2017-11-10 23:41:04 +00:00
|
|
|
<script>
|
2018-10-30 20:28:31 +00:00
|
|
|
import tooltip from '~/vue_shared/directives/tooltip';
|
2018-10-29 08:01:50 +00:00
|
|
|
|
2018-10-30 20:28:31 +00:00
|
|
|
export default {
|
|
|
|
name: 'CollapsedCalendarIcon',
|
|
|
|
directives: {
|
|
|
|
tooltip,
|
|
|
|
},
|
|
|
|
props: {
|
|
|
|
containerClass: {
|
|
|
|
type: String,
|
|
|
|
required: false,
|
|
|
|
default: '',
|
2018-10-29 08:01:50 +00:00
|
|
|
},
|
2018-10-30 20:28:31 +00:00
|
|
|
text: {
|
|
|
|
type: String,
|
|
|
|
required: false,
|
|
|
|
default: '',
|
2017-11-10 23:41:04 +00:00
|
|
|
},
|
2018-10-30 20:28:31 +00:00
|
|
|
showIcon: {
|
|
|
|
type: Boolean,
|
|
|
|
required: false,
|
|
|
|
default: true,
|
2017-11-10 23:41:04 +00:00
|
|
|
},
|
2018-10-30 20:28:31 +00:00
|
|
|
tooltipText: {
|
|
|
|
type: String,
|
|
|
|
required: false,
|
|
|
|
default: '',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
methods: {
|
|
|
|
click() {
|
|
|
|
this.$emit('click');
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
2017-11-10 23:41:04 +00:00
|
|
|
</script>
|
|
|
|
|
|
|
|
<template>
|
|
|
|
<div
|
2018-10-29 08:01:50 +00:00
|
|
|
v-tooltip
|
2017-11-10 23:41:04 +00:00
|
|
|
:class="containerClass"
|
2018-10-29 08:01:50 +00:00
|
|
|
:title="tooltipText"
|
|
|
|
data-container="body"
|
|
|
|
data-placement="left"
|
|
|
|
data-html="true"
|
|
|
|
data-boundary="viewport"
|
2017-11-10 23:41:04 +00:00
|
|
|
@click="click"
|
|
|
|
>
|
2018-11-16 20:07:38 +00:00
|
|
|
<i v-if="showIcon" class="fa fa-calendar" aria-hidden="true"> </i>
|
2017-11-10 23:41:04 +00:00
|
|
|
<slot>
|
2018-11-16 20:07:38 +00:00
|
|
|
<span> {{ text }} </span>
|
2017-11-10 23:41:04 +00:00
|
|
|
</slot>
|
|
|
|
</div>
|
|
|
|
</template>
|