diff --git a/App.tsx b/App.tsx index eb068e7..25bc1c6 100644 --- a/App.tsx +++ b/App.tsx @@ -22,6 +22,7 @@ import { QueryClientProvider, QueryClient } from "@tanstack/react-query"; import { StatusBar } from "expo-status-bar"; import UserInfoPage from "./src/routes/UserInfoPage/UserInfoPage"; import SubjectsPage from "./src/routes/SubjectsPage/SubjectsPage"; +import ConversationPage from "./src/routes/ConversationPage/ConversationPage"; import Loading from "./src/routes/Loading/Loading"; import StartStudying from "./src/routes/StartStudying/StartStudying"; import { ToastProvider } from "react-native-toast-notifications"; @@ -69,6 +70,7 @@ export default function App() { + }> + diff --git a/src/components/DrawerSettings/CustomDrawerContent.tsx b/src/components/DrawerSettings/CustomDrawerContent.tsx index 7a8d64b..cfd622a 100644 --- a/src/components/DrawerSettings/CustomDrawerContent.tsx +++ b/src/components/DrawerSettings/CustomDrawerContent.tsx @@ -178,7 +178,14 @@ export default function CustomDrawerContent(props: {}) { Register - + { + navigation.navigate("Conversation"); + }} + > + + Conversation + {/* Debug buttons for accessing revalidation and activation page ([{ + username: "You", + message: "Hello World naa ko diri canteen gutom sh*t.", + userId: Math.floor(Math.random() * 1000), + type: "o", + color: Math.floor(Math.random() * 16777215).toString(16) + }, { + username: "User 2", + message: "Hahahah shor oy.", + userId: Math.floor(Math.random() * 1000), + type: "i", + color: Math.floor(Math.random() * 16777215).toString(16) + }, { + username: "User 3", + message: "AHAHAHHA BOBO!", + userId: Math.floor(Math.random() * 1000), + type: "i", + color: Math.floor(Math.random() * 16777215).toString(16) + }, + { + username: "Vale", + message: "tanga valir! bobo!", + userId: Math.floor(Math.random() * 1000), + type: "i", + color: Math.floor(Math.random() * 16777215).toString(16) + }, + { + username: "You", + message: "Hoyy bobo!!!", + userId: Math.floor(Math.random() * 1000), + type: "o", + color: Math.floor(Math.random() * 16777215).toString(16) + }, { + username: "Valir", + message: "Gago! 1v1 nalng?", + userId: Math.floor(Math.random() * 1000), + type: "o", + color: Math.floor(Math.random() * 16777215).toString(16) + }, { + username: "User 2", + message: "Hello World", + userId: Math.floor(Math.random() * 1000), + type: "i", + color: Math.floor(Math.random() * 16777215).toString(16) + }, { + username: "User 3", + message: "Hello World", + userId: Math.floor(Math.random() * 1000), + type: "i", + color: Math.floor(Math.random() * 16777215).toString(16) + }, + { + username: "User 1", + message: "Hello World", + userId: Math.floor(Math.random() * 1000), + type: "o", + color: Math.floor(Math.random() * 16777215).toString(16) + }, + { + username: "User 1", + message: "Hello World", + userId: Math.floor(Math.random() * 1000), + type: "o", + color: Math.floor(Math.random() * 16777215).toString(16) + }, + { + username: "User 1", + message: "Hello World", + userId: Math.floor(Math.random() * 1000), + type: "o", + color: Math.floor(Math.random() * 16777215).toString(16) + }, + { + username: "User 1", + message: "Hello World", + userId: Math.floor(Math.random() * 1000), + type: "o", + color: Math.floor(Math.random() * 16777215).toString(16) + } + ]); + + return ( + + + + + Group#57605 + + 3 students + + + + + + + { + conversation.map((item: ConversationType) => ( + + + + { + item.type == 'i' ? : null + } + {item.username} + { + item.type == 'o' ? : null + } + + + {item.message} + + + )) + } + + + + + ); +} diff --git a/src/styles.tsx b/src/styles.tsx index 546847e..0f9ab15 100644 --- a/src/styles.tsx +++ b/src/styles.tsx @@ -203,5 +203,15 @@ const styles = StyleSheet.create({ padding: 0, border: 0, }, + chatbox: { + paddingHorizontal: 8, + height: 50, + marginVertical: 10, + borderWidth: 1, + color: colors.text_default, + backgroundColor: colors.primary_2, + borderRadius: 20, + borderColor: colors.primary_3, + } }); export default styles;