i dont understand the navigation with tabs and sub-stack routing but this is as close as im going to get it for now as it is 12:48 am and i must be up at 6:30 lol
This commit is contained in:
@@ -1,13 +1,20 @@
|
||||
import { router } from 'expo-router'
|
||||
import React from 'react'
|
||||
import { StyleSheet, Text, TouchableOpacity, View } from 'react-native'
|
||||
|
||||
import { Post, StatusEnum } from '../models/postModel'
|
||||
|
||||
export const CompactPostComponent: React.FC<Post> = (post) => {
|
||||
console.log()
|
||||
console.log()
|
||||
|
||||
return (
|
||||
<TouchableOpacity key={post._id} style={styles.posts}>
|
||||
<TouchableOpacity key={post._id} style={styles.posts} onPress={()=>{
|
||||
router.push({
|
||||
pathname: '/posts/details',
|
||||
params: {
|
||||
id: post._id,
|
||||
}
|
||||
})
|
||||
}}>
|
||||
<View style={styles.header}>
|
||||
<Text style={[styles.text, styles.date]}>{post.notes}</Text>
|
||||
<View style={{ flexDirection: 'row', justifyContent: 'space-between' }}>
|
||||
|
||||
Reference in New Issue
Block a user