-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(web): enhance styling and add missing icons
- Loading branch information
Showing
28 changed files
with
416 additions
and
265 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
import FoodScreen from '@/components/Food/FoodScreen' | ||
import { FoodHeaderRight } from '@/components/Food/HeaderRight' | ||
import WorkaroundStack from '@/components/Universal/WorkaroundStack' | ||
import { useNavigation } from 'expo-router' | ||
import Head from 'expo-router/head' | ||
import React, { useEffect, useLayoutEffect, useState } from 'react' | ||
import { useTranslation } from 'react-i18next' | ||
|
||
export default function FoodRootScreen(): JSX.Element { | ||
const [isPageOpen, setIsPageOpen] = useState(false) | ||
const { t } = useTranslation('navigation') | ||
const navigation = useNavigation() | ||
useEffect(() => { | ||
setIsPageOpen(true) | ||
}, []) | ||
|
||
useLayoutEffect(() => { | ||
navigation.setOptions({ | ||
headerRight: () => <FoodHeaderRight />, | ||
}) | ||
}, [navigation]) | ||
|
||
return ( | ||
<> | ||
<Head> | ||
{/* eslint-disable-next-line react-native/no-raw-text */} | ||
<title>{t('navigation.food')}</title> | ||
<meta name="Food" content="Meal plan for the canteens" /> | ||
<meta property="expo:handoff" content="true" /> | ||
<meta property="expo:spotlight" content="true" /> | ||
</Head> | ||
<WorkaroundStack | ||
name={'food'} | ||
titleKey={'navigation.food'} | ||
component={isPageOpen ? FoodScreen : () => <></>} | ||
headerRightElement={FoodHeaderRight} | ||
androidFallback | ||
/> | ||
</> | ||
) | ||
} |
Oops, something went wrong.