Video records API

This commit is contained in:
Adolfo Reyna
2023-01-08 23:54:41 -05:00
parent 05d05f79f7
commit ff6e695bee
8 changed files with 54 additions and 14 deletions

View File

@@ -8,8 +8,10 @@ import VideoPlayer from './VideoPlayer';
const MediaView = (props) => {
const gState = useSnapshot(GlobalState);
const currentMedia = gState.currentMedia;
const mediaPost = gState.mediaPost;
const [state, setState] = useState('');
const currentStyles = state === "min" ? styles.min : styles.float;
//console.log(mediaPost)
return (
<>
@@ -20,7 +22,8 @@ const MediaView = (props) => {
}}>
<VideoPlayer
videoUrl={currentMedia}
postId={props.postId}
postId={mediaPost._id}
profileId={mediaPost.profileid}
videoStyle={{
top: -10
}}
@@ -40,6 +43,7 @@ const MediaView = (props) => {
opacity: 0.9
}} icon={"close"} color="#fff" onPress={()=>{
GlobalState.currentMedia = '';
GlobalState.mediaPost = {};
}}></IconButton>
<IconButton style={{
backgroundColor: "#c44d56",