mirror of
https://github.com/reddit-archive/reddit.git
synced 2026-01-27 07:48:16 -05:00
Move [deleted] logic into wrappeduser.mobile, add author class.
This commit is contained in:
committed by
Logan Hanks
parent
b9f4f970f5
commit
6fe4db8eae
@@ -46,22 +46,7 @@
|
||||
</%def>
|
||||
|
||||
<%def name="author(friend = False, gray = False)" buffered="True">
|
||||
%if WrappedUser(thing.author).user_deleted:
|
||||
<span>[deleted]</span>
|
||||
%else:
|
||||
<%
|
||||
author = thing.author
|
||||
author_cls = "author"
|
||||
if friend:
|
||||
author_cls += " friend"
|
||||
elif gray:
|
||||
author_cls += " gray"
|
||||
name = websafe(author.name)
|
||||
href = unsafe('href="/user/%s.mobile"' % name)
|
||||
if c.user_is_admin: name += " (%d)" % (author.link_karma)
|
||||
%>
|
||||
${WrappedUser(thing.author, thing.attribs, thing, gray = collapse).render()}
|
||||
%endif
|
||||
</%def>
|
||||
|
||||
<%def name="score(this, likes=None, inline=True, label = True, _id = True)">
|
||||
|
||||
@@ -27,11 +27,15 @@ else:
|
||||
flair = False
|
||||
%>
|
||||
|
||||
%if flair and flair_left:
|
||||
<span class="flair">${flair}</span>
|
||||
%endif
|
||||
<a href="/user/${thing.name}">0<
|
||||
<b>${thing.name}</b></a>
|
||||
%if flair and not flair_left:
|
||||
<span class="flair">${flair}</span>
|
||||
%if WrappedUser(thing.author).user_deleted:
|
||||
<span>[deleted]</span>
|
||||
%else:
|
||||
%if flair and flair_left:
|
||||
<span class="flair">${flair}</span>
|
||||
%endif
|
||||
<a href="/user/${thing.name}" class="${thing.author_cls}">
|
||||
<b>${thing.name}</b></a>
|
||||
%if flair and not flair_left:
|
||||
<span class="flair">${flair}</span>
|
||||
%endif
|
||||
%endif
|
||||
|
||||
Reference in New Issue
Block a user