aboutsummaryrefslogtreecommitdiff
path: root/juick-www/src
diff options
context:
space:
mode:
Diffstat (limited to 'juick-www/src')
-rw-r--r--juick-www/src/main/static/scripts.js10
1 files changed, 4 insertions, 6 deletions
diff --git a/juick-www/src/main/static/scripts.js b/juick-www/src/main/static/scripts.js
index ad6d2e66..4cd1bc82 100644
--- a/juick-www/src/main/static/scripts.js
+++ b/juick-www/src/main/static/scripts.js
@@ -182,30 +182,28 @@ function isTreeMode() {
}
function wsIncomingReply(msg) {
- const unsetProto = (url) => url.replace(/^(https?:)?(?=\/\/)/i, '');
let msgNum = '/' + msg.rid;
if (msg.replyto > 0) {
msgNum += ` ${i18n('message.inReplyTo')} <a href="#${msg.replyto}">/${msg.replyto}</a>`;
}
- let photoDiv = (msg.photo === undefined) ? '' : `
+ let photoDiv = (msg.attach === undefined) ? '' : `
<div class="msg-media"><a href="//i.juick.com/p/${msg.mid}-${msg.rid}.${msg.attach}">
- <img src="${unsetProto(msg.photo.small)}"/></a>
+ <img src="//i.juick.com/photos-512/${msg.mid}-${msg.rid}.${msg.attach}"/></a>
</div>`;
let msgContHtml = `
<div class="msg-cont">
<div class="msg-header">
- @<a href="/${msg.user.uname}/">${msg.user.uname}</a>:
+ <a href="/${msg.user.uname}/">${msg.user.uname}</a>:
<div class="msg-avatar">
<a href="/${msg.user.uname}/"><img src="//i.juick.com/a/${msg.user.uid}.png" alt="${msg.user.uname}"/></a>
</div>
- <div class="msg-menu"><a href="#"><i data-icon="ei-link" data-size="s"></i></a></div>
<div class="msg-ts">
<a href="/${msg.mid}#${msg.rid}" title="${msg.timestamp}GMT">${msg.timestamp}</a>
</div>
</div>
<div class="msg-txt">${killy.format(msg.body, msg.mid, false)}</div>${photoDiv}
<div class="msg-links">${msgNum} &middot; <a class="msg-reply-link" href="#">${i18n('message.reply')}</a></div>
- <div class="msg-comment" style="display: none;"></div>
+ <div class="msg-comment msg-comment-hidden"></div>
</div>`;
let li = document.createElement('li');