Remove confirmation-popover
This commit is contained in:
parent
c0da5d482f
commit
929ad8648b
@ -1,38 +0,0 @@
|
|||||||
export default {
|
|
||||||
name: 'confirmation-popover',
|
|
||||||
|
|
||||||
props: {
|
|
||||||
action: String,
|
|
||||||
btn_text: String,
|
|
||||||
btn_icon: String,
|
|
||||||
btn_class: String,
|
|
||||||
cancel_btn_text: String,
|
|
||||||
confirm_btn_text: String,
|
|
||||||
confirm_msg: String,
|
|
||||||
csrf_token: String,
|
|
||||||
name: String,
|
|
||||||
},
|
|
||||||
|
|
||||||
template: `
|
|
||||||
<v-popover placement='top-start'>
|
|
||||||
<template slot="popover">
|
|
||||||
<p>{{ confirm_msg }}</p>
|
|
||||||
<div class='action-group'>
|
|
||||||
<form method="POST" v-bind:action="action">
|
|
||||||
<input id="csrf_token" name="csrf_token" type="hidden" v-bind:value="csrf_token">
|
|
||||||
<button class='usa-button usa-button-primary' type='submit'>
|
|
||||||
{{ confirm_btn_text }}
|
|
||||||
</button>
|
|
||||||
</form>
|
|
||||||
<button class='usa-button usa-button-secondary' v-close-popover>
|
|
||||||
{{ cancel_btn_text }}
|
|
||||||
</button>
|
|
||||||
</div>
|
|
||||||
</template>
|
|
||||||
<button class="tooltip-target" v-bind:class="[btn_class]" type="button">
|
|
||||||
<div v-html="btn_icon" />
|
|
||||||
{{ btn_text }}
|
|
||||||
</button>
|
|
||||||
</v-popover>
|
|
||||||
`,
|
|
||||||
}
|
|
@ -1,20 +0,0 @@
|
|||||||
{% macro ConfirmationButton(
|
|
||||||
btn_text,
|
|
||||||
action,
|
|
||||||
btn_icon=None,
|
|
||||||
btn_class=None,
|
|
||||||
confirm_msg="Are you sure?",
|
|
||||||
confirm_btn="Confirm",
|
|
||||||
cancel_btn="Cancel")
|
|
||||||
-%}
|
|
||||||
<confirmation-popover
|
|
||||||
btn_text='{{ btn_text }}'
|
|
||||||
btn_icon='{{ btn_icon }}'
|
|
||||||
btn_class='{{ btn_class }}'
|
|
||||||
action='{{ action }}'
|
|
||||||
csrf_token='{{ csrf_token() }}'
|
|
||||||
confirm_msg='{{ confirm_msg }}'
|
|
||||||
confirm_btn_text='{{ confirm_btn }}'
|
|
||||||
cancel_btn_text='{{ cancel_btn }}'>
|
|
||||||
</confirmation-popover>
|
|
||||||
{%- endmacro %}
|
|
Loading…
x
Reference in New Issue
Block a user