2018-03-17 18:26:18 +05:30
|
|
|
<script>
|
2018-05-09 12:01:36 +05:30
|
|
|
import timeAgoTooltip from '../../vue_shared/components/time_ago_tooltip.vue';
|
2018-03-17 18:26:18 +05:30
|
|
|
|
2018-05-09 12:01:36 +05:30
|
|
|
export default {
|
|
|
|
name: 'EditedNoteText',
|
|
|
|
components: {
|
|
|
|
timeAgoTooltip,
|
|
|
|
},
|
|
|
|
props: {
|
|
|
|
actionText: {
|
|
|
|
type: String,
|
|
|
|
required: true,
|
2018-03-17 18:26:18 +05:30
|
|
|
},
|
2018-11-08 19:23:39 +05:30
|
|
|
actionDetailText: {
|
|
|
|
type: String,
|
|
|
|
required: false,
|
|
|
|
default: '',
|
|
|
|
},
|
2018-05-09 12:01:36 +05:30
|
|
|
editedAt: {
|
|
|
|
type: String,
|
2018-11-08 19:23:39 +05:30
|
|
|
required: false,
|
|
|
|
default: null,
|
2018-03-17 18:26:18 +05:30
|
|
|
},
|
2018-05-09 12:01:36 +05:30
|
|
|
editedBy: {
|
|
|
|
type: Object,
|
|
|
|
required: false,
|
2018-11-08 19:23:39 +05:30
|
|
|
default: null,
|
2018-05-09 12:01:36 +05:30
|
|
|
},
|
|
|
|
className: {
|
|
|
|
type: String,
|
|
|
|
required: false,
|
|
|
|
default: 'edited-text',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
2018-03-17 18:26:18 +05:30
|
|
|
</script>
|
|
|
|
|
|
|
|
<template>
|
|
|
|
<div :class="className">
|
|
|
|
{{ actionText }}
|
|
|
|
<template v-if="editedBy">
|
|
|
|
by
|
|
|
|
<a
|
|
|
|
:href="editedBy.path"
|
2018-11-18 11:00:15 +05:30
|
|
|
class="js-vue-author author-link">
|
2018-03-17 18:26:18 +05:30
|
|
|
{{ editedBy.name }}
|
|
|
|
</a>
|
|
|
|
</template>
|
2018-11-08 19:23:39 +05:30
|
|
|
{{ actionDetailText }}
|
|
|
|
<time-ago-tooltip
|
|
|
|
:time="editedAt"
|
|
|
|
tooltip-placement="bottom"
|
|
|
|
/>
|
2018-03-17 18:26:18 +05:30
|
|
|
</div>
|
|
|
|
</template>
|