mirror of https://gitlab.com/bashrc2/epicyon
Different color for moderated blog posts
parent
0e7490a44b
commit
94c2bd819e
|
@ -67,6 +67,7 @@
|
|||
--quote-font-size: 120%;
|
||||
--line-spacing: 130%;
|
||||
--line-spacing-newswire: 100%;
|
||||
--newswire-moderate-color: yellow;
|
||||
--column-left-width: 10vw;
|
||||
--column-center-width: 80vw;
|
||||
--column-right-width: 10vw;
|
||||
|
@ -231,6 +232,13 @@ a:focus {
|
|||
line-height: var(--line-spacing-newswire);
|
||||
}
|
||||
|
||||
.newswireItemModerate {
|
||||
font-size: var(--font-size-newswire);
|
||||
color: var(--newswire-moderate-color);
|
||||
font-weight: bold;
|
||||
line-height: var(--line-spacing-newswire);
|
||||
}
|
||||
|
||||
.newswireDate {
|
||||
font-size: var(--font-size-newswire);
|
||||
color: var(--newswire-date-color);
|
||||
|
|
|
@ -5342,8 +5342,16 @@ def htmlNewswire(newswire: str) -> str:
|
|||
"""
|
||||
htmlStr = ''
|
||||
for dateStr, item in newswire.items():
|
||||
htmlStr += '<p class="newswireItem">' + \
|
||||
'<a href="' + item[1] + '">' + item[0] + '</a>'
|
||||
if len(item) == 2:
|
||||
htmlStr += '<p class="newswireItem">' + \
|
||||
'<a href="' + item[1] + '">' + item[0] + '</a>'
|
||||
elif len(item) > 2:
|
||||
if item[2].startswith('moderate'):
|
||||
htmlStr += '<p class="newswireItemModerate">' + \
|
||||
'<a href="' + item[1] + '">' + item[0] + '</a>'
|
||||
else:
|
||||
htmlStr += '<p class="newswireItem">' + \
|
||||
'<a href="' + item[1] + '">' + item[0] + '</a>'
|
||||
htmlStr += ' <label class="newswireDate">'
|
||||
htmlStr += dateStr.replace('+00:00', '') + '</label></p>'
|
||||
return htmlStr
|
||||
|
|
Loading…
Reference in New Issue