mirror of https://git.lenooby09.tech/LeNooby09/social-app.git
1import {View} from 'react-native'
2
3import {usePalette} from '#/lib/hooks/usePalette'
4import {atoms as a, useBreakpoints} from '#/alf'
5import * as Layout from '#/components/Layout'
6import {Text} from '#/components/Typography'
7import {TimesLarge_Stroke2_Corner0_Rounded} from './icons/Times'
8
9export function SearchError({
10 title,
11 children,
12}: {
13 title?: string
14 children?: React.ReactNode
15}) {
16 const {gtMobile} = useBreakpoints()
17 const pal = usePalette('default')
18
19 return (
20 <Layout.Content>
21 <View
22 style={[
23 a.align_center,
24 a.gap_4xl,
25 a.px_xl,
26 {
27 paddingVertical: 150,
28 },
29 ]}>
30 <TimesLarge_Stroke2_Corner0_Rounded width={32} fill={pal.colors.icon} />
31 <View
32 style={[
33 a.align_center,
34 {maxWidth: gtMobile ? 394 : 294},
35 gtMobile ? a.gap_md : a.gap_sm,
36 ]}>
37 <Text
38 style={[
39 a.font_semi_bold,
40 a.text_lg,
41 a.text_center,
42 a.leading_snug,
43 ]}>
44 {title}
45 </Text>
46 {children}
47 </View>
48 </View>
49 </Layout.Content>
50 )
51}