feat: edit expense
This commit is contained in:
parent
deda54152b
commit
5b71fa74b1
11 changed files with 273 additions and 41 deletions
39
app/(tabs)/home/expense/_layout.tsx
Normal file
39
app/(tabs)/home/expense/_layout.tsx
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
import { StyleSheet, Text, View } from 'react-native'
|
||||
import { Stack } from 'expo-router'
|
||||
import React from 'react'
|
||||
import { useTheme } from '../../../contexts/ThemeContext'
|
||||
|
||||
const _layout = () => {
|
||||
const {colors} = useTheme();
|
||||
return (
|
||||
<Stack
|
||||
initialRouteName="new"
|
||||
screenOptions={{
|
||||
contentStyle: {
|
||||
backgroundColor:colors.containerColor,
|
||||
},
|
||||
headerStyle: {
|
||||
backgroundColor: colors.containerColor
|
||||
},
|
||||
headerTintColor: colors.primaryText
|
||||
|
||||
}}>
|
||||
<Stack.Screen name='new'
|
||||
options={{
|
||||
title: "New Expense"
|
||||
|
||||
}}
|
||||
/>
|
||||
<Stack.Screen name="[expense]"
|
||||
options={{
|
||||
title: "edit Expense"
|
||||
}}
|
||||
getId={(params) => String(Date.now())}
|
||||
/>
|
||||
</Stack>
|
||||
)
|
||||
}
|
||||
|
||||
export default _layout
|
||||
|
||||
const styles = StyleSheet.create({})
|
||||
Reference in a new issue