@react-navigation/elements 2.3.6 → 2.3.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/typescript/src/Background.d.ts.map +1 -0
- package/lib/typescript/src/Button.d.ts.map +1 -0
- package/lib/typescript/src/Header/Header.d.ts.map +1 -0
- package/lib/typescript/src/Header/HeaderBackButton.d.ts.map +1 -0
- package/lib/typescript/src/Header/HeaderBackContext.d.ts.map +1 -0
- package/lib/typescript/src/Header/HeaderBackground.d.ts.map +1 -0
- package/lib/typescript/src/Header/HeaderButton.d.ts.map +1 -0
- package/lib/typescript/src/Header/HeaderHeightContext.d.ts.map +1 -0
- package/lib/typescript/src/Header/HeaderIcon.d.ts.map +1 -0
- package/lib/typescript/src/Header/HeaderSearchBar.d.ts.map +1 -0
- package/lib/typescript/src/Header/HeaderShownContext.d.ts.map +1 -0
- package/lib/typescript/src/Header/HeaderTitle.d.ts.map +1 -0
- package/lib/typescript/src/Header/getDefaultHeaderHeight.d.ts.map +1 -0
- package/lib/typescript/src/Header/getHeaderTitle.d.ts.map +1 -0
- package/lib/typescript/src/Header/useHeaderHeight.d.ts.map +1 -0
- package/lib/typescript/src/Label/Label.d.ts.map +1 -0
- package/lib/typescript/src/Label/getLabel.d.ts.map +1 -0
- package/lib/typescript/src/MaskedView.android.d.ts.map +1 -0
- package/lib/typescript/src/MaskedView.d.ts.map +1 -0
- package/lib/typescript/src/MaskedView.ios.d.ts.map +1 -0
- package/lib/typescript/src/MaskedViewNative.d.ts.map +1 -0
- package/lib/typescript/src/MissingIcon.d.ts.map +1 -0
- package/lib/typescript/src/PlatformPressable.d.ts.map +1 -0
- package/lib/typescript/src/ResourceSavingView.d.ts.map +1 -0
- package/lib/typescript/src/SafeAreaProviderCompat.d.ts.map +1 -0
- package/lib/typescript/src/Screen.d.ts.map +1 -0
- package/lib/typescript/src/Text.d.ts.map +1 -0
- package/lib/typescript/src/getDefaultSidebarWidth.d.ts.map +1 -0
- package/lib/typescript/src/getNamedContext.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts.map +1 -0
- package/lib/typescript/src/types.d.ts.map +1 -0
- package/package.json +13 -25
- package/lib/commonjs/Background.js +0 -28
- package/lib/commonjs/Background.js.map +0 -1
- package/lib/commonjs/Button.js +0 -113
- package/lib/commonjs/Button.js.map +0 -1
- package/lib/commonjs/Header/Header.js +0 -344
- package/lib/commonjs/Header/Header.js.map +0 -1
- package/lib/commonjs/Header/HeaderBackButton.js +0 -195
- package/lib/commonjs/Header/HeaderBackButton.js.map +0 -1
- package/lib/commonjs/Header/HeaderBackContext.js +0 -9
- package/lib/commonjs/Header/HeaderBackContext.js.map +0 -1
- package/lib/commonjs/Header/HeaderBackground.js +0 -53
- package/lib/commonjs/Header/HeaderBackground.js.map +0 -1
- package/lib/commonjs/Header/HeaderButton.js +0 -60
- package/lib/commonjs/Header/HeaderButton.js.map +0 -1
- package/lib/commonjs/Header/HeaderHeightContext.js +0 -9
- package/lib/commonjs/Header/HeaderHeightContext.js.map +0 -1
- package/lib/commonjs/Header/HeaderIcon.js +0 -43
- package/lib/commonjs/Header/HeaderIcon.js.map +0 -1
- package/lib/commonjs/Header/HeaderSearchBar.js +0 -291
- package/lib/commonjs/Header/HeaderSearchBar.js.map +0 -1
- package/lib/commonjs/Header/HeaderShownContext.js +0 -9
- package/lib/commonjs/Header/HeaderShownContext.js.map +0 -1
- package/lib/commonjs/Header/HeaderTitle.js +0 -45
- package/lib/commonjs/Header/HeaderTitle.js.map +0 -1
- package/lib/commonjs/Header/getDefaultHeaderHeight.js +0 -38
- package/lib/commonjs/Header/getDefaultHeaderHeight.js.map +0 -1
- package/lib/commonjs/Header/getHeaderTitle.js +0 -10
- package/lib/commonjs/Header/getHeaderTitle.js.map +0 -1
- package/lib/commonjs/Header/useHeaderHeight.js +0 -18
- package/lib/commonjs/Header/useHeaderHeight.js.map +0 -1
- package/lib/commonjs/Label/Label.js +0 -29
- package/lib/commonjs/Label/Label.js.map +0 -1
- package/lib/commonjs/Label/getLabel.js +0 -10
- package/lib/commonjs/Label/getLabel.js.map +0 -1
- package/lib/commonjs/MaskedView.android.js +0 -13
- package/lib/commonjs/MaskedView.android.js.map +0 -1
- package/lib/commonjs/MaskedView.ios.js +0 -13
- package/lib/commonjs/MaskedView.ios.js.map +0 -1
- package/lib/commonjs/MaskedView.js +0 -16
- package/lib/commonjs/MaskedView.js.map +0 -1
- package/lib/commonjs/MaskedViewNative.js +0 -37
- package/lib/commonjs/MaskedViewNative.js.map +0 -1
- package/lib/commonjs/MissingIcon.js +0 -28
- package/lib/commonjs/MissingIcon.js.map +0 -1
- package/lib/commonjs/PlatformPressable.js +0 -147
- package/lib/commonjs/PlatformPressable.js.map +0 -1
- package/lib/commonjs/ResourceSavingView.js +0 -63
- package/lib/commonjs/ResourceSavingView.js.map +0 -1
- package/lib/commonjs/SafeAreaProviderCompat.js +0 -130
- package/lib/commonjs/SafeAreaProviderCompat.js.map +0 -1
- package/lib/commonjs/Screen.js +0 -89
- package/lib/commonjs/Screen.js.map +0 -1
- package/lib/commonjs/Text.js +0 -27
- package/lib/commonjs/Text.js.map +0 -1
- package/lib/commonjs/assets/back-icon-mask.png +0 -0
- package/lib/commonjs/assets/back-icon.png +0 -0
- package/lib/commonjs/assets/back-icon@1x.android.png +0 -0
- package/lib/commonjs/assets/back-icon@1x.ios.png +0 -0
- package/lib/commonjs/assets/back-icon@2x.android.png +0 -0
- package/lib/commonjs/assets/back-icon@2x.ios.png +0 -0
- package/lib/commonjs/assets/back-icon@3x.android.png +0 -0
- package/lib/commonjs/assets/back-icon@3x.ios.png +0 -0
- package/lib/commonjs/assets/back-icon@4x.android.png +0 -0
- package/lib/commonjs/assets/back-icon@4x.ios.png +0 -0
- package/lib/commonjs/assets/clear-icon.png +0 -0
- package/lib/commonjs/assets/clear-icon@1x.png +0 -0
- package/lib/commonjs/assets/clear-icon@2x.png +0 -0
- package/lib/commonjs/assets/clear-icon@3x.png +0 -0
- package/lib/commonjs/assets/clear-icon@4x.png +0 -0
- package/lib/commonjs/assets/close-icon.png +0 -0
- package/lib/commonjs/assets/close-icon@1x.png +0 -0
- package/lib/commonjs/assets/close-icon@2x.png +0 -0
- package/lib/commonjs/assets/close-icon@3x.png +0 -0
- package/lib/commonjs/assets/close-icon@4x.png +0 -0
- package/lib/commonjs/assets/search-icon.png +0 -0
- package/lib/commonjs/assets/search-icon@1x.android.png +0 -0
- package/lib/commonjs/assets/search-icon@1x.ios.png +0 -0
- package/lib/commonjs/assets/search-icon@2x.android.png +0 -0
- package/lib/commonjs/assets/search-icon@2x.ios.png +0 -0
- package/lib/commonjs/assets/search-icon@3x.android.png +0 -0
- package/lib/commonjs/assets/search-icon@3x.ios.png +0 -0
- package/lib/commonjs/assets/search-icon@4x.android.png +0 -0
- package/lib/commonjs/assets/search-icon@4x.ios.png +0 -0
- package/lib/commonjs/getDefaultSidebarWidth.js +0 -23
- package/lib/commonjs/getDefaultSidebarWidth.js.map +0 -1
- package/lib/commonjs/getNamedContext.js +0 -23
- package/lib/commonjs/getNamedContext.js.map +0 -1
- package/lib/commonjs/index.js +0 -205
- package/lib/commonjs/index.js.map +0 -1
- package/lib/commonjs/package.json +0 -1
- package/lib/commonjs/types.js +0 -6
- package/lib/commonjs/types.js.map +0 -1
- package/lib/typescript/commonjs/package.json +0 -1
- package/lib/typescript/commonjs/src/Background.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Button.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/Header.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/HeaderBackButton.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/HeaderBackContext.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/HeaderBackground.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/HeaderButton.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/HeaderHeightContext.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/HeaderIcon.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/HeaderSearchBar.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/HeaderShownContext.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/HeaderTitle.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/getDefaultHeaderHeight.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/getHeaderTitle.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Header/useHeaderHeight.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Label/Label.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Label/getLabel.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/MaskedView.android.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/MaskedView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/MaskedView.ios.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/MaskedViewNative.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/MissingIcon.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/PlatformPressable.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/ResourceSavingView.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/SafeAreaProviderCompat.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Screen.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/Text.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/getDefaultSidebarWidth.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/getNamedContext.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/index.d.ts.map +0 -1
- package/lib/typescript/commonjs/src/types.d.ts.map +0 -1
- package/lib/typescript/module/src/Background.d.ts +0 -9
- package/lib/typescript/module/src/Background.d.ts.map +0 -1
- package/lib/typescript/module/src/Button.d.ts +0 -13
- package/lib/typescript/module/src/Button.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/Header.d.ts +0 -31
- package/lib/typescript/module/src/Header/Header.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/HeaderBackButton.d.ts +0 -3
- package/lib/typescript/module/src/Header/HeaderBackButton.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/HeaderBackContext.d.ts +0 -5
- package/lib/typescript/module/src/Header/HeaderBackContext.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/HeaderBackground.d.ts +0 -9
- package/lib/typescript/module/src/Header/HeaderBackground.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/HeaderButton.d.ts +0 -3
- package/lib/typescript/module/src/Header/HeaderButton.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/HeaderHeightContext.d.ts +0 -2
- package/lib/typescript/module/src/Header/HeaderHeightContext.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/HeaderIcon.d.ts +0 -5
- package/lib/typescript/module/src/Header/HeaderIcon.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/HeaderSearchBar.d.ts +0 -10
- package/lib/typescript/module/src/Header/HeaderSearchBar.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/HeaderShownContext.d.ts +0 -2
- package/lib/typescript/module/src/Header/HeaderShownContext.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/HeaderTitle.d.ts +0 -9
- package/lib/typescript/module/src/Header/HeaderTitle.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/getDefaultHeaderHeight.d.ts +0 -3
- package/lib/typescript/module/src/Header/getDefaultHeaderHeight.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/getHeaderTitle.d.ts +0 -6
- package/lib/typescript/module/src/Header/getHeaderTitle.d.ts.map +0 -1
- package/lib/typescript/module/src/Header/useHeaderHeight.d.ts +0 -2
- package/lib/typescript/module/src/Header/useHeaderHeight.d.ts.map +0 -1
- package/lib/typescript/module/src/Label/Label.d.ts +0 -9
- package/lib/typescript/module/src/Label/Label.d.ts.map +0 -1
- package/lib/typescript/module/src/Label/getLabel.d.ts +0 -5
- package/lib/typescript/module/src/Label/getLabel.d.ts.map +0 -1
- package/lib/typescript/module/src/MaskedView.android.d.ts +0 -2
- package/lib/typescript/module/src/MaskedView.android.d.ts.map +0 -1
- package/lib/typescript/module/src/MaskedView.d.ts +0 -11
- package/lib/typescript/module/src/MaskedView.d.ts.map +0 -1
- package/lib/typescript/module/src/MaskedView.ios.d.ts +0 -2
- package/lib/typescript/module/src/MaskedView.ios.d.ts.map +0 -1
- package/lib/typescript/module/src/MaskedViewNative.d.ts +0 -11
- package/lib/typescript/module/src/MaskedViewNative.d.ts.map +0 -1
- package/lib/typescript/module/src/MissingIcon.d.ts +0 -9
- package/lib/typescript/module/src/MissingIcon.d.ts.map +0 -1
- package/lib/typescript/module/src/PlatformPressable.d.ts +0 -21
- package/lib/typescript/module/src/PlatformPressable.d.ts.map +0 -1
- package/lib/typescript/module/src/ResourceSavingView.d.ts +0 -10
- package/lib/typescript/module/src/ResourceSavingView.d.ts.map +0 -1
- package/lib/typescript/module/src/SafeAreaProviderCompat.d.ts +0 -13
- package/lib/typescript/module/src/SafeAreaProviderCompat.d.ts.map +0 -1
- package/lib/typescript/module/src/Screen.d.ts +0 -18
- package/lib/typescript/module/src/Screen.d.ts.map +0 -1
- package/lib/typescript/module/src/Text.d.ts +0 -3
- package/lib/typescript/module/src/Text.d.ts.map +0 -1
- package/lib/typescript/module/src/getDefaultSidebarWidth.d.ts +0 -4
- package/lib/typescript/module/src/getDefaultSidebarWidth.d.ts.map +0 -1
- package/lib/typescript/module/src/getNamedContext.d.ts +0 -6
- package/lib/typescript/module/src/getNamedContext.d.ts.map +0 -1
- package/lib/typescript/module/src/index.d.ts +0 -25
- package/lib/typescript/module/src/index.d.ts.map +0 -1
- package/lib/typescript/module/src/types.d.ts +0 -325
- package/lib/typescript/module/src/types.d.ts.map +0 -1
- /package/lib/typescript/{module/package.json → package.json} +0 -0
- /package/lib/typescript/{commonjs/src → src}/Background.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Button.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/Header.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/HeaderBackButton.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/HeaderBackContext.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/HeaderBackground.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/HeaderButton.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/HeaderHeightContext.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/HeaderIcon.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/HeaderSearchBar.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/HeaderShownContext.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/HeaderTitle.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/getDefaultHeaderHeight.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/getHeaderTitle.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Header/useHeaderHeight.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Label/Label.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Label/getLabel.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/MaskedView.android.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/MaskedView.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/MaskedView.ios.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/MaskedViewNative.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/MissingIcon.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/PlatformPressable.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/ResourceSavingView.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/SafeAreaProviderCompat.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Screen.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/Text.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/getDefaultSidebarWidth.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/getNamedContext.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/index.d.ts +0 -0
- /package/lib/typescript/{commonjs/src → src}/types.d.ts +0 -0
|
@@ -1,325 +0,0 @@
|
|
|
1
|
-
import type { Animated, LayoutChangeEvent, StyleProp, TextInputProps, TextStyle, ViewStyle } from 'react-native';
|
|
2
|
-
export type HeaderBackButtonDisplayMode = 'default' | 'generic' | 'minimal';
|
|
3
|
-
export type Layout = {
|
|
4
|
-
width: number;
|
|
5
|
-
height: number;
|
|
6
|
-
};
|
|
7
|
-
export type HeaderSearchBarRef = {
|
|
8
|
-
focus: () => void;
|
|
9
|
-
blur: () => void;
|
|
10
|
-
setText: (text: string) => void;
|
|
11
|
-
clearText: () => void;
|
|
12
|
-
cancelSearch: () => void;
|
|
13
|
-
};
|
|
14
|
-
export type HeaderSearchBarOptions = {
|
|
15
|
-
/**
|
|
16
|
-
* Ref to imperatively update the search bar.
|
|
17
|
-
*
|
|
18
|
-
* Supported operations:
|
|
19
|
-
* - `focus` - focuses the search bar
|
|
20
|
-
* - `blur` - removes focus from the search bar
|
|
21
|
-
* - `setText` - sets the search bar's content to given value
|
|
22
|
-
* - `clearText` - removes any text present in the search bar input field
|
|
23
|
-
* - `cancelSearch` - cancel the search and close the search bar
|
|
24
|
-
*/
|
|
25
|
-
ref?: React.Ref<HeaderSearchBarRef>;
|
|
26
|
-
/**
|
|
27
|
-
* The auto-capitalization behavior
|
|
28
|
-
*/
|
|
29
|
-
autoCapitalize?: 'none' | 'words' | 'sentences' | 'characters';
|
|
30
|
-
/**
|
|
31
|
-
* Automatically focuses search input on mount
|
|
32
|
-
*/
|
|
33
|
-
autoFocus?: boolean;
|
|
34
|
-
/**
|
|
35
|
-
* The text to be used instead of default `Cancel` button text
|
|
36
|
-
*
|
|
37
|
-
* @platform ios
|
|
38
|
-
*/
|
|
39
|
-
cancelButtonText?: string;
|
|
40
|
-
/**
|
|
41
|
-
* Sets type of the input. Defaults to `text`.
|
|
42
|
-
*/
|
|
43
|
-
inputType?: 'text' | 'phone' | 'number' | 'email';
|
|
44
|
-
/**
|
|
45
|
-
* Determines how the return key should look. Defaults to `search`.
|
|
46
|
-
*/
|
|
47
|
-
enterKeyHint?: TextInputProps['enterKeyHint'];
|
|
48
|
-
/**
|
|
49
|
-
* A callback that gets called when search input has lost focus
|
|
50
|
-
*/
|
|
51
|
-
onBlur?: TextInputProps['onBlur'];
|
|
52
|
-
/**
|
|
53
|
-
* A callback that gets called when the text changes.
|
|
54
|
-
* It receives the current text value of the search input.
|
|
55
|
-
*/
|
|
56
|
-
onChangeText?: TextInputProps['onChange'];
|
|
57
|
-
/**
|
|
58
|
-
* Callback that is called when the submit button is pressed.
|
|
59
|
-
* It receives the current text value of the search input.
|
|
60
|
-
*/
|
|
61
|
-
onSubmitEditing?: TextInputProps['onSubmitEditing'];
|
|
62
|
-
/**
|
|
63
|
-
* A callback that gets called when search input is opened
|
|
64
|
-
*/
|
|
65
|
-
onOpen?: () => void;
|
|
66
|
-
/**
|
|
67
|
-
* A callback that gets called when search input is closed
|
|
68
|
-
*/
|
|
69
|
-
onClose?: () => void;
|
|
70
|
-
/**
|
|
71
|
-
* A callback that gets called when search input has received focus
|
|
72
|
-
*/
|
|
73
|
-
onFocus?: TextInputProps['onFocus'];
|
|
74
|
-
/**
|
|
75
|
-
* Text displayed when search field is empty
|
|
76
|
-
*/
|
|
77
|
-
placeholder?: string;
|
|
78
|
-
};
|
|
79
|
-
export type HeaderOptions = {
|
|
80
|
-
/**
|
|
81
|
-
* String or a function that returns a React Element to be used by the header.
|
|
82
|
-
* Defaults to screen `title` or route name.
|
|
83
|
-
*
|
|
84
|
-
* It receives `allowFontScaling`, `tintColor`, `style` and `children` in the options object as an argument.
|
|
85
|
-
* The title string is passed in `children`.
|
|
86
|
-
*/
|
|
87
|
-
headerTitle?: string | ((props: HeaderTitleProps) => React.ReactNode);
|
|
88
|
-
/**
|
|
89
|
-
* How to align the the header title.
|
|
90
|
-
* Defaults to `center` on iOS and `left` on Android.
|
|
91
|
-
*/
|
|
92
|
-
headerTitleAlign?: 'left' | 'center';
|
|
93
|
-
/**
|
|
94
|
-
* Style object for the title component.
|
|
95
|
-
*/
|
|
96
|
-
headerTitleStyle?: Animated.WithAnimatedValue<StyleProp<TextStyle>>;
|
|
97
|
-
/**
|
|
98
|
-
* Style object for the container of the `headerTitle` element.
|
|
99
|
-
*/
|
|
100
|
-
headerTitleContainerStyle?: Animated.WithAnimatedValue<StyleProp<ViewStyle>>;
|
|
101
|
-
/**
|
|
102
|
-
* Whether header title font should scale to respect Text Size accessibility settings. Defaults to `false`.
|
|
103
|
-
*/
|
|
104
|
-
headerTitleAllowFontScaling?: boolean;
|
|
105
|
-
/**
|
|
106
|
-
* Options to render a search bar.
|
|
107
|
-
*/
|
|
108
|
-
headerSearchBarOptions?: HeaderSearchBarOptions;
|
|
109
|
-
/**
|
|
110
|
-
* Function which returns a React Element to display on the left side of the header.
|
|
111
|
-
*/
|
|
112
|
-
headerLeft?: (props: HeaderBackButtonProps & {
|
|
113
|
-
/**
|
|
114
|
-
* Whether it's possible to navigate back.
|
|
115
|
-
*/
|
|
116
|
-
canGoBack?: boolean;
|
|
117
|
-
}) => React.ReactNode;
|
|
118
|
-
/**
|
|
119
|
-
* How the back button displays icon and title.
|
|
120
|
-
*
|
|
121
|
-
* Supported values:
|
|
122
|
-
* - "default" - Displays one of the following depending on the available space: previous screen's title, truncated title (e.g. 'Back') or no title (only icon).
|
|
123
|
-
* - "generic" – Displays one of the following depending on the available space: truncated title (e.g. 'Back') or no title (only icon).
|
|
124
|
-
* - "minimal" – Always displays only the icon without a title.
|
|
125
|
-
*
|
|
126
|
-
* Defaults to "default" on iOS, and "minimal" on other platforms.
|
|
127
|
-
*/
|
|
128
|
-
headerBackButtonDisplayMode?: HeaderBackButtonDisplayMode;
|
|
129
|
-
/**
|
|
130
|
-
* Style object for header back title. Supported properties:
|
|
131
|
-
* - fontFamily
|
|
132
|
-
* - fontSize
|
|
133
|
-
*/
|
|
134
|
-
headerBackTitleStyle?: StyleProp<{
|
|
135
|
-
fontFamily?: string;
|
|
136
|
-
fontSize?: number;
|
|
137
|
-
}>;
|
|
138
|
-
/**
|
|
139
|
-
* Style object for the container of the `headerLeft` element`.
|
|
140
|
-
*/
|
|
141
|
-
headerLeftContainerStyle?: Animated.WithAnimatedValue<StyleProp<ViewStyle>>;
|
|
142
|
-
/**
|
|
143
|
-
* Function which returns a React Element to display on the right side of the header.
|
|
144
|
-
*/
|
|
145
|
-
headerRight?: (props: {
|
|
146
|
-
tintColor?: string;
|
|
147
|
-
pressColor?: string;
|
|
148
|
-
pressOpacity?: number;
|
|
149
|
-
canGoBack: boolean;
|
|
150
|
-
}) => React.ReactNode;
|
|
151
|
-
/**
|
|
152
|
-
* Style object for the container of the `headerRight` element.
|
|
153
|
-
*/
|
|
154
|
-
headerRightContainerStyle?: Animated.WithAnimatedValue<StyleProp<ViewStyle>>;
|
|
155
|
-
/**
|
|
156
|
-
* Color for material ripple (Android >= 5.0 only).
|
|
157
|
-
*/
|
|
158
|
-
headerPressColor?: string;
|
|
159
|
-
/**
|
|
160
|
-
* Color for material ripple (Android >= 5.0 only).
|
|
161
|
-
*/
|
|
162
|
-
headerPressOpacity?: number;
|
|
163
|
-
/**
|
|
164
|
-
* Tint color for the header.
|
|
165
|
-
*/
|
|
166
|
-
headerTintColor?: string;
|
|
167
|
-
/**
|
|
168
|
-
* Function which returns a React Element to render as the background of the header.
|
|
169
|
-
* This is useful for using backgrounds such as an image, a gradient, blur effect etc.
|
|
170
|
-
* You can use this with `headerTransparent` to render a blur view, for example, to create a translucent header.
|
|
171
|
-
*/
|
|
172
|
-
headerBackground?: (props: {
|
|
173
|
-
style: Animated.WithAnimatedValue<StyleProp<ViewStyle>>;
|
|
174
|
-
}) => React.ReactNode;
|
|
175
|
-
/**
|
|
176
|
-
* Style object for the container of the `headerBackground` element.
|
|
177
|
-
*/
|
|
178
|
-
headerBackgroundContainerStyle?: Animated.WithAnimatedValue<StyleProp<ViewStyle>>;
|
|
179
|
-
/**
|
|
180
|
-
* Defaults to `false`. If `true`, the header will not have a background unless you explicitly provide it with `headerBackground`.
|
|
181
|
-
* The header will also float over the screen so that it overlaps the content underneath.
|
|
182
|
-
* This is useful if you want to render a semi-transparent header or a blurred background.
|
|
183
|
-
*/
|
|
184
|
-
headerTransparent?: boolean;
|
|
185
|
-
/**
|
|
186
|
-
* Style object for the header. You can specify a custom background color here, for example.
|
|
187
|
-
*/
|
|
188
|
-
headerStyle?: Animated.WithAnimatedValue<StyleProp<ViewStyle>>;
|
|
189
|
-
/**
|
|
190
|
-
* Whether to hide the elevation shadow (Android) or the bottom border (iOS) on the header.
|
|
191
|
-
*
|
|
192
|
-
* This is a short-hand for the following styles:
|
|
193
|
-
*
|
|
194
|
-
* ```js
|
|
195
|
-
* {
|
|
196
|
-
* elevation: 0,
|
|
197
|
-
* shadowOpacity: 0,
|
|
198
|
-
* borderBottomWidth: 0,
|
|
199
|
-
* }
|
|
200
|
-
* ```
|
|
201
|
-
*
|
|
202
|
-
* If the above styles are specified in `headerStyle` along with `headerShadowVisible: false`,
|
|
203
|
-
* then `headerShadowVisible: false` will take precedence.
|
|
204
|
-
*/
|
|
205
|
-
headerShadowVisible?: boolean;
|
|
206
|
-
/**
|
|
207
|
-
* Extra padding to add at the top of header to account for translucent status bar.
|
|
208
|
-
* By default, it uses the top value from the safe area insets of the device.
|
|
209
|
-
* Pass 0 or a custom value to disable the default behaviour, and customize the height.
|
|
210
|
-
*/
|
|
211
|
-
headerStatusBarHeight?: number;
|
|
212
|
-
};
|
|
213
|
-
export type HeaderTitleProps = {
|
|
214
|
-
/**
|
|
215
|
-
* The title text of the header.
|
|
216
|
-
*/
|
|
217
|
-
children: string;
|
|
218
|
-
/**
|
|
219
|
-
* Whether title font should scale to respect Text Size accessibility settings.
|
|
220
|
-
*/
|
|
221
|
-
allowFontScaling?: boolean;
|
|
222
|
-
/**
|
|
223
|
-
* Tint color for the header.
|
|
224
|
-
*/
|
|
225
|
-
tintColor?: string;
|
|
226
|
-
/**
|
|
227
|
-
* Callback to trigger when the size of the title element changes.
|
|
228
|
-
*/
|
|
229
|
-
onLayout?: (e: LayoutChangeEvent) => void;
|
|
230
|
-
/**
|
|
231
|
-
* Style object for the title element.
|
|
232
|
-
*/
|
|
233
|
-
style?: Animated.WithAnimatedValue<StyleProp<TextStyle>>;
|
|
234
|
-
};
|
|
235
|
-
export type HeaderButtonProps = {
|
|
236
|
-
/**
|
|
237
|
-
* Callback to call when the button is pressed.
|
|
238
|
-
*/
|
|
239
|
-
onPress?: () => void;
|
|
240
|
-
/**
|
|
241
|
-
* The `href` to use for the anchor tag on web
|
|
242
|
-
*/
|
|
243
|
-
href?: string;
|
|
244
|
-
/**
|
|
245
|
-
* Whether the button is disabled.
|
|
246
|
-
*/
|
|
247
|
-
disabled?: boolean;
|
|
248
|
-
/**
|
|
249
|
-
* Accessibility label for the button for screen readers.
|
|
250
|
-
*/
|
|
251
|
-
accessibilityLabel?: string;
|
|
252
|
-
/**
|
|
253
|
-
* ID to locate this button in tests.
|
|
254
|
-
*/
|
|
255
|
-
testID?: string;
|
|
256
|
-
/**
|
|
257
|
-
* Tint color for the header button.
|
|
258
|
-
*/
|
|
259
|
-
tintColor?: string;
|
|
260
|
-
/**
|
|
261
|
-
* Color for material ripple (Android >= 5.0 only).
|
|
262
|
-
*/
|
|
263
|
-
pressColor?: string;
|
|
264
|
-
/**
|
|
265
|
-
* Opacity when the button is pressed, used when ripple is not supported.
|
|
266
|
-
*/
|
|
267
|
-
pressOpacity?: number;
|
|
268
|
-
/**
|
|
269
|
-
* Style object for the button.
|
|
270
|
-
*/
|
|
271
|
-
style?: StyleProp<ViewStyle>;
|
|
272
|
-
/**
|
|
273
|
-
* Content to render for the button. Usually the icon.
|
|
274
|
-
*/
|
|
275
|
-
children: React.ReactNode;
|
|
276
|
-
};
|
|
277
|
-
export type HeaderBackButtonProps = Omit<HeaderButtonProps, 'children'> & {
|
|
278
|
-
/**
|
|
279
|
-
* Function which returns a React Element to display custom image in header's back button.
|
|
280
|
-
*/
|
|
281
|
-
backImage?: (props: {
|
|
282
|
-
tintColor: string;
|
|
283
|
-
}) => React.ReactNode;
|
|
284
|
-
/**
|
|
285
|
-
* Label text for the button. Usually the title of the previous screen.
|
|
286
|
-
* By default, this is only shown on iOS.
|
|
287
|
-
*/
|
|
288
|
-
label?: string;
|
|
289
|
-
/**
|
|
290
|
-
* Label text to show when there isn't enough space for the full label.
|
|
291
|
-
*/
|
|
292
|
-
truncatedLabel?: string;
|
|
293
|
-
/**
|
|
294
|
-
* How the back button displays icon and title.
|
|
295
|
-
*
|
|
296
|
-
* Supported values:
|
|
297
|
-
* - "default" - Displays one of the following depending on the available space: previous screen's title, truncated title (e.g. 'Back') or no title (only icon).
|
|
298
|
-
* - "generic" – Displays one of the following depending on the available space: truncated title (e.g. 'Back') or no title (only icon).
|
|
299
|
-
* - "minimal" – Always displays only the icon without a title.
|
|
300
|
-
*
|
|
301
|
-
* Defaults to "default" on iOS, and "minimal" on other platforms.
|
|
302
|
-
*/
|
|
303
|
-
displayMode?: HeaderBackButtonDisplayMode;
|
|
304
|
-
/**
|
|
305
|
-
* Style object for the label.
|
|
306
|
-
*/
|
|
307
|
-
labelStyle?: Animated.WithAnimatedValue<StyleProp<TextStyle>>;
|
|
308
|
-
/**
|
|
309
|
-
* Whether label font should scale to respect Text Size accessibility settings.
|
|
310
|
-
*/
|
|
311
|
-
allowFontScaling?: boolean;
|
|
312
|
-
/**
|
|
313
|
-
* Callback to trigger when the size of the label changes.
|
|
314
|
-
*/
|
|
315
|
-
onLabelLayout?: (e: LayoutChangeEvent) => void;
|
|
316
|
-
/**
|
|
317
|
-
* Layout of the screen.
|
|
318
|
-
*/
|
|
319
|
-
screenLayout?: Layout;
|
|
320
|
-
/**
|
|
321
|
-
* Layout of the title element in the header.
|
|
322
|
-
*/
|
|
323
|
-
titleLayout?: Layout;
|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;IACH,UAAU,CAAC,EAAE,QAAQ,CAAC,iBAAiB,CAAC,SAAS,CAAC,SAAS,CAAC,CAAC,CAAC;IAC9D;;OAEG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B;;OAEG;IACH,aAAa,CAAC,EAAE,CAAC,CAAC,EAAE,iBAAiB,KAAK,IAAI,CAAC;IAC/C;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,CAAC"}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|