diff options
Diffstat (limited to 'app/assets/javascripts/work_items/components/work_item_weight.vue')
-rw-r--r-- | app/assets/javascripts/work_items/components/work_item_weight.vue | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/app/assets/javascripts/work_items/components/work_item_weight.vue b/app/assets/javascripts/work_items/components/work_item_weight.vue new file mode 100644 index 00000000000..b0f2b3aa14a --- /dev/null +++ b/app/assets/javascripts/work_items/components/work_item_weight.vue @@ -0,0 +1,26 @@ +<script> +import { __ } from '~/locale'; + +export default { + inject: ['hasIssueWeightsFeature'], + props: { + weight: { + type: Number, + required: false, + default: undefined, + }, + }, + computed: { + weightText() { + return this.weight ?? __('None'); + }, + }, +}; +</script> + +<template> + <div v-if="hasIssueWeightsFeature" class="gl-mb-5"> + <span class="gl-display-inline-block gl-font-weight-bold gl-w-15">{{ __('Weight') }}</span> + {{ weightText }} + </div> +</template> |