|
|
@ -1,22 +1,43 @@ |
|
|
|
<template> |
|
|
|
<div> |
|
|
|
<v-btn |
|
|
|
:disabled="false" |
|
|
|
class="text-capitalize" |
|
|
|
outlined |
|
|
|
@click="handleClear()" |
|
|
|
<v-tooltip bottom> |
|
|
|
<template v-slot:activator="{ on }"> |
|
|
|
<v-btn |
|
|
|
class="text-capitalize ps-1 pe-1" |
|
|
|
color="error" |
|
|
|
min-width="36" |
|
|
|
icon |
|
|
|
v-on="on" |
|
|
|
@click="dialog=true" |
|
|
|
> |
|
|
|
<v-icon> |
|
|
|
mdi-delete-outline |
|
|
|
</v-icon> |
|
|
|
</v-btn> |
|
|
|
</template> |
|
|
|
<span>Clear Annotations</span> |
|
|
|
<v-dialog |
|
|
|
v-model="dialog" |
|
|
|
width="800" |
|
|
|
> |
|
|
|
{{ "Clear Annotations" }} |
|
|
|
</v-btn> |
|
|
|
</div> |
|
|
|
<confirm-form |
|
|
|
title="Clear annotations" |
|
|
|
message="Are you sure you want to delete all annotations?" |
|
|
|
:button-true-text="$t('generic.yes')" |
|
|
|
:button-false-text="$t('generic.cancel')" |
|
|
|
@ok="handleClear();dialog=false" |
|
|
|
@cancel="dialog=false" |
|
|
|
/> |
|
|
|
</v-dialog> |
|
|
|
</v-tooltip> |
|
|
|
</template> |
|
|
|
|
|
|
|
<script> |
|
|
|
import { mapState, mapActions } from 'vuex' |
|
|
|
import { mapActions } from 'vuex' |
|
|
|
import ConfirmForm from '@/components/organisms/utils/ConfirmForm' |
|
|
|
|
|
|
|
export default { |
|
|
|
components: { |
|
|
|
|
|
|
|
ConfirmForm |
|
|
|
}, |
|
|
|
|
|
|
|
data() { |
|
|
@ -25,10 +46,6 @@ export default { |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
computed: { |
|
|
|
...mapState('documents', ['selected']) |
|
|
|
}, |
|
|
|
|
|
|
|
methods: { |
|
|
|
...mapActions('documents', ['clearAnnotations']), |
|
|
|
|
|
|
|