From b8e6807925dd5c5ed948ddb94c741a99e76adb79 Mon Sep 17 00:00:00 2001 From: vineyardbovines Date: Wed, 2 Sep 2026 17:19:47 -0400 Subject: [PATCH] Show starter pack opt-outs in an admonition --- .../StarterPack/Main/ProfilesList.tsx | 64 ++++++++++--------- 1 file changed, 33 insertions(+), 31 deletions(-) diff --git a/src/components/StarterPack/Main/ProfilesList.tsx b/src/components/StarterPack/Main/ProfilesList.tsx index ef65c652bf..05c0227ae5 100644 --- a/src/components/StarterPack/Main/ProfilesList.tsx +++ b/src/components/StarterPack/Main/ProfilesList.tsx @@ -16,12 +16,12 @@ import {useSession} from '#/state/session' import {List, type ListRef} from '#/view/com/util/List' import {type SectionRef} from '#/screens/Profile/Sections/types' import {atoms as a, useTheme} from '#/alf' -import {Button, ButtonIcon, ButtonText} from '#/components/Button' +import * as Admonition from '#/components/Admonition' +import {ButtonIcon, ButtonText} from '#/components/Button' import {ListFooter, ListMaybePlaceholder} from '#/components/Lists' import {Loader} from '#/components/Loader' import {Default as ProfileCard} from '#/components/ProfileCard' import * as Toast from '#/components/Toast' -import {Text} from '#/components/Typography' import {IS_NATIVE, IS_WEB} from '#/env' import {type app} from '#/lexicons' @@ -159,7 +159,6 @@ function OptedOutControls({ canRemove: boolean }) { const {_} = useLingui() - const t = useTheme() const {mutate: removeMembership, isPending} = useListMembershipRemoveMutation( { onSuccess: () => Toast.show(_(msg`Removed from starter pack`)), @@ -171,33 +170,36 @@ function OptedOutControls({ ) return ( - - - Opted out of this starter pack - - {canRemove ? ( - - ) : null} - + + + + + + Opted out of this starter pack + + + {canRemove ? ( + + removeMembership({ + listUri, + actorDid: item.subject.did, + membershipUri: item.uri, + }) + }> + {isPending ? ( + + ) : ( + + Remove + + )} + + ) : null} + + ) }