Tweak visibility display

This commit is contained in:
Ivan Habunek 2022-12-28 07:48:53 +01:00
parent 064cab1988
commit fa6b90a115
No known key found for this signature in database
GPG key ID: F5F0623FF5EBCB3D

View file

@ -320,12 +320,15 @@ class StatusDetails(urwid.Pile):
"direct": "yellow"
}
visibility = status.visibility.title()
visibility_color = visibility_colors.get(status.visibility, "gray")
yield ("pack", urwid.Text([
("red", "🠷 ") if status.bookmarked else "",
("gray", f"{status.data['replies_count']} "),
("yellow" if status.reblogged else "gray", f"{status.data['reblogs_count']} "),
("yellow" if status.favourited else "gray", f"{status.data['favourites_count']}"),
(visibility_colors[status.visibility], f" · {status.visibility}"),
(visibility_color, f" · {visibility}"),
("yellow", f" · Translated from {translated_from} ") if translated_from else "",
("gray", f" · {application}" if application else ""),
]))