mirror of https://gitlab.com/bashrc2/epicyon
Show post author
parent
314a3aa047
commit
39bfc07ac5
63
epicyon.css
63
epicyon.css
|
@ -1,56 +1,61 @@
|
|||
@charset "UTF-8";
|
||||
|
||||
body {
|
||||
margin: 0 auto;
|
||||
max-width: 80%;
|
||||
padding: 0 20px;
|
||||
margin: 0 auto;
|
||||
max-width: 80%;
|
||||
padding: 0 20px;
|
||||
}
|
||||
|
||||
.container {
|
||||
border: 2px solid #dedede;
|
||||
background-color: #f1f1f1;
|
||||
border-radius: 5px;
|
||||
padding: 10px;
|
||||
margin: 10px 0;
|
||||
border: 2px solid #dedede;
|
||||
background-color: #f1f1f1;
|
||||
border-radius: 5px;
|
||||
padding: 10px;
|
||||
margin: 10px 0;
|
||||
}
|
||||
|
||||
.darker {
|
||||
border-color: #ccc;
|
||||
background-color: #ddd;
|
||||
border-color: #ccc;
|
||||
background-color: #ddd;
|
||||
}
|
||||
|
||||
.container::after {
|
||||
content: "";
|
||||
clear: both;
|
||||
display: table;
|
||||
content: "";
|
||||
clear: both;
|
||||
display: table;
|
||||
}
|
||||
|
||||
.container img {
|
||||
float: left;
|
||||
max-width: 60px;
|
||||
width: 100%;
|
||||
margin-right: 20px;
|
||||
border-radius: 50%;
|
||||
float: left;
|
||||
max-width: 60px;
|
||||
width: 100%;
|
||||
margin-right: 20px;
|
||||
border-radius: 50%;
|
||||
}
|
||||
|
||||
.container img.attachment {
|
||||
max-width: 100%;
|
||||
margin-left: 25%;
|
||||
width: 50%;
|
||||
border-radius: 0%;
|
||||
max-width: 100%;
|
||||
margin-left: 25%;
|
||||
width: 50%;
|
||||
border-radius: 0%;
|
||||
}
|
||||
.container img.right {
|
||||
float: right;
|
||||
margin-left: 20px;
|
||||
margin-right:0;
|
||||
float: right;
|
||||
margin-left: 20px;
|
||||
margin-right:0;
|
||||
}
|
||||
|
||||
.time-right {
|
||||
float: right;
|
||||
color: #aaa;
|
||||
float: right;
|
||||
color: #aaa;
|
||||
}
|
||||
|
||||
.time-left {
|
||||
float: left;
|
||||
color: #999;
|
||||
float: left;
|
||||
color: #999;
|
||||
}
|
||||
|
||||
.post-title {
|
||||
margin-top: 0px;
|
||||
color: #999;
|
||||
}
|
||||
|
|
|
@ -7,6 +7,8 @@ __email__ = "bob@freedombone.net"
|
|||
__status__ = "Production"
|
||||
|
||||
import json
|
||||
from utils import getNicknameFromActor
|
||||
from utils import getDomainFromActor
|
||||
|
||||
def htmlHeader(lang='en') -> str:
|
||||
htmlStr= \
|
||||
|
@ -72,10 +74,13 @@ def individualPostAsHtml(postJsonObject: {}) -> str:
|
|||
'<img src="'+attach['url']+'" alt="'+imageDescription+'" title="'+imageDescription+'" class="attachment"></a>\n'
|
||||
attachmentCtr+=1
|
||||
|
||||
nickname=getNicknameFromActor(postJsonObject['actor'])
|
||||
domain,port=getDomainFromActor(postJsonObject['actor'])
|
||||
return \
|
||||
'<div class="'+containerClass+'">\n' \
|
||||
'<a href="'+postJsonObject['actor']+'">' \
|
||||
'<img src="'+postJsonObject['actor']+'/avatar.png" alt="Avatar"'+avatarPosition+'></a>\n'+ \
|
||||
'<p class="post-title">@'+nickname+'@'+domain+'</p>'+ \
|
||||
postJsonObject['object']['content']+'\n'+ \
|
||||
attachmentStr+ \
|
||||
'<span class="'+timeClass+'">'+postJsonObject['object']['published']+'</span>\n'+ \
|
||||
|
|
Loading…
Reference in New Issue