diff options
| author | Akshay Nair <phenax5@gmail.com> | 2024-05-12 20:04:58 +0530 |
|---|---|---|
| committer | Akshay Nair <phenax5@gmail.com> | 2024-09-29 16:16:39 +0530 |
| commit | dda041a9aebc23f7a0576fc4030d06c71fa370d2 (patch) | |
| tree | 545016cf9df58395dfebc520f9e26dd802a2ffa6 /App.tsx | |
| parent | d87cea9ff2467f93be28533938dfc3a3e5c0c937 (diff) | |
| download | daft-launcher-dda041a9aebc23f7a0576fc4030d06c71fa370d2.tar.gz daft-launcher-dda041a9aebc23f7a0576fc4030d06c71fa370d2.zip | |
Add draggable favorite apps list
Diffstat (limited to 'App.tsx')
| -rw-r--r-- | App.tsx | 31 |
1 files changed, 17 insertions, 14 deletions
@@ -4,6 +4,7 @@ import {InstalledApps} from 'react-native-launcher-kit'; import Swiper from 'react-native-swiper'; import {AppList} from './src/screens/AppList'; import {Home} from './src/screens/Home'; +import {GestureHandlerRootView} from 'react-native-gesture-handler'; function App(): React.JSX.Element { const [apps, setApps] = useState(() => InstalledApps.getSortedApps()); @@ -11,21 +12,23 @@ function App(): React.JSX.Element { const [screenIndex, setScreenIndex] = useState(0); return ( - <SafeAreaView className="flex flex-1 bg-slate-100 dark:bg-black"> - <Swiper - autoplay={false} - horizontal - loop={false} - loadMinimal - dot={<></>} - activeDot={<></>} - index={screenIndex} - onIndexChanged={setScreenIndex}> - <Home /> + <GestureHandlerRootView> + <SafeAreaView className="flex flex-1 bg-slate-100 dark:bg-black"> + <Swiper + autoplay={false} + horizontal + loop={false} + loadMinimal + dot={<></>} + activeDot={<></>} + index={screenIndex} + onIndexChanged={setScreenIndex}> + <Home apps={apps} /> - <AppList apps={apps} screenIndex={screenIndex} /> - </Swiper> - </SafeAreaView> + <AppList apps={apps} screenIndex={screenIndex} /> + </Swiper> + </SafeAreaView> + </GestureHandlerRootView> ); } |
