111eb43fd9
* Add title attr with buttons on the post form * fix * tooltip * missing ; * remove title attr * fix bug * Update reactions-viewer.details.vue * help wip * ok! * i18n Co-authored-by: syuilo <Syuilotan@yahoo.co.jp>
52 lines
1.1 KiB
Vue
52 lines
1.1 KiB
Vue
<template>
|
|
<mk-tooltip :source="source" ref="tooltip">
|
|
<template v-if="users.length <= 10">
|
|
<b v-for="u in users" :key="u.id" style="margin-right: 12px;">
|
|
<mk-avatar :user="u" style="width: 24px; height: 24px; margin-right: 2px;"/>
|
|
<mk-user-name :user="u" :nowrap="false" style="line-height: 24px;"/>
|
|
</b>
|
|
</template>
|
|
<template v-if="10 < users.length">
|
|
<b v-for="u in users" :key="u.id" style="margin-right: 12px;">
|
|
<mk-avatar :user="u" style="width: 24px; height: 24px; margin-right: 2px;"/>
|
|
<mk-user-name :user="u" :nowrap="false" style="line-height: 24px;"/>
|
|
</b>
|
|
<span slot="omitted">+{{ count - 10 }}</span>
|
|
</template>
|
|
</mk-tooltip>
|
|
</template>
|
|
|
|
<script lang="ts">
|
|
import Vue from 'vue';
|
|
import MkTooltip from './ui/tooltip.vue';
|
|
|
|
export default Vue.extend({
|
|
components: {
|
|
MkTooltip
|
|
},
|
|
props: {
|
|
reaction: {
|
|
type: String,
|
|
required: true,
|
|
},
|
|
users: {
|
|
type: Array,
|
|
required: true,
|
|
},
|
|
count: {
|
|
type: Number,
|
|
required: true,
|
|
},
|
|
source: {
|
|
required: true,
|
|
}
|
|
},
|
|
|
|
methods: {
|
|
close() {
|
|
this.$refs.tooltip.close();
|
|
}
|
|
}
|
|
})
|
|
</script>
|