mirror of
https://github.com/codex-team/codex.docs.git
synced 2025-08-09 07:25:21 +02:00
add confirmation
This commit is contained in:
parent
f7cb2406d7
commit
d6209f8578
3 changed files with 7 additions and 4 deletions
2
public/dist/main.bundle.js
vendored
2
public/dist/main.bundle.js
vendored
File diff suppressed because one or more lines are too long
|
@ -64,6 +64,11 @@ export default class Writing {
|
||||||
|
|
||||||
if (this.nodes.removeButton) {
|
if (this.nodes.removeButton) {
|
||||||
this.nodes.removeButton.addEventListener('click', () => {
|
this.nodes.removeButton.addEventListener('click', () => {
|
||||||
|
const isUserAgree = confirm("Are you sure?");
|
||||||
|
if (!isUserAgree) {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
this.removeButtonClicked();
|
this.removeButtonClicked();
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,9 +53,7 @@
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</div>
|
</div>
|
||||||
{% if page is not empty %}
|
{% if page is not empty %}
|
||||||
<main>
|
<p><input type="text" class="uri-input" name="uri-input" placeholder="Uri(Optional)" value="{{ page.uri }}"></p>
|
||||||
<input type="text" class="uri-input" name="uri-input" placeholder="Uri(Optional)" value="{{ page.uri }}">
|
|
||||||
</main>
|
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</section>
|
</section>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue