@react-navigation/native-stack 6.6.0 → 6.7.0

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.
@@ -42,7 +42,7 @@ export default function NativeStackView({ state, descriptors }: Props) {
42
42
  const previousDescriptor = previousKey
43
43
  ? descriptors[previousKey]
44
44
  : undefined;
45
- const nexDescriptor = nextKey ? descriptors[nextKey] : undefined;
45
+ const nextDescriptor = nextKey ? descriptors[nextKey] : undefined;
46
46
  const { options, navigation, render } = descriptors[route.key];
47
47
 
48
48
  const {
@@ -58,12 +58,13 @@ export default function NativeStackView({ state, descriptors }: Props) {
58
58
  headerStyle,
59
59
  headerShadowVisible,
60
60
  headerTransparent,
61
+ headerBackground,
61
62
  headerBackTitle,
62
63
  presentation,
63
64
  contentStyle,
64
65
  } = options;
65
66
 
66
- const nextPresentation = nexDescriptor?.options.presentation;
67
+ const nextPresentation = nextDescriptor?.options.presentation;
67
68
 
68
69
  return (
69
70
  <Screen
@@ -137,18 +138,10 @@ export default function NativeStackView({ state, descriptors }: Props) {
137
138
  }
138
139
  headerTitleAlign={headerTitleAlign}
139
140
  headerTitleStyle={headerTitleStyle}
140
- headerStyle={[
141
- headerTransparent
142
- ? {
143
- position: 'absolute',
144
- backgroundColor: 'transparent',
145
- }
146
- : null,
147
- headerStyle,
148
- headerShadowVisible === false
149
- ? { shadowOpacity: 0, borderBottomWidth: 0 }
150
- : null,
151
- ]}
141
+ headerTransparent={headerTransparent}
142
+ headerShadowVisible={headerShadowVisible}
143
+ headerBackground={headerBackground}
144
+ headerStyle={headerStyle}
152
145
  />
153
146
  )
154
147
  }