forked from rDrama/rDrama
fix remove_dialog() not getting applied when making root comment
parent
46c889f0c0
commit
27b1389da1
|
@ -171,6 +171,7 @@ function post_reply(id) {
|
||||||
input.value = null;
|
input.value = null;
|
||||||
oldfiles[ta.id] = []
|
oldfiles[ta.id] = []
|
||||||
|
|
||||||
|
remove_dialog();
|
||||||
restore_reply_buttons(`c_${id}`)
|
restore_reply_buttons(`c_${id}`)
|
||||||
} else {
|
} else {
|
||||||
showToast(false, getMessageFromJsonData(false, data));
|
showToast(false, getMessageFromJsonData(false, data));
|
||||||
|
@ -298,6 +299,8 @@ function post_comment(fullname, hide){
|
||||||
const ghost_town_box = document.getElementById('ghost-town-box')
|
const ghost_town_box = document.getElementById('ghost-town-box')
|
||||||
if (ghost_town_box) ghost_town_box.remove()
|
if (ghost_town_box) ghost_town_box.remove()
|
||||||
|
|
||||||
|
remove_dialog();
|
||||||
|
if (fullname.startsWith('c_'))
|
||||||
restore_reply_buttons(fullname)
|
restore_reply_buttons(fullname)
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -360,10 +363,10 @@ function restore_reply_buttons(fullname) {
|
||||||
newHTML += 'Reply'
|
newHTML += 'Reply'
|
||||||
t.innerHTML = newHTML
|
t.innerHTML = newHTML
|
||||||
}
|
}
|
||||||
remove_dialog();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function cancel(fullname) {
|
function cancel(fullname) {
|
||||||
document.getElementById(`reply-to-${fullname}`).classList.add('d-none')
|
document.getElementById(`reply-to-${fullname}`).classList.add('d-none')
|
||||||
|
remove_dialog();
|
||||||
restore_reply_buttons(fullname)
|
restore_reply_buttons(fullname)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue