Revert "del init"

This reverts commit 6667a41adc.
This commit is contained in:
Patryk
2025-04-04 20:36:50 +02:00
parent 6667a41adc
commit 83ee244190
38 changed files with 15291 additions and 0 deletions

View File

@@ -0,0 +1,32 @@
import { Link, Stack } from 'expo-router';
import { StyleSheet } from 'react-native';
import { ThemedText } from '@/components/ThemedText';
import { ThemedView } from '@/components/ThemedView';
export default function NotFoundScreen() {
return (
<>
<Stack.Screen options={{ title: 'Oops!' }} />
<ThemedView style={styles.container}>
<ThemedText type="title">This screen doesn't exist.</ThemedText>
<Link href="/" style={styles.link}>
<ThemedText type="link">Go to home screen!</ThemedText>
</Link>
</ThemedView>
</>
);
}
const styles = StyleSheet.create({
container: {
flex: 1,
alignItems: 'center',
justifyContent: 'center',
padding: 20,
},
link: {
marginTop: 15,
paddingVertical: 15,
},
});

View File

@@ -0,0 +1,17 @@
import { Stack } from "expo-router";
import { Appearance } from "react-native";
import {Colors} from "@/constants/Colors"
export default function RootLayout() {
const colorScheme = Appearance.getColorScheme();
const theme = colorScheme === 'dark' ? Colors.dark :
Colors.light;
return <Stack screenOptions={{ headerStyle: {backgroundColor:theme.background},
headerTintColor: theme.text
}}>
<Stack.Screen name="index"/>
<Stack.Screen name="+not-found" options={{headerShown:false}}/>
</Stack>;
}

View File

@@ -0,0 +1,14 @@
import { Text, View, Pressable } from "react-native";
import { Link } from "expo-router";
export default function Index() {
return (
<View>
<Link href="/notices" asChild>
<Pressable>
<Text>Notices</Text>
</Pressable>
</Link>
</View>
);
}

View File

@@ -0,0 +1,27 @@
import { Appearance, StyleSheet, Platform,
SafeAreaView,FlatList, ScrollView, View, Text } from "react-native";
import { Colors } from "@/constants/Colors";
import { MENU_ITEMS } from "@/constants/NoticeItems";
export default function MenuScreen(){
const colorScheme = Appearance.getColorScheme();
const theme = colorScheme === 'dark' ? Colors.dark : Colors.light;
const Container = Platform.OS === 'web' ? ScrollView : SafeAreaView;
return(
<Container>
<FlatList
data={MENU_ITEMS}
keyExtractor={(item) => item.id.toString()}
renderItem={({ item }) => (
<View>
<Text>{item.title}</Text>
</View>
)}
></FlatList>
</Container>
)
}