diff options
| author | s-ol <s+removethis@s-ol.nu> | 2022-01-12 09:17:26 +0000 |
|---|---|---|
| committer | s-ol <s+removethis@s-ol.nu> | 2022-01-12 09:33:13 +0000 |
| commit | 0d5e63dde3da4116a49f6c83eb6094d68a41b914 (patch) | |
| tree | 4d7c347d8ef39ab92502a289a83fa237efef9648 /src/ui/Note.js | |
| parent | collapse using ellipsis, hide media (diff) | |
| download | fedidag-0d5e63dde3da4116a49f6c83eb6094d68a41b914.tar.gz fedidag-0d5e63dde3da4116a49f6c83eb6094d68a41b914.zip | |
handle errors while loading more gracefully
Diffstat (limited to 'src/ui/Note.js')
| -rw-r--r-- | src/ui/Note.js | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/ui/Note.js b/src/ui/Note.js index d4ef30a..63905e4 100644 --- a/src/ui/Note.js +++ b/src/ui/Note.js @@ -49,6 +49,14 @@ section > header > .avatar { flex: 0 0 auto; margin: 0.25rem; border-radius: 0.3rem; + + font-size: 1.5rem; + font-weight: bold; + line-height: 2rem; + text-align: center; + text-decoration: none; + background: white; + color: black; } section > header > .avatar img { width: inherit; @@ -78,7 +86,7 @@ section > header > .user { } section > header > .time { - flex: 0 1 auto; + flex: 0 0 auto; font-size: 0.8em; color: #363636; } @@ -94,7 +102,9 @@ const Header = ({ id, user, published, collapsed, onCollapse }) => { return ( <header> <a class="avatar" href={user.id}> - <img src={new URL(user.icon.url, user.id)} /> + {user.icon + ? <img src={new URL(user.icon.url, user.id)} /> + : "?"} </a> <span class="user">{username}</span> <Space /> |
