diff --git a/bskyogcard/src/components/Avatar.tsx b/bskyogcard/src/components/Avatar.tsx index 0903c66616..7cdbc3fd2b 100644 --- a/bskyogcard/src/components/Avatar.tsx +++ b/bskyogcard/src/components/Avatar.tsx @@ -4,6 +4,7 @@ import {ModeratorData} from '../data/getModeratorData.js' import {Image as ImageSource} from '../data/getPostData.js' import {atoms as a, theme as t} from '../theme/index.js' import {Box} from './Box.js' +import {DefaultUser} from './icons/avatars/DefaultUser.js' import {Image} from './Image.js' export function Avatar({ @@ -35,7 +36,11 @@ export function Avatar({ filter: 'blur(2.5px)', }, ]}> - {image && } + {image ? ( + + ) : ( + + )} ) } diff --git a/bskyogcard/src/components/FeedCard.tsx b/bskyogcard/src/components/FeedCard.tsx index bef859c76a..9783e67af4 100644 --- a/bskyogcard/src/components/FeedCard.tsx +++ b/bskyogcard/src/components/FeedCard.tsx @@ -6,6 +6,7 @@ import {atoms as a, theme as t} from '../theme/index.js' import {formatCount} from '../util/formatCount.js' import {getModerationCauseInfo} from '../util/getModerationCauseInfo.js' import {Box} from './Box.js' +import {DefaultFeed} from './icons/avatars/DefaultFeed.js' import {Image} from './Image.js' import {ModeratedEmbed} from './ModeratedEmbed.js' import {Text} from './Text.js' @@ -47,7 +48,7 @@ export function FeedCard({ t.atoms.border_contrast_low, ]}> - {image && ( + {image ? ( + ) : ( + )} {displayName} diff --git a/bskyogcard/src/components/ListCard.tsx b/bskyogcard/src/components/ListCard.tsx index df5d6b7ddb..f12d21a995 100644 --- a/bskyogcard/src/components/ListCard.tsx +++ b/bskyogcard/src/components/ListCard.tsx @@ -5,6 +5,7 @@ import {PostData} from '../data/getPostData.js' import {atoms as a, theme as t} from '../theme/index.js' import {getModerationCauseInfo} from '../util/getModerationCauseInfo.js' import {Box} from './Box.js' +import {DefaultFeed} from './icons/avatars/DefaultFeed.js' import {Image} from './Image.js' import {ModeratedEmbed} from './ModeratedEmbed.js' import {Text} from './Text.js' @@ -46,7 +47,7 @@ export function ListCard({ t.atoms.border_contrast_low, ]}> - {image && ( + {image ? ( + ) : ( + )} {name} diff --git a/bskyogcard/src/components/Post/index.tsx b/bskyogcard/src/components/Post/index.tsx index b901e3e39c..04bd775f76 100644 --- a/bskyogcard/src/components/Post/index.tsx +++ b/bskyogcard/src/components/Post/index.tsx @@ -53,6 +53,9 @@ export function Post({ const hasInteractions = post.likeCount > 0 || post.repostCount > 0 const moderation = moderatePost(post, moderatorData.moderationOptions) + const bgTop = avatar?.colors?.muted ?? '#1083fe' + const bgBottom = avatar?.colors?.lightMuted ?? '#67b0fe' + return ( diff --git a/bskyogcard/src/components/icons/avatars/DefaultFeed.tsx b/bskyogcard/src/components/icons/avatars/DefaultFeed.tsx new file mode 100644 index 0000000000..39a190a963 --- /dev/null +++ b/bskyogcard/src/components/icons/avatars/DefaultFeed.tsx @@ -0,0 +1,13 @@ +import {IconProps} from '../types.js' + +export function DefaultFeed({size}: IconProps) { + return ( + + + + + ) +} diff --git a/bskyogcard/src/components/icons/avatars/DefaultList.tsx b/bskyogcard/src/components/icons/avatars/DefaultList.tsx new file mode 100644 index 0000000000..9e471fae17 --- /dev/null +++ b/bskyogcard/src/components/icons/avatars/DefaultList.tsx @@ -0,0 +1,20 @@ +import {IconProps} from '../types.js' + +export function DefaultList({size}: IconProps) { + return ( + + + + + + ) +} diff --git a/bskyogcard/src/components/icons/avatars/DefaultUser.tsx b/bskyogcard/src/components/icons/avatars/DefaultUser.tsx new file mode 100644 index 0000000000..8d591a64ec --- /dev/null +++ b/bskyogcard/src/components/icons/avatars/DefaultUser.tsx @@ -0,0 +1,16 @@ +import {IconProps} from '../types.js' + +export function DefaultUser({size}: IconProps) { + return ( + + + + + + ) +} diff --git a/bskyogcard/test.html b/bskyogcard/test.html index 800da012cd..b2810985c4 100644 --- a/bskyogcard/test.html +++ b/bskyogcard/test.html @@ -84,6 +84,17 @@ + +
+

Default avatars

+
+
Default avatar
+
Default avi quote
+
Default avi list
+
Default avi feed
+
+
+

Misc

@@ -93,7 +104,6 @@
Long handle
-