2
0
mirror of https://github.com/frappe/books.git synced 2025-02-14 17:56:34 +00:00
books/src/components/StatusBadge.vue

23 lines
400 B
Vue
Raw Normal View History

<template>
<Badge class="text-xs flex-center px-3 ml-2" :color="color" v-if="status">{{
status
}}</Badge>
</template>
<script>
import { statusColor } from '@/utils';
import Badge from '@/components/Badge';
export default {
name: 'StatusBadge',
props: ['status'],
components: {
Badge,
},
computed: {
color() {
return statusColor[this.status];
},
},
};
</script>