debian-mirror-gitlab/app/assets/javascripts/notebook/cells/prompt.vue
2018-03-17 18:26:18 +05:30

37 lines
578 B
Vue

<script>
export default {
props: {
type: {
type: String,
required: false,
default: '',
},
count: {
type: Number,
required: false,
default: 0,
},
},
computed: {
hasKeys() {
return this.type !== '' && this.count;
},
},
};
</script>
<template>
<div class="prompt">
<span v-if="hasKeys">
{{ type }} [{{ count }}]:
</span>
</div>
</template>
<style scoped>
.prompt {
padding: 0 10px;
min-width: 7em;
font-family: monospace;
}
</style>