diff --git a/frontend/.gitignore b/frontend/.gitignore new file mode 100644 index 0000000..5873d9a --- /dev/null +++ b/frontend/.gitignore @@ -0,0 +1,6 @@ + +# @generated expo-cli sync-2b81b286409207a5da26e14c78851eb30d8ccbdb +# The following patterns were generated by expo-cli + +expo-env.d.ts +# @end expo-cli \ No newline at end of file diff --git a/frontend/app/(tabs)/_layout.tsx b/frontend/app/(tabs)/_layout.tsx index 79cd584..57aee00 100644 --- a/frontend/app/(tabs)/_layout.tsx +++ b/frontend/app/(tabs)/_layout.tsx @@ -17,12 +17,21 @@ export default function TabLayout() { ( ), }} /> + ( + + ), + }} + /> Settings - This code can be help you. - - - This app has two screens:{' '} - app/(tabs)/index.tsx and{' '} - app/(tabs)/explore.tsx - - - The layout file in app/(tabs)/_layout.tsx{' '} - sets up the tab navigator. - - - Learn more - - - - - You can open this project on Android, iOS, and the web. To open the web version, press{' '} - w in the terminal running this project. - - - - - For static images, you can use the @2x and{' '} - @3x suffixes to provide files for - different screen densities - - - - Learn more - - - - - Open app/_layout.tsx to see how to load{' '} - - custom fonts such as this one. - - - - Learn more - - - - - This template has light and dark mode support. The{' '} - useColorScheme() hook lets you inspect - what the user's current color scheme is, and so you can adjust UI colors accordingly. - - - Learn more - - - - - This template includes an example of an animated component. The{' '} - components/HelloWave.tsx component uses - the powerful react-native-reanimated library - to create a waving hand animation. - - {Platform.select({ - ios: ( - - The components/ParallaxScrollView.tsx{' '} - component provides a parallax effect for the header image. - - ), - })} - + ); } diff --git a/frontend/app/(tabs)/group.tsx b/frontend/app/(tabs)/group.tsx deleted file mode 100644 index 3773e80..0000000 --- a/frontend/app/(tabs)/group.tsx +++ /dev/null @@ -1,107 +0,0 @@ -import { Image, StyleSheet, Platform, Button, ActivityIndicator } from 'react-native'; - -import ParallaxScrollView from '@/components/ParallaxScrollView'; -import { ThemedText } from '@/components/ThemedText'; -import { ThemedView } from '@/components/ThemedView'; -import { useEffect, useState } from 'react'; - -interface Message { - title: string; - type: string; - additionally: { - payload: string; - }; -} - -interface Data { - users: string[]; - messages: Message[]; -} - -export default function GroupScreen() { - const [groupData, setGroupData] = useState(null); - - useEffect(() => { - fetch("http://127.0.0.1:8099/grouphash:1/reloadDataFromServer") - .then(v => v.json()) - .then((data: Data) => { - setGroupData(data); - }) - .catch(e => { - console.log(e); - }); - }, []); - - return ( - - }> - - - Пользователи - {groupData?.users.map((user, index) => ( - {user} - ))} - - - - { groupData === null ? - : - groupData?.messages.map((message, index) => ( - - {message.title} - { message.type === "text" ? - {message.additionally.payload} : - !!! Please Update Program !!! - } - - - )) - } - - -