mirror of https://github.com/doccano/doccano.git
Hironsan
5 years ago
5 changed files with 112 additions and 91 deletions
Unified View
Diff Options
-
32frontend/components/containers/MemberAdditionButton.vue
-
37frontend/components/containers/MemberDeletionButton.vue
-
33frontend/components/containers/ProjectCreationButton.vue
-
37frontend/components/containers/ProjectDeletionButton.vue
-
64frontend/components/molecules/BaseModal.vue
@ -0,0 +1,64 @@ |
|||||
|
<template> |
||||
|
<v-dialog |
||||
|
v-model="dialog" |
||||
|
width="800px" |
||||
|
> |
||||
|
<template v-slot:activator="{ on }"> |
||||
|
<v-btn |
||||
|
class="mb-2 text-capitalize" |
||||
|
:class="classObject" |
||||
|
:color="color" |
||||
|
:outlined="isOutlined" |
||||
|
:disabled="disabled" |
||||
|
@click="dialog=true" |
||||
|
> |
||||
|
{{ 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> |
Write
Preview
Loading…
Cancel
Save