about summary refs log tree commit diff
path: root/src/view/com/util/UserAvatar.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'src/view/com/util/UserAvatar.tsx')
-rw-r--r--src/view/com/util/UserAvatar.tsx17
1 files changed, 8 insertions, 9 deletions
diff --git a/src/view/com/util/UserAvatar.tsx b/src/view/com/util/UserAvatar.tsx
index 5a7a4801d..d0d2c273b 100644
--- a/src/view/com/util/UserAvatar.tsx
+++ b/src/view/com/util/UserAvatar.tsx
@@ -31,7 +31,7 @@ export function UserAvatar({
   handle: string
   displayName: string | undefined
   avatar?: string | null
-  onSelectNewAvatar?: (img: PickedMedia) => void
+  onSelectNewAvatar?: (img: PickedMedia | null) => void
 }) {
   const store = useStores()
   const pal = usePalette('default')
@@ -97,14 +97,13 @@ export function UserAvatar({
         )
       },
     },
-    // TODO: Remove avatar https://github.com/bluesky-social/social-app/issues/122
-    // {
-    //   label: 'Remove',
-    //   icon: ['far', 'trash-can'],
-    //   onPress: () => {
-    //   // Remove avatar API call
-    //   },
-    // },
+    {
+      label: 'Remove',
+      icon: ['far', 'trash-can'] as IconProp,
+      onPress: async () => {
+        onSelectNewAvatar?.(null)
+      },
+    },
   ]
   // onSelectNewAvatar is only passed as prop on the EditProfile component
   return onSelectNewAvatar ? (