Skip to content

Commit

Permalink
100vh settings screen (#4015)
Browse files Browse the repository at this point in the history
  • Loading branch information
mozzius authored May 14, 2024
1 parent 03da056 commit 6b2635c
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/screens/Messages/Settings.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export function MessagesSettingsScreen({}: Props) {
if (!gate('dms')) return <ClipClopGate />

return (
<CenteredView sideBorders>
<CenteredView sideBorders style={a.h_full_vh}>
<ViewHeader title={_(msg`Settings`)} showOnDesktop showBorder />
<View style={[a.px_md, a.py_lg, a.gap_md]}>
<Text style={[a.text_xl, a.font_bold, a.px_sm]}>
Expand Down
11 changes: 10 additions & 1 deletion src/view/com/util/Views.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,14 @@ export function CenteredView({
sideBorders,
...props
}: React.PropsWithChildren<
ViewProps & {sideBorders?: boolean; topBorder?: boolean}
ViewProps & {
/**
* @platform web
*/
sideBorders?: boolean
/**
* @platform web
*/
topBorder?: boolean
}
>)
5 changes: 3 additions & 2 deletions src/view/com/util/Views.web.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@ import {
View,
ViewProps,
} from 'react-native'
import {addStyle} from 'lib/styles'
import Animated from 'react-native-reanimated'

import {usePalette} from 'lib/hooks/usePalette'
import {useWebMediaQueries} from 'lib/hooks/useWebMediaQueries'
import Animated from 'react-native-reanimated'
import {addStyle} from 'lib/styles'

interface AddedProps {
desktopFixedHeight?: boolean | number
Expand Down

0 comments on commit 6b2635c

Please sign in to comment.