Transform on delete button component to c-input-confirm
This commit is contained in:
@@ -89,14 +89,10 @@
|
||||
/>
|
||||
|
||||
<b-input-group-append>
|
||||
<b-button
|
||||
variant="danger"
|
||||
@click="param.value.splice(hIndex, 1)"
|
||||
>
|
||||
<font-awesome-icon
|
||||
:icon="['far', 'trash-alt']"
|
||||
/>
|
||||
</b-button>
|
||||
<c-input-confirm
|
||||
show-icon
|
||||
@confirmed="param.value.splice(hIndex, 1)"
|
||||
/>
|
||||
</b-input-group-append>
|
||||
</b-input-group>
|
||||
|
||||
|
||||
@@ -34,7 +34,6 @@
|
||||
<b-col class="text-right">
|
||||
<c-input-confirm
|
||||
data-test-id="button-remove-role"
|
||||
no-prompt
|
||||
show-icon
|
||||
@confirmed="removeRole(role)"
|
||||
/>
|
||||
@@ -47,8 +46,6 @@
|
||||
<script>
|
||||
import { debounce } from 'lodash'
|
||||
import { VueSelect } from 'vue-select'
|
||||
import { components } from '@cortezaproject/corteza-vue/'
|
||||
const { CInputConfirm } = components
|
||||
|
||||
function roleSorter (a, b) {
|
||||
return `${a.name} ${a.handle} ${a.roleID}`.localeCompare(`${b.name} ${b.handle} ${b.roleID}`)
|
||||
@@ -57,7 +54,6 @@ function roleSorter (a, b) {
|
||||
export default {
|
||||
components: {
|
||||
VueSelect,
|
||||
CInputConfirm,
|
||||
},
|
||||
|
||||
props: {
|
||||
|
||||
@@ -41,7 +41,6 @@
|
||||
<c-input-confirm
|
||||
data-test-id="button-remove-member"
|
||||
show-icon
|
||||
no-prompt
|
||||
@confirmed="removeMember(user.userID)"
|
||||
/>
|
||||
</td>
|
||||
@@ -72,8 +71,6 @@
|
||||
<script>
|
||||
import { debounce } from 'lodash'
|
||||
import { VueSelect } from 'vue-select'
|
||||
import { components } from '@cortezaproject/corteza-vue/'
|
||||
const { CInputConfirm } = components
|
||||
|
||||
export default {
|
||||
i18nOptions: {
|
||||
@@ -83,7 +80,6 @@ export default {
|
||||
|
||||
components: {
|
||||
VueSelect,
|
||||
CInputConfirm,
|
||||
},
|
||||
|
||||
props: {
|
||||
|
||||
@@ -15,12 +15,9 @@
|
||||
|
||||
<c-input-confirm
|
||||
v-if="uploadedFile('ui.main-logo')"
|
||||
show-icon
|
||||
@confirmed="resetAttachment('ui.main-logo')"
|
||||
>
|
||||
<font-awesome-icon
|
||||
:icon="['far', 'trash-alt']"
|
||||
/>
|
||||
</c-input-confirm>
|
||||
/>
|
||||
</template>
|
||||
|
||||
<c-uploader-with-preview
|
||||
@@ -48,12 +45,9 @@
|
||||
|
||||
<c-input-confirm
|
||||
v-if="uploadedFile('ui.icon-logo')"
|
||||
show-icon
|
||||
@confirmed="resetAttachment('ui.icon-logo')"
|
||||
>
|
||||
<font-awesome-icon
|
||||
:icon="['far', 'trash-alt']"
|
||||
/>
|
||||
</c-input-confirm>
|
||||
/>
|
||||
</template>
|
||||
|
||||
<c-uploader-with-preview
|
||||
|
||||
@@ -104,15 +104,10 @@
|
||||
/>
|
||||
</template>
|
||||
<template #cell(actions)="data">
|
||||
<b-button
|
||||
variant="outline-danger"
|
||||
class="border-0 px-1"
|
||||
@click="topbarSettings.helpLinks.splice(data.index, 1)"
|
||||
>
|
||||
<font-awesome-icon
|
||||
:icon="['far', 'trash-alt']"
|
||||
/>
|
||||
</b-button>
|
||||
<c-input-confirm
|
||||
show-icon
|
||||
@confirmed="topbarSettings.helpLinks.splice(data.index, 1)"
|
||||
/>
|
||||
</template>
|
||||
</b-table>
|
||||
</b-form-group>
|
||||
@@ -183,15 +178,10 @@
|
||||
/>
|
||||
</template>
|
||||
<template #cell(actions)="data">
|
||||
<b-button
|
||||
variant="outline-danger"
|
||||
class="border-0 px-1"
|
||||
@click="topbarSettings.profileLinks.splice(data.index, 1)"
|
||||
>
|
||||
<font-awesome-icon
|
||||
:icon="['far', 'trash-alt']"
|
||||
/>
|
||||
</b-button>
|
||||
<c-input-confirm
|
||||
show-icon
|
||||
@confirmed="topbarSettings.profileLinks.splice(data.index, 1)"
|
||||
/>
|
||||
</template>
|
||||
</b-table>
|
||||
</b-form-group>
|
||||
|
||||
@@ -10,14 +10,11 @@
|
||||
:fields="fields"
|
||||
>
|
||||
<template #cell(editor)="{ item }">
|
||||
<b-button
|
||||
<c-input-confirm
|
||||
data-test-id="button-remove-provider"
|
||||
variant="link"
|
||||
class="pr-0"
|
||||
@click="$emit('delete', item.credentialsID)"
|
||||
>
|
||||
<font-awesome-icon :icon="['far', 'trash-alt']" />
|
||||
</b-button>
|
||||
show-icon
|
||||
@confirmed="$emit('delete', item.credentialsID)"
|
||||
/>
|
||||
</template>
|
||||
</b-table>
|
||||
<template #header>
|
||||
|
||||
Reference in New Issue
Block a user