Skip to content

Commit 20a5a33

Browse files
committed
Refine layout
1 parent 40a3dd3 commit 20a5a33

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

main.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -83,10 +83,11 @@ def into_format(self, fmt: str) -> str:
8383
if fmt == "text":
8484
return str(self)
8585
elif fmt == "html":
86-
return f"<strong>[{self.series} {self.date}]</strong> <em>{self.title}</em> by {', '.join(self.authors)}\n" + \
87-
f"(<a href='{self.link}'>Link</a>" + \
86+
return f"<strong>[{self.series} {self.date}] <em>{self.title}</em></strong><br>" + \
87+
f"<ul><li>Authors: {', '.join(self.authors)}</li>" + \
88+
f"<li><a href='{self.link}'>Link</a>" + \
8889
(f", <a href='{self.code}'>Code</a>" if self.code else "") + \
89-
")"
90+
"</ul>"
9091
else:
9192
raise ValueError(f"Unsupported format: {fmt}.")
9293

0 commit comments

Comments
 (0)