Popup for delete button attached
This commit is contained in:
parent
4f1ccf83c8
commit
910cde4380
|
@ -82,22 +82,23 @@ module.exports = function(state, emit) {
|
||||||
class="btn"
|
class="btn"
|
||||||
title="${state.translate('deleteFileButton')}"
|
title="${state.translate('deleteFileButton')}"
|
||||||
onclick=${showPopup}>${state.translate('deleteFileButton')}
|
onclick=${showPopup}>${state.translate('deleteFileButton')}
|
||||||
<div class="popup">
|
|
||||||
<div class="popuptext" onblur=${cancel} tabindex="-1">
|
|
||||||
<div class="popup-message">${state.translate(
|
|
||||||
'deletePopupText'
|
|
||||||
)}</div>
|
|
||||||
<div class="popup-action">
|
|
||||||
<span class="popup-no" onclick=${cancel}>${state.translate(
|
|
||||||
'deletePopupCancel'
|
|
||||||
)}</span>
|
|
||||||
<span class="popup-yes" onclick=${deleteFile}>${state.translate(
|
|
||||||
'deletePopupYes'
|
|
||||||
)}</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</button>
|
</button>
|
||||||
|
<div id="deletePopup" class="popup">
|
||||||
|
<div class="popuptext" onblur=${cancel} tabindex="-1">
|
||||||
|
<div class="popup-message">${state.translate('deletePopupText')}
|
||||||
|
</div>
|
||||||
|
<div class="popup-action">
|
||||||
|
<span class="popup-no" onclick=${cancel}>${state.translate(
|
||||||
|
'deletePopupCancel'
|
||||||
|
)}
|
||||||
|
</span>
|
||||||
|
<span class="popup-yes" onclick=${deleteFile}>${state.translate(
|
||||||
|
'deletePopupYes'
|
||||||
|
)}
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<a class="send-new"
|
<a class="send-new"
|
||||||
data-state="completed"
|
data-state="completed"
|
||||||
href="/"
|
href="/"
|
||||||
|
@ -113,7 +114,7 @@ module.exports = function(state, emit) {
|
||||||
|
|
||||||
function cancel(e) {
|
function cancel(e) {
|
||||||
e.stopPropagation();
|
e.stopPropagation();
|
||||||
const popupText = e.target.parentElement.parentElement;
|
const popupText = document.querySelector('.popuptext');
|
||||||
popupText.classList.remove('show');
|
popupText.classList.remove('show');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -636,6 +636,11 @@ tbody {
|
||||||
color: #313131;
|
color: #313131;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#deletePopup {
|
||||||
|
position: relative;
|
||||||
|
bottom: 50px;
|
||||||
|
}
|
||||||
|
|
||||||
#delete-file:hover {
|
#delete-file:hover {
|
||||||
background: #efeff1;
|
background: #efeff1;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue