aboutsummaryrefslogtreecommitdiff
path: root/src/components/moments
diff options
context:
space:
mode:
authorShravya Ramesh <shravs1208@gmail.com>2021-05-25 13:59:12 -0700
committerShravya Ramesh <shravs1208@gmail.com>2021-05-25 14:22:38 -0700
commitf25b4d4309bead2d9d5a5d9e8cc198d978deb875 (patch)
treebc2214d0fe851a072fbf63242ee0060012b9f0b8 /src/components/moments
parentb3041bb521fc4f52b414151eb4d8220791f6c874 (diff)
Pass remove() down, Add/remove removeTag btn
Diffstat (limited to 'src/components/moments')
-rw-r--r--src/components/moments/MomentPostHeader.tsx8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/components/moments/MomentPostHeader.tsx b/src/components/moments/MomentPostHeader.tsx
index 3c3ee4c3..ae9e96a0 100644
--- a/src/components/moments/MomentPostHeader.tsx
+++ b/src/components/moments/MomentPostHeader.tsx
@@ -1,5 +1,5 @@
import {useNavigation} from '@react-navigation/native';
-import React, {useState} from 'react';
+import React, {useEffect, useState} from 'react';
import {
StyleSheet,
Text,
@@ -20,6 +20,8 @@ interface MomentPostHeaderProps extends ViewProps {
screenType: ScreenType;
username: string;
momentId: string;
+ momentTagId: string;
+ removeTag: () => Promise<void>;
}
const MomentPostHeader: React.FC<MomentPostHeaderProps> = ({
@@ -28,6 +30,8 @@ const MomentPostHeader: React.FC<MomentPostHeaderProps> = ({
username,
momentId,
style,
+ momentTagId,
+ removeTag,
}) => {
const [drawerVisible, setDrawerVisible] = useState(false);
const dispatch = useDispatch();
@@ -66,6 +70,8 @@ const MomentPostHeader: React.FC<MomentPostHeaderProps> = ({
setIsOpen={setDrawerVisible}
momentId={momentId}
isOwnProfile={isOwnProfile}
+ momentTagId={momentTagId}
+ removeTag={removeTag}
dismissScreenAndUpdate={() => {
dispatch(loadUserMoments(loggedInUserId));
navigation.pop();