diff --git a/assets/icons/circleX_stroke2_corner0_rounded.svg b/assets/icons/circleX_stroke2_corner0_rounded.svg
new file mode 100644
index 0000000000..c887d0e903
--- /dev/null
+++ b/assets/icons/circleX_stroke2_corner0_rounded.svg
@@ -0,0 +1 @@
+
diff --git a/src/Navigation.tsx b/src/Navigation.tsx
index baf99f1103..807fd92e5b 100644
--- a/src/Navigation.tsx
+++ b/src/Navigation.tsx
@@ -69,6 +69,7 @@ import {SharedPreferencesTesterScreen} from '#/screens/E2E/SharedPreferencesTest
import HashtagScreen from '#/screens/Hashtag'
import {MessagesScreen} from '#/screens/Messages/ChatList'
import {MessagesConversationScreen} from '#/screens/Messages/Conversation'
+import {MessagesInboxScreen} from '#/screens/Messages/Inbox'
import {MessagesSettingsScreen} from '#/screens/Messages/Settings'
import {ModerationScreen} from '#/screens/Moderation'
import {Screen as ModerationInteractionSettings} from '#/screens/ModerationInteractionSettings'
@@ -411,6 +412,11 @@ function commonScreens(Stack: typeof HomeTab, unreadCountLabel?: string) {
getComponent={() => MessagesSettingsScreen}
options={{title: title(msg`Chat settings`), requireAuth: true}}
/>
+ MessagesInboxScreen}
+ options={{title: title(msg`Chat request inbox`), requireAuth: true}}
+ />
NotificationSettingsScreen}
diff --git a/src/alf/atoms.ts b/src/alf/atoms.ts
index c9db8accc3..1d3d5cab34 100644
--- a/src/alf/atoms.ts
+++ b/src/alf/atoms.ts
@@ -31,6 +31,18 @@ export const atoms = {
right: 0,
bottom: 0,
},
+ top_0: {
+ top: 0,
+ },
+ right_0: {
+ right: 0,
+ },
+ bottom_0: {
+ bottom: 0,
+ },
+ left_0: {
+ left: 0,
+ },
z_10: {
zIndex: 10,
},
@@ -93,6 +105,9 @@ export const atoms = {
/*
* Border radius
*/
+ rounded_0: {
+ borderRadius: 0,
+ },
rounded_2xs: {
borderRadius: tokens.borderRadius._2xs,
},
diff --git a/src/components/AvatarStack.tsx b/src/components/AvatarStack.tsx
index 1b27a95ace..63f5ed77a0 100644
--- a/src/components/AvatarStack.tsx
+++ b/src/components/AvatarStack.tsx
@@ -1,37 +1,37 @@
import {View} from 'react-native'
import {moderateProfile} from '@atproto/api'
+import {logger} from '#/logger'
import {useModerationOpts} from '#/state/preferences/moderation-opts'
import {useProfilesQuery} from '#/state/queries/profile'
import {UserAvatar} from '#/view/com/util/UserAvatar'
import {atoms as a, useTheme} from '#/alf'
+import * as bsky from '#/types/bsky'
export function AvatarStack({
profiles,
size = 26,
+ numPending,
+ backgroundColor,
}: {
- profiles: string[]
+ profiles: bsky.profile.AnyProfileView[]
size?: number
+ numPending?: number
+ backgroundColor?: string
}) {
const halfSize = size / 2
- const {data, error} = useProfilesQuery({handles: profiles})
const t = useTheme()
const moderationOpts = useModerationOpts()
- if (error) {
- console.error(error)
- return null
- }
-
- const isPending = !data || !moderationOpts
+ const isPending = (numPending && profiles.length === 0) || !moderationOpts
const items = isPending
- ? Array.from({length: profiles.length}).map((_, i) => ({
+ ? Array.from({length: numPending ?? profiles.length}).map((_, i) => ({
key: i,
profile: null,
moderation: null,
}))
- : data.profiles.map(item => ({
+ : profiles.map(item => ({
key: item.did,
profile: item,
moderation: moderateProfile(item, moderationOpts),
@@ -56,7 +56,7 @@ export function AvatarStack({
height: size,
left: i * -halfSize,
borderWidth: 1,
- borderColor: t.atoms.bg.backgroundColor,
+ borderColor: backgroundColor ?? t.atoms.bg.backgroundColor,
borderRadius: 999,
zIndex: 3 - i,
},
@@ -74,3 +74,33 @@ export function AvatarStack({
)
}
+
+export function AvatarStackWithFetch({
+ profiles,
+ size,
+ backgroundColor,
+}: {
+ profiles: string[]
+ size?: number
+ backgroundColor?: string
+}) {
+ const {data, error} = useProfilesQuery({handles: profiles})
+
+ if (error) {
+ if (error.name !== 'AbortError') {
+ logger.error('Error fetching profiles for AvatarStack', {
+ safeMessage: error,
+ })
+ }
+ return null
+ }
+
+ return (
+
+ )
+}
diff --git a/src/components/KnownFollowers.tsx b/src/components/KnownFollowers.tsx
index 1e7cf448a7..a883066caf 100644
--- a/src/components/KnownFollowers.tsx
+++ b/src/components/KnownFollowers.tsx
@@ -33,11 +33,13 @@ export function KnownFollowers({
moderationOpts,
onLinkPress,
minimal,
+ showIfEmpty,
}: {
profile: bsky.profile.AnyProfileView
moderationOpts: ModerationOpts
onLinkPress?: LinkProps['onPress']
minimal?: boolean
+ showIfEmpty?: boolean
}) {
const cache = React.useRef