test 2
This commit is contained in:
1 parent
f56f2a70ab
commit
ba91f06e05
3 files changed
+228
-230
No files matched your search
+1
-8
@@ -67,14 +67,7 @@ document.addEventListener('DOMContentLoaded', () => {
|
||||
listEl.innerHTML = '';
|
||||
|
||||
if (titleEl) {
|
||||
const old = titleEl.querySelector('.comment-count-badge');
|
||||
if (old) old.remove();
|
||||
if (snap.size > 0) {
|
||||
const badge = document.createElement('span');
|
||||
badge.className = 'comment-count-badge';
|
||||
badge.textContent = snap.size;
|
||||
titleEl.appendChild(badge);
|
||||
}
|
||||
titleEl.textContent = snap.size > 0 ? `(${snap.size})` : '';
|
||||
}
|
||||
|
||||
if (snap.empty) {
|
||||
|
||||
Reference in new issue
Block a user