diff options
Diffstat (limited to 'src/view/shell')
-rw-r--r-- | src/view/shell/Composer.web.tsx | 2 | ||||
-rw-r--r-- | src/view/shell/desktop/LeftNav.tsx | 3 | ||||
-rw-r--r-- | src/view/shell/desktop/RightNav.tsx | 1 | ||||
-rw-r--r-- | src/view/shell/index.tsx | 9 |
4 files changed, 13 insertions, 2 deletions
diff --git a/src/view/shell/Composer.web.tsx b/src/view/shell/Composer.web.tsx index e8f7908c2..b32ba90c4 100644 --- a/src/view/shell/Composer.web.tsx +++ b/src/view/shell/Composer.web.tsx @@ -76,11 +76,13 @@ const styles = StyleSheet.create({ borderRadius: 8, marginBottom: 0, borderWidth: 1, + // @ts-ignore web only maxHeight: 'calc(100% - (40px * 2))', }, containerMobile: { borderRadius: 0, marginBottom: BOTTOM_BAR_HEIGHT, + // @ts-ignore web only maxHeight: `calc(100% - ${BOTTOM_BAR_HEIGHT}px)`, }, }) diff --git a/src/view/shell/desktop/LeftNav.tsx b/src/view/shell/desktop/LeftNav.tsx index 087455d3f..6df121fae 100644 --- a/src/view/shell/desktop/LeftNav.tsx +++ b/src/view/shell/desktop/LeftNav.tsx @@ -367,8 +367,10 @@ const styles = StyleSheet.create({ leftNav: { position: 'absolute', top: 10, + // @ts-ignore web only right: 'calc(50vw + 312px)', width: 220, + // @ts-ignore web only maxHeight: 'calc(100vh - 10px)', overflowY: 'auto', }, @@ -413,6 +415,7 @@ const styles = StyleSheet.create({ width: 28, height: 28, marginTop: 2, + zIndex: 1, }, navItemIconWrapperTablet: { width: 40, diff --git a/src/view/shell/desktop/RightNav.tsx b/src/view/shell/desktop/RightNav.tsx index 746bbcf59..797058d6c 100644 --- a/src/view/shell/desktop/RightNav.tsx +++ b/src/view/shell/desktop/RightNav.tsx @@ -120,6 +120,7 @@ const styles = StyleSheet.create({ rightNav: { position: 'absolute', top: 20, + // @ts-ignore web only left: 'calc(50vw + 310px)', width: 304, }, diff --git a/src/view/shell/index.tsx b/src/view/shell/index.tsx index 72e7facc8..c5080e866 100644 --- a/src/view/shell/index.tsx +++ b/src/view/shell/index.tsx @@ -1,7 +1,12 @@ import React from 'react' import {observer} from 'mobx-react-lite' import {StatusBar} from 'expo-status-bar' -import {StyleSheet, useWindowDimensions, View} from 'react-native' +import { + DimensionValue, + StyleSheet, + useWindowDimensions, + View, +} from 'react-native' import {useSafeAreaInsets} from 'react-native-safe-area-context' import {Drawer} from 'react-native-drawer-layout' import {useNavigationState} from '@react-navigation/native' @@ -25,7 +30,7 @@ const ShellInner = observer(() => { const winDim = useWindowDimensions() const safeAreaInsets = useSafeAreaInsets() const containerPadding = React.useMemo( - () => ({height: '100%', paddingTop: safeAreaInsets.top}), + () => ({height: '100%' as DimensionValue, paddingTop: safeAreaInsets.top}), [safeAreaInsets], ) const renderDrawerContent = React.useCallback(() => <DrawerContent />, []) |