diff --git a/files/templates/comments.html b/files/templates/comments.html index 17dcb06a4..2f54cc65c 100644 --- a/files/templates/comments.html +++ b/files/templates/comments.html @@ -211,7 +211,10 @@ {% for c in p.comments %} {% if not (v and v.id==c.author_id) and not c.voted %} if ({{c.created_utc*1000}} > lastCount.t) - try {document.getElementById("comment-{{c.id}}-only").classList.add('unread')} + try { + document.getElementById("comment-{{c.id}}-only").classList.add('unread') + document.getElementById("comment-{{c.id}}").querySelector(".comment-user-info").innerHTML += "~new~"; + } catch(e) {} {% endif %} {% endfor %} @@ -253,7 +256,10 @@ {% for c in p.comments %} {% if not (v and v.id==c.author_id) and not c.voted %} if ({{c.created_utc*1000}} > lastCount.t) - try {document.getElementById("comment-{{c.id}}-only").classList.add('unread')} + try { + document.getElementById("comment-{{c.id}}-only").classList.add('unread') + document.getElementById("comment-{{c.id}}").querySelector(".comment-user-info").innerHTML += "~new~"; + } catch(e) {} {% endif %} {% endfor %} diff --git a/files/templates/submission.html b/files/templates/submission.html index 83aaf8474..1f790652f 100644 --- a/files/templates/submission.html +++ b/files/templates/submission.html @@ -494,7 +494,10 @@ {% for c in p.comments %} {% if not (v and v.id==c.author_id) and not c.voted %} if ({{c.created_utc*1000}} > lastCount.t) - try {document.getElementById("comment-{{c.id}}-only").classList.add('unread')} + try { + document.getElementById("comment-{{c.id}}-only").classList.add('unread') + document.getElementById("comment-{{c.id}}").querySelector(".comment-user-info").innerHTML += "~new~"; + } catch(e) {} {% endif %} {% endfor %}