mirror of https://github.com/doccano/doccano.git
pythonannotation-tooldatasetsactive-learningtext-annotationdatasetnatural-language-processingdata-labelingmachine-learning
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
64 lines
997 B
64 lines
997 B
<template>
|
|
<v-dialog
|
|
v-model="dialog"
|
|
width="800px"
|
|
>
|
|
<template v-slot:activator="{}">
|
|
<v-btn
|
|
:class="classObject"
|
|
:color="color"
|
|
:outlined="isOutlined"
|
|
:disabled="disabled"
|
|
@click="dialog=true"
|
|
class="mb-2 text-capitalize"
|
|
>
|
|
{{ text }}
|
|
</v-btn>
|
|
</template>
|
|
<slot :close="close" />
|
|
</v-dialog>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
props: {
|
|
text: {
|
|
type: String,
|
|
default: '',
|
|
required: true
|
|
},
|
|
disabled: {
|
|
type: Boolean,
|
|
default: false
|
|
},
|
|
isCreate: {
|
|
type: Boolean,
|
|
default: false
|
|
}
|
|
},
|
|
|
|
data() {
|
|
return {
|
|
dialog: false
|
|
}
|
|
},
|
|
|
|
computed: {
|
|
classObject() {
|
|
return this.isCreate ? [] : ['ml-2']
|
|
},
|
|
color() {
|
|
return this.isCreate ? 'primary' : ''
|
|
},
|
|
isOutlined() {
|
|
return !this.isCreate
|
|
}
|
|
},
|
|
|
|
methods: {
|
|
close() {
|
|
this.dialog = false
|
|
}
|
|
}
|
|
}
|
|
</script>
|