UNPKG

6.98 kBTypeScriptView Raw
1import * as React from 'react';
2import { StyleProp, View, ViewStyle } from 'react-native';
3import { Appbar } from './Appbar';
4declare type Props = React.ComponentProps<typeof Appbar> & {
5 /**
6 * Whether the background color is a dark color. A dark header will render light text and vice-versa.
7 */
8 dark?: boolean;
9 /**
10 * Extra padding to add at the top of header to account for translucent status bar.
11 * This is automatically handled on iOS >= 11 including iPhone X using `SafeAreaView`.
12 * If you are using Expo, we assume translucent status bar and set a height for status bar automatically.
13 * Pass `0` or a custom value to disable the default behaviour, and customize the height.
14 */
15 statusBarHeight?: number;
16 /**
17 * Content of the header.
18 */
19 children: React.ReactNode;
20 /**
21 * @optional
22 */
23 theme: ReactNativePaper.Theme;
24 style?: StyleProp<ViewStyle>;
25};
26declare const _default: React.ComponentType<(Pick<Pick<Partial<import("react-native").ViewProps & React.RefAttributes<View>> & {
27 dark?: boolean | undefined;
28 children: React.ReactNode;
29 theme: ReactNativePaper.Theme;
30 style?: StyleProp<ViewStyle>;
31}, keyof import("react-native").ViewProps | "dark" | keyof React.RefAttributes<View>> & {
32 theme?: import("@callstack/react-theme-provider").$DeepPartial<ReactNativePaper.Theme> | undefined;
33} & {
34 /**
35 * Whether the background color is a dark color. A dark header will render light text and vice-versa.
36 */
37 dark?: boolean | undefined;
38 /**
39 * Extra padding to add at the top of header to account for translucent status bar.
40 * This is automatically handled on iOS >= 11 including iPhone X using `SafeAreaView`.
41 * If you are using Expo, we assume translucent status bar and set a height for status bar automatically.
42 * Pass `0` or a custom value to disable the default behaviour, and customize the height.
43 */
44 statusBarHeight?: number | undefined;
45 /**
46 * Content of the header.
47 */
48 children: React.ReactNode;
49 /**
50 * @optional
51 */
52 theme: ReactNativePaper.Theme;
53 style?: StyleProp<ViewStyle>;
54}, keyof import("react-native").ViewProps | "dark" | keyof React.RefAttributes<View> | "statusBarHeight"> | Pick<Pick<Partial<import("react-native").ViewProps & React.RefAttributes<View>> & {
55 dark?: boolean | undefined;
56 children: React.ReactNode;
57 theme: ReactNativePaper.Theme;
58 style?: StyleProp<ViewStyle>;
59}, keyof import("react-native").ViewProps | "dark" | keyof React.RefAttributes<View>> & {
60 theme?: import("@callstack/react-theme-provider").$DeepPartial<ReactNativePaper.Theme> | undefined;
61} & {
62 children?: React.ReactNode;
63} & {
64 /**
65 * Whether the background color is a dark color. A dark header will render light text and vice-versa.
66 */
67 dark?: boolean | undefined;
68 /**
69 * Extra padding to add at the top of header to account for translucent status bar.
70 * This is automatically handled on iOS >= 11 including iPhone X using `SafeAreaView`.
71 * If you are using Expo, we assume translucent status bar and set a height for status bar automatically.
72 * Pass `0` or a custom value to disable the default behaviour, and customize the height.
73 */
74 statusBarHeight?: number | undefined;
75 /**
76 * Content of the header.
77 */
78 children: React.ReactNode;
79 /**
80 * @optional
81 */
82 theme: ReactNativePaper.Theme;
83 style?: StyleProp<ViewStyle>;
84}, keyof import("react-native").ViewProps | "dark" | keyof React.RefAttributes<View> | "statusBarHeight">) & {
85 theme?: import("@callstack/react-theme-provider").$DeepPartial<ReactNativePaper.Theme> | undefined;
86}> & import("@callstack/react-theme-provider/typings/hoist-non-react-statics").NonReactStatics<React.ComponentType<Props> & {
87 (props: Props): JSX.Element;
88 displayName: string;
89}, {}>;
90export default _default;
91declare const AppbarHeaderWithTheme: React.ComponentType<(Pick<Pick<Partial<import("react-native").ViewProps & React.RefAttributes<View>> & {
92 dark?: boolean | undefined;
93 children: React.ReactNode;
94 theme: ReactNativePaper.Theme;
95 style?: StyleProp<ViewStyle>;
96}, keyof import("react-native").ViewProps | "dark" | keyof React.RefAttributes<View>> & {
97 theme?: import("@callstack/react-theme-provider").$DeepPartial<ReactNativePaper.Theme> | undefined;
98} & {
99 /**
100 * Whether the background color is a dark color. A dark header will render light text and vice-versa.
101 */
102 dark?: boolean | undefined;
103 /**
104 * Extra padding to add at the top of header to account for translucent status bar.
105 * This is automatically handled on iOS >= 11 including iPhone X using `SafeAreaView`.
106 * If you are using Expo, we assume translucent status bar and set a height for status bar automatically.
107 * Pass `0` or a custom value to disable the default behaviour, and customize the height.
108 */
109 statusBarHeight?: number | undefined;
110 /**
111 * Content of the header.
112 */
113 children: React.ReactNode;
114 /**
115 * @optional
116 */
117 theme: ReactNativePaper.Theme;
118 style?: StyleProp<ViewStyle>;
119}, keyof import("react-native").ViewProps | "dark" | keyof React.RefAttributes<View> | "statusBarHeight"> | Pick<Pick<Partial<import("react-native").ViewProps & React.RefAttributes<View>> & {
120 dark?: boolean | undefined;
121 children: React.ReactNode;
122 theme: ReactNativePaper.Theme;
123 style?: StyleProp<ViewStyle>;
124}, keyof import("react-native").ViewProps | "dark" | keyof React.RefAttributes<View>> & {
125 theme?: import("@callstack/react-theme-provider").$DeepPartial<ReactNativePaper.Theme> | undefined;
126} & {
127 children?: React.ReactNode;
128} & {
129 /**
130 * Whether the background color is a dark color. A dark header will render light text and vice-versa.
131 */
132 dark?: boolean | undefined;
133 /**
134 * Extra padding to add at the top of header to account for translucent status bar.
135 * This is automatically handled on iOS >= 11 including iPhone X using `SafeAreaView`.
136 * If you are using Expo, we assume translucent status bar and set a height for status bar automatically.
137 * Pass `0` or a custom value to disable the default behaviour, and customize the height.
138 */
139 statusBarHeight?: number | undefined;
140 /**
141 * Content of the header.
142 */
143 children: React.ReactNode;
144 /**
145 * @optional
146 */
147 theme: ReactNativePaper.Theme;
148 style?: StyleProp<ViewStyle>;
149}, keyof import("react-native").ViewProps | "dark" | keyof React.RefAttributes<View> | "statusBarHeight">) & {
150 theme?: import("@callstack/react-theme-provider").$DeepPartial<ReactNativePaper.Theme> | undefined;
151}> & import("@callstack/react-theme-provider/typings/hoist-non-react-statics").NonReactStatics<React.ComponentType<Props> & {
152 (props: Props): JSX.Element;
153 displayName: string;
154}, {}>;
155export { AppbarHeaderWithTheme as AppbarHeader };