mirror of
https://github.com/aelve/guide.git
synced 2024-12-26 22:34:42 +03:00
428c17048d
* TestCafe added to project. First test written * Search input test added * Seacth input test changed, travis job for testcafe tests added * Travis bugfix test * Travis testcafe bugfix test try 2 * Travis testcafe bugfix test ry 3 * Travis testcafe test sleep increased to 10 * Test adding category added but bug with click occurs - check!!! * Category test (testing the group where test was creating) added - bug fix * Article component rewrite * Article component rewritten * Big with rendering content.html in v-for * Collapse bug fix * MInor category visual changes/fixes * Description, reactivity bug fix * merge * Refactoring after code review * Conflict in styles resolved * Item add/delete feature in category * merge with vue * minor code fix * Update ArticleContent.vue * Merge bug fix * Minor merge bug fix * Code review fixes
54 lines
1.1 KiB
Vue
54 lines
1.1 KiB
Vue
<!-- Universal confirmation dialog, just pass text and function in Props -->
|
|
<template>
|
|
<v-dialog
|
|
:value="value"
|
|
@input="close"
|
|
max-width="500px"
|
|
>
|
|
<slot slot="activator" />
|
|
|
|
<v-card>
|
|
<v-card-text>
|
|
Are you sure you want to {{ confirmationText }}
|
|
</v-card-text>
|
|
<v-divider />
|
|
<v-card-actions>
|
|
<v-spacer />
|
|
<v-btn
|
|
flat
|
|
color="primary"
|
|
@click.native="confirmAction(itemId); close"
|
|
>
|
|
Continue
|
|
</v-btn>
|
|
<v-btn
|
|
flat
|
|
color="primary"
|
|
@click.native="close"
|
|
>
|
|
Cancel
|
|
</v-btn>
|
|
</v-card-actions>
|
|
</v-card>
|
|
</v-dialog>
|
|
</template>
|
|
|
|
<script lang="ts">
|
|
import Vue from 'vue'
|
|
import Component from 'vue-class-component';
|
|
import { Prop } from 'vue-property-decorator';
|
|
|
|
@Component
|
|
export default class ConfirmDialog extends Vue {
|
|
@Prop(String) confirmationText!: string
|
|
@Prop(Function) confirmAction!: Function
|
|
@Prop(Boolean) value!: boolean
|
|
@Prop(String) itemId!: string
|
|
|
|
close() {
|
|
this.$emit('input', false)
|
|
}
|
|
}
|
|
|
|
</script>
|