fdssfd
This commit is contained in:
parent
1bf59a9192
commit
52531644f5
30 changed files with 293 additions and 549 deletions
|
@ -1,8 +1,3 @@
|
|||
function timestamp(str, ti) {
|
||||
date = new Date(ti*1000);
|
||||
document.getElementById(str).setAttribute("data-bs-original-title", date.toString());
|
||||
};
|
||||
|
||||
function collapse_comment(comment_id) {
|
||||
const comment = "comment-" + comment_id
|
||||
const element = document.getElementById(comment)
|
||||
|
@ -15,26 +10,8 @@ function collapse_comment(comment_id) {
|
|||
}
|
||||
};
|
||||
|
||||
const popoverTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="popover"]'));
|
||||
const popoverList = popoverTriggerList.map(function(popoverTriggerEl) {
|
||||
const popoverId = popoverTriggerEl.getAttribute('data-content-id');
|
||||
const contentEl = document.getElementById(popoverId);
|
||||
if (contentEl) {
|
||||
return new bootstrap.Popover(popoverTriggerEl, {
|
||||
content: contentEl.innerHTML,
|
||||
html: true,
|
||||
});
|
||||
}
|
||||
})
|
||||
|
||||
function poll_vote_no_v() {
|
||||
var myToast = new bootstrap.Toast(document.getElementById('toast-post-error'));
|
||||
myToast.show();
|
||||
document.getElementById('toast-post-error-text').innerText = "Only logged-in users can vote!";
|
||||
}
|
||||
|
||||
function pinned_timestamp(id) {
|
||||
const el = document.getElementById(id)
|
||||
const time = new Date(eldataset.timestamp).toString()
|
||||
el.setAttribute("data-bs-original-title", `Pinned until ${time}`)
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue