debian-mirror-gitlab/app/assets/javascripts/batch_comments/components/drafts_count.vue
2022-07-23 20:15:48 +02:00

26 lines
517 B
Vue

<script>
import { GlBadge } from '@gitlab/ui';
import { mapGetters } from 'vuex';
export default {
components: {
GlBadge,
},
props: {
variant: {
type: String,
required: false,
default: 'info',
},
},
computed: {
...mapGetters('batchComments', ['draftsCount']),
},
};
</script>
<template>
<gl-badge size="sm" :variant="variant" class="gl-ml-2">
{{ draftsCount }}
<span class="sr-only"> {{ n__('draft', 'drafts', draftsCount) }} </span>
</gl-badge>
</template>