Skip to content
This repository was archived by the owner on Feb 25, 2020. It is now read-only.

Commit 3ed1b28

Browse files
committed
feat: add a canGoBack prop to header back button
1 parent 1695290 commit 3ed1b28

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

src/types.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -140,6 +140,7 @@ export type HeaderBackButtonProps = {
140140
onLabelLayout?: (e: LayoutChangeEvent) => void;
141141
screenLayout?: Layout;
142142
titleLayout?: Layout;
143+
canGoBack?: boolean;
143144
};
144145

145146
export type HeaderTitleProps = {

src/views/Header/HeaderSegment.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -313,6 +313,7 @@ export default class HeaderSegment extends React.Component<Props, State> {
313313
screenLayout: layout,
314314
titleLayout,
315315
tintColor: headerTintColor,
316+
canGoBack: Boolean(onGoBack),
316317
})}
317318
</Animated.View>
318319
) : null}

0 commit comments

Comments
 (0)