border-bottom: none;
}
+#sone .post > .avatar {
+ position: absolute;
+}
+
+#sone .post > .inner-part {
+ margin-left: 48px;
+ padding-left: 0.5em;
+ min-height: 48px;
+}
+
#sone .post .author {
display: inline;
font-weight: bold;
}
#sone .post .status-line {
- clear: both;
margin-top: 0.5ex;
font-size: 85%;
}
padding-top: 0.2ex;
}
+#sone .post .reply > .avatar {
+ position: absolute;
+}
+
+#sone .post .reply > .inner-part {
+ margin-left: 36px;
+ padding-left: 0.5em;
+ min-height: 36px;
+}
+
#sone .post .reply {
clear: both;
background-color: #f0f0ff;
function likePost(postId) {
$.getJSON("ajax/like.ajax", { "type": "post", "post" : postId, "formPassword": getFormPassword() }, function() {
- $("#sone .post#" + postId + " > .status-line .like").addClass("hidden");
- $("#sone .post#" + postId + " > .status-line .unlike").removeClass("hidden");
+ $("#sone .post#" + postId + " > .inner-part > .status-line .like").addClass("hidden");
+ $("#sone .post#" + postId + " > .inner-part > .status-line .unlike").removeClass("hidden");
updatePostLikes(postId);
});
}
function unlikePost(postId) {
$.getJSON("ajax/unlike.ajax", { "type": "post", "post" : postId, "formPassword": getFormPassword() }, function() {
- $("#sone .post#" + postId + " > .status-line .unlike").addClass("hidden");
- $("#sone .post#" + postId + " > .status-line .like").removeClass("hidden");
+ $("#sone .post#" + postId + " > .inner-part > .status-line .unlike").addClass("hidden");
+ $("#sone .post#" + postId + " > .inner-part > .status-line .like").removeClass("hidden");
updatePostLikes(postId);
});
}
function updatePostLikes(postId) {
$.getJSON("ajax/getLikes.ajax", { "type": "post", "post": postId }, function(data, textStatus) {
if (data.success) {
- $("#sone .post#" + postId + " > .status-line .likes").toggleClass("hidden", data.likes == 0)
- $("#sone .post#" + postId + " > .status-line .likes span.like-count").text(data.likes);
- $("#sone .post#" + postId + " > .status-line .likes > span").attr("title", generateSoneList(data.sones));
+ $("#sone .post#" + postId + " > .inner-part > .status-line .likes").toggleClass("hidden", data.likes == 0)
+ $("#sone .post#" + postId + " > .inner-part > .status-line .likes span.like-count").text(data.likes);
+ $("#sone .post#" + postId + " > .inner-part > .status-line .likes > span").attr("title", generateSoneList(data.sones));
}
});
}
$(document).ready(function() {
$("#sone .post").each(function() {
postId = $(this).attr("id");
- enhanceDeletePostButton("#sone .post#" + postId + " > .status-line .delete button", postId);
+ enhanceDeletePostButton("#sone .post#" + postId + " > .inner-part > .status-line .delete button", postId);
(function(postId) {
$("#sone .post#" + postId + " .reply").each(function() {
replyId = $(this).attr("id");
<script language="javascript">
/* convert all “like” buttons to javascript functions. */
$(document).ready(function() {
- $("#sone .post > .status-line .like").submit(function() {
+ $("#sone .post > .inner-part > .status-line .like").submit(function() {
likePost(getPostId(this));
return false;
});
- $("#sone .post > .status-line .unlike").submit(function() {
+ $("#sone .post > .inner-part > .status-line .unlike").submit(function() {
unlikePost(getPostId(this));
return false;
});
<div id="<% post.id|html>" class="post<%if loop.last> last<%/if>">
+ <div class="avatar">
+ <img src="/WoT/GetIdenticon?identity=<% post.sone.id|html>&width=48&height=48" width="48" height="48" alt="Avatar Image" />
+ </div>
+ <div class="inner-part">
<div>
<div class="author profile-link"><a href="viewSone.html?sone=<% post.sone.id|html>"><% post.sone.niceName|html></a></div>
<div class="text"><% post.text|html></div>
<div class="replies">
<%foreach post.replies reply>
<div id="<% reply.id|html>" class="reply">
+ <div class="avatar">
+ <img src="/WoT/GetIdenticon?identity=<% reply.sone.id|html>&width=36&height=36" width="36" height="36" alt="Avatar Image" />
+ </div>
+ <div class="inner-part">
<div>
<div class="author profile-link"><a href="viewSone.html?sone=<% reply.sone.id|html>"><% reply.sone.niceName|html></a></div>
<div class="text"><% reply.text|html></div>
</form>
<%/if>
</div>
+ </div>
</div>
<%/foreach>
<%ifnull ! currentSone>
</div>
<%/if>
</div>
+ </div>
</div>