@@ -8,7 +8,6 @@ import React, {
88} from 'react' ;
99import { useTranslation } from 'react-i18next' ;
1010import { StyleSheet , View } from 'react-native' ;
11- import { useAppDispatch , useAppSelector } from '../../hooks/redux' ;
1211
1312import Dialog from '../../components/Dialog' ;
1413import Divider from '../../components/Divider' ;
@@ -19,8 +18,10 @@ import ProfileLinks from '../../components/ProfileLinks';
1918import SafeAreaInset from '../../components/SafeAreaInset' ;
2019import Button from '../../components/buttons/Button' ;
2120import { Keyboard } from '../../hooks/keyboard' ;
21+ import { useAppDispatch , useAppSelector } from '../../hooks/redux' ;
2222import { useProfile , useSlashtags } from '../../hooks/slashtags' ;
2323import ProfileLinkNavigation from '../../navigation/bottom-sheet/ProfileLinkNavigation' ;
24+ import { useSheetRef } from '../../navigation/bottom-sheet/SheetRefsProvider' ;
2425import type { RootStackScreenProps } from '../../navigation/types' ;
2526import { slashtagsLinksSelector } from '../../store/reselect/slashtags' ;
2627import { onboardingProfileStepSelector } from '../../store/reselect/slashtags' ;
@@ -29,7 +30,6 @@ import {
2930 setOnboardingProfileStep ,
3031} from '../../store/slices/slashtags' ;
3132import { BasicProfile } from '../../store/types/slashtags' ;
32- import { showBottomSheet } from '../../store/utils/ui' ;
3333import { ScrollView , View as ThemedView } from '../../styles/components' ;
3434import { PlusIcon } from '../../styles/icons' ;
3535import { BodyS } from '../../styles/text' ;
@@ -48,6 +48,7 @@ const ProfileEdit = ({
4848 const [ showDeleteDialog , setShowDeleteDialog ] = useState ( false ) ;
4949 const [ fields , setFields ] = useState < Omit < BasicProfile , 'links' > > ( { } ) ;
5050 const dispatch = useAppDispatch ( ) ;
51+ const sheetRef = useSheetRef ( 'profileAddDataForm' ) ;
5152 const links = useAppSelector ( slashtagsLinksSelector ) ;
5253 const onboardingStep = useAppSelector ( onboardingProfileStepSelector ) ;
5354
@@ -94,7 +95,7 @@ const ProfileEdit = ({
9495
9596 const onAddLink = async ( ) : Promise < void > => {
9697 await Keyboard . dismiss ( ) ;
97- showBottomSheet ( 'profileAddDataForm' ) ;
98+ sheetRef . current ?. present ( ) ;
9899 } ;
99100
100101 const onSave = async ( ) : Promise < void > => {
0 commit comments